cloudflare / cloudflare/stream-react

Responsive video gets cut off when using full screen API on parent element

Open
#64 6 comments 0 reactions 0 assignees View on GitHub
Dominant language
TypeScript
Stars
198
Forks
30
PR merge metrics
No merged PRs in 30d

Description

I have a situation where I have the player wrapped in a parent div that the user can toggle full screen on, as in, not by using the fullscreen button in the player itself. This is so that other elements can be included in fullscreen mode. The lib I'm using for this is [https://www.npmjs.com/package/react-full-screen](https://www.npmjs.com/package/react-full-screen).

The problem is that the aspect ratio doesn't get updated correctly which results in the video getting cut off on large screens.

It looks to be because of the `padding-top` on the iframe wrapper div.

Screen Shot 2022-04-15 at 14 33 12
Screen Shot 2022-04-15 at 14 33 36

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.