@web-utils/form-ui 1.0.0-beta56 → 1.0.0-beta57
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/-qKZw-3p2.mjs +23 -0
- package/chunks/{B3A-CnYr.mjs → 33G2_TH8.mjs} +4 -4
- package/chunks/{gLPy4Sus.mjs → 8P-OAGbj.mjs} +1 -1
- package/chunks/B2PuSZ_F.mjs +35 -0
- package/chunks/B6B-rhhB.mjs +37 -0
- package/chunks/{C7Mak2La.mjs → BHT38Us-.mjs} +7 -6
- package/chunks/BWoKh6f6.mjs +66 -0
- package/chunks/{Dt_s96gL2.mjs → BXrA0SYn2.mjs} +2 -2
- package/chunks/BZ0v5mka.mjs +30 -0
- package/chunks/CE1uX9hJ.mjs +95 -0
- package/chunks/CGnOR2gn.mjs +59 -0
- package/chunks/CJ1-f8sg.mjs +30 -0
- package/chunks/{5KomemiE2.mjs → CUq3MOiQ2.mjs} +29 -29
- package/chunks/CdzoVG6J.mjs +47 -0
- package/chunks/{BZTAuJxn2.mjs → CqoMZ9Wo2.mjs} +1 -1
- package/chunks/CrQmTHMA.mjs +105 -0
- package/chunks/Crh2RUrS.mjs +106 -0
- package/chunks/DBUJ7Bva.mjs +56 -0
- package/chunks/DB_UKPay.mjs +27 -0
- package/chunks/{BvKUeniN.mjs → DEC2O0q-.mjs} +46 -44
- package/chunks/{BoJgSMkL.mjs → DUhF8YOY.mjs} +2 -2
- package/chunks/Du1PslcN.mjs +28 -0
- package/chunks/{Dluor05A.mjs → DyEYDv4B.mjs} +7 -6
- package/chunks/EAJCsX8W.mjs +32 -0
- package/chunks/{Bq62m7IR2.mjs → T4GdQtY8.mjs} +11 -11
- package/chunks/ZFJ73RWd2.mjs +29 -0
- package/chunks/{D2B9Y3oT.mjs → fmIV_kHp.mjs} +2 -2
- package/chunks/h5488Kii.mjs +27 -0
- package/chunks/k3cC9SGC.mjs +27 -0
- package/chunks/{CauzhVSa2.mjs → rJWvEBq9.mjs} +12 -12
- package/chunks/{7GmKqdbC.mjs → usyXQe35.mjs} +1 -1
- package/chunks/{BpCiVuKL.mjs → v3wbYL_-.mjs} +7 -6
- package/chunks/vd9nXj8B.mjs +59 -0
- package/chunks/{g8MIBMw92.mjs → ztBRZQwM.mjs} +13 -13
- package/confirm-button/index.mjs +1 -1
- package/confirmable/index.mjs +1 -1
- package/editable-tree/index.mjs +591 -2
- package/element-dialog/index.mjs +1 -1
- package/element-resize-observer/index.mjs +1 -1
- package/form-cascader/index.mjs +1 -1
- package/form-checkbox/index.mjs +1 -1
- package/form-checkbox-group/index.mjs +1 -1
- 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.mjs +1 -1
- package/form-rate/index.mjs +1 -1
- package/form-row/index.mjs +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.mjs +1 -1
- package/form-table-plus/index.mjs +1 -1
- 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 +1 -1
- package/helper/form-item.d.ts +1 -1
- package/helper/form-item.mjs +27 -2
- package/helper/input.mjs +1 -1
- package/iframe-window/index.mjs +1 -1
- package/index.mjs +37 -37
- package/package.json +1 -1
- package/pageable-table/index.mjs +1 -1
- package/props/cascader.d.ts +326 -0
- package/{chunks/Czz_49pC.mjs → props/cascader.mjs} +8 -58
- package/props/checkbox-group.d.ts +213 -0
- package/props/checkbox-group.mjs +83 -0
- package/props/checkbox.d.ts +202 -0
- package/props/checkbox.mjs +71 -0
- package/props/col.d.ts +74 -0
- package/props/col.mjs +32 -0
- package/props/common.d.ts +114 -0
- package/props/common.mjs +18 -0
- package/props/date.d.ts +339 -0
- package/props/date.mjs +145 -0
- package/props/form-item.d.ts +144 -0
- package/props/form-item.mjs +73 -0
- package/props/form.d.ts +157 -0
- package/props/form.mjs +89 -0
- package/props/image.d.ts +102 -0
- package/props/image.mjs +10 -0
- package/props/input-cron.d.ts +102 -0
- package/props/input-cron.mjs +16 -0
- package/props/input-number.d.ts +216 -0
- package/props/input-number.mjs +72 -0
- package/props/input-tag.d.ts +123 -0
- package/props/input-tag.mjs +33 -0
- package/props/input.d.ts +299 -0
- package/props/input.mjs +97 -0
- package/props/radio-group.d.ts +205 -0
- package/props/radio-group.mjs +84 -0
- package/props/rate.d.ts +211 -0
- package/{chunks/D0kIhzQo.mjs → props/rate.mjs} +7 -28
- package/props/select.d.ts +450 -0
- package/props/select.mjs +218 -0
- package/props/slide.d.ts +235 -0
- package/{chunks/DZrQmH9Y.mjs → props/slide.mjs} +7 -28
- package/props/switch.d.ts +229 -0
- package/{chunks/ecpQ-ODX.mjs → props/switch.mjs} +7 -33
- package/props/text.d.ts +127 -0
- package/props/text.mjs +22 -0
- package/props/textarea.d.ts +266 -0
- package/{chunks/CNK4mfga.mjs → props/textarea.mjs} +19 -31
- package/props/time-select.d.ts +216 -0
- package/props/time-select.mjs +67 -0
- package/props/time.d.ts +304 -0
- package/{chunks/C3MF_-bN.mjs → props/time.mjs} +8 -39
- package/props/tree.d.ts +76 -0
- package/props/tree.mjs +75 -0
- package/sub-table/index.mjs +1 -1
- package/sub-table-plus/index.mjs +1 -1
- package/table-column/index.mjs +1 -1
- package/table-column-def/index.mjs +1 -1
- package/table-view/index.mjs +13 -13
- package/toolbar/index.mjs +1 -1
- 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 +2 -2
- package/year-calendar/index.mjs +1 -1
- package/chunks/6GcIyEQV.mjs +0 -95
- package/chunks/8c9TEVNY.mjs +0 -36
- package/chunks/AAZfNtly.mjs +0 -119
- package/chunks/BKlMENhV.mjs +0 -57
- package/chunks/BNVYEWWW.mjs +0 -57
- package/chunks/BTuzBfTA.mjs +0 -141
- package/chunks/C6Dq9Dgb.mjs +0 -17
- package/chunks/C6u76g6o.mjs +0 -158
- package/chunks/CLO5X9Lb.mjs +0 -176
- package/chunks/CdoiMj7L2.mjs +0 -39
- package/chunks/DTVTvvq-.mjs +0 -189
- package/chunks/DWE67l1f.mjs +0 -317
- package/chunks/DWMePN6q.mjs +0 -660
- package/chunks/D_L1p3vm2.mjs +0 -90
- package/chunks/Dy_5vPdP.mjs +0 -101
- package/chunks/Goee5Y-H.mjs +0 -198
- /package/chunks/{BlxLaWcU.mjs → 6av50rJm.mjs} +0 -0
- /package/chunks/{CkOD-_VV.mjs → B1MSrc6f.mjs} +0 -0
- /package/chunks/{BNqVEHk_.mjs → C-0zqLII.mjs} +0 -0
- /package/chunks/{xq_LR6R2.mjs → CI1ehQi5.mjs} +0 -0
- /package/chunks/{DcTVYqeJ.mjs → DuOxL6xh.mjs} +0 -0
- /package/chunks/{CXsoKP22.mjs → mekxD3ef.mjs} +0 -0
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import { f as e } from "./DuOxL6xh.mjs";
|
|
2
|
+
import { useFormItemProps as t } from "../helper/form-item.mjs";
|
|
3
|
+
import { r as n } from "./DEC2O0q-.mjs";
|
|
4
|
+
import { allProps as r, predicate as i } from "../props/text.mjs";
|
|
5
|
+
import { createVNode as a, mergeProps as o } from "vue";
|
|
6
|
+
import { ElText as s } from "element-plus/es";
|
|
7
|
+
//#endregion
|
|
8
|
+
//#region src/components/form/FormText.vue
|
|
9
|
+
var c = {
|
|
10
|
+
name: "FormText",
|
|
11
|
+
inheritAttrs: !1,
|
|
12
|
+
props: { ...r },
|
|
13
|
+
setup(r, { slots: c, attrs: l }) {
|
|
14
|
+
let u = t(r, { attrs: l }), d = e(r, i);
|
|
15
|
+
return () => n(r, {
|
|
16
|
+
vNodes: a(s, o(d.value, l), { default: c.default || (() => r.text) }),
|
|
17
|
+
formItemProps: u,
|
|
18
|
+
slots: c
|
|
19
|
+
});
|
|
20
|
+
}
|
|
21
|
+
};
|
|
22
|
+
//#endregion
|
|
23
|
+
export { c as t };
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import { d as e, f as t, n, r } from "./
|
|
1
|
+
import { d as e, f as t, n, r } from "./DuOxL6xh.mjs";
|
|
2
2
|
import { getDictLabel as i } from "../helper/dictionary.mjs";
|
|
3
3
|
import { cellClickHandlerContextKey as a, pageableTableContextKey as o } from "../constants/index.mjs";
|
|
4
|
-
import { t as s } from "./
|
|
4
|
+
import { t as s } from "./usyXQe35.mjs";
|
|
5
5
|
import c from "../element-resize-observer/index.mjs";
|
|
6
|
-
import { t as l } from "./
|
|
7
|
-
import { t as u } from "./
|
|
6
|
+
import { t as l } from "./CI1ehQi5.mjs";
|
|
7
|
+
import { t as u } from "./fmIV_kHp.mjs";
|
|
8
8
|
import { useVisibilityChange as ee } from "../hook/useVisibilityChange.mjs";
|
|
9
9
|
import { Fragment as te, computed as d, createBlock as f, createTextVNode as p, createVNode as m, inject as h, isVNode as g, mergeModels as _, mergeProps as v, nextTick as ne, onUpdated as y, openBlock as b, provide as x, reactive as S, ref as C, toDisplayString as w, useModel as T, useTemplateRef as E, watch as D, withCtx as O } from "vue";
|
|
10
10
|
import { ElMessage as re } from "element-plus";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { d as e } from "./
|
|
1
|
+
import { d as e } from "./DuOxL6xh.mjs";
|
|
2
2
|
import { computed as t, createBlock as n, createCommentVNode as r, createElementBlock as i, createElementVNode as a, createSlots as o, getCurrentInstance as s, mergeModels as c, mergeProps as l, normalizeClass as u, openBlock as d, ref as f, renderSlot as p, toDisplayString as m, toHandlers as h, unref as g, useModel as _, useTemplateRef as v, withCtx as y, withModifiers as b } from "vue";
|
|
3
3
|
import { ElDialog as x } from "element-plus/es";
|
|
4
4
|
//#region src/components/dialog/props.ts
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import { n as e, o as t } from "./DEC2O0q-.mjs";
|
|
2
|
+
import { allProps as n, predicate as r } from "../props/input-number.mjs";
|
|
3
|
+
import { isString as i } from "@web-utils/core";
|
|
4
|
+
import { computed as a, createVNode as o, mergeProps as s } from "vue";
|
|
5
|
+
import { ElInputNumber as c } from "element-plus/es";
|
|
6
|
+
//#endregion
|
|
7
|
+
//#region src/components/form/FormInputNumber.vue
|
|
8
|
+
var l = {
|
|
9
|
+
name: "FormInputNumber",
|
|
10
|
+
inheritAttrs: !1,
|
|
11
|
+
props: { ...n },
|
|
12
|
+
emits: { ...e },
|
|
13
|
+
setup(e, { emit: n, slots: l, attrs: u }) {
|
|
14
|
+
let { emitInput: d, render: f, placeholder: p, disabled: m, listeners: h, inputProps: g } = t(e, {
|
|
15
|
+
emit: n,
|
|
16
|
+
slots: l,
|
|
17
|
+
attrs: u,
|
|
18
|
+
predicate: r
|
|
19
|
+
}), _ = a(() => i(e.modelValue) ? Number(e.modelValue) : e.modelValue);
|
|
20
|
+
return () => f({ vNodes: o(c, s(h.value, g.value, {
|
|
21
|
+
style: "width: 100%",
|
|
22
|
+
modelValue: _.value,
|
|
23
|
+
disabled: m.value,
|
|
24
|
+
"onUpdate:modelValue": d,
|
|
25
|
+
placeholder: p.value
|
|
26
|
+
}), {
|
|
27
|
+
prefix: l.prefix || e.prefix ? () => e.prefix : null,
|
|
28
|
+
suffix: l.suffix || e.suffix ? () => e.suffix : e.append,
|
|
29
|
+
"decrease-icon": l["decrease-icon"],
|
|
30
|
+
"increase-icon": l["increase-icon"]
|
|
31
|
+
}) });
|
|
32
|
+
}
|
|
33
|
+
};
|
|
34
|
+
//#endregion
|
|
35
|
+
export { l as t };
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import { n as e, o as t } from "./DEC2O0q-.mjs";
|
|
2
|
+
import { allProps as n, predicate as r } from "../props/time.mjs";
|
|
3
|
+
import { createVNode as i, mergeProps as a } from "vue";
|
|
4
|
+
import { ElTimePicker as o } from "element-plus/es";
|
|
5
|
+
//#endregion
|
|
6
|
+
//#region src/components/form/FormInputTime.vue
|
|
7
|
+
var s = {
|
|
8
|
+
name: "FormInputTime",
|
|
9
|
+
inheritAttrs: !1,
|
|
10
|
+
props: { ...n },
|
|
11
|
+
emits: { ...e },
|
|
12
|
+
setup(e, { emit: n, slots: s, attrs: c }) {
|
|
13
|
+
let { emitInput: l, render: u, placeholder: d, disabled: f, listeners: p, inputProps: m } = t(e, {
|
|
14
|
+
emit: n,
|
|
15
|
+
slots: s,
|
|
16
|
+
attrs: c,
|
|
17
|
+
predicate: r
|
|
18
|
+
}), h = { modifiers: [{
|
|
19
|
+
name: "arrow",
|
|
20
|
+
options: { padding: ({ popper: e, reference: t, placement: n }) => e.width / 2 }
|
|
21
|
+
}] };
|
|
22
|
+
return () => u({ vNodes: i(o, a(p.value, m.value, {
|
|
23
|
+
"popper-options": e.popperOptions || h,
|
|
24
|
+
style: "width: 100%",
|
|
25
|
+
placement: e.placement || "left",
|
|
26
|
+
"is-range": e.isRange || e.range,
|
|
27
|
+
format: e.format,
|
|
28
|
+
"value-format": e.valueFormat || e.format,
|
|
29
|
+
modelValue: e.modelValue,
|
|
30
|
+
disabled: f.value,
|
|
31
|
+
"onUpdate:modelValue": l,
|
|
32
|
+
placeholder: d.value
|
|
33
|
+
}), null) });
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
//#endregion
|
|
37
|
+
export { s as t };
|
|
@@ -1,5 +1,6 @@
|
|
|
1
|
-
import { n as e } from "./
|
|
2
|
-
import {
|
|
1
|
+
import { n as e } from "./DEC2O0q-.mjs";
|
|
2
|
+
import { t } from "./BWoKh6f6.mjs";
|
|
3
|
+
import { allProps as n } from "../props/input.mjs";
|
|
3
4
|
import { createVNode as r, isVNode as i, mergeProps as a, useModel as o } from "vue";
|
|
4
5
|
//#region src/components/form/FormInputPhoneNumber.vue?vue&type=script&lang.jsx
|
|
5
6
|
function s(e) {
|
|
@@ -10,15 +11,15 @@ function s(e) {
|
|
|
10
11
|
var c = {
|
|
11
12
|
name: "FormInputPhoneNumber",
|
|
12
13
|
inheritAttrs: !1,
|
|
13
|
-
props: { ...
|
|
14
|
+
props: { ...n },
|
|
14
15
|
emits: { ...e },
|
|
15
|
-
setup(e, { slots:
|
|
16
|
+
setup(e, { slots: n, attrs: i }) {
|
|
16
17
|
let c = o(e, "modelValue");
|
|
17
|
-
return () => r(
|
|
18
|
+
return () => r(t, a(e, i, {
|
|
18
19
|
modelValue: c.value,
|
|
19
20
|
"onUpdate:modelValue": (e) => c.value = e,
|
|
20
21
|
type: "phone"
|
|
21
|
-
}), s(
|
|
22
|
+
}), s(n) ? n : { default: () => [n] });
|
|
22
23
|
}
|
|
23
24
|
};
|
|
24
25
|
//#endregion
|
|
@@ -0,0 +1,66 @@
|
|
|
1
|
+
import { n as e, o as t, t as n } from "./DEC2O0q-.mjs";
|
|
2
|
+
import { allProps as r, predicate as i } from "../props/input.mjs";
|
|
3
|
+
import { validatePhoneNum as a } from "@web-utils/core";
|
|
4
|
+
import { computed as o, createVNode as s, mergeProps as c, useModel as l } from "vue";
|
|
5
|
+
import { ElInput as u } from "element-plus/es";
|
|
6
|
+
//#region src/utils/form-validate.ts
|
|
7
|
+
var d = (e, t, n) => t && !/^[A-Za-z0-9\u4e00-\u9fa5_-]+@[a-zA-Z0-9_-]+(\.[a-zA-Z0-9_-]+)+$/.test(t) ? n(/* @__PURE__ */ Error("invalid")) : n();
|
|
8
|
+
function f(e, t, n) {
|
|
9
|
+
t && !/^[1-9][0-9]{5}(18|19|(2[0-9]))[0-9]{2}((0[1-9])|(10|11|12))(([0-2][1-9])|10|20|30|31)[0-9]{3}[0-9Xx]$/.test(t) ? n(/* @__PURE__ */ Error("invalid")) : n();
|
|
10
|
+
}
|
|
11
|
+
function p(e, t, n) {
|
|
12
|
+
if (this.$refs.table.$refs.table.records.length === 0) {
|
|
13
|
+
n(Error(e.message || `请添加${e.label}`));
|
|
14
|
+
return;
|
|
15
|
+
}
|
|
16
|
+
n();
|
|
17
|
+
}
|
|
18
|
+
//#endregion
|
|
19
|
+
//#region src/components/form/FormInput.vue
|
|
20
|
+
var m = {
|
|
21
|
+
name: "FormInput",
|
|
22
|
+
inheritAttrs: !1,
|
|
23
|
+
props: { ...r },
|
|
24
|
+
emits: { ...e },
|
|
25
|
+
setup(e, { emit: r, slots: p, attrs: m }) {
|
|
26
|
+
let h = l(e, "modelValue"), g = `请输入正确的${e.label}!`, { render: _, placeholder: v, disabled: y, listeners: b, inputProps: x, printing: S } = t(e, {
|
|
27
|
+
emit: r,
|
|
28
|
+
slots: p,
|
|
29
|
+
attrs: m,
|
|
30
|
+
rules: o(() => {
|
|
31
|
+
if (!e.type || e.type === "textarea") return null;
|
|
32
|
+
let t = {
|
|
33
|
+
message: g,
|
|
34
|
+
trigger: "blur"
|
|
35
|
+
};
|
|
36
|
+
if (e.type === "email") t.validator = d;
|
|
37
|
+
else if (e.type === "idcard") t.validator = f;
|
|
38
|
+
else if (e.type === "phone") t.validator = a;
|
|
39
|
+
else return null;
|
|
40
|
+
return [t];
|
|
41
|
+
}),
|
|
42
|
+
predicate: i
|
|
43
|
+
});
|
|
44
|
+
return () => _({ vNodes: S.value ? e.modelValue : s(u, c(b.value, x.value, {
|
|
45
|
+
class: ["form-input", {
|
|
46
|
+
"is-readonly": e.readonlyGrey && e.readonly && !e.picker,
|
|
47
|
+
"el-input-cursor-pointer": e.picker && !y.value
|
|
48
|
+
}],
|
|
49
|
+
modelValue: h.value,
|
|
50
|
+
"onUpdate:modelValue": (e) => h.value = e,
|
|
51
|
+
disabled: y.value,
|
|
52
|
+
placeholder: v.value,
|
|
53
|
+
readonly: e.readonly || e.picker,
|
|
54
|
+
"prefix-icon": n({ icon: e.picker ? "el-icon-search" : e.prefixIcon }),
|
|
55
|
+
"suffix-icon": n({ icon: e.suffixIcon })
|
|
56
|
+
}), {
|
|
57
|
+
prefix: p.prefix || e.prefix ? () => e.prefix : null,
|
|
58
|
+
suffix: p.suffix || e.suffix ? () => e.suffix : null,
|
|
59
|
+
"password-icon": p["password-icon"],
|
|
60
|
+
prepend: p.prepend || e.prepend ? () => e.prepend : null,
|
|
61
|
+
append: p.append || e.append ? () => e.append : null
|
|
62
|
+
}) });
|
|
63
|
+
}
|
|
64
|
+
};
|
|
65
|
+
//#endregion
|
|
66
|
+
export { p as n, m as t };
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { s as e } from "./
|
|
1
|
+
import { s as e } from "./DuOxL6xh.mjs";
|
|
2
2
|
import { goBack as t, hasAuthority as n } from "../api/index.mjs";
|
|
3
3
|
import { toolbarContextKey as r } from "../constants/index.mjs";
|
|
4
|
-
import { t as i } from "./
|
|
4
|
+
import { t as i } from "./usyXQe35.mjs";
|
|
5
5
|
import { NOOP as a, capitalize as o } from "@web-utils/core";
|
|
6
6
|
import { Comment as s, createVNode as c } from "vue";
|
|
7
7
|
//#region src/components/toolbar/Toolbar.vue?vue&type=script&lang.jsx
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { allProps as e, predicate as t } from "../props/checkbox.mjs";
|
|
2
|
+
import { n, o as r } from "./DEC2O0q-.mjs";
|
|
3
|
+
import { createVNode as i, mergeProps as a, useModel as o } from "vue";
|
|
4
|
+
import { ElCheckbox as s } from "element-plus/es";
|
|
5
|
+
//#endregion
|
|
6
|
+
//#region src/components/form/FormCheckbox.vue
|
|
7
|
+
var c = {
|
|
8
|
+
name: "FormCheckbox",
|
|
9
|
+
inheritAttrs: !1,
|
|
10
|
+
props: { ...e },
|
|
11
|
+
emits: { ...n },
|
|
12
|
+
setup(e, { emit: n, slots: c, attrs: l }) {
|
|
13
|
+
let u = o(e, "modelValue"), { render: d, disabled: f, listeners: p, inputProps: m } = r(e, {
|
|
14
|
+
emit: n,
|
|
15
|
+
slots: c,
|
|
16
|
+
attrs: l,
|
|
17
|
+
predicate: t
|
|
18
|
+
});
|
|
19
|
+
return () => d({ vNodes: i(s, a(m.value, p.value, {
|
|
20
|
+
label: e.labelValue,
|
|
21
|
+
modelValue: u.value,
|
|
22
|
+
"onUpdate:modelValue": (e) => u.value = e,
|
|
23
|
+
trueValue: e.trueLabel ?? e.trueValue,
|
|
24
|
+
falseValue: e.falseLabel ?? e.falseValue,
|
|
25
|
+
disabled: f.value
|
|
26
|
+
}), { default: c.default }) });
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
//#endregion
|
|
30
|
+
export { c as t };
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { allProps as e, predicate as t } from "../props/checkbox-group.mjs";
|
|
2
|
+
import { n, o as r } from "./DEC2O0q-.mjs";
|
|
3
|
+
import { useDictionary as i } from "../hook/useDictionary.mjs";
|
|
4
|
+
import { t as a } from "./BWoKh6f6.mjs";
|
|
5
|
+
import { computed as o, createVNode as s, defineComponent as c, isVNode as l, mergeProps as u, useModel as d } from "vue";
|
|
6
|
+
import { ElCheckbox as f, ElCheckboxButton as p, ElCheckboxGroup as m } from "element-plus/es";
|
|
7
|
+
//#region src/components/form/FormCheckboxGroup.vue?vue&type=script&lang.jsx
|
|
8
|
+
function h(e) {
|
|
9
|
+
return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !l(e);
|
|
10
|
+
}
|
|
11
|
+
//#endregion
|
|
12
|
+
//#region src/components/form/FormCheckboxGroup.vue
|
|
13
|
+
var g = /* @__PURE__ */ c({
|
|
14
|
+
name: "FormCheckboxGroup",
|
|
15
|
+
inheritAttrs: !1,
|
|
16
|
+
props: { ...e },
|
|
17
|
+
emits: {
|
|
18
|
+
...n,
|
|
19
|
+
"update:other": null
|
|
20
|
+
},
|
|
21
|
+
setup(e, { emit: n, slots: c, attrs: l }) {
|
|
22
|
+
let g = d(e, "other"), { emitInput: _, render: v, disabled: y, listeners: b, inputProps: x } = r(e, {
|
|
23
|
+
emit: n,
|
|
24
|
+
slots: c,
|
|
25
|
+
attrs: l,
|
|
26
|
+
predicate: t,
|
|
27
|
+
messagePrefix: "请选择",
|
|
28
|
+
class: o(() => ["form-checkbox-group", {
|
|
29
|
+
"form-checkbox-group-row": e.fillRow,
|
|
30
|
+
"form-checkbox-group-row-break-word": e.fillRow,
|
|
31
|
+
"form-checkbox-group-row-ellipsis": e.ellipsis
|
|
32
|
+
}])
|
|
33
|
+
}), S = (t) => {
|
|
34
|
+
let n = t;
|
|
35
|
+
e.sort && (n = t.sort()), e.stringMode || e.split ? _(n.join(",")) : _(n);
|
|
36
|
+
}, C = o(() => {
|
|
37
|
+
if (e.stringMode || e.split) {
|
|
38
|
+
var t;
|
|
39
|
+
return Array.isArray(e.modelValue) ? e.modelValue.filter((e) => e) : ((t = e.modelValue) == null ? void 0 : t.split(e.delimiter).filter((e) => e)) ?? [];
|
|
40
|
+
}
|
|
41
|
+
return e.modelValue || [];
|
|
42
|
+
}), w = o(() => e.classic ? "label" : e.labelProp), T = o(() => e.classic ? "value" : e.valueProp), { dictItems: E } = i(e), D = o(() => e.dictType ? E.value : e.gender ? [{
|
|
43
|
+
[w.value]: "男",
|
|
44
|
+
[T.value]: "男"
|
|
45
|
+
}, {
|
|
46
|
+
[w.value]: "女",
|
|
47
|
+
[T.value]: "女"
|
|
48
|
+
}] : e.confirm ? [{
|
|
49
|
+
[w.value]: "是",
|
|
50
|
+
[T.value]: "是"
|
|
51
|
+
}, {
|
|
52
|
+
[w.value]: "否",
|
|
53
|
+
[T.value]: "否"
|
|
54
|
+
}] : e.options);
|
|
55
|
+
return () => v({ vNodes: [s(m, u(b.value, x.value, {
|
|
56
|
+
modelValue: C.value,
|
|
57
|
+
disabled: y.value,
|
|
58
|
+
"onUpdate:modelValue": S
|
|
59
|
+
}), {
|
|
60
|
+
...c,
|
|
61
|
+
default: c.default || (() => {
|
|
62
|
+
var t;
|
|
63
|
+
return (t = D.value) == null ? void 0 : t.map(({ value: t, label: n, disabled: r }) => e.type === "button" ? s(p, {
|
|
64
|
+
key: t,
|
|
65
|
+
value: t,
|
|
66
|
+
disabled: r
|
|
67
|
+
}, h(n) ? n : { default: () => [n] }) : s(f, {
|
|
68
|
+
key: t,
|
|
69
|
+
value: t,
|
|
70
|
+
disabled: r
|
|
71
|
+
}, h(n) ? n : { default: () => [n] }));
|
|
72
|
+
})
|
|
73
|
+
}), C.value.includes(e.otherVal) ? s(a, {
|
|
74
|
+
"wrap-col": !1,
|
|
75
|
+
class: "form-checkbox-group-other",
|
|
76
|
+
"hide-label": !0,
|
|
77
|
+
"label-width": "0",
|
|
78
|
+
prop: e.otherProp,
|
|
79
|
+
disabled: y.value,
|
|
80
|
+
required: !!e.otherProp,
|
|
81
|
+
placeholder: e.otherPlaceholder,
|
|
82
|
+
label: e.otherLabel,
|
|
83
|
+
"show-message": !!e.otherLabel,
|
|
84
|
+
style: e.otherLabel ? { width: e.otherWidth } : {
|
|
85
|
+
marginBottom: 0,
|
|
86
|
+
width: e.otherWidth
|
|
87
|
+
},
|
|
88
|
+
modelValue: g.value,
|
|
89
|
+
"onUpdate:modelValue": (e) => g.value = e,
|
|
90
|
+
"max-length": e.otherMaxLength
|
|
91
|
+
}, null) : null] });
|
|
92
|
+
}
|
|
93
|
+
});
|
|
94
|
+
//#endregion
|
|
95
|
+
export { g as t };
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { allProps as e, predicate as t } from "../props/date.mjs";
|
|
2
|
+
import { n, o as r } from "./DEC2O0q-.mjs";
|
|
3
|
+
import { computed as i, createVNode as a, mergeProps as o } from "vue";
|
|
4
|
+
import { ElDatePicker as s } from "element-plus/es";
|
|
5
|
+
import { toDate as c } from "@web-utils/integrations/dayjs";
|
|
6
|
+
//#endregion
|
|
7
|
+
//#region src/components/form/FormDatePicker.vue
|
|
8
|
+
var l = {
|
|
9
|
+
name: "FormDatePicker",
|
|
10
|
+
inheritAttrs: !1,
|
|
11
|
+
props: { ...e },
|
|
12
|
+
emits: {
|
|
13
|
+
...n,
|
|
14
|
+
"update:startDate": null,
|
|
15
|
+
"update:endDate": null
|
|
16
|
+
},
|
|
17
|
+
setup(e, { emit: n, slots: l, attrs: u }) {
|
|
18
|
+
let { emitInput: d, render: f, placeholder: p, disabled: m, listeners: h, inputProps: g } = r(e, {
|
|
19
|
+
emit: n,
|
|
20
|
+
slots: l,
|
|
21
|
+
attrs: u,
|
|
22
|
+
predicate: t,
|
|
23
|
+
messagePrefix: "请选择"
|
|
24
|
+
}), _ = i(() => e.dateTimeRange || e.dateRange || e.monthRange), v = i(() => e.year ? "YYYY" : e.month || e.monthRange ? "YYYY-MM" : e.week ? "YYYY 第 WW 周" : e.dateTime || e.dateTimeRange ? "YYYY-MM-DD HH:mm:ss" : "YYYY-MM-DD"), y = i(() => e.year ? "year" : e.month ? "month" : e.dates ? "dates" : e.week ? "week" : e.dateTime ? "datetime" : e.dateTimeRange ? "datetimerange" : e.dateRange ? "daterange" : e.monthRange ? "monthrange" : "date"), b = i(() => {
|
|
25
|
+
if (e.miniDate) {
|
|
26
|
+
let t = c(e.miniDate);
|
|
27
|
+
return t.setDate(t.getDate() - 1), t;
|
|
28
|
+
} else return null;
|
|
29
|
+
}), x = i(() => e.maxDate ? c(e.maxDate) : null), S = (e) => {
|
|
30
|
+
if (!b.value && !x.value) return !1;
|
|
31
|
+
let t = e.getTime();
|
|
32
|
+
return b.value && !x.value ? t <= b.value.getTime() : !b.value && x.value ? t >= x.value.getTime() : b.value && x.value ? !(t > b.value.getTime() && t <= x.value.getTime()) : !1;
|
|
33
|
+
}, C = (e, t) => {
|
|
34
|
+
n("update:startDate", e), n("update:endDate", t);
|
|
35
|
+
}, w = (t) => {
|
|
36
|
+
_.value && e.split ? t ? C(t[0], t[1]) : C(null, null) : d(t);
|
|
37
|
+
}, T = i(() => _.value && e.split ? [e.startDate, e.endDate] : e.modelValue), E = i(() => e.week ? "YYYY-MM-DD" : e.valueFormat || v.value), D = i(() => e.format || v.value);
|
|
38
|
+
return () => f({ vNodes: a(s, o(h.value, g.value, {
|
|
39
|
+
style: "width: 100%",
|
|
40
|
+
type: y.value,
|
|
41
|
+
modelValue: T.value,
|
|
42
|
+
disabled: m.value,
|
|
43
|
+
placeholder: p.value,
|
|
44
|
+
format: D.value,
|
|
45
|
+
disabledDate: S,
|
|
46
|
+
"value-format": E.value,
|
|
47
|
+
"onUpdate:modelValue": w
|
|
48
|
+
}), {
|
|
49
|
+
default: l.default,
|
|
50
|
+
"range-separator": l["range-separator"],
|
|
51
|
+
"pre-month": l["pre-month"],
|
|
52
|
+
"next-month": l["next-month"],
|
|
53
|
+
"pre-year": l["pre-year"],
|
|
54
|
+
"next-year": l["next-year"]
|
|
55
|
+
}) });
|
|
56
|
+
}
|
|
57
|
+
};
|
|
58
|
+
//#endregion
|
|
59
|
+
export { l as t };
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { n as e, o as t } from "./DEC2O0q-.mjs";
|
|
2
|
+
import n from "../x-input-tag/index.mjs";
|
|
3
|
+
import { allProps as r, predicate as i } from "../props/input-tag.mjs";
|
|
4
|
+
import { createVNode as a, mergeProps as o } from "vue";
|
|
5
|
+
//#endregion
|
|
6
|
+
//#region src/components/form/FormInputTag.vue
|
|
7
|
+
var s = {
|
|
8
|
+
name: "FormInputTag",
|
|
9
|
+
inheritAttrs: !1,
|
|
10
|
+
props: { ...r },
|
|
11
|
+
emits: { ...e },
|
|
12
|
+
setup(e, { emit: r, slots: s, attrs: c }) {
|
|
13
|
+
let { emitInput: l, render: u, placeholder: d, disabled: f, listeners: p, inputProps: m } = t(e, {
|
|
14
|
+
emit: r,
|
|
15
|
+
slots: s,
|
|
16
|
+
attrs: c,
|
|
17
|
+
predicate: i,
|
|
18
|
+
block: e.block === void 0 ? !0 : e.block
|
|
19
|
+
});
|
|
20
|
+
return () => u({ vNodes: a(n, o(p.value, m.value, {
|
|
21
|
+
style: "width: 100%",
|
|
22
|
+
modelValue: e.modelValue,
|
|
23
|
+
disabled: f.value,
|
|
24
|
+
"onUpdate:modelValue": l,
|
|
25
|
+
placeholder: d.value
|
|
26
|
+
}), null) });
|
|
27
|
+
}
|
|
28
|
+
};
|
|
29
|
+
//#endregion
|
|
30
|
+
export { s as t };
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import { i as e } from "./
|
|
2
|
-
import {
|
|
3
|
-
import { n as r,
|
|
4
|
-
import {
|
|
5
|
-
import { n as o, t as s } from "./
|
|
1
|
+
import { i as e } from "./DuOxL6xh.mjs";
|
|
2
|
+
import { commonAutoBindProps as t, commonManualBindProps as n } from "../props/common.mjs";
|
|
3
|
+
import { n as r, o as i } from "./DEC2O0q-.mjs";
|
|
4
|
+
import { n as a } from "./BWoKh6f6.mjs";
|
|
5
|
+
import { n as o, t as s } from "./ztBRZQwM.mjs";
|
|
6
6
|
import { isArray as c, isString as l, trace as u, warning as d } from "@web-utils/core";
|
|
7
7
|
import { computed as f, createVNode as p, getCurrentInstance as m, mergeProps as h, useModel as g, useTemplateRef as _ } from "vue";
|
|
8
8
|
import { useEventBus as v } from "@web-utils/vue/hooks/useEventBus";
|
|
9
9
|
//#region src/components/table/form-table-plus.ts
|
|
10
10
|
var y = {
|
|
11
|
-
...
|
|
12
|
-
...
|
|
11
|
+
...n,
|
|
12
|
+
...t,
|
|
13
13
|
...o,
|
|
14
14
|
rowDbClick: Function,
|
|
15
15
|
viewId: [String, Array],
|
|
@@ -17,11 +17,11 @@ var y = {
|
|
|
17
17
|
}, b = {
|
|
18
18
|
readonly: !0,
|
|
19
19
|
block: !0
|
|
20
|
-
}, x = (e) =>
|
|
20
|
+
}, x = (e) => n[e] === void 0 && b[e] !== !0, S = {
|
|
21
21
|
name: "FormTablePlus",
|
|
22
22
|
props: { ...y },
|
|
23
|
-
emits: { ...
|
|
24
|
-
setup(t, { emit:
|
|
23
|
+
emits: { ...r },
|
|
24
|
+
setup(t, { emit: n, slots: r, attrs: o, expose: y }) {
|
|
25
25
|
let b = g(t, "modelValue"), S = _("table"), C = [];
|
|
26
26
|
t.viewId && C.push(t.viewId);
|
|
27
27
|
let w = m();
|
|
@@ -43,13 +43,13 @@ var y = {
|
|
|
43
43
|
t.rowDbClick ? t.rowDbClick(...n) : w.proxy.$router.push(e(t.formPath, n[0]));
|
|
44
44
|
}, O = () => {
|
|
45
45
|
w.proxy.$router.push(e(t.formPath));
|
|
46
|
-
}, { render: k, placeholder: A, disabled: j, listeners: M, inputProps: N } =
|
|
46
|
+
}, { render: k, placeholder: A, disabled: j, listeners: M, inputProps: N } = i(t, {
|
|
47
47
|
rules: f(() => [t.fetchApi ? {
|
|
48
48
|
required: !0,
|
|
49
49
|
validator: a
|
|
50
50
|
} : { required: !0 }]),
|
|
51
|
-
emit:
|
|
52
|
-
slots:
|
|
51
|
+
emit: n,
|
|
52
|
+
slots: r,
|
|
53
53
|
attrs: o,
|
|
54
54
|
predicate: x,
|
|
55
55
|
block: t.block === void 0 ? !0 : t.block
|
|
@@ -60,14 +60,14 @@ var y = {
|
|
|
60
60
|
}), () => {
|
|
61
61
|
var e;
|
|
62
62
|
let n = {};
|
|
63
|
-
for (let
|
|
64
|
-
let e = t.columns[
|
|
65
|
-
n[e.prop] = ({ row: t, column: n, index:
|
|
63
|
+
for (let i = 0; i < (((e = t.columns) == null ? void 0 : e.length) ?? 0); i++) {
|
|
64
|
+
let e = t.columns[i];
|
|
65
|
+
n[e.prop] = ({ row: t, column: n, index: i, prop: a, required: o }) => {
|
|
66
66
|
var s;
|
|
67
|
-
return (s =
|
|
67
|
+
return (s = r[e.prop]) == null ? void 0 : s.call(r, {
|
|
68
68
|
row: t,
|
|
69
69
|
column: n,
|
|
70
|
-
index:
|
|
70
|
+
index: i,
|
|
71
71
|
prop: a,
|
|
72
72
|
required: o
|
|
73
73
|
});
|
|
@@ -86,18 +86,18 @@ var y = {
|
|
|
86
86
|
...n,
|
|
87
87
|
columns: ({ columns: e }) => {
|
|
88
88
|
var t;
|
|
89
|
-
return (t =
|
|
89
|
+
return (t = r.columns) == null ? void 0 : t.call(r, { columns: e });
|
|
90
90
|
},
|
|
91
91
|
handle: ({ add: e, remove: t }) => {
|
|
92
92
|
var n;
|
|
93
|
-
return (n =
|
|
93
|
+
return (n = r.handle) == null ? void 0 : n.call(r, {
|
|
94
94
|
add: e,
|
|
95
95
|
remove: t
|
|
96
96
|
});
|
|
97
97
|
},
|
|
98
98
|
tag: ({ column: e, row: t, $index: n }) => {
|
|
99
|
-
var
|
|
100
|
-
return (
|
|
99
|
+
var i;
|
|
100
|
+
return (i = r.tag) == null ? void 0 : i.call(r, {
|
|
101
101
|
column: e,
|
|
102
102
|
row: t,
|
|
103
103
|
index: n
|
|
@@ -105,26 +105,26 @@ var y = {
|
|
|
105
105
|
},
|
|
106
106
|
"handle-column-header": ({ column: e, $index: t }) => {
|
|
107
107
|
var n;
|
|
108
|
-
return (n =
|
|
108
|
+
return (n = r["handle-column-header"]) == null ? void 0 : n.call(r, {
|
|
109
109
|
column: e,
|
|
110
110
|
index: t
|
|
111
111
|
});
|
|
112
112
|
},
|
|
113
113
|
toolbar: () => {
|
|
114
114
|
var e;
|
|
115
|
-
return (e =
|
|
115
|
+
return (e = r.toolbar) == null ? void 0 : e.call(r);
|
|
116
116
|
},
|
|
117
117
|
"toolbar-left": ({ addRow: e, delRow: t, refresh: n }) => {
|
|
118
|
-
var
|
|
119
|
-
return (
|
|
118
|
+
var i;
|
|
119
|
+
return (i = r["toolbar-left"]) == null ? void 0 : i.call(r, {
|
|
120
120
|
addRow: e,
|
|
121
121
|
delRow: t,
|
|
122
122
|
refresh: n
|
|
123
123
|
});
|
|
124
124
|
},
|
|
125
125
|
"toolbar-left-append": ({ addRow: e, delRow: t, refresh: n }) => {
|
|
126
|
-
var
|
|
127
|
-
return (
|
|
126
|
+
var i;
|
|
127
|
+
return (i = r["toolbar-left-append"]) == null ? void 0 : i.call(r, {
|
|
128
128
|
addRow: e,
|
|
129
129
|
delRow: t,
|
|
130
130
|
refresh: n
|
|
@@ -132,7 +132,7 @@ var y = {
|
|
|
132
132
|
},
|
|
133
133
|
"toolbar-right": ({ selectedRows: e, removeSelectedRows: t }) => {
|
|
134
134
|
var n;
|
|
135
|
-
return (n =
|
|
135
|
+
return (n = r["toolbar-right"]) == null ? void 0 : n.call(r, {
|
|
136
136
|
selectedRows: e,
|
|
137
137
|
removeSelectedRows: t
|
|
138
138
|
});
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { n as e, o as t } from "./DEC2O0q-.mjs";
|
|
2
|
+
import { t as n } from "./DUhF8YOY.mjs";
|
|
3
|
+
import { allProps as r, predicate as i } from "../props/input-cron.mjs";
|
|
4
|
+
import { createVNode as a, mergeProps as o, ref as s } from "vue";
|
|
5
|
+
import { ElInput as c, ElPopover as l } from "element-plus/es";
|
|
6
|
+
//#endregion
|
|
7
|
+
//#region src/components/form/FormInputCronExpression.vue
|
|
8
|
+
var u = {
|
|
9
|
+
name: "FormInputCronExpression",
|
|
10
|
+
props: { ...r },
|
|
11
|
+
emits: { ...e },
|
|
12
|
+
setup(e, { emit: r, slots: u, attrs: d }) {
|
|
13
|
+
let f = s(!1), { emitInput: p, render: m, placeholder: h, disabled: g, listeners: _, inputProps: v } = t(e, {
|
|
14
|
+
emit: r,
|
|
15
|
+
slots: u,
|
|
16
|
+
attrs: d,
|
|
17
|
+
predicate: i
|
|
18
|
+
}), y = () => {
|
|
19
|
+
f.value = !0;
|
|
20
|
+
}, b = () => {
|
|
21
|
+
f.value = !1;
|
|
22
|
+
};
|
|
23
|
+
return () => m({ vNodes: a("div", { class: "cron" }, [a(l, {
|
|
24
|
+
placement: "bottom-start",
|
|
25
|
+
disabled: g.value,
|
|
26
|
+
visible: f.value,
|
|
27
|
+
"onUpdate:visible": (e) => f.value = e,
|
|
28
|
+
"popper-class": "cron-popover"
|
|
29
|
+
}, {
|
|
30
|
+
default: () => a(n, o(_.value, v.value, {
|
|
31
|
+
i18n: "cn",
|
|
32
|
+
expression: e.modelValue,
|
|
33
|
+
onChange: p,
|
|
34
|
+
onClose: b
|
|
35
|
+
}), null),
|
|
36
|
+
reference: () => a(c, {
|
|
37
|
+
modelValue: e.modelValue,
|
|
38
|
+
readonly: !0,
|
|
39
|
+
disabled: g.value,
|
|
40
|
+
placeholder: h.value,
|
|
41
|
+
onClick: y
|
|
42
|
+
}, null)
|
|
43
|
+
})]) });
|
|
44
|
+
}
|
|
45
|
+
};
|
|
46
|
+
//#endregion
|
|
47
|
+
export { u as t };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as e } from "./
|
|
1
|
+
import { t as e } from "./B1MSrc6f.mjs";
|
|
2
2
|
import { Fragment as t, createCommentVNode as n, createElementBlock as r, createElementVNode as i, createStaticVNode as a, createVNode as o, normalizeClass as s, normalizeStyle as c, openBlock as l, renderList as u, toDisplayString as d, withModifiers as f } from "vue";
|
|
3
3
|
import p from "dayjs";
|
|
4
4
|
//#region src/components/material-year-calendar/MonthCalendar.vue
|