From b5a5558f40ce57f51c5fd2e401226db9b3fbf760 Mon Sep 17 00:00:00 2001 From: DDMeaqua Date: Mon, 14 Oct 2024 16:30:47 +0800 Subject: [PATCH] =?UTF-8?q?chore:=20=E6=9B=BF=E6=8D=A2=E6=94=B9=E4=B8=BA?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/components/chat.tsx | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/app/components/chat.tsx b/app/components/chat.tsx index 324fc74c8..5f71bc192 100644 --- a/app/components/chat.tsx +++ b/app/components/chat.tsx @@ -603,7 +603,9 @@ export function ChatActions(props: { }; const onRecognitionEnd = (finalTranscript: string) => { console.log(finalTranscript); - if (finalTranscript) props.setUserInput(finalTranscript); + if (finalTranscript) { + props.setUserInput((prevInput) => prevInput + finalTranscript); + } if (config.sttConfig.engine !== DEFAULT_STT_ENGINE) setIsTranscription(false); };