@aplus-frontend/ui 6.11.0 → 6.13.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (92) hide show
  1. package/es/src/ap-descriptions/interface.d.ts +1 -1
  2. package/es/src/ap-form/ap-form.vue2.mjs +118 -108
  3. package/es/src/ap-form/items/number/index.vue.d.ts +2 -2
  4. package/es/src/ap-form/items/select/index.vue.d.ts +4 -4
  5. package/es/src/ap-form/items/text/index.vue.d.ts +2 -2
  6. package/es/src/ap-form/items/text/password.vue.d.ts +2 -2
  7. package/es/src/ap-form/items/tree-select/index.vue.d.ts +4 -4
  8. package/es/src/ap-form/search-form/hooks/use-collapse-input-count.d.ts +8 -1
  9. package/es/src/ap-form/search-form/hooks/use-collapse-input-count.mjs +27 -19
  10. package/es/src/ap-form/search-form/hooks/use-sorter.mjs +31 -30
  11. package/es/src/ap-form/search-form/index.vue.d.ts +6 -2
  12. package/es/src/ap-form/search-form/index.vue.mjs +35 -35
  13. package/es/src/ap-grid/index.vue.mjs +221 -225
  14. package/es/src/ap-modal/interface.d.ts +8 -0
  15. package/es/src/ap-modal/utils/createModalStream.mjs +69 -66
  16. package/es/src/ap-table/ap-table.vue2.mjs +107 -111
  17. package/es/src/ap-table/constants.d.ts +7 -7
  18. package/es/src/ap-table/context.d.ts +1 -0
  19. package/es/src/ap-table/context.mjs +6 -5
  20. package/es/src/ap-table/utils.d.ts +5 -3247
  21. package/es/src/ap-table/utils.mjs +107 -121
  22. package/es/src/business/ap-card/ApCard.vue2.mjs +17 -17
  23. package/es/src/business/ap-summary/interface.d.ts +1 -1
  24. package/es/src/business/ap-view/ap-view.vue2.mjs +76 -74
  25. package/es/src/business/ap-view/interface.d.ts +1 -0
  26. package/es/src/business/batch-input-group/index.vue.d.ts +2 -1
  27. package/es/src/business/batch-input-group/index.vue.mjs +56 -52
  28. package/es/src/business/batch-input-group/interface.d.ts +5 -0
  29. package/es/src/business/batch-input-group/popover-input/index.vue2.mjs +36 -32
  30. package/es/src/business/batch-input-group/utils.d.ts +8 -0
  31. package/es/src/business/batch-input-group/utils.mjs +10 -0
  32. package/es/src/config-provider/config-provider-props.d.ts +5 -1
  33. package/es/src/config-provider/config-provider-props.mjs +4 -0
  34. package/es/src/config-provider/config-provider.d.ts +14 -5
  35. package/es/src/config-provider/config-provider.mjs +19 -18
  36. package/es/src/config-provider/constants.d.ts +3 -0
  37. package/es/src/config-provider/hooks/use-global-config.d.ts +5 -1
  38. package/es/src/config-provider/index.d.ts +28 -13
  39. package/es/src/utils/config-provider-preset.d.ts +6 -6
  40. package/es/src/version.d.ts +1 -1
  41. package/es/src/version.mjs +1 -1
  42. package/lib/src/ap-descriptions/interface.d.ts +1 -1
  43. package/lib/src/ap-form/ap-form.vue2.js +1 -1
  44. package/lib/src/ap-form/items/number/index.vue.d.ts +2 -2
  45. package/lib/src/ap-form/items/select/index.vue.d.ts +4 -4
  46. package/lib/src/ap-form/items/text/index.vue.d.ts +2 -2
  47. package/lib/src/ap-form/items/text/password.vue.d.ts +2 -2
  48. package/lib/src/ap-form/items/tree-select/index.vue.d.ts +4 -4
  49. package/lib/src/ap-form/search-form/hooks/use-collapse-input-count.d.ts +8 -1
  50. package/lib/src/ap-form/search-form/hooks/use-collapse-input-count.js +1 -1
  51. package/lib/src/ap-form/search-form/hooks/use-sorter.js +1 -1
  52. package/lib/src/ap-form/search-form/index.vue.d.ts +6 -2
  53. package/lib/src/ap-form/search-form/index.vue.js +1 -1
  54. package/lib/src/ap-grid/index.vue.js +1 -1
  55. package/lib/src/ap-modal/interface.d.ts +8 -0
  56. package/lib/src/ap-modal/utils/createModalStream.js +1 -1
  57. package/lib/src/ap-table/ap-table.vue2.js +1 -1
  58. package/lib/src/ap-table/constants.d.ts +7 -7
  59. package/lib/src/ap-table/context.d.ts +1 -0
  60. package/lib/src/ap-table/context.js +1 -1
  61. package/lib/src/ap-table/utils.d.ts +5 -3247
  62. package/lib/src/ap-table/utils.js +1 -1
  63. package/lib/src/business/ap-card/ApCard.vue2.js +1 -1
  64. package/lib/src/business/ap-summary/interface.d.ts +1 -1
  65. package/lib/src/business/ap-view/ap-view.vue2.js +1 -1
  66. package/lib/src/business/ap-view/interface.d.ts +1 -0
  67. package/lib/src/business/batch-input-group/index.vue.d.ts +2 -1
  68. package/lib/src/business/batch-input-group/index.vue.js +2 -2
  69. package/lib/src/business/batch-input-group/interface.d.ts +5 -0
  70. package/lib/src/business/batch-input-group/popover-input/index.vue2.js +3 -2
  71. package/lib/src/business/batch-input-group/utils.d.ts +8 -0
  72. package/lib/src/business/batch-input-group/utils.js +1 -0
  73. package/lib/src/config-provider/config-provider-props.d.ts +5 -1
  74. package/lib/src/config-provider/config-provider-props.js +1 -1
  75. package/lib/src/config-provider/config-provider.d.ts +14 -5
  76. package/lib/src/config-provider/config-provider.js +1 -1
  77. package/lib/src/config-provider/constants.d.ts +3 -0
  78. package/lib/src/config-provider/hooks/use-global-config.d.ts +5 -1
  79. package/lib/src/config-provider/index.d.ts +28 -13
  80. package/lib/src/utils/config-provider-preset.d.ts +6 -6
  81. package/lib/src/version.d.ts +1 -1
  82. package/lib/src/version.js +1 -1
  83. package/package.json +3 -3
  84. package/theme/ap-grid/index.css +3 -0
  85. package/theme/ap-grid/index.less +3 -4
  86. package/theme/index.css +3 -0
  87. package/es/src/ap-table/components/dynamic-component/index.vue.d.ts +0 -4
  88. package/es/src/ap-table/components/dynamic-component/index.vue.mjs +0 -4
  89. package/es/src/ap-table/components/dynamic-component/index.vue2.mjs +0 -15
  90. package/lib/src/ap-table/components/dynamic-component/index.vue.d.ts +0 -4
  91. package/lib/src/ap-table/components/dynamic-component/index.vue.js +0 -1
  92. package/lib/src/ap-table/components/dynamic-component/index.vue2.js +0 -1
