membraneframework-labs / membrane_videoroom

Apache License 2.0
42 stars 8 forks source link

Adding dynamic height computation in css MV-475 #177

Closed pkrucz00 closed 1 year ago

pkrucz00 commented 1 year ago

This PR addresses the issue of lack of support for dvh on pre-late-2022 browsers which causes the site to scroll and behave strange on mobile devices.

It uses window.innerHeight property of the browser to calculate the proper pixel value. The css class .h-inner-height changes depending on this value.

The trick has been taken from this article..

I sincerely hope this code of mine will be removed as quickly as dvh will be widely supported.