feat(rooms): true sibling-room isolation (Rooms v3) - #99
Conversation
Make data/ a neutral "home" container and every room a self-contained, isolated sibling cabinet (data/<room>/). No room is the parent of another, so Personal and Work never mix. Reverses v2's "root is the default room" direction, which made the root cabinet both a room and the parent of all rooms (isolation could only be faked with a UI filter). - listRooms: only top-level dirs with a .cabinet, excluding the home; plain folders are no longer shown as rooms - /api/rooms returns defaultRoom from data/.home/home.json; the app lands inside the default room (the logo home button is the room switcher) - creation: "Add room" makes an isolated top-level room (kind:room + auto icon/color); the sidebar "New Cabinet" nests inside the current room - per-room search: each room has its own .cabinet.db; pages/agents/tasks scoped by room prefix (cabinet param threaded palette -> API -> daemon) - roll-up never crosses a room boundary (the home rolls up nothing) - switching rooms clears the stale selected page - onboarding scaffolds the first room at data/<slug>/ and writes the home marker; global app config stays at the container (data/.agents/.config) - migration for existing installs: scripts/migrate-rooms-v3.mjs (idempotent, git-checkpointed) - verified per-room theme-on-switch (RoomThemeSync) and multi-window "open in new window" (Electron cabinet:open-window IPC + web window.open) Kept a thin kind:home data/.cabinet so the ~114 "."-as-root call sites resolve to a valid but empty (leak-free) scope instead of a full retire-"." refactor. Docs: ROOMS_WORKSPACES_PRD.md updated to shipped v3; adds ROOMS_V3_TRUE_ISOLATION_PLAN.md (gap analysis + migration spec).
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (20)
📝 WalkthroughWalkthroughThis PR implements Rooms v3, restructuring the Cabinet app from a root-cabinet model to true sibling room isolation. Each room becomes an independent cabinet at ChangesRooms v3 True Sibling Isolation
Estimated code review effort🎯 4 (Complex) | ⏱️ ~60 minutes Possibly related PRs
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Rooms v3 — true sibling-room isolation
Makes
data/a neutral home container and every room a self-contained, isolated sibling cabinet (data/<room>/). No room is the parent of another, so Personal and Work never mix. This reverses v2's "root is the default room" direction, where the root cabinet was simultaneously a room and the physical parent of every other room (isolation could only be faked with a UI filter).What changed
listRooms()returns only top-level dirs with a.cabinet, excluding the home; plain folders are no longer shown as rooms./api/roomsreturnsdefaultRoomfromdata/.home/home.json, and the app lands inside the default room (the logo home button is the switcher).kind:room+ auto icon/color); the sidebar "New Cabinet" nests inside the current room (kind:child)..cabinet.db; pages/agents/tasks scoped by room prefix,cabinetparam threaded palette → API → daemon); roll-up never crosses a room boundary (the home rolls up nothing); switching rooms clears the stale selected page.icon+color+themein its.cabinet;RoomThemeSyncapplies the room theme on switch and on load, with global fallback (verified live).BrowserWindowreusing the backend (cabinet:open-windowIPC +CabinetDesktop.openWindow), web useswindow.open. Each window keeps its own room + theme.data/<slug>/and writes the home marker; global app config stays at the container (data/.agents/.config).scripts/migrate-rooms-v3.mjsfor existing installs — idempotent and git-checkpointed.Note
Kept a thin
kind:homedata/.cabinetso the ~114"."-as-root call sites resolve to a valid but empty (leak-free) scope, instead of a full retire-.refactor.Verification
Model, isolation, theme-on-switch, multi-window, and from-scratch onboarding were all verified via Chrome DevTools + filesystem inspection (see
PROGRESS.md, 2026-05-23).Docs
docs/ROOMS_WORKSPACES_PRD.mdupdated to shipped v3.docs/ROOMS_V3_TRUE_ISOLATION_PLAN.md(gap analysis + migration spec).Summary by CodeRabbit
New Features
Chores
.gitignoreto exclude backup directories.