style
Browse files
src/lib/components/InferencePlayground/InferencePlaygroundCodeSnippets.svelte
CHANGED
@@ -297,13 +297,13 @@ print(output.choices[0].message)`,
|
|
297 |
<h2 class="font-semibold">{label}</h2>
|
298 |
<div class="flex items-center gap-x-4">
|
299 |
{#if needsToken && hfToken}
|
300 |
-
<label class="flex items-center gap-x-1.5 text-sm">
|
301 |
<input type="checkbox" bind:checked={showToken} />
|
302 |
-
<p class="leading-none">
|
303 |
</label>
|
304 |
{/if}
|
305 |
<button
|
306 |
-
class="flex items-center gap-x-
|
307 |
on:click={e => {
|
308 |
const el = e.currentTarget;
|
309 |
el.classList.add("text-green-500");
|
@@ -316,7 +316,7 @@ print(output.choices[0].message)`,
|
|
316 |
}, 400);
|
317 |
}}
|
318 |
>
|
319 |
-
<IconCopyCode /> Copy code
|
320 |
</button>
|
321 |
</div>
|
322 |
</div>
|
|
|
297 |
<h2 class="font-semibold">{label}</h2>
|
298 |
<div class="flex items-center gap-x-4">
|
299 |
{#if needsToken && hfToken}
|
300 |
+
<label class="flex items-center gap-x-1.5 text-sm select-none">
|
301 |
<input type="checkbox" bind:checked={showToken} />
|
302 |
+
<p class="leading-none">With token</p>
|
303 |
</label>
|
304 |
{/if}
|
305 |
<button
|
306 |
+
class="flex items-center gap-x-2 rounded-md bg-white border dark:border-gray-800 shadow-sm px-1.5 py-0.5 text-sm transition dark:bg-gray-800"
|
307 |
on:click={e => {
|
308 |
const el = e.currentTarget;
|
309 |
el.classList.add("text-green-500");
|
|
|
316 |
}, 400);
|
317 |
}}
|
318 |
>
|
319 |
+
<IconCopyCode classNames="text-xs"/> Copy code
|
320 |
</button>
|
321 |
</div>
|
322 |
</div>
|
src/lib/components/InferencePlayground/InferencePlaygroundConversation.svelte
CHANGED
@@ -49,7 +49,7 @@
|
|
49 |
{/each}
|
50 |
|
51 |
<button
|
52 |
-
class="flex px-6 py-6 hover:bg-gray-50 dark:hover:bg-gray-800/50"
|
53 |
on:click={() => dispatch("addMessage")}
|
54 |
disabled={loading}
|
55 |
>
|
|
|
49 |
{/each}
|
50 |
|
51 |
<button
|
52 |
+
class="flex px-3.5 md:px-6 py-6 hover:bg-gray-50 dark:hover:bg-gray-800/50"
|
53 |
on:click={() => dispatch("addMessage")}
|
54 |
disabled={loading}
|
55 |
>
|
src/lib/components/InferencePlayground/InferencePlaygroundHFTokenModal.svelte
CHANGED
@@ -78,9 +78,9 @@
|
|
78 |
</div>
|
79 |
<!-- Modal body -->
|
80 |
<div class="p-4 md:p-5">
|
81 |
-
<p class="text-base leading-relaxed text-gray-800
|
82 |
You need a free Hugging Face token to use this application. <strong class="font-semibold"
|
83 |
-
>Make sure you create a token with Inference API
|
84 |
><br /> Your token is kept safe by only being used from your browser.
|
85 |
</p>
|
86 |
<div>
|
@@ -106,7 +106,7 @@
|
|
106 |
<!-- Modal footer -->
|
107 |
<div class="flex items-center justify-between rounded-b border-t border-gray-200 p-4 md:p-5 dark:border-gray-600">
|
108 |
<a
|
109 |
-
href="https://huggingface.co/settings/tokens/new?globalPermissions=inference.serverless.write&tokenType=fineGrained"
|
110 |
tabindex="-1"
|
111 |
target="_blank"
|
112 |
class="rounded-lg border border-gray-200 bg-white px-5 py-2.5 text-sm font-medium text-gray-900 hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:outline-none focus:ring-4 focus:ring-gray-100 dark:border-gray-600 dark:bg-gray-800 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white dark:focus:ring-gray-700"
|
|
|
78 |
</div>
|
79 |
<!-- Modal body -->
|
80 |
<div class="p-4 md:p-5">
|
81 |
+
<p class="text-base leading-relaxed text-gray-800 dark:text-gray-300 mb-5">
|
82 |
You need a free Hugging Face token to use this application. <strong class="font-semibold"
|
83 |
+
>Make sure you create a token with Gated models access and Inference API permissions.</strong
|
84 |
><br /> Your token is kept safe by only being used from your browser.
|
85 |
</p>
|
86 |
<div>
|
|
|
106 |
<!-- Modal footer -->
|
107 |
<div class="flex items-center justify-between rounded-b border-t border-gray-200 p-4 md:p-5 dark:border-gray-600">
|
108 |
<a
|
109 |
+
href="https://huggingface.co/settings/tokens/new?globalPermissions=inference.serverless.write&canReadGatedRepos=true&tokenType=fineGrained"
|
110 |
tabindex="-1"
|
111 |
target="_blank"
|
112 |
class="rounded-lg border border-gray-200 bg-white px-5 py-2.5 text-sm font-medium text-gray-900 hover:bg-gray-100 hover:text-blue-700 focus:z-10 focus:outline-none focus:ring-4 focus:ring-gray-100 dark:border-gray-600 dark:bg-gray-800 dark:text-gray-400 dark:hover:bg-gray-700 dark:hover:text-white dark:focus:ring-gray-700"
|