docs: refresh ARCHITECTURE + CLAUDE with this session's work

- Pattern #2 (useNitroQuery): list the eight catalog-layer queries
  carved out of useCatalog this session (gift / groups / club offers /
  pet palette / marketplace / club gifts), plus the new
  useNitroEventInvalidator companion for server-push refresh.
- Note ICatalogOptions deleted — the legacy 'catalogOptions' bag has
  no remaining fields after the migrations, useCatalog no longer
  exposes it.
- New 'useCatalog decomposition (in progress)' table — what's been
  lifted to TanStack and what's deferred (page tree + Builders Club
  status, both core state slices that move with the data/actions
  split).
- Pattern #4 (god-hook split): add the three new splits done this
  session (chat-input doorbell-style, wired-tools singleton-filter,
  translation singleton-filter inline).
- Bump Vitest count 83 → 99 (added 16 cases on the
  useCatalogFavorites helpers).
- Note the pure-module test convention: import from concrete file
  paths rather than the api barrel to avoid jsdom pulling in Pixi.
- Typecheck baseline: client now reports 0 too (was 57 at last
  doc-write); the section's enumerated sweeps all landed.
- CLAUDE.md: bump '77/77' references to '99/99' (both places).
This commit is contained in:
simoleo89
2026-05-11 22:47:35 +02:00
parent 8b79233059
commit 7cf01b0947
2 changed files with 59 additions and 9 deletions
+2 -2
View File
@@ -160,7 +160,7 @@ Login / Register / Forgot in `src/components/login/LoginView.tsx` use
| Zustand | `NavigatorRoomCreatorView` (`useRoomCreatorStore`) |
| God-hook split | `doorbell`, `poll`, `furni-chooser`, `user-chooser`, `friend-request` |
| `WidgetErrorBoundary` | `RoomWidgetsView` umbrella |
| Vitest | 77/77 cases on pure helpers + the Zustand store |
| Vitest | 99/99 cases on pure helpers + the Zustand store |
| Not yet | Notes |
|---|---|
@@ -196,7 +196,7 @@ Fix shapes documented; both are reasonable PRs on their own.
- **Skip-motivated god-hook splits are fine** — when a hook's actions
mutate internal state, document the reason in the commit message and
move on rather than forcing a bad split.
- **`yarn test` must stay green** on every commit. Currently 77/77.
- **`yarn test` must stay green** on every commit. Currently 99/99.
- **Lint baseline**: don't regress. Some pre-existing errors (`FC<{}>`,
`IMessageEvent | undefined` redundant union in the local sandbox where
the renderer SDK isn't installed) are out of scope here.