Consider changing overlay scrollbar default setting ('scrollbar-gutter: stable' does not reserve any space for the scrollbar)
Categories
(Core :: Layout: Scrolling and Overflow, defect, P3)
Tracking
()
People
(Reporter: dramaretskiy, Unassigned)
Details
Attachments
(1 file)
|
2.15 KB,
text/html
|
Details |
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:141.0) Gecko/20100101 Firefox/141.0
Steps to reproduce:
Use 'scrollbar-gutter: stable' on a container element with overflow enabled.
Actual results:
Firefox does not reserve any space for the scrollbar on Win 11.
Expected results:
As advertised by the MDN's own description of the property, it should force the agent to reserve some space for the scrollbar, just like Chrome, Edge and Safari do. I am aware of the bug report 1865074 raised (and closed) earlier and I was able to force FF to behave in the expected way with both 'widget.gtk.overlay-scrollbars.enabled' and 'widget.windows.overlay-scrollbars.enabled' flags set to 'false'. However, in many cases, this can undermine layouts intended by web designers - e.g. imagine the table shown in the testcase file is cloned and the copy is placed next to the master along the horizontal line within a closely spaced container. Determining the required gap between the two is strongly dependent on whether any space is reserved for the scrollbar or not and that is exactly what the 'scrollbar-gutter' property is useful for. My own suggested resolution is that the two flags mentioned above are set to 'false' by default, to align with the majority of the web and to make the browser's behaviour truly 'OS neutral' as it should be.
Comment 1•10 months ago
|
||
The Bugbug bot thinks this bug should belong to the 'Core::Widget: Gtk' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.
Comment 2•10 months ago
|
||
This should belong to win32 instead of Gtk.
Updated•10 months ago
|
Comment 3•10 months ago
|
||
The severity field is not set for this bug.
:hiro, could you have a look please?
For more information, please visit BugBot documentation.
Comment 4•10 months ago
|
||
From the CSS overflow spec;
stable
The scrollbar gutter is present for classic scrollbars when overflow is hidden, scroll, or auto, regardless of whether the box is actually overflowing. Overlay scrollbars do not consume space.
So, the scrollbar-gutter property doesn't affect for overlay scrollbars at all by the definition. I am wondering whether you agree on the current scrollbar-gutter behavior or not since the current bug title "'scrollbar-gutter: stable' does not reserve any space for the scrollbar" is quite confusing.
Also note that Gecko has tried to respect each OS behaviors, I mean features on Gecko depend on OS, for example, the mouse wheel scroll direction MacOS is the opposite direction of Windows and Linux. So the default of overlay scrollbars will not be changed.
Anyways, I'd rather suggest you to open a new spec issue to add a new CSS property to force sites using classic scrollbars.
Comment 5•10 months ago
|
||
Also note that our overlay scrollbars implementation does respect Windows settings, so even if we changed our default, for users who set the Windows setting to use overlay scrollbars, the site will not work as expected.
Comment 6•10 months ago
|
||
I am going to close as WONTFIX.
Description
•