Spaces:
Running
on
CPU Upgrade
Running
on
CPU Upgrade
Same shortcut as other chatbots
Browse files
src/lib/components/Playground/Playground.svelte
CHANGED
|
@@ -154,7 +154,7 @@
|
|
| 154 |
}
|
| 155 |
|
| 156 |
function onKeydown(event: KeyboardEvent) {
|
| 157 |
-
if (
|
| 158 |
submit();
|
| 159 |
}
|
| 160 |
}
|
|
@@ -367,7 +367,7 @@
|
|
| 367 |
{:else}
|
| 368 |
Run <span
|
| 369 |
class="inline-flex gap-0.5 rounded border border-white/20 bg-white/10 px-0.5 text-xs text-white/70"
|
| 370 |
-
|
| 371 |
>
|
| 372 |
{/if}
|
| 373 |
</button>
|
|
|
|
| 154 |
}
|
| 155 |
|
| 156 |
function onKeydown(event: KeyboardEvent) {
|
| 157 |
+
if (!event.shiftKey && event.key === 'Enter') {
|
| 158 |
submit();
|
| 159 |
}
|
| 160 |
}
|
|
|
|
| 367 |
{:else}
|
| 368 |
Run <span
|
| 369 |
class="inline-flex gap-0.5 rounded border border-white/20 bg-white/10 px-0.5 text-xs text-white/70"
|
| 370 |
+
>↵</span
|
| 371 |
>
|
| 372 |
{/if}
|
| 373 |
</button>
|