diff --git a/.vscode/config.code-snippets b/.vscode/config.code-snippets index 0d0b8e3..4796b30 100644 --- a/.vscode/config.code-snippets +++ b/.vscode/config.code-snippets @@ -3,7 +3,7 @@ "prefix": "module-config", "scope": "typescript", "body": [ - "import { ModuleConfig } from \"/@/cool\";", + "import type { ModuleConfig } from \"/@/cool\";", "", "export default (): ModuleConfig => {", " return {};", diff --git a/src/modules/base/config.ts b/src/modules/base/config.ts index 426b3ab..c86a833 100644 --- a/src/modules/base/config.ts +++ b/src/modules/base/config.ts @@ -2,7 +2,7 @@ import VueECharts from "vue-echarts"; import ElementPlus from "element-plus"; import { useStore } from "./store"; import { config } from "/@/config"; -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; import "element-plus/theme-chalk/src/index.scss"; import "./static/css/index.scss"; diff --git a/src/modules/chat/config.ts b/src/modules/chat/config.ts index ddd24c1..ec86391 100644 --- a/src/modules/chat/config.ts +++ b/src/modules/chat/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return { diff --git a/src/modules/cloud/config.ts b/src/modules/cloud/config.ts index 43ced0a..98bd2c6 100644 --- a/src/modules/cloud/config.ts +++ b/src/modules/cloud/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; import { CodeDeclare } from "./dict"; import { addDeclare } from "/@/plugins/editor-monaco"; diff --git a/src/modules/demo/config.ts b/src/modules/demo/config.ts index 6f31d56..5c3e17d 100644 --- a/src/modules/demo/config.ts +++ b/src/modules/demo/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return { diff --git a/src/modules/design/config.ts b/src/modules/design/config.ts index c2fc851..e8a67d3 100644 --- a/src/modules/design/config.ts +++ b/src/modules/design/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return { diff --git a/src/modules/dict/config.ts b/src/modules/dict/config.ts index 87d4b8b..8d2a998 100644 --- a/src/modules/dict/config.ts +++ b/src/modules/dict/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; import { useDict } from "./index"; export default (): ModuleConfig => { diff --git a/src/modules/helper/config.ts b/src/modules/helper/config.ts index 8d14efa..672e161 100644 --- a/src/modules/helper/config.ts +++ b/src/modules/helper/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; import { getRules } from "./utils"; export default (): ModuleConfig => { diff --git a/src/modules/space/config.ts b/src/modules/space/config.ts index 9be10d1..6a250d8 100644 --- a/src/modules/space/config.ts +++ b/src/modules/space/config.ts @@ -1,4 +1,6 @@ -export default () => { +import type { ModuleConfig } from "/@/cool"; + +export default (): ModuleConfig => { return { components: [ () => import("./components/space.vue"), diff --git a/src/modules/theme/config.ts b/src/modules/theme/config.ts index 3e97423..22dea33 100644 --- a/src/modules/theme/config.ts +++ b/src/modules/theme/config.ts @@ -1,7 +1,6 @@ import { setTheme } from "./utils"; -import { storage } from "/@/cool"; -import { ModuleConfig } from "../../cool/types"; import { config } from "/@/config"; +import { storage, type ModuleConfig } from "/@/cool"; import "element-plus/theme-chalk/dark/css-vars.css"; import "./static/css/index.scss"; diff --git a/src/modules/user/config.ts b/src/modules/user/config.ts index 47ae21a..fddae1f 100644 --- a/src/modules/user/config.ts +++ b/src/modules/user/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return {}; diff --git a/src/plugins/crud/config.ts b/src/plugins/crud/config.ts index 2922283..b8065a0 100644 --- a/src/plugins/crud/config.ts +++ b/src/plugins/crud/config.ts @@ -1,4 +1,4 @@ -import { Merge, ModuleConfig } from "/@/cool"; +import type { Merge, ModuleConfig } from "/@/cool"; // npm import Crud, { locale, setFocus } from "@cool-vue/crud"; diff --git a/src/plugins/distpicker/components/index.tsx b/src/plugins/distpicker/components/index.tsx index 32f24b9..91d4e47 100644 --- a/src/plugins/distpicker/components/index.tsx +++ b/src/plugins/distpicker/components/index.tsx @@ -1,4 +1,4 @@ -import { PropType, defineComponent } from "vue"; +import { type PropType, defineComponent } from "vue"; import data from "../data/pca.json"; export default defineComponent({ diff --git a/src/plugins/distpicker/config.ts b/src/plugins/distpicker/config.ts index 67ab468..8bda75c 100644 --- a/src/plugins/distpicker/config.ts +++ b/src/plugins/distpicker/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; import { registerFormHook } from "@cool-vue/crud"; // 注册hook diff --git a/src/plugins/editor-monaco/config.ts b/src/plugins/editor-monaco/config.ts index a742478..7c89362 100644 --- a/src/plugins/editor-monaco/config.ts +++ b/src/plugins/editor-monaco/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return { diff --git a/src/plugins/editor-preview/config.ts b/src/plugins/editor-preview/config.ts index edff83c..c8a4ec3 100644 --- a/src/plugins/editor-preview/config.ts +++ b/src/plugins/editor-preview/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return { diff --git a/src/plugins/editor-wang/config.ts b/src/plugins/editor-wang/config.ts index 2c9bcf0..03ba78b 100644 --- a/src/plugins/editor-wang/config.ts +++ b/src/plugins/editor-wang/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return { diff --git a/src/plugins/excel/config.ts b/src/plugins/excel/config.ts index cd96e85..93df13a 100644 --- a/src/plugins/excel/config.ts +++ b/src/plugins/excel/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return { diff --git a/src/plugins/upload/config.ts b/src/plugins/upload/config.ts index 17ef499..748456a 100644 --- a/src/plugins/upload/config.ts +++ b/src/plugins/upload/config.ts @@ -1,4 +1,6 @@ -export default () => { +import type { ModuleConfig } from "/@/cool"; + +export default (): ModuleConfig => { return { label: "文件上传", description: "基于 el-upload 封装的文件上传组件", diff --git a/src/plugins/view/config.ts b/src/plugins/view/config.ts index b27598c..c1ee905 100644 --- a/src/plugins/view/config.ts +++ b/src/plugins/view/config.ts @@ -1,4 +1,4 @@ -import { ModuleConfig } from "/@/cool"; +import type { ModuleConfig } from "/@/cool"; export default (): ModuleConfig => { return {