fix(svelte): repair selection, add multi selection closes #3557

This commit is contained in:
moklick
2023-10-31 18:31:24 +01:00
parent ce1680ba71
commit d2b140ce5e
12 changed files with 204 additions and 117 deletions
+6 -8
View File
@@ -23,14 +23,12 @@ function useDrag({ nodeRef, disabled = false, noDragClassName, handleSelector, n
xyDrag.current = XYDrag({
domNode: nodeRef.current,
getStoreItems: () => store.getState(),
onNodeClick: () => {
if (nodeId) {
handleNodeClick({
id: nodeId,
store,
nodeRef: nodeRef as RefObject<HTMLDivElement>,
});
}
onNodeMouseDown: (id: string) => {
handleNodeClick({
id,
store,
nodeRef: nodeRef as RefObject<HTMLDivElement>,
});
},
onDragStart: () => {
setDragging(true);