Commit 30e9b99
authored
🤖 fix: sidebar layout — tighter indentation, always-visible actions, aligned status dots (#3124)
## Summary
Overhauls the left sidebar layout to maximize horizontal real estate:
actions always stay visible, group labels (A/B/C for best-of-n, variant
names) never truncate, and status dots align directly with project
folder icons — eliminating the vertical connector line.
## Background
Three issues with the sidebar at narrow widths:
1. Action buttons (kebab menu, + button) got clipped by
`overflow-hidden` and Radix's `display: table` inner wrapper
2. Variant/best-of-n indicators truncated away since they were part of
the title text
3. Excessive left indentation wasted space, especially at deeper nesting
levels
## Implementation
**Radix ScrollArea fix** — The root cause of button clipping was Radix
ScrollArea's internal `<div style="display: table; min-width: 100%">`
wrapper. Table auto-layout sizes to max-content (full untruncated title
width), expanding beyond the viewport. Combined with 4 layers of
`overflow-hidden`, right-aligned buttons got pushed past the clip
boundary. Fixed with a global CSS override:
`[data-radix-scroll-area-viewport] > div { display: block !important;
min-width: 0 !important; }`.
**Status dot ↔ project icon alignment** — Removed the vertical connector
line between project headers and workspace lists. Adjusted
`getItemPaddingLeft` base from 4→10px so the status dot center (10px +
8px/2 = 18px) aligns with the project folder icon center (pl-2 8px +
h-5/2 10px = 18px). Dropped workspace row margins from `ml-4`/`ml-5.5`
to `ml-0`/`ml-2`.
**Group labels as badges** — Split the variant/best-of label out of the
truncated title string into a separate `shrink-0` span. Best-of-n
candidates now get alphabetical labels (A, B, C…) derived from their
index.
## Risks
Low — all changes are CSS/layout. The Radix `display: table` override is
the broadest change, but ScrollArea is only used in ProjectSidebar so
impact is contained. Sub-agent connector lines (SVG elbows, trunk
segments) are untouched and still use absolute positioning relative to
`paddingLeft`.
---
_Generated with `mux` • Model: `anthropic:claude-opus-4-6` • Thinking:
`xhigh` • Cost: `$13.11`_
<!-- mux-attribution: model=anthropic:claude-opus-4-6 thinking=xhigh
costs=13.11 -->1 parent 3102607 commit 30e9b99
File tree
5 files changed
+44
-27
lines changed- src/browser
- components
- AgentListItem
- ProjectSidebar
- SectionHeader
- styles
5 files changed
+44
-27
lines changedLines changed: 22 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
125 | 125 | | |
126 | 126 | | |
127 | 127 | | |
128 | | - | |
| 128 | + | |
| 129 | + | |
| 130 | + | |
129 | 131 | | |
130 | 132 | | |
131 | | - | |
| 133 | + | |
132 | 134 | | |
133 | 135 | | |
134 | 136 | | |
| |||
314 | 316 | | |
315 | 317 | | |
316 | 318 | | |
317 | | - | |
| 319 | + | |
318 | 320 | | |
319 | 321 | | |
320 | 322 | | |
| |||
470 | 472 | | |
471 | 473 | | |
472 | 474 | | |
473 | | - | |
474 | | - | |
475 | | - | |
| 475 | + | |
| 476 | + | |
| 477 | + | |
| 478 | + | |
| 479 | + | |
| 480 | + | |
| 481 | + | |
476 | 482 | | |
477 | | - | |
| 483 | + | |
478 | 484 | | |
479 | 485 | | |
480 | 486 | | |
| |||
687 | 693 | | |
688 | 694 | | |
689 | 695 | | |
690 | | - | |
| 696 | + | |
| 697 | + | |
| 698 | + | |
691 | 699 | | |
692 | 700 | | |
693 | 701 | | |
| |||
1014 | 1022 | | |
1015 | 1023 | | |
1016 | 1024 | | |
| 1025 | + | |
| 1026 | + | |
| 1027 | + | |
| 1028 | + | |
| 1029 | + | |
1017 | 1030 | | |
1018 | 1031 | | |
1019 | 1032 | | |
| |||
1022 | 1035 | | |
1023 | 1036 | | |
1024 | 1037 | | |
1025 | | - | |
| 1038 | + | |
1026 | 1039 | | |
1027 | 1040 | | |
1028 | 1041 | | |
| |||
Lines changed: 5 additions & 12 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1941 | 1941 | | |
1942 | 1942 | | |
1943 | 1943 | | |
1944 | | - | |
1945 | | - | |
| 1944 | + | |
1946 | 1945 | | |
1947 | 1946 | | |
1948 | 1947 | | |
| |||
1967 | 1966 | | |
1968 | 1967 | | |
1969 | 1968 | | |
1970 | | - | |
| 1969 | + | |
1971 | 1970 | | |
1972 | 1971 | | |
1973 | 1972 | | |
| |||
2081 | 2080 | | |
2082 | 2081 | | |
2083 | 2082 | | |
2084 | | - | |
2085 | | - | |
2086 | | - | |
2087 | | - | |
2088 | | - | |
2089 | | - | |
2090 | | - | |
2091 | | - | |
2092 | | - | |
| 2083 | + | |
| 2084 | + | |
| 2085 | + | |
2093 | 2086 | | |
2094 | 2087 | | |
2095 | 2088 | | |
| |||
Lines changed: 3 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
28 | | - | |
| 28 | + | |
29 | 29 | | |
30 | 30 | | |
31 | 31 | | |
| |||
56 | 56 | | |
57 | 57 | | |
58 | 58 | | |
59 | | - | |
| 59 | + | |
60 | 60 | | |
61 | 61 | | |
62 | 62 | | |
| |||
72 | 72 | | |
73 | 73 | | |
74 | 74 | | |
75 | | - | |
| 75 | + | |
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
| |||
Lines changed: 4 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
107 | 107 | | |
108 | 108 | | |
109 | 109 | | |
110 | | - | |
| 110 | + | |
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
| |||
180 | 180 | | |
181 | 181 | | |
182 | 182 | | |
183 | | - | |
184 | | - | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
185 | 186 | | |
186 | 187 | | |
187 | 188 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2193 | 2193 | | |
2194 | 2194 | | |
2195 | 2195 | | |
| 2196 | + | |
| 2197 | + | |
| 2198 | + | |
| 2199 | + | |
| 2200 | + | |
| 2201 | + | |
| 2202 | + | |
| 2203 | + | |
| 2204 | + | |
| 2205 | + | |
2196 | 2206 | | |
2197 | 2207 | | |
2198 | 2208 | | |
| |||
0 commit comments