Repository navigation
feat(ui): make sidebar catalog project groups collapsible - #109648
Conversation
Project group heads in the native session catalogs (Codex + Claude) are now collapse toggles: chevron + aria-expanded, rows hidden while the head and count stay visible. State persists per catalog+host+project through the existing collapsed-sections localStorage set. Follow-up to #109575.
|
Codex review: needs maintainer review before merge. Reviewed July 17, 2026, 12:43 AM ET / 04:43 UTC. Summary PR surface: Source +40, Tests +32, Docs +1. Total +73 across 4 files. Reproducibility: not applicable. This PR adds an agreed sidebar interaction rather than repairing broken behavior under an existing contract. The before-and-after behavior is nevertheless demonstrated through a real Gateway and browser run. Review metrics: 1 noteworthy metric.
Stored data model Merge readiness Overall follows the weaker of proof and patch quality, so missing proof can cap an otherwise strong patch. Next step before merge
Security Review detailsBest possible solution: Land the shared-renderer disclosure implementation after the protected-label maintainer review and exact-head checks complete, keeping the existing opaque collapse-state mechanism and focused browser coverage. Do we have a high-confidence way to reproduce the issue? Not applicable: this PR adds an agreed sidebar interaction rather than repairing broken behavior under an existing contract. The before-and-after behavior is nevertheless demonstrated through a real Gateway and browser run. Is this the best way to solve the issue? Yes. Reusing the shared catalog renderer and existing collapsed-section persistence is narrower and more maintainable than adding catalog-specific state or a parallel preference surface. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning high; reviewed against 7641aa80c23b. Label changesLabel changes:
Label justifications:
Evidence reviewedPR surface: Source +40, Tests +32, Docs +1. Total +73 across 4 files. View PR surface stats
What I checked:
Likely related people:
What the crustacean ranks mean
Shiny media proof means a screenshot, video, or linked artifact directly shows the changed behavior. Runtime, network, CSP, and security claims still need visible diagnostics. How this review workflow works
|
|
Merged via squash.
|
…09648) Project group heads in the native session catalogs (Codex + Claude) are now collapse toggles: chevron + aria-expanded, rows hidden while the head and count stay visible. State persists per catalog+host+project through the existing collapsed-sections localStorage set. Follow-up to openclaw#109575.
…09648) Project group heads in the native session catalogs (Codex + Claude) are now collapse toggles: chevron + aria-expanded, rows hidden while the head and count stay visible. State persists per catalog+host+project through the existing collapsed-sections localStorage set. Follow-up to openclaw#109575.
What Problem This Solves
PR #109575 grouped the native session catalogs (Codex + Claude) by project under each host, but the groups are static headers: a node with many sessions in one busy repo still forces scrolling past all of them to reach the next project. Every other sidebar section (catalogs, pinned, categories) collapses; project groups should too.
Why This Change Was Made
Follow-up agreed in #109575. The project head becomes a collapse toggle reusing the existing section-collapse machinery — no new state surface:
renderCatalogHostGrouprenders each head as a<button>with a chevron andaria-expanded; clicking calls the existingonToggleSectionwith idcatalog-project:<catalogId>:<hostId>:<projectKey>, persisted in the existingopenclaw:sidebar:sessions:collapsed-sectionslocalStorage set.User Impact
Project groups under each node in the Codex/Claude session catalogs now collapse and expand like every other sidebar section, and the collapsed set survives reloads. No config or protocol changes; docs updated in
docs/nodes/index.md.Live proof (real gateway from this branch on a Testbox, real seeded
~/.claude/projectsstore with a worktree session, Chromium via Playwright):openclawcollapsed (live)Evidence
tbx_01kxq4qp88ctde1t04zw50mn8k: built the branch (pnpm build), seeded~/.claude/projectswith three sessions across two projects (one in.claude/worktrees/fix-sidebar), rannode openclaw.mjs gateway --bind loopbackwith a token, drove the real dashboard in Chromium: 2 project heads, worktree folded (openclawcount 2), collapse hid its 2 rows (aria-expanded=false, other project untouched), flatten removed heads with all 3 rows present. Screenshots above are from that run.ui/src/e2e/codex-sessions.e2e.test.ts: collapse hides only that group's rows, head + count persist,collapsed-sectionsstorage gains/losescatalog-project:codex:gateway:local:/Users/dev/openclaw, expand restores. Green on the Testbox alongside scopedrun-oxlint,tsgo:ui, andtsgo:test:ui.node scripts/run-vitest.mjs ui/src/lib/sessions/catalog-project-grouping.test.ts— 12/12 (helper untouched, no regression).