@duxweb/dvha-pro 1.1.21 → 1.1.23
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/cascaderPanel/cascaderPanel.cjs +1 -0
- package/dist/cjs/components/chart/echart.cjs +1 -1
- package/dist/cjs/components/dashboard/helloBig.cjs +1 -1
- package/dist/cjs/components/data/dynamicData.cjs +1 -1
- package/dist/cjs/components/data/selectModal.cjs +1 -1
- package/dist/cjs/components/designEditor/editor/setting.cjs +1 -1
- package/dist/cjs/components/designEditor/editor.cjs +1 -1
- package/dist/cjs/components/drawer/drawer.cjs +1 -1
- package/dist/cjs/components/flowEditor/components/setting.cjs +1 -1
- package/dist/cjs/components/form/drawerForm.cjs +1 -1
- package/dist/cjs/components/form/formItem.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/pageTabForm.cjs +1 -1
- package/dist/cjs/components/form/settingForm.cjs +1 -1
- package/dist/cjs/components/formEditor/components/imageUpload.cjs +1 -1
- package/dist/cjs/components/formEditor/editor.cjs +1 -1
- package/dist/cjs/components/layout/table.cjs +1 -1
- package/dist/cjs/components/layout/tools.cjs +1 -1
- package/dist/cjs/components/mapCoord/mapCoord.cjs +1 -0
- package/dist/cjs/components/media/media.cjs +1 -1
- package/dist/cjs/components/modal/modalTab.cjs +1 -1
- package/dist/cjs/components/panel/setting.cjs +1 -1
- package/dist/cjs/components/posterEditor/posterEditor.cjs +1 -1
- package/dist/cjs/components/select/selectCard.cjs +1 -1
- package/dist/cjs/components/spec/spec.cjs +1 -1
- package/dist/cjs/components/stats/realTime.cjs +1 -1
- package/dist/cjs/components/table/table.cjs +1 -1
- package/dist/cjs/components/textImageEditor/textImageEditor.cjs +1 -0
- package/dist/cjs/components/textImageEditor/textModal.cjs +1 -0
- 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/components/upload/video.cjs +1 -0
- package/dist/cjs/components/widget/connect.cjs +1 -1
- package/dist/cjs/dvha-pro.css +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/switch.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/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/menuApp.cjs +1 -1
- package/dist/cjs/pages/menu/mobile.cjs +1 -1
- package/dist/cjs/pages/menu/notice.cjs +1 -1
- package/dist/cjs/pages/page404.cjs +1 -1
- package/dist/cjs/pages/pageStatus.cjs +1 -1
- package/dist/cjs/theme/uno.css.cjs +26 -4
- package/dist/esm/component.js +21 -20
- package/dist/esm/components/cascaderPanel/cascaderPanel.js +378 -0
- package/dist/esm/components/chart/echart.js +1 -1
- package/dist/esm/components/dashboard/helloBig.js +3 -2
- package/dist/esm/components/data/dynamicData.js +49 -40
- package/dist/esm/components/data/selectModal.js +3 -3
- package/dist/esm/components/designEditor/editor/setting.js +2 -2
- package/dist/esm/components/designEditor/editor.js +3 -2
- package/dist/esm/components/drawer/drawer.js +22 -19
- package/dist/esm/components/flowEditor/components/setting.js +1 -1
- package/dist/esm/components/form/drawerForm.js +1 -1
- package/dist/esm/components/form/formItem.js +1 -1
- package/dist/esm/components/form/modalForm.js +1 -1
- package/dist/esm/components/form/pageForm.js +1 -1
- package/dist/esm/components/form/pageTabForm.js +1 -1
- package/dist/esm/components/form/settingForm.js +1 -1
- package/dist/esm/components/formEditor/components/imageUpload.js +1 -1
- package/dist/esm/components/formEditor/editor.js +1 -1
- package/dist/esm/components/layout/table.js +74 -56
- package/dist/esm/components/layout/tools.js +8 -8
- package/dist/esm/components/mapCoord/mapCoord.js +218 -0
- package/dist/esm/components/media/media.js +57 -32
- package/dist/esm/components/modal/modalTab.js +20 -14
- package/dist/esm/components/panel/setting.js +3 -2
- package/dist/esm/components/posterEditor/posterEditor.js +1 -1
- package/dist/esm/components/select/selectCard.js +3 -3
- package/dist/esm/components/spec/spec.js +142 -103
- package/dist/esm/components/stats/realTime.js +5 -4
- package/dist/esm/components/table/table.js +19 -19
- package/dist/esm/components/textImageEditor/textImageEditor.js +405 -0
- package/dist/esm/components/textImageEditor/textModal.js +77 -0
- package/dist/esm/components/upload/image.js +35 -34
- package/dist/esm/components/upload/manage/item.js +1 -1
- package/dist/esm/components/upload/manager.js +155 -138
- package/dist/esm/components/upload/video.js +340 -0
- package/dist/esm/components/widget/connect.js +3 -2
- package/dist/esm/dvha-pro.css +1 -1
- package/dist/esm/hooks/dialog.js +2 -2
- package/dist/esm/hooks/drawer.js +2 -2
- package/dist/esm/hooks/modal.js +2 -2
- package/dist/esm/hooks/table/image.js +2 -2
- package/dist/esm/hooks/table/media.js +2 -2
- package/dist/esm/hooks/table/switch.js +58 -26
- package/dist/esm/index.js +308 -296
- package/dist/esm/langs/en-US.json.js +1 -1
- package/dist/esm/langs/zh-CN.json.js +1 -1
- package/dist/esm/pages/authLayout.js +1 -1
- package/dist/esm/pages/login.js +2 -2
- package/dist/esm/pages/menu/avatar.js +1 -1
- package/dist/esm/pages/menu/button.js +1 -1
- package/dist/esm/pages/menu/menuApp.js +1 -1
- package/dist/esm/pages/menu/mobile.js +1 -1
- package/dist/esm/pages/menu/notice.js +1 -1
- package/dist/esm/pages/page404.js +1 -1
- package/dist/esm/pages/pageStatus.js +2 -2
- package/dist/esm/theme/uno.css.js +26 -4
- package/dist/types/components/cascaderPanel/cascaderPanel.d.ts +110 -0
- package/dist/types/components/cascaderPanel/index.d.ts +1 -0
- package/dist/types/components/data/dynamicData.d.ts +10 -0
- package/dist/types/components/data/index.d.ts +1 -1
- package/dist/types/components/data/selectModal.d.ts +2 -2
- package/dist/types/components/drawer/drawer.d.ts +1 -1
- package/dist/types/components/flowEditor/components/kvInput.d.ts +1 -1
- package/dist/types/components/flowEditor/components/nodeCard.d.ts +1 -1
- package/dist/types/components/form/drawerForm.d.ts +2 -2
- package/dist/types/components/form/formLayout.d.ts +2 -2
- package/dist/types/components/form/modalForm.d.ts +2 -2
- package/dist/types/components/index.d.ts +3 -0
- package/dist/types/components/level/level.d.ts +2 -2
- package/dist/types/components/mapCoord/index.d.ts +1 -0
- package/dist/types/components/mapCoord/mapCoord.d.ts +93 -0
- package/dist/types/components/media/media.d.ts +3 -32
- package/dist/types/components/modal/modalTab.d.ts +5 -5
- package/dist/types/components/select/checkboxTag.d.ts +2 -2
- package/dist/types/components/select/dateTag.d.ts +2 -2
- package/dist/types/components/select/radioTag.d.ts +2 -2
- package/dist/types/components/select/selectCard.d.ts +4 -4
- package/dist/types/components/spec/spec.d.ts +21 -0
- package/dist/types/components/table/table.d.ts +3 -3
- package/dist/types/components/textImageEditor/index.d.ts +2 -0
- package/dist/types/components/textImageEditor/textImageEditor.d.ts +56 -0
- package/dist/types/components/textImageEditor/textModal.d.ts +72 -0
- package/dist/types/components/textImageEditor/types.d.ts +19 -0
- package/dist/types/components/upload/index.d.ts +1 -0
- package/dist/types/components/upload/video.d.ts +126 -0
- package/dist/types/components/widget/index.d.ts +1 -0
- package/dist/types/hooks/table/column.d.ts +1 -1
- package/dist/types/hooks/table/switch.d.ts +1 -1
- package/dist/types/main.d.ts +5 -0
- package/package.json +3 -3
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useDisclosure as
|
|
3
|
-
import { NDrawer as
|
|
4
|
-
const
|
|
1
|
+
import { defineComponent as f, ref as s, defineAsyncComponent as h, createVNode as t, Suspense as w } from "vue";
|
|
2
|
+
import { useDisclosure as p } from "@overlastic/vue";
|
|
3
|
+
import { NDrawer as v, NSpin as W } from "naive-ui";
|
|
4
|
+
const y = /* @__PURE__ */ f({
|
|
5
5
|
name: "DuxDrawer",
|
|
6
6
|
props: {
|
|
7
7
|
title: String,
|
|
@@ -19,27 +19,30 @@ const w = /* @__PURE__ */ r({
|
|
|
19
19
|
},
|
|
20
20
|
setup(e) {
|
|
21
21
|
const {
|
|
22
|
-
visible:
|
|
22
|
+
visible: u,
|
|
23
23
|
confirm: o,
|
|
24
24
|
cancel: l,
|
|
25
|
-
vanish:
|
|
26
|
-
} =
|
|
25
|
+
vanish: r
|
|
26
|
+
} = p({
|
|
27
27
|
duration: 1e3
|
|
28
|
-
}), n = e?.
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
28
|
+
}), n = s(typeof window > "u" ? void 0 : window.innerWidth), d = () => n.value ? e?.maxWidth ? Math.min(e.maxWidth, n.value) : n.value : e?.maxWidth ?? 800, c = () => {
|
|
29
|
+
const a = e?.width || 400;
|
|
30
|
+
return typeof a == "number" && n.value ? Math.min(a, n.value) : a;
|
|
31
|
+
}, i = e?.componentProps || {};
|
|
32
|
+
i.title = e.title, i.onConfirm = o, i.onClose = l;
|
|
33
|
+
const m = typeof e.component == "function" ? h(e.component) : e.component;
|
|
34
|
+
return () => t(v, {
|
|
32
35
|
closeOnEsc: !1,
|
|
33
36
|
maskClosable: !1,
|
|
34
37
|
minWidth: 200,
|
|
35
|
-
maxWidth:
|
|
36
|
-
defaultWidth:
|
|
38
|
+
maxWidth: d(),
|
|
39
|
+
defaultWidth: c(),
|
|
37
40
|
resizable: !0,
|
|
38
41
|
placement: e.placement,
|
|
39
|
-
show:
|
|
42
|
+
show: u.value,
|
|
40
43
|
onUpdateShow: () => o(),
|
|
41
44
|
onAfterLeave: () => {
|
|
42
|
-
|
|
45
|
+
r();
|
|
43
46
|
},
|
|
44
47
|
onEsc: () => {
|
|
45
48
|
l();
|
|
@@ -48,9 +51,9 @@ const w = /* @__PURE__ */ r({
|
|
|
48
51
|
}, {
|
|
49
52
|
default: () => [t("div", {
|
|
50
53
|
class: "h-full"
|
|
51
|
-
}, [t(
|
|
52
|
-
default: () => t(
|
|
53
|
-
fallback: () => t(
|
|
54
|
+
}, [t(w, null, {
|
|
55
|
+
default: () => t(m, i, null),
|
|
56
|
+
fallback: () => t(W, {
|
|
54
57
|
show: !0,
|
|
55
58
|
class: "h-full"
|
|
56
59
|
}, {
|
|
@@ -63,5 +66,5 @@ const w = /* @__PURE__ */ r({
|
|
|
63
66
|
}
|
|
64
67
|
});
|
|
65
68
|
export {
|
|
66
|
-
|
|
69
|
+
y as default
|
|
67
70
|
};
|
|
@@ -6,8 +6,8 @@ import x from "lodash-es/cloneDeep";
|
|
|
6
6
|
import { useMessage as H, NScrollbar as L, NButton as c, NRadioGroup as W, NRadio as h } from "naive-ui";
|
|
7
7
|
import "vue-router";
|
|
8
8
|
import "@overlastic/vue";
|
|
9
|
-
import "vue-echarts";
|
|
10
9
|
import "@vueuse/core";
|
|
10
|
+
import "vue-echarts";
|
|
11
11
|
import "vue3-ace-editor";
|
|
12
12
|
import "ace-builds/src-noconflict/mode-vue";
|
|
13
13
|
import "ace-builds/src-noconflict/mode-javascript";
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { defineComponent as S, computed as v, toRef as C, createVNode as i, Fragment as F, mergeProps as x, isVNode as D } from "vue";
|
|
2
2
|
import { useI18n as j, useInvalidate as E, useExtendForm as N } from "@duxweb/dvha-core";
|
|
3
3
|
import { useMessage as O, NButton as p, NScrollbar as h } from "naive-ui";
|
|
4
|
+
import "@vueuse/core";
|
|
4
5
|
import "clsx";
|
|
5
6
|
import "vue-echarts";
|
|
6
7
|
import "vue-router";
|
|
@@ -9,7 +10,6 @@ import "dayjs";
|
|
|
9
10
|
import "lodash-es";
|
|
10
11
|
import "@tanstack/vue-query";
|
|
11
12
|
import "@duxweb/dvha-naiveui";
|
|
12
|
-
import "@vueuse/core";
|
|
13
13
|
import "pinia";
|
|
14
14
|
import "vue3-ace-editor";
|
|
15
15
|
import "ace-builds/src-noconflict/mode-vue";
|
|
@@ -59,7 +59,7 @@ const T = /* @__PURE__ */ h({
|
|
|
59
59
|
return typeof r == "number" && (r = `${r}px`), t.value !== "left" ? "auto" : r;
|
|
60
60
|
}), b = i(() => a.divider.value || t.value === "page");
|
|
61
61
|
return () => l("div", {
|
|
62
|
-
class: [t.value !== "top" ? "md:flex-row gap-
|
|
62
|
+
class: [t.value !== "top" ? "md:flex-row gap-4 lg:items-start" : "gap-1", b.value ? "py-6" : "", t.value === "setting" ? "md:justify-between md:items-start md:gap-4" : "", t.value === "page" ? "grid grid-cols-1 lg:grid-cols-4 px-4" : "flex flex-col"]
|
|
63
63
|
}, [e.label && l("div", {
|
|
64
64
|
class: [t.value === "left" ? "flex lg:items-center lg:pt-1.5" : "md:mb-1", t.value === "left" && a.labelAlign.value === "right" ? "justify-end" : ""],
|
|
65
65
|
style: {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { defineComponent as S, computed as b, toRef as C, createVNode as r, Fragment as v, isVNode as F } from "vue";
|
|
2
2
|
import { useI18n as x, useInvalidate as j, useExtendForm as E } from "@duxweb/dvha-core";
|
|
3
3
|
import { useMessage as O, NButton as n } from "naive-ui";
|
|
4
|
+
import "@vueuse/core";
|
|
4
5
|
import "clsx";
|
|
5
6
|
import "vue-echarts";
|
|
6
7
|
import "vue-router";
|
|
@@ -9,7 +10,6 @@ import "dayjs";
|
|
|
9
10
|
import "lodash-es";
|
|
10
11
|
import "@tanstack/vue-query";
|
|
11
12
|
import "@duxweb/dvha-naiveui";
|
|
12
|
-
import "@vueuse/core";
|
|
13
13
|
import "pinia";
|
|
14
14
|
import "vue3-ace-editor";
|
|
15
15
|
import "ace-builds/src-noconflict/mode-vue";
|
|
@@ -4,9 +4,9 @@ import { useMessage as v, NButton as p, NScrollbar as h } from "naive-ui";
|
|
|
4
4
|
import { useRouter as E } from "vue-router";
|
|
5
5
|
import "@overlastic/vue";
|
|
6
6
|
import { DuxCard as F } from "../card/card.js";
|
|
7
|
+
import "@vueuse/core";
|
|
7
8
|
import "clsx";
|
|
8
9
|
import "vue-echarts";
|
|
9
|
-
import "@vueuse/core";
|
|
10
10
|
import "vue3-ace-editor";
|
|
11
11
|
import "ace-builds/src-noconflict/mode-vue";
|
|
12
12
|
import "ace-builds/src-noconflict/mode-javascript";
|
|
@@ -4,9 +4,9 @@ import { useMessage as x, NTabs as S, NButton as n } from "naive-ui";
|
|
|
4
4
|
import { useRouter as h } from "vue-router";
|
|
5
5
|
import "@overlastic/vue";
|
|
6
6
|
import { DuxCard as T } from "../card/card.js";
|
|
7
|
+
import "@vueuse/core";
|
|
7
8
|
import "clsx";
|
|
8
9
|
import "vue-echarts";
|
|
9
|
-
import "@vueuse/core";
|
|
10
10
|
import "vue3-ace-editor";
|
|
11
11
|
import "ace-builds/src-noconflict/mode-vue";
|
|
12
12
|
import "ace-builds/src-noconflict/mode-javascript";
|
|
@@ -3,9 +3,9 @@ import { useI18n as g, useInvalidate as y, useExtendForm as x } from "@duxweb/dv
|
|
|
3
3
|
import { useMessage as b, NTabs as v } from "naive-ui";
|
|
4
4
|
import "@overlastic/vue";
|
|
5
5
|
import "vue-router";
|
|
6
|
+
import "@vueuse/core";
|
|
6
7
|
import "clsx";
|
|
7
8
|
import "vue-echarts";
|
|
8
|
-
import "@vueuse/core";
|
|
9
9
|
import "vue3-ace-editor";
|
|
10
10
|
import "ace-builds/src-noconflict/mode-vue";
|
|
11
11
|
import "ace-builds/src-noconflict/mode-javascript";
|
|
@@ -58,12 +58,12 @@ import { DuxFormEditorItem as c, DuxFormEditorRule as s } from "../base/base.js"
|
|
|
58
58
|
import { WidgetEditorSettingCard as f } from "../../designEditor/editor/setting.js";
|
|
59
59
|
import "mime";
|
|
60
60
|
import { DuxImageUpload as g } from "../../upload/image.js";
|
|
61
|
+
import "vue-draggable-plus";
|
|
61
62
|
import "@iconify-json/tabler/icons.json";
|
|
62
63
|
import "../../posterEditor/elements/index.js";
|
|
63
64
|
import "fabric";
|
|
64
65
|
import "../../schemaEditor/schemaEditor.js";
|
|
65
66
|
import "dayjs";
|
|
66
|
-
import "vue-draggable-plus";
|
|
67
67
|
import "@tanstack/vue-query";
|
|
68
68
|
import "pinia";
|
|
69
69
|
const v = /* @__PURE__ */ n({
|
|
@@ -3,9 +3,9 @@ import { useI18n as F } from "@duxweb/dvha-core";
|
|
|
3
3
|
import { NButton as a } from "naive-ui";
|
|
4
4
|
import "vue-router";
|
|
5
5
|
import "@overlastic/vue";
|
|
6
|
+
import "@vueuse/core";
|
|
6
7
|
import "clsx";
|
|
7
8
|
import "vue-echarts";
|
|
8
|
-
import "@vueuse/core";
|
|
9
9
|
import "vue3-ace-editor";
|
|
10
10
|
import "ace-builds/src-noconflict/mode-vue";
|
|
11
11
|
import "ace-builds/src-noconflict/mode-javascript";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { defineComponent as Re, toRef as O, computed as
|
|
1
|
+
import { defineComponent as Re, toRef as O, computed as u, reactive as A, ref as P, unref as Ce, createVNode as e, watch as F, nextTick as w, onMounted as Se, h as M, mergeProps as Te, toRaw as N } from "vue";
|
|
2
2
|
import { useI18n as je, useJsonSchema as I, useTabStore as ze } from "@duxweb/dvha-core";
|
|
3
3
|
import { useWindowSize as Oe } from "@vueuse/core";
|
|
4
4
|
import { cloneDeep as W, isEqual as Ae } from "lodash-es";
|
|
5
|
-
import { NButton as
|
|
5
|
+
import { NButton as s, NTabs as Pe, NTab as Fe, NPopselect as Ne, NTooltip as k, NProgress as Le, NPagination as De, NDrawer as K } from "naive-ui";
|
|
6
6
|
import { useAction as Be } from "../../hooks/action.js";
|
|
7
7
|
import "@overlastic/vue";
|
|
8
8
|
import "clsx";
|
|
@@ -131,13 +131,13 @@ const la = /* @__PURE__ */ Re({
|
|
|
131
131
|
slots: r,
|
|
132
132
|
expose: $
|
|
133
133
|
}) {
|
|
134
|
-
const
|
|
135
|
-
t:
|
|
134
|
+
const d = O(l, "filter", {}), J = O(l, "sorter", {}), g = u(() => l.filterReactive || {}), G = O(l, "columns", []), {
|
|
135
|
+
t: n
|
|
136
136
|
} = je(), {
|
|
137
137
|
renderAction: H
|
|
138
138
|
} = Be(), o = A({
|
|
139
|
-
...
|
|
140
|
-
}),
|
|
139
|
+
...d.value || {}
|
|
140
|
+
}), c = Me({
|
|
141
141
|
...l.hookTableProps,
|
|
142
142
|
path: l.path,
|
|
143
143
|
filters: o,
|
|
@@ -145,7 +145,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
145
145
|
columns: G,
|
|
146
146
|
pagination: l.pagination
|
|
147
147
|
});
|
|
148
|
-
$(
|
|
148
|
+
$(c);
|
|
149
149
|
const {
|
|
150
150
|
columns: L,
|
|
151
151
|
tablePagination: Q,
|
|
@@ -162,19 +162,19 @@ const la = /* @__PURE__ */ Re({
|
|
|
162
162
|
onExport: ie,
|
|
163
163
|
onExportRows: re,
|
|
164
164
|
onImport: oe
|
|
165
|
-
} =
|
|
165
|
+
} = c, se = u(() => L.value.filter((t) => "title" in t && "key" in t).map((t) => ({
|
|
166
166
|
label: t.title,
|
|
167
167
|
value: t.key
|
|
168
168
|
}))), {
|
|
169
169
|
width: p
|
|
170
|
-
} = Oe(), ne =
|
|
170
|
+
} = Oe(), ne = u(() => L.value.reduce((a, i) => a + (Number(i?.width) || Number(i?.minWidth) || 110), 0)), v = A({
|
|
171
171
|
show: !1
|
|
172
172
|
}), b = A({
|
|
173
173
|
show: !1
|
|
174
|
-
}), x = P(!1), ce =
|
|
174
|
+
}), x = P(!1), ce = u(() => {
|
|
175
175
|
const t = Ce(l.filterSchema);
|
|
176
176
|
return Array.isArray(t) ? t : [];
|
|
177
|
-
}), E =
|
|
177
|
+
}), E = u(() => ce.value.map((t, a) => {
|
|
178
178
|
const m = (Array.isArray(t) ? t : [t]).map((f, ye) => {
|
|
179
179
|
const {
|
|
180
180
|
label: we,
|
|
@@ -190,7 +190,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
190
190
|
key: `filter-row-${a}`,
|
|
191
191
|
nodes: m
|
|
192
192
|
};
|
|
193
|
-
})), ue =
|
|
193
|
+
})), ue = u(() => E.value.flatMap((t) => t.nodes.map((a) => ({
|
|
194
194
|
tag: Ee,
|
|
195
195
|
attrs: {
|
|
196
196
|
label: a.label
|
|
@@ -199,8 +199,8 @@ const la = /* @__PURE__ */ Re({
|
|
|
199
199
|
})))), {
|
|
200
200
|
render: de
|
|
201
201
|
} = I({
|
|
202
|
-
data:
|
|
203
|
-
}), R =
|
|
202
|
+
data: u(() => ue.value)
|
|
203
|
+
}), R = u(() => ({
|
|
204
204
|
import: !1,
|
|
205
205
|
export: !0,
|
|
206
206
|
refresh: !0,
|
|
@@ -212,21 +212,21 @@ const la = /* @__PURE__ */ Re({
|
|
|
212
212
|
return !Ae(a, i);
|
|
213
213
|
}, j = (t) => {
|
|
214
214
|
if (t) {
|
|
215
|
-
|
|
215
|
+
c.page?.value !== 1 && c.onUpdatePage?.(1);
|
|
216
216
|
return;
|
|
217
217
|
}
|
|
218
|
-
|
|
218
|
+
c.onRefresh?.();
|
|
219
219
|
}, y = () => {
|
|
220
220
|
const t = T(() => {
|
|
221
221
|
Object.keys(o).forEach((a) => {
|
|
222
222
|
delete o[a];
|
|
223
|
-
}), Object.assign(o, S(
|
|
223
|
+
}), Object.assign(o, S(d.value)), Object.assign(o, S(g.value));
|
|
224
224
|
});
|
|
225
225
|
j(t);
|
|
226
226
|
}, z = () => {
|
|
227
|
-
const t =
|
|
228
|
-
Object.keys(
|
|
229
|
-
i !== "tab" && delete
|
|
227
|
+
const t = d.value?.tab;
|
|
228
|
+
Object.keys(d.value || {}).forEach((i) => {
|
|
229
|
+
i !== "tab" && delete d.value[i];
|
|
230
230
|
});
|
|
231
231
|
const a = T(() => {
|
|
232
232
|
Object.keys(o).forEach((i) => {
|
|
@@ -234,7 +234,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
234
234
|
}), t !== void 0 && (o.tab = t), Object.assign(o, S(g.value));
|
|
235
235
|
});
|
|
236
236
|
j(a), C.value++;
|
|
237
|
-
}, fe =
|
|
237
|
+
}, fe = u(() => ({
|
|
238
238
|
tag: "div",
|
|
239
239
|
attrs: {
|
|
240
240
|
class: "flex flex-wrap gap-2 items-center w-full"
|
|
@@ -250,7 +250,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
250
250
|
class: "flex flex-wrap gap-2 flex-1"
|
|
251
251
|
},
|
|
252
252
|
children: [{
|
|
253
|
-
tag:
|
|
253
|
+
tag: s,
|
|
254
254
|
attrs: {
|
|
255
255
|
type: "primary",
|
|
256
256
|
secondary: !0,
|
|
@@ -260,10 +260,10 @@ const la = /* @__PURE__ */ Re({
|
|
|
260
260
|
icon: () => e("div", {
|
|
261
261
|
class: "i-tabler:search size-4"
|
|
262
262
|
}, null),
|
|
263
|
-
default: () =>
|
|
263
|
+
default: () => n("components.button.search")
|
|
264
264
|
}
|
|
265
265
|
}, {
|
|
266
|
-
tag:
|
|
266
|
+
tag: s,
|
|
267
267
|
attrs: {
|
|
268
268
|
secondary: !0,
|
|
269
269
|
onClick: z
|
|
@@ -272,11 +272,22 @@ const la = /* @__PURE__ */ Re({
|
|
|
272
272
|
icon: () => e("div", {
|
|
273
273
|
class: "i-tabler:arrow-back-up size-4"
|
|
274
274
|
}, null),
|
|
275
|
-
default: () =>
|
|
275
|
+
default: () => n("components.button.reset")
|
|
276
|
+
}
|
|
277
|
+
}, {
|
|
278
|
+
tag: s,
|
|
279
|
+
attrs: {
|
|
280
|
+
secondary: !0,
|
|
281
|
+
onClick: () => c.onRefresh?.()
|
|
282
|
+
},
|
|
283
|
+
slots: {
|
|
284
|
+
icon: () => e("div", {
|
|
285
|
+
class: "i-tabler:refresh size-4"
|
|
286
|
+
}, null)
|
|
276
287
|
}
|
|
277
288
|
}]
|
|
278
289
|
}]
|
|
279
|
-
})), me =
|
|
290
|
+
})), me = u(() => {
|
|
280
291
|
const t = E.value.map((a) => {
|
|
281
292
|
const i = a.nodes.length > 1;
|
|
282
293
|
return {
|
|
@@ -321,7 +332,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
321
332
|
data: me
|
|
322
333
|
}), be = () => e("div", {
|
|
323
334
|
class: ["flex gap-2"]
|
|
324
|
-
}, [r?.sideLeft && p.value < 1024 && e(
|
|
335
|
+
}, [r?.sideLeft && p.value < 1024 && e(s, {
|
|
325
336
|
class: "flex-none",
|
|
326
337
|
secondary: !0,
|
|
327
338
|
onClick: () => {
|
|
@@ -331,7 +342,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
331
342
|
icon: () => e("div", {
|
|
332
343
|
class: "i-tabler:layout-sidebar-inactive size-4"
|
|
333
344
|
}, null)
|
|
334
|
-
}), r?.sideRight && p.value < 1024 && e(
|
|
345
|
+
}), r?.sideRight && p.value < 1024 && e(s, {
|
|
335
346
|
class: "flex-none",
|
|
336
347
|
secondary: !0,
|
|
337
348
|
onClick: () => {
|
|
@@ -343,7 +354,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
343
354
|
}, null)
|
|
344
355
|
}), e("div", {
|
|
345
356
|
class: "flex-none lg:hidden"
|
|
346
|
-
}, [e(
|
|
357
|
+
}, [e(s, {
|
|
347
358
|
secondary: !0,
|
|
348
359
|
onClick: () => {
|
|
349
360
|
x.value = !x.value;
|
|
@@ -356,7 +367,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
356
367
|
class: ["flex gap-2 flex-row"]
|
|
357
368
|
}, [e("div", {
|
|
358
369
|
class: "flex lg:hidden"
|
|
359
|
-
}, [e(
|
|
370
|
+
}, [e(s, {
|
|
360
371
|
type: "primary",
|
|
361
372
|
secondary: !0,
|
|
362
373
|
onClick: y
|
|
@@ -366,7 +377,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
366
377
|
}, null)
|
|
367
378
|
})]), e("div", {
|
|
368
379
|
class: ["hidden lg:flex gap-2"]
|
|
369
|
-
}, [e(
|
|
380
|
+
}, [e(s, {
|
|
370
381
|
type: "primary",
|
|
371
382
|
secondary: !0,
|
|
372
383
|
onClick: y
|
|
@@ -374,15 +385,22 @@ const la = /* @__PURE__ */ Re({
|
|
|
374
385
|
icon: () => e("div", {
|
|
375
386
|
class: "i-tabler:search size-4"
|
|
376
387
|
}, null),
|
|
377
|
-
default: () =>
|
|
378
|
-
}), e(
|
|
388
|
+
default: () => n("components.button.search")
|
|
389
|
+
}), e(s, {
|
|
379
390
|
secondary: !0,
|
|
380
391
|
onClick: z
|
|
381
392
|
}, {
|
|
382
393
|
icon: () => e("div", {
|
|
383
394
|
class: "i-tabler:arrow-back-up size-4"
|
|
384
395
|
}, null),
|
|
385
|
-
default: () =>
|
|
396
|
+
default: () => n("components.button.reset")
|
|
397
|
+
}), e(s, {
|
|
398
|
+
secondary: !0,
|
|
399
|
+
onClick: () => c.onRefresh?.()
|
|
400
|
+
}, {
|
|
401
|
+
icon: () => e("div", {
|
|
402
|
+
class: "i-tabler:refresh size-4"
|
|
403
|
+
}, null)
|
|
386
404
|
})])]), U = (t) => e("div", {
|
|
387
405
|
class: "flex justify-between gap-2"
|
|
388
406
|
}, [be(), t ? he() : e("div", {
|
|
@@ -390,9 +408,9 @@ const la = /* @__PURE__ */ Re({
|
|
|
390
408
|
}, null)]);
|
|
391
409
|
F(() => l.tabs?.map((t) => t.value), () => {
|
|
392
410
|
const t = l.tabs?.map((a) => a.value) || [];
|
|
393
|
-
if (
|
|
411
|
+
if (d.value?.tab === void 0) {
|
|
394
412
|
const a = t[0];
|
|
395
|
-
a !== void 0 && (
|
|
413
|
+
a !== void 0 && (d.value.tab = a);
|
|
396
414
|
}
|
|
397
415
|
w(() => h.value?.syncBarPosition());
|
|
398
416
|
}, {
|
|
@@ -402,8 +420,8 @@ const la = /* @__PURE__ */ Re({
|
|
|
402
420
|
h.value?.syncBarPosition();
|
|
403
421
|
});
|
|
404
422
|
});
|
|
405
|
-
const q = ze(), ge = q.tabs.find((t) => t.path === q.current), xe =
|
|
406
|
-
const t = l.tabs?.map((i) => i.value) || [], a =
|
|
423
|
+
const q = ze(), ge = q.tabs.find((t) => t.path === q.current), xe = u(() => {
|
|
424
|
+
const t = l.tabs?.map((i) => i.value) || [], a = d.value?.tab;
|
|
407
425
|
return t.includes(a) ? a : t[0];
|
|
408
426
|
});
|
|
409
427
|
return Se(() => {
|
|
@@ -445,7 +463,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
445
463
|
"default-value": l.tabs?.[0]?.value || "",
|
|
446
464
|
value: xe.value,
|
|
447
465
|
onUpdateValue: (t) => {
|
|
448
|
-
|
|
466
|
+
d.value.tab = t, o.tab = t, w(() => h.value?.syncBarPosition());
|
|
449
467
|
}
|
|
450
468
|
}, {
|
|
451
469
|
default: () => [l.tabs?.map((t) => e(Fe, {
|
|
@@ -458,7 +476,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
458
476
|
type: p.value < 1024 ? "dropdown" : "button",
|
|
459
477
|
items: l.actions
|
|
460
478
|
})])]), r.filter ? r.filter({
|
|
461
|
-
filter:
|
|
479
|
+
filter: d.value,
|
|
462
480
|
filterReactive: g.value,
|
|
463
481
|
onSearch: y,
|
|
464
482
|
onReset: z
|
|
@@ -479,7 +497,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
479
497
|
}, [M(de)])]), U(!0)]), r?.header?.(), e("div", {
|
|
480
498
|
class: "flex-1 min-h-0"
|
|
481
499
|
}, [r?.default?.({
|
|
482
|
-
...
|
|
500
|
+
...c,
|
|
483
501
|
width: ne.value
|
|
484
502
|
})]), e("div", {
|
|
485
503
|
class: "flex justify-between"
|
|
@@ -496,7 +514,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
496
514
|
trigger: "click"
|
|
497
515
|
}, {
|
|
498
516
|
default: () => [e(k, null, {
|
|
499
|
-
trigger: () => e(
|
|
517
|
+
trigger: () => e(s, {
|
|
500
518
|
quaternary: !0,
|
|
501
519
|
circle: !0,
|
|
502
520
|
"icon-placement": "right"
|
|
@@ -505,10 +523,10 @@ const la = /* @__PURE__ */ Re({
|
|
|
505
523
|
class: "i-tabler:columns size-4"
|
|
506
524
|
}, null)
|
|
507
525
|
}),
|
|
508
|
-
default: () =>
|
|
526
|
+
default: () => n("components.list.columnSetting")
|
|
509
527
|
})]
|
|
510
528
|
}), R.value.export && e(k, null, {
|
|
511
|
-
trigger: () => e(
|
|
529
|
+
trigger: () => e(s, {
|
|
512
530
|
quaternary: !0,
|
|
513
531
|
circle: !0,
|
|
514
532
|
loading: te.value,
|
|
@@ -518,9 +536,9 @@ const la = /* @__PURE__ */ Re({
|
|
|
518
536
|
class: "i-tabler:database-export size-4"
|
|
519
537
|
}, null)
|
|
520
538
|
}),
|
|
521
|
-
default: () =>
|
|
539
|
+
default: () => n("components.button.export")
|
|
522
540
|
}), R.value.import && e(k, null, {
|
|
523
|
-
trigger: () => e(
|
|
541
|
+
trigger: () => e(s, {
|
|
524
542
|
quaternary: !0,
|
|
525
543
|
circle: !0,
|
|
526
544
|
loading: le.value,
|
|
@@ -530,9 +548,9 @@ const la = /* @__PURE__ */ Re({
|
|
|
530
548
|
class: "i-tabler:database-import size-4"
|
|
531
549
|
}, null)
|
|
532
550
|
}),
|
|
533
|
-
default: () =>
|
|
551
|
+
default: () => n("components.button.import")
|
|
534
552
|
}), R.value.refresh && e(k, null, {
|
|
535
|
-
trigger: () => e(
|
|
553
|
+
trigger: () => e(s, {
|
|
536
554
|
quaternary: !0,
|
|
537
555
|
circle: !0,
|
|
538
556
|
onClick: ee
|
|
@@ -551,16 +569,16 @@ const la = /* @__PURE__ */ Re({
|
|
|
551
569
|
class: "i-tabler:refresh size-4"
|
|
552
570
|
}, null)
|
|
553
571
|
}),
|
|
554
|
-
default: () =>
|
|
572
|
+
default: () => n("components.button.autoRefresh")
|
|
555
573
|
})]), e("div", null, [l.pagination && e(De, Te(Q.value, {
|
|
556
574
|
simple: p.value < 768
|
|
557
575
|
}), {
|
|
558
|
-
prefix: () => e("div", null, [
|
|
559
|
-
total:
|
|
576
|
+
prefix: () => e("div", null, [n("components.list.total", {
|
|
577
|
+
total: c.total.value || 0
|
|
560
578
|
})])
|
|
561
579
|
})])]), e(qe, {
|
|
562
|
-
isLoading:
|
|
563
|
-
onBatch:
|
|
580
|
+
isLoading: c.isBatching.value,
|
|
581
|
+
onBatch: c.onBatch,
|
|
564
582
|
selecteds: D.value.checkedRowKeys,
|
|
565
583
|
number: D.value.checkedRowKeys?.length || 0 || 0,
|
|
566
584
|
group: [[{
|
|
@@ -569,7 +587,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
569
587
|
Y?.([]);
|
|
570
588
|
}
|
|
571
589
|
}], [{
|
|
572
|
-
label:
|
|
590
|
+
label: n("components.button.export"),
|
|
573
591
|
icon: "i-tabler:file-export",
|
|
574
592
|
loading: ae.value,
|
|
575
593
|
onClick: re
|
|
@@ -581,7 +599,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
581
599
|
placement: "left"
|
|
582
600
|
}, {
|
|
583
601
|
default: () => [e(V, {
|
|
584
|
-
title: l.sideLeftTitle ||
|
|
602
|
+
title: l.sideLeftTitle || n("components.button.sideLeft"),
|
|
585
603
|
onClose: () => v.show = !1,
|
|
586
604
|
scrollbar: !1
|
|
587
605
|
}, {
|
|
@@ -594,7 +612,7 @@ const la = /* @__PURE__ */ Re({
|
|
|
594
612
|
placement: "right"
|
|
595
613
|
}, {
|
|
596
614
|
default: () => [e(V, {
|
|
597
|
-
title: l.sideRightTitle ||
|
|
615
|
+
title: l.sideRightTitle || n("components.button.sideRight"),
|
|
598
616
|
onClose: () => b.show = !1,
|
|
599
617
|
scrollbar: !1
|
|
600
618
|
}, {
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { defineComponent as u, computed as a, createVNode as o, Transition as d, Fragment as c } from "vue";
|
|
2
2
|
import { useI18n as f } from "@duxweb/dvha-core";
|
|
3
|
-
import { NButton as
|
|
3
|
+
import { NButton as m, NDropdown as y } from "naive-ui";
|
|
4
4
|
import "vue-router";
|
|
5
5
|
import { useDialog as g } from "../../hooks/dialog.js";
|
|
6
6
|
import "@overlastic/vue";
|
|
7
|
+
import "@vueuse/core";
|
|
7
8
|
import "clsx";
|
|
8
9
|
import "vue-echarts";
|
|
9
|
-
import "@vueuse/core";
|
|
10
10
|
import "vue3-ace-editor";
|
|
11
11
|
import "ace-builds/src-noconflict/mode-vue";
|
|
12
12
|
import "ace-builds/src-noconflict/mode-javascript";
|
|
@@ -93,7 +93,7 @@ const Ft = /* @__PURE__ */ u({
|
|
|
93
93
|
setup(t) {
|
|
94
94
|
const {
|
|
95
95
|
t: e
|
|
96
|
-
} = f(), i = a(() => t.group ? t.group : [t.options]),
|
|
96
|
+
} = f(), i = a(() => t.group ? t.group : [t.options]), p = a(() => t.number && t.number > 0), l = g();
|
|
97
97
|
return () => o("div", {
|
|
98
98
|
class: "absolute bottom-0 left-0 right-0 pointer-events-none"
|
|
99
99
|
}, [o(d, {
|
|
@@ -106,8 +106,8 @@ const Ft = /* @__PURE__ */ u({
|
|
|
106
106
|
leaveFromClass: "transform translate-y-0 opacity-100",
|
|
107
107
|
leaveToClass: "transform translate-y-full opacity-0"
|
|
108
108
|
}, {
|
|
109
|
-
default: () => [
|
|
110
|
-
class: "flex h-10 px-1 justify-between
|
|
109
|
+
default: () => [p.value ? o("div", {
|
|
110
|
+
class: "flex h-10 px-1 justify-between md:justify-center gap-2 pointer-events-auto"
|
|
111
111
|
}, [i.value?.map((s, n) => o("div", {
|
|
112
112
|
class: "h-10 mt-1 bg-default rounded px-4 py-1 shadow flex items-center gap-4"
|
|
113
113
|
}, [n === i.value.length - 1 && o(c, null, [o("span", {
|
|
@@ -116,10 +116,10 @@ const Ft = /* @__PURE__ */ u({
|
|
|
116
116
|
num: t.number || 0
|
|
117
117
|
})]), o("div", {
|
|
118
118
|
class: "w-px h-4 bg-elevated"
|
|
119
|
-
}, null)]), s?.map((r) => o(
|
|
119
|
+
}, null)]), s?.map((r) => o(m, {
|
|
120
120
|
text: !0,
|
|
121
121
|
onClick: () => {
|
|
122
|
-
r.onClick ? r.onClick?.(t.selecteds) : r.key &&
|
|
122
|
+
r.onClick ? r.onClick?.(t.selecteds) : r.key && l.confirm({
|
|
123
123
|
title: e("components.list.batchTitle"),
|
|
124
124
|
content: e("components.list.batchContent")
|
|
125
125
|
}).then(() => {
|
|
@@ -138,7 +138,7 @@ const Ft = /* @__PURE__ */ u({
|
|
|
138
138
|
})), n === i.value.length - 1 && t.dropdown && t.dropdown.length > 0 && o(y, {
|
|
139
139
|
options: t.dropdown
|
|
140
140
|
}, {
|
|
141
|
-
default: () => [o(
|
|
141
|
+
default: () => [o(m, {
|
|
142
142
|
text: !0
|
|
143
143
|
}, {
|
|
144
144
|
icon: () => o("div", {
|