mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-20 16:55:40 +00:00
f95dd888e1
Per the css-contain specification, size contained elements must be sized as if they were empty. Up until now, we've been handling that by just using "0" as the intrinsic size of some components, but that doesn't actually match the size of a "true" empty select, which has some nonzero width from: (a) the default inline-axis padding on the display frame (added in a rule for the ::-moz-display-comboboxcontrol-frame pseudo, in forms.css). (b) the width (inline-size) of the display frame's "placeholder" space character, which has a small intrinsic width (but which really only exists for *block-axis* sizing and alignment, when no option is selected from the dropdown). This patch addresses issue (a) by explicitly adding the display frame's inline-axis padding to size-contained elements, and it addresses issue (b) by changing to use a zero-width space character in empty select elements. So: as of this patch, size-contained select elements are getting a little wider (to address (a)), and empty select elements are also getting a little skinnier (to address (b)), and they'll end up being the same width. (I chose U+FEFF "zero-width non-breaking-space" since we were previously using a non-breaking space character. I'm not sure if the non-breaking aspect matters, but I figured I'd preserve that to be on the safe side.) Differential Revision: https://phabricator.services.mozilla.com/D48791 --HG-- extra : moz-landing-system : lando |
||
---|---|---|
.. | ||
crashtests | ||
test | ||
moz.build | ||
nsButtonFrameRenderer.cpp | ||
nsButtonFrameRenderer.h | ||
nsCheckboxRadioFrame.cpp | ||
nsCheckboxRadioFrame.h | ||
nsColorControlFrame.cpp | ||
nsColorControlFrame.h | ||
nsComboboxControlFrame.cpp | ||
nsComboboxControlFrame.h | ||
nsDateTimeControlFrame.cpp | ||
nsDateTimeControlFrame.h | ||
nsFieldSetFrame.cpp | ||
nsFieldSetFrame.h | ||
nsFileControlFrame.cpp | ||
nsFileControlFrame.h | ||
nsGfxButtonControlFrame.cpp | ||
nsGfxButtonControlFrame.h | ||
nsHTMLButtonControlFrame.cpp | ||
nsHTMLButtonControlFrame.h | ||
nsIFormControlFrame.h | ||
nsImageControlFrame.cpp | ||
nsISelectControlFrame.h | ||
nsITextControlFrame.h | ||
nsLegendFrame.cpp | ||
nsLegendFrame.h | ||
nsListControlFrame.cpp | ||
nsListControlFrame.h | ||
nsMeterFrame.cpp | ||
nsMeterFrame.h | ||
nsNumberControlFrame.cpp | ||
nsNumberControlFrame.h | ||
nsProgressFrame.cpp | ||
nsProgressFrame.h | ||
nsRangeFrame.cpp | ||
nsRangeFrame.h | ||
nsSelectsAreaFrame.cpp | ||
nsSelectsAreaFrame.h | ||
nsTextControlFrame.cpp | ||
nsTextControlFrame.h |