Firefox uses horizontal margin/border/padding when sizing <option> elements, but otherwise ignores these properties (and other browsers ignore them completely)
Categories
(Core :: Layout: Form Controls, defect, P3)
Tracking
()
People
(Reporter: dholbert, Unassigned)
References
Details
Attachments
(2 files)
STR:
- Load attached testcase.
ACTUAL RESULTS:
The select
elements are all different sizes -- i.e. their sizes are influenced by the margin/border/padding specified styles on their option
elements.
EXPECTED RESULTS:
The select
elements should perhaps all be the same size.
Chrome and Edge and Safari all give EXPECTED RESULTS.
One further observation: in Firefox, the option contents (the "a" characters) are all left-aligned at the same position, and the 20px solid pink
border doesn't ever paint. That means we don't actually use these properties (margin/border/padding) when positioning/painting the content. We simply factor them in for sizing purposes, for probably no-good-reason...
Reporter | ||
Updated•5 years ago
|
Reporter | ||
Comment 1•5 years ago
|
||
(Also notable: Firefox ignores the block-axis components of these properties entirely as well -- the margin/border/padding doesn't make these form controls or their option entries any taller.
Reporter | ||
Comment 2•5 years ago
|
||
For <select multiple>
, browsers do consistently honor the margin/border/padding (and do draw the border, and do offset the "a" from the left edge). Here's a testcase to demonstrate that.
So, we don't want to break that currently-interoperably-implemented behavior. This bug is just focused on the dropdown-menu version of <select>, which is not interoperable on this right now and where our behavior doesn't really make any sense.
Reporter | ||
Comment 3•5 years ago
|
||
(Actually -- just for the record -- testcase 2 isn't entirely interoperable, but Firefox & Chrome seem to agree on honoring all the properties, and Edge does as well though they also make the block-level select elements stretch to fill the width of the viewport. Safari 12.1 is the odd one out -- they don't honor the margin/border/padding at all in testcase 2.)
But anyway -- bottom line, the point of this bug is to fix testcase 1 to be interoperable, but probably without changing our behavior on testcase 2.
Updated•2 years ago
|
Description
•