diff --git a/src/components/Handle/Handle.vue b/src/components/Handle/Handle.vue index 79d54de0..323a6452 100644 --- a/src/components/Handle/Handle.vue +++ b/src/components/Handle/Handle.vue @@ -4,7 +4,7 @@ import { Position } from '../../types' import { NodeId } from '../../context' import type { HandleProps } from '../../types/components' -const { id } = useVueFlow() +const { id, hooks } = useVueFlow() const props = withDefaults(defineProps(), { id: '', type: 'source', @@ -16,7 +16,9 @@ const nodeId = inject(NodeId, '') const handler = useHandle() const onMouseDownHandler = (event: MouseEvent) => - handler(event, props.id, nodeId, props.type === 'target', props.isValidConnection) + handler(event, props.id, nodeId, props.type === 'target', props.isValidConnection, undefined, (connection) => + hooks.value.connect.trigger(connection), + )