fix: Scroll chat to bottom immediately on user message send

This commit is contained in:
2026-02-16 01:21:13 -06:00
parent e54157a6d8
commit cf2755a731

View File

@@ -579,10 +579,9 @@ function handleSessionChange(sessionId: string) {
function handleSubmit(text: string) {
messages.push({ id: ++idCounter, role: 'user', content: text, status: 'sent' })
scrollToBottom()
emit('submit', text)
// Send text as input to the agent's terminal PTY
agentTerminal.sendPrompt(text)
// Real response will arrive via transcript-update WebSocket
}
function handleMic() {
@@ -599,9 +598,9 @@ function handleTranscriptDone(text: string) {
if (!text.trim()) return
messages.push({ id: ++idCounter, role: 'user', content: text, status: 'sent' })
scrollToBottom()
emit('submit', text)
agentTerminal.sendPrompt(text)
// Real response will arrive via transcript-update WebSocket
}
function toggleSettings() {