feat: convo mode

This commit is contained in:
Timothy J. Baek 2024-02-09 17:09:14 -08:00
parent cb5520c519
commit 3015bb766d
3 changed files with 34 additions and 2 deletions

View file

@ -149,6 +149,9 @@
audio.onended = () => {
speaking = null;
if ($settings.conversationMode) {
document.getElementById('voice-input-button')?.click();
}
};
audio.play().catch((e) => console.error('Error playing audio:', e));
}
@ -166,6 +169,9 @@
speak.onend = () => {
speaking = null;
if ($settings.conversationMode) {
document.getElementById('voice-input-button')?.click();
}
};
speak.voice = voice;
speechSynthesis.speak(speak);