From a7a57782bbaadad342f592331b7b9d49aa0e62de Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Tue, 18 Apr 2023 12:04:26 +0200 Subject: [PATCH] fix(editor): Fix moving canvas on middle click preventing lasso selection (#5996) :bug: Prevent moving canvas on middle click --- packages/editor-ui/src/mixins/moveNodeWorkflow.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/editor-ui/src/mixins/moveNodeWorkflow.ts b/packages/editor-ui/src/mixins/moveNodeWorkflow.ts index c72264767c8b2..d35a46b8645d9 100644 --- a/packages/editor-ui/src/mixins/moveNodeWorkflow.ts +++ b/packages/editor-ui/src/mixins/moveNodeWorkflow.ts @@ -39,7 +39,7 @@ export const moveNodeWorkflow = mixins(deviceSupportHelpers).extend({ return; } - // Don't indicate move start just yet if middle button is pressed + // Prevent moving canvas on anything but middle button if (e.button !== 1) { this.uiStore.nodeViewMoveInProgress = true; } @@ -77,7 +77,7 @@ export const moveNodeWorkflow = mixins(deviceSupportHelpers).extend({ } // Signal that moving canvas is active if middle button is pressed and mouse is moved - if (e.button === 1) { + if (e.buttons === 4) { this.uiStore.nodeViewMoveInProgress = true; }