vft 0.0.370 → 0.0.372

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.
Files changed (56) hide show
  1. package/dist/index.css +1 -1
  2. package/es/components/button/index.d.ts +9 -9
  3. package/es/components/carousel/use-carousel.js +1 -1
  4. package/es/components/form/form-item.vue.d.ts +1 -1
  5. package/es/components/form/form-item.vue2.js +3 -2
  6. package/es/components/form/index.d.ts +30 -30
  7. package/es/components/input/input.vue2.js +4 -4
  8. package/es/components/input-tag/composables/use-input-tag.js +1 -1
  9. package/es/components/popconfirm/index.d.ts +15 -15
  10. package/es/components/popconfirm/popconfirm.vue.d.ts +1 -1
  11. package/es/components/select/defaults.d.ts +7 -2
  12. package/es/components/select/defaults.js +3 -1
  13. package/es/components/select/option-item.vue.d.ts +12 -2
  14. package/es/components/select/select-dropdown.js +6 -6
  15. package/es/components/skeleton/index.d.ts +12 -0
  16. package/es/components/skeleton/skeleton-item.vue.d.ts +2 -0
  17. package/es/components/skeleton/skeleton-item.vue2.js +22 -16
  18. package/es/components/super-form/index.d.ts +5 -0
  19. package/es/components/super-form/super-form-action.vue2.js +42 -40
  20. package/es/components/super-form/super-form-item.vue2.js +312 -188
  21. package/es/components/super-form/super-form.vue.d.ts +2 -0
  22. package/es/components/super-form/super-form.vue2.js +64 -63
  23. package/es/components/super-form/types.d.ts +6 -0
  24. package/es/components/super-form/use/use-form-context.d.ts +1 -0
  25. package/es/package.json.d.ts +1 -1
  26. package/es/package.json.js +1 -1
  27. package/es/utils/vue/vnode.js +1 -1
  28. package/lib/components/button/index.d.ts +9 -9
  29. package/lib/components/form/form-item.vue.d.ts +1 -1
  30. package/lib/components/form/form-item.vue2.cjs +1 -1
  31. package/lib/components/form/index.d.ts +30 -30
  32. package/lib/components/input/input.vue2.cjs +1 -1
  33. package/lib/components/popconfirm/index.d.ts +15 -15
  34. package/lib/components/popconfirm/popconfirm.vue.d.ts +1 -1
  35. package/lib/components/select/defaults.cjs +1 -1
  36. package/lib/components/select/defaults.d.ts +7 -2
  37. package/lib/components/select/option-item.vue.d.ts +12 -2
  38. package/lib/components/select/select-dropdown.cjs +1 -1
  39. package/lib/components/skeleton/index.d.ts +12 -0
  40. package/lib/components/skeleton/skeleton-item.vue.d.ts +2 -0
  41. package/lib/components/skeleton/skeleton-item.vue2.cjs +1 -1
  42. package/lib/components/super-form/index.d.ts +5 -0
  43. package/lib/components/super-form/super-form-action.vue2.cjs +1 -1
  44. package/lib/components/super-form/super-form-item.vue2.cjs +1 -1
  45. package/lib/components/super-form/super-form.vue.d.ts +2 -0
  46. package/lib/components/super-form/super-form.vue2.cjs +1 -1
  47. package/lib/components/super-form/types.d.ts +6 -0
  48. package/lib/components/super-form/use/use-form-context.d.ts +1 -0
  49. package/lib/package.json.cjs +1 -1
  50. package/lib/package.json.d.ts +1 -1
  51. package/package.json +5 -5
  52. package/theme-style/index.css +1 -1
  53. package/theme-style/src/common/icon.scss +1 -0
  54. package/theme-style/src/super-form.scss +15 -0
  55. package/theme-style/vft-super-form.css +1 -1
  56. package/web-types.json +1 -1
