animebook / animebook.github.io

In-browser video player for learning Japanese with subtitles
https://animebook.github.io
MIT License
273 stars 29 forks source link

Audio doesn't autoplay in the latest version of Chromium #41

Closed soamsy closed 2 years ago

soamsy commented 2 years ago

Chromium version 96.0.4664.110.

When recording a flashcard, I get this error and no audio playback. Uncaught (in promise) DOMException: play() failed because the user didn't interact with the document first.

The user is interacting with the document, but because the audio playback happens in the extension's background page in an iframe, Chromium is likely detecting it as though you didn't interact with it. I can probably get around this by sending the audio data back to the extension's front-end and playing it there.

soamsy commented 2 years ago

Fixed in the latest release.