@duxweb/dvha-pro 0.0.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/cjs/app.cjs +1 -0
- package/dist/cjs/component.cjs +1 -0
- package/dist/cjs/components/card/card.cjs +1 -0
- package/dist/cjs/components/carousel/carousel.cjs +1 -0
- package/dist/cjs/components/dashboard/hello.cjs +1 -0
- package/dist/cjs/components/dashboard/helloBig.cjs +1 -0
- package/dist/cjs/components/dashboard/quick.cjs +1 -0
- package/dist/cjs/components/dialog/dialog.cjs +1 -0
- package/dist/cjs/components/draw/drawApps.cjs +1 -0
- package/dist/cjs/components/draw/drawAuth.cjs +1 -0
- package/dist/cjs/components/draw/drawEmpty.cjs +1 -0
- package/dist/cjs/components/draw/drawEmptyForm.cjs +1 -0
- package/dist/cjs/components/draw/drawError.cjs +1 -0
- package/dist/cjs/components/drawer/drawer.cjs +1 -0
- package/dist/cjs/components/drawer/drawerPage.cjs +1 -0
- package/dist/cjs/components/form/formItem.cjs +1 -0
- package/dist/cjs/components/form/formLayout.cjs +1 -0
- package/dist/cjs/components/form/modalForm.cjs +1 -0
- package/dist/cjs/components/form/pageForm.cjs +1 -0
- package/dist/cjs/components/form/settingForm.cjs +1 -0
- package/dist/cjs/components/layout/filter.cjs +1 -0
- package/dist/cjs/components/layout/list.cjs +1 -0
- package/dist/cjs/components/layout/table.cjs +1 -0
- package/dist/cjs/components/layout/tools.cjs +1 -0
- package/dist/cjs/components/list/card.cjs +1 -0
- package/dist/cjs/components/list/list.cjs +1 -0
- package/dist/cjs/components/media/media.cjs +1 -0
- package/dist/cjs/components/modal/modal.cjs +1 -0
- package/dist/cjs/components/modal/modalPage.cjs +1 -0
- package/dist/cjs/components/modal/modalTab.cjs +1 -0
- package/dist/cjs/components/panel/alert.cjs +1 -0
- package/dist/cjs/components/panel/setting.cjs +1 -0
- package/dist/cjs/components/status/blockEmpty.cjs +1 -0
- package/dist/cjs/components/table/tablePage.cjs +1 -0
- package/dist/cjs/components/widget/connect.cjs +1 -0
- package/dist/cjs/config/uno.cjs +1 -0
- package/dist/cjs/config/validate.cjs +1 -0
- package/dist/cjs/dvha-pro.css +1 -0
- package/dist/cjs/hooks/action.cjs +1 -0
- package/dist/cjs/hooks/dialog.cjs +1 -0
- package/dist/cjs/hooks/drawer.cjs +1 -0
- package/dist/cjs/hooks/modal.cjs +1 -0
- package/dist/cjs/hooks/table/column.cjs +1 -0
- package/dist/cjs/hooks/table/copy.cjs +1 -0
- package/dist/cjs/hooks/table/hidden.cjs +1 -0
- package/dist/cjs/hooks/table/image.cjs +1 -0
- package/dist/cjs/hooks/table/input.cjs +1 -0
- package/dist/cjs/hooks/table/map.cjs +1 -0
- package/dist/cjs/hooks/table/media.cjs +1 -0
- package/dist/cjs/hooks/table/status.cjs +1 -0
- package/dist/cjs/hooks/table/switch.cjs +1 -0
- package/dist/cjs/hooks/table.cjs +1 -0
- package/dist/cjs/hooks/ui.cjs +1 -0
- package/dist/cjs/index.cjs +1 -0
- package/dist/cjs/langs/en-US.json.cjs +1 -0
- package/dist/cjs/langs/zh-CN.json.cjs +1 -0
- package/dist/cjs/main.cjs +1 -0
- package/dist/cjs/node_modules/@iconify-json/tabler/icons.json.cjs +1 -0
- package/dist/cjs/node_modules/@overlastic/core/dist/index.cjs +1 -0
- package/dist/cjs/node_modules/@overlastic/vue/dist/index.cjs +1 -0
- package/dist/cjs/node_modules/@vee-validate/i18n/dist/locale/en.json.cjs +1 -0
- package/dist/cjs/node_modules/@vee-validate/i18n/dist/locale/zh_CN.json.cjs +1 -0
- package/dist/cjs/node_modules/@vueuse/integrations/useFocusTrap.cjs +1 -0
- package/dist/cjs/node_modules/@vueuse/shared/index.cjs +1 -0
- package/dist/cjs/node_modules/colorizr/dist/index.cjs +1 -0
- package/dist/cjs/node_modules/focus-trap/dist/focus-trap.esm.cjs +5 -0
- package/dist/cjs/node_modules/lower-case/dist.es2015/index.cjs +1 -0
- package/dist/cjs/node_modules/no-case/dist.es2015/index.cjs +1 -0
- package/dist/cjs/node_modules/pascal-case/dist.es2015/index.cjs +1 -0
- package/dist/cjs/node_modules/tabbable/dist/index.esm.cjs +4 -0
- package/dist/cjs/node_modules/tslib/tslib.es6.cjs +1 -0
- package/dist/cjs/pages/authLayout.cjs +1 -0
- package/dist/cjs/pages/layout/global.cjs +1 -0
- package/dist/cjs/pages/layout/page.cjs +1 -0
- package/dist/cjs/pages/layout/tab.cjs +1 -0
- package/dist/cjs/pages/layout.cjs +1 -0
- package/dist/cjs/pages/loading.cjs +1 -0
- package/dist/cjs/pages/login.cjs +1 -0
- package/dist/cjs/pages/menu/avatar.cjs +1 -0
- package/dist/cjs/pages/menu/button.cjs +1 -0
- package/dist/cjs/pages/menu/cmd.cjs +1 -0
- package/dist/cjs/pages/menu/main.cjs +1 -0
- package/dist/cjs/pages/menu/mobile.cjs +1 -0
- package/dist/cjs/pages/page.cjs +1 -0
- package/dist/cjs/pages/page403.cjs +1 -0
- package/dist/cjs/pages/page404.cjs +1 -0
- package/dist/cjs/pages/page500.cjs +1 -0
- package/dist/cjs/pages/pageEmpty.cjs +1 -0
- package/dist/cjs/pages/pageLoading.cjs +1 -0
- package/dist/cjs/pages/pageStatus.cjs +1 -0
- package/dist/cjs/static/images/placeholder.png.cjs +1 -0
- package/dist/cjs/stores/ui.cjs +1 -0
- package/dist/cjs/theme/naiveTheme.cjs +1 -0
- package/dist/cjs/theme/presetTheme.cjs +1 -0
- package/dist/cjs/theme/uno.css.cjs +1285 -0
- package/dist/esm/app.js +20 -0
- package/dist/esm/component.js +59 -0
- package/dist/esm/components/card/card.js +114 -0
- package/dist/esm/components/carousel/carousel.js +37 -0
- package/dist/esm/components/dashboard/hello.js +40 -0
- package/dist/esm/components/dashboard/helloBig.js +344 -0
- package/dist/esm/components/dashboard/quick.js +59 -0
- package/dist/esm/components/dialog/dialog.js +118 -0
- package/dist/esm/components/draw/drawApps.js +145 -0
- package/dist/esm/components/draw/drawAuth.js +50 -0
- package/dist/esm/components/draw/drawEmpty.js +92 -0
- package/dist/esm/components/draw/drawEmptyForm.js +128 -0
- package/dist/esm/components/draw/drawError.js +242 -0
- package/dist/esm/components/drawer/drawer.js +73 -0
- package/dist/esm/components/drawer/drawerPage.js +28 -0
- package/dist/esm/components/form/formItem.js +77 -0
- package/dist/esm/components/form/formLayout.js +38 -0
- package/dist/esm/components/form/modalForm.js +108 -0
- package/dist/esm/components/form/pageForm.js +94 -0
- package/dist/esm/components/form/settingForm.js +104 -0
- package/dist/esm/components/layout/filter.js +27 -0
- package/dist/esm/components/layout/list.js +333 -0
- package/dist/esm/components/layout/table.js +292 -0
- package/dist/esm/components/layout/tools.js +78 -0
- package/dist/esm/components/list/card.js +78 -0
- package/dist/esm/components/list/list.js +38 -0
- package/dist/esm/components/media/media.js +77 -0
- package/dist/esm/components/modal/modal.js +116 -0
- package/dist/esm/components/modal/modalPage.js +56 -0
- package/dist/esm/components/modal/modalTab.js +70 -0
- package/dist/esm/components/panel/alert.js +57 -0
- package/dist/esm/components/panel/setting.js +49 -0
- package/dist/esm/components/status/blockEmpty.js +78 -0
- package/dist/esm/components/table/tablePage.js +41 -0
- package/dist/esm/components/widget/connect.js +119 -0
- package/dist/esm/config/uno.js +32 -0
- package/dist/esm/config/validate.js +15 -0
- package/dist/esm/dvha-pro.css +1 -0
- package/dist/esm/hooks/action.js +213 -0
- package/dist/esm/hooks/dialog.js +32 -0
- package/dist/esm/hooks/drawer.js +25 -0
- package/dist/esm/hooks/modal.js +14 -0
- package/dist/esm/hooks/table/column.js +31 -0
- package/dist/esm/hooks/table/copy.js +27 -0
- package/dist/esm/hooks/table/hidden.js +48 -0
- package/dist/esm/hooks/table/image.js +24 -0
- package/dist/esm/hooks/table/input.js +81 -0
- package/dist/esm/hooks/table/map.js +21 -0
- package/dist/esm/hooks/table/media.js +34 -0
- package/dist/esm/hooks/table/status.js +32 -0
- package/dist/esm/hooks/table/switch.js +33 -0
- package/dist/esm/hooks/table.js +74 -0
- package/dist/esm/hooks/ui.js +16 -0
- package/dist/esm/index.js +139 -0
- package/dist/esm/langs/en-US.json.js +11 -0
- package/dist/esm/langs/zh-CN.json.js +11 -0
- package/dist/esm/main.js +18 -0
- package/dist/esm/node_modules/@iconify-json/tabler/icons.json.js +17 -0
- package/dist/esm/node_modules/@overlastic/core/dist/index.js +76 -0
- package/dist/esm/node_modules/@overlastic/vue/dist/index.js +122 -0
- package/dist/esm/node_modules/@vee-validate/i18n/dist/locale/en.json.js +9 -0
- package/dist/esm/node_modules/@vee-validate/i18n/dist/locale/zh_CN.json.js +9 -0
- package/dist/esm/node_modules/@vueuse/integrations/useFocusTrap.js +43 -0
- package/dist/esm/node_modules/@vueuse/shared/index.js +6 -0
- package/dist/esm/node_modules/colorizr/dist/index.js +318 -0
- package/dist/esm/node_modules/focus-trap/dist/focus-trap.esm.js +473 -0
- package/dist/esm/node_modules/lower-case/dist.es2015/index.js +6 -0
- package/dist/esm/node_modules/no-case/dist.es2015/index.js +18 -0
- package/dist/esm/node_modules/pascal-case/dist.es2015/index.js +13 -0
- package/dist/esm/node_modules/tabbable/dist/index.esm.js +202 -0
- package/dist/esm/node_modules/tslib/tslib.es6.js +12 -0
- package/dist/esm/pages/authLayout.js +38 -0
- package/dist/esm/pages/layout/global.js +51 -0
- package/dist/esm/pages/layout/page.js +54 -0
- package/dist/esm/pages/layout/tab.js +110 -0
- package/dist/esm/pages/layout.js +14 -0
- package/dist/esm/pages/loading.js +14 -0
- package/dist/esm/pages/login.js +143 -0
- package/dist/esm/pages/menu/avatar.js +205 -0
- package/dist/esm/pages/menu/button.js +60 -0
- package/dist/esm/pages/menu/cmd.js +156 -0
- package/dist/esm/pages/menu/main.js +101 -0
- package/dist/esm/pages/menu/mobile.js +38 -0
- package/dist/esm/pages/page.js +47 -0
- package/dist/esm/pages/page403.js +46 -0
- package/dist/esm/pages/page404.js +57 -0
- package/dist/esm/pages/page500.js +45 -0
- package/dist/esm/pages/pageEmpty.js +25 -0
- package/dist/esm/pages/pageLoading.js +22 -0
- package/dist/esm/pages/pageStatus.js +50 -0
- package/dist/esm/static/images/placeholder.png.js +4 -0
- package/dist/esm/stores/ui.js +34 -0
- package/dist/esm/theme/naiveTheme.js +97 -0
- package/dist/esm/theme/presetTheme.js +12 -0
- package/dist/esm/theme/uno.css.js +1288 -0
- package/dist/types/app.d.ts +1 -0
- package/dist/types/component.d.ts +5 -0
- package/dist/types/components/card/card.d.ts +140 -0
- package/dist/types/components/card/index.d.ts +1 -0
- package/dist/types/components/carousel/carousel.d.ts +20 -0
- package/dist/types/components/carousel/index.d.ts +1 -0
- package/dist/types/components/dashboard/hello.d.ts +16 -0
- package/dist/types/components/dashboard/helloBig.d.ts +19 -0
- package/dist/types/components/dashboard/index.d.ts +3 -0
- package/dist/types/components/dashboard/quick.d.ts +33 -0
- package/dist/types/components/dialog/dialog.d.ts +35 -0
- package/dist/types/components/dialog/index.d.ts +1 -0
- package/dist/types/components/draw/drawApps.d.ts +1 -0
- package/dist/types/components/draw/drawAuth.d.ts +1 -0
- package/dist/types/components/draw/drawEmpty.d.ts +1 -0
- package/dist/types/components/draw/drawEmptyForm.d.ts +1 -0
- package/dist/types/components/draw/drawError.d.ts +1 -0
- package/dist/types/components/draw/index.d.ts +5 -0
- package/dist/types/components/drawer/drawer.d.ts +19 -0
- package/dist/types/components/drawer/drawerPage.d.ts +1 -0
- package/dist/types/components/drawer/index.d.ts +2 -0
- package/dist/types/components/form/formItem.d.ts +27 -0
- package/dist/types/components/form/formLayout.d.ts +38 -0
- package/dist/types/components/form/index.d.ts +5 -0
- package/dist/types/components/form/modalForm.d.ts +89 -0
- package/dist/types/components/form/pageForm.d.ts +51 -0
- package/dist/types/components/form/settingForm.d.ts +69 -0
- package/dist/types/components/index.d.ts +14 -0
- package/dist/types/components/layout/filter.d.ts +13 -0
- package/dist/types/components/layout/index.d.ts +4 -0
- package/dist/types/components/layout/list.d.ts +85 -0
- package/dist/types/components/layout/table.d.ts +72 -0
- package/dist/types/components/layout/tools.d.ts +37 -0
- package/dist/types/components/list/card.d.ts +117 -0
- package/dist/types/components/list/index.d.ts +2 -0
- package/dist/types/components/list/list.d.ts +87 -0
- package/dist/types/components/media/index.d.ts +1 -0
- package/dist/types/components/media/media.d.ts +95 -0
- package/dist/types/components/modal/index.d.ts +3 -0
- package/dist/types/components/modal/modal.d.ts +66 -0
- package/dist/types/components/modal/modalPage.d.ts +42 -0
- package/dist/types/components/modal/modalTab.d.ts +42 -0
- package/dist/types/components/panel/alert.d.ts +32 -0
- package/dist/types/components/panel/index.d.ts +2 -0
- package/dist/types/components/panel/setting.d.ts +29 -0
- package/dist/types/components/status/blockEmpty.d.ts +25 -0
- package/dist/types/components/status/index.d.ts +1 -0
- package/dist/types/components/table/index.d.ts +1 -0
- package/dist/types/components/table/tablePage.d.ts +73 -0
- package/dist/types/components/widget/connect.d.ts +11 -0
- package/dist/types/components/widget/index.d.ts +1 -0
- package/dist/types/config/index.d.ts +2 -0
- package/dist/types/config/uno.d.ts +2 -0
- package/dist/types/config/validate.d.ts +1 -0
- package/dist/types/hooks/action.d.ts +17 -0
- package/dist/types/hooks/dialog.d.ts +17 -0
- package/dist/types/hooks/drawer.d.ts +11 -0
- package/dist/types/hooks/index.d.ts +6 -0
- package/dist/types/hooks/modal.d.ts +9 -0
- package/dist/types/hooks/table/column.d.ts +14 -0
- package/dist/types/hooks/table/copy.d.ts +6 -0
- package/dist/types/hooks/table/hidden.d.ts +7 -0
- package/dist/types/hooks/table/image.d.ts +8 -0
- package/dist/types/hooks/table/index.d.ts +7 -0
- package/dist/types/hooks/table/input.d.ts +9 -0
- package/dist/types/hooks/table/map.d.ts +13 -0
- package/dist/types/hooks/table/media.d.ts +12 -0
- package/dist/types/hooks/table/status.d.ts +12 -0
- package/dist/types/hooks/table/switch.d.ts +7 -0
- package/dist/types/hooks/table/types.d.ts +74 -0
- package/dist/types/hooks/table.d.ts +2 -0
- package/dist/types/hooks/ui.d.ts +8 -0
- package/dist/types/index.d.ts +10 -0
- package/dist/types/langs/index.d.ts +3 -0
- package/dist/types/main.d.ts +5 -0
- package/dist/types/pages/authLayout.d.ts +1 -0
- package/dist/types/pages/index.d.ts +12 -0
- package/dist/types/pages/layout/global.d.ts +1 -0
- package/dist/types/pages/layout/index.d.ts +3 -0
- package/dist/types/pages/layout/page.d.ts +1 -0
- package/dist/types/pages/layout/tab.d.ts +1 -0
- package/dist/types/pages/layout.d.ts +1 -0
- package/dist/types/pages/loading.d.ts +1 -0
- package/dist/types/pages/login.d.ts +1 -0
- package/dist/types/pages/menu/avatar.d.ts +14 -0
- package/dist/types/pages/menu/button.d.ts +41 -0
- package/dist/types/pages/menu/cmd.d.ts +7 -0
- package/dist/types/pages/menu/index.d.ts +4 -0
- package/dist/types/pages/menu/main.d.ts +13 -0
- package/dist/types/pages/menu/mobile.d.ts +1 -0
- package/dist/types/pages/page.d.ts +42 -0
- package/dist/types/pages/page403.d.ts +1 -0
- package/dist/types/pages/page404.d.ts +1 -0
- package/dist/types/pages/page500.d.ts +1 -0
- package/dist/types/pages/pageEmpty.d.ts +7 -0
- package/dist/types/pages/pageLoading.d.ts +1 -0
- package/dist/types/pages/pageStatus.d.ts +7 -0
- package/dist/types/stores/index.d.ts +1 -0
- package/dist/types/stores/ui.d.ts +28 -0
- package/dist/types/theme/index.d.ts +2 -0
- package/dist/types/theme/naiveTheme.d.ts +5 -0
- package/dist/types/theme/presetTheme.d.ts +7 -0
- package/package.json +73 -0
|
@@ -0,0 +1,205 @@
|
|
|
1
|
+
import { defineComponent as D, computed as p, createVNode as e, createTextVNode as n } from "vue";
|
|
2
|
+
import { useI18n as N, useManage as $, useLogout as j, useTheme as L } from "@duxweb/dvha-core";
|
|
3
|
+
import { NAvatar as m, NDropdown as R } from "naive-ui";
|
|
4
|
+
import { useRouter as S } from "vue-router";
|
|
5
|
+
import A from "./button.js";
|
|
6
|
+
const V = /* @__PURE__ */ D({
|
|
7
|
+
name: "DuxMenuAvatar",
|
|
8
|
+
props: {
|
|
9
|
+
open: {
|
|
10
|
+
type: Boolean,
|
|
11
|
+
default: !1
|
|
12
|
+
}
|
|
13
|
+
},
|
|
14
|
+
setup(g) {
|
|
15
|
+
const i = N(), b = S(), {
|
|
16
|
+
config: v,
|
|
17
|
+
getRoutePath: f
|
|
18
|
+
} = $(), {
|
|
19
|
+
mutate: h
|
|
20
|
+
} = j(), {
|
|
21
|
+
mode: c,
|
|
22
|
+
primaryColors: y,
|
|
23
|
+
neutralColors: k,
|
|
24
|
+
colorMapping: u,
|
|
25
|
+
setColor: d,
|
|
26
|
+
setMode: x
|
|
27
|
+
} = L(), o = (a, t) => e("div", {
|
|
28
|
+
class: "flex gap-2 items-center w-30"
|
|
29
|
+
}, [e("div", {
|
|
30
|
+
class: "flex-1 min-w-0"
|
|
31
|
+
}, [a]), e("div", null, [t && e("div", {
|
|
32
|
+
class: "i-tabler:check"
|
|
33
|
+
}, null)])]), r = (a) => e("div", {
|
|
34
|
+
class: `${a} size-4`
|
|
35
|
+
}, null), C = p(() => {
|
|
36
|
+
var t;
|
|
37
|
+
const a = (t = v.userMenus) == null ? void 0 : t.map((l) => ({
|
|
38
|
+
label: l.label,
|
|
39
|
+
key: l.key,
|
|
40
|
+
icon: () => r(l.icon),
|
|
41
|
+
path: l.path
|
|
42
|
+
}));
|
|
43
|
+
return (a == null ? void 0 : a.length) > 0 ? [...a, {
|
|
44
|
+
type: "divider"
|
|
45
|
+
}] : [];
|
|
46
|
+
}), z = p(() => {
|
|
47
|
+
var a, t;
|
|
48
|
+
return [{
|
|
49
|
+
key: "header",
|
|
50
|
+
type: "render",
|
|
51
|
+
render: () => e("div", {
|
|
52
|
+
class: "flex gap-2 px-3 pb-1 pt-1 items-center "
|
|
53
|
+
}, [e(m, {
|
|
54
|
+
round: !0,
|
|
55
|
+
size: 28,
|
|
56
|
+
src: "https://07akioni.oss-cn-beijing.aliyuncs.com/07akioni.jpeg"
|
|
57
|
+
}, null), e("div", {
|
|
58
|
+
class: "flex flex-col"
|
|
59
|
+
}, [e("div", {
|
|
60
|
+
class: "text-sm font-medium"
|
|
61
|
+
}, [n("admin")]), e("div", {
|
|
62
|
+
class: "text-xs text-muted"
|
|
63
|
+
}, [n("admin@example.com")])])])
|
|
64
|
+
}, {
|
|
65
|
+
type: "divider"
|
|
66
|
+
}, ...C.value, {
|
|
67
|
+
label: "语言",
|
|
68
|
+
key: "locale",
|
|
69
|
+
icon: () => r("i-tabler:language"),
|
|
70
|
+
children: [{
|
|
71
|
+
label: () => o("中文", i.getLocale() === "zh-CN"),
|
|
72
|
+
key: "locale.zh-CN"
|
|
73
|
+
}, {
|
|
74
|
+
label: () => o("English", i.getLocale() === "en-US"),
|
|
75
|
+
key: "locale.en-US"
|
|
76
|
+
}]
|
|
77
|
+
}, {
|
|
78
|
+
label: "颜色",
|
|
79
|
+
key: "color",
|
|
80
|
+
icon: () => r("i-tabler:palette"),
|
|
81
|
+
children: [{
|
|
82
|
+
label: () => e("div", {
|
|
83
|
+
class: "flex gap-2 items-center w-30"
|
|
84
|
+
}, [e("div", {
|
|
85
|
+
class: "size-2 rounded-full",
|
|
86
|
+
style: {
|
|
87
|
+
backgroundColor: "rgb(var(--ui-color-primary))"
|
|
88
|
+
}
|
|
89
|
+
}, null), e("div", null, [n("主题色")])]),
|
|
90
|
+
key: "color.primary",
|
|
91
|
+
children: (a = y.value) == null ? void 0 : a.map((l) => ({
|
|
92
|
+
label: () => o(e("div", {
|
|
93
|
+
class: "flex gap-2 items-center"
|
|
94
|
+
}, [e("div", {
|
|
95
|
+
class: "size-2 rounded-full",
|
|
96
|
+
style: {
|
|
97
|
+
backgroundColor: `rgb(var(--base-color-${l}-500))`
|
|
98
|
+
}
|
|
99
|
+
}, null), e("div", null, [l])]), u.value.primary === l),
|
|
100
|
+
key: `color.primary.${l}`
|
|
101
|
+
}))
|
|
102
|
+
}, {
|
|
103
|
+
label: () => e("div", {
|
|
104
|
+
class: "flex gap-2 items-center w-30"
|
|
105
|
+
}, [e("div", {
|
|
106
|
+
class: "size-2 rounded-full",
|
|
107
|
+
style: {
|
|
108
|
+
backgroundColor: "rgb(var(--ui-color-gray-600))"
|
|
109
|
+
}
|
|
110
|
+
}, null), e("div", null, [n("中性色")])]),
|
|
111
|
+
key: "color.neutral",
|
|
112
|
+
children: (t = k.value) == null ? void 0 : t.map((l) => ({
|
|
113
|
+
label: () => o(e("div", {
|
|
114
|
+
class: "flex gap-2 items-center"
|
|
115
|
+
}, [e("div", {
|
|
116
|
+
class: "size-2 rounded-full",
|
|
117
|
+
style: {
|
|
118
|
+
backgroundColor: `rgb(var(--base-color-${l}-600))`
|
|
119
|
+
}
|
|
120
|
+
}, null), e("div", null, [l])]), u.value.gray === l),
|
|
121
|
+
key: `color.neutral.${l}`
|
|
122
|
+
}))
|
|
123
|
+
}]
|
|
124
|
+
}, {
|
|
125
|
+
label: "主题",
|
|
126
|
+
key: "theme",
|
|
127
|
+
icon: () => r("i-tabler:brightness-half"),
|
|
128
|
+
children: [{
|
|
129
|
+
label: () => o("跟随系统", c.value === "auto"),
|
|
130
|
+
key: "theme.auto"
|
|
131
|
+
}, {
|
|
132
|
+
label: () => o("亮色", c.value === "light"),
|
|
133
|
+
key: "theme.light"
|
|
134
|
+
}, {
|
|
135
|
+
label: () => o("暗色", c.value === "dark"),
|
|
136
|
+
key: "theme.dark"
|
|
137
|
+
}]
|
|
138
|
+
}, {
|
|
139
|
+
type: "divider"
|
|
140
|
+
}, {
|
|
141
|
+
label: "查看文档",
|
|
142
|
+
key: "link.docs",
|
|
143
|
+
icon: () => r("i-tabler:link")
|
|
144
|
+
}, {
|
|
145
|
+
type: "divider"
|
|
146
|
+
}, {
|
|
147
|
+
label: "退出登录",
|
|
148
|
+
key: "logout",
|
|
149
|
+
icon: () => r("i-tabler:logout")
|
|
150
|
+
}];
|
|
151
|
+
});
|
|
152
|
+
function w(a, t) {
|
|
153
|
+
const l = a.lastIndexOf("."), [M, s] = l === -1 ? [a, ""] : [a.substring(0, l), a.substring(l + 1)];
|
|
154
|
+
switch (M) {
|
|
155
|
+
case "locale":
|
|
156
|
+
i.changeLocale(s);
|
|
157
|
+
break;
|
|
158
|
+
case "color.primary":
|
|
159
|
+
d("primary", s);
|
|
160
|
+
break;
|
|
161
|
+
case "color.neutral":
|
|
162
|
+
d("gray", s);
|
|
163
|
+
break;
|
|
164
|
+
case "theme":
|
|
165
|
+
x(s);
|
|
166
|
+
break;
|
|
167
|
+
case "logout":
|
|
168
|
+
h();
|
|
169
|
+
break;
|
|
170
|
+
default:
|
|
171
|
+
if (!(t != null && t.path))
|
|
172
|
+
return;
|
|
173
|
+
b.push(f(t.path));
|
|
174
|
+
}
|
|
175
|
+
}
|
|
176
|
+
return () => e(R, {
|
|
177
|
+
options: z.value,
|
|
178
|
+
placement: "bottom-start",
|
|
179
|
+
trigger: "click",
|
|
180
|
+
onSelect: w,
|
|
181
|
+
width: 200
|
|
182
|
+
}, {
|
|
183
|
+
default: () => [e(A, {
|
|
184
|
+
open: g.open
|
|
185
|
+
}, {
|
|
186
|
+
icon: () => e(m, {
|
|
187
|
+
class: "group-hover:shadow-lg",
|
|
188
|
+
round: !0,
|
|
189
|
+
size: 28,
|
|
190
|
+
src: "https://07akioni.oss-cn-beijing.aliyuncs.com/07akioni.jpeg"
|
|
191
|
+
}, null),
|
|
192
|
+
default: () => e("div", {
|
|
193
|
+
class: "flex flex-col"
|
|
194
|
+
}, [e("div", {
|
|
195
|
+
class: "text-sm font-medium"
|
|
196
|
+
}, [n("admin")]), e("div", {
|
|
197
|
+
class: "text-xs text-muted"
|
|
198
|
+
}, [n("admin@example.com")])])
|
|
199
|
+
})]
|
|
200
|
+
});
|
|
201
|
+
}
|
|
202
|
+
});
|
|
203
|
+
export {
|
|
204
|
+
V as default
|
|
205
|
+
};
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import { defineComponent as l, createVNode as u } from "vue";
|
|
2
|
+
import "@duxweb/dvha-core";
|
|
3
|
+
import "naive-ui";
|
|
4
|
+
import "vue-router";
|
|
5
|
+
import "../../node_modules/@overlastic/vue/dist/index.js";
|
|
6
|
+
import "clsx";
|
|
7
|
+
import "jinrishici";
|
|
8
|
+
import "lodash-es";
|
|
9
|
+
import "@vueuse/core";
|
|
10
|
+
import "vee-validate";
|
|
11
|
+
import "@vee-validate/i18n";
|
|
12
|
+
import "vue-command-palette";
|
|
13
|
+
import "@duxweb/dvha-naiveui";
|
|
14
|
+
import "../page404.js";
|
|
15
|
+
import { useUI as d } from "../../hooks/ui.js";
|
|
16
|
+
const s = /* @__PURE__ */ l({
|
|
17
|
+
name: "DuxMenuButton",
|
|
18
|
+
props: {
|
|
19
|
+
class: {
|
|
20
|
+
type: String,
|
|
21
|
+
default: ""
|
|
22
|
+
},
|
|
23
|
+
onClick: {
|
|
24
|
+
type: Function,
|
|
25
|
+
default: () => {
|
|
26
|
+
}
|
|
27
|
+
},
|
|
28
|
+
open: {
|
|
29
|
+
type: Boolean,
|
|
30
|
+
default: !1
|
|
31
|
+
},
|
|
32
|
+
inverted: {
|
|
33
|
+
type: Boolean,
|
|
34
|
+
default: !1
|
|
35
|
+
}
|
|
36
|
+
},
|
|
37
|
+
setup(e, {
|
|
38
|
+
slots: t
|
|
39
|
+
}) {
|
|
40
|
+
const {
|
|
41
|
+
menuCollapsed: n,
|
|
42
|
+
menuMobileCollapsed: o
|
|
43
|
+
} = d();
|
|
44
|
+
return () => {
|
|
45
|
+
var i, a;
|
|
46
|
+
return u("div", {
|
|
47
|
+
onClick: () => {
|
|
48
|
+
var r;
|
|
49
|
+
(r = e.onClick) == null || r.call(e);
|
|
50
|
+
},
|
|
51
|
+
class: ["flex items-center gap-1 justify-center py-1 px-2 cursor-pointer gap-2", e.class, n.value && !o.value ? "group" : "hover:shadow-xs hover:bg-default flex-1 w-full", e.inverted ? "transition-all duration-300 bg-inverted/5 rounded-full hover:bg-default hover:shadow-xs" : " rounded-md"]
|
|
52
|
+
}, [(i = t.icon) == null ? void 0 : i.call(t), (!n.value && !o.value || e.open) && u("div", {
|
|
53
|
+
class: ["overflow-hidden ease-in-out whitespace-nowrap text-left min-w-0 flex-1", e.inverted ? "text-default" : ""]
|
|
54
|
+
}, [(a = t.default) == null ? void 0 : a.call(t)])]);
|
|
55
|
+
};
|
|
56
|
+
}
|
|
57
|
+
});
|
|
58
|
+
export {
|
|
59
|
+
s as default
|
|
60
|
+
};
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
import { defineComponent as M, ref as d, watch as s, computed as w, createVNode as t, Fragment as V, createTextVNode as B } from "vue";
|
|
2
|
+
import { useRouteStore as D, useTheme as T, useI18n as K } from "@duxweb/dvha-core";
|
|
3
|
+
import { useMagicKeys as R, watchThrottled as j } from "@vueuse/core";
|
|
4
|
+
import { cloneDeep as E } from "lodash-es";
|
|
5
|
+
import { NTag as S, NButton as G } from "naive-ui";
|
|
6
|
+
import { Command as n } from "vue-command-palette";
|
|
7
|
+
import { useRouter as L } from "vue-router";
|
|
8
|
+
import "../../node_modules/@overlastic/vue/dist/index.js";
|
|
9
|
+
import "clsx";
|
|
10
|
+
import "jinrishici";
|
|
11
|
+
import "vee-validate";
|
|
12
|
+
import "@vee-validate/i18n";
|
|
13
|
+
import "@duxweb/dvha-naiveui";
|
|
14
|
+
import "../page404.js";
|
|
15
|
+
import { useUI as q } from "../../hooks/ui.js";
|
|
16
|
+
const te = /* @__PURE__ */ M({
|
|
17
|
+
name: "DuxMenuCmd",
|
|
18
|
+
setup() {
|
|
19
|
+
const {
|
|
20
|
+
cmdVisible: b,
|
|
21
|
+
setCmdVisible: c
|
|
22
|
+
} = q(), f = R(), C = f["Meta+K"], m = d(), i = d([]), p = L(), u = D(), {
|
|
23
|
+
setMode: g
|
|
24
|
+
} = T(), r = d(""), {
|
|
25
|
+
t: a
|
|
26
|
+
} = K(), x = d(), k = (e) => {
|
|
27
|
+
const l = u.routes.filter((o) => o.parent === e);
|
|
28
|
+
m.value = e, i.value = l;
|
|
29
|
+
}, N = () => {
|
|
30
|
+
c(!0);
|
|
31
|
+
}, z = () => {
|
|
32
|
+
c(!1);
|
|
33
|
+
}, I = (e) => {
|
|
34
|
+
e ? i.value = [...E(u.routes).filter((l) => {
|
|
35
|
+
var o;
|
|
36
|
+
return (o = l.label) == null ? void 0 : o.includes(e);
|
|
37
|
+
})] : i.value = u.routes.filter((l) => !l.parent);
|
|
38
|
+
};
|
|
39
|
+
s(b, (e) => {
|
|
40
|
+
e ? i.value = u.routes.filter((l) => !l.parent) : i.value = u.routes.filter((l) => !l.parent);
|
|
41
|
+
}), j(r, () => {
|
|
42
|
+
I(r.value);
|
|
43
|
+
}, {
|
|
44
|
+
throttle: 500
|
|
45
|
+
});
|
|
46
|
+
const y = () => {
|
|
47
|
+
const e = u.routes.find((l) => l.name === m.value);
|
|
48
|
+
k(e == null ? void 0 : e.parent);
|
|
49
|
+
};
|
|
50
|
+
s(C, (e) => {
|
|
51
|
+
e && N();
|
|
52
|
+
}), s(f.Escape, (e) => {
|
|
53
|
+
e && c(!1);
|
|
54
|
+
}), s(f.Backspace, (e) => {
|
|
55
|
+
e && r.value === "" && m.value && y();
|
|
56
|
+
}), s(x, (e) => {
|
|
57
|
+
e && e.focus();
|
|
58
|
+
});
|
|
59
|
+
const h = w(() => i.value.filter((e) => e.hidden === void 0 || e.hidden === !1)), v = (e) => t(n.Item, {
|
|
60
|
+
onSelect: e == null ? void 0 : e.onSelect
|
|
61
|
+
}, {
|
|
62
|
+
default: () => [t("div", {
|
|
63
|
+
class: "flex items-center justify-between flex-1"
|
|
64
|
+
}, [t("div", {
|
|
65
|
+
class: "flex items-center gap-2"
|
|
66
|
+
}, [t("div", {
|
|
67
|
+
class: ["size-4", e == null ? void 0 : e.icon]
|
|
68
|
+
}, null), t("div", null, [e == null ? void 0 : e.label])]), t("div", null, [(e == null ? void 0 : e.keyName) && t(S, {
|
|
69
|
+
size: "small"
|
|
70
|
+
}, {
|
|
71
|
+
default: () => [e == null ? void 0 : e.keyName]
|
|
72
|
+
})])])]
|
|
73
|
+
});
|
|
74
|
+
return () => t(n.Dialog, {
|
|
75
|
+
visible: b.value,
|
|
76
|
+
theme: "command-palette"
|
|
77
|
+
}, {
|
|
78
|
+
header: () => t("div", {
|
|
79
|
+
class: "relative"
|
|
80
|
+
}, [t("input", {
|
|
81
|
+
ref: x,
|
|
82
|
+
placeholder: a("common.search"),
|
|
83
|
+
onInput: (e) => {
|
|
84
|
+
r.value = e.target.value;
|
|
85
|
+
},
|
|
86
|
+
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"
|
|
87
|
+
}, null), t("span", {
|
|
88
|
+
class: "absolute inset-y-0 start-0 flex items-center ps-3"
|
|
89
|
+
}, [t("div", {
|
|
90
|
+
class: "i-tabler:search shrink-0 text-dimmed size-5",
|
|
91
|
+
"aria-hidden": "true"
|
|
92
|
+
}, null)]), t("span", {
|
|
93
|
+
class: "absolute inset-y-0 end-0 flex items-center gap-2 pe-3"
|
|
94
|
+
}, [t(S, {
|
|
95
|
+
size: "small"
|
|
96
|
+
}, {
|
|
97
|
+
default: () => [B("Esc")]
|
|
98
|
+
}), t(G, {
|
|
99
|
+
quaternary: !0,
|
|
100
|
+
circle: !0,
|
|
101
|
+
size: "small",
|
|
102
|
+
onClick: () => c(!1)
|
|
103
|
+
}, {
|
|
104
|
+
icon: () => t("div", {
|
|
105
|
+
class: "i-tabler:x size-5",
|
|
106
|
+
"aria-hidden": "true"
|
|
107
|
+
}, null)
|
|
108
|
+
})])]),
|
|
109
|
+
body: () => t(V, null, [h.value.length === 0 && r.value && t("div", {
|
|
110
|
+
class: "flex items-center justify-center h-20 border-t border-muted"
|
|
111
|
+
}, [a("common.empty")]), h.value.length > 0 && t(n.List, null, {
|
|
112
|
+
default: () => [t(n.Group, {
|
|
113
|
+
heading: a("common.menu")
|
|
114
|
+
}, {
|
|
115
|
+
default: () => {
|
|
116
|
+
var e;
|
|
117
|
+
return [(e = h.value) == null ? void 0 : e.map((l, o) => t(n.Item, {
|
|
118
|
+
key: o,
|
|
119
|
+
onSelect: () => {
|
|
120
|
+
l.path ? (p.push(l.path), z()) : k(l.name);
|
|
121
|
+
}
|
|
122
|
+
}, {
|
|
123
|
+
default: () => [t("div", {
|
|
124
|
+
class: l.path ? "i-tabler:link" : "i-tabler:folder"
|
|
125
|
+
}, null), l.label]
|
|
126
|
+
}))];
|
|
127
|
+
}
|
|
128
|
+
}), t(n.Separator, null, null), m.value ? t(v, {
|
|
129
|
+
icon: "i-tabler:arrow-left",
|
|
130
|
+
label: a("common.back"),
|
|
131
|
+
onSelect: y,
|
|
132
|
+
keyName: "Backspace"
|
|
133
|
+
}, null) : t(n.Group, {
|
|
134
|
+
heading: a("common.theme")
|
|
135
|
+
}, {
|
|
136
|
+
default: () => [t(v, {
|
|
137
|
+
icon: "i-tabler:moon",
|
|
138
|
+
label: a("common.dark"),
|
|
139
|
+
onSelect: () => {
|
|
140
|
+
g("dark");
|
|
141
|
+
}
|
|
142
|
+
}, null), t(v, {
|
|
143
|
+
icon: "i-tabler:sun",
|
|
144
|
+
label: a("common.light"),
|
|
145
|
+
onSelect: () => {
|
|
146
|
+
g("light");
|
|
147
|
+
}
|
|
148
|
+
}, null)]
|
|
149
|
+
})]
|
|
150
|
+
})])
|
|
151
|
+
});
|
|
152
|
+
}
|
|
153
|
+
});
|
|
154
|
+
export {
|
|
155
|
+
te as DuxMenuCmd
|
|
156
|
+
};
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
import { defineComponent as c, createVNode as e, createTextVNode as i } from "vue";
|
|
2
|
+
import { useManage as f, useI18n as v, DuxLogoIcon as x } from "@duxweb/dvha-core";
|
|
3
|
+
import { useNaiveMenu as g } from "@duxweb/dvha-naiveui";
|
|
4
|
+
import { NTag as n, NMenu as h } from "naive-ui";
|
|
5
|
+
import "vue-router";
|
|
6
|
+
import "../../node_modules/@overlastic/vue/dist/index.js";
|
|
7
|
+
import "clsx";
|
|
8
|
+
import "jinrishici";
|
|
9
|
+
import "lodash-es";
|
|
10
|
+
import "@vueuse/core";
|
|
11
|
+
import "vee-validate";
|
|
12
|
+
import "@vee-validate/i18n";
|
|
13
|
+
import b from "./avatar.js";
|
|
14
|
+
import a from "./button.js";
|
|
15
|
+
import "vue-command-palette";
|
|
16
|
+
import "../page404.js";
|
|
17
|
+
import { useUI as M } from "../../hooks/ui.js";
|
|
18
|
+
const W = /* @__PURE__ */ c({
|
|
19
|
+
name: "DuxMenuMain",
|
|
20
|
+
props: {
|
|
21
|
+
open: {
|
|
22
|
+
type: Boolean,
|
|
23
|
+
default: !1
|
|
24
|
+
}
|
|
25
|
+
},
|
|
26
|
+
setup(l) {
|
|
27
|
+
const {
|
|
28
|
+
options: r,
|
|
29
|
+
active: s
|
|
30
|
+
} = g({}), {
|
|
31
|
+
menuCollapsed: o,
|
|
32
|
+
setCmdVisible: p,
|
|
33
|
+
menuMobileCollapsed: t,
|
|
34
|
+
setMenuCollapsed: u
|
|
35
|
+
} = M(), {
|
|
36
|
+
config: d
|
|
37
|
+
} = f(), {
|
|
38
|
+
t: m
|
|
39
|
+
} = v();
|
|
40
|
+
return () => e("div", {
|
|
41
|
+
class: "flex flex-col h-screen"
|
|
42
|
+
}, [e("div", {
|
|
43
|
+
class: "h-13 px-2 hidden lg:flex justify-center items-center"
|
|
44
|
+
}, [e(a, {
|
|
45
|
+
onClick: () => u(!o.value),
|
|
46
|
+
open: l.open
|
|
47
|
+
}, {
|
|
48
|
+
icon: () => e("div", {
|
|
49
|
+
class: "bg-white dark:bg-primary-950 rounded-full p-2 shadow group-hover:shadow-lg"
|
|
50
|
+
}, [e(x, {
|
|
51
|
+
highlight: "fill-primary",
|
|
52
|
+
class: "size-4"
|
|
53
|
+
}, null)]),
|
|
54
|
+
default: () => e("div", null, [d.title])
|
|
55
|
+
})]), e("div", {
|
|
56
|
+
class: "px-2 py-1 hidden lg:block"
|
|
57
|
+
}, [e(a, {
|
|
58
|
+
open: l.open,
|
|
59
|
+
inverted: !0,
|
|
60
|
+
class: "relative py-1.5 px-3",
|
|
61
|
+
onClick: () => p(!0)
|
|
62
|
+
}, {
|
|
63
|
+
icon: () => e("div", {
|
|
64
|
+
class: "i-tabler:search size-4 icon-gradient"
|
|
65
|
+
}, null),
|
|
66
|
+
default: () => e("div", {
|
|
67
|
+
class: "text-muted text-sm"
|
|
68
|
+
}, [m("common.search"), !o.value && e("div", {
|
|
69
|
+
class: "flex items-center gap-1 absolute right-2.5 top-1.3"
|
|
70
|
+
}, [e(n, {
|
|
71
|
+
size: "small",
|
|
72
|
+
bordered: !1,
|
|
73
|
+
type: "primary"
|
|
74
|
+
}, {
|
|
75
|
+
default: () => [i("⌘")]
|
|
76
|
+
}), e(n, {
|
|
77
|
+
size: "small",
|
|
78
|
+
bordered: !1,
|
|
79
|
+
type: "primary"
|
|
80
|
+
}, {
|
|
81
|
+
default: () => [i("K")]
|
|
82
|
+
})])])
|
|
83
|
+
})]), e("div", {
|
|
84
|
+
class: ["flex-1 min-h-0", t.value ? "border-t border-muted" : ""]
|
|
85
|
+
}, [e(h, {
|
|
86
|
+
options: r.value,
|
|
87
|
+
value: s.value,
|
|
88
|
+
collapsed: o.value && !t.value,
|
|
89
|
+
indent: 20,
|
|
90
|
+
collapsedWidth: 60,
|
|
91
|
+
collapsedIconSize: 20
|
|
92
|
+
}, null)]), e("div", {
|
|
93
|
+
class: "flex-none hidden lg:flex flex-col items-center gap-2 p-2"
|
|
94
|
+
}, [e(b, {
|
|
95
|
+
open: l.open
|
|
96
|
+
}, null)])]);
|
|
97
|
+
}
|
|
98
|
+
});
|
|
99
|
+
export {
|
|
100
|
+
W as DuxMenuMain
|
|
101
|
+
};
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import { defineComponent as t, createVNode as e } from "vue";
|
|
2
|
+
import { NDrawer as p } from "naive-ui";
|
|
3
|
+
import "@duxweb/dvha-core";
|
|
4
|
+
import "vue-router";
|
|
5
|
+
import "../../node_modules/@overlastic/vue/dist/index.js";
|
|
6
|
+
import "clsx";
|
|
7
|
+
import "jinrishici";
|
|
8
|
+
import "lodash-es";
|
|
9
|
+
import "@vueuse/core";
|
|
10
|
+
import "vee-validate";
|
|
11
|
+
import "@vee-validate/i18n";
|
|
12
|
+
import "@duxweb/dvha-naiveui";
|
|
13
|
+
import "../page404.js";
|
|
14
|
+
import { useUI as m } from "../../hooks/ui.js";
|
|
15
|
+
import "vue-command-palette";
|
|
16
|
+
import { DuxMenuMain as i } from "./main.js";
|
|
17
|
+
const U = /* @__PURE__ */ t({
|
|
18
|
+
name: "DuxMobileMenu",
|
|
19
|
+
props: {},
|
|
20
|
+
setup(n) {
|
|
21
|
+
const {
|
|
22
|
+
menuMobileCollapsed: o
|
|
23
|
+
} = m();
|
|
24
|
+
return () => e(p, {
|
|
25
|
+
show: o.value,
|
|
26
|
+
onUpdateShow: (r) => o.value = r,
|
|
27
|
+
width: 250,
|
|
28
|
+
placement: "left"
|
|
29
|
+
}, {
|
|
30
|
+
default: () => [e(i, {
|
|
31
|
+
open: !0
|
|
32
|
+
}, null)]
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
});
|
|
36
|
+
export {
|
|
37
|
+
U as DuxMobileMenu
|
|
38
|
+
};
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { defineComponent as u, createVNode as d } from "vue";
|
|
2
|
+
import { NScrollbar as o } from "naive-ui";
|
|
3
|
+
const m = /* @__PURE__ */ u({
|
|
4
|
+
name: "DuxPage",
|
|
5
|
+
props: {
|
|
6
|
+
padding: {
|
|
7
|
+
type: Boolean,
|
|
8
|
+
default: !0
|
|
9
|
+
},
|
|
10
|
+
actions: {
|
|
11
|
+
type: Array,
|
|
12
|
+
default: () => []
|
|
13
|
+
},
|
|
14
|
+
card: {
|
|
15
|
+
type: Boolean,
|
|
16
|
+
default: !0
|
|
17
|
+
},
|
|
18
|
+
scrollbar: {
|
|
19
|
+
type: Boolean,
|
|
20
|
+
default: !0
|
|
21
|
+
}
|
|
22
|
+
},
|
|
23
|
+
setup(e, {
|
|
24
|
+
slots: a
|
|
25
|
+
}) {
|
|
26
|
+
return () => {
|
|
27
|
+
var n;
|
|
28
|
+
const r = e.card ? "bg-default dark:bg-muted rounded-md shadow-xs lg:dark:border lg:dark:border-muted" : "", t = e.card && e.padding ? "p-3" : "", l = e.scrollbar ? "" : "h-full";
|
|
29
|
+
return d("div", {
|
|
30
|
+
class: "h-full"
|
|
31
|
+
}, [e.scrollbar ? d(o, {
|
|
32
|
+
class: r,
|
|
33
|
+
contentClass: `${t} ${l}`
|
|
34
|
+
}, {
|
|
35
|
+
default: () => {
|
|
36
|
+
var c;
|
|
37
|
+
return [(c = a.default) == null ? void 0 : c.call(a)];
|
|
38
|
+
}
|
|
39
|
+
}) : d("div", {
|
|
40
|
+
class: `${r} ${t} ${l}`
|
|
41
|
+
}, [(n = a.default) == null ? void 0 : n.call(a)])]);
|
|
42
|
+
};
|
|
43
|
+
}
|
|
44
|
+
});
|
|
45
|
+
export {
|
|
46
|
+
m as DuxPage
|
|
47
|
+
};
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
import { defineComponent as i, createVNode as t, isVNode as c } from "vue";
|
|
2
|
+
import { useI18n as l } from "@duxweb/dvha-core";
|
|
3
|
+
import { NButton as p } from "naive-ui";
|
|
4
|
+
import { useRoute as a, useRouter as f } from "vue-router";
|
|
5
|
+
import { DuxDrawAuth as m } from "../components/draw/drawAuth.js";
|
|
6
|
+
import { DuxPageStatus as d } from "./pageStatus.js";
|
|
7
|
+
function h(e) {
|
|
8
|
+
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !c(e);
|
|
9
|
+
}
|
|
10
|
+
const N = /* @__PURE__ */ i({
|
|
11
|
+
name: "DuxPage403",
|
|
12
|
+
setup(e) {
|
|
13
|
+
const n = a(), u = f(), {
|
|
14
|
+
t: o
|
|
15
|
+
} = l();
|
|
16
|
+
function s() {
|
|
17
|
+
u.push({
|
|
18
|
+
path: n.path,
|
|
19
|
+
query: {
|
|
20
|
+
...n.query,
|
|
21
|
+
t: Date.now()
|
|
22
|
+
}
|
|
23
|
+
});
|
|
24
|
+
}
|
|
25
|
+
return () => t(d, {
|
|
26
|
+
title: o("pages.403.title"),
|
|
27
|
+
desc: o("pages.403.desc")
|
|
28
|
+
}, {
|
|
29
|
+
default: () => t("div", null, [t(m, null, null)]),
|
|
30
|
+
action: () => {
|
|
31
|
+
let r;
|
|
32
|
+
return t(p, {
|
|
33
|
+
onClick: s,
|
|
34
|
+
renderIcon: () => t("div", {
|
|
35
|
+
class: "n-icon i-tabler:refresh"
|
|
36
|
+
}, null)
|
|
37
|
+
}, h(r = o("components.button.refresh")) ? r : {
|
|
38
|
+
default: () => [r]
|
|
39
|
+
});
|
|
40
|
+
}
|
|
41
|
+
});
|
|
42
|
+
}
|
|
43
|
+
});
|
|
44
|
+
export {
|
|
45
|
+
N as DuxPage403
|
|
46
|
+
};
|