Skip to content

Latest commit

 

History

History
1455 lines (759 loc) · 105 KB

CHANGELOG.md

File metadata and controls

1455 lines (759 loc) · 105 KB

@xyflow/react

13.0.2

Patch Changes

  • #6130 d0d3fd7 - Announce the new position, instead of the previous one, when moving a selected node with the arrow keys.

  • #6155 f7b8546 - EdgeToolbar: use the elevated zIndex so the toolbar stacks with its edge

13.0.1

Patch Changes

13.0.0

Major Changes

  • #6114 dff4dad - Align the connection APIs across all frameworks on NodeConnection.

    • Remove getHandleConnections. Use getNodeConnections({ nodeId, type, handleId }) instead: id is renamed to handleId and type is optional.
    • Add getNodeConnections to useSvelteFlow.
    • HandleConnection type removed: use NodeConnection instead.
  • #6117 dae45aa - onConnectEnd and onReconnectEnd now receive to in 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 for fitView, and fitBounds.

  • #5866 479082d - Remove deprecated useHandleConnections hook.

  • #5800 7eca9fd - Replace useStore with useNodesStore, useEdgesStore, useViewportStore, useOptionsStore, useConnectionStore and useSelectionStore. They no longer accept an equality function, use useShallow instead.

  • #5996 885ac9e - Performance: Move options, nodes, edges, selections and connection into separate stores.

  • #6115 b1ad016 - Replace paneClickDistance with paneDragThreshold (default 1). Like nodeDragThreshold, 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, add forceColorMode to opt-out.

  • #5556 9fcddb8 - Remove nodeClickDistance. 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. Use nodeDragThreshold (and snapGrid) to control this.

  • #5987 615c5f6 - Rename the measured handle geometry type from Handle to HandleBounds so it no longer collides with the <Handle /> component.

  • #5996 eaf5a2d - Remove lib ("react") entry from store.

  • #5927 7b52b50 - Numbers passed to fitViewOptions.padding are 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 - Pass NodeChangeset/EdgeChangeset class to onNodesChange/onEdgesChange or onnodeschange/onedgeschange.

  • #5866 1a77ebf - Remove UMD build.

Minor Changes

  • #5939 621f5d9 - Add changeParent to useReactFlow, useSvelteFlow and useVueFlow, to easily change the parent of a node without calculating a new position.

  • #5978 bf83263 - Elevate selected edges by default (elevateEdgesOnSelect now defaults to true), so overlapping edges can be reconnected by selecting them first.

  • #5844 861a6be - Exported styles now live in @layer xyflow.

  • #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 - Add xy-theme.css stylesheet (@xyflow/<lib>/xy-theme.css) that ships the xyflow default theme on top of base.css.

  • #5996 885ac9e - Performance: Compile library with React Compiler

  • #5939 846d686 - Add useNode and useEdge hooks for subscribing to changes to specific nodes & edges

  • #6099 66da96b - Add useEqualSelector hook

Patch Changes

12.12.1

Patch Changes

  • #6068 7813eeb - Cancel a pending click connection when clicking the pane and call onClickConnectEnd / onclickconnectend

  • #6097 d150c38 - Don't mutate the internal selection state

  • #5650 f7cddb9 - Infer the type of pathOptions in EdgeProps from the edge type instead of using any.

  • #6090 b235ea0 - Respect nodeOrigin in isNodeIntersecting and getIntersectingNodes when you pass a node object instead of { id }

  • #6054 c7d0fcb - Disconnect the ResizeObservers when a flow unmounts

  • Updated dependencies [d150c38, 8483a2f, c7d0fcb, 9dcbd29, cba335d]:

12.12.0

Minor Changes

  • #5998 91a4adf - Always fire onResizeEnd after onResizeStart

Patch Changes

12.11.6

Patch Changes

12.11.5

Patch Changes

12.11.4

Patch Changes

  • #5974 8c42922 - Minimap still works after ReactFlow remounts

  • #5962 cbf40b9 - Show log if user hides attribution in development

  • #5976 3319ef4 - Fix the MiniMap zooming out to include the origin when every node is hidden.

  • #5955 965ca70 - Fix MiniMap calling useCallback conditionally for onNodeClick.

12.11.3

