Spaces:
Sleeping
Sleeping
Make iOS audio unlock non-blocking to prevent flow interruption
Browse files1006 unmodified lines100710081009101010111012101310141015101610171006 unmodified linesdocument.getElementById('vgActive').style.display = 'flex';document.getElementById('vgInputArea').classList.add('active');// Unlock audio on iOS with user gesturetry {const silentAudio = new Audio("data:audio/wav;base64,UklGRiQAAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQAAAAA=");await silentAudio.play();silentAudio.pause();} catch (e) { /* OK if blocked */ }// Load walkthrough definition1006 unmodified lines10071008100910101011101210131014101510161006 unmodified linesdocument.getElementById('vgActive').style.display = 'flex';document.getElementById('vgInputArea').classList.add('active');// Unlock audio on iOS with user gesture (non-blocking)try {const silentAudio = new Audio("data:audio/wav;base64,UklGRiQAAABXQVZFZm10IBAAAAABAAEARKwAAIhYAQACABAAZGF0YQAAAAA=");silentAudio.play().then(() => silentAudio.pause()).catch(() => {});} catch (e) { /* OK if blocked */ }// Load walkthrough definition
frontend/index.html+2-3