diff --git a/src/views/chart/ContentConfigurations/components/ChartEvent/index.vue b/src/views/chart/ContentConfigurations/components/ChartEvent/index.vue
index 05e5ce4d..6b18e79b 100644
--- a/src/views/chart/ContentConfigurations/components/ChartEvent/index.vue
+++ b/src/views/chart/ContentConfigurations/components/ChartEvent/index.vue
@@ -5,6 +5,7 @@
组件 id:
{{ targetData.id }}
+
@@ -12,6 +13,7 @@
diff --git a/src/views/preview/index.vue b/src/views/preview/index.vue
index e11a3092..4209edab 100644
--- a/src/views/preview/index.vue
+++ b/src/views/preview/index.vue
@@ -1,5 +1,5 @@
-
@@ -36,25 +36,30 @@ import { useScale } from './hooks/useScale.hook'
import { useStore } from './hooks/useStore.hook'
import { PreviewScaleEnum } from '@/enums/styleEnum'
import type { ChartEditStorageType } from './index.d'
+import { useChartEditStore } from '@/store/modules/chartEditStore/chartEditStore'
-const localStorageInfo: ChartEditStorageType = getSessionStorageInfo() as ChartEditStorageType
-setTitle(`预览-${localStorageInfo.editCanvasConfig.projectName}`)
+// const localStorageInfo: ChartEditStorageType = getSessionStorageInfo() as ChartEditStorageType
+
+const chartEditStore = useChartEditStore() as unknown as ChartEditStorageType
+getSessionStorageInfo()
+
+setTitle(`预览-${chartEditStore.editCanvasConfig.projectName}`)
const previewRefStyle = computed(() => {
return {
- ...getEditCanvasConfigStyle(localStorageInfo.editCanvasConfig),
- ...getFilterStyle(localStorageInfo.editCanvasConfig)
+ ...getEditCanvasConfigStyle(chartEditStore.editCanvasConfig),
+ ...getFilterStyle(chartEditStore.editCanvasConfig)
}
})
const showEntity = computed(() => {
- const type = localStorageInfo.editCanvasConfig.previewScaleType
+ const type = chartEditStore.editCanvasConfig.previewScaleType
return type === PreviewScaleEnum.SCROLL_Y || type === PreviewScaleEnum.SCROLL_X
})
-useStore(localStorageInfo)
-const { entityRef, previewRef } = useScale(localStorageInfo)
-const { show } = useComInstall(localStorageInfo)
+useStore(chartEditStore)
+const { entityRef, previewRef } = useScale(chartEditStore)
+const { show } = useComInstall(chartEditStore)