Patch Changes

  • #5902 393d951 - Allow middle-mouse viewport panning to start from a selection rectangle.

  • #5889 ff126a0 - Fix extent: 'parent' not immediately resolving when parent has width or initialWidth.

  • #5943 d1def59 - Invoke an error if handle can not be found

  • #5947 2ba040f - Use correct nodeExtent for internal setNodes.

  • #5918 c5d7442 - Fix selection box appearing when dragging the pane via touch. Prefer touch panning over drag selection when selectionOnDrag is combined with mouse-button-specific panOnDrag settings.

  • #5922 392da00 - Allow Control to activate pane panning with a primary-button drag.

  • #5929 4c5d7d2 - Allow key combinations of three or more keys (e.g. 'Meta+Shift+s') for useKeyPress.

  • #5938 91a052f - Fix <Background /> pattern offset miscalculation.

  • Updated dependencies [393d951, ff126a0, e5d86bd, 392da00]:

12.11.2

Patch Changes

12.11.1

Patch Changes

  • #5815 87da45c - Fix FinalConnectionState type so it preserves the discriminated union.

  • #5823 a6afc91 - Update attribution link

  • #5824 6b1dac5 - Do not fire on pane click when connection ends on pane

  • #5818 4ddc2d8 - Provide the shared handle config (connectOnClick, noPanClassName, rfId) through context instead of subscribing to the store in every Handle, so a store update no longer runs a selector once per handle

  • #5817 8df250b - Reduce per-handle work on store updates by returning a shared connection state while no connection is in progress.

  • #5822 a6249de - Return stable reference for edge position when connected node gets deleted

  • Updated dependencies [ceb8604, 87da45c]:

12.11.0

Minor Changes

  • #5677 e6661de - Add autoPanOnSelection to auto-pan when user drags a selection close to the edge of the viewport.

Patch Changes

12.10.2

Patch Changes

12.10.1

Patch Changes

12.10.0

Minor Changes

Patch Changes

12.9.3

Patch Changes

12.9.2

Patch Changes

12.9.1

Patch Changes

12.9.0

Minor Changes

Patch Changes

12.8.6

Patch Changes

12.8.5

Patch Changes

12.8.4

Patch Changes

12.8.3

Patch Changes

12.8.2

Patch Changes

12.8.1

Patch Changes

12.8.0

Minor Changes

Patch Changes

12.7.1

Patch Changes

12.7.0

Minor Changes

Patch Changes

12.6.4

Patch Changes

12.6.3

Patch Changes

12.6.2

Patch Changes

12.6.1

Patch Changes

12.6.0

Minor Changes

  • #5219 4236adbc Thanks @moklick! - Add initialMinZoom, initialMaxZoom and initialFitViewOptions to ReactFlowProvider

  • #5227 a7d10ffc Thanks @moklick! - Add resizeDirection prop for the NodeResizeControl component

Patch Changes

12.5.6

Patch Changes

12.5.5

Patch Changes

12.5.4

Patch Changes

12.5.3

Patch Changes

12.5.2

Patch Changes

12.5.1

Patch Changes

12.5.0

Minor Changes

  • #5067 acba901d Thanks @peterkogo! - You can now express paddings in fitViewOptions as pixels ('30px'), as viewport percentages ('20%') and define different paddings for each side.

Patch Changes

12.4.4

Patch Changes

12.4.3

Patch Changes

12.4.2

Patch Changes

12.4.1

Patch Changes

12.4.0

Minor Changes

  • #4725 e10f53cf Thanks @peterkogo! - Add useNodeConnections hook to track all connections to a node. Can be filtered by handleType and handleId.

Patch Changes

12.3.6

Patch Changes

12.3.5

Patch Changes

12.3.4

Patch Changes

  • #4772 7f670ab0 Thanks @mistic! - Splits exports field in package.json to support an explicit resolution for browser, node and default to resolve issues with webpack esm module resolution.

  • Updated dependencies [7f670ab0]:

12.3.3

Patch Changes

12.3.2

Patch Changes

  • #4722 e816bb69 Thanks @moklick! - Fix internal behaviour that mutated user nodes which led to an issue with Redux and immer

12.3.1

Patch Changes

12.3.0

