@fangzhongya/vue-archive 0.1.4 → 0.1.5
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.
- package/dist/node/index.cjs +24 -18
- package/dist/node/index.js +24 -18
- package/dist/packages/components/code/highlight.vue2.cjs +1 -1
- package/dist/packages/components/code/highlight.vue2.js +1 -1
- package/dist/packages/components/use/retrie/input/editor/editor.d.ts +49 -0
- package/dist/packages/router/index.cjs +1 -1
- package/dist/packages/router/index.js +22 -22
- package/package.json +11 -12
- /package/dist/node_modules/.pnpm/{@highlightjs_vue-plugin@2.1_9b7dd99aa1babbf0e2c1b55c05d36e38 → @highlightjs_vue-plugin@2.1_088738b011f896e680b57492efece010}/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.cjs +0 -0
- /package/dist/node_modules/.pnpm/{@highlightjs_vue-plugin@2.1_9b7dd99aa1babbf0e2c1b55c05d36e38 → @highlightjs_vue-plugin@2.1_088738b011f896e680b57492efece010}/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.js +0 -0
package/dist/node/index.cjs
CHANGED
|
@@ -87,12 +87,12 @@ __export(index_exports, {
|
|
|
87
87
|
});
|
|
88
88
|
module.exports = __toCommonJS(index_exports);
|
|
89
89
|
|
|
90
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
90
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-5PX3AFSC.js
|
|
91
91
|
function isArray(obj2) {
|
|
92
92
|
return Object.prototype.toString.call(obj2) == "[object Array]";
|
|
93
93
|
}
|
|
94
94
|
|
|
95
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
95
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-A276ZDLP.js
|
|
96
96
|
function getStartSames(str, val) {
|
|
97
97
|
let s = "";
|
|
98
98
|
const vs = [...val];
|
|
@@ -108,7 +108,7 @@ function getStartSames(str, val) {
|
|
|
108
108
|
return [s, str.substring(index), val.substring(index)];
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
111
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-KDOS4NFR.js
|
|
112
112
|
function getImportUrl(url, imp) {
|
|
113
113
|
const arr = getStartSames(url, imp);
|
|
114
114
|
const ts2 = arr[0];
|
|
@@ -132,12 +132,12 @@ function getImportUrl(url, imp) {
|
|
|
132
132
|
return ds.join("") + arr[2].replace(/\\/g, "/");
|
|
133
133
|
}
|
|
134
134
|
|
|
135
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
135
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-EWJJKQIO.js
|
|
136
136
|
function firstUpper(str) {
|
|
137
137
|
return str.slice(0, 1).toUpperCase() + str.slice(1);
|
|
138
138
|
}
|
|
139
139
|
|
|
140
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
140
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-XCDKXZFR.js
|
|
141
141
|
function lineToLargeHump(name) {
|
|
142
142
|
let arr = name.split("-");
|
|
143
143
|
arr = arr.map((vs) => {
|
|
@@ -846,7 +846,7 @@ function runDev(config2, configCallback) {
|
|
|
846
846
|
return new FangMd(config2, configCallback);
|
|
847
847
|
}
|
|
848
848
|
|
|
849
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
849
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-NCSN3MC5.js
|
|
850
850
|
var zObj = {
|
|
851
851
|
"<": "<",
|
|
852
852
|
">": ">",
|
|
@@ -867,7 +867,7 @@ function htmlEscape(str) {
|
|
|
867
867
|
// packages/node/index.ts
|
|
868
868
|
var import_node_path = require("path");
|
|
869
869
|
|
|
870
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
870
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-RD4EP3M5.js
|
|
871
871
|
function mergeObject(a, b, j = 0, i) {
|
|
872
872
|
if (a instanceof Array) {
|
|
873
873
|
if (j > 0 && i) {
|
|
@@ -921,7 +921,7 @@ function getConfig(key) {
|
|
|
921
921
|
return config[key];
|
|
922
922
|
}
|
|
923
923
|
|
|
924
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
924
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-7PJ2D3KR.js
|
|
925
925
|
function getVueText(content) {
|
|
926
926
|
const result = {
|
|
927
927
|
template: "",
|
|
@@ -968,7 +968,7 @@ function getVueTexts(content) {
|
|
|
968
968
|
};
|
|
969
969
|
}
|
|
970
970
|
|
|
971
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
971
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-J7CICTHH.js
|
|
972
972
|
function humpToLine(name) {
|
|
973
973
|
const reg = /(([A-Z])([^A-Z]*))/g;
|
|
974
974
|
let result;
|
|
@@ -990,12 +990,12 @@ function humpToLine(name) {
|
|
|
990
990
|
}
|
|
991
991
|
}
|
|
992
992
|
|
|
993
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
993
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-4OBNLDTJ.js
|
|
994
994
|
function firstLower(str) {
|
|
995
995
|
return str.slice(0, 1).toLowerCase() + str.slice(1);
|
|
996
996
|
}
|
|
997
997
|
|
|
998
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
998
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-Q6FMBSK4.js
|
|
999
999
|
function asyncMergeArray(arr, callback) {
|
|
1000
1000
|
return new Promise((resolve2, reject) => {
|
|
1001
1001
|
let index = 0;
|
|
@@ -1019,7 +1019,7 @@ function asyncMergeArray(arr, callback) {
|
|
|
1019
1019
|
});
|
|
1020
1020
|
}
|
|
1021
1021
|
|
|
1022
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1022
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-Z7NTQAAJ.js
|
|
1023
1023
|
function getSuffix2(url) {
|
|
1024
1024
|
const reg = /\.([a-z|A-Z][a-z|A-Z|0-9]*)$/;
|
|
1025
1025
|
const regs = reg.exec(url);
|
|
@@ -1029,7 +1029,7 @@ function getSuffix2(url) {
|
|
|
1029
1029
|
return "";
|
|
1030
1030
|
}
|
|
1031
1031
|
|
|
1032
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1032
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-S6JRKYPY.js
|
|
1033
1033
|
function matchsStart2(key, matchs) {
|
|
1034
1034
|
if (matchs && matchs.length > 0) {
|
|
1035
1035
|
for (const value of matchs) {
|
|
@@ -1049,7 +1049,7 @@ function matchsStart2(key, matchs) {
|
|
|
1049
1049
|
}
|
|
1050
1050
|
}
|
|
1051
1051
|
|
|
1052
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1052
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-YNOFNHEK.js
|
|
1053
1053
|
function matchsEnd2(key, matchs) {
|
|
1054
1054
|
if (matchs && matchs.length > 0) {
|
|
1055
1055
|
for (const value of matchs) {
|
|
@@ -1712,7 +1712,7 @@ function parse(source, options = {}) {
|
|
|
1712
1712
|
}
|
|
1713
1713
|
var stringify = getStringifier();
|
|
1714
1714
|
|
|
1715
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1715
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-FS4JPT23.js
|
|
1716
1716
|
function deComment(code) {
|
|
1717
1717
|
let output = "";
|
|
1718
1718
|
let state = "code";
|
|
@@ -1804,7 +1804,7 @@ function deComment(code) {
|
|
|
1804
1804
|
return output;
|
|
1805
1805
|
}
|
|
1806
1806
|
|
|
1807
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1807
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-N5Y3XGHX.js
|
|
1808
1808
|
function getImports(code, includeType = false) {
|
|
1809
1809
|
code = deComment(code);
|
|
1810
1810
|
const imports = /* @__PURE__ */ new Set();
|
|
@@ -3230,7 +3230,7 @@ var top_default2 = (0, import_vue2.defineComponent)({
|
|
|
3230
3230
|
}
|
|
3231
3231
|
});
|
|
3232
3232
|
|
|
3233
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
3233
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-Q6BNW3MO.js
|
|
3234
3234
|
var FUNCTION_REGEX = /^\s*(?:(async)\s+)?(?:function\s*(\*?)\s*(\w*)\s*\(([\s\S]*?)\)|(\*?\s*)\b(\w+)\s*\(([\s\S]*?)\)|\(([\s\S]*?)\)|([^=>,\(\)]+?))\s*(?:=>)?\s*(?:\{([\s\S]*?)\}|([\s\S]*))$/;
|
|
3235
3235
|
function getFunctionFormat(v) {
|
|
3236
3236
|
if (!v) return;
|
|
@@ -3272,6 +3272,8 @@ function getFunctionFormat(v) {
|
|
|
3272
3272
|
let name = "";
|
|
3273
3273
|
let param = "";
|
|
3274
3274
|
let body = "";
|
|
3275
|
+
let isArrow = false;
|
|
3276
|
+
let arrowBody = "";
|
|
3275
3277
|
if (funcParams !== void 0) {
|
|
3276
3278
|
isGenerator = funcGenerator === "*";
|
|
3277
3279
|
name = funcName || "";
|
|
@@ -3283,18 +3285,22 @@ function getFunctionFormat(v) {
|
|
|
3283
3285
|
param = methodParams;
|
|
3284
3286
|
body = blockBody || exprBody || "";
|
|
3285
3287
|
} else if (arrowParenParams !== void 0 || arrowSingleParam !== void 0) {
|
|
3288
|
+
isArrow = true;
|
|
3286
3289
|
param = arrowParenParams || arrowSingleParam || "";
|
|
3287
3290
|
body = blockBody || exprBody || "";
|
|
3291
|
+
arrowBody = body.trim();
|
|
3288
3292
|
if (!blockBody && !/^\s*return\b/.test(body)) {
|
|
3289
3293
|
body = `return ${body}`;
|
|
3290
3294
|
}
|
|
3291
3295
|
}
|
|
3292
3296
|
return {
|
|
3297
|
+
isArrow,
|
|
3293
3298
|
isAsync,
|
|
3294
3299
|
isGenerator,
|
|
3295
3300
|
...name && { name },
|
|
3296
3301
|
param: param.trim(),
|
|
3297
|
-
body: body.trim()
|
|
3302
|
+
body: body.trim(),
|
|
3303
|
+
arrowBody
|
|
3298
3304
|
};
|
|
3299
3305
|
}
|
|
3300
3306
|
|
package/dist/node/index.js
CHANGED
|
@@ -58,12 +58,12 @@ var init_prettier = __esm({
|
|
|
58
58
|
}
|
|
59
59
|
});
|
|
60
60
|
|
|
61
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
61
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-5PX3AFSC.js
|
|
62
62
|
function isArray(obj2) {
|
|
63
63
|
return Object.prototype.toString.call(obj2) == "[object Array]";
|
|
64
64
|
}
|
|
65
65
|
|
|
66
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
66
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-A276ZDLP.js
|
|
67
67
|
function getStartSames(str, val) {
|
|
68
68
|
let s = "";
|
|
69
69
|
const vs = [...val];
|
|
@@ -79,7 +79,7 @@ function getStartSames(str, val) {
|
|
|
79
79
|
return [s, str.substring(index), val.substring(index)];
|
|
80
80
|
}
|
|
81
81
|
|
|
82
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
82
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-KDOS4NFR.js
|
|
83
83
|
function getImportUrl(url, imp) {
|
|
84
84
|
const arr = getStartSames(url, imp);
|
|
85
85
|
const ts2 = arr[0];
|
|
@@ -103,12 +103,12 @@ function getImportUrl(url, imp) {
|
|
|
103
103
|
return ds.join("") + arr[2].replace(/\\/g, "/");
|
|
104
104
|
}
|
|
105
105
|
|
|
106
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
106
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-EWJJKQIO.js
|
|
107
107
|
function firstUpper(str) {
|
|
108
108
|
return str.slice(0, 1).toUpperCase() + str.slice(1);
|
|
109
109
|
}
|
|
110
110
|
|
|
111
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
111
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-XCDKXZFR.js
|
|
112
112
|
function lineToLargeHump(name) {
|
|
113
113
|
let arr = name.split("-");
|
|
114
114
|
arr = arr.map((vs) => {
|
|
@@ -828,7 +828,7 @@ function runDev(config2, configCallback) {
|
|
|
828
828
|
return new FangMd(config2, configCallback);
|
|
829
829
|
}
|
|
830
830
|
|
|
831
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
831
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-NCSN3MC5.js
|
|
832
832
|
var zObj = {
|
|
833
833
|
"<": "<",
|
|
834
834
|
">": ">",
|
|
@@ -849,7 +849,7 @@ function htmlEscape(str) {
|
|
|
849
849
|
// packages/node/index.ts
|
|
850
850
|
import { join as join4 } from "path";
|
|
851
851
|
|
|
852
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
852
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-RD4EP3M5.js
|
|
853
853
|
function mergeObject(a, b, j = 0, i) {
|
|
854
854
|
if (a instanceof Array) {
|
|
855
855
|
if (j > 0 && i) {
|
|
@@ -903,7 +903,7 @@ function getConfig(key) {
|
|
|
903
903
|
return config[key];
|
|
904
904
|
}
|
|
905
905
|
|
|
906
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
906
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-7PJ2D3KR.js
|
|
907
907
|
function getVueText(content) {
|
|
908
908
|
const result = {
|
|
909
909
|
template: "",
|
|
@@ -950,7 +950,7 @@ function getVueTexts(content) {
|
|
|
950
950
|
};
|
|
951
951
|
}
|
|
952
952
|
|
|
953
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
953
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-J7CICTHH.js
|
|
954
954
|
function humpToLine(name) {
|
|
955
955
|
const reg = /(([A-Z])([^A-Z]*))/g;
|
|
956
956
|
let result;
|
|
@@ -972,12 +972,12 @@ function humpToLine(name) {
|
|
|
972
972
|
}
|
|
973
973
|
}
|
|
974
974
|
|
|
975
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
975
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-4OBNLDTJ.js
|
|
976
976
|
function firstLower(str) {
|
|
977
977
|
return str.slice(0, 1).toLowerCase() + str.slice(1);
|
|
978
978
|
}
|
|
979
979
|
|
|
980
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
980
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-Q6FMBSK4.js
|
|
981
981
|
function asyncMergeArray(arr, callback) {
|
|
982
982
|
return new Promise((resolve2, reject) => {
|
|
983
983
|
let index = 0;
|
|
@@ -1001,7 +1001,7 @@ function asyncMergeArray(arr, callback) {
|
|
|
1001
1001
|
});
|
|
1002
1002
|
}
|
|
1003
1003
|
|
|
1004
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1004
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-Z7NTQAAJ.js
|
|
1005
1005
|
function getSuffix2(url) {
|
|
1006
1006
|
const reg = /\.([a-z|A-Z][a-z|A-Z|0-9]*)$/;
|
|
1007
1007
|
const regs = reg.exec(url);
|
|
@@ -1011,7 +1011,7 @@ function getSuffix2(url) {
|
|
|
1011
1011
|
return "";
|
|
1012
1012
|
}
|
|
1013
1013
|
|
|
1014
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1014
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-S6JRKYPY.js
|
|
1015
1015
|
function matchsStart2(key, matchs) {
|
|
1016
1016
|
if (matchs && matchs.length > 0) {
|
|
1017
1017
|
for (const value of matchs) {
|
|
@@ -1031,7 +1031,7 @@ function matchsStart2(key, matchs) {
|
|
|
1031
1031
|
}
|
|
1032
1032
|
}
|
|
1033
1033
|
|
|
1034
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1034
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-YNOFNHEK.js
|
|
1035
1035
|
function matchsEnd2(key, matchs) {
|
|
1036
1036
|
if (matchs && matchs.length > 0) {
|
|
1037
1037
|
for (const value of matchs) {
|
|
@@ -1694,7 +1694,7 @@ function parse(source, options = {}) {
|
|
|
1694
1694
|
}
|
|
1695
1695
|
var stringify = getStringifier();
|
|
1696
1696
|
|
|
1697
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1697
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-FS4JPT23.js
|
|
1698
1698
|
function deComment(code) {
|
|
1699
1699
|
let output = "";
|
|
1700
1700
|
let state = "code";
|
|
@@ -1786,7 +1786,7 @@ function deComment(code) {
|
|
|
1786
1786
|
return output;
|
|
1787
1787
|
}
|
|
1788
1788
|
|
|
1789
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
1789
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-N5Y3XGHX.js
|
|
1790
1790
|
function getImports(code, includeType = false) {
|
|
1791
1791
|
code = deComment(code);
|
|
1792
1792
|
const imports = /* @__PURE__ */ new Set();
|
|
@@ -3212,7 +3212,7 @@ var top_default2 = defineComponent2({
|
|
|
3212
3212
|
}
|
|
3213
3213
|
});
|
|
3214
3214
|
|
|
3215
|
-
// node_modules/.pnpm/@fangzhongya+utils@0.0.
|
|
3215
|
+
// node_modules/.pnpm/@fangzhongya+utils@0.0.65/node_modules/@fangzhongya/utils/dist/chunk-Q6BNW3MO.js
|
|
3216
3216
|
var FUNCTION_REGEX = /^\s*(?:(async)\s+)?(?:function\s*(\*?)\s*(\w*)\s*\(([\s\S]*?)\)|(\*?\s*)\b(\w+)\s*\(([\s\S]*?)\)|\(([\s\S]*?)\)|([^=>,\(\)]+?))\s*(?:=>)?\s*(?:\{([\s\S]*?)\}|([\s\S]*))$/;
|
|
3217
3217
|
function getFunctionFormat(v) {
|
|
3218
3218
|
if (!v) return;
|
|
@@ -3254,6 +3254,8 @@ function getFunctionFormat(v) {
|
|
|
3254
3254
|
let name = "";
|
|
3255
3255
|
let param = "";
|
|
3256
3256
|
let body = "";
|
|
3257
|
+
let isArrow = false;
|
|
3258
|
+
let arrowBody = "";
|
|
3257
3259
|
if (funcParams !== void 0) {
|
|
3258
3260
|
isGenerator = funcGenerator === "*";
|
|
3259
3261
|
name = funcName || "";
|
|
@@ -3265,18 +3267,22 @@ function getFunctionFormat(v) {
|
|
|
3265
3267
|
param = methodParams;
|
|
3266
3268
|
body = blockBody || exprBody || "";
|
|
3267
3269
|
} else if (arrowParenParams !== void 0 || arrowSingleParam !== void 0) {
|
|
3270
|
+
isArrow = true;
|
|
3268
3271
|
param = arrowParenParams || arrowSingleParam || "";
|
|
3269
3272
|
body = blockBody || exprBody || "";
|
|
3273
|
+
arrowBody = body.trim();
|
|
3270
3274
|
if (!blockBody && !/^\s*return\b/.test(body)) {
|
|
3271
3275
|
body = `return ${body}`;
|
|
3272
3276
|
}
|
|
3273
3277
|
}
|
|
3274
3278
|
return {
|
|
3279
|
+
isArrow,
|
|
3275
3280
|
isAsync,
|
|
3276
3281
|
isGenerator,
|
|
3277
3282
|
...name && { name },
|
|
3278
3283
|
param: param.trim(),
|
|
3279
|
-
body: body.trim()
|
|
3284
|
+
body: body.trim(),
|
|
3285
|
+
arrowBody
|
|
3280
3286
|
};
|
|
3281
3287
|
}
|
|
3282
3288
|
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";;/* empty css */require("../../../_virtual/common.cjs");const e=require("../../../node_modules/.pnpm/@highlightjs_vue-plugin@2.
|
|
1
|
+
"use strict";;/* empty css */require("../../../_virtual/common.cjs");const e=require("../../../node_modules/.pnpm/@highlightjs_vue-plugin@2.1_088738b011f896e680b57492efece010/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.cjs"),n=require("vue"),t=n.defineComponent({props:{language:{type:String},code:{type:String}},components:{highlightjs:e.component}});module.exports=t;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/* empty css */
|
|
2
2
|
import "../../../_virtual/common.js";
|
|
3
|
-
import o from "../../../node_modules/.pnpm/@highlightjs_vue-plugin@2.
|
|
3
|
+
import o from "../../../node_modules/.pnpm/@highlightjs_vue-plugin@2.1_088738b011f896e680b57492efece010/node_modules/@highlightjs/vue-plugin/dist/highlightjs-vue.esm.min.js";
|
|
4
4
|
import { defineComponent as t } from "vue";
|
|
5
5
|
const m = t({
|
|
6
6
|
props: {
|
|
@@ -3,3 +3,52 @@ export declare function getJs(parent: HTMLElement, value: string, options?: stri
|
|
|
3
3
|
export declare function getHtml(parent: HTMLElement, value: string, options?: string[]): monaco.editor.IStandaloneCodeEditor;
|
|
4
4
|
export declare function getJson(parent: HTMLElement, value: string, options?: string[]): monaco.editor.IStandaloneCodeEditor;
|
|
5
5
|
export declare function getCss(parent: HTMLElement, value: string, options?: string[]): monaco.editor.IStandaloneCodeEditor;
|
|
6
|
+
...items: string[]): string[];
|
|
7
|
+
isArray(arg: any): arg is any[];
|
|
8
|
+
readonly prototype: any[];
|
|
9
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
10
|
+
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
11
|
+
from<T>(iterable: Iterable<T> | ArrayLike<T>): T[];
|
|
12
|
+
from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
13
|
+
of<T>(...items: T[]): T[];
|
|
14
|
+
fromAsync<T>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T | PromiseLike<T>> | ArrayLike<T | PromiseLike<T>>): Promise<T[]>;
|
|
15
|
+
fromAsync<T, U>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T> | ArrayLike<T>, mapFn: (value: Awaited<T>, index: number) => U, thisArg?: any): Promise<Awaited<U>[]>;
|
|
16
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
17
|
+
};
|
|
18
|
+
};
|
|
19
|
+
}>, {}, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
|
|
20
|
+
"update:modelValue": (...args: any[]) => void;
|
|
21
|
+
}, string, PublicProps, Readonly< ExtractPropTypes<{
|
|
22
|
+
modelValue: {
|
|
23
|
+
type: StringConstructor;
|
|
24
|
+
default: string;
|
|
25
|
+
};
|
|
26
|
+
format: {
|
|
27
|
+
type: StringConstructor;
|
|
28
|
+
};
|
|
29
|
+
options: {
|
|
30
|
+
type: {
|
|
31
|
+
(arrayLength: number): string[];
|
|
32
|
+
(...items: string[]): string[];
|
|
33
|
+
new (arrayLength: number): string[];
|
|
34
|
+
new (...items: string[]): string[];
|
|
35
|
+
isArray(arg: any): arg is any[];
|
|
36
|
+
readonly prototype: any[];
|
|
37
|
+
from<T>(arrayLike: ArrayLike<T>): T[];
|
|
38
|
+
from<T, U>(arrayLike: ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
39
|
+
from<T>(iterable: Iterable<T> | ArrayLike<T>): T[];
|
|
40
|
+
from<T, U>(iterable: Iterable<T> | ArrayLike<T>, mapfn: (v: T, k: number) => U, thisArg?: any): U[];
|
|
41
|
+
of<T>(...items: T[]): T[];
|
|
42
|
+
fromAsync<T>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T | PromiseLike<T>> | ArrayLike<T | PromiseLike<T>>): Promise<T[]>;
|
|
43
|
+
fromAsync<T, U>(iterableOrArrayLike: AsyncIterable<T> | Iterable<T> | ArrayLike<T>, mapFn: (value: Awaited<T>, index: number) => U, thisArg?: any): Promise<Awaited<U>[]>;
|
|
44
|
+
readonly [Symbol.species]: ArrayConstructor;
|
|
45
|
+
};
|
|
46
|
+
};
|
|
47
|
+
}>> & Readonly<{
|
|
48
|
+
"onUpdate:modelValue"?: ((...args: any[]) => any) | undefined;
|
|
49
|
+
}>, {
|
|
50
|
+
modelValue: string;
|
|
51
|
+
}, {}, {}, {}, string, ComponentProvideOptions, true, {
|
|
52
|
+
refText: HTMLDivElement;
|
|
53
|
+
}, HTMLDivElement>;
|
|
54
|
+
export default _default;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("../config.cjs"),l=require("../utils/storage.cjs");require("@fangzhongya/utils/basic/string/firstUpper");const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const d=require("../config.cjs"),l=require("../utils/storage.cjs");require("@fangzhongya/utils/basic/string/firstUpper");const f=require("./file.cjs"),g=e=>Object.freeze(Object.defineProperty({__proto__:null,default:e},Symbol.toStringTag,{value:"Module"})),i=[{path:"/__document",name:"__document",component:()=>Promise.resolve().then(()=>g(require("../index/index.vue.cjs"))),redirect:{name:"__documentIndex"},meta:{title:"文档"},children:[]}];let m=0;document.addEventListener("keydown",y);function y(e){e=e||window.event,(e.ctrlKey&&e.location==82||e.location==116)&&l.setSession("-keydown-F5",2)}let o="__document";function h(e){o=d.getConfig("router")||"__document";let t="/"+o;if(i[0].path=t,i[0].name=o,i[0].redirect={name:o+"Index"},i[0].children?.unshift({path:t+"/:chapters+",redirect:{name:o+"Index"}}),f.getFileName().forEach(n=>{i[0].children?.push({path:n.value,name:o+n.name,component:n.component})}),i.forEach(n=>{e.addRoute(n)}),e.beforeEach((n,r,c)=>{if(r.fullPath=="/"){let p=l.getSession("-keydown-F5");document.referrer||p==2?(console.log("刷新"),m=2):(console.log("地址栏输入 或者 刷新"),m=3)}else console.log("跳转"),m=1;l.setSession("-keydown-F5",0),c()}),d.getConfig("redirect")){const n=e.getRoutes().filter(r=>r.path=="/")[0]||{path:"/"};n.redirect=t,n.name?e.addRoute(n.name,n):e.addRoute(n)}}const u={};function k(e){let t=e.path,a=e.params;if(a&&Object.keys(a).length)return a;{let n=u[t];return n&&Object.keys(n).length?n:m==3?{}:l.getSession("router.toPage."+t)}}function s(e,t,a="push"){let n=t.path||"";const r=t.name,c=t.params||{};delete t.params,e[a](t),r&&(n=e.resolve({name:r}).path),u[n]=c,l.setSession("router.toPage."+n,c)}function v(e,t){s(e,{name:o+"Single",query:{id:t?.name+"/"+t?.value},params:{key:t?.key,comkey:t?.comkey}})}function _(e,t){s(e,{name:o+"Develop",query:{id:t?.value},params:{key:t?.key}})}function P(e,t){s(e,{name:o+"Edit",query:{id:t?.value},params:{key:t?.key}})}function S(e,t){s(e,{name:o+"Tests",query:{id:t?.value},params:{key:t?.key}})}function q(e,t){s(e,{name:o+"Compon",query:{id:t?.value},params:{key:t?.key}})}exports.getPageParams=k;exports.init=h;exports.toCompon=q;exports.toDevelop=_;exports.toEdit=P;exports.toPage=s;exports.toSingle=v;exports.toTests=S;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { getConfig as d } from "../config.js";
|
|
2
2
|
import { setSession as s, getSession as p } from "../utils/storage.js";
|
|
3
3
|
import "@fangzhongya/utils/basic/string/firstUpper";
|
|
4
|
-
import { getFileName as
|
|
4
|
+
import { getFileName as y } from "./file.js";
|
|
5
5
|
const i = [
|
|
6
6
|
{
|
|
7
7
|
path: "/__document",
|
|
@@ -13,19 +13,19 @@ const i = [
|
|
|
13
13
|
}
|
|
14
14
|
];
|
|
15
15
|
let l = 0;
|
|
16
|
-
document.addEventListener("keydown",
|
|
17
|
-
function
|
|
16
|
+
document.addEventListener("keydown", h);
|
|
17
|
+
function h(t) {
|
|
18
18
|
t = t || window.event, (t.ctrlKey && t.location == 82 || //ctrl+R
|
|
19
19
|
t.location == 116) && s("-keydown-F5", 2);
|
|
20
20
|
}
|
|
21
21
|
let a = "__document";
|
|
22
|
-
function
|
|
22
|
+
function P(t) {
|
|
23
23
|
a = d("router") || "__document";
|
|
24
24
|
let e = "/" + a;
|
|
25
25
|
if (i[0].path = e, i[0].name = a, i[0].redirect = { name: a + "Index" }, i[0].children?.unshift({
|
|
26
26
|
path: e + "/:chapters+",
|
|
27
27
|
redirect: { name: a + "Index" }
|
|
28
|
-
}),
|
|
28
|
+
}), y().forEach((n) => {
|
|
29
29
|
i[0].children?.push({
|
|
30
30
|
path: n.value,
|
|
31
31
|
name: a + n.name,
|
|
@@ -33,13 +33,13 @@ function _(t) {
|
|
|
33
33
|
});
|
|
34
34
|
}), i.forEach((n) => {
|
|
35
35
|
t.addRoute(n);
|
|
36
|
-
}), t.beforeEach((n, r) => {
|
|
36
|
+
}), t.beforeEach((n, r, c) => {
|
|
37
37
|
if (r.fullPath == "/") {
|
|
38
|
-
let
|
|
39
|
-
document.referrer ||
|
|
38
|
+
let f = p("-keydown-F5");
|
|
39
|
+
document.referrer || f == 2 ? (console.log("刷新"), l = 2) : (console.log("地址栏输入 或者 刷新"), l = 3);
|
|
40
40
|
} else
|
|
41
41
|
console.log("跳转"), l = 1;
|
|
42
|
-
s("-keydown-F5", 0);
|
|
42
|
+
s("-keydown-F5", 0), c();
|
|
43
43
|
}), d("redirect")) {
|
|
44
44
|
const n = t.getRoutes().filter((r) => r.path == "/")[0] || {
|
|
45
45
|
path: "/"
|
|
@@ -48,7 +48,7 @@ function _(t) {
|
|
|
48
48
|
}
|
|
49
49
|
}
|
|
50
50
|
const u = {};
|
|
51
|
-
function
|
|
51
|
+
function w(t) {
|
|
52
52
|
let e = t.path, o = t.params;
|
|
53
53
|
if (o && Object.keys(o).length)
|
|
54
54
|
return o;
|
|
@@ -62,7 +62,7 @@ function m(t, e, o = "push") {
|
|
|
62
62
|
const r = e.name, c = e.params || {};
|
|
63
63
|
delete e.params, t[o](e), r && (n = t.resolve({ name: r }).path), u[n] = c, s("router.toPage." + n, c);
|
|
64
64
|
}
|
|
65
|
-
function
|
|
65
|
+
function E(t, e) {
|
|
66
66
|
m(t, {
|
|
67
67
|
name: a + "Single",
|
|
68
68
|
query: {
|
|
@@ -71,7 +71,7 @@ function w(t, e) {
|
|
|
71
71
|
params: { key: e?.key, comkey: e?.comkey }
|
|
72
72
|
});
|
|
73
73
|
}
|
|
74
|
-
function
|
|
74
|
+
function q(t, e) {
|
|
75
75
|
m(t, {
|
|
76
76
|
name: a + "Develop",
|
|
77
77
|
query: {
|
|
@@ -80,7 +80,7 @@ function E(t, e) {
|
|
|
80
80
|
params: { key: e?.key }
|
|
81
81
|
});
|
|
82
82
|
}
|
|
83
|
-
function
|
|
83
|
+
function x(t, e) {
|
|
84
84
|
m(t, {
|
|
85
85
|
name: a + "Edit",
|
|
86
86
|
query: {
|
|
@@ -89,7 +89,7 @@ function q(t, e) {
|
|
|
89
89
|
params: { key: e?.key }
|
|
90
90
|
});
|
|
91
91
|
}
|
|
92
|
-
function
|
|
92
|
+
function F(t, e) {
|
|
93
93
|
m(t, {
|
|
94
94
|
name: a + "Tests",
|
|
95
95
|
query: {
|
|
@@ -98,7 +98,7 @@ function x(t, e) {
|
|
|
98
98
|
params: { key: e?.key }
|
|
99
99
|
});
|
|
100
100
|
}
|
|
101
|
-
function
|
|
101
|
+
function R(t, e) {
|
|
102
102
|
m(t, {
|
|
103
103
|
name: a + "Compon",
|
|
104
104
|
query: {
|
|
@@ -108,12 +108,12 @@ function F(t, e) {
|
|
|
108
108
|
});
|
|
109
109
|
}
|
|
110
110
|
export {
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
111
|
+
w as getPageParams,
|
|
112
|
+
P as init,
|
|
113
|
+
R as toCompon,
|
|
114
|
+
q as toDevelop,
|
|
115
|
+
x as toEdit,
|
|
116
116
|
m as toPage,
|
|
117
|
-
|
|
118
|
-
|
|
117
|
+
E as toSingle,
|
|
118
|
+
F as toTests
|
|
119
119
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@fangzhongya/vue-archive",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "0.1.
|
|
4
|
+
"version": "0.1.5",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"description ": "vue 组件注释生成文档",
|
|
7
7
|
"author": "fangzhongya ",
|
|
@@ -23,22 +23,21 @@
|
|
|
23
23
|
"@codemirror/lang-html": "^6.4.11",
|
|
24
24
|
"@codemirror/lang-javascript": "^6.2.4",
|
|
25
25
|
"@codemirror/lang-json": "^6.0.2",
|
|
26
|
-
"@codemirror/state": "^6.5.
|
|
27
|
-
"@codemirror/view": "^6.39.
|
|
26
|
+
"@codemirror/state": "^6.5.3",
|
|
27
|
+
"@codemirror/view": "^6.39.8",
|
|
28
28
|
"@fangzhongya/create": "0.2.43",
|
|
29
|
-
"@fangzhongya/utils": "0.0.
|
|
29
|
+
"@fangzhongya/utils": "0.0.65",
|
|
30
30
|
"@fangzhongya/vue-components": "0.1.20",
|
|
31
31
|
"@highlightjs/vue-plugin": "^2.1.0",
|
|
32
32
|
"@types/node": "^25.0.3",
|
|
33
33
|
"@vitejs/plugin-vue": "^6.0.3",
|
|
34
|
-
"@vue/compiler-dom": "3.5.
|
|
35
|
-
"@vue/compiler-sfc": "3.5.
|
|
36
|
-
"@vue/runtime-dom": "3.5.
|
|
37
|
-
"@vue/server-renderer": "3.5.
|
|
38
|
-
"@vue/shared": "3.5.25",
|
|
34
|
+
"@vue/compiler-dom": "3.5.26",
|
|
35
|
+
"@vue/compiler-sfc": "3.5.26",
|
|
36
|
+
"@vue/runtime-dom": "3.5.26",
|
|
37
|
+
"@vue/server-renderer": "3.5.26",
|
|
39
38
|
"codemirror": "^6.0.2",
|
|
40
39
|
"fast-glob": "^3.3.3",
|
|
41
|
-
"sass": "^1.97.
|
|
40
|
+
"sass": "^1.97.1",
|
|
42
41
|
"ts-node": "^10.9.2",
|
|
43
42
|
"tsup": "^8.5.1",
|
|
44
43
|
"typescript": "^5.9.3",
|
|
@@ -46,7 +45,7 @@
|
|
|
46
45
|
"vite": "^7.3.0",
|
|
47
46
|
"vite-plugin-dts": "4.5.4",
|
|
48
47
|
"vitest": "^4.0.16",
|
|
49
|
-
"vue-tsc": "^3.1
|
|
48
|
+
"vue-tsc": "^3.2.1"
|
|
50
49
|
},
|
|
51
50
|
"dependencies": {
|
|
52
51
|
"comment-parser": "^1.4.1",
|
|
@@ -54,7 +53,7 @@
|
|
|
54
53
|
"markdown-it": "^14.1.0",
|
|
55
54
|
"monaco-editor": "^0.55.1",
|
|
56
55
|
"prettier": "^3.7.4",
|
|
57
|
-
"vue": "^3.5.
|
|
56
|
+
"vue": "^3.5.26",
|
|
58
57
|
"vue-router": "^4.6.4"
|
|
59
58
|
},
|
|
60
59
|
"types": "./dist/packages/index.d.ts",
|
|
File without changes
|