NEW 271051
Visual Viewport API returning inaccurate values
https://bugs.webkit.org/show_bug.cgi?id=271051
Summary Visual Viewport API returning inaccurate values
Christian "Schepp" Schaefer
Reported 2024-03-15 04:01:30 PDT
Created attachment 470381 [details] QR-Code with URL to test case WebKit has a bug where, when pinch-zooming, the result of `visualViewport.width` × `visualViewport.scale` does not correspond to the layout viewport's width, although it should. This leads to jumpy and wiggly fixed positioned element during pinch-zoom, when they rely on this calculation. More explanation and a test case: https://schepp.dev/demos/webkit-visual-viewport-api-bug/
Attachments
QR-Code with URL to test case (18.32 KB, image/png)
2024-03-15 04:01 PDT, Christian "Schepp" Schaefer
no flags
Radar WebKit Bug Importer
Comment 1 2024-03-18 20:14:31 PDT
Bramus
Comment 2 2024-03-25 08:34:57 PDT
Can confirm this bug on this demo page: https://interop-2022-viewport.netlify.app/individual/visual-viewport/ The values for `widthXscale` and `heightXscale` are off by a few pixels upon pinch zooming in/out.
Note You need to log in before you can comment on or make changes to this bug.