Minor Changes

  • #4477 d5592e75 Thanks @peterkogo! - Add getNodesBounds to useReactFlow/useSvelteFlow hook as the new recommended way of determining node bounds.

Patch Changes

12.2.1

Patch Changes

12.2.0

Minor Changes

Patch Changes

12.1.1

Patch Changes

12.1.0

Minor Changes

Patch Changes

12.0.4

Patch Changes

12.0.3

Patch Changes

12.0.2

Patch Changes

12.0.1

Patch Changes

12.0.0

React Flow 12 is finally out! With a new package name @xyflow/react!

Main features

  • SSR / SSG: you can define width, height and handles for the nodes. This makes it possible to render a flow on the server and hydrate on the client: SSR guide
    • Details: In v11, width and height were set by the library as soon as the nodes got measured. This still happens, but we are now using measured.width and measured.height to store this information. In the previous versions there was always a lot of confusion about width and height. It’s hard to understand, that you can’t use it for passing an actual width or height. It’s also not obvious that those attributes get added by the library. We think that the new implementation solves both of the problems: width and height are optional attributes that can be used to define dimensions and the measured dimensions are stored in measured.
  • Reactive Flows: The new hooks useHandleConnections and useNodesData and the new updateNode and updateNodeData functions can be used for managing the data flow between your nodes: computing flows guide
    • Details: Working with reactive flows is super common. You update node A and want to react on those changes in the connected node B. Until now everyone had to come up with a custom solution. With this version we want to change this and give you performant helpers to handle this. If you are excited about this, you can check out this example:
  • Dark mode and css variables: React Flow now comes with a built-in dark mode, that can be toggled by using the new colorMode prop (”light”, “dark” or “system”): dark mode example
    • Details: With this version we want to make it easier to switch between dark and light modes and give you a better starting point for dark flows. If you pass colorMode=”dark”, we add the class name “dark” to the wrapper and use it to adjust the styling. To make the implementation for this new feature easier on our ends, we switched to CSS variables for most of the styles. These variables can also be used in user land to customize a flow.

More features and updates

There is more! Besides the new main features, we added some minor things that were on our list for a long time. We also started to use TS docs for better docs. We already started to add some docs for some types and hooks which should improve the developer experience.

  • useConnection hook: With this hook you can access the ongoing connection. For example, you can use it for colorizing handles styling a custom connection line based on the current start / end handles.
  • Controlled viewport: This is an advanced feature. Possible use cases are to animate the viewport or round the transform for lower res screens for example. This features brings two new props: viewport and onViewportChange.
  • ViewportPortal component: This makes it possible to render elements in the viewport without the need to implement a custom node.
  • onDelete handler: We added a combined handler for onDeleteNodes and onDeleteEdges to make it easier to react to deletions.
  • onBeforeDelete handler: With this handler you can prevent/ manage deletions.
  • isValidConnection prop: This makes it possible to implement one validation function for all connections. It also gets called for programmatically added edges.
  • autoPanSpeed prop: For controlling the speed while auto panning.
  • Background component: add patternClassName prop to be able to style the background pattern by using a class name. This is useful if you want to style the background pattern with Tailwind for example.
  • onMove callback gets triggered for library-invoked viewport updates (like fitView or zoom-in)
  • deleteElements now returns deleted nodes and deleted edges
  • add origin attribute for nodes
  • add selectable attribute for edges
  • Node Resizer: child nodes don't move when the group is resized, extent and expand is recognized correctly
  • Correct types for BezierEdge, StepEdge, SmoothStepEdge and StraightEdge components
  • New edges created by the library only have sourceHandle and targetHandle attributes when those attributes are set. (We used to pass sourceHandle: null and targetHandle: null)
  • Edges do not mount/unmount when their z-index change
  • connection line knows about the target handle position so that the path is drawn correctly
  • nodeDragThreshold is 1 by default instead of 0
  • a better selection box usability (capture while dragging out of the flow)
  • add selectable, deletable, draggable and parentId to NodeProps
  • add a warning when styles not loaded

12.0.0-next.28

  • add paneDistanceClick prop (max distance between mousedown/up that will trigger a click)
  • returned nodes in onNodeDragStop are set to dragging=false

12.0.0-next.27

  • return Promises for setViewport, fitView, fitBounds and zoomTo to be able to await viewport update

