Skip to content

Sidebar decluttering: denser thread cards, per-group overflow cap, sticky group headers - #71

Merged
currentbits merged 2 commits into
mainfrom
coder/we-need-to-look-at-the-sidebar-when-we-h-aac079
Aug 16, 2026
Merged

currentbits merged 2 commits into
mainfrom
coder/we-need-to-look-at-the-sidebar-when-we-h-aac079

Conversation

@currentbits

@currentbits currentbits commented Aug 16, 2026 •

Copy link
Copy Markdown
Owner

Why

With several projects and many threads per project, the sidebar got hard to scan: every attention thread rendered as a ~90–110px card with no per-group limit, each card repeated the project slug already shown in the group header, and tag pills (provider/ssh/worktree) occupied a full row per card. The existing shelf model (pinned / snoozed / settled tail) is deliberate and stays untouched — this PR attacks density inside the attention groups only. Tracked as #70.

What changed

  • Slimmer thread cards (src/components/Sidebar.tsx): ThreadCard gains a showSlug prop — the slug row renders only for orphan groups (which have no project header to carry it) and standalone renders. The tag pills merge into the card's top row next to the relative age, so a card goes from 4 rows to 3 (~65–85px). All existing class names and data-* hooks are preserved.
  • Per-group overflow cap (src/sidebarGroups.ts, Sidebar.tsx): GROUP_ATTENTION_CAP = 8 — a group renders its newest 8 attention threads (static createdAt order means the oldest hide, so fresh work is always visible). A session-only "Show N more / Show fewer" disclosure (reusing the settled-tail .settledShowMore style) expands the rest. Carve-out: the active or freshly-revealed thread extends the slice so the open thread never vanishes. Search bypasses the cap, consistent with search bypassing collapse and shelves.
  • Keyboard nav stays in sync (src/sidebarSelection.ts): buildVisibleThreadIds applies the identical capped slice via the shared pure visibleAttentionCount helper, so cmd+1..9 and cmd+j/k mirror the render exactly.
  • Sticky group headers (Sidebar.module.css): .groupHeaderRow is position: sticky with an opaque var(--bg-elevated) background, keeping project context visible while scrolling long groups.

Explicitly not changed

Settled tail (10/25 paging, global, expanded-by-default), snoozed/pinned shelves, partition precedence, collapse persistence keys, collapse-all semantics, archived toggles, remove-project confirm, batch bar, and createdAt ordering.

Verification

  • 15 new tests: cap constant pinned (sidebarGroups.test.ts), capped-slice mirroring incl. carve-out and search bypass (sidebarSelection.test.ts), render behavior — cap disclosure, active-thread carve-out, search uncapped, orphan-slug rule (sidebar.test.tsx). All 69 pre-existing sidebar tests pass unchanged.
  • Renderer 664/664, core 38/38, memory 119/119, tsc --noEmit clean.
  • Note: the electron suite has 9 pre-existing failures on this branch (orch-server allowedTools, worktrees gh PR); electron/ imports none of the touched files. No live visual pass was done — the sticky header and merged tag row are worth an eyeball on a narrow sidebar.

Closes #70

  • PR created by the Kimi Code agent

Willem and others added 2 commits August 15, 2026 22:06
@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.

@currentbits
currentbits merged commit e3666b5 into main Aug 16, 2026
1 check failed
@currentbits
currentbits deleted the coder/we-need-to-look-at-the-sidebar-when-we-h-aac079 branch October 3, 2026 16:07
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 decluttering: card density + per-group overflow cap

1 participant