Merge pull request #3822 from xyflow/refactor/on-node-drag-types
refactor(types): OnNodeDrag
This commit is contained in:
@@ -79,7 +79,6 @@ export {
|
||||
type OnError,
|
||||
type NodeProps,
|
||||
type NodeOrigin,
|
||||
type OnNodeDrag,
|
||||
type OnSelectionDrag,
|
||||
Position,
|
||||
type XYPosition,
|
||||
|
||||
@@ -15,7 +15,6 @@ import {
|
||||
type XYPosition,
|
||||
type CoordinateExtent,
|
||||
type UpdateConnection,
|
||||
type NodeBase,
|
||||
type NodeDragItem,
|
||||
errorMessages
|
||||
} from '@xyflow/system';
|
||||
@@ -67,7 +66,7 @@ export function createStore({
|
||||
const updateNodePositions: UpdateNodePositions = (nodeDragItems, dragging = false) => {
|
||||
store.nodes.update((nds) => {
|
||||
return nds.map((node) => {
|
||||
const nodeDragItem = (nodeDragItems as Array<NodeBase | NodeDragItem>).find(
|
||||
const nodeDragItem = (nodeDragItems as Array<Node | NodeDragItem>).find(
|
||||
(ndi) => ndi.id === node.id
|
||||
);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user