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

fix: only autoplay videos if visible #194

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

themicknugget
Copy link

If autoplay is enabled, redlib will start playing all videos on the current page, at the same time.

This introduces an observer to only start autoplaying a video if it's visible, and pause it if it stops being visible. This was my expected behavior when I enabled the "autoplay" setting.

@pimlie
Copy link
Contributor

pimlie commented Jul 30, 2024

I guess this should also be fixed by #179 or #181, also added an intersectionobserver in those prs

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

Successfully merging this pull request may close these issues.

2 participants