Skip to content

Keep New thread clear of the macOS traffic lights in the narrow sidebar drawer - #5495

Merged
brsbl merged 4 commits into
mainfrom
bb/debug-code-thr_u2zp68t9qb
Oct 15, 2026
Merged

brsbl merged 4 commits into
mainfrom
bb/debug-code-thr_u2zp68t9qb

Conversation

@brsbl

@brsbl brsbl commented Oct 14, 2026 •

Copy link
Copy Markdown
Collaborator

Human comments

What was wrong

In macOS desktop windows narrower than 768px, New thread in the sidebar drawer sits under the traffic lights, and the sidebar toggle draws on top of it (reported on Discord after desktop-v0.46.0). #5229 (ff9484883) moved the navigation rail into the compact drawer and dropped the macOS start inset from SidebarTopReserveRow. The drawer's header row now starts right after the rail, at x=52. That is under the lights (x=18–78), and the sidebar toggle, fixed at x=84–112, overlaps it.

What changed

  • SidebarTopReserveRow (apps/app/src/components/sidebar/SidebarChrome.tsx) pads the drawer's header row so New thread starts at x=116, just after the sidebar toggle. That is where it sat in 0.45.0.
  • The padding applies only on macOS desktop, in the compact drawer (not the framed sidebar), and outside full screen, where there are no traffic lights.
  • Wide framed windows, browsers and other platforms are unchanged. No wire, CLI or contract changes.

How you verified

  • New SidebarChrome.test.tsx: the compact macOS drawer reserves the space, while the framed window and a compact browser window don't. CI failed with only the test (run 38601538235, app-8: "expected false to be true") and passes with the fix.
  • Real Mac (macOS 26.5.2), using the Electron desktop dev app built from main (before) and from this branch (after), with the same seeded thread. The window was resized natively to 700×800 with the sidebar drawer open, and to 1100×800.
    • 700px: New thread moves from x=52–287, under the lights and the toggle, to x=116–287. The hit test at its center returns New thread.
    • 1100px: the framed layout is identical before and after.
  • The colored dots are stand-ins drawn at the traffic lights' native position (18, 18). The native buttons can't be captured without Screen Recording permission.
  • Not covered: a narrow window in native full screen, where the padding is off by design because there are no lights.
  • Remote CI runs the tests; nothing was run locally.
  • CI: every job passes except the plugin SDK npm version guard in Checks. Plugin Fork Check was skipped by change-based selection. The guard fails because @get-bb/[email protected] was published to npm at 15:11 UTC today, and building the SDK from main now produces a different dist/provider-bridge-testing.js. This PR doesn't touch the SDK. Every PR based on current main without a version bump fails the same way (for example Keep native Browser pages when switching servers #5490 and Never strip HTML when saving Docs #5443), and Show the hosting server's version in Updates #5492 passes because it bumps to 0.6.44. It clears once a bump lands on main and this PR's CI reruns.
Screen / state Viewport Before After
Thread · sidebar drawer open (zoom) macOS desktop · 700×800 Before 700 zoom After 700 zoom
Thread · sidebar drawer open macOS desktop · 700×800 Before 700 After 700
Thread · framed sidebar (unchanged) macOS desktop · 1100×800 Before 1100 After 1100

Merge order with "Compact the macOS app frame and move headers into the title bar" (#5529)

Resolved: the PRs can merge in either order. #5495 used to pad the narrow-window drawer header with a literal 88px, which assumed the sidebar toggle sits at the 84px reserve; with #5529's wider reserve New thread would have started under the toggle (measured at an earlier 88px reserve: New thread at x=112 under the toggle at x=88–116). #5495 now includes 5bd8c8b85, which derives that padding from --bb-macos-traffic-light-reserve (falling back to 84px), so New thread starts 4px after the toggle under either geometry. Measured on a real Mac at 700px:

Build Sidebar toggle New thread
#5495 head 5bd8c8b85 on main x=84–112 x=116
#5529 head 96084fc15 + #5495 x=87–115 x=119

BB-Thread-ID: thr_eigbyjruhs

🤖 Generated with Claude Code

AGENT GENERATED

@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Oct 14, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-14T17:26:34.660082Z a068c47 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

brsbl and others added 3 commits October 15, 2026 00:02
#5229 put the navigation rail inside the compact drawer and dropped the
header's macOS start inset, so in windows under 768px New thread sat
under the traffic lights and the sidebar toggle.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@brsbl
brsbl force-pushed the bb/debug-code-thr_u2zp68t9qb branch from 2b1bba5 to fde97d1 Compare October 15, 2026 00:03
The compact macOS drawer padded New thread with a literal 88px, which
assumes the sidebar toggle sits at the 84px reserve. When the traffic
lights move, the toggle moves with --bb-macos-traffic-light-reserve, so
compute the padding from it: New thread starts 4px after the 28px toggle
whatever the reserve, rail padding or control size. Builds that don't set
the reserve keep 84px, so the start stays at x=116 on the current layout.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@brsbl
brsbl merged commit 9e81a24 into main Oct 15, 2026
30 checks passed
@brsbl
brsbl deleted the bb/debug-code-thr_u2zp68t9qb branch October 15, 2026 07:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant