From 79d47c16889e9fc526b79e6eda93ceaa4f9189a6 Mon Sep 17 00:00:00 2001 From: Mutasem Date: Wed, 3 Nov 2021 17:08:38 +0100 Subject: [PATCH] increase input margin --- packages/editor-ui/src/views/NodeView.vue | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/packages/editor-ui/src/views/NodeView.vue b/packages/editor-ui/src/views/NodeView.vue index ed47d8105c..71ec4d31d4 100644 --- a/packages/editor-ui/src/views/NodeView.vue +++ b/packages/editor-ui/src/views/NodeView.vue @@ -1485,9 +1485,10 @@ export default mixins( return; } + const inputMargin = 24; const intersecting = nodes.find((element: Element) => { const {top, left, right, bottom} = element.getBoundingClientRect(); - if (top <= e.pageY && bottom >= e.pageY && left <= e.pageX && right >= e.pageX) { + if (top <= e.pageY && bottom >= e.pageY && (left - inputMargin) <= e.pageX && right >= e.pageX) { const nodeName = (element as HTMLElement).dataset['name']; const node = this.$store.getters.getNodeByName(nodeName) as INodeUi | null; if (node) {