Scrollbar-gutter shows on resize with with position:sticky on bottom
Categories
(Core :: Layout: Positioned, defect, P3)
Tracking
()
People
(Reporter: moz, Unassigned)
References
(Depends on 1 open bug, )
Details
Attachments
(2 files)
Mozilla/5.0 (Windows NT 6.1; Win64; x64; rv:109.0) Gecko/20100101 Firefox/113.0
- Visit
peter-hindelang.de/PH.html
EDIT: new URL peter-hindelang.de/Vita.html
EDIT: new URL https://peter-hindelang.de/Vita/
There is a background-image covering the viewport(background-size: cover) - Resize window (by clicking resize-button near window closing button [x]) or reduce window height by mouse
Result (almost always for me):
Background-image dosesn't cover the whole viewport, the space of right scrollbar is coverd by the dark background-color. Needs reload to get the expected result
I'v seen this sometimes without window resizing as well.
Tested on Windows 7 with Fx 113.0.2 and current Nightly 115.
Additional info: This page https://peter-hindelang.de/
has a similar issue but it is hard to reproduce. Sometimes the background-image disapears completely, e.g. after sitching tabs.
(Edit: That similar issue affects the reported URL as well)
Updated•2 years ago
|
Sorry, I have to correct me (there isn't background-size:cover at all, background is a bit more tricky).
The problem is triggerd by position:sticky. It fixes the <address> element on bottom.
Comment 2•2 years ago
|
||
I don't seem to be able to reproduce on nightly, on Linux...
Comment 3•2 years ago
|
||
You need classic scrollbars to reproduce. Looks like something where the page structure will cause an intermediate reflow with a scrollbar and then the final reflow will show that a scrollbar is not required, but somehow the page rect with the scrollbar is getting used stale somewhere.
Comment 4•2 years ago
|
||
The severity field is not set for this bug.
:alaskanemily, could you have a look please?
For more information, please visit BugBot documentation.
Found a hack to work around this bug and implemented it in https://peter-hindelang.de/Vita/
function bugfix(x) {
document.documentElement.style.overflow = x;
}
onresize = function() {
bugfix("");
setTimeout(bugfix, 0, "auto");
}
May it be helpful.
Comment 6•1 year ago
|
||
So, thanks to :tnikkel's comment and yours I can reproduce now. This has nothing to do with background-size or anything, it's just about whether we think scrollbars should appear or not.
The viewport-relative padding on the <body> helps reproduce, but I can repro when reducing the size without it.
Ting-Yu, you're the most familiar with scrollbar-gutter-related issues, maybe you can dig a bit to see if we can prevent this from happening?
Comment 7•1 year ago
•
|
||
.
Comment 8•1 year ago
|
||
This happens just with block layout too.
Comment 9•1 year ago
|
||
Ting-Yu, you're the most familiar with scrollbar-gutter-related issues, maybe you can dig a bit to see if we can prevent this from happening?
This is actually is a sticky positioning and overflow area issue. My proposed patches in bug 1748891 fixed testcases in this bug. I'll make this a dup after my patches are accepted.
Comment 10•1 year ago
|
||
Both reduced testcase in comment 6 and comment 8 are fixed by bug 1748891. Tested on Nightly 127.0a1 (2024-04-26).
Description
•