12.0.0-next.26

  • add autoPanSpeed prop

12.0.0-next.25

  • useConnection returns ConnectionState with toNode and toHandle
  • add toNode and toHandle to custom connection line props
  • node origin is part of position absolute
  • refactor connection handling

12.0.0-next.24

  • fix window bug for SSR for real

12.0.0-next.23

  • fix window bug for SSR

12.0.0-next.22

  • ⚠️ rename updateEdge to reconnectEdge and related APIs #4373
  • revise selection usability (capture while dragging out of the flow)
  • use correct end handle position when drawing a connection lines
  • determine correct end positions for connection lines

12.0.0-next.21

  • fix node origin bug

12.0.0-next.20

  • add updateEdge and updateEdgeData helpers to useReactFlow
  • enable dynamic edge label updates
  • prevent zooming on mobile if zoomOnPinch is false
  • add straight edge to path built-in-types
  • abort drag when multiple touches are detected

12.0.0-next.19

  • update internals on node resizer updates
  • re-observe node when node.hidden is toggled
  • update updateNodeData argument type - thanks @ogroppo
  • add selectable, deletable and draggable to node and edge props
  • add parentId to node props
  • fix parent node lookup in evaluateAbsolutePosition- thanks @lcsfort

12.0.0-next.18

  • don't show nodeTypes warning if not necessary you've created a new nodeTypes or edgeTypes
  • add node resizer styles to base.css
  • remove HandleComponentProps type, only export HandleProps type
  • add warning when styles not loaded

12.0.0-next.17

  • fix broken defaultNodes
  • add string array to UpdateNodeInternals thanks @DenizUgur
  • pinch zoom on windows
  • drag for touch devices
  • return user node in node event handlers
  • cleanup useReactFlow
  • export KeyCode and Align type
  • remove Instance in favour of ReactFlowInstance type

12.0.0-next.16

Patch changes

  • fix batching for setNodes, updateNode, updateNodeData etc.
  • fix useNodesInitialized

12.0.0-next.15

Patch changes

  • re-observe nodes when using onlyRenderVisibleElements={true}
  • use correct positions for intersection helpers
  • fix minimap interaction for touch devices
  • pass user nodes to onSelectionChange instead of internal ones to work with Redux
  • call onEnd in XYResizer thanks @tonyf
  • cleanup getPositionWithOrigin usage
  • use setAttributes flag for dimension change when width/height should be set
  • use replace: false as the default for updateNode function

12.0.0-next.14

Patch changes

  • fix hidden nodes
  • use direction=ltr for outer wrapper to support rtl sites
  • allow pinch zoom even if preventScrolling=false
  • export node and edge change related types
  • only trigger dimensions updates when changes detected

12.0.0-next.13

⚠️ Breaking changes

  • rename node.parentNode to node.parentId
  • rename node.computed to node.measured
  • remove positionAbsolute from node.computed

Minor Changes

  • new helpers: useInternalNode hook, getInternalNode function

Patch changes

  • remove internalsSymbol (now called internals and only available for internal nodes)
  • handle parentExpand on library side instead of applyChanges
  • new type InternalNode

12.0.0-next.12

Patch changes

  • fix useNodesData: handle invalid node id thanks @saswatax
  • fix forwardRef: use custom fixForwardRef function
  • refactor intersection helpers to use passed node value

12.0.0-next.11

Patch changes

  • fix ref prop for ReactFlow and Handle component
  • unify Edge and Node type handling
  • fix safari: prevent selection of viewport
  • fix useNodesData hook to prevent re-renderings
  • fix edges: allow start at 0,0

12.0.0-next.10

⚠️ Breaking changes

  • useNodesData not only returns data objects but also the type and the id of the node
  • status class names for Handle components are slightly different. It's now "connectingfrom" and "connectingto" instead of "connecting"

Patch changes

  • better cursor defaults for the pane, nodes and edges
  • disableKeyboardA11y now also disables Enter and Escape for selecting/deselecting nodes and edges
  • fix bug where users couldn't drag a node after toggle nodes hidden attribute
  • add initialWidth and initialHeight node attributes for specifying initial dimensions for ssr
  • fix NodeResizer when used in combination with nodeOrigin

