From 8263fddf86f05259b3c10e2509e4c9c10882acb2 Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Mon, 14 Apr 2025 15:41:44 +0800 Subject: [PATCH] =?UTF-8?q?refactor(=E7=A7=BB=E5=8A=A8=E7=AB=AF):=20?= =?UTF-8?q?=E7=A7=BB=E5=8A=A8=E7=AB=AF=E5=9B=BE=E8=A1=A8=E5=9C=A8tab?= =?UTF-8?q?=E5=86=85=E8=BF=9B=E8=A1=8C=E4=BF=AE=E6=94=B9=E6=97=B6=EF=BC=8C?= =?UTF-8?q?=E5=A2=9E=E5=8A=A0tab=E5=86=85=E5=9B=BE=E8=A1=A8=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=E5=90=8C=E6=AD=A5=E5=8A=9F=E8=83=BD?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../canvas/ComponentWrapper.vue | 44 +++++++++++++++++-- 1 file changed, 40 insertions(+), 4 deletions(-) diff --git a/core/core-frontend/src/components/data-visualization/canvas/ComponentWrapper.vue b/core/core-frontend/src/components/data-visualization/canvas/ComponentWrapper.vue index b714f5c37e..2e940cdeac 100644 --- a/core/core-frontend/src/components/data-visualization/canvas/ComponentWrapper.vue +++ b/core/core-frontend/src/components/data-visualization/canvas/ComponentWrapper.vue @@ -16,7 +16,9 @@ import { isDashboard, isMainCanvas } from '@/utils/canvasUtils' import { XpackComponent } from '@/components/plugin' import { useAppStoreWithOut } from '@/store/modules/app' import DePreviewPopDialog from '@/components/visualization/DePreviewPopDialog.vue' +import Icon from '../../icon-custom/src/Icon.vue' const appStore = useAppStoreWithOut() +import replaceOutlined from '@/assets/svg/icon_replace_outlined.svg' const componentWrapperInnerRef = ref(null) const componentEditBarRef = ref(null) @@ -168,14 +170,14 @@ const handleInnerMouseDown = e => { // do setCurComponent if (showPosition.value.includes('multiplexing')) { componentEditBarRef.value.multiplexingCheckOut() - e.stopPropagation() - e.preventDefault() + e?.stopPropagation() + e?.preventDefault() } if (['popEdit', 'preview'].includes(showPosition.value) || dvMainStore.mobileInPc) { onClick(e) if (e.target?.className?.includes('ed-input__inner')) return - e.stopPropagation() - e.preventDefault() + e?.stopPropagation() + e?.preventDefault() } } @@ -384,6 +386,21 @@ const commonParams = computed(() => { eventType: config.value.events.type } }) + +const showCheck = computed(() => { + return dvMainStore.mobileInPc && showPosition.value === 'edit' +}) + +const updateFromMobile = (e, type) => { + if (type === 'syncPcDesign') { + e.preventDefault() + e.stopPropagation() + } + useEmitt().emitter.emit('onMobileStatusChange', { + type: type, + value: config.value.id + }) +}