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

perf(react-sdk): add "visibilitychange" event handler #634

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

Conversation

arnautov-anton
Copy link
Contributor

Also:

  • fixes issue where PIP participant becomes viewport "invisible" and freezes PIP video


const handleVisibilityChange = () => {
const isDocumentVisible = document.visibilityState === 'visible';
const isPIP = trackedElement.contains(document.pictureInPictureElement);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What does "PIP" mean? Could you add a comment @arnautov-anton ? I understand that it is picture in picture

@arnautov-anton arnautov-anton force-pushed the feat/visibilitychange branch from b4d9a4c to 974fa78 Compare June 28, 2023 15:25
@arnautov-anton arnautov-anton force-pushed the feat/visibilitychange branch from 974fa78 to 20b3f8b Compare July 18, 2023 09:38
@sonarcloud
Copy link

sonarcloud bot commented Jul 18, 2023

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

0.0% 0.0% Coverage
0.0% 0.0% Duplication

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