Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pause video when "Pause playback when video is no longer in view" #234

Open
clara-am opened this issue May 18, 2022 · 0 comments
Open

Pause video when "Pause playback when video is no longer in view" #234

clara-am opened this issue May 18, 2022 · 0 comments

Comments

@clara-am
Copy link

I'm trying to use these option in the config, however it doesn't work like I was expecting.
I would like to pause the video when you minimize/left to see the window and not only when you navigate to other place and the component lefts to be visible. Maybe using sth like these in:

document.addEventListener( 'visibilitychange' , function() {
if (document.hidden) {
self.onWidgetInview();
} else {
self.onOverlayClick();
}
}, false );

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

No branches or pull requests

3 participants