12.0.0-next.9

Patch changes

  • a better NodeResizer that works with subflows. Child nodes do not move when parent node gets resized and parent extent is taken into account
  • refactor setNodes batching
  • re-measure nodes when necessary
  • don't trigger drag start / end when node is not draggable

12.0.0-next.8

Patch changes

  • selection box is not interrupted by selectionKey being let go
  • fix OnNodeDrag type
  • do not use fallback handle if a specific id is being used
  • fix defaultEdgeOptions markers not being applied
  • fix getNodesBounds and add second param for passing options
  • fix expandParent for child nodes

12.0.0-next.7

Minor changes

  • add second option param to screenToFlowPosition for configuring if snapToGrid should be used

Patch changes

  • pass Node/ Edge types to changes thanks @FelipeEmos
  • use position instead of positionAbsolute for getNodesBounds
  • infer types for getIncomers, getOutgoers, updateEdge, addEdge and getConnectedEdges thanks @joeyballentine
  • refactor handles: prefix with flow id for handling nested flows
  • add comments for types like ReactFlowProps or Node for a better developer experience

12.0.0-next.6

Patch changes

  • fix deleteElements
  • refactor internal applyChanges
  • batch setNodes and setEdges from useReactFlow
  • add aria-label prop for <Controls />

12.0.0-next.5

Minor changes

  • fix applyChanges: handle multi changes for one node, deletions and expandParent
  • use XYResizer from @xyflow/system
  • add unit tests for applyNodeChanges and applyEdgeChanges

12.0.0-next.4

Minor changes

  • fix applyChanges: handle empty flows + addNodes/addEdges closes
  • cleanup exports

12.0.0-next.3

Minor changes

  • fix edges styles when using base.css

12.0.0-next.2

Minor changes

  • fix connection line rendering
  • fix multi handle

12.0.0-next.1

Minor changes

  • fix edge rendering

12.0.0-next.0

React Flow v12 is coming soon! We worked hard over the past months and tried to make as few breaking changes as possible (there are some). We are in no rush to release v12, so we’d be happy to hear any early feedback so we can adjust the API or redefine new features before launching stable v12. 🚀 The big topics for this version are:

  1. Support for SSG/ SSR: you can now render flows on the server
  2. Reactive flows: new hooks and helper functions to simplify data flows
  3. Dark mode: a new base style and easy way to switch between built in color modes

Svelte Flow had a big impact on this release as well. While combing through each line of React Flow, we created framework agnostic helpers, found bugs, and made some under the hood improvements. All of these changes are baked into the v12 release as a welcome side-effect of that launch. 🙌🏻 We also improved the performance for larger flows with the help of Ivan.

Migrate from 11 to 12

Before you can try out the new features, you need to do some minor updates:

  • A new npm package name: Our name changed from reactflow to @xyflow/react and the main component is no longer a default, but a named import:
    • v11: import ReactFlow from 'reactflow';
    • v12: import { ReactFlow } from '@xyflow/react';
  • Node attribute “computed”: All computed node values are now stored in node.computed
    • v11: node.width, node.height ,node.positionAbsolute
    • v12: node.computed.width, node.computed.height and node.computed.positionAbsolute . (node.width/ node.height can now be used for SSG)
  • Updating nodes: We are not supporting node updates with object mutations anymore. If you want to update a certain attribute, you need to create a new node.
    • v11:
      setNodes((nds) =>
        nds.map((node) => {
          node.hidden = true;
          return node;
        })
      );
    • v12:
      setNodes((nds) =>
        nds.map((node) => ({
          ...node,
          hidden: true,
        }))
      );
  • NodeProps: posX/posY is now called positionAbsoluteX/positionAbsoluteY
  • Typescript only: We simplified types and fixed issues about functions where users could pass a NodeData generic. The new way is to define your own node type for the whole app and then only use that one. The big advantage of this is, that you can have multiple node types with different data structures and always be able to distinguish by checking the node.type attribute.
    • v11: applyNodeChange<NodeData, NodeType>
    • v12: type MyNodeType = Node<{ value: number }, ‘number’> | Node<{ value: string }, ‘text’>; applyNodeChange<MyNodeType>
    • affected functions: useNodes, useNodesState, useEdgesState, applyNodeChange, onInit, applyEdgeChanges , MiniMapProps
  • Removal of deprecated functions:
    • getTransformForBounds (new name: getViewportForBounds),
    • getRectOfNodes (new name: getNodesBounds)
    • project (new name: screenToFlowPosition)
    • getMarkerEndId

