diff options
| author | Adam Soltys <[email protected]> | 2023-12-01 20:04:13 -0800 |
|---|---|---|
| committer | Adam Soltys <[email protected]> | 2023-12-01 20:04:13 -0800 |
| commit | 216a600224fde22ce76b367557a02094ec693886 (patch) | |
| tree | d1189bbaa39db204633523132a7d4767b952717d /src/components/Code.svelte | |
| parent | 7d9bc1f54dfd04172e8d6d43ebc2efd6f407e833 (diff) | |
| download | coinos-ui-216a600224fde22ce76b367557a02094ec693886.tar.gz coinos-ui-216a600224fde22ce76b367557a02094ec693886.zip | |
prettier
Diffstat (limited to 'src/components/Code.svelte')
| -rw-r--r-- | src/components/Code.svelte | 42 |
1 files changed, 23 insertions, 19 deletions
diff --git a/src/components/Code.svelte b/src/components/Code.svelte index ffca98a4..6c1048cf 100644 --- a/src/components/Code.svelte +++ b/src/components/Code.svelte @@ -1,27 +1,31 @@ <script> - import { copyNoNewlines as copy } from '$lib/utils'; - import { Icon } from '$comp'; - import samples from '$lib/samples'; - export let sample; + import { copyNoNewlines as copy } from "$lib/utils"; + import { Icon } from "$comp"; + import samples from "$lib/samples"; + export let sample; </script> -<div class="bg-black text-white rounded-lg p-4 flex gap-4 whitespace-pre-wrap font-mono"> - <div class="overflow-x-scroll max-w-full scrollbar-hide"> - <div class="break-all min-w-[800px]">{samples[sample]}</div> - </div> - <button class="ml-auto my-auto invert opacity-90" on:click={() => copy(samples[sample])} - ><Icon icon="copy" style="w-10 max-w-none" /></button - > +<div + class="bg-black text-white rounded-lg p-4 flex gap-4 whitespace-pre-wrap font-mono" +> + <div class="overflow-x-scroll max-w-full scrollbar-hide"> + <div class="break-all min-w-[800px]">{samples[sample]}</div> + </div> + <button + class="ml-auto my-auto invert opacity-90" + on:click={() => copy(samples[sample])} + ><Icon icon="copy" style="w-10 max-w-none" /></button + > </div> <style> - .scrollbar-hide::-webkit-scrollbar { - display: none; - } + .scrollbar-hide::-webkit-scrollbar { + display: none; + } - /* For IE, Edge and Firefox */ - .scrollbar-hide { - -ms-overflow-style: none; /* IE and Edge */ - scrollbar-width: none; /* Firefox */ - } + /* For IE, Edge and Firefox */ + .scrollbar-hide { + -ms-overflow-style: none; /* IE and Edge */ + scrollbar-width: none; /* Firefox */ + } </style> |
