@web-utils/form-ui 1.0.0-beta47 → 1.0.0-beta49
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/chunks/{C9dGL28n.mjs → 6yfBZFOB.mjs} +2 -2
- package/chunks/B-zqRAXo.mjs +69 -0
- package/chunks/{CXvGoZKJ.mjs → B1IPSTA6.mjs} +2 -2
- package/chunks/{Ct5bDJ50.mjs → B9gA65rt2.mjs} +3 -3
- package/chunks/{C1AgOUe_.mjs → BA2KEptL.mjs} +2 -2
- package/chunks/BTlLPtSk2.mjs +146 -0
- package/chunks/{Bm5eiSmT.mjs → BUGCiCnl.mjs} +11 -7
- package/chunks/{DiJyms_r.mjs → BbSPWDDZ.mjs} +2 -2
- package/chunks/{BH_JJ8Xh.mjs → BfxDxIg0.mjs} +2 -2
- package/chunks/{C3Uo82-I.mjs → BqWvBF14.mjs} +3 -3
- package/chunks/BsZgAJX_2.mjs +81 -0
- package/chunks/BtOr-3u02.mjs +568 -0
- package/chunks/{DXYgAmil.mjs → BtcjAHE6.mjs} +2 -2
- package/chunks/{DhtHh0jk.mjs → ByHz4mmh.mjs} +2 -2
- package/chunks/{BufIRDd0.mjs → C2zgFLYO.mjs} +1 -1
- package/chunks/{XCGWTz41.mjs → CAd1zK9Q.mjs} +2 -2
- package/chunks/{CSyJ-vEx.mjs → CJdkjadi.mjs} +1 -1
- package/chunks/{CFOGMFgo.mjs → CabldOLo.mjs} +17 -10
- package/chunks/{Bd1UFJic.mjs → Cln3RBAD.mjs} +21 -21
- package/chunks/{CTKmEf2M.mjs → CqoVAnxC2.mjs} +2 -2
- package/chunks/{DF9fJMQS.mjs → CuAoMR3n.mjs} +3 -3
- package/chunks/{XqRTtFfp.mjs → CxTg0r4n.mjs} +1 -1
- package/chunks/{pdwFQpA8.mjs → D0Zg2CV0.mjs} +3 -3
- package/chunks/{BsCS7SB5.mjs → DA7oGHSX.mjs} +2 -2
- package/chunks/DOZRzqlo.mjs +37 -0
- package/chunks/{Cj59E77g.mjs → D_qiRmiE.mjs} +5 -5
- package/chunks/{cmuHpsX6.mjs → DcTVYqeJ.mjs} +29 -25
- package/chunks/{B3ajWLh3.mjs → Dkd5BC98.mjs} +2 -2
- package/chunks/DyHLMash.mjs +614 -0
- package/chunks/{ChmDDqoZ2.mjs → GI8krYU82.mjs} +1 -1
- package/chunks/{D8UVq1t1.mjs → V2p-PCpL.mjs} +6 -6
- package/chunks/{taicx2sd.mjs → bFbPPcdq.mjs} +2 -2
- package/chunks/{TvNHGVAP.mjs → eae6huQB.mjs} +2 -2
- package/chunks/gCeDFHo1.mjs +32 -0
- package/chunks/{BvA0aMEE.mjs → gLPy4Sus.mjs} +1 -1
- package/chunks/{o6VhYAN52.mjs → hzaYr6Ud2.mjs} +2 -2
- package/chunks/{CqTcEefA.mjs → pIzhYsBe.mjs} +2 -2
- package/chunks/{CWfUPCtS.mjs → vXQf89tS.mjs} +274 -273
- package/chunks/{BWBHzD5N.mjs → wXeqV-_7.mjs} +2 -2
- package/confirm-button/index.d.ts +2 -0
- package/confirm-button/index.mjs +1 -1
- package/confirmable/index.d.ts +2 -0
- package/confirmable/index.mjs +1 -1
- package/dict-render/index.d.ts +28 -0
- package/dict-render/index.mjs +2 -0
- package/editable-tree/index.mjs +1 -1
- package/element-dialog/index.d.ts +2 -2
- package/element-dialog/index.mjs +1 -1
- package/{resize-observer → element-resize-observer}/index.mjs +3 -3
- package/form-button/index.d.ts +2 -0
- package/form-cascader/index.d.ts +3 -3
- package/form-cascader/index.mjs +1 -1
- package/form-checkbox/index.mjs +1 -1
- package/form-checkbox-group/index.mjs +2 -0
- package/form-date-picker/index.mjs +1 -1
- package/form-holder/index.mjs +1 -1
- package/form-image/index.mjs +1 -1
- package/form-input/index.mjs +1 -1
- package/form-input-cron-expression/index.mjs +1 -1
- package/form-input-email/index.mjs +1 -1
- package/form-input-id-card/index.mjs +1 -1
- package/form-input-number/index.mjs +1 -1
- package/form-input-phone-number/index.mjs +1 -1
- package/form-input-tag/index.mjs +1 -1
- package/form-input-time/index.mjs +1 -1
- package/form-item-group/index.mjs +1 -1
- package/form-item-x/index.mjs +1 -1
- package/form-radio-group/index.d.ts +1 -1
- package/form-radio-group/index.mjs +1 -1
- package/form-rate/index.mjs +1 -1
- package/form-row/index.mjs +1 -1
- package/form-select/index.d.ts +1 -1
- package/form-select/index.mjs +1 -1
- package/form-slider/index.mjs +1 -1
- package/form-switch/index.mjs +1 -1
- package/form-table/index.d.ts +269 -0
- package/form-table/index.mjs +2 -0
- package/form-table-plus/index.d.ts +266 -0
- package/form-table-plus/index.mjs +2 -0
- package/form-text/index.mjs +1 -1
- package/form-textarea/index.mjs +1 -1
- package/form-time-select/index.mjs +1 -1
- package/helper/dictionary.mjs +7 -7
- package/iframe-window/index.mjs +1 -1
- package/index.css +1 -1
- package/index.d.ts +8 -3
- package/index.mjs +55 -50
- package/package.json +1 -1
- package/pageable-table/index.d.ts +7 -7
- package/pageable-table/index.mjs +1 -1
- package/sub-table/index.d.ts +100 -0
- package/sub-table/index.mjs +472 -0
- package/sub-table/style.css +1 -0
- package/sub-table-plus/index.d.ts +97 -0
- package/sub-table-plus/index.mjs +2 -0
- package/sub-table-plus/style.css +1 -0
- package/table-column/index.mjs +1 -1
- package/table-column-def/index.d.ts +18 -8
- package/table-column-def/index.mjs +1 -1
- package/table-view/index.mjs +107 -106
- package/toolbar/index.mjs +1 -1
- package/toolbar-button/index.d.ts +2 -2
- package/toolbar-button/index.mjs +1 -1
- package/vue-cron/index.mjs +1 -1
- package/web-types.json +1 -1
- package/x-input-tag/index.mjs +52 -51
- package/year-calendar/index.mjs +1 -1
- package/chunks/CLPSCSsy.mjs +0 -603
- package/chunks/CuG2Q-PM.mjs +0 -100
- package/form-check-box-group/index.mjs +0 -2
- package/chunks/{Ds_Tpa_M.mjs → BBERmTup.mjs} +0 -0
- package/chunks/{B1MSrc6f.mjs → CkOD-_VV.mjs} +0 -0
- package/chunks/{DDmQcNm6.mjs → DOP3aBxf.mjs} +0 -0
- package/chunks/{DJe97Fgi.mjs → hlha6Bhc.mjs} +0 -0
- package/{resize-observer → element-resize-observer}/index.d.ts +0 -0
- package/{resize-observer → element-resize-observer}/style.css +0 -0
- package/{form-check-box-group → form-checkbox-group}/index.d.ts +1 -1
- /package/{form-check-box-group → form-checkbox-group}/style.css +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { t as n } from "./
|
|
3
|
-
import { t as r } from "./
|
|
1
|
+
import { d as e, t } from "./DcTVYqeJ.mjs";
|
|
2
|
+
import { t as n } from "./CxTg0r4n.mjs";
|
|
3
|
+
import { t as r } from "./CkOD-_VV.mjs";
|
|
4
4
|
import { computePosition as i, delay as a, fastClone as o, findTreeChildren as s, hasOwn as c, isFunction as l, isNotEmpty as u, isPlainObject as d, isUndefined as f, isVerticalScrollbarVisible as p, patch as m, scrollbarWidth as h } from "@web-utils/core";
|
|
5
5
|
import { Fragment as g, createBlock as _, createCommentVNode as v, createElementBlock as y, createElementVNode as b, createTextVNode as x, createVNode as S, mergeProps as C, normalizeClass as w, normalizeStyle as T, openBlock as E, renderSlot as D, toDisplayString as O, toHandlers as k, vShow as A, withCtx as j, withDirectives as M, withModifiers as N } from "vue";
|
|
6
6
|
import { ElMessageBox as P } from "element-plus";
|
|
@@ -130,8 +130,8 @@ var V = {
|
|
|
130
130
|
this.expandedKeys = [...e];
|
|
131
131
|
}
|
|
132
132
|
} },
|
|
133
|
-
setup(
|
|
134
|
-
let { autoBindProps: n, listeners: r } = t
|
|
133
|
+
setup(t) {
|
|
134
|
+
let { autoBindProps: n, listeners: r } = e(t, {
|
|
135
135
|
predicate: U,
|
|
136
136
|
removeOn: !0
|
|
137
137
|
});
|
|
@@ -248,12 +248,12 @@ var V = {
|
|
|
248
248
|
async appendRootNode() {
|
|
249
249
|
this.text = "", !this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.createNewChild(void 0), this.$refs.tree.root.insertChild({ data: this.newChild }, void 0, !0), await this.scrollIntoView(!0)) : await P.prompt(`请输入${this.label}名:`, {
|
|
250
250
|
...this.defaultOptions,
|
|
251
|
-
beforeClose: async (
|
|
252
|
-
if (
|
|
251
|
+
beforeClose: async (e, n, r) => {
|
|
252
|
+
if (e === "confirm") {
|
|
253
253
|
try {
|
|
254
254
|
this.createNewChild(-1), n.confirmButtonLoading = !0, n.confirmButtonText = "处理中...";
|
|
255
|
-
let
|
|
256
|
-
this.newChild[this.treeProps.label] = n.inputValue, this.newChild.edit = !1,
|
|
255
|
+
let e = await this.saveApi(this.newNodeBuilder(n.inputValue, { id: -1 }));
|
|
256
|
+
this.newChild[this.treeProps.label] = n.inputValue, this.newChild.edit = !1, t(this.newChild, e.data), this.$refs.tree.root.insertChild({ data: this.newChild }, void 0, !0), await this.locateView(), r();
|
|
257
257
|
} catch {
|
|
258
258
|
n.confirmButtonText = "确定";
|
|
259
259
|
}
|
|
@@ -262,18 +262,18 @@ var V = {
|
|
|
262
262
|
}
|
|
263
263
|
}).catch((e) => e);
|
|
264
264
|
},
|
|
265
|
-
appendChildNode(
|
|
265
|
+
appendChildNode(e) {
|
|
266
266
|
this.text = "";
|
|
267
|
-
let n =
|
|
268
|
-
|
|
269
|
-
!this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.createNewChild(
|
|
267
|
+
let n = e.expanded;
|
|
268
|
+
e.expand(async () => {
|
|
269
|
+
!this.contextMenu || this.contextMenuIcon || this.contextMenuInline ? (this.clear(), this.createNewChild(e.data.id), this.$refs.tree.append(this.newChild, e), await this.scrollIntoView(n)) : await P.prompt(`请输入${this.label}名:`, {
|
|
270
270
|
...this.defaultOptions,
|
|
271
271
|
beforeClose: async (n, r, i) => {
|
|
272
272
|
if (n === "confirm") {
|
|
273
273
|
try {
|
|
274
|
-
this.createNewChild(
|
|
275
|
-
let n = await this.saveApi(this.newNodeBuilder(r.inputValue,
|
|
276
|
-
this.newChild[this.treeProps.label] = r.inputValue, this.newChild.edit = !1,
|
|
274
|
+
this.createNewChild(e.data.id), r.confirmButtonLoading = !0, r.confirmButtonText = "处理中...";
|
|
275
|
+
let n = await this.saveApi(this.newNodeBuilder(r.inputValue, e.data));
|
|
276
|
+
this.newChild[this.treeProps.label] = r.inputValue, this.newChild.edit = !1, t(this.newChild, n.data), this.$refs.tree.append(this.newChild, e), await this.locateView(), i();
|
|
277
277
|
} catch {
|
|
278
278
|
r.confirmButtonText = "确定";
|
|
279
279
|
}
|
|
@@ -361,7 +361,7 @@ var V = {
|
|
|
361
361
|
} else this.$refs.tree.remove(e);
|
|
362
362
|
} catch {}
|
|
363
363
|
},
|
|
364
|
-
async onConfirm(
|
|
364
|
+
async onConfirm(e, n) {
|
|
365
365
|
if (n[this.treeProps.label] === this.text || !u(this.text)) {
|
|
366
366
|
this.clear();
|
|
367
367
|
return;
|
|
@@ -369,16 +369,16 @@ var V = {
|
|
|
369
369
|
f(n.loading), n.loading = !0;
|
|
370
370
|
try {
|
|
371
371
|
if (this.loading = !0, n.id === -1) {
|
|
372
|
-
let r = await this.saveApi(this.newNodeBuilder(this.text,
|
|
373
|
-
|
|
372
|
+
let r = await this.saveApi(this.newNodeBuilder(this.text, e.parent.data || { id: -1 })), i = o(n);
|
|
373
|
+
t(n, {
|
|
374
374
|
...r.data,
|
|
375
375
|
isTempNode: !1
|
|
376
|
-
}), this.$emit("node-added", n, i,
|
|
376
|
+
}), this.$emit("node-added", n, i, e), this.registerNode(e);
|
|
377
377
|
} else await this.updateApi({
|
|
378
378
|
...n,
|
|
379
379
|
[this.treeProps.label]: this.text
|
|
380
380
|
});
|
|
381
|
-
n[this.treeProps.label] = this.text, n.edit = !1, this.$emit("node-updated", n,
|
|
381
|
+
n[this.treeProps.label] = this.text, n.edit = !1, this.$emit("node-updated", n, e), this.text = "";
|
|
382
382
|
} catch {}
|
|
383
383
|
n.loading = !1, this.loading = !1;
|
|
384
384
|
},
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { i as e, n as t } from "./
|
|
2
|
-
import { n, t as r } from "./
|
|
1
|
+
import { i as e, n as t } from "./D_qiRmiE.mjs";
|
|
2
|
+
import { n, t as r } from "./CJdkjadi.mjs";
|
|
3
3
|
import { createVNode as i, mergeProps as a } from "vue";
|
|
4
4
|
import { ElTimeSelect as o } from "element-plus/es";
|
|
5
5
|
//#region src/components/form/props/time-select.ts
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { n as e } from "./
|
|
2
|
-
import { n as t, t as n } from "./
|
|
3
|
-
import { t as r } from "./
|
|
1
|
+
import { n as e } from "./D_qiRmiE.mjs";
|
|
2
|
+
import { n as t, t as n } from "./CJdkjadi.mjs";
|
|
3
|
+
import { t as r } from "./CabldOLo.mjs";
|
|
4
4
|
import { createVNode as i, isVNode as a, mergeProps as o, useModel as s } from "vue";
|
|
5
5
|
//#region src/components/form/props/textarea.ts
|
|
6
6
|
var c = {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { f as e } from "./DcTVYqeJ.mjs";
|
|
2
2
|
import { hasAuthority as t } from "../api/index.mjs";
|
|
3
3
|
import { toolbarContextKey as n } from "../constants/index.mjs";
|
|
4
4
|
import { isArray as r, isFunction as i } from "@web-utils/core";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { i as e, n as t } from "./
|
|
2
|
-
import { n, t as r } from "./
|
|
3
|
-
import { t as i } from "./
|
|
1
|
+
import { i as e, n as t } from "./D_qiRmiE.mjs";
|
|
2
|
+
import { n, t as r } from "./CJdkjadi.mjs";
|
|
3
|
+
import { t as i } from "./vXQf89tS.mjs";
|
|
4
4
|
import { createVNode as a, mergeProps as o, ref as s } from "vue";
|
|
5
5
|
import { ElInput as c, ElPopover as l } from "element-plus/es";
|
|
6
6
|
//#region src/components/form/props/input-cron.ts
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { i as e, n as t } from "./
|
|
2
|
-
import { n } from "./
|
|
1
|
+
import { i as e, n as t } from "./D_qiRmiE.mjs";
|
|
2
|
+
import { n } from "./CJdkjadi.mjs";
|
|
3
3
|
import { useDictionary as r } from "../hook/useDictionary.mjs";
|
|
4
4
|
import { computed as i, createVNode as a, isVNode as o, mergeProps as s, useModel as c } from "vue";
|
|
5
5
|
import { ElRadio as l, ElRadioButton as u, ElRadioGroup as d } from "element-plus/es";
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { getDictLabel as e } from "../helper/dictionary.mjs";
|
|
2
|
+
import { computed as t, createVNode as n, ref as r, watchEffect as i } from "vue";
|
|
3
|
+
//#endregion
|
|
4
|
+
//#region src/components/table/DictRender.vue
|
|
5
|
+
var a = {
|
|
6
|
+
name: "DictRender",
|
|
7
|
+
inheritAttrs: !1,
|
|
8
|
+
props: {
|
|
9
|
+
row: Object,
|
|
10
|
+
column: Object,
|
|
11
|
+
dictType: String,
|
|
12
|
+
options: Array,
|
|
13
|
+
treeDict: Boolean,
|
|
14
|
+
idAsValue: {
|
|
15
|
+
type: Boolean,
|
|
16
|
+
default: !0
|
|
17
|
+
},
|
|
18
|
+
labelAsValue: Boolean
|
|
19
|
+
},
|
|
20
|
+
setup(a, { attrs: o }) {
|
|
21
|
+
let s = r(null), c = t(() => a.row[a.column.property]);
|
|
22
|
+
return i(async () => {
|
|
23
|
+
if (a.dictType) s.value = await e(a.dictType, c.value, !0, {
|
|
24
|
+
options: !0,
|
|
25
|
+
treeDict: a.treeDict,
|
|
26
|
+
idAsValue: a.idAsValue,
|
|
27
|
+
labelAsValue: a.labelAsValue
|
|
28
|
+
});
|
|
29
|
+
else {
|
|
30
|
+
var t;
|
|
31
|
+
s.value = ((t = a.options) == null || (t = t.find((e) => `${e.modelValue}` == `${e.value}`)) == null ? void 0 : t.label) ?? `${c.value}`;
|
|
32
|
+
}
|
|
33
|
+
}), () => n("span", o, [s.value]);
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
//#endregion
|
|
37
|
+
export { a as t };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { f as e, o as t, p as n } from "./DcTVYqeJ.mjs";
|
|
2
2
|
import { formHolderContextKey as r, formItemConfigProviderContextKey as i, formItemGroupContextKey as a } from "../constants/index.mjs";
|
|
3
3
|
import { isArray as o, isPlainObject as s, isString as c } from "@web-utils/core";
|
|
4
4
|
import { computed as l, createVNode as u, h as d, inject as f, mergeProps as p, nextTick as m, unref as h, useTemplateRef as g } from "vue";
|
|
@@ -69,7 +69,7 @@ var S = {
|
|
|
69
69
|
inputColspan: !0,
|
|
70
70
|
labelRowspan: !0,
|
|
71
71
|
inputRowspan: !0
|
|
72
|
-
}, w = (e) => S[e] !== void 0 && C[e] !== !0, T = (
|
|
72
|
+
}, w = (e) => S[e] !== void 0 && C[e] !== !0, T = (e, { emit: n, events: r, predicate: i }) => l(() => t(e, i, r, n)), E = {
|
|
73
73
|
span: {
|
|
74
74
|
type: Number,
|
|
75
75
|
default: 12
|
|
@@ -95,7 +95,7 @@ var S = {
|
|
|
95
95
|
type: String,
|
|
96
96
|
default: "div"
|
|
97
97
|
}
|
|
98
|
-
}, D = { span: !0 }, O = (e) => E[e] !== void 0 && D[e] !== !0, k = (
|
|
98
|
+
}, D = { span: !0 }, O = (e) => E[e] !== void 0 && D[e] !== !0, k = (e, { emit: n, events: r, predicate: i }) => l(() => t(e, i, r, n)), A = (e) => {
|
|
99
99
|
let t = f(r, null);
|
|
100
100
|
return l(() => e.required === !0 ? !0 : (t == null ? void 0 : t.requiredFieldsMap[e.prop]) === !0);
|
|
101
101
|
}, j = (e, t) => {
|
|
@@ -214,7 +214,7 @@ var S = {
|
|
|
214
214
|
formItemProps: v,
|
|
215
215
|
slots: a,
|
|
216
216
|
disabled: h
|
|
217
|
-
}), S = l(() =>
|
|
217
|
+
}), S = l(() => t(r, u, c, i)), C = n({ removeOn: p });
|
|
218
218
|
return {
|
|
219
219
|
emitInput: y,
|
|
220
220
|
render: x,
|
|
@@ -222,7 +222,7 @@ var S = {
|
|
|
222
222
|
disabled: h,
|
|
223
223
|
formItemProps: v,
|
|
224
224
|
autoBind: S,
|
|
225
|
-
inputProps:
|
|
225
|
+
inputProps: e(r, u),
|
|
226
226
|
listeners: C
|
|
227
227
|
};
|
|
228
228
|
}, B = (e) => e.icon ? d("i", { class: e.icon }) : null;
|
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import { camelize as e, capitalize as t, copy as n, hyphenate as r, isArray as i, isFunction as a, isString as o, uncapitalize as s } from "@web-utils/core";
|
|
2
|
-
import {
|
|
3
|
-
import { ElMessage as
|
|
2
|
+
import { Comment as c, Fragment as l, computed as u, useAttrs as d } from "vue";
|
|
3
|
+
import { ElMessage as f } from "element-plus";
|
|
4
4
|
//#region src/utils/index.ts
|
|
5
|
-
var
|
|
5
|
+
var p = (e, n, r, i, a = !0) => {
|
|
6
6
|
let o = {};
|
|
7
7
|
if (n) for (let t in e) n(t) && (o[t] = e[t]);
|
|
8
8
|
return a && r && r.forEach((e) => {
|
|
9
9
|
o[`on${t(e)}`] = (...t) => i(e, ...t);
|
|
10
10
|
}), o;
|
|
11
|
-
},
|
|
11
|
+
}, m = (e, t) => u(() => {
|
|
12
12
|
let n = {};
|
|
13
13
|
if (t) for (let r in e) t(r) && (n[r] = e[r]);
|
|
14
14
|
return n;
|
|
15
|
-
}),
|
|
16
|
-
let i =
|
|
17
|
-
return
|
|
15
|
+
}), h = ({ removeOn: t = !1, include: n, exclude: r } = {}) => {
|
|
16
|
+
let i = d();
|
|
17
|
+
return u(() => {
|
|
18
18
|
let a = {}, o = {}, c = {}, l = !1;
|
|
19
19
|
(n || r) && (l = !0), n == null || n.forEach((t) => {
|
|
20
20
|
o[e(t)] = !0;
|
|
@@ -28,14 +28,14 @@ var d = (e, n, r, i, a = !0) => {
|
|
|
28
28
|
}
|
|
29
29
|
return a;
|
|
30
30
|
});
|
|
31
|
-
},
|
|
32
|
-
listeners:
|
|
33
|
-
autoBindProps:
|
|
34
|
-
}),
|
|
31
|
+
}, g = (e, { predicate: t, removeOn: n }) => ({
|
|
32
|
+
listeners: h({ removeOn: n }),
|
|
33
|
+
autoBindProps: m(e, t)
|
|
34
|
+
}), _ = (e, { withOn: t = !1 } = {}) => {
|
|
35
35
|
let n = {};
|
|
36
36
|
for (let r in e) r.startsWith("on") && (t ? n[r] = e[r] : n[s(r.replace(/^on/, ""))] = e[r]);
|
|
37
37
|
return n;
|
|
38
|
-
},
|
|
38
|
+
}, v = (e, t = "id", n = "label") => {
|
|
39
39
|
let r = [];
|
|
40
40
|
function i(e, a) {
|
|
41
41
|
if (!e) return;
|
|
@@ -52,9 +52,9 @@ var d = (e, n, r, i, a = !0) => {
|
|
|
52
52
|
});
|
|
53
53
|
}
|
|
54
54
|
return e.forEach((e) => i(e, [])), r;
|
|
55
|
-
},
|
|
55
|
+
}, y = (e, t = "id", n = "label") => {
|
|
56
56
|
let r = [];
|
|
57
|
-
return
|
|
57
|
+
return v(e).forEach((e) => {
|
|
58
58
|
let i = [], a = [];
|
|
59
59
|
for (let r = 0; r < e.length; r++) i.push(e[r][t]), a.push(e[r][n]);
|
|
60
60
|
r.push({
|
|
@@ -62,9 +62,9 @@ var d = (e, n, r, i, a = !0) => {
|
|
|
62
62
|
label: a.join("/")
|
|
63
63
|
});
|
|
64
64
|
}), r;
|
|
65
|
-
},
|
|
65
|
+
}, b = (e, t = "id", n = "label") => {
|
|
66
66
|
let r = {};
|
|
67
|
-
return
|
|
67
|
+
return v(e).forEach((e) => {
|
|
68
68
|
let i = [], a = [];
|
|
69
69
|
for (let r = 0; r < e.length; r++) i.push(e[r][t]), a.push(e[r][n]);
|
|
70
70
|
r[i.join("/")] = {
|
|
@@ -73,23 +73,23 @@ var d = (e, n, r, i, a = !0) => {
|
|
|
73
73
|
};
|
|
74
74
|
}), r;
|
|
75
75
|
};
|
|
76
|
-
function
|
|
77
|
-
n(e, () =>
|
|
76
|
+
function x(e) {
|
|
77
|
+
n(e, () => f.success({
|
|
78
78
|
duration: 1e3,
|
|
79
79
|
message: "复制成功!",
|
|
80
80
|
type: "success"
|
|
81
|
-
}), () =>
|
|
81
|
+
}), () => f.error({
|
|
82
82
|
duration: 1e3,
|
|
83
83
|
message: "复制失败!",
|
|
84
84
|
type: "error"
|
|
85
85
|
}));
|
|
86
86
|
}
|
|
87
|
-
var
|
|
87
|
+
var S = (e) => {
|
|
88
88
|
let t = [];
|
|
89
89
|
return e && (i(e) ? e.forEach((e) => {
|
|
90
|
-
i(e) ? t.push(...
|
|
90
|
+
i(e) ? t.push(...S(e)) : e && t.push(e);
|
|
91
91
|
}) : e && t.push(e)), t;
|
|
92
|
-
},
|
|
92
|
+
}, C = (e = "", t = {}) => {
|
|
93
93
|
let n = t || {};
|
|
94
94
|
return (e || "").replace(/{(.*?)}/g, (e, t) => {
|
|
95
95
|
if (t.indexOf(":")) {
|
|
@@ -97,13 +97,17 @@ var b = (e) => {
|
|
|
97
97
|
return n[e] ? n[e] : r;
|
|
98
98
|
} else return n[t] || "";
|
|
99
99
|
});
|
|
100
|
-
},
|
|
100
|
+
}, w = (e, t) => a(e) ? C(e(t), t) : o(e) ? C(e, t) : null, T = (e) => {
|
|
101
101
|
let t = {};
|
|
102
102
|
for (let n in e) t[r(n)] = e[n];
|
|
103
103
|
return t;
|
|
104
|
-
},
|
|
104
|
+
}, E = (e, t) => {
|
|
105
105
|
for (let n in t) e[n] = t[n];
|
|
106
106
|
return e;
|
|
107
|
+
}, D = (e) => {
|
|
108
|
+
let t = [];
|
|
109
|
+
for (let n of e) n.type === c || (n.type === l ? n.children && t.push(...D(n.children)) : t.push(n));
|
|
110
|
+
return t;
|
|
107
111
|
};
|
|
108
112
|
//#endregion
|
|
109
|
-
export {
|
|
113
|
+
export { S as a, b as c, g as d, m as f, w as i, T as l, x as n, p as o, h as p, D as r, _ as s, E as t, y as u };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { i as e, n as t } from "./
|
|
2
|
-
import { n, t as r } from "./
|
|
1
|
+
import { i as e, n as t } from "./D_qiRmiE.mjs";
|
|
2
|
+
import { n, t as r } from "./CJdkjadi.mjs";
|
|
3
3
|
import { useDictionary as i } from "../hook/useDictionary.mjs";
|
|
4
4
|
import { findTreeChildren as a, isArray as o, isString as s, setParent as c } from "@web-utils/core";
|
|
5
5
|
import { computed as l, createVNode as u, mergeProps as d } from "vue";
|