Add placeholder move history

This commit is contained in:
2026-07-23 22:39:59 +02:00
parent 0a51703315
commit 53282e8c7c
12 changed files with 1106 additions and 160 deletions
+15 -11
View File
@@ -26,18 +26,22 @@ concurrency checks.
The public dispatcher currently supports `circuit.update`, `circuit.insert`,
`circuit.delete`, `circuit-device-row.update`,
`circuit-device-row.insert`, `circuit-device-row.delete` and
`circuit-device-row.move`, all with schema version `1`. Other command types are
rejected. Insert commands contain the complete entity or circuit block with
stable ids; delete commands include the expected parent identity. Circuit
snapshots contain zero, one or multiple complete device rows. Move commands
contain each row's expected and target circuit plus its exact expected and
target sort order. This makes deletion and moves undoable without generating
replacement identities or renumbering circuits. The editor does not consume
these endpoints yet.
`circuit-device-row.move` plus
`circuit-device-row.move-with-new-circuit`, all with schema version `1`. Other
command types are rejected. Insert commands contain the complete entity or
circuit block with stable ids; delete commands include the expected parent
identity. Circuit snapshots contain zero, one or multiple complete device
rows. Move commands contain each row's expected and target circuit plus its
exact expected and target sort order. This makes deletion and moves undoable
without generating replacement identities or renumbering circuits. The editor
does not consume these endpoints yet.
`circuit-device-row.move` currently targets existing circuits in the same
circuit list. Creating a new target circuit while moving rows is not yet part
of the persistent command API.
`circuit-device-row.move` targets existing circuits in the same circuit list.
`circuit-device-row.move-with-new-circuit` atomically creates exactly one
explicitly identified empty target circuit and moves one or multiple existing
rows into it. Its inverse restores every row to its exact prior position and
deletes the generated circuit only if its fields and complete row set still
match the recorded state.
Example: