Bug 1673321 - Remove theme CSS for macOS 10.11 and below. r=dao
authorTim Nguyen <ntim.bugs@gmail.com>
Tue, 27 Oct 2020 15:42:31 +0000
changeset 554713 29b5f82540f0eff1203e41bab6582f599cea233f
parent 554712 382e2efbd132a95e498f5e77a76e4c3719363498
child 554714 c86e703df3e773e8712fda0bcf864d9de3e0fd94
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)
reviewersdao
bugs1673321
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 1673321 - Remove theme CSS for macOS 10.11 and below. r=dao Differential Revision: https://phabricator.services.mozilla.com/D94719
browser/themes/osx/browser.css
browser/themes/osx/places/organizer.css
browser/themes/osx/places/sidebar.css
browser/themes/osx/syncedtabs/sidebar.css
toolkit/themes/osx/global/findBar.css
toolkit/themes/osx/global/tabbox.css
--- a/browser/themes/osx/browser.css
+++ b/browser/themes/osx/browser.css
@@ -38,16 +38,24 @@
   --arrowpanel-dimmed-further: rgba(249,249,250,.15);
   --arrowpanel-dimmed-even-further: rgba(249,249,250,.2);
 
   --arrowpanel-field-background: rgba(12,12,13,.3);
 }
 
 #navigator-toolbox {
   appearance: none;
+  --tabs-border-color: rgba(0,0,0,.2);
+}
+
+#navigator-toolbox:not(:-moz-lwtheme):-moz-window-inactive {
+  --tabs-border-color: rgba(0,0,0,.05);
+}
+
+#navigator-toolbox:-moz-lwtheme {
   --tabs-border-color: rgba(0,0,0,.3);
 }
 
 /*
   This is a workaround for Bug 1482157
   -moz-default-appearance: toolbox; makes the macOS sheets attached to the
   element's bottom border. We cannot put this property on the toolbox itself as
   it cancels all backgrounds that are there, so we set it on the toolbox bottom
@@ -97,59 +105,34 @@
 }
 
 /* These would be margin-inline-start/end if it wasn't for the fact that OS X
  * doesn't reverse the order of the items in the titlebar in RTL mode. */
 .titlebar-buttonbox {
   margin-left: 12px;
 }
 
-/* The fullscreen button doesnt show on Yosemite(10.10) or above so dont give it a
-   border there */
-@media (-moz-mac-yosemite-theme: 0) {
-  .titlebar-spacer[type="fullscreen-button"] {
-    margin-right: 4px;
-  }
-}
-
 /** End titlebar **/
 
 :root[chromehidden~="toolbar"][chromehidden~="location"][chromehidden~="directories"] {
   border-top: 1px solid rgba(0,0,0,0.65);
 }
 
 .browser-toolbar:not(.titlebar-color) {
   appearance: none;
   background: var(--toolbar-bgcolor);
   color: var(--toolbar-color);
 }
 
-/* Draw the bottom border of the tabs toolbar when it's not using
-   -moz-default-appearance: toolbar. */
-:root:is([sizemode="fullscreen"],[customizing]) #nav-bar:not([tabs-hidden="true"]),
-:root:not([tabsintitlebar]) #nav-bar:not([tabs-hidden="true"]),
+/* Draw the bottom border of the tabs toolbar when titlebar isn't using vibrancy */
+:root:not(:is([inFullscreen], [tabsintitlebar])) #nav-bar:not([tabs-hidden="true"]),
 #nav-bar:not([tabs-hidden="true"]):-moz-lwtheme {
   box-shadow: 0 calc(-1 * var(--tabs-navbar-shadow-size)) 0 var(--tabs-border-color);
 }
 
-/* Always draw a border on Yosemite to ensure the border is well-defined there
- * (the default border is too light). */
-@media (-moz-mac-yosemite-theme) {
-  #navigator-toolbox:not(:-moz-lwtheme) {
-    --tabs-border-color: rgba(0,0,0,.2);
-  }
-  #navigator-toolbox:not(:-moz-lwtheme):-moz-window-inactive {
-    --tabs-border-color: rgba(0,0,0,.05);
-  }
-
-  :root[tabsintitlebar] #nav-bar:not([tabs-hidden="true"]):not(:-moz-lwtheme) {
-    box-shadow: 0 calc(-1 * var(--tabs-navbar-shadow-size)) 0 var(--tabs-border-color);
-  }
-}
-
 #nav-bar:not([tabs-hidden="true"]) {
   /* The toolbar buttons that animate are only visible when the #TabsToolbar is not collapsed.
      The animations use position:absolute and require a positioned #nav-bar. */
   position: relative;
 }
 
 #PersonalToolbar:not(:-moz-lwtheme):-moz-window-inactive,
 #nav-bar:not(:-moz-lwtheme):-moz-window-inactive {
--- a/browser/themes/osx/places/organizer.css
+++ b/browser/themes/osx/places/organizer.css
@@ -5,22 +5,16 @@
 /* Places Organizer Sidebars */
 
 #placesList {
   appearance: auto;
   -moz-default-appearance: -moz-mac-source-list;
   width: 160px;
 }
 
