-
-
Notifications
You must be signed in to change notification settings - Fork 428
Open
Labels
Bug: Needs Confirmation 🧐Bugs that are reported, but needs to be confirmed and replicated.Bugs that are reported, but needs to be confirmed and replicated.
Description
Issue Description
Play button does not change status if call via API or pause/play via device control.
Expected Behavior
// Fix for Amplitude errors - not change play button after media pause/play via control center of device
audioElement.addEventListener('pause', (event) => {
document.getElementById('play-pause').classList.remove('amplitude-playing');
document.getElementById('play-pause').classList.add('amplitude-paused');
document.getElementById('playlist-play-pause').classList.remove('amplitude-playing');
document.getElementById('playlist-play-pause').classList.add('amplitude-paused');
});
audioElement.addEventListener('playing', (event) => {
document.getElementById('play-pause').classList.add('amplitude-playing');
document.getElementById('play-pause').classList.remove('amplitude-paused');
document.getElementById('playlist-play-pause').classList.add('amplitude-playing');
document.getElementById('playlist-play-pause').classList.remove('amplitude-paused');
});
Steps To Reproduce
Lets try fix in core
AmplitudeJS Version
5.3.2
Browser Information
No response
Link To Where Your Issue Can Be Reproduced
No response
Anything else?
No response
rafaeliga
Metadata
Metadata
Assignees
Labels
Bug: Needs Confirmation 🧐Bugs that are reported, but needs to be confirmed and replicated.Bugs that are reported, but needs to be confirmed and replicated.