Clean: Remove userChrome.tab.shareProton

This commit is contained in:
alstjr7375 2021-12-28 14:10:56 +09:00
parent 0d05071f64
commit c9ec7bc97b
7 changed files with 49 additions and 31 deletions

View file

@ -21,3 +21,24 @@
}
}
}
@include test-module("If not exist pref [mx]") {
@include test("simple") {
@include assert {
@include output {
@include option.NotOption("userChrome.tab.photon") {
body {
font-size: 16px;
}
}
}
@include expect {
@supports not -moz-bool-pref("userChrome.tab.photon") {
body {
font-size: 16px;
}
}
}
}
}
}

View file

@ -85,7 +85,7 @@
padding-right: var(--newtab-button-width-padding) !important;
}
@include Option("userChrome.tab.shareProton") {
@include NotOption("userChrome.tab.photon") {
#tabbrowser-tabs[haspinnedtabs]:not([positionpinnedtabs])
> #tabbrowser-arrowscrollbox
> .tabbrowser-tab[first-visible-unpinned-tab] {
@ -119,7 +119,7 @@
}
/* Tab - Max Size */
@include Option("userChrome.tab.shareProton") {
@include NotOption("userChrome.tab.photon") {
:root {
--tab-max-width: 240px;
}
@ -134,7 +134,7 @@
}
/* neighbouring tabs should "pinch" together */
@include Option("userChrome.tab.shareProton") {
@include NotOption("userChrome.tab.photon") {
.tabbrowser-tab {
padding-inline: 1px !important;
}
@ -162,7 +162,7 @@
}
/* Toolbar Height */
@include Option("userChrome.tab.shareProton") {
@include NotOption("userChrome.tab.photon") {
:root:not([uidensity="touch"]) #TabsToolbar {
--toolbarbutton-inner-padding: 9px; /* Original: calc((var(--tab-min-height) - 16px) / 2) = 10px */
}

View file

@ -1,4 +1,4 @@
@include Option("userChrome.tab.shareProton") {
@include NotOption("userChrome.tab.photon") {
.tab-context-line {
display: none;
}

View file

@ -1,5 +1,7 @@
/*= Unselected Tab - Dynamic Separator =======================================*/
@import "unselected_tab/dynamic_separator";
@include NotOption("userChrome.tab.photon") {
@import "unselected_tab/dynamic_separator";
}
/*= Unselected Tab - Static Separator ========================================*/
@include Option("userChrome.tab.photon") {

View file

@ -57,10 +57,8 @@
}
}
@include Option("userChrome.tab.shareProton") {
.tabbrowser-tab:not([visuallyselected], [multiselected], :hover, :first-child) .tab-background::before {
.tabbrowser-tab:not([visuallyselected], [multiselected], :hover, :first-child) .tab-background::before {
opacity: var(--tab-separator-opacity);
}
}
@include Option("userChrome.tab.original") {
#tabs-newtab-button:not(:hover, [open])::before {
@ -76,16 +74,14 @@
}
}
@include Option("userChrome.tab.shareProton") {
#navigator-toolbox:not([movingtab])
#navigator-toolbox:not([movingtab])
.tabbrowser-tab[first-visible-unpinned-tab]:is([visuallyselected], [multiselected], :hover)
.tab-background::before,
#navigator-toolbox:not([movingtab])
#navigator-toolbox:not([movingtab])
#tabbrowser-arrowscrollbox[overflowing]
tab.tabbrowser-tab[first-visible-unpinned-tab]
.tab-background::before {
opacity: 0 !important;
}
}
@include Option("userChrome.tab.original") {
#navigator-toolbox:not([movingtab])
@ -112,11 +108,9 @@
/* Animate */
@media (prefers-reduced-motion: no-preference) {
@include Option("userChrome.tab.shareProton") {
.tab-background::before {
transition: opacity 0.2s var(--animation-easing-function); /* cubic-bezier(.07, .95, 0, 1) */
}
}
@include Option("userChrome.tab.original") {
#tabs-newtab-button::before {
transition: opacity 0.2s var(--animation-easing-function); /* cubic-bezier(.07, .95, 0, 1) */
@ -132,8 +126,6 @@
}
/* Latest Tab & New tab margin */
@include Option("userChrome.tab.shareProton") {
#tabbrowser-arrowscrollbox:not([overflowing]) .tabbrowser-tab[last-visible-tab] {
#tabbrowser-arrowscrollbox:not([overflowing]) .tabbrowser-tab[last-visible-tab] {
margin-inline-end: 1px !important;
}
}

View file

@ -5,3 +5,9 @@ $tabProton: "userChrome.tab.proton";
@content;
}
}
@mixin NotOption($optionName) {
@supports not -moz-bool-pref("#{$optionName}") {
@content;
}
}

View file

@ -27,9 +27,6 @@ user_pref("browser.newtabpage.activity-stream.improvesearch.handoffToAwesomebar"
// user_pref("layout.css.prefers-color-scheme.content-override", 3);
// ** Theme Related Options ****************************************************
user_pref("userChrome.tab.sharePhoton", true); // Original, Photon
user_pref("userChrome.tab.shareProton", true); // Original, Proton
user_pref("userChrome.tab.original", true); // Original
// user_pref("userChrome.tab.photon", true); // Photon
// user_pref("userChrome.tab.proton", true); // Proton