feat(flows): NF-UI-5 input-reference picker #356

Merged
code-lead merged 2 commits from dev/335 into main 2026-04-24 14:37:15 +00:00
Collaborator

Floating tree picker for binding a node's input port to an upstream value — operators right-click any input handle to choose a reference instead of typing src.pr.number by hand.

Test plan

  • Right-click on an input handle fires onInputHandleContextMenu in node data → picker opens at cursor position
  • Tree shows upstream nodes → compatible output ports → JSON paths; trigger-type ports use DSL shorthand (src.repo, src.pr.number, …); forge-type ports show base ref + sub-fields; scalars show just the base ref
  • Port-type filtering: incompatible ports hidden; same rule as drag-to-connect
  • Selecting a path writes to nodeInputs, marks editor dirty, round-trips via Ctrl+S → updateFlow
  • Free-form escape hatch: nodeId.field validation, error shown inline, Enter / Set button both fire onSelect
  • Escape and click-outside dismiss the picker
  • Edge binding tooltip: onEdgeMouseEnter shows all inputs bindings on target that reference source node; onEdgeMouseLeave clears it
  • just qa clean — typecheck (4 packages), Biome, 297 web tests + 1562 server tests all pass

Closes #335

Floating tree picker for binding a node's input port to an upstream value — operators right-click any input handle to choose a reference instead of typing `src.pr.number` by hand. ## Test plan - [x] Right-click on an input handle fires `onInputHandleContextMenu` in node data → picker opens at cursor position - [x] Tree shows upstream nodes → compatible output ports → JSON paths; trigger-type ports use DSL shorthand (`src.repo`, `src.pr.number`, …); forge-type ports show base ref + sub-fields; scalars show just the base ref - [x] Port-type filtering: incompatible ports hidden; same rule as drag-to-connect - [x] Selecting a path writes to `nodeInputs`, marks editor dirty, round-trips via Ctrl+S → `updateFlow` - [x] Free-form escape hatch: `nodeId.field` validation, error shown inline, Enter / Set button both fire `onSelect` - [x] Escape and click-outside dismiss the picker - [x] Edge binding tooltip: `onEdgeMouseEnter` shows all `inputs` bindings on target that reference source node; `onEdgeMouseLeave` clears it - [x] `just qa` clean — typecheck (4 packages), Biome, 297 web tests + 1562 server tests all pass Closes #335
feat(flows): NF-UI-5 input-reference picker
All checks were successful
qa / qa (pull_request) Successful in 4m1s
qa / dockerfile (pull_request) Successful in 8s
4acc952b7d
Add `InputRefPicker` — a floating tree picker that opens on right-click
of an input handle, letting operators bind a port to an upstream node's
output via point-and-click rather than hand-typing dotted references.

- `InputRefPicker` component: header (port name + type), tree of
  upstream nodes → compatible output ports → JSON path options,
  free-form escape hatch with `nodeId.field` validation.
- DSL shorthand paths for `trigger`-type ports (`src.repo`,
  `src.pr.number`, …) matching the seed-fixture convention; forge-type
  ports get base ref + common sub-fields; scalars get just the base ref.
- Port-type compatibility filtering mirrors the drag-to-connect rule.
- Selection writes to `nodeInputs`, marks the editor dirty, and
  round-trips through `updateFlow` on save.
- Edge binding tooltip: `onEdgeMouseEnter` aggregates all `inputs`
  bindings on the target node that reference the source, then shows a
  floating tooltip — satisfying the discoverability AC.
- 30 new tests (unit + integration) in `InputRefPicker.test.tsx`.
- Export `PORT_COLORS` from `FlowCanvas.tsx` for downstream consumers.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
dev requested review from reviewer 2026-04-24 13:49:34 +00:00
dev force-pushed dev/335 from 4acc952b7d
All checks were successful
qa / qa (pull_request) Successful in 4m1s
qa / dockerfile (pull_request) Successful in 8s
to d8c49f67cb
Some checks failed
qa / qa (pull_request) Failing after 2m49s
qa / dockerfile (pull_request) Successful in 9s
2026-04-24 13:58:41 +00:00
Compare
fix(web): NF-UI-5 import order for biome (#335 follow-up)
All checks were successful
qa / qa (pull_request) Successful in 5m12s
qa / dockerfile (pull_request) Successful in 9s
1efd03a5cb
Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
code-lead deleted branch dev/335 2026-04-24 14:37:16 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
2 participants
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!356
No description provided.