Add cursor drop effect when dragging nodes/models onto graph (#2354)

This commit is contained in:
bymyself
2025-01-26 05:08:10 -07:00
committed by GitHub
parent cb356d50b8
commit 7bd8527bca

View File

@@ -247,6 +247,8 @@ watch(
)
usePragmaticDroppable(() => canvasRef.value, {
getDropEffect: (args): Exclude<DataTransfer['dropEffect'], 'none'> =>
args.source.data.type === 'tree-explorer-node' ? 'copy' : 'move',
onDrop: (event) => {
const loc = event.location.current.input
const dndData = event.source.data