NF-UI-9: Version diff + revert #339

Closed
opened 2026-04-24 11:29:57 +00:00 by code-lead · 0 comments
Collaborator

As an operator, I want to inspect any past version of a flow, diff it against current, and revert to it so that recovering from a bad edit doesn't require SQL.

Acceptance criteria

Historical view

  • /app/flows/:id/v/:version loads the historical body via GET /flows/:id/versions/:version.

Diff

  • Toggle "Compare to current" → merged canvas view.
  • Color scheme: nodes only in current → green outline; only in :version → red; changed args → amber.
  • Inspector Diff tab surfaces arg-level deltas (JSON keys added / removed / changed) for the selected node.

Revert

  • "Revert to this version" button → POST /flows/:id/revert?version=:version.
  • New version whose body = the selected historical body; version counter bumps; flow_audit mentions source version.

List

  • /app/flows/:id/versions lists every historical version with author, timestamp, diff size (nodes added / removed / modified counts).

Out of scope

  • Cross-flow diff.
  • Collaborative merge conflict resolution.

References

As an operator, I want to inspect any past version of a flow, diff it against current, and revert to it so that recovering from a bad edit doesn't require SQL. ## Acceptance criteria ### Historical view - [ ] `/app/flows/:id/v/:version` loads the historical body via `GET /flows/:id/versions/:version`. ### Diff - [ ] Toggle "Compare to current" → merged canvas view. - [ ] Color scheme: nodes only in current → green outline; only in `:version` → red; changed args → amber. - [ ] Inspector **Diff** tab surfaces arg-level deltas (JSON keys added / removed / changed) for the selected node. ### Revert - [ ] "Revert to this version" button → `POST /flows/:id/revert?version=:version`. - [ ] New version whose body = the selected historical body; version counter bumps; `flow_audit` mentions source version. ### List - [ ] `/app/flows/:id/versions` lists every historical version with author, timestamp, diff size (nodes added / removed / modified counts). ## Out of scope - Cross-flow diff. - Collaborative merge conflict resolution. ## References - Spec: [`specs/node-flows-ui.md`](../src/branch/main/specs/node-flows-ui.md) § Stories § NF-UI-9. - Depends on NF-UI-3 (#333) + NF-7 (#328).
Sign in to join this conversation.
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
charles/claude-hooks#339
No description provided.