fix(web): 130+ UI consistency fixes - #6218
Conversation
|
Important Review skippedAuto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Repository UI Review profile: CHILL Plan: Pro Plus Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
ApprovabilityVerdict: Approved f631c20 This PR contains 130+ mechanical CSS class modifications for UI consistency: adding cursor-pointer to interactive elements, focus-visible ring styles for accessibility, standardizing opacity values, and using CSS variables for consistent spacing. All changes are pure styling with no runtime behavior impact. You can customize Macroscope's approvability policy. Learn more. |
d86f2ed to
e21bd74
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Dismissing prior approval to re-evaluate e21bd74
e21bd74 to
c4ef3ee
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Dismissing prior approval to re-evaluate c4ef3ee
c4ef3ee to
00fe156
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
00fe156 to
6798e63
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
6798e63 to
602815c
Compare
Dismissing prior approval to re-evaluate 602815c
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
602815c to
66f4e28
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Dismissing prior approval to re-evaluate 66f4e28
66f4e28 to
42dc566
Compare
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
# Conflicts: # apps/web/src/components/AgentsPanel.tsx # apps/web/src/components/BranchToolbarBranchSelector.tsx # apps/web/src/components/ChatView.tsx # apps/web/src/components/DiffPanel.tsx # apps/web/src/components/LegacySidebar.tsx # apps/web/src/components/ThreadTerminalDrawer.tsx # apps/web/src/components/chat/ChangedFilesTree.test.tsx # apps/web/src/components/chat/ChangedFilesTree.tsx # apps/web/src/components/chat/ComposerPendingUserInputPanel.tsx # apps/web/src/components/chat/ComposerPreviewAnnotationCards.tsx # apps/web/src/components/chat/ComposerPrimaryActions.tsx # apps/web/src/components/chat/ModelPickerContent.tsx # apps/web/src/components/chat/ProviderStatusBanner.tsx # apps/web/src/components/files/FilePreviewPanel.tsx # apps/web/src/components/pullRequest/PullRequestCodeTab.tsx # apps/web/src/components/search/ProjectContentSearchDialog.tsx # apps/web/src/components/settings/SourceControlSettings.tsx # apps/web/src/components/settings/settingsLayout.tsx # apps/web/src/components/sidebar/SidebarProviderUpdatePill.tsx # apps/web/src/components/ui/combobox.tsx # apps/web/src/components/ui/menu.tsx # apps/web/src/components/ui/toast.tsx # apps/web/src/index.css
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Dismissing prior approval to re-evaluate f9cf6c4
There was a problem hiding this comment.
UI consistency review: 3 findings, all in shared primitives or their call sites. The rest of the pass (cursor/focus-ring standardization, opacity-64 alignment, --control-radius / --sidebar-row-content-inset adoption, switch track/thumb geometry, electron-drag-region → drag-region, ChangedFilesCard state lift and !size-[22px] removal) checks out: the switch travel math still resolves to --thumb-size - 4px, icon-xs and xs buttons are both size-7 sm:size-6 so the collapse-all control still lines up with "Open diff", and --control-radius (0.5rem) equals rounded-md so the sidebar radius token swap is a no-op visually.
Posted via Macroscope — UI Consistency
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Dismissing prior approval to re-evaluate 518548d
There was a problem hiding this comment.
Reviewed the changed web UI against the shared primitives and Tailwind/CSS ownership rules. The three findings from the previous run (selectTriggerIconClassName sizing, the missing autocomplete popup shadow, and the hand-copied MenuGroupLabel classes in TraitsPicker) are all addressed.
Two new items below. Everything else checked out: the --control-radius / --sidebar-row-content-inset swaps are value-preserving, the Switch and MenuCheckboxItem track resize keeps thumb size and travel identical, the ChangedFilesCard state hoist keeps the ChangedFilesTree contract intact (only consumers are the card and its tests), and the unlayered prefers-reduced-motion block correctly overrides the animate-* utilities.
Posted via Macroscope — UI Consistency
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Dismissing prior approval to re-evaluate 251a1dc
There was a problem hiding this comment.
Reviewed the changed web UI files for shared-primitive and Tailwind-ownership consistency. The earlier findings (autocomplete popup elevation, select trigger icon sizing, TraitsPicker group label, image-dialog close button, mini-player focus ring) are resolved in this head. Two small consistency items remain, both inline.
Posted via Macroscope — UI Consistency
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Dismissing prior approval to re-evaluate 4a6ca15
There was a problem hiding this comment.
UI consistency review: two findings, both about shared-token/primitive ownership. Everything else in the pass (focus-ring standardization, opacity-64 disabled token, cursor-pointer on interactive elements, popup/glass elevation, --control-radius / --sidebar-row-content-inset adoption, select trigger icon deferral, changed-files expansion state) checks out, and the earlier review points are resolved.
Posted via Macroscope — UI Consistency
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Dismissing prior approval to re-evaluate fdbce62
There was a problem hiding this comment.
UI consistency review of the web surface changes. Most of the pass is a clean convergence (shared DIALOG_BACKDROP_CLASS, extracted SWITCH_TRACK_CLASS, primitive-owned icon sizing in Button, --control-radius / --sidebar-row-content-inset sidebar rows, MenuGroupLabel instead of hand-rolled labels). Three ownership issues introduced by this diff are worth tightening before merge.
Posted via Macroscope — UI Consistency
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Problem
The web app has accumulated small UI drift: raw interactive elements missing the
cursor-pointerthe primitives opt into (Tailwind v4 preflight leaves buttons atcursor: default), controls withoutline-noneand no focus ring, seven different disabled opacities (30/40/45/50/55/60/80) against the primitives'opacity-64, popups that animate in but not out (or not at all), single-line text clipping descenders, and sibling components hand-rolling what a shared primitive already provides.None of these are features — every change aligns an element with what its own siblings or the
ui/primitives already do. When one instance of a defect was found, the identical pattern was grepped for across the tree, so each category below is exhaustive rather than anecdotal. ~130 fixes, 87 files, +249/−283.Fixes
1. Switch thumb flush against the track edge; unchecked state invisible in dark
The thumb had a 1px inset (
p-pxon a track sizedthumb+2px). The track now grows 2px each way withp-0.5, giving an even 2px inset in both states — the checked translate distance is unchanged (--thumb-size − 4pxbefore and after). Separately, the dark unchecked track was--input= white/8% under abg-backgroundthumb — structurally invisible. It now getsdark:data-unchecked:bg-foreground/16plus the hairlineinset-ring-white/6edge treatment dark surfaces use elsewhere. Checked state untouched. Applied toui/switch.tsxand the inline switch inui/menu.tsx.2. Descender clipping (the letter g cut off)
leading-nonecombined withtruncate/line-clampgives a 1em line box withoverflow: hidden, so g/y/p/q tails clip at the box edge. Three real instances: the sidebar thread tooltip title (Sidebar.tsx),InputGroupText, and a copy-pastedleading-8.5on the smallNumberField(a 34px line box inside a 26px input).3. ~60 clickable elements missing
cursor-pointerRaw
<button>s and clickable labels across the sidebar, terminal drawer, pull-requests page, changed-files tree, settings, diff panel, and preview cards rendered the arrow cursor. Also fixed at the source:AutocompleteItemshippedcursor-default, which three consumers (command palette, composer command/stash menus) had each patched around locally; the base is now correct. Conditionally-clickable elements set both branches (isClickable ? "cursor-pointer" : "cursor-default").Each clip shows nightly first, then the fixed build after the window switch:
4. Menus and selects don't animate; popovers animate in but not out
ui/popover.tsxhaddata-starting-stylewith nodata-ending-style, so popovers faded in and popped out.ui/menu.tsxandui/select.tsxpopups carriedorigin-(--transform-origin)but no transition at all. The combobox and autocomplete popups declaredtransition-[scale,opacity]with nothing driving it. All five now share the tooltip's bidirectional scale/fade. Frame-level proof: at 120Hz, nightly's menu open/close changes exactly 1 frame; fixed shows a multi-frame ramp both directions.5. Snoozed shelf expand judders the list; Settled doesn't
The thread list FLIP-animates every moved row (
auto-animate). Settled sits at the list tail, so expanding it moves nothing and looks smooth; Snoozed sits mid-list, so expanding it slides every settled row below while translucent rows cross each other. Shelf toggles now suspend the list animation for that one update (toggleShelfWithoutListAnimationinSidebar.tsx), making both shelves behave identically. Single-row transitions — settle, wake, pin reorder — keep the animation they were designed for.6. Autocomplete popup was the only opaque popup
Every popup surface uses
dropdown-glassexcept the autocomplete popup (composer @-mentions, file pickers), which hand-rolledborder bg-popover shadow-lg/5— and therefore also ignored the Settings → Appearance glass controls.7. Theme color picker cancelled its own glass
The picker painted
bg-popoveron a child filling its glass popover, stackedborder-border/70+shadow-2xlon top of the glass border/elevation (utilities beat the@layer componentsshadow silently), and its dark hex field used a black wash on a dark surface — the only dark overlay in settings that darkens instead of lightens (cf.AddProviderInstanceDialog'sdark:bg-white/*pattern).8. Two select triggers, two chevrons
ui/select.tsxcontains two trigger components. One rendered the picker-standard⇕(matching comboboxes, the diff-panel branch picker, the PR base selector); the other a half-size 50%-opacity˅. Value pickers now consistently use⇕; menus and compact ghost selects keep˅— the pop-up vs pull-down distinction the app already follows.9. Invisible keyboard focus on ~15 controls
outline-none/outline-hiddenwith no replacement ring: diff-file collapse chevrons, changed-files tree rows (three of five also missing the ring offset their two siblings have), markdown<details>triggers, toast copy/expand buttons, combobox/autocomplete trigger and clear buttons, the ⌘K submenu Back button, the scroll-to-end pill, onboarding step cards. All now use the standard ring (focus-visible:ring-2 focus-visible:ring-ring+ offset), or the inset variant where full-bleed rows would clip an offset ring.The tooltip proves focus is on the collapse button in both shots; only one shows it:
10. Project settings "Actions" section invented a third heading scale
text-base font-semiboldwhere every settings row title istext-sm font-medium tracking-[-0.005em], a brighter description than the canonical recipe, andpy-2rows against theITEM_ROW_CLASSNAMEstandard ofpy-3.11. Preview controller badge didn't match the zoom pill
Same overlay layer, same geometry, different everything else:
text-[11px]onbg-background/90+shadow-smvs the zoom pill'stext-xsonbg-popover/95+shadow-md/10. Now identical.12. Timeline disclosure rows misaligned
The turn-plan row lacked the
size-5chevron centering box its sibling work-group rows use (and usedgap-2vs theirgap-1.5), so stacked rows' labels started at different x-offsets; one chevron was alsosize-3vssize-3.5.Unannotated pair
13. Disabled states dimmed to seven different values
opacity-30/40/45/50/55/60/80normalized to the primitives'opacity-64across ~20 sites, including the sharedsidebarMenuButtonVariants(disabled:andaria-disabled:). Two disabled rows (search results in flight, saved-backend cards while applying) had no dimming at all and gained it.14. Added during review
Two fixes landed after the PR opened, in the same spirit:
Autocomplete and combobox popups now animate their exit (Cursor Bugbot finding, confirmed real). Both put the scale/fade transition on a wrapper span reacting to a child's
data-ending-style, but Base UI waits only on the Popup node's own animations before unmounting, so exits popped instantly. The transition now lives on the Popup itself, matching menu, select, popover, and tooltip.The changed-files header buttons were different sizes. The collapse-all button carried a
!size-[22px]override forcing it 2px smaller than the Open-diff button beside it. Removed the override so both render the standard control size; the two tests pinning the old markup now pin its absence.15. Changed-files collapse-all button desynced from manually opened folders
The collapse/expand-all button on the changed-files card toggled a boolean owned by the timeline row, while each folder's open state lived privately inside the tree. Folders opened by hand desynced the pair: the button's icon pointed the wrong way and its first click re-applied the state the tree was already in — a visible no-op. The folder state now lives next to the button, which derives its icon, tooltip, and action from the actual per-folder state (collapse-all exactly when every folder is really open). Manual folder toggles also survive collapsing and reopening the card now.
Cursor Bugbot then caught an edge in the new derivation: with only root-level files there are no folders,
every()is vacuously true, and the button pinned itself to "Collapse all folders" with nothing to do. Confirmed against a root-only fixture; since the control is meaningless without folders, it is now omitted entirely in that case:16. Fixes without a useful screenshot
electron-drag-regionclassPreviewPanelShellreferenced a class that no stylesheet defines — the preview panel's window-drag strip has been inert since it shipped (the bundle defines only.drag-region). Renamed to the real class.bg-background/60 backdrop-blur-xs(2px); dialogs use.dialog-backdrop(4px + tuned tint). Sheets now use the shared class.dropdown-glasslackedsaturate()saturate(var(--glass-saturation)); content behind menus read grayer than behind dialogs.prefers-reduced-motion.ultrathink-pill,.ultrathink-word,.turn-chip-strip,.diff-render-file) plus a duplicate darkmodel-picker-surfacerule that overrode nothing; the split.dialog-glassdeclaration merged; two near-identical markdown scrollbar styles unified on the--app-scrollbar-widthtoken.--sidebar-*-inset,--floating-content-inset,--command-content-inset, and--fade-sizenow route through the vars (zero visual delta — these tokens exist, per the comment above them, so these surfaces "cannot quietly drift apart").sidebarMenuButtonVariantslg/smhad the radius and inset values transposed relative todefault.transitionwhere only colors change, color hovers with no transition, hover-reveals without a keyboard reveal (focus-visible:opacity-100), one-off hover tokens (hover:bg-accent/50amid/20siblings), a deadtransition-colorswith no hover state,hover:cursor-pointerinstead ofcursor-pointer.Notes
Validation
vp run --filter @t3tools/web typecheckvp test run --project unit(apps/web) — 2199 tests passedvp lint --report-unused-disable-directivesvp fmt --checkvp run --filter @t3tools/web buildModel: Claude Fable 5 · Harness: Claude Code in T3 Code
Note
Fix 130+ UI consistency issues across cursor, opacity, animation, and focus styles
cursor-pointerto dozens of interactive elements (buttons, rows, links) that previously showed the default cursor, and addscursor-default/pointer-events-noneto disabled controls.opacity-64across buttons, labels, and settings rows (previously mixed betweenopacity-40,opacity-45,opacity-50, andopacity-60).focus-visiblering styles to keyboard-navigable elements including sidebar thread timestamps, image preview buttons, composer buttons, and the stash delete control.ChangedFilesCarddirectory expansion state internal, replacing theallDirectoriesExpanded/onToggleAllDirectoriesprops withdefaultAllDirectoriesExpandedand per-directory override tracking; hides the collapse-all control when no directory nodes exist.prefers-reduced-motionsupport in index.css to disable ghost-pulse, status-pulse, status-ping, ultrathink, and chroma animations; also shortens the ghost-pulse period from 2.4s to 2s.DROPDOWN_LIST_POPUP_CLASS,DIALOG_BACKDROP_CLASS,SWITCH_TRACK_CLASS) and replaces arbitrary Tailwind values with CSS variable-driven utilities across sidebar, scroll area, and minimap components.ChangedFilesCardprop rename (allDirectoriesExpanded→defaultAllDirectoriesExpanded, removal ofonToggleAllDirectories) is a breaking interface change for any callers outside the updated files.Macroscope summarized f631c20.
Note
Low Risk
Mostly CSS and presentational state; the largest behavioral tweaks are changed-files folder state and sidebar shelf animation suspension, both localized and covered by updated unit tests.
Overview
Broad UI consistency pass across the web app: interactive elements get
cursor-pointer(and disabledcursor-not-allowed/opacity-64),focus-visiblerings where outlines were stripped, and bidirectional open/close animations on menus, selects, popovers, and list popups via sharedDROPDOWN_LIST_POPUP_CLASSon combobox/autocomplete.Changed-files card lifts folder expand/collapse into
ChangedFilesCardso collapse-all matches real folder state, hides the control when there are no directories, and drops the!size-[22px]header override so both actions match.Sidebar snoozed/settled shelf toggles temporarily disable
auto-animateon the thread list to avoid mid-list FLIP jank; shelf headers gain hover/focus styling aligned with other sidebar rows.Primitives and settings pick up smaller alignments: checkbox/radio cursors, menu switch track via
SWITCH_TRACK_CLASS, menu group labels in composer trait menus, geometry tokens (--control-radius, sidebar insets), and assorted typography/transition tweaks (e.g. descender clipping, preview badge vs zoom pill).Reviewed by Cursor Bugbot for commit f631c20. Bugbot is set up for automated code reviews on this repo. Configure here.