mirror of
https://github.com/ChatGPTNextWeb/ChatGPT-Next-Web.git
synced 2025-10-01 15:46:39 +08:00
chore: wip
This commit is contained in:
parent
80a7a1d9d0
commit
43d38249d3
@ -575,16 +575,18 @@ export function ChatActions(props: {
|
||||
if (speechApi) {
|
||||
await speechApi.start();
|
||||
setIsListening(true);
|
||||
document.getElementById("chat-input")?.focus();
|
||||
}
|
||||
};
|
||||
const stopListening = async () => {
|
||||
showToast(Locale.Chat.CloseSpeak);
|
||||
if (speechApi) {
|
||||
if (config.sttConfig.engine !== DEFAULT_STT_ENGINE)
|
||||
setIsTranscription(true);
|
||||
await speechApi.stop();
|
||||
setIsListening(false);
|
||||
}
|
||||
showToast(Locale.Chat.CloseSpeak);
|
||||
document.getElementById("chat-input")?.focus();
|
||||
};
|
||||
const onRecognitionEnd = (finalTranscript: string) => {
|
||||
console.log(finalTranscript);
|
||||
|
Loading…
Reference in New Issue
Block a user