The modal opens games in an iframe but there's no global mute. Add a 🔊 / 🔇 button next to the fullscreen / restart buttons.
Approach
- Add the button in index.html modal toolbar.
- Use
postMessage to the iframe so individual games can opt in (most won't), but as a fallback set iframe.allow="autoplay 'none'" or use the muted attribute trick.
- Persist the preference in
localStorage.
Good first issue if you've worked with iframe messaging before.
The modal opens games in an iframe but there's no global mute. Add a 🔊 / 🔇 button next to the fullscreen / restart buttons.
Approach
postMessageto the iframe so individual games can opt in (most won't), but as a fallback setiframe.allow="autoplay 'none'"or use the muted attribute trick.localStorage.Good first issue if you've worked with iframe messaging before.