-@media (-moz-mac-yosemite-theme: 0) {
-  #placesList {
-    box-shadow: inset -2px 0 0 hsla(0,0%,100%,.2);
-  }
-}
-
 #placesList > treechildren::-moz-tree-cell-text {
   margin-inline-end: 6px;
 }
 
 #placesList > treechildren::-moz-tree-row(selected) {
   appearance: auto;
   -moz-default-appearance: -moz-mac-source-list-selection;
   -moz-font-smoothing-background-color: -moz-mac-source-list-selection;
@@ -36,29 +30,16 @@
   cursor: default;
 }
 
 #placesList > treechildren::-moz-tree-separator {
   border-top: 1px solid #505d6d;
   margin: 0 10px;
 }
 
-/* Match selected item styling for -moz-appearance values on OSX 10.9 */
-@media (-moz-mac-yosemite-theme: 0) {
-  #placesList > treechildren::-moz-tree-image(selected),
-  #placesList > treechildren::-moz-tree-twisty(selected),
-  #placesList > treechildren::-moz-tree-cell-text(selected) {
-    color: #fff;
-  }
-
-  #placesList > treechildren::-moz-tree-cell-text(selected) {
-    font-weight: bold;
-  }
-}
-
 #placesToolbar {
   padding: 0 4px 3px;
 }
 
 #placesView {
   border-top: none !important;
 }
 
--- a/browser/themes/osx/places/sidebar.css
+++ b/browser/themes/osx/places/sidebar.css
@@ -32,29 +32,16 @@
   -moz-default-appearance: -moz-mac-active-source-list-selection;
   -moz-font-smoothing-background-color: -moz-mac-active-source-list-selection;
 }
 
 .sidebar-placesTreechildren::-moz-tree-cell-text {
   margin-inline-end: 6px;
 }
 
-/* Match selected item styling for -moz-appearance values on OSX 10.9 */
-@media (-moz-mac-yosemite-theme: 0) {
-  .sidebar-placesTreechildren::-moz-tree-image(selected),
-  .sidebar-placesTreechildren::-moz-tree-twisty(selected),
-  .sidebar-placesTreechildren::-moz-tree-cell-text(selected) {
-    color: #fff;
-  }
-
-  .sidebar-placesTreechildren::-moz-tree-cell-text(selected) {
-    font-weight: bold;
-  }
-}
-
 #sidebar-search-container {
   /* Native searchbar styling already adds 4px margin on Mac, so
    * adding 4px padding results in 8px of total whitespace. */
   padding: 4px;
 }
 
 #viewButton {
   margin: 4px 0;
--- a/browser/themes/osx/syncedtabs/sidebar.css
+++ b/browser/themes/osx/syncedtabs/sidebar.css
@@ -24,15 +24,8 @@ body:not([lwt-sidebar]) .item.selected:n
   -moz-font-smoothing-background-color: -moz-mac-source-list-selection;
 }
 
 body:not([lwt-sidebar-highlight]) .item.selected:focus > .item-title-container {
   appearance: auto;
   -moz-default-appearance: -moz-mac-active-source-list-selection;
   -moz-font-smoothing-background-color: -moz-mac-active-source-list-selection;
 }
-
-@media (-moz-mac-yosemite-theme: 0) {
-  .item.selected > .item-title-container {
-    color: #fff;
-    font-weight: bold;
-  }
-}
--- a/toolkit/themes/osx/global/findBar.css
+++ b/toolkit/themes/osx/global/findBar.css
@@ -57,23 +57,16 @@ label.findbar-find-fast:-moz-lwtheme {
 .findbar-find-next:not(:-moz-lwtheme):not([disabled]):hover:active,
 .findbar-find-previous:not(:-moz-lwtheme):not([disabled]):hover:active,
 .findbar-button:not([disabled]):hover:active,
 .findbar-button:not([disabled])[checked="true"] {
   background-image: @roundButtonPressedBackgroundImage@;
   box-shadow: @roundButtonPressedShadow@;
 }
 
-@media (-moz-mac-yosemite-theme: 0) {
-  html|input.findbar-textbox,
-  .findbar-find-next {
-    border-radius: 10000px;
-  }
-}
-
 html|input.findbar-textbox {
   border: @roundButtonBorderWidth@ @roundButtonBorderStyle@ var(--lwt-toolbar-field-border-color, @roundButtonBorderColor@);
   -moz-context-properties: fill, fill-opacity;
   fill: currentColor;
   fill-opacity: 0.8;
   background-image: url("chrome://global/skin/icons/search-textbox.svg");
   background-repeat: no-repeat;
   background-position: 5px center;
--- a/toolkit/themes/osx/global/tabbox.css
+++ b/toolkit/themes/osx/global/tabbox.css
@@ -46,23 +46,16 @@ tab:first-of-type {
 tab:last-of-type {
   padding-inline-end: 2px;
 }
 
 tab[visuallyselected="true"]:not(:-moz-window-inactive) {
   color: #FFF;
 }
 
-@media (-moz-mac-yosemite-theme: 0) {
-  tab[visuallyselected="true"] {
-    color: #FFF;
-    text-shadow: rgba(0, 0, 0, 0.4) 0 1px;
-  }
-}
-
 .tab-middle {
   padding: 1px 6px 2px;
 }
 
 .tabs-left,
 .tabs-right  {
   -moz-box-flex: 1;
 }