Spaces:
Runtime error
Runtime error
Change copy btn style
Browse files251 unmodified lines2522532542552562572582592602612622632642652662672686 unmodified lines275276277278279280281282251 unmodified lines</div>{#each snippetsByLanguage[selectedLanguage] as { label, code, language }}<div class="px-4 pb-4 pt-6"><h2 class="font-semibold">{label}</h2></div><div class="group relative"><preclass="overflow-x-auto rounded-lg border border-gray-200/80 bg-white px-4 py-6 text-sm shadow-sm dark:border-gray-800 dark:bg-gray-800/50">{@html highlight(code,language ?? selectedLanguage)}</pre><buttonclass="absolute right-3 top-3 opacity-0 transition group-hover:opacity-80"on:click={(e) => {const el = e.currentTarget;el.classList.add('text-green-500');6 unmodified lines}, 1000);}}><IconCopyCode /></button></div>{/each}</div>251 unmodified lines2522532542552562572582592602616 unmodified lines268269270271272273274275276277278279280251 unmodified lines</div>{#each snippetsByLanguage[selectedLanguage] as { label, code, language }}<div class="flex items-center justify-between px-4 pb-4 pt-6"><h2 class="font-semibold">{label}</h2><buttonclass="flex items-center gap-x-1.5 rounded-md bg-gray-200 px-1.5 py-0.5 transition dark:bg-gray-950"on:click={(e) => {const el = e.currentTarget;el.classList.add('text-green-500');6 unmodified lines}, 1000);}}><IconCopyCode /> Copy code</button></div><preclass="overflow-x-auto rounded-lg border border-gray-200/80 bg-white px-4 py-6 text-sm shadow-sm dark:border-gray-800 dark:bg-gray-800/50">{@html highlight(code,language ?? selectedLanguage)}</pre>{/each}</div>
src/lib/components/InferencePlayground/InferencePlaygroundCodeSnippets.svelte+8-10