volume icon verbeteringen

This commit is contained in:
2024-07-24 22:09:14 +02:00
parent 9187470df5
commit c0af89c6e5
2 changed files with 7 additions and 2 deletions
+3 -1
View File
@@ -101,10 +101,12 @@
console.log(event);
let volume = event.target.value / 11;
event.target.classList.add("playing");
event.target.classList.remove("muted");
kankerherrie.play();
if (volume <= 1/11) {
kankerherrie.pause();
event.target.classList.remove("playing");
event.target.classList.remove("playing");
event.target.classList.add("muted");
}
kankerherrie.volume = volume;
})