Bug 1374812 - Update sidebar header button hover states. r=dao draft
authorDale Harvey <dale@arandomurl.com>
Wed, 11 Oct 2017 11:30:05 +0100
changeset 685468 39273731e87b7eb0f995c6c2cf179c34db14b86b
parent 685439 3792e9864edade3efd257a061a015a22a93dd8f4
child 737146 e35713422e104ba535f82f82b2750e08a351fdc4
push id85927
push userbmo:dharvey@mozilla.com
push dateTue, 24 Oct 2017 15:44:47 +0000
reviewersdao
bugs1374812
milestone58.0a1
Bug 1374812 - Update sidebar header button hover states. r=dao MozReview-Commit-ID: HDg3gwI5Pfa
browser/themes/shared/sidebar.inc.css
--- a/browser/themes/shared/sidebar.inc.css
+++ b/browser/themes/shared/sidebar.inc.css
@@ -64,37 +64,37 @@
   width: 12px;
   height: 12px;
 }
 
 #sidebar-switcher-target {
   -moz-appearance: none;
   color: inherit;
   margin-inline-end: 4px;
-  border-radius: 4px;
+  border-radius: var(--toolbarbutton-border-radius);
   border: 1px solid transparent;
   padding: 2px 4px;
 }
 
 #sidebar-switcher-target:hover {
-  background: hsla(240, 5%, 5%, 0.05);
-}
-
-#sidebar-switcher-target:hover {
-  border-color: rgba(0, 0, 0, 0.2);
+  background: var(--toolbarbutton-hover-background);
 }
 
 #sidebar-switcher-target:hover:active,
 #sidebar-switcher-target.active {
-  background: hsla(240, 5%, 5%, 0.1);
+  background: var(--toolbarbutton-active-background);
 }
 
-#sidebar-switcher-target:hover:active,
-#sidebar-switcher-target.active {
-  border-color: rgba(0, 0, 0, 0.25);
+/* Ensure we do not lose contrast between lightweight and OS theme colours */
+#sidebar-switcher-target:hover:-moz-lwtheme {
+  background: hsla(240, 5%, 5%, 0.1);
+}
+#sidebar-switcher-target:hover:active:-moz-lwtheme,
+#sidebar-switcher-target.active:-moz-lwtheme {
+  background: hsla(240, 5%, 5%, 0.15);
 }
 
 #sidebarMenu-popup .subviewbutton {
   min-width: 190px;
 }
 
 #sidebar-extensions:empty + toolbarseparator {
   display: none;