Skip to content

Add sidebar lifecycle filters and drafts - #2421

Open
brsbl wants to merge 11 commits into
bb/sidebar-draft-slots-thr_2e2gbjx943from
bb/sidebar-lifecycle-drafts-search-thr_2e2gbjx943
Open

Add sidebar lifecycle filters and drafts#2421
brsbl wants to merge 11 commits into
bb/sidebar-draft-slots-thr_2e2gbjx943from
bb/sidebar-lifecycle-drafts-search-thr_2e2gbjx943

Conversation

@brsbl

@brsbl brsbl commented Aug 25, 2026

Copy link
Copy Markdown
Collaborator

What was wrong

The built-in sidebar thread list represented only active server threads. Client-local new-thread drafts disappeared from navigation after leaving a composer, archived threads were available only through Settings, and the client had no count-only archived read for showing lifecycle totals without fetching archived rows.

What changed

  • Adds a session-local Show checkbox group for Active, Drafts, and Archived, with live counts, Active as the launch default, and reset-on-launch behavior.
  • Renders client-local draft rows in the built-in list's top cluster, re-enters a draft only from its row, preserves its submit destination, removes empty/submitted drafts, and shows Saved to Drafts once when navigating away from a non-empty composer.
  • Adds a contiguous trailing archived group with incremental paging, archived-row navigation and unarchive actions, and an empty-filter state.
  • Adds the smallest count-only server/SDK read for active or archived threads, so the Show menu can display archived totals without loading archived rows.
  • Keeps drafts and preferences entirely client-local, leaves plugin-rendered composers and experimental_threadList replacement rendering unchanged, and deliberately defers search to its future command-palette layer.
  • Does not change the host-daemon wire protocol or add server-side draft state.

Before — parent PR #2404 (e503e4d35)

The built-in list has no lifecycle controls and exposes neither local drafts nor archived threads.

Before — no lifecycle filter or draft/archive rows

After — this PR (b971bd795)

The same fixture and 1440×900 viewport show the Draft top cluster, Active rows, trailing Archived group, and the Show menu with all three live counts.

After — lifecycle filter with draft, active, and archived rows

How you verified

  • Phase 2 focused regressions: app 73, server routes 80, database 53, SDK 51, and server-contract 35 tests passed (292 total).
  • pnpm exec turbo run typecheck --force: 76/76 tasks passed under Node 22.22.1.
  • pnpm exec turbo run lint --force: 2/2 tasks passed; only existing warnings remained.
  • pnpm exec turbo run test --force: 69/75 tasks passed. The changed app, server-route, database, SDK, and contract coverage passed; the remaining failures were outside this diff in provider recorded-replay parity and plugin-build /tmp path normalization, plus two server timeout cases that passed together on immediate direct rerun (33/33).
  • Chrome for Testing 151.0.7922.71 and Safari 26.5.2: passed first paint, hard reload, client navigation, five menu cycles, lifecycle reset, draft toast, archived unarchive/empty state, light/dark/system themes, and exact mobile/small/desktop/very-wide plus breakpoint-adjacent widths with no overflow or console errors.

BB-Thread-ID: thr_2e2gbjx943

AGENT GENERATED

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.

1 participant