@@ -1,24 +1,122 @@
1
- import { defineComponent as $, computed as v, ref as ee, unref as u, useSlots as te, createVNode as f, mergeProps as w, withDirectives as re, vShow as ne, isVNode as oe, createTextVNode as G, resolveComponent as q } from "vue";
1
+ import { defineComponent as Q, computed as v, ref as re, unref as c, useSlots as oe, createVNode as s, mergeProps as L, withDirectives as ie, vShow as ne, isVNode as le, createTextVNode as G, resolveComponent as V } from "vue";
2
+ import "../alert/index.js";
3
+ import "../avatar/index.js";
4
+ import "../avatar-stack/index.js";
5
+ import "../backtop/index.js";
6
+ import "../button/index.js";
7
+ import "../card/index.js";
8
+ import "../cascader/index.js";
9
+ import "../cascader-panel/index.js";
10
+ import "../check-tag/index.js";
11
+ import "../checkbox/index.js";
12
+ import "../clamp/index.js";
13
+ import "../clamp-toggle/index.js";
14
+ import "../clamp-tooltip/index.js";
2
15
  import { VftCol as X } from "../col/index.js";
3
- import { VftDivider as le } from "../divider/index.js";
4
- import { VftFormItem as se } from "../form/index.js";
16
+ import "../collapse-transition/index.js";
17
+ import "../color-picker/index.js";
18
+ import "../config-provider/index.js";
19
+ import "../container/index.js";
20
+ import { isFunction as b, isBoolean as j, singleAttrToObj as z, cloneDeep as se, isArray as J, isNull as ae, upperFirst as me, isString as ce } from "@vft/utils";
21
+ import "../context-menu/context-menu.vue2.js";
22
+ import { VftIcon as W } from "../icon/index.js";
23
+ import "../date-picker/index.js";
24
+ import "../date-time-select/index.js";
25
+ import "../descriptions/index.js";
26
+ import "../dialog/index.js";
27
+ import { VftDivider as pe } from "../divider/index.js";
28
+ import "../drawer/index.js";
29
+ import "../dropdown/index.js";
30
+ import "../empty/index.js";
31
+ import "../footer-layout/index.js";
32
+ import { VftFormItem as ue } from "../form/index.js";
33
+ import "../full-screen/index.js";
34
+ import "../header-layout/index.js";
35
+ import "../horizontal-menu/index.js";
36
+ import "../icon-text/index.js";
37
+ import "../iframe-layout/index.js";
38
+ import "../image/index.js";
39
+ import "../image-viewer/index.js";
40
+ import "../input/index.js";
41
+ import "../input-number/index.js";
42
+ import "../link/index.js";
43
+ import "../list-cell/index.js";
44
+ import "../logo/index.js";
45
+ import "../menu/index.js";
46
+ import "../multiple-tabs/index.js";
47
+ import "../notification/index.js";
48
+ import "../overlay/index.js";
49
+ import "../page-wrapper/index.js";
50
+ import "../pagination/index.js";
51
+ import "../popconfirm/index.js";
52
+ import "../popover/index.js";
53
+ import "../popper/index.js";
54
+ import "../qrcode/index.js";
55
+ import "../radio/index.js";
56
+ import "../result/index.js";
57
+ import "../router-view-content/index.js";
58
+ import "../row/index.js";
59
+ import "../scrollbar/index.js";
60
+ import "../search/index.js";
61
+ import "../select/index.js";
62
+ import "../side-menu/index.js";
63
+ import "../skeleton/index.js";
64
+ import "../slider/index.js";
65
+ import "../space/index.js";
66
+ import "../steps/index.js";
67
+ import "../switch/index.js";
68
+ import "../table/index.js";
69
+ import "../tabs/index.js";
70
+ import "../tag/index.js";
71
+ import "../time-picker/index.js";
72
+ import { VftTooltip as fe } from "../tooltip/index.js";
73
+ import "../tree/index.js";
74
+ import "../verify-code/index.js";
75
+ import "../virtual-list/components/fixed-size-list.js";
76
+ import "../virtual-list/components/dynamic-size-list.js";
77
+ import "../virtual-list/components/fixed-size-grid.js";
78
+ import "../virtual-list/components/dynamic-size-grid.js";
79
+ import "../virtual-list/props.js";
80
+ import "../autocomplete/index.js";
81
+ import "../breadcrumb/index.js";
82
+ import "../carousel/index.js";
83
+ import "../collapse/index.js";
84
+ import "../countdown/index.js";
85
+ import "../input-tag/index.js";
86
+ import "../modal/index.js";
87
+ import "../progress/index.js";
88
+ import "../segmented/index.js";
89
+ import "../statistic/index.js";
90
+ import "./index.js";
91
+ import "../timeline/index.js";
92
+ import "../transfer/index.js";
93
+ import "../upload/index.js";
94
+ import "../watermark/index.js";
95
+ import "../md-code-demo/index.js";
96
+ import "../md-code-tabs/index.js";
97
+ import "../md-comment/index.js";
98
+ import "../md-container/index.js";
99
+ import "../md-tabs/index.js";
100
+ import "../md-vue-playground/index.js";
101
+ import "../infinite-scroll/index.js";
5
102
  import "@vueuse/core";
