scrollbar-width CSS property value is also applied to select dropdown arrow
Categories
(Core :: Layout: Form Controls, defect, P3)
Tracking
()
Tracking | Status | |
---|---|---|
firefox78 | --- | fixed |
People
(Reporter: zavecz.krisztina, Assigned: emilio)
References
Details
Attachments
(2 files, 1 obsolete file)
User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:69.0) Gecko/20100101 Firefox/69.0
Steps to reproduce:
Set all elements on page to use thin scrollbars:
* {
scrollbar-width: thin
}
Implement a select field with options.
I'm using Firefox Developer Edition 69.0b10 (64-bit) on Windows 10.
Actual results:
The scrollbar-width property's value is used on the select element's dropdown arrow as well. So the dropdown arrow becomes way too small.
Expected results:
IMO a select's dropdown arrow should not be considered as a scrollbar, thus, scrollbar-width CSS property shouldn't affect it at all.
Workaround: to select, I reset scrollbar-width to "auto", but this shouldn't be necessary.
(ie. for Chrome, I'm using the ::-webkit-scrollbar-thumb pseudo element to style the scrollbars, and the values I give there do not apply to select element's dropdown button. This would be the desirable approach).
Comment 1•5 years ago
|
||
Bugbug thinks this bug should belong to this component, but please revert this change in case of error.
Assignee | ||
Comment 2•5 years ago
|
||
Can you share a screenshot of the rendering of data:text/html,<select style="scrollbar-width: thin"><option>ABCDE</option></select>
?
This looks like a plausible side effect of this line of code, but it looks fine here on Linux anyway (some OSes paint the <select>
differently).
Assignee | ||
Comment 3•5 years ago
|
||
Oh, I guess I can repro everywhere with data:text/html,<select style="scrollbar-width: thin; border: 1px solid"><option>ABCDE</option></select>
Assignee | ||
Comment 5•5 years ago
|
||
Assignee | ||
Updated•5 years ago
|
Reporter | ||
Comment 6•5 years ago
|
||
Reporter | ||
Updated•5 years ago
|
Comment 7•5 years ago
|
||
Try this one
*:not(select) { scrollbar-width: thin }
Reporter | ||
Comment 8•5 years ago
|
||
(In reply to Anand Rathod from comment #7)
Try this one
*:not(select) { scrollbar-width: thin }
This is not that I couldn't solve it by CSS, it is a bug, because scrollbar-width property should not apply to dropdown arrows.
Assignee | ||
Comment 9•5 years ago
|
||
Yes, this is clearly a bug. Sorry I still haven't found time to debug why the test I added in the patch still fails in some platforms...
I need to do that, though I'm swamped with other stuff atm, and this has a very easy work-around (select { scrollbar-width: auto }
) that it's hard to prioritize.
I'll try to get to it, I promise... Though If somebody wants to take over the patch and figure it out I'd be happy to help/mentor :)
Assignee | ||
Updated•4 years ago
|
Assignee | ||
Comment 10•4 years ago
|
||
That is, so that the select dropdown button always take the size of a
native scrollbar rather than a potentially custom scrollbar.
Updated•4 years ago
|
Assignee | ||
Updated•4 years ago
|
Comment 11•4 years ago
|
||
Pushed by ealvarez@mozilla.com: https://hg.mozilla.org/integration/autoland/rev/9de39e80563d Make all themes support non-disappearing scrollbar sizes. r=mstange
Comment 12•4 years ago
|
||
bugherder |
Description
•