diff --git a/core/core-frontend/src/custom-component/v-query/Component.vue b/core/core-frontend/src/custom-component/v-query/Component.vue index 1c4c893f33..c762516597 100644 --- a/core/core-frontend/src/custom-component/v-query/Component.vue +++ b/core/core-frontend/src/custom-component/v-query/Component.vue @@ -620,15 +620,7 @@ const marginRight = computed(() => { }) const autoStyle = computed(() => { - return { - position: 'absolute', - height: 100 / scale.value + '%!important', - width: 100 / scale.value + '%!important', - left: 50 * (1 - 1 / scale.value) + '%', // 放大余量 除以 2 - top: 50 * (1 - 1 / scale.value) + '%', // 放大余量 除以 2 - transform: 'scale(' + scale.value + ') translateZ(0)', - opacity: element.value?.style?.opacity || 1 - } as CSSProperties + return { zoom: scale.value } }) diff --git a/core/core-frontend/src/views/chart/components/views/components/ChartComponentS2.vue b/core/core-frontend/src/views/chart/components/views/components/ChartComponentS2.vue index b2a5f6a58d..bc01240514 100644 --- a/core/core-frontend/src/views/chart/components/views/components/ChartComponentS2.vue +++ b/core/core-frontend/src/views/chart/components/views/components/ChartComponentS2.vue @@ -604,12 +604,7 @@ onBeforeUnmount(() => { }) const autoStyle = computed(() => { - return { - height: 20 * scale.value + 8 + 'px', - width: 100 / scale.value + '%!important', - left: 50 * (1 - 1 / scale.value) + '%', // 放大余量 除以 2 - transform: 'scale(' + scale.value + ') translateZ(0)' - } + return { zoom: scale.value } }) const autoHeightStyle = computed(() => {