OptionalapplyOptional consumer commit hook. When present, moveAction (and other
default actions) submit their committed ops through it instead of
scene.applyBatch, so apps with their own history integration
(checkpoint + push entry) capture the gesture as one undo entry.
When absent, commits fall back to scene.applyBatch.
Area-select dep — AABB hit-test + selection read/write.
Sourced from <SceneCanvas> via AABB overlap over all scene
nodes. Override per-consumer for custom hit-testing (e.g. contain-mode,
lock-aware filtering).
OptionalbooleansBooleans adapter — read selection ids, fetch world-space Paths,
compare z-order, and mint result nodes for Pathfinder ops.
Consumers wire via useBooleansAdapter(adapter) (a thin wrapper
around useDepSource('booleansAdapter', ...)). The descriptor's
enabled predicate reads deps.selection for the count check; the
invoker reads deps.booleansAdapter to execute the op.
OptionalclipboardClipboard dep — the imperative surface useClipboardOps returns.
Published by the consumer (useDepSource('clipboard', …) from under
<SceneCanvas>), because useClipboardOps needs an adapter and a
selection reader only the consumer has. Feeds clipboard.copy /
clipboard.cut; both no-op when the dep is absent.
OptionaldispatcherGesture dispatcher control surface — exposes cancelAll(reason) so
actions that need to abort an in-flight handle (Escape cancels a
drag, etc.) can do so. Sourced by <SceneCanvas> from the
dispatcher instance it already owns.
Edit-anchors dep — narrow read/write of one polygon's path pose.
Sourced from consumer. Wraps getPose/setPose/applyOps
for the currently-being-edited polygon node.
The editAnchorsAction requires this dep to be registered when anchor
editing is active. If absent, start returns an empty handle (no-op).
OptionalgeometryOptional consumer seam for the eager-sync layer: lets pose-transform
actions (resize/move/nudge/flip — NOT rotate) ALSO rewrite a node's
data-held geometry. Given a node and the affine m applied to its pose,
transform(node, m) returns updated data (geometry mapped by m) or
null for nodes with no data-held geometry.
Strictly opt-in: when absent (or when transform returns null), the kit
emits only the pose op and leaves data untouched. apps/draw wires this
to mirror data.path through transformPath. Rotate intentionally never
consults this seam (rotation lives on the pose, baked at render).
Undo/redo history bound to the current scene.
OptionalingestionIngestion dep — canvas viewport rect + consumer file→src resolver.
Sourced from <SceneCanvas> / <StandardActionsRegistrar> via
useIngestionDepSource. Feeds ingestAction with the world-space
viewport rect for paste-placement and image fit-clamping, and forwards
the consumer's optional resolveSrc seam.
Optional: when absent, the ingest action no-ops (there is no
placement geometry to work with).
Insert dep — node factory for drag-to-insert.
Sourced from <SceneCanvas>. The kind param comes from
the active binding's opts.params.kind. Override per-consumer to
provide a typed node factory (e.g. with custom data payloads).
Lasso-select dep — polygon hit-test + selection read/write.
Sourced from <SceneCanvas> / <StandardActionsRegistrar>.
Falls back to AABB hit-test when hitTestLasso is absent.
OptionallayoutLayout-strategy lookup. Sourced by <SceneCanvas> from layouts.
Optional: absent (or all-null) → moveAction skips reflow.
OptionalnodeTopmost node at a world-space point. Sourced by <SceneCanvas> from
the same picker that feeds the tool dispatcher's getNodeAtPoint.
Optional: actions that read this (e.g. moveAction reparent-on-drop)
fall back to a no-op when the dep isn't registered.
Canvas pointer position in world space.
Exposes pointerRef (mutable live ref) and getDropPoint() thunk.
Marked @experimental in the source.
OptionalposeOptional pose-composition strategy for hierarchical (local-pose) scenes. When absent, defaults to IDENTITY (absolute-pose: nodes store world coords). Local-pose consumers supply { compose: composeRectPose, decompose: decomposeRectPose } (or their pose shape's equivalent).
OptionalresizeResize-policy dep — bounds constraints, point-snap behaviors,
group expansion, and pose↔bounds projection for resizeAction.
Optional: when omitted, resizeAction falls back to identity defaults
(no constraints, no snap, identity expandIds, RECT_POSE_DESCRIPTOR).
Consumers wire via useDepSource('resizePolicy', ...) or the
useResizePolicy helper.
Scene tree — structural reads + undoable mutations.
The entry uses the fully-erased form Scene<unknown, string, unknown>
because DepSchema must be concrete. Actions that need a typed scene
should cast: deps.scene as Scene<MyData, MyLayer, MyPose>.
Kit selection state — ids of currently selected nodes.
OptionalsliceSlice dep — consumer-supplied commit for the Slice action.
Receives the finite slice segment in world coordinates; the consumer
scans the scene, splits crossed paths via splitPathByLine, and
applies the result as one undoable batch.
Optional: when absent, sliceAction is a no-op.
OptionalsnapSnap dep — world-space point snapping (grid / guides).
Sourced by <SceneCanvas> from toolOptions.snapPoint. Optional:
absent means no snapping (identity).
Text-edit dep — activates the in-place text editing overlay.
Sourced from consumer via useTextEdit / useSceneTextEdit.
The enterTextEditAction requires this dep to be registered by the text
tool when text editing is available.
The optional isTextNode predicate guards against entering edit mode on
non-text nodes. A binding can pre-filter instead with a
target: 'kind:text:selected' spec; the guard remains for consumers who
bind the broader 'selected-body' target or opted out of routing.
Current viewport — camera position + scale.
Currently active tool id + hotkey-hold stack.