Repository navigation
feat(tui): tell navigator tabs apart by ground and centre labels - #678
Merged
Merged
Conversation
The active navigator tab was marked by an accent underline plus a reserved `>` cell in front of the label. Replace both with the tab's own ground: the active tab fills with `accent_soft`, keeps the accent hue at bold weight, and the label is centred in the tab box. Consequences carried deliberately: - The label no longer shifts when the tab gains focus, because there is no marker cell left to reserve. - The tab bar now shows which tab is active, not which block owns the keyboard. On the Sessions tab that removes the only ownership cue, since the list already paints `selected` and `focused` rows identically. - `N need` keeps its right edge and is dropped when the centred label would touch it, which happens between frame widths 116 and 125. Add a per-theme guard that `accent_soft` stays separable from `surface` and `surface_hover`, so a future theme cannot collapse the active tab into an idle or hovered one (FORGE-DESIGN invariant 11, §9.6).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Navigator tab selection (
Sessions | Files) is now carried by the tab's own ground instead of an underline plus a reserved>cell.What changed
accent_softacross the whole tab box; its label keeps the accent hue at bold weight. No tab is underlined any more.N needkeeps its right edge and is dropped only when it would touch the centred label.NavigatorTabs::focusedis deleted rather than left as a no-op: it existed solely to draw the marker.Deliberate tradeoffs
selectedandfocusedrows identically (navigator.rs:194,209). That is recorded inFORGE-DESIGN.md§9.6 rather than left implicit.N needdisappears between frame widths 116 and 125. The navigator isclamp(content_width / 4, 28, 37), so the centred label eats the badge's lane there; it fit when the label was left-aligned. The count returns at 126 and up, and the collapsed chip belowfiles_fit()is unaffected.theme.rs::brand()'s "accent is a focus style" docstring is untouched. The FORGE-DESIGN token table already lists accent for "active structure", and §9.6 now names the active tab's accent as exactly that.Tests
the_active_tab_is_told_apart_by_its_ground_alone— accent + bold + ground on the label, fill spans the tab box, nothing underlined.each_label_is_centred_in_its_own_tab— pins absolute label columns at 40 cells.the_badge_holds_the_right_edge_and_yields_to_a_narrow_tab— wide tab keeps both; narrow tab drops the badge rather than crowding the label.navigator_tab_grounds_stay_apart_in_every_theme— new per-theme guard:accent_softmust stay separable fromsurfaceandsurface_hover, so a future theme cannot collapse the active tab into an idle or hovered one.Docs updated: §9.6 tab treatment, the §5 L3 lists, and invariant 11's marker list.
Local run
cargo test -p forge-tui: 1286 passed, 5 failed on this machine — all five are the host refusing nested confinement (background-command tests and thebash exit 127case), unrelated to this diff and green in a normal environment.cargo fmt --all -- --checkandcargo clippy -p forge-tui --all-targets -- -D warningsare clean.