My website.
Find a file
Hornwitser e5ba70d6a9 Prevent perspective shifts when browser toolbar hides
When scrolling the page on mobile and the toolbar gets hidden or made
visible again as a result of scrolling the browser reports the size of
the page having changed when the scrolling ends, which in turn causes
perspective shifts when the finger is lifted from the screen.

Try to work around this by anticipating this resize and calculating the
perspective as if the screen hadn't changed size.

While window.visibleViewport and window.screen in theory could have been
used to determine exactly where and when the browser toolbar is present,
it was found through testing that neither Chrome nor Firefox on Android
reports useful values through these APIs, and instead pretended that the
inner viewport was the whole screen.
2025-02-02 15:46:53 +01:00
.vscode Scaffold project structure 2025-01-21 07:56:15 +01:00
src Set viewport size to inital width 2025-02-02 15:36:14 +01:00
web Prevent perspective shifts when browser toolbar hides 2025-02-02 15:46:53 +01:00
.gitattributes Scaffold project structure 2025-01-21 07:56:15 +01:00
.gitignore Scaffold project structure 2025-01-21 07:56:15 +01:00
package.json Re-organise cli.ts into functions and sub-commands 2025-02-01 16:25:45 +01:00
pnpm-lock.yaml Scaffold project structure 2025-01-21 07:56:15 +01:00
Readme.md Scaffold project structure 2025-01-21 07:56:15 +01:00
tsconfig.json Reorganise source files into src and web 2025-02-02 10:37:42 +01:00

hornwitser.no

The code behind hornwitser.no