Skip to content

refactor(web): Button consumers outside the composer stop restyling it - #13208

Merged
juliusmarminge merged 1 commit into
restyle/stack-otherfrom
restyle/stack-button-rest
Sep 23, 2026
Merged

juliusmarminge merged 1 commit into
restyle/stack-otherfrom
restyle/stack-button-rest

Conversation

@juliusmarminge

@juliusmarminge juliusmarminge commented Sep 23, 2026 •

Copy link
Copy Markdown
Member

Buttons outside the composer stop restyling Button. Two generic changes land in ui/button.tsx:

  • glass is round. All three consumers forced rounded-full: Scroll to end, Cite selection, and the PR review trigger.
  • aria-disabled looks like disabled. This is for a disabled action that still explains itself in a popover (the git quick action).

Consumers:

  • Muted text actions use ghost-muted: the server update and environment actions, Copy message, Show full message, the PR sort toggles (now 12px), the sidebar search clears, and the accent colour Clear. Some become medium weight.
  • Pressed toggles use secondary: the device toolbar ratio lock, and table expand and code wrap in chat.
  • The chat-markdown-chrome-action CSS is deleted. Chat code-block and table buttons no longer follow the code-block colour tokens, so under a custom theme they use the regular muted colours.
  • "Setup Required" in the command palette and git menu is warning-outline micro, at 11px.
  • Row-hover reveal moves to a wrapper span: diff comment delete, project action edit, script edit, and PR edit. The code-review glass button loses its local opacity override.
  • sm-multiline for the default-branch dialog and onboarding rows. The provider update pill's dismiss X is a plain button, because it takes the pill's colour.
  • Small padding and hover shifts: git quick action, open in editor, palette submit, PR load more and reply, diff and code tab collapse, reset zoom, context window meter, script icon picker, and image dialog previous/next (no longer pills).

Input (generic): number inputs hide the browser spin buttons, replacing the device toolbar's call-site selectors. The theme hex field is left-aligned.

no-restyle findings: 250 → 101.

No screenshots yet: these changes are verified by lint, typecheck and tests only.

Claude Opus 5.5 via Claude Code.

🤖 Generated with Claude Code

Summary by CodeRabbit

  • Style
    • Refined button appearance, spacing, and layouts across chat, settings, project tools, pull requests, and onboarding.
    • Updated editing and deletion controls to reveal on hover or keyboard focus where applicable.
    • Standardized disabled-button appearance and rounded glass-style buttons.
    • Adjusted number fields to hide browser spinner controls and use text-field styling.

@juliusmarminge
juliusmarminge added this pull request to stack #13194 September 23, 2026 04:08
@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:L 100-499 changed lines (additions + deletions). labels Sep 23, 2026
type="button"
aria-label="Dismiss provider update notice"
className="relative z-[1] mr-1 [--control-icon-color:currentColor] rounded-md text-inherit opacity-70 hover:bg-transparent hover:opacity-100"
className="relative z-[1] mr-1 flex size-5 shrink-0 cursor-pointer items-center justify-center rounded-md opacity-70 outline-none hover:opacity-100 focus-visible:opacity-100 focus-visible:ring-2 focus-visible:ring-ring"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Medium sidebar/SidebarProviderUpdatePill.tsx:197

On coarse-pointer devices, the dismiss control now has only a size-5 (20px) hit target, so dismissing the notification is substantially harder than with the removed Button, which provided a 44px pointer-coarse target via after:min-h-11/after:min-w-11. Restore an equivalent coarse-pointer hit area on this native button.

🚀 Reply "fix it for me" or copy this AI Prompt for your agent:
In file @apps/web/src/components/sidebar/SidebarProviderUpdatePill.tsx around line 197:

On coarse-pointer devices, the dismiss control now has only a `size-5` (20px) hit target, so dismissing the notification is substantially harder than with the removed `Button`, which provided a 44px `pointer-coarse` target via `after:min-h-11`/`after:min-w-11`. Restore an equivalent coarse-pointer hit area on this native button.

<Button
size="icon-micro"
variant="ghost"
<button

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shared primitives over custom controls: this styled raw <button> rebuilds a control; use Button from components/ui/button instead.

Posted via Macroscope — UI Consistency

@github-actions

github-actions Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

Thread transfer impact

✅ Thread transfer remains within every enforced ceiling.

ℹ️ No successful main baseline artifact is available yet. This run establishes the initial measurement.

Provider Metric Main baseline This PR Impact PR ceiling
Codex Total thread wire — 13.5 KiB — 15.1 KiB ✅
Codex Thread snapshot wire — 7.1 KiB — 7.3 KiB ✅
Codex Live turn WebSocket wire — 6.4 KiB — 7.8 KiB ✅
Codex Live turn WebSocket decoded — 56.2 KiB — 66.4 KiB ✅
Codex Live turn messages — 9 — 21 ✅
Claude Total thread wire — 13.5 KiB — 15.1 KiB ✅
Claude Thread snapshot wire — 7.1 KiB — 7.3 KiB ✅
Claude Live turn WebSocket wire — 6.4 KiB — 7.8 KiB ✅
Claude Live turn WebSocket decoded — 57.0 KiB — 66.4 KiB ✅
Claude Live turn messages — 9 — 21 ✅

