@fangzhongya/vue-archive 0.0.6 → 0.0.8

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.
Files changed (125) hide show
  1. package/README.md +3 -2
  2. package/dist/node/index.cjs +135 -71
  3. package/dist/node/index.d.cts +8 -0
  4. package/dist/node/index.d.ts +8 -0
  5. package/dist/node/index.js +118 -54
  6. package/dist/node_modules/.pnpm/@fangzhongya_utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-LPMR5W6M.cjs +1 -0
  7. package/dist/node_modules/.pnpm/@fangzhongya_utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-LPMR5W6M.js +9 -0
  8. package/dist/packages/components/aside/index.vue.cjs +1 -1
  9. package/dist/packages/components/aside/index.vue.js +43 -45
  10. package/dist/packages/components/boxurl/index.vue.cjs +1 -1
  11. package/dist/packages/components/boxurl/index.vue.js +34 -37
  12. package/dist/packages/components/choice/choice.vue.cjs +1 -1
  13. package/dist/packages/components/choice/choice.vue.js +29 -32
  14. package/dist/packages/components/choice/index.vue.cjs +1 -1
  15. package/dist/packages/components/choice/index.vue.js +39 -42
  16. package/dist/packages/components/code/highlight.vue2.cjs +1 -1
  17. package/dist/packages/components/code/highlight.vue2.js +1 -1
  18. package/dist/packages/components/code/index.vue.cjs +1 -1
  19. package/dist/packages/components/code/index.vue.js +79 -87
  20. package/dist/packages/components/compo/ftable.vue.cjs +1 -1
  21. package/dist/packages/components/compo/ftable.vue.js +15 -15
  22. package/dist/packages/components/compo/index.cjs +1 -1
  23. package/dist/packages/components/compo/index.js +86 -97
  24. package/dist/packages/components/compo/index.vue.cjs +1 -1
  25. package/dist/packages/components/compo/index.vue.js +33 -34
  26. package/dist/packages/components/compo/info.vue.cjs +1 -1
  27. package/dist/packages/components/compo/info.vue.js +22 -25
  28. package/dist/packages/components/compo/top.cjs +1 -1
  29. package/dist/packages/components/compo/top.js +21 -21
  30. package/dist/packages/components/main/index.vue.cjs +1 -1
  31. package/dist/packages/components/main/index.vue.js +16 -17
  32. package/dist/packages/components/md/index.vue.cjs +1 -1
  33. package/dist/packages/components/md/index.vue.js +28 -32
  34. package/dist/packages/components/test/index.cjs +1 -1
  35. package/dist/packages/components/test/index.js +39 -42
  36. package/dist/packages/components/test/index.vue.cjs +1 -1
  37. package/dist/packages/components/test/index.vue.js +44 -49
  38. package/dist/packages/components/use/code.cjs +1 -1
  39. package/dist/packages/components/use/code.js +3 -3
  40. package/dist/packages/components/use/index.cjs +1 -1
  41. package/dist/packages/components/use/index.js +1 -1
  42. package/dist/packages/components/use/retrie/choice/index.vue.cjs +1 -1
  43. package/dist/packages/components/use/retrie/choice/index.vue.js +32 -34
  44. package/dist/packages/components/use/retrie/expose/index.vue.cjs +1 -1
  45. package/dist/packages/components/use/retrie/expose/index.vue.js +18 -19
  46. package/dist/packages/components/use/retrie/form/index.vue.cjs +1 -1
  47. package/dist/packages/components/use/retrie/form/index.vue.js +110 -114
  48. package/dist/packages/components/use/retrie/function/index.vue.cjs +2 -2
  49. package/dist/packages/components/use/retrie/function/index.vue.js +1 -4
  50. package/dist/packages/components/use/retrie/input/index.vue.cjs +1 -1
  51. package/dist/packages/components/use/retrie/input/index.vue.js +20 -21
  52. package/dist/packages/components/use/retrie/number/index.vue.cjs +1 -1
  53. package/dist/packages/components/use/retrie/number/index.vue.js +12 -13
  54. package/dist/packages/components/use/retrie/select/index.vue.cjs +1 -1
  55. package/dist/packages/components/use/retrie/select/index.vue.js +21 -23
  56. package/dist/packages/components/use/retrie/slot/index.vue.cjs +1 -1
  57. package/dist/packages/components/use/retrie/slot/index.vue.js +15 -16
  58. package/dist/packages/components/use/retrie/string/index.vue.cjs +1 -1
  59. package/dist/packages/components/use/retrie/string/index.vue.js +14 -15
  60. package/dist/packages/components/use/set-emit.vue.cjs +1 -1
  61. package/dist/packages/components/use/set-emit.vue.js +20 -24
  62. package/dist/packages/components/use/set-expose.vue.cjs +1 -1
  63. package/dist/packages/components/use/set-expose.vue.js +15 -18
  64. package/dist/packages/components/use/set-props.vue.cjs +1 -1
  65. package/dist/packages/components/use/set-props.vue.js +48 -49
  66. package/dist/packages/config.cjs +1 -1
  67. package/dist/packages/config.d.ts +8 -1
  68. package/dist/packages/config.js +1 -1
  69. package/dist/packages/directives/adjust/index copy.d.ts +6 -0
  70. package/dist/packages/directives/adjust/index.cjs +1 -1
  71. package/dist/packages/directives/adjust/index.js +96 -97
  72. package/dist/packages/page/comprops/index.vue2.cjs +1 -1
  73. package/dist/packages/page/comprops/index.vue2.js +65 -71
  74. package/dist/packages/page/index/index.vue2.cjs +1 -1
  75. package/dist/packages/page/index/index.vue2.js +19 -23
  76. package/dist/packages/page/single/index.vue2.cjs +1 -1
  77. package/dist/packages/page/single/index.vue2.js +46 -49
  78. package/dist/packages/router/index.cjs +1 -1
  79. package/dist/packages/router/index.js +44 -46
  80. package/dist/packages/utils/common.cjs +1 -1
  81. package/dist/packages/utils/common.d.ts +4 -0
  82. package/dist/packages/utils/common.js +57 -54
  83. package/dist/packages/utils/glob.cjs +3 -3
  84. package/dist/packages/utils/glob.d.ts +1 -1
  85. package/dist/packages/utils/glob.js +269 -227
  86. package/dist/packages/utils/props.cjs +1 -1
  87. package/dist/packages/utils/props.js +34 -28
  88. package/dist/src/components/common/cs3.d.ts +4 -0
  89. package/dist/src/components/common/index.d.ts +4 -0
  90. package/dist/src/components/cs/expose/index.d.ts +4 -1
  91. package/dist/src/components/cs/expose/src/index.vue.d.ts +4 -1
  92. package/dist/vue-archive.css +1 -1
  93. package/package.json +19 -20
  94. package/dist/node_modules/.pnpm/@fangzhongya_utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-SNABGVNO.cjs +0 -1
  95. package/dist/node_modules/.pnpm/@fangzhongya_utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-SNABGVNO.js +0 -9
  96. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-4OBNLDTJ.cjs +0 -0
  97. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-4OBNLDTJ.js +0 -0
  98. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-5RZYHE3X.cjs +0 -0
  99. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-5RZYHE3X.js +0 -0
  100. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-AM67P3W7.cjs +0 -0
  101. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-AM67P3W7.js +0 -0
  102. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-APKFW4LU.cjs +0 -0
  103. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-APKFW4LU.js +0 -0
  104. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-EWJJKQIO.cjs +0 -0
  105. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-EWJJKQIO.js +0 -0
  106. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-J7CICTHH.cjs +0 -0
  107. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-J7CICTHH.js +0 -0
  108. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-Q6FMBSK4.cjs +0 -0
  109. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-Q6FMBSK4.js +0 -0
  110. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-RD4EP3M5.cjs +0 -0
  111. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-RD4EP3M5.js +0 -0
  112. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-UOADEBDH.cjs +0 -0
  113. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-UOADEBDH.js +0 -0
  114. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-VBS6YE6H.cjs +0 -0
  115. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-VBS6YE6H.js +0 -0
  116. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-VKE5JARB.cjs +0 -0
  117. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-VKE5JARB.js +0 -0
  118. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-XCDKXZFR.cjs +0 -0
  119. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-XCDKXZFR.js +0 -0
  120. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-XUL6LPTN.cjs +0 -0
  121. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-XUL6LPTN.js +0 -0
  122. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-ZVBCHJA5.cjs +0 -0
  123. /package/dist/node_modules/.pnpm/{@fangzhongya_utils@0.0.8-77 → @fangzhongya_utils@0.0.24}/node_modules/@fangzhongya/utils/dist/chunk-ZVBCHJA5.js +0 -0
  124. /package/dist/node_modules/.pnpm/{@highlightjs_vue-plugin@2.1_0b670f4f8863792fd47bf820772b9cbf → @highlightjs_vue-plugin@2.1_b586068ec461434c266304f56a34d01a}/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.cjs +0 -0
  125. /package/dist/node_modules/.pnpm/{@highlightjs_vue-plugin@2.1_0b670f4f8863792fd47bf820772b9cbf → @highlightjs_vue-plugin@2.1_b586068ec461434c266304f56a34d01a}/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.js +0 -0
