Merge pull request #4877 from xyflow/fix/intersection-origin2

Fix intersection for various node origins
This commit is contained in:
Moritz Klack
2024-12-09 17:27:27 +01:00
committed by GitHub
3 changed files with 9 additions and 5 deletions
+1 -2
View File
@@ -55,11 +55,10 @@ export function useReactFlow<NodeType extends Node = Node, EdgeType extends Edge
: nodeToUse.position;
const nodeWithPosition = {
id: nodeToUse.id,
...nodeToUse,
position,
width: nodeToUse.measured?.width ?? nodeToUse.width,
height: nodeToUse.measured?.height ?? nodeToUse.height,
data: nodeToUse.data,
};
return nodeToRect(nodeWithPosition);