Skip to content

Sidebar: extract 7 hooks and 7 components into src/components/sidebar/ (#1447 pass T) - #1471

Merged
currentbits merged 16 commits into
mainfrom
coder/refactor-t-sidebar-hooks-388695
Oct 5, 2026
Merged

currentbits merged 16 commits into
mainfrom
coder/refactor-t-sidebar-hooks-388695

Conversation

@currentbits

Copy link
Copy Markdown
Owner

Round 6, pass T of #1447. This extracts 7 hooks and 7 stateless components from the Sidebar component body into src/components/sidebar/, one commit each. The state map, plan and reasoning are in docs/superpowers/specs/2026-10-05-sidebar-split.md.

Hooks: useSidebarRows (140 lines), useSidebarShortcuts (104), useThreadSearch (71), useListAnimation (58), useProviderOptions (40), useMoreMenuFocus (36), useStableThreadTitles (27).

Components: FilterBar (484), CreateThreadMenu (271), TrashedShelf (123), ScopeMenu (119), RemoveProjectConfirm (118), InsightsMenu (117), BatchBar (82).

Sidebar.tsx: 3,328 → 2,124 lines.

Checked

  • Effect order: a script lists the component's effects on main, then on this branch with each hook expanded at its call site. Both have the same 14 effects, with the same kind and opening line, in the same order.
  • New components hold no state or refs; they render from props.
    • RemoveProjectConfirm keeps main's removeConfirmId && guard. The old inline projectById lookup / null return now sits inside the component.
    • removeConfirmRef is passed through and attached to the dialog, so useModalFocus / useEscapeClose in the parent still work.
  • Pure move, ignoring indentation: the only non-move lines are hook calls and returns, JSX props, and that guard.
  • Screenshots against main (default, search, filter bar, scope menu, Insights menu, folded rail): three are byte-identical and three differ by YMAX 1, an invisible anti-aliasing difference.
  • npm run typecheck and npx vite build are clean. Renderer suite: 2701/2701, 0 cancelled (TAP count).

🤖 Generated with Claude Code

Willem and others added 16 commits October 5, 2026 13:34
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
…r split plan (#1447)

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@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 5059d43 into main Oct 5, 2026
6 checks passed
@currentbits
currentbits deleted the coder/refactor-t-sidebar-hooks-388695 branch October 5, 2026 12:49
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