@ditari/bsui 1.0.1 → 1.0.2
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/cjs/components/grid/Grid.cjs.js +1 -1
- package/dist/cjs/components/layout/Breadcrumb.vue.cjs.js +1 -1
- package/dist/cjs/components/layout/List.vue.cjs.js +1 -1
- package/dist/cjs/components/layout/Main.vue.cjs.js +1 -1
- package/dist/cjs/components/layout/Menu.cjs.js +1 -1
- package/dist/cjs/components/layout/NavTabs.vue.cjs.js +1 -1
- package/dist/cjs/components/layout/Show.vue.cjs.js +1 -1
- package/dist/cjs/hooks/route/index.cjs.js +1 -1
- package/dist/cjs/store/index.cjs.js +1 -0
- package/dist/cjs/store/index.d.ts +7 -7
- package/dist/cjs/store/modules/Breadcrumb.cjs.js +1 -1
- package/dist/cjs/store/modules/Breadcrumb.d.ts +1 -2
- package/dist/cjs/store/modules/DataDictionary.cjs.js +1 -1
- package/dist/cjs/store/modules/DataDictionary.d.ts +2 -2
- package/dist/cjs/store/modules/KeepAlive.cjs.js +1 -1
- package/dist/cjs/store/modules/KeepAlive.d.ts +1 -2
- package/dist/cjs/store/modules/Menu.cjs.js +1 -1
- package/dist/cjs/store/modules/Menu.d.ts +1 -2
- package/dist/cjs/store/modules/NavTab.cjs.js +1 -1
- package/dist/cjs/store/modules/NavTab.d.ts +3 -4
- package/dist/cjs/store/modules/Settings.cjs.js +1 -1
- package/dist/cjs/store/modules/Settings.d.ts +14 -95
- package/dist/cjs/store/modules/User.cjs.js +1 -1
- package/dist/cjs/store/modules/User.d.ts +1 -2
- package/dist/esm/components/grid/Grid.esm.js +1 -1
- package/dist/esm/components/layout/Breadcrumb.vue.esm.js +10 -16
- package/dist/esm/components/layout/List.vue.esm.js +21 -27
- package/dist/esm/components/layout/Main.vue.esm.js +2 -2
- package/dist/esm/components/layout/Menu.esm.js +19 -25
- package/dist/esm/components/layout/NavTabs.vue.esm.js +2 -2
- package/dist/esm/components/layout/Show.vue.esm.js +18 -23
- package/dist/esm/hooks/route/index.esm.js +26 -32
- package/dist/esm/store/index.d.ts +7 -7
- package/dist/esm/store/index.esm.js +16 -0
- package/dist/esm/store/modules/Breadcrumb.d.ts +1 -2
- package/dist/esm/store/modules/Breadcrumb.esm.js +2 -2
- package/dist/esm/store/modules/DataDictionary.d.ts +2 -2
- package/dist/esm/store/modules/DataDictionary.esm.js +5 -2
- package/dist/esm/store/modules/KeepAlive.d.ts +1 -2
- package/dist/esm/store/modules/KeepAlive.esm.js +11 -8
- package/dist/esm/store/modules/Menu.d.ts +1 -2
- package/dist/esm/store/modules/Menu.esm.js +4 -1
- package/dist/esm/store/modules/NavTab.d.ts +3 -4
- package/dist/esm/store/modules/NavTab.esm.js +4 -1
- package/dist/esm/store/modules/Settings.d.ts +14 -95
- package/dist/esm/store/modules/Settings.esm.js +7 -5
- package/dist/esm/store/modules/User.d.ts +1 -2
- package/dist/esm/store/modules/User.esm.js +4 -1
- package/package.json +4 -3
- package/src/components/layout/Breadcrumb.vue +1 -1
- package/src/components/layout/List.vue +1 -1
- package/src/components/layout/Menu.jsx +4 -2
- package/src/components/layout/NavTabs.vue +1 -1
- package/src/components/layout/Show.vue +4 -2
- package/src/hooks/route/index.ts +1 -1
- package/src/store/index.ts +7 -7
- package/src/store/modules/Breadcrumb.ts +1 -2
- package/src/store/modules/DataDictionary.ts +3 -1
- package/src/store/modules/KeepAlive.ts +1 -1
- package/src/store/modules/Menu.ts +1 -1
- package/src/store/modules/NavTab.ts +1 -1
- package/src/store/modules/Settings.ts +12 -4
- package/src/store/modules/User.ts +1 -1
|
@@ -1,26 +1,20 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import "../../store/modules/
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
import y from "../../store/modules/Menu.esm.js";
|
|
6
|
-
import "../../store/modules/NavTab.esm.js";
|
|
7
|
-
import "../../store/modules/Settings.esm.js";
|
|
8
|
-
import "../../store/modules/User.esm.js";
|
|
9
|
-
function v(r) {
|
|
10
|
-
return typeof r == "function" || Object.prototype.toString.call(r) === "[object Object]" && !b(r);
|
|
1
|
+
import { defineComponent as p, ref as c, createVNode as l, resolveComponent as o, Fragment as r, h as f, createTextVNode as b, isVNode as m } from "vue";
|
|
2
|
+
import { useMenuStore as y } from "../../store/modules/Menu.esm.js";
|
|
3
|
+
function v(u) {
|
|
4
|
+
return typeof u == "function" || Object.prototype.toString.call(u) === "[object Object]" && !m(u);
|
|
11
5
|
}
|
|
12
|
-
const
|
|
6
|
+
const h = /* @__PURE__ */ p({
|
|
13
7
|
name: "DMenu",
|
|
14
8
|
setup() {
|
|
15
9
|
const {
|
|
16
|
-
list:
|
|
17
|
-
} = y(),
|
|
10
|
+
list: u
|
|
11
|
+
} = y(), a = c(["/labelList", "/label"]), i = c(["/label"]), s = ({
|
|
18
12
|
item: n,
|
|
19
13
|
key: e,
|
|
20
14
|
keyPath: t
|
|
21
15
|
}) => {
|
|
22
|
-
console.log(n, e, t),
|
|
23
|
-
},
|
|
16
|
+
console.log(n, e, t), a.value = t, i.value = [e];
|
|
17
|
+
}, d = (n, e) => !n || !n.length ? null : l(o("a-sub-menu"), null, {
|
|
24
18
|
title: () => e.title,
|
|
25
19
|
default: () => n.map((t) => l(o("a-menu-item"), {
|
|
26
20
|
key: t.url
|
|
@@ -32,21 +26,21 @@ const N = /* @__PURE__ */ d({
|
|
|
32
26
|
let n;
|
|
33
27
|
return l(o("a-menu"), {
|
|
34
28
|
mode: "inline",
|
|
35
|
-
openKeys:
|
|
36
|
-
"onUpdate:openKeys": (e) =>
|
|
37
|
-
selectedKeys:
|
|
38
|
-
"onUpdate:selectedKeys": (e) =>
|
|
29
|
+
openKeys: a.value,
|
|
30
|
+
"onUpdate:openKeys": (e) => a.value = e,
|
|
31
|
+
selectedKeys: i.value,
|
|
32
|
+
"onUpdate:selectedKeys": (e) => i.value = e,
|
|
39
33
|
onClick: s
|
|
40
|
-
}, v(n =
|
|
34
|
+
}, v(n = u.map((e) => l(o("a-sub-menu"), {
|
|
41
35
|
key: e.url
|
|
42
36
|
}, {
|
|
43
|
-
title: () => l(
|
|
44
|
-
icon: () => l(
|
|
45
|
-
default: () => e.children && e.children.length ? e.children.map((t) => l(
|
|
37
|
+
title: () => l(r, null, [e.title]),
|
|
38
|
+
icon: () => l(r, null, [l("span", null, [e.icon ? f(o(e.icon)) : void 0])]),
|
|
39
|
+
default: () => e.children && e.children.length ? e.children.map((t) => l(r, null, [t.children ? d(t.children, e) : l(o("a-menu-item"), {
|
|
46
40
|
key: t.url
|
|
47
41
|
}, {
|
|
48
42
|
default: () => [t.title]
|
|
49
|
-
})])) : l(
|
|
43
|
+
})])) : l(r, null, [b("无子标签")])
|
|
50
44
|
}))) ? n : {
|
|
51
45
|
default: () => [n]
|
|
52
46
|
});
|
|
@@ -54,5 +48,5 @@ const N = /* @__PURE__ */ d({
|
|
|
54
48
|
}
|
|
55
49
|
});
|
|
56
50
|
export {
|
|
57
|
-
|
|
51
|
+
h as default
|
|
58
52
|
};
|
|
@@ -3,9 +3,9 @@ import { useRoute as P, useRouter as q } from "vue-router";
|
|
|
3
3
|
import { CloseOutlined as w } from "@ant-design/icons-vue";
|
|
4
4
|
import "../../store/modules/Breadcrumb.esm.js";
|
|
5
5
|
import "../../store/modules/DataDictionary.esm.js";
|
|
6
|
-
import D from "../../store/modules/KeepAlive.esm.js";
|
|
6
|
+
import { useKeepAliveStore as D } from "../../store/modules/KeepAlive.esm.js";
|
|
7
7
|
import "../../store/modules/Menu.esm.js";
|
|
8
|
-
import E from "../../store/modules/NavTab.esm.js";
|
|
8
|
+
import { useNavTabsStore as E } from "../../store/modules/NavTab.esm.js";
|
|
9
9
|
import "../../store/modules/Settings.esm.js";
|
|
10
10
|
import "../../store/modules/User.esm.js";
|
|
11
11
|
import { storeToRefs as L } from "pinia";
|
|
@@ -1,60 +1,55 @@
|
|
|
1
|
-
import { defineComponent as $, useSlots as x, watch as B, resolveComponent as c, openBlock as
|
|
1
|
+
import { defineComponent as $, useSlots as x, watch as B, resolveComponent as c, openBlock as d, createElementBlock as p, createVNode as a, withCtx as o, normalizeClass as C, unref as u, createTextVNode as N, toDisplayString as L, renderSlot as t, createElementVNode as R, createCommentVNode as V } from "vue";
|
|
2
2
|
import { useRouter as z, useRoute as D } from "vue-router";
|
|
3
3
|
import { LeftOutlined as E } from "@ant-design/icons-vue";
|
|
4
4
|
import { useWindowScroll as I, useScrollLock as O } from "@vueuse/core";
|
|
5
|
-
import "../../store/modules/
|
|
6
|
-
import "../../store/modules/
|
|
7
|
-
import "../../store/modules/KeepAlive.esm.js";
|
|
8
|
-
import "../../store/modules/Menu.esm.js";
|
|
9
|
-
import W from "../../store/modules/NavTab.esm.js";
|
|
10
|
-
import j from "../../store/modules/Settings.esm.js";
|
|
11
|
-
import "../../store/modules/User.esm.js";
|
|
5
|
+
import { useNavTabsStore as W } from "../../store/modules/NavTab.esm.js";
|
|
6
|
+
import { useSettingsStore as j } from "../../store/modules/Settings.esm.js";
|
|
12
7
|
import { storeToRefs as q } from "pinia";
|
|
13
8
|
const A = { class: "ditari-show-layout" }, F = {
|
|
14
9
|
key: 0,
|
|
15
10
|
class: "ditari-show-footer"
|
|
16
11
|
}, G = {
|
|
17
12
|
name: "DShowLayout"
|
|
18
|
-
},
|
|
13
|
+
}, Y = /* @__PURE__ */ $({
|
|
19
14
|
...G,
|
|
20
15
|
props: {
|
|
21
16
|
close: { type: Boolean, default: !1 },
|
|
22
17
|
loading: { type: Boolean, default: !1 }
|
|
23
18
|
},
|
|
24
|
-
setup(
|
|
25
|
-
const
|
|
26
|
-
padding: `10px 10px ${
|
|
19
|
+
setup(n, { expose: f }) {
|
|
20
|
+
const r = n, s = z(), l = D(), m = x(), i = W(), h = j(), { refresh: g } = q(h), _ = {
|
|
21
|
+
padding: `10px 10px ${m.footer ? "70px" : "10px"} 10px`
|
|
27
22
|
}, y = () => {
|
|
28
|
-
|
|
23
|
+
r.close && i.deleteTabs(l.path), s.go(-1);
|
|
29
24
|
}, S = () => {
|
|
30
25
|
g.value = !0, i.deleteTabs(l.path), s.go(-1);
|
|
31
26
|
}, { y: v } = I(), T = O(document.body);
|
|
32
27
|
B(
|
|
33
|
-
() =>
|
|
28
|
+
() => r.loading,
|
|
34
29
|
(e) => {
|
|
35
30
|
T.value = e;
|
|
36
31
|
}
|
|
37
32
|
);
|
|
38
33
|
const b = 200;
|
|
39
|
-
return
|
|
34
|
+
return f({
|
|
40
35
|
refresh: S
|
|
41
36
|
}), (e, H) => {
|
|
42
37
|
const k = c("a-page-header"), w = c("a-spin");
|
|
43
|
-
return
|
|
44
|
-
|
|
38
|
+
return d(), p("div", A, [
|
|
39
|
+
a(w, {
|
|
45
40
|
tip: "正在处理...",
|
|
46
|
-
spinning:
|
|
41
|
+
spinning: n.loading,
|
|
47
42
|
delay: b,
|
|
48
43
|
size: "large"
|
|
49
44
|
}, {
|
|
50
45
|
default: o(() => [
|
|
51
|
-
|
|
52
|
-
class: C(["ditari-page-header", { active:
|
|
46
|
+
a(k, {
|
|
47
|
+
class: C(["ditari-page-header", { active: u(v) > 0 }]),
|
|
53
48
|
ghost: !1,
|
|
54
49
|
onBack: y
|
|
55
50
|
}, {
|
|
56
51
|
backIcon: o(() => [
|
|
57
|
-
|
|
52
|
+
a(u(E))
|
|
58
53
|
]),
|
|
59
54
|
title: o(() => [
|
|
60
55
|
N(L(e.$route.meta.title), 1)
|
|
@@ -73,7 +68,7 @@ const A = { class: "ditari-show-layout" }, F = {
|
|
|
73
68
|
}, [
|
|
74
69
|
t(e.$slots, "default")
|
|
75
70
|
]),
|
|
76
|
-
e.$slots.footer ? (
|
|
71
|
+
e.$slots.footer ? (d(), p("div", F, [
|
|
77
72
|
t(e.$slots, "footer")
|
|
78
73
|
])) : V("", !0)
|
|
79
74
|
]),
|
|
@@ -84,5 +79,5 @@ const A = { class: "ditari-show-layout" }, F = {
|
|
|
84
79
|
}
|
|
85
80
|
});
|
|
86
81
|
export {
|
|
87
|
-
|
|
82
|
+
Y as default
|
|
88
83
|
};
|
|
@@ -1,48 +1,42 @@
|
|
|
1
|
-
import { ref as
|
|
1
|
+
import { ref as f } from "vue";
|
|
2
2
|
import { createRouterMatcher as u } from "vue-router";
|
|
3
|
-
import v from "../../store/modules/Breadcrumb.esm.js";
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
const k = (r) => {
|
|
11
|
-
const { saveBreadcrumb: o } = v(), e = n(null), t = n([]);
|
|
12
|
-
return e.value = u(r, {}), {
|
|
13
|
-
flatRoutes: l(r, null),
|
|
14
|
-
setMatched: (p, f) => {
|
|
15
|
-
var i;
|
|
3
|
+
import { useBreadcrumbStore as v } from "../../store/modules/Breadcrumb.esm.js";
|
|
4
|
+
const y = (a) => {
|
|
5
|
+
const { saveBreadcrumb: s } = v(), e = f(null), t = f([]);
|
|
6
|
+
return e.value = u(a, {}), {
|
|
7
|
+
flatRoutes: i(a, null),
|
|
8
|
+
setMatched: (m, d) => {
|
|
9
|
+
var n;
|
|
16
10
|
try {
|
|
17
|
-
const
|
|
18
|
-
t.value =
|
|
19
|
-
var
|
|
20
|
-
return
|
|
21
|
-
(
|
|
22
|
-
) ||
|
|
23
|
-
path:
|
|
24
|
-
title: ((
|
|
25
|
-
}),
|
|
11
|
+
const c = ((n = e.value) == null ? void 0 : n.resolve(m, d).matched) ?? [];
|
|
12
|
+
t.value = c.reduce((h, o) => {
|
|
13
|
+
var l;
|
|
14
|
+
return h.some(
|
|
15
|
+
(p) => p.path === o.path
|
|
16
|
+
) || h.push({
|
|
17
|
+
path: o.path,
|
|
18
|
+
title: ((l = o.meta) == null ? void 0 : l.title) ?? "未设置标题"
|
|
19
|
+
}), h;
|
|
26
20
|
}, []);
|
|
27
|
-
} catch (
|
|
28
|
-
console.log(
|
|
21
|
+
} catch (c) {
|
|
22
|
+
console.log(c), t.value = [];
|
|
29
23
|
}
|
|
30
|
-
|
|
24
|
+
s(t.value);
|
|
31
25
|
}
|
|
32
26
|
};
|
|
33
27
|
};
|
|
34
|
-
function
|
|
35
|
-
return
|
|
36
|
-
if (t.children && e.push(...
|
|
37
|
-
const
|
|
28
|
+
function i(a, s) {
|
|
29
|
+
return a.reduce((e, t) => {
|
|
30
|
+
if (t.children && e.push(...i(t.children, t)), t.component) {
|
|
31
|
+
const r = `${s == null ? void 0 : s.path}` + (t.path ? "/" + t.path : "");
|
|
38
32
|
e.push({
|
|
39
33
|
...t,
|
|
40
|
-
path:
|
|
34
|
+
path: r
|
|
41
35
|
});
|
|
42
36
|
}
|
|
43
37
|
return e;
|
|
44
38
|
}, []);
|
|
45
39
|
}
|
|
46
40
|
export {
|
|
47
|
-
|
|
41
|
+
y as useDitariRoute
|
|
48
42
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export {
|
|
2
|
-
export {
|
|
3
|
-
export {
|
|
4
|
-
export {
|
|
5
|
-
export {
|
|
6
|
-
export {
|
|
7
|
-
export {
|
|
1
|
+
export { useBreadcrumbStore } from "./modules/Breadcrumb";
|
|
2
|
+
export { useDataDicStore } from "./modules/DataDictionary";
|
|
3
|
+
export { useKeepAliveStore } from "./modules/KeepAlive";
|
|
4
|
+
export { useMenuStore } from "./modules/Menu";
|
|
5
|
+
export { useNavTabsStore } from "./modules/NavTab";
|
|
6
|
+
export { useSettingsStore } from "./modules/Settings";
|
|
7
|
+
export { useUserStore } from "./modules/User";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { useBreadcrumbStore as o } from "./modules/Breadcrumb.esm.js";
|
|
2
|
+
import { useDataDicStore as s } from "./modules/DataDictionary.esm.js";
|
|
3
|
+
import { useKeepAliveStore as m } from "./modules/KeepAlive.esm.js";
|
|
4
|
+
import { useMenuStore as S } from "./modules/Menu.esm.js";
|
|
5
|
+
import { useNavTabsStore as x } from "./modules/NavTab.esm.js";
|
|
6
|
+
import { useSettingsStore as i } from "./modules/Settings.esm.js";
|
|
7
|
+
import { useUserStore as c } from "./modules/User.esm.js";
|
|
8
|
+
export {
|
|
9
|
+
o as useBreadcrumbStore,
|
|
10
|
+
s as useDataDicStore,
|
|
11
|
+
m as useKeepAliveStore,
|
|
12
|
+
S as useMenuStore,
|
|
13
|
+
x as useNavTabsStore,
|
|
14
|
+
i as useSettingsStore,
|
|
15
|
+
c as useUserStore
|
|
16
|
+
};
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
export interface State {
|
|
2
2
|
breadcrumbs: [];
|
|
3
3
|
}
|
|
4
|
-
declare const
|
|
4
|
+
export declare const useBreadcrumbStore: import("pinia").StoreDefinition<string, State, {
|
|
5
5
|
getBreadcrumb: (state: {
|
|
6
6
|
breadcrumbs: [];
|
|
7
7
|
} & import("pinia").PiniaCustomStateProperties<State>) => [];
|
|
8
8
|
}, {
|
|
9
9
|
saveBreadcrumb(data: any): void;
|
|
10
10
|
}>;
|
|
11
|
-
export default _default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineStore as e } from "pinia";
|
|
2
2
|
import { BREADCRUMB_ID as t } from "../types.esm.js";
|
|
3
|
-
const
|
|
3
|
+
const a = e(t, {
|
|
4
4
|
state: () => ({
|
|
5
5
|
breadcrumbs: []
|
|
6
6
|
}),
|
|
@@ -15,5 +15,5 @@ const m = e(t, {
|
|
|
15
15
|
persist: !0
|
|
16
16
|
});
|
|
17
17
|
export {
|
|
18
|
-
|
|
18
|
+
a as useBreadcrumbStore
|
|
19
19
|
};
|
|
@@ -2,7 +2,7 @@ interface State {
|
|
|
2
2
|
someState: string;
|
|
3
3
|
list: any;
|
|
4
4
|
}
|
|
5
|
-
declare const
|
|
5
|
+
declare const useDataDicStore: import("pinia").StoreDefinition<string, State, {
|
|
6
6
|
/**
|
|
7
7
|
* 根据key获取字典列表
|
|
8
8
|
* @param state
|
|
@@ -26,4 +26,4 @@ declare const _default: import("pinia").StoreDefinition<string, State, {
|
|
|
26
26
|
*/
|
|
27
27
|
save(data: any): void;
|
|
28
28
|
}>;
|
|
29
|
-
export
|
|
29
|
+
export { useDataDicStore };
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineStore as s } from "pinia";
|
|
2
|
-
import { DATA_DICTIONARY_ID as
|
|
3
|
-
s(
|
|
2
|
+
import { DATA_DICTIONARY_ID as o } from "../types.esm.js";
|
|
3
|
+
const u = s(o, {
|
|
4
4
|
state: () => ({
|
|
5
5
|
someState: "你好 pinia",
|
|
6
6
|
list: {}
|
|
@@ -28,3 +28,6 @@ s(a, {
|
|
|
28
28
|
},
|
|
29
29
|
persist: !0
|
|
30
30
|
});
|
|
31
|
+
export {
|
|
32
|
+
u as useDataDicStore
|
|
33
|
+
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { RouteLocationNormalized } from "vue-router";
|
|
2
|
-
declare const
|
|
2
|
+
export declare const useKeepAliveStore: import("pinia").StoreDefinition<string, {
|
|
3
3
|
list: string[];
|
|
4
4
|
}, {
|
|
5
5
|
get: (state: {
|
|
@@ -19,4 +19,3 @@ declare const _default: import("pinia").StoreDefinition<string, {
|
|
|
19
19
|
*/
|
|
20
20
|
save(route: RouteLocationNormalized): void;
|
|
21
21
|
}>;
|
|
22
|
-
export default _default;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { defineStore as i } from "pinia";
|
|
2
2
|
import { KEEP_ALIVE_ID as r } from "../types.esm.js";
|
|
3
|
-
i(r, {
|
|
3
|
+
const f = i(r, {
|
|
4
4
|
state: () => ({
|
|
5
5
|
list: []
|
|
6
6
|
}),
|
|
7
7
|
getters: {
|
|
8
|
-
get: (
|
|
8
|
+
get: (e) => e.list
|
|
9
9
|
},
|
|
10
10
|
actions: {
|
|
11
11
|
/**
|
|
12
12
|
* 删除已经缓存的组件
|
|
13
13
|
* @param name 组件名称(必须唯一)
|
|
14
14
|
*/
|
|
15
|
-
deleteKeepAlive(
|
|
15
|
+
deleteKeepAlive(e) {
|
|
16
16
|
this.list.splice(
|
|
17
|
-
this.list.findIndex((
|
|
17
|
+
this.list.findIndex((t) => t === e),
|
|
18
18
|
1
|
|
19
19
|
);
|
|
20
20
|
},
|
|
@@ -22,12 +22,15 @@ i(r, {
|
|
|
22
22
|
* 保存要缓存的组件名称
|
|
23
23
|
* @param route
|
|
24
24
|
*/
|
|
25
|
-
save(
|
|
26
|
-
const
|
|
27
|
-
if (!
|
|
25
|
+
save(e) {
|
|
26
|
+
const t = e.name;
|
|
27
|
+
if (!t)
|
|
28
28
|
return;
|
|
29
|
-
this.list.some((s) => s ===
|
|
29
|
+
this.list.some((s) => s === t) || this.list.push(t);
|
|
30
30
|
}
|
|
31
31
|
},
|
|
32
32
|
persist: !0
|
|
33
33
|
});
|
|
34
|
+
export {
|
|
35
|
+
f as useKeepAliveStore
|
|
36
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const
|
|
1
|
+
export declare const useMenuStore: import("pinia").StoreDefinition<string, {
|
|
2
2
|
list: never[];
|
|
3
3
|
}, {
|
|
4
4
|
getMenu: (state: {
|
|
@@ -9,4 +9,3 @@ declare const _default: import("pinia").StoreDefinition<string, {
|
|
|
9
9
|
}, {
|
|
10
10
|
save(data: any): void;
|
|
11
11
|
}>;
|
|
12
|
-
export default _default;
|
|
@@ -7,7 +7,7 @@ export interface INavTab {
|
|
|
7
7
|
meta: RouteMeta | any;
|
|
8
8
|
name: string;
|
|
9
9
|
}
|
|
10
|
-
declare const
|
|
10
|
+
export declare const useNavTabsStore: import("pinia").StoreDefinition<string, {
|
|
11
11
|
list: INavTab[];
|
|
12
12
|
activeKey: string;
|
|
13
13
|
}, {
|
|
@@ -17,7 +17,7 @@ declare const _default: import("pinia").StoreDefinition<string, {
|
|
|
17
17
|
fullPath: string;
|
|
18
18
|
query: LocationQuery;
|
|
19
19
|
params: RouteParams;
|
|
20
|
-
meta: any;
|
|
20
|
+
meta: RouteMeta | any;
|
|
21
21
|
name: string;
|
|
22
22
|
}[];
|
|
23
23
|
activeKey: string;
|
|
@@ -31,7 +31,7 @@ declare const _default: import("pinia").StoreDefinition<string, {
|
|
|
31
31
|
fullPath: string;
|
|
32
32
|
query: LocationQuery;
|
|
33
33
|
params: RouteParams;
|
|
34
|
-
meta: any;
|
|
34
|
+
meta: RouteMeta | any;
|
|
35
35
|
name: string;
|
|
36
36
|
}[];
|
|
37
37
|
activeKey: string;
|
|
@@ -56,4 +56,3 @@ declare const _default: import("pinia").StoreDefinition<string, {
|
|
|
56
56
|
*/
|
|
57
57
|
deleteTabs(key: string): void;
|
|
58
58
|
}>;
|
|
59
|
-
export default _default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineStore as i } from "pinia";
|
|
2
2
|
import { NAV_TAB_ID as l } from "../types.esm.js";
|
|
3
|
-
i(l, {
|
|
3
|
+
const n = i(l, {
|
|
4
4
|
state: () => ({
|
|
5
5
|
// 多标签列表
|
|
6
6
|
list: [],
|
|
@@ -51,3 +51,6 @@ i(l, {
|
|
|
51
51
|
},
|
|
52
52
|
persist: !0
|
|
53
53
|
});
|
|
54
|
+
export {
|
|
55
|
+
n as useNavTabsStore
|
|
56
|
+
};
|
|
@@ -1,112 +1,32 @@
|
|
|
1
|
-
|
|
1
|
+
export interface State {
|
|
2
2
|
refresh: boolean;
|
|
3
3
|
collapsed: boolean;
|
|
4
|
-
mediaRuleMap:
|
|
5
|
-
|
|
6
|
-
value: string;
|
|
7
|
-
description: string;
|
|
8
|
-
}[];
|
|
9
|
-
gridConfig: {
|
|
10
|
-
key: string;
|
|
11
|
-
value: string;
|
|
12
|
-
col: number;
|
|
13
|
-
description: string;
|
|
14
|
-
}[];
|
|
4
|
+
mediaRuleMap: any;
|
|
5
|
+
gridConfig: any;
|
|
15
6
|
gridValue: any;
|
|
16
|
-
}
|
|
7
|
+
}
|
|
8
|
+
export declare const useSettingsStore: import("pinia").StoreDefinition<string, State, {
|
|
17
9
|
getRefresh: (state: {
|
|
18
10
|
refresh: boolean;
|
|
19
11
|
collapsed: boolean;
|
|
20
|
-
mediaRuleMap:
|
|
21
|
-
|
|
22
|
-
value: string;
|
|
23
|
-
description: string;
|
|
24
|
-
}[];
|
|
25
|
-
gridConfig: {
|
|
26
|
-
key: string;
|
|
27
|
-
value: string;
|
|
28
|
-
col: number;
|
|
29
|
-
description: string;
|
|
30
|
-
}[];
|
|
12
|
+
mediaRuleMap: any;
|
|
13
|
+
gridConfig: any;
|
|
31
14
|
gridValue: any;
|
|
32
|
-
} & import("pinia").PiniaCustomStateProperties<
|
|
33
|
-
refresh: boolean;
|
|
34
|
-
collapsed: boolean;
|
|
35
|
-
mediaRuleMap: {
|
|
36
|
-
key: string;
|
|
37
|
-
value: string;
|
|
38
|
-
description: string;
|
|
39
|
-
}[];
|
|
40
|
-
gridConfig: {
|
|
41
|
-
key: string;
|
|
42
|
-
value: string;
|
|
43
|
-
col: number;
|
|
44
|
-
description: string;
|
|
45
|
-
}[];
|
|
46
|
-
gridValue: any;
|
|
47
|
-
}>) => boolean;
|
|
15
|
+
} & import("pinia").PiniaCustomStateProperties<State>) => boolean;
|
|
48
16
|
getCollapsed: (state: {
|
|
49
17
|
refresh: boolean;
|
|
50
18
|
collapsed: boolean;
|
|
51
|
-
mediaRuleMap:
|
|
52
|
-
|
|
53
|
-
value: string;
|
|
54
|
-
description: string;
|
|
55
|
-
}[];
|
|
56
|
-
gridConfig: {
|
|
57
|
-
key: string;
|
|
58
|
-
value: string;
|
|
59
|
-
col: number;
|
|
60
|
-
description: string;
|
|
61
|
-
}[];
|
|
62
|
-
gridValue: any;
|
|
63
|
-
} & import("pinia").PiniaCustomStateProperties<{
|
|
64
|
-
refresh: boolean;
|
|
65
|
-
collapsed: boolean;
|
|
66
|
-
mediaRuleMap: {
|
|
67
|
-
key: string;
|
|
68
|
-
value: string;
|
|
69
|
-
description: string;
|
|
70
|
-
}[];
|
|
71
|
-
gridConfig: {
|
|
72
|
-
key: string;
|
|
73
|
-
value: string;
|
|
74
|
-
col: number;
|
|
75
|
-
description: string;
|
|
76
|
-
}[];
|
|
19
|
+
mediaRuleMap: any;
|
|
20
|
+
gridConfig: any;
|
|
77
21
|
gridValue: any;
|
|
78
|
-
}>) => boolean;
|
|
22
|
+
} & import("pinia").PiniaCustomStateProperties<State>) => boolean;
|
|
79
23
|
getGrid: (state: {
|
|
80
24
|
refresh: boolean;
|
|
81
25
|
collapsed: boolean;
|
|
82
|
-
mediaRuleMap:
|
|
83
|
-
|
|
84
|
-
value: string;
|
|
85
|
-
description: string;
|
|
86
|
-
}[];
|
|
87
|
-
gridConfig: {
|
|
88
|
-
key: string;
|
|
89
|
-
value: string;
|
|
90
|
-
col: number;
|
|
91
|
-
description: string;
|
|
92
|
-
}[];
|
|
93
|
-
gridValue: any;
|
|
94
|
-
} & import("pinia").PiniaCustomStateProperties<{
|
|
95
|
-
refresh: boolean;
|
|
96
|
-
collapsed: boolean;
|
|
97
|
-
mediaRuleMap: {
|
|
98
|
-
key: string;
|
|
99
|
-
value: string;
|
|
100
|
-
description: string;
|
|
101
|
-
}[];
|
|
102
|
-
gridConfig: {
|
|
103
|
-
key: string;
|
|
104
|
-
value: string;
|
|
105
|
-
col: number;
|
|
106
|
-
description: string;
|
|
107
|
-
}[];
|
|
26
|
+
mediaRuleMap: any;
|
|
27
|
+
gridConfig: any;
|
|
108
28
|
gridValue: any;
|
|
109
|
-
}>) => any;
|
|
29
|
+
} & import("pinia").PiniaCustomStateProperties<State>) => any;
|
|
110
30
|
}, {
|
|
111
31
|
/**
|
|
112
32
|
* 切换刷新
|
|
@@ -121,4 +41,3 @@ declare const _default: import("pinia").StoreDefinition<string, {
|
|
|
121
41
|
*/
|
|
122
42
|
gridMatching(): void;
|
|
123
43
|
}>;
|
|
124
|
-
export default _default;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineStore as r } from "pinia";
|
|
2
|
-
import { useMediaQuery as
|
|
3
|
-
import { SETTINGS_ID as
|
|
2
|
+
import { useMediaQuery as s } from "@vueuse/core";
|
|
3
|
+
import { SETTINGS_ID as a } from "../types.esm.js";
|
|
4
4
|
const d = [
|
|
5
5
|
{
|
|
6
6
|
key: "700",
|
|
@@ -58,8 +58,7 @@ const d = [
|
|
|
58
58
|
col: 5,
|
|
59
59
|
description: " 显示5列每列占20%宽"
|
|
60
60
|
}
|
|
61
|
-
]
|
|
62
|
-
r(s, {
|
|
61
|
+
], c = r(a, {
|
|
63
62
|
state: () => ({
|
|
64
63
|
// 刷新状态
|
|
65
64
|
refresh: !1,
|
|
@@ -94,7 +93,7 @@ r(s, {
|
|
|
94
93
|
*/
|
|
95
94
|
gridMatching() {
|
|
96
95
|
const e = this.mediaRuleMap.filter(
|
|
97
|
-
(i) =>
|
|
96
|
+
(i) => s(i.value).value
|
|
98
97
|
)[0], t = this.gridConfig.filter(
|
|
99
98
|
(i) => i.key === e.key
|
|
100
99
|
)[0];
|
|
@@ -103,3 +102,6 @@ r(s, {
|
|
|
103
102
|
},
|
|
104
103
|
persist: !0
|
|
105
104
|
});
|
|
105
|
+
export {
|
|
106
|
+
c as useSettingsStore
|
|
107
|
+
};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
declare const
|
|
1
|
+
export declare const useUserStore: import("pinia").StoreDefinition<string, {
|
|
2
2
|
token: undefined;
|
|
3
3
|
}, {
|
|
4
4
|
getToken: (state: {
|
|
@@ -13,4 +13,3 @@ declare const _default: import("pinia").StoreDefinition<string, {
|
|
|
13
13
|
*/
|
|
14
14
|
saveToken(token: any): void;
|
|
15
15
|
}>;
|
|
16
|
-
export default _default;
|