@vue-start/element-pro 0.2.38 → 0.2.40

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/dist/index.es.js CHANGED
@@ -1,31 +1,31 @@
1
- import { createExpose as $e, createFormItemCompFn as dt, useProConfig as ce, createExposeObj as L, useGetCompByKey as He, ElementKeys as p, ProForm as U, ProSearchForm as Y, ProFormList as me, ProTable as ee, ProDesc as te, ProCurdDesc as ye, ProCurdForm as se, ProCurdModal as ge, ProUploaderText as ve, ProTip as he, ProCurd as it, ProList as ft, ProPage as mt, ProOperate as yt, ProShowText as be, ProShowDigit as st, ProShowDate as gt, ProShowOptions as Q, ProShowTree as pe } from "@vue-start/pro";
2
- import { ElFormItem as ae, ElForm as ne, ElLoading as qe, ElDialog as Se, ElDrawer as Pe, ElPagination as Ce, ElPopover as Ke, ElCheckboxGroup as we, ElCheckboxButton as vt, ElCheckbox as Ge, ElRadioGroup as xe, ElRadioButton as ht, ElRadio as bt, ElSelect as ke, ElOption as pt, ElTabs as Ee, ElTabPane as St, ElMenu as H, ElUpload as Re, useFormItem as Pt, ElInputNumber as $, ElTree as Fe, ElDropdown as Te, ElDropdownMenu as Ct, ElDropdownItem as Kt, ElInput as wt, ElDatePicker as xt, ElTimePicker as kt, ElTreeSelect as Et, ElSwitch as Rt, ElCascader as Ft, ElColorPicker as Tt, ElTableColumn as le, ElTable as Me, ElButton as re, ElTableV2 as Ie, ElDescriptions as _e, ElTooltip as Ze, ElRow as Mt, ElCol as It, ElDescriptionsItem as Vt, ElScrollbar as Bt, ElEmpty as Nt } from "element-plus";
3
- import { defineComponent as x, createVNode as c, mergeProps as s, reactive as Je, ref as R, toRaw as Ot, computed as E, Fragment as Qe, isVNode as Dt, nextTick as Lt } from "vue";
4
- import { keys as V, omit as v, isBoolean as q, isString as zt, debounce as At, map as T, size as D, pick as G, get as N, isNumber as z, isArray as Xe, filter as oe, reduce as X, isFunction as Ut, forEach as Ve, find as jt, last as Wt } from "lodash";
5
- import { useEffect as _, generateId as $t, useWatch as j, convertCollection as Ht, isValidFileType as qt, convertFileSize as Be, isSame as Gt, getNameMapByMergeOpts as _t, useUpdateKey as Zt, useResizeObserver as Jt } from "@vue-start/hooks";
6
- const Ne = () => ({
1
+ import { createExpose as at, createFormItemCompFn as pt, useProConfig as fe, createExposeObj as D, useGetCompByKey as lt, ElementKeys as V, ProForm as W, ProSearchForm as ae, ProFormList as ve, ProTable as le, ProDesc as ne, ProCurdDesc as be, ProCurdForm as Se, ProCurdModal as pe, ProUploaderText as Pe, ProTip as Ve, ProCurd as Pt, ProList as Vt, ProPage as Ct, ProOperate as xt, ProShowText as Ce, ProShowDigit as Kt, ProShowDate as kt, ProShowOptions as Z, ProShowTree as xe } from "@vue-start/pro";
2
+ import { ElFormItem as re, ElForm as oe, ElLoading as nt, ElDialog as Ke, ElDrawer as ke, ElPagination as Fe, ElPopover as we, ElCheckboxGroup as Ee, ElCheckboxButton as Ft, ElCheckbox as rt, ElRadioGroup as Te, ElRadioButton as wt, ElRadio as Et, ElSelect as Re, ElOption as Tt, ElSelectV2 as $e, ElTabs as Me, ElTabPane as Rt, ElMenu as Q, ElUpload as Ne, useFormItem as $t, ElInputNumber as J, ElTree as Ie, ElDropdown as Oe, ElDropdownMenu as Mt, ElDropdownItem as Nt, ElTreeSelect as Be, ElCascader as Ae, ElInput as It, ElDatePicker as Ot, ElTimePicker as Bt, ElSwitch as At, ElColorPicker as Lt, ElTableColumn as ue, ElTable as Le, ElButton as de, ElTableV2 as De, ElDescriptions as ot, ElTooltip as ut, ElRow as Dt, ElCol as Ut, ElDescriptionsItem as zt, ElScrollbar as jt, ElEmpty as Wt } from "element-plus";
3
+ import { defineComponent as k, createVNode as f, mergeProps as y, reactive as dt, ref as T, toRaw as Ht, computed as x, Fragment as ct, isVNode as qt, nextTick as Gt } from "vue";
4
+ import { keys as $, omit as h, isBoolean as X, isString as _t, debounce as Zt, map as E, get as w, size as L, pick as Y, isNumber as U, isArray as j, filter as ce, last as ie, reduce as te, isFunction as Jt, forEach as Ue, find as Qt } from "lodash";
5
+ import { useEffect as ee, generateId as Xt, useWatch as H, parseValue as q, formatValue as G, createExposeObj as se, convertCollection as Yt, isValidFileType as ea, convertFileSize as ze, findTreeItem as je, isSame as ta, getNameMapByMergeOpts as aa, useUpdateKey as la, useResizeObserver as na } from "@vue-start/hooks";
6
+ const We = () => ({
7
7
  name: {
8
8
  type: [String, Array]
9
9
  }
10
- }), Ye = x({
10
+ }), it = k({
11
11
  props: {
12
- ...ae.props,
13
- ...Ne()
12
+ ...re.props,
13
+ ...We()
14
14
  },
15
15
  setup: (e, {
16
16
  slots: t
17
17
  }) => {
18
- const u = V(Ne());
19
- return () => c(ae, s(v(e, ...u, "name", "prop"), {
18
+ const o = $(We());
19
+ return () => f(re, y(h(e, ...o, "name", "prop"), {
20
20
  prop: e.prop || e.name
21
21
  }), {
22
22
  label: e.label ? () => e.label : void 0,
23
23
  ...t
24
24
  });
25
25
  }
26
- }), et = ["clearValidate", "resetFields", "scrollToField", "validate", "validateField", "submit"], Qt = x({
26
+ }), mt = ["clearValidate", "resetFields", "scrollToField", "validate", "validateField", "submit"], ra = k({
27
27
  props: {
28
- ...ne.props,
28
+ ...oe.props,
29
29
  hideRequiredMark: {
30
30
  type: [Boolean, Object],
31
31
  default: void 0
@@ -33,30 +33,30 @@ const Ne = () => ({
33
33
  },
34
34
  setup: (e, {
35
35
  slots: t,
36
- emit: u,
37
- expose: a
36
+ emit: o,
37
+ expose: n
38
38
  }) => {
39
- const o = e.model || Je({}), n = R();
40
- return _(() => {
41
- !n.value || (n.value.submit = () => {
42
- var l;
43
- (l = n.value) == null || l.validate((f, r) => {
44
- f ? u("finish", Ot(o)) : u("finishFailed", r);
39
+ const u = e.model || dt({}), l = T();
40
+ return ee(() => {
41
+ !l.value || (l.value.submit = () => {
42
+ var d;
43
+ (d = l.value) == null || d.validate((s, c) => {
44
+ s ? o("finish", Ht(u)) : o("finishFailed", c);
45
45
  });
46
46
  });
47
- }, []), a($e(et, n)), () => c(ne, s({
48
- ref: n
49
- }, v(e, "model"), {
50
- hideRequiredAsterisk: q(e.hideRequiredMark) ? e.hideRequiredMark : e.hideRequiredAsterisk,
51
- model: o
47
+ }, []), n(at(mt, l)), () => f(oe, y({
48
+ ref: l
49
+ }, h(e, "model"), {
50
+ hideRequiredAsterisk: X(e.hideRequiredMark) ? e.hideRequiredMark : e.hideRequiredAsterisk,
51
+ model: u
52
52
  }), t);
53
53
  }
54
- }), B = dt(Ye, (e, t, u) => ({
54
+ }), M = pt(it, (e, t, o) => ({
55
55
  modelValue: e,
56
56
  "onUpdate:modelValue": t,
57
57
  clearable: !0,
58
- disabled: u
59
- })), tt = (e = "comp") => e + "-" + $t(), Xt = () => ({
58
+ disabled: o
59
+ })), ft = (e = "comp") => e + "-" + Xt(), oa = () => ({
60
60
  loading: {
61
61
  type: Boolean
62
62
  },
@@ -84,22 +84,22 @@ const Ne = () => ({
84
84
  customClass: {
85
85
  type: String
86
86
  }
87
- }), at = x({
87
+ }), st = k({
88
88
  props: {
89
- ...Xt()
89
+ ...oa()
90
90
  },
91
91
  setup: (e, {
92
92
  slots: t
93
93
  }) => {
94
- const u = tt();
95
- return _(() => {
94
+ const o = ft();
95
+ return ee(() => {
96
96
  if (!e.loading)
97
97
  return;
98
- let a = e.target;
99
- if (t.default ? a = document.getElementById(u) : e.target && zt(e.target) && (a = document.querySelector("#" + e.target)), !a)
98
+ let n = e.target;
99
+ if (t.default ? n = document.getElementById(o) : e.target && _t(e.target) && (n = document.querySelector("#" + e.target)), !n)
100
100
  return;
101
- const o = qe.service({
102
- target: a,
101
+ const u = nt.service({
102
+ target: n,
103
103
  body: e.body,
104
104
  fullscreen: e.fullscreen,
105
105
  lock: e.lock,
@@ -109,13 +109,13 @@ const Ne = () => ({
109
109
  customClass: e.customClass
110
110
  });
111
111
  return () => {
112
- o && o.close();
112
+ u && u.close();
113
113
  };
114
- }, () => e.loading), () => t.default ? c("div", {
115
- id: u
114
+ }, () => e.loading), () => t.default ? f("div", {
115
+ id: o
116
116
  }, [t.default()]) : null;
117
117
  }
118
- }), ue = () => ({
118
+ }), me = () => ({
119
119
  clsName: {
120
120
  type: String,
121
121
  default: "pro-modal"
@@ -146,9 +146,9 @@ const Ne = () => ({
146
146
  type: Boolean,
147
147
  default: !1
148
148
  }
149
- }), nt = x({
149
+ }), yt = k({
150
150
  props: {
151
- ...Se.props,
151
+ ...Ke.props,
152
152
  appendToBody: {
153
153
  type: Boolean,
154
154
  default: !0
@@ -157,65 +157,65 @@ const Ne = () => ({
157
157
  type: Boolean,
158
158
  default: !0
159
159
  },
160
- ...ue()
160
+ ...me()
161
161
  },
162
162
  setup: (e, {
163
163
  slots: t,
164
- emit: u,
165
- expose: a
164
+ emit: o,
165
+ expose: n
166
166
  }) => {
167
167
  const {
168
- t: o
169
- } = ce(), n = R();
170
- a(L(n));
171
- const l = (g) => {
172
- u("update:modelValue", g), u("update:visible", g), g || (u("cancel"), u("closed"));
173
- }, f = () => {
174
- l(!1);
175
- }, r = () => {
176
- u("ok");
177
- }, m = He(), d = m(p.ProOperateKey), i = m(p.ScrollKey), P = E(() => [{
168
+ t: u
169
+ } = fe(), l = T();
170
+ n(D(l));
171
+ const d = (g) => {
172
+ o("update:modelValue", g), o("update:visible", g), g || (o("cancel"), o("closed"));
173
+ }, s = () => {
174
+ d(!1);
175
+ }, c = () => {
176
+ o("ok");
177
+ }, a = lt(), m = a(V.ProOperateKey), r = a(V.ScrollKey), i = x(() => [{
178
178
  value: "cancel",
179
- label: o.value("cancel"),
180
- onClick: f
179
+ label: u.value("cancel"),
180
+ onClick: s
181
181
  }, {
182
182
  value: "ok",
183
- label: o.value("confirm"),
183
+ label: u.value("confirm"),
184
184
  loading: e.confirmLoading,
185
185
  extraProps: {
186
186
  type: "primary"
187
187
  },
188
- onClick: r
189
- }]), w = V(ue());
188
+ onClick: c
189
+ }]), S = $(me());
190
190
  return () => {
191
191
  const g = [e.clsName];
192
- return e.useScroll && g.push("scroll"), c(Se, s({
192
+ return e.useScroll && g.push("scroll"), f(Ke, y({
193
193
  class: g,
194
- ref: n
195
- }, v(e, ...w), {
196
- closeOnClickModal: q(e.maskClosable) ? e.maskClosable : e.closeOnClickModal,
194
+ ref: l
195
+ }, h(e, ...S), {
196
+ closeOnClickModal: X(e.maskClosable) ? e.maskClosable : e.closeOnClickModal,
197
197
  modelValue: e.visible || e.modelValue,
198
- "onUpdate:modelValue": l
198
+ "onUpdate:modelValue": d
199
199
  }), {
200
- footer: e.footer === !1 ? void 0 : () => c(d, {
201
- items: P.value
200
+ footer: e.footer === !1 ? void 0 : () => f(m, {
201
+ items: i.value
202
202
  }, null),
203
203
  ...t,
204
204
  default: () => {
205
- var k;
206
- return e.useScroll ? c(i, s({
205
+ var K;
206
+ return e.useScroll ? f(r, y({
207
207
  class: `${e.clsName}-scroll`
208
208
  }, e.scrollProps), {
209
209
  default: () => {
210
- var F;
211
- return [(F = t.default) == null ? void 0 : F.call(t)];
210
+ var R;
211
+ return [(R = t.default) == null ? void 0 : R.call(t)];
212
212
  }
213
- }) : (k = t.default) == null ? void 0 : k.call(t);
213
+ }) : (K = t.default) == null ? void 0 : K.call(t);
214
214
  }
215
215
  });
216
216
  };
217
217
  }
218
- }), Yt = () => ({
218
+ }), ua = () => ({
219
219
  clsName: {
220
220
  type: String,
221
221
  default: "pro-drawer"
@@ -242,10 +242,10 @@ const Ne = () => ({
242
242
  type: Boolean,
243
243
  default: !1
244
244
  }
245
- }), ea = x({
245
+ }), da = k({
246
246
  props: {
247
- ...Pe.props,
248
- ...Yt(),
247
+ ...ke.props,
248
+ ...ua(),
249
249
  appendToBody: {
250
250
  type: Boolean,
251
251
  default: !0
@@ -257,62 +257,62 @@ const Ne = () => ({
257
257
  },
258
258
  setup: (e, {
259
259
  slots: t,
260
- emit: u,
261
- expose: a
260
+ emit: o,
261
+ expose: n
262
262
  }) => {
263
263
  const {
264
- t: o
265
- } = ce(), n = R();
266
- a(L(n));
267
- const l = (g) => {
268
- u("update:modelValue", g), u("update:visible", g), g || u("cancel");
269
- }, f = () => {
270
- l(!1);
271
- }, r = () => {
272
- u("ok");
273
- }, m = He(), d = m(p.ProOperateKey), i = m(p.ScrollKey), P = E(() => [{
264
+ t: u
265
+ } = fe(), l = T();
266
+ n(D(l));
267
+ const d = (g) => {
268
+ o("update:modelValue", g), o("update:visible", g), g || o("cancel");
269
+ }, s = () => {
270
+ d(!1);
271
+ }, c = () => {
272
+ o("ok");
273
+ }, a = lt(), m = a(V.ProOperateKey), r = a(V.ScrollKey), i = x(() => [{
274
274
  value: "cancel",
275
- label: o.value("cancel"),
276
- onClick: f
275
+ label: u.value("cancel"),
276
+ onClick: s
277
277
  }, {
278
278
  value: "ok",
279
- label: o.value("confirm"),
279
+ label: u.value("confirm"),
280
280
  loading: e.confirmLoading,
281
281
  extraProps: {
282
282
  type: "primary"
283
283
  },
284
- onClick: r
285
- }]), w = V(ue());
284
+ onClick: c
285
+ }]), S = $(me());
286
286
  return () => {
287
287
  const g = [e.clsName];
288
- return e.useScroll && g.push("scroll"), c(Pe, s({
288
+ return e.useScroll && g.push("scroll"), f(ke, y({
289
289
  class: g,
290
- ref: n
291
- }, v(e, w), {
290
+ ref: l
291
+ }, h(e, S), {
292
292
  modelValue: e.visible || e.modelValue,
293
- "onUpdate:modelValue": l
293
+ "onUpdate:modelValue": d
294
294
  }), {
295
- footer: e.footer === !1 ? void 0 : () => c(d, {
296
- items: P.value
295
+ footer: e.footer === !1 ? void 0 : () => f(m, {
296
+ items: i.value
297
297
  }, null),
298
298
  ...t,
299
299
  default: () => {
300
- var k;
301
- return e.useScroll ? c(i, s({
300
+ var K;
301
+ return e.useScroll ? f(r, y({
302
302
  class: `${e.clsName}-scroll`
303
303
  }, e.scrollProps), {
304
304
  default: () => {
305
- var F;
306
- return [(F = t.default) == null ? void 0 : F.call(t)];
305
+ var R;
306
+ return [(R = t.default) == null ? void 0 : R.call(t)];
307
307
  }
308
- }) : (k = t.default) == null ? void 0 : k.call(t);
308
+ }) : (K = t.default) == null ? void 0 : K.call(t);
309
309
  }
310
310
  });
311
311
  };
312
312
  }
313
- }), ta = x({
313
+ }), ca = k({
314
314
  props: {
315
- ...Ce.props,
315
+ ...Fe.props,
316
316
  page: {
317
317
  type: Number,
318
318
  default: 1
@@ -320,42 +320,45 @@ const Ne = () => ({
320
320
  },
321
321
  setup: (e, {
322
322
  slots: t,
323
- emit: u
323
+ emit: o
324
324
  }) => {
325
- const a = R(e.page), o = R(e.pageSize);
326
- j(() => {
327
- a.value !== e.page && (a.value = e.page);
328
- }, () => e.page), j(() => {
329
- o.value !== e.pageSize && (o.value = e.pageSize);
325
+ const n = T(e.page), u = T(e.pageSize);
326
+ H(() => {
327
+ n.value !== e.page && (n.value = e.page);
328
+ }, () => e.page), H(() => {
329
+ u.value !== e.pageSize && (u.value = e.pageSize);
330
330
  }, () => e.pageSize);
331
- const n = At(() => {
332
- u("composeChange", a.value, o.value);
333
- }, 300), l = () => {
334
- n(), u("update:page", a.value);
335
- }, f = () => {
336
- n(), u("update:pageSize", o.value);
331
+ const l = Zt(() => {
332
+ o("composeChange", n.value, u.value);
333
+ }, 300), d = () => {
334
+ l(), o("update:page", n.value);
335
+ }, s = () => {
336
+ l(), o("update:pageSize", u.value);
337
337
  };
338
- return () => c(Ce, s({
339
- currentPage: a.value,
340
- "onUpdate:currentPage": (r) => a.value = r,
341
- pageSize: o.value,
342
- "onUpdate:pageSize": (r) => o.value = r,
343
- onCurrentChange: l,
344
- onSizeChange: f
345
- }, v(e, "currentPage", "pageSize")), t);
338
+ return () => f(Fe, y({
339
+ currentPage: n.value,
340
+ "onUpdate:currentPage": (c) => n.value = c,
341
+ pageSize: u.value,
342
+ "onUpdate:pageSize": (c) => u.value = c,
343
+ onCurrentChange: d,
344
+ onSizeChange: s
345
+ }, h(e, "currentPage", "pageSize")), t);
346
346
  }
347
- }), aa = x({
347
+ }), ia = k({
348
348
  props: {
349
- ...Ke.props
349
+ ...we.props
350
350
  },
351
351
  setup: (e, {
352
352
  slots: t
353
- }) => () => c(Ke, e, {
353
+ }) => () => f(we, e, {
354
354
  reference: t.default,
355
355
  default: t.content
356
356
  })
357
- }), Oe = () => ({
357
+ }), He = () => ({
358
358
  options: Array,
359
+ fieldNames: {
360
+ type: Object
361
+ },
359
362
  buttonStyle: {
360
363
  type: String,
361
364
  default: "default"
@@ -363,50 +366,89 @@ const Ne = () => ({
363
366
  optionType: {
364
367
  type: String,
365
368
  default: "default"
369
+ },
370
+ expMethods: {
371
+ type: Array,
372
+ default: () => ["focus", "blur", "selectedLabel"]
373
+ },
374
+ separator$: {
375
+ type: String
376
+ },
377
+ parseValue$: {
378
+ type: Function
379
+ },
380
+ formatValue$: {
381
+ type: Function
366
382
  }
367
- }), na = x({
383
+ }), ma = k({
368
384
  props: {
369
- ...we.props,
370
- ...Oe()
385
+ ...Ee.props,
386
+ ...He()
371
387
  },
372
388
  setup: (e, {
373
389
  slots: t,
374
- emit: u,
375
- expose: a
390
+ emit: o,
391
+ expose: n
376
392
  }) => {
377
- const o = R();
378
- a(L(o));
379
- const n = V(Oe());
380
- return () => c(we, s({
381
- ref: o
382
- }, v(e, n), {
383
- "onUpdate:modelValue": (l) => {
384
- u("update:modelValue", l || void 0);
393
+ const u = T();
394
+ n(D(u, e.expMethods));
395
+ const l = x(() => E(e.options, (a) => {
396
+ var m, r, i;
397
+ return {
398
+ ...a,
399
+ label: w(a, ((m = e.fieldNames) == null ? void 0 : m.label) || "label"),
400
+ value: w(a, ((r = e.fieldNames) == null ? void 0 : r.value) || "value"),
401
+ disabled: w(a, ((i = e.fieldNames) == null ? void 0 : i.label) || "disabled")
402
+ };
403
+ })), d = x(() => {
404
+ const a = e.modelValue;
405
+ return e.parseValue$ ? e.parseValue$(a, e) : q(a, {
406
+ multiple: !0,
407
+ separator: e.separator$
408
+ });
409
+ }), s = (a) => {
410
+ if (e.formatValue$) {
411
+ o("update:modelValue", e.formatValue$(a, e));
412
+ return;
385
413
  }
414
+ if (e.separator$) {
415
+ o("update:modelValue", G(a, {
416
+ multiple: !0,
417
+ separator: e.separator$
418
+ }));
419
+ return;
420
+ }
421
+ o("update:modelValue", a);
422
+ }, c = [...$(He()), "modelValue"];
423
+ return () => f(Ee, y({
424
+ ref: u
425
+ }, h(e, c), {
426
+ modelValue: d.value,
427
+ "onUpdate:modelValue": (a) => s(a)
386
428
  }), {
387
429
  default: () => {
388
- var l, f;
389
- return [(l = t.start) == null ? void 0 : l.call(t), T(e.options, (r) => {
390
- var d;
391
- const m = (d = t.label) == null ? void 0 : d.call(t, r);
392
- return e.optionType === "button" || e.buttonStyle === "button" ? c(vt, s({
430
+ var a, m;
431
+ return [(a = t.start) == null ? void 0 : a.call(t), E(l.value, (r) => {
432
+ var S;
433
+ const i = (S = t.label) == null ? void 0 : S.call(t, r);
434
+ return e.optionType === "button" || e.buttonStyle === "button" ? f(Ft, y({
393
435
  key: r.value
394
- }, v(r, "value"), {
436
+ }, h(r, "value"), {
395
437
  label: r.value
396
438
  }), {
397
- default: () => [m || r.label]
398
- }) : c(Ge, s({
439
+ default: () => [i || r.label]
440
+ }) : f(rt, y({
399
441
  key: r.value
400
442
  }, r, {
401
443
  label: r.value
402
444
  }), {
403
- default: () => [m || r.label]
445
+ default: () => [i || r.label]
404
446
  });
405
- }), (f = t.default) == null ? void 0 : f.call(t)];
447
+ }), (m = t.default) == null ? void 0 : m.call(t)];
406
448
  }
407
449
  });
408
450
  }
409
- }), De = () => ({
451
+ }), qe = () => ({
410
452
  options: {
411
453
  type: Array
412
454
  },
@@ -418,116 +460,217 @@ const Ne = () => ({
418
460
  type: String,
419
461
  default: "default"
420
462
  }
421
- }), la = x({
463
+ }), fa = k({
422
464
  props: {
423
- ...xe.props,
424
- ...De()
465
+ ...Te.props,
466
+ ...qe()
425
467
  },
426
468
  setup: (e, {
427
469
  slots: t,
428
- emit: u,
429
- expose: a
470
+ emit: o,
471
+ expose: n
430
472
  }) => {
431
- const o = R();
432
- a(L(o));
433
- const n = V(De());
434
- return () => c(xe, s({
435
- ref: o
436
- }, v(e, n), {
437
- "onUpdate:modelValue": (l) => {
438
- u("update:modelValue", l);
473
+ const u = T();
474
+ n(D(u));
475
+ const l = $(qe());
476
+ return () => f(Te, y({
477
+ ref: u
478
+ }, h(e, l), {
479
+ "onUpdate:modelValue": (d) => {
480
+ o("update:modelValue", d);
439
481
  }
440
482
  }), {
441
483
  default: () => {
442
- var l, f;
443
- return [(l = t.start) == null ? void 0 : l.call(t), T(e.options, (r) => {
444
- var d;
445
- const m = (d = t.label) == null ? void 0 : d.call(t, r);
446
- return e.optionType === "button" || e.buttonStyle === "button" ? c(ht, s({
447
- key: r.value
448
- }, v(r, "value"), {
449
- label: r.value
484
+ var d, s;
485
+ return [(d = t.start) == null ? void 0 : d.call(t), E(e.options, (c) => {
486
+ var m;
487
+ const a = (m = t.label) == null ? void 0 : m.call(t, c);
488
+ return e.optionType === "button" || e.buttonStyle === "button" ? f(wt, y({
489
+ key: c.value
490
+ }, h(c, "value"), {
491
+ label: c.value
450
492
  }), {
451
- default: () => [m || r.label]
452
- }) : c(bt, s({
453
- key: r.value
454
- }, v(r, "value"), {
455
- label: r.value
493
+ default: () => [a || c.label]
494
+ }) : f(Et, y({
495
+ key: c.value
496
+ }, h(c, "value"), {
497
+ label: c.value
456
498
  }), {
457
- default: () => [m || r.label]
499
+ default: () => [a || c.label]
458
500
  });
459
- }), (f = t.default) == null ? void 0 : f.call(t)];
501
+ }), (s = t.default) == null ? void 0 : s.call(t)];
460
502
  }
461
503
  });
462
504
  }
463
- }), Le = () => ({
464
- options: Array
465
- }), ra = x({
505
+ }), Ge = () => ({
506
+ options: Array,
507
+ fieldNames: {
508
+ type: Object
509
+ },
510
+ expMethods: {
511
+ type: Array,
512
+ default: () => ["focus", "blur", "selectedLabel"]
513
+ },
514
+ separator$: {
515
+ type: String
516
+ },
517
+ parseValue$: {
518
+ type: Function
519
+ },
520
+ formatValue$: {
521
+ type: Function
522
+ }
523
+ }), sa = k({
466
524
  props: {
467
- ...ke.props,
468
- ...Le()
525
+ ...Re.props,
526
+ ...Ge()
469
527
  },
470
528
  setup: (e, {
471
529
  slots: t,
472
- emit: u,
473
- expose: a
530
+ emit: o,
531
+ expose: n
474
532
  }) => {
475
- const o = R();
476
- a(L(o));
477
- const n = V(Le());
478
- return () => c(ke, s({
479
- ref: o
480
- }, v(e, n), {
481
- "onUpdate:modelValue": (l) => {
482
- u("update:modelValue", l || void 0);
533
+ const u = T();
534
+ n(D(u, e.expMethods));
535
+ const l = x(() => E(e.options, (a) => {
536
+ var m, r, i;
537
+ return {
538
+ ...a,
539
+ label: w(a, ((m = e.fieldNames) == null ? void 0 : m.label) || "label"),
540
+ value: w(a, ((r = e.fieldNames) == null ? void 0 : r.value) || "value"),
541
+ disabled: w(a, ((i = e.fieldNames) == null ? void 0 : i.label) || "disabled")
542
+ };
543
+ })), d = x(() => {
544
+ const a = e.modelValue;
545
+ return e.parseValue$ ? e.parseValue$(a, e) : q(a, {
546
+ multiple: e.multiple,
547
+ separator: e.separator$
548
+ });
549
+ }), s = (a) => {
550
+ if (e.formatValue$) {
551
+ o("update:modelValue", e.formatValue$(a, e));
552
+ return;
553
+ }
554
+ if (e.separator$) {
555
+ o("update:modelValue", G(a, {
556
+ multiple: e.multiple,
557
+ separator: e.separator$
558
+ }));
559
+ return;
483
560
  }
561
+ o("update:modelValue", a);
562
+ }, c = [...$(Ge()), "modelValue"];
563
+ return () => f(Re, y({
564
+ ref: u
565
+ }, h(e, c), {
566
+ modelValue: d.value,
567
+ "onUpdate:modelValue": (a) => s(a)
484
568
  }), {
485
569
  default: () => {
486
- var l, f;
487
- return [(l = t.start) == null ? void 0 : l.call(t), T(e.options, (r) => {
488
- var d;
489
- const m = (d = t.label) == null ? void 0 : d.call(t, r);
490
- return c(pt, s({
570
+ var a, m;
571
+ return [(a = t.start) == null ? void 0 : a.call(t), E(l.value, (r) => {
572
+ var S;
573
+ const i = (S = t.label) == null ? void 0 : S.call(t, r);
574
+ return f(Tt, y({
491
575
  key: r.value
492
576
  }, r), {
493
- default: () => [m || r.label]
577
+ default: () => [i || r.label]
494
578
  });
495
- }), (f = t.default) == null ? void 0 : f.call(t)];
579
+ }), (m = t.default) == null ? void 0 : m.call(t)];
496
580
  },
497
- ...v(t, "default")
581
+ ...h(t, "default")
498
582
  });
499
583
  }
500
- }), Va = x({
584
+ }), _e = () => ({
585
+ options: Array,
586
+ fieldNames: Object,
587
+ expMethods: {
588
+ type: Array,
589
+ default: () => ["focus", "blur", "selectedLabel"]
590
+ },
591
+ separator$: String,
592
+ parseValue$: Function,
593
+ formatValue$: Function
594
+ }), ya = k({
595
+ name: "ProSelectV2",
501
596
  props: {
502
- ...Ee.props,
597
+ ...$e.props,
598
+ ..._e()
599
+ },
600
+ setup: (e, {
601
+ slots: t,
602
+ emit: o,
603
+ expose: n
604
+ }) => {
605
+ const u = T();
606
+ n(se(u, e.expMethods));
607
+ const l = x(() => E(e.options, (a) => {
608
+ var m, r, i;
609
+ return {
610
+ ...a,
611
+ label: w(a, ((m = e.fieldNames) == null ? void 0 : m.label) || "label"),
612
+ value: w(a, ((r = e.fieldNames) == null ? void 0 : r.value) || "value"),
613
+ disabled: w(a, ((i = e.fieldNames) == null ? void 0 : i.disabled) || "disabled")
614
+ };
615
+ })), d = x(() => {
616
+ const a = e.modelValue;
617
+ return e.parseValue$ ? e.parseValue$(a, e) : q(a, {
618
+ multiple: e.multiple,
619
+ separator: e.separator$
620
+ });
621
+ }), s = (a) => {
622
+ if (e.formatValue$) {
623
+ o("update:modelValue", e.formatValue$(a, e));
624
+ return;
625
+ }
626
+ if (e.separator$) {
627
+ o("update:modelValue", G(a, {
628
+ multiple: e.multiple,
629
+ separator: e.separator$
630
+ }));
631
+ return;
632
+ }
633
+ o("update:modelValue", a);
634
+ }, c = [...$(_e()), "modelValue"];
635
+ return () => f($e, y({
636
+ ref: u
637
+ }, h(e, c), {
638
+ modelValue: d.value,
639
+ "onUpdate:modelValue": (a) => s(a),
640
+ options: l.value
641
+ }), t);
642
+ }
643
+ }), qa = k({
644
+ props: {
645
+ ...Me.props,
503
646
  options: {
504
647
  type: Array
505
648
  }
506
649
  },
507
650
  setup: (e, {
508
651
  slots: t,
509
- emit: u
510
- }) => () => c(Ee, s(v(e, "options"), {
511
- "onUpdate:modelValue": (a) => {
512
- u("update:modelValue", a);
652
+ emit: o
653
+ }) => () => f(Me, y(h(e, "options"), {
654
+ "onUpdate:modelValue": (n) => {
655
+ o("update:modelValue", n);
513
656
  }
514
657
  }), {
515
658
  default: () => {
516
- var a, o;
517
- return [(a = t.start) == null ? void 0 : a.call(t), T(e.options, (n) => c(St, s({
518
- key: n.value
519
- }, v(n, "value"), {
520
- name: n.value
659
+ var n, u;
660
+ return [(n = t.start) == null ? void 0 : n.call(t), E(e.options, (l) => f(Rt, y({
661
+ key: l.value
662
+ }, h(l, "value"), {
663
+ name: l.value
521
664
  }), {
522
665
  label: () => {
523
- var l;
524
- return ((l = t.label) == null ? void 0 : l.call(t, n)) || n.label;
666
+ var d;
667
+ return ((d = t.label) == null ? void 0 : d.call(t, l)) || l.label;
525
668
  }
526
- })), (o = t.end) == null ? void 0 : o.call(t)];
669
+ })), (u = t.end) == null ? void 0 : u.call(t)];
527
670
  },
528
671
  ...t
529
672
  })
530
- }), de = {
673
+ }), ye = {
531
674
  convertSubMenuProps: {
532
675
  type: Function
533
676
  },
@@ -537,51 +680,51 @@ const Ne = () => ({
537
680
  onMenuItemClick: {
538
681
  type: Function
539
682
  }
540
- }, lt = V(de), rt = x({
683
+ }, gt = $(ye), ht = k({
541
684
  inheritAttrs: !1,
542
685
  props: {
543
686
  menu: {
544
687
  type: Object
545
688
  },
546
- ...de
689
+ ...ye
547
690
  },
548
691
  setup: (e, {
549
692
  slots: t
550
693
  }) => {
551
- const u = () => {
552
- var a;
553
- (a = e.onMenuItemClick) == null || a.call(e, e.menu);
694
+ const o = () => {
695
+ var n;
696
+ (n = e.onMenuItemClick) == null || n.call(e, e.menu);
554
697
  };
555
698
  return () => {
556
- var o, n;
557
- const a = e.menu;
558
- return (a == null ? void 0 : a.children) && D(a.children) > 0 ? c(H.SubMenu, s({
559
- index: a == null ? void 0 : a.value
560
- }, (o = e.convertSubMenuProps) == null ? void 0 : o.call(e, a)), {
561
- default: () => [T(a.children, (l) => c(rt, s({
562
- menu: l
563
- }, G(e, lt)), t))],
699
+ var u, l;
700
+ const n = e.menu;
701
+ return (n == null ? void 0 : n.children) && L(n.children) > 0 ? f(Q.SubMenu, y({
702
+ index: n == null ? void 0 : n.value
703
+ }, (u = e.convertSubMenuProps) == null ? void 0 : u.call(e, n)), {
704
+ default: () => [E(n.children, (d) => f(ht, y({
705
+ menu: d
706
+ }, Y(e, gt)), t))],
564
707
  title: () => {
565
- var l;
566
- return ((l = t.title) == null ? void 0 : l.call(t, a)) || (a == null ? void 0 : a.label);
708
+ var d;
709
+ return ((d = t.title) == null ? void 0 : d.call(t, n)) || (n == null ? void 0 : n.label);
567
710
  }
568
- }) : c(H.MenuItem, s({
569
- index: a == null ? void 0 : a.value
570
- }, (n = e.convertMenuItemProps) == null ? void 0 : n.call(e, a), {
571
- onClick: u
711
+ }) : f(Q.MenuItem, y({
712
+ index: n == null ? void 0 : n.value
713
+ }, (l = e.convertMenuItemProps) == null ? void 0 : l.call(e, n), {
714
+ onClick: o
572
715
  }), {
573
716
  title: () => {
574
- var l;
575
- return ((l = t.title) == null ? void 0 : l.call(t, a)) || (a == null ? void 0 : a.label);
717
+ var d;
718
+ return ((d = t.title) == null ? void 0 : d.call(t, n)) || (n == null ? void 0 : n.label);
576
719
  },
577
720
  default: t.default ? () => {
578
- var l;
579
- return (l = t.default) == null ? void 0 : l.call(t, a);
721
+ var d;
722
+ return (d = t.default) == null ? void 0 : d.call(t, n);
580
723
  } : void 0
581
724
  });
582
725
  };
583
726
  }
584
- }), ze = () => ({
727
+ }), Ze = () => ({
585
728
  activeKey: {
586
729
  type: String
587
730
  },
@@ -596,43 +739,43 @@ const Ne = () => ({
596
739
  label: "label"
597
740
  }
598
741
  },
599
- ...de
600
- }), oa = x({
742
+ ...ye
743
+ }), ga = k({
601
744
  props: {
602
- ...v(H.props, "defaultActive"),
603
- ...ze()
745
+ ...h(Q.props, "defaultActive"),
746
+ ...Ze()
604
747
  },
605
748
  setup: (e, {
606
749
  slots: t
607
750
  }) => {
608
- const u = R(e.activeKey);
609
- j(() => {
610
- e.activeKey !== u.value && (u.value = e.activeKey);
751
+ const o = T(e.activeKey);
752
+ H(() => {
753
+ e.activeKey !== o.value && (o.value = e.activeKey);
611
754
  }, () => e.activeKey);
612
- const a = E(() => {
613
- var n;
614
- return Ht(e.options, (l) => {
615
- var m, d;
616
- const f = ((m = e.fieldNames) == null ? void 0 : m.value) || "value", r = ((d = e.fieldNames) == null ? void 0 : d.label) || "label";
755
+ const n = x(() => {
756
+ var l;
757
+ return Yt(e.options, (d) => {
758
+ var a, m;
759
+ const s = ((a = e.fieldNames) == null ? void 0 : a.value) || "value", c = ((m = e.fieldNames) == null ? void 0 : m.label) || "label";
617
760
  return {
618
- ...v(l, f, r),
619
- value: N(l, f),
620
- label: N(l, r)
761
+ ...h(d, s, c),
762
+ value: w(d, s),
763
+ label: w(d, c)
621
764
  };
622
765
  }, {
623
- children: ((n = e.fieldNames) == null ? void 0 : n.children) || "children",
766
+ children: ((l = e.fieldNames) == null ? void 0 : l.children) || "children",
624
767
  childrenName: "children"
625
768
  });
626
- }), o = V(ze());
627
- return () => c(H, s({
628
- defaultActive: u.value
629
- }, v(e, o)), {
630
- default: () => c(Qe, null, [T(a.value, (n) => c(rt, s({
631
- menu: n
632
- }, G(e, lt)), t))])
769
+ }), u = $(Ze());
770
+ return () => f(Q, y({
771
+ defaultActive: o.value
772
+ }, h(e, u)), {
773
+ default: () => f(ct, null, [E(n.value, (l) => f(ht, y({
774
+ menu: l
775
+ }, Y(e, gt)), t))])
633
776
  });
634
777
  }
635
- }), Ae = () => ({
778
+ }), Je = () => ({
636
779
  modelValue: {
637
780
  type: Array,
638
781
  default: void 0
@@ -655,6 +798,9 @@ const Ne = () => ({
655
798
  beforeUpload: {
656
799
  type: Function
657
800
  },
801
+ beforeUpload2: {
802
+ type: Function
803
+ },
658
804
  globalLoading: {
659
805
  type: [Boolean, Object],
660
806
  default: void 0
@@ -663,112 +809,114 @@ const Ne = () => ({
663
809
  type: Function,
664
810
  default: void 0
665
811
  }
666
- }), ua = ["abort", "submit", "clearFiles", "handleStart", "handleRemove"], ot = x({
812
+ }), ha = ["abort", "submit", "clearFiles", "handleStart", "handleRemove"], vt = k({
667
813
  props: {
668
- ...v(Re.props, "fileList"),
669
- ...Ae()
814
+ ...h(Ne.props, "fileList"),
815
+ ...Je()
670
816
  },
671
817
  setup: (e, {
672
818
  slots: t,
673
- expose: u,
674
- emit: a
819
+ expose: o,
820
+ emit: n
675
821
  }) => {
676
822
  const {
677
- showMsg: o,
678
- t: n
679
- } = ce(), l = R();
680
- u(L(l, ua));
823
+ showMsg: u,
824
+ t: l
825
+ } = fe(), d = T();
826
+ o(D(d, ha));
681
827
  const {
682
- formItem: f
683
- } = Pt(), r = () => Xe(e.modelValue) ? T(e.modelValue, (y) => {
684
- var h;
685
- return ((h = e.convertItemData) == null ? void 0 : h.call(e, y)) || y;
686
- }) : [], m = R(r());
687
- let d = !1;
688
- const i = () => {
689
- var h;
690
- d = !0;
691
- const y = oe(m.value, (b) => b.status === "success");
692
- a("update:modelValue", T(y, (b) => {
693
- var K;
694
- return ((K = e.convertResponseData) == null ? void 0 : K.call(e, b)) || b;
695
- })), (h = f == null ? void 0 : f.validate) == null || h.call(f, "change");
828
+ formItem: s
829
+ } = $t(), c = () => j(e.modelValue) ? E(e.modelValue, (b) => {
830
+ var p;
831
+ return ((p = e.convertItemData) == null ? void 0 : p.call(e, b)) || b;
832
+ }) : [], a = T(c());
833
+ let m = !1;
834
+ const r = () => {
835
+ var p;
836
+ m = !0;
837
+ const b = ce(a.value, (P) => P.status === "success");
838
+ n("update:modelValue", E(b, (P) => {
839
+ var F;
840
+ return ((F = e.convertResponseData) == null ? void 0 : F.call(e, P)) || P;
841
+ })), (p = s == null ? void 0 : s.validate) == null || p.call(s, "change");
696
842
  };
697
- j(() => {
698
- d || (m.value = r(), d = !1);
843
+ H(() => {
844
+ m || (a.value = c(), m = !1);
699
845
  }, () => e.modelValue);
700
- let P;
701
- const w = () => {
702
- e.globalLoading && (P = qe.service({
846
+ let i;
847
+ const S = () => {
848
+ e.globalLoading && (i = nt.service({
703
849
  lock: !0,
704
- text: n.value("uploadingWatting"),
705
- ...q(e.globalLoading) ? {} : e.globalLoading
850
+ text: l.value("uploadingWatting"),
851
+ ...X(e.globalLoading) ? {} : e.globalLoading
706
852
  }));
707
853
  }, g = () => {
708
- e.globalLoading && (P == null || P.close());
854
+ e.globalLoading && (i == null || i.close());
709
855
  };
710
- _(() => () => {
856
+ ee(() => () => {
711
857
  g();
712
858
  }, []);
713
- const k = (y, h, b) => {
859
+ const K = (b, p, P) => {
714
860
  if (e.onErrorMsg) {
715
- e.onErrorMsg(y, h);
861
+ e.onErrorMsg(b, p);
716
862
  return;
717
863
  }
718
- o({
864
+ u({
719
865
  type: "error",
720
- message: h
866
+ message: p
721
867
  });
722
- }, F = (y) => {
723
- var h;
868
+ }, R = (b) => {
869
+ var p;
724
870
  if (e.beforeUpload)
725
- return e.beforeUpload(y);
726
- if (e.accept && !qt(e.accept, y.name))
727
- return k("FileTypeError", `\u8BF7\u4E0A\u4F20\u6B63\u786E\u683C\u5F0F\uFF08${e.accept.replace(/,/g, "\uFF0C")}\uFF09\u7684\u6587\u4EF6`, {
871
+ return e.beforeUpload(b);
872
+ if (e.beforeUpload2 && !e.beforeUpload2(b))
873
+ return !1;
874
+ if (e.accept && !ea(e.accept, b.name))
875
+ return K("FileTypeError", `\u8BF7\u4E0A\u4F20\u6B63\u786E\u683C\u5F0F\uFF08${e.accept.replace(/,/g, "\uFF0C")}\uFF09\u7684\u6587\u4EF6`, {
728
876
  accept: e.accept.replace(/,/g, "\uFF0C")
729
877
  }), !1;
730
- if (z(y.size)) {
731
- if (y.size <= 0)
732
- return k("FileSizeError-Zero", "\u4E0A\u4F20\u6587\u4EF6\u5185\u5BB9\u4E0D\u80FD\u4E3A\u7A7A"), !1;
733
- if (z(e.maxSize) && y.size > e.maxSize)
734
- return k("FileSizeError-MaxSize", `\u8BF7\u4E0A\u4F20\u5C0F\u4E8E${Be(e.maxSize)}\u7684\u6587\u4EF6`, {
735
- maxSize: Be(e.maxSize)
878
+ if (U(b.size)) {
879
+ if (b.size <= 0)
880
+ return K("FileSizeError-Zero", "\u4E0A\u4F20\u6587\u4EF6\u5185\u5BB9\u4E0D\u80FD\u4E3A\u7A7A"), !1;
881
+ if (U(e.maxSize) && b.size > e.maxSize)
882
+ return K("FileSizeError-MaxSize", `\u8BF7\u4E0A\u4F20\u5C0F\u4E8E${ze(e.maxSize)}\u7684\u6587\u4EF6`, {
883
+ maxSize: ze(e.maxSize)
736
884
  }), !1;
737
885
  }
738
- return (h = e.onStart) == null || h.call(e, y), w(), !0;
739
- }, Z = (y, h, b) => {
740
- var K;
741
- (K = e.onSuccess) == null || K.call(e, y, h, b), i(), g();
742
- }, J = (y, h, b) => {
743
- var K;
744
- (K = e.onError) == null || K.call(e, y, h, b), g(), k("UploadError", "\u4E0A\u4F20\u5931\u8D25");
745
- }, S = (y, h) => {
746
- var b;
747
- m.value = oe(m.value, (K) => !(y.uid === K.uid && y.name === K.name)), (b = e.onRemove) == null || b.call(e, y, h), i();
748
- }, C = E(() => z(e.limit) ? e.limit > D(m.value) : !0), M = V(Ae());
886
+ return (p = e.onStart) == null || p.call(e, b), S(), !0;
887
+ }, B = (b, p, P) => {
888
+ var F;
889
+ (F = e.onSuccess) == null || F.call(e, b, p, P), r(), g();
890
+ }, O = (b, p, P) => {
891
+ var F;
892
+ (F = e.onError) == null || F.call(e, b, p, P), g(), K("UploadError", "\u4E0A\u4F20\u5931\u8D25");
893
+ }, v = (b, p) => {
894
+ var P;
895
+ a.value = ce(a.value, (F) => !(b.uid === F.uid && b.name === F.name)), (P = e.onRemove) == null || P.call(e, b, p), r();
896
+ }, C = x(() => U(e.limit) ? e.limit > L(a.value) : !0), N = $(Je());
749
897
  return () => {
750
- var y, h;
751
- return c("div", {
898
+ var b, p;
899
+ return f("div", {
752
900
  class: `pro-uploader ${C.value ? "" : "pro-uploader-limit"}`
753
- }, [(y = t.start) == null ? void 0 : y.call(t), c(Re, s({
754
- ref: l,
755
- fileList: m.value,
756
- "onUpdate:fileList": (b) => m.value = b
757
- }, v(e, "fileList", "onSuccess", "onError", "onRemove", "beforeUpload", ...M), {
758
- beforeUpload: F,
759
- onSuccess: Z,
760
- onError: J,
761
- onRemove: S
901
+ }, [(b = t.start) == null ? void 0 : b.call(t), f(Ne, y({
902
+ ref: d,
903
+ fileList: a.value,
904
+ "onUpdate:fileList": (P) => a.value = P
905
+ }, h(e, "fileList", "onSuccess", "onError", "onRemove", "beforeUpload", ...N), {
906
+ beforeUpload: R,
907
+ onSuccess: B,
908
+ onError: O,
909
+ onRemove: v
762
910
  }), {
763
911
  default: () => {
764
- var b, K;
765
- return [C.value && c(Qe, null, [((b = t.default) == null ? void 0 : b.call(t)) || ((K = e.renderDom) == null ? void 0 : K.call(e))])];
912
+ var P, F;
913
+ return [C.value && f(ct, null, [((P = t.default) == null ? void 0 : P.call(t)) || ((F = e.renderDom) == null ? void 0 : F.call(e))])];
766
914
  },
767
- ...v(t, "default")
768
- }), (h = t.end) == null ? void 0 : h.call(t)]);
915
+ ...h(t, "default")
916
+ }), (p = t.end) == null ? void 0 : p.call(t)]);
769
917
  };
770
918
  }
771
- }), Ue = () => ({
919
+ }), Qe = () => ({
772
920
  modelValue: {
773
921
  type: Array
774
922
  },
@@ -785,54 +933,54 @@ const Ne = () => ({
785
933
  divider: {
786
934
  type: Function
787
935
  }
788
- }), ca = x({
936
+ }), va = k({
789
937
  props: {
790
- ...v($.props, "modelValue"),
938
+ ...h(J.props, "modelValue"),
791
939
  controlsPosition: {
792
940
  type: String,
793
941
  default: "right"
794
942
  },
795
- ...Ue()
943
+ ...Qe()
796
944
  },
797
945
  setup: (e, {
798
946
  slots: t,
799
- emit: u
947
+ emit: o
800
948
  }) => {
801
- const a = R(N(e.modelValue, 0)), o = R(N(e.modelValue, 1));
802
- let n = !1;
803
- j(() => {
804
- n || (a.value = N(e.modelValue, 0), o.value = N(e.modelValue, 1)), n = !1;
949
+ const n = T(w(e.modelValue, 0)), u = T(w(e.modelValue, 1));
950
+ let l = !1;
951
+ H(() => {
952
+ l || (n.value = w(e.modelValue, 0), u.value = w(e.modelValue, 1)), l = !1;
805
953
  }, [e.modelValue, () => e.modelValue]);
806
- const l = () => {
807
- n = !0, e.singleEmit ? u("update:modelValue", [a.value, o.value]) : z(a.value) && z(o.value) ? u("update:modelValue", [a.value, o.value]) : u("update:modelValue", null);
808
- }, f = (i) => {
809
- for (let P = 0; P < i.length; P++)
810
- if (z(i[P]))
811
- return i[P];
812
- }, r = E(() => {
813
- var i;
814
- return f([o.value, (i = e.start) == null ? void 0 : i.max, e.max]);
815
- }), m = E(() => {
816
- var i;
817
- return f([a.value, (i = e.end) == null ? void 0 : i.min, e.min]);
818
- }), d = V(Ue());
954
+ const d = () => {
955
+ l = !0, e.singleEmit ? o("update:modelValue", [n.value, u.value]) : U(n.value) && U(u.value) ? o("update:modelValue", [n.value, u.value]) : o("update:modelValue", null);
956
+ }, s = (r) => {
957
+ for (let i = 0; i < r.length; i++)
958
+ if (U(r[i]))
959
+ return r[i];
960
+ }, c = x(() => {
961
+ var r;
962
+ return s([u.value, (r = e.start) == null ? void 0 : r.max, e.max]);
963
+ }), a = x(() => {
964
+ var r;
965
+ return s([n.value, (r = e.end) == null ? void 0 : r.min, e.min]);
966
+ }), m = $(Qe());
819
967
  return () => {
820
- var P, w;
821
- const i = v(e, ...d, "min", "max");
822
- return c("span", {
968
+ var i, S;
969
+ const r = h(e, ...m, "min", "max");
970
+ return f("span", {
823
971
  class: "pro-number-range"
824
- }, [c($, s(i, v(e.start, "max"), {
825
- max: r.value,
826
- modelValue: a.value,
827
- "onUpdate:modelValue": [(g) => a.value = g, l]
828
- }), null), c("span", null, [((P = t.divider) == null ? void 0 : P.call(t)) || ((w = e.divider) == null ? void 0 : w.call(e)) || " - "]), c($, s(i, v(e.start, "min"), {
829
- min: m.value,
830
- modelValue: o.value,
831
- "onUpdate:modelValue": [(g) => o.value = g, l]
972
+ }, [f(J, y(r, h(e.start, "max"), {
973
+ max: c.value,
974
+ modelValue: n.value,
975
+ "onUpdate:modelValue": [(g) => n.value = g, d]
976
+ }), null), f("span", null, [((i = t.divider) == null ? void 0 : i.call(t)) || ((S = e.divider) == null ? void 0 : S.call(e)) || " - "]), f(J, y(r, h(e.start, "min"), {
977
+ min: a.value,
978
+ modelValue: u.value,
979
+ "onUpdate:modelValue": [(g) => u.value = g, d]
832
980
  }), null)]);
833
981
  };
834
982
  }
835
- }), je = () => ({
983
+ }), ba = ["filter", "updateKeyChildren", "getCheckedNodes", "setCheckedNodes", "getCheckedKeys", "setCheckedKeys", "setChecked", "getHalfCheckedNodes", "getHalfCheckedKeys", "getCurrentKey", "getCurrentNode", "setCurrentKey", "setCurrentNode", "getNode", "remove", "append", "insertBefore", "insertAfter"], Xe = () => ({
836
984
  treeData: {
837
985
  type: Array
838
986
  },
@@ -849,126 +997,307 @@ const Ne = () => ({
849
997
  checkedKeys: {
850
998
  type: Array
851
999
  }
852
- }), Ba = x({
1000
+ }), Ga = k({
853
1001
  props: {
854
- ...Fe.props,
855
- ...je()
1002
+ ...Ie.props,
1003
+ ...Xe()
856
1004
  },
857
1005
  setup: (e, {
858
1006
  slots: t
859
1007
  }) => {
860
- const u = V(je()), o = (() => {
861
- const n = e.fieldNames;
862
- if (!!n)
1008
+ const o = $(Xe()), u = (() => {
1009
+ const l = e.fieldNames;
1010
+ if (!!l)
863
1011
  return {
864
- label: n.title,
865
- children: n.children,
866
- disabled: n.disabled,
867
- isLeaf: n.isLeaf,
868
- class: n.class
1012
+ label: l.title,
1013
+ children: l.children,
1014
+ disabled: l.disabled,
1015
+ isLeaf: l.isLeaf,
1016
+ class: l.class
869
1017
  };
870
1018
  })();
871
1019
  return () => {
872
- var n;
873
- return c(Fe, s(v(e, u), {
1020
+ var l;
1021
+ return f(Ie, y(h(e, o), {
874
1022
  data: e.treeData || e.data,
875
- props: o || e.props,
876
- nodeKey: ((n = e.fieldNames) == null ? void 0 : n.key) || e.nodeKey,
877
- showCheckbox: q(e.selectable) ? e.selectable : e.showCheckbox,
1023
+ props: u || e.props,
1024
+ nodeKey: ((l = e.fieldNames) == null ? void 0 : l.key) || e.nodeKey,
1025
+ showCheckbox: X(e.selectable) ? e.selectable : e.showCheckbox,
878
1026
  defaultExpandedKeys: e.expandedKeys || e.defaultExpandedKeys,
879
1027
  defaultCheckedKeys: e.checkedKeys || e.checkedKeys
880
1028
  }), t);
881
1029
  };
882
1030
  }
883
1031
  });
884
- function da(e) {
885
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !Dt(e);
1032
+ function Sa(e) {
1033
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !qt(e);
886
1034
  }
887
- const We = () => ({
1035
+ const Ye = () => ({
888
1036
  options: Array
889
- }), ia = x({
1037
+ }), pa = k({
890
1038
  props: {
891
- ...Te.props,
892
- ...We()
1039
+ ...Oe.props,
1040
+ ...Ye()
893
1041
  },
894
1042
  setup: (e, {
895
1043
  slots: t,
896
- expose: u
1044
+ expose: o
897
1045
  }) => {
898
- const a = R();
899
- u(L(a));
900
- const o = V(We());
901
- return () => c(Te, s({
902
- ref: a
903
- }, v(e, o)), {
1046
+ const n = T();
1047
+ o(D(n));
1048
+ const u = $(Ye());
1049
+ return () => f(Oe, y({
1050
+ ref: n
1051
+ }, h(e, u)), {
904
1052
  dropdown: () => {
905
- let n;
906
- return c(Ct, null, da(n = T(e.options, (l) => {
907
- var r;
908
- const f = (r = t.label) == null ? void 0 : r.call(t, l);
909
- return c(Kt, s({
910
- command: l.value
911
- }, v(l, "value", "label")), {
912
- default: () => [f || l.label]
1053
+ let l;
1054
+ return f(Mt, null, Sa(l = E(e.options, (d) => {
1055
+ var c;
1056
+ const s = (c = t.label) == null ? void 0 : c.call(t, d);
1057
+ return f(Nt, y({
1058
+ command: d.value
1059
+ }, h(d, "value", "label")), {
1060
+ default: () => [s || d.label]
913
1061
  });
914
- })) ? n : {
915
- default: () => [n]
1062
+ })) ? l : {
1063
+ default: () => [l]
916
1064
  });
917
1065
  },
918
1066
  ...t
919
1067
  });
920
1068
  }
921
- }), fa = B({
922
- InputComp: wt,
1069
+ }), et = () => ({
1070
+ options: Array,
1071
+ fieldNames: {
1072
+ type: Object
1073
+ },
1074
+ emitPath: {
1075
+ type: Boolean,
1076
+ default: !1
1077
+ },
1078
+ expMethods: {
1079
+ type: Array,
1080
+ default: () => [...ba]
1081
+ },
1082
+ separator$: {
1083
+ type: String
1084
+ },
1085
+ itemSeparator$: {
1086
+ type: String
1087
+ },
1088
+ parseValue$: {
1089
+ type: Function
1090
+ },
1091
+ formatValue$: {
1092
+ type: Function
1093
+ }
1094
+ }), Pa = k({
1095
+ props: {
1096
+ ...Be.props,
1097
+ ...et()
1098
+ },
1099
+ setup: (e, {
1100
+ slots: t,
1101
+ emit: o,
1102
+ expose: n
1103
+ }) => {
1104
+ const u = T();
1105
+ n(se(u, e.expMethods));
1106
+ const l = x(() => e.options || e.data), d = x(() => e.fieldNames || e.props), s = x(() => {
1107
+ const r = e.modelValue;
1108
+ if (e.parseValue$)
1109
+ return e.parseValue$(r, e);
1110
+ const i = q(r, {
1111
+ multiple: e.multiple,
1112
+ allPath: e.emitPath,
1113
+ separator: e.separator$,
1114
+ itemSeparator: e.itemSeparator$
1115
+ });
1116
+ return j(i) ? e.multiple ? E(i, (S) => j(S) ? ie(S) : S) : ie(i) : i;
1117
+ }), c = (r) => {
1118
+ var S, g;
1119
+ let i = r;
1120
+ if (e.emitPath && r) {
1121
+ const K = ((S = d.value) == null ? void 0 : S.value) || "value", R = ((g = d.value) == null ? void 0 : g.children) || "children";
1122
+ if (j(r))
1123
+ i = E(r, (B) => {
1124
+ const O = je(l.value, (v) => w(v, K) === B, {
1125
+ children: R
1126
+ }, []);
1127
+ return E(O.parentList, (v) => w(v, K));
1128
+ });
1129
+ else {
1130
+ const B = je(l.value, (O) => w(O, K) === r, {
1131
+ children: R
1132
+ }, []);
1133
+ i = E(B.parentList, (O) => w(O, K));
1134
+ }
1135
+ }
1136
+ return e.separator$ || e.itemSeparator$ ? G(i, {
1137
+ multiple: e.multiple,
1138
+ allPath: e.emitPath,
1139
+ separator: e.separator$,
1140
+ itemSeparator: e.itemSeparator$
1141
+ }) : i;
1142
+ }, a = (r) => {
1143
+ if (e.formatValue$) {
1144
+ o("update:modelValue", e.formatValue$(r, e));
1145
+ return;
1146
+ }
1147
+ const i = c(r);
1148
+ o("update:modelValue", i);
1149
+ }, m = [...$(et()), "modelValue", "data", "props"];
1150
+ return () => f(Be, y({
1151
+ ref: u
1152
+ }, h(e, m), {
1153
+ modelValue: s.value,
1154
+ "onUpdate:modelValue": (r) => a(r),
1155
+ data: l.value,
1156
+ props: d.value
1157
+ }), t);
1158
+ }
1159
+ }), tt = () => ({
1160
+ expandTrigger: {
1161
+ type: String,
1162
+ default: "click"
1163
+ },
1164
+ multiple: {
1165
+ type: Boolean,
1166
+ default: !1
1167
+ },
1168
+ checkStrictly: {
1169
+ type: Boolean,
1170
+ default: !1
1171
+ },
1172
+ emitPath: {
1173
+ type: Boolean,
1174
+ default: !0
1175
+ },
1176
+ fieldNames: {
1177
+ type: Object
1178
+ },
1179
+ expMethods: {
1180
+ type: Array,
1181
+ default: () => ["getCheckedNodes", "togglePopperVisible", "focus", "blur"]
1182
+ },
1183
+ separator$: {
1184
+ type: String
1185
+ },
1186
+ itemSeparator$: {
1187
+ type: String
1188
+ },
1189
+ parseValue$: {
1190
+ type: Function
1191
+ },
1192
+ formatValue$: {
1193
+ type: Function
1194
+ }
1195
+ }), Va = k({
1196
+ props: {
1197
+ ...Ae.props,
1198
+ ...tt()
1199
+ },
1200
+ setup: (e, {
1201
+ slots: t,
1202
+ emit: o,
1203
+ expose: n
1204
+ }) => {
1205
+ const u = T();
1206
+ n(se(u, e.expMethods));
1207
+ const l = x(() => ({
1208
+ ...e.fieldNames,
1209
+ expandTrigger: e.expandTrigger,
1210
+ multiple: e.multiple,
1211
+ checkStrictly: e.checkStrictly,
1212
+ emitPath: e.emitPath,
1213
+ ...e.props
1214
+ })), d = x(() => {
1215
+ const a = e.modelValue;
1216
+ return e.parseValue$ ? e.parseValue$(a, e) : q(a, {
1217
+ multiple: l.value.multiple,
1218
+ allPath: l.value.emitPath,
1219
+ separator: e.separator$,
1220
+ itemSeparator: e.itemSeparator$
1221
+ });
1222
+ }), s = (a) => {
1223
+ if (e.formatValue$) {
1224
+ o("update:modelValue", e.formatValue$(a, e));
1225
+ return;
1226
+ }
1227
+ if (e.separator$ || e.itemSeparator$) {
1228
+ o("update:modelValue", G(a, {
1229
+ multiple: l.value.multiple,
1230
+ allPath: l.value.emitPath,
1231
+ separator: e.separator$,
1232
+ itemSeparator: e.itemSeparator$
1233
+ }));
1234
+ return;
1235
+ }
1236
+ o("update:modelValue", a);
1237
+ }, c = [...$(tt()), "modelValue", "props"];
1238
+ return () => f(Ae, y({
1239
+ ref: u
1240
+ }, h(e, c), {
1241
+ modelValue: d.value,
1242
+ "onUpdate:modelValue": (a) => s(a),
1243
+ props: l.value
1244
+ }), t);
1245
+ }
1246
+ }), Ca = M({
1247
+ InputComp: It,
923
1248
  valueType: "text",
924
1249
  name: "PFromText"
925
- }), ma = B({
926
- InputComp: $,
1250
+ }), xa = M({
1251
+ InputComp: J,
927
1252
  valueType: "digit",
928
1253
  name: "PFormNumber"
929
- }), ya = B({
930
- InputComp: ca,
1254
+ }), Ka = M({
1255
+ InputComp: va,
931
1256
  valueType: "digitRange",
932
1257
  name: "PFormNumberRange"
933
- }), sa = B({
934
- InputComp: xt,
1258
+ }), ka = M({
1259
+ InputComp: Ot,
935
1260
  valueType: "date",
936
1261
  name: "PFormDate"
937
- }), ga = B({
938
- InputComp: kt,
1262
+ }), Fa = M({
1263
+ InputComp: Bt,
939
1264
  valueType: "time",
940
1265
  name: "PFormTime"
941
- }), va = B({
942
- InputComp: ra,
1266
+ }), wa = M({
1267
+ InputComp: sa,
943
1268
  valueType: "select",
944
1269
  name: "PFormSelect"
945
- }), ha = B({
946
- InputComp: Et,
1270
+ }), Ea = M({
1271
+ InputComp: ya,
1272
+ valueType: "selectv2",
1273
+ name: "PFormSelectV2"
1274
+ }), Ta = M({
1275
+ InputComp: Pa,
947
1276
  valueType: "treeSelect",
948
1277
  name: "PFormTreeSelect"
949
- }), ba = B({
950
- InputComp: na,
1278
+ }), Ra = M({
1279
+ InputComp: ma,
951
1280
  valueType: "checkbox",
952
1281
  name: "PFromCheckbox"
953
- }), pa = B({
954
- InputComp: la,
1282
+ }), $a = M({
1283
+ InputComp: fa,
955
1284
  valueType: "radio",
956
1285
  name: "PFromRadio"
957
- }), Sa = B({
958
- InputComp: Rt,
1286
+ }), Ma = M({
1287
+ InputComp: At,
959
1288
  valueType: "switch",
960
1289
  name: "PFromSwitch"
961
- }), Pa = B({
962
- InputComp: Ft,
1290
+ }), Na = M({
1291
+ InputComp: Va,
963
1292
  valueType: "cascader",
964
1293
  name: "PFormCascader"
965
- }), Ca = B({
966
- InputComp: Tt,
1294
+ }), Ia = M({
1295
+ InputComp: Lt,
967
1296
  valueType: "color",
968
1297
  name: "PFormColor"
969
- }), ut = x({
1298
+ }), bt = k({
970
1299
  props: {
971
- ...v(le.props, "label", "prop"),
1300
+ ...h(ue.props, "label", "prop"),
972
1301
  title: {
973
1302
  type: String
974
1303
  },
@@ -985,53 +1314,53 @@ const We = () => ({
985
1314
  setup: (e, {
986
1315
  slots: t
987
1316
  }) => {
988
- const u = ({
989
- row: n,
990
- column: l,
991
- $index: f
1317
+ const o = ({
1318
+ row: l,
1319
+ column: d,
1320
+ $index: s
992
1321
  }) => {
993
1322
  var g;
994
- const r = n, m = f, d = {
995
- ...l,
996
- title: l.label,
997
- dataIndex: l.property
998
- }, i = N(n, d.dataIndex), P = {
999
- value: i,
1000
- text: i,
1001
- record: r,
1002
- column: d,
1003
- index: m
1004
- }, w = (g = t.bodyCell) == null ? void 0 : g.call(t, P);
1005
- return w || (e.customRender ? e.customRender(P) : i);
1006
- }, o = {
1323
+ const c = l, a = s, m = {
1324
+ ...d,
1325
+ title: d.label,
1326
+ dataIndex: d.property
1327
+ }, r = w(l, m.dataIndex), i = {
1328
+ value: r,
1329
+ text: r,
1330
+ record: c,
1331
+ column: m,
1332
+ index: a
1333
+ }, S = (g = t.bodyCell) == null ? void 0 : g.call(t, i);
1334
+ return S || (e.customRender ? e.customRender(i) : r);
1335
+ }, u = {
1007
1336
  header: ({
1008
- column: n,
1009
- $index: l
1337
+ column: l,
1338
+ $index: d
1010
1339
  }) => {
1011
- var i;
1012
- const f = l, r = n.label, m = {
1013
- ...n,
1014
- title: r,
1015
- dataIndex: n.property
1340
+ var r;
1341
+ const s = d, c = l.label, a = {
1342
+ ...l,
1343
+ title: c,
1344
+ dataIndex: l.property
1016
1345
  };
1017
- return ((i = t.headerCell) == null ? void 0 : i.call(t, {
1018
- title: r,
1019
- column: m,
1020
- index: f
1021
- })) || r;
1346
+ return ((r = t.headerCell) == null ? void 0 : r.call(t, {
1347
+ title: c,
1348
+ column: a,
1349
+ index: s
1350
+ })) || c;
1022
1351
  }
1023
1352
  };
1024
- return (!e.children || D(e.children) <= 0) && (o.default = u), () => c(le, s(v(e, "title", "dataIndex", "prop", "customRender", "children"), {
1353
+ return (!e.children || L(e.children) <= 0) && (u.default = o), () => f(ue, y(h(e, "title", "dataIndex", "prop", "customRender", "children"), {
1025
1354
  prop: e.dataIndex,
1026
1355
  label: e.title
1027
1356
  }), {
1028
- default: () => [D(e.children) > 0 && T(e.children, (n) => c(ut, s({
1029
- key: n.dataIndex
1030
- }, n), t))],
1031
- ...o
1357
+ default: () => [L(e.children) > 0 && E(e.children, (l) => f(bt, y({
1358
+ key: l.dataIndex
1359
+ }, l), t))],
1360
+ ...u
1032
1361
  });
1033
1362
  }
1034
- }), Ka = ["clearSelection", "getSelectionRows", "toggleRowSelection", "toggleAllSelection", "toggleRowExpansion", "setCurrentRow", "clearSort", "clearFilter", "doLayout", "sort", "scrollTo", "setScrollTop", "setScrollLeft"], wa = () => ({
1363
+ }), Oa = ["clearSelection", "getSelectionRows", "toggleRowSelection", "toggleAllSelection", "toggleRowExpansion", "setCurrentRow", "clearSort", "clearFilter", "doLayout", "sort", "scrollTo", "setScrollTop", "setScrollLeft"], Ba = () => ({
1035
1364
  columns: {
1036
1365
  type: Array
1037
1366
  },
@@ -1051,141 +1380,141 @@ const We = () => ({
1051
1380
  type: Object,
1052
1381
  default: void 0
1053
1382
  }
1054
- }), ct = x({
1383
+ }), St = k({
1055
1384
  props: {
1056
- ...Me.props,
1057
- ...wa()
1385
+ ...Le.props,
1386
+ ...Ba()
1058
1387
  },
1059
1388
  setup: (e, {
1060
1389
  slots: t,
1061
- expose: u,
1062
- emit: a
1390
+ expose: o,
1391
+ emit: n
1063
1392
  }) => {
1064
- const o = R(), n = tt("table");
1065
- u($e(Ka, o));
1066
- const l = E(() => e.dataSource || e.data || []), f = E(() => X(l.value, (S, C) => ({
1067
- ...S,
1068
- [r(C)]: !0
1069
- }), {})), r = (S) => {
1393
+ const u = T(), l = ft("table");
1394
+ o(at(Oa, u));
1395
+ const d = x(() => e.dataSource || e.data || []), s = x(() => te(d.value, (v, C) => ({
1396
+ ...v,
1397
+ [c(C)]: !0
1398
+ }), {})), c = (v) => {
1070
1399
  const C = e.rowKey;
1071
- return Ut(C) ? C(S) : C ? S[C] : S.id;
1072
- }, m = E(() => !!e.rowSelection), d = E(() => {
1073
- const S = e.rowSelection;
1074
- return S ? !S.type || S.type === "multi" : !1;
1075
- }), i = E(() => {
1076
- const S = e.selectedRowKeys;
1077
- return Xe(S) ? S : S ? [S] : [];
1078
- }), P = E(() => X(i.value, (S, C) => ({
1079
- ...S,
1400
+ return Jt(C) ? C(v) : C ? v[C] : v.id;
1401
+ }, a = x(() => !!e.rowSelection), m = x(() => {
1402
+ const v = e.rowSelection;
1403
+ return v ? !v.type || v.type === "multi" : !1;
1404
+ }), r = x(() => {
1405
+ const v = e.selectedRowKeys;
1406
+ return j(v) ? v : v ? [v] : [];
1407
+ }), i = x(() => te(r.value, (v, C) => ({
1408
+ ...v,
1080
1409
  [C]: !0
1081
1410
  }), {}));
1082
- let w = [], g = !1;
1083
- const k = (S) => {
1084
- var M, y, h, b, K, A, ie, fe;
1411
+ let S = [], g = !1;
1412
+ const K = (v) => {
1413
+ var N, b, p, P, F, z, ge, he;
1085
1414
  if (!g)
1086
1415
  return;
1087
- const C = T(S, (I) => r(I));
1088
- if (m.value && !d.value) {
1089
- if (D(C) <= 0 && D(w) > 0) {
1090
- const I = l.value, O = jt(I, (W) => r(W) === w[0]);
1091
- O && ((M = o.value) == null || M.toggleRowSelection(O, !0));
1416
+ const C = E(v, (I) => c(I));
1417
+ if (a.value && !m.value) {
1418
+ if (L(C) <= 0 && L(S) > 0) {
1419
+ const I = d.value, A = Qt(I, (_) => c(_) === S[0]);
1420
+ A && ((N = u.value) == null || N.toggleRowSelection(A, !0));
1092
1421
  return;
1093
- } else if (D(C) > 1) {
1094
- const I = Wt(C);
1095
- Ve(S, (O) => {
1096
- var W;
1097
- (W = o.value) == null || W.toggleRowSelection(O, r(O) === I);
1422
+ } else if (L(C) > 1) {
1423
+ const I = ie(C);
1424
+ Ue(v, (A) => {
1425
+ var _;
1426
+ (_ = u.value) == null || _.toggleRowSelection(A, c(A) === I);
1098
1427
  });
1099
1428
  return;
1100
1429
  }
1101
1430
  }
1102
- if (!Gt(i.value, C, {
1431
+ if (!ta(r.value, C, {
1103
1432
  sort: !0
1104
1433
  })) {
1105
- if (!d.value) {
1106
- const I = N(C, 0);
1107
- (h = (y = e.rowSelection).onChange) == null || h.call(y, I, N(S, 0)), a("update:selectedRowKeys", I);
1434
+ if (!m.value) {
1435
+ const I = w(C, 0);
1436
+ (p = (b = e.rowSelection).onChange) == null || p.call(b, I, w(v, 0)), n("update:selectedRowKeys", I);
1108
1437
  return;
1109
1438
  }
1110
- if ((b = e.rowSelection) != null && b.pagination) {
1111
- const I = oe(i.value, (O) => !f.value[O]);
1112
- I.push(...C), (A = (K = e.rowSelection).onChange) == null || A.call(K, I, []), a("update:selectedRowKeys", I);
1439
+ if ((P = e.rowSelection) != null && P.pagination) {
1440
+ const I = ce(r.value, (A) => !s.value[A]);
1441
+ I.push(...C), (z = (F = e.rowSelection).onChange) == null || z.call(F, I, []), n("update:selectedRowKeys", I);
1113
1442
  return;
1114
1443
  }
1115
- (fe = (ie = e.rowSelection).onChange) == null || fe.call(ie, C, S), a("update:selectedRowKeys", C);
1444
+ (he = (ge = e.rowSelection).onChange) == null || he.call(ge, C, v), n("update:selectedRowKeys", C);
1116
1445
  }
1117
- }, F = E(() => {
1446
+ }, R = x(() => {
1118
1447
  if (!!e.rowSelection)
1119
1448
  return {
1120
- onSelectionChange: k
1449
+ onSelectionChange: K
1121
1450
  };
1122
1451
  });
1123
- _(() => {
1452
+ ee(() => {
1124
1453
  var C;
1125
- g = !1, w = i.value;
1126
- const S = l.value;
1127
- if (m.value) {
1128
- const M = (C = o.value) == null ? void 0 : C.getSelectionRows(), y = X(M, (h, b) => ({
1129
- ...h,
1130
- [r(b)]: !0
1454
+ g = !1, S = r.value;
1455
+ const v = d.value;
1456
+ if (a.value) {
1457
+ const N = (C = u.value) == null ? void 0 : C.getSelectionRows(), b = te(N, (p, P) => ({
1458
+ ...p,
1459
+ [c(P)]: !0
1131
1460
  }), {});
1132
- Lt(() => {
1133
- Ve(S, (h) => {
1134
- var K;
1135
- const b = r(h);
1136
- P.value[b] !== y[b] && ((K = o.value) == null || K.toggleRowSelection(h, !!P.value[b]));
1461
+ Gt(() => {
1462
+ Ue(v, (p) => {
1463
+ var F;
1464
+ const P = c(p);
1465
+ i.value[P] !== b[P] && ((F = u.value) == null || F.toggleRowSelection(p, !!i.value[P]));
1137
1466
  }), g = !0;
1138
1467
  });
1139
1468
  } else
1140
1469
  g = !0;
1141
- }, [i, l]);
1142
- const Z = () => {
1143
- var S, C;
1470
+ }, [r, d]);
1471
+ const B = () => {
1472
+ var v, C;
1144
1473
  if (e.spanMethod)
1145
1474
  return e.spanMethod;
1146
- if (((S = e.mergeOpts) == null ? void 0 : S.rowNames) || ((C = e.mergeOpts) == null ? void 0 : C.colNames)) {
1147
- const M = _t(e.mergeOpts);
1475
+ if (((v = e.mergeOpts) == null ? void 0 : v.rowNames) || ((C = e.mergeOpts) == null ? void 0 : C.colNames)) {
1476
+ const N = aa(e.mergeOpts);
1148
1477
  return ({
1149
- row: y,
1150
- column: h
1478
+ row: b,
1479
+ column: p
1151
1480
  }) => {
1152
- const b = h.property;
1153
- if (M[b]) {
1154
- const K = y[M[b]], A = y[b + "-colspan"];
1481
+ const P = p.property;
1482
+ if (N[P]) {
1483
+ const F = b[N[P]], z = b[P + "-colspan"];
1155
1484
  return {
1156
- rowspan: K !== void 0 ? K : 1,
1157
- colspan: A !== void 0 ? A : 1
1485
+ rowspan: F !== void 0 ? F : 1,
1486
+ colspan: z !== void 0 ? z : 1
1158
1487
  };
1159
1488
  }
1160
1489
  };
1161
1490
  }
1162
1491
  return e.spanMethod;
1163
- }, J = E(() => Z());
1164
- return () => c(Me, s({
1165
- ref: o,
1166
- id: n
1167
- }, v(e, "columns", "dataSource", "data", "loading", "spanMethod"), {
1168
- data: l.value,
1169
- spanMethod: J.value
1170
- }, F.value), {
1492
+ }, O = x(() => B());
1493
+ return () => f(Le, y({
1494
+ ref: u,
1495
+ id: l
1496
+ }, h(e, "columns", "dataSource", "data", "loading", "spanMethod"), {
1497
+ data: d.value,
1498
+ spanMethod: O.value
1499
+ }, R.value), {
1171
1500
  default: () => {
1172
- var S, C, M, y, h;
1173
- return [(S = t.start) == null ? void 0 : S.call(t), m.value && c(le, s({
1501
+ var v, C, N, b, p;
1502
+ return [(v = t.start) == null ? void 0 : v.call(t), a.value && f(ue, y({
1174
1503
  type: "selection",
1175
- className: d.value ? "pro-multi" : "pro-single"
1176
- }, v((C = e.rowSelection) == null ? void 0 : C.column, "slots")), (y = (M = e.rowSelection) == null ? void 0 : M.column) == null ? void 0 : y.slots), T(e.columns, (b) => c(ut, s({
1177
- key: b.dataIndex
1178
- }, b), t)), (h = t.default) == null ? void 0 : h.call(t), e.loading && c(at, {
1179
- target: n,
1504
+ className: m.value ? "pro-multi" : "pro-single"
1505
+ }, h((C = e.rowSelection) == null ? void 0 : C.column, "slots")), (b = (N = e.rowSelection) == null ? void 0 : N.column) == null ? void 0 : b.slots), E(e.columns, (P) => f(bt, y({
1506
+ key: P.dataIndex
1507
+ }, P), t)), (p = t.default) == null ? void 0 : p.call(t), e.loading && f(st, {
1508
+ target: l,
1180
1509
  loading: !0
1181
1510
  }, null)];
1182
1511
  },
1183
- ...G(t, "append", "empty")
1512
+ ...Y(t, "append", "empty")
1184
1513
  });
1185
1514
  }
1186
- }), xa = x({
1515
+ }), Aa = k({
1187
1516
  props: {
1188
- ...re.props,
1517
+ ...de.props,
1189
1518
  type: {
1190
1519
  type: String,
1191
1520
  default: "primary"
@@ -1197,8 +1526,8 @@ const We = () => ({
1197
1526
  },
1198
1527
  setup: (e, {
1199
1528
  slots: t
1200
- }) => () => c(re, e, t)
1201
- }), ka = () => ({
1529
+ }) => () => f(de, e, t)
1530
+ }), La = () => ({
1202
1531
  fixed: {
1203
1532
  type: Boolean,
1204
1533
  default: !0
@@ -1215,204 +1544,211 @@ const We = () => ({
1215
1544
  type: Number,
1216
1545
  default: 100
1217
1546
  }
1218
- }), Ea = x({
1547
+ }), Da = k({
1219
1548
  inheritAttrs: !1,
1220
1549
  props: {
1221
- ...v(Ie.props, ["class"]),
1222
- ...ka()
1550
+ ...h(De.props, ["class"]),
1551
+ ...La()
1223
1552
  },
1224
1553
  setup: (e, {
1225
1554
  attrs: t
1226
1555
  }) => {
1227
- const u = R(), [a, o] = Zt(), n = Je({
1556
+ const o = T(), [n, u] = la(), l = dt({
1228
1557
  width: 0,
1229
1558
  height: 0
1230
1559
  });
1231
- Jt(u, (d) => {
1232
- var P;
1233
- const i = (P = d[0]) == null ? void 0 : P.contentRect;
1234
- n.width = i.width, n.height = i.height, o();
1560
+ na(o, (m) => {
1561
+ var i;
1562
+ const r = (i = m[0]) == null ? void 0 : i.contentRect;
1563
+ l.width = r.width, l.height = r.height, u();
1235
1564
  });
1236
- const l = E(() => {
1237
- var w, g;
1238
- const d = ((w = e.columns) == null ? void 0 : w.filter((k) => k.width || k.minWidth)) || [], i = d.reduce((k, F) => k + (F.width || F.minWidth || 0), 0), P = (((g = e.columns) == null ? void 0 : g.length) || 0) - d.length;
1239
- return P > 0 && n.width > 0 ? Math.max((n.width - i - (e.vScrollbarSize || 0)) / P, e.minWidth || 0) : e.minWidth;
1240
- }), f = E(() => T(e.columns, (d) => {
1241
- const i = d.dataIndex || d.key, P = {
1242
- ...d,
1243
- width: d.width || d.minWidth || l.value,
1244
- key: i,
1245
- dataKey: i
1565
+ const d = x(() => {
1566
+ var S, g;
1567
+ const m = ((S = e.columns) == null ? void 0 : S.filter((K) => K.width || K.minWidth)) || [], r = m.reduce((K, R) => K + (R.width || R.minWidth || 0), 0), i = (((g = e.columns) == null ? void 0 : g.length) || 0) - m.length;
1568
+ return i > 0 && l.width > 0 ? Math.max((l.width - r - (e.vScrollbarSize || 0)) / i, e.minWidth || 0) : e.minWidth;
1569
+ }), s = x(() => E(e.columns, (m) => {
1570
+ const r = m.dataIndex || m.key, i = {
1571
+ ...m,
1572
+ width: m.width || m.minWidth || d.value,
1573
+ key: r,
1574
+ dataKey: r
1246
1575
  };
1247
- return d.customRender && (P.cellRenderer = ({
1248
- cellData: w,
1576
+ return m.customRender && (i.cellRenderer = ({
1577
+ cellData: S,
1249
1578
  rowData: g,
1250
- rowIndex: k,
1251
- column: F
1252
- }) => d.customRender({
1253
- value: w,
1254
- text: w,
1579
+ rowIndex: K,
1580
+ column: R
1581
+ }) => m.customRender({
1582
+ value: S,
1583
+ text: S,
1255
1584
  record: g,
1256
- column: F,
1257
- index: k
1258
- })), P;
1259
- })), r = E(() => !e.estimatedRowHeight && e.dynamicHei ? 50 : e.estimatedRowHeight), m = E(() => {
1260
- const d = ["el-table"];
1261
- return r.value && d.push("dynamic-hei"), d;
1585
+ column: R,
1586
+ index: K
1587
+ })), i;
1588
+ })), c = x(() => !e.estimatedRowHeight && e.dynamicHei ? 50 : e.estimatedRowHeight), a = x(() => {
1589
+ const m = ["el-table"];
1590
+ return c.value && m.push("dynamic-hei"), m;
1262
1591
  });
1263
- return () => c("div", s({
1592
+ return () => f("div", y({
1264
1593
  class: "pro-table-v2-wrapper",
1265
1594
  style: {
1266
- "--estimated-hei": `${r.value || 0}px`
1595
+ "--estimated-hei": `${c.value || 0}px`
1267
1596
  },
1268
- ref: u
1269
- }, G(t, ["class"])), [n.width > 0 && n.height > 0 && c(Ie, s({
1270
- key: a.value,
1271
- class: m.value
1272
- }, v(t, ["class", "className"]), v(e, "dataSource", "data", "columns", "estimatedRowHeight", "width", "height"), {
1273
- estimatedRowHeight: r.value,
1274
- columns: f.value,
1597
+ ref: o
1598
+ }, Y(t, ["class"])), [l.width > 0 && l.height > 0 && f(De, y({
1599
+ key: n.value,
1600
+ class: a.value
1601
+ }, h(t, ["class", "className"]), h(e, "dataSource", "data", "columns", "estimatedRowHeight", "width", "height"), {
1602
+ estimatedRowHeight: c.value,
1603
+ columns: s.value,
1275
1604
  data: e.dataSource || e.data || [],
1276
- width: n.width,
1277
- height: n.height
1605
+ width: l.width,
1606
+ height: l.height
1278
1607
  }), null)]);
1279
1608
  }
1280
1609
  });
1281
- U.props = {
1282
- ...ne.props,
1283
- ...U.props,
1284
- formMethods: { type: Array, default: et }
1610
+ W.props = {
1611
+ ...oe.props,
1612
+ ...W.props,
1613
+ formMethods: { type: Array, default: mt }
1285
1614
  };
1286
- Y.props = {
1287
- ...U.props,
1288
- ...Y.props,
1615
+ ae.props = {
1616
+ ...W.props,
1617
+ ...ae.props,
1289
1618
  inline: { type: Boolean, default: !0 }
1290
1619
  };
1291
- me.props = {
1292
- ...ae.props,
1293
- ...me.props
1620
+ ve.props = {
1621
+ ...re.props,
1622
+ ...ve.props
1294
1623
  };
1295
- ee.props = {
1296
- ...ct.props,
1297
- ...ee.props
1624
+ le.props = {
1625
+ ...St.props,
1626
+ ...le.props
1298
1627
  };
1299
- te.props = {
1300
- ..._e.props,
1301
- ...te.props
1628
+ ne.props = {
1629
+ ...ot.props,
1630
+ ...ne.props
1302
1631
  };
1303
- ye.props = {
1304
- ...te.props,
1305
- ...ye.props
1632
+ be.props = {
1633
+ ...ne.props,
1634
+ ...be.props
1306
1635
  };
1307
- se.props = {
1308
- ...U.props,
1309
- ...se.props
1636
+ Se.props = {
1637
+ ...W.props,
1638
+ ...Se.props
1310
1639
  };
1311
- ge.props = {
1312
- ...nt.props,
1313
- ...ge.props
1640
+ pe.props = {
1641
+ ...yt.props,
1642
+ ...pe.props
1314
1643
  };
1315
- ve.props = {
1316
- ...ot.props,
1317
- ...ve.props,
1644
+ Pe.props = {
1645
+ ...vt.props,
1646
+ ...Pe.props,
1318
1647
  modelValue: String
1319
1648
  };
1320
- he.props = {
1321
- ...Ze.props,
1322
- ...he.props,
1649
+ Ve.props = {
1650
+ ...ut.props,
1651
+ ...Ve.props,
1323
1652
  placement: { type: String, default: "top-start" }
1324
1653
  };
1325
- const Na = {
1326
- [p.LoadingKey]: at,
1327
- [p.RowKey]: Mt,
1328
- [p.ColKey]: It,
1329
- [p.ButtonKey]: re,
1330
- [p.DescriptionsKey]: _e,
1331
- [p.DescriptionsItemKey]: Vt,
1332
- [p.MenusKey]: oa,
1333
- [p.ModalKey]: nt,
1334
- [p.DrawerKey]: ea,
1335
- [p.PaginationKey]: ta,
1336
- [p.PopoverKey]: aa,
1337
- [p.TooltipKey]: Ze,
1338
- [p.CheckboxKey]: Ge,
1339
- [p.FormKey]: Qt,
1340
- [p.FormItemKey]: Ye,
1341
- [p.TableKey]: ct,
1342
- [p.TableV2Key]: Ea,
1343
- [p.TableOperateKey]: xa,
1344
- [p.UploaderKey]: ot,
1345
- [p.DropdownKey]: ia,
1346
- [p.ScrollKey]: Bt,
1347
- [p.EmptyKey]: Nt,
1348
- [p.ProFormKey]: U,
1349
- [p.ProSearchFormKey]: Y,
1350
- [p.ProTableKey]: ee,
1351
- [p.ProCurdKey]: it,
1352
- [p.ProListKey]: ft,
1353
- [p.ProPageKey]: mt,
1354
- [p.ProOperateKey]: yt,
1355
- text: be,
1356
- digit: st,
1357
- date: gt,
1358
- time: be,
1359
- select: Q,
1360
- radio: Q,
1361
- checkbox: Q,
1362
- treeSelect: pe,
1363
- cascader: pe
1364
- }, Oa = {
1365
- text: fa,
1366
- digit: ma,
1367
- digitRange: ya,
1368
- date: sa,
1369
- time: ga,
1370
- select: va,
1371
- treeSelect: ha,
1372
- checkbox: ba,
1373
- radio: pa,
1374
- switch: Sa,
1375
- cascader: Pa,
1376
- color: Ca
1654
+ const _a = {
1655
+ [V.LoadingKey]: st,
1656
+ [V.RowKey]: Dt,
1657
+ [V.ColKey]: Ut,
1658
+ [V.ButtonKey]: de,
1659
+ [V.DescriptionsKey]: ot,
1660
+ [V.DescriptionsItemKey]: zt,
1661
+ [V.MenusKey]: ga,
1662
+ [V.ModalKey]: yt,
1663
+ [V.DrawerKey]: da,
1664
+ [V.PaginationKey]: ca,
1665
+ [V.PopoverKey]: ia,
1666
+ [V.TooltipKey]: ut,
1667
+ [V.CheckboxKey]: rt,
1668
+ [V.FormKey]: ra,
1669
+ [V.FormItemKey]: it,
1670
+ [V.TableKey]: St,
1671
+ [V.TableV2Key]: Da,
1672
+ [V.TableOperateKey]: Aa,
1673
+ [V.UploaderKey]: vt,
1674
+ [V.DropdownKey]: pa,
1675
+ [V.ScrollKey]: jt,
1676
+ [V.EmptyKey]: Wt,
1677
+ [V.ProFormKey]: W,
1678
+ [V.ProSearchFormKey]: ae,
1679
+ [V.ProTableKey]: le,
1680
+ [V.ProCurdKey]: Pt,
1681
+ [V.ProListKey]: Vt,
1682
+ [V.ProPageKey]: Ct,
1683
+ [V.ProOperateKey]: xt,
1684
+ text: Ce,
1685
+ digit: Kt,
1686
+ date: kt,
1687
+ time: Ce,
1688
+ select: Z,
1689
+ selectv2: Z,
1690
+ radio: Z,
1691
+ checkbox: Z,
1692
+ treeSelect: xe,
1693
+ cascader: xe
1694
+ }, Za = {
1695
+ text: Ca,
1696
+ digit: xa,
1697
+ digitRange: Ka,
1698
+ date: ka,
1699
+ time: Fa,
1700
+ select: wa,
1701
+ selectv2: Ea,
1702
+ treeSelect: Ta,
1703
+ checkbox: Ra,
1704
+ radio: $a,
1705
+ switch: Ma,
1706
+ cascader: Na,
1707
+ color: Ia
1377
1708
  };
1378
1709
  export {
1379
- et as FormMethods,
1380
- ca as InputNumberRange,
1381
- na as ProCheckbox,
1382
- ea as ProDrawer,
1383
- ia as ProDropdown,
1384
- Qt as ProForm,
1385
- Pa as ProFormCascader,
1386
- ba as ProFormCheckbox,
1387
- Ca as ProFormColor,
1388
- sa as ProFormDatePicker,
1389
- ya as ProFormInputNumberRange,
1390
- Ye as ProFormItem,
1391
- pa as ProFormRadio,
1392
- va as ProFormSelect,
1393
- Sa as ProFormSwitch,
1394
- fa as ProFormText,
1395
- ma as ProFormTextNumber,
1396
- ga as ProFormTimePicker,
1397
- ha as ProFormTreeSelect,
1398
- at as ProLoading,
1399
- oa as ProMenus,
1400
- nt as ProModal,
1401
- ta as ProPagination,
1402
- aa as ProPopover,
1403
- la as ProRadio,
1404
- ra as ProSelect,
1405
- ct as ProTable,
1406
- ut as ProTableColumn,
1407
- xa as ProTableOperateItem,
1408
- Ea as ProTableV2,
1409
- Va as ProTabs,
1410
- Ba as ProTree,
1411
- ot as ProUploader,
1412
- Ka as TableMethods,
1413
- ua as UploadMethods,
1414
- B as createFormItemComponent,
1415
- tt as createLoadingId,
1416
- Na as elementMap,
1417
- Oa as formElementMap
1710
+ mt as FormMethods,
1711
+ va as InputNumberRange,
1712
+ Va as ProCascader,
1713
+ ma as ProCheckbox,
1714
+ da as ProDrawer,
1715
+ pa as ProDropdown,
1716
+ ra as ProForm,
1717
+ Na as ProFormCascader,
1718
+ Ra as ProFormCheckbox,
1719
+ Ia as ProFormColor,
1720
+ ka as ProFormDatePicker,
1721
+ Ka as ProFormInputNumberRange,
1722
+ it as ProFormItem,
1723
+ $a as ProFormRadio,
1724
+ wa as ProFormSelect,
1725
+ Ea as ProFormSelectV2,
1726
+ Ma as ProFormSwitch,
1727
+ Ca as ProFormText,
1728
+ xa as ProFormTextNumber,
1729
+ Fa as ProFormTimePicker,
1730
+ Ta as ProFormTreeSelect,
1731
+ st as ProLoading,
1732
+ ga as ProMenus,
1733
+ yt as ProModal,
1734
+ ca as ProPagination,
1735
+ ia as ProPopover,
1736
+ fa as ProRadio,
1737
+ sa as ProSelect,
1738
+ ya as ProSelectV2,
1739
+ St as ProTable,
1740
+ bt as ProTableColumn,
1741
+ Aa as ProTableOperateItem,
1742
+ Da as ProTableV2,
1743
+ qa as ProTabs,
1744
+ Ga as ProTree,
1745
+ Pa as ProTreeSelect,
1746
+ vt as ProUploader,
1747
+ Oa as TableMethods,
1748
+ ba as TreeMethods,
1749
+ ha as UploadMethods,
1750
+ M as createFormItemComponent,
1751
+ ft as createLoadingId,
1752
+ _a as elementMap,
1753
+ Za as formElementMap
1418
1754
  };