Orientation lock and safe areas
When opening a game on the phone, hang the full screen + screen orientation, the notch is avoided by the safe-area margin, and the height is reduced to 100dvh according to the address bar.
- Category
- CSS & layout
Technical terms · Screen Orientation API (screen.orientation.lock) · env(safe-area-inset-*) + viewport-fit=cover · Dynamic viewport units (100dvh) · Fullscreen API (requestFullscreen)