Baseline: unavailable · PR result: 327992a · Source CI: success

Scenario and decoded snapshot size

10 historical turns, 5 command tools per turn, 878.9 KiB retained MCP result per historical turn, and a 1.05 MiB retained result in the measured turn.

  • Codex decoded thread snapshot: 113.9 KiB
  • Claude decoded thread snapshot: 114.6 KiB

Updated in place by a trusted workflow. PR artifacts are strictly validated and never executed.

@macroscopeapp

macroscopeapp Bot commented Sep 23, 2026 •

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Would Approve

Macroscope's review found this PR approvable — This is a broad but low-risk web UI refactor that centralizes existing Button/Input styling without changing application logic, schemas, workflows, or sensitive paths. An unresolved Medium finding notes that the provider-update dismiss control lost its coarse-pointer hit area, which remains a separate issue to resolve before merging.

Not approved because:

  • 1 blocking correctness issue found at or above your repo's Minimum Blocking Severity

Adjust the Minimum Blocking Severity for this repo — including turning it Off — in Settings. You can add or adjust custom eligibility rules. Learn more.

@coderabbitai

coderabbitai Bot commented Sep 23, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Repository: pingdotgg/t3code/.coderabbit.yaml

Review profile: CHILL

Plan: Team

Run ID: 5e34e8ef-77de-4fe7-9a70-9072b9040982

📥 Commits

Reviewing files that changed from the base of the PR and between 4204200 and 327992a.

📒 Files selected for processing (1)
  • apps/web/src/components/onboarding/WelcomeWizard.tsx
🚧 Files skipped from review as they are similar to previous changes (1)
  • apps/web/src/components/onboarding/WelcomeWizard.tsx

Limit details: You’ve used all 10 included reviews currently available.


📝 Walkthrough

Walkthrough

This pull request updates button variants, spacing, and interaction styling across web application controls. It also changes shared button and number-input styles, moves some visibility rules to wrappers, and lowers the restyle lint ceiling.

Changes

Web control styling

