dlzn-ui 1.39.0 → 1.40.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -2,7 +2,7 @@ import { basename, resolve } from "node:path";
2
2
  import { globSync } from "tinyglobby";
3
3
  //#region node/aliasElementPlus.ts
4
4
  var aliasElementPlus_default = (root) => {
5
- const elementPlusCss = globSync(resolve(root, "src/plugins/element-plus/theme-chalk/*.css"));
5
+ const elementPlusCss = globSync("src/plugins/element-plus/theme-chalk/*.css", { cwd: root });
6
6
  const arr = [];
7
7
  elementPlusCss.forEach((file) => {
8
8
  const _basename = basename(file);
@@ -1,10 +1,10 @@
1
1
  import { upperFirst } from "./utils/index.mjs";
2
- import { basename, resolve } from "node:path";
2
+ import { basename } from "node:path";
3
3
  import { globSync } from "tinyglobby";
4
4
  //#region node/autoImportStores.ts
5
5
  var autoImportStores_default = (root) => {
6
6
  const piniaStoreKeys = [];
7
- globSync(resolve(root, "src/store/modules/*.ts")).forEach((p) => {
7
+ globSync("src/store/modules/*.ts", { cwd: root }).forEach((p) => {
8
8
  piniaStoreKeys.push(basename(p, ".ts"));
9
9
  });
10
10
  const customerImport = {};
@@ -1,4 +1,7 @@
1
- declare const _default: (isProduction: boolean) => ({
1
+ declare const _default: (options: {
2
+ isProduction: boolean;
3
+ root: string;
4
+ }) => ({
2
5
  resolve: (name: string) => {
3
6
  from: string;
4
7
  name: string;
@@ -2,13 +2,14 @@ import path from "node:path";
2
2
  import { globSync } from "tinyglobby";
3
3
  import { TDesignResolver } from "@tdesign-vue-next/auto-import-resolver";
4
4
  //#region node/tDesignResolve.ts
5
- var tDesignResetComponentsSubFolderName = globSync("src/components/tDesignReset/*/Index.vue").map((file) => {
6
- return path.basename(path.dirname(file));
7
- });
8
- var autoImportComponentsSubFolderName = globSync("src/components/autoImport/*/Index.vue").map((file) => {
9
- return path.basename(path.dirname(file));
10
- });
11
- var tDesignResolve_default = (isProduction) => {
5
+ var tDesignResolve_default = (options) => {
6
+ const { isProduction, root } = options;
7
+ const tDesignResetComponentsSubFolderName = globSync("src/components/tDesignReset/*/Index.vue", { cwd: root }).map((file) => {
8
+ return path.basename(path.dirname(file));
9
+ });
10
+ const autoImportComponentsSubFolderName = globSync("src/components/autoImport/*/Index.vue", { cwd: root }).map((file) => {
11
+ return path.basename(path.dirname(file));
12
+ });
12
13
  return [{
13
14
  resolve: (name) => {
14
15
  if (["TCard"].includes(name)) return {
@@ -181,13 +181,19 @@ var vite_config_default = (_env, options) => {
181
181
  autoImportStores_default(options.root),
182
182
  ...options.autoImports ?? []
183
183
  ],
184
- resolvers: [...options.autoImportResolvers ?? [], ...tDesignResolve_default(isProduction)],
184
+ resolvers: [...options.autoImportResolvers ?? [], ...tDesignResolve_default({
185
+ isProduction,
186
+ root: options.root
187
+ })],
185
188
  vueTemplate: true
186
189
  }),
187
190
  Components({
188
191
  deep: false,
189
192
  dts: "types/components.d.ts",
190
- resolvers: [...options.autoImportResolvers ?? [], ...tDesignResolve_default(isProduction)]
193
+ resolvers: [...options.autoImportResolvers ?? [], ...tDesignResolve_default({
194
+ isProduction,
195
+ root: options.root
196
+ })]
191
197
  }),
192
198
  ...vitePlugins_default({
193
199
  isProduction,
package/package.json CHANGED
@@ -110,6 +110,6 @@
110
110
  "**/*.css"
111
111
  ],
112
112
  "type": "module",
113
- "version": "1.39.0",
113
+ "version": "1.40.0",
114
114
  "scripts": {}
115
115
  }