-
Notifications
You must be signed in to change notification settings - Fork 133
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
Feature Request: Use Document Picture-in-Picture Web API #1211
Comments
Hi @beaufortfrancois and thanks for reaching out for this browser update! The feature looks nicer than the current API as we now will be able to also integrate subtitles and even some of the application's UI in the window. Though I checked and didn't see support for other browsers than Chrome (the spec seems to be an "Unofficial Proposal Draft" and its Chrome Platform Status page indicates "no signal" and even some reticences from other vendors). Is there incoming updates to the API to reach a consensus? I would prefer a browser-independent solution. Also, I think that in a RxPlayer context, it will be the role of the application (who integrates the RxPlayer) to actually rely on such API so it can decide what to put in it. However, the RxPlayer might want to detect when a pip window containing the video element is displayed for two reasons:
|
Exactly! 🥳
The Chrome team is the one proposing this API based on feedback we’ve received from the Picture-in-Picture API for
Yes. You can also check at any time whether
Yes.
Would
Is it safe to assume the video size covers 100% of the PiP window size?
I’ve just tried it and I still get updates from a const resizeObserver = new ResizeObserver((entries) => {
console.log(`New size: ${entries[0].target.clientWidth}x${entries[0].target.clientHeight}`);
});
resizeObserver.observe(document.querySelector('video')); |
Users should be able to use the RxPlayer in a Picture-in-Picture window, not just the video inside the player.
Before the Document Picture-in-Picture API, it was only possible to put an HTML
<video>
element into a Picture-in-Picture window. This new API makes it possible to open an always-on-top window that can be populated with arbitrary HTML content. It is available as an origin trial starting in Chrome 111 on desktop.Documentation:
The text was updated successfully, but these errors were encountered: