Skip to content

Commit

Permalink
update for new private browsing indicator.
Browse files Browse the repository at this point in the history
  • Loading branch information
aminomancer committed Aug 27, 2022
1 parent f7d7a15 commit 83d6b83
Show file tree
Hide file tree
Showing 4 changed files with 48 additions and 32 deletions.
32 changes: 1 addition & 31 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -895,36 +895,6 @@ It's not like there aren't other ways to see where the panel is anchored, but wh

</details>

#### Restore pre-Proton Downloads Button:

⚠️ _This script has been made obsolete by new animations I made for v3.1.1 (13 Jan 2022). If you had `restorePreProtonDownloadsButton.uc.js` or `restorePreProtonDownloadsButton-standalone.uc.js` installed, delete it._ Restores the pre-Proton downloads button icon and animations. <details><summary>💬 <i><b>If you don't use duskFox...</b></i></summary>

You're going to need the [resources/downloads](/resources/downloads) folder, so download that. Then, (with fx-autoconfig installed) add these three lines to utils/chrome.manifest:

```
override chrome://browser/skin/downloads/downloads.svg ../resources/downloads/downloads.svg
override chrome://browser/skin/downloads/notification-start-animation.svg ../resources/downloads/notification-start-animation.svg
override chrome://browser/skin/downloads/notification-finish-animation.svg ../resources/downloads/notification-finish-animation.svg
```

With the resources out of the way, add this to userChrome.css:

```css
#downloads-button > .toolbarbutton-badge-stack > #downloads-indicator-progress-outer {
top: calc(50% - 10px) !important;
left: calc(50% - 10px) !important;
width: 20px !important;
height: 20px !important;
border-radius: 0 !important;
border: none !important;
background-image: url(chrome://userchrome/content/downloads/progress-circle.svg) !important;
background-position: center !important;
background-size: 20px !important;
}
```

</details>

#### [Restore pre-Proton Library Button](/JS/restorePreProtonLibraryButton.uc.js):

✨ The library toolbar button used to have an animation that played when a bookmark was added. It's another casualty of the Proton updates. This script restores the library button animation in its entirety, with one minor improvement.<details><summary>💬 <i><b>More details...</b></i></summary>
Expand Down Expand Up @@ -1084,7 +1054,7 @@ When opening a new tab without selecting it, the tab will gain an attribute `not
```css
.tabbrowser-tab[notselectedsinceload]:not([pending]),
.tabbrowser-tab[notselectedsinceload][pending][busy] {
font-style:italic!important;
font-style: italic !important;
}
```

Expand Down
12 changes: 12 additions & 0 deletions uc-navbar.css
Original file line number Diff line number Diff line change
Expand Up @@ -328,6 +328,18 @@ toolbar
background-color: var(--toolbarbutton-checked-background) !important;
}

#firefox-view-button:is(:focus-visible, [checked="true"]):not([open], :hover, :active) > .toolbarbutton-icon {
background: var(--toolbarbutton-checked-background) !important;
}

#firefox-view-button:hover > .toolbarbutton-icon {
background: var(--toolbarbutton-hover-background) !important;
}

#firefox-view-button:is(:hover:active, [open]) > .toolbarbutton-icon {
background: var(--toolbarbutton-active-background) !important;
}

toolbar .toolbarbutton-1:not([disabled], [open])[checked]:hover > .toolbarbutton-icon {
background-color: var(--toolbarbutton-hover-background) !important;
}
Expand Down
24 changes: 23 additions & 1 deletion uc-tabs-bar.css
Original file line number Diff line number Diff line change
Expand Up @@ -197,7 +197,7 @@ titlebar, this sheet controls their appearance as well. */
margin-inline-end: 2px !important;
}

:is(toolbarbutton, toolbaritem) + #tabbrowser-tabs {
:is(toolbarbutton, toolbaritem, toolbarpaletteitem) + #tabbrowser-tabs {
margin-inline-start: 2px !important;
}

Expand Down Expand Up @@ -363,6 +363,19 @@ overflowing tabs don't draw shadows on the special new tab button */
background: none !important;
}

:root[privatebrowsingmode="temporary"] .private-browsing-indicator {
display: revert !important;
}

#private-browsing-indicator-with-label {
-moz-context-properties: fill, fill-opacity !important;
fill: currentColor !important;
}

.private-browsing-indicator + #private-browsing-indicator-with-label {
display: none !important;
}

.private-browsing-indicator::before {
content: "";
display: -moz-box;
Expand Down Expand Up @@ -399,6 +412,15 @@ button.private-browsing-indicator:is(:hover:active, [open])::before {
background-color: var(--arrowpanel-dimmed-further) !important;
}

:root:not([privatebrowsingmode="temporary"]) :is(#firefox-view-button, #wrapper-firefox-view-button) + #tabbrowser-tabs {
border-inline-start: revert !important;
padding-inline-start: revert !important;
}

#TabsToolbar-customization-target > :is(toolbarbutton, toolbaritem, toolbarpaletteitem):first-child {
margin-inline-start: 2px !important;
}

/* all tabs button popup */
.panel-subview-body > .all-tabs-item {
border-radius: var(--arrowpanel-menuitem-border-radius) !important;
Expand Down
12 changes: 12 additions & 0 deletions uc-tabs.css
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,18 @@ not expand until you move your mouse out of the tab strip. */
border-top-right-radius: 5px !important;
}

#TabsToolbar
:is(toolbarbutton, toolbaritem, toolbarpaletteitem):not([hidden])
+ #tabbrowser-tabs:not([using-closing-tabs-spacer])
.tabbrowser-tab[first-visible-tab]:not([justmoved], [style*="transform"]),
#TabsToolbar
:is(toolbarbutton, toolbaritem, toolbarpaletteitem):not([hidden])
+ #tabbrowser-tabs:not([using-closing-tabs-spacer])
.tabbrowser-tab[first-visible-tab]:not([justmoved], [style*="transform"])
:is(.tab-stack, .tab-background, .tab-content, .tab-loading-burst) {
border-top-left-radius: 5px !important;
}

/* set rounded outside corners on tabs so they look like folder labels.
you can disable this by making a new pref in about:config
and setting it to true: "userChrome.tabs.rounded-outer-corners.disabled"
Expand Down

0 comments on commit 83d6b83

Please sign in to comment.