@@ -71,6 +71,14 @@ export type ModalStreamNextFunc<ModalType extends ModalStreamTypeKey = ModalStre
71
71
  * 本次弹框的实例方法
72
72
  */
73
73
  modalExample: ModalStreamTypeExample[ModalType]) => any | Promise<any>;
74
+ /**
75
+ * 处理当前弹框流中存在的弹框
76
+ * @param option.getModal 根据modalId获取弹框实例
77
+ * @returns
78
+ */
79
+ handleModal?: (option: {
80
+ getModal: (modalId: string) => CreateModalFuncReturn;
81
+ }) => any | Promise<any>;
74
82
  }) => any | Promise<any>;
75
83
  export type ModalStreamType = {
76
84
  createModal: CreateModalStream<'createModal'>;
@@ -1,99 +1,102 @@
1
1
  import { isValid as L } from "@aplus-frontend/utils";
2
2
  import { createModal as P } from "./createModal.mjs";
3
3
  import { Modal as V } from "@aplus-frontend/antdv";
4
- import { ModalMessage as S } from "../enums/modalMessage.mjs";
5
- const G = (u, F) => {
6
- var O;
7
- const y = F ?? (Array.isArray(u) ? (O = u[0]) == null ? void 0 : O.modalId : void 0), d = /* @__PURE__ */ new Map();
8
- let T, _, E = 1e3;
9
- const l = async ({
10
- modalId: f,
11
- params: o,
12
- handleCurrentModal: t
4
+ import { ModalMessage as y } from "../enums/modalMessage.mjs";
5
+ const H = (d, F) => {
6
+ var A;
7
+ const g = F ?? (Array.isArray(d) ? (A = d[0]) == null ? void 0 : A.modalId : void 0), o = /* @__PURE__ */ new Map();
8
+ let k, I, m = 1e3;
9
+ const T = async ({
10
+ modalId: i,
11
+ params: E,
12
+ handleCurrentModal: n,
13
+ handleModal: w
13
14
  }) => {
14
- T = o;
15
- const w = u.find((n) => n.modalId === f);
16
- let s = !1;
17
- if (_) {
18
- const n = d.get(_), i = {
19
- ...n,
15
+ k = E;
16
+ const s = d.find((t) => t.modalId === i);
17
+ let a = !1;
18
+ if (I) {
19
+ const t = o.get(I), c = {
20
+ ...t,
20
21
  destroy: () => {
21
- var a;
22
- (a = n == null ? void 0 : n.destroy) == null || a.call(n), d.delete(_);
22
+ var N;
23
+ (N = t == null ? void 0 : t.destroy) == null || N.call(t), o.delete(I);
23
24
  },
24
25
  open: () => {
25
- s = !0;
26
+ a = !0;
26
27
  }
27
28
  };
28
- await (t == null ? void 0 : t(i));
29
+ await (n == null ? void 0 : n(c)), await (w == null ? void 0 : w({
30
+ getModal: o.get.bind(o)
31
+ }));
29
32
  }
30
- return w && setTimeout(() => {
31
- k(w);
32
- }), s;
33
- }, I = () => {
34
- var f;
35
- for (const [o, t] of d)
36
- (f = t == null ? void 0 : t.destroy) == null || f.call(t);
37
- }, k = async (f) => {
38
- var g, A, C, z;
33
+ return s && setTimeout(() => {
34
+ D(s);
35
+ }), a;
36
+ }, C = () => {
37
+ var i;
38
+ for (const [E, n] of o)
39
+ (i = n == null ? void 0 : n.destroy) == null || i.call(n);
40
+ }, D = async (i) => {
41
+ var N, z, S, b;
39
42
  const {
40
- modalId: o,
41
- modalType: t = "createModal",
43
+ modalId: E,
44
+ modalType: n = "createModal",
42
45
  props: w
43
- } = f;
44
- _ = o;
45
- const s = d.get(o), n = await (w == null ? void 0 : w(T, async (e) => (a = !0, await l(e))));
46
- E = Math.max((n == null ? void 0 : n.zIndex) ?? 0, E), E += 1;
47
- let i, a = !1;
48
- if (t === "createModal") {
49
- const e = n, m = async (r) => (a = !0, await l(r));
50
- i = {
46
+ } = i;
47
+ I = E;
48
+ const s = o.get(E), a = await (w == null ? void 0 : w(k, async (e) => (c = !0, await T(e))));
49
+ m = Math.max((a == null ? void 0 : a.zIndex) ?? 0, m), m += 1;
50
+ let t, c = !1;
51
+ if (n === "createModal") {
52
+ const e = a, u = async (r) => (c = !0, await T(r));
53
+ t = {
51
54
  ...e,
52
55
  destroyOnClose: !1,
53
- zIndex: E,
56
+ zIndex: m,
54
57
  onOk: async (r) => {
55
- var N;
56
- const c = await ((N = e == null ? void 0 : e.onOk) == null ? void 0 : N.call(e, r, m));
57
- if (a || I(), c)
58
- throw new Error(S.NOT_NEED_CLOSE);
58
+ var _;
59
+ const f = await ((_ = e == null ? void 0 : e.onOk) == null ? void 0 : _.call(e, r, u));
60
+ if (c || C(), f)
61
+ throw new Error(y.NOT_NEED_CLOSE);
59
62
  },
60
63
  onCancel: async (r) => {
61
- var N;
62
- const c = await ((N = e == null ? void 0 : e.onCancel) == null ? void 0 : N.call(e, r, m));
63
- if (a || I(), c)
64
- throw new Error(S.NOT_NEED_CLOSE);
64
+ var _;
65
+ const f = await ((_ = e == null ? void 0 : e.onCancel) == null ? void 0 : _.call(e, r, u));
66
+ if (c || C(), f)
67
+ throw new Error(y.NOT_NEED_CLOSE);
65
68
  }
66
69
  };
67
70
  } else {
68
- const e = n, m = async (r) => (a = !0, await l(r));
69
- i = {
71
+ const e = a, u = async (r) => (c = !0, await T(r));
72
+ t = {
70
73
  ...e,
71
- zIndex: E,
74
+ zIndex: m,
72
75
  onOk: async () => {
73
- var c;
74
- const r = await ((c = e == null ? void 0 : e.onOk) == null ? void 0 : c.call(e, m));
75
- if (a || I(), r)
76
- throw new Error(S.NOT_NEED_CLOSE);
76
+ var f;
77
+ const r = await ((f = e == null ? void 0 : e.onOk) == null ? void 0 : f.call(e, u));
78
+ if (c || C(), r)
79
+ throw new Error(y.NOT_NEED_CLOSE);
77
80
  },
78
81
  onCancel: async () => {
79
- var c;
80
- const r = await ((c = e == null ? void 0 : e.onCancel) == null ? void 0 : c.call(e, m));
81
- if (a || I(), r)
82
- throw new Error(S.NOT_NEED_CLOSE);
82
+ var f;
83
+ const r = await ((f = e == null ? void 0 : e.onCancel) == null ? void 0 : f.call(e, u));
84
+ if (c || C(), r)
85
+ throw new Error(y.NOT_NEED_CLOSE);
83
86
  }
84
87
  };
85
88
  }
86
89
  if (s) {
87
- s == null || s.update(i), (g = s == null ? void 0 : s.open) == null || g.call(s);
90
+ s == null || s.update(t), (N = s == null ? void 0 : s.open) == null || N.call(s);
88
91
  return;
89
- } else if (t === "createModal") {
90
- const e = P(i);
91
- (A = e == null ? void 0 : e.open) == null || A.call(e), d.set(o, e);
92
+ } else if (n === "createModal") {
93
+ const e = P(t);
94
+ (z = e == null ? void 0 : e.open) == null || z.call(e), o.set(E, e);
92
95
  } else
93
- (z = (C = V) == null ? void 0 : C[t]) == null || z.call(C, i);
94
- }, D = u.find((f) => L(y) && f.modalId === y);
95
- D !== void 0 && k(D);
96
+ (b = (S = V) == null ? void 0 : S[n]) == null || b.call(S, t);
97
+ }, O = d.find((i) => L(g) && i.modalId === g);
98
+ O !== void 0 && D(O);
96
99
  };
97
100
  export {
98
- G as createModalStream
101
+ H as createModalStream
99
102
  };
@@ -1,15 +1,15 @@
1
- import { defineComponent as je, useSlots as We, ref as v, computed as s, unref as l, toRef as _e, createVNode as y, Fragment as ae, watch as B, createElementBlock as I, openBlock as g, normalizeStyle as K, normalizeClass as b, createCommentVNode as le, createElementVNode as L, mergeProps as R, createSlots as ne, withCtx as C, renderList as se, createBlock as de, resolveDynamicComponent as He, renderSlot as T, normalizeProps as Ue, guardReactiveProps as qe } from "vue";
1
+ import { defineComponent as je, useSlots as We, ref as v, computed as s, unref as l, toRef as He, createVNode as y, Fragment as le, watch as k, createElementBlock as B, openBlock as g, normalizeStyle as K, normalizeClass as b, createCommentVNode as ne, createElementVNode as L, mergeProps as I, createSlots as se, withCtx as R, renderList as de, createBlock as ue, resolveDynamicComponent as _e, renderSlot as C, normalizeProps as Ue, guardReactiveProps as qe } from "vue";
2
2
  import { Divider as Me, Table as Ge } from "@aplus-frontend/antdv";
3
3
  import { useToken as Je } from "@aplus-frontend/antdv/es/theme/internal";
4
4
  import { ApForm as Qe } from "../ap-form/index.mjs";
5
- import { noRenderAsFormItemValueList as ue } from "./constants.mjs";
5
+ import { noRenderAsFormItemValueList as ie } from "./constants.mjs";
6
6
  import "../config-provider/index.mjs";
7
7
  import { useTablePaging as Xe } from "./hooks/use-table-paging-ng.mjs";
8
- import { isUndefined as S, omit as ie, isBoolean as Ye } from "lodash-unified";
9
- import { getColumnOrder as ce, updateFormProps as Ze, getFieldProps as er, getSearchFormItemRenderNode as rr, recursionApColumns as fe, getTableTitle as or, getTableRenderType as tr, getTableRenderProps as ar, getTableCellRenderNode as lr, apColumnToColumn as nr, falseToUndefined as sr, objectToString as dr } from "./utils.mjs";
8
+ import { isUndefined as S, omit as ce, isBoolean as Ye } from "lodash-unified";
9
+ import { getColumnOrder as fe, updateFormProps as Ze, getFieldProps as er, getSearchFormItemRenderNode as rr, recursionApColumns as pe, getTableTitle as or, getTableRenderType as tr, getTableRenderProps as ar, getTableCellRenderNode as lr, apColumnToColumn as nr, falseToUndefined as sr, objectToString as dr } from "./utils.mjs";
10
10
  import ur from "./hooks/use-table-content-height.mjs";
11
11
  import ir from "./hooks/use-table-row-selection.mjs";
12
- import { getScrollbarSize as cr, isDef as pe } from "../utils/index.mjs";
12
+ import { getScrollbarSize as cr, isDef as me } from "../utils/index.mjs";
13
13
  import "./components/setting/modal/index.vue.mjs";
14
14
  import "./components/paragraph-ellipsis/index.vue.mjs";
15
15
  import { useProvideApTable as fr } from "./context.mjs";
@@ -21,7 +21,7 @@ import { useGlobalConfig as gr } from "../config-provider/hooks/use-global-confi
21
21
  import br from "./components/paragraph-ellipsis/index.vue2.mjs";
22
22
  import Sr from "./components/setting/modal/index.vue2.mjs";
23
23
  import hr from "../scroll-bar/index.vue.mjs";
24
- const _r = /* @__PURE__ */ je({
24
+ const Hr = /* @__PURE__ */ je({
25
25
  name: "ApTable",
26
26
  __name: "ap-table",
27
27
  props: {
@@ -145,27 +145,27 @@ const _r = /* @__PURE__ */ je({
145
145
  default: void 0
146
146
  }
147
147
  },
148
- setup(me, {
149
- expose: ye
148
+ setup(ye, {
149
+ expose: ge
150
150
  }) {
151
- const r = me;
151
+ const r = ye;
152
152
  let O = 0;
153
- const c = We(), [, ge] = Je(), {
153
+ const c = We(), [, be] = Je(), {
154
154
  e: z,
155
155
  b: f,
156
156
  be: A,
157
- m: be,
158
- cssVar: Se
157
+ m: Se,
158
+ cssVar: he
159
159
  } = yr("ap-table"), $ = gr("valueTypeMap"), {
160
- height: he,
161
- contentRef: we
160
+ height: we,
161
+ contentRef: ve
162
162
  } = ur(), D = v(), j = v(), {
163
163
  isStickyMode: W,
164
164
  scrollBarRef: i
165
- } = pr(D), N = v(r.size), u = v([]), _ = v([]), H = cr();
165
+ } = pr(D), N = v(r.size), u = v([]), H = v([]), _ = cr();
166
166
  fr({
167
167
  columns: s(() => u.value),
168
- columnsBackup: s(() => _.value),
168
+ columnsBackup: s(() => H.value),
169
169
  size: s(() => N.value),
170
170
  updateColumns(e) {
171
171
  u.value = e;
@@ -174,19 +174,20 @@ const _r = /* @__PURE__ */ je({
174
174
  N.value = e;
175
175
  },
176
176
  dataSource: s(() => l(h).records),
177
- getSearchFormValues: Q,
178
- setSearchFormValues: J,
177
+ getSearchFormValues: X,
178
+ setSearchFormValues: Q,
179
179
  submit: () => P(),
180
180
  reset: () => V(),
181
- getSearchFormSorterItems: X,
182
- setSearchFormSorterItems: Y,
183
- resetSearchFormSorterItems: Z
181
+ refresh: () => M(),
182
+ getSearchFormSorterItems: Y,
183
+ setSearchFormSorterItems: Z,
184
+ resetSearchFormSorterItems: ee
184
185
  });
185
186
  const U = s(() => {
186
187
  var e, o, t;
187
- return O++, ((t = (o = (e = r.columns) == null ? void 0 : e.filter((a) => !a.hideInSearch && a.dataIndex && (a.valueType || a.customRenderFormItem) && !ue.includes(a.valueType))) == null ? void 0 : o.sort((a, d) => {
188
- let n = ce(a.order);
189
- return ce(d.order) - n;
188
+ return O++, ((t = (o = (e = r.columns) == null ? void 0 : e.filter((a) => !a.hideInSearch && a.dataIndex && (a.valueType || a.customRenderFormItem) && !ie.includes(a.valueType))) == null ? void 0 : o.sort((a, d) => {
189
+ let n = fe(a.order);
190
+ return fe(d.order) - n;
190
191
  })) == null ? void 0 : t.map((a) => {
191
192
  const d = Ze(a, er(a.fieldProps, {})), n = {
192
193
  ...a,
@@ -202,36 +203,36 @@ const _r = /* @__PURE__ */ je({
202
203
  };
203
204
  return n.renderNode = rr(n, l($)), n;
204
205
  })) || [];
205
- }), ve = s(() => fe(l(u), (e) => {
206
+ }), Re = s(() => pe(l(u), (e) => {
206
207
  if (e.sorter === !0)
207
208
  return e.key || (e == null ? void 0 : e.dataIndex);
208
- }).filter(Boolean)), Re = s(() => fe(l(u), (e) => {
209
+ }).filter(Boolean)), Ce = s(() => pe(l(u), (e) => {
209
210
  if (e.filters && !e.onFilter)
210
211
  return e.key || (e == null ? void 0 : e.dataIndex);
211
- }).filter(Boolean)), Ce = s(() => S(r.dataSource) ? h.records : r.dataSource), Te = s(() => {
212
+ }).filter(Boolean)), Te = s(() => S(r.dataSource) ? h.records : r.dataSource), Fe = s(() => {
212
213
  var o;
213
- return pe(r.manual) ? r.manual : mr(((o = c.searchFormExtra) == null ? void 0 : o.call(c)) || []).some((t) => {
214
+ return me(r.manual) ? r.manual : mr(((o = c.searchFormExtra) == null ? void 0 : o.call(c)) || []).some((t) => {
214
215
  var a;
215
216
  return ((a = t.type) == null ? void 0 : a.name) === "ApView";
216
217
  });
217
218
  }), {
218
- rowSelection: F,
219
- selectedRows: x,
220
- ...k
219
+ rowSelection: T,
220
+ selectedRows: F,
221
+ ...x
221
222
  } = ir({
222
223
  fixed: !0,
223
224
  ...r.rowSelection === !0 ? {} : r.rowSelection,
224
225
  rowKey: r.rowKey,
225
- dataSource: Ce
226
+ dataSource: Te
226
227
  }), {
227
228
  formRef: p,
228
229
  submit: P,
229
230
  reset: V,
230
231
  tableProps: q,
231
- refresh: Fe,
232
+ refresh: M,
232
233
  data: h,
233
234
  setDataSource: xe,
234
- getColumnSFConfig: M,
235
+ getColumnSFConfig: G,
235
236
  sortedInfo: ke,
236
237
  filteredInfo: Be,
237
238
  setPaging: Ie,
@@ -239,7 +240,7 @@ const _r = /* @__PURE__ */ je({
239
240
  } = Xe({
240
241
  async request(e) {
241
242
  var t, a;
242
- if (!F.value.preserveSelectedRowKeys && S(r.dataSource) && k.clearAll(), !S(r.dataSource))
243
+ if (!T.value.preserveSelectedRowKeys && S(r.dataSource) && x.clearAll(), !S(r.dataSource))
243
244
  return {
244
245
  data: r.dataSource || [],
245
246
  total: r.dataSource.length || 0
@@ -250,11 +251,11 @@ const _r = /* @__PURE__ */ je({
250
251
  total: (o == null ? void 0 : o.total) || 0
251
252
  };
252
253
  },
253
- filterFields: Re,
254
- sortFields: ve,
255
- params: _e(r, "params"),
254
+ filterFields: Ce,
255
+ sortFields: Re,
256
+ params: He(r, "params"),
256
257
  defaultData: r.defaultData,
257
- manual: l(Te),
258
+ manual: l(Fe),
258
259
  formatParams: r.beforeSearchSubmit,
259
260
  pagination: r.pagination
260
261
  }), Ne = () => {
@@ -262,37 +263,37 @@ const _r = /* @__PURE__ */ je({
262
263
  let e = ((t = r.columns) == null ? void 0 : t.filter((a) => !a.hideInTable)) || [];
263
264
  function o(a, d) {
264
265
  return a.map((n) => ({
265
- resizable: pe(n.resizable) ? n.resizable : r.columnResizable,
266
- ...ie(nr(n), ["ellipsis"]),
266
+ resizable: me(n.resizable) ? n.resizable : r.columnResizable,
267
+ ...ce(nr(n), ["ellipsis"]),
267
268
  // tips: 此函数内部依赖查询&筛选的相应式值
268
- ...M(n),
269
+ ...G(n),
269
270
  fixed: d ? d.fixed : n.fixed,
270
- title: or(n, A("table-header", "title"), c.headerCell, l(ge).colorTextTertiary),
271
+ title: or(n, A("table-header", "title"), c.headerCell, l(be).colorTextTertiary),
271
272
  customRender({
272
273
  value: m,
273
274
  ...w
274
275
  }) {
275
- var oe, te;
276
- const ee = tr(n), Ae = ar({
276
+ var te, ae;
277
+ const re = tr(n), Ae = ar({
277
278
  ...n,
278
- valueType: ee
279
+ valueType: re
279
280
  }, {
280
281
  value: m,
281
282
  ...w
282
- }), $e = lr(ee, Ae, w.record, l($)), re = ((oe = n.renderText) == null ? void 0 : oe.call(n, {
283
+ }), $e = lr(re, Ae, w.record, l($)), oe = ((te = n.renderText) == null ? void 0 : te.call(n, {
283
284
  value: m,
284
285
  ...w
285
- })) || m, De = n.renderText ? y(ae, null, [(te = n.renderText) == null ? void 0 : te.call(n, {
286
+ })) || m, De = n.renderText ? y(le, null, [(ae = n.renderText) == null ? void 0 : ae.call(n, {
286
287
  value: m,
287
288
  ...w
288
289
  })]) : $e;
289
- let E = Le(n, re, De);
290
+ let E = Le(n, oe, De);
290
291
  return n.customRender && (E = n.customRender({
291
292
  value: m,
292
293
  ...w,
293
294
  column: n,
294
295
  originalNode: E,
295
- originalText: re
296
+ originalText: oe
296
297
  })), E;
297
298
  },
298
299
  children: o(n.children || [], d || n)
@@ -303,17 +304,17 @@ const _r = /* @__PURE__ */ je({
303
304
  function e(o) {
304
305
  var t;
305
306
  for (const a of o)
306
- (t = a.children) != null && t.length ? e(a.children) : M(a, !0);
307
+ (t = a.children) != null && t.length ? e(a.children) : G(a, !0);
307
308
  }
308
309
  e(u.value);
309
310
  };
310
- B(() => [r.columns, r.columnResizable], () => {
311
+ k(() => [r.columns, r.columnResizable], () => {
311
312
  const e = Ne();
312
- u.value = e, _.value = e;
313
+ u.value = e, H.value = e;
313
314
  }, {
314
315
  deep: !0,
315
316
  immediate: !0
316
- }), B(() => [ke.value, Be.value], () => {
317
+ }), k(() => [ke.value, Be.value], () => {
317
318
  Pe();
318
319
  }, {
319
320
  deep: !0
@@ -322,7 +323,7 @@ const _r = /* @__PURE__ */ je({
322
323
  var o, t;
323
324
  if (r.adaptive && (h.total > 0 || ((o = r.dataSource) == null ? void 0 : o.length)))
324
325
  return {
325
- y: l(he),
326
+ y: l(we),
326
327
  x: ((t = r.scroll) == null ? void 0 : t.x) || "100%"
327
328
  };
328
329
  if (r.scroll)
@@ -333,9 +334,9 @@ const _r = /* @__PURE__ */ je({
333
334
  return r.tableLayout;
334
335
  if ((e = r.columns) != null && e.some((o) => o.ellipsis))
335
336
  return "fixed";
336
- }), G = s(() => {
337
+ }), J = s(() => {
337
338
  var t;
338
- const e = l(q), o = l(F);
339
+ const e = l(q), o = l(T);
339
340
  return {
340
341
  ...r,
341
342
  ...e,
@@ -350,10 +351,10 @@ const _r = /* @__PURE__ */ je({
350
351
  };
351
352
  }), Ke = s(() => {
352
353
  var e;
353
- return [f(), r.card ? null : f("wrapper"), r.adaptive ? f("adaptive") : null, W.value && ((e = i.value) != null && e.visible) ? be(`sticky-${H === 0 ? "absolute" : "relative"}`) : null].filter(Boolean);
354
+ return [f(), r.card ? null : f("wrapper"), r.adaptive ? f("adaptive") : null, W.value && ((e = i.value) != null && e.visible) ? Se(`sticky-${_ === 0 ? "absolute" : "relative"}`) : null].filter(Boolean);
354
355
  });
355
356
  function Le(e, o, t) {
356
- if (ue.includes(e.valueType))
357
+ if (ie.includes(e.valueType))
357
358
  return t;
358
359
  const a = dr(o);
359
360
  return e.copyable || e.ellipsis ? y(br, {
@@ -369,51 +370,51 @@ const _r = /* @__PURE__ */ je({
369
370
  content: t
370
371
  }, null) : t;
371
372
  }
372
- B(() => l(h).loading, (e) => {
373
+ k(() => l(h).loading, (e) => {
373
374
  var o;
374
375
  (o = r.onLoadingChange) == null || o.call(r, e);
375
- }), B(() => r.dataSource, (e) => {
376
+ }), k(() => r.dataSource, (e) => {
376
377
  xe(e);
377
378
  }, {
378
379
  immediate: !0
379
380
  });
380
- function J(e) {
381
+ function Q(e) {
381
382
  var o, t, a;
382
383
  (a = (t = (o = p.value) == null ? void 0 : o.apForm) == null ? void 0 : t.setFieldsValue) == null || a.call(t, e);
383
384
  }
384
- function Q(e = !1) {
385
+ function X(e = !1) {
385
386
  var t, a, d;
386
387
  const o = e ? "getFieldsValueTransformed" : "getFieldsValue";
387
388
  return (d = (a = (t = p.value) == null ? void 0 : t.apForm) == null ? void 0 : a[o]) == null ? void 0 : d.call(a, !0);
388
389
  }
389
- function X() {
390
+ function Y() {
390
391
  var e;
391
392
  return ((e = p.value) == null ? void 0 : e.getSorterItems()) || [];
392
393
  }
393
- function Y(e) {
394
+ function Z(e) {
394
395
  var o;
395
396
  (o = p.value) == null || o.setSorterItems(e);
396
397
  }
397
- function Z() {
398
+ function ee() {
398
399
  var e;
399
400
  (e = p.value) == null || e.resetSorterItems();
400
401
  }
401
402
  function Oe() {
402
403
  return l(u);
403
404
  }
404
- return ye({
405
+ return ge({
405
406
  submit: () => P(),
406
407
  reset: () => V(),
407
- refresh: () => Fe(),
408
- setSearchFormValues: J,
409
- getSearchFormValues: Q,
408
+ refresh: () => M(),
409
+ setSearchFormValues: Q,
410
+ getSearchFormValues: X,
410
411
  setPaging: Ie,
411
412
  getPaging: ze,
412
413
  getShownColumns: Oe,
413
414
  dataSource: s(() => l(h).records),
414
415
  rowSelection: {
415
- selectedRows: s(() => l(x)),
416
- ...k
416
+ selectedRows: s(() => l(F)),
417
+ ...x
417
418
  },
418
419
  scrollBar: {
419
420
  x: {
@@ -428,86 +429,81 @@ const _r = /* @__PURE__ */ je({
428
429
  },
429
430
  y: void 0
430
431
  },
431
- getSearchFormSorterItems: X,
432
- setSearchFormSorterItems: Y,
433
- resetSearchFormSorterItems: Z
434
- }), (e, o) => (g(), I("div", {
432
+ getSearchFormSorterItems: Y,
433
+ setSearchFormSorterItems: Z,
434
+ resetSearchFormSorterItems: ee
435
+ }), (e, o) => (g(), B("div", {
435
436
  ref_key: "tableWrapperRef",
436
437
  ref: D,
437
438
  class: b(Ke.value),
438
- style: K(l(Se)({
439
- "scroll-bar-width": `${l(H)}px`
439
+ style: K(l(he)({
440
+ "scroll-bar-width": `${l(_)}px`
440
441
  }))
441
- }, [l(S)(e.dataSource) && e.searchForm !== !1 && U.value.length > 0 ? (g(), I("div", {
442
+ }, [l(S)(e.dataSource) && e.searchForm !== !1 && U.value.length > 0 ? (g(), B("div", {
442
443
  key: 0,
443
444
  class: b(e.card ? l(z)("search-wrapper") : null),
444
445
  style: K(e.searchFormWrapperStyle)
445
- }, [y(l(Qe).SearchForm, R(e.searchForm || {}, {
446
+ }, [y(l(Qe).SearchForm, I(e.searchForm || {}, {
446
447
  ref_key: "formRef",
447
448
  ref: p,
448
449
  "custom-reset": "",
449
450
  "submit-loading": l(q).loading,
450
451
  onSubmit: l(P),
451
452
  onReset: l(V)
452
- }), ne({
453
- default: C(() => [(g(!0), I(ae, null, se(U.value, (t) => (g(), de(He(t.renderNode.Comp), R({
454
- key: t.dataIndex,
455
- item: t,
456
- ref_for: !0
457
- }, t.fieldProps || {}, {
458
- span: t.span,
459
- "custom-render": t.renderNode.render
460
- }), null, 16, ["item", "span", "custom-render"]))), 128))]),
453
+ }), se({
454
+ default: R(() => [(g(!0), B(le, null, de(U.value, (t) => (g(), ue(_e(t.renderNode), {
455
+ key: t.dataIndex
456
+ }))), 128))]),
461
457
  _: 2
462
458
  }, [c.searchFormExtra ? {
463
459
  name: "extra",
464
- fn: C(() => [T(e.$slots, "searchFormExtra")]),
460
+ fn: R(() => [C(e.$slots, "searchFormExtra")]),
465
461
  key: "0"
466
- } : void 0]), 1040, ["submit-loading", "onSubmit", "onReset"])], 6)) : le("", !0), L("div", {
462
+ } : void 0]), 1040, ["submit-loading", "onSubmit", "onReset"])], 6)) : ne("", !0), L("div", {
467
463
  ref_key: "contentRef",
468
- ref: we,
464
+ ref: ve,
469
465
  class: b([l(z)("table-wrapper"), e.card ? l(z)("table-wrapper-card") : null]),
470
466
  style: K(e.tableWrapperStyle)
471
467
  }, [L("div", {
472
468
  class: b(l(f)("header-wrapper"))
473
- }, [e.settings ? (g(), I("div", {
469
+ }, [e.settings ? (g(), B("div", {
474
470
  key: 0,
475
471
  class: b(l(f)("header"))
476
472
  }, [L("div", {
477
473
  class: b(l(A)("header", "title"))
478
- }, [T(e.$slots, "title", R({
479
- selectedRows: l(x),
480
- selectedRowKeys: l(F).selectedRowKeys,
474
+ }, [C(e.$slots, "title", I({
475
+ selectedRows: l(F),
476
+ selectedRowKeys: l(T).selectedRowKeys,
481
477
  shownColumns: u.value
482
- }, k))], 2), c.title ? (g(), de(l(Me), {
478
+ }, x))], 2), c.title ? (g(), ue(l(Me), {
483
479
  key: 0,
484
480
  type: "vertical"
485
- })) : le("", !0), y(Sr, {
481
+ })) : ne("", !0), y(Sr, {
486
482
  config: e.settings === !0 ? {} : e.settings
487
- }, null, 8, ["config"])], 2)) : T(e.$slots, "title", R({
483
+ }, null, 8, ["config"])], 2)) : C(e.$slots, "title", I({
488
484
  key: 1,
489
- selectedRows: l(x),
490
- selectedRowKeys: l(F).selectedRowKeys,
485
+ selectedRows: l(F),
486
+ selectedRowKeys: l(T).selectedRowKeys,
491
487
  shownColumns: u.value
492
- }, k))], 2), y(l(Ge), R({
488
+ }, x))], 2), y(l(Ge), I({
493
489
  ref_key: "antdTableRef",
494
490
  ref: j,
495
491
  class: l(f)("table")
496
- }, G.value, {
492
+ }, J.value, {
497
493
  size: N.value,
498
494
  "table-layout": Ee.value,
499
495
  columns: u.value,
500
496
  onResizeColumn: o[0] || (o[0] = (t, a) => a.width = t)
501
- }), ne({
502
- summary: C(() => [T(e.$slots, "summary", {
497
+ }), se({
498
+ summary: R(() => [C(e.$slots, "summary", {
503
499
  columns: u.value,
504
- records: G.value.dataSource,
505
- selectedRows: l(x)
500
+ records: J.value.dataSource,
501
+ selectedRows: l(F)
506
502
  })]),
507
503
  _: 2
508
504
  }, [l(W) ? {
509
505
  name: "bottomPaginationTop",
510
- fn: C(() => {
506
+ fn: R(() => {
511
507
  var t, a;
512
508
  return [y(l(hr), {
513
509
  ref_key: "scrollBarRef",
@@ -519,12 +515,12 @@ const _r = /* @__PURE__ */ je({
519
515
  }, null, 8, ["scroll-container"])];
520
516
  }),
521
517
  key: "0"
522
- } : void 0, se(l(ie)(c, ["title", "searchFormExtra", "headerCell", "summary"]), (t, a) => ({
518
+ } : void 0, de(l(ce)(c, ["title", "searchFormExtra", "headerCell", "summary"]), (t, a) => ({
523
519
  name: a,
524
- fn: C((d) => [T(e.$slots, a, Ue(qe(d || {})))])
520
+ fn: R((d) => [C(e.$slots, a, Ue(qe(d || {})))])
525
521
  }))]), 1040, ["class", "size", "table-layout", "columns"])], 6)], 6));
526
522
  }
527
523
  });
528
524
  export {
529
- _r as default
525
+ Hr as default
530
526
  };