From 539a94a5fcaaecfbe9d1647340c5750712a58711 Mon Sep 17 00:00:00 2001 From: Yatri <yatripatel.169@gmail.com> Date: Sat, 22 Sep 2018 11:46:06 -0700 Subject: [PATCH] Bug 1338158: use 'unset' value more in UA stylesheets, in cases where we're already just resetting the property. r=dholbert --HG-- extra : rebase_source : a3fa80a793a8a531e9f31c7097c2b2451020d724 --- layout/style/res/forms.css | 42 +++++++++++++++++++------------------- layout/style/res/html.css | 6 +++--- layout/style/res/quirk.css | 2 +- 3 files changed, 25 insertions(+), 25 deletions(-) diff --git a/layout/style/res/forms.css b/layout/style/res/forms.css index 88c26e4ea3820..70aaf63e93353 100644 --- a/layout/style/res/forms.css +++ b/layout/style/res/forms.css @@ -274,7 +274,7 @@ select[size="1"] { background-color: -moz-Combobox; color: -moz-ComboboxText; vertical-align: baseline; - padding: 0; + padding: unset; -moz-appearance: menulist; } @@ -331,9 +331,9 @@ select:empty { padding-block-end: 1px; padding-inline-start: 4px; padding-inline-end: 0; - color: inherit; + color: unset; white-space: nowrap; - text-align: inherit; + text-align: unset; -moz-user-select: none; /* Make sure to size correctly if the combobox has a non-auto block-size. */ block-size: 100% ! important; @@ -380,7 +380,7 @@ optgroup { line-height: normal !important; font-style: italic; font-weight: bold; - font-size: inherit; + font-size: unset; -moz-user-select: none; text-indent: 0; white-space: nowrap !important; @@ -432,7 +432,7 @@ select:disabled:disabled /* Need the pseudo-class twice to have the specificity { color: GrayText; background-color: ThreeDLightShadow; - cursor: inherit; + cursor: unset; } input:disabled, @@ -449,7 +449,7 @@ optgroup:disabled { input[type="hidden"] { -moz-appearance: none; display: none !important; - padding: 0; + padding: unset; border: 0; cursor: auto; -moz-user-focus: ignore; @@ -459,7 +459,7 @@ input[type="hidden"] { /* image buttons */ input[type="image"] { -moz-appearance: none; - padding: 0; + padding: unset; border: none; background-color: transparent; font-family: sans-serif; @@ -469,7 +469,7 @@ input[type="image"] { } input[type="image"]:disabled { - cursor: inherit; + cursor: unset; } input[type="image"]:-moz-focusring { @@ -483,7 +483,7 @@ input[type="file"] { white-space: nowrap; overflow: hidden; overflow-clip-box: padding-box; - color: inherit; + color: unset; /* Revert rules which apply on all inputs. */ -moz-appearance: none; @@ -492,7 +492,7 @@ input[type="file"] { border: none; background-color: transparent; - padding: 0; + padding: unset; } input[type="file"] > xul|label { @@ -500,9 +500,9 @@ input[type="file"] > xul|label { padding-inline-start: 5px; text-align: match-parent; - color: inherit; - font-size: inherit; - letter-spacing: inherit; + color: unset; + font-size: unset; + letter-spacing: unset; /* * Force the text to have LTR directionality. Otherwise filenames containing @@ -514,9 +514,9 @@ input[type="file"] > xul|label { /* button part of file selector */ input[type="file"] > button[type="button"] { block-size: inherit; - font-size: inherit; - letter-spacing: inherit; - cursor: inherit; + font-size: unset; + letter-spacing: unset; + cursor: unset; } /* colored part of the color selector button */ @@ -582,7 +582,7 @@ input[type="checkbox"]:disabled, input[type="checkbox"]:disabled:active, input[type="checkbox"]:disabled:hover, input[type="checkbox"]:disabled:hover:active { - cursor: inherit; + cursor: unset; } % On Mac, the native theme takes care of this. @@ -649,7 +649,7 @@ input[type="color"] { button { /* Buttons should lay out like "normal" html, mostly */ - white-space: inherit; + white-space: unset; text-indent: 0; /* But no text-decoration reaching inside, by default */ display: inline-block; @@ -767,7 +767,7 @@ input[type="submit"]:disabled { padding-block-end: 0px; padding-inline-start: 8px; border: 2px outset ThreeDLightShadow; - cursor: inherit; + cursor: unset; } button:disabled:active, button:disabled, @@ -1058,12 +1058,12 @@ input[type=number]::-moz-number-text { * above. We want to inherit its value from its <input type=number> * ancestor, not have that general CSS rule reset it. */ - text-align: inherit; + text-align: unset; text-decoration: inherit; ime-mode: inherit; flex: 1; min-inline-size: 0; - padding: 0; + padding: unset; border: 0; margin: 0; } diff --git a/layout/style/res/html.css b/layout/style/res/html.css index 2f553d3391b54..8a74108b89c9f 100644 --- a/layout/style/res/html.css +++ b/layout/style/res/html.css @@ -472,7 +472,7 @@ table > tr { td { display: table-cell; vertical-align: inherit; - text-align: inherit; + text-align: unset; padding: 1px; } @@ -729,7 +729,7 @@ area { iframe:fullscreen { /* iframes in full-screen mode don't show a border. */ border: none !important; - padding: 0 !important; + padding: unset !important; } /* media elements */ @@ -899,7 +899,7 @@ rtc:lang(zh-TW), rt:lang(zh-TW) { -moz-min-font-size-ratio: 30%; } rtc > rt { - font-size: inherit; + font-size: unset; } ruby, rb, rt, rtc { unicode-bidi: isolate; diff --git a/layout/style/res/quirk.css b/layout/style/res/quirk.css index ba9e6d4acee97..daf01098fa295 100644 --- a/layout/style/res/quirk.css +++ b/layout/style/res/quirk.css @@ -22,7 +22,7 @@ li ul, li ol, li dir, li menu { ol ul, ol ol, ol dir, ol menu, ol li, dir ul, dir ol, dir dir, dir menu, dir li, menu ul, menu ol, menu dir, menu menu, menu li { - list-style-position: inherit; + list-style-position: unset; } -- GitLab