cleared lines names

This commit is contained in:
2026-01-27 01:10:10 +01:00
parent 9f4ab194be
commit 559d9dc9e6

View File

@@ -11,9 +11,9 @@ const AWARDED_LINE_CLEARS = {
const CLEARED_LINES_NAMES = [ const CLEARED_LINES_NAMES = [
"", "",
"SOLO", "LIGNE",
"DUO", "DOUBLE",
"TRIO", "TRIPLE",
"TETRA", "TETRA",
] ]
@@ -192,16 +192,10 @@ class Stats {
const speechSynthesisAvailable = 'speechSynthesis' in window; const speechSynthesisAvailable = 'speechSynthesis' in window;
let utterance;
if ('SpeechSynthesisUtterance' in window) {
utterance = new SpeechSynthesisUtterance();
utterance.lang = 'fr-FR';
}
function speak(text, volume=1) { function speak(text, volume=1) {
if (!utterance) return; if (!speechSynthesisAvailable) return;
const utterance = new SpeechSynthesisUtterance(text);
utterance.text = text ; utterance.lang = 'fr-FR';
utterance.volume = volume; utterance.volume = volume;
speechSynthesis.speak(utterance); speechSynthesis.speak(utterance);
} }