Add 2 splitters to resize Zen sidebar on all sides, rewrite handleSplitter method

This commit is contained in:
brahim
2024-09-24 23:33:51 +02:00
parent ed4ab842a5
commit 43c86ea74c
2 changed files with 17 additions and 10 deletions

View File

@@ -26,7 +26,9 @@
</toolbar>
<toolbarbutton id="zen-sidebar-add-panel-button" class="zen-sidebar-panel-button toolbarbutton-1 chromeclass-toolbar-additional" onclick="gZenBrowserManagerSidebar._openAddPanelDialog();"/>
</toolbar>
<html:span id="zen-sidebar-web-panel-splitter"></html:span>
<html:span id="zen-sidebar-web-panel-hsplitter"></html:span>
<html:span class="zen-sidebar-web-panel-splitter" side="left"></html:span>
<html:span class="zen-sidebar-web-panel-splitter" side="right"></html:span>
<html:span class="zen-sidebar-web-panel-splitter" orient="horizontal" side="top"></html:span>
<html:span class="zen-sidebar-web-panel-splitter" orient="horizontal" side="bottom"></html:span>
</box>
</hbox>

View File

@@ -101,10 +101,10 @@
height: unset !important;
}
#zen-sidebar-web-panel-splitter {
.zen-sidebar-web-panel-splitter {
position: absolute;
top: 0;
right: 0;
left: 0;
height: 100%;
width: 4px;
background: transparent;
@@ -112,17 +112,22 @@
cursor: ew-resize;
}
#zen-sidebar-web-panel-hsplitter {
position: absolute;
bottom: -2px;
left: 0;
.zen-sidebar-web-panel-splitter[side='right'] {
left: initial;
right: 0;
}
.zen-sidebar-web-panel-splitter[orient='horizontal'] {
width: 100%;
height: 7px;
background: transparent;
border: none;
cursor: ns-resize;
}
.zen-sidebar-web-panel-splitter[side='bottom'] {
top: initial;
bottom: -2px;
}
#zen-sidebar-web-panel[hidden='true'] #zen-sidebar-web-panel-hsplitter,
#zen-sidebar-web-panel-wrapper[hidden='true'] + #zen-sidebar-web-panel-splitter,
#zen-sidebar-web-panel-wrapper[hidden='true'] + #zen-sidebar-web-panel-hsplitter,