mirror of
https://github.com/zen-browser/desktop.git
synced 2026-05-03 04:25:12 +00:00
Update subproject commit references
This commit is contained in:
@@ -76,14 +76,6 @@
|
||||
}
|
||||
tabs.style.maxHeight = totalHeight + 'px';
|
||||
//console.info('ZenThemeModifier: set tabs max-height to', totalHeight + 'px');
|
||||
|
||||
const allTabs = document.getElementById('alltabs-button');
|
||||
allTabs.removeAttribute('hidden');
|
||||
allTabs.removeAttribute('badged');
|
||||
allTabs.setAttribute('class', 'toolbarbutton-1 zen-sidebar-action-button');
|
||||
document.getElementById('zen-sidebar-icons-wrapper').prepend(
|
||||
allTabs
|
||||
);
|
||||
},
|
||||
|
||||
openWatermark() {
|
||||
@@ -108,10 +100,6 @@
|
||||
_changeSidebarLocation() {
|
||||
const legacyLocation = Services.prefs.getBoolPref('zen.themes.tabs.legacy-location', false);
|
||||
const kElementsToAppend = ['sidebar-splitter', 'sidebar-box'];
|
||||
if (legacyLocation) {
|
||||
kElementsToAppend.push('navigator-toolbox');
|
||||
window.document.documentElement.setAttribute('zen-sidebar-legacy', 'true');
|
||||
}
|
||||
const wrapper = document.getElementById('zen-tabbox-wrapper');
|
||||
const appWrapepr = document.getElementById('zen-sidebar-box-container');
|
||||
for (let id of kElementsToAppend) {
|
||||
@@ -124,9 +112,7 @@
|
||||
|
||||
const browser = document.getElementById('browser');
|
||||
const toolbox = document.getElementById('navigator-toolbox');
|
||||
if (!legacyLocation) {
|
||||
browser.prepend(toolbox);
|
||||
}
|
||||
browser.prepend(toolbox);
|
||||
|
||||
// remove all styles except for the width, since we are xulstoring the complet style list
|
||||
const width = toolbox.style.width;
|
||||
@@ -140,6 +126,34 @@
|
||||
splitter.setAttribute('resizebefore', 'sibling');
|
||||
splitter.setAttribute('resizeafter', 'none');
|
||||
toolbox.insertAdjacentElement('afterend', splitter);
|
||||
|
||||
this._moveWindowButtons();
|
||||
this._addSidebarButtons();
|
||||
},
|
||||
|
||||
_moveWindowButtons() {
|
||||
const windowControls = document.getElementById('titlebar-buttonbox-container');
|
||||
const toolboxIcons = document.getElementById('zen-sidebar-top-buttons');
|
||||
if (AppConstants.platform == "macosx") {
|
||||
toolboxIcons.prepend(windowControls);
|
||||
}
|
||||
},
|
||||
|
||||
_addSidebarButtons() {
|
||||
const sidebarBox = window.MozXULElement.parseXULToFragment(`
|
||||
<toolbar id="zen-sidebar-top-buttons" fullscreentoolbar="true" brighttext="true">
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button" id="zen-expand-sidebar-button" data-l10n-id="sidebar-zen-expand" oncommand="gZenVerticalTabsManager.toggleExpand();"></toolbarbutton>
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button chromeclass-toolbar-additional subviewbutton-nav" badge="true" closemenu="none" removable="true" delegatesanchor="true" cui-areatype="toolbar" id="zen-profile-button" data-l10n-id="toolbar-button-account" onclick="ZenProfileDialogUI.showSubView(this, event)"></toolbarbutton>
|
||||
</toolbar>
|
||||
`);
|
||||
document.getElementById('navigator-toolbox').prepend(sidebarBox);
|
||||
const sideBarTopButtons = document.getElementById('zen-sidebar-top-buttons');
|
||||
|
||||
const panelMenu = document.getElementById('PanelUI-menu-button');
|
||||
panelMenu.classList.add('zen-sidebar-action-button');
|
||||
panelMenu.setAttribute('cui-areatype', 'toolbar');
|
||||
|
||||
sideBarTopButtons.prepend(panelMenu);
|
||||
},
|
||||
|
||||
_focusSearchBar() {
|
||||
|
||||
Submodule src/browser/base/content/zen-components updated: 0f775df5e6...72396b8f55
@@ -1,9 +1,4 @@
|
||||
<toolbar brighttext="true" id="zen-sidebar-icons-wrapper" class="zen-dont-hide-on-fullscreen">
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button chromeclass-toolbar-additional subviewbutton-nav" badge="true" closemenu="none" removable="true" delegatesanchor="true" cui-areatype="toolbar" id="zen-profile-button" data-l10n-id="toolbar-button-account" onclick="ZenProfileDialogUI.showSubView(this, event)">
|
||||
</toolbarbutton>
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button" id="zen-expand-sidebar-button" data-l10n-id="sidebar-zen-expand" oncommand="gZenVerticalTabsManager.toggleExpand();"></toolbarbutton>
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button" id="zen-sidepanel-button" data-l10n-id="sidebar-zen-sidepanel" onclick="gZenBrowserManagerSidebar.toggle();"></toolbarbutton>
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button" id="zen-bookmark-button" data-l10n-id="sidebar-menu-bookmarks" onclick="gZenUIManager.toogleBookmarksSidebar();"></toolbarbutton>
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button" id="zen-history-button" data-l10n-id="sidebar-menu-history" oncommand="PanelUI.showSubView('PanelUI-history', this);"></toolbarbutton>
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button" id="zen-preferences-button" data-l10n-id="toolbar-settings-button" onclick="event.target.ownerGlobal.openPreferences(undefined);"></toolbarbutton>
|
||||
<toolbarbutton class="toolbarbutton-1 zen-sidebar-action-button" id="zen-sidepanel-button" data-l10n-id="sidebar-zen-sidepanel" onclick="gZenBrowserManagerSidebar.toggle();"></toolbarbutton>
|
||||
</toolbar>
|
||||
@@ -1,4 +1,12 @@
|
||||
:root:not([inDOMFullscreen='true']):not([chromehidden~='location']):not([chromehidden~='toolbar']) {
|
||||
#tabbrowser-tabbox {
|
||||
--zen-webview-correction-margin: 2px;
|
||||
|
||||
& > *:not(#tabbrowser-tabpanels) {
|
||||
margin-top: var(--zen-webview-correction-margin);
|
||||
}
|
||||
}
|
||||
|
||||
& #tabbrowser-tabbox #tabbrowser-tabpanels .browserSidebarContainer {
|
||||
width: -moz-available;
|
||||
border-radius: var(--zen-webview-border-radius, var(--zen-border-radius));
|
||||
@@ -6,7 +14,6 @@
|
||||
position: relative;
|
||||
|
||||
/* This fixes an issue with the left border */
|
||||
--zen-webview-correction-margin: 2px;
|
||||
margin-left: var(--zen-webview-correction-margin);
|
||||
margin-top: var(--zen-webview-correction-margin);
|
||||
|
||||
|
||||
@@ -85,24 +85,11 @@
|
||||
@media not (-moz-bool-pref: 'zen.view.compact.hide-toolbar') {
|
||||
#navigator-toolbox {
|
||||
/* Remove the top margin */
|
||||
/* The toolbox isn't relative to the webview anymore, meaning we can't just add a static value and call it a day...
|
||||
* The top margin is calculated by taking the following factors into account:
|
||||
* 1. Element separation
|
||||
* 2. Extra margin to separate from the webview
|
||||
* 3. Add element separation variable, to avoid overlaping with the toolbar
|
||||
* 4. Calculate toolbar height, taken from zen-urlbar.css
|
||||
*/
|
||||
--zen-compact-toolbox-margin: calc(
|
||||
var(--zen-element-separation) + 0.8rem +
|
||||
(18px + (var(--toolbarbutton-inner-padding) * 2))
|
||||
) var(--zen-compact-toolbox-margin-single) var(--zen-compact-toolbox-margin-single) var(--zen-compact-toolbox-margin-single);
|
||||
--zen-compact-toolbox-margin: calc(var(--zen-compact-toolbox-margin-single) / 2)
|
||||
var(--zen-compact-toolbox-margin-single) var(--zen-compact-toolbox-margin-single)
|
||||
var(--zen-compact-toolbox-margin-single);
|
||||
|
||||
margin-top: 0 !important;
|
||||
:root[zen-sidebar-legacy='true'] & {
|
||||
--zen-compact-toolbox-margin: calc(var(--zen-compact-toolbox-margin-single) / 2)
|
||||
var(--zen-compact-toolbox-margin-single) var(--zen-compact-toolbox-margin-single)
|
||||
var(--zen-compact-toolbox-margin-single);
|
||||
}
|
||||
}
|
||||
|
||||
#zen-sidebar-web-panel-wrapper,
|
||||
|
||||
@@ -14,10 +14,6 @@
|
||||
|
||||
#browser {
|
||||
--zen-toolbox-padding: 5px;
|
||||
|
||||
:root:not([zen-sidebar-legacy='true']) & {
|
||||
--zen-toolbox-top-align: var(--zen-toolbox-padding);
|
||||
}
|
||||
}
|
||||
|
||||
#navigator-toolbox {
|
||||
@@ -97,7 +93,7 @@
|
||||
#zen-sidebar-icons-wrapper {
|
||||
background: transparent;
|
||||
|
||||
& toolbarbutton {
|
||||
& toolbarbutton:not(#zen-workspaces-button) {
|
||||
width: fit-content;
|
||||
padding: 0 !important;
|
||||
}
|
||||
@@ -158,10 +154,9 @@
|
||||
--zen-toolbox-min-width: 150px;
|
||||
|
||||
& #zen-sidebar-icons-wrapper {
|
||||
display: grid;
|
||||
display: flex;
|
||||
/* Make sure the icons take most of the space, smartly */
|
||||
grid-template-columns: repeat(auto-fit, minmax(34px, auto));
|
||||
gap: 4px;
|
||||
flex-direction: row;
|
||||
justify-content: space-between;
|
||||
|
||||
padding-top: calc(var(--zen-toolbox-padding) * 2);
|
||||
@@ -169,7 +164,7 @@
|
||||
width: 100%;
|
||||
position: relative;
|
||||
|
||||
--toolbarbutton-inner-padding: 9px !important;
|
||||
--toolbarbutton-inner-padding: var(--zen-toolbar-button-inner-padding) !important;
|
||||
|
||||
justify-content: space-between;
|
||||
}
|
||||
@@ -238,10 +233,6 @@
|
||||
}
|
||||
|
||||
@media (-moz-bool-pref: 'zen.view.sidebar-expanded.on-hover') {
|
||||
:root:not([zen-sidebar-legacy='true']) #navigator-toolbox:is([zen-user-hover='true']:hover, :not([zen-user-hover='true'])) {
|
||||
padding-right: 47px !important;
|
||||
}
|
||||
|
||||
& #zen-profile-button {
|
||||
width: 100% !important;
|
||||
padding: var(--toolbarbutton-inner-padding) !important;
|
||||
@@ -470,4 +461,18 @@
|
||||
opacity: 0;
|
||||
display: none;
|
||||
}
|
||||
|
||||
/* Mark: Sidebar top buttons */
|
||||
#zen-sidebar-top-buttons {
|
||||
--toolbarbutton-inner-padding: var(--zen-toolbar-button-inner-padding) !important;
|
||||
|
||||
gap: 5px;
|
||||
& .zen-sidebar-action-button {
|
||||
padding: 0 !important;
|
||||
|
||||
& label {
|
||||
display: none !important;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -74,6 +74,10 @@
|
||||
--zen-button-border-radius: 7px;
|
||||
--zen-button-padding: 0.6rem 1.2rem;
|
||||
|
||||
/* Toolbar */
|
||||
--zen-toolbar-height: 39px;
|
||||
--zen-toolbar-button-inner-padding: 6px;
|
||||
|
||||
/* Other colors */
|
||||
--urlbar-box-bgcolor: var(--zen-urlbar-background) !important;
|
||||
--toolbar-field-focus-background-color: var(--urlbar-box-bgcolor) !important;
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
#nav-bar {
|
||||
#nav-bar,
|
||||
#zen-sidebar-top-buttons {
|
||||
background: transparent;
|
||||
}
|
||||
|
||||
|
||||
@@ -171,53 +171,26 @@ button.popup-notification-dropmarker {
|
||||
margin-top: 5px;
|
||||
}
|
||||
|
||||
:root:not([zen-sidebar-legacy='true']) {
|
||||
@media (max-width: 650px) {
|
||||
#urlbar-container {
|
||||
width: calc(176px + 2 * (24px + 2 * var(--toolbarbutton-inner-padding)));
|
||||
}
|
||||
|
||||
#nav-bar[downloadsbuttonshown] #urlbar-container,
|
||||
#nav-bar[unifiedextensionsbuttonshown] #urlbar-container {
|
||||
width: calc(76px + 24px + 2 * var(--toolbarbutton-inner-padding));
|
||||
}
|
||||
|
||||
#nav-bar[downloadsbuttonshown][unifiedextensionsbuttonshown] #urlbar-container {
|
||||
width: 176px;
|
||||
}
|
||||
|
||||
#identity-icon-box {
|
||||
max-width: 70px;
|
||||
}
|
||||
|
||||
#urlbar-zoom-button {
|
||||
display: none;
|
||||
}
|
||||
@media (max-width: 550px) {
|
||||
#urlbar-container {
|
||||
width: calc(176px + 2 * (24px + 2 * var(--toolbarbutton-inner-padding)));
|
||||
}
|
||||
}
|
||||
|
||||
:root[zen-sidebar-legacy='true'] {
|
||||
@media (max-width: 550px) {
|
||||
#urlbar-container {
|
||||
width: calc(176px + 2 * (24px + 2 * var(--toolbarbutton-inner-padding)));
|
||||
}
|
||||
#nav-bar[downloadsbuttonshown] #urlbar-container,
|
||||
#nav-bar[unifiedextensionsbuttonshown] #urlbar-container {
|
||||
width: calc(76px + 24px + 2 * var(--toolbarbutton-inner-padding));
|
||||
}
|
||||
|
||||
#nav-bar[downloadsbuttonshown] #urlbar-container,
|
||||
#nav-bar[unifiedextensionsbuttonshown] #urlbar-container {
|
||||
width: calc(76px + 24px + 2 * var(--toolbarbutton-inner-padding));
|
||||
}
|
||||
#nav-bar[downloadsbuttonshown][unifiedextensionsbuttonshown] #urlbar-container {
|
||||
width: 176px;
|
||||
}
|
||||
|
||||
#nav-bar[downloadsbuttonshown][unifiedextensionsbuttonshown] #urlbar-container {
|
||||
width: 176px;
|
||||
}
|
||||
#identity-icon-box {
|
||||
max-width: 70px;
|
||||
}
|
||||
|
||||
#identity-icon-box {
|
||||
max-width: 70px;
|
||||
}
|
||||
|
||||
#urlbar-zoom-button {
|
||||
display: none;
|
||||
}
|
||||
#urlbar-zoom-button {
|
||||
display: none;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -272,6 +245,15 @@ button.popup-notification-dropmarker {
|
||||
}
|
||||
}
|
||||
|
||||
#nav-bar,
|
||||
#zen-sidebar-top-buttons {
|
||||
min-height: var(--zen-toolbar-height) !important;
|
||||
height: var(--zen-toolbar-height) !important;
|
||||
max-height: var(--zen-toolbar-height) !important;
|
||||
display: flex;
|
||||
align-items: center;
|
||||
}
|
||||
|
||||
/* Other small tweaks */
|
||||
#nav-bar-customization-target {
|
||||
/* Don't grow if potentially-user-sized elements (like the searchbar or the
|
||||
@@ -279,6 +261,8 @@ button.popup-notification-dropmarker {
|
||||
* available space as much as possible, see bug 1795260. */
|
||||
min-width: 0;
|
||||
|
||||
--toolbarbutton-inner-padding: var(--zen-toolbar-button-inner-padding);
|
||||
|
||||
/* Add space to beginning of toolbar and make that space click the first <toolbarbutton> */
|
||||
> :is(toolbarbutton, toolbaritem):first-child,
|
||||
> toolbarpaletteitem:first-child > :is(toolbarbutton, toolbaritem) {
|
||||
@@ -286,12 +270,6 @@ button.popup-notification-dropmarker {
|
||||
}
|
||||
}
|
||||
|
||||
@media (-moz-bool-pref: 'zen.view.compact') or (-moz-bool-pref: 'zen.themes.tabs.legacy-location') {
|
||||
#nav-bar {
|
||||
padding-left: var(--zen-element-separation) !important;
|
||||
}
|
||||
}
|
||||
|
||||
.titlebar-button:last-child {
|
||||
padding-right: var(--zen-element-separation) !important;
|
||||
}
|
||||
|
||||
@@ -1,12 +1,9 @@
|
||||
#zen-workspaces-button {
|
||||
border: 1px solid var(--zen-colors-border);
|
||||
border-radius: var(--zen-button-border-radius);
|
||||
min-height: 33px;
|
||||
justify-content: center;
|
||||
align-items: center;
|
||||
display: flex;
|
||||
box-shadow: rgba(0, 0, 0, 0.05) 0px 1px 2px 0px;
|
||||
-moz-window-dragging: no-drag;
|
||||
margin: 0 30px;
|
||||
opacity: .6;
|
||||
}
|
||||
|
||||
#zen-workspaces-button .zen-workspace-sidebar-name {
|
||||
@@ -15,7 +12,7 @@
|
||||
overflow: hidden;
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
font-size: 12px;
|
||||
font-size: 13px;
|
||||
pointer-events: none;
|
||||
}
|
||||
|
||||
@@ -51,7 +48,6 @@
|
||||
white-space: nowrap;
|
||||
text-overflow: ellipsis;
|
||||
display: flex;
|
||||
padding: 0 10px;
|
||||
width: calc(100% - var(--zen-tabbrowser-padding) * 6) !important;
|
||||
gap: 0.5ch;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user