Merge pull request 'fix(sidebar): 让未归类与默认工作区真正固定在侧栏底部' (#2) from fix/sidebar-bottom-dock into main
This commit is contained in:
commit
d061e7ce35
File diff suppressed because one or more lines are too long
|
|
@ -11,6 +11,23 @@
|
|||
overflow:hidden;
|
||||
}
|
||||
|
||||
/* The host sidebar scrollport lays its workspace region out as a max-content
|
||||
grid row. That makes the whole sidebar scroll as one block, so the plugin's
|
||||
own .wgRoot height cannot fill the viewport and the bottom dock ends up
|
||||
right after the tree instead of pinned to the sidebar bottom. Only when our
|
||||
tree is mounted, give the workspace region the remaining row; the tree body
|
||||
then owns the scrolling and .wgDock stays outside it. */
|
||||
[data-sidebar-scrollport]:has(> [class*="regionArea"] > .wgRoot) {
|
||||
grid-template-rows:8px max-content 2px minmax(0, 1fr);
|
||||
align-content:stretch;
|
||||
overflow-y:hidden;
|
||||
}
|
||||
|
||||
[data-sidebar-scrollport] > [class*="regionArea"]:has(> .wgRoot) {
|
||||
min-height:0;
|
||||
overflow:hidden;
|
||||
}
|
||||
|
||||
/* Remote SSH's legacy title matcher appends a globe to the first SVG it
|
||||
finds. Our row starts with a disclosure slot, so the badge can land on the
|
||||
wrong icon. Suppress only that injected decoration within this tree; keep
|
||||
|
|
|
|||
|
|
@ -61,6 +61,8 @@ const block = (selector) => {
|
|||
assert.match(block('.wgRoot'), /height:100%/, 'the root consumes the sidebar slot height')
|
||||
assert.match(block('.wgRoot'), /max-height:100%/, 'the root cannot grow past its slot')
|
||||
assert.match(block('.wgRoot'), /overflow:hidden/, 'the root clips instead of scrolling the whole sidebar')
|
||||
assert.match(css, /\[data-sidebar-scrollport\]:has\(> \[class\*="regionArea"\] > \.wgRoot\)/, 'the host scrollport is claimed only when the tree is mounted')
|
||||
assert.match(css, /grid-template-rows:8px max-content 2px minmax\(0, 1fr\)/, 'the workspace region takes the remaining row instead of max-content')
|
||||
assert.match(block('.wgDock'), /border-top:1px solid/, 'the dock draws the divider against the tree')
|
||||
assert.match(block('.wgDock'), /max-height:min\(62vh,560px\)/, 'the dock is capped so the tree always keeps room')
|
||||
assert.match(block('.wgDock'), /overflow:hidden/, 'the dock clips its own overflow instead of painting over the tree')
|
||||
|
|
|
|||
Loading…
Reference in New Issue