diff options
Diffstat (limited to 'packages/frontend/src/lib/components/ChatInput.svelte')
| -rw-r--r-- | packages/frontend/src/lib/components/ChatInput.svelte | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/packages/frontend/src/lib/components/ChatInput.svelte b/packages/frontend/src/lib/components/ChatInput.svelte index 92c78b9..9563a9f 100644 --- a/packages/frontend/src/lib/components/ChatInput.svelte +++ b/packages/frontend/src/lib/components/ChatInput.svelte @@ -1,9 +1,9 @@ <script lang="ts"> -import { chatStore } from "../chat.svelte.js"; +import { tabStore } from "../tabs.svelte.js"; let inputEl: HTMLInputElement | undefined; let inputValue = $state(""); -const isDisabled = $derived(chatStore.agentStatus === "running"); +const isDisabled = $derived((tabStore.activeTab?.agentStatus ?? "idle") === "running"); $effect(() => { inputEl?.focus(); @@ -20,7 +20,7 @@ function submit() { const text = inputValue.trim(); if (!text || isDisabled) return; inputValue = ""; - chatStore.sendMessage(text); + tabStore.sendMessage(text); } </script> |