Main features

Now that you successfully migrated to v12, you can use all the fancy features. As mentioned above, the biggest updates for v12 are:

  • SSR / SSG: you can define width, height and handles for the nodes. This makes it possible to render a flow on the server and hydrate on the client: codesandbox
    • Details: In v11, width and height were set by the library as soon as the nodes got measured. This still happens, but we are now using computed.width and computed.height to store this information. The positionAbsolute attribute also gets stored in computed . In the previous versions there was always a lot of confusion about width and height. It’s hard to understand, that you can’t use it for passing an actual width or height. It’s also not obvious that those attributes get added by the library. We think that the new implementation solves both of the problems: width and height are optional attributes that can be used to define dimensions and everything that is set by the library, is stored in computed.
  • Reactive Flows: The new hooks useHandleConnections and useNodesData and the new updateNode and updateNodeData functions can be used for managing the data flow between your nodes: codesandbox
    • Details: Working with reactive flows is super common. You update node A and want to react on those changes in the connected node B. Until now everyone had to come up with a custom solution. With this version we want to change this and give you performant helpers to handle this. If you are excited about this, you can check out this example:
  • Dark mode and css variables: React Flow now comes with a built-in dark mode, that can be toggled by using the new colorMode prop (”light”, “dark” or “system”): codesandbox
    • Details: With this version we want to make it easier to switch between dark and light modes and give you a better starting point for dark flows. If you pass colorMode=”dark”, we add the class name “dark” to the wrapper and use it to adjust the styling. To make the implementation for this new feature easier on our ends, we switched to CSS variables for most of the styles. These variables can also be used in user land to customize a flow.

More features and updates

There is more! Besides the new main features, we added some minor things that were on our list for a long time. We also started to use TS docs for better docs. We already started to add some docs for some types and hooks which should improve the developer experience.

  • useConnection hook: This hook makes it possible to handle an ongoing connection. For example, you can use it for colorizing handles.
  • onDelete handler: We added a combined handler for onDeleteNodes and onDeleteEdges to make it easier to react to deletions.
  • isValidConnection prop: This makes it possible to implement one validation function for all connections. It also gets called for programmatically added edges.
  • Controlled viewport: This is definitely an advanced feature. Possible use cases are to animate the viewport or round the transform for lower res screens for example. This features brings two new props: viewport and onViewportChange.
  • ViewportPortal component: This makes it possible to render elements in the viewport without the need to implement a custom node.
  • Background component: add patternClassName to be able to style the background pattern by using a class name. This is useful if you want to style the background pattern with Tailwind for example.
  • onMove callback gets triggered for library-invoked viewport updates (like fitView or zoom-in)
  • deleteElements now returns deleted nodes and deleted edges
  • add origin attribute for nodes
  • add selectable attribute for edges
  • Correct types for BezierEdge, StepEdge, SmoothStepEdge and StraightEdge components
  • New edges created by the library only have sourceHandle and targetHandle attributes when those attributes are set. (We used to pass sourceHandle: null and targetHandle: null)
  • Edges do not mount/unmount when their z-index change

Internal changes

These changes are not really user-facing, but it could be important for folks who are working with the React Flow store:

  • The biggest internal change is that we created a new package @xyflow/system with framework agnostic helpers that can be used be React Flow and Svelte Flow
    • XYDrag for handling dragging node(s) and selection
    • XYPanZoom for controlling the viewport panning and zooming
    • XYHandle for managing new connections
  • We replaced the nodeInternals map with a nodes array. We added a new nodeLookup map that serves as a lookup, but we are not creating a new map object on any change so it’s really only useful as a lookup.
  • We removed connectionNodeId, connectionHandleId, connectionHandleType from the store and added connectionStartHandle.nodeId, connectionStartHandle.handleId, …
  • add data-id to edges

With v12 the reactflow package was renamed to @xyflow/react - you can find the v11 source and the reactflow changelog on the v11 branch.