fix(core): use connecting handle to update connection (#1996)
Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
5
.changeset/giant-pants-jam.md
Normal file
5
.changeset/giant-pants-jam.md
Normal file
@@ -0,0 +1,5 @@
|
||||
---
|
||||
"@vue-flow/core": patch
|
||||
---
|
||||
|
||||
Use the connecting handle result when updating a connection, so we get an accurate connection position for `toPosition`.
|
||||
@@ -244,6 +244,7 @@ export function useHandle({
|
||||
}
|
||||
|
||||
const connectingHandle = closestHandle ?? result.toHandle
|
||||
|
||||
updateConnection(
|
||||
connectingHandle && isValid
|
||||
? rendererPointToPoint(
|
||||
@@ -254,7 +255,7 @@ export function useHandle({
|
||||
viewport.value,
|
||||
)
|
||||
: connectionPosition,
|
||||
result.toHandle,
|
||||
connectingHandle,
|
||||
getConnectionStatus(!!connectingHandle, isValid),
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user