md-select/settings-dropdown-menu dropdown arrow overlaps text |
|||||
Issue descriptionIn a native <select>, text does not overlay underneath the dropdown arrow: https://jsfiddle.net/v6r7d8c2/ The <settings-dropdown-menu> hides the native frame and uses a background image positioned at 97% 70% for the arrow: https://jsfiddle.net/szuetokm/ If we remove the <settings-dropdown-menu> |width| styling (so it fits the content), the result is similar: https://jsfiddle.net/k3Lyyfgh/ I played around with this a bit for the timezone dropdown menu, which can be quite long. Using a -webkit-padding-end value of twice the background-image width, combined with setting background-position-x to "right" (because 97% doesn't scale properly with different font sizes/zoom levels). BTW, it would be easier to vertically center the dropdown arrow if you chop off the bottom 12px of the svg's viewbox. Otherwise the vertical position of the arrow won't scale easily with font sizes/zoom levels.
,
Oct 7 2016
[corrected links] Here is a before/after at various widths and font sizes: before - https://jsfiddle.net/pjwL97v5/1 after - https://jsfiddle.net/sfsb48gh/ using a -webkit-padding-end of 1.5x and background-position: right 70%.
,
Oct 7 2016
Issue 653824 has been merged into this issue.
,
Oct 7 2016
,
Oct 7 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/577dc9d546b6b77bb3ee2158e1aa4805d4f5adcd commit 577dc9d546b6b77bb3ee2158e1aa4805d4f5adcd Author: dpapad <dpapad@chromium.org> Date: Fri Oct 07 21:33:22 2016 MD Settings: Ensure that long text does not overlap with <select> arrow. Thanks to @michaelpg for the suggestions. BUG= 653755 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:closure_compilation Review-Url: https://codereview.chromium.org/2401093002 Cr-Commit-Position: refs/heads/master@{#423971} [modify] https://crrev.com/577dc9d546b6b77bb3ee2158e1aa4805d4f5adcd/chrome/browser/resources/settings/images/arrow_down.svg [modify] https://crrev.com/577dc9d546b6b77bb3ee2158e1aa4805d4f5adcd/chrome/browser/resources/settings/md_select_css.html
,
Oct 7 2016
,
Oct 21 2016
Verified on ChromeOS 8911.0.0, 56.0.2894.0 |
|||||
►
Sign in to add a comment |
|||||
Comment 1 Deleted