diff --git a/browser/themes/linux/browser.css b/browser/themes/linux/browser.css index f9f33ebde546..6501ed29b1c5 100644 --- a/browser/themes/linux/browser.css +++ b/browser/themes/linux/browser.css @@ -270,6 +270,11 @@ notification[value="translation"] menulist > .menulist-dropmarker { /* AutoComplete */ %include ../shared/autocomplete.inc.css + +#PopupAutoComplete > richlistbox > richlistitem[originaltype~="datalist-first"] { + border-top: 1px solid ThreeDShadow; +} + %include ../shared/urlbar-autocomplete.inc.css :root { @@ -277,10 +282,6 @@ notification[value="translation"] menulist > .menulist-dropmarker { --urlbar-popup-action-color: -moz-nativehyperlinktext; } -#PopupAutoComplete > richlistbox > richlistitem[originaltype~="datalist-first"] { - border-top: 1px solid ThreeDShadow; -} - .urlbarView { font-size: 1.05em; } diff --git a/browser/themes/osx/browser.css b/browser/themes/osx/browser.css index f27991a5e571..a7efe753d19c 100644 --- a/browser/themes/osx/browser.css +++ b/browser/themes/osx/browser.css @@ -282,6 +282,11 @@ /* ----- AUTOCOMPLETE ----- */ %include ../shared/autocomplete.inc.css + +#PopupAutoComplete > richlistbox > richlistitem[originaltype~="datalist-first"] { + border-top: 1px solid #C7C7C7; +} + %include ../shared/urlbar-autocomplete.inc.css :root { @@ -289,8 +294,10 @@ --urlbar-popup-action-color: hsl(178, 100%, 28%); } -#PopupAutoComplete > richlistbox > richlistitem[originaltype~="datalist-first"] { - border-top: 1px solid #C7C7C7; +.urlbarView:not(:-moz-lwtheme), +#PopupSearchAutoComplete:not(:-moz-lwtheme) { + /* Set custom disabled text color since native graytext is too faint on macOS 10.14+. */ + --panel-disabled-color: #737373; } .urlbarView { diff --git a/browser/themes/windows/browser.css b/browser/themes/windows/browser.css index 189c1f6e09e3..896710294e0e 100644 --- a/browser/themes/windows/browser.css +++ b/browser/themes/windows/browser.css @@ -572,12 +572,13 @@ menuitem.bookmark-item { /* autocomplete */ %include ../shared/autocomplete.inc.css -%include ../shared/urlbar-autocomplete.inc.css #PopupAutoComplete > richlistbox > richlistitem[originaltype~="datalist-first"] { border-top: 1px solid ThreeDShadow; } +%include ../shared/urlbar-autocomplete.inc.css + @media (-moz-windows-default-theme) { :root { --urlbar-popup-url-color: hsl(210, 77%, 47%); diff --git a/toolkit/components/extensions/test/browser/browser_ext_themes_autocomplete_popup.js b/toolkit/components/extensions/test/browser/browser_ext_themes_autocomplete_popup.js index 40165e9ba332..df4e44794b5b 100644 --- a/toolkit/components/extensions/test/browser/browser_ext_themes_autocomplete_popup.js +++ b/toolkit/components/extensions/test/browser/browser_ext_themes_autocomplete_popup.js @@ -253,16 +253,19 @@ add_task(async function test_popup_url() { "darktext should not be set!" ); - // Calculate what GrayText should be. May differ between platforms. - let span = document.createXULElement("span"); - span.style.color = "GrayText"; - document.documentElement.appendChild(span); - let GRAY_TEXT = window.getComputedStyle(span).color; - span.remove(); + // Calculate what GrayText should be. Differs between platforms. + // We don't use graytext for urlbar results on Mac as it's too faint. + if (AppConstants.platform != "macosx") { + let span = document.createXULElement("span"); + span.style.color = "GrayText"; + document.documentElement.appendChild(span); + let GRAY_TEXT = window.getComputedStyle(span).color; + span.remove(); - Assert.equal( - window.getComputedStyle(urlResult.element.separator, ":before").color, - GRAY_TEXT, - `Urlbar popup separator color should be set to ${GRAY_TEXT}` - ); + Assert.equal( + window.getComputedStyle(urlResult.element.separator, ":before").color, + GRAY_TEXT, + `Urlbar popup separator color should be set to ${GRAY_TEXT}` + ); + } });