6
- import { isFunction as R, isBoolean as j, cloneDeep as ie, isArray as J, isNull as ae, upperFirst as ce, isString as ue } from "@vft/utils";
7
103
  import "../config-provider/hooks/use-global-config.js";
8
104
  import "lodash-es";
9
- import { useNamespace as fe } from "../../hooks/use-namespace/index.js";
105
+ import { useNamespace as de } from "../../hooks/use-namespace/index.js";
10
106
  import "../../hooks/use-model-toggle/index.js";
11
107
  import "@popperjs/core";
12
108
  import "../../hooks/use-z-index/index.js";
13
- import { FormCompEnum as e, getComponent as z, isInput as de, isDatePicker as me, isRangePicker as he } from "./component-map.js";
14
- import { createPlaceholderMessage as W } from "./use/helper.js";
15
- function k(n) {
16
- return typeof n == "function" || Object.prototype.toString.call(n) === "[object Object]" && !oe(n);
109
+ import "../message/index.js";
110
+ import "../progress-i/index.js";
111
+ import { FormCompEnum as e, getComponent as $, isInput as he, isDatePicker as Ee, isRangePicker as Pe } from "./component-map.js";
112
+ import { createPlaceholderMessage as Y } from "./use/helper.js";
113
+ function q(o) {
114
+ return typeof o == "function" || Object.prototype.toString.call(o) === "[object Object]" && !le(o);
17
115
  }
18
- const pe = $({
116
+ const Ce = Q({
19
117
  inheritAttrs: !1
20
- }), De = /* @__PURE__ */ $({
21
- ...pe,
118
+ }), Tr = /* @__PURE__ */ Q({
119
+ ...Ce,
22
120
  __name: "super-form-item",
23
121
  props: {
24
122
  schema: {},
@@ -29,30 +127,30 @@ const pe = $({
29
127
  updateSchema: {},
30
128
  formActionType: {}
31
129
  },
32
- setup(n) {
33
- const N = fe("super-form"), P = v(() => {
130
+ setup(o) {
131
+ const S = de("super-form"), I = v(() => {
34
132
  const {
35
133
  mergeDynamicData: r
36
- } = n.formProps;
134
+ } = o.formProps;
37
135
  return {
38
- field: n.schema.field,
39
- model: n.formModel,
136
+ field: o.schema.field,
137
+ model: o.formModel,
40
138
  values: {
41
139
  ...r,
42
- ...n.allDefaultValues,
43
- ...n.formModel
140
+ ...o.allDefaultValues,
141
+ ...o.formModel
44
142
  },
45
- schema: n.schema,
46
- elRef: L
143
+ schema: o.schema,
144
+ elRef: w
47
145
  };
48
146
  }), K = v(() => {
49
147
  let {
50
148
  componentProps: r = {}
51
- } = n.schema;
52
- R(r) && (r = r({
53
- schema: n.schema,
54
- formModel: n.formModel,
55
- formActionType: n.formActionType
149
+ } = o.schema;
150
+ b(r) && (r = r({
151
+ schema: o.schema,
152
+ formModel: o.formModel,
153
+ formActionType: o.formActionType
56
154
  }) ?? {});
57
155
  const t = /* @__PURE__ */ new Map([[e.DIVIDER, {
58
156
  type: "horizontal"
@@ -97,276 +195,302 @@ const pe = $({
97
195
  "start-placeholder": "开始月份",
98
196
  "end-placeholder": "结束月份"
99
197
  }]]);
100
- return t.has(n.schema.type) && (r = Object.assign(t.get(n.schema.type) || {}, r)), n.formProps.inputMaxLength && [e.INPUT].includes(n.schema.type) && !r?.maxlength && (r.maxlength = n.formProps.inputMaxLength), r;
101
- }), Y = v(() => {
198
+ return t.has(o.schema.type) && (r = Object.assign(t.get(o.schema.type) || {}, r)), o.formProps.inputMaxLength && [e.INPUT].includes(o.schema.type) && !r?.maxlength && (r.maxlength = o.formProps.inputMaxLength), r;
199
+ }), Z = v(() => {
102
200
  const {
103
201
  disabled: r
104
- } = n.formProps, {
202
+ } = o.formProps, {
105
203
  dynamicDisabled: t
106
- } = n.schema, {
107
- disabled: a = !1
108
- } = u(K);
109
- let i = !!r || a;
110
- return j(t) && (i = t), R(t) && (i = t(u(P))), i;
204
+ } = o.schema, {
205
+ disabled: m = !1
206
+ } = c(K);
207
+ let a = !!r || m;
208
+ return j(t) && (a = t), b(t) && (a = t(c(I))), a;
111
209
  });
112
- function B() {
210
+ function k() {
113
211
  const {
114
212
  show: r,
115
213
  ifShow: t
116
- } = n.schema;
117
- let a = !0, i = !0;
118
- return j(r) && (a = r), j(t) && (i = t), R(r) && (a = r(u(P))), R(t) && (i = t(u(P))), {
119
- isShow: a,
120
- isIfShow: i
214
+ } = o.schema;
215
+ let m = !0, a = !0;
216
+ return j(r) && (m = r), j(t) && (a = t), b(r) && (m = r(c(I))), b(t) && (a = t(c(I))), {
217
+ isShow: m,
218
+ isIfShow: a
121
219
  };
122
220
  }
123
- function Q() {
221
+ function _() {
124
222
  const {
125
223
  rules: r = [],
126
224
  type: t = e.INPUT,
127
- rulesMessageJoinLabel: a,
128
- label: i,
129
- title: p,
130
- dynamicRule: c,
131
- required: g,
132
- dynamicRuleAdd: I = !0
133
- } = n.schema, m = i || p;
134
- if (R(c) && !I)
135
- return c(u(P));
136
- let o = ie(J(r) ? r : [r]);
225
+ rulesMessageJoinLabel: m,
226
+ label: a,
227
+ title: P,
228
+ dynamicRule: u,
229
+ required: h,
230
+ dynamicRuleAdd: f = !0
231
+ } = o.schema, p = a || P;
232
+ if (b(u) && !f)
233
+ return u(c(I));
234
+ let i = se(J(r) ? r : [r]);
137
235
  const {
138
- rulesMessageJoinLabel: b
139
- } = n.formProps, y = Reflect.has(n.schema, "rulesMessageJoinLabel") ? a : b, A = W(t, `${y ? m : ""}`);
140
- function M(l, s) {
141
- const D = l.message || A;
142
- return s === void 0 || ae(s) || t === e.CHECKBOX_SINGLE && !s || Array.isArray(s) && s.length === 0 || typeof s == "string" && s.trim() === "" || typeof s == "object" && Reflect.has(s, "checked") && Reflect.has(s, "halfChecked") && Array.isArray(s.checked) && Array.isArray(s.halfChecked) && s.checked.length === 0 && s.halfChecked.length === 0 ? Promise.reject(D) : Promise.resolve();
236
+ rulesMessageJoinLabel: g
237
+ } = o.formProps, y = Reflect.has(o.schema, "rulesMessageJoinLabel") ? m : g, A = Y(t, `${y ? p : ""}`);
238
+ function M(n, l) {
239
+ const D = n.message || A;
240
+ return l === void 0 || ae(l) || t === e.CHECKBOX_SINGLE && !l || Array.isArray(l) && l.length === 0 || typeof l == "string" && l.trim() === "" || typeof l == "object" && Reflect.has(l, "checked") && Reflect.has(l, "halfChecked") && Array.isArray(l.checked) && Array.isArray(l.halfChecked) && l.checked.length === 0 && l.halfChecked.length === 0 ? Promise.reject(D) : Promise.resolve();
143
241
  }
144
- const d = R(g) ? g(u(P)) : g, T = [e.RADIO, e.SELECT, e.RADIO, e.RADIO_SINGLE, e.RADIO_BUTTON, e.CHECKBOX, e.CHECKBOX_SINGLE, e.CHECKBOX_BUTTON, e.AUTOCOMPLETE, e.Cascader, e.ColorPicker, e.Upload, e.Slider].includes(t);
145
- d && (!o || o.length === 0 ? o = [{
242
+ const d = b(h) ? h(c(I)) : h, T = [e.RADIO, e.SELECT, e.RADIO, e.RADIO_SINGLE, e.RADIO_BUTTON, e.CHECKBOX, e.CHECKBOX_SINGLE, e.CHECKBOX_BUTTON, e.AUTOCOMPLETE, e.Cascader, e.ColorPicker, e.Upload, e.Slider].includes(t);
243
+ d && (!i || i.length === 0 ? i = [{
146
244
  required: d,
147
245
  validator: M,
148
246
  trigger: T ? "change" : "blur"
149
- }] : o.findIndex((s) => Reflect.has(s, "required")) === -1 && o.unshift({
247
+ }] : i.findIndex((l) => Reflect.has(l, "required")) === -1 && i.unshift({
150
248
  required: d,
151
249
  validator: M,
152
250
  trigger: T ? "change" : "blur"
153
251
  }));
154
- const S = o.findIndex((l) => Reflect.has(l, "required") && !Reflect.has(l, "validator"));
155
- if (S !== -1) {
156
- const l = o[S], {
157
- isShow: s
158
- } = B();
159
- s || (l.required = !1), t && (l.message = l.message || A);
252
+ const x = i.findIndex((n) => Reflect.has(n, "required") && !Reflect.has(n, "validator"));
253
+ if (x !== -1) {
254
+ const n = i[x], {
255
+ isShow: l
256
+ } = k();
257
+ l || (n.required = !1), t && (n.message = n.message || A);
160
258
  }
161
- const h = o.findIndex((l) => l.min), E = o.findIndex((l) => l.max);
162
- function C(l, s, D = "all") {
163
- const O = o[s], F = O.isNumber ? isNaN(l) ? l?.length || 0 : Number(l) : l?.length || 0;
164
- return ["min", "all"].includes(D) && F < O.min ? Promise.reject(m + "至少为" + O.min + "位") : ["max", "all"].includes(D) && F > O.max ? Promise.reject(m + "最多" + O.max + "位") : Promise.resolve();
259
+ const E = i.findIndex((n) => n.min), C = i.findIndex((n) => n.max);
260
+ function R(n, l, D = "all") {
261
+ const O = i[l], F = O.isNumber ? isNaN(n) ? n?.length || 0 : Number(n) : n?.length || 0;
262
+ return ["min", "all"].includes(D) && F < O.min ? Promise.reject(p + "至少为" + O.min + "位") : ["max", "all"].includes(D) && F > O.max ? Promise.reject(p + "最多" + O.max + "位") : Promise.resolve();
165
263
  }
166
- (h !== -1 || E !== -1) && (h !== -1 && E !== -1 && !o[h].validator && !o[h].message ? o[h].validator = (l, s) => C(s, h) : h !== -1 && !o[h].validator && !o[h].message ? o[h].validator = (l, s) => C(s, h, "min") : E !== -1 && !o[E].validator && !o[E].message && (o[E].validator = (l, s) => C(s, E, "max")));
167
- const x = o.findIndex((l) => l.len);
168
- if (x !== -1 && (o[x].validator = (l, s) => s.length !== o[x].len ? Promise.reject(m + "必须是" + o[x].len + "位") : Promise.resolve()), R(c) && I) {
169
- let l = c(u(P));
170
- l = J(l) ? l : [l], o = o.concat(l);
264
+ (E !== -1 || C !== -1) && (E !== -1 && C !== -1 && !i[E].validator && !i[E].message ? i[E].validator = (n, l) => R(l, E) : E !== -1 && !i[E].validator && !i[E].message ? i[E].validator = (n, l) => R(l, E, "min") : C !== -1 && !i[C].validator && !i[C].message && (i[C].validator = (n, l) => R(l, C, "max")));
265
+ const N = i.findIndex((n) => n.len);
266
+ if (N !== -1 && (i[N].validator = (n, l) => l.length !== i[N].len ? Promise.reject(p + "必须是" + i[N].len + "位") : Promise.resolve()), b(u) && f) {
267
+ let n = u(c(I));
268
+ n = J(n) ? n : [n], i = i.concat(n);
171
269
  }
172
- return o;
270
+ return i;
173
271
  }
174
- const L = ee(), Z = () => {
272
+ const w = re(), ee = () => {
175
273
  const {
176
274
  renderComponentContent: r,
177
275
  type: t = e.INPUT,
178
- field: a,
179
- changeEvent: i = "change",
180
- valueField: p,
181
- label: c,
182
- title: g,
183
- placeholderJoinLabel: I = !0
184
- } = n.schema;
185
- let m = i;
186
- de(t) ? m = "input" : me(t) || t === e.TIME_PICKER || [e.INPUT_TAG, e.AUTOCOMPLETE, e.Cascader, e.ColorPicker, e.Slider].includes(t) ? m = "update:modelValue" : t === e.Upload && (m = "update:fileList");
187
- const o = `on${ce(m)}`, b = {
188
- [o]: (...C) => {
189
- const [x] = C;
190
- d[o] && d[o](...C);
191
- const l = x ? x.target : null, s = l ? l.value : x;
192
- n.setFormModel(a, s, n.schema);
276
+ field: m,
277
+ changeEvent: a = "change",
278
+ valueField: P,
279
+ label: u,
280
+ title: h,
281
+ placeholderJoinLabel: f = !0
282
+ } = o.schema;
283
+ let p = a;
284
+ he(t) ? p = "input" : Ee(t) || t === e.TIME_PICKER || [e.INPUT_TAG, e.AUTOCOMPLETE, e.Cascader, e.ColorPicker, e.Slider].includes(t) ? p = "update:modelValue" : t === e.Upload && (p = "update:fileList");
285
+ const i = `on${me(p)}`, g = {
286
+ [i]: (...R) => {
287
+ const [N] = R;
288
+ d[i] && d[i](...R);
289
+ const n = N ? N.target : null, l = n ? n.value : N;
290
+ o.setFormModel(m, l, o.schema);
193
291
  }
194
- }, y = z(t), {
292
+ }, y = $(t), {
195
293
  autoSetPlaceHolder: A,
196
294
  size: M
197
- } = n.formProps, d = {
295
+ } = o.formProps, d = {
198
296
  clearable: !0,
199
- ...u(K)
297
+ ...c(K)
200
298
  };
201
- if ([e.SEARCH].includes(t) || (d.size = u(K)?.size || M, d.disabled = u(Y)), !d.disabled && A && !he(t) && t) {
202
- const C = c || g;
203
- d.placeholder = u(K)?.placeholder || W(t, I && ue(C) ? C : "");
299
+ if ([e.SEARCH].includes(t) || (d.size = c(K)?.size || M, d.disabled = c(Z)), !d.disabled && A && !Pe(t) && t) {
300
+ const R = u || h;
301
+ d.placeholder = c(K)?.placeholder || Y(t, f && ce(R) ? R : "");
204
302
  }
205
- const S = {
206
- [p || "model-value"]: n.formModel[a]
207
- }, h = {
208
- ...b,
303
+ const x = {
304
+ [P || "model-value"]: o.formModel[m]
305
+ }, E = {
306
+ ...g,
209
307
  ...d,
210
- ...S
308
+ ...x
211
309
  };
212
310
  if (!r && t !== e.Upload)
213
- return f(y, w({
214
- ref: L
215
- }, h), null);
216
- let E;
217
- if (E = R(r) ? {
311
+ return s(y, L({
312
+ ref: w
313
+ }, E), null);
314
+ let C;
315
+ if (C = b(r) ? {
218
316
  ...r({
219
- ...u(P),
220
- elRef: L
317
+ ...c(I),
318
+ elRef: w
221
319
  })
222
320
  } : {
223
321
  default: () => r
224
322
  }, t === e.Upload && !r) {
225
323
  const {
226
- drag: C
227
- } = u(K);
228
- E = C ? {
229
- default: () => f(q("vft-icon"), {
324
+ drag: R
325
+ } = c(K);
326
+ C = R ? {
327
+ default: () => s(V("vft-icon"), {
230
328
  icon: "icon-arrow-upload"
231
329
  }, null)
232
330
  } : {
233
- default: () => f(q("vft-button"), {
331
+ default: () => s(V("vft-button"), {
234
332
  type: "primary"
235
333
  }, {
236
- default: () => [f(q("vft-icon"), {
334
+ default: () => [s(V("vft-icon"), {
237
335
  icon: "icon-arrow-upload"
238
336
  }, null)]
239
337
  })
240
338
  };
241
339
  }
242
- return f(y, w({
243
- ref: L
244
- }, h), k(E) ? E : {
245
- default: () => [E]
340
+ return s(y, L({
341
+ ref: w
342
+ }, E), q(C) ? C : {
343
+ default: () => [C]
246
344
  });
247
345
  };
248
346
  function U() {
249
347
  const {
250
348
  showLabel: r = !0,
251
349
  label: t,
252
- title: a,
253
- subLabel: i,
254
- labelRequired: p
255
- } = n.schema;
256
- let c = t || a;
257
- return c = p ? f("span", null, [f("span", {
350
+ title: m,
351
+ subLabel: a,
352
+ labelRequired: P,
353
+ helpIcon: u,
354
+ helpTooltip: h
355
+ } = o.schema;
356
+ let f = t || m;
357
+ f = P ? s("span", null, [s("span", {
258
358
  class: "label-required"
259
- }, [G("*")]), f("span", null, [c])]) : c, r && c ? i ? f("span", null, [c, G(" "), f("span", {
359
+ }, [G("*")]), s("span", null, [f])]) : f;
360
+ const p = () => {
361
+ if (!u && !h) return null;
362
+ const i = v(() => z(u, "icon", {
363
+ size: 20,
364
+ pointer: !0,
365
+ icon: "icon-help"
366
+ }));
367
+ if (h) {
368
+ const g = v(() => z(h, "content", {
369
+ placement: "right-start"
370
+ }));
371
+ return s(fe, L({
372
+ className: "box-item"
373
+ }, g.value), {
374
+ default: () => [s(W, i.value, null)]
375
+ });
376
+ }
377
+ return s(W, i.value, null);
378
+ };
379
+ return r && f ? a ? s("div", {
380
+ class: "label-content"
381
+ }, [s("div", null, [f, G(" "), s("span", {
260
382
  class: "sub-label"
261
- }, [i])]) : c : void 0;
383
+ }, [a])]), p()]) : s("div", {
384
+ class: "label-content"
385
+ }, [s("div", null, [f]), p()]) : void 0;
262
386
  }
263
- const V = te();
264
- function H(r, t = "default", a) {
387
+ const B = oe();
388
+ function H(r, t = "default", m) {
265
389
  if (!r || !Reflect.has(r, t))
266
390
  return null;
267
- if (!R(r[t]))
391
+ if (!b(r[t]))
268
392
  return console.error(`${t} is not a function!`), null;
269
- const i = r[t];
270
- return i ? i(a) : null;
393
+ const a = r[t];
394
+ return a ? a(m) : null;
271
395
  }
272
- function _() {
396
+ function te() {
273
397
  const {
274
398
  itemProps: r,
275
399
  slot: t,
276
- render: a,
277
- field: i,
278
- suffix: p,
279
- prefix: c,
280
- prefixParentStyle: g
281
- } = n.schema, {
282
- autoCleanErrorMessage: I,
283
- compFullWidth: m
284
- } = n.formProps, o = () => t ? H(V, t, u(P)) : a ? a(u(P)) : Z(), b = !!p, y = !!c, A = R(p) ? p(u(P)) : p, M = R(c) ? c(u(P)) : c, d = () => {
285
- n.updateSchema([{
286
- field: i,
400
+ render: m,
401
+ field: a,
402
+ suffix: P,
403
+ prefix: u,
404
+ prefixParentStyle: h
405
+ } = o.schema, {
406
+ autoCleanErrorMessage: f,
407
+ compFullWidth: p
408
+ } = o.formProps, i = () => t ? H(B, t, c(I)) : m ? m(c(I)) : ee(), g = !!P, y = !!u, A = b(P) ? P(c(I)) : P, M = b(u) ? u(c(I)) : u, d = () => {
409
+ o.updateSchema([{
410
+ field: a,
287
411
  itemProps: {
288
412
  error: ""
289
413
  }
290
414
  }]);
291
- }, T = () => f(se, w({
415
+ }, T = () => s(ue, L({
292
416
  style: {
293
- marginRight: n.formProps.customLayout ? "10px" : 0
417
+ marginRight: o.formProps.customLayout ? "10px" : 0
294
418
  },
295
- prop: i,
419
+ prop: a,
296
420
  class: [{
297
- [N.is("suffix")]: b
421
+ [S.is("suffix")]: g
298
422
  }, {
299
- [N.is("comp-full-width")]: m
300
- }, N.e("item")]
423
+ [S.is("comp-full-width")]: p
424
+ }, S.e("item")]
301
425
  }, r, {
302
426
  label: r?.label || r?.title,
303
- "onUpdate:error": I ? d : () => {
427
+ "onUpdate:error": f ? d : () => {
304
428
  },
305
- rules: Q()
429
+ rules: _()
306
430
  }), {
307
- default: () => [f("div", {
308
- class: N.e("container")
309
- }, [f("div", {
310
- class: N.e("content")
311
- }, [o(), b && f("span", {
312
- class: N.m("suffix")
431
+ default: () => [s("div", {
432
+ class: S.e("container")
433
+ }, [s("div", {
434
+ class: S.e("content")
435
+ }, [i(), g && s("span", {
436
+ class: S.m("suffix")
313
437
  }, [A])])])],
314
438
  label: U() ? () => U() : void 0
315
439
  });
316
- return y ? f("div", {
317
- style: g
318
- }, [f("span", {
319
- class: N.m("prefix")
440
+ return y ? s("div", {
441
+ style: h
442
+ }, [s("span", {
443
+ class: S.m("prefix")
320
444
  }, [M]), T()]) : T();
321
445
  }
322
446
  return () => {
323
447
  let r;
324
448
  const {
325
449
  colProps: t = {},
326
- colSlot: a,
327
- renderColContent: i,
328
- type: p = e.INPUT,
329
- render: c,
330
- quickColSpan: g
331
- } = n.schema;
332
- if (!z(p) && !i && !c)
450
+ colSlot: m,
451
+ renderColContent: a,
452
+ type: P = e.INPUT,
453
+ render: u,
454
+ quickColSpan: h
455
+ } = o.schema;
456
+ if (!$(P) && !a && !u)
333
457
  return null;
334
458
  const {
335
- baseColProps: I = {},
336
- quickColSpan: m
337
- } = n.formProps, o = m ? {
338
- span: Math.ceil(24 / m),
339
- ...I
459
+ baseColProps: f = {},
460
+ quickColSpan: p
461
+ } = o.formProps, i = p ? {
462
+ span: Math.ceil(24 / p),
463
+ ...f
340
464
  } : {
341
- ...I
342
- }, b = g ? {
343
- span: Math.ceil(24 / g),
465
+ ...f
466
+ }, g = h ? {
467
+ span: Math.ceil(24 / h),
344
468
  ...t
345
469
  } : {
346
470
  ...t
347
471
  }, y = {
348
- ...o,
349
- ...b
472
+ ...i,
473
+ ...g
350
474
  }, {
351
475
  isIfShow: A,
352
476
  isShow: M
353
- } = B(), d = u(P), T = () => a ? H(V, a, d) : i ? i(d) : _();
354
- if (p === e.DIVIDER) {
355
- let S;
356
- return f(X, w({
477
+ } = k(), d = c(I), T = () => m ? H(B, m, d) : a ? a(d) : te();
478
+ if (P === e.DIVIDER) {
479
+ let x;
480
+ return s(X, L({
357
481
  span: 24
358
- }, b), {
359
- default: () => [f(le, u(K), k(S = U()) ? S : {
360
- default: () => [S]
482
+ }, g), {
483
+ default: () => [s(pe, c(K), q(x = U()) ? x : {
484
+ default: () => [x]
361
485
  })]
362
486
  });
363
487
  }
364
- return A && (n.formProps.customLayout ? T() : re(f(X, y, k(r = T()) ? r : {
488
+ return A && (o.formProps.customLayout ? T() : ie(s(X, y, q(r = T()) ? r : {
365
489
  default: () => [r]
366
490
  }), [[ne, M]]));
367
491
  };
368
492
  }
369
493
  });
370
494
  export {
371
- De as default
495
+ Tr as default
372
496
  };