Bug 1673011 - Make the search indicator close button background the same as the urlbar background, which fixes high-contrast mode. r=ntim
authorDrew Willcoxon <adw@mozilla.com>
Tue, 27 Oct 2020 16:54:56 +0000
changeset 554805 4b2288d37d5627f6a7c989e16ff98364e10c095d
parent 554804 095e60791055bf46cd722a87e79459e583933f06
child 554806 e41e89a62d3154397c7d14f4fdb8e580cf428075
push id37898
push userabutkovits@mozilla.com
push dateWed, 28 Oct 2020 09:24:21 +0000
treeherdermozilla-central@83bf4fd3b1fb [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersntim
bugs1673011
milestone84.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1673011 - Make the search indicator close button background the same as the urlbar background, which fixes high-contrast mode. r=ntim Differential Revision: https://phabricator.services.mozilla.com/D94663
browser/themes/shared/urlbar-searchbar.inc.css
--- a/browser/themes/shared/urlbar-searchbar.inc.css
+++ b/browser/themes/shared/urlbar-searchbar.inc.css
@@ -299,20 +299,29 @@
 #urlbar-search-mode-indicator-close {
   display: none;
   background: url(chrome://global/skin/icons/close.svg) no-repeat center;
   background-size: 100% 16px;
   width: 16px;
   height: 100%;
   margin-inline-start: -16px;
   -moz-context-properties: fill, fill-opacity, stroke-opacity;
-  fill: currentColor;
   fill-opacity: 0;
   stroke-opacity: 0.6;
-  background-color: var(--lwt-toolbar-field-background-color, white);
+  /* fill and background-color should match the urlbar focused color and
+     background. */
+  fill: currentColor;
+  background-color: Field;
+}
+
+#urlbar-search-mode-indicator-close:-moz-lwtheme {
+  /* fill and background-color should match the urlbar focused color and
+     background. */
+  fill: var(--lwt-toolbar-field-focus-color);
+  background-color: var(--lwt-toolbar-field-focus);
 }
 
 #urlbar-search-mode-indicator:hover  > #urlbar-search-mode-indicator-close {
   display: inline;
 }
 
 @supports -moz-bool-pref("browser.urlbar.experimental.searchModeIndicatorHover") {
   #urlbar-search-mode-indicator-close:hover {