feat(bread-theme): vertical (side-docked) bar orientation (v0.7.10) #18
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "feature/bar-15-vertical-side-dock"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Part of BAR-15 (breadbar): support a bar docked to the left/right screen edge, not just top/bottom.
[bar.window].anchorsalready acceptedleft/rightas edge pins for a horizontal bar, but there was no orientation axis at all —width(Fill/Px) was always the length axis andheightwas always the fixed thickness, with no "fill vertically, fixed width" mode.Approach
Derived from the anchor set instead of a new schema field: anchored to exactly one of
left/rightand bothtopandbottomis unambiguously a vertical dock — the same "opposing anchors with nothing else fill that axis" rule a horizontal bar already uses forwidth = "fill", applied to the other axis. Every existing theme's anchor set (e.g.["top", "left", "right"]) resolves toHorizontalunchanged — no migration, no new TOML key.Changes
bread-theme/src/shell/types.rs:WindowOrientationenum +WindowSpec::orientation().bread-theme/src/shell/manifest.rs:resolve_windowrejectswidth = "fill"on a vertical anchor set — the fill axis for a side dock is top/bottom (already filled by the anchors), so"fill"has nothing left to mean onwidth.docs/shell-themes.md: new "Side-docked (vertical) bars" subsection, updated live-vs-restart table and theneeds_restartexact-rule paragraph (see companion breadbar PR — a horizontal↔vertical switch is one of the few[bar.window]changes that isn't live, since the internal box orientations aren't rebuilt by the live-reload path).Test plan
cargo build --release -p bread-themecargo test --release -p bread-theme— 109 tests passing, including 6 newWindowSpec::orientation()unit tests (types.rs) and 2 new manifest-resolution tests (mod.rs: a left-docked theme resolves asVerticalwithwidthintact;width = "fill"on a vertical anchor set is a hard error naming "vertical")Depends on / blocks
Breadbar's consumer-side changes (
apply_window_spec's exclusive zone, and vertical-stacking layout for the bar's slot containers) are written and tested locally against this branch via a.cargo/config.tomlpath patch, but can't be opened as a real PR or merged until this lands and a new tag is cut — breadbar pinsbread-themeby git tag (v0.7.9currently), and the newWindowOrientation/orientation()API doesn't exist there yet. Sequencing: merge this → cut av0.7.10tag → bump breadbar's pin → open breadbar's PR.🤖 Generated with Claude Code
https://claude.ai/code/session_01WtbAi2H268yYaoUb5YoPN9
Pull request closed