Layer / File(s) Summary
Shared button, input, and markdown styling
apps/web/src/components/ui/button.tsx, apps/web/src/components/ui/input.tsx, apps/web/src/components/ChatMarkdown.tsx, apps/web/src/components/chat/MessageCopyButton.tsx, apps/web/src/index.css, scripts/lint-restyle-ceiling.ts
Shared button styles now include aria-disabled cursor and opacity rules, and the glass variant is rounded. Number inputs use text-field appearance and hide WebKit spin buttons. Markdown action buttons and related CSS selectors changed; the lint restyle ceiling is lower.
Browser and application controls
apps/web/src/browser/BrowserDeviceToolbar.tsx, apps/web/src/components/CommandPalette.tsx, apps/web/src/components/CustomSnoozeDialog.tsx, apps/web/src/components/DiffPanel.tsx, apps/web/src/components/GitActionsControl.tsx, apps/web/src/components/ProjectScriptsControl.tsx, apps/web/src/components/ServerUpdateAction.tsx, apps/web/src/components/Sidebar.tsx, apps/web/src/components/onboarding/WelcomeWizard.tsx, apps/web/src/components/projectScriptEditor.tsx, apps/web/src/components/sidebar/SidebarProviderUpdatePill.tsx
Browser, project, command, and onboarding controls use updated button variants and styling. Some controls move hover or focus visibility rules to wrappers. The provider update dismissal control now uses a native button.
Chat, media, and diff controls
apps/web/src/components/ChatView.tsx, apps/web/src/components/chat/AssistantSelectionToolbar.tsx, apps/web/src/components/chat/ContextWindowMeter.tsx, apps/web/src/components/chat/ExpandedImageDialog.tsx, apps/web/src/components/chat/MessagesTimeline.tsx, apps/web/src/components/chat/OpenInPicker.tsx, apps/web/src/components/chat/SnapShotAttachmentDetails.tsx, apps/web/src/components/diffs/DiffCommentAnnotation.tsx, apps/web/src/components/preview/PreviewMoreMenu.tsx
Chat, image, preview, and diff annotation controls have styling and button variant changes. The diff annotation delete control now uses a wrapper for focus and small-screen visibility.
Pull request and settings controls
apps/web/src/components/pullRequest/*, apps/web/src/components/settings/ConnectionsSettings.tsx, apps/web/src/components/settings/KeybindingsSettings.tsx, apps/web/src/components/settings/ProjectActionsList.tsx, apps/web/src/components/settings/ProviderAccentColorPicker.tsx, apps/web/src/components/settings/SettingsSidebarNav.tsx, apps/web/src/components/sidebar/SidebarThreadHeader.tsx
Pull request, settings, and sidebar controls have updated variants, spacing, and text styling. Edit-button visibility styling moved to a wrapper in pull request and project settings controls.

Priority: ⬇️ Low

Estimated code review effort: 3 (Moderate) | ~20 minutes

Change: Refactor

Merge Risk: ⚪ Minimal · up to 32799

The inspected controls remain usable as intended, with no concrete issue requiring a fix before merge. Proceed after normal checks.

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 23.53% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 34 functions across 35 files. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change: Button consumers outside the composer stop applying custom restyling.
Description check ✅ Passed The description clearly explains the changes and motivation, covers the UI updates, and reports validation. It does not use the template headings, include the checklist, or provide required before/aft…
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Comment @coderabbitai help to get the list of available commands.

Clears the 149 shadcn/no-restyle findings on Button outside the chat
composer. No new variant, size, or prop. Two existing Button styles change.

Changes to components/ui/button.tsx:
- glass is now a pill (rounded-full). All three Button consumers
  (Scroll to end, Cite selection, PR review trigger) forced rounded-full,
  so the variant owns it.
- The base now styles aria-disabled like disabled (opacity-64,
  not-allowed cursor). This is a generic state for a disabled control
  that still hosts an explanation popover, and it replaces the hand-rolled
  copy on the git quick action.

Drift, moved onto existing variants and sizes (the visible change is accepted):
- Text-colour tweaks (text-muted-foreground, hover:text-foreground, the
  sidebar muted tokens, text-muted-foreground/60, font-normal) become
  ghost-muted: server update icon and batch action, Add environment,
  message copy (ghost), Show full message, PR sort toggles, settings and
  thread search clear, accent-colour Clear, PR edit pencil.
- Toggle-state tints become variant switches, secondary when pressed:
  device-toolbar aspect lock, markdown table expand and code wrap. This
  deletes the chat-markdown-chrome-action CSS.
- Setup Required chips become warning-outline + micro.
- Padding and size tweaks drop to the size's own padding: ps-[8.5px],
  ps/pe/gap on the palette submit, px-1, and px-0/px overrides on the
  header script actions. Multiline dialog and onboarding rows use
  sm-multiline.
- Hover and background tweaks are deleted: diff collapse, reset zoom,
  PR code collapse, context meter, script icon picker, media navigation
  bg-white/10 and rounded-full. White-on-image snapshot buttons use the
  existing overlay variant.
- Diff-type colour moves from the Button to its chevron icon.

Restructured:
- Reveal on row hover (opacity-0 group-hover:opacity-100) is the row's
  behaviour, so it moves to a plain wrapper span: diff comment delete,
  project actions edit, script menu edit, PullRequestEditButton.
- The sticky device-toolbar close backing, the colour-picker footer
  divider, and the monospace on the when-clause label move to plain
  elements.
- The provider update pill dismiss was not a Button (it inherits the
  pill's tone colour and has no surface of its own), so it is now a
  plain button.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
@juliusmarminge
juliusmarminge force-pushed the restyle/stack-button-rest branch from 4204200 to 327992a Compare September 23, 2026 04:27
@juliusmarminge
juliusmarminge merged commit 71c9b69 into main Sep 23, 2026
23 checks passed
@juliusmarminge
juliusmarminge deleted the restyle/stack-button-rest branch September 23, 2026 04:33
cursor Bot pushed a commit to aaditagrawal/t3code that referenced this pull request Sep 23, 2026
pingdotgg#13208)

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
cursor Bot pushed a commit to aaditagrawal/t3code that referenced this pull request Sep 23, 2026
pingdotgg#13208)

Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
github-actions Bot added a commit to omarcresp/t3code-flake that referenced this pull request Sep 23, 2026
## What's Changed
* hatch/variant functions by @juliusmarminge in pingdotgg/t3code#13191
* refactor(web): context chips render through one ContextChip component by @juliusmarminge in pingdotgg/t3code#13192
* refactor(web): ui components drop their secondary className props by @juliusmarminge in pingdotgg/t3code#13193
* refactor(web): menu triggers and items stop restyling ui/menu by @juliusmarminge in pingdotgg/t3code#13205
* refactor(web): field controls stop restyling Input, Select, Combobox and Command by @juliusmarminge in pingdotgg/t3code#13206
* refactor(web): app code stops restyling sidebar, popover, table and misc ui exports by @juliusmarminge in pingdotgg/t3code#13207
* refactor(web): Button consumers outside the composer stop restyling it by @juliusmarminge in pingdotgg/t3code#13208
* refactor(web): composer controls own their look instead of restyling ui components by @juliusmarminge in pingdotgg/t3code#13209
* chore(web): no-restyle fails lint, and the ceiling gate goes by @juliusmarminge in pingdotgg/t3code#13210
* fix(mobile): recover from screen render errors by @juliusmarminge in pingdotgg/t3code#13197
* feat(web): navigate back and forward with mod+[ and mod+] by @juliusmarminge in pingdotgg/t3code#13212
* fix(web): sort title matches by recent activity by @Yash-Singh1 in pingdotgg/t3code#13219
* test(desktop): remove redundant keyring module-load test by @t3-code[bot] in pingdotgg/t3code#13220


**Full Changelog**: pingdotgg/t3code@v0.0.43-nightly.20260923.2135...v0.0.43-nightly.20260923.2150

Upstream release: https://github.com/pingdotgg/t3code/releases/tag/v0.0.43-nightly.20260923.2150
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L 100-499 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant