add stop button
Some checks failed
Deploy / deploy (build, debian, 22) (push) Has been cancelled
Deploy / deploy (build:staging, school, 8822) (push) Has been cancelled

This commit is contained in:
2026-04-06 05:50:57 -06:00
parent 8a594446b6
commit 93c816f3ab
2 changed files with 32 additions and 2 deletions

View File

@@ -35,9 +35,16 @@
:disabled="streaming"
/>
<n-button
v-if="streaming"
type="error"
@click="stopPrompt"
>
停止
</n-button>
<n-button
v-else
type="primary"
:loading="streaming"
:disabled="!input.trim() || streaming"
:disabled="!input.trim() || !connected"
@click="send"
>
发送
@@ -55,7 +62,9 @@ import {
messages,
streaming,
streamingContent,
connected,
sendPrompt,
stopPrompt,
} from "../../store/prompt"
const input = ref("")