misc: chat stop button and tool typing indicator and prevent sending message during composition (#37)

This commit is contained in:
Felix
2026-02-10 19:12:22 +08:00
committed by GitHub
Unverified
parent 29d0db706f
commit 816a0e24a2
3 changed files with 85 additions and 6 deletions

View File

@@ -28,6 +28,7 @@ export function Chat() {
const loadHistory = useChatStore((s) => s.loadHistory);
const loadSessions = useChatStore((s) => s.loadSessions);
const sendMessage = useChatStore((s) => s.sendMessage);
const abortRun = useChatStore((s) => s.abortRun);
const clearError = useChatStore((s) => s.clearError);
const messagesEndRef = useRef<HTMLDivElement>(null);
@@ -145,6 +146,7 @@ export function Chat() {
{/* Input Area */}
<ChatInput
onSend={sendMessage}
onStop={abortRun}
disabled={!isGatewayRunning}
sending={sending}
/>