fix: todo in useHandle
* edge update end only emits the mouse event, not the edge Signed-off-by: Braks <78412429+bcakmakoglu@users.noreply.github.com>
This commit is contained in:
@@ -156,10 +156,7 @@ export default () => {
|
||||
|
||||
hooks.connectEnd.trigger(event)
|
||||
|
||||
if (elementEdgeUpdaterType) {
|
||||
// todo fix missing edge
|
||||
hooks.edgeUpdateEnd.trigger({ event } as any)
|
||||
}
|
||||
if (elementEdgeUpdaterType) hooks.edgeUpdateEnd.trigger(event)
|
||||
|
||||
resetRecentHandle(recentHoveredHandle)
|
||||
store.setConnectionNodeId({ connectionNodeId: undefined, connectionHandleId: undefined, connectionHandleType: undefined })
|
||||
|
||||
+1
-1
@@ -45,7 +45,7 @@ export interface FlowEvents {
|
||||
edgeDoubleClick: { event: MouseEvent; edge: Edge }
|
||||
edgeClick: { event: MouseEvent; edge: Edge }
|
||||
edgeUpdateStart: { event: MouseEvent; edge: Edge }
|
||||
edgeUpdateEnd: { event: MouseEvent; edge: Edge }
|
||||
edgeUpdateEnd: MouseEvent
|
||||
}
|
||||
|
||||
export type FlowHooks = { [key in keyof FlowEvents]: FlowHook<FlowEvents[key]> }
|
||||
|
||||
Reference in New Issue
Block a user