Repository navigation
fix(ui): keep tab titles clear of stationary close actions - #3535
Merged
Merged
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.
Summary
Tab close actions currently cover short titles. Reserve a fixed internal action slot, center the title/icon/suffix at rest, and shift them aside as the action appears. Tab and close-button positions remain unchanged during hover.
Type and Areas
Type: UI/UX, bug fix
Areas: shared TabGroup design-system component, scene/document tab bars
Motivation / Impact
Short titles remain readable and close targets stay stationary. Tabs without an end action keep their existing layout. Keyboard focus reveals actions immediately, touch keeps content clear of visible actions, RTL reverses the shift, and reduced motion disables the transitions. Existing label overflow, rolling-text replacement, tab selection, and close callbacks retain their ownership.
Verification
pnpm run check:web— passed, including type checking, Appearance, all-surface theme color audits, and theme visual contracts.pnpm --dir design-system run build:ui && node --test design-system/packages/ui/tests/tab-group.test.mjs design-system/packages/ui/tests/capsule.test.mjs design-system/packages/ui/tests/icon-slots.test.mjs— 25 tests passed.pnpm --dir src/web-ui run test:run src/app/components/SceneBar/SceneBar.test.tsx src/app/components/SceneTopBar/SceneTopBar.test.tsx src/app/components/panels/content-canvas/tab-bar/TabBar.test.tsx— 47 tests passed.pnpm run motion:audit— reviewed inventory, not a pass/fail gate.git diff --checkandnode scripts/check-git-object-sizes.mjs --base upstream/main --head HEAD— passed.Browser geometry/callback verification used the public TabGroup with real SceneBar sizing in a temporary fixture: compact, standard, and RTL layouts; short titles, long rolling titles with suffixes, and icons. All idle content groups centered exactly. Across 27 pointer closes and 3,324 sampled frames, tab/action geometry changed by zero and no selection callbacks fired. Keyboard closure, immediate focus presentation, and reduced-motion behavior also passed. Temporary files were removed.
Reviewer Notes
AI-assisted; locally tested. Browser fixture measurements establish interaction geometry, not native WebView visual fidelity. No native screenshots are included. For visual review, hover a short tab and then its close button: the title should move while the pill and close target stay fixed. Compare a long title and a tab without a close action.
No persisted shapes, APIs, or remote protocols change. Live remote workspace, remote control, Peer Device Mode, and Detached Dispatch were not exercised. A prior broader design-system check encountered existing unrelated flow-chat catalog mismatches; this change was verified with the focused checks above.
Checklist