Skip to content

Restore sidebar quick-action order on parent threads - #6088

Merged
brsbl merged 5 commits into
mainfrom
restore-sidebar-quick-action-order
Oct 22, 2026
Merged

brsbl merged 5 commits into
mainfrom
restore-sidebar-quick-action-order

Conversation

@brsbl

@brsbl brsbl commented Oct 21, 2026 •

Copy link
Copy Markdown
Collaborator

Human comments

What was wrong

Parent rows measured the space beside their disclosure arrow and shifted quick actions left when titles were long. This put Archive before the arrow and moved it out of alignment with leaf rows.

What changed

  • Parent rows reserve quick-action space and keep the order arrow, Archive, then “…” on hover.
  • Archive and “…” remain in the same columns across parent and leaf rows.
  • Long parent titles truncate about 30px earlier at rest.

How you verified

  • One-off Chromium measurements found main’s 28px Archive shift at 220, 288, and 360px. Baseline run
  • The same one-off measurement passed with the revert. Revert run
  • A standalone DevBrowser check also failed on main and passed all 18 row/width cases on 95d2dcc382.
  • The standalone check verifies short/long leaves and collapsed/expanded parents; Archive and menu columns align at every width.
  • Isolated Chromium checks passed hover order, disclosure persistence, keyboard menus, navigation, and Archive recovery on 95d2dcc382.
  • Remote CI passed on 95d2dcc382, including the parent order/reserved-space unit coverage.

Desktop web, 1440 × 900 viewport, default 320px sidebar, captured at 2×. Before uses main’s row implementation (d9912408c2); after uses 95d2dcc382.

State Before After
Hovered long-title parent Before: Archive appears before the arrow After: arrow, Archive, then menu

Fixes #5909

BB-Thread-ID: thr_b5w9teuwgi

AGENT GENERATED

@brsbl
brsbl marked this pull request as ready for review October 21, 2026 23:26
@chatgpt-codex-connector

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 ⚠️ Failed 2026-10-21T23:26:27.450756Z
We couldn’t complete this review. Comment @codex review to try again.
a429cff Draft marked ready
ℹ️ 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.

@chatgpt-codex-connector

Copy link
Copy Markdown

You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard.
To continue using code reviews, add credits to your account and enable them for code reviews in your settings.

@brsbl
brsbl merged commit 831f743 into main Oct 22, 2026
42 checks passed
@brsbl
brsbl deleted the restore-sidebar-quick-action-order branch October 22, 2026 01:14
alexandre-vl added a commit to alexandre-vl/bb that referenced this pull request Oct 22, 2026
With provider icons off, the toggle hung 16 px left of the title. A
top-level row has 8 px of left padding, so the chevron sat on the
sidebar's edge, half outside the row: the hover, selected and focus
highlights cut it in two, and the chevrons of rows scrolled under a
sticky project header showed beside and above it.

