@vue-start/element-pro 0.2.30 → 0.2.32

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 Be, createFormItemCompFn as Je, createExposeObj as U, useProConfig as Qe, ProForm as O, ProSearchForm as W, ProFormList as te, ProTable as Z, ProDesc as H, ProCurdDesc as ne, ProCurdForm as ae, ProCurdModal as le, ProUploaderText as re, ProTip as oe, ElementKeys as b, ProCurd as Xe, ProList as Ye, ProPage as et, ProShowText as ue, ProShowDigit as tt, ProShowDate as nt, ProShowOptions as _, ProShowTree as ce } from "@vue-start/pro";
2
- import { ElFormItem as J, ElForm as Q, ElLoading as Ne, ElDialog as de, ElButton as z, ElPagination as ie, ElPopover as fe, ElCheckboxGroup as me, ElCheckboxButton as at, ElCheckbox as De, ElRadioGroup as ye, ElRadioButton as lt, ElRadio as rt, ElSelect as se, ElOption as ot, ElTabs as ge, ElTabPane as ut, ElMenu as q, ElUpload as ve, useFormItem as ct, ElInputNumber as j, ElTree as be, ElDropdown as he, ElDropdownMenu as dt, ElDropdownItem as it, ElInput as ft, ElDatePicker as mt, ElTimePicker as yt, ElTreeSelect as st, ElSwitch as gt, ElCascader as vt, ElTableColumn as X, ElTable as Pe, ElDescriptions as Le, ElTooltip as Ae, ElRow as bt, ElCol as ht, ElDescriptionsItem as Pt } from "element-plus";
3
- import { defineComponent as C, createVNode as c, mergeProps as s, reactive as St, ref as T, toRaw as pt, computed as N, Fragment as Oe, isVNode as Ct, nextTick as Se } from "vue";
4
- import { keys as w, omit as y, isBoolean as $, isString as kt, debounce as Kt, map as R, size as D, pick as Y, get as B, isNumber as L, isArray as Ft, filter as pe, reduce as Ce, forEach as Et, find as xt, isFunction as Tt } from "lodash";
5
- import { useEffect as G, generateId as Rt, useWatch as A, convertCollection as wt, isValidFileType as Mt, convertFileSize as It, isSame as ke, getNameMapByMergeOpts as Vt } from "@vue-start/hooks";
6
- const Ke = () => ({
1
+ import { createExpose as Be, createFormItemCompFn as Qe, createExposeObj as D, useGetCompByKey as Ne, ElementKeys as m, useProConfig as Xe, ProForm as U, ProSearchForm as _, ProFormList as ae, ProTable as W, ProDesc as Z, ProCurdDesc as ne, ProCurdForm as le, ProCurdModal as re, ProUploaderText as oe, ProTip as ue, ProCurd as Ye, ProList as et, ProPage as tt, ProOperate as at, ProShowText as ce, ProShowDigit as nt, ProShowDate as lt, ProShowOptions as G, ProShowTree as de } from "@vue-start/pro";
2
+ import { ElFormItem as H, ElForm as J, ElLoading as Oe, ElDialog as ie, ElDrawer as fe, ElPagination as ye, ElPopover as me, ElCheckboxGroup as se, ElCheckboxButton as rt, ElCheckbox as De, ElRadioGroup as ge, ElRadioButton as ot, ElRadio as ut, ElSelect as be, ElOption as ct, ElTabs as ve, ElTabPane as dt, ElMenu as j, ElUpload as pe, useFormItem as it, ElInputNumber as z, ElTree as Se, ElDropdown as Pe, ElDropdownMenu as ft, ElDropdownItem as yt, ElInput as mt, ElDatePicker as st, ElTimePicker as gt, ElTreeSelect as bt, ElSwitch as vt, ElCascader as pt, ElTableColumn as Q, ElTable as he, ElButton as X, ElDescriptions as Le, ElTooltip as Ue, ElRow as St, ElCol as Pt, ElDescriptionsItem as ht, ElScrollbar as Ct, ElEmpty as Kt } from "element-plus";
3
+ import { defineComponent as C, createVNode as c, mergeProps as y, reactive as kt, ref as F, toRaw as xt, computed as N, Fragment as Ae, isVNode as Et, nextTick as Ft } from "vue";
4
+ import { keys as I, omit as s, isBoolean as $, isString as Tt, debounce as Rt, map as M, size as B, pick as ee, get as O, isNumber as L, isArray as wt, filter as Ce, reduce as Ke, forEach as ke, isFunction as Mt, find as It, last as Vt } from "lodash";
5
+ import { useEffect as q, generateId as Bt, useWatch as A, convertCollection as Nt, isValidFileType as Ot, convertFileSize as Dt, isSame as Lt, getNameMapByMergeOpts as Ut } from "@vue-start/hooks";
6
+ const xe = () => ({
7
7
  name: {
8
8
  type: [String, Array]
9
9
  }
10
10
  }), ze = C({
11
11
  props: {
12
- ...J.props,
13
- ...Ke()
12
+ ...H.props,
13
+ ...xe()
14
14
  },
15
15
  setup: (e, {
16
16
  slots: t
17
17
  }) => {
18
- const u = w(Ke());
19
- return () => c(J, s(y(e, ...u, "name", "prop"), {
18
+ const u = I(xe());
19
+ return () => c(H, y(s(e, ...u, "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
- }), Ue = ["clearValidate", "resetFields", "scrollToField", "validate", "validateField", "submit"], Bt = C({
26
+ }), je = ["clearValidate", "resetFields", "scrollToField", "validate", "validateField", "submit"], At = C({
27
27
  props: {
28
- ...Q.props,
28
+ ...J.props,
29
29
  hideRequiredMark: {
30
30
  type: [Boolean, Object],
31
31
  default: void 0
@@ -34,29 +34,29 @@ const Ke = () => ({
34
34
  setup: (e, {
35
35
  slots: t,
36
36
  emit: u,
37
- expose: n
37
+ expose: a
38
38
  }) => {
39
- const o = e.model || St({}), l = T();
40
- return G(() => {
39
+ const o = e.model || kt({}), l = F();
40
+ return q(() => {
41
41
  !l.value || (l.value.submit = () => {
42
- var a;
43
- (a = l.value) == null || a.validate((f, r) => {
44
- f ? u("finish", pt(o)) : u("finishFailed", r);
42
+ var n;
43
+ (n = l.value) == null || n.validate((f, r) => {
44
+ f ? u("finish", xt(o)) : u("finishFailed", r);
45
45
  });
46
46
  });
47
- }, []), n(Be(Ue, l)), () => c(Q, s({
47
+ }, []), a(Be(je, l)), () => c(J, y({
48
48
  ref: l
49
- }, y(e, "model"), {
49
+ }, s(e, "model"), {
50
50
  hideRequiredAsterisk: $(e.hideRequiredMark) ? e.hideRequiredMark : e.hideRequiredAsterisk,
51
51
  model: o
52
52
  }), t);
53
53
  }
54
- }), M = Je(ze, (e, t, u) => ({
54
+ }), V = Qe(ze, (e, t, u) => ({
55
55
  modelValue: e,
56
56
  "onUpdate:modelValue": t,
57
57
  clearable: !0,
58
58
  disabled: u
59
- })), je = (e = "comp") => e + "-" + Rt(), Nt = () => ({
59
+ })), $e = (e = "comp") => e + "-" + Bt(), zt = () => ({
60
60
  loading: {
61
61
  type: Boolean
62
62
  },
@@ -86,20 +86,20 @@ const Ke = () => ({
86
86
  }
87
87
  }), qe = C({
88
88
  props: {
89
- ...Nt()
89
+ ...zt()
90
90
  },
91
91
  setup: (e, {
92
92
  slots: t
93
93
  }) => {
94
- const u = je();
95
- return G(() => {
94
+ const u = $e();
95
+ return q(() => {
96
96
  if (!e.loading)
97
97
  return;
98
- let n = e.target;
99
- if (t.default ? n = document.getElementById(u) : e.target && kt(e.target) && (n = document.querySelector("#" + e.target)), !n)
98
+ let a = e.target;
99
+ if (t.default ? a = document.getElementById(u) : e.target && Tt(e.target) && (a = document.querySelector("#" + e.target)), !a)
100
100
  return;
101
- const o = Ne.service({
102
- target: n,
101
+ const o = Oe.service({
102
+ target: a,
103
103
  body: e.body,
104
104
  fullscreen: e.fullscreen,
105
105
  lock: e.lock,
@@ -115,7 +115,7 @@ const Ke = () => ({
115
115
  id: u
116
116
  }, [t.default()]) : null;
117
117
  }
118
- }), Fe = () => ({
118
+ }), Y = () => ({
119
119
  clsName: {
120
120
  type: String,
121
121
  default: "pro-modal"
@@ -128,16 +128,10 @@ const Ke = () => ({
128
128
  type: String,
129
129
  default: "\u53D6\u6D88"
130
130
  },
131
- cancelButtonProps: {
132
- type: Object
133
- },
134
131
  okText: {
135
132
  type: String,
136
133
  default: "\u786E\u8BA4"
137
134
  },
138
- okButtonProps: {
139
- type: Object
140
- },
141
135
  confirmLoading: Boolean,
142
136
  footer: {
143
137
  type: Boolean,
@@ -146,73 +140,159 @@ const Ke = () => ({
146
140
  maskClosable: {
147
141
  type: [Object, Boolean],
148
142
  default: void 0
143
+ },
144
+ scrollProps: {
145
+ type: Object
149
146
  }
150
- }), $e = C({
151
- inheritAttrs: !1,
147
+ }), Ge = C({
152
148
  props: {
153
- ...de.props,
149
+ ...ie.props,
154
150
  appendToBody: {
155
151
  type: Boolean,
156
152
  default: !0
157
153
  },
158
- ...Fe()
154
+ destroyOnClose: {
155
+ type: Boolean,
156
+ default: !0
157
+ },
158
+ ...Y()
159
159
  },
160
160
  setup: (e, {
161
161
  slots: t,
162
162
  emit: u,
163
- attrs: n
163
+ expose: a
164
164
  }) => {
165
- const o = T(e.visible);
166
- A(() => {
167
- o.value !== e.visible && (o.value = e.visible);
168
- }, () => e.visible);
169
- const l = () => {
170
- var r;
171
- if ((r = e.cancelButtonProps) != null && r.onClick) {
172
- e.cancelButtonProps.onClick();
173
- return;
174
- }
175
- o.value = !1, u("update:visible", !1);
176
- }, a = () => {
177
- var r;
178
- if ((r = e.okButtonProps) != null && r.onClick) {
179
- e.okButtonProps.onClick();
180
- return;
181
- }
165
+ const o = F();
166
+ a(D(o));
167
+ const l = (S) => {
168
+ u("update:modelValue", S), u("update:visible", S), S || u("cancel");
169
+ }, n = () => {
170
+ l(!1);
171
+ }, f = () => {
182
172
  u("ok");
183
- }, f = w(Fe());
184
- return () => c(de, s({
185
- class: e.clsName
186
- }, y(n, "onCancel"), y(e, ...f, "modelValue"), {
173
+ }, r = Ne(), v = r(m.ProOperateKey), g = r(m.ScrollKey), b = N(() => [{
174
+ value: "cancel",
175
+ label: e.cancelText,
176
+ onClick: n
177
+ }, {
178
+ value: "ok",
179
+ label: e.okText,
180
+ loading: e.confirmLoading,
181
+ extraProps: {
182
+ type: "primary"
183
+ },
184
+ onClick: f
185
+ }]), K = I(Y());
186
+ return () => c(ie, y({
187
+ class: e.clsName,
188
+ ref: o
189
+ }, s(e, ...K), {
187
190
  closeOnClickModal: $(e.maskClosable) ? e.maskClosable : e.closeOnClickModal,
188
- modelValue: o.value,
189
- "onUpdate:modelValue": [(r) => o.value = r, (r) => {
190
- u("update:visible", r);
191
- }],
192
- onClose: () => {
193
- u("cancel");
194
- }
191
+ modelValue: e.visible || e.modelValue,
192
+ "onUpdate:modelValue": l
195
193
  }), {
196
- footer: e.footer === !1 ? void 0 : () => c("div", {
197
- class: `${e.clsName}-operate`
198
- }, [c(z, s(y(e.cancelButtonProps, "onClick"), {
199
- onClick: l
200
- }), {
201
- default: () => [e.cancelText]
202
- }), c(z, s({
203
- type: "primary",
204
- loading: e.confirmLoading
205
- }, y(e.okButtonProps, "onClick"), {
206
- onClick: a
207
- }), {
208
- default: () => [e.okText]
209
- })]),
210
- ...t
194
+ footer: e.footer === !1 ? void 0 : () => c(v, {
195
+ items: b.value
196
+ }, null),
197
+ ...t,
198
+ default: () => c(g, y({
199
+ class: `${e.clsName}-scroll`
200
+ }, e.scrollProps), {
201
+ default: () => {
202
+ var S;
203
+ return [(S = t.default) == null ? void 0 : S.call(t)];
204
+ }
205
+ })
211
206
  });
212
207
  }
213
- }), Dt = C({
208
+ }), jt = () => ({
209
+ clsName: {
210
+ type: String,
211
+ default: "pro-drawer"
212
+ },
213
+ visible: {
214
+ type: Boolean,
215
+ default: !1
216
+ },
217
+ cancelText: {
218
+ type: String,
219
+ default: "\u53D6\u6D88"
220
+ },
221
+ okText: {
222
+ type: String,
223
+ default: "\u786E\u8BA4"
224
+ },
225
+ footer: {
226
+ type: Boolean,
227
+ default: !0
228
+ },
229
+ confirmLoading: Boolean,
230
+ scrollProps: {
231
+ type: Object
232
+ }
233
+ }), $t = C({
214
234
  props: {
215
- ...ie.props,
235
+ ...fe.props,
236
+ ...jt(),
237
+ appendToBody: {
238
+ type: Boolean,
239
+ default: !0
240
+ },
241
+ destroyOnClose: {
242
+ type: Boolean,
243
+ default: !0
244
+ }
245
+ },
246
+ setup: (e, {
247
+ slots: t,
248
+ emit: u,
249
+ expose: a
250
+ }) => {
251
+ const o = F();
252
+ a(D(o));
253
+ const l = (S) => {
254
+ u("update:modelValue", S), u("update:visible", S), S || u("cancel");
255
+ }, n = () => {
256
+ l(!1);
257
+ }, f = () => {
258
+ u("ok");
259
+ }, r = Ne(), v = r(m.ProOperateKey), g = r(m.ScrollKey), b = N(() => [{
260
+ value: "cancel",
261
+ label: e.cancelText,
262
+ onClick: n
263
+ }, {
264
+ value: "ok",
265
+ label: e.okText,
266
+ loading: e.confirmLoading,
267
+ extraProps: {
268
+ type: "primary"
269
+ },
270
+ onClick: f
271
+ }]), K = I(Y());
272
+ return () => c(fe, y({
273
+ class: e.clsName,
274
+ ref: o
275
+ }, s(e, K), {
276
+ modelValue: e.visible || e.modelValue,
277
+ "onUpdate:modelValue": l
278
+ }), {
279
+ footer: e.footer === !1 ? void 0 : () => c(v, {
280
+ items: b.value
281
+ }, null),
282
+ ...t,
283
+ default: () => c(g, y({
284
+ class: `${e.clsName}-scroll`
285
+ }, e.scrollProps), {
286
+ default: () => {
287
+ var S;
288
+ return [(S = t.default) == null ? void 0 : S.call(t)];
289
+ }
290
+ })
291
+ });
292
+ }
293
+ }), qt = C({
294
+ props: {
295
+ ...ye.props,
216
296
  page: {
217
297
  type: Number,
218
298
  default: 1
@@ -222,35 +302,35 @@ const Ke = () => ({
222
302
  slots: t,
223
303
  emit: u
224
304
  }) => {
225
- const n = T(e.page), o = T(e.pageSize);
305
+ const a = F(e.page), o = F(e.pageSize);
226
306
  A(() => {
227
- n.value !== e.page && (n.value = e.page);
307
+ a.value !== e.page && (a.value = e.page);
228
308
  }, () => e.page), A(() => {
229
309
  o.value !== e.pageSize && (o.value = e.pageSize);
230
310
  }, () => e.pageSize);
231
- const l = Kt(() => {
232
- u("composeChange", n.value, o.value);
233
- }, 300), a = () => {
234
- l(), u("update:page", n.value);
311
+ const l = Rt(() => {
312
+ u("composeChange", a.value, o.value);
313
+ }, 300), n = () => {
314
+ l(), u("update:page", a.value);
235
315
  }, f = () => {
236
316
  l(), u("update:pageSize", o.value);
237
317
  };
238
- return () => c(ie, s({
239
- currentPage: n.value,
240
- "onUpdate:currentPage": (r) => n.value = r,
318
+ return () => c(ye, y({
319
+ currentPage: a.value,
320
+ "onUpdate:currentPage": (r) => a.value = r,
241
321
  pageSize: o.value,
242
322
  "onUpdate:pageSize": (r) => o.value = r,
243
- onCurrentChange: a,
323
+ onCurrentChange: n,
244
324
  onSizeChange: f
245
- }, y(e, "currentPage", "pageSize")), t);
325
+ }, s(e, "currentPage", "pageSize")), t);
246
326
  }
247
- }), Lt = C({
327
+ }), Gt = C({
248
328
  props: {
249
- ...fe.props
329
+ ...me.props
250
330
  },
251
331
  setup: (e, {
252
332
  slots: t
253
- }) => () => c(fe, e, {
333
+ }) => () => c(me, e, {
254
334
  reference: t.default,
255
335
  default: t.content
256
336
  })
@@ -264,49 +344,49 @@ const Ke = () => ({
264
344
  type: String,
265
345
  default: "default"
266
346
  }
267
- }), At = C({
347
+ }), _t = C({
268
348
  props: {
269
- ...me.props,
349
+ ...se.props,
270
350
  ...Ee()
271
351
  },
272
352
  setup: (e, {
273
353
  slots: t,
274
354
  emit: u,
275
- expose: n
355
+ expose: a
276
356
  }) => {
277
- const o = T();
278
- n(U(o));
279
- const l = w(Ee());
280
- return () => c(me, s({
357
+ const o = F();
358
+ a(D(o));
359
+ const l = I(Ee());
360
+ return () => c(se, y({
281
361
  ref: o
282
- }, y(e, l), {
283
- "onUpdate:modelValue": (a) => {
284
- u("update:modelValue", a || void 0);
362
+ }, s(e, l), {
363
+ "onUpdate:modelValue": (n) => {
364
+ u("update:modelValue", n || void 0);
285
365
  }
286
366
  }), {
287
367
  default: () => {
288
- var a, f;
289
- return [(a = t.start) == null ? void 0 : a.call(t), R(e.options, (r) => {
290
- var P;
291
- const h = (P = t.label) == null ? void 0 : P.call(t, r);
292
- return e.optionType === "button" || e.buttonStyle === "button" ? c(at, s({
368
+ var n, f;
369
+ return [(n = t.start) == null ? void 0 : n.call(t), M(e.options, (r) => {
370
+ var g;
371
+ const v = (g = t.label) == null ? void 0 : g.call(t, r);
372
+ return e.optionType === "button" || e.buttonStyle === "button" ? c(rt, y({
293
373
  key: r.value
294
- }, y(r, "value"), {
374
+ }, s(r, "value"), {
295
375
  label: r.value
296
376
  }), {
297
- default: () => [h || r.label]
298
- }) : c(De, s({
377
+ default: () => [v || r.label]
378
+ }) : c(De, y({
299
379
  key: r.value
300
380
  }, r, {
301
381
  label: r.value
302
382
  }), {
303
- default: () => [h || r.label]
383
+ default: () => [v || r.label]
304
384
  });
305
385
  }), (f = t.default) == null ? void 0 : f.call(t)];
306
386
  }
307
387
  });
308
388
  }
309
- }), xe = () => ({
389
+ }), Fe = () => ({
310
390
  options: {
311
391
  type: Array
312
392
  },
@@ -318,43 +398,43 @@ const Ke = () => ({
318
398
  type: String,
319
399
  default: "default"
320
400
  }
321
- }), Ot = C({
401
+ }), Wt = C({
322
402
  props: {
323
- ...ye.props,
324
- ...xe()
403
+ ...ge.props,
404
+ ...Fe()
325
405
  },
326
406
  setup: (e, {
327
407
  slots: t,
328
408
  emit: u,
329
- expose: n
409
+ expose: a
330
410
  }) => {
331
- const o = T();
332
- n(U(o));
333
- const l = w(xe());
334
- return () => c(ye, s({
411
+ const o = F();
412
+ a(D(o));
413
+ const l = I(Fe());
414
+ return () => c(ge, y({
335
415
  ref: o
336
- }, y(e, l), {
337
- "onUpdate:modelValue": (a) => {
338
- u("update:modelValue", a);
416
+ }, s(e, l), {
417
+ "onUpdate:modelValue": (n) => {
418
+ u("update:modelValue", n);
339
419
  }
340
420
  }), {
341
421
  default: () => {
342
- var a, f;
343
- return [(a = t.start) == null ? void 0 : a.call(t), R(e.options, (r) => {
344
- var P;
345
- const h = (P = t.label) == null ? void 0 : P.call(t, r);
346
- return e.optionType === "button" || e.buttonStyle === "button" ? c(lt, s({
422
+ var n, f;
423
+ return [(n = t.start) == null ? void 0 : n.call(t), M(e.options, (r) => {
424
+ var g;
425
+ const v = (g = t.label) == null ? void 0 : g.call(t, r);
426
+ return e.optionType === "button" || e.buttonStyle === "button" ? c(ot, y({
347
427
  key: r.value
348
- }, y(r, "value"), {
428
+ }, s(r, "value"), {
349
429
  label: r.value
350
430
  }), {
351
- default: () => [h || r.label]
352
- }) : c(rt, s({
431
+ default: () => [v || r.label]
432
+ }) : c(ut, y({
353
433
  key: r.value
354
- }, y(r, "value"), {
434
+ }, s(r, "value"), {
355
435
  label: r.value
356
436
  }), {
357
- default: () => [h || r.label]
437
+ default: () => [v || r.label]
358
438
  });
359
439
  }), (f = t.default) == null ? void 0 : f.call(t)];
360
440
  }
@@ -362,44 +442,44 @@ const Ke = () => ({
362
442
  }
363
443
  }), Te = () => ({
364
444
  options: Array
365
- }), zt = C({
445
+ }), Zt = C({
366
446
  props: {
367
- ...se.props,
447
+ ...be.props,
368
448
  ...Te()
369
449
  },
370
450
  setup: (e, {
371
451
  slots: t,
372
452
  emit: u,
373
- expose: n
453
+ expose: a
374
454
  }) => {
375
- const o = T();
376
- n(U(o));
377
- const l = w(Te());
378
- return () => c(se, s({
455
+ const o = F();
456
+ a(D(o));
457
+ const l = I(Te());
458
+ return () => c(be, y({
379
459
  ref: o
380
- }, y(e, l), {
381
- "onUpdate:modelValue": (a) => {
382
- u("update:modelValue", a || void 0);
460
+ }, s(e, l), {
461
+ "onUpdate:modelValue": (n) => {
462
+ u("update:modelValue", n || void 0);
383
463
  }
384
464
  }), {
385
465
  default: () => {
386
- var a, f;
387
- return [(a = t.start) == null ? void 0 : a.call(t), R(e.options, (r) => {
388
- var P;
389
- const h = (P = t.label) == null ? void 0 : P.call(t, r);
390
- return c(ot, s({
466
+ var n, f;
467
+ return [(n = t.start) == null ? void 0 : n.call(t), M(e.options, (r) => {
468
+ var g;
469
+ const v = (g = t.label) == null ? void 0 : g.call(t, r);
470
+ return c(ct, y({
391
471
  key: r.value
392
472
  }, r), {
393
- default: () => [h || r.label]
473
+ default: () => [v || r.label]
394
474
  });
395
475
  }), (f = t.default) == null ? void 0 : f.call(t)];
396
476
  },
397
- ...y(t, "default")
477
+ ...s(t, "default")
398
478
  });
399
479
  }
400
- }), mn = C({
480
+ }), Sa = C({
401
481
  props: {
402
- ...ge.props,
482
+ ...ve.props,
403
483
  options: {
404
484
  type: Array
405
485
  }
@@ -407,27 +487,27 @@ const Ke = () => ({
407
487
  setup: (e, {
408
488
  slots: t,
409
489
  emit: u
410
- }) => () => c(ge, s(y(e, "options"), {
411
- "onUpdate:modelValue": (n) => {
412
- u("update:modelValue", n);
490
+ }) => () => c(ve, y(s(e, "options"), {
491
+ "onUpdate:modelValue": (a) => {
492
+ u("update:modelValue", a);
413
493
  }
414
494
  }), {
415
495
  default: () => {
416
- var n, o;
417
- return [(n = t.start) == null ? void 0 : n.call(t), R(e.options, (l) => c(ut, s({
496
+ var a, o;
497
+ return [(a = t.start) == null ? void 0 : a.call(t), M(e.options, (l) => c(dt, y({
418
498
  key: l.value
419
- }, y(l, "value"), {
499
+ }, s(l, "value"), {
420
500
  name: l.value
421
501
  }), {
422
502
  label: () => {
423
- var a;
424
- return ((a = t.label) == null ? void 0 : a.call(t, l)) || l.label;
503
+ var n;
504
+ return ((n = t.label) == null ? void 0 : n.call(t, l)) || l.label;
425
505
  }
426
506
  })), (o = t.end) == null ? void 0 : o.call(t)];
427
507
  },
428
508
  ...t
429
509
  })
430
- }), ee = {
510
+ }), te = {
431
511
  convertSubMenuProps: {
432
512
  type: Function
433
513
  },
@@ -437,46 +517,46 @@ const Ke = () => ({
437
517
  onMenuItemClick: {
438
518
  type: Function
439
519
  }
440
- }, Ge = w(ee), _e = C({
520
+ }, _e = I(te), We = C({
441
521
  inheritAttrs: !1,
442
522
  props: {
443
523
  menu: {
444
524
  type: Object
445
525
  },
446
- ...ee
526
+ ...te
447
527
  },
448
528
  setup: (e, {
449
529
  slots: t
450
530
  }) => {
451
531
  const u = () => {
452
- var n;
453
- (n = e.onMenuItemClick) == null || n.call(e, e.menu);
532
+ var a;
533
+ (a = e.onMenuItemClick) == null || a.call(e, e.menu);
454
534
  };
455
535
  return () => {
456
536
  var o, l;
457
- const n = e.menu;
458
- return (n == null ? void 0 : n.children) && D(n.children) > 0 ? c(q.SubMenu, s({
459
- index: n == null ? void 0 : n.value
460
- }, (o = e.convertSubMenuProps) == null ? void 0 : o.call(e, n)), {
461
- default: () => [R(n.children, (a) => c(_e, s({
462
- menu: a
463
- }, Y(e, Ge)), t))],
537
+ const a = e.menu;
538
+ return (a == null ? void 0 : a.children) && B(a.children) > 0 ? c(j.SubMenu, y({
539
+ index: a == null ? void 0 : a.value
540
+ }, (o = e.convertSubMenuProps) == null ? void 0 : o.call(e, a)), {
541
+ default: () => [M(a.children, (n) => c(We, y({
542
+ menu: n
543
+ }, ee(e, _e)), t))],
464
544
  title: () => {
465
- var a;
466
- return ((a = t.title) == null ? void 0 : a.call(t, n)) || (n == null ? void 0 : n.label);
545
+ var n;
546
+ return ((n = t.title) == null ? void 0 : n.call(t, a)) || (a == null ? void 0 : a.label);
467
547
  }
468
- }) : c(q.MenuItem, s({
469
- index: n == null ? void 0 : n.value
470
- }, (l = e.convertMenuItemProps) == null ? void 0 : l.call(e, n), {
548
+ }) : c(j.MenuItem, y({
549
+ index: a == null ? void 0 : a.value
550
+ }, (l = e.convertMenuItemProps) == null ? void 0 : l.call(e, a), {
471
551
  onClick: u
472
552
  }), {
473
553
  title: () => {
474
- var a;
475
- return ((a = t.title) == null ? void 0 : a.call(t, n)) || (n == null ? void 0 : n.label);
554
+ var n;
555
+ return ((n = t.title) == null ? void 0 : n.call(t, a)) || (a == null ? void 0 : a.label);
476
556
  },
477
557
  default: t.default ? () => {
478
- var a;
479
- return (a = t.default) == null ? void 0 : a.call(t, n);
558
+ var n;
559
+ return (n = t.default) == null ? void 0 : n.call(t, a);
480
560
  } : void 0
481
561
  });
482
562
  };
@@ -496,40 +576,40 @@ const Ke = () => ({
496
576
  label: "label"
497
577
  }
498
578
  },
499
- ...ee
500
- }), Ut = C({
579
+ ...te
580
+ }), Ht = C({
501
581
  props: {
502
- ...y(q.props, "defaultActive"),
582
+ ...s(j.props, "defaultActive"),
503
583
  ...Re()
504
584
  },
505
585
  setup: (e, {
506
586
  slots: t
507
587
  }) => {
508
- const u = T(e.activeKey);
588
+ const u = F(e.activeKey);
509
589
  A(() => {
510
590
  e.activeKey !== u.value && (u.value = e.activeKey);
511
591
  }, () => e.activeKey);
512
- const n = N(() => {
592
+ const a = N(() => {
513
593
  var l;
514
- return wt(e.options, (a) => {
515
- var h, P;
516
- const f = ((h = e.fieldNames) == null ? void 0 : h.value) || "value", r = ((P = e.fieldNames) == null ? void 0 : P.label) || "label";
594
+ return Nt(e.options, (n) => {
595
+ var v, g;
596
+ const f = ((v = e.fieldNames) == null ? void 0 : v.value) || "value", r = ((g = e.fieldNames) == null ? void 0 : g.label) || "label";
517
597
  return {
518
- ...y(a, f, r),
519
- value: B(a, f),
520
- label: B(a, r)
598
+ ...s(n, f, r),
599
+ value: O(n, f),
600
+ label: O(n, r)
521
601
  };
522
602
  }, {
523
603
  children: ((l = e.fieldNames) == null ? void 0 : l.children) || "children",
524
604
  childrenName: "children"
525
605
  });
526
- }), o = w(Re());
527
- return () => c(q, s({
606
+ }), o = I(Re());
607
+ return () => c(j, y({
528
608
  defaultActive: u.value
529
- }, y(e, o)), {
530
- default: () => c(Oe, null, [R(n.value, (l) => c(_e, s({
609
+ }, s(e, o)), {
610
+ default: () => c(Ae, null, [M(a.value, (l) => c(We, y({
531
611
  menu: l
532
- }, Y(e, Ge)), t))])
612
+ }, ee(e, _e)), t))])
533
613
  });
534
614
  }
535
615
  }), we = () => ({
@@ -563,104 +643,104 @@ const Ke = () => ({
563
643
  type: Function,
564
644
  default: void 0
565
645
  }
566
- }), jt = ["abort", "submit", "clearFiles", "handleStart", "handleRemove"], We = C({
646
+ }), Jt = ["abort", "submit", "clearFiles", "handleStart", "handleRemove"], Ze = C({
567
647
  props: {
568
- ...y(ve.props, "fileList"),
648
+ ...s(pe.props, "fileList"),
569
649
  ...we()
570
650
  },
571
651
  setup: (e, {
572
652
  slots: t,
573
653
  expose: u,
574
- emit: n
654
+ emit: a
575
655
  }) => {
576
656
  const {
577
657
  showMsg: o
578
- } = Qe(), l = T();
579
- u(U(l, jt));
658
+ } = Xe(), l = F();
659
+ u(D(l, Jt));
580
660
  const {
581
- formItem: a
582
- } = ct(), f = () => Ft(e.modelValue) ? R(e.modelValue, (i) => {
583
- var g;
584
- return ((g = e.convertItemData) == null ? void 0 : g.call(e, i)) || i;
585
- }) : [], r = T(f());
586
- let h = !1;
587
- const P = () => {
588
- var g;
589
- h = !0;
590
- const i = pe(r.value, (p) => p.status === "success");
591
- n("update:modelValue", R(i, (p) => {
661
+ formItem: n
662
+ } = it(), f = () => wt(e.modelValue) ? M(e.modelValue, (i) => {
663
+ var d;
664
+ return ((d = e.convertItemData) == null ? void 0 : d.call(e, i)) || i;
665
+ }) : [], r = F(f());
666
+ let v = !1;
667
+ const g = () => {
668
+ var d;
669
+ v = !0;
670
+ const i = Ce(r.value, (p) => p.status === "success");
671
+ a("update:modelValue", M(i, (p) => {
592
672
  var x;
593
673
  return ((x = e.convertResponseData) == null ? void 0 : x.call(e, p)) || p;
594
- })), (g = a == null ? void 0 : a.validate) == null || g.call(a, "change");
674
+ })), (d = n == null ? void 0 : n.validate) == null || d.call(n, "change");
595
675
  };
596
676
  A(() => {
597
- h || (r.value = f(), h = !1);
677
+ v || (r.value = f(), v = !1);
598
678
  }, () => e.modelValue);
599
- let v;
600
- const F = () => {
601
- e.globalLoading && (v = Ne.service({
679
+ let b;
680
+ const K = () => {
681
+ e.globalLoading && (b = Oe.service({
602
682
  lock: !0,
603
683
  text: "\u6B63\u5728\u4E0A\u4F20\u6587\u4EF6\uFF0C\u8BF7\u7A0D\u540E...",
604
684
  ...$(e.globalLoading) ? {} : e.globalLoading
605
685
  }));
606
- }, d = () => {
607
- e.globalLoading && (v == null || v.close());
686
+ }, S = () => {
687
+ e.globalLoading && (b == null || b.close());
608
688
  };
609
- G(() => () => {
610
- d();
689
+ q(() => () => {
690
+ S();
611
691
  }, []);
612
- const m = (i, g) => {
692
+ const T = (i, d) => {
613
693
  if (e.onErrorMsg) {
614
- e.onErrorMsg(i, g);
694
+ e.onErrorMsg(i, d);
615
695
  return;
616
696
  }
617
697
  o({
618
698
  type: "error",
619
- message: g
699
+ message: d
620
700
  });
621
- }, k = (i) => {
622
- var g;
701
+ }, P = (i) => {
702
+ var d;
623
703
  if (e.beforeUpload)
624
704
  return e.beforeUpload(i);
625
- if (e.accept && !Mt(e.accept, i.name))
626
- return m("FileTypeError", `\u8BF7\u4E0A\u4F20\u6B63\u786E\u683C\u5F0F\uFF08${e.accept.replace(/,/g, "\uFF0C")}\uFF09\u7684\u6587\u4EF6`), !1;
705
+ if (e.accept && !Ot(e.accept, i.name))
706
+ return T("FileTypeError", `\u8BF7\u4E0A\u4F20\u6B63\u786E\u683C\u5F0F\uFF08${e.accept.replace(/,/g, "\uFF0C")}\uFF09\u7684\u6587\u4EF6`), !1;
627
707
  if (L(i.size)) {
628
708
  if (i.size <= 0)
629
- return m("FileSizeError-Zero", "\u4E0A\u4F20\u6587\u4EF6\u5185\u5BB9\u4E0D\u80FD\u4E3A\u7A7A"), !1;
709
+ return T("FileSizeError-Zero", "\u4E0A\u4F20\u6587\u4EF6\u5185\u5BB9\u4E0D\u80FD\u4E3A\u7A7A"), !1;
630
710
  if (L(e.maxSize) && i.size > e.maxSize)
631
- return m("FileSizeError-MaxSize", `\u8BF7\u4E0A\u4F20\u5C0F\u4E8E${It(e.maxSize)}\u7684\u6587\u4EF6`), !1;
711
+ return T("FileSizeError-MaxSize", `\u8BF7\u4E0A\u4F20\u5C0F\u4E8E${Dt(e.maxSize)}\u7684\u6587\u4EF6`), !1;
632
712
  }
633
- return (g = e.onStart) == null || g.call(e, i), F(), !0;
634
- }, S = (i, g, p) => {
713
+ return (d = e.onStart) == null || d.call(e, i), K(), !0;
714
+ }, h = (i, d, p) => {
635
715
  var x;
636
- (x = e.onSuccess) == null || x.call(e, i, g, p), P(), d();
637
- }, E = (i, g, p) => {
716
+ (x = e.onSuccess) == null || x.call(e, i, d, p), g(), S();
717
+ }, E = (i, d, p) => {
638
718
  var x;
639
- (x = e.onError) == null || x.call(e, i, g, p), d(), m("UploadError", "\u4E0A\u4F20\u5931\u8D25");
640
- }, K = (i, g) => {
719
+ (x = e.onError) == null || x.call(e, i, d, p), S(), T("UploadError", "\u4E0A\u4F20\u5931\u8D25");
720
+ }, R = (i, d) => {
641
721
  var p;
642
- r.value = pe(r.value, (x) => !(i.uid === x.uid && i.name === x.name)), (p = e.onRemove) == null || p.call(e, i, g), P();
643
- }, I = N(() => L(e.limit) ? e.limit > D(r.value) : !0), V = w(we());
722
+ r.value = Ce(r.value, (x) => !(i.uid === x.uid && i.name === x.name)), (p = e.onRemove) == null || p.call(e, i, d), g();
723
+ }, w = N(() => L(e.limit) ? e.limit > B(r.value) : !0), k = I(we());
644
724
  return () => {
645
- var i, g;
725
+ var i, d;
646
726
  return c("div", {
647
- class: `pro-uploader ${I.value ? "" : "pro-uploader-limit"}`
648
- }, [(i = t.start) == null ? void 0 : i.call(t), c(ve, s({
727
+ class: `pro-uploader ${w.value ? "" : "pro-uploader-limit"}`
728
+ }, [(i = t.start) == null ? void 0 : i.call(t), c(pe, y({
649
729
  ref: l,
650
730
  fileList: r.value,
651
731
  "onUpdate:fileList": (p) => r.value = p
652
- }, y(e, "fileList", "onSuccess", "onError", "onRemove", "beforeUpload", ...V), {
653
- beforeUpload: k,
654
- onSuccess: S,
732
+ }, s(e, "fileList", "onSuccess", "onError", "onRemove", "beforeUpload", ...k), {
733
+ beforeUpload: P,
734
+ onSuccess: h,
655
735
  onError: E,
656
- onRemove: K
736
+ onRemove: R
657
737
  }), {
658
738
  default: () => {
659
739
  var p, x;
660
- return [I.value && c(Oe, null, [((p = t.default) == null ? void 0 : p.call(t)) || ((x = e.renderDom) == null ? void 0 : x.call(e))])];
740
+ return [w.value && c(Ae, null, [((p = t.default) == null ? void 0 : p.call(t)) || ((x = e.renderDom) == null ? void 0 : x.call(e))])];
661
741
  },
662
- ...y(t, "default")
663
- }), (g = t.end) == null ? void 0 : g.call(t)]);
742
+ ...s(t, "default")
743
+ }), (d = t.end) == null ? void 0 : d.call(t)]);
664
744
  };
665
745
  }
666
746
  }), Me = () => ({
@@ -680,9 +760,9 @@ const Ke = () => ({
680
760
  divider: {
681
761
  type: Function
682
762
  }
683
- }), qt = C({
763
+ }), Qt = C({
684
764
  props: {
685
- ...y(j.props, "modelValue"),
765
+ ...s(z.props, "modelValue"),
686
766
  controlsPosition: {
687
767
  type: String,
688
768
  default: "right"
@@ -693,37 +773,37 @@ const Ke = () => ({
693
773
  slots: t,
694
774
  emit: u
695
775
  }) => {
696
- const n = T(B(e.modelValue, 0)), o = T(B(e.modelValue, 1));
776
+ const a = F(O(e.modelValue, 0)), o = F(O(e.modelValue, 1));
697
777
  let l = !1;
698
778
  A(() => {
699
- l || (n.value = B(e.modelValue, 0), o.value = B(e.modelValue, 1)), l = !1;
779
+ l || (a.value = O(e.modelValue, 0), o.value = O(e.modelValue, 1)), l = !1;
700
780
  }, [e.modelValue, () => e.modelValue]);
701
- const a = () => {
702
- l = !0, e.singleEmit ? u("update:modelValue", [n.value, o.value]) : L(n.value) && L(o.value) ? u("update:modelValue", [n.value, o.value]) : u("update:modelValue", null);
703
- }, f = (v) => {
704
- for (let F = 0; F < v.length; F++)
705
- if (L(v[F]))
706
- return v[F];
781
+ const n = () => {
782
+ l = !0, e.singleEmit ? u("update:modelValue", [a.value, o.value]) : L(a.value) && L(o.value) ? u("update:modelValue", [a.value, o.value]) : u("update:modelValue", null);
783
+ }, f = (b) => {
784
+ for (let K = 0; K < b.length; K++)
785
+ if (L(b[K]))
786
+ return b[K];
707
787
  }, r = N(() => {
708
- var v;
709
- return f([o.value, (v = e.start) == null ? void 0 : v.max, e.max]);
710
- }), h = N(() => {
711
- var v;
712
- return f([n.value, (v = e.end) == null ? void 0 : v.min, e.min]);
713
- }), P = w(Me());
788
+ var b;
789
+ return f([o.value, (b = e.start) == null ? void 0 : b.max, e.max]);
790
+ }), v = N(() => {
791
+ var b;
792
+ return f([a.value, (b = e.end) == null ? void 0 : b.min, e.min]);
793
+ }), g = I(Me());
714
794
  return () => {
715
- var F, d;
716
- const v = y(e, ...P, "min", "max");
795
+ var K, S;
796
+ const b = s(e, ...g, "min", "max");
717
797
  return c("span", {
718
798
  class: "pro-number-range"
719
- }, [c(j, s(v, y(e.start, "max"), {
799
+ }, [c(z, y(b, s(e.start, "max"), {
720
800
  max: r.value,
721
- modelValue: n.value,
722
- "onUpdate:modelValue": [(m) => n.value = m, a]
723
- }), null), c("span", null, [((F = t.divider) == null ? void 0 : F.call(t)) || ((d = e.divider) == null ? void 0 : d.call(e)) || " - "]), c(j, s(v, y(e.start, "min"), {
724
- min: h.value,
801
+ modelValue: a.value,
802
+ "onUpdate:modelValue": [(T) => a.value = T, n]
803
+ }), null), c("span", null, [((K = t.divider) == null ? void 0 : K.call(t)) || ((S = e.divider) == null ? void 0 : S.call(e)) || " - "]), c(z, y(b, s(e.start, "min"), {
804
+ min: v.value,
725
805
  modelValue: o.value,
726
- "onUpdate:modelValue": [(m) => o.value = m, a]
806
+ "onUpdate:modelValue": [(T) => o.value = T, n]
727
807
  }), null)]);
728
808
  };
729
809
  }
@@ -744,15 +824,15 @@ const Ke = () => ({
744
824
  checkedKeys: {
745
825
  type: Array
746
826
  }
747
- }), yn = C({
827
+ }), Pa = C({
748
828
  props: {
749
- ...be.props,
829
+ ...Se.props,
750
830
  ...Ie()
751
831
  },
752
832
  setup: (e, {
753
833
  slots: t
754
834
  }) => {
755
- const u = w(Ie()), o = (() => {
835
+ const u = I(Ie()), o = (() => {
756
836
  const l = e.fieldNames;
757
837
  if (!!l)
758
838
  return {
@@ -765,7 +845,7 @@ const Ke = () => ({
765
845
  })();
766
846
  return () => {
767
847
  var l;
768
- return c(be, s(y(e, u), {
848
+ return c(Se, y(s(e, u), {
769
849
  data: e.treeData || e.data,
770
850
  props: o || e.props,
771
851
  nodeKey: ((l = e.fieldNames) == null ? void 0 : l.key) || e.nodeKey,
@@ -776,35 +856,35 @@ const Ke = () => ({
776
856
  };
777
857
  }
778
858
  });
779
- function $t(e) {
780
- return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !Ct(e);
859
+ function Xt(e) {
860
+ return typeof e == "function" || Object.prototype.toString.call(e) === "[object Object]" && !Et(e);
781
861
  }
782
862
  const Ve = () => ({
783
863
  options: Array
784
- }), Gt = C({
864
+ }), Yt = C({
785
865
  props: {
786
- ...he.props,
866
+ ...Pe.props,
787
867
  ...Ve()
788
868
  },
789
869
  setup: (e, {
790
870
  slots: t,
791
871
  expose: u
792
872
  }) => {
793
- const n = T();
794
- u(U(n));
795
- const o = w(Ve());
796
- return () => c(he, s({
797
- ref: n
798
- }, y(e, o)), {
873
+ const a = F();
874
+ u(D(a));
875
+ const o = I(Ve());
876
+ return () => c(Pe, y({
877
+ ref: a
878
+ }, s(e, o)), {
799
879
  dropdown: () => {
800
880
  let l;
801
- return c(dt, null, $t(l = R(e.options, (a) => {
881
+ return c(ft, null, Xt(l = M(e.options, (n) => {
802
882
  var r;
803
- const f = (r = t.label) == null ? void 0 : r.call(t, a);
804
- return c(it, s({
805
- command: a.value
806
- }, y(a, "value", "label")), {
807
- default: () => [f || a.label]
883
+ const f = (r = t.label) == null ? void 0 : r.call(t, n);
884
+ return c(yt, y({
885
+ command: n.value
886
+ }, s(n, "value", "label")), {
887
+ default: () => [f || n.label]
808
888
  });
809
889
  })) ? l : {
810
890
  default: () => [l]
@@ -813,53 +893,53 @@ const Ve = () => ({
813
893
  ...t
814
894
  });
815
895
  }
816
- }), _t = M({
817
- InputComp: ft,
896
+ }), ea = V({
897
+ InputComp: mt,
818
898
  valueType: "text",
819
899
  name: "PFromText"
820
- }), Wt = M({
821
- InputComp: j,
900
+ }), ta = V({
901
+ InputComp: z,
822
902
  valueType: "digit",
823
903
  name: "PFormNumber"
824
- }), Zt = M({
825
- InputComp: qt,
904
+ }), aa = V({
905
+ InputComp: Qt,
826
906
  valueType: "digitRange",
827
907
  name: "PFormNumberRange"
828
- }), Ht = M({
829
- InputComp: mt,
908
+ }), na = V({
909
+ InputComp: st,
830
910
  valueType: "date",
831
911
  name: "PFormDate"
832
- }), Jt = M({
833
- InputComp: yt,
912
+ }), la = V({
913
+ InputComp: gt,
834
914
  valueType: "time",
835
915
  name: "PFormTime"
836
- }), Qt = M({
837
- InputComp: zt,
916
+ }), ra = V({
917
+ InputComp: Zt,
838
918
  valueType: "select",
839
919
  name: "PFormSelect"
840
- }), Xt = M({
841
- InputComp: st,
920
+ }), oa = V({
921
+ InputComp: bt,
842
922
  valueType: "treeSelect",
843
923
  name: "PFormTreeSelect"
844
- }), Yt = M({
845
- InputComp: At,
924
+ }), ua = V({
925
+ InputComp: _t,
846
926
  valueType: "checkbox",
847
927
  name: "PFromCheckbox"
848
- }), en = M({
849
- InputComp: Ot,
928
+ }), ca = V({
929
+ InputComp: Wt,
850
930
  valueType: "radio",
851
931
  name: "PFromRadio"
852
- }), tn = M({
853
- InputComp: gt,
932
+ }), da = V({
933
+ InputComp: vt,
854
934
  valueType: "switch",
855
935
  name: "PFromSwitch"
856
- }), nn = M({
857
- InputComp: vt,
936
+ }), ia = V({
937
+ InputComp: pt,
858
938
  valueType: "cascader",
859
939
  name: "PFormCascader"
860
- }), Ze = C({
940
+ }), He = C({
861
941
  props: {
862
- ...y(X.props, "label", "prop"),
942
+ ...s(Q.props, "label", "prop"),
863
943
  title: {
864
944
  type: String
865
945
  },
@@ -878,51 +958,51 @@ const Ve = () => ({
878
958
  }) => {
879
959
  const u = ({
880
960
  row: l,
881
- column: a,
961
+ column: n,
882
962
  $index: f
883
963
  }) => {
884
- var m;
885
- const r = l, h = f, P = {
886
- ...a,
887
- title: a.label,
888
- dataIndex: a.property
889
- }, v = B(l, P.dataIndex), F = {
890
- value: v,
891
- text: v,
964
+ var T;
965
+ const r = l, v = f, g = {
966
+ ...n,
967
+ title: n.label,
968
+ dataIndex: n.property
969
+ }, b = O(l, g.dataIndex), K = {
970
+ value: b,
971
+ text: b,
892
972
  record: r,
893
- column: P,
894
- index: h
895
- }, d = (m = t.bodyCell) == null ? void 0 : m.call(t, F);
896
- return d || (e.customRender ? e.customRender(F) : v);
973
+ column: g,
974
+ index: v
975
+ }, S = (T = t.bodyCell) == null ? void 0 : T.call(t, K);
976
+ return S || (e.customRender ? e.customRender(K) : b);
897
977
  }, o = {
898
978
  header: ({
899
979
  column: l,
900
- $index: a
980
+ $index: n
901
981
  }) => {
902
- var v;
903
- const f = a, r = l.label, h = {
982
+ var b;
983
+ const f = n, r = l.label, v = {
904
984
  ...l,
905
985
  title: r,
906
986
  dataIndex: l.property
907
987
  };
908
- return ((v = t.headerCell) == null ? void 0 : v.call(t, {
988
+ return ((b = t.headerCell) == null ? void 0 : b.call(t, {
909
989
  title: r,
910
- column: h,
990
+ column: v,
911
991
  index: f
912
992
  })) || r;
913
993
  }
914
994
  };
915
- return (!e.children || D(e.children) <= 0) && (o.default = u), () => c(X, s(y(e, "title", "dataIndex", "prop", "customRender", "children"), {
995
+ return (!e.children || B(e.children) <= 0) && (o.default = u), () => c(Q, y(s(e, "title", "dataIndex", "prop", "customRender", "children"), {
916
996
  prop: e.dataIndex,
917
997
  label: e.title
918
998
  }), {
919
- default: () => [D(e.children) > 0 && R(e.children, (l) => c(Ze, s({
999
+ default: () => [B(e.children) > 0 && M(e.children, (l) => c(He, y({
920
1000
  key: l.dataIndex
921
1001
  }, l), t))],
922
1002
  ...o
923
1003
  });
924
1004
  }
925
- }), an = ["clearSelection", "getSelectionRows", "toggleRowSelection", "toggleAllSelection", "toggleRowExpansion", "setCurrentRow", "clearSort", "clearFilter", "doLayout", "sort", "scrollTo", "setScrollTop", "setScrollLeft"], ln = () => ({
1005
+ }), fa = ["clearSelection", "getSelectionRows", "toggleRowSelection", "toggleAllSelection", "toggleRowExpansion", "setCurrentRow", "clearSort", "clearFilter", "doLayout", "sort", "scrollTo", "setScrollTop", "setScrollLeft"], ya = () => ({
926
1006
  columns: {
927
1007
  type: Array
928
1008
  },
@@ -942,129 +1022,134 @@ const Ve = () => ({
942
1022
  type: Object,
943
1023
  default: void 0
944
1024
  }
945
- }), He = C({
1025
+ }), Je = C({
946
1026
  props: {
947
- ...Pe.props,
948
- ...ln()
1027
+ ...he.props,
1028
+ ...ya()
949
1029
  },
950
1030
  setup: (e, {
951
1031
  slots: t,
952
1032
  expose: u,
953
- emit: n
1033
+ emit: a
954
1034
  }) => {
955
- const o = T(), l = je("table");
956
- u(Be(an, o));
957
- const a = (d) => {
958
- const m = e.rowKey;
959
- return Tt(m) ? m(d) : m ? d[m] : d.id;
960
- }, f = N(() => {
961
- const d = e.rowSelection;
962
- return d ? !d.type || d.type === "multi" : !1;
963
- }), r = (d) => {
964
- var k, S;
965
- const m = d ? [a(d)] : [];
966
- ke(e.selectedRowKeys, m, {
967
- sort: !0
968
- }) || ((S = (k = e.rowSelection).onChange) == null || S.call(k, m, d ? [d] : []), n("update:selectedRowKeys", m));
969
- }, h = (d) => {
970
- var k, S;
971
- const m = R(d, (E) => a(E));
972
- ke(e.selectedRowKeys, m, {
1035
+ const o = F(), l = $e("table");
1036
+ u(Be(fa, o));
1037
+ const n = (P) => {
1038
+ const h = e.rowKey;
1039
+ return Mt(h) ? h(P) : h ? P[h] : P.id;
1040
+ }, f = N(() => !!e.rowSelection), r = N(() => {
1041
+ const P = e.rowSelection;
1042
+ return P ? !P.type || P.type === "multi" : !1;
1043
+ });
1044
+ let v = [], g = !1;
1045
+ const b = (P) => {
1046
+ var E, R, w;
1047
+ if (!g)
1048
+ return;
1049
+ const h = M(P, (k) => n(k));
1050
+ if (f.value && !r.value) {
1051
+ if (B(h) <= 0 && B(v) > 0) {
1052
+ const k = e.dataSource || e.data, i = It(k, (d) => n(d) === v[0]);
1053
+ i && ((E = o.value) == null || E.toggleRowSelection(i, !0));
1054
+ return;
1055
+ } else if (B(h) > 1) {
1056
+ const k = Vt(h);
1057
+ ke(P, (i) => {
1058
+ var d;
1059
+ (d = o.value) == null || d.toggleRowSelection(i, n(i) === k);
1060
+ });
1061
+ return;
1062
+ }
1063
+ }
1064
+ Lt(e.selectedRowKeys, h, {
973
1065
  sort: !0
974
- }) || ((S = (k = e.rowSelection).onChange) == null || S.call(k, m, d), n("update:selectedRowKeys", m));
975
- }, P = N(() => {
1066
+ }) || ((w = (R = e.rowSelection).onChange) == null || w.call(R, h, P), a("update:selectedRowKeys", h));
1067
+ }, K = N(() => {
976
1068
  if (!!e.rowSelection)
977
- return f.value ? {
978
- onSelectionChange: h
979
- } : {
980
- highlightCurrentRow: !0,
981
- onCurrentChange: r
1069
+ return {
1070
+ onSelectionChange: b
982
1071
  };
983
1072
  });
984
- G(() => {
985
- var m, k;
986
- const d = e.dataSource || e.data;
1073
+ q(() => {
1074
+ var h;
1075
+ g = !1, v = e.selectedRowKeys;
1076
+ const P = e.dataSource || e.data;
987
1077
  if (f.value) {
988
- const S = e.selectedRowKeys, E = Ce(S, (i, g) => ({
989
- ...i,
990
- [g]: !0
991
- }), {}), K = (m = o.value) == null ? void 0 : m.getSelectionRows(), I = Ce(K, (i, g) => ({
992
- ...i,
993
- [a(g)]: !0
1078
+ const E = e.selectedRowKeys, R = Ke(E, (d, p) => ({
1079
+ ...d,
1080
+ [p]: !0
1081
+ }), {}), w = (h = o.value) == null ? void 0 : h.getSelectionRows(), k = Ke(w, (d, p) => ({
1082
+ ...d,
1083
+ [n(p)]: !0
994
1084
  }), {});
995
- let V = !1;
996
- if (D(S) !== D(K))
997
- V = !0;
998
- else if (D(S) !== 0)
999
- for (let i = 0; i < S.length; i++) {
1000
- const g = S[i];
1001
- if (!I[g]) {
1002
- V = !0;
1085
+ let i = !1;
1086
+ if (B(E) !== B(w))
1087
+ i = !0;
1088
+ else if (B(E) !== 0)
1089
+ for (let d = 0; d < E.length; d++) {
1090
+ const p = E[d];
1091
+ if (!k[p]) {
1092
+ i = !0;
1003
1093
  break;
1004
1094
  }
1005
1095
  }
1006
- V && Se(() => {
1007
- Et(d, (i) => {
1008
- var p;
1009
- const g = a(i);
1010
- E[g] !== I[g] && ((p = o.value) == null || p.toggleRowSelection(i, !!E[g]));
1011
- });
1012
- });
1013
- } else {
1014
- const S = (k = e.selectedRowKeys) == null ? void 0 : k[0];
1015
- let E = null;
1016
- S && (E = xt(d, (K) => a(K) === S)), Se(() => {
1017
- var K;
1018
- (K = o.value) == null || K.setCurrentRow(E);
1019
- });
1020
- }
1096
+ i ? Ft(() => {
1097
+ ke(P, (d) => {
1098
+ var x;
1099
+ const p = n(d);
1100
+ R[p] !== k[p] && ((x = o.value) == null || x.toggleRowSelection(d, !!R[p]));
1101
+ }), g = !0;
1102
+ }) : g = !0;
1103
+ } else
1104
+ g = !0;
1021
1105
  }, [() => e.selectedRowKeys, () => e.dataSource, () => e.data]);
1022
- const v = () => {
1023
- var d, m;
1106
+ const S = () => {
1107
+ var P, h;
1024
1108
  if (e.spanMethod)
1025
1109
  return e.spanMethod;
1026
- if (((d = e.mergeOpts) == null ? void 0 : d.rowNames) || ((m = e.mergeOpts) == null ? void 0 : m.colNames)) {
1027
- const k = Vt(e.mergeOpts);
1110
+ if (((P = e.mergeOpts) == null ? void 0 : P.rowNames) || ((h = e.mergeOpts) == null ? void 0 : h.colNames)) {
1111
+ const E = Ut(e.mergeOpts);
1028
1112
  return ({
1029
- row: S,
1030
- column: E
1113
+ row: R,
1114
+ column: w
1031
1115
  }) => {
1032
- const K = E.property;
1033
- if (k[K]) {
1034
- const I = S[k[K]], V = S[K + "-colspan"];
1116
+ const k = w.property;
1117
+ if (E[k]) {
1118
+ const i = R[E[k]], d = R[k + "-colspan"];
1035
1119
  return {
1036
- rowspan: I !== void 0 ? I : 1,
1037
- colspan: V !== void 0 ? V : 1
1120
+ rowspan: i !== void 0 ? i : 1,
1121
+ colspan: d !== void 0 ? d : 1
1038
1122
  };
1039
1123
  }
1040
1124
  };
1041
1125
  }
1042
1126
  return e.spanMethod;
1043
- }, F = N(() => v());
1044
- return () => c(Pe, s({
1127
+ }, T = N(() => S());
1128
+ return () => c(he, y({
1045
1129
  ref: o,
1046
1130
  id: l
1047
- }, y(e, "columns", "dataSource", "data", "loading", "spanMethod"), {
1131
+ }, s(e, "columns", "dataSource", "data", "loading", "spanMethod"), {
1048
1132
  data: e.dataSource || e.data,
1049
- spanMethod: F.value
1050
- }, P.value), {
1133
+ spanMethod: T.value
1134
+ }, K.value), {
1051
1135
  default: () => {
1052
- var d, m, k, S, E;
1053
- return [(d = t.start) == null ? void 0 : d.call(t), f.value && c(X, s({
1054
- type: "selection"
1055
- }, y((m = e.rowSelection) == null ? void 0 : m.column, "slots")), (S = (k = e.rowSelection) == null ? void 0 : k.column) == null ? void 0 : S.slots), R(e.columns, (K) => c(Ze, s({
1056
- key: K.dataIndex
1057
- }, K), t)), (E = t.default) == null ? void 0 : E.call(t), e.loading && c(qe, {
1136
+ var P, h, E, R, w;
1137
+ return [(P = t.start) == null ? void 0 : P.call(t), f.value && c(Q, y({
1138
+ type: "selection",
1139
+ className: r.value ? "pro-multi" : "pro-single"
1140
+ }, s((h = e.rowSelection) == null ? void 0 : h.column, "slots")), (R = (E = e.rowSelection) == null ? void 0 : E.column) == null ? void 0 : R.slots), M(e.columns, (k) => c(He, y({
1141
+ key: k.dataIndex
1142
+ }, k), t)), (w = t.default) == null ? void 0 : w.call(t), e.loading && c(qe, {
1058
1143
  target: l,
1059
1144
  loading: !0
1060
1145
  }, null)];
1061
1146
  },
1062
- ...Y(t, "append", "empty")
1147
+ ...ee(t, "append", "empty")
1063
1148
  });
1064
1149
  }
1065
- }), rn = C({
1150
+ }), ma = C({
1066
1151
  props: {
1067
- ...z.props,
1152
+ ...X.props,
1068
1153
  type: {
1069
1154
  type: String,
1070
1155
  default: "primary"
@@ -1076,134 +1161,139 @@ const Ve = () => ({
1076
1161
  },
1077
1162
  setup: (e, {
1078
1163
  slots: t
1079
- }) => () => c(z, e, t)
1164
+ }) => () => c(X, e, t)
1080
1165
  });
1081
- O.props = {
1082
- ...Q.props,
1083
- ...O.props,
1084
- formMethods: { type: Array, default: Ue }
1166
+ U.props = {
1167
+ ...J.props,
1168
+ ...U.props,
1169
+ formMethods: { type: Array, default: je }
1085
1170
  };
1086
- W.props = {
1087
- ...O.props,
1088
- ...W.props,
1171
+ _.props = {
1172
+ ...U.props,
1173
+ ..._.props,
1089
1174
  inline: { type: Boolean, default: !0 }
1090
1175
  };
1091
- te.props = {
1092
- ...J.props,
1093
- ...te.props
1176
+ ae.props = {
1177
+ ...H.props,
1178
+ ...ae.props
1094
1179
  };
1095
- Z.props = {
1096
- ...He.props,
1097
- ...Z.props
1180
+ W.props = {
1181
+ ...Je.props,
1182
+ ...W.props
1098
1183
  };
1099
- H.props = {
1184
+ Z.props = {
1100
1185
  ...Le.props,
1101
- ...H.props
1186
+ ...Z.props
1102
1187
  };
1103
1188
  ne.props = {
1104
- ...H.props,
1189
+ ...Z.props,
1105
1190
  ...ne.props
1106
1191
  };
1107
- ae.props = {
1108
- ...O.props,
1109
- ...ae.props
1110
- };
1111
1192
  le.props = {
1112
- ...$e.props,
1193
+ ...U.props,
1113
1194
  ...le.props
1114
1195
  };
1115
1196
  re.props = {
1116
- ...We.props,
1117
- ...re.props,
1118
- modelValue: String
1197
+ ...Ge.props,
1198
+ ...re.props
1119
1199
  };
1120
1200
  oe.props = {
1121
- ...Ae.props,
1201
+ ...Ze.props,
1122
1202
  ...oe.props,
1203
+ modelValue: String
1204
+ };
1205
+ ue.props = {
1206
+ ...Ue.props,
1207
+ ...ue.props,
1123
1208
  placement: { type: String, default: "top-start" }
1124
1209
  };
1125
- const sn = {
1126
- [b.LoadingKey]: qe,
1127
- [b.RowKey]: bt,
1128
- [b.ColKey]: ht,
1129
- [b.ButtonKey]: z,
1130
- [b.DescriptionsKey]: Le,
1131
- [b.DescriptionsItemKey]: Pt,
1132
- [b.MenusKey]: Ut,
1133
- [b.ModalKey]: $e,
1134
- [b.PaginationKey]: Dt,
1135
- [b.PopoverKey]: Lt,
1136
- [b.TooltipKey]: Ae,
1137
- [b.CheckboxKey]: De,
1138
- [b.FormKey]: Bt,
1139
- [b.FormItemKey]: ze,
1140
- [b.TableKey]: He,
1141
- [b.TableOperateKey]: rn,
1142
- [b.UploaderKey]: We,
1143
- [b.DropdownKey]: Gt,
1144
- [b.ProFormKey]: O,
1145
- [b.ProSearchFormKey]: W,
1146
- [b.ProTableKey]: Z,
1147
- [b.ProCurdKey]: Xe,
1148
- [b.ProListKey]: Ye,
1149
- [b.ProPageKey]: et,
1150
- text: ue,
1151
- digit: tt,
1152
- date: nt,
1153
- time: ue,
1154
- select: _,
1155
- radio: _,
1156
- checkbox: _,
1157
- treeSelect: ce,
1158
- cascader: ce
1159
- }, gn = {
1160
- text: _t,
1161
- digit: Wt,
1162
- digitRange: Zt,
1163
- date: Ht,
1164
- time: Jt,
1165
- select: Qt,
1166
- treeSelect: Xt,
1167
- checkbox: Yt,
1168
- radio: en,
1169
- switch: tn,
1170
- cascader: nn
1210
+ const ha = {
1211
+ [m.LoadingKey]: qe,
1212
+ [m.RowKey]: St,
1213
+ [m.ColKey]: Pt,
1214
+ [m.ButtonKey]: X,
1215
+ [m.DescriptionsKey]: Le,
1216
+ [m.DescriptionsItemKey]: ht,
1217
+ [m.MenusKey]: Ht,
1218
+ [m.ModalKey]: Ge,
1219
+ [m.DrawerKey]: $t,
1220
+ [m.PaginationKey]: qt,
1221
+ [m.PopoverKey]: Gt,
1222
+ [m.TooltipKey]: Ue,
1223
+ [m.CheckboxKey]: De,
1224
+ [m.FormKey]: At,
1225
+ [m.FormItemKey]: ze,
1226
+ [m.TableKey]: Je,
1227
+ [m.TableOperateKey]: ma,
1228
+ [m.UploaderKey]: Ze,
1229
+ [m.DropdownKey]: Yt,
1230
+ [m.ScrollKey]: Ct,
1231
+ [m.EmptyKey]: Kt,
1232
+ [m.ProFormKey]: U,
1233
+ [m.ProSearchFormKey]: _,
1234
+ [m.ProTableKey]: W,
1235
+ [m.ProCurdKey]: Ye,
1236
+ [m.ProListKey]: et,
1237
+ [m.ProPageKey]: tt,
1238
+ [m.ProOperateKey]: at,
1239
+ text: ce,
1240
+ digit: nt,
1241
+ date: lt,
1242
+ time: ce,
1243
+ select: G,
1244
+ radio: G,
1245
+ checkbox: G,
1246
+ treeSelect: de,
1247
+ cascader: de
1248
+ }, Ca = {
1249
+ text: ea,
1250
+ digit: ta,
1251
+ digitRange: aa,
1252
+ date: na,
1253
+ time: la,
1254
+ select: ra,
1255
+ treeSelect: oa,
1256
+ checkbox: ua,
1257
+ radio: ca,
1258
+ switch: da,
1259
+ cascader: ia
1171
1260
  };
1172
1261
  export {
1173
- Ue as FormMethods,
1174
- qt as InputNumberRange,
1175
- At as ProCheckbox,
1176
- Gt as ProDropdown,
1177
- Bt as ProForm,
1178
- nn as ProFormCascader,
1179
- Yt as ProFormCheckbox,
1180
- Ht as ProFormDatePicker,
1181
- Zt as ProFormInputNumberRange,
1262
+ je as FormMethods,
1263
+ Qt as InputNumberRange,
1264
+ _t as ProCheckbox,
1265
+ $t as ProDrawer,
1266
+ Yt as ProDropdown,
1267
+ At as ProForm,
1268
+ ia as ProFormCascader,
1269
+ ua as ProFormCheckbox,
1270
+ na as ProFormDatePicker,
1271
+ aa as ProFormInputNumberRange,
1182
1272
  ze as ProFormItem,
1183
- en as ProFormRadio,
1184
- Qt as ProFormSelect,
1185
- tn as ProFormSwitch,
1186
- _t as ProFormText,
1187
- Wt as ProFormTextNumber,
1188
- Jt as ProFormTimePicker,
1189
- Xt as ProFormTreeSelect,
1273
+ ca as ProFormRadio,
1274
+ ra as ProFormSelect,
1275
+ da as ProFormSwitch,
1276
+ ea as ProFormText,
1277
+ ta as ProFormTextNumber,
1278
+ la as ProFormTimePicker,
1279
+ oa as ProFormTreeSelect,
1190
1280
  qe as ProLoading,
1191
- Ut as ProMenus,
1192
- $e as ProModal,
1193
- Dt as ProPagination,
1194
- Lt as ProPopover,
1195
- Ot as ProRadio,
1196
- zt as ProSelect,
1197
- He as ProTable,
1198
- Ze as ProTableColumn,
1199
- rn as ProTableOperateItem,
1200
- mn as ProTabs,
1201
- yn as ProTree,
1202
- We as ProUploader,
1203
- an as TableMethods,
1204
- jt as UploadMethods,
1205
- M as createFormItemComponent,
1206
- je as createLoadingId,
1207
- sn as elementMap,
1208
- gn as formElementMap
1281
+ Ht as ProMenus,
1282
+ Ge as ProModal,
1283
+ qt as ProPagination,
1284
+ Gt as ProPopover,
1285
+ Wt as ProRadio,
1286
+ Zt as ProSelect,
1287
+ Je as ProTable,
1288
+ He as ProTableColumn,
1289
+ ma as ProTableOperateItem,
1290
+ Sa as ProTabs,
1291
+ Pa as ProTree,
1292
+ Ze as ProUploader,
1293
+ fa as TableMethods,
1294
+ Jt as UploadMethods,
1295
+ V as createFormItemComponent,
1296
+ $e as createLoadingId,
1297
+ ha as elementMap,
1298
+ Ca as formElementMap
1209
1299
  };