You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Again obsessing over the smallest detail π π π
When the current page is longer than the screen, the pages becomes slightly narrower to accommodate the scrollbar.
This is enough to cause a layout shift, most notably in the top bar.
The top navigation bar must be fixed while browsing. Buttons constantly moving is very annoying.
Notice how I'm not moving my mouse, yet I'm clicking different buttons
scrollbar.mp4
To Reproduce
Find the "perfect" width, where the scrollbar dictates whether the right-most button fits in the top bar.
Flip between pages with and without the scrollbar
Probably happens on desktop only. Mobile overlays the scrollbar as far as I can tell
Expected behavior
I expect the webpage to allocate some empty space for the scrollbar?
I found scrollbar-gutter exists. This does the job, but it may not be the prettiest solution.
html {
scrollbar-gutter: stable both-edges;
}
scrollbar-gutter.mp4
Probably the right way to do it, is some clever padding..
Describe the bug
Again obsessing over the smallest detail π π π
When the current page is longer than the screen, the pages becomes slightly narrower to accommodate the scrollbar.
This is enough to cause a layout shift, most notably in the top bar.
The top navigation bar must be fixed while browsing. Buttons constantly moving is very annoying.
Notice how I'm not moving my mouse, yet I'm clicking different buttons
scrollbar.mp4
To Reproduce
Probably happens on desktop only. Mobile overlays the scrollbar as far as I can tell
Expected behavior
I expect the webpage to allocate some empty space for the scrollbar?
I found scrollbar-gutter exists. This does the job, but it may not be the prettiest solution.
scrollbar-gutter.mp4
Probably the right way to do it, is some clever padding..
Affected browsers
Chrome
Stacktrace