Conversation
The editor on this branch was a broken mix of TipTap and markdown that did not parse. Restore the textarea editor so documents can be read and typed, matching the existing e2e selectors. Co-authored-by: michael berry <mberrys@users.noreply.github.com>
Replace the hardcoded first-run seed with a SeedPacket registry. An empty workspace offers a picker; planting sprouts docs, opens the packet's panes, and records origin in workspace meta and .rrspace export. Welcome is packet garden/welcome. History seminar, grant shop, and field notes ship as distinct profession packets with extra recipes and prompt addenda. Co-authored-by: michael berry <mberrys@users.noreply.github.com>
Playwright's Welcome to garden name match hit sidebar, tab, and action buttons. Wait for .rr-markdown instead. Co-authored-by: michael berry <mberrys@users.noreply.github.com>
- Extend SeedPacket contract (version, starterBases, links, layout, requires) - Add database doc kind with grid/kanban views and relation fields - Ship comms/campaign proof packet with linked bases and sample rows - Persist seedPacketVersion in workspace meta and .rrspace exports - Complex packet preview and capability gating in picker Refs #8 #18 Co-authored-by: Cursor Agent <cursoragent@cursor.com> Co-authored-by: michael berry <mberrys@users.noreply.github.com>
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 564cfd9d21
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| inverse.push({ | ||
| op: "addField", | ||
| field: removed as unknown as { type: DatabaseField["type"] } & Record<string, unknown>, | ||
| index, | ||
| }); |
There was a problem hiding this comment.
Restore deleted cell values when undoing a field deletion
When deleteField removes a populated column, its inverse records only an addField; the following loop permanently removes every corresponding cell value. Pressing Undo therefore recreates an empty column instead of restoring the document, silently losing user data. Capture the removed values in the inverse or introduce an operation that restores the field and its cells together.
Useful? React with 👍 / 👎.
| export const RelationFieldSchema = z.object({ | ||
| ...fieldCommon, | ||
| type: z.literal("relation"), | ||
| targetDocId: z.string(), | ||
| }); |
There was a problem hiding this comment.
Remap database references when imported document IDs collide
When a bundle containing related database documents is imported into a workspace that already has the same document IDs, importBundle assigns new envelope IDs to the imported copies but does not rewrite RelationField.targetDocId or GardenRef.documentId. The imported bases then silently point to the pre-existing documents rather than their imported counterparts, so restoring a packet into a non-empty workspace corrupts its topology. Build an old-to-new document-ID map and remap these references after parsing all imported documents.
Useful? React with 👍 / 👎.
| const options = | ||
| groupField?.type === "select" ? groupField.options : groupField?.type === "multi_select" ? groupField.options : []; | ||
|
|
||
| const columns = options.length > 0 ? options : ["Unassigned"]; |
There was a problem hiding this comment.
Keep unassigned rows visible in kanban views
For a kanban grouped by a select field with options, columns omits the Unassigned column entirely. A newly added row has no group value, so in the Campaign packet's Pipeline view it disappears from the board as soon as its inspector is closed and cannot be selected again there. Include an unassigned column even when configured options exist.
Useful? React with 👍 / 👎.
| const sprouted = sproutPacket(packet); | ||
| const state = get(); | ||
| const docs = { ...state.docs }; | ||
| const order = [...state.order]; |
There was a problem hiding this comment.
Serialize concurrent packet planting
If the user double-clicks a Plant button, both asynchronous calls capture the same pre-plant workspace before either reaches set(). Each invocation sprouts different document IDs and persists them, while the final in-memory state and saved order contain only whichever invocation finishes last; after reload, the other persisted documents reappear as an extra duplicate packet. Disable planting while it is in flight or serialize the state update and persistence transaction.
Useful? React with 👍 / 👎.
| {listPackets().map((packet) => ( | ||
| <MenuItem | ||
| key={packet.id} | ||
| icon={<Sprout size={14} />} | ||
| onClick={() => void plantPacket(packet.id)} |
There was a problem hiding this comment.
Show complex packet previews from the sidebar
Planting from the sidebar calls plantPacket directly, bypassing the packetNeedsPreview flow used by SeedPacketPicker. Consequently, planting Campaign later in an existing workspace immediately adds all linked bases and artifacts without the promised preview, and requestPacketPicker cannot help because the picker is hidden whenever documents already exist. Route complex sidebar selections through the preview before applying them.
Useful? React with 👍 / 👎.
| for (const baseSeed of packet.starterBases ?? []) { | ||
| const dbDoc = databaseFromSeed(baseSeed, localToId); | ||
| localToId.set(baseSeed.localId, dbDoc.id); |
There was a problem hiding this comment.
Resolve database IDs before building relation fields
A relation field can target any starter base accepted by parseSeedPacket, but each database is built before its own ID and later base IDs are inserted into localToId. Thus a valid packet containing a self-relation or a relation to a base declared later throws an unresolved-target error during sprouting. Allocate IDs for all bases first, then build their fields using the complete map.
Useful? React with 👍 / 👎.
|
Closing as superseded. This branch ( The review comments raised here were real, and I've ported the still-live ones onto main's current code in PR #67 (now merged): deleteField undo restoring cell values, kanban Unassigned column + multi_select grouping, multi_select cell editor, importBundle ref remap, sidebar complex-packet preview, concurrent planting serialize, and sprout forward-reference base ids. |
No description provided.