quiz sentence hide details and stop audio before starting next

This commit is contained in:
polv committed 2026-07-05 12:01:32 +07:00
1 parent eff1227b20
commit 09af058fa1
3 files changed
+26 -1

No files matched your search

+4
View File
@@ -30,6 +30,10 @@ async function playAudio() {
const voices = await getVoices(lang);
if (!voices.length) return;
document.querySelectorAll("audio").forEach((el) => {
el.pause();
});
const v = voices[Math.floor(Math.random() * voices.length)];
console.log(JSON.stringify(v));
await speak({