Skip to content

fix(web): keep sidebar icons aligned on non-Retina displays - #31323

Open
PixPMusic wants to merge 1 commit into
pingdotgg:mainfrom
PixPMusic:fix/sidebar-navigation-alignment
Open

PixPMusic wants to merge 1 commit into
pingdotgg:mainfrom
PixPMusic:fix/sidebar-navigation-alignment

Conversation

@PixPMusic

Copy link
Copy Markdown
Contributor

Problem

On a non-Retina display, the sidebar toggle and enabled Back arrow render one pixel below the T3 mark and disabled Forward arrow. Their layout boxes are centered, but the enabled buttons have a persistent will-change: scale hint that changes how Chromium rasterizes them. This is visible with 20pt interface text.

Change

Remove the idle scale hint from the shared Button primitive. Its existing pressed scale and transition remain. The logo, enabled buttons, and disabled buttons now align at rest.

This addresses the vertical rendering defect independently of #31125, which moves the history controls to the right edge.

Scope and approval

Alex reported this visible alignment defect and requested the fix. This is a small, focused visual bug fix under the existing exception. The shared Button CSS covers web and desktop controls; native mobile controls, providers, contracts, and connection behavior need no changes.

Verification

  • vp run check:changed passed formatting, lint, both knip checks, affected web/scripts typechecks, and the React Compiler check.
  • Actual macOS Electron app with isolated Demo Studio data, 20pt interface text: matched captures on a physical 1× external display and the built-in 2× Retina display. Removing only the hint corrects the 1× toggle/Back offset. The 2× control centers stay aligned. Also checked zoom level 2 on both displays.
  • Clicked Back to the previous draft and Forward to the same demo thread, checking enabled/disabled states. Collapsed and reopened the sidebar. No cosmetic UI test added; native captures provide the regression proof. Windows and Linux were not exercised.

The comparison below enlarges the original 1× pixels threefold and adds a cyan center guide. Unannotated matched captures follow.

Non-Retina sidebar before and after, with a common center guide

Display Before After
1× external Before: enabled controls render below the logo and disabled arrow After: enabled and disabled controls align with the logo
2× Retina Retina before Retina after, preserving the control centers

Model: GPT-6.1 Sol (xhigh reasoning) | Harness: Codex in T3 Code

@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:XS 0-9 changed lines (additions + deletions). labels Nov 5, 2026
@macroscopeapp

macroscopeapp Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved at bc1a107

Macroscope's review found this PR approvable — Removes a rendering hint from shared button styles to address icon alignment on non-Retina displays. The change is presentation-only and preserves button interactions and product defaults.

You can add or adjust custom eligibility rules. Learn more.

@coderabbitai

coderabbitai Bot commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

Explain Change →

No actionable comments were generated in the recent review.

Walkthrough

The base button styles no longer apply the conditional will-change: scale utility. The active-state scale utility remains.

Changes: Button Styles

Layer / File(s) Summary
Update base button styles
apps/web/src/components/ui/button.tsx
The base button styles remove the conditional will-change: scale utility. The active-state scale utility remains.

Estimated code review effort: 1 (Trivial) | ~3 minutes

Change: Bug fix

Possibly related PRs

  • pingdotgg/t3code#30122: Both changes address button scaling; this PR removes the shared idle will-change: scale hint and retains the pressed scale.

Suggested reviewers: t3dotgg

Merge Risk: Minimal · up to bc1a1

No actionable merge-blocking risk is evident in this focused styling change.

Pre-merge checks: Passed 4

Check name Status Explanation
Title check Passed The title clearly identifies the focused visual fix: keeping sidebar icons aligned on non-Retina displays.
Description check Passed The description includes the required Problem, Change, Scope and approval, and Verification sections. It explains the defect, implementation, scope, test results, limitations, and UI evidence.
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.
Finishing Touches

Generate unit tests (beta)

  • Create a new PR
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts
Recent review info

Run configuration

Commits

Reviewing files that changed from the base of the PR and between 67eebac and bc1a107.

Files selected for processing: 1

  • apps/web/src/components/ui/button.tsx

Included review availability: This review used your included allowance. Your plan provides up to 10 included reviews per hour; 7 remain after this review.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XS 0-9 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