Merge branch 'dev' into master-fetch-dev

This commit is contained in:
奔跑的面条
2023-09-13 10:44:28 +08:00
15 changed files with 202 additions and 110 deletions
@@ -182,20 +182,16 @@ export const useChartEditStore = defineStore({
},
getComponentList(): Array<CreateComponentType | CreateComponentGroupType> {
return this.componentList
},
// 获取需要存储的数据项
}
},
actions: {
// * 获取需要存储的数据项
getStorageInfo(): ChartEditStorage {
return {
[ChartEditStoreEnum.EDIT_CANVAS_CONFIG]: this.getEditCanvasConfig,
[ChartEditStoreEnum.COMPONENT_LIST]: this.getComponentList,
[ChartEditStoreEnum.REQUEST_GLOBAL_CONFIG]: this.getRequestGlobalConfig
}
}
},
actions: {
// * 设置 peojectInfo 数据项
setProjectInfo<T extends keyof ProjectInfoType, K extends ProjectInfoType[T]>(key: T, value: K) {
this.projectInfo[key] = value
},
// * 设置 editCanvas 数据项
setEditCanvas<T extends keyof EditCanvasType, K extends EditCanvasType[T]>(key: T, value: K) {