Repository navigation
feat(sidebar): filter workspaces and agents by label without hiding the selection - #1851
Conversation
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 16 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
Merge pass review-work for b90cec1: REVIEW FAILED on one fold case. Everything else passed. Blocker: opening a worktree from its dialog while the filter is on erases the saved fold.
Checked and passing:
Non-blocking:
|
|
Fixed the blocker in db2980e.
Non-blocking notes:
|
|
Merge pass: held. "Browser regression (ui-regression)" and "Integration and browser" fail on db2980e, and the failure comes from this PR.
await page.keyboard.press("Escape");
assert.equal(await page.getByRole("search").count(), 0);The check expects no Pick whichever fits the design:
Two |
|
Merge pass: one rebase needed. #1874 is merged on main. |
A filter field above the sidebar's lists narrows the PC, workspace and agent rows to the ones whose labels match the command palette's fuzzy matcher, in herdr's order with their pins and folds. The selected pane's row and the rows over it stay, drawn as context and marked Selected. The query is never stored and clears on Escape, the clear button, closing the phone drawer or a reload. Reordering waits until the filter is cleared. Ported onto current main from the local feat/sidebar-label-filter branch (7 commits): the drawer's Escape now lives in useSidebarLayout, the filter's strings in the machines i18n parts, and "Selected" moved to the base dictionaries since the palette and the sidebar both use it.
The reorder coordinator draws its own order while a move lands, so a worktree can sit under a head the filter did not keep (it read herdr's order). The group now stays when one of its children is kept, its head drawn as context, instead of the match disappearing.
…ns under the filter Opening a checkout from a group's Open worktree dialog wrote the group's saved fold open even while the filter was on, so clearing the filter left a group the user had folded expanded. The dialog now opens the group through the same path as its caret: for the filter's time only while a filter is on, and as the saved fold otherwise. The filter demo opens a checkout under the filter on desktop and phone, clears it, and checks the saved fold is back.
…ind check to the find bar The sidebar filter adds a search landmark that stays on the page, so the pane-find regression's check that no search landmark is left once the find bar closes always counted one. The check now looks for the find bar's own landmark, and the filter's landmark carries its own name so the two can be told apart.
|
Rebased onto main (4c8ce30, with #1874) and fixed the CI failure.
|
db2980e to
5b0584b
Compare
|
Merge pass review-work report. Overall: PASSED.
QA
Behaviour
Round 1 finding, fixed in db2980e: opening a worktree from its dialog while filtering now uses the temporary fold. The saved key stays
Follow-ups (MINOR)
All required checks are green and no review thread is open. CodeRabbit did not review this PR (rate-limited or skipped). The reviews above stand in for it. |
What it does for the user
A Filter field sits above the sidebar's lists. Typing narrows the PC, workspace and agent rows to the ones whose labels match, using the command palette's fuzzy matcher. Rows keep herdr's order, their PC, group, card, pins and folds.
The design is explained in DESIGN.md (Sidebar roster row and footer). Search as in finding anything and acting on it stays in the command palette, as in the Codex and Claude apps. This filter only narrows the lists in place by the words the rows show (maintainer-approved in #1043). The idea of keeping a row when it, a header above it or a row below it matches is adapted from agent-of-empires and credited in THIRD_PARTY_NOTICES.md.
Why this PR
This is the local
feat/sidebar-label-filterbranch (7 commits), cut about 180 commits behind main and never pushed, ported onto current main:src/lib/useSidebarLayout.ts.src/lib/i18n/machines.*parts. "Selected" moved from the palette parts to the base dictionaries, since the palette and the sidebar both use it now.drawerOpenprop passes through main'sReorderContextwrapper.ovis:*storage keys, and the browser lane counts 84 scripts.How it was verified
bun run check fast: pass on b90cec1 (unit: 455 test files). An earlier run under heavy load had one unrelated failure,server/rpc-diagnostics.test.ts(3 requests counted instead of 4); this branch touches nothing inserver/, and the test passes on its own 3/3.src/lib/sidebarFilter.test.ts(8 tests, including the reorder case, which failed before the fix), plus the i18n, palette search and browser-lane tests: all pass.bun scripts/sidebar-filter-demo-regression.tson the demo: 26/26 scenarios pass at 390 and 1440 px, dark and light, plus Korean (90 screenshots underUI_EVIDENCE_DIR).Known follow-ups (from review, MEDIUM/LOW, kept out to hold the original scope)
onDropreturns beforepreventDefault).