@web-utils/component 4.0.15 → 4.0.16
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/address-input/index.mjs +13 -15
- package/card/index.mjs +18 -20
- package/carousel/index.mjs +10 -12
- package/chat/index.mjs +45 -56
- package/chunk-file-uploader/index.mjs +36 -378
- package/chunk-file-uploader/style.css +1 -1
- package/chunks/ElementBaseInfo.ZADwixb5.mjs +125 -0
- package/chunks/ElementForm.CQ3PN5qj.mjs +223 -0
- package/chunks/ElementListeners.De_PRuIm.mjs +215 -0
- package/chunks/ElementMultiInstance.DQo2wuAQ.mjs +181 -0
- package/chunks/ElementOtherConfig.B1NfMTYh.mjs +60 -0
- package/chunks/ElementProperties.CosfDrlW.mjs +112 -0
- package/chunks/{ElementTaskConfig.AvBOzAni.mjs → ElementTaskConfig.Bko0kgTp.mjs} +55 -63
- package/chunks/FlowCondition.Y6qEYi1T.mjs +102 -0
- package/chunks/FormTemp.BQxO5IQq.mjs +123 -0
- package/chunks/SignalAndMessage.Bb5PFX0N.mjs +85 -0
- package/chunks/UserTaskListeners.Bv3BDfEI.mjs +169 -0
- package/chunks/{confirmable-mixin.BFZb6pcK.mjs → confirmable-mixin.B2TtLAdk.mjs} +1 -1
- package/chunks/core.0Exl13Mz.mjs +54 -0
- package/chunks/{dataformat.DJoNBlmI.mjs → dataformat.CpqOeGBl.mjs} +6 -6
- package/chunks/{dic.BinnDitI.mjs → dic.Dkl-leRW.mjs} +9 -9
- package/chunks/dictionary.DGt59Ir7.mjs +68 -0
- package/chunks/{event.DSlcqYHL.mjs → event.9aDS6jcw.mjs} +2 -2
- package/chunks/{form-input.BtS_J5a2.mjs → form-input.CvFdwlEV.mjs} +2 -2
- package/chunks/form-item.LWjePsPa.mjs +233 -0
- package/chunks/{index.CIfe3UB3.mjs → index.9OxHjTIE.mjs} +2 -2
- package/chunks/{index.Cn7aq-Et.mjs → index.B2TRddqf.mjs} +8 -8
- package/chunks/{init.xOlFpTyZ.mjs → init.DAsXSoLW.mjs} +2 -2
- package/chunks/sub-table-plus-props.BVsD71hT.mjs +30 -0
- package/chunks/{util.DI42t5GU.mjs → util.DqFv_pWg.mjs} +22 -22
- package/chunks/utilSelf.Csq1766E.mjs +48 -0
- package/chunks/utils.DRcxC1Fb.mjs +60 -0
- package/color-picker/index.mjs +22 -101
- package/confirm-button/index.mjs +1 -1
- package/confirmable/index.mjs +1 -1
- package/data-box/index.mjs +12 -15
- package/data-card/index.mjs +10 -12
- package/data-card-text/index.mjs +10 -12
- package/data-display/index.mjs +15 -17
- package/data-icons/index.mjs +13 -16
- package/data-imgtext/index.mjs +15 -18
- package/data-operatext/index.mjs +14 -16
- package/data-panel/index.mjs +13 -16
- package/data-pay/index.mjs +16 -20
- package/data-price/index.mjs +14 -16
- package/data-progress/index.mjs +13 -17
- package/data-rotate/index.mjs +12 -15
- package/data-table-picker/index.mjs +15 -18
- package/data-tabs/index.mjs +12 -15
- package/dialog-form/index.mjs +16 -18
- package/dynamic-table/index.mjs +25 -30
- package/editable-progress/index.mjs +9 -11
- package/editable-tree/index.mjs +52 -56
- package/egd-collapse-item/index.mjs +9 -9
- package/element-dialog/index.mjs +22 -23
- package/element-listeners/style.css +1 -0
- package/element-multi-instance/style.css +1 -0
- package/flex-column/index.mjs +1 -1
- package/flex-item/index.mjs +1 -1
- package/flex-row/index.mjs +1 -1
- package/flow/index.mjs +10 -11
- package/flow-designer/index.mjs +699 -1973
- package/flow-designer/style.css +1 -1
- package/flow-node/index.mjs +1 -1
- package/flow-viewer/index.mjs +9 -9
- package/form-block/index.mjs +32 -34
- package/form-cascader/index.mjs +23 -24
- package/form-checkbox/index.mjs +16 -17
- package/form-checkbox-group/index.mjs +20 -23
- package/form-date-picker/index.mjs +18 -20
- package/form-holder/index.mjs +13 -14
- package/form-input/index.mjs +14 -15
- package/form-input-cron-expression/index.mjs +19 -22
- package/form-input-email/index.mjs +15 -16
- package/form-input-id-card/index.mjs +12 -13
- package/form-input-number/index.mjs +16 -17
- package/form-input-phone-number/index.mjs +21 -22
- package/form-input-tag/index.mjs +14 -15
- package/form-input-time/index.mjs +14 -15
- package/form-item/index.mjs +140 -3
- package/form-item-group/index.mjs +28 -31
- package/form-radio-group/index.mjs +27 -28
- package/form-select/index.mjs +21 -23
- package/form-switch/index.mjs +16 -17
- package/form-table/index.mjs +16 -17
- package/form-table-plus/index.mjs +21 -22
- package/form-textarea/index.mjs +15 -16
- package/form-tree-select/index.mjs +14 -15
- package/form-tree-select-multiple/index.mjs +14 -15
- package/form-view/index.mjs +35 -39
- package/fy-array/index.mjs +33 -37
- package/fy-cascader/index.mjs +16 -17
- package/fy-checkbox/index.mjs +11 -13
- package/fy-code/index.mjs +10 -10
- package/fy-curd/index.mjs +1128 -1152
- package/fy-date/index.mjs +10 -11
- package/fy-draggable/index.mjs +9 -10
- package/fy-dynamic/index.mjs +22 -25
- package/fy-empty/index.mjs +1 -1
- package/fy-form/index.mjs +638 -15
- package/fy-form-design/index.mjs +1307 -1345
- package/fy-from/crud/zh.d.ts +6 -6
- package/fy-input/index.mjs +12 -14
- package/fy-input-color/index.mjs +13 -15
- package/fy-input-icon/index.mjs +20 -23
- package/fy-input-map/index.mjs +28 -31
- package/fy-input-number/index.mjs +9 -10
- package/fy-input-table/index.mjs +18 -22
- package/fy-input-tree/index.mjs +33 -37
- package/fy-progress/index.mjs +9 -10
- package/fy-radio/index.mjs +15 -16
- package/fy-rate/index.mjs +10 -11
- package/fy-select/index.mjs +25 -29
- package/fy-slider/index.mjs +11 -12
- package/fy-switch/index.mjs +9 -10
- package/fy-tabs/index.mjs +15 -17
- package/fy-time/index.mjs +1 -1
- package/fy-title/index.mjs +1 -1
- package/fy-tree/index.mjs +18 -24
- package/fy-u-editor/index.mjs +1 -1
- package/fy-upload/index.mjs +74 -76
- package/guide-steps/index.mjs +11 -13
- package/iframe-window/index.mjs +9 -10
- package/image-cropper/index.mjs +28 -30
- package/image-preview/index.mjs +12 -14
- package/index.mjs +72 -72
- package/input-number/index.mjs +13 -14
- package/input-number-range/index.mjs +11 -12
- package/license/index.mjs +1 -1
- package/login/index.mjs +21 -26
- package/nav-bar/index.mjs +9 -10
- package/notice/index.mjs +9 -10
- package/package.json +1 -1
- package/page-index/index.mjs +12 -13
- package/page-index-top/index.mjs +23 -28
- package/page-skeleton/index.mjs +14 -14
- package/page-skeleton-new/index.mjs +8 -9
- package/pageable-table/index.mjs +172 -182
- package/pageable-view/index.mjs +15 -16
- package/picker-table-view/index.mjs +49 -58
- package/present-view/index.mjs +35 -39
- package/record-video/index.mjs +1 -1
- package/resize-observer/index.mjs +1 -1
- package/search/index.mjs +20 -22
- package/search-popover/index.mjs +1 -1
- package/sign/index.mjs +1 -1
- package/skeleton-panel/index.mjs +9 -10
- package/split-pane/index.mjs +36 -37
- package/static-pageable-table/index.mjs +11 -13
- package/sub-table/index.mjs +36 -49
- package/sub-table-plus/index.mjs +229 -18
- package/swiper/index.mjs +11 -12
- package/table-column/index.mjs +223 -3
- package/table-view/index.mjs +52 -60
- package/tabs-view/index.mjs +17 -19
- package/tag-render/index.mjs +16 -18
- package/text-ellipsis/index.mjs +9 -10
- package/toolbar/index.mjs +13 -14
- package/toolbar-button/index.mjs +13 -14
- package/verify/index.mjs +1 -1
- package/vue-cron/index.mjs +259 -267
- package/watermark/index.mjs +1 -1
- package/web-types.json +1 -1
- package/x-input-tag/index.mjs +21 -24
- package/chunks/FormItem.Bhsy_O2B.mjs +0 -372
- package/chunks/FyForm.DriwCJ7b.mjs +0 -765
- package/chunks/SignalAndMessage.BpjOoKhK.mjs +0 -92
- package/chunks/SubTablePlus.BH0IIv3X.mjs +0 -270
- package/chunks/TableColumn.BzivvXMF.mjs +0 -337
package/form-item/index.mjs
CHANGED
|
@@ -1,5 +1,142 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import "../chunks/
|
|
1
|
+
import { h as m } from "vue";
|
|
2
|
+
import { f as B } from "../chunks/form-item.LWjePsPa.mjs";
|
|
3
|
+
import { hasOwn as I, isDef as D } from "@web-utils/core";
|
|
4
|
+
import { n as L } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
|
|
5
|
+
const N = {
|
|
6
|
+
name: "FormItem",
|
|
7
|
+
mixins: [B],
|
|
8
|
+
inject: {
|
|
9
|
+
formHolder: {
|
|
10
|
+
default: {}
|
|
11
|
+
},
|
|
12
|
+
formItemConfig: {
|
|
13
|
+
default: null
|
|
14
|
+
}
|
|
15
|
+
},
|
|
16
|
+
computed: {
|
|
17
|
+
gutter() {
|
|
18
|
+
let e = this.$parent;
|
|
19
|
+
for (; e && e.$options.componentName !== "ElRow"; )
|
|
20
|
+
e = e.$parent;
|
|
21
|
+
return (e == null ? void 0 : e.gutter) ?? 0;
|
|
22
|
+
}
|
|
23
|
+
},
|
|
24
|
+
methods: {
|
|
25
|
+
renderFormItem() {
|
|
26
|
+
var x, k, R, y, E, T, H;
|
|
27
|
+
const {
|
|
28
|
+
hideLabel: e,
|
|
29
|
+
label: l,
|
|
30
|
+
labelWidth: u,
|
|
31
|
+
prop: t,
|
|
32
|
+
rules: p,
|
|
33
|
+
$scopedSlots: r,
|
|
34
|
+
elFormItemProps: i,
|
|
35
|
+
elForm: n,
|
|
36
|
+
formHolder: a,
|
|
37
|
+
formItemClass: c,
|
|
38
|
+
required: f,
|
|
39
|
+
block: h,
|
|
40
|
+
half: w,
|
|
41
|
+
wrapCol: W,
|
|
42
|
+
wrapFormItem: P,
|
|
43
|
+
disabled: V,
|
|
44
|
+
formItemConfig: s,
|
|
45
|
+
getRequireRule: j
|
|
46
|
+
} = this;
|
|
47
|
+
let o = p, d = f, b = f, v = h, g = W;
|
|
48
|
+
s && (I(s, "block") && (v = s.block), I(s, "wrapCol") && (g = s.wrapCol));
|
|
49
|
+
const z = a.tableForm ? "" : v && w && g ? `calc( 50% - ${this.gutter / 2}px)` : "";
|
|
50
|
+
(x = a.requiredFields) != null && x.includes(t) && (d = !0), (V || n != null && n.disabled) && !((k = a.requiredFields) != null && k.includes(t)) ? (o = [], !a.required && !((R = a.requiredFields) != null && R.includes(t)) && (b = !1)) : (!a.required && !((y = a.requiredFields) != null && y.includes(t)) && (d = !1), d && !(o != null && o.length) && t ? o = [j()] : d || (b = !1, o && (o = o.filter((C) => !C.required))));
|
|
51
|
+
const F = (E = r.tips) == null ? void 0 : E.call(r), q = F || this.tips, _ = q ? m("ElTooltip", {
|
|
52
|
+
attrs: {
|
|
53
|
+
effect: "light",
|
|
54
|
+
content: this.tips
|
|
55
|
+
}
|
|
56
|
+
}, [F ? m("div", {
|
|
57
|
+
slot: "content"
|
|
58
|
+
}, [F]) : null, m("i", {
|
|
59
|
+
class: "el-icon-info form-item-input-info"
|
|
60
|
+
})]) : null;
|
|
61
|
+
return P ? m("ElFormItem", {
|
|
62
|
+
style: {
|
|
63
|
+
width: z
|
|
64
|
+
},
|
|
65
|
+
key: `${t}-${d}`,
|
|
66
|
+
class: ["form-item", c, {
|
|
67
|
+
required: b,
|
|
68
|
+
"form-item-hide-label": e
|
|
69
|
+
}],
|
|
70
|
+
scopedSlots: {
|
|
71
|
+
...r,
|
|
72
|
+
default: q ? () => {
|
|
73
|
+
var C;
|
|
74
|
+
return m("div", {
|
|
75
|
+
class: "form-item-input-wrapper"
|
|
76
|
+
}, [(C = r.default) == null ? void 0 : C.call(r), _]);
|
|
77
|
+
} : r.default
|
|
78
|
+
},
|
|
79
|
+
props: {
|
|
80
|
+
...i
|
|
81
|
+
},
|
|
82
|
+
attrs: {
|
|
83
|
+
label: l,
|
|
84
|
+
"label-width": e ? "0" : u,
|
|
85
|
+
prop: t,
|
|
86
|
+
rules: o
|
|
87
|
+
},
|
|
88
|
+
ref: "formItem"
|
|
89
|
+
}) : q ? m("div", {
|
|
90
|
+
class: "form-item-input-wrapper"
|
|
91
|
+
}, [(T = r.default) == null ? void 0 : T.call(r), _]) : m("div", [(H = r.default) == null ? void 0 : H.call(r)]);
|
|
92
|
+
},
|
|
93
|
+
async clearValidate() {
|
|
94
|
+
var e, l;
|
|
95
|
+
await this.$nextTick(), (l = (e = this.$refs.formItem).clearValidate) == null || l.call(e);
|
|
96
|
+
},
|
|
97
|
+
async validate() {
|
|
98
|
+
var e, l;
|
|
99
|
+
await this.$nextTick(), (l = (e = this.$refs.formItem).validate) == null || l.call(e);
|
|
100
|
+
}
|
|
101
|
+
},
|
|
102
|
+
render() {
|
|
103
|
+
var h, w;
|
|
104
|
+
const {
|
|
105
|
+
computeSpan: e,
|
|
106
|
+
wrapCol: l,
|
|
107
|
+
fixedSpan: u,
|
|
108
|
+
formItemConfig: t,
|
|
109
|
+
renderFormItem: p,
|
|
110
|
+
elColProps: r,
|
|
111
|
+
$scopedSlots: i,
|
|
112
|
+
unwrap: n,
|
|
113
|
+
formHolder: a
|
|
114
|
+
} = this;
|
|
115
|
+
let c = !a.tableForm && l, f = !1;
|
|
116
|
+
return t && (I(t, "wrapCol") && (c = t.wrapCol), I(t, "reactive") && (f = t.reactive)), n ? m("div", [(h = i.default) == null ? void 0 : h.call(i)]) : c ? m("ElCol", {
|
|
117
|
+
props: {
|
|
118
|
+
...r,
|
|
119
|
+
span: u || e,
|
|
120
|
+
...!D(u) && f ? {
|
|
121
|
+
xs: 24,
|
|
122
|
+
sm: 12,
|
|
123
|
+
md: 12,
|
|
124
|
+
lg: 8,
|
|
125
|
+
xl: 6
|
|
126
|
+
} : {}
|
|
127
|
+
}
|
|
128
|
+
}, [p(), (w = i == null ? void 0 : i.below) == null ? void 0 : w.call(i)]) : p();
|
|
129
|
+
}
|
|
130
|
+
}, O = null, A = null;
|
|
131
|
+
var G = /* @__PURE__ */ L(
|
|
132
|
+
N,
|
|
133
|
+
O,
|
|
134
|
+
A,
|
|
135
|
+
!1,
|
|
136
|
+
null,
|
|
137
|
+
null
|
|
138
|
+
);
|
|
139
|
+
const U = G.exports;
|
|
3
140
|
export {
|
|
4
|
-
|
|
141
|
+
U as default
|
|
5
142
|
};
|
|
@@ -1,9 +1,6 @@
|
|
|
1
|
-
import a from "element-ui/lib/transitions/collapse-transition";
|
|
2
|
-
import d from "../empty-view/index.mjs";
|
|
3
|
-
import n from "element-ui/lib/row";
|
|
4
1
|
import { h as s } from "vue";
|
|
5
|
-
import { n as
|
|
6
|
-
const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth", "hideRequiredAsterisk", "$emit", "validate", "clearValidate"],
|
|
2
|
+
import { n as a } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
|
|
3
|
+
const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth", "hideRequiredAsterisk", "$emit", "validate", "clearValidate"], d = ["$emit", "validate", "clearValidate"], n = {
|
|
7
4
|
name: "FormItemGroup",
|
|
8
5
|
inject: {
|
|
9
6
|
elForm: {
|
|
@@ -42,23 +39,23 @@ const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
|
|
|
42
39
|
notDispatch: Boolean
|
|
43
40
|
},
|
|
44
41
|
data() {
|
|
45
|
-
const
|
|
46
|
-
return r.forEach((
|
|
47
|
-
t
|
|
42
|
+
const e = {};
|
|
43
|
+
return r.forEach((t) => {
|
|
44
|
+
e[t] = null;
|
|
48
45
|
}), {
|
|
49
46
|
expand: !0,
|
|
50
|
-
proxyForm:
|
|
47
|
+
proxyForm: e
|
|
51
48
|
};
|
|
52
49
|
},
|
|
53
50
|
computed: {
|
|
54
51
|
formCfg() {
|
|
55
|
-
const
|
|
52
|
+
const e = {
|
|
56
53
|
enabled: this.enabled,
|
|
57
54
|
forbidden: this.disabled
|
|
58
55
|
};
|
|
59
|
-
return r.forEach((
|
|
60
|
-
t
|
|
61
|
-
}),
|
|
56
|
+
return r.forEach((t) => {
|
|
57
|
+
e[t] = this.elForm[t];
|
|
58
|
+
}), e;
|
|
62
59
|
},
|
|
63
60
|
isDisabled() {
|
|
64
61
|
return this.disabled ? this.disabled : this.enabled ? !this.enabled : this.elForm.disabled;
|
|
@@ -67,16 +64,16 @@ const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
|
|
|
67
64
|
watch: {
|
|
68
65
|
collapse: {
|
|
69
66
|
immediate: !0,
|
|
70
|
-
handler(
|
|
71
|
-
this.expand = !
|
|
67
|
+
handler(e) {
|
|
68
|
+
this.expand = !e;
|
|
72
69
|
}
|
|
73
70
|
},
|
|
74
71
|
formCfg: {
|
|
75
72
|
immediate: !0,
|
|
76
73
|
handler() {
|
|
77
|
-
this.proxyForm.disabled = this.isDisabled, r.forEach((
|
|
78
|
-
var
|
|
79
|
-
|
|
74
|
+
this.proxyForm.disabled = this.isDisabled, r.forEach((e) => {
|
|
75
|
+
var t;
|
|
76
|
+
e !== "disabled" && (d.includes(e) ? this.proxyForm[e] = (t = this.elForm[e]) == null ? void 0 : t.bind(this.elForm) : this.proxyForm[e] = this.elForm[e]);
|
|
80
77
|
}), this.size && (this.proxyForm.size = this.size);
|
|
81
78
|
}
|
|
82
79
|
}
|
|
@@ -88,14 +85,14 @@ const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
|
|
|
88
85
|
this.notDispatch || this.dispatch("FormView", "FormView.removeGroup", [this]);
|
|
89
86
|
},
|
|
90
87
|
methods: {
|
|
91
|
-
dispatch(
|
|
88
|
+
dispatch(e, t, l) {
|
|
92
89
|
let i = this.$parent || this.$root, o = i.$options.name;
|
|
93
|
-
for (; i && (!o || o !==
|
|
90
|
+
for (; i && (!o || o !== e); )
|
|
94
91
|
i = i.$parent, i && (o = i.$options.name);
|
|
95
|
-
i && i.$emit.apply(i, [
|
|
92
|
+
i && i.$emit.apply(i, [t].concat(l));
|
|
96
93
|
},
|
|
97
94
|
renderDefault() {
|
|
98
|
-
return this.$scopedSlots.default ? !this.formHolder.tableForm && this.wrapRow ? s(
|
|
95
|
+
return this.$scopedSlots.default ? !this.formHolder.tableForm && this.wrapRow ? s("ElRow", {
|
|
99
96
|
attrs: {
|
|
100
97
|
gutter: this.gutter
|
|
101
98
|
}
|
|
@@ -103,7 +100,7 @@ const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
|
|
|
103
100
|
disabled: this.proxyForm.disabled
|
|
104
101
|
})]) : this.$scopedSlots.default({
|
|
105
102
|
disabled: this.proxyForm.disabled
|
|
106
|
-
}) : s(
|
|
103
|
+
}) : s("EmptyView", {
|
|
107
104
|
attrs: {
|
|
108
105
|
"font-size": "14px",
|
|
109
106
|
"empty-tips": "暂无信息"
|
|
@@ -138,23 +135,23 @@ const r = ["disabled", "size", "statusIcon", "inlineMessage", "autoLabelWidth",
|
|
|
138
135
|
style: "color:#ff0000;font-size:14px;"
|
|
139
136
|
}, [" (", this.tips, ")"]) : null, this.$scopedSlots["title-right"] ? this.$scopedSlots["title-right"]() : null]), " ", s("i", {
|
|
140
137
|
class: this.expand ? "el-icon-arrow-down" : "el-icon-arrow-right"
|
|
141
|
-
})]), s(
|
|
138
|
+
})]), s("ElCollapseTransition", [s("div", {
|
|
142
139
|
directives: [{
|
|
143
140
|
name: "show",
|
|
144
141
|
value: this.expand
|
|
145
142
|
}]
|
|
146
143
|
}, [this.renderDefault()])])]);
|
|
147
144
|
}
|
|
148
|
-
},
|
|
149
|
-
var
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
145
|
+
}, h = null, p = null;
|
|
146
|
+
var m = /* @__PURE__ */ a(
|
|
147
|
+
n,
|
|
148
|
+
h,
|
|
149
|
+
p,
|
|
153
150
|
!1,
|
|
154
151
|
null,
|
|
155
152
|
null
|
|
156
153
|
);
|
|
157
|
-
const
|
|
154
|
+
const f = m.exports;
|
|
158
155
|
export {
|
|
159
|
-
|
|
156
|
+
f as default
|
|
160
157
|
};
|
|
@@ -1,13 +1,12 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
|
|
8
|
-
const h = u(i).filter((o) => !["value", "placeholder", "disabled"].includes(o)), m = {
|
|
1
|
+
import { f as n } from "../chunks/form-input.CvFdwlEV.mjs";
|
|
2
|
+
import { f as l } from "../chunks/form-pick.BFTIVn_i.mjs";
|
|
3
|
+
import a from "element-ui/lib/radio-group";
|
|
4
|
+
import { c as s, d as u, n as p } from "../chunks/index.B2TRddqf.mjs";
|
|
5
|
+
import { d } from "../chunks/dictionary.DqiP9x2m.mjs";
|
|
6
|
+
import { n as c } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
|
|
7
|
+
const f = s(a).filter((t) => !["value", "placeholder", "disabled"].includes(t)), h = {
|
|
9
8
|
name: "FormRadioGroup",
|
|
10
|
-
mixins: [
|
|
9
|
+
mixins: [n, l, d],
|
|
11
10
|
props: {
|
|
12
11
|
options: {
|
|
13
12
|
type: Array,
|
|
@@ -53,7 +52,7 @@ const h = u(i).filter((o) => !["value", "placeholder", "disabled"].includes(o)),
|
|
|
53
52
|
return "请选择";
|
|
54
53
|
},
|
|
55
54
|
inputProps() {
|
|
56
|
-
return
|
|
55
|
+
return u({ ...p(this.$attrs), ...this.$props }, f);
|
|
57
56
|
},
|
|
58
57
|
labelKey() {
|
|
59
58
|
return this.classic ? "label" : this.labelProp;
|
|
@@ -84,40 +83,40 @@ const h = u(i).filter((o) => !["value", "placeholder", "disabled"].includes(o)),
|
|
|
84
83
|
}
|
|
85
84
|
},
|
|
86
85
|
methods: {
|
|
87
|
-
emitInput(
|
|
88
|
-
this.$emit("input",
|
|
86
|
+
emitInput(t) {
|
|
87
|
+
this.$emit("input", t);
|
|
89
88
|
},
|
|
90
|
-
toggle(
|
|
91
|
-
this.value ===
|
|
89
|
+
toggle(t) {
|
|
90
|
+
this.value === t[this.valueKey] ? this.emitInput(null) : this.emitInput(t[this.valueKey]);
|
|
92
91
|
}
|
|
93
92
|
}
|
|
94
93
|
};
|
|
95
|
-
var
|
|
94
|
+
var m = function() {
|
|
96
95
|
var e = this, r = e._self._c;
|
|
97
|
-
return r(
|
|
98
|
-
return [r(
|
|
99
|
-
return r(e.component, { key:
|
|
100
|
-
return
|
|
101
|
-
} } }, [e._v(" " + e._s(
|
|
102
|
-
}) : e._l(e.innerOptions, function(
|
|
103
|
-
return r(e.component, { key:
|
|
96
|
+
return r("FormItem", e._b({ class: ["form-radio-group", { "form-radio-group-row": e.fillRow, inline: e.inline }, e.ellipsis ? "form-radio-group-row-ellipsis" : "form-radio-group-row-break-word"], attrs: { rules: e.computeRules, disabled: e.inputDisabled }, scopedSlots: e._u([{ key: "default", fn: function() {
|
|
97
|
+
return [r("ElRadioGroup", e._g(e._b({ class: { "over-flow": e.overFlow }, attrs: { value: e.value, disabled: e.inputDisabled, placeholder: e.computePlaceholder }, on: { input: (o) => e.$emit("input", o) } }, "ElRadioGroup", e.inputProps, !1), e.listeners), [e.allowCancel ? e._l(e.innerOptions, function(o) {
|
|
98
|
+
return r(e.component, { key: o[e.valueKey], tag: "Component", attrs: { border: e.border, label: o[e.valueKey] }, nativeOn: { click: function(i) {
|
|
99
|
+
return i.preventDefault(), i.stopPropagation(), e.toggle(o);
|
|
100
|
+
} } }, [e._v(" " + e._s(o[e.labelKey]) + " ")]);
|
|
101
|
+
}) : e._l(e.innerOptions, function(o) {
|
|
102
|
+
return r(e.component, { key: o[e.valueKey], tag: "Component", attrs: { border: e.border, label: o[e.valueKey] } }, [e._v(" " + e._s(o[e.labelKey]) + " ")]);
|
|
104
103
|
})], 2), e._t("append")];
|
|
105
|
-
}, proxy: !0 }, { key: "error", fn: function({ error:
|
|
106
|
-
return [e._t("error", null, { error:
|
|
104
|
+
}, proxy: !0 }, { key: "error", fn: function({ error: o }) {
|
|
105
|
+
return [e._t("error", null, { error: o })];
|
|
107
106
|
} }, { key: "label", fn: function() {
|
|
108
107
|
return [e._t("label")];
|
|
109
108
|
}, proxy: !0 }, { key: "below", fn: function() {
|
|
110
109
|
return [e._t("below")];
|
|
111
110
|
}, proxy: !0 }], null, !0) }, "FormItem", e.formItemProps, !1));
|
|
112
|
-
},
|
|
111
|
+
}, y = [], g = /* @__PURE__ */ c(
|
|
112
|
+
h,
|
|
113
113
|
m,
|
|
114
114
|
y,
|
|
115
|
-
_,
|
|
116
115
|
!1,
|
|
117
116
|
null,
|
|
118
117
|
null
|
|
119
118
|
);
|
|
120
|
-
const
|
|
119
|
+
const P = g.exports;
|
|
121
120
|
export {
|
|
122
|
-
|
|
121
|
+
P as default
|
|
123
122
|
};
|
package/form-select/index.mjs
CHANGED
|
@@ -1,15 +1,13 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
|
|
9
|
-
import { n as _ } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
|
|
10
|
-
const y = h(o).filter((e) => !["value", "placeholder", "disabled"].includes(e)), g = {
|
|
1
|
+
import { f as o } from "../chunks/form-input.CvFdwlEV.mjs";
|
|
2
|
+
import { f as l } from "../chunks/form-pick.BFTIVn_i.mjs";
|
|
3
|
+
import { d as n } from "../chunks/dictionary.DqiP9x2m.mjs";
|
|
4
|
+
import a from "element-ui/lib/select";
|
|
5
|
+
import { c as p, d as u, n as h } from "../chunks/index.B2TRddqf.mjs";
|
|
6
|
+
import { isString as m, isPlainObject as f, isNumber as c } from "@web-utils/core";
|
|
7
|
+
import { n as d } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
|
|
8
|
+
const b = p(a).filter((e) => !["value", "placeholder", "disabled"].includes(e)), y = {
|
|
11
9
|
name: "FormSelect",
|
|
12
|
-
mixins: [
|
|
10
|
+
mixins: [o, l, n],
|
|
13
11
|
props: {
|
|
14
12
|
options: {
|
|
15
13
|
type: Array,
|
|
@@ -61,7 +59,7 @@ const y = h(o).filter((e) => !["value", "placeholder", "disabled"].includes(e)),
|
|
|
61
59
|
return "请选择";
|
|
62
60
|
},
|
|
63
61
|
inputProps() {
|
|
64
|
-
return
|
|
62
|
+
return u({ ...h(this.$attrs), ...this.$props }, b);
|
|
65
63
|
},
|
|
66
64
|
innerOptions() {
|
|
67
65
|
if (this.dictType)
|
|
@@ -100,7 +98,7 @@ const y = h(o).filter((e) => !["value", "placeholder", "disabled"].includes(e)),
|
|
|
100
98
|
if (this.year) {
|
|
101
99
|
const e = (/* @__PURE__ */ new Date()).getFullYear(), t = [];
|
|
102
100
|
let i = 10;
|
|
103
|
-
|
|
101
|
+
c(this.year) && (i = this.year);
|
|
104
102
|
for (let r = -i; r <= i; r++) {
|
|
105
103
|
const s = e + r;
|
|
106
104
|
t.push({
|
|
@@ -133,7 +131,7 @@ const y = h(o).filter((e) => !["value", "placeholder", "disabled"].includes(e)),
|
|
|
133
131
|
try {
|
|
134
132
|
this.loading = !0;
|
|
135
133
|
const i = await this.remoteMethod(e, this.prop);
|
|
136
|
-
((t = i.data.data) == null ? void 0 : t.length) >= 0 ?
|
|
134
|
+
((t = i.data.data) == null ? void 0 : t.length) >= 0 ? m(i.data.data[0]) ? this.remoteOptions = i.data.data.map((r) => ({ [this.props.value]: r, [this.props.label]: r })) : f(i.data.data[0]) && (this.remoteOptions = i.data.data) : this.remoteOptions = [];
|
|
137
135
|
} catch {
|
|
138
136
|
}
|
|
139
137
|
this.loading = !1;
|
|
@@ -146,13 +144,13 @@ const y = h(o).filter((e) => !["value", "placeholder", "disabled"].includes(e)),
|
|
|
146
144
|
}
|
|
147
145
|
}
|
|
148
146
|
};
|
|
149
|
-
var
|
|
147
|
+
var _ = function() {
|
|
150
148
|
var t = this, i = t._self._c;
|
|
151
|
-
return i(
|
|
152
|
-
return [i(
|
|
149
|
+
return i("FormItem", t._b({ attrs: { rules: t.computeRules, disabled: t.inputDisabled }, scopedSlots: t._u([{ key: "default", fn: function() {
|
|
150
|
+
return [i("ElSelect", t._g(t._b({ attrs: { value: t.innerValue, filterable: t.filterable || !!t.year, placeholder: t.inputDisabled ? "--" : t.computePlaceholder, "allow-create": t.allowCreate || !!t.year, disabled: t.inputDisabled, multiple: t.multiple, "multiple-limit": t.multipleLimit, loading: t.loading, remote: t.remote, "remote-method": t.fetchOptions, clearable: "" }, on: { clear: t.reloadOptions, input: t.emitInput } }, "ElSelect", t.inputProps, !1), t.listeners), [t._t("default", function() {
|
|
153
151
|
return [t._l(t.innerOptions, function(r) {
|
|
154
152
|
return [t._t("option", function() {
|
|
155
|
-
return [i(
|
|
153
|
+
return [i("ElOption", { key: r[t.props.value], attrs: { value: r[t.props.value], label: r[t.props.label] } })];
|
|
156
154
|
}, { value: r[t.props.value], label: r[t.props.label] })];
|
|
157
155
|
})];
|
|
158
156
|
})], 2), t.$slots.warn ? i("div", { staticClass: "el-form-item__warn" }, [t._t("warn")], 2) : t._e()];
|
|
@@ -167,15 +165,15 @@ var v = function() {
|
|
|
167
165
|
}, proxy: !0 }, { key: "tips", fn: function() {
|
|
168
166
|
return [t._t("tips")];
|
|
169
167
|
}, proxy: !0 }], null, !0) }, "FormItem", t.formItemProps, !1));
|
|
170
|
-
},
|
|
168
|
+
}, g = [], v = /* @__PURE__ */ d(
|
|
169
|
+
y,
|
|
170
|
+
_,
|
|
171
171
|
g,
|
|
172
|
-
v,
|
|
173
|
-
S,
|
|
174
172
|
!1,
|
|
175
173
|
null,
|
|
176
174
|
null
|
|
177
175
|
);
|
|
178
|
-
const
|
|
176
|
+
const k = v.exports;
|
|
179
177
|
export {
|
|
180
|
-
|
|
178
|
+
k as default
|
|
181
179
|
};
|
package/form-switch/index.mjs
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
const m = u(n).filter((t) => !["value", "placeholder", "disabled"].includes(t)), c = {
|
|
1
|
+
import { f as o } from "../chunks/form-input.CvFdwlEV.mjs";
|
|
2
|
+
import l from "element-ui/lib/switch";
|
|
3
|
+
import { c as a, d as u, n as i } from "../chunks/index.B2TRddqf.mjs";
|
|
4
|
+
import { n as s } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
|
|
5
|
+
const p = a(l).filter((t) => !["value", "placeholder", "disabled"].includes(t)), c = {
|
|
7
6
|
name: "FormSwitch",
|
|
8
|
-
mixins: [
|
|
7
|
+
mixins: [o],
|
|
9
8
|
props: {
|
|
10
9
|
value: [String, Number, Boolean],
|
|
11
10
|
activeValue: {
|
|
@@ -19,7 +18,7 @@ const m = u(n).filter((t) => !["value", "placeholder", "disabled"].includes(t)),
|
|
|
19
18
|
},
|
|
20
19
|
computed: {
|
|
21
20
|
inputProps() {
|
|
22
|
-
return
|
|
21
|
+
return u({ ...i(this.$attrs), ...this.$props }, p);
|
|
23
22
|
}
|
|
24
23
|
},
|
|
25
24
|
methods: {
|
|
@@ -28,28 +27,28 @@ const m = u(n).filter((t) => !["value", "placeholder", "disabled"].includes(t)),
|
|
|
28
27
|
}
|
|
29
28
|
}
|
|
30
29
|
};
|
|
31
|
-
var
|
|
30
|
+
var m = function() {
|
|
32
31
|
var e = this, r = e._self._c;
|
|
33
|
-
return r(
|
|
32
|
+
return r("FormItem", e._b({ attrs: { rules: e.computeRules, disabled: e.inputDisabled }, scopedSlots: e._u([{ key: "default", fn: function() {
|
|
34
33
|
return [e._t("default", function() {
|
|
35
|
-
return [r(
|
|
34
|
+
return [r("ElSwitch", e._g(e._b({ class: { "is-readonly": e.readonly }, attrs: { "active-value": e.activeValue, "inactive-value": e.inactiveValue, value: e.value, readonly: e.readonly, disabled: e.inputDisabled, placeholder: e.computePlaceholder }, on: { input: e.emitInput }, scopedSlots: e._u([{ key: "append", fn: function() {
|
|
36
35
|
return [e._t("append")];
|
|
37
36
|
}, proxy: !0 }], null, !0) }, "ElSwitch", e.inputProps, !1), e.listeners))];
|
|
38
37
|
})];
|
|
39
|
-
}, proxy: !0 }, { key: "error", fn: function({ error:
|
|
40
|
-
return [e._t("error", null, { error:
|
|
38
|
+
}, proxy: !0 }, { key: "error", fn: function({ error: n }) {
|
|
39
|
+
return [e._t("error", null, { error: n })];
|
|
41
40
|
} }, { key: "label", fn: function() {
|
|
42
41
|
return [e._t("label")];
|
|
43
42
|
}, proxy: !0 }], null, !0) }, "FormItem", e.formItemProps, !1));
|
|
44
|
-
}, d = [],
|
|
43
|
+
}, d = [], f = /* @__PURE__ */ s(
|
|
45
44
|
c,
|
|
46
|
-
|
|
45
|
+
m,
|
|
47
46
|
d,
|
|
48
47
|
!1,
|
|
49
48
|
null,
|
|
50
49
|
null
|
|
51
50
|
);
|
|
52
|
-
const
|
|
51
|
+
const b = f.exports;
|
|
53
52
|
export {
|
|
54
|
-
|
|
53
|
+
b as default
|
|
55
54
|
};
|
package/form-table/index.mjs
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
import
|
|
2
|
-
import {
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
|
|
6
|
-
const p = Object.keys(u.props).filter((l) => !["value", "placeholder", "disabled"].includes(l)), f = {
|
|
1
|
+
import { f as a } from "../chunks/form-input.CvFdwlEV.mjs";
|
|
2
|
+
import { d as s, n as d } from "../chunks/index.B2TRddqf.mjs";
|
|
3
|
+
import m from "../sub-table/index.mjs";
|
|
4
|
+
import { n as c } from "../chunks/_plugin-vue2_normalizer.CeySl7Fu.mjs";
|
|
5
|
+
const i = Object.keys(m.props).filter((l) => !["value", "placeholder", "disabled"].includes(l)), p = {
|
|
7
6
|
name: "FormTable",
|
|
8
|
-
mixins: [
|
|
7
|
+
mixins: [a],
|
|
9
8
|
emits: ["add-row"],
|
|
10
9
|
props: {
|
|
11
10
|
value: Array,
|
|
@@ -40,7 +39,7 @@ const p = Object.keys(u.props).filter((l) => !["value", "placeholder", "disabled
|
|
|
40
39
|
},
|
|
41
40
|
computed: {
|
|
42
41
|
inputProps() {
|
|
43
|
-
return
|
|
42
|
+
return s({ ...d(this.$attrs), ...this.$props }, i);
|
|
44
43
|
}
|
|
45
44
|
},
|
|
46
45
|
methods: {
|
|
@@ -49,12 +48,12 @@ const p = Object.keys(u.props).filter((l) => !["value", "placeholder", "disabled
|
|
|
49
48
|
}
|
|
50
49
|
}
|
|
51
50
|
};
|
|
52
|
-
var
|
|
51
|
+
var f = function() {
|
|
53
52
|
var e = this, r = e._self._c;
|
|
54
|
-
return r(
|
|
55
|
-
return [r(
|
|
56
|
-
return { key: n.prop, fn: function({ row: o, column: t, index:
|
|
57
|
-
return [e._t(n.prop, null, { row: o, column: t, index:
|
|
53
|
+
return r("FormItem", e._b({ attrs: { block: e.block, rules: e.computeRules, disabled: e.inputDisabled }, scopedSlots: e._u([{ key: "default", fn: function() {
|
|
54
|
+
return [r("SubTable", e._g(e._b({ class: { "is-readonly": e.readonly }, attrs: { status: e.status, value: e.value, prop: e.prop, editable: e.editable, columns: e.columns, readonly: e.readonly, "allow-empty": e.allowEmpty, disabled: e.inputDisabled, "handle-column": e.handleColumn, "show-handle-column-add-button": e.showHandleColumnAddButton, "show-empty-add-button": e.showEmptyAddButton, placeholder: e.computePlaceholder }, on: { "selection-change": e.onSelectionChange, input: (n) => e.$emit("input", n) }, scopedSlots: e._u([e._l(e.columns, function(n) {
|
|
55
|
+
return { key: n.prop, fn: function({ row: o, column: t, index: u }) {
|
|
56
|
+
return [e._t(n.prop, null, { row: o, column: t, index: u })];
|
|
58
57
|
} };
|
|
59
58
|
}), { key: "columns", fn: function({ columns: n }) {
|
|
60
59
|
return [e._t("columns", null, { columns: n })];
|
|
@@ -72,15 +71,15 @@ var y = function() {
|
|
|
72
71
|
} }, { key: "label", fn: function() {
|
|
73
72
|
return [e._t("label")];
|
|
74
73
|
}, proxy: !0 }], null, !0) }, "FormItem", e.formItemProps, !1));
|
|
75
|
-
},
|
|
74
|
+
}, y = [], b = /* @__PURE__ */ c(
|
|
75
|
+
p,
|
|
76
76
|
f,
|
|
77
77
|
y,
|
|
78
|
-
h,
|
|
79
78
|
!1,
|
|
80
79
|
null,
|
|
81
80
|
null
|
|
82
81
|
);
|
|
83
|
-
const
|
|
82
|
+
const B = b.exports;
|
|
84
83
|
export {
|
|
85
|
-
|
|
84
|
+
B as default
|
|
86
85
|
};
|