mirror of
https://github.com/Ark0N/Codeman.git
synced 2026-11-15 18:59:33 +01:00
feat(tabs): L-shaped header strip, wrapped rows run under the toolbar
A wrapped classic tab strip stopped at the toolbar's left edge on every row, so the space under the header chips stayed empty and long tabs took a row each. Once the strip wraps, the toolbar now sits over the strip's top-right corner and the strip lays its tabs out inline around a float sized to the toolbar's box (_syncTabStripCorner), so only the rows beside the toolbar stop short of it and every later row runs the header's full width. - Wrap is still measured with the toolbar in flow (the corner is dropped before the measure), so the single-row strip is unchanged. - A ResizeObserver on the toolbar re-decides wrap + corner and redraws the lineage routes when a reading or the divider changes its size. - Falls back to the plain strip when the first tab cannot fit beside the toolbar (it would otherwise leave an empty band). - Classic arrangement, desktop, header host only; state/case/ledger, the sidebar and the tab rail keep their own layouts.
This commit is contained in:
1 parent
3e06f3c141
commit
3dafc89095
2 files changed
+118
-1
No files matched your search
@@ -616,6 +616,44 @@ body {
|
||||
padding-left: var(--lineage-spine-channel);
|
||||
}
|
||||
|
||||
/* L-shaped strip (`_syncTabStripCorner()`, app.js): a wrapped classic strip
|
||||
runs the header's full width, the toolbar sits over its top-right corner,
|
||||
and only the rows beside the toolbar stop short of it. A flex line cannot
|
||||
be shortened on its own, so the strip lays its tabs out inline, around a
|
||||
float the size of the toolbar's box (measured into --tab-corner-width and
|
||||
--tab-corner-height). The strip scrolls, so it contains the float and is
|
||||
never shorter than the toolbar it now holds up. Inline tabs space their
|
||||
rows with a bottom margin (the old row-gap, lineage's included); the strip
|
||||
carries no font size of its own, so the whitespace between tabs is 0 wide. */
|
||||
.header:has(> .session-tabs-host > .session-tabs.tabs-corner) > .header-right {
|
||||
position: absolute;
|
||||
top: 0.35rem;
|
||||
right: 0.75rem;
|
||||
}
|
||||
|
||||
.session-tabs-host > .session-tabs.tabs-corner {
|
||||
display: block;
|
||||
font-size: 0;
|
||||
padding-bottom: 0;
|
||||
}
|
||||
|
||||
.session-tabs-host > .session-tabs.tabs-corner::before {
|
||||
content: '';
|
||||
float: right;
|
||||
width: var(--tab-corner-width, 0px);
|
||||
height: var(--tab-corner-height, 0px);
|
||||
}
|
||||
|
||||
.session-tabs-host > .session-tabs.tabs-corner > .session-tab {
|
||||
display: inline-flex;
|
||||
vertical-align: top;
|
||||
margin: 0 2px var(--lineage-row-gap, 4px) 0;
|
||||
}
|
||||
|
||||
.session-tabs-host > .session-tabs.lineage-tree.tabs-corner {
|
||||
padding-bottom: calc(var(--lineage-bottom-room) - var(--lineage-row-gap));
|
||||
}
|
||||
|
||||
.session-tabs::-webkit-scrollbar {
|
||||
width: 4px;
|
||||
height: 0;
|
||||
|
||||
Reference in new issue
Block a user