refactor(core): cleanup useHandle and set status on actions
Signed-off-by: braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
@@ -33,7 +33,6 @@ export default function useHandle({
|
||||
connectionRadius,
|
||||
connectOnClick,
|
||||
connectionClickStartHandle,
|
||||
connectionStatus,
|
||||
nodesConnectable,
|
||||
defaultEdgeOptions,
|
||||
autoPanOnConnect,
|
||||
@@ -114,8 +113,6 @@ export default function useHandle({
|
||||
event,
|
||||
)
|
||||
|
||||
connectionStatus.value = null
|
||||
|
||||
emits.connectStart({ event, nodeId, handleId, handleType })
|
||||
|
||||
function onPointerMove(event: MouseEvent | TouchEvent) {
|
||||
@@ -155,10 +152,9 @@ export default function useHandle({
|
||||
viewport.value,
|
||||
)
|
||||
: connectionPosition,
|
||||
getConnectionStatus(!!prevClosestHandle, result.isValid),
|
||||
)
|
||||
|
||||
connectionStatus.value = getConnectionStatus(!!prevClosestHandle, isValid)
|
||||
|
||||
if (!prevClosestHandle) return resetRecentHandle(prevActiveHandle)
|
||||
|
||||
connection = result.connection
|
||||
|
||||
Reference in New Issue
Block a user