From d219e3cd7e7a7baf798730a6d9381de55cd40cb9 Mon Sep 17 00:00:00 2001 From: Pete Matsyburka Date: Tue, 2 Jul 2024 13:17:39 +0300 Subject: [PATCH] do not move in preview --- app/javascript/template_builder/area.vue | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/app/javascript/template_builder/area.vue b/app/javascript/template_builder/area.vue index 5b72db8e..e018ca31 100644 --- a/app/javascript/template_builder/area.vue +++ b/app/javascript/template_builder/area.vue @@ -691,6 +691,10 @@ export default { this.$emit('start-drag') }, touchDrag (e) { + if (!this.editable) { + return + } + const page = this.$parent.$refs.mask.previousSibling const rect = page.getBoundingClientRect() @@ -732,6 +736,10 @@ export default { this.$emit('start-drag') }, mouseMove (e) { + if (!this.editable) { + return + } + this.isMoved = true const page = this.$parent.$refs.mask.previousSibling