@duxweb/dvha-pro 1.0.18 → 1.0.20
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/component.cjs +1 -1
- package/dist/cjs/components/card/card.cjs +1 -1
- package/dist/cjs/components/chart/echart.cjs +1 -1
- package/dist/cjs/components/code/code.cjs +1 -0
- package/dist/cjs/components/crop/imageCrop.cjs +1 -1
- package/dist/cjs/components/data/dynamicSelect.cjs +1 -1
- package/dist/cjs/components/data/selectModal.cjs +1 -1
- package/dist/cjs/components/drawer/drawer.cjs +1 -1
- package/dist/cjs/components/drawer/drawerPage.cjs +1 -1
- package/dist/cjs/components/form/formItem.cjs +1 -1
- package/dist/cjs/components/form/formLayout.cjs +1 -1
- package/dist/cjs/components/form/modalForm.cjs +1 -1
- package/dist/cjs/components/form/pageForm.cjs +1 -1
- package/dist/cjs/components/form/settingForm.cjs +1 -1
- package/dist/cjs/components/icon/icon.cjs +1 -1
- package/dist/cjs/components/layout/filter.cjs +1 -1
- package/dist/cjs/components/layout/filterLayout.cjs +1 -0
- package/dist/cjs/components/layout/list.cjs +1 -1
- package/dist/cjs/components/layout/table.cjs +1 -1
- package/dist/cjs/components/level/level.cjs +1 -1
- package/dist/cjs/components/modal/modal.cjs +1 -1
- package/dist/cjs/components/modal/modalPage.cjs +1 -1
- package/dist/cjs/components/panel/collapse.cjs +1 -0
- package/dist/cjs/components/panel/setting.cjs +1 -1
- package/dist/cjs/components/status/listEmpty.cjs +1 -0
- package/dist/cjs/components/table/table.cjs +1 -0
- package/dist/cjs/components/table/tablePage.cjs +1 -1
- package/dist/cjs/components/tree/treeFilter.cjs +1 -1
- package/dist/cjs/components/upload/config.cjs +1 -0
- package/dist/cjs/components/upload/file.cjs +1 -1
- package/dist/cjs/components/upload/image.cjs +1 -1
- package/dist/cjs/components/upload/manage/item.cjs +1 -1
- package/dist/cjs/components/upload/manager.cjs +1 -1
- package/dist/cjs/dvha-pro.css +1 -1
- package/dist/cjs/hooks/action.cjs +1 -1
- package/dist/cjs/hooks/dialog.cjs +1 -1
- package/dist/cjs/hooks/drawer.cjs +1 -1
- package/dist/cjs/hooks/modal.cjs +1 -1
- package/dist/cjs/hooks/table/image.cjs +1 -1
- package/dist/cjs/hooks/table/media.cjs +1 -1
- package/dist/cjs/hooks/table.cjs +1 -1
- package/dist/cjs/index.cjs +1 -1
- package/dist/cjs/langs/en-US.json.cjs +1 -1
- package/dist/cjs/langs/zh-CN.json.cjs +1 -1
- package/dist/cjs/pages/authLayout.cjs +1 -1
- package/dist/cjs/pages/layout/page.cjs +1 -1
- package/dist/cjs/pages/login.cjs +1 -1
- package/dist/cjs/pages/menu/avatar.cjs +1 -1
- package/dist/cjs/pages/menu/button.cjs +1 -1
- package/dist/cjs/pages/menu/cmd.cjs +1 -1
- package/dist/cjs/pages/menu/main.cjs +1 -1
- package/dist/cjs/pages/menu/mobile.cjs +1 -1
- package/dist/cjs/pages/page.cjs +1 -1
- package/dist/cjs/pages/page404.cjs +1 -1
- package/dist/cjs/pages/pageStatus.cjs +1 -1
- package/dist/cjs/theme/naiveTheme.cjs +1 -1
- package/dist/cjs/theme/uno.css.cjs +23 -7
- package/dist/esm/component.js +36 -34
- package/dist/esm/components/card/card.js +6 -6
- package/dist/esm/components/chart/echart.js +17 -6
- package/dist/esm/components/code/code.js +53 -0
- package/dist/esm/components/crop/imageCrop.js +37 -26
- package/dist/esm/components/data/dynamicSelect.js +29 -18
- package/dist/esm/components/data/selectModal.js +49 -38
- package/dist/esm/components/drawer/drawer.js +17 -28
- package/dist/esm/components/drawer/drawerPage.js +54 -17
- package/dist/esm/components/form/formItem.js +17 -17
- package/dist/esm/components/form/formLayout.js +8 -8
- package/dist/esm/components/form/modalForm.js +44 -35
- package/dist/esm/components/form/pageForm.js +81 -43
- package/dist/esm/components/form/settingForm.js +28 -17
- package/dist/esm/components/icon/icon.js +23 -12
- package/dist/esm/components/layout/filter.js +15 -11
- package/dist/esm/components/layout/filterLayout.js +34 -0
- package/dist/esm/components/layout/list.js +211 -161
- package/dist/esm/components/layout/table.js +217 -186
- package/dist/esm/components/level/level.js +28 -17
- package/dist/esm/components/modal/modal.js +9 -9
- package/dist/esm/components/modal/modalPage.js +2 -2
- package/dist/esm/components/panel/collapse.js +49 -0
- package/dist/esm/components/panel/setting.js +3 -3
- package/dist/esm/components/status/listEmpty.js +26 -0
- package/dist/esm/components/table/table.js +110 -0
- package/dist/esm/components/table/tablePage.js +24 -18
- package/dist/esm/components/tree/treeFilter.js +44 -39
- package/dist/esm/components/upload/config.js +32 -0
- package/dist/esm/components/upload/file.js +142 -116
- package/dist/esm/components/upload/image.js +95 -66
- package/dist/esm/components/upload/manage/item.js +17 -6
- package/dist/esm/components/upload/manager.js +202 -164
- package/dist/esm/dvha-pro.css +1 -1
- package/dist/esm/hooks/action.js +77 -75
- package/dist/esm/hooks/dialog.js +13 -2
- package/dist/esm/hooks/drawer.js +13 -2
- package/dist/esm/hooks/modal.js +13 -2
- package/dist/esm/hooks/table/image.js +21 -10
- package/dist/esm/hooks/table/media.js +20 -9
- package/dist/esm/hooks/table.js +16 -16
- package/dist/esm/index.js +174 -164
- package/dist/esm/langs/en-US.json.js +5 -3
- package/dist/esm/langs/zh-CN.json.js +5 -3
- package/dist/esm/pages/authLayout.js +19 -8
- package/dist/esm/pages/layout/page.js +17 -6
- package/dist/esm/pages/login.js +40 -29
- package/dist/esm/pages/menu/avatar.js +97 -86
- package/dist/esm/pages/menu/button.js +23 -12
- package/dist/esm/pages/menu/cmd.js +45 -34
- package/dist/esm/pages/menu/main.js +40 -27
- package/dist/esm/pages/menu/mobile.js +13 -2
- package/dist/esm/pages/page.js +1 -1
- package/dist/esm/pages/page404.js +20 -9
- package/dist/esm/pages/pageStatus.js +31 -15
- package/dist/esm/theme/naiveTheme.js +6 -6
- package/dist/esm/theme/uno.css.js +23 -7
- package/dist/types/components/code/code.d.ts +44 -0
- package/dist/types/components/code/index.d.ts +1 -0
- package/dist/types/components/drawer/drawer.d.ts +2 -0
- package/dist/types/components/drawer/drawerPage.d.ts +20 -1
- package/dist/types/components/form/formItem.d.ts +2 -2
- package/dist/types/components/form/formLayout.d.ts +3 -3
- package/dist/types/components/form/modalForm.d.ts +3 -3
- package/dist/types/components/form/pageForm.d.ts +12 -0
- package/dist/types/components/index.d.ts +1 -0
- package/dist/types/components/layout/filterLayout.d.ts +32 -0
- package/dist/types/components/layout/index.d.ts +1 -0
- package/dist/types/components/layout/list.d.ts +7 -1
- package/dist/types/components/layout/table.d.ts +10 -1
- package/dist/types/components/list/card.d.ts +6 -0
- package/dist/types/components/list/list.d.ts +6 -0
- package/dist/types/components/panel/collapse.d.ts +14 -0
- package/dist/types/components/panel/index.d.ts +1 -0
- package/dist/types/components/select/cardSelect.d.ts +1 -1
- package/dist/types/components/status/index.d.ts +1 -0
- package/dist/types/components/status/listEmpty.d.ts +11 -0
- package/dist/types/components/table/index.d.ts +1 -0
- package/dist/types/components/table/table.d.ts +6552 -0
- package/dist/types/components/table/tablePage.d.ts +9 -0
- package/dist/types/components/tree/treeFilter.d.ts +13 -12
- package/dist/types/components/upload/config.d.ts +13 -0
- package/dist/types/components/upload/file.d.ts +4 -0
- package/dist/types/components/upload/image.d.ts +30 -2
- package/dist/types/components/upload/manager.d.ts +4 -0
- package/dist/types/hooks/drawer.d.ts +1 -0
- package/dist/types/hooks/table/types.d.ts +1 -0
- package/dist/types/main.d.ts +6 -0
- package/dist/types/pages/pageStatus.d.ts +11 -1
- package/package.json +7 -5
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as M, ref as d, watch as
|
|
1
|
+
import { defineComponent as M, ref as d, watch as u, computed as w, createVNode as t, Fragment as V, createTextVNode as B } from "vue";
|
|
2
2
|
import { useRouteStore as D, useTheme as T, useI18n as K } from "@duxweb/dvha-core";
|
|
3
3
|
import { useMagicKeys as R, watchThrottled as j } from "@vueuse/core";
|
|
4
4
|
import { cloneDeep as E } from "lodash-es";
|
|
5
5
|
import { NTag as y, NButton as G } from "naive-ui";
|
|
6
|
-
import { Command as
|
|
6
|
+
import { Command as i } from "vue-command-palette";
|
|
7
7
|
import { useRouter as L } from "vue-router";
|
|
8
8
|
import "@overlastic/vue";
|
|
9
9
|
import "clsx";
|
|
@@ -26,36 +26,47 @@ import "@duxweb/dvha-naiveui";
|
|
|
26
26
|
import "../page404.js";
|
|
27
27
|
import "@iconify-json/tabler/icons.json";
|
|
28
28
|
import "mime";
|
|
29
|
+
import "vue3-ace-editor";
|
|
30
|
+
import "ace-builds/src-noconflict/mode-vue";
|
|
31
|
+
import "ace-builds/src-noconflict/mode-javascript";
|
|
32
|
+
import "ace-builds/src-noconflict/mode-html";
|
|
33
|
+
import "ace-builds/src-noconflict/mode-json";
|
|
34
|
+
import "ace-builds/src-noconflict/mode-json5";
|
|
35
|
+
import "ace-builds/src-noconflict/theme-tomorrow_night";
|
|
36
|
+
import "ace-builds/src-noconflict/theme-tomorrow";
|
|
37
|
+
import "ace-builds/src-noconflict/ext-searchbox";
|
|
38
|
+
import "ace-builds/src-noconflict/ext-language_tools";
|
|
39
|
+
import "ace-builds/src-noconflict/mode-snippets";
|
|
29
40
|
import "dayjs";
|
|
30
41
|
import "@tanstack/vue-query";
|
|
31
42
|
import { useUI as q } from "../../hooks/ui.js";
|
|
32
|
-
const
|
|
43
|
+
const we = /* @__PURE__ */ M({
|
|
33
44
|
name: "DuxMenuCmd",
|
|
34
45
|
setup() {
|
|
35
46
|
const {
|
|
36
|
-
cmdVisible:
|
|
47
|
+
cmdVisible: v,
|
|
37
48
|
setCmdVisible: s
|
|
38
|
-
} = q(), f = R(), S = f["Meta+K"], c = d(),
|
|
39
|
-
setMode:
|
|
40
|
-
} = T(),
|
|
49
|
+
} = q(), f = R(), S = f["Meta+K"], c = d(), n = d([]), C = L(), o = D(), {
|
|
50
|
+
setMode: b
|
|
51
|
+
} = T(), m = d(""), {
|
|
41
52
|
t: a
|
|
42
53
|
} = K(), g = d(), x = (e) => {
|
|
43
54
|
const l = o.routes.filter((r) => r.parent === e);
|
|
44
|
-
c.value = e,
|
|
55
|
+
c.value = e, n.value = l;
|
|
45
56
|
}, N = () => {
|
|
46
57
|
s(!0);
|
|
47
58
|
}, z = () => {
|
|
48
59
|
s(!1);
|
|
49
60
|
}, I = (e) => {
|
|
50
|
-
e ?
|
|
61
|
+
e ? n.value = [...E(o.routes).filter((l) => {
|
|
51
62
|
var r;
|
|
52
63
|
return (r = l.label) == null ? void 0 : r.includes(e);
|
|
53
|
-
})] :
|
|
64
|
+
})] : n.value = o.routes.filter((l) => !l.parent);
|
|
54
65
|
};
|
|
55
|
-
|
|
56
|
-
e ?
|
|
57
|
-
}), j(
|
|
58
|
-
I(
|
|
66
|
+
u(v, (e) => {
|
|
67
|
+
e ? n.value = o.routes.filter((l) => !l.parent) : n.value = o.routes.filter((l) => !l.parent);
|
|
68
|
+
}), j(m, () => {
|
|
69
|
+
I(m.value);
|
|
59
70
|
}, {
|
|
60
71
|
throttle: 500
|
|
61
72
|
});
|
|
@@ -63,16 +74,16 @@ const pe = /* @__PURE__ */ M({
|
|
|
63
74
|
const e = o.routes.find((l) => l.name === c.value);
|
|
64
75
|
x(e == null ? void 0 : e.parent);
|
|
65
76
|
};
|
|
66
|
-
|
|
77
|
+
u(S, (e) => {
|
|
67
78
|
e && N();
|
|
68
|
-
}),
|
|
79
|
+
}), u(f.Escape, (e) => {
|
|
69
80
|
e && s(!1);
|
|
70
|
-
}),
|
|
71
|
-
e &&
|
|
72
|
-
}),
|
|
81
|
+
}), u(f.Backspace, (e) => {
|
|
82
|
+
e && m.value === "" && c.value && k();
|
|
83
|
+
}), u(g, (e) => {
|
|
73
84
|
e && e.focus();
|
|
74
85
|
});
|
|
75
|
-
const h = w(() =>
|
|
86
|
+
const h = w(() => n.value.filter((e) => e.hidden === void 0 || e.hidden === !1)), p = (e) => t(i.Item, {
|
|
76
87
|
onSelect: e == null ? void 0 : e.onSelect
|
|
77
88
|
}, {
|
|
78
89
|
default: () => [t("div", {
|
|
@@ -87,8 +98,8 @@ const pe = /* @__PURE__ */ M({
|
|
|
87
98
|
default: () => [e == null ? void 0 : e.keyName]
|
|
88
99
|
})])])]
|
|
89
100
|
});
|
|
90
|
-
return () => t(
|
|
91
|
-
visible:
|
|
101
|
+
return () => t(i.Dialog, {
|
|
102
|
+
visible: v.value,
|
|
92
103
|
theme: "command-palette"
|
|
93
104
|
}, {
|
|
94
105
|
header: () => t("div", {
|
|
@@ -97,7 +108,7 @@ const pe = /* @__PURE__ */ M({
|
|
|
97
108
|
ref: g,
|
|
98
109
|
placeholder: a("common.search"),
|
|
99
110
|
onInput: (e) => {
|
|
100
|
-
|
|
111
|
+
m.value = e.target.value;
|
|
101
112
|
},
|
|
102
113
|
class: "w-full h-12 text-base/5 rounded-md border-0 placeholder:text-dimmed outline-0 px-2.5 py-1.5 text-sm gap-1.5 text-highlighted bg-transparent ps-10 pe-10"
|
|
103
114
|
}, null), t("span", {
|
|
@@ -122,15 +133,15 @@ const pe = /* @__PURE__ */ M({
|
|
|
122
133
|
"aria-hidden": "true"
|
|
123
134
|
}, null)
|
|
124
135
|
})])]),
|
|
125
|
-
body: () => t(V, null, [h.value.length === 0 &&
|
|
136
|
+
body: () => t(V, null, [h.value.length === 0 && m.value && t("div", {
|
|
126
137
|
class: "flex items-center justify-center h-20 border-t border-muted"
|
|
127
|
-
}, [a("common.empty")]), h.value.length > 0 && t(
|
|
128
|
-
default: () => [t(
|
|
138
|
+
}, [a("common.empty")]), h.value.length > 0 && t(i.List, null, {
|
|
139
|
+
default: () => [t(i.Group, {
|
|
129
140
|
heading: a("common.menu")
|
|
130
141
|
}, {
|
|
131
142
|
default: () => {
|
|
132
143
|
var e;
|
|
133
|
-
return [(e = h.value) == null ? void 0 : e.map((l, r) => t(
|
|
144
|
+
return [(e = h.value) == null ? void 0 : e.map((l, r) => t(i.Item, {
|
|
134
145
|
key: r,
|
|
135
146
|
onSelect: () => {
|
|
136
147
|
l.path ? (C.push(l.path), z()) : x(l.name);
|
|
@@ -141,25 +152,25 @@ const pe = /* @__PURE__ */ M({
|
|
|
141
152
|
}, null), l.label]
|
|
142
153
|
}))];
|
|
143
154
|
}
|
|
144
|
-
}), t(
|
|
155
|
+
}), t(i.Separator, null, null), c.value ? t(p, {
|
|
145
156
|
icon: "i-tabler:arrow-left",
|
|
146
157
|
label: a("common.back"),
|
|
147
158
|
onSelect: k,
|
|
148
159
|
keyName: "Backspace"
|
|
149
|
-
}, null) : t(
|
|
160
|
+
}, null) : t(i.Group, {
|
|
150
161
|
heading: a("common.theme")
|
|
151
162
|
}, {
|
|
152
|
-
default: () => [t(
|
|
163
|
+
default: () => [t(p, {
|
|
153
164
|
icon: "i-tabler:moon",
|
|
154
165
|
label: a("common.dark"),
|
|
155
166
|
onSelect: () => {
|
|
156
|
-
|
|
167
|
+
b("dark");
|
|
157
168
|
}
|
|
158
|
-
}, null), t(
|
|
169
|
+
}, null), t(p, {
|
|
159
170
|
icon: "i-tabler:sun",
|
|
160
171
|
label: a("common.light"),
|
|
161
172
|
onSelect: () => {
|
|
162
|
-
|
|
173
|
+
b("light");
|
|
163
174
|
}
|
|
164
175
|
}, null)]
|
|
165
176
|
})]
|
|
@@ -168,5 +179,5 @@ const pe = /* @__PURE__ */ M({
|
|
|
168
179
|
}
|
|
169
180
|
});
|
|
170
181
|
export {
|
|
171
|
-
|
|
182
|
+
we as DuxMenuCmd
|
|
172
183
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { defineComponent as c, createVNode as e, createTextVNode as i } from "vue";
|
|
2
2
|
import { useManage as f, useI18n as v, DuxLogoIcon as x } from "@duxweb/dvha-core";
|
|
3
3
|
import { useNaiveMenu as g } from "@duxweb/dvha-naiveui";
|
|
4
|
-
import { NTag as r,
|
|
4
|
+
import { NTag as r, NScrollbar as h, NMenu as b } from "naive-ui";
|
|
5
5
|
import "vue-router";
|
|
6
6
|
import "@overlastic/vue";
|
|
7
7
|
import "clsx";
|
|
@@ -22,16 +22,27 @@ import "@unocss/preset-typography";
|
|
|
22
22
|
import "unocss/preset-wind4";
|
|
23
23
|
import "@vee-validate/i18n/dist/locale/en.json";
|
|
24
24
|
import "@vee-validate/i18n/dist/locale/zh_CN.json";
|
|
25
|
-
import
|
|
26
|
-
import
|
|
25
|
+
import M from "./avatar.js";
|
|
26
|
+
import p from "./button.js";
|
|
27
27
|
import "vue-command-palette";
|
|
28
28
|
import "../page404.js";
|
|
29
29
|
import "@iconify-json/tabler/icons.json";
|
|
30
30
|
import "mime";
|
|
31
|
+
import "vue3-ace-editor";
|
|
32
|
+
import "ace-builds/src-noconflict/mode-vue";
|
|
33
|
+
import "ace-builds/src-noconflict/mode-javascript";
|
|
34
|
+
import "ace-builds/src-noconflict/mode-html";
|
|
35
|
+
import "ace-builds/src-noconflict/mode-json";
|
|
36
|
+
import "ace-builds/src-noconflict/mode-json5";
|
|
37
|
+
import "ace-builds/src-noconflict/theme-tomorrow_night";
|
|
38
|
+
import "ace-builds/src-noconflict/theme-tomorrow";
|
|
39
|
+
import "ace-builds/src-noconflict/ext-searchbox";
|
|
40
|
+
import "ace-builds/src-noconflict/ext-language_tools";
|
|
41
|
+
import "ace-builds/src-noconflict/mode-snippets";
|
|
31
42
|
import "dayjs";
|
|
32
43
|
import "@tanstack/vue-query";
|
|
33
|
-
import { useUI as
|
|
34
|
-
const
|
|
44
|
+
import { useUI as y } from "../../hooks/ui.js";
|
|
45
|
+
const ue = /* @__PURE__ */ c({
|
|
35
46
|
name: "DuxMenuMain",
|
|
36
47
|
props: {
|
|
37
48
|
collapsed: {
|
|
@@ -41,14 +52,14 @@ const ee = /* @__PURE__ */ c({
|
|
|
41
52
|
},
|
|
42
53
|
setup(o) {
|
|
43
54
|
const {
|
|
44
|
-
options:
|
|
45
|
-
active:
|
|
55
|
+
options: a,
|
|
56
|
+
active: m
|
|
46
57
|
} = g({}), {
|
|
47
|
-
menuCollapsed:
|
|
48
|
-
setCmdVisible:
|
|
49
|
-
menuMobileCollapsed:
|
|
58
|
+
menuCollapsed: t,
|
|
59
|
+
setCmdVisible: s,
|
|
60
|
+
menuMobileCollapsed: l,
|
|
50
61
|
setMenuCollapsed: d
|
|
51
|
-
} =
|
|
62
|
+
} = y(), {
|
|
52
63
|
config: n
|
|
53
64
|
} = f(), {
|
|
54
65
|
t: u
|
|
@@ -57,8 +68,8 @@ const ee = /* @__PURE__ */ c({
|
|
|
57
68
|
class: "flex flex-col h-screen px-1"
|
|
58
69
|
}, [e("div", {
|
|
59
70
|
class: "h-13 px-2 hidden lg:flex justify-center items-center"
|
|
60
|
-
}, [e(
|
|
61
|
-
onClick: () => d(!
|
|
71
|
+
}, [e(p, {
|
|
72
|
+
onClick: () => d(!t.value),
|
|
62
73
|
collapsed: o.collapsed
|
|
63
74
|
}, {
|
|
64
75
|
icon: () => e("div", {
|
|
@@ -70,18 +81,18 @@ const ee = /* @__PURE__ */ c({
|
|
|
70
81
|
default: () => e("div", null, [n.title])
|
|
71
82
|
})]), e("div", {
|
|
72
83
|
class: "px-2 py-1 hidden lg:block"
|
|
73
|
-
}, [e(
|
|
84
|
+
}, [e(p, {
|
|
74
85
|
collapsed: o.collapsed,
|
|
75
86
|
inverted: !0,
|
|
76
87
|
class: "relative py-1.5 px-3",
|
|
77
|
-
onClick: () =>
|
|
88
|
+
onClick: () => s(!0)
|
|
78
89
|
}, {
|
|
79
90
|
icon: () => e("div", {
|
|
80
91
|
class: "i-tabler:search size-4 icon-gradient"
|
|
81
92
|
}, null),
|
|
82
93
|
default: () => e("div", {
|
|
83
94
|
class: "text-muted text-sm"
|
|
84
|
-
}, [u("common.search"), !
|
|
95
|
+
}, [u("common.search"), !t.value && e("div", {
|
|
85
96
|
class: "flex items-center gap-1 absolute right-2.5 top-1.3"
|
|
86
97
|
}, [e(r, {
|
|
87
98
|
size: "small",
|
|
@@ -97,21 +108,23 @@ const ee = /* @__PURE__ */ c({
|
|
|
97
108
|
default: () => [i("K")]
|
|
98
109
|
})])])
|
|
99
110
|
})]), e("div", {
|
|
100
|
-
class: ["flex-1 min-h-0",
|
|
101
|
-
}, [e(h, {
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
111
|
+
class: ["flex-1 min-h-0", l.value ? "border-t border-muted" : ""]
|
|
112
|
+
}, [e(h, null, {
|
|
113
|
+
default: () => [e(b, {
|
|
114
|
+
options: a.value,
|
|
115
|
+
value: m.value,
|
|
116
|
+
collapsed: t.value && !l.value,
|
|
117
|
+
indent: 20,
|
|
118
|
+
collapsedWidth: 60,
|
|
119
|
+
collapsedIconSize: 20
|
|
120
|
+
}, null)]
|
|
121
|
+
})]), e("div", {
|
|
109
122
|
class: "flex-none hidden lg:flex flex-col items-center gap-2 p-2 border-t border-muted/50"
|
|
110
|
-
}, [e(
|
|
123
|
+
}, [e(M, {
|
|
111
124
|
collapsed: o.collapsed
|
|
112
125
|
}, null)])]);
|
|
113
126
|
}
|
|
114
127
|
});
|
|
115
128
|
export {
|
|
116
|
-
|
|
129
|
+
ue as DuxMenuMain
|
|
117
130
|
};
|
|
@@ -27,10 +27,21 @@ import "@duxweb/dvha-naiveui";
|
|
|
27
27
|
import "../page404.js";
|
|
28
28
|
import "@iconify-json/tabler/icons.json";
|
|
29
29
|
import "mime";
|
|
30
|
+
import "vue3-ace-editor";
|
|
31
|
+
import "ace-builds/src-noconflict/mode-vue";
|
|
32
|
+
import "ace-builds/src-noconflict/mode-javascript";
|
|
33
|
+
import "ace-builds/src-noconflict/mode-html";
|
|
34
|
+
import "ace-builds/src-noconflict/mode-json";
|
|
35
|
+
import "ace-builds/src-noconflict/mode-json5";
|
|
36
|
+
import "ace-builds/src-noconflict/theme-tomorrow_night";
|
|
37
|
+
import "ace-builds/src-noconflict/theme-tomorrow";
|
|
38
|
+
import "ace-builds/src-noconflict/ext-searchbox";
|
|
39
|
+
import "ace-builds/src-noconflict/ext-language_tools";
|
|
40
|
+
import "ace-builds/src-noconflict/mode-snippets";
|
|
30
41
|
import "dayjs";
|
|
31
42
|
import "@tanstack/vue-query";
|
|
32
43
|
import { useUI as e } from "../../hooks/ui.js";
|
|
33
|
-
const
|
|
44
|
+
const Y = /* @__PURE__ */ p({
|
|
34
45
|
name: "DuxMobileMenu",
|
|
35
46
|
props: {},
|
|
36
47
|
setup(l) {
|
|
@@ -50,5 +61,5 @@ const H = /* @__PURE__ */ p({
|
|
|
50
61
|
}
|
|
51
62
|
});
|
|
52
63
|
export {
|
|
53
|
-
|
|
64
|
+
Y as DuxMobileMenu
|
|
54
65
|
};
|
package/dist/esm/pages/page.js
CHANGED
|
@@ -29,7 +29,7 @@ const x = /* @__PURE__ */ m({
|
|
|
29
29
|
};
|
|
30
30
|
return () => {
|
|
31
31
|
var t, o, i;
|
|
32
|
-
const r = a.card ? "bg-default dark:bg-muted rounded
|
|
32
|
+
const r = a.card ? "bg-default dark:bg-muted rounded shadow-xs lg:dark:border lg:dark:border-muted" : "", n = a.card && a.padding ? "p-3" : "", l = a.scrollbar ? "" : "h-full";
|
|
33
33
|
return c("div", {
|
|
34
34
|
class: "h-full flex-1 flex gap-2 relative"
|
|
35
35
|
}, [c("div", {
|
|
@@ -30,20 +30,31 @@ import "@vee-validate/i18n/dist/locale/zh_CN.json";
|
|
|
30
30
|
import "vue-command-palette";
|
|
31
31
|
import { DuxPageStatus as d } from "./pageStatus.js";
|
|
32
32
|
import "@iconify-json/tabler/icons.json";
|
|
33
|
+
import "vue3-ace-editor";
|
|
34
|
+
import "ace-builds/src-noconflict/mode-vue";
|
|
35
|
+
import "ace-builds/src-noconflict/mode-javascript";
|
|
36
|
+
import "ace-builds/src-noconflict/mode-html";
|
|
37
|
+
import "ace-builds/src-noconflict/mode-json";
|
|
38
|
+
import "ace-builds/src-noconflict/mode-json5";
|
|
39
|
+
import "ace-builds/src-noconflict/theme-tomorrow_night";
|
|
40
|
+
import "ace-builds/src-noconflict/theme-tomorrow";
|
|
41
|
+
import "ace-builds/src-noconflict/ext-searchbox";
|
|
42
|
+
import "ace-builds/src-noconflict/ext-language_tools";
|
|
43
|
+
import "ace-builds/src-noconflict/mode-snippets";
|
|
33
44
|
function g(o) {
|
|
34
45
|
return typeof o == "function" || Object.prototype.toString.call(o) === "[object Object]" && !u(o);
|
|
35
46
|
}
|
|
36
47
|
const D = /* @__PURE__ */ n({
|
|
37
48
|
name: "DuxPage404",
|
|
38
49
|
setup(o) {
|
|
39
|
-
const
|
|
50
|
+
const p = l(), m = c(), {
|
|
40
51
|
t: r
|
|
41
52
|
} = s();
|
|
42
|
-
function
|
|
43
|
-
|
|
44
|
-
path:
|
|
53
|
+
function e() {
|
|
54
|
+
m.push({
|
|
55
|
+
path: p.path,
|
|
45
56
|
query: {
|
|
46
|
-
...
|
|
57
|
+
...p.query,
|
|
47
58
|
t: Date.now()
|
|
48
59
|
}
|
|
49
60
|
});
|
|
@@ -54,14 +65,14 @@ const D = /* @__PURE__ */ n({
|
|
|
54
65
|
}, {
|
|
55
66
|
default: () => t("div", null, [t(f, null, null)]),
|
|
56
67
|
action: () => {
|
|
57
|
-
let
|
|
68
|
+
let i;
|
|
58
69
|
return t(a, {
|
|
59
|
-
onClick:
|
|
70
|
+
onClick: e,
|
|
60
71
|
renderIcon: () => t("div", {
|
|
61
72
|
class: "n-icon i-tabler:refresh"
|
|
62
73
|
}, null)
|
|
63
|
-
}, g(
|
|
64
|
-
default: () => [
|
|
74
|
+
}, g(i = r("components.button.refresh")) ? i : {
|
|
75
|
+
default: () => [i]
|
|
65
76
|
});
|
|
66
77
|
}
|
|
67
78
|
});
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as o, createVNode as
|
|
1
|
+
import { defineComponent as o, createVNode as i } from "vue";
|
|
2
2
|
import { DuxCard as p } from "../components/card/card.js";
|
|
3
3
|
import "clsx";
|
|
4
4
|
import "naive-ui";
|
|
@@ -30,37 +30,53 @@ import "@vee-validate/i18n/dist/locale/zh_CN.json";
|
|
|
30
30
|
import "vue-command-palette";
|
|
31
31
|
import "./page404.js";
|
|
32
32
|
import "@iconify-json/tabler/icons.json";
|
|
33
|
-
|
|
33
|
+
import "vue3-ace-editor";
|
|
34
|
+
import "ace-builds/src-noconflict/mode-vue";
|
|
35
|
+
import "ace-builds/src-noconflict/mode-javascript";
|
|
36
|
+
import "ace-builds/src-noconflict/mode-html";
|
|
37
|
+
import "ace-builds/src-noconflict/mode-json";
|
|
38
|
+
import "ace-builds/src-noconflict/mode-json5";
|
|
39
|
+
import "ace-builds/src-noconflict/theme-tomorrow_night";
|
|
40
|
+
import "ace-builds/src-noconflict/theme-tomorrow";
|
|
41
|
+
import "ace-builds/src-noconflict/ext-searchbox";
|
|
42
|
+
import "ace-builds/src-noconflict/ext-language_tools";
|
|
43
|
+
import "ace-builds/src-noconflict/mode-snippets";
|
|
44
|
+
const Y = /* @__PURE__ */ o({
|
|
34
45
|
name: "DuxPageStatus",
|
|
35
46
|
props: {
|
|
36
47
|
title: String,
|
|
37
|
-
desc: String
|
|
48
|
+
desc: String,
|
|
49
|
+
bordered: {
|
|
50
|
+
type: Boolean,
|
|
51
|
+
default: !0
|
|
52
|
+
}
|
|
38
53
|
},
|
|
39
|
-
setup(
|
|
54
|
+
setup(t, {
|
|
40
55
|
slots: e
|
|
41
56
|
}) {
|
|
42
|
-
return () =>
|
|
43
|
-
class: "size-full flex items-center justify-center"
|
|
57
|
+
return () => i(p, {
|
|
58
|
+
class: "size-full flex items-center justify-center",
|
|
59
|
+
bordered: t.bordered
|
|
44
60
|
}, {
|
|
45
61
|
default: () => {
|
|
46
|
-
var
|
|
47
|
-
return [
|
|
62
|
+
var r, m;
|
|
63
|
+
return [i("div", {
|
|
48
64
|
class: "flex flex-col gap-6 justify-center items-center py-10"
|
|
49
|
-
}, [
|
|
65
|
+
}, [i("div", {
|
|
50
66
|
class: "w-40"
|
|
51
|
-
}, [(
|
|
67
|
+
}, [(r = e.default) == null ? void 0 : r.call(e)]), i("div", {
|
|
52
68
|
class: "flex flex-col items-center justify-center gap-2"
|
|
53
|
-
}, [
|
|
69
|
+
}, [i("div", {
|
|
54
70
|
class: "text-lg text-default font-bold"
|
|
55
|
-
}, [
|
|
71
|
+
}, [t == null ? void 0 : t.title]), i("div", {
|
|
56
72
|
class: "text-muted"
|
|
57
|
-
}, [
|
|
73
|
+
}, [t == null ? void 0 : t.desc])]), i("div", {
|
|
58
74
|
class: "flex justify-center items-center gap-4"
|
|
59
|
-
}, [(
|
|
75
|
+
}, [(m = e.action) == null ? void 0 : m.call(e)])])];
|
|
60
76
|
}
|
|
61
77
|
});
|
|
62
78
|
}
|
|
63
79
|
});
|
|
64
80
|
export {
|
|
65
|
-
|
|
81
|
+
Y as DuxPageStatus
|
|
66
82
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { useTheme as C } from "@duxweb/dvha-core";
|
|
2
2
|
import { hex2rgb as i } from "colorizr";
|
|
3
|
-
import { merge as
|
|
3
|
+
import { merge as s } from "lodash-es";
|
|
4
4
|
import { computed as l } from "vue";
|
|
5
5
|
function g() {
|
|
6
6
|
const { getSceneColor: o, getSemanticColor: r } = C(), e = (m) => {
|
|
7
7
|
const t = i(m);
|
|
8
8
|
return `${t.r}, ${t.g},${t.b}`;
|
|
9
|
-
},
|
|
9
|
+
}, a = l(() => ({
|
|
10
10
|
common: {
|
|
11
11
|
primaryColor: o("primary"),
|
|
12
12
|
primaryColorHover: o("primary", "hover"),
|
|
@@ -70,18 +70,18 @@ function g() {
|
|
|
70
70
|
tabTextColorHoverSegment: r("text", "muted")
|
|
71
71
|
},
|
|
72
72
|
Card: {}
|
|
73
|
-
})),
|
|
73
|
+
})), d = l(() => s(a.value, {
|
|
74
74
|
common: {
|
|
75
75
|
cardColor: r("bg", "base"),
|
|
76
76
|
modalColor: r("bg", "base"),
|
|
77
77
|
dividerColor: r("border", "muted"),
|
|
78
78
|
borderColor: r("border", "muted"),
|
|
79
|
-
popoverColor: `rgba(${e(r("bg", "
|
|
79
|
+
popoverColor: `rgba(${e(r("bg", "base"))}, 0.98)`
|
|
80
80
|
},
|
|
81
81
|
DataTable: {
|
|
82
82
|
tdColor: r("bg", "base")
|
|
83
83
|
}
|
|
84
|
-
})), n = l(() => a
|
|
84
|
+
})), n = l(() => s(a.value, {
|
|
85
85
|
common: {
|
|
86
86
|
cardColor: r("bg", "muted"),
|
|
87
87
|
modalColor: r("bg", "muted"),
|
|
@@ -94,7 +94,7 @@ function g() {
|
|
|
94
94
|
}
|
|
95
95
|
}));
|
|
96
96
|
return {
|
|
97
|
-
lightTheme:
|
|
97
|
+
lightTheme: d,
|
|
98
98
|
darkTheme: n
|
|
99
99
|
};
|
|
100
100
|
}
|