|
4 | 4 | * Show things only when you need it: Top & bottom buttons, workspace indicator, bookmarks bar and more |
5 | 5 | */ |
6 | 6 |
|
7 | | -/* 0 - Tidy up extension menu by default */ |
8 | | -/* Reduce icon size in extension menu */ |
9 | | -:root { |
10 | | - --uei-icon-size: 20px !important; |
11 | | -} |
12 | | - |
13 | | -@media not (-moz-bool-pref: "mod.extension.viewgrid") { |
14 | | - /* Hide header, description, extension captions */ |
15 | | - #unified-extensions-view box.panel-header, |
16 | | - #unified-extensions-view > :nth-child(2), |
17 | | - #unified-extensions-description, |
18 | | - #unified-extensions-messages-container, |
19 | | - .unified-extensions-item-message-deck { |
20 | | - display: none !important; |
21 | | - } |
22 | | - /* Reduce the panel size and padding */ |
23 | | - #unified-extensions-view { |
24 | | - width: var(--menu-panel-width) !important; |
25 | | - } |
26 | | - #overflowed-extensions-list { |
27 | | - padding-block-start: 2px !important; |
28 | | - } |
29 | | - #unified-extensions-area { |
30 | | - padding-block-end: 1px !important; |
31 | | - } |
32 | | - panelview .unified-extensions-item-action-button { |
33 | | - padding-inline: 8px !important; |
34 | | - padding-block: 4px !important; |
35 | | - } |
36 | | - #unified-extensions-manage-extensions { |
37 | | - margin-inline: 3px !important; |
38 | | - padding: 8px 10px !important; |
39 | | - margin-block-end: 4px !important; |
40 | | - } |
41 | | - #unified-extensions-panel .unified-extensions-item { |
42 | | - margin-block: 2px !important; |
43 | | - } |
44 | | - #unified-extensions-view .unified-extensions-item-action-button:hover { |
45 | | - background-color: color-mix(in srgb, currentColor 3%, transparent) !important; |
46 | | - } |
47 | | - #unified-extensions-view .unified-extensions-item-menu-button.subviewbutton, |
48 | | - .unified-extensions-item-row-wrapper { |
49 | | - padding: 0 !important; |
50 | | - } |
51 | | - #unified-extensions-view .unified-extensions-item-menu-button.subviewbutton > .toolbarbutton-icon { |
52 | | - opacity: 0 !important; |
53 | | - transition: 0.2s ease !important; |
54 | | - } |
55 | | - #unified-extensions-panel .unified-extensions-item:hover { |
56 | | - .unified-extensions-item-menu-button.subviewbutton > .toolbarbutton-icon { |
57 | | - opacity: 0.85 !important; |
58 | | - } |
59 | | - background-color: transparent !important; |
60 | | - } |
61 | | - #unified-extensions-view .unified-extensions-item-action-button .panel-no-padding .webextension-browser-action { |
62 | | - padding: 0 !important; |
63 | | - } |
64 | | - #unified-extensions-view .toolbar-menupopup :is(menu, menuitem), .subview-subheader, panelview .toolbarbutton-1, .subviewbutton, .widget-overflow-list .toolbarbutton-1 { |
65 | | - max-height: 3em !important; |
66 | | - } |
67 | | - #unified-extensions-view .subviewbutton-iconic { |
68 | | - & > .toolbarbutton-icon { |
69 | | - width: 1em !important; |
70 | | - height: 1em !important; |
71 | | - padding: 0.6em !important; |
72 | | - } |
73 | | - } |
74 | | -} |
75 | | - |
76 | | -/* 1 - Apply grid view in extension menu */ |
77 | | -@media (-moz-bool-pref: "mod.extension.viewgrid") { |
78 | | - /* Set width of Unified Extension View */ |
79 | | - #unified-extensions-view { |
80 | | - width: calc(var(--menu-panel-width) - 118px) !important; |
81 | | - } |
82 | | - |
83 | | - /* Hide the header as well as texts and settings icon for each extension, so only icons are visible */ |
84 | | - #unified-extensions-description, |
85 | | - #unified-extensions-view .panel-header, |
86 | | - #unified-extensions-view > :nth-child(2), |
87 | | - .unified-extensions-item-name, |
88 | | - .unified-extensions-item-message, |
89 | | - .unified-extensions-item-message-hover, |
90 | | - .unified-extensions-item-message-hover-menu-button, |
91 | | - .unified-extensions-item-menu-button { |
92 | | - display: none !important; |
93 | | - } |
94 | | - |
95 | | - /* Arrange extensions in a properly centered 4-column grid */ |
96 | | - #overflowed-extensions-list, #unified-extensions-area, .unified-extensions-list { |
97 | | - display: grid !important; |
98 | | - grid-template-columns: repeat(4, 1fr) !important; /* 4 columns */ |
99 | | - justify-content: left !important; |
100 | | - align-items: center !important; |
101 | | - margin-inline: 7px !important; |
102 | | - width: 0px !important; |
103 | | - } |
104 | | - |
105 | | - #overflowed-extensions-list { |
106 | | - padding-block-start: 5px !important; |
107 | | - } |
108 | | - #unified-extensions-area { |
109 | | - padding-block-end: 10px !important; |
110 | | - } |
111 | | - |
112 | | - /* Ensure the extensions are fully centered with squircle hover shape, and reduce unneeded margins/paddings */ |
113 | | - .unified-extensions-item { |
114 | | - display: flex !important; |
115 | | - align-items: center !important; |
116 | | - justify-content: center !important; |
117 | | - border-radius: 12px !important; |
118 | | - } |
119 | | - .unified-extensions-item-icon, .unified-extensions-item .webextension-browser-action.subviewbutton > .toolbarbutton-badge-stack { |
120 | | - margin: 0px !important; |
121 | | - } |
122 | | - panelview .unified-extensions-item-action-button { |
123 | | - padding: 10px 10px !important; |
124 | | - } |
125 | | - |
126 | | - /* Set proper padding for the Manage Extensions button */ |
127 | | - #unified-extensions-manage-extensions { |
128 | | - padding: 8px 16px !important; |
129 | | - margin-block-end: 4px !important; |
130 | | - } |
131 | | - |
132 | | - /* Set lighter opacity for passive extension buttons */ |
133 | | - .unified-extensions-item-icon { |
134 | | - opacity: 0.6; |
135 | | - } |
136 | | - .unified-extensions-item-action-button:hover { |
137 | | - background-color: color-mix(in srgb, currentColor 20%, transparent) !important; |
138 | | - } |
139 | | - |
140 | | - #unified-extensions-view toolbarseparator { |
141 | | - margin-top: 0px !important; |
142 | | - } |
143 | | -} |
144 | | -/* Invert the passive extension icons in dark mode */ |
145 | | -@media (prefers-color-scheme: dark) { |
146 | | - @media (-moz-bool-pref: "mod.extension.viewgrid") { |
147 | | - .unified-extensions-item-icon { |
148 | | - filter: invert(1) !important; |
149 | | - } |
150 | | - } |
151 | | -} |
152 | | - |
153 | | -/* 2 - Hide Zoom button in URL bar */ |
| 7 | +/* 1 - Hide Zoom button in URL bar */ |
154 | 8 | @media (-moz-bool-pref: "mod.lean.hide-zoom") { |
155 | 9 | #urlbar-zoom-button { |
156 | 10 | display: none !important; |
157 | 11 | } |
158 | 12 | } |
159 | 13 |
|
160 | | -/* 3 - Show translation button when hovering URL bar in Single Toolbar mode */ |
| 14 | +/* 2 - Show translation button when hovering URL bar in Single Toolbar mode */ |
161 | 15 | :root[zen-single-toolbar='true'] { |
162 | 16 | @media (-moz-bool-pref: "mod.lean.show-translation") { |
163 | 17 | #urlbar:hover { |
|
192 | 46 | } |
193 | 47 | } |
194 | 48 |
|
195 | | -/* 4 - Show page action button for extensions when hovering URL bar in Single Toolbar mode */ |
| 49 | +/* 3 - Show page action button for extensions when hovering URL bar in Single Toolbar mode */ |
196 | 50 | :root[zen-single-toolbar='true'] { |
197 | 51 | @media (-moz-bool-pref: "mod.lean.show-pageactions") { |
198 | 52 | #urlbar:hover { |
|
206 | 60 | } |
207 | 61 | } |
208 | 62 |
|
209 | | -/* 5 - Hide top workspace indicator unless when editing space name |
| 63 | +/* 4 - Hide top workspace indicator unless when editing space name |
210 | 64 | * + adjust Essentials area bottom padding */ |
211 | 65 | @media -moz-pref("mod.lean.top-workspace") { |
212 | 66 | .zen-current-workspace-indicator:not(:has(.tab-label-container-editing)) { |
|
237 | 91 | } |
238 | 92 | } |
239 | 93 |
|
240 | | -/* 6 - Hide bottom buttons area unless tab sidebar is hovered */ |
| 94 | +/* 5 - Hide bottom buttons area unless tab sidebar is hovered */ |
241 | 95 | :root:not([customizing]) { |
242 | 96 | @media -moz-pref("mod.lean.bottom-buttons") { |
243 | 97 | #zen-sidebar-foot-buttons, #zen-workspaces-button, #zen-sidebar-foot-buttons toolbarbutton { |
|
266 | 120 | } |
267 | 121 | } |
268 | 122 |
|
269 | | -/* 7 - Ninja top buttons on Single Toolbar mode |
| 123 | +/* 6 - Ninja top buttons on Single Toolbar mode |
270 | 124 | * You can hover slightly above URL bar to access the top buttons, but you can't see it */ |
271 | 125 | :root[zen-single-toolbar="true"] { |
272 | 126 | --top-toolbar-hover-opacity: 0; |
|
290 | 144 | } |
291 | 145 |
|
292 | 146 |
|
293 | | -/* 8 - Only show bookmarks when hovering top navigation bar on Multiple & Collapsed Toolbar mode |
| 147 | +/* 7 - Only show bookmarks when hovering top navigation bar on Multiple & Collapsed Toolbar mode |
294 | 148 | * Mimicking how it works on Single Toolbar */ |
295 | 149 | :root:not([zen-single-toolbar="true"]) { |
296 | 150 | @media -moz-pref("mod.lean.bookmarks") { |
|
318 | 172 | } |
319 | 173 | } |
320 | 174 |
|
321 | | -/* 9 - WIP: Bottom buttons as "pinned extensions" on Single Toolbar mode |
| 175 | +/* 8 - WIP: Bottom buttons as "pinned extensions" on Single Toolbar mode |
322 | 176 | * Also hide the workspace buttons, and the separator below tabs area */ |
323 | 177 |
|
324 | 178 | /* Part A: When bottom buttons is always shown */ |
|
0 commit comments