@fangzhongya/vue-archive 0.1.3 → 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 +111 -20
- package/dist/node/index.js +111 -20
- package/dist/node_modules/.pnpm/highlight.js@11.11.1/node_modules/highlight.js/lib/core.js +1 -1
- 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/code.cjs +5 -5
- package/dist/packages/components/use/code.js +25 -26
- package/dist/packages/components/use/util.cjs +3 -3
- package/dist/packages/components/use/util.d.ts +1 -0
- package/dist/packages/components/use/util.js +166 -79
- package/dist/packages/router/index.cjs +1 -1
- package/dist/packages/router/index.js +22 -22
- package/package.json +17 -18
- /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
|
@@ -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,39 +23,38 @@
|
|
|
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.
|
|
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
|
-
"@types/node": "^
|
|
33
|
-
"@vitejs/plugin-vue": "^6.0.
|
|
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",
|
|
32
|
+
"@types/node": "^25.0.3",
|
|
33
|
+
"@vitejs/plugin-vue": "^6.0.3",
|
|
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.
|
|
40
|
+
"sass": "^1.97.1",
|
|
42
41
|
"ts-node": "^10.9.2",
|
|
43
42
|
"tsup": "^8.5.1",
|
|
44
43
|
"typescript": "^5.9.3",
|
|
45
44
|
"unplugin-vue-components": "^30.0.0",
|
|
46
|
-
"vite": "^7.
|
|
45
|
+
"vite": "^7.3.0",
|
|
47
46
|
"vite-plugin-dts": "4.5.4",
|
|
48
|
-
"vitest": "^4.0.
|
|
49
|
-
"vue-tsc": "^3.1
|
|
47
|
+
"vitest": "^4.0.16",
|
|
48
|
+
"vue-tsc": "^3.2.1"
|
|
50
49
|
},
|
|
51
50
|
"dependencies": {
|
|
52
51
|
"comment-parser": "^1.4.1",
|
|
53
52
|
"highlight.js": "^11.11.1",
|
|
54
53
|
"markdown-it": "^14.1.0",
|
|
55
54
|
"monaco-editor": "^0.55.1",
|
|
56
|
-
"prettier": "^3.7.
|
|
57
|
-
"vue": "^3.5.
|
|
58
|
-
"vue-router": "^4.6.
|
|
55
|
+
"prettier": "^3.7.4",
|
|
56
|
+
"vue": "^3.5.26",
|
|
57
|
+
"vue-router": "^4.6.4"
|
|
59
58
|
},
|
|
60
59
|
"types": "./dist/packages/index.d.ts",
|
|
61
60
|
"main": "./dist/packages/index.cjs",
|
|
File without changes
|