Without an icon slot, the disclosure now follows the title, before the
count, and the row reserves the quick-action space as on main (get-bb#6088),
so the chevron stays still on hover and Archive keeps its column.
Rows with a provider icon keep the icon-slot toggle and the leaf
geometry.
alexandre-vl added a commit to alexandre-vl/bb that referenced this pull request Oct 22, 2026
Without provider icons, a parent's toggle hung 16 px left of its title,
half outside its row: the hover, selected and focus highlights cut it in
two, and the chevrons of rows scrolled under a sticky project header
showed beside it.

The disclosure now sits in a 16 px slot at the start of the row, 2 px
inside the row's left edge and 2 px before the title. Every thread row
keeps that slot while icons are hidden, so leaf and parent titles line
up and nothing shifts when a parent appears or goes away. Sub-thread
guide lines, including the segment a sticky parent draws for its own
parent, run through the chevron's center. Parents keep the quick-action
space reserved, so the count stays still on hover and Archive keeps its
column as on main (get-bb#6088). Rows with provider icons keep the icon-slot
toggle.

The Action alignment story now hides provider icons, so its check no
longer depends on whether a dev server answers the providers request.
The check also asserts that the disclosure leads the title inside its
row, that titles line up, and that sub-thread guides meet the chevron.
ymichael added a commit that referenced this pull request Nov 23, 2026
## Human comments

## What was wrong

In the sidebar, a parent thread row with children always reserved the
full quick-action width (30 px per configured action) on its right edge.
The 26 px slot of its disclosure chevron stayed reserved too, also when
the chevron was hidden at rest.

#6088 added this reserve to fix #5909: it keeps the chevron still on
hover, so Archive cannot appear where the chevron was. But an expanded
parent hides its chevron until hover, so there is nothing to keep still
at rest. Its title still truncated 56 px (1 action) to 116 px (3
actions) earlier than a leaf title. [Reproduction
report](https://get-bb.github.io/reports/issues/8053.html).

## What changed

`plugins/thread-list/app/rows/ThreadRow.tsx`:

- Only collapsed parents keep the permanent reserve, because their
chevron shows at rest. Expanded parents use the hover-only inset, the
same as leaf rows.
- At rest, the hidden chevron of an expanded parent goes out of the
layout flow (`absolute`). It comes back into the flow under the same row
states that apply the inset: hover, keyboard focus, or an open actions
menu. It stays focusable, so Tab from the row link still goes to the
chevron. Touch screens (`hover: none`) do not change.

This is a partial fix for #8053. Collapsed parents still reserve the
space. A full fix needs the chevron at the leading edge of the row.

The table compares three layouts, each built and measured in Chromium.
It shows the title width at rest in a 288 px sidebar, with a long title
and provider icons on. The leaf title is 210 px.

| Layout | Expanded parent | Collapsed parent |
|---|---|---|
| main | 154 px (1 action), 94 px (3 actions) | 154 px, 94 px |
| A: reserve only on collapsed parents (this PR) | 210 px | 154 px, 94
px |
| B: chevron before the title | 190 px | 190 px |
| C: chevron in the provider icon slot | 210 px | 210 px |

In all three layouts, Archive and the menu stay in the leaf columns and
the chevron does not move on hover. A is the closest to how the app
works now. Every expandable row (project headers, environment groups,
sidebar sections, timeline disclosures) keeps the chevron right after
its label. B and C also fix collapsed parents, but they add a new
pattern. With C, a collapsed parent also does not show its provider
icon. B or C can follow in a separate PR if the maintainer prefers.

No wire, SDK, CLI or setting change.

## How you verified

- `ThreadRow.test.tsx`: the test "reserves quick-action space after
parent disclosure" now asserts that a collapsed parent keeps the
permanent padding and an expanded parent uses the hover-only inset. The
expanded case fails on main (`expected true to be false`) and passes
with this change.
- `pnpm exec turbo run typecheck test lint
--filter=bb-plugin-thread-list`: typecheck passes. Lint has 0 errors.
Its 6 warnings are also on main. Tests: 460 of 460 pass. On Node 26,
`app.test.tsx` "keys its slot and preferences mirror" fails because
Node's own `localStorage` replaces the jsdom one. It passes with
`NODE_OPTIONS=--no-experimental-webstorage`. CI uses Node 22.
- Browser check in Chromium with hover. The rows are real `ThreadRow`
DOM from the test harness, with the built app CSS and thread-list plugin
CSS. Sidebar width 288 px, depth 0, 1 and 3 actions, provider icons on
and off. Positions are from the left edge of the row:

| Row (1 action, icons on) | main: title at rest | This PR: title at
rest | Chevron x on hover | Archive x on hover | Space from chevron to
Archive |
  |---|---|---|---|---|---|
  | Leaf, long title | 210 | 210 | - | 220 | - |
  | Expanded parent | 154 | 210 | 192 (main 192) | 220 | 8 px |
  | Collapsed parent | 154 | 154 | 192 (main 192) | 220 | 8 px |
  | Sticky expanded parent | 154 | 210 | 192 (main 192) | 220 | 8 px |

With 3 actions: expanded parent 94 px to 210 px, chevron at 132 px,
Archive at 160 px, 8 px between them. With provider icons off: expanded
parent 178 px to 234 px (1 action) and 118 px to 234 px (3 actions).
- In every case the row height is 28 px at rest and on hover, and the
menu is at 250 px.
- A click at the visible chevron of a collapsed parent hits Expand.
- Keyboard focus on the row link and an open actions menu both show the
chevron and apply the inset. Tab from the link goes to the chevron, then
Archive, as on main.
- Rename mode is the same as on main: 246 px input, chevron hidden, no
padding.
- Not checked: WebKit, the packaged desktop app, touch devices with a
real pointer.

Fixes #8053

> AGENT GENERATED

---------

Co-authored-by: Michael Yong <[email protected]>
Co-authored-by: Claude Opus 5.5 <[email protected]>
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.

Sidebar: Archive moves and sits 2 px from the expand chevron on rows with sub-threads

1 participant