fix(tui): disclose truncated tab titles - #42344
Closed
kitlangton wants to merge 1 commit into
Closed
Conversation
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.
What
Keep truncated session tab titles stationary and disclose the full title in a delayed hover tooltip instead of scrolling it as a marquee.
The tooltip appears only when the title exceeds its available cells, stays within the terminal bounds, and works in both the vertical session rail and horizontal tab strip.
Before / After
Before: Hovering a truncated tab for 600 ms started a continuously looping marquee. The tab label changed beneath the pointer and could keep moving independently of the user scanning the tab strip.
After: The truncated title remains a stable, softly faded landmark. A deliberate 600 ms hover opens the full title beside or below the tab, and leaving, pressing, dragging, switching layout, or removing the tab dismisses it immediately.
How
packages/tui/src/component/session-tabs.tsxreplaces the marquee timer and offset state with overflow-only delayed disclosure state.Scope
This changes only pointer-hover disclosure for truncated TUI session tab titles. Tab sizing, keyboard navigation, close controls, drag ordering, and the web titlebar are unchanged.
Testing
bun run test test/component/session-tabs-title-disclosure.test.ts test/context/session-tabs-model.test.tsfrompackages/tui(33 passing)bun typecheckfrompackages/tuibun turbo typecheck --concurrency=3(34 successful tasks)Demo
Isolated OpenCode Drive
session-tabsstory using the productionSessionTabscomponent. The pointer hovers a truncated title in the vertical rail, then repeats the interaction in the horizontal strip.tab-title-tooltip.mp4