package/README.md CHANGED
@@ -92,10 +92,11 @@ vue 组件文档展示 采用 Vite 导入本地文件,
92
92
  * @name 方法名
93
93
  * @selectable 参数
94
94
  * @description 说明
95
+ * @return 返回值
95
96
  */
96
97
  /**
97
98
  * 单标签
98
- * @expose 方法名 (参数) 说明
99
+ * @expose 方法名 (参数)=返回值 说明
99
100
  */
100
101
  ```
101
102
 
@@ -205,4 +206,4 @@ index.js 和 index.vue 中的文件注释,生成文档
205
206
  件夹,用来放当前组件的示例 支持多个实例的,也只会读取文件夹
206
207
  下的 index.js 和 index.vue 文件来当示例展示的
207
208
 
208
- 测试 自动提交2
209
+ 测试 自动提交2
@@ -24,12 +24,12 @@ __export(index_exports, {
24
24
  });
25
25
  module.exports = __toCommonJS(index_exports);
26
26
 
27
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-5PX3AFSC.js
27
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-5PX3AFSC.js
28
28
  function isArray(obj) {
29
29
  return Object.prototype.toString.call(obj) == "[object Array]";
30
30
  }
31
31
 
32
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-A276ZDLP.js
32
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-A276ZDLP.js
33
33
  function getStartSames(str, val) {
34
34
  let s = "";
35
35
  const vs = [...val];
@@ -45,7 +45,7 @@ function getStartSames(str, val) {
45
45
  return [s, str.substring(index), val.substring(index)];
46
46
  }
47
47
 
48
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-AWC672JW.js
48
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-AWC672JW.js
49
49
  function getImportUrl(url, imp) {
50
50
  const arr = getStartSames(url, imp);
51
51
  const ts = arr[0];
@@ -72,12 +72,12 @@ function getImportUrl(url, imp) {
72
72
  return ds.join("") + arr[2].replace(/\\/g, "/");
73
73
  }
74
74
 
75
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-EWJJKQIO.js
75
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-EWJJKQIO.js
76
76
  function firstUpper(str) {
77
77
  return str.slice(0, 1).toUpperCase() + str.slice(1);
78
78
  }
79
79
 
80
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-XCDKXZFR.js
80
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-XCDKXZFR.js
81
81
  function lineToLargeHump(name) {
82
82
  let arr = name.split("-");
83
83
  arr = arr.map((vs) => {
@@ -86,9 +86,9 @@ function lineToLargeHump(name) {
86
86
  return arr.join("");
87
87
  }
88
88
 
89
- // node_modules/.pnpm/@fangzhongya+create@0.2.10/node_modules/@fangzhongya/create/dist/chunk-GZYHZMXR.js
90
- var import_node_fs = require("fs");
91
- var import_node_path = require("path");
89
+ // node_modules/.pnpm/@fangzhongya+create@0.2.29/node_modules/@fangzhongya/create/dist/chunk-7V2NDMIF.js
90
+ var import_fs = require("fs");
91
+ var import_path = require("path");
92
92
  function getUrlCatalogueObj(str) {
93
93
  const reg = /(\\|\/)([^\\|\/]+)\.([a-z|A-Z]+)$/g;
94
94
  const ml = str.replace(reg, "");
@@ -131,7 +131,7 @@ function fsCreateReadStream(url, type) {
131
131
  type = "utf-8";
132
132
  }
133
133
  return new Promise((resolve2) => {
134
- const stream = (0, import_node_fs.createReadStream)(url, {
134
+ const stream = (0, import_fs.createReadStream)(url, {
135
135
  start: 0,
136
136
  end: 100,
137
137
  encoding: type
@@ -150,7 +150,7 @@ function fsCreateReadStream(url, type) {
150
150
  }
151
151
  function fsReaddir(filePath) {
152
152
  return new Promise((resolve2, reject) => {
153
- (0, import_node_fs.readdir)(filePath, (err, files) => {
153
+ (0, import_fs.readdir)(filePath, (err, files) => {
154
154
  if (err) {
155
155
  reject(err);
156
156
  } else {
@@ -160,8 +160,8 @@ function fsReaddir(filePath) {
160
160
  if (lg) {
161
161
  let i = 0;
162
162
  files.forEach((filename) => {
163
- const filedir = (0, import_node_path.join)(filePath, filename);
164
- (0, import_node_fs.stat)(filedir, (err2, stats) => {
163
+ const filedir = (0, import_path.join)(filePath, filename);
164
+ (0, import_fs.stat)(filedir, (err2, stats) => {
165
165
  i++;
166
166
  if (err2) {
167
167
  console.log("4", err2);
@@ -194,12 +194,12 @@ function fsReaddir(filePath) {
194
194
  });
195
195
  }
196
196
  function fsOpenStream(path, json, type = 0, cover, callback) {
197
- (0, import_node_fs.open)(path, "wx", async (err, fd) => {
197
+ (0, import_fs.open)(path, "wx", async (err, fd) => {
198
198
  if (err) {
199
199
  if (err.code === "EEXIST") {
200
200
  if (type == 1 || type == 0) {
201
201
  const fwrite = () => {
202
- (0, import_node_fs.writeFile)(path, json, "utf-8", (err2) => {
202
+ (0, import_fs.writeFile)(path, json, "utf-8", (err2) => {
203
203
  if (err2) {
204
204
  console.log("6", err2);
205
205
  if (callback) {
@@ -243,7 +243,7 @@ function fsOpenStream(path, json, type = 0, cover, callback) {
243
243
  }
244
244
  } else {
245
245
  if (type != 1) {
246
- (0, import_node_fs.write)(fd, json, (err2) => {
246
+ (0, import_fs.write)(fd, json, (err2) => {
247
247
  if (err2) {
248
248
  console.log("8", err2);
249
249
  if (callback) {
@@ -264,7 +264,7 @@ function fsOpenStream(path, json, type = 0, cover, callback) {
264
264
  });
265
265
  }
266
266
  function fsMkdir(reaPath, callback) {
267
- (0, import_node_fs.mkdir)(reaPath, { recursive: true }, (err, path) => {
267
+ (0, import_fs.mkdir)(reaPath, { recursive: true }, (err, path) => {
268
268
  if (err) {
269
269
  console.log("0", err);
270
270
  if (callback) {
@@ -309,7 +309,7 @@ function writeFileUrl(url, files, callback, isDirs, isFile, issynch) {
309
309
  if (is) {
310
310
  dirs.push(dir);
311
311
  const urls = await writeInit(
312
- (0, import_node_path.join)(url, dir),
312
+ (0, import_path.join)(url, dir),
313
313
  callback,
314
314
  isDirs,
315
315
  isFile,
@@ -329,7 +329,7 @@ function writeFileUrl(url, files, callback, isDirs, isFile, issynch) {
329
329
  }
330
330
  if (is) {
331
331
  file.push(name);
332
- arr.push((0, import_node_path.join)(url, name));
332
+ arr.push((0, import_path.join)(url, name));
333
333
  }
334
334
  });
335
335
  }
@@ -345,8 +345,8 @@ function writeFileUrl(url, files, callback, isDirs, isFile, issynch) {
345
345
  });
346
346
  }
347
347
 
348
- // node_modules/.pnpm/@fangzhongya+create@0.2.10/node_modules/@fangzhongya/create/dist/chunk-UAWU4UVR.js
349
- var import_node_path2 = require("path");
348
+ // node_modules/.pnpm/@fangzhongya+create@0.2.29/node_modules/@fangzhongya/create/dist/chunk-PXLSY3ZR.js
349
+ var import_path2 = require("path");
350
350
  function styleLog(msg = "", obj) {
351
351
  const arr = ["\x1B[0m"];
352
352
  if (obj?.revert) {
@@ -541,7 +541,7 @@ var FangCom = class {
541
541
  getDirUrl(dir) {
542
542
  const str = dir || this.config.dir;
543
543
  if (str) {
544
- return (0, import_node_path2.resolve)(process.cwd(), str);
544
+ return (0, import_path2.resolve)(process.cwd(), str);
545
545
  } else {
546
546
  return "";
547
547
  }
@@ -555,7 +555,7 @@ var FangCom = class {
555
555
  }
556
556
  isMatchFile(url, name) {
557
557
  const dirUrl = this.getDirUrl();
558
- const dir = (0, import_node_path2.join)(url, name).replace(dirUrl, "");
558
+ const dir = (0, import_path2.join)(url, name).replace(dirUrl, "");
559
559
  const is = matchsEnd(dir, this.config.matchexts);
560
560
  const nomatchexts = this.config.nomatchexts;
561
561
  if (is && nomatchexts && nomatchexts.length > 0) {
@@ -570,7 +570,7 @@ var FangCom = class {
570
570
  }
571
571
  isMatchDir(url, name) {
572
572
  const dirUrl = this.getDirUrl();
573
- const dir = (0, import_node_path2.join)(url, name).replace(dirUrl, "");
573
+ const dir = (0, import_path2.join)(url, name).replace(dirUrl, "");
574
574
  const is = matchsStart(dir, this.config.matchs);
575
575
  const nomatchs = this.config.nomatchs;
576
576
  if (is && nomatchs && nomatchs.length > 0) {
@@ -767,7 +767,7 @@ var FangCom = class {
767
767
  }
768
768
  };
769
769
 
770
- // node_modules/.pnpm/@fangzhongya+create@0.2.10/node_modules/@fangzhongya/create/dist/bins/md.js
770
+ // node_modules/.pnpm/@fangzhongya+create@0.2.29/node_modules/@fangzhongya/create/dist/bins/md.js
771
771
  var defaultConfig2 = Object.assign({}, defaultConfig, {
772
772
  name: "md"
773
773
  });
@@ -786,7 +786,7 @@ function runDev(config2, configCallback) {
786
786
  return new FangMd(config2, configCallback);
787
787
  }
788
788
 
789
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-NCSN3MC5.js
789
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-NCSN3MC5.js
790
790
  var zObj = {
791
791
  "<": "&lt;",
792
792
  ">": "&gt;",
@@ -805,9 +805,9 @@ function htmlEscape(str) {
805
805
  }
806
806
 
807
807
  // packages/node/index.ts
808
- var import_node_path3 = require("path");
808
+ var import_node_path = require("path");
809
809
 
810
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-RD4EP3M5.js
810
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-RD4EP3M5.js
811
811
  function mergeObject(a, b, j = 0, i) {
812
812
  if (a instanceof Array) {
813
813
  if (j > 0 && i) {
@@ -850,7 +850,7 @@ function mergeObject(a, b, j = 0, i) {
850
850
  return a;
851
851
  }
852
852
 
853
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-J7CICTHH.js
853
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-J7CICTHH.js
854
854
  function humpToLine(name) {
855
855
  const reg = /(([A-Z])([^A-Z]*))/g;
856
856
  let result;
@@ -872,23 +872,23 @@ function humpToLine(name) {
872
872
  }
873
873
  }
874
874
 
875
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-SNABGVNO.js
875
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-LPMR5W6M.js
876
876
  function appearNum(str, t) {
877
877
  let reg = t;
878
878
  if (typeof t == "string") {
879
- reg = new RegExp(t, "g");
879
+ reg = new RegExp(t.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), "g");
880
880
  }
881
881
  let arr = str.match(reg);
882
882
  let c = arr ? arr.length : 0;
883
883
  return c;
884
884
  }
885
885
 
886
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-4OBNLDTJ.js
886
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-4OBNLDTJ.js
887
887
  function firstLower(str) {
888
888
  return str.slice(0, 1).toLowerCase() + str.slice(1);
889
889
  }
890
890
 
891
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-Q6FMBSK4.js
891
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-Q6FMBSK4.js
892
892
  function asyncMergeArray(arr, callback) {
893
893
  return new Promise((resolve2, reject) => {
894
894
  let index = 0;
@@ -912,7 +912,7 @@ function asyncMergeArray(arr, callback) {
912
912
  });
913
913
  }
914
914
 
915
- // node_modules/.pnpm/@fangzhongya+utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-UOADEBDH.js
915
+ // node_modules/.pnpm/@fangzhongya+utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-UOADEBDH.js
916
916
  function getSuffix2(url) {
917
917
  const reg = /\.([a-z|A-Z]+)$/;
918
918
  const regs = reg.exec(url);
@@ -1001,6 +1001,7 @@ function getUrlName(url, pps, raliass = {}, alias = "") {
1001
1001
  });
1002
1002
  let value = ms[1];
1003
1003
  let rsobj = {
1004
+ url: "",
1004
1005
  dir: "",
1005
1006
  suffix: getSuffix2(url),
1006
1007
  name: lineToLargeHump(value),
@@ -1032,7 +1033,7 @@ function getTDir(key) {
1032
1033
  }
1033
1034
  function isComprops(url, comprops) {
1034
1035
  if (comprops) {
1035
- const reg = new RegExp(comprops + ".+(\\.(js|ts))?$");
1036
+ const reg = new RegExp(comprops);
1036
1037
  return reg.test(url);
1037
1038
  } else {
1038
1039
  return false;
@@ -1052,10 +1053,14 @@ function getComponentsArr(urls, v, comRaw, com, config2) {
1052
1053
  const ppz = getMatchs(v.matchexts, v.extensions, v.matchs);
1053
1054
  const tdir = getTDir(v.dir);
1054
1055
  urls.forEach((key) => {
1056
+ const dk = v.dir.replace(/^\./, "");
1057
+ let z = key.indexOf(dk);
1058
+ let zv = "." + key.substring(z);
1055
1059
  const reg = new RegExp("^" + v.dir);
1056
- let k = key.replace(reg, "");
1057
- if (config2.comprops && isComprops(k, config2.comprops) || config2.curprops && isCurprops(k, config2.curprops)) {
1060
+ let k = zv.replace(reg, "");
1061
+ if (config2.comprops && isComprops("/" + k, config2.comprops) || config2.curprops && isCurprops("/" + k, config2.curprops)) {
1058
1062
  let value = {};
1063
+ value.url = zv;
1059
1064
  value.comprops = config2.comprops || "";
1060
1065
  value.curprops = config2.curprops || "";
1061
1066
  value.value = k;
@@ -1069,6 +1074,7 @@ function getComponentsArr(urls, v, comRaw, com, config2) {
1069
1074
  } else {
1070
1075
  let value = getUrlName(k, ppz, v.aliass, v.alias);
1071
1076
  if (value) {
1077
+ value.url = zv;
1072
1078
  value.comprops = config2.comprops;
1073
1079
  value.curprops = config2.curprops;
1074
1080
  value.dir = v.dir;
@@ -1595,6 +1601,22 @@ function getexamplesRawObj(comRaw, key) {
1595
1601
  return comRaw;
1596
1602
  }
1597
1603
  }
1604
+ var aliasObj = {};
1605
+ function getURLalias(value) {
1606
+ const alias = getConfig("resolve");
1607
+ if (aliasObj[value]) {
1608
+ return aliasObj[value];
1609
+ } else {
1610
+ for (let o of alias) {
1611
+ if (value.startsWith(o.find + "/")) {
1612
+ const t = o.replacement.replaceAll("\\", "/");
1613
+ const v = t + value.replace(o.find + "/", "/");
1614
+ aliasObj[value] = v;
1615
+ return v;
1616
+ }
1617
+ }
1618
+ }
1619
+ }
1598
1620
  async function getImport(text, type) {
1599
1621
  let jstext = "";
1600
1622
  if (type == "vue") {
@@ -1625,6 +1647,11 @@ async function getImport(text, type) {
1625
1647
  if (key) {
1626
1648
  if (key.startsWith("./") || key.startsWith("../")) {
1627
1649
  yrs.push(key);
1650
+ } else {
1651
+ const v = getURLalias(key);
1652
+ if (v) {
1653
+ yrs.push(v);
1654
+ }
1628
1655
  }
1629
1656
  }
1630
1657
  });
@@ -1803,7 +1830,7 @@ function getKeyMds(key) {
1803
1830
  getTestObj(key);
1804
1831
  return componentsObj[key].mds;
1805
1832
  }
1806
- async function getTestImportUrl(url, text, type, comprops) {
1833
+ async function getTestImportUrl(url, text, type, dir, comprops) {
1807
1834
  let arr = await getImport(text, type) || [];
1808
1835
  let urs = url.split("/");
1809
1836
  return arr.map((key) => {
@@ -1811,14 +1838,16 @@ async function getTestImportUrl(url, text, type, comprops) {
1811
1838
  let head = urs.slice(0, urs.length - 1).join("/");
1812
1839
  let v = key.substring(2);
1813
1840
  return {
1841
+ url: head + "/" + v,
1814
1842
  name: key,
1815
1843
  comprops: comprops || "",
1816
1844
  value: v,
1817
1845
  suffix: getSuffix2(key),
1818
1846
  head,
1819
- key: head + "/" + v
1847
+ dir,
1848
+ key
1820
1849
  };
1821
- } else {
1850
+ } else if (key.startsWith("../")) {
1822
1851
  let ks = key.split("/");
1823
1852
  let z = 0;
1824
1853
  for (let index = 0; index < ks.length; index++) {
@@ -1831,14 +1860,33 @@ async function getTestImportUrl(url, text, type, comprops) {
1831
1860
  let vs = ks.slice(z, ks.length);
1832
1861
  let head = urs.slice(0, urs.length - z - 1).join("/");
1833
1862
  let v = vs.join("/");
1834
- return {
1863
+ const rv = {
1864
+ url: head + "/" + v,
1835
1865
  name: key,
1836
1866
  comprops: comprops || "",
1837
1867
  value: v,
1838
1868
  suffix: getSuffix2(key),
1839
1869
  head,
1840
- key: head + "/" + v
1870
+ dir,
1871
+ key
1841
1872
  };
1873
+ return rv;
1874
+ } else {
1875
+ const k = dir.replace(/^\./, "");
1876
+ let z = key.indexOf(k) + k.length;
1877
+ let v = key.substring(z);
1878
+ let head = dir.substring(0, dir.length - 1);
1879
+ const rv = {
1880
+ url: head + "/" + v,
1881
+ name: key,
1882
+ comprops: comprops || "",
1883
+ value: v,
1884
+ suffix: getSuffix2(key),
1885
+ head,
1886
+ dir,
1887
+ key
1888
+ };
1889
+ return rv;
1842
1890
  }
1843
1891
  });
1844
1892
  }
@@ -1897,7 +1945,7 @@ function setForComponentsValue(v) {
1897
1945
  obj = getComponentsArr(urls, v, v.componentsRaw, v.components, v);
1898
1946
  if (obj && obj?.props) {
1899
1947
  obj.props.forEach((z) => {
1900
- componentPropsObj[z.key] = z;
1948
+ componentPropsObj[z.url] = z;
1901
1949
  });
1902
1950
  }
1903
1951
  setComponentsObj(alias, obj.components);
@@ -1911,18 +1959,29 @@ function getCompoNameObj() {
1911
1959
  async function getPropsImport(text, obj) {
1912
1960
  let ts = text;
1913
1961
  if (text) {
1914
- let arr = (await getTestImportUrl(obj.key, text, obj.suffix, obj.comprops)).filter((v) => {
1962
+ let arr = (await getTestImportUrl(
1963
+ obj.key,
1964
+ text,
1965
+ obj.suffix,
1966
+ obj.dir,
1967
+ obj.comprops
1968
+ )).filter((v) => {
1915
1969
  return v.key.startsWith(obj.head) || isComprops(v.name, obj.comprops || "");
1916
1970
  });
1917
1971
  ts = await getPropsTexts(arr) + ts;
1918
1972
  }
1919
1973
  return ts;
1920
1974
  }
1975
+ function getPropsValue(o) {
1976
+ const u = o.url;
1977
+ const k = o.key;
1978
+ return componentPropsObj[u] || componentPropsObj[u + ".js"] || componentPropsObj[u + ".ts"] || componentPropsObj[k] || componentPropsObj[k + ".js"] || componentPropsObj[k + ".ts"];
1979
+ }
1921
1980
  function getPropsRaws(arr) {
1922
1981
  return new Promise((resolve2) => {
1923
1982
  if (arr && arr.length > 0) {
1924
1983
  let arrs = arr.map((o) => {
1925
- return componentPropsObj[o.key] || componentPropsObj[o.key + ".js"] || componentPropsObj[o.key + ".ts"];
1984
+ return getPropsValue(o);
1926
1985
  }).filter((o) => Boolean(o));
1927
1986
  asyncMergeArray(arrs, (res, rej, value, index) => {
1928
1987
  if (value.raw) {
@@ -1959,6 +2018,7 @@ async function getComponentsProps(text, obj) {
1959
2018
  obj.key,
1960
2019
  text,
1961
2020
  obj.suffix,
2021
+ obj.dir,
1962
2022
  obj.comprops || ""
1963
2023
  )).filter((v) => {
1964
2024
  return isComprops(v.name, obj.comprops || "") || isCurprops(v.name, obj.curprops || "");
@@ -2125,6 +2185,19 @@ var expose = {
2125
2185
  } else {
2126
2186
  return "";
2127
2187
  }
2188
+ },
2189
+ return(obj) {
2190
+ if (obj.return) {
2191
+ let t = obj.return.type;
2192
+ if (t) {
2193
+ t = `[${t}]`;
2194
+ }
2195
+ return t + (obj.return.description || obj.return.name);
2196
+ } else if (obj.expose) {
2197
+ return obj.expose.return;
2198
+ } else {
2199
+ return "";
2200
+ }
2128
2201
  }
2129
2202
  };
2130
2203
  var slot = {
@@ -2158,7 +2231,7 @@ var slot = {
2158
2231
  }
2159
2232
  }
2160
2233
  };
2161
- function getPropsValue(arr) {
2234
+ function getPropsValue2(arr) {
2162
2235
  return arr.map((obj) => {
2163
2236
  const v = {};
2164
2237
  Object.keys(props).forEach((key) => {
@@ -3033,13 +3106,7 @@ function setSlot(obj) {
3033
3106
  let name = "";
3034
3107
  let description = "";
3035
3108
  let selectable = "";
3036
- let arr = [
3037
- "slot",
3038
- "name",
3039
- "selectable",
3040
- "description",
3041
- "descriptions"
3042
- ];
3109
+ let arr = ["slot", "name", "selectable", "description", "descriptions"];
3043
3110
  let fobj = getFilter2(obj, arr);
3044
3111
  let value = {};
3045
3112
  arr.forEach((key) => {
@@ -3051,16 +3118,7 @@ function setSlot(obj) {
3051
3118
  });
3052
3119
  }
3053
3120
  function setEmits(obj) {
3054
- let name = "";
3055
- let description = "";
3056
- let selectable = "";
3057
- let arr = [
3058
- "emits",
3059
- "name",
3060
- "selectable",
3061
- "description",
3062
- "descriptions"
3063
- ];
3121
+ let arr = ["emits", "name", "selectable", "description", "descriptions"];
3064
3122
  let fobj = getFilter2(obj, arr);
3065
3123
  let value = {};
3066
3124
  arr.forEach((key) => {
@@ -3076,6 +3134,7 @@ function setExpose(obj) {
3076
3134
  "expose",
3077
3135
  "name",
3078
3136
  "type",
3137
+ "return",
3079
3138
  "selectable",
3080
3139
  "description",
3081
3140
  "descriptions"
@@ -3113,7 +3172,7 @@ function getFilter2(obj, arrs) {
3113
3172
  };
3114
3173
  const arr = [];
3115
3174
  if (obj?.tags) {
3116
- obj?.tags?.forEach((v) => {
3175
+ obj.tags?.forEach((v) => {
3117
3176
  let tag = v.tag;
3118
3177
  let ov = getObj2(v);
3119
3178
  if (!_objs.hasOwnProperty(tag)) {
@@ -3198,11 +3257,14 @@ function notesFilter(notes) {
3198
3257
  function getNotes2(key) {
3199
3258
  return new Promise((resolve2) => {
3200
3259
  getLocalTextComponents(key).then((text) => {
3201
- let notes = getTextNotes(text);
3202
- resolve2(notesFilter(notes));
3260
+ resolve2(getNotesText(text));
3203
3261
  });
3204
3262
  });
3205
3263
  }
3264
+ function getNotesText(text) {
3265
+ let notes = getTextNotes(text);
3266
+ return notesFilter(notes);
3267
+ }
3206
3268
  var tprops = [
3207
3269
  {
3208
3270
  label: "\u5C5E\u6027\u540D",
@@ -3266,7 +3328,9 @@ var texpose = [
3266
3328
  {
3267
3329
  label: "\u8FD4\u56DE\u503C",
3268
3330
  prop: "type",
3269
- formatter: expose.type
3331
+ formatter(obj) {
3332
+ return expose.return(obj) ?? expose.type(obj);
3333
+ }
3270
3334
  }
3271
3335
  ];
3272
3336
  var tslot = [
@@ -3353,7 +3417,7 @@ function gettests(obj, arr, n) {
3353
3417
  })
3354
3418
  );
3355
3419
  if (configObj.generatetype != 2) {
3356
- setVue(getName(obj), n, (0, import_node_path3.join)(configObj.dir, key));
3420
+ setVue(getName(obj), n, (0, import_node_path.join)(configObj.dir, key));
3357
3421
  }
3358
3422
  if (configObj.generatetype != 3) {
3359
3423
  setMd(obj, arr);
@@ -3398,7 +3462,7 @@ function getDefaultValue(obj) {
3398
3462
  }
3399
3463
  }
3400
3464
  function setVue(propsname, param, url) {
3401
- const ps = getPropsValue(param.propss);
3465
+ const ps = getPropsValue2(param.propss);
3402
3466
  const es = getEmitsValue(param.emitss);
3403
3467
  const propsObj = {};
3404
3468
  ps.forEach((val) => {
@@ -3439,7 +3503,7 @@ function setVue(propsname, param, url) {
3439
3503
  var lss = 0;
3440
3504
  function setMd(obj, arr) {
3441
3505
  lss++;
3442
- const sc = (0, import_node_path3.join)(
3506
+ const sc = (0, import_node_path.join)(
3443
3507
  configObj.dir,
3444
3508
  configObj.outDir,
3445
3509
  "/" + obj.value + "/index.md"
@@ -3453,8 +3517,8 @@ function setMd(obj, arr) {
3453
3517
  }
3454
3518
  function setTestUrl(obj, test) {
3455
3519
  const arr = [];
3456
- const tu = (0, import_node_path3.join)(configObj.dir, test.key);
3457
- const sc = (0, import_node_path3.join)(
3520
+ const tu = (0, import_node_path.join)(configObj.dir, test.key);
3521
+ const sc = (0, import_node_path.join)(
3458
3522
  configObj.dir,
3459
3523
  configObj.outDir,
3460
3524
  "/" + obj.value + "/index.md"
@@ -57,10 +57,17 @@ interface ExampleObj {
57
57
  examplesRaw?: Globs;
58
58
  md?: string;
59
59
  }
60
+ type Resolve = {
61
+ find: string | RegExp;
62
+ replacement: string;
63
+ } | {
64
+ [find: string]: string;
65
+ };
60
66
  interface Config {
61
67
  router?: string;
62
68
  redirect?: boolean;
63
69
  useparam?: boolean;
70
+ resolve?: Resolve[];
64
71
  components: Array<Components>;
65
72
  example?: ExampleObj;
66
73
  }
@@ -89,6 +96,7 @@ interface TestsObj extends TextObj {
89
96
  component: AsyncComponentLoader;
90
97
  }
91
98
  interface ComponentsObj extends Component, TextObj {
99
+ url: string;
92
100
  name: string;
93
101
  tdir: string;
94
102
  adir: string;
@@ -57,10 +57,17 @@ interface ExampleObj {
57
57
  examplesRaw?: Globs;
58
58
  md?: string;
59
59
  }
60
+ type Resolve = {
61
+ find: string | RegExp;
62
+ replacement: string;
63
+ } | {
64
+ [find: string]: string;
65
+ };
60
66
  interface Config {
61
67
  router?: string;
62
68
  redirect?: boolean;
63
69
  useparam?: boolean;
70
+ resolve?: Resolve[];
64
71
  components: Array<Components>;
65
72
  example?: ExampleObj;
66
73
  }
@@ -89,6 +96,7 @@ interface TestsObj extends TextObj {
89
96
  component: AsyncComponentLoader;
90
97
  }
91
98
  interface ComponentsObj extends Component, TextObj {
99
+ url: string;
92
100
  name: string;
93
101
  tdir: string;
94
102
  adir: string;