From b78a75de9bf96604d92f0731283d0039dbcd98ae Mon Sep 17 00:00:00 2001 From: wangjiahao <1522128093@qq.com> Date: Tue, 5 Nov 2024 15:26:41 +0800 Subject: [PATCH] =?UTF-8?q?refactor(=E4=BB=AA=E8=A1=A8=E6=9D=BF=E3=80=81?= =?UTF-8?q?=E6=95=B0=E6=8D=AE=E5=A4=A7=E5=B1=8F):=20=E4=BC=98=E5=8C=96?= =?UTF-8?q?=E5=85=A8=E5=B1=8F=E6=BB=9A=E5=8A=A8=E6=9D=A1=E6=A0=B7=E5=BC=8F?= =?UTF-8?q?=EF=BC=8C=E7=A7=BB=E5=8A=A8=E7=AB=AF=E6=8F=90=E7=A4=BA=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F=E7=AD=89=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../component-background/BackgroundOverallCommon.vue | 1 - .../src/custom-component/common/CommonAttr.vue | 1 + .../editor-style/components/TooltipSelector.vue | 11 ++++++++--- .../src/views/data-visualization/DvPreview.vue | 3 +++ .../src/views/data-visualization/PreviewCanvas.vue | 7 +++---- 5 files changed, 15 insertions(+), 8 deletions(-) diff --git a/core/core-frontend/src/components/visualization/component-background/BackgroundOverallCommon.vue b/core/core-frontend/src/components/visualization/component-background/BackgroundOverallCommon.vue index 57570f42e6..cd024dff68 100644 --- a/core/core-frontend/src/components/visualization/component-background/BackgroundOverallCommon.vue +++ b/core/core-frontend/src/components/visualization/component-background/BackgroundOverallCommon.vue @@ -325,7 +325,6 @@ const upload = file => { } const onBackgroundChange = () => { - snapshotStore.recordSnapshotCacheToMobile('commonBackground') emits('onBackgroundChange', state.commonBackground) } diff --git a/core/core-frontend/src/custom-component/common/CommonAttr.vue b/core/core-frontend/src/custom-component/common/CommonAttr.vue index bf406a57db..2016d359df 100644 --- a/core/core-frontend/src/custom-component/common/CommonAttr.vue +++ b/core/core-frontend/src/custom-component/common/CommonAttr.vue @@ -53,6 +53,7 @@ const dashboardActive = computed(() => { const onBackgroundChange = val => { element.value.commonBackground = val + snapshotStore.recordSnapshotCacheToMobile('commonBackground') emits('onAttrChange', { custom: 'commonBackground' }) } diff --git a/core/core-frontend/src/views/chart/components/editor/editor-style/components/TooltipSelector.vue b/core/core-frontend/src/views/chart/components/editor/editor-style/components/TooltipSelector.vue index 174f6fec9c..d4d21a4727 100644 --- a/core/core-frontend/src/views/chart/components/editor/editor-style/components/TooltipSelector.vue +++ b/core/core-frontend/src/views/chart/components/editor/editor-style/components/TooltipSelector.vue @@ -36,7 +36,7 @@ const props = defineProps({ } }) const dvMainStore = dvMainStoreWithOut() -const { batchOptStatus } = storeToRefs(dvMainStore) +const { batchOptStatus, mobileInPc } = storeToRefs(dvMainStore) const predefineColors = COLOR_PANEL const toolTip = computed(() => { return props.themes === 'dark' ? 'ndark' : 'dark' @@ -45,7 +45,12 @@ const emit = defineEmits(['onTooltipChange', 'onExtTooltipChange']) const curSeriesFormatter = ref>({}) const quotaData = ref(inject('quotaData')) const showSeriesTooltipFormatter = computed(() => { - return showProperty('seriesTooltipFormatter') && !batchOptStatus.value && props.chart.id + return ( + showProperty('seriesTooltipFormatter') && + !batchOptStatus.value && + !mobileInPc.value && + props.chart.id + ) }) // 切换图表类型直接重置为默认 @@ -488,7 +493,7 @@ onMounted(() => { -
+
diff --git a/core/core-frontend/src/views/data-visualization/PreviewCanvas.vue b/core/core-frontend/src/views/data-visualization/PreviewCanvas.vue index d9680094d2..7b509cdb7a 100644 --- a/core/core-frontend/src/views/data-visualization/PreviewCanvas.vue +++ b/core/core-frontend/src/views/data-visualization/PreviewCanvas.vue @@ -205,6 +205,9 @@ defineExpose({