@done-coding/admin-core 0.8.1-alpha.0 → 0.8.2-alpha.0
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/es/components/form/FormSubmitBtn.vue.mjs +6 -8
- package/es/components/form/FormSubmitPanel.vue.mjs +2 -2
- package/es/components/form/FormSubmitPanel.vue2.mjs +40 -45
- package/es/components/panel/PanelEditSwitch.vue.mjs +1 -1
- package/es/components/panel/PanelEditSwitch.vue2.mjs +14 -12
- package/es/components/panel/PanelItem.vue.mjs +33 -34
- package/es/components/panel/PanelMain.vue.mjs +2 -2
- package/es/components/panel/PanelMain.vue2.mjs +55 -60
- package/es/style.css +1 -1
- package/package.json +2 -2
- package/types/components/form/FormSubmitBtn.vue.d.ts +2 -2
- package/types/components/form/FormSubmitPanel.vue.d.ts +7 -22
- package/types/components/form/types.d.ts +1 -1
- package/types/components/panel/PanelItem.vue.d.ts +2 -2
- package/types/components/panel/PanelMain.vue.d.ts +5 -2
- package/types/components/panel/types.d.ts +7 -5
|
@@ -8,7 +8,7 @@ const w = /* @__PURE__ */ p({
|
|
|
8
8
|
props: {
|
|
9
9
|
size: {},
|
|
10
10
|
disabled: { type: Boolean },
|
|
11
|
-
type: {},
|
|
11
|
+
type: { default: "primary" },
|
|
12
12
|
icon: {},
|
|
13
13
|
nativeType: {},
|
|
14
14
|
loadingIcon: {},
|
|
@@ -30,17 +30,15 @@ const w = /* @__PURE__ */ p({
|
|
|
30
30
|
},
|
|
31
31
|
emits: ["success", "fail"],
|
|
32
32
|
setup(a, { emit: s }) {
|
|
33
|
-
const e = a, i = s, o = u(!1),
|
|
33
|
+
const e = a, i = s, o = u(!1), r = f(
|
|
34
34
|
() => k(e, ["formMainInstance", "submitText", "submitFn"])
|
|
35
|
-
),
|
|
35
|
+
), l = async () => {
|
|
36
36
|
o.value = !0;
|
|
37
37
|
const { formMainInstance: n } = e;
|
|
38
38
|
try {
|
|
39
39
|
await n.validate();
|
|
40
40
|
const t = n.stringify();
|
|
41
|
-
await e.submitFn(t), i("success",
|
|
42
|
-
stringifyData: t
|
|
43
|
-
});
|
|
41
|
+
await e.submitFn(t), i("success", t);
|
|
44
42
|
} catch (t) {
|
|
45
43
|
i("fail", t);
|
|
46
44
|
} finally {
|
|
@@ -49,9 +47,9 @@ const w = /* @__PURE__ */ p({
|
|
|
49
47
|
};
|
|
50
48
|
return (n, t) => {
|
|
51
49
|
const c = m;
|
|
52
|
-
return y(), d(c, B(b(
|
|
50
|
+
return y(), d(c, B(b(r), {
|
|
53
51
|
loading: o.value,
|
|
54
|
-
onClick:
|
|
52
|
+
onClick: l
|
|
55
53
|
}), {
|
|
56
54
|
default: g(() => [
|
|
57
55
|
x(_(a.submitText), 1)
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./FormSubmitPanel.vue2.mjs";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../_virtual/_plugin-vue_export-helper.mjs";
|
|
4
|
-
const
|
|
4
|
+
const a = /* @__PURE__ */ t(o, [["__scopeId", "data-v-d71ece49"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
a as default
|
|
7
7
|
};
|
|
@@ -1,14 +1,14 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as V, useAttrs as W, shallowRef as E, ref as R, computed as l, watch as B, openBlock as o, createElementBlock as T, normalizeClass as j, createVNode as g, mergeProps as m, unref as r, createSlots as z, renderList as G, withCtx as s, renderSlot as c, normalizeProps as H, guardReactiveProps as M, createBlock as u, resolveDynamicComponent as I, createElementVNode as L, createTextVNode as P, toDisplayString as h, createCommentVNode as x } from "vue";
|
|
2
2
|
import { ElAffix as O } from "element-plus";
|
|
3
3
|
import q from "./FormMain.vue.mjs";
|
|
4
4
|
import J from "./FormSubmitBtn.vue.mjs";
|
|
5
|
-
import
|
|
5
|
+
import D from "../display/ActionBtn.vue.mjs";
|
|
6
6
|
import { parseFormData as K, generateFormData as Q } from "./utils.mjs";
|
|
7
|
-
const U = { class: "form-submit-panel-operation-inner" }, nt = /* @__PURE__ */
|
|
7
|
+
const U = { class: "form-submit-panel-operation-inner" }, nt = /* @__PURE__ */ V({
|
|
8
8
|
name: "FormSubmitPanel",
|
|
9
9
|
inheritAttrs: !1,
|
|
10
10
|
__name: "FormSubmitPanel",
|
|
11
|
-
props:
|
|
11
|
+
props: {
|
|
12
12
|
list: {},
|
|
13
13
|
layout: { default: () => ({
|
|
14
14
|
span: 24
|
|
@@ -24,81 +24,76 @@ const U = { class: "form-submit-panel-operation-inner" }, nt = /* @__PURE__ */ M
|
|
|
24
24
|
resetBtn: {},
|
|
25
25
|
operationPosition: { default: "bottom-center" },
|
|
26
26
|
operationAffix: { type: [Boolean, Object], default: !1 }
|
|
27
|
-
},
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
stringifyData: a.stringifyData,
|
|
38
|
-
parseData: r.value
|
|
39
|
-
}), F = (a) => n("fail", a);
|
|
40
|
-
return E(
|
|
41
|
-
[() => e.stringifyData, () => e.list],
|
|
27
|
+
},
|
|
28
|
+
emits: ["cancel", "fail", "success", "parseDataChange"],
|
|
29
|
+
setup(t, { emit: v }) {
|
|
30
|
+
const a = t, n = v, k = W(), f = E(), i = R({}), C = (e) => e, S = l(() => f.value), w = l(() => a.operationAffix ? O : "div"), A = l(() => a.operationAffix ? typeof a.operationAffix == "object" ? a.operationAffix : { position: "bottom" } : {}), d = () => a.stringifyData ? K(a.stringifyData, a.list) : Q(a.list), b = () => n("cancel"), p = () => {
|
|
31
|
+
i.value = d();
|
|
32
|
+
}, F = (e) => n("success", e), $ = (e) => n("fail", e);
|
|
33
|
+
return B(i, (e) => {
|
|
34
|
+
n("parseDataChange", e);
|
|
35
|
+
}), B(
|
|
36
|
+
[() => a.stringifyData, () => a.list],
|
|
42
37
|
() => {
|
|
43
|
-
|
|
38
|
+
i.value = d();
|
|
44
39
|
},
|
|
45
40
|
{
|
|
46
41
|
immediate: !0
|
|
47
42
|
}
|
|
48
|
-
), (
|
|
49
|
-
class:
|
|
43
|
+
), (e, X) => (o(), T("div", {
|
|
44
|
+
class: j(["form-submit-panel", `form-submit-panel_${t.operationPosition}`])
|
|
50
45
|
}, [
|
|
51
|
-
|
|
46
|
+
g(q, m({
|
|
52
47
|
ref_key: "formMain",
|
|
53
|
-
ref:
|
|
48
|
+
ref: f,
|
|
54
49
|
class: "form-submit-panel-form",
|
|
55
50
|
list: t.list,
|
|
56
|
-
data: r
|
|
51
|
+
data: C(r(i)),
|
|
57
52
|
"row-gutter": t.rowGutter
|
|
58
|
-
},
|
|
53
|
+
}, r(k), {
|
|
59
54
|
layout: t.layout,
|
|
60
55
|
labelPosition: t.labelPosition,
|
|
61
56
|
labelWidth: t.labelWidth
|
|
62
|
-
}),
|
|
63
|
-
|
|
57
|
+
}), z({ _: 2 }, [
|
|
58
|
+
G(t.list, (y) => ({
|
|
64
59
|
name: y.key,
|
|
65
|
-
fn:
|
|
66
|
-
|
|
60
|
+
fn: s((N) => [
|
|
61
|
+
c(e.$slots, y.key, H(M(N)), void 0, !0)
|
|
67
62
|
])
|
|
68
63
|
}))
|
|
69
64
|
]), 1040, ["list", "data", "row-gutter", "layout", "labelPosition", "labelWidth"]),
|
|
70
|
-
(
|
|
71
|
-
default:
|
|
65
|
+
(o(), u(I(w.value), m(A.value, { class: "form-submit-panel-operation" }), {
|
|
66
|
+
default: s(() => [
|
|
72
67
|
L("div", U, [
|
|
73
|
-
|
|
74
|
-
t.cancelBtn ? (
|
|
68
|
+
c(e.$slots, "cancelBtn", { cancel: b }, () => [
|
|
69
|
+
t.cancelBtn ? (o(), u(r(D), {
|
|
75
70
|
key: 0,
|
|
76
71
|
onClick: b
|
|
77
72
|
}, {
|
|
78
|
-
default:
|
|
79
|
-
|
|
73
|
+
default: s(() => [
|
|
74
|
+
P(h(t.cancelBtn), 1)
|
|
80
75
|
]),
|
|
81
76
|
_: 1
|
|
82
|
-
})) :
|
|
77
|
+
})) : x("", !0)
|
|
83
78
|
], !0),
|
|
84
|
-
|
|
85
|
-
t.resetBtn ? (
|
|
79
|
+
c(e.$slots, "resetBtn", { reset: p }, () => [
|
|
80
|
+
t.resetBtn ? (o(), u(r(D), {
|
|
86
81
|
key: 0,
|
|
87
82
|
type: "warning",
|
|
88
83
|
onClick: p
|
|
89
84
|
}, {
|
|
90
|
-
default:
|
|
91
|
-
|
|
85
|
+
default: s(() => [
|
|
86
|
+
P(h(t.resetBtn), 1)
|
|
92
87
|
]),
|
|
93
88
|
_: 1
|
|
94
|
-
})) :
|
|
89
|
+
})) : x("", !0)
|
|
95
90
|
], !0),
|
|
96
|
-
|
|
91
|
+
g(J, m(t.submitBtnProps, {
|
|
97
92
|
"submit-fn": t.submitFn,
|
|
98
93
|
"submit-text": t.submitText,
|
|
99
94
|
"form-main-instance": S.value,
|
|
100
|
-
onSuccess:
|
|
101
|
-
onFail:
|
|
95
|
+
onSuccess: F,
|
|
96
|
+
onFail: $
|
|
102
97
|
}), null, 16, ["submit-fn", "submit-text", "form-main-instance"])
|
|
103
98
|
])
|
|
104
99
|
]),
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import t from "./PanelEditSwitch.vue2.mjs";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import o from "../../_virtual/_plugin-vue_export-helper.mjs";
|
|
4
|
-
const i = /* @__PURE__ */ o(t, [["__scopeId", "data-v-
|
|
4
|
+
const i = /* @__PURE__ */ o(t, [["__scopeId", "data-v-7bb14fd1"]]);
|
|
5
5
|
export {
|
|
6
6
|
i as default
|
|
7
7
|
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { ElButton as C } from "element-plus/es";
|
|
2
2
|
import "element-plus/es/components/base/style/css";
|
|
3
3
|
import "element-plus/es/components/button/style/css";
|
|
4
|
-
import { defineComponent as
|
|
4
|
+
import { defineComponent as h, useModel as w, ref as F, computed as B, watch as c, openBlock as r, createElementBlock as u, createBlock as d, withCtx as E, createTextVNode as P, createCommentVNode as M, renderSlot as l, Fragment as $, unref as o, mergeModels as m } from "vue";
|
|
5
5
|
import N from "lodash/cloneDeep";
|
|
6
6
|
import T from "../form/FormSubmitPanel.vue.mjs";
|
|
7
|
-
const V = { class: "panel-edit-switch" }, A = /* @__PURE__ */
|
|
7
|
+
const V = { class: "panel-edit-switch" }, A = /* @__PURE__ */ h({
|
|
8
8
|
name: "PanelEditSwitch",
|
|
9
9
|
__name: "PanelEditSwitch",
|
|
10
10
|
props: /* @__PURE__ */ m({
|
|
@@ -18,9 +18,9 @@ const V = { class: "panel-edit-switch" }, A = /* @__PURE__ */ w({
|
|
|
18
18
|
}),
|
|
19
19
|
emits: /* @__PURE__ */ m(["submitSuccess"], ["update:editing"]),
|
|
20
20
|
setup(i, { emit: f }) {
|
|
21
|
-
const n = i, g = f, e =
|
|
21
|
+
const n = i, g = f, e = w(i, "editing"), a = F(
|
|
22
22
|
{}
|
|
23
|
-
),
|
|
23
|
+
), p = B(() => [n.config.editorConfig]), y = (t) => t, b = () => {
|
|
24
24
|
e.value = !0;
|
|
25
25
|
}, k = () => {
|
|
26
26
|
e.value = !1;
|
|
@@ -31,13 +31,13 @@ const V = { class: "panel-edit-switch" }, A = /* @__PURE__ */ w({
|
|
|
31
31
|
}, D = (t) => {
|
|
32
32
|
e.value = !1, g("submitSuccess", t);
|
|
33
33
|
};
|
|
34
|
-
return
|
|
34
|
+
return c(
|
|
35
35
|
e,
|
|
36
36
|
(t, s) => {
|
|
37
37
|
t && !s && (a.value = N(n.data));
|
|
38
38
|
},
|
|
39
39
|
{ immediate: !0 }
|
|
40
|
-
),
|
|
40
|
+
), c(
|
|
41
41
|
() => n.editable,
|
|
42
42
|
(t) => {
|
|
43
43
|
t || (e.value = !1);
|
|
@@ -47,8 +47,8 @@ const V = { class: "panel-edit-switch" }, A = /* @__PURE__ */ w({
|
|
|
47
47
|
}
|
|
48
48
|
), (t, s) => {
|
|
49
49
|
const S = C;
|
|
50
|
-
return r(),
|
|
51
|
-
i.editable && !e.value ? (r(),
|
|
50
|
+
return r(), u("div", V, [
|
|
51
|
+
i.editable && !e.value ? (r(), d(S, {
|
|
52
52
|
key: 0,
|
|
53
53
|
class: "panel-edit-switch-edit-btn",
|
|
54
54
|
type: "primary",
|
|
@@ -61,14 +61,16 @@ const V = { class: "panel-edit-switch" }, A = /* @__PURE__ */ w({
|
|
|
61
61
|
])]),
|
|
62
62
|
_: 1
|
|
63
63
|
})) : M("", !0),
|
|
64
|
-
e.value ? (r(),
|
|
64
|
+
e.value ? (r(), u($, { key: 2 }, [
|
|
65
65
|
i.config.editorRender ? l(t.$slots, "editor", {
|
|
66
66
|
key: 0,
|
|
67
67
|
stringifyDraftData: o(a)
|
|
68
|
-
}, void 0, !0) : i.config.editorConfig ? (r(),
|
|
68
|
+
}, void 0, !0) : i.config.editorConfig ? (r(), d(o(T), {
|
|
69
69
|
key: 1,
|
|
70
|
-
list: o(
|
|
71
|
-
"stringify-data":
|
|
70
|
+
list: o(p),
|
|
71
|
+
"stringify-data": y(o(a)),
|
|
72
|
+
"cancel-btn": "取消",
|
|
73
|
+
"operation-position": "bottom-right",
|
|
72
74
|
"submit-fn": v,
|
|
73
75
|
onCancel: k,
|
|
74
76
|
onSuccess: D
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import { defineComponent as P, useModel as h, computed as
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
const w = { key: 0 }, j = /* @__PURE__ */ P({
|
|
1
|
+
import { defineComponent as P, useModel as h, computed as r, openBlock as c, createBlock as u, withCtx as l, resolveDynamicComponent as f, normalizeProps as g, guardReactiveProps as E, createElementBlock as x, toDisplayString as I, mergeProps as M, mergeModels as m } from "vue";
|
|
2
|
+
import R from "./PanelEditSwitch.vue.mjs";
|
|
3
|
+
const w = { key: 0 }, U = /* @__PURE__ */ P({
|
|
5
4
|
name: "PanelItem",
|
|
6
5
|
__name: "PanelItem",
|
|
7
|
-
props: /* @__PURE__ */
|
|
6
|
+
props: /* @__PURE__ */ m({
|
|
8
7
|
data: {},
|
|
9
8
|
config: {},
|
|
10
9
|
refreshFn: { type: Function }
|
|
@@ -12,19 +11,19 @@ const w = { key: 0 }, j = /* @__PURE__ */ P({
|
|
|
12
11
|
editing: { type: Boolean, default: !1 },
|
|
13
12
|
editingModifiers: {}
|
|
14
13
|
}),
|
|
15
|
-
emits: /* @__PURE__ */
|
|
16
|
-
setup(o, { emit:
|
|
17
|
-
const t = o,
|
|
14
|
+
emits: /* @__PURE__ */ m(["submitSuccess"], ["update:editing"]),
|
|
15
|
+
setup(o, { emit: v }) {
|
|
16
|
+
const t = o, b = v, a = h(o, "editing"), d = (e) => {
|
|
18
17
|
const { config: n } = t;
|
|
19
18
|
return {
|
|
20
19
|
data: e,
|
|
21
20
|
value: e[n.key],
|
|
22
21
|
config: n
|
|
23
22
|
};
|
|
24
|
-
},
|
|
23
|
+
}, p = r(() => d(t.data)), y = r(() => {
|
|
25
24
|
const { editable: e } = t.config;
|
|
26
|
-
return typeof e == "function" ? !!e(
|
|
27
|
-
}),
|
|
25
|
+
return typeof e == "function" ? !!e(p.value) : !!e;
|
|
26
|
+
}), S = (e) => {
|
|
28
27
|
const {
|
|
29
28
|
config: { key: n, label: i }
|
|
30
29
|
} = t;
|
|
@@ -36,49 +35,49 @@ const w = { key: 0 }, j = /* @__PURE__ */ P({
|
|
|
36
35
|
layoutHide: !0,
|
|
37
36
|
layout: { span: 24 }
|
|
38
37
|
};
|
|
39
|
-
},
|
|
38
|
+
}, k = r(() => {
|
|
40
39
|
const {
|
|
41
40
|
config: { editorConfig: e, ...n }
|
|
42
41
|
} = t;
|
|
43
42
|
return {
|
|
44
43
|
...n,
|
|
45
|
-
|
|
44
|
+
editorConfig: S(e)
|
|
46
45
|
};
|
|
47
|
-
}),
|
|
46
|
+
}), B = () => {
|
|
48
47
|
var e;
|
|
49
|
-
return (e = t.refreshFn) == null ? void 0 : e.call(t,
|
|
50
|
-
|
|
51
|
-
parseData: f.value && s.value.editorConfig ? R(t.data, [s.value.editorConfig]) : t.data
|
|
52
|
-
});
|
|
53
|
-
}, F = () => {
|
|
48
|
+
return (e = t.refreshFn) == null ? void 0 : e.call(t, t.data);
|
|
49
|
+
}, C = () => {
|
|
54
50
|
a.value = !1;
|
|
55
|
-
},
|
|
56
|
-
...
|
|
51
|
+
}, s = (e) => ({
|
|
52
|
+
...d(e),
|
|
57
53
|
editing: a.value,
|
|
58
|
-
refresh:
|
|
59
|
-
closeEdit:
|
|
60
|
-
}),
|
|
61
|
-
|
|
54
|
+
refresh: B,
|
|
55
|
+
closeEdit: C
|
|
56
|
+
}), F = (e) => {
|
|
57
|
+
b("submitSuccess", {
|
|
58
|
+
...t.data,
|
|
59
|
+
...e
|
|
60
|
+
});
|
|
62
61
|
};
|
|
63
|
-
return (e, n) => (
|
|
62
|
+
return (e, n) => (c(), u(R, {
|
|
64
63
|
editing: a.value,
|
|
65
64
|
"onUpdate:editing": n[0] || (n[0] = (i) => a.value = i),
|
|
66
|
-
config:
|
|
67
|
-
editable:
|
|
65
|
+
config: k.value,
|
|
66
|
+
editable: y.value,
|
|
68
67
|
data: o.data,
|
|
69
68
|
"submit-fn": o.config.submitFn,
|
|
70
|
-
onSubmitSuccess:
|
|
69
|
+
onSubmitSuccess: F
|
|
71
70
|
}, {
|
|
72
|
-
default:
|
|
73
|
-
o.config.render === void 0 ? (
|
|
71
|
+
default: l(({ stringifyDraftData: i }) => [
|
|
72
|
+
o.config.render === void 0 ? (c(), x("span", w, I(s(i).value), 1)) : (c(), u(f(o.config.render), g(M({ key: 1 }, s(i))), null, 16))
|
|
74
73
|
]),
|
|
75
|
-
editor:
|
|
76
|
-
(
|
|
74
|
+
editor: l(({ stringifyDraftData: i }) => [
|
|
75
|
+
(c(), u(f(o.config.editorRender), g(E(s(i))), null, 16))
|
|
77
76
|
]),
|
|
78
77
|
_: 1
|
|
79
78
|
}, 8, ["editing", "config", "editable", "data", "submit-fn"]));
|
|
80
79
|
}
|
|
81
80
|
});
|
|
82
81
|
export {
|
|
83
|
-
|
|
82
|
+
U as default
|
|
84
83
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./PanelMain.vue2.mjs";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../../_virtual/_plugin-vue_export-helper.mjs";
|
|
4
|
-
const
|
|
4
|
+
const p = /* @__PURE__ */ t(o, [["__scopeId", "data-v-25951dc8"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
p as default
|
|
7
7
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
|
-
import { ElRow as E, ElCol as
|
|
1
|
+
import { ElRow as E, ElCol as M } from "element-plus/es";
|
|
2
2
|
import "element-plus/es/components/base/style/css";
|
|
3
3
|
import "element-plus/es/components/row/style/css";
|
|
4
4
|
import "element-plus/es/components/col/style/css";
|
|
5
|
-
import { defineComponent as
|
|
6
|
-
import
|
|
7
|
-
import { ElCard as
|
|
5
|
+
import { defineComponent as x, useCssVars as F, unref as i, ref as L, computed as c, watch as j, openBlock as l, createBlock as u, withCtx as d, createElementBlock as P, Fragment as D, renderList as G, withDirectives as H, mergeProps as O, resolveDynamicComponent as R, normalizeClass as U, createVNode as V, vShow as W } from "vue";
|
|
6
|
+
import $ from "./PanelItem.vue.mjs";
|
|
7
|
+
import { ElCard as f } from "element-plus";
|
|
8
8
|
import { resolveFormLayout as y } from "../form/utils.mjs";
|
|
9
|
-
const
|
|
9
|
+
const Q = /* @__PURE__ */ x({
|
|
10
10
|
name: "PanelMain",
|
|
11
11
|
__name: "PanelMain",
|
|
12
12
|
props: {
|
|
@@ -17,78 +17,73 @@ const J = /* @__PURE__ */ M({
|
|
|
17
17
|
itemCard: { type: [Boolean, Object], default: () => ({ lastMarginBottom: "8px" }) },
|
|
18
18
|
refreshFn: {}
|
|
19
19
|
},
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
emits: ["submitSuccess"],
|
|
21
|
+
setup(s, { emit: C }) {
|
|
22
|
+
F((e) => ({
|
|
23
|
+
v39ccf6bc: i(_)
|
|
23
24
|
}));
|
|
24
|
-
const a =
|
|
25
|
-
() =>
|
|
26
|
-
|
|
27
|
-
return o - d;
|
|
28
|
-
})
|
|
29
|
-
), f = c(() => a.itemCard ? g : "span"), _ = c(
|
|
30
|
-
() => `panel-main-item-col-wrap_${f.value === g ? "card" : "span"}`
|
|
31
|
-
), h = c(
|
|
25
|
+
const a = s, h = C, n = L({}), p = c(() => a.itemCard ? f : "span"), k = c(
|
|
26
|
+
() => `panel-main-item-col-wrap_${p.value === f ? "card" : "span"}`
|
|
27
|
+
), _ = c(
|
|
32
28
|
() => typeof a.itemCard == "object" && a.itemCard.lastMarginBottom ? a.itemCard.lastMarginBottom : 0
|
|
33
|
-
),
|
|
34
|
-
const { hide:
|
|
35
|
-
if (typeof
|
|
36
|
-
const
|
|
29
|
+
), v = (e) => {
|
|
30
|
+
const { hide: t } = e;
|
|
31
|
+
if (typeof t == "function") {
|
|
32
|
+
const r = {
|
|
37
33
|
data: a.data,
|
|
38
|
-
value: a.data[
|
|
39
|
-
config:
|
|
34
|
+
value: a.data[e.key],
|
|
35
|
+
config: e
|
|
40
36
|
};
|
|
41
|
-
return !!
|
|
37
|
+
return !!t(r);
|
|
42
38
|
}
|
|
43
|
-
return !!
|
|
44
|
-
},
|
|
39
|
+
return !!t;
|
|
40
|
+
}, b = (e) => ({
|
|
45
41
|
...y(a.layout),
|
|
46
|
-
...y(
|
|
47
|
-
}),
|
|
48
|
-
|
|
49
|
-
},
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
}) => {
|
|
53
|
-
|
|
54
|
-
(o = a.refreshFn) == null || o.call(a, t, e);
|
|
42
|
+
...y(e)
|
|
43
|
+
}), g = (e, t) => {
|
|
44
|
+
n.value = {}, t && (n.value[e] = t);
|
|
45
|
+
}, w = (e) => (t) => {
|
|
46
|
+
var r;
|
|
47
|
+
return (r = a.refreshFn) == null ? void 0 : r.call(a, t, e);
|
|
48
|
+
}, S = (e, t) => {
|
|
49
|
+
h("submitSuccess", t, e);
|
|
55
50
|
};
|
|
56
|
-
return
|
|
51
|
+
return j(
|
|
57
52
|
() => a.list,
|
|
58
|
-
(
|
|
59
|
-
const
|
|
60
|
-
Object.keys(
|
|
61
|
-
|
|
53
|
+
(e) => {
|
|
54
|
+
const t = e.map((r) => r.key);
|
|
55
|
+
Object.keys(n.value).forEach((r) => {
|
|
56
|
+
t.includes(r) || delete n.value[r];
|
|
62
57
|
});
|
|
63
58
|
},
|
|
64
59
|
{ immediate: !0 }
|
|
65
|
-
), (
|
|
66
|
-
const
|
|
67
|
-
return
|
|
68
|
-
default:
|
|
69
|
-
(
|
|
70
|
-
key:
|
|
71
|
-
}, { ref_for: !0 },
|
|
72
|
-
default:
|
|
73
|
-
(
|
|
74
|
-
class:
|
|
60
|
+
), (e, t) => {
|
|
61
|
+
const r = M, B = E;
|
|
62
|
+
return l(), u(B, { gutter: s.rowGutter }, {
|
|
63
|
+
default: d(() => [
|
|
64
|
+
(l(!0), P(D, null, G(s.list, (o) => H((l(), u(r, O({
|
|
65
|
+
key: o.key
|
|
66
|
+
}, { ref_for: !0 }, b(o.layout), { class: "panel-main-item-col" }), {
|
|
67
|
+
default: d(() => [
|
|
68
|
+
(l(), u(R(i(p)), {
|
|
69
|
+
class: U(i(k))
|
|
75
70
|
}, {
|
|
76
|
-
default:
|
|
77
|
-
|
|
78
|
-
data:
|
|
79
|
-
config:
|
|
80
|
-
editing: i(
|
|
81
|
-
"refresh-fn":
|
|
82
|
-
"onUpdate:editing": (
|
|
83
|
-
onSubmitSuccess:
|
|
84
|
-
}, null, 8, ["data", "config", "editing", "onUpdate:editing"])
|
|
71
|
+
default: d(() => [
|
|
72
|
+
V($, {
|
|
73
|
+
data: s.data,
|
|
74
|
+
config: o,
|
|
75
|
+
editing: i(n)[o.key] ?? !1,
|
|
76
|
+
"refresh-fn": w(o.key),
|
|
77
|
+
"onUpdate:editing": (m) => g(o.key, m),
|
|
78
|
+
onSubmitSuccess: (m) => S(o.key, m)
|
|
79
|
+
}, null, 8, ["data", "config", "editing", "refresh-fn", "onUpdate:editing", "onSubmitSuccess"])
|
|
85
80
|
]),
|
|
86
81
|
_: 2
|
|
87
82
|
}, 1032, ["class"]))
|
|
88
83
|
]),
|
|
89
84
|
_: 2
|
|
90
85
|
}, 1040)), [
|
|
91
|
-
[
|
|
86
|
+
[W, !v(o)]
|
|
92
87
|
])), 128))
|
|
93
88
|
]),
|
|
94
89
|
_: 1
|
|
@@ -97,5 +92,5 @@ const J = /* @__PURE__ */ M({
|
|
|
97
92
|
}
|
|
98
93
|
});
|
|
99
94
|
export {
|
|
100
|
-
|
|
95
|
+
Q as default
|
|
101
96
|
};
|
package/es/style.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.confirm-dialog .content[data-v-8a29e4c8]{overflow-x:hidden;overflow-y:auto;max-height:calc(100vh - 200px)}.confirm-dialog .btn[data-v-8a29e4c8]{width:150px;height:40px;border-radius:4px}.confirm-dialog .main[data-v-8a29e4c8]{position:relative;text-align:center}.confirm-dialog .main .close-box[data-v-8a29e4c8]{position:absolute;top:0;right:0;cursor:pointer;z-index:2}.confirm-dialog .main .shim[data-v-8a29e4c8]{position:relative;z-index:1}.confirm-dialog .main .shim .title[data-v-8a29e4c8]{font-size:18px;font-weight:500}.confirm-dialog .main .shim .content[data-v-8a29e4c8]{font-size:16px;margin-top:15px}.confirm-dialog .main .shim .footer[data-v-8a29e4c8]{display:flex;justify-content:center;align-items:center;padding-top:5px}.confirm-dialog .main .shim .footer>.btn[data-v-8a29e4c8]:not(:last-child){margin-right:30px}.confirm-dialog .main .shim .footer[reverse=true][data-v-8a29e4c8]{flex-direction:row-reverse}.confirm-dialog .main .shim .footer[reverse=true]>.btn[data-v-8a29e4c8]:not(:last-child){margin-right:0;margin-left:30px}.confirm-dialog .el-dialog__header,.confirm-dialog .el-dialog__body{padding:0;background-color:transparent}.action-confirm__title[data-v-88119b35]{font-weight:600;margin-bottom:6px}.action-confirm__content[data-v-88119b35]{margin-bottom:12px;color:var(--el-text-color-regular)}.action-confirm__actions[data-v-88119b35]{display:flex;justify-content:flex-end;gap:8px}.form-item-tip[data-v-0dd66b41]{text-align:left;line-height:1.5;font-size:12px}.form-item-label-hide[data-v-0dd66b41] .el-form-item__label-wrap{display:none}.form-submit-panel[data-v-90ab06ac]{display:flex;flex-direction:column}.form-submit-panel .form-submit-panel-form[data-v-90ab06ac]{order:1}.form-submit-panel .form-submit-panel-operation[data-v-90ab06ac]{order:2}.form-submit-panel .form-submit-panel-operation-inner[data-v-90ab06ac]{display:flex;align-items:center;gap:8px;padding:10px 12px}.form-submit-panel .el-affix--fixed .form-submit-panel-operation-inner[data-v-90ab06ac]{background-color:var(--el-bg-color)}.form-submit-panel_bottom-center .form-submit-panel-operation-inner[data-v-90ab06ac],.form-submit-panel_bottom-right .form-submit-panel-operation-inner[data-v-90ab06ac]{border-top:1px solid var(--el-border-color-light);border-bottom-left-radius:var(--el-border-radius-base);border-bottom-right-radius:var(--el-border-radius-base)}.form-submit-panel_bottom-center .form-submit-panel-operation-inner[data-v-90ab06ac]{justify-content:center}.form-submit-panel_bottom-right .form-submit-panel-operation-inner[data-v-90ab06ac]{justify-content:flex-end}.form-submit-panel_top-right .form-submit-panel-operation[data-v-90ab06ac]{order:0}.form-submit-panel_top-right .form-submit-panel-operation-inner[data-v-90ab06ac]{justify-content:flex-end;border-bottom:1px solid var(--el-border-color-light);border-top-left-radius:var(--el-border-radius-base);border-top-right-radius:var(--el-border-radius-base)}.panel-edit-switch[data-v-5b38b68e]{position:relative}.panel-edit-switch:hover .panel-edit-switch-edit-btn[data-v-5b38b68e]{display:block}.panel-edit-switch-edit-btn[data-v-5b38b68e]{position:absolute;top:0;right:0;z-index:1;display:none}.panel-edit-switch-actions[data-v-5b38b68e]{display:flex;justify-content:flex-end;gap:8px;margin-top:8px}.form-search_show[data-v-d240f220]{margin-bottom:10px}.form-search .btn-box[data-v-d240f220]{display:flex;align-items:center;gap:8px;justify-content:flex-end}.form-search .btn-box-expand-icon[data-v-d240f220]{margin-right:2px}.form-search[data-v-d240f220] .el-col{padding-left:14px}.form-verify-image[data-v-a4baf877] .el-input__suffix-inner *{margin:0}.form-verify-image-suffix[data-v-a4baf877]{position:absolute;height:100%;border-radius:var(--el-input-border-radius, var(--el-border-radius-base));top:50%;transform:translateY(-50%);overflow:hidden;cursor:pointer}.form-verify-image-suffix-main[data-v-a4baf877]{position:absolute;left:0;top:0;width:100%;height:100%;background-color:#f4f4f4}.tabs-main-bar[data-v-d6937179]{position:relative;display:flex;align-items:center}.tabs-main-bar-item[data-v-d6937179]{border:none;background:transparent;cursor:pointer;color:var(--el-text-color-regular);transition:background .2s,color .2s,box-shadow .2s}.tabs-main-bar-indicator[data-v-d6937179]{position:absolute;left:0;background:var(--el-color-primary);transition:transform .2s,width .2s}.tabs-main-bar--l1 .tabs-main-bar-item[data-v-d6937179]{font-size:16px}.tabs-main-bar--l2 .tabs-main-bar-item[data-v-d6937179]{font-size:14px}.tabs-main-bar--l3 .tabs-main-bar-item[data-v-d6937179],.tabs-main-bar--l4 .tabs-main-bar-item[data-v-d6937179]{font-size:12px}.tabs-main-bar--variant-card[data-v-d6937179]{position:relative;overflow:hidden;gap:2px}.tabs-main-bar--variant-card .tabs-main-bar-item[data-v-d6937179]{position:relative;padding:8px 20px;line-height:1.4;border:1px solid transparent;border-bottom:0;border-radius:6px 6px 0 0}.tabs-main-bar--variant-card .tabs-main-bar-item[data-v-d6937179]:hover:not(.tabs-main-bar-item_active){color:var(--el-color-primary)}.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]{color:var(--el-color-primary);border-color:var(--el-border-color-light)}.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]:before,.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]:after{content:"";position:absolute;bottom:0;width:100vw;height:1px;background:var(--el-border-color-light)}.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]:before{right:100%}.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]:after{left:100%}.tabs-main-bar--variant-indicator .tabs-main-bar-item[data-v-d6937179]{padding:8px 16px}.tabs-main-bar--variant-indicator .tabs-main-bar-item_active[data-v-d6937179]{color:var(--el-color-primary)}.tabs-main-bar--variant-indicator .tabs-main-bar-indicator[data-v-d6937179]{bottom:0;height:2px}.tabs-main-bar--variant-indicator-compact .tabs-main-bar-item[data-v-d6937179]{padding:6px 10px}.tabs-main-bar--variant-indicator-compact .tabs-main-bar-item_active[data-v-d6937179]{color:var(--el-color-primary)}.tabs-main-bar--variant-indicator-compact .tabs-main-bar-indicator[data-v-d6937179]{bottom:0;height:1px}.tabs-main-bar--variant-plain .tabs-main-bar-item[data-v-d6937179]{padding:4px 8px}.tabs-main-bar--variant-plain .tabs-main-bar-item_active[data-v-d6937179]{color:var(--el-color-primary);font-weight:600}.app-breadcrumb[data-v-2f677890]{display:flex;align-items:center;justify-content:flex-start}.app-body[data-v-265945fd]{transition-duration:.3s;transition-property:padding;transition-timing-function:linear;min-height:100vh}.app-body-shim[data-v-265945fd]{width:100%;--app-viewport-max-height: var(--ba2eb370)}.app-footer[data-v-393d9768]{transition-duration:.3s;transition-property:height;transition-timing-function:linear;overflow:hidden;width:100%;box-shadow:-5px 0 5px #0000001a}.app-footer-shim[data-v-393d9768]{width:100%;height:100%;padding:0 20px}.app-header[data-v-ef3cc8a6]{transition-duration:.3s;transition-property:height;transition-timing-function:linear;overflow:hidden;position:fixed;left:0;top:0;width:100%;box-shadow:5px 0 5px #0000001a;z-index:1}.app-header-module[data-v-ef3cc8a6]{display:flex;flex:1;height:100%;overflow-x:auto}.app-header-module-item[data-v-ef3cc8a6]{display:flex;justify-content:center;align-items:center;padding:0 20px;white-space:nowrap;height:100%;color:var(--v3dfae5bc)}.app-header-module-item[data-v-ef3cc8a6]:hover,.app-header-module-item_active[data-v-ef3cc8a6]{color:var(--v158cd0d2)}.app-header-module-item_active[data-v-ef3cc8a6]{position:relative}.app-header-module-item_active[data-v-ef3cc8a6]:before{content:"";position:absolute;left:50%;top:0;width:100%;height:3px;background-color:var(--v158cd0d2);transform:translate(-50%)}.app-header-shim[data-v-ef3cc8a6]{width:100%;height:100%;display:flex;align-items:center;justify-content:space-between;padding:0 20px;font-size:18px;font-weight:700}.app-header-module-item__icon[data-v-ef3cc8a6]{margin-right:8px}.app-header-userInfo[data-v-ef3cc8a6]{padding-left:80px}.app-header-userInfo__theme-switch[data-v-ef3cc8a6]{margin-right:12px}.app-sidebar[data-v-37ff5e0c]{transition-duration:.3s;transition-property:width;transition-timing-function:linear;position:fixed;left:0;top:0;height:100%;box-shadow:0 5px 5px #0000001a;overflow:visible;z-index:var(--ce9ef212)}.app-sidebar-top[data-v-37ff5e0c]{position:absolute;left:0;right:0;top:0;overflow:hidden}.app-sidebar-bottom[data-v-37ff5e0c]{position:absolute;left:0;right:0;bottom:0;overflow:hidden}.app-sidebar-shim[data-v-37ff5e0c]{position:absolute;left:0;right:0;top:var(--v309db2c2);bottom:var(--v2189b8a1);overflow-x:hidden;overflow-y:auto;--el-menu-border-color: transparent;-webkit-user-select:none;user-select:none}.app-sidebar-toggle[data-v-37ff5e0c]{position:absolute;left:100%;top:50%;transform:translate(-50%,-50%);cursor:pointer;width:22px;height:22px;border-radius:50%;background-color:var(--v65908f82);color:var(--v42a24063);border:1px solid var(--v42a24063);box-shadow:0 1px 2px #0000000f;display:flex;align-items:center;justify-content:center;font-size:12px;z-index:1;isolation:isolate;transition:color .3s,border-color .3s,box-shadow .3s}.app-sidebar-toggle[data-v-37ff5e0c]:before{content:"";position:absolute;top:-3px;right:-3px;bottom:-3px;left:-3px;border-radius:50%;background-color:var(--v42a24063);opacity:.18;z-index:-1;pointer-events:none;transition:opacity .3s,inset .3s}.app-sidebar-toggle[data-v-37ff5e0c]:active,.app-sidebar-toggle[data-v-37ff5e0c]:focus,.app-sidebar-toggle[data-v-37ff5e0c]:hover{box-shadow:0 2px 6px #0000001f}.app-sidebar-toggle[data-v-37ff5e0c]:active:before,.app-sidebar-toggle[data-v-37ff5e0c]:focus:before,.app-sidebar-toggle[data-v-37ff5e0c]:hover:before{opacity:.32;top:-5px;right:-5px;bottom:-5px;left:-5px}.app-sidebar-toggle-icon[data-v-37ff5e0c]{transition:transform .3s}.app-layout[data-v-6924f8b7]{position:relative}.app-layout_noLogin[data-v-6924f8b7] .app-body,.app-layout_noLogin[data-v-6924f8b7] .app-sidebar,.app-layout_noLogin[data-v-6924f8b7] .app-header,.app-layout_noLogin[data-v-6924f8b7] .app-footer{transition:none!important}.app-page-shim[data-v-fda19616]{--app-viewport-max-height: var(--v54888f0e)}[data-v-1f8a1089] .auto-refresh-label{display:flex;font-size:13px;color:var(--el-text-color-regular);margin-bottom:8px}.auto-refresh-group-icon--rotating[data-v-9cac8b09]{animation:auto-refresh-rotating-9cac8b09 1s linear infinite}@keyframes auto-refresh-rotating-9cac8b09{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.table-toolbar[data-v-22ae8fa7]{display:flex;justify-content:space-between;align-items:center;padding-bottom:8px;gap:20px}.table-toolbar-left[data-v-22ae8fa7],.table-toolbar-right[data-v-22ae8fa7]{display:flex;align-items:center;gap:10px}.table-toolbar-switch-view[data-v-22ae8fa7]{--el-switch-off-color: var(--el-color-primary);--el-switch-on-color: var(--el-color-warning)}.data-list-view[data-v-da38bea6]{width:100%}.data-list-view-empty[data-v-da38bea6]{display:flex;justify-content:center;align-items:center;width:100%;min-height:60px}.table-main-pagination[data-v-05684b89]{margin-top:10px;display:flex;justify-content:flex-end}.list-page[data-v-d70424b6]{min-height:var(--v9299b0d4)}.list-page-header[data-v-d70424b6],.list-page-operation[data-v-d70424b6]{margin-bottom:10px}.list-page[data-v-d70424b6] .el-loading-mask{left:-10px;top:-10px;right:-10px;bottom:-10px}.panel-main-item-col:not(:last-of-type) .panel-main-item-col-wrap_card[data-v-5cd9d7e4]{margin-bottom:var(--v855b420c)}
|
|
1
|
+
.confirm-dialog .content[data-v-8a29e4c8]{overflow-x:hidden;overflow-y:auto;max-height:calc(100vh - 200px)}.confirm-dialog .btn[data-v-8a29e4c8]{width:150px;height:40px;border-radius:4px}.confirm-dialog .main[data-v-8a29e4c8]{position:relative;text-align:center}.confirm-dialog .main .close-box[data-v-8a29e4c8]{position:absolute;top:0;right:0;cursor:pointer;z-index:2}.confirm-dialog .main .shim[data-v-8a29e4c8]{position:relative;z-index:1}.confirm-dialog .main .shim .title[data-v-8a29e4c8]{font-size:18px;font-weight:500}.confirm-dialog .main .shim .content[data-v-8a29e4c8]{font-size:16px;margin-top:15px}.confirm-dialog .main .shim .footer[data-v-8a29e4c8]{display:flex;justify-content:center;align-items:center;padding-top:5px}.confirm-dialog .main .shim .footer>.btn[data-v-8a29e4c8]:not(:last-child){margin-right:30px}.confirm-dialog .main .shim .footer[reverse=true][data-v-8a29e4c8]{flex-direction:row-reverse}.confirm-dialog .main .shim .footer[reverse=true]>.btn[data-v-8a29e4c8]:not(:last-child){margin-right:0;margin-left:30px}.confirm-dialog .el-dialog__header,.confirm-dialog .el-dialog__body{padding:0;background-color:transparent}.action-confirm__title[data-v-88119b35]{font-weight:600;margin-bottom:6px}.action-confirm__content[data-v-88119b35]{margin-bottom:12px;color:var(--el-text-color-regular)}.action-confirm__actions[data-v-88119b35]{display:flex;justify-content:flex-end;gap:8px}.form-item-tip[data-v-0dd66b41]{text-align:left;line-height:1.5;font-size:12px}.form-item-label-hide[data-v-0dd66b41] .el-form-item__label-wrap{display:none}.form-submit-panel[data-v-d71ece49]{display:flex;flex-direction:column}.form-submit-panel .form-submit-panel-form[data-v-d71ece49]{order:1}.form-submit-panel .form-submit-panel-operation[data-v-d71ece49]{order:2}.form-submit-panel .form-submit-panel-operation-inner[data-v-d71ece49]{display:flex;align-items:center;gap:8px;padding:10px 12px}.form-submit-panel .el-affix--fixed .form-submit-panel-operation-inner[data-v-d71ece49]{background-color:var(--el-bg-color)}.form-submit-panel_bottom-center .form-submit-panel-operation-inner[data-v-d71ece49],.form-submit-panel_bottom-right .form-submit-panel-operation-inner[data-v-d71ece49]{border-top:1px solid var(--el-border-color-light);border-bottom-left-radius:var(--el-border-radius-base);border-bottom-right-radius:var(--el-border-radius-base)}.form-submit-panel_bottom-center .form-submit-panel-operation-inner[data-v-d71ece49]{justify-content:center}.form-submit-panel_bottom-right .form-submit-panel-operation-inner[data-v-d71ece49]{justify-content:flex-end}.form-submit-panel_top-right .form-submit-panel-operation[data-v-d71ece49]{order:0}.form-submit-panel_top-right .form-submit-panel-operation-inner[data-v-d71ece49]{justify-content:flex-end;border-bottom:1px solid var(--el-border-color-light);border-top-left-radius:var(--el-border-radius-base);border-top-right-radius:var(--el-border-radius-base)}.panel-edit-switch[data-v-7bb14fd1]{position:relative}.panel-edit-switch:hover .panel-edit-switch-edit-btn[data-v-7bb14fd1]{display:block}.panel-edit-switch-edit-btn[data-v-7bb14fd1]{position:absolute;top:0;right:0;z-index:1;display:none}.panel-edit-switch-actions[data-v-7bb14fd1]{display:flex;justify-content:flex-end;gap:8px;margin-top:8px}.form-search_show[data-v-d240f220]{margin-bottom:10px}.form-search .btn-box[data-v-d240f220]{display:flex;align-items:center;gap:8px;justify-content:flex-end}.form-search .btn-box-expand-icon[data-v-d240f220]{margin-right:2px}.form-search[data-v-d240f220] .el-col{padding-left:14px}.form-verify-image[data-v-a4baf877] .el-input__suffix-inner *{margin:0}.form-verify-image-suffix[data-v-a4baf877]{position:absolute;height:100%;border-radius:var(--el-input-border-radius, var(--el-border-radius-base));top:50%;transform:translateY(-50%);overflow:hidden;cursor:pointer}.form-verify-image-suffix-main[data-v-a4baf877]{position:absolute;left:0;top:0;width:100%;height:100%;background-color:#f4f4f4}.tabs-main-bar[data-v-d6937179]{position:relative;display:flex;align-items:center}.tabs-main-bar-item[data-v-d6937179]{border:none;background:transparent;cursor:pointer;color:var(--el-text-color-regular);transition:background .2s,color .2s,box-shadow .2s}.tabs-main-bar-indicator[data-v-d6937179]{position:absolute;left:0;background:var(--el-color-primary);transition:transform .2s,width .2s}.tabs-main-bar--l1 .tabs-main-bar-item[data-v-d6937179]{font-size:16px}.tabs-main-bar--l2 .tabs-main-bar-item[data-v-d6937179]{font-size:14px}.tabs-main-bar--l3 .tabs-main-bar-item[data-v-d6937179],.tabs-main-bar--l4 .tabs-main-bar-item[data-v-d6937179]{font-size:12px}.tabs-main-bar--variant-card[data-v-d6937179]{position:relative;overflow:hidden;gap:2px}.tabs-main-bar--variant-card .tabs-main-bar-item[data-v-d6937179]{position:relative;padding:8px 20px;line-height:1.4;border:1px solid transparent;border-bottom:0;border-radius:6px 6px 0 0}.tabs-main-bar--variant-card .tabs-main-bar-item[data-v-d6937179]:hover:not(.tabs-main-bar-item_active){color:var(--el-color-primary)}.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]{color:var(--el-color-primary);border-color:var(--el-border-color-light)}.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]:before,.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]:after{content:"";position:absolute;bottom:0;width:100vw;height:1px;background:var(--el-border-color-light)}.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]:before{right:100%}.tabs-main-bar--variant-card .tabs-main-bar-item_active[data-v-d6937179]:after{left:100%}.tabs-main-bar--variant-indicator .tabs-main-bar-item[data-v-d6937179]{padding:8px 16px}.tabs-main-bar--variant-indicator .tabs-main-bar-item_active[data-v-d6937179]{color:var(--el-color-primary)}.tabs-main-bar--variant-indicator .tabs-main-bar-indicator[data-v-d6937179]{bottom:0;height:2px}.tabs-main-bar--variant-indicator-compact .tabs-main-bar-item[data-v-d6937179]{padding:6px 10px}.tabs-main-bar--variant-indicator-compact .tabs-main-bar-item_active[data-v-d6937179]{color:var(--el-color-primary)}.tabs-main-bar--variant-indicator-compact .tabs-main-bar-indicator[data-v-d6937179]{bottom:0;height:1px}.tabs-main-bar--variant-plain .tabs-main-bar-item[data-v-d6937179]{padding:4px 8px}.tabs-main-bar--variant-plain .tabs-main-bar-item_active[data-v-d6937179]{color:var(--el-color-primary);font-weight:600}.app-breadcrumb[data-v-2f677890]{display:flex;align-items:center;justify-content:flex-start}.app-body[data-v-265945fd]{transition-duration:.3s;transition-property:padding;transition-timing-function:linear;min-height:100vh}.app-body-shim[data-v-265945fd]{width:100%;--app-viewport-max-height: var(--ba2eb370)}.app-footer[data-v-393d9768]{transition-duration:.3s;transition-property:height;transition-timing-function:linear;overflow:hidden;width:100%;box-shadow:-5px 0 5px #0000001a}.app-footer-shim[data-v-393d9768]{width:100%;height:100%;padding:0 20px}.app-header[data-v-ef3cc8a6]{transition-duration:.3s;transition-property:height;transition-timing-function:linear;overflow:hidden;position:fixed;left:0;top:0;width:100%;box-shadow:5px 0 5px #0000001a;z-index:1}.app-header-module[data-v-ef3cc8a6]{display:flex;flex:1;height:100%;overflow-x:auto}.app-header-module-item[data-v-ef3cc8a6]{display:flex;justify-content:center;align-items:center;padding:0 20px;white-space:nowrap;height:100%;color:var(--v3dfae5bc)}.app-header-module-item[data-v-ef3cc8a6]:hover,.app-header-module-item_active[data-v-ef3cc8a6]{color:var(--v158cd0d2)}.app-header-module-item_active[data-v-ef3cc8a6]{position:relative}.app-header-module-item_active[data-v-ef3cc8a6]:before{content:"";position:absolute;left:50%;top:0;width:100%;height:3px;background-color:var(--v158cd0d2);transform:translate(-50%)}.app-header-shim[data-v-ef3cc8a6]{width:100%;height:100%;display:flex;align-items:center;justify-content:space-between;padding:0 20px;font-size:18px;font-weight:700}.app-header-module-item__icon[data-v-ef3cc8a6]{margin-right:8px}.app-header-userInfo[data-v-ef3cc8a6]{padding-left:80px}.app-header-userInfo__theme-switch[data-v-ef3cc8a6]{margin-right:12px}.app-sidebar[data-v-37ff5e0c]{transition-duration:.3s;transition-property:width;transition-timing-function:linear;position:fixed;left:0;top:0;height:100%;box-shadow:0 5px 5px #0000001a;overflow:visible;z-index:var(--ce9ef212)}.app-sidebar-top[data-v-37ff5e0c]{position:absolute;left:0;right:0;top:0;overflow:hidden}.app-sidebar-bottom[data-v-37ff5e0c]{position:absolute;left:0;right:0;bottom:0;overflow:hidden}.app-sidebar-shim[data-v-37ff5e0c]{position:absolute;left:0;right:0;top:var(--v309db2c2);bottom:var(--v2189b8a1);overflow-x:hidden;overflow-y:auto;--el-menu-border-color: transparent;-webkit-user-select:none;user-select:none}.app-sidebar-toggle[data-v-37ff5e0c]{position:absolute;left:100%;top:50%;transform:translate(-50%,-50%);cursor:pointer;width:22px;height:22px;border-radius:50%;background-color:var(--v65908f82);color:var(--v42a24063);border:1px solid var(--v42a24063);box-shadow:0 1px 2px #0000000f;display:flex;align-items:center;justify-content:center;font-size:12px;z-index:1;isolation:isolate;transition:color .3s,border-color .3s,box-shadow .3s}.app-sidebar-toggle[data-v-37ff5e0c]:before{content:"";position:absolute;top:-3px;right:-3px;bottom:-3px;left:-3px;border-radius:50%;background-color:var(--v42a24063);opacity:.18;z-index:-1;pointer-events:none;transition:opacity .3s,inset .3s}.app-sidebar-toggle[data-v-37ff5e0c]:active,.app-sidebar-toggle[data-v-37ff5e0c]:focus,.app-sidebar-toggle[data-v-37ff5e0c]:hover{box-shadow:0 2px 6px #0000001f}.app-sidebar-toggle[data-v-37ff5e0c]:active:before,.app-sidebar-toggle[data-v-37ff5e0c]:focus:before,.app-sidebar-toggle[data-v-37ff5e0c]:hover:before{opacity:.32;top:-5px;right:-5px;bottom:-5px;left:-5px}.app-sidebar-toggle-icon[data-v-37ff5e0c]{transition:transform .3s}.app-layout[data-v-6924f8b7]{position:relative}.app-layout_noLogin[data-v-6924f8b7] .app-body,.app-layout_noLogin[data-v-6924f8b7] .app-sidebar,.app-layout_noLogin[data-v-6924f8b7] .app-header,.app-layout_noLogin[data-v-6924f8b7] .app-footer{transition:none!important}.app-page-shim[data-v-fda19616]{--app-viewport-max-height: var(--v54888f0e)}[data-v-1f8a1089] .auto-refresh-label{display:flex;font-size:13px;color:var(--el-text-color-regular);margin-bottom:8px}.auto-refresh-group-icon--rotating[data-v-9cac8b09]{animation:auto-refresh-rotating-9cac8b09 1s linear infinite}@keyframes auto-refresh-rotating-9cac8b09{0%{transform:rotate(0)}to{transform:rotate(360deg)}}.table-toolbar[data-v-22ae8fa7]{display:flex;justify-content:space-between;align-items:center;padding-bottom:8px;gap:20px}.table-toolbar-left[data-v-22ae8fa7],.table-toolbar-right[data-v-22ae8fa7]{display:flex;align-items:center;gap:10px}.table-toolbar-switch-view[data-v-22ae8fa7]{--el-switch-off-color: var(--el-color-primary);--el-switch-on-color: var(--el-color-warning)}.data-list-view[data-v-da38bea6]{width:100%}.data-list-view-empty[data-v-da38bea6]{display:flex;justify-content:center;align-items:center;width:100%;min-height:60px}.table-main-pagination[data-v-05684b89]{margin-top:10px;display:flex;justify-content:flex-end}.list-page[data-v-d70424b6]{min-height:var(--v9299b0d4)}.list-page-header[data-v-d70424b6],.list-page-operation[data-v-d70424b6]{margin-bottom:10px}.list-page[data-v-d70424b6] .el-loading-mask{left:-10px;top:-10px;right:-10px;bottom:-10px}.panel-main-item-col:not(:last-of-type) .panel-main-item-col-wrap_card[data-v-25951dc8]{margin-bottom:var(--v39ccf6bc)}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@done-coding/admin-core",
|
|
3
|
-
"version": "0.8.
|
|
3
|
+
"version": "0.8.2-alpha.0",
|
|
4
4
|
"description": "后台管理核心",
|
|
5
5
|
"private": false,
|
|
6
6
|
"main": "lib/index.cjs",
|
|
@@ -81,5 +81,5 @@
|
|
|
81
81
|
"node": ">=18.0.0",
|
|
82
82
|
"pnpm": ">=9.0.0"
|
|
83
83
|
},
|
|
84
|
-
"gitHead": "
|
|
84
|
+
"gitHead": "ab62c1951866382399a7a524aefc1f8aad7b056b"
|
|
85
85
|
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { FormDataInfo, FormSubmitBtnProps } from './types';
|
|
2
2
|
declare const _default: <PO extends Record<string, any>, SO extends Record<string, any>>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
3
3
|
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
4
|
-
readonly onSuccess?: ((data:
|
|
4
|
+
readonly onSuccess?: ((data: import('./types').ExcludeNeverProperties<import('./types').ExtractFormStringifyRawFromObject<PO, SO>>) => any) | undefined;
|
|
5
5
|
readonly onFail?: ((error: any) => any) | undefined;
|
|
6
6
|
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onSuccess" | "onFail"> & FormSubmitBtnProps<PO, SO> & Partial<{}>> & import('vue').PublicProps;
|
|
7
7
|
expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
|
|
8
8
|
attrs: any;
|
|
9
9
|
slots: {};
|
|
10
10
|
emit: {
|
|
11
|
-
(e: "success", data:
|
|
11
|
+
(e: "success", data: FormDataInfo<PO, SO>["stringifyData"]): void;
|
|
12
12
|
(e: "fail", error: any): void;
|
|
13
13
|
};
|
|
14
14
|
}>) => import('vue').VNode & {
|
|
@@ -1,26 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { FormDataInfo } from './types';
|
|
1
|
+
import { FormSubmitPanelProps, FormDataInfo } from './types';
|
|
3
2
|
declare const _default: <PO extends Record<string, any>, SO extends Record<string, any>>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
4
3
|
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
5
|
-
readonly onSuccess?: ((
|
|
6
|
-
readonly onReset?: ((initParseData: PO) => any) | undefined;
|
|
4
|
+
readonly onSuccess?: ((sData: import('./types').ExcludeNeverProperties<import('./types').ExtractFormStringifyRawFromObject<PO, SO>>) => any) | undefined;
|
|
7
5
|
readonly onCancel?: (() => any) | undefined;
|
|
8
6
|
readonly onFail?: ((error: any) => any) | undefined;
|
|
9
|
-
readonly
|
|
10
|
-
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "
|
|
11
|
-
parseData?: PO;
|
|
12
|
-
} & Omit<import('./types').FormMainProps<PO, SO>, "data"> & {
|
|
13
|
-
stringifyData?: import('./types').ExcludeNeverProperties<import('./types').ExtractFormStringifyRawFromObject<PO, SO>> | undefined;
|
|
14
|
-
} & Pick<import('./types').FormSubmitBtnProps<PO, SO>, import('./types').FormSubmitPanelFlatProps> & {
|
|
15
|
-
submitBtnProps?: Omit<import('./types').FormSubmitBtnProps<PO, SO>, "formMainInstance" | import('./types').FormSubmitPanelFlatProps> | undefined;
|
|
16
|
-
} & {
|
|
17
|
-
labelPosition?: "right" | "left" | "top";
|
|
18
|
-
labelWidth?: string;
|
|
19
|
-
cancelBtn?: string;
|
|
20
|
-
resetBtn?: string;
|
|
21
|
-
operationPosition?: "bottom-center" | "bottom-right" | "top-right";
|
|
22
|
-
operationAffix?: boolean | AffixProps;
|
|
23
|
-
}) & Partial<{}>> & import('vue').PublicProps;
|
|
7
|
+
readonly onParseDataChange?: ((pData: PO) => any) | undefined;
|
|
8
|
+
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onCancel" | "onSuccess" | "onFail" | "onParseDataChange"> & FormSubmitPanelProps<PO, SO> & Partial<{}>> & import('vue').PublicProps;
|
|
24
9
|
expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
|
|
25
10
|
attrs: any;
|
|
26
11
|
slots: Partial<Record<NonNullable<Extract<keyof PO, string>>, (_: any) => any>> & {
|
|
@@ -34,9 +19,9 @@ declare const _default: <PO extends Record<string, any>, SO extends Record<strin
|
|
|
34
19
|
emit: {
|
|
35
20
|
(e: "cancel"): void;
|
|
36
21
|
(e: "fail", error: any): void;
|
|
37
|
-
(e: "success",
|
|
38
|
-
(e: "
|
|
39
|
-
}
|
|
22
|
+
(e: "success", sData: FormDataInfo<PO, SO>["stringifyData"]): void;
|
|
23
|
+
(e: "parseDataChange", pData: PO): void;
|
|
24
|
+
};
|
|
40
25
|
}>) => import('vue').VNode & {
|
|
41
26
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
42
27
|
};
|
|
@@ -298,7 +298,7 @@ export type FormSubmitPanelProps<PO extends Record<string, any>, SO extends Reco
|
|
|
298
298
|
* -----
|
|
299
299
|
* 同名插槽优先级高于props,如果是props则只是重置按钮的文字 为空则不展示
|
|
300
300
|
* ----
|
|
301
|
-
* 默认的resetBtn
|
|
301
|
+
* 默认的resetBtn插槽的按钮点击后重置内部 parseData,并通过 parseDataChange 通知外部
|
|
302
302
|
*/
|
|
303
303
|
resetBtn?: string;
|
|
304
304
|
/** 操作区位置
|
|
@@ -3,14 +3,14 @@ import { FormDataInfo } from '../form/types.ts';
|
|
|
3
3
|
declare const _default: <PO extends Record<string, any>, SO extends Record<string, any>>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
4
4
|
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
5
5
|
readonly "onUpdate:editing"?: ((value: boolean) => any) | undefined;
|
|
6
|
-
readonly onSubmitSuccess?: ((data:
|
|
6
|
+
readonly onSubmitSuccess?: ((data: import('../form/types.ts').ExcludeNeverProperties<import('../form/types.ts').ExtractFormStringifyRawFromObject<PO, SO>>) => any) | undefined;
|
|
7
7
|
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onSubmitSuccess" | "onUpdate:editing"> & ({
|
|
8
8
|
editing?: boolean;
|
|
9
9
|
} & PanelItemProps<PO, SO>) & Partial<{}>> & import('vue').PublicProps;
|
|
10
10
|
expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
|
|
11
11
|
attrs: any;
|
|
12
12
|
slots: {};
|
|
13
|
-
emit: ((e: "submitSuccess", data: FormDataInfo<PO, SO>) => void) & ((evt: "update:editing", value: boolean) => void);
|
|
13
|
+
emit: ((e: "submitSuccess", data: FormDataInfo<PO, SO>["stringifyData"]) => void) & ((evt: "update:editing", value: boolean) => void);
|
|
14
14
|
}>) => import('vue').VNode & {
|
|
15
15
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
16
16
|
};
|
|
@@ -1,10 +1,13 @@
|
|
|
1
1
|
import { PanelMainProps } from './types';
|
|
2
|
+
import { FormDataInfo } from '../form';
|
|
2
3
|
declare const _default: <PO extends Record<string, any>, SO extends Record<string, any>>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
|
|
3
|
-
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
4
|
+
props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{
|
|
5
|
+
readonly onSubmitSuccess?: ((currentStringifyData: import('../form').ExcludeNeverProperties<import('../form').ExtractFormStringifyRawFromObject<PO, SO>>, key: string) => any) | undefined;
|
|
6
|
+
} & import('vue').VNodeProps & import('vue').AllowedComponentProps & import('vue').ComponentCustomProps, never>, "onSubmitSuccess"> & PanelMainProps<PO, SO> & Partial<{}>> & import('vue').PublicProps;
|
|
4
7
|
expose(exposed: import('vue').ShallowUnwrapRef<{}>): void;
|
|
5
8
|
attrs: any;
|
|
6
9
|
slots: {};
|
|
7
|
-
emit:
|
|
10
|
+
emit: (e: "submitSuccess", currentStringifyData: FormDataInfo<PO, SO>["stringifyData"], key: string) => void;
|
|
8
11
|
}>) => import('vue').VNode & {
|
|
9
12
|
__ctx?: Awaited<typeof __VLS_setup>;
|
|
10
13
|
};
|
|
@@ -22,7 +22,7 @@ export interface PanelScopeBase<PO extends Record<string, any> = Record<string,
|
|
|
22
22
|
export interface PanelRenderScope<PO extends Record<string, any> = Record<string, any>, SO extends Record<string, any> = Record<string, any>> extends PanelScopeBase<PO, SO> {
|
|
23
23
|
/** 是否编辑态 */
|
|
24
24
|
editing: boolean;
|
|
25
|
-
/** 请求 PanelMain
|
|
25
|
+
/** 请求 PanelMain 调用 refreshFn;仅用于 render/editorRender 自管刷新,不处理 editorConfig 提交成功 */
|
|
26
26
|
refresh?: () => Promise<unknown> | void;
|
|
27
27
|
/** 结束编辑态 */
|
|
28
28
|
closeEdit?: () => void;
|
|
@@ -35,8 +35,6 @@ export interface PanelItemConfig<PO extends Record<string, any> = Record<string,
|
|
|
35
35
|
label?: string;
|
|
36
36
|
/** 栅格布局,复用 resolveFormLayout 语义;缺省继承 PanelMain.layout */
|
|
37
37
|
layout?: Partial<ColProps>;
|
|
38
|
-
/** 顺序,缺省按数组序 */
|
|
39
|
-
order?: number;
|
|
40
38
|
/** 隐藏 */
|
|
41
39
|
hide?: boolean | ((scope: PanelScopeBase<PO, SO>) => boolean);
|
|
42
40
|
/** 只读渲染;缺省=纯文本 data[key] */
|
|
@@ -71,13 +69,17 @@ export interface PanelMainProps<PO extends Record<string, any> = Record<string,
|
|
|
71
69
|
/** 最后一个 margin bottom */
|
|
72
70
|
lastMarginBottom?: string;
|
|
73
71
|
}>;
|
|
74
|
-
|
|
72
|
+
/** render/editorRender 内 scope.refresh 的回调;editorConfig 提交成功请监听 submitSuccess */
|
|
73
|
+
refreshFn?: (currentStringifyData: any,
|
|
74
|
+
/** 当前的key */
|
|
75
|
+
key: string) => Promise<unknown> | void;
|
|
75
76
|
}
|
|
76
77
|
/** PanelItem props */
|
|
77
78
|
export interface PanelItemProps<PO extends Record<string, any> = Record<string, any>, SO extends Record<string, any> = Record<string, any>> {
|
|
78
79
|
data: ExtractFormStringifyFromObject<PO, SO>;
|
|
79
80
|
config: PanelItemConfig<PO, SO>;
|
|
80
|
-
|
|
81
|
+
/** render/editorRender 内 scope.refresh 的回调;不承接 submitSuccess */
|
|
82
|
+
refreshFn?: (currentStringifyData: FormDataInfo<PO, SO>["stringifyData"]) => Promise<unknown> | void;
|
|
81
83
|
}
|
|
82
84
|
/** PanelEditSwitch props */
|
|
83
85
|
export interface PanelEditSwitchProps<PO extends Record<string, any> = Record<string, any>, SO extends Record<string, any> = Record<string, any>> extends Partial<Pick<FormSubmitPanelProps<PO, SO>, "submitFn">> {
|