v4.13.19
- fix(jsx): render an async component that returns null, a boolean, or a number in https://github.com/honojs/hono/pull/5594
- fix(jsx/dom): align useActionState with React 19 in https://github.com/honojs/hono/pull/5635
- fix(jsx/dom): reset a form's pending state when its action rejects in https://github.com/honojs/hono/pull/5636
- fix(jsx/dom): keep an ErrorBoundary in sync when its parent re-renders in https://github.com/honojs/hono/pull/5638
- fix(jsx/dom): keep keyed components in order when they update with a reorder in https://github.com/honojs/hono/pull/5637
- fix(bun): pass errors thrown in WebSocket handlers to onError in https://github.com/honojs/hono/pull/5620
- fix(proxy): drop Transfer-Encoding and Keep-Alive from the headers option in https://github.com/honojs/hono/pull/5640
- fix(method-override): drop the body when overriding to GET or HEAD in https://github.com/honojs/hono/pull/5641
- fix(jsx/dom): restore attributes and effects when Suspense children suspend again in https://github.com/honojs/hono/pull/5642
- fix(combine): continue the chain when a Condition returns true in every() in https://github.com/honojs/hono/pull/5392
- docs: fix JSDoc parameter types and missing annotations in middleware and helpers in https://github.com/honojs/hono/pull/5409
- fix(jsx/dom): keep a falsy Suspense fallback in https://github.com/honojs/hono/pull/5644
- fix(lambda-edge): omit body in a 204 result in https://github.com/honojs/hono/pull/5643
- fix(utils/types): stop JSONParsed at a recursive JSON type in https://github.com/honojs/hono/pull/5645
- feat(secure-headers): add an overwrite option in https://github.com/honojs/hono/pull/5634
- feat(jwt): add a typ option to verify the token header in https://github.com/honojs/hono/pull/5639
Full Changelog: https://github.com/honojs/hono/compare/v4.13.18...v4.13.19
@xyflow/vue@2.0.0
-
#5891
ca9c2fb-ConnectionLineTypeandPanelPositionare now re-exported from@xyflow/system, matching@xyflow/reactand@xyflow/svelte.- The value of
ConnectionLineType.SimpleBezierchanged from"simple-bezier"to"simplebezier". Using the enum is unaffected; update raw"simple-bezier"strings. - The
PanelPositionenum and thePanelPositionTypeunion are replaced by thePanelPositionstring union (e.g."top-left"). It also accepts"center-left"and"center-right".
- The value of
-
#5891
ca9c2fb- Rename container classes to match@xyflow/reactand@xyflow/svelte. Update custom CSS or DOM queries that use them:.vue-flow__transformationpane→.vue-flow__viewport.vue-flow__viewport→.vue-flow__renderer.vue-flow__edge-labels→.vue-flow__edgelabel-renderer
-
#5891
ca9c2fb- Use the same CSS variables and stylesheets as@xyflow/reactand@xyflow/svelte.--vf-*variables are replaced by--xy-*variables, e.g.--vf-node-bg→--xy-node-background-color,--vf-node-text→--xy-node-color,--vf-handle→--xy-handle-background-color,--vf-edge-text→--xy-edge-label-color. Node border, box-shadow and handle color are now separate variables instead of one--vf-node-color.theme-default.cssis removed. Importstyle.cssfor the default theme, orbase.cssfor the structural styles only.- The built-in
input/outputnodes no longer have blue/pink accents.
-
#5896
02607f9-edgesReconnectableandelevateEdgesOnSelectnow default totrue.Edges are reconnectable by default (this only takes effect once you handle
@reconnect), and selected edges are raised above their siblings. To keep the previous behavior, set:edges-reconnectable="false"and/or:elevate-edges-on-select="false"on<VueFlow>. -
#5891
ca9c2fb- Align connection and reconnect event payloads with@xyflow/reactand add aselectionChangeevent.connectEnd/clickConnectEndemit{ event, connectionState }instead of the bare event.reconnectStartemits{ event, edge, handleType }andreconnectEndemits{ event, edge, handleType, connectionState }.- New
selectionChangeevent (@selection-change/onSelectionChange) emits{ nodes, edges }when the selection changes.
-
#5891
ca9c2fb- RenamefitViewOnInittofitViewand add afitViewOptionsprop for the initial fit. ThenodeOriginprop, which was previously ignored, is now applied. -
#6114
dff4dad- Align the connection APIs across all frameworks onNodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. - Add
getNodeConnectionstouseSvelteFlow. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
-
#5891
ca9c2fb- Align the package exports with@xyflow/reactand@xyflow/svelte:- ESM types resolve from
index.d.mtsand CJS types fromindex.d.ts, fixing type resolution undernode16/nodenext. - Stylesheets can be imported as
@xyflow/vue/style.css,@xyflow/vue/base.cssand@xyflow/vue/xy-theme.css. - The IIFE / browser-global build (
vue-flow-core.iife.js) and theunpkg/jsdelivrfields are removed. CDN users should load the ESM build (e.g. via esm.sh).
- ESM types resolve from
-
#5891
ca9c2fb- Align core types with@xyflow/system.NodeandEdgeare now built on the systemNodeBase/EdgeBase, and the store and its types take anEdgeTypegeneric next toNodeType(useVueFlow<NodeType, EdgeType>()).Old New node.parentNodenode.parentIdnode.computedPositionnode.internals.positionAbsolute(+node.internals.z)node.dimensionsnode.measurednode.handleBoundsnode.internals.handleBoundsnode.isParentuseVueFlowStore().parentLookup.get(node.id)?.size > 0node.labelnode.data.labelNodeProps<MyData>NodeProps<Node<MyData, "myType">>EdgeProps<MyData>EdgeProps<Edge<MyData, "myType">>NodeDimensionChange.updateStyleNodeDimensionChange.setAttributesNodePositionChange.fromNodePositionChange.positionAbsoluteNodeAddChange.item: GraphNode/EdgeAddChange.item: GraphEdgeNode/EdgeEdgeRemoveChange.{source,target,sourceHandle,targetHandle}read the edge via getEdge(id)@pane-ready/onPaneReady@init/onInit<VueFlow v-model="elements"><VueFlow v-model:nodes="nodes" v-model:edges="edges">setElements,getElements,getSelectedElementssetNodes/setEdges,getNodes/getEdges,getSelectedNodes/getSelectedEdgesaddSelectedElements,removeSelectedElementsaddSelectedNodes/addSelectedEdges,removeSelectedNodes/removeSelectedEdgesCustom node components now also receive
selectable,deletable,draggable,isConnectable,positionAbsoluteX,positionAbsoluteYandparentIdas props.NodeDragItemuses the system shape. -
#6046
e0be409- The<Background>pattern is now colored by the stylesheet rather than by an inlinefill/stroke. Previously the color was resolved in JS from a hardcoded{ lines: "#eee", dots: "#91919a" }.If you relied on those hardcoded light colors, pass them explicitly:
<Background color="#91919a" />for dots,<Background variant="lines" color="#eee" />for lines. -
#5890
72dbb75- Thenodes/edgesbinding now determines how changes are handled, and theapplyDefaultprop is removed.v-model:nodes/v-model:edges(or no binding at all, when driving the flow throughuseVueFlow()/setupVueFlow()) is managed: Vue Flow applies changes to its store and mirrors them back to your ref.- A bare one-way
:nodes/:edgesis controlled: changes are delivered via@nodes-change/@edges-changeand nothing is applied until you handle them (apply them and reassign your array).
-
#5891
ca9c2fb- Type theclassproperty asClassValue(string | Record<string, boolean> | ClassValue[], mirroring the Vue class-binding type) onNode,Edgeand theconnectionLineClassprop, replacing the looserstring | string[] | Record<string, any>.The function form for
classandstyle((el) => value) is removed. It was never part of the public type — only a dead runtime branch in the node/edge wrappers — and passing a function produced a broken native render anyway. Pass a resolvedClassValue/ style object instead (compute it in your own component if it needs to be dynamic). -
#6117
dae45aa-onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates -
#6049
15da095- TheconnectionLineOptionsobject of<VueFlow>is replaced by individual props.before after connectionLineOptions.typeconnectionLineTypeconnectionLineOptions.styleconnectionLineStyleconnectionLineOptions.classconnectionLineClassconnectionLineOptions.markerStartconnectionLineMarkerStartconnectionLineOptions.markerEndconnectionLineMarkerEndThe
ConnectionLineOptionstype is removed. -
#5891
ca9c2fb- Custom connection lines (#connection-lineslot) receivefrom*/to*props instead ofsource*/target*(sourceX→fromX,targetHandle→toHandle, …), matching@xyflow/react.markerStart/markerEndare optional.The
ElementDatatype is removed.Edgedata now defaults toRecord<string, unknown>. -
#6049
15da095- The connection status is now applied to the group of the connection line rather than its path. -
#5891
ca9c2fb- Expose the raw pointer position during a connection:- Custom connection-line components (
#connection-line) now receive apointerprop — the unsnapped pointer position in flow coordinates, distinct fromtoX/toY(which snap to the hovered handle). useConnection().pointeris now the raw pointer position. Previously it tracked the snapped end (it was aliased toconnection.to); the snapped end is still available viato/toHandle.
- Custom connection-line components (
-
#5898
903cd43- The store now exposes the ongoing connection as a singleconnectionobject (ConnectionState), replacing the separateconnectionStartHandle,connectionEndHandle,connectionPosition, andconnectionStatusfields. Readconnection.fromHandle,connection.toHandle,connection.pointer, andconnection.isValidinstead — this matchesuseConnection()and React/Svelte Flow. -
#6050
bf75d26- Rename thefitViewParamsprop of<Controls>tofitViewOptions. -
#5903
b507faa-isValidConnectionnow receives only the attempted connection, matchingIsValidConnectionin React and Svelte Flow. The extra second argument ({ nodes, edges, sourceNode, targetNode }) is removed, read those fromuseVueFlow()inside your handler if you need them. -
#5893
825e6c2- Removed theautoConnectprop and theConnectortype. Handle new connections with@connect(oronConnect) andaddEdge/addEdgesinstead:<VueFlow @connect="(connection) => (edges = addEdge(connection, edges))" />
-
#5906
b2ceddc- Removed the per-edgetemplateoption (edge.template). Use edge slots or map an edgetypeto a component via theedgeTypesprop instead. -
#5901
4675bdd- Removed the internalinitializedstore flag. It only guarded a redundant empty commit during store construction and was alwaystrueby the time your code ran. UsenodesInitializedorviewportInitializedto check readiness. -
#5891
ca9c2fb- Remove the redundantviewportHelperComputedReffrom theuseVueFlow()instance. The viewport functions (setCenter,fitView,zoomIn,zoomOut,zoomTo,setViewport,getViewport,fitBounds,screenToFlowPosition,flowToScreenPosition) are already exposed flat on the instance so the nestedviewportHelperwas duplicate surface.useVueFlow().viewportHelper.value.setCenter(…)→useVueFlow().setCenter(…)(and likewise for the other viewport functions).- The init flag moves to a flat
viewportInitialized(ComputedRef<boolean>):useVueFlow().viewportHelper.value.viewportInitialized→useVueFlow().viewportInitialized.value.
-
#5895
0ddd0b3- Removed the$destroymethod from the Vue Flow instance. It was a no-op — the store is owned by its provider component and torn down automatically when that component unmounts. -
#5891
ca9c2fb- Add theselectableclass to edges. The edge<g>now carries aselectableclass whenever the edge is selectable (its ownselectableflag, orelementsSelectablewhen unset), and the CSS keyscursor: pointerand the focus edge-path stroke off.selectable. Previouslycursor: pointerwas applied to every edge unconditionally, so non-selectable edges no longer show the pointer cursor. -
#5891
ca9c2fb- Edges are stored as your plainEdgeobjects and the edge, connection and viewport APIs are aligned with@xyflow/reactand@xyflow/svelte.GraphEdgeandisGraphEdgeare removed.getEdges/getEdge/v-model:edgesreturn plainEdges, soedge.sourceNode,edge.targetNodeandedge.sourceXare gone. UseuseInternalNode(() => props.source)and the positions fromEdgeProps.- In-place edge mutation is no longer reactive. Use
updateEdge,updateEdgeDataorsetEdges. EdgePropsdropssourceNode/targetNode, addsselectable/deletableand exposessourceHandleId/targetHandleId.useEdge().edgeis now aComputedRef.defaultEdgeOptionsare applied when rendering instead of being written onto stored edges.useConnection()returns aComputedRef<ConnectionState>(inProgress,isValid,from*,to*,pointer).connectionModedefaults tostrict. Setconnection-mode="loose"for the old behavior.
Old New findNode/findEdgegetNode/getEdgescreenToFlowCoordinate/flowToScreenCoordinatescreenToFlowPosition/flowToScreenPositionprojectscreenToFlowPositionupdateEdge(oldEdge, connection)reconnectEdge(oldEdge, connection)@edge-update-start/@edge-update/@edge-update-end@reconnect-start/@reconnect/@reconnect-endedgeUpdaterRadius/edgesUpdatable/edge.updatablereconnectRadius/edgesReconnectable/edge.reconnectableEdgeUpdatable/EdgeUpdateEventEdgeReconnectable/EdgeReconnectEventNew:
updateEdge(id, edgeUpdate, { replace? })for partial edge updates, anduseInternalNodeis exported. -
#5914
5a8ed98- Fix theuseKeyPresspreventDefaultoption, which was inverted. It now callspreventDefault()by default and only skips it when set tofalse— previouslypreventDefault: truewas what disabled it. The default behavior is unchanged; if you explicitly set this option, flip the value. -
#5927
69dc311- Use 5% as new default padding forfitView, andfitBounds. -
#5891
ca9c2fb-nodeLookup,parentLookupandedgeLookupare now reactiveMaps instead ofComputedRefs. Read them fromuseVueFlowStore()without.value:- useVueFlow().nodeLookup.value.get(id) + useVueFlowStore().nodeLookup.get(id)
-
#5891
ca9c2fb- Remove the deprecateduseHandleConnectionscomposable. UseuseNodeConnectionsinstead:type→handleType,id→handleIdandnodeId→id.// before useHandleConnections({ type: "target", id: "a", nodeId: "1" }) // after useNodeConnections({ handleType: "target", handleId: "a", id: "1" })
-
#6048
022cbc3-<MiniMap>now colors itself through--xy-minimap-*-propscustom properties instead of inline attributes. -
#5891
ca9c2fb- Remove the deprecatedupdateEdgeutil (usereconnectEdge) anduseZoomPanHelper(use the viewport functions onuseVueFlow()).addEdgenow takes an edges array instead of mixed elements:addEdge(connection, edges). -
#5891
ca9c2fb- Node events (click, mouse, context menu, drag, selection drag, minimap node events andnodesInitialized) now emit the userNodeinstead of theInternalNode. UsegetInternalNode(node.id)to readinternalsormeasured. -
#5891
ca9c2fb- Align nodeextenttyping with@xyflow/system:- Collapse the local
CoordinateExtenttype onto the one from@xyflow/system(they were identical) — it is now re-exported from@xyflow/system. - Remove
CoordinateExtentRangeand the per-node "clamp to parent with padding" extent form (extent: { range, padding }).node.extentand thenodeExtentprop now accept exactly what the system understands:"parent" | CoordinateExtent | null. Useextent: "parent"to clamp a child to its parent. This drops a vue-flow-only workaround that could not be cleanly typed against@xyflow/system; if padded clamping returns it will be a system-level feature. To inset from the parent in the meantime, apply the offset yourself.
- Collapse the local
-
#5891
ca9c2fb- Split nodes into the user-facingNodeand theInternalNode(formerlyGraphNode), matching@xyflow/reactand@xyflow/svelte.v-model:nodes,getNodes,getNodeandgetSelectedNodesreturn the plain nodes you passed in. Readinternals(absolute position, z-index, handle bounds) andmeasuredviagetInternalNode(id),useInternalNode(id)ornodeLookup.- In-place node mutation (
node.position = …,node.data.x = …) is no longer reactive. UseupdateNode,updateNodeDataorsetNodes. - Nodes are no longer filled with defaults: a node without
datakeepsdata: undefined(previously{}), andselected/draggingstayundefineduntil set.
- In-place node mutation (
-
#6115
b1ad016- ReplacepaneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. -
#5891
ca9c2fb-toObject()no longer returns the deprecatedpositionandzoomfields. Useviewport({ x, y, zoom }) instead. -
#5891
ca9c2fb- RemoveuseVueFlow().fromObject()and theFlowImportObjecttype.toObject()is unchanged. To restore a saved flow, set the elements and viewport yourself fromonInit(or any time after mount):const { setNodes, setEdges, setViewport, onInit } = useVueFlow() onInit(() => { const flow = JSON.parse(localStorage.getItem("flow") ?? "null") if (!flow) { return } setNodes(flow.nodes) setEdges(flow.edges) if (flow.viewport) { setViewport(flow.viewport) } })
-
#5556
9fcddb8- RemovenodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. -
#6085
fc128ca- RemovedgetNodeTypesandgetEdgeTypesfromuseVueFlow(). Node and edge components now resolve from the registered types directly; readnodeTypes/edgeTypesoffuseVueFlowStore()if you need the registered map. -
#5891
ca9c2fb- Remove thevueFlowVersionfield from the flow instance (useVueFlow().vueFlowVersion) and the build-time__VUE_FLOW_VERSION__injection. It was exposed but never used internally and has no equivalent in xyflow/react; read your installed version from your package manager or@xyflow/vue/package.jsoninstead. -
#5987
615c5f6- Rename the measured handle geometry type fromHandletoHandleBoundsso it no longer collides with the<Handle />component. -
#5911
0d330e0- Renamed the$resetinstance action toreset. -
#5891
ca9c2fb- Remove the global flow registry.useVueFlow()no longer accepts an id or options. It returns the store of the nearest<VueFlow>or<VueFlowProvider>and throws outside of one.useVueFlow({ nodes, edges, … })→ pass these as props to<VueFlow>.useVueFlow("my-id")to access a flow from outside → wrap both in<VueFlowProvider>and calluseVueFlow()inside it.
The
idprop is now only used as a label (aria/debug), not to look up a flow. -
#5891
ca9c2fb- Add an explicitselectionOnDragprop and drop theselectionKeyCode={true}overload.Drawing a selection box on a plain pane drag (no key held) used to be expressed by setting
selectionKeyCodetotrue, which overloaded the key-code prop. It is now its own boolean prop:<!-- before --> <VueFlow :selection-key-code="true" :pan-on-drag="false" /> <!-- after --> <VueFlow :selection-on-drag="true" :pan-on-drag="false" />
selectionKeyCodeis once again just the key you hold to select (default"Shift").paneClickalso fires while selecting on drag (it was previously swallowed by the d3-zoom click handling). -
#5927
7b52b50- Numbers passed tofitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%) -
#5891
ca9c2fb- Use the parent expansion of@xyflow/systemforexpandParentnodes when dragging, measuring and resizing, matching@xyflow/react:- A child dragged past the top/left edge of its parent now grows the parent up/left, and its siblings are offset so they stay in place.
node.originis respected when a resize expands the parent.- Keyboard moves of nodes with an
extentno longer stop a full node width/height short of the boundary.
-
#5887
1d34f03-HandleElementis removed in favor ofHandleBounds, andEdgePositionsin favor ofEdgePosition. The<Handle>propsconnectableStart/connectableEndare renamed toisConnectableStart/isConnectableEnd,OnConnectStartParamsfields are now nullable, and the deprecatedProjecttype is no longer re-exported. -
#6136
1262688-updateNodeInternals(id)requires a node id or an array of ids; the no-argument form (which re-measured every node) is removed. -
#5900
ec0405e-useNodenow returns the user-facingNodeinstead of the enrichedInternalNode— useuseInternalNodeforinternals/measured. Itsidargument also accepts a ref or getter, matchinguseInternalNode. -
#5891
ca9c2fb-useHandlenow usesXYHandlefrom@xyflow/system, so drag-to-connect (auto-pan, connection radius, closest-handle resolution, drag threshold) behaves like@xyflow/reactand@xyflow/svelte. Its reconnect options are renamed:edgeUpdaterType→reconnectHandleType,onEdgeUpdate→onReconnect,onEdgeUpdateEnd→onReconnectEnd, andonReconnectStartis added. -
#5891
ca9c2fb- - Rename thenodeIdparam toid(useNodeConnections({ nodeId })→useNodeConnections({ id })). Like before, it is optional and falls back to the node id from theuseNodeIdcontext injection.handleIdnow requireshandleTypeto be set. PassinghandleIdon its own is a type error —handleIdis meaningless at runtime without ahandleType, and the type now points you at the fix. Runtime behavior is unchanged.
-
#5891
ca9c2fb- Split the store API.useVueFlow()now returns the flow instance (actions, computed getters and event hooks likeonNodeClickoronConnect) and no longer exposes the raw reactive state. The state moved touseVueFlowStore(), withstoreToRefs()to destructure it (Pinia-style).// before const { nodes, transform, nodeLookup, setViewport, onConnect } = useVueFlow() // after const { setViewport, onConnect } = useVueFlow() const store = useVueFlowStore() // reactive state (store.nodes, store.transform — no .value) const { nodes, transform } = storeToRefs(store) // refs for destructuring const { nodeLookup } = useVueFlowStore() // lookup Maps can be destructured directly
useVueFlowStore()returns the reactive state object, including thenodeLookup/parentLookup/edgeLookup/connectionLookupMaps. Reading it inside acomputed,watchor template is tracked.storeToRefs(store)turns the state fields into refs so destructuring stays reactive.- Computed getters (
getNodes,getEdges,getSelectedNodes,getSelectedEdges,viewport) and all event hooks stay onuseVueFlow().
A
<VueFlow>template ref now exposes the instance (VueFlowInstance). TheVueFlowStoretype is kept as an alias ofVueFlowInstance. -
#5891
ca9c2fb- Addeaseandinterpolateoptions to every viewport function.fitView,setViewport,setCenter,fitBounds,zoomTo,zoomInandzoomOutnow acceptease?: (t: number) => numberandinterpolate?: "smooth" | "linear"alongsidedurationto control the transition curve.The viewport option types now come from
@xyflow/system:FitViewParams→FitViewOptions(FitViewOptionsBasefrom@xyflow/system). Itsnodesoption takes node objects instead of ids —nodes?: string[]→nodes?: (Node | { id: string })[]— and the vestigialoffsetoption is removed (superseded bypadding).TransitionOptions→ViewportHelperFunctionOptions.
-
#6052
1afef23- Require Vue^3.5.27(peer dependency ofvueand@vue/reactivity). The default flowidis now generated withuseId(), and earlier 3.5 releases cannot resolve@xyflow/systemtypes indefineProps(vuejs/core#14236). -
#6077
f062cfb- Remove the array-basedapplyChanges,applyNodeChangesandapplyEdgeChangesexports, andapplyNodeChanges/applyEdgeChangeson theuseVueFlow()instance. UseapplyTo(elements)of the changeset instead.
-
#5891
ca9c2fb-fitViewandfitBoundsnow acceptPaddingfrom@xyflow/system: per-side values andpx/%units in addition to a number.Padding,PaddingWithUnitandPaddingUnitare re-exported. -
#5891
ca9c2fb- Add anariaLabelConfigprop to customize the accessibility text. Pass aPartial<AriaLabelConfig>(merged over the defaults) to override any of the node/edge a11y descriptions, the aria-live "moved node" message, and the Controls / MiniMap / Handle aria labels. As part of this, the Controls buttons and Handle — which previously had noaria-label— now get accessible labels, the Controls panel gets aControl Panellabel, and the MiniMap label default moves into the config.AriaLabelConfigis re-exported from the package root. -
#5891
ca9c2fb- Allow theming arrowhead markers with the--xy-edge-strokeCSS variable.defaultMarkerColornow acceptsnull— pass it (or leave thecolorof a marker unset) and the arrowhead inherits--xy-edge-strokeinstead of the hard-coded#b1b1b7, so markers can match themed edge colors. The marker polylines carry.arrow/.arrowclosedclasses and only set an inline color when one is provided; the open arrow strokes only, the closed arrow strokes and fills. The default (#b1b1b7) is unchanged. -
#5891
ca9c2fb- AddautoPanOnNodeFocus(defaulttrue), mirroring xyflow/react. When a node receives keyboard focus (Tab) and is not within the viewport, the viewport pans to center it — so keyboard navigation never lands on an off-screen node. Only reacts to keyboard focus (:focus-visible), not pointer/programmatic focus. Setauto-pan-on-node-focus="false"(or passfalse) to disable. -
#5891
ca9c2fb- Add anautoPanOnSelectionprop. Whentrue(the default), the viewport pans automatically as the cursor reaches the edge of the viewport while dragging a selection box, so you can select nodes beyond the visible area in one gesture. Set:auto-pan-on-selection="false"to keep the viewport fixed during selection. -
#6046
e0be409- AddbgColorandpatternClassNameprops to<Background>.colorandbgColorare applied as the--xy-background-pattern-color-propsand--xy-background-color-propscustom properties. -
#5891
ca9c2fb- Add a dark theme. The flow follows the system color scheme by default. Use theforceColorModeprop ("light" | "dark") to pin it. -
#5891
ca9c2fb- Add aconnectionDragThresholdprop. It is the distance in pixels the pointer must move from a handle before a connection line starts to drag — useful to prevent accidental connections when you just click a handle. Defaults to1; set it higher (e.g.connectionDragThreshold="25") to require a more deliberate drag, or0to start the connection immediately on pointer-down. Below the threshold, neitherconnectStartnorconnectEndfires. -
#6049
15da095- AddconnectionLineContainerStyleprop, applied to the<svg>the connection line is drawn in. -
#5891
ca9c2fb- Add a controlledviewportprop withv-model:viewportsupport, matching the controlled viewport of@xyflow/reactandbind:viewportof@xyflow/svelte.<VueFlow v-model:viewport="viewport" />
The bound value two-way binds to the viewport of the flow: setting it pans/zooms the flow (applied via
syncViewport, so no extra pan/zoom events fire), and it updates as the user interacts (viaupdate:viewport).defaultViewportremains the uncontrolled initial-viewport prop; useviewportwhen you want to own the viewport state. -
#6048
022cbc3- Add anorientationprop to<Controls>("vertical" | "horizontal", default"vertical"). -
#5910
87108d3- Added adebugprop. Whentrue, Vue Flow logs its events to the console as they fire (high-frequency events like move/drag/hover are skipped) — useful for seeing which events run. -
#5939
621f5d9- AddchangeParenttouseReactFlow,useSvelteFlowanduseVueFlow, to easily change the parent of a node without calculating a new position. -
#5891
ca9c2fb- Discriminate the#node-<type>/#edge-<type>slot props by node/edge type. Whennodes/edgesare typed as a discriminated union (e.g.(MyNodeA | MyNodeB)[]), each#node-<type>/#edge-<type>slot now narrows its props to theNodeProps/EdgePropsof the matching variant, so a custom node/edge component can safely type itsdatawithout a cast. GenericNode[]/Edge[]flows are unchanged (props stay broad), and arbitrary slot names remain allowed (a broadnode-${string}/edge-${string}fallback). Type-only. -
#5905
a5753cd- Tightened the edgelabeltype. Dropped the catch-allobjectfromEdgePropsandEdgeTextPropsso it matches the actual label type of edges (string | VNode | Component). -
#6050
bf75d26- ExportControlButtonPropsandControlButtonEmitstypes. -
#6050
d61a36a- ExportgetEdgeCenter, along with theGetBezierPathParams,GetSmoothStepPathParamsandGetStraightPathParamsparameter types. -
#5891
ca9c2fb- MoveBackground,Controls,MiniMap,NodeResizer,NodeResizeControl, andNodeToolbarcomponents into core pkg. -
#6048
022cbc3- Add abgColorprop to<MiniMap>, applied as the--xy-minimap-background-color-propscustom property. -
#5891
ca9c2fb- Add anautoScaleprop toNodeResizer/NodeResizeControl. Handle controls already scale up byMath.max(1 / zoom, 1)so they do not shrink below their base size when zooming out;autoScale(defaulttrue) now lets you opt out, previously the prop existed but had no effect. The handle is also centered via thetranslateCSS property instead oftransform, so the centering composes with the zoomscaleand the handle stays pinned to the node corner at any zoom. -
#6050
f94dad9- Add aresizeDirectionprop to<NodeResizeControl>("horizontal" | "vertical"). When set, the control only resizes the node along that axis; left unset it resizes in any direction, as before. -
#5891
ca9c2fb- Add theonBeforeDeleteprop and thedeleteElementsaction.deleteElements({ nodes, edges })also removes child nodes and connected edges, and resolves to{ deletedNodes, deletedEdges }.onBeforeDeleteruns before the Delete key anddeleteElementsremove anything: returnfalseto cancel,trueto continue or{ nodes, edges }to delete a subset. -
#5993
901b0e4- Addxy-theme.cssstylesheet (@xyflow/<lib>/xy-theme.css) that ships the xyflow default theme on top ofbase.css. -
#5891
ca9c2fb- Add astepPositionoption to smooth-step / step edges. SetpathOptions.stepPosition(0 = bend at source, 1 = at target, 0.5 = midpoint, the default) to control where the edge bends along its path. The path math comes fromgetSmoothStepPathfrom@xyflow/system; theSmoothStepEdgecomponent now forwards the option to it. -
#5891
ca9c2fb-ConnectionLineProps,RemoveNodes,RemoveEdgesandIsNodeIntersectingnow take theNodeType/EdgeTypeof the flow, so custom connection lines and updater functions get typed nodes and edges. -
#5904
1e7fa6b- TightenedBaseEdgeProps.labelfromanytostring | VNode | Component<EdgeTextProps>, matching the actual label type of edges. -
#5882
3334af0- AddnodesDelete,edgesDelete, anddeleteevents, matching@xyflow/react(onNodesDelete/onEdgesDelete/onDelete) and@xyflow/svelte(ondelete). They fire fromdeleteElements(the choke point for both the delete key and programmatic deletion) afteronBeforeDeletehas resolved the removed set —edgesDeletewith the removed edges,nodesDeletewith the removed nodes (each only when non-empty), anddeletewith{ nodes, edges }whenever anything was removed. Also exports theOnDeletehandler type alongsideOnBeforeDelete. -
#5914
96bfd42-<VueFlowProvider>now accepts the same options assetupVueFlow()to seed its store — passnodes,edges, or any otherVueFlowPropsand they become the initial values of the store. The seed is read once when the store is created.
-
#6046
e0be409- Correct the pattern offset of<Background>, which was calculated asoffset * zoom || 1 + gap / 2. That parses asoffset * zoom || (1 + gap / 2), so with the defaultoffsetof0the pattern sat one pixel off. -
#5891
ca9c2fb- Clear the visual nodes-selection box when no selected nodes remain.nodesSelectionActiveonly ever turns on via a user drag-select, but it could get stucktrueafter the selected nodes were removed (e.g. deleted) — so a later programmatic select would wrongly render theNodesSelectionrect around an unrelated node. Re-adopting nodes now turns it back off whenever the selection is empty. -
#6085
fc128ca- Improve rendering performance, especially while dragging large selections:- Node drag updates are batched to one per animation frame.
- Nodes, edges and the
<MiniMap>re-render less during drags. removeSelectedNodes/removeSelectedEdgesonly emit changes for elements that are actually selected.- Built-in edges no longer render their props (
source,sourceX,animated, …) as attributes on the<path>, andEdgeTextno longer re-measures its label on every position change.
-
#5945
7e4c422-EdgeWrappernow computes edge positions withgetEdgePositionfrom@xyflow/system(as@xyflow/reactand@xyflow/sveltedo) instead of a hand-rolled copy. It returnsnullwhen a node is not initialized or a handle cannot be resolved, so an edge between nodes that render no<Handle>draws nothing instead of a phantom line to the bounding box of the node. This also aligns handle resolution across connection modes with the other packages. -
#5914
a86e6e5- Dev warnings now link to the matching entry in the error reference, e.g.Help: https://vueflow.dev/error#NODE_TYPE_MISSING. -
#5891
ca9c2fb- Fix theincludeHiddenNodesoption offitViewbeing ignored. -
#5891
ca9c2fb- Defer an imperativefitView()until the nodes are measured. AfitView()call made before the nodes settle — e.g. right afteraddNodes()— used to frame only the already-measured nodes (getFitViewNodesskips unmeasured ones) and ignore the new ones. It now waits fornodesInitializedbefore fitting, so the fit always frames the current nodes. An empty flow resolves immediately (nothing to wait for). -
#5891
ca9c2fb- FixisNodeIntersectingwithpartially: falsewhen the area is fully contained in the node. Previously only a node fully inside the area counted, now containment in either direction does, matchinggetIntersectingNodes. -
#5881
9d13542-setEdges/addEdgesno longer drop edges whose source or target node is not in the store. PreviouslyvalidateEdgesdiscarded any edge with a missing endpoint at commit time, which silently deleted edges and made the order ofsetNodes/setEdgesmatter — adding edges before their nodes lost them. Edges are now kept andEdgeWrapperskips drawing them (emitting the existingEDGE_SOURCE_MISSING/EDGE_TARGET_MISSINGdev warning) until both nodes exist. TheisValidConnectiongate still runs whenever both endpoint nodes are resolvable. -
#5887
81d4b63- Multi-keyuseKeyPresscombinations now match regardless of the order keys are pressed. The unused type-guard overload onuseNodesData/useEdgesDatais removed. -
#6048
022cbc3- ThemaskStrokeWidthof<MiniMap>is now scaled by the view scale of the minimap. -
#6048
022cbc3-MiniMapNodeFuncmay now returnundefined— its signature is(node) => string | undefined— so a per-node callback can fall back to the themed default for that node. AnundefinednodeColor,nodeStrokeColorornodeClassNameno longer throws. -
#6048
022cbc3- The<svg>inside<MiniMap>now carries thevue-flow__minimap-svgclass. -
#5891
ca9c2fb- Fix the intermittentTS2589: Type instantiation is excessively deeperror on updates likenodes.value = nodes.value.map(...). Nodes and edges are now excluded from the VueUnwrapRef. -
#5891
ca9c2fb- Honorwidth/heightandinitialWidth/initialHeightin the node visibility gate and inline size. The node wrapper previously gated visibility onmeasuredalone, so a node sized viawidth/initialWidthstayedvisibility: hiddenuntil theResizeObservermeasured it, and in SSR (noResizeObserver) it never became visible. Visibility now usesnodeHasDimensionsfrom@xyflow/system(measured ?? width ?? initialWidth), and the inline size of the wrapper falls back throughinitialWidth/initialHeightbefore the node is measured (initialWidth/initialHeightare the SSR dimensions, since DOM cannot be measured server-side). -
#5891
ca9c2fb- Keep the current selection on a pane click whenelementsSelectableisfalse. Previously a pane click always cleared the selection; now a selection set before selection was disabled, or set programmatically, survives the click. The interactive reset is centralized in a new gatedresetSelectedElementsaction (a no-op whileelementsSelectableisfalse), distinct fromremoveSelectedNodes/removeSelectedEdges, which still clear unconditionally. -
#6115
b1ad016- Fire the pane context menu event when right-click panning is enabled (panOnDragincludes2). -
#5891
ca9c2fb- ExportResizeControlVariantas a value, not type-only. It is a runtime enum, but the bundled type declarations re-exported it through the NodeResizer barrel asexport type, soResizeControlVariant.Line/.Handlecould not be used as a value in TypeScript consumers. It is now re-exported directly from the package root as a value. -
#5891
ca9c2fb- A plain click on the pane no longer opens a selection box or firesselectionStart/selectionEnd. The selection (clearing the current selection +selectionStart) now begins only once the pointer moves past the click threshold (paneDragThreshold, or immediately while the selection key is held), andnodesSelectionActive/selectionEndonly update when a real selection drag happened — instead of resetting on every pointer-down and activating on every pointer-up. -
#6064
de1e4c5- Resolve the promises of animated viewport functions likefitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending -
#5891
ca9c2fb- Improve the return type ofuseNodesData. It now usesDistributivePickfrom@xyflow/systeminstead of a merged object type, so when you pass a union node type the result is a discriminated union — checking.typenarrows.data:const node = useNodesData<MyNode>(id) // MyNode = TextNode | NumberNode if (node.value?.type === "text") { node.value.data.text // narrowed to TextNode data }
For a single (non-union) node type the result is unchanged.
-
#6101
49a335e- Build the<Background>pattern element id aspattern-<flowId><id> -
#6101
63d077b- Holding the selection key now starts a selection box even when the drag begins over a node or edge. The element underneath no longer starts a drag of its own. A child marked withnokeystill opts out, and a secondary pointer no longer opens a box. -
#6101
c62aee5- Do not start a selection box on touch when panning is enabled. ApanOnDragbutton array only restricts mouse input, so a touch drag now pans, unless the selection key is held. -
Updated dependencies [
dff4dad,dae45aa,13bf20a,5d448e9,fbe2ba5,96b196f,69dc311,b872a5b,1d9b9cd,b1ad016,de1e4c5,bf27626,9fcddb8,5161767,615c5f6,de1e4c5,8849014,7b52b50,885ac9e]:- @xyflow/system@1.0.0
@xyflow/vue@2.0.0
-
#5891
ca9c2fb-ConnectionLineTypeandPanelPositionare now re-exported from@xyflow/system, matching@xyflow/reactand@xyflow/svelte.- The value of
ConnectionLineType.SimpleBezierchanged from"simple-bezier"to"simplebezier". Using the enum is unaffected; update raw"simple-bezier"strings. - The
PanelPositionenum and thePanelPositionTypeunion are replaced by thePanelPositionstring union (e.g."top-left"). It also accepts"center-left"and"center-right".
- The value of
-
#5891
ca9c2fb- Rename container classes to match@xyflow/reactand@xyflow/svelte. Update custom CSS or DOM queries that use them:.vue-flow__transformationpane→.vue-flow__viewport.vue-flow__viewport→.vue-flow__renderer.vue-flow__edge-labels→.vue-flow__edgelabel-renderer
-
#5891
ca9c2fb- Use the same CSS variables and stylesheets as@xyflow/reactand@xyflow/svelte.--vf-*variables are replaced by--xy-*variables, e.g.--vf-node-bg→--xy-node-background-color,--vf-node-text→--xy-node-color,--vf-handle→--xy-handle-background-color,--vf-edge-text→--xy-edge-label-color. Node border, box-shadow and handle color are now separate variables instead of one--vf-node-color.theme-default.cssis removed. Importstyle.cssfor the default theme, orbase.cssfor the structural styles only.- The built-in
input/outputnodes no longer have blue/pink accents.
-
#5896
02607f9-edgesReconnectableandelevateEdgesOnSelectnow default totrue.Edges are reconnectable by default (this only takes effect once you handle
@reconnect), and selected edges are raised above their siblings. To keep the previous behavior, set:edges-reconnectable="false"and/or:elevate-edges-on-select="false"on<VueFlow>. -
#5891
ca9c2fb- Align connection and reconnect event payloads with@xyflow/reactand add aselectionChangeevent.connectEnd/clickConnectEndemit{ event, connectionState }instead of the bare event.reconnectStartemits{ event, edge, handleType }andreconnectEndemits{ event, edge, handleType, connectionState }.- New
selectionChangeevent (@selection-change/onSelectionChange) emits{ nodes, edges }when the selection changes.
-
#5891
ca9c2fb- RenamefitViewOnInittofitViewand add afitViewOptionsprop for the initial fit. ThenodeOriginprop, which was previously ignored, is now applied. -
#6114
dff4dad- Align the connection APIs across all frameworks onNodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. - Add
getNodeConnectionstouseSvelteFlow. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
-
#5891
ca9c2fb- Align the package exports with@xyflow/reactand@xyflow/svelte:- ESM types resolve from
index.d.mtsand CJS types fromindex.d.ts, fixing type resolution undernode16/nodenext. - Stylesheets can be imported as
@xyflow/vue/style.css,@xyflow/vue/base.cssand@xyflow/vue/xy-theme.css. - The IIFE / browser-global build (
vue-flow-core.iife.js) and theunpkg/jsdelivrfields are removed. CDN users should load the ESM build (e.g. via esm.sh).
- ESM types resolve from
-
#5891
ca9c2fb- Align core types with@xyflow/system.NodeandEdgeare now built on the systemNodeBase/EdgeBase, and the store and its types take anEdgeTypegeneric next toNodeType(useVueFlow<NodeType, EdgeType>()).Old New node.parentNodenode.parentIdnode.computedPositionnode.internals.positionAbsolute(+node.internals.z)node.dimensionsnode.measurednode.handleBoundsnode.internals.handleBoundsnode.isParentuseVueFlowStore().parentLookup.get(node.id)?.size > 0node.labelnode.data.labelNodeProps<MyData>NodeProps<Node<MyData, "myType">>EdgeProps<MyData>EdgeProps<Edge<MyData, "myType">>NodeDimensionChange.updateStyleNodeDimensionChange.setAttributesNodePositionChange.fromNodePositionChange.positionAbsoluteNodeAddChange.item: GraphNode/EdgeAddChange.item: GraphEdgeNode/EdgeEdgeRemoveChange.{source,target,sourceHandle,targetHandle}read the edge via getEdge(id)@pane-ready/onPaneReady@init/onInit<VueFlow v-model="elements"><VueFlow v-model:nodes="nodes" v-model:edges="edges">setElements,getElements,getSelectedElementssetNodes/setEdges,getNodes/getEdges,getSelectedNodes/getSelectedEdgesaddSelectedElements,removeSelectedElementsaddSelectedNodes/addSelectedEdges,removeSelectedNodes/removeSelectedEdgesCustom node components now also receive
selectable,deletable,draggable,isConnectable,positionAbsoluteX,positionAbsoluteYandparentIdas props.NodeDragItemuses the system shape. -
#6046
e0be409- The<Background>pattern is now colored by the stylesheet rather than by an inlinefill/stroke. Previously the color was resolved in JS from a hardcoded{ lines: "#eee", dots: "#91919a" }.If you relied on those hardcoded light colors, pass them explicitly:
<Background color="#91919a" />for dots,<Background variant="lines" color="#eee" />for lines. -
#5890
72dbb75- Thenodes/edgesbinding now determines how changes are handled, and theapplyDefaultprop is removed.v-model:nodes/v-model:edges(or no binding at all, when driving the flow throughuseVueFlow()/setupVueFlow()) is managed: Vue Flow applies changes to its store and mirrors them back to your ref.- A bare one-way
:nodes/:edgesis controlled: changes are delivered via@nodes-change/@edges-changeand nothing is applied until you handle them (apply them and reassign your array).
-
#5891
ca9c2fb- Type theclassproperty asClassValue(string | Record<string, boolean> | ClassValue[], mirroring the Vue class-binding type) onNode,Edgeand theconnectionLineClassprop, replacing the looserstring | string[] | Record<string, any>.The function form for
classandstyle((el) => value) is removed. It was never part of the public type — only a dead runtime branch in the node/edge wrappers — and passing a function produced a broken native render anyway. Pass a resolvedClassValue/ style object instead (compute it in your own component if it needs to be dynamic). -
#6117
dae45aa-onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates -
#6049
15da095- TheconnectionLineOptionsobject of<VueFlow>is replaced by individual props.before after connectionLineOptions.typeconnectionLineTypeconnectionLineOptions.styleconnectionLineStyleconnectionLineOptions.classconnectionLineClassconnectionLineOptions.markerStartconnectionLineMarkerStartconnectionLineOptions.markerEndconnectionLineMarkerEndThe
ConnectionLineOptionstype is removed. -
#5891
ca9c2fb- Custom connection lines (#connection-lineslot) receivefrom*/to*props instead ofsource*/target*(sourceX→fromX,targetHandle→toHandle, …), matching@xyflow/react.markerStart/markerEndare optional.The
ElementDatatype is removed.Edgedata now defaults toRecord<string, unknown>. -
#6049
15da095- The connection status is now applied to the group of the connection line rather than its path. -
#5891
ca9c2fb- Expose the raw pointer position during a connection:- Custom connection-line components (
#connection-line) now receive apointerprop — the unsnapped pointer position in flow coordinates, distinct fromtoX/toY(which snap to the hovered handle). useConnection().pointeris now the raw pointer position. Previously it tracked the snapped end (it was aliased toconnection.to); the snapped end is still available viato/toHandle.
- Custom connection-line components (
-
#5898
903cd43- The store now exposes the ongoing connection as a singleconnectionobject (ConnectionState), replacing the separateconnectionStartHandle,connectionEndHandle,connectionPosition, andconnectionStatusfields. Readconnection.fromHandle,connection.toHandle,connection.pointer, andconnection.isValidinstead — this matchesuseConnection()and React/Svelte Flow. -
#6050
bf75d26- Rename thefitViewParamsprop of<Controls>tofitViewOptions. -
#5903
b507faa-isValidConnectionnow receives only the attempted connection, matchingIsValidConnectionin React and Svelte Flow. The extra second argument ({ nodes, edges, sourceNode, targetNode }) is removed, read those fromuseVueFlow()inside your handler if you need them. -
#5893
825e6c2- Removed theautoConnectprop and theConnectortype. Handle new connections with@connect(oronConnect) andaddEdge/addEdgesinstead:<VueFlow @connect="(connection) => (edges = addEdge(connection, edges))" />
-
#5906
b2ceddc- Removed the per-edgetemplateoption (edge.template). Use edge slots or map an edgetypeto a component via theedgeTypesprop instead. -
#5901
4675bdd- Removed the internalinitializedstore flag. It only guarded a redundant empty commit during store construction and was alwaystrueby the time your code ran. UsenodesInitializedorviewportInitializedto check readiness. -
#5891
ca9c2fb- Remove the redundantviewportHelperComputedReffrom theuseVueFlow()instance. The viewport functions (setCenter,fitView,zoomIn,zoomOut,zoomTo,setViewport,getViewport,fitBounds,screenToFlowPosition,flowToScreenPosition) are already exposed flat on the instance so the nestedviewportHelperwas duplicate surface.useVueFlow().viewportHelper.value.setCenter(…)→useVueFlow().setCenter(…)(and likewise for the other viewport functions).- The init flag moves to a flat
viewportInitialized(ComputedRef<boolean>):useVueFlow().viewportHelper.value.viewportInitialized→useVueFlow().viewportInitialized.value.
-
#5895
0ddd0b3- Removed the$destroymethod from the Vue Flow instance. It was a no-op — the store is owned by its provider component and torn down automatically when that component unmounts. -
#5891
ca9c2fb- Add theselectableclass to edges. The edge<g>now carries aselectableclass whenever the edge is selectable (its ownselectableflag, orelementsSelectablewhen unset), and the CSS keyscursor: pointerand the focus edge-path stroke off.selectable. Previouslycursor: pointerwas applied to every edge unconditionally, so non-selectable edges no longer show the pointer cursor. -
#5891
ca9c2fb- Edges are stored as your plainEdgeobjects and the edge, connection and viewport APIs are aligned with@xyflow/reactand@xyflow/svelte.GraphEdgeandisGraphEdgeare removed.getEdges/getEdge/v-model:edgesreturn plainEdges, soedge.sourceNode,edge.targetNodeandedge.sourceXare gone. UseuseInternalNode(() => props.source)and the positions fromEdgeProps.- In-place edge mutation is no longer reactive. Use
updateEdge,updateEdgeDataorsetEdges. EdgePropsdropssourceNode/targetNode, addsselectable/deletableand exposessourceHandleId/targetHandleId.useEdge().edgeis now aComputedRef.defaultEdgeOptionsare applied when rendering instead of being written onto stored edges.useConnection()returns aComputedRef<ConnectionState>(inProgress,isValid,from*,to*,pointer).connectionModedefaults tostrict. Setconnection-mode="loose"for the old behavior.
Old New findNode/findEdgegetNode/getEdgescreenToFlowCoordinate/flowToScreenCoordinatescreenToFlowPosition/flowToScreenPositionprojectscreenToFlowPositionupdateEdge(oldEdge, connection)reconnectEdge(oldEdge, connection)@edge-update-start/@edge-update/@edge-update-end@reconnect-start/@reconnect/@reconnect-endedgeUpdaterRadius/edgesUpdatable/edge.updatablereconnectRadius/edgesReconnectable/edge.reconnectableEdgeUpdatable/EdgeUpdateEventEdgeReconnectable/EdgeReconnectEventNew:
updateEdge(id, edgeUpdate, { replace? })for partial edge updates, anduseInternalNodeis exported. -
#5914
5a8ed98- Fix theuseKeyPresspreventDefaultoption, which was inverted. It now callspreventDefault()by default and only skips it when set tofalse— previouslypreventDefault: truewas what disabled it. The default behavior is unchanged; if you explicitly set this option, flip the value. -
#5927
69dc311- Use 5% as new default padding forfitView, andfitBounds. -
#5891
ca9c2fb-nodeLookup,parentLookupandedgeLookupare now reactiveMaps instead ofComputedRefs. Read them fromuseVueFlowStore()without.value:- useVueFlow().nodeLookup.value.get(id) + useVueFlowStore().nodeLookup.get(id)
-
#5891
ca9c2fb- Remove the deprecateduseHandleConnectionscomposable. UseuseNodeConnectionsinstead:type→handleType,id→handleIdandnodeId→id.// before useHandleConnections({ type: "target", id: "a", nodeId: "1" }) // after useNodeConnections({ handleType: "target", handleId: "a", id: "1" })
-
#6048
022cbc3-<MiniMap>now colors itself through--xy-minimap-*-propscustom properties instead of inline attributes. -
#5891
ca9c2fb- Remove the deprecatedupdateEdgeutil (usereconnectEdge) anduseZoomPanHelper(use the viewport functions onuseVueFlow()).addEdgenow takes an edges array instead of mixed elements:addEdge(connection, edges). -
#5891
ca9c2fb- Node events (click, mouse, context menu, drag, selection drag, minimap node events andnodesInitialized) now emit the userNodeinstead of theInternalNode. UsegetInternalNode(node.id)to readinternalsormeasured. -
#5891
ca9c2fb- Align nodeextenttyping with@xyflow/system:- Collapse the local
CoordinateExtenttype onto the one from@xyflow/system(they were identical) — it is now re-exported from@xyflow/system. - Remove
CoordinateExtentRangeand the per-node "clamp to parent with padding" extent form (extent: { range, padding }).node.extentand thenodeExtentprop now accept exactly what the system understands:"parent" | CoordinateExtent | null. Useextent: "parent"to clamp a child to its parent. This drops a vue-flow-only workaround that could not be cleanly typed against@xyflow/system; if padded clamping returns it will be a system-level feature. To inset from the parent in the meantime, apply the offset yourself.
- Collapse the local
-
#5891
ca9c2fb- Split nodes into the user-facingNodeand theInternalNode(formerlyGraphNode), matching@xyflow/reactand@xyflow/svelte.v-model:nodes,getNodes,getNodeandgetSelectedNodesreturn the plain nodes you passed in. Readinternals(absolute position, z-index, handle bounds) andmeasuredviagetInternalNode(id),useInternalNode(id)ornodeLookup.- In-place node mutation (
node.position = …,node.data.x = …) is no longer reactive. UseupdateNode,updateNodeDataorsetNodes. - Nodes are no longer filled with defaults: a node without
datakeepsdata: undefined(previously{}), andselected/draggingstayundefineduntil set.
- In-place node mutation (
-
#6115
b1ad016- ReplacepaneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. -
#5891
ca9c2fb-toObject()no longer returns the deprecatedpositionandzoomfields. Useviewport({ x, y, zoom }) instead. -
#5891
ca9c2fb- RemoveuseVueFlow().fromObject()and theFlowImportObjecttype.toObject()is unchanged. To restore a saved flow, set the elements and viewport yourself fromonInit(or any time after mount):const { setNodes, setEdges, setViewport, onInit } = useVueFlow() onInit(() => { const flow = JSON.parse(localStorage.getItem("flow") ?? "null") if (!flow) { return } setNodes(flow.nodes) setEdges(flow.edges) if (flow.viewport) { setViewport(flow.viewport) } })
-
#5556
9fcddb8- RemovenodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. -
#6085
fc128ca- RemovedgetNodeTypesandgetEdgeTypesfromuseVueFlow(). Node and edge components now resolve from the registered types directly; readnodeTypes/edgeTypesoffuseVueFlowStore()if you need the registered map. -
#5891
ca9c2fb- Remove thevueFlowVersionfield from the flow instance (useVueFlow().vueFlowVersion) and the build-time__VUE_FLOW_VERSION__injection. It was exposed but never used internally and has no equivalent in xyflow/react; read your installed version from your package manager or@xyflow/vue/package.jsoninstead. -
#5987
615c5f6- Rename the measured handle geometry type fromHandletoHandleBoundsso it no longer collides with the<Handle />component. -
#5911
0d330e0- Renamed the$resetinstance action toreset. -
#5891
ca9c2fb- Remove the global flow registry.useVueFlow()no longer accepts an id or options. It returns the store of the nearest<VueFlow>or<VueFlowProvider>and throws outside of one.useVueFlow({ nodes, edges, … })→ pass these as props to<VueFlow>.useVueFlow("my-id")to access a flow from outside → wrap both in<VueFlowProvider>and calluseVueFlow()inside it.
The
idprop is now only used as a label (aria/debug), not to look up a flow. -
#5891
ca9c2fb- Add an explicitselectionOnDragprop and drop theselectionKeyCode={true}overload.Drawing a selection box on a plain pane drag (no key held) used to be expressed by setting
selectionKeyCodetotrue, which overloaded the key-code prop. It is now its own boolean prop:<!-- before --> <VueFlow :selection-key-code="true" :pan-on-drag="false" /> <!-- after --> <VueFlow :selection-on-drag="true" :pan-on-drag="false" />
selectionKeyCodeis once again just the key you hold to select (default"Shift").paneClickalso fires while selecting on drag (it was previously swallowed by the d3-zoom click handling). -
#5927
7b52b50- Numbers passed tofitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%) -
#5891
ca9c2fb- Use the parent expansion of@xyflow/systemforexpandParentnodes when dragging, measuring and resizing, matching@xyflow/react:- A child dragged past the top/left edge of its parent now grows the parent up/left, and its siblings are offset so they stay in place.
node.originis respected when a resize expands the parent.- Keyboard moves of nodes with an
extentno longer stop a full node width/height short of the boundary.
-
#5887
1d34f03-HandleElementis removed in favor ofHandleBounds, andEdgePositionsin favor ofEdgePosition. The<Handle>propsconnectableStart/connectableEndare renamed toisConnectableStart/isConnectableEnd,OnConnectStartParamsfields are now nullable, and the deprecatedProjecttype is no longer re-exported. -
#6136
1262688-updateNodeInternals(id)requires a node id or an array of ids; the no-argument form (which re-measured every node) is removed. -
#5900
ec0405e-useNodenow returns the user-facingNodeinstead of the enrichedInternalNode— useuseInternalNodeforinternals/measured. Itsidargument also accepts a ref or getter, matchinguseInternalNode. -
#5891
ca9c2fb-useHandlenow usesXYHandlefrom@xyflow/system, so drag-to-connect (auto-pan, connection radius, closest-handle resolution, drag threshold) behaves like@xyflow/reactand@xyflow/svelte. Its reconnect options are renamed:edgeUpdaterType→reconnectHandleType,onEdgeUpdate→onReconnect,onEdgeUpdateEnd→onReconnectEnd, andonReconnectStartis added. -
#5891
ca9c2fb- - Rename thenodeIdparam toid(useNodeConnections({ nodeId })→useNodeConnections({ id })). Like before, it is optional and falls back to the node id from theuseNodeIdcontext injection.handleIdnow requireshandleTypeto be set. PassinghandleIdon its own is a type error —handleIdis meaningless at runtime without ahandleType, and the type now points you at the fix. Runtime behavior is unchanged.
-
#5891
ca9c2fb- Split the store API.useVueFlow()now returns the flow instance (actions, computed getters and event hooks likeonNodeClickoronConnect) and no longer exposes the raw reactive state. The state moved touseVueFlowStore(), withstoreToRefs()to destructure it (Pinia-style).// before const { nodes, transform, nodeLookup, setViewport, onConnect } = useVueFlow() // after const { setViewport, onConnect } = useVueFlow() const store = useVueFlowStore() // reactive state (store.nodes, store.transform — no .value) const { nodes, transform } = storeToRefs(store) // refs for destructuring const { nodeLookup } = useVueFlowStore() // lookup Maps can be destructured directly
useVueFlowStore()returns the reactive state object, including thenodeLookup/parentLookup/edgeLookup/connectionLookupMaps. Reading it inside acomputed,watchor template is tracked.storeToRefs(store)turns the state fields into refs so destructuring stays reactive.- Computed getters (
getNodes,getEdges,getSelectedNodes,getSelectedEdges,viewport) and all event hooks stay onuseVueFlow().
A
<VueFlow>template ref now exposes the instance (VueFlowInstance). TheVueFlowStoretype is kept as an alias ofVueFlowInstance. -
#5891
ca9c2fb- Addeaseandinterpolateoptions to every viewport function.fitView,setViewport,setCenter,fitBounds,zoomTo,zoomInandzoomOutnow acceptease?: (t: number) => numberandinterpolate?: "smooth" | "linear"alongsidedurationto control the transition curve.The viewport option types now come from
@xyflow/system:FitViewParams→FitViewOptions(FitViewOptionsBasefrom@xyflow/system). Itsnodesoption takes node objects instead of ids —nodes?: string[]→nodes?: (Node | { id: string })[]— and the vestigialoffsetoption is removed (superseded bypadding).TransitionOptions→ViewportHelperFunctionOptions.
-
#6052
1afef23- Require Vue^3.5.27(peer dependency ofvueand@vue/reactivity). The default flowidis now generated withuseId(), and earlier 3.5 releases cannot resolve@xyflow/systemtypes indefineProps(vuejs/core#14236). -
#6077
f062cfb- Remove the array-basedapplyChanges,applyNodeChangesandapplyEdgeChangesexports, andapplyNodeChanges/applyEdgeChangeson theuseVueFlow()instance. UseapplyTo(elements)of the changeset instead.
-
#5891
ca9c2fb-fitViewandfitBoundsnow acceptPaddingfrom@xyflow/system: per-side values andpx/%units in addition to a number.Padding,PaddingWithUnitandPaddingUnitare re-exported. -
#5891
ca9c2fb- Add anariaLabelConfigprop to customize the accessibility text. Pass aPartial<AriaLabelConfig>(merged over the defaults) to override any of the node/edge a11y descriptions, the aria-live "moved node" message, and the Controls / MiniMap / Handle aria labels. As part of this, the Controls buttons and Handle — which previously had noaria-label— now get accessible labels, the Controls panel gets aControl Panellabel, and the MiniMap label default moves into the config.AriaLabelConfigis re-exported from the package root. -
#5891
ca9c2fb- Allow theming arrowhead markers with the--xy-edge-strokeCSS variable.defaultMarkerColornow acceptsnull— pass it (or leave thecolorof a marker unset) and the arrowhead inherits--xy-edge-strokeinstead of the hard-coded#b1b1b7, so markers can match themed edge colors. The marker polylines carry.arrow/.arrowclosedclasses and only set an inline color when one is provided; the open arrow strokes only, the closed arrow strokes and fills. The default (#b1b1b7) is unchanged. -
#5891
ca9c2fb- AddautoPanOnNodeFocus(defaulttrue), mirroring xyflow/react. When a node receives keyboard focus (Tab) and is not within the viewport, the viewport pans to center it — so keyboard navigation never lands on an off-screen node. Only reacts to keyboard focus (:focus-visible), not pointer/programmatic focus. Setauto-pan-on-node-focus="false"(or passfalse) to disable. -
#5891
ca9c2fb- Add anautoPanOnSelectionprop. Whentrue(the default), the viewport pans automatically as the cursor reaches the edge of the viewport while dragging a selection box, so you can select nodes beyond the visible area in one gesture. Set:auto-pan-on-selection="false"to keep the viewport fixed during selection. -
#6046
e0be409- AddbgColorandpatternClassNameprops to<Background>.colorandbgColorare applied as the--xy-background-pattern-color-propsand--xy-background-color-propscustom properties. -
#5891
ca9c2fb- Add a dark theme. The flow follows the system color scheme by default. Use theforceColorModeprop ("light" | "dark") to pin it. -
#5891
ca9c2fb- Add aconnectionDragThresholdprop. It is the distance in pixels the pointer must move from a handle before a connection line starts to drag — useful to prevent accidental connections when you just click a handle. Defaults to1; set it higher (e.g.connectionDragThreshold="25") to require a more deliberate drag, or0to start the connection immediately on pointer-down. Below the threshold, neitherconnectStartnorconnectEndfires. -
#6049
15da095- AddconnectionLineContainerStyleprop, applied to the<svg>the connection line is drawn in. -
#5891
ca9c2fb- Add a controlledviewportprop withv-model:viewportsupport, matching the controlled viewport of@xyflow/reactandbind:viewportof@xyflow/svelte.<VueFlow v-model:viewport="viewport" />
The bound value two-way binds to the viewport of the flow: setting it pans/zooms the flow (applied via
syncViewport, so no extra pan/zoom events fire), and it updates as the user interacts (viaupdate:viewport).defaultViewportremains the uncontrolled initial-viewport prop; useviewportwhen you want to own the viewport state. -
#6048
022cbc3- Add anorientationprop to<Controls>("vertical" | "horizontal", default"vertical"). -
#5910
87108d3- Added adebugprop. Whentrue, Vue Flow logs its events to the console as they fire (high-frequency events like move/drag/hover are skipped) — useful for seeing which events run. -
#5939
621f5d9- AddchangeParenttouseReactFlow,useSvelteFlowanduseVueFlow, to easily change the parent of a node without calculating a new position. -
#5891
ca9c2fb- Discriminate the#node-<type>/#edge-<type>slot props by node/edge type. Whennodes/edgesare typed as a discriminated union (e.g.(MyNodeA | MyNodeB)[]), each#node-<type>/#edge-<type>slot now narrows its props to theNodeProps/EdgePropsof the matching variant, so a custom node/edge component can safely type itsdatawithout a cast. GenericNode[]/Edge[]flows are unchanged (props stay broad), and arbitrary slot names remain allowed (a broadnode-${string}/edge-${string}fallback). Type-only. -
#5905
a5753cd- Tightened the edgelabeltype. Dropped the catch-allobjectfromEdgePropsandEdgeTextPropsso it matches the actual label type of edges (string | VNode | Component). -
#6050
bf75d26- ExportControlButtonPropsandControlButtonEmitstypes. -
#6050
d61a36a- ExportgetEdgeCenter, along with theGetBezierPathParams,GetSmoothStepPathParamsandGetStraightPathParamsparameter types. -
#5891
ca9c2fb- MoveBackground,Controls,MiniMap,NodeResizer,NodeResizeControl, andNodeToolbarcomponents into core pkg. -
#6048
022cbc3- Add abgColorprop to<MiniMap>, applied as the--xy-minimap-background-color-propscustom property. -
#5891
ca9c2fb- Add anautoScaleprop toNodeResizer/NodeResizeControl. Handle controls already scale up byMath.max(1 / zoom, 1)so they do not shrink below their base size when zooming out;autoScale(defaulttrue) now lets you opt out, previously the prop existed but had no effect. The handle is also centered via thetranslateCSS property instead oftransform, so the centering composes with the zoomscaleand the handle stays pinned to the node corner at any zoom. -
#6050
f94dad9- Add aresizeDirectionprop to<NodeResizeControl>("horizontal" | "vertical"). When set, the control only resizes the node along that axis; left unset it resizes in any direction, as before. -
#5891
ca9c2fb- Add theonBeforeDeleteprop and thedeleteElementsaction.deleteElements({ nodes, edges })also removes child nodes and connected edges, and resolves to{ deletedNodes, deletedEdges }.onBeforeDeleteruns before the Delete key anddeleteElementsremove anything: returnfalseto cancel,trueto continue or{ nodes, edges }to delete a subset. -
#5993
901b0e4- Addxy-theme.cssstylesheet (@xyflow/<lib>/xy-theme.css) that ships the xyflow default theme on top ofbase.css. -
#5891
ca9c2fb- Add astepPositionoption to smooth-step / step edges. SetpathOptions.stepPosition(0 = bend at source, 1 = at target, 0.5 = midpoint, the default) to control where the edge bends along its path. The path math comes fromgetSmoothStepPathfrom@xyflow/system; theSmoothStepEdgecomponent now forwards the option to it. -
#5891
ca9c2fb-ConnectionLineProps,RemoveNodes,RemoveEdgesandIsNodeIntersectingnow take theNodeType/EdgeTypeof the flow, so custom connection lines and updater functions get typed nodes and edges. -
#5904
1e7fa6b- TightenedBaseEdgeProps.labelfromanytostring | VNode | Component<EdgeTextProps>, matching the actual label type of edges. -
#5882
3334af0- AddnodesDelete,edgesDelete, anddeleteevents, matching@xyflow/react(onNodesDelete/onEdgesDelete/onDelete) and@xyflow/svelte(ondelete). They fire fromdeleteElements(the choke point for both the delete key and programmatic deletion) afteronBeforeDeletehas resolved the removed set —edgesDeletewith the removed edges,nodesDeletewith the removed nodes (each only when non-empty), anddeletewith{ nodes, edges }whenever anything was removed. Also exports theOnDeletehandler type alongsideOnBeforeDelete. -
#5914
96bfd42-<VueFlowProvider>now accepts the same options assetupVueFlow()to seed its store — passnodes,edges, or any otherVueFlowPropsand they become the initial values of the store. The seed is read once when the store is created.
-
#6046
e0be409- Correct the pattern offset of<Background>, which was calculated asoffset * zoom || 1 + gap / 2. That parses asoffset * zoom || (1 + gap / 2), so with the defaultoffsetof0the pattern sat one pixel off. -
#5891
ca9c2fb- Clear the visual nodes-selection box when no selected nodes remain.nodesSelectionActiveonly ever turns on via a user drag-select, but it could get stucktrueafter the selected nodes were removed (e.g. deleted) — so a later programmatic select would wrongly render theNodesSelectionrect around an unrelated node. Re-adopting nodes now turns it back off whenever the selection is empty. -
#6085
fc128ca- Improve rendering performance, especially while dragging large selections:- Node drag updates are batched to one per animation frame.
- Nodes, edges and the
<MiniMap>re-render less during drags. removeSelectedNodes/removeSelectedEdgesonly emit changes for elements that are actually selected.- Built-in edges no longer render their props (
source,sourceX,animated, …) as attributes on the<path>, andEdgeTextno longer re-measures its label on every position change.
-
#5945
7e4c422-EdgeWrappernow computes edge positions withgetEdgePositionfrom@xyflow/system(as@xyflow/reactand@xyflow/sveltedo) instead of a hand-rolled copy. It returnsnullwhen a node is not initialized or a handle cannot be resolved, so an edge between nodes that render no<Handle>draws nothing instead of a phantom line to the bounding box of the node. This also aligns handle resolution across connection modes with the other packages. -
#5914
a86e6e5- Dev warnings now link to the matching entry in the error reference, e.g.Help: https://vueflow.dev/error#NODE_TYPE_MISSING. -
#5891
ca9c2fb- Fix theincludeHiddenNodesoption offitViewbeing ignored. -
#5891
ca9c2fb- Defer an imperativefitView()until the nodes are measured. AfitView()call made before the nodes settle — e.g. right afteraddNodes()— used to frame only the already-measured nodes (getFitViewNodesskips unmeasured ones) and ignore the new ones. It now waits fornodesInitializedbefore fitting, so the fit always frames the current nodes. An empty flow resolves immediately (nothing to wait for). -
#5891
ca9c2fb- FixisNodeIntersectingwithpartially: falsewhen the area is fully contained in the node. Previously only a node fully inside the area counted, now containment in either direction does, matchinggetIntersectingNodes. -
#5881
9d13542-setEdges/addEdgesno longer drop edges whose source or target node is not in the store. PreviouslyvalidateEdgesdiscarded any edge with a missing endpoint at commit time, which silently deleted edges and made the order ofsetNodes/setEdgesmatter — adding edges before their nodes lost them. Edges are now kept andEdgeWrapperskips drawing them (emitting the existingEDGE_SOURCE_MISSING/EDGE_TARGET_MISSINGdev warning) until both nodes exist. TheisValidConnectiongate still runs whenever both endpoint nodes are resolvable. -
#5887
81d4b63- Multi-keyuseKeyPresscombinations now match regardless of the order keys are pressed. The unused type-guard overload onuseNodesData/useEdgesDatais removed. -
#6048
022cbc3- ThemaskStrokeWidthof<MiniMap>is now scaled by the view scale of the minimap. -
#6048
022cbc3-MiniMapNodeFuncmay now returnundefined— its signature is(node) => string | undefined— so a per-node callback can fall back to the themed default for that node. AnundefinednodeColor,nodeStrokeColorornodeClassNameno longer throws. -
#6048
022cbc3- The<svg>inside<MiniMap>now carries thevue-flow__minimap-svgclass. -
#5891
ca9c2fb- Fix the intermittentTS2589: Type instantiation is excessively deeperror on updates likenodes.value = nodes.value.map(...). Nodes and edges are now excluded from the VueUnwrapRef. -
#5891
ca9c2fb- Honorwidth/heightandinitialWidth/initialHeightin the node visibility gate and inline size. The node wrapper previously gated visibility onmeasuredalone, so a node sized viawidth/initialWidthstayedvisibility: hiddenuntil theResizeObservermeasured it, and in SSR (noResizeObserver) it never became visible. Visibility now usesnodeHasDimensionsfrom@xyflow/system(measured ?? width ?? initialWidth), and the inline size of the wrapper falls back throughinitialWidth/initialHeightbefore the node is measured (initialWidth/initialHeightare the SSR dimensions, since DOM cannot be measured server-side). -
#5891
ca9c2fb- Keep the current selection on a pane click whenelementsSelectableisfalse. Previously a pane click always cleared the selection; now a selection set before selection was disabled, or set programmatically, survives the click. The interactive reset is centralized in a new gatedresetSelectedElementsaction (a no-op whileelementsSelectableisfalse), distinct fromremoveSelectedNodes/removeSelectedEdges, which still clear unconditionally. -
#6115
b1ad016- Fire the pane context menu event when right-click panning is enabled (panOnDragincludes2). -
#5891
ca9c2fb- ExportResizeControlVariantas a value, not type-only. It is a runtime enum, but the bundled type declarations re-exported it through the NodeResizer barrel asexport type, soResizeControlVariant.Line/.Handlecould not be used as a value in TypeScript consumers. It is now re-exported directly from the package root as a value. -
#5891
ca9c2fb- A plain click on the pane no longer opens a selection box or firesselectionStart/selectionEnd. The selection (clearing the current selection +selectionStart) now begins only once the pointer moves past the click threshold (paneDragThreshold, or immediately while the selection key is held), andnodesSelectionActive/selectionEndonly update when a real selection drag happened — instead of resetting on every pointer-down and activating on every pointer-up. -
#6064
de1e4c5- Resolve the promises of animated viewport functions likefitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending -
#5891
ca9c2fb- Improve the return type ofuseNodesData. It now usesDistributivePickfrom@xyflow/systeminstead of a merged object type, so when you pass a union node type the result is a discriminated union — checking.typenarrows.data:const node = useNodesData<MyNode>(id) // MyNode = TextNode | NumberNode if (node.value?.type === "text") { node.value.data.text // narrowed to TextNode data }
For a single (non-union) node type the result is unchanged.
-
#6101
49a335e- Build the<Background>pattern element id aspattern-<flowId><id> -
#6101
63d077b- Holding the selection key now starts a selection box even when the drag begins over a node or edge. The element underneath no longer starts a drag of its own. A child marked withnokeystill opts out, and a secondary pointer no longer opens a box. -
#6101
c62aee5- Do not start a selection box on touch when panning is enabled. ApanOnDragbutton array only restricts mouse input, so a touch drag now pans, unless the selection key is held. -
Updated dependencies [
dff4dad,dae45aa,13bf20a,5d448e9,fbe2ba5,96b196f,69dc311,b872a5b,1d9b9cd,b1ad016,de1e4c5,bf27626,9fcddb8,5161767,615c5f6,de1e4c5,8849014,7b52b50,885ac9e]:- @xyflow/system@1.0.0
@xyflow/react@13.0.0
-
#6114
dff4dad- Align the connection APIs across all frameworks onNodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. - Add
getNodeConnectionstouseSvelteFlow. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
-
#6117
dae45aa-onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates -
#5915
96b196f- Remove requirement of parent nodes to appear before child nodes in the nodes array -
#5927
69dc311- Use 5% as new default padding forfitView, andfitBounds. -
#5866
479082d- Remove deprecateduseHandleConnectionshook. -
#5800
7eca9fd- ReplaceuseStorewithuseNodesStore,useEdgesStore,useViewportStore,useOptionsStore,useConnectionStoreanduseSelectionStore. They no longer accept an equality function, useuseShallowinstead. -
#5996
885ac9e- Performance: Move options, nodes, edges, selections and connection into separate stores. -
#6115
b1ad016- ReplacepaneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. -
#5843
9eb6929- Use system color mode by default, addforceColorModeto opt-out. -
#5556
9fcddb8- RemovenodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. -
#5987
615c5f6- Rename the measured handle geometry type fromHandletoHandleBoundsso it no longer collides with the<Handle />component. -
#5927
7b52b50- Numbers passed tofitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%) -
#5866
0d1893a- Require React 18 as minimal supported version -
#5944
5ff09ef- PassNodeChangeset/EdgeChangesetclass toonNodesChange/onEdgesChangeoronnodeschange/onedgeschange.
-
#5939
621f5d9- AddchangeParenttouseReactFlow,useSvelteFlowanduseVueFlow, to easily change the parent of a node without calculating a new position. -
#5978
bf83263- Elevate selected edges by default (elevateEdgesOnSelectnow defaults totrue), so overlapping edges can be reconnected by selecting them first. -
#5996
885ac9e- Performance: Add fine grained reactivity when subscribing to specific nodes and edges. -
#6029
b872a5b- Improve panning performance by avoiding a full style recalculation when the pane cursor changes. -
#5866
1a77ebf- Add style import from@xyflow/react/style.css. -
#5996
885ac9e- Performance: Add fine grained reactivity to handles when making a new connection -
#5993
901b0e4- Addxy-theme.cssstylesheet (@xyflow/<lib>/xy-theme.css) that ships the xyflow default theme on top ofbase.css. -
#5996
885ac9e- Performance: Compile library with React Compiler -
#5939
846d686- AdduseNodeanduseEdgehooks for subscribing to changes to specific nodes & edges
-
#5866
7da73f2- Include source maps and src folder in package. "Go to definition" now links to the source code instead of the generated types -
#6084
1d9b9cd- Fix resizing nodes with a fixed extent & a non-default origin. -
#6110
ebc2f5d- Avoid re-renderinguseNodesDataconsumers when only the position, selection or measurements of a node change. -
#5989
bf27626- Prevent jumping nodes when origin node option is used -
#6071
a3d15ed- Do not scan nodes and edges for selection changes while noonSelectionChangehandler is registered. -
#6064
de1e4c5- Resolve the promises of animated viewport functions likefitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending -
#6131
8849014- NarrowdatabytypewhenNodePropsreceives a union of node types. -
#6103
1cac28a- Fix missing edges when controlled node updates overlap with node measurement. -
#5996
885ac9e- Performance: Optimize processing of nodes & edges -
#6117
2e038ee- FixuseConnectionre-rendering on every pointermove even when a selector is passed -
Updated dependencies [
dff4dad,dae45aa,13bf20a,5d448e9,fbe2ba5,96b196f,69dc311,b872a5b,1d9b9cd,b1ad016,de1e4c5,bf27626,9fcddb8,5161767,615c5f6,de1e4c5,8849014,7b52b50,885ac9e]:- @xyflow/system@1.0.0
@xyflow/system@1.0.0
-
#6114
dff4dad- Align the connection APIs across all frameworks onNodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. - Add
getNodeConnectionstouseSvelteFlow. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
-
#6117
dae45aa-onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates -
#6115
b1ad016- ReplacepaneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. -
#6064
de1e4c5- ResolvePanZoomInstance.setViewportwithtruewhen the transition finishes andfalsewhen it gets interrupted. -
#5556
9fcddb8- RemovenodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. -
#5987
615c5f6- Rename the measured handle geometry type fromHandletoHandleBoundsso it no longer collides with the<Handle />component.
-
#6109
13bf20a- CallonConnectandonDisconnectofuseNodeConnectionsreliably and keep its result up to date when edges are added, removed, reconnected or replaced. -
#6074
5d448e9- Improve deletion performance for large graphs. -
#6119
fbe2ba5- RespectpanOnDragwhen panning with the middle mouse button on nodes, edges and selections. -
#5915
96b196f- Remove requirement of parent nodes to appear before child nodes in the nodes array -
#5927
69dc311- Use 5% as new default padding forfitView, andfitBounds. -
#6029
b872a5b- Improve panning performance by avoiding a full style recalculation when the pane cursor changes. -
#6084
1d9b9cd- Fix resizing nodes with a fixed extent & a non-default origin. -
#5989
bf27626- Prevent jumping nodes when origin node option is used -
#6111
5161767- Delete all descendants of a parent node, regardless of their order innodes -
#6064
de1e4c5- Resolve the promises of animated viewport functions likefitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending -
#6131
8849014- NarrowdatabytypewhenNodePropsreceives a union of node types. -
#5927
7b52b50- Numbers passed tofitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%) -
#5996
885ac9e- Performance: Optimize processing of nodes & edges
@xyflow/react@13.0.0
-
#6114
dff4dad- Align the connection APIs across all frameworks onNodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. - Add
getNodeConnectionstouseSvelteFlow. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
-
#6117
dae45aa-onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates -
#5915
96b196f- Remove requirement of parent nodes to appear before child nodes in the nodes array -
#5927
69dc311- Use 5% as new default padding forfitView, andfitBounds. -
#5866
479082d- Remove deprecateduseHandleConnectionshook. -
#5800
7eca9fd- ReplaceuseStorewithuseNodesStore,useEdgesStore,useViewportStore,useOptionsStore,useConnectionStoreanduseSelectionStore. They no longer accept an equality function, useuseShallowinstead. -
#5996
885ac9e- Performance: Move options, nodes, edges, selections and connection into separate stores. -
#6115
b1ad016- ReplacepaneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. -
#5843
9eb6929- Use system color mode by default, addforceColorModeto opt-out. -
#5556
9fcddb8- RemovenodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. -
#5987
615c5f6- Rename the measured handle geometry type fromHandletoHandleBoundsso it no longer collides with the<Handle />component. -
#5927
7b52b50- Numbers passed tofitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%) -
#5866
0d1893a- Require React 18 as minimal supported version -
#5944
5ff09ef- PassNodeChangeset/EdgeChangesetclass toonNodesChange/onEdgesChangeoronnodeschange/onedgeschange.
-
#5939
621f5d9- AddchangeParenttouseReactFlow,useSvelteFlowanduseVueFlow, to easily change the parent of a node without calculating a new position. -
#5978
bf83263- Elevate selected edges by default (elevateEdgesOnSelectnow defaults totrue), so overlapping edges can be reconnected by selecting them first. -
#5996
885ac9e- Performance: Add fine grained reactivity when subscribing to specific nodes and edges. -
#6029
b872a5b- Improve panning performance by avoiding a full style recalculation when the pane cursor changes. -
#5866
1a77ebf- Add style import from@xyflow/react/style.css. -
#5996
885ac9e- Performance: Add fine grained reactivity to handles when making a new connection -
#5993
901b0e4- Addxy-theme.cssstylesheet (@xyflow/<lib>/xy-theme.css) that ships the xyflow default theme on top ofbase.css. -
#5996
885ac9e- Performance: Compile library with React Compiler -
#5939
846d686- AdduseNodeanduseEdgehooks for subscribing to changes to specific nodes & edges
-
#5866
7da73f2- Include source maps and src folder in package. "Go to definition" now links to the source code instead of the generated types -
#6084
1d9b9cd- Fix resizing nodes with a fixed extent & a non-default origin. -
#6110
ebc2f5d- Avoid re-renderinguseNodesDataconsumers when only the position, selection or measurements of a node change. -
#5989
bf27626- Prevent jumping nodes when origin node option is used -
#6071
a3d15ed- Do not scan nodes and edges for selection changes while noonSelectionChangehandler is registered. -
#6064
de1e4c5- Resolve the promises of animated viewport functions likefitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending -
#6131
8849014- NarrowdatabytypewhenNodePropsreceives a union of node types. -
#6103
1cac28a- Fix missing edges when controlled node updates overlap with node measurement. -
#5996
885ac9e- Performance: Optimize processing of nodes & edges -
#6117
2e038ee- FixuseConnectionre-rendering on every pointermove even when a selector is passed -
Updated dependencies [
dff4dad,dae45aa,13bf20a,5d448e9,fbe2ba5,96b196f,69dc311,b872a5b,1d9b9cd,b1ad016,de1e4c5,bf27626,9fcddb8,5161767,615c5f6,de1e4c5,8849014,7b52b50,885ac9e]:- @xyflow/system@1.0.0
@xyflow/svelte@2.0.0
-
#6114
dff4dad- Align the connection APIs across all frameworks onNodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. - Add
getNodeConnectionstouseSvelteFlow. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
-
#6082
70615a3- Removed setters fromuseNodesanduseEdgesin favor of better change handling viaupdateNode&updateEdgeinuseSvelteFlow. -
#6117
dae45aa-onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates -
#5915
96b196f- Remove requirement of parent nodes to appear before child nodes in the nodes array -
#5927
69dc311- Use 5% as new default padding forfitView, andfitBounds. -
#6115
b1ad016- ReplacepaneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. -
#5843
9eb6929- Use system color mode by default, addforceColorModeto opt-out. -
#5556
9fcddb8- RemovenodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. -
#5987
615c5f6- Rename the measured handle geometry type fromHandletoHandleBoundsso it no longer collides with the<Handle />component. -
#5927
7b52b50- Numbers passed tofitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%) -
#5944
5ff09ef- PassNodeChangeset/EdgeChangesetclass toonNodesChange/onEdgesChangeoronnodeschange/onedgeschange. -
#5842
968d801- Hooks do not require to be $derived anymore and accept a function parameter instead.
-
#5866
1a77ebf- Add style import from@xyflow/svelte/style.css. -
#5939
621f5d9- AddchangeParenttouseReactFlow,useSvelteFlowanduseVueFlow, to easily change the parent of a node without calculating a new position. -
#6082
4bdeda0- Control and monitor any changes to your nodes & edges viaonnodeschange&onedgeschange. Clearing a changeset withchanges.clear()inonnodeschangeprevents automatic application of changes. Use it to manually manage changes to nodes & edges. -
#6029
b872a5b- Improve panning performance by avoiding a full style recalculation when the pane cursor changes. -
#5993
901b0e4- Addxy-theme.cssstylesheet (@xyflow/<lib>/xy-theme.css) that ships the xyflow default theme on top ofbase.css. -
#5939
846d686- AdduseNodeanduseEdgehooks for subscribing to changes to specific nodes & edges
-
#5866
7da73f2- Include source maps and src folder in package. "Go to definition" now links to the source code instead of the generated types -
#6064
de1e4c5- Stop an interrupted animatedfitViewfrom running again on every later nodes change, for example while dragging a node -
#6084
1d9b9cd- Fix resizing nodes with a fixed extent & a non-default origin. -
#6115
b1ad016- Fire the pane context menu event when right-click panning is enabled (panOnDragincludes2). -
#5989
bf27626- Prevent jumping nodes when origin node option is used -
#6064
de1e4c5- Resolve the promises of animated viewport functions likefitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending -
#6131
8849014- NarrowdatabytypewhenNodePropsreceives a union of node types. -
#5996
885ac9e- Performance: Optimize processing of nodes & edges -
Updated dependencies [
dff4dad,dae45aa,13bf20a,5d448e9,fbe2ba5,96b196f,69dc311,b872a5b,1d9b9cd,b1ad016,de1e4c5,bf27626,9fcddb8,5161767,615c5f6,de1e4c5,8849014,7b52b50,885ac9e]:- @xyflow/system@1.0.0
@xyflow/svelte@2.0.0
-
#6114
dff4dad- Align the connection APIs across all frameworks onNodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. - Add
getNodeConnectionstouseSvelteFlow. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
-
#6082
70615a3- Removed setters fromuseNodesanduseEdgesin favor of better change handling viaupdateNode&updateEdgeinuseSvelteFlow. -
#6117
dae45aa-onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates -
#5915
96b196f- Remove requirement of parent nodes to appear before child nodes in the nodes array -
#5927
69dc311- Use 5% as new default padding forfitView, andfitBounds. -
#6115
b1ad016- ReplacepaneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. -
#5843
9eb6929- Use system color mode by default, addforceColorModeto opt-out. -
#5556
9fcddb8- RemovenodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. -
#5987
615c5f6- Rename the measured handle geometry type fromHandletoHandleBoundsso it no longer collides with the<Handle />component. -
#5927
7b52b50- Numbers passed tofitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%) -
#5944
5ff09ef- PassNodeChangeset/EdgeChangesetclass toonNodesChange/onEdgesChangeoronnodeschange/onedgeschange. -
#5842
968d801- Hooks do not require to be $derived anymore and accept a function parameter instead.
-
#5866
1a77ebf- Add style import from@xyflow/svelte/style.css. -
#5939
621f5d9- AddchangeParenttouseReactFlow,useSvelteFlowanduseVueFlow, to easily change the parent of a node without calculating a new position. -
#6082
4bdeda0- Control and monitor any changes to your nodes & edges viaonnodeschange&onedgeschange. Clearing a changeset withchanges.clear()inonnodeschangeprevents automatic application of changes. Use it to manually manage changes to nodes & edges. -
#6029
b872a5b- Improve panning performance by avoiding a full style recalculation when the pane cursor changes. -
#5993
901b0e4- Addxy-theme.cssstylesheet (@xyflow/<lib>/xy-theme.css) that ships the xyflow default theme on top ofbase.css. -
#5939
846d686- AdduseNodeanduseEdgehooks for subscribing to changes to specific nodes & edges
-
#5866
7da73f2- Include source maps and src folder in package. "Go to definition" now links to the source code instead of the generated types -
#6064
de1e4c5- Stop an interrupted animatedfitViewfrom running again on every later nodes change, for example while dragging a node -
#6084
1d9b9cd- Fix resizing nodes with a fixed extent & a non-default origin. -
#6115
b1ad016- Fire the pane context menu event when right-click panning is enabled (panOnDragincludes2). -
#5989
bf27626- Prevent jumping nodes when origin node option is used -
#6064
de1e4c5- Resolve the promises of animated viewport functions likefitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending -
#6131
8849014- NarrowdatabytypewhenNodePropsreceives a union of node types. -
#5996
885ac9e- Performance: Optimize processing of nodes & edges -
Updated dependencies [
dff4dad,dae45aa,13bf20a,5d448e9,fbe2ba5,96b196f,69dc311,b872a5b,1d9b9cd,b1ad016,de1e4c5,bf27626,9fcddb8,5161767,615c5f6,de1e4c5,8849014,7b52b50,885ac9e]:- @xyflow/system@1.0.0
@xyflow/system@1.0.0
-
#6114
dff4dad- Align the connection APIs across all frameworks onNodeConnection.- Remove
getHandleConnections. UsegetNodeConnections({ nodeId, type, handleId })instead:idis renamed tohandleIdandtypeis optional. - Add
getNodeConnectionstouseSvelteFlow. HandleConnectiontype removed: useNodeConnectioninstead.
- Remove
-
#6117
dae45aa-onConnectEndandonReconnectEndnow receivetoin flow coordinates instead of screen coordinates -
#6115
b1ad016- ReplacepaneClickDistancewithpaneDragThreshold(default1). LikenodeDragThreshold, the pane only starts panning or selecting once the pointer has moved further than the threshold; otherwise it counts as a click. Works with every mouse button. -
#6064
de1e4c5- ResolvePanZoomInstance.setViewportwithtruewhen the transition finishes andfalsewhen it gets interrupted. -
#5556
9fcddb8- RemovenodeClickDistance. Whether a click on a node fires is now determined solely by whether a drag actually moved the node: clicks are suppressed only after a drag changed node positions. UsenodeDragThreshold(andsnapGrid) to control this. -
#5987
615c5f6- Rename the measured handle geometry type fromHandletoHandleBoundsso it no longer collides with the<Handle />component.
-
#6109
13bf20a- CallonConnectandonDisconnectofuseNodeConnectionsreliably and keep its result up to date when edges are added, removed, reconnected or replaced. -
#6074
5d448e9- Improve deletion performance for large graphs. -
#6119
fbe2ba5- RespectpanOnDragwhen panning with the middle mouse button on nodes, edges and selections. -
#5915
96b196f- Remove requirement of parent nodes to appear before child nodes in the nodes array -
#5927
69dc311- Use 5% as new default padding forfitView, andfitBounds. -
#6029
b872a5b- Improve panning performance by avoiding a full style recalculation when the pane cursor changes. -
#6084
1d9b9cd- Fix resizing nodes with a fixed extent & a non-default origin. -
#5989
bf27626- Prevent jumping nodes when origin node option is used -
#6111
5161767- Delete all descendants of a parent node, regardless of their order innodes -
#6064
de1e4c5- Resolve the promises of animated viewport functions likefitViewandsetCenterwithfalsewhen a user interaction or another viewport change interrupts the animation, instead of leaving them pending -
#6131
8849014- NarrowdatabytypewhenNodePropsreceives a union of node types. -
#5927
7b52b50- Numbers passed tofitViewOptions.paddingare interpreted as pixel values instead of legacy units. Use percentage values instead (0.1 ≈ 4.5%, 0.5 ≈ 16.7%, 1 ≈ 25%, 2 ≈ 33%) -
#5996
885ac9e- Performance: Optimize processing of nodes & edges