Skip to content

Archive projects: hidden-project helpers move into their own files - #43

Merged
ziyadakl merged 2 commits into
spec107/integrationfrom
spec107/archive-projects
Nov 3, 2026
Merged

ziyadakl merged 2 commits into
spec107/integrationfrom
spec107/archive-projects

Conversation

@ziyadakl

@ziyadakl ziyadakl commented Nov 3, 2026

Copy link
Copy Markdown
Owner

Part of ziyadakl/tokenmaxxing#116 (spec pingdotgg#107, slice 1). Behaviour unchanged.

Summary

The hidden-project helpers leave Upstream's files and live in three Fork-owned files. Upstream's call sites keep one import each.

 packages/client-runtime/src/
 ├── state/projects.ts               # back to Upstream's content (-37)
 ├── state/projects.test.ts          # renamed
+├── state/archivedProjects.ts       # isProjectArchived, withoutArchivedProjects (moved verbatim)
+└── state/archivedProjects.test.ts  # only the import line changed
 apps/web/src/state/
 ├── entities.ts                     # back to Upstream's content (-11)
+└── archivedProjects.ts             # useUnarchivedProjectsAndThreads
 apps/mobile/src/state/
 ├── entities.ts                     # back to Upstream's content (-16)
+└── archivedProjects.ts             # useUnarchivedProjectsWithThreads, useUnarchivedNavigationProjectsAndThreads
  • packages/client-runtime/package.json: new export ./state/archived-projects (file already edited by the Fork).
  • Import paths changed in Sidebar.tsx, CommandPalette.tsx, useHandleNewThread.ts, DraftHeroHeadline.tsx, ArchivedProjectsSection.tsx, mobile HomeRouteScreen.tsx and ThreadNavigationSidebar.tsx. Call lines are untouched.
  • CommandPalette.tsx: useServerConfigs back in Upstream's import order; comment shortened to one line.
  • CUSTOM.md row names the new files.
  • Migration 076's guard and its test are unchanged (a database from the old Fork step already has archived_at).
  • Sidebar.tsx: only the import line changed. The useSidebarLookups call is left for the machine-filter slice.

Footprint (Upstream files the Fork edits, MB=8657eecb28bc, --diff-filter=MD):

Files Lines
Before (spec107/integration) 181 +13,889 −2,908
After 178 +13,827 −2,906
The 11 files this feature touches, before 11 +547 −84
Same files, after 8 +481 −82

(The 11-file counts include other features' hunks in Sidebar.tsx and CommandPalette.tsx.) git diff MB HEAD -- packages/client-runtime/src/state/projects.ts apps/web/src/state/entities.ts apps/mobile/src/state/entities.ts is empty.

Evidence

  • Before: projects.test.ts, 2 tests, green on spec107/integration.
    After: the same tests as archivedProjects.test.ts (import line only), run with fnm exec --using=24 on Node 24:
    • client-runtime archivedProjects.test.ts: 2/2
    • server 076_ProjectionProjectsPinArchive.test.ts: 2/2
    • web CommandPalette.logic.test.ts, the three CommandPalette*.browser.test.tsx, useHandleNewThread.test.ts: 55/55
    • vp check: 0 errors (4 warnings, none in touched files). vp run knip:check: pass. tsc --noEmit in client-runtime, web and mobile: clean.
  • No interface test was added: the only gap (nothing checks that the sidebar, palette or mobile Home hide an archived project's threads) is the same as before the move.

Merge Danger

Door: two-way. Moves code between files; a revert restores the old layout.

Blast Radius: Sidebar, palette, new-thread picker and mobile Home/thread list (all archived-project hiding)

The next sync can clash at Sidebar.tsx and DraftHeroHeadline.tsx, which Upstream also edited since the merge base. The machine-filter slice absorbs the remaining Sidebar.tsx archive call.

🤖 Generated with Claude Code

withoutArchivedProjects/isProjectArchived, the web hook and the two mobile hooks
leave Upstream's projects.ts and entities.ts files, which return to Upstream's
content. Behaviour is unchanged. Migration 076's guard stays.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions github-actions Bot added size:L vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. labels Nov 3, 2026
@ziyadakl
ziyadakl merged commit eeca0d0 into spec107/integration Nov 3, 2026
27 checks passed
@ziyadakl
ziyadakl deleted the spec107/archive-projects branch November 3, 2026 08:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants