@vue-start/element-pro 0.2.38 → 0.2.39

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