Fix issue that source node was also selected after duplicate

This commit is contained in:
Jan Oberhauser
2020-12-24 08:37:13 +01:00
parent 9dfcfc72bd
commit 75cca869b4
2 changed files with 9 additions and 1 deletions

View File

@@ -341,6 +341,14 @@ export const nodeBase = mixins(
}
},
mouseLeftClick (e: MouseEvent) {
// @ts-ignore
const path = e.path || (e.composedPath && e.composedPath());
for (let index = 0; index < path.length; index++) {
if (path[index].className && typeof path[index].className === 'string' && path[index].className.includes('no-select-on-click')) {
return;
}
}
if (!this.isTouchDevice) {
if (this.$store.getters.isActionActive('dragActive')) {
this.$store.commit('removeActiveAction', 'dragActive');