@fangzhongya/vue-archive 0.0.7 → 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.
- package/README.md +3 -2
- package/dist/node/index.cjs +135 -71
- package/dist/node/index.d.cts +8 -0
- package/dist/node/index.d.ts +8 -0
- package/dist/node/index.js +118 -54
- package/dist/node_modules/.pnpm/@fangzhongya_utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-LPMR5W6M.cjs +1 -0
- package/dist/node_modules/.pnpm/@fangzhongya_utils@0.0.24/node_modules/@fangzhongya/utils/dist/chunk-LPMR5W6M.js +9 -0
- package/dist/packages/components/aside/index.vue.cjs +1 -1
- package/dist/packages/components/aside/index.vue.js +43 -45
- package/dist/packages/components/boxurl/index.vue.cjs +1 -1
- package/dist/packages/components/boxurl/index.vue.js +34 -37
- package/dist/packages/components/choice/choice.vue.cjs +1 -1
- package/dist/packages/components/choice/choice.vue.js +29 -32
- package/dist/packages/components/choice/index.vue.cjs +1 -1
- package/dist/packages/components/choice/index.vue.js +39 -42
- package/dist/packages/components/code/highlight.vue2.cjs +1 -1
- package/dist/packages/components/code/highlight.vue2.js +1 -1
- package/dist/packages/components/code/index.vue.cjs +1 -1
- package/dist/packages/components/code/index.vue.js +79 -87
- package/dist/packages/components/compo/ftable.vue.cjs +1 -1
- package/dist/packages/components/compo/ftable.vue.js +15 -15
- package/dist/packages/components/compo/index.cjs +1 -1
- package/dist/packages/components/compo/index.js +86 -97
- package/dist/packages/components/compo/index.vue.cjs +1 -1
- package/dist/packages/components/compo/index.vue.js +33 -34
- package/dist/packages/components/compo/info.vue.cjs +1 -1
- package/dist/packages/components/compo/info.vue.js +22 -25
- package/dist/packages/components/compo/top.cjs +1 -1
- package/dist/packages/components/compo/top.js +21 -21
- package/dist/packages/components/main/index.vue.cjs +1 -1
- package/dist/packages/components/main/index.vue.js +16 -17
- package/dist/packages/components/md/index.vue.cjs +1 -1
- package/dist/packages/components/md/index.vue.js +28 -32
- package/dist/packages/components/test/index.cjs +1 -1
- package/dist/packages/components/test/index.js +39 -42
- package/dist/packages/components/test/index.vue.cjs +1 -1
- package/dist/packages/components/test/index.vue.js +44 -49
- package/dist/packages/components/use/code.cjs +1 -1
- package/dist/packages/components/use/code.js +3 -3
- package/dist/packages/components/use/index.cjs +1 -1
- package/dist/packages/components/use/index.js +1 -1
- package/dist/packages/components/use/retrie/choice/index.vue.cjs +1 -1
- package/dist/packages/components/use/retrie/choice/index.vue.js +32 -34
- package/dist/packages/components/use/retrie/expose/index.vue.cjs +1 -1
- package/dist/packages/components/use/retrie/expose/index.vue.js +18 -19
- package/dist/packages/components/use/retrie/form/index.vue.cjs +1 -1
- package/dist/packages/components/use/retrie/form/index.vue.js +110 -114
- package/dist/packages/components/use/retrie/function/index.vue.cjs +2 -2
- package/dist/packages/components/use/retrie/function/index.vue.js +1 -4
- package/dist/packages/components/use/retrie/input/index.vue.cjs +1 -1
- package/dist/packages/components/use/retrie/input/index.vue.js +20 -21
- package/dist/packages/components/use/retrie/number/index.vue.cjs +1 -1
- package/dist/packages/components/use/retrie/number/index.vue.js +12 -13
- package/dist/packages/components/use/retrie/select/index.vue.cjs +1 -1
- package/dist/packages/components/use/retrie/select/index.vue.js +21 -23
- package/dist/packages/components/use/retrie/slot/index.vue.cjs +1 -1
- package/dist/packages/components/use/retrie/slot/index.vue.js +15 -16
- package/dist/packages/components/use/retrie/string/index.vue.cjs +1 -1
- package/dist/packages/components/use/retrie/string/index.vue.js +14 -15
- package/dist/packages/components/use/set-emit.vue.cjs +1 -1
- package/dist/packages/components/use/set-emit.vue.js +20 -24
- package/dist/packages/components/use/set-expose.vue.cjs +1 -1
- package/dist/packages/components/use/set-expose.vue.js +15 -18
- package/dist/packages/components/use/set-props.vue.cjs +1 -1
- package/dist/packages/components/use/set-props.vue.js +48 -49
- package/dist/packages/config.cjs +1 -1
- package/dist/packages/config.d.ts +8 -1
- package/dist/packages/config.js +1 -1
- package/dist/packages/directives/adjust/index copy.d.ts +6 -0
- package/dist/packages/directives/adjust/index.cjs +1 -1
- package/dist/packages/directives/adjust/index.js +96 -97
- package/dist/packages/page/comprops/index.vue2.cjs +1 -1
- package/dist/packages/page/comprops/index.vue2.js +65 -71
- package/dist/packages/page/index/index.vue2.cjs +1 -1
- package/dist/packages/page/index/index.vue2.js +19 -23
- package/dist/packages/page/single/index.vue2.cjs +1 -1
- package/dist/packages/page/single/index.vue2.js +46 -49
- package/dist/packages/router/index.cjs +1 -1
- package/dist/packages/router/index.js +44 -46
- package/dist/packages/utils/common.cjs +1 -1
- package/dist/packages/utils/common.d.ts +4 -0
- package/dist/packages/utils/common.js +57 -54
- package/dist/packages/utils/glob.cjs +3 -3
- package/dist/packages/utils/glob.d.ts +1 -1
- package/dist/packages/utils/glob.js +269 -227
- package/dist/packages/utils/props.cjs +1 -1
- package/dist/packages/utils/props.js +34 -28
- package/dist/src/components/common/cs3.d.ts +4 -0
- package/dist/src/components/common/index.d.ts +4 -0
- package/dist/src/components/cs/expose/index.d.ts +4 -1
- package/dist/src/components/cs/expose/src/index.vue.d.ts +4 -1
- package/dist/vue-archive.css +1 -1
- package/package.json +18 -19
- package/dist/node_modules/.pnpm/@fangzhongya_utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-SNABGVNO.cjs +0 -1
- package/dist/node_modules/.pnpm/@fangzhongya_utils@0.0.8-77/node_modules/@fangzhongya/utils/dist/chunk-SNABGVNO.js +0 -9
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
- /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
|
@@ -1,55 +1,52 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as x, ref as d, onMounted as b, createElementBlock as a, openBlock as o, createElementVNode as s, renderSlot as m, normalizeStyle as p, createCommentVNode as f, toDisplayString as i, Fragment as y, renderList as _ } from "vue";
|
|
2
|
+
const g = { class: "box-url-span" }, h = { class: "box-url-box-div" }, k = { class: "box-div-li" }, N = { class: "box-div-li-span" }, S = { class: "box-div-li-span" }, w = {
|
|
3
3
|
key: 0,
|
|
4
4
|
class: "box-div-li"
|
|
5
|
-
},
|
|
5
|
+
}, B = { class: "box-div-li-span" }, C = { class: "box-div-li" }, E = { class: "box-div-li-span" }, X = /* @__PURE__ */ x({
|
|
6
6
|
__name: "index",
|
|
7
7
|
props: {
|
|
8
8
|
value: Object
|
|
9
9
|
},
|
|
10
10
|
setup(l) {
|
|
11
11
|
const v = d(), u = d(""), r = d("");
|
|
12
|
-
return
|
|
12
|
+
return b(() => {
|
|
13
13
|
v.value.onmouseenter = (e) => {
|
|
14
14
|
var e = e || window.event;
|
|
15
|
-
let t,
|
|
16
|
-
e.x || e.y ? (t = e.x,
|
|
15
|
+
let t, n;
|
|
16
|
+
e.x || e.y ? (t = e.x, n = e.y) : (e.pageX || e.pageY) && (t = e.pageX - 1, n = e.pageY - 1), u.value = t + "px", r.value = n + "px";
|
|
17
17
|
};
|
|
18
|
-
}), (
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
18
|
+
}), (c, e) => (o(), a("div", {
|
|
19
|
+
ref_key: "boxurl",
|
|
20
|
+
ref: v,
|
|
21
|
+
class: "box-url"
|
|
22
|
+
}, [
|
|
23
|
+
s("span", g, [
|
|
24
|
+
m(c.$slots, "default")
|
|
25
|
+
]),
|
|
26
|
+
s("div", {
|
|
27
|
+
class: "box-url-box",
|
|
28
|
+
style: p({ top: r.value, left: u.value })
|
|
24
29
|
}, [
|
|
25
|
-
s("
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
s("div", E, n((t = l.value) == null ? void 0 : t.name), 1),
|
|
35
|
-
s("div", V, n((a = l.value) == null ? void 0 : a.value), 1)
|
|
36
|
-
]),
|
|
37
|
-
(c = l.value) != null && c.aliasNames && ((x = l.value) != null && x.aliasNames.length) ? (i(), o("div", X, [
|
|
38
|
-
e[0] || (e[0] = s("div", { class: "box-div-li-span" }, "别名", -1)),
|
|
39
|
-
s("div", Y, [
|
|
40
|
-
(i(!0), o(N, null, S((b = l.value) == null ? void 0 : b.aliasNames, (f) => (i(), o("span", null, n(f), 1))), 256))
|
|
41
|
-
])
|
|
42
|
-
])) : k("", !0),
|
|
43
|
-
s("div", j, [
|
|
44
|
-
e[1] || (e[1] = s("div", { class: "box-div-li-span" }, " 文件路径 ", -1)),
|
|
45
|
-
s("div", z, n((m = l.value) == null ? void 0 : m.key), 1)
|
|
30
|
+
s("div", h, [
|
|
31
|
+
s("div", k, [
|
|
32
|
+
s("div", N, i(l.value?.name), 1),
|
|
33
|
+
s("div", S, i(l.value?.value), 1)
|
|
34
|
+
]),
|
|
35
|
+
l.value?.aliasNames && l.value?.aliasNames.length ? (o(), a("div", w, [
|
|
36
|
+
e[0] || (e[0] = s("div", { class: "box-div-li-span" }, "别名", -1)),
|
|
37
|
+
s("div", B, [
|
|
38
|
+
(o(!0), a(y, null, _(l.value?.aliasNames, (t) => (o(), a("span", null, i(t), 1))), 256))
|
|
46
39
|
])
|
|
40
|
+
])) : f("", !0),
|
|
41
|
+
s("div", C, [
|
|
42
|
+
e[1] || (e[1] = s("div", { class: "box-div-li-span" }, " 文件路径 ", -1)),
|
|
43
|
+
s("div", E, i(l.value?.key), 1)
|
|
47
44
|
])
|
|
48
|
-
]
|
|
49
|
-
],
|
|
50
|
-
|
|
45
|
+
])
|
|
46
|
+
], 4)
|
|
47
|
+
], 512));
|
|
51
48
|
}
|
|
52
49
|
});
|
|
53
50
|
export {
|
|
54
|
-
|
|
51
|
+
X as default
|
|
55
52
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),
|
|
1
|
+
"use strict";const e=require("vue"),r=require("../boxurl/index.vue.cjs"),d={class:"choice aside"},_=["onClick"],u={class:"aside-li-name"},p={class:"aside-li-name-name"},m={class:"aside-li-name-aliass"},k={class:"aside-li-name-aliass"},h=e.defineComponent({__name:"choice",props:{value:{type:Array},choice:{type:Object}},emits:["change"],setup(a,{emit:l}){const n=a,o=l;function i(s){o("change",s)}return(s,v)=>(e.openBlock(),e.createElementBlock("div",d,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.value,(t,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["aside-li",{on:t.key==n.choice?.key}]),onClick:c=>i(t)},[e.createVNode(r,{value:t},{default:e.withCtx(()=>[e.createElementVNode("div",u,[e.createElementVNode("div",p,e.toDisplayString(t.name),1),e.createElementVNode("div",m,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(t.aliasNames,c=>(e.openBlock(),e.createElementBlock("span",null,e.toDisplayString(c),1))),256))]),e.createElementVNode("div",k,[e.createElementVNode("span",null,e.toDisplayString(t.key),1)])])]),_:2},1032,["value"])],10,_))),256))]))}});module.exports=h;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
const
|
|
1
|
+
import { defineComponent as p, createElementBlock as s, openBlock as a, Fragment as l, renderList as r, normalizeClass as h, createVNode as v, withCtx as k, createElementVNode as n, toDisplayString as t } from "vue";
|
|
2
|
+
import f from "../boxurl/index.vue.js";
|
|
3
|
+
const y = { class: "choice aside" }, C = ["onClick"], g = { class: "aside-li-name" }, x = { class: "aside-li-name-name" }, N = { class: "aside-li-name-aliass" }, B = { class: "aside-li-name-aliass" }, j = /* @__PURE__ */ p({
|
|
4
4
|
__name: "choice",
|
|
5
5
|
props: {
|
|
6
6
|
value: {
|
|
@@ -11,39 +11,36 @@ const C = { class: "choice aside" }, g = ["onClick"], x = { class: "aside-li-nam
|
|
|
11
11
|
}
|
|
12
12
|
},
|
|
13
13
|
emits: ["change"],
|
|
14
|
-
setup(
|
|
15
|
-
const i =
|
|
16
|
-
function
|
|
17
|
-
|
|
14
|
+
setup(d, { emit: _ }) {
|
|
15
|
+
const i = d, u = _;
|
|
16
|
+
function m(c) {
|
|
17
|
+
u("change", c);
|
|
18
18
|
}
|
|
19
|
-
return (c,
|
|
20
|
-
(a(!0), s(
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
n("div",
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
n("div", E, [
|
|
36
|
-
n("span", null, t(e.key), 1)
|
|
37
|
-
])
|
|
19
|
+
return (c, E) => (a(), s("div", y, [
|
|
20
|
+
(a(!0), s(l, null, r(i.value, (e, V) => (a(), s("div", {
|
|
21
|
+
class: h(["aside-li", {
|
|
22
|
+
on: e.key == i.choice?.key
|
|
23
|
+
}]),
|
|
24
|
+
onClick: (o) => m(e)
|
|
25
|
+
}, [
|
|
26
|
+
v(f, { value: e }, {
|
|
27
|
+
default: k(() => [
|
|
28
|
+
n("div", g, [
|
|
29
|
+
n("div", x, t(e.name), 1),
|
|
30
|
+
n("div", N, [
|
|
31
|
+
(a(!0), s(l, null, r(e.aliasNames, (o) => (a(), s("span", null, t(o), 1))), 256))
|
|
32
|
+
]),
|
|
33
|
+
n("div", B, [
|
|
34
|
+
n("span", null, t(e.key), 1)
|
|
38
35
|
])
|
|
39
|
-
])
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
36
|
+
])
|
|
37
|
+
]),
|
|
38
|
+
_: 2
|
|
39
|
+
}, 1032, ["value"])
|
|
40
|
+
], 10, C))), 256))
|
|
44
41
|
]));
|
|
45
42
|
}
|
|
46
43
|
});
|
|
47
44
|
export {
|
|
48
|
-
|
|
45
|
+
j as default
|
|
49
46
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),
|
|
1
|
+
"use strict";const e=require("vue"),_=require("./choice.vue.cjs"),p=require("../../utils/glob.cjs"),h=require("../../utils/common.cjs"),g=require("vue-router"),k=require("../../router/index.cjs"),y={class:"__document-compon"},f={key:0,class:"__document-compon-choice"},B={key:0},q={key:1},C={key:2},E=e.defineComponent({__name:"index",props:{getName:{type:Function,default(l){return l.id}},getKey:{type:Function,default(l){return l.key}}},emits:["change"],setup(l,{emit:v}){const r=l,u=g.useRoute(),m=k.getPageParams(u),t=e.ref(),n=e.ref([]),c=e.ref(!1),a=v;e.watch(()=>u.query.id,()=>{s()});function s(){let o=p.getCompoName(r.getName(u.query),!0,r.getKey(m))||[];n.value=[],o.length==1?(t.value=o[0],a("change",t.value)):o.length==0?(t.value=void 0,a("change",t.value)):(c.value=!0,n.value=o)}function d(o){c.value=!1,t.value=o,a("change",t.value),h.setAsideKey(o.key)}return s(),(o,i)=>(e.openBlock(),e.createElementBlock("div",y,[n.value.length?(e.openBlock(),e.createElementBlock("div",f,[c.value?(e.openBlock(),e.createBlock(_,{key:0,onChange:d,value:n.value,choice:t.value},null,8,["value","choice"])):e.createCommentVNode("",!0),e.createElementVNode("div",{onClick:i[0]||(i[0]=N=>c.value=!c.value),class:"__document-compon-choice-but"},e.toDisplayString(c.value?"展开":"隐藏"),1)])):e.createCommentVNode("",!0),e.createElementVNode("div",{class:e.normalizeClass(["__document-compon-body",{choice:n.value.length}])},[t.value?.key?(e.openBlock(),e.createElementBlock("div",B,[e.renderSlot(o.$slots,"default",{value:t.value})])):n.value.length?(e.openBlock(),e.createElementBlock("div",q," 请先选择要查看的组件 ")):(e.openBlock(),e.createElementBlock("div",C," 没有查询到"+e.toDisplayString(e.unref(u).query.id)+"组件 ",1))],2)]))}});module.exports=E;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import { getCompoName as
|
|
4
|
-
import { setAsideKey as
|
|
5
|
-
import { useRoute as
|
|
6
|
-
import { getPageParams as
|
|
7
|
-
const
|
|
1
|
+
import { defineComponent as y, ref as s, watch as k, createElementBlock as l, openBlock as a, createCommentVNode as d, createElementVNode as p, createBlock as C, toDisplayString as _, normalizeClass as N, renderSlot as q, unref as B } from "vue";
|
|
2
|
+
import K from "./choice.vue.js";
|
|
3
|
+
import { getCompoName as $ } from "../../utils/glob.js";
|
|
4
|
+
import { setAsideKey as b } from "../../utils/common.js";
|
|
5
|
+
import { useRoute as x } from "vue-router";
|
|
6
|
+
import { getPageParams as D } from "../../router/index.js";
|
|
7
|
+
const E = { class: "__document-compon" }, F = {
|
|
8
8
|
key: 0,
|
|
9
9
|
class: "__document-compon-choice"
|
|
10
|
-
},
|
|
10
|
+
}, P = { key: 0 }, S = { key: 1 }, V = { key: 2 }, I = /* @__PURE__ */ y({
|
|
11
11
|
__name: "index",
|
|
12
12
|
props: {
|
|
13
13
|
getName: {
|
|
@@ -24,53 +24,50 @@ const F = { class: "__document-compon" }, P = {
|
|
|
24
24
|
}
|
|
25
25
|
},
|
|
26
26
|
emits: ["change"],
|
|
27
|
-
setup(c, { emit:
|
|
28
|
-
const r = c, u =
|
|
29
|
-
|
|
27
|
+
setup(c, { emit: h }) {
|
|
28
|
+
const r = c, u = x(), f = D(u), e = s(), o = s([]), n = s(!1), i = h;
|
|
29
|
+
k(
|
|
30
30
|
() => u.query.id,
|
|
31
31
|
() => {
|
|
32
32
|
m();
|
|
33
33
|
}
|
|
34
34
|
);
|
|
35
35
|
function m() {
|
|
36
|
-
let t =
|
|
36
|
+
let t = $(
|
|
37
37
|
r.getName(u.query),
|
|
38
38
|
!0,
|
|
39
|
-
r.getKey(
|
|
39
|
+
r.getKey(f)
|
|
40
40
|
) || [];
|
|
41
41
|
o.value = [], t.length == 1 ? (e.value = t[0], i("change", e.value)) : t.length == 0 ? (e.value = void 0, i("change", e.value)) : (n.value = !0, o.value = t);
|
|
42
42
|
}
|
|
43
|
-
function
|
|
44
|
-
n.value = !1, e.value = t, i("change", e.value),
|
|
43
|
+
function g(t) {
|
|
44
|
+
n.value = !1, e.value = t, i("change", e.value), b(t.key);
|
|
45
45
|
}
|
|
46
|
-
return m(), (t, v) =>
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
], 2)
|
|
70
|
-
]);
|
|
71
|
-
};
|
|
46
|
+
return m(), (t, v) => (a(), l("div", E, [
|
|
47
|
+
o.value.length ? (a(), l("div", F, [
|
|
48
|
+
n.value ? (a(), C(K, {
|
|
49
|
+
key: 0,
|
|
50
|
+
onChange: g,
|
|
51
|
+
value: o.value,
|
|
52
|
+
choice: e.value
|
|
53
|
+
}, null, 8, ["value", "choice"])) : d("", !0),
|
|
54
|
+
p("div", {
|
|
55
|
+
onClick: v[0] || (v[0] = (w) => n.value = !n.value),
|
|
56
|
+
class: "__document-compon-choice-but"
|
|
57
|
+
}, _(n.value ? "展开" : "隐藏"), 1)
|
|
58
|
+
])) : d("", !0),
|
|
59
|
+
p("div", {
|
|
60
|
+
class: N(["__document-compon-body", {
|
|
61
|
+
choice: o.value.length
|
|
62
|
+
}])
|
|
63
|
+
}, [
|
|
64
|
+
e.value?.key ? (a(), l("div", P, [
|
|
65
|
+
q(t.$slots, "default", { value: e.value })
|
|
66
|
+
])) : o.value.length ? (a(), l("div", S, " 请先选择要查看的组件 ")) : (a(), l("div", V, " 没有查询到" + _(B(u).query.id) + "组件 ", 1))
|
|
67
|
+
], 2)
|
|
68
|
+
]));
|
|
72
69
|
}
|
|
73
70
|
});
|
|
74
71
|
export {
|
|
75
|
-
|
|
72
|
+
I as default
|
|
76
73
|
};
|
|
@@ -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_b586068ec461434c266304f56a34d01a/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_b586068ec461434c266304f56a34d01a/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: {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),
|
|
1
|
+
"use strict";const e=require("vue"),u=require("../boxurl/index.vue.cjs"),g=require("../../router/index.cjs"),m=require("./highlight.vue.cjs"),v=require("../../utils/index.cjs"),d=require("../../utils/glob.cjs"),C=require("vue-router"),x={class:"code"},w={class:"code-top"},E={class:"code-top-but"},N={class:"top-but-files"},V=["onClick"],y={class:"code-highlightjs"},b=e.defineComponent({__name:"index",props:{text:String,value:Object},setup(p){const _=C.useRouter(),t=p;e.watch(()=>t.text,()=>{r()});const s=e.ref([]),o=e.ref(),n=e.ref(!1);function h(){o.value?.raw?v.copyCode(o.value.raw):v.copyCode(t.text)}function f(){n.value=!n.value}function k(){g.toSingle(_,t.value)}function a(i){n.value=!0,o.value=i}function r(){o.value=void 0,n.value=!1,t.text&&d.getTestImportUrl(t.value?.key,t.text,"vue",t.value?.comprops).then(i=>{d.getLocalTextArr(i).then(c=>{s.value=c.filter(l=>l.raw)})})}return r(),(i,c)=>(e.openBlock(),e.createElementBlock("div",x,[e.createElementVNode("div",w,[e.createElementVNode("div",E,[e.createElementVNode("div",{class:"but-div",onClick:k}," go "),e.createElementVNode("div",{class:"but-div",onClick:h}," 复制 "),e.createElementVNode("div",{class:"but-div",onClick:f},e.toDisplayString(n.value?"隐藏":"显示"),1),e.createElementVNode("div",N,[e.createVNode(u,{value:t.value},{default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(["but-div",{on:!(o.value&&o.value.value)}]),onClick:c[0]||(c[0]=e.withModifiers(l=>a(),["stop"]))}," index.vue ",2)]),_:1},8,["value"]),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(l,q)=>(e.openBlock(),e.createBlock(u,{value:l},{default:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(["but-div",{on:l.key==o.value?.key}]),onClick:e.withModifiers(B=>a(l),["stop"])},e.toDisplayString(l.value),11,V)]),_:2},1032,["value"]))),256))])])]),e.withDirectives(e.createElementVNode("div",y,[e.createVNode(m,{language:"html",code:o.value?.raw||t.text},null,8,["code"])],512),[[e.vShow,n.value]])]))}});module.exports=b;
|
|
@@ -1,111 +1,103 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import { toSingle as
|
|
4
|
-
import
|
|
5
|
-
import { copyCode as
|
|
6
|
-
import { getTestImportUrl as
|
|
7
|
-
import { useRouter as
|
|
8
|
-
const
|
|
1
|
+
import { defineComponent as S, watch as B, ref as n, createElementBlock as d, openBlock as c, createElementVNode as t, withDirectives as D, toDisplayString as f, createVNode as p, withCtx as m, withModifiers as h, normalizeClass as _, Fragment as T, renderList as $, createBlock as j, vShow as E } from "vue";
|
|
2
|
+
import k from "../boxurl/index.vue.js";
|
|
3
|
+
import { toSingle as L } from "../../router/index.js";
|
|
4
|
+
import N from "./highlight.vue.js";
|
|
5
|
+
import { copyCode as g } from "../../utils/index.js";
|
|
6
|
+
import { getTestImportUrl as V, getLocalTextArr as z } from "../../utils/glob.js";
|
|
7
|
+
import { useRouter as A } from "vue-router";
|
|
8
|
+
const F = { class: "code" }, H = { class: "code-top" }, I = { class: "code-top-but" }, M = { class: "top-but-files" }, O = ["onClick"], R = { class: "code-highlightjs" }, Y = /* @__PURE__ */ S({
|
|
9
9
|
__name: "index",
|
|
10
10
|
props: {
|
|
11
11
|
text: String,
|
|
12
12
|
value: Object
|
|
13
13
|
},
|
|
14
|
-
setup(
|
|
15
|
-
const
|
|
16
|
-
|
|
14
|
+
setup(C) {
|
|
15
|
+
const x = A(), e = C;
|
|
16
|
+
B(
|
|
17
17
|
() => e.text,
|
|
18
18
|
() => {
|
|
19
|
-
|
|
19
|
+
v();
|
|
20
20
|
}
|
|
21
21
|
);
|
|
22
|
-
const
|
|
23
|
-
function
|
|
24
|
-
|
|
25
|
-
(l = o.value) != null && l.raw ? w(o.value.raw) : w(e.text);
|
|
22
|
+
const u = n([]), o = n(), i = n(!1);
|
|
23
|
+
function w() {
|
|
24
|
+
o.value?.raw ? g(o.value.raw) : g(e.text);
|
|
26
25
|
}
|
|
27
|
-
function
|
|
28
|
-
|
|
26
|
+
function b() {
|
|
27
|
+
i.value = !i.value;
|
|
29
28
|
}
|
|
30
|
-
function
|
|
31
|
-
|
|
29
|
+
function y() {
|
|
30
|
+
L(x, e.value);
|
|
32
31
|
}
|
|
33
|
-
function
|
|
34
|
-
|
|
32
|
+
function r(a) {
|
|
33
|
+
i.value = !0, o.value = a;
|
|
35
34
|
}
|
|
36
|
-
function
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
(l = e.value) == null ? void 0 : l.key,
|
|
35
|
+
function v() {
|
|
36
|
+
o.value = void 0, i.value = !1, e.text && V(
|
|
37
|
+
e.value?.key,
|
|
40
38
|
e.text,
|
|
41
39
|
"vue",
|
|
42
|
-
|
|
43
|
-
).then((
|
|
44
|
-
|
|
45
|
-
|
|
40
|
+
e.value?.comprops
|
|
41
|
+
).then((a) => {
|
|
42
|
+
z(a).then((s) => {
|
|
43
|
+
u.value = s.filter((l) => l.raw);
|
|
46
44
|
});
|
|
47
45
|
});
|
|
48
46
|
}
|
|
49
|
-
return
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
}, h(i.value), 11, q)
|
|
90
|
-
];
|
|
91
|
-
}),
|
|
92
|
-
_: 2
|
|
93
|
-
}, 1032, ["value"]))), 256))
|
|
94
|
-
])
|
|
47
|
+
return v(), (a, s) => (c(), d("div", F, [
|
|
48
|
+
t("div", H, [
|
|
49
|
+
t("div", I, [
|
|
50
|
+
t("div", {
|
|
51
|
+
class: "but-div",
|
|
52
|
+
onClick: y
|
|
53
|
+
}, " go "),
|
|
54
|
+
t("div", {
|
|
55
|
+
class: "but-div",
|
|
56
|
+
onClick: w
|
|
57
|
+
}, " 复制 "),
|
|
58
|
+
t("div", {
|
|
59
|
+
class: "but-div",
|
|
60
|
+
onClick: b
|
|
61
|
+
}, f(i.value ? "隐藏" : "显示"), 1),
|
|
62
|
+
t("div", M, [
|
|
63
|
+
p(k, {
|
|
64
|
+
value: e.value
|
|
65
|
+
}, {
|
|
66
|
+
default: m(() => [
|
|
67
|
+
t("div", {
|
|
68
|
+
class: _(["but-div", {
|
|
69
|
+
on: !(o.value && o.value.value)
|
|
70
|
+
}]),
|
|
71
|
+
onClick: s[0] || (s[0] = h((l) => r(), ["stop"]))
|
|
72
|
+
}, " index.vue ", 2)
|
|
73
|
+
]),
|
|
74
|
+
_: 1
|
|
75
|
+
}, 8, ["value"]),
|
|
76
|
+
(c(!0), d(T, null, $(u.value, (l, U) => (c(), j(k, { value: l }, {
|
|
77
|
+
default: m(() => [
|
|
78
|
+
t("div", {
|
|
79
|
+
class: _(["but-div", {
|
|
80
|
+
on: l.key == o.value?.key
|
|
81
|
+
}]),
|
|
82
|
+
onClick: h((q) => r(l), ["stop"])
|
|
83
|
+
}, f(l.value), 11, O)
|
|
84
|
+
]),
|
|
85
|
+
_: 2
|
|
86
|
+
}, 1032, ["value"]))), 256))
|
|
95
87
|
])
|
|
96
|
-
]),
|
|
97
|
-
j(t("div", G, [
|
|
98
|
-
_(A, {
|
|
99
|
-
language: "html",
|
|
100
|
-
code: ((n = o.value) == null ? void 0 : n.raw) || e.text
|
|
101
|
-
}, null, 8, ["code"])
|
|
102
|
-
], 512), [
|
|
103
|
-
[V, a.value]
|
|
104
88
|
])
|
|
105
|
-
])
|
|
106
|
-
|
|
89
|
+
]),
|
|
90
|
+
D(t("div", R, [
|
|
91
|
+
p(N, {
|
|
92
|
+
language: "html",
|
|
93
|
+
code: o.value?.raw || e.text
|
|
94
|
+
}, null, 8, ["code"])
|
|
95
|
+
], 512), [
|
|
96
|
+
[E, i.value]
|
|
97
|
+
])
|
|
98
|
+
]));
|
|
107
99
|
}
|
|
108
100
|
});
|
|
109
101
|
export {
|
|
110
|
-
|
|
102
|
+
Y as default
|
|
111
103
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("vue"),u={class:"compo-talbe"},d={class:"compo-talbe-body"},
|
|
1
|
+
"use strict";const e=require("vue"),u={class:"compo-talbe"},d={class:"compo-talbe-body"},m={class:"compo-talbe-top"},i={class:"compo-talbe-li"},k={key:1,class:"compo-talbe-zw"},B=e.defineComponent({__name:"ftable",props:{list:{type:Array,default(){return[]}},value:{type:Array,default(){return[]}}},setup(c){const l=c;function a(n,t,o,r){if(t.formatter)return t.formatter(n,t,o,r);if(t.prop)return n[t.prop]}return(n,t)=>(e.openBlock(),e.createElementBlock("div",u,[e.createElementVNode("table",d,[e.createElementVNode("thead",null,[e.createElementVNode("tr",m,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.list,(o,r)=>(e.openBlock(),e.createElementBlock("th",null,e.toDisplayString(o?.label),1))),256))])]),e.createElementVNode("tbody",null,[l.value&&l.value.length>0?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(l.value,(o,r)=>(e.openBlock(),e.createElementBlock("tr",i,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.list,(s,p)=>(e.openBlock(),e.createElementBlock("td",null,e.toDisplayString(a(o,s,r,p)),1))),256))]))),256)):(e.openBlock(),e.createElementBlock("tr",k,t[0]||(t[0]=[e.createElementVNode("td",{colspan:"5"},"暂无",-1)])))])])]))}});module.exports=B;
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
const
|
|
1
|
+
import { defineComponent as m, createElementBlock as e, openBlock as l, createElementVNode as n, Fragment as u, renderList as c, toDisplayString as p } from "vue";
|
|
2
|
+
const b = { class: "compo-talbe" }, y = { class: "compo-talbe-body" }, h = { class: "compo-talbe-top" }, v = { class: "compo-talbe-li" }, k = {
|
|
3
3
|
key: 1,
|
|
4
4
|
class: "compo-talbe-zw"
|
|
5
|
-
}, x = /* @__PURE__ */
|
|
5
|
+
}, x = /* @__PURE__ */ m({
|
|
6
6
|
__name: "ftable",
|
|
7
7
|
props: {
|
|
8
8
|
/**
|
|
@@ -27,27 +27,27 @@ const y = { class: "compo-talbe" }, h = { class: "compo-talbe-body" }, m = { cla
|
|
|
27
27
|
}
|
|
28
28
|
},
|
|
29
29
|
setup(d) {
|
|
30
|
-
const
|
|
31
|
-
function
|
|
30
|
+
const r = d;
|
|
31
|
+
function i(a, t, o, s) {
|
|
32
32
|
if (t.formatter)
|
|
33
|
-
return t.formatter(a, t,
|
|
33
|
+
return t.formatter(a, t, o, s);
|
|
34
34
|
if (t.prop)
|
|
35
35
|
return a[t.prop];
|
|
36
36
|
}
|
|
37
|
-
return (a, t) => (l(), e("div",
|
|
38
|
-
n("table",
|
|
37
|
+
return (a, t) => (l(), e("div", b, [
|
|
38
|
+
n("table", y, [
|
|
39
39
|
n("thead", null, [
|
|
40
|
-
n("tr",
|
|
41
|
-
(l(!0), e(u, null, c(
|
|
40
|
+
n("tr", h, [
|
|
41
|
+
(l(!0), e(u, null, c(r.list, (o, s) => (l(), e("th", null, p(o?.label), 1))), 256))
|
|
42
42
|
])
|
|
43
43
|
]),
|
|
44
44
|
n("tbody", null, [
|
|
45
|
-
|
|
46
|
-
(l(!0), e(u, null, c(
|
|
47
|
-
|
|
48
|
-
|
|
45
|
+
r.value && r.value.length > 0 ? (l(!0), e(u, { key: 0 }, c(r.value, (o, s) => (l(), e("tr", v, [
|
|
46
|
+
(l(!0), e(u, null, c(r.list, (_, f) => (l(), e("td", null, p(i(
|
|
47
|
+
o,
|
|
48
|
+
_,
|
|
49
49
|
s,
|
|
50
|
-
|
|
50
|
+
f
|
|
51
51
|
)), 1))), 256))
|
|
52
52
|
]))), 256)) : (l(), e("tr", k, t[0] || (t[0] = [
|
|
53
53
|
n("td", { colspan: "5" }, "暂无", -1)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const h=require("../../utils/index.cjs"),o=require("../../utils/props.cjs"),i={titles:[],propss:[],slots:[],emitss:[],exposes:[]};function x(e,s){let r=e.charAt(0),l=[['"','"'],["'","'"],["`","`"],["(",")"],["{","}"],["[","]"]],a=l.map(p=>p[0]).indexOf(r);if(a!=-1){let n=new RegExp("^"+l[a][0]+"((.|\\n|\\r)+?)"+l[a][1]+(s?"\\s":""),"gi").exec(e);if(n)return n[0]}}function E(e){delete e.problems,delete e.source;let s=e.tag,r=e.name,l=e.description,t=e.default,a="";if(s=="default")r=r.trim(),r=x(r)||r;else if(s=="selectable")r=r.trim();else{if(r.includes("=")){const m=r.split("=");r=m[0];const g=m[1]+" "+l,d=x(g,!0);d?(t=d,l=g.replace(d,"")):t=e.default||m[1]||""}const n=/\s*\((.*)\)\s/gi.exec(l);n&&n.length>0&&(a=n[1],l=l.replace(n[0],""))}return e.name=r,e.default=t||"",e.description=l,e.selectable=a,e}function O(e){let s=["title","text","author","date"],r=u(e),l={};s.forEach(t=>{l[t]=r.obj[t]}),b(l),r.arr.forEach(t=>{f(t.key,t.value)})}function b(e){i.titles.push(e)}function T(e){let s=["props","name","type","default","selectable","description","descriptions"],r=u(e),l={};s.forEach(t=>{l[t]=r.obj[t]}),c(l,"props"),r.arr.forEach(t=>{f(t.key,t.value)})}function y(e){let s=["slot","name","selectable","description","descriptions"],r=u(e),l={};s.forEach(t=>{l[t]=r.obj[t]}),c(l,"slot"),r.arr.forEach(t=>{f(t.key,t.value)})}function j(e){let s=["emits","name","selectable","description","descriptions"],r=u(e),l={};s.forEach(t=>{l[t]=r.obj[t]}),c(l,"emits"),r.arr.forEach(t=>{f(t.key,t.value)})}function w(e){let s=["expose","name","type","return","selectable","description","descriptions"],r=u(e),l={};s.forEach(t=>{l[t]=r.obj[t]}),c(l,"expose"),r.arr.forEach(t=>{f(t.key,t.value)})}function c(e,s){const r=i[s+"name"]||[],l=e.name??e[s]?.name,t=r.indexOf(l);t>=0&&(i[s+"s"].splice(t,1),r.splice(t,1)),i[s+"s"].push(e),r.push(l),i[s+"name"]=r}function k(){Object.keys(i).forEach(e=>{i[e]=[]})}function u(e,s){const r={descriptions:e?.description||""},l=[];return e?.tags&&e.tags?.forEach(t=>{let a=t.tag,p=E(t);if(!r.hasOwnProperty(a))r[a]=p;else{const n={};n[a]=p,l.push({key:a,value:n})}}),{arr:l,obj:r}}function f(e,s){switch(e){case"title":return b(s),!0;case"text":return b(s),!0;case"props":return c(s,"props"),!0;case"slot":return c(s,"slot"),!0;case"emits":return c(s,"emits"),!0;case"expose":return c(s,"expose"),!0;default:return!1}}function N(e,s){switch(e){case"title":return O(s),!0;case"props":return T(s),!0;case"slot":return y(s),!0;case"emits":return j(s),!0;case"expose":return w(s),!0;default:return!1}}function P(e){return k(),e?.forEach(s=>{let r=s?.tags||[],l=r?.length||0;if(l>0)for(let t=0;t<l;t++){const a=r[t]||{};if(N(a.tag,s))break}}),i}function S(e){let s=h.getTextNotes(e);return P(s)}const q=[{label:"属性名",prop:"name",formatter:o.props.name},{label:"说明",prop:"description",formatter:o.props.description},{label:"类型",prop:"type",formatter:o.props.type},{label:"可选值",prop:"selectable",formatter:o.props.selectable},{label:"默认值",prop:"default",formatter:o.props.default}],F=[{label:"事件名",prop:"name",formatter:o.emits.name},{label:"说明",prop:"description",formatter:o.emits.description},{label:"回调参数",prop:"selectable",formatter:o.emits.selectable}],v=[{label:"方法名",prop:"name",formatter:o.expose.name},{label:"说明",prop:"description",formatter:o.expose.description},{label:"参数",prop:"selectable",formatter:o.expose.selectable},{label:"返回值",prop:"type",formatter(e){return o.expose.return(e)??o.expose.type(e)}}],z=[{label:"插槽名",prop:"name",formatter:o.slot.name},{label:"说明",prop:"description",formatter:o.slot.description},{label:"作用域参数",prop:"selectable",formatter:o.slot.selectable}];exports.getNotesText=S;exports.temits=F;exports.texpose=v;exports.tprops=q;exports.tslot=z;
|