mirror of
https://github.com/zen-browser/desktop.git
synced 2025-09-05 19:08:18 +00:00
Refactor compact mode styles and improve sidebar width handling
This commit is contained in:
@@ -173,7 +173,6 @@
|
||||
width: 100%;
|
||||
opacity: 0;
|
||||
background: var(--zen-dialog-background);
|
||||
padding-left: var(--zen-toolbox-padding) !important;
|
||||
|
||||
max-height: var(--zen-toolbar-height);
|
||||
overflow: hidden;
|
||||
@@ -187,11 +186,6 @@
|
||||
transition: transform 0.1s ease-in-out;
|
||||
}
|
||||
|
||||
:root[zen-window-buttons-reversed='true'] & {
|
||||
padding-left: 0 !important;
|
||||
padding-right: var(--zen-toolbox-padding) !important;
|
||||
}
|
||||
|
||||
@media (-moz-bool-pref: 'zen.view.compact.color-toolbar') {
|
||||
background-attachment: fixed;
|
||||
backdrop-filter: blur(5px);
|
||||
|
@@ -33,8 +33,8 @@ height: var(--zen-toolbar-height);
|
||||
}
|
||||
|
||||
:root[inDOMFullscreen='true'] & {
|
||||
max-height: 0;
|
||||
max-height: 0 !important;
|
||||
min-height: unset !important;
|
||||
opacity: 0;
|
||||
pointer-events: none;
|
||||
opacity: 0 !important;
|
||||
pointer-events: none !important;
|
||||
}
|
||||
|
@@ -306,8 +306,18 @@ button.popup-notification-dropmarker {
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
:root:not([zen-single-toolbar='true']) #nav-bar {
|
||||
margin-bottom: -1px;
|
||||
:root:not([zen-single-toolbar='true']) {
|
||||
& #nav-bar {
|
||||
margin-bottom: -1px;
|
||||
}
|
||||
|
||||
&[zen-right-side='true']:not([zen-window-buttons-reversed='true']) #nav-bar {
|
||||
margin-inline-start: var(--zen-element-separation);
|
||||
}
|
||||
|
||||
&:not([zen-right-side='true'])[zen-window-buttons-reversed='true'] #nav-bar {
|
||||
margin-inline-end: var(--zen-element-separation);
|
||||
}
|
||||
}
|
||||
|
||||
/* Other small tweaks */
|
||||
|
@@ -103,7 +103,9 @@ var gZenCompactModeManager = {
|
||||
|
||||
getAndApplySidebarWidth() {
|
||||
let sidebarWidth = this.sidebar.getBoundingClientRect().width;
|
||||
this.sidebar.style.setProperty("--zen-sidebar-width", `${sidebarWidth}px`);
|
||||
if (sidebarWidth > 1) {
|
||||
this.sidebar.style.setProperty("--zen-sidebar-width", `${sidebarWidth}px`);
|
||||
}
|
||||
return sidebarWidth;
|
||||
},
|
||||
|
||||
|
Reference in New Issue
Block a user