Bug 1348574 - Clean up .autocomplete-richlistitem styling. r=mak a=gchang
authorDão Gottwald <dao@mozilla.com>
Sat, 18 Mar 2017 16:42:22 +0100
changeset 379293 1411f6a2c16364b7faa46b13d97abbc86ed30a96
parent 379292 68f40432b9a3a58ae9b369ccac7761e3c0d1041b
child 379294 cedc5c3f53b5409f3059e656baf4e5bfc5fd5ec7
push id1419
push userjlund@mozilla.com
push dateMon, 10 Apr 2017 20:44:07 +0000
treeherdermozilla-release@5e6801b73ef6 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmak, gchang
bugs1348574
milestone53.0
Bug 1348574 - Clean up .autocomplete-richlistitem styling. r=mak a=gchang MozReview-Commit-ID: K1jZgM7iFos
browser/themes/linux/browser.css
browser/themes/osx/browser.css
browser/themes/windows/browser.css
toolkit/themes/linux/global/autocomplete.css
toolkit/themes/windows/global/autocomplete.css
--- a/browser/themes/linux/browser.css
+++ b/browser/themes/linux/browser.css
@@ -945,50 +945,41 @@ notification[value="translation"] menuli
 .autocomplete-richlistitem {
   height: 30px;
   min-height: 30px;
   font: message-box;
   border-radius: 2px;
   border: 1px solid transparent;
 }
 
-.autocomplete-richlistitem[selected=true] {
-  background-color: Highlight;
-}
-
 .ac-title {
   font-size: 1.05em;
 }
 
+.ac-separator,
+.ac-url,
+.ac-action,
 .ac-tags {
   font-size: 0.9em;
 }
 
 html|span.ac-tag {
   background-color: MenuText;
   color: Menu;
   border-radius: 2px;
   border: 1px solid transparent;
   padding: 0 1px;
 }
 
-.ac-separator,
-.ac-url,
-.ac-action {
-  font-size: 0.9em;
+.ac-separator:not([selected=true]),
+.ac-url:not([selected=true]),
+.ac-action:not([selected=true]) {
   color: -moz-nativehyperlinktext;
 }
 
-.ac-title[selected=true],
-.ac-separator[selected],
-.ac-url[selected=true],
-.ac-action[selected=true] {
-  color: inherit !important;
-}
-
 .ac-tags-text[selected] > html|span.ac-tag {
   background-color: HighlightText;
   color: Highlight;
 }
 
 html|span.ac-emphasize-text-title,
 html|span.ac-emphasize-text-tag,
 html|span.ac-emphasize-text-url {
--- a/browser/themes/osx/browser.css
+++ b/browser/themes/osx/browser.css
@@ -1745,60 +1745,50 @@ toolbar .toolbarbutton-1 > .toolbarbutto
   min-height: 30px;
   font: message-box;
   border-radius: 2px;
   border: 1px solid transparent;
 }
 
 .autocomplete-richlistitem[selected] {
   background-color: hsl(210, 80%, 52%);
+  color: hsl(0, 0%, 100%);
 }
 
 .ac-title {
   font-size: 14px;
-  color: hsl(0, 0%, 0%);
-}
-
+}
+
+.ac-separator,
+.ac-url,
+.ac-action,
 .ac-tags {
   font-size: 12px;
 }
 
 html|span.ac-tag {
   background-color: hsl(216, 0%, 88%);
   color: hsl(0, 0%, 0%);
   border-radius: 2px;
   border: 1px solid transparent;
   padding: 0 1px;
 }
 
-.ac-separator,
-.ac-url,
-.ac-action {
-  font-size: 12px;
-}
-
-.ac-separator {
+.ac-separator:not([selected=true]) {
   color: hsl(0, 0%, 50%);
 }
 
-.ac-url {
+.ac-url:not([selected=true]) {
   color: hsl(210, 77%, 47%);
 }
 
-.ac-action {
+.ac-action:not([selected=true]) {
   color: hsl(178, 100%, 28%);
 }
 
-.ac-title[selected],
-.ac-separator[selected],
-.ac-url[selected],
-.ac-action[selected] {
-  color: hsl(0, 0%, 100%);
-}
-
 .ac-tags-text[selected] > html|span.ac-tag {
   background-color: hsl(0, 0%, 100%);
   color: hsl(210, 80%, 40%);
 }
 
 html|span.ac-emphasize-text-title,
 html|span.ac-emphasize-text-tag,
 html|span.ac-emphasize-text-url {
--- a/browser/themes/windows/browser.css
+++ b/browser/themes/windows/browser.css
@@ -1462,93 +1462,87 @@ html|*.urlbar-input:-moz-lwtheme::placeh
 .autocomplete-richlistitem {
   height: 30px;
   min-height: 30px;
   font: message-box;
   border-radius: 2px;
   border: 1px solid transparent;
 }
 
-.autocomplete-richlistitem[selected=true] {
-  background-color: hsl(210, 80%, 52%);
-}
-
 .ac-title {
   font-size: 14px;
-  color: hsl(0, 0%, 0%);
 }
 
 .ac-tags {
   font-size: 12px;
 }
 
 html|span.ac-tag {
-  background-color: hsl(216, 0%, 88%);
-  color: hsl(0, 0%, 0%);
   border-radius: 2px;
   border: 1px solid transparent;
   padding: 0 1px;
 }
 
 .ac-separator,
 .ac-url,
 .ac-action {
   font-size: 12px;
 }
 
-.ac-separator {
-  color: hsl(0, 0%, 50%);
-}
-
-.ac-url {
-  color: hsl(210, 77%, 47%);
-}
-
-.ac-action {
-  color: hsl(178, 100%, 28%);
-}
-
-.ac-title[selected=true],
-.ac-separator[selected],
-.ac-url[selected=true],
-.ac-action[selected=true] {
-  color: hsl(0, 0%, 100%);
-}
-
-.ac-tags-text[selected] > html|span.ac-tag {
-  background-color: hsl(0, 0%, 100%);
-  color: hsl(210, 80%, 40%);
-}
-
 html|span.ac-emphasize-text-title,
 html|span.ac-emphasize-text-tag,
 html|span.ac-emphasize-text-url {
   font-weight: 600;
 }
 
-@media (-moz-windows-default-theme: 0) {
+@media (-moz-windows-default-theme) {
   .autocomplete-richlistitem[selected=true] {
-    background-color: Highlight;
+    background-color: hsl(210, 80%, 52%);
+    color: hsl(0, 0%, 100%);
+  }
+
+  .ac-title:not([selected=true]) {
+    color: hsl(0, 0%, 0%);
+  }
+
+  .ac-separator:not([selected=true]) {
+    color: hsl(0, 0%, 50%);
+  }
+
+  .ac-url:not([selected=true]) {
+    color: hsl(210, 77%, 47%);
   }
 
-  .ac-title {
-    color: inherit;
+  .ac-action:not([selected=true]) {
+    color: hsl(178, 100%, 28%);
+  }
+
+  html|span.ac-tag {
+    background-color: hsl(216, 0%, 88%);
+    color: hsl(0, 0%, 0%);
+  }
+
+  .ac-tags-text[selected] > html|span.ac-tag {
+    background-color: hsl(0, 0%, 100%);
+    color: hsl(210, 80%, 40%);
+  }
+}
+
+@media (-moz-windows-default-theme: 0) {
+  .ac-separator:not([selected=true]),
+  .ac-url:not([selected=true]),
+  .ac-action:not([selected=true]) {
+    color: -moz-nativehyperlinktext;
   }
 
   html|span.ac-tag {
     background-color: -moz-FieldText;
     color: -moz-Field;
   }
 
-  .ac-separator,
-  .ac-url,
-  .ac-action {
-    color: -moz-nativehyperlinktext;
-  }
-
   .ac-tags-text[selected] > html|span.ac-tag {
     background-color: HighlightText;
     color: Highlight;
   }
 }
 
 .ac-type-icon[type=bookmark] {
   list-style-image: url("chrome://browser/skin/urlbar-star.svg#star");
--- a/toolkit/themes/linux/global/autocomplete.css
+++ b/toolkit/themes/linux/global/autocomplete.css
@@ -100,16 +100,17 @@ treechildren.autocomplete-treebody::-moz
 
 .autocomplete-richlistbox {
   -moz-appearance: none;
   margin: 1px;
   background-color: transparent;
 }
 
 .autocomplete-richlistitem[selected] {
+  background-color: Highlight;
   color: HighlightText;
 }
 
 .ac-type-icon {
   width: 16px;
   height: 16px;
   max-width: 16px;
   max-height: 16px;
--- a/toolkit/themes/windows/global/autocomplete.css
+++ b/toolkit/themes/windows/global/autocomplete.css
@@ -92,16 +92,21 @@ treechildren.autocomplete-treebody::-moz
 
 /* ::::: richlistbox autocomplete ::::: */
 
 .autocomplete-richlistbox {
   -moz-appearance: none;
   margin: 0;
 }
 
+.autocomplete-richlistitem[selected] {
+  background-color: Highlight;
+  color: HighlightText;
+}
+
 .ac-type-icon {
   width: 16px;
   height: 16px;
   max-width: 16px;
   max-height: 16px;
   margin-inline-start: 14px;
   margin-inline-end: 6px;
 }