From 5542b5e9a618fe6ddbc79ca5e06f07f2c0f4c767 Mon Sep 17 00:00:00 2001 From: Laurence Juden Date: Wed, 24 Aug 2022 20:55:40 +0200 Subject: [PATCH] Allow user to disable audio --- index.html | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/index.html b/index.html index cbdecff9..077819e4 100644 --- a/index.html +++ b/index.html @@ -45,6 +45,7 @@
Advanced settings: [show]
+



@@ -183,7 +184,12 @@ async function makeImage() { btn.innerHTML = 'Make Image' btn.disabled = false; - playSound() + + const shouldPlaySound = document.querySelector('#sound_toggle').checked + + if (shouldPlaySound) { + playSound() + } if (!res) { return