@aplus-frontend/ui 6.26.4 → 6.27.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 (102) hide show
  1. package/es/src/ag-grid/hooks/use-columns-def.d.ts +2 -2
  2. package/es/src/ag-grid/hooks/use-columns-def.mjs +29 -29
  3. package/es/src/ag-grid/hooks/use-columns.d.ts +1 -1
  4. package/es/src/ag-grid/hooks/use-columns.mjs +8 -8
  5. package/es/src/ag-grid/hooks/use-pinned-row.d.ts +7 -0
  6. package/es/src/ag-grid/hooks/use-pinned-row.mjs +32 -0
  7. package/es/src/ag-grid/hooks/use-virtual-config.d.ts +5 -0
  8. package/es/src/ag-grid/hooks/use-virtual-config.mjs +25 -0
  9. package/es/src/ag-grid/index.vue.mjs +274 -232
  10. package/es/src/ag-grid/interface.d.ts +25 -2
  11. package/es/src/ap-field/select/index.vue.d.ts +51 -21
  12. package/es/src/ap-field/select/index.vue.mjs +51 -49
  13. package/es/src/ap-field/select/read.vue2.mjs +4 -1
  14. package/es/src/ap-field/tree-select/index.vue.d.ts +29 -21
  15. package/es/src/ap-field/tree-select/index.vue.mjs +11 -9
  16. package/es/src/ap-field/tree-select/read.vue2.mjs +7 -5
  17. package/es/src/ap-form/ap-form.vue.d.ts +20 -0
  18. package/es/src/ap-form/ap-form.vue2.mjs +11 -10
  19. package/es/src/ap-form/drawer-form/index.vue.d.ts +22 -0
  20. package/es/src/ap-form/drawer-form/index.vue.mjs +1 -0
  21. package/es/src/ap-form/hooks/use-watch.mjs +25 -28
  22. package/es/src/ap-form/interface.d.ts +1 -1
  23. package/es/src/ap-form/items/select/index.vue.d.ts +64 -28
  24. package/es/src/ap-form/items/tree-select/index.vue.d.ts +40 -28
  25. package/es/src/ap-form/modal-form/index.vue.d.ts +22 -0
  26. package/es/src/ap-form/modal-form/index.vue.mjs +31 -30
  27. package/es/src/ap-form/search-form/index.vue.d.ts +24 -2
  28. package/es/src/ap-form/search-form/index.vue.mjs +72 -68
  29. package/es/src/ap-table/constants.d.ts +52 -28
  30. package/es/src/ap-upload/apUpload.vue.d.ts +9 -0
  31. package/es/src/ap-upload/apUpload.vue.mjs +38 -34
  32. package/es/src/ap-upload/components/MultipleFile.vue2.mjs +59 -59
  33. package/es/src/ap-upload/components/Picture.vue2.mjs +74 -74
  34. package/es/src/ap-upload/components/SingleFile.vue2.mjs +95 -95
  35. package/es/src/business/ap-value-select-card/index.vue2.mjs +120 -123
  36. package/es/src/business/ap-view/components/main-button-content.vue.d.ts +11 -0
  37. package/es/src/business/ap-view/components/menu-list-content.vue.d.ts +11 -0
  38. package/es/src/business/hooks/usePageListAgGrid.d.ts +1 -1
  39. package/es/src/business/hooks/usePageListAgGrid.mjs +4 -4
  40. package/es/src/business/hooks/usePageListApGrid.mjs +14 -14
  41. package/es/src/config-provider/config-provider-props.d.ts +14 -1
  42. package/es/src/config-provider/config-provider.d.ts +31 -1
  43. package/es/src/config-provider/hooks/use-global-config.d.ts +14 -1
  44. package/es/src/config-provider/index.d.ts +52 -1
  45. package/es/src/utils/config-provider-preset.d.ts +11 -1
  46. package/es/src/version.d.ts +1 -1
  47. package/es/src/version.mjs +1 -1
  48. package/es/src/work-order-modal/work-order-modal.vue.d.ts +11 -0
  49. package/lib/src/ag-grid/hooks/use-columns-def.d.ts +2 -2
  50. package/lib/src/ag-grid/hooks/use-columns-def.js +1 -1
  51. package/lib/src/ag-grid/hooks/use-columns.d.ts +1 -1
  52. package/lib/src/ag-grid/hooks/use-columns.js +1 -1
  53. package/lib/src/ag-grid/hooks/use-pinned-row.d.ts +7 -0
  54. package/lib/src/ag-grid/hooks/use-pinned-row.js +1 -0
  55. package/lib/src/ag-grid/hooks/use-virtual-config.d.ts +5 -0
  56. package/lib/src/ag-grid/hooks/use-virtual-config.js +1 -0
  57. package/lib/src/ag-grid/index.vue.js +1 -1
  58. package/lib/src/ag-grid/interface.d.ts +25 -2
  59. package/lib/src/ap-field/select/index.vue.d.ts +51 -21
  60. package/lib/src/ap-field/select/index.vue.js +1 -1
  61. package/lib/src/ap-field/select/read.vue2.js +1 -1
  62. package/lib/src/ap-field/tree-select/index.vue.d.ts +29 -21
  63. package/lib/src/ap-field/tree-select/index.vue.js +1 -1
  64. package/lib/src/ap-field/tree-select/read.vue2.js +1 -1
  65. package/lib/src/ap-form/ap-form.vue.d.ts +20 -0
  66. package/lib/src/ap-form/ap-form.vue2.js +1 -1
  67. package/lib/src/ap-form/drawer-form/index.vue.d.ts +22 -0
  68. package/lib/src/ap-form/drawer-form/index.vue.js +1 -1
  69. package/lib/src/ap-form/hooks/use-watch.js +1 -1
  70. package/lib/src/ap-form/interface.d.ts +1 -1
  71. package/lib/src/ap-form/items/select/index.vue.d.ts +64 -28
  72. package/lib/src/ap-form/items/tree-select/index.vue.d.ts +40 -28
  73. package/lib/src/ap-form/modal-form/index.vue.d.ts +22 -0
  74. package/lib/src/ap-form/modal-form/index.vue.js +1 -1
  75. package/lib/src/ap-form/search-form/index.vue.d.ts +24 -2
  76. package/lib/src/ap-form/search-form/index.vue.js +1 -1
  77. package/lib/src/ap-table/constants.d.ts +52 -28
  78. package/lib/src/ap-upload/apUpload.vue.d.ts +9 -0
  79. package/lib/src/ap-upload/apUpload.vue.js +1 -1
  80. package/lib/src/ap-upload/components/MultipleFile.vue2.js +1 -1
  81. package/lib/src/ap-upload/components/Picture.vue2.js +1 -1
  82. package/lib/src/ap-upload/components/SingleFile.vue2.js +1 -1
  83. package/lib/src/business/ap-value-select-card/index.vue2.js +1 -1
  84. package/lib/src/business/ap-view/components/main-button-content.vue.d.ts +11 -0
  85. package/lib/src/business/ap-view/components/menu-list-content.vue.d.ts +11 -0
  86. package/lib/src/business/hooks/usePageListAgGrid.d.ts +1 -1
  87. package/lib/src/business/hooks/usePageListAgGrid.js +1 -1
  88. package/lib/src/business/hooks/usePageListApGrid.js +1 -1
  89. package/lib/src/config-provider/config-provider-props.d.ts +14 -1
  90. package/lib/src/config-provider/config-provider.d.ts +31 -1
  91. package/lib/src/config-provider/hooks/use-global-config.d.ts +14 -1
  92. package/lib/src/config-provider/index.d.ts +52 -1
  93. package/lib/src/utils/config-provider-preset.d.ts +11 -1
  94. package/lib/src/version.d.ts +1 -1
  95. package/lib/src/version.js +1 -1
  96. package/lib/src/work-order-modal/work-order-modal.vue.d.ts +11 -0
  97. package/package.json +3 -3
  98. package/theme/ap-pro-card/index.css +5 -5
  99. package/theme/ap-pro-card/index.less +5 -5
  100. package/theme/ap-value-select-card/index.css +3 -4
  101. package/theme/ap-value-select-card/index.less +3 -4
  102. package/theme/index.css +8 -9
@@ -1,27 +1,29 @@
1
- import { defineComponent as Ke, useSlots as Ae, ref as h, toRef as H, computed as n, unref as t, nextTick as Ne, watch as T, createElementBlock as k, openBlock as w, normalizeStyle as v, normalizeClass as i, createCommentVNode as $, createElementVNode as S, createVNode as D, mergeProps as j, createSlots as Ve, withCtx as q, Fragment as Ie, renderList as Pe, createBlock as U, resolveDynamicComponent as Ee, renderSlot as J, withDirectives as Me, vShow as We } from "vue";
2
- import { AgGridVue as Le } from "ag-grid-vue3";
3
- import { ModuleRegistry as Oe, AllCommunityModule as Ge } from "ag-grid-community";
4
- import { Spin as He, Pagination as $e } from "@aplus-frontend/antdv";
5
- import { isUndefined as g, isFunction as je } from "lodash-unified";
1
+ import { defineComponent as Oe, useSlots as We, ref as R, toRef as B, unref as r, computed as n, nextTick as je, watch as K, createElementBlock as P, openBlock as h, normalizeStyle as E, normalizeClass as u, createCommentVNode as Q, createElementVNode as v, createVNode as V, mergeProps as I, createSlots as Le, withCtx as X, Fragment as Ge, renderList as He, createBlock as Y, resolveDynamicComponent as Ue, renderSlot as Z, withDirectives as $e, vShow as qe } from "vue";
2
+ import { AgGridVue as Je } from "ag-grid-vue3";
3
+ import { ModuleRegistry as Qe, AllCommunityModule as Xe } from "ag-grid-community";
4
+ import { Spin as Ye, Pagination as Ze } from "@aplus-frontend/antdv";
5
+ import { isUndefined as C, isFunction as _e } from "lodash-unified";
6
6
  import "../config-provider/index.mjs";
7
- import { ApForm as qe } from "../ap-form/index.mjs";
8
- import { recursionApColumns as Ue } from "../ap-table/utils.mjs";
9
- import { useTablePaging as Je } from "../ap-table/hooks/use-table-paging-ng.mjs";
10
- import Qe from "./hooks/use-row-selection.mjs";
11
- import { useProvideSorter as Xe } from "./context.mjs";
12
- import { useProvideApTable as Ye } from "../ap-table/context.mjs";
13
- import { sizeReverseMap as Ze, sizeMap as _e } from "../ap-grid/constants.mjs";
14
- import { useToken as eo } from "@aplus-frontend/antdv/es/theme/internal";
15
- import { useTheme as oo } from "./theme.mjs";
16
- import { useColumns as to } from "./hooks/use-columns.mjs";
17
- import { useColumnsDef as ro } from "./hooks/use-columns-def.mjs";
18
- import { isDef as ao } from "../utils/index.mjs";
19
- import { getValidVNodeList as no } from "../utils/slot.mjs";
20
- import { useSearchForm as lo } from "./hooks/use-search-form.mjs";
7
+ import { ApForm as eo } from "../ap-form/index.mjs";
8
+ import { recursionApColumns as oo } from "../ap-table/utils.mjs";
9
+ import { useTablePaging as to } from "../ap-table/hooks/use-table-paging-ng.mjs";
10
+ import ro from "./hooks/use-row-selection.mjs";
11
+ import { useProvideSorter as ao } from "./context.mjs";
12
+ import { useProvideApTable as no } from "../ap-table/context.mjs";
13
+ import { sizeReverseMap as lo, sizeMap as so } from "../ap-grid/constants.mjs";
14
+ import { useToken as io } from "@aplus-frontend/antdv/es/theme/internal";
15
+ import { useTheme as co } from "./theme.mjs";
16
+ import { useColumns as uo } from "./hooks/use-columns.mjs";
17
+ import { useColumnsDef as mo } from "./hooks/use-columns-def.mjs";
18
+ import { isDef as po } from "../utils/index.mjs";
19
+ import { getValidVNodeList as fo } from "../utils/slot.mjs";
20
+ import { useSearchForm as So } from "./hooks/use-search-form.mjs";
21
21
  import "./components/empty/index.vue.mjs";
22
- import { useNamespace as so } from "../config-provider/hooks/use-namespace.mjs";
23
- import io from "./components/empty/index.vue2.mjs";
24
- const No = /* @__PURE__ */ Ke({
22
+ import go from "./hooks/use-virtual-config.mjs";
23
+ import { usePinnedRow as wo } from "./hooks/use-pinned-row.mjs";
24
+ import { useNamespace as yo } from "../config-provider/hooks/use-namespace.mjs";
25
+ import ho from "./components/empty/index.vue2.mjs";
26
+ const Uo = /* @__PURE__ */ Oe({
25
27
  name: "AgGrid",
26
28
  __name: "index",
27
29
  props: {
@@ -85,340 +87,380 @@ const No = /* @__PURE__ */ Ke({
85
87
  summary: {},
86
88
  rowHeight: {},
87
89
  advanceRenderer: { type: Boolean },
88
- browserTooltips: { type: Boolean }
90
+ browserTooltips: { type: Boolean },
91
+ virtual: { type: [Boolean, Object], default: void 0 },
92
+ onRowClicked: {},
93
+ onScrollEnd: {}
89
94
  },
90
- setup(Q, { expose: X }) {
91
- Oe.registerModules([Ge]);
92
- const o = Q, z = Ae(), { e: y, b: l, be: Y } = so("ag-grid"), m = h(o.size), Z = oo(m, H(o, "rowHeight")), p = h(), [, _] = eo();
93
- let d = !!o.dataSource;
94
- const K = lo(o), { shownColumns: s, shownColumnsBackup: ee } = to(o), { defaultColDef: oe, columnDefs: te } = ro(
95
- s,
96
- o
97
- ), A = h({});
98
- Xe({
99
- sorter: A,
95
+ setup(_, { expose: ee }) {
96
+ Qe.registerModules([Xe]);
97
+ const o = _, A = We();
98
+ function oe(...e) {
99
+ return e.reduce((t, a) => ({ ...t, ...a }), {});
100
+ }
101
+ const { e: b, b: i, be: te } = yo("ag-grid"), y = R(o.size), re = co(y, B(o, "rowHeight")), ae = go(B(o, "virtual")), { rowPinnedGridConfig: ne, getRowPinnedCellClass: le } = wo(
102
+ B(o, "summary")
103
+ ), d = R(), [, se] = io();
104
+ let m = !!o.dataSource;
105
+ const N = So(o), { shownColumns: p, columns: M } = uo(o), { defaultColDef: ie, columnDefs: de } = mo(
106
+ M,
107
+ o,
108
+ le
109
+ ), F = R({});
110
+ ao({
111
+ sorter: F,
100
112
  setSorter(e) {
101
- A.value = e;
113
+ F.value = e;
102
114
  }
103
115
  });
104
- const re = {
116
+ const ce = {
105
117
  asc: "ascend",
106
118
  desc: "descend"
107
119
  };
108
- function ae() {
109
- const e = p.value.getColumns()?.filter((x) => x.getSort() !== void 0);
110
- if (!e?.length)
120
+ function ue() {
121
+ const e = d.value.getColumns()?.filter((s) => s.getSort() !== void 0), t = r(F) || {};
122
+ let a = e?.[0];
123
+ const c = Object.keys(t);
124
+ if (c.length && c.every((s) => t[s] === null)) {
125
+ const s = Object.keys(t)[0];
126
+ s && (a = d.value?.getColumn(s));
127
+ }
128
+ if (!a)
111
129
  return;
112
- const r = e[0], a = r.getColDef(), f = r.getSort();
113
- V(void 0, void 0, {
114
- column: a,
115
- field: a.field,
116
- order: f ? re[f] : null
130
+ const w = a.getColDef(), l = a.getSort();
131
+ W(void 0, void 0, {
132
+ column: w,
133
+ field: w.field,
134
+ order: l ? ce[l] : null
117
135
  });
118
136
  }
119
- const ne = n(() => Ue(t(s), (e) => {
137
+ const me = n(() => oo(r(p), (e) => {
120
138
  if (e.sorter === !0)
121
139
  return e.key || e.dataIndex;
122
- }).filter(Boolean)), le = n(() => ao(o.manual) ? o.manual : no(z.searchFormExtra?.() || []).some((r) => r.type?.name === "ApView")), {
123
- formRef: c,
124
- submit: b,
125
- reset: C,
126
- data: u,
127
- tableProps: N,
128
- handleTableChangeOptional: V,
129
- submitWith: I,
130
- refresh: P,
131
- getPaging: se,
132
- setPaging: ie,
133
- setDataSource: de
134
- } = Je({
140
+ }).filter(Boolean)), pe = n(() => po(o.manual) ? o.manual : fo(A.searchFormExtra?.() || []).some((t) => t.type?.name === "ApView")), {
141
+ formRef: f,
142
+ submit: x,
143
+ reset: k,
144
+ data: S,
145
+ tableProps: O,
146
+ handleTableChangeOptional: W,
147
+ submitWith: j,
148
+ refresh: L,
149
+ getPaging: fe,
150
+ setPaging: Se,
151
+ setDataSource: ge
152
+ } = to({
135
153
  async request(e) {
136
- if (d = !1, !ue.value && g(o.dataSource) && B(), !g(o.dataSource)) {
154
+ if (m = !1, !ye.value && C(o.dataSource) && z(), !C(o.dataSource)) {
137
155
  const a = e.pageSize * (e.current - 1);
138
156
  return {
139
157
  data: (o.pagination === !1 ? o.dataSource : o.dataSource.slice(a, a + e.pageSize)) || [],
140
158
  total: o.dataSource.length || 0
141
159
  };
142
160
  }
143
- const r = await o.request?.(e);
161
+ const t = await o.request?.(e);
144
162
  return {
145
- data: r?.data || [],
146
- total: r?.total || 0
163
+ data: t?.data || [],
164
+ total: t?.total || 0
147
165
  };
148
166
  },
149
167
  namespace: "ap-grid",
150
- filterFields: h([]),
151
- params: H(o, "params"),
168
+ filterFields: R([]),
169
+ params: B(o, "params"),
152
170
  defaultData: o.defaultData,
153
- manual: t(le),
171
+ manual: r(pe),
154
172
  formatParams: o.beforeSearchSubmit,
155
173
  pagination: o.pagination,
156
- sortFields: ne
157
- }), ce = n(
158
- () => g(o.dataSource) ? u.records : o.dataSource
159
- ), ue = n(() => {
174
+ sortFields: me
175
+ }), we = n(
176
+ () => C(o.dataSource) ? S.records : o.dataSource
177
+ ), ye = n(() => {
160
178
  const e = o.rowSelection === !0 ? {} : o.rowSelection;
161
179
  return e ? e.preserveSelectedRowKeys !== !1 : !1;
162
180
  }), {
163
- select: me,
164
- unSelect: pe,
165
- selectedRows: R,
166
- selectedRowKeys: fe,
167
- clearAll: we,
168
- selectMultiByKeys: Se
169
- } = Qe({
181
+ select: he,
182
+ unSelect: ve,
183
+ selectedRows: T,
184
+ selectedRowKeys: Ce,
185
+ clearAll: be,
186
+ selectMultiByKeys: Re
187
+ } = ro({
170
188
  ...o.rowSelection === !0 ? {} : o.rowSelection,
171
- dataSource: ce,
189
+ dataSource: we,
172
190
  rowKey: o.rowKey
173
- }), ge = {
191
+ }), Be = {
174
192
  checkbox: "multiRow",
175
193
  radio: "singleRow"
176
- }, ye = n(() => {
194
+ }, Fe = n(() => {
177
195
  if (!o.rowSelection)
178
196
  return;
179
- const { type: e = "checkbox", disabled: r } = o.rowSelection === !0 ? {} : o.rowSelection;
197
+ const { type: e = "checkbox", disabled: t } = o.rowSelection === !0 ? {} : o.rowSelection;
180
198
  return {
181
- mode: ge[e],
182
- isRowSelectable: (a) => r ? !r(a.data) : !0
199
+ mode: Be[e],
200
+ isRowSelectable: (a) => t ? !t(a.data) : !0
183
201
  };
184
- }), he = n(() => {
202
+ }), xe = n(() => {
185
203
  if (!o.rowSelection)
186
204
  return;
187
205
  const e = o.rowSelection === !0 ? {} : o.rowSelection;
188
- let r = e.fixed;
189
- return r === void 0 && (r = s.value.some(
206
+ let t = e.fixed;
207
+ return t === void 0 && (t = p.value.some(
190
208
  (a) => a.fixed === "left" || a.fixed === !0
191
209
  ) ? "left" : void 0), {
192
210
  sortable: !1,
193
211
  resizable: !1,
194
212
  width: e.columnWidth || 60,
195
- pinned: r
213
+ pinned: t
196
214
  };
197
215
  });
198
- function F(e) {
199
- return je(o.rowKey) ? o.rowKey(e) : e[o.rowKey];
216
+ function D(e) {
217
+ return _e(o.rowKey) ? o.rowKey(e) : e[o.rowKey];
200
218
  }
201
- const E = ({
202
- api: e = p.value
219
+ const G = ({
220
+ api: e = d.value
203
221
  }) => {
204
222
  if (!o.rowSelection)
205
223
  return;
206
- const r = R.value;
207
- if (!r.length) {
224
+ const t = T.value;
225
+ if (!t.length) {
208
226
  setTimeout(() => {
209
- d = !0;
227
+ m = !0;
210
228
  }, 0);
211
229
  return;
212
230
  }
213
- d = !1;
231
+ m = !1;
214
232
  const a = [];
215
- e.forEachNode((f) => {
216
- const x = f.data, De = F(x);
217
- r.find((ze) => F(ze) === De) && a.push(f);
233
+ e.forEachNode((c) => {
234
+ const g = c.data, w = D(g);
235
+ t.find((l) => D(l) === w) && a.push(c);
218
236
  }), e.setNodesSelected({ nodes: a, newValue: !0 }), setTimeout(() => {
219
- d = !0;
237
+ m = !0;
220
238
  }, 0);
221
- }, ve = (e) => {
222
- d && (e.node.isSelected() ? me(e.data) : pe(e.data));
223
- }, be = () => {
224
- d = !0;
225
- }, B = () => {
226
- we(), p.value?.deselectAll();
239
+ }, ke = (e) => {
240
+ m && (e.node.isSelected() ? he(e.data) : ve(e.data));
241
+ }, Te = () => {
242
+ m = !0;
243
+ }, z = () => {
244
+ be(), d.value?.deselectAll();
227
245
  };
228
- function Ce(e) {
229
- Se(e), Ne(() => {
230
- E({});
246
+ function De(e) {
247
+ Re(e), je(() => {
248
+ G({});
231
249
  });
232
250
  }
233
- function M(e = !1) {
234
- const r = e ? "getFieldsValueTransformed" : "getFieldsValue";
235
- return c.value?.apForm?.[r]?.(!0);
251
+ function H(e = !1) {
252
+ const t = e ? "getFieldsValueTransformed" : "getFieldsValue";
253
+ return f.value?.apForm?.[t]?.(!0);
236
254
  }
237
- function W(e) {
238
- c.value?.apForm?.setFieldsValue?.(e);
255
+ function U(e) {
256
+ f.value?.apForm?.setFieldsValue?.(e);
239
257
  }
240
- function L() {
241
- return c.value?.getSorterItems() || [];
258
+ function $() {
259
+ return f.value?.getSorterItems() || [];
242
260
  }
243
- function O(e) {
244
- c.value?.setSorterItems(e);
261
+ function q(e) {
262
+ f.value?.setSorterItems(e);
245
263
  }
246
- function G() {
247
- c.value?.resetSorterItems();
264
+ function J() {
265
+ f.value?.resetSorterItems();
248
266
  }
249
- Ye({
250
- columns: n(() => s.value),
251
- columnsBackup: n(() => ee.value),
252
- size: n(() => _e[m.value]),
267
+ function ze(e) {
268
+ const t = d.value;
269
+ if (!t)
270
+ return;
271
+ const a = t.getColumnState() || [], c = e.map((l) => l.key ? String(l.key) : l.key).filter(Boolean);
272
+ let g = !1;
273
+ const w = a.map((l) => {
274
+ const s = !c.includes(l.colId);
275
+ return !g && s !== l.hide && (g = !0), {
276
+ ...l,
277
+ hide: s
278
+ };
279
+ });
280
+ g && t.applyColumnState({
281
+ state: w,
282
+ applyOrder: !0
283
+ });
284
+ }
285
+ no({
286
+ columns: n(() => p.value),
287
+ columnsBackup: n(() => M.value),
288
+ size: n(() => so[y.value]),
253
289
  updateColumns(e) {
254
- s.value = e, o.onShownColumnsChange?.(e);
290
+ p.value = e, o.onShownColumnsChange?.(e), ze(e);
255
291
  },
256
292
  updateSize(e) {
257
- m.value = Ze[e];
293
+ y.value = lo[e];
258
294
  },
259
295
  renderConfig: n(() => ({
260
- className: Y("table-header", "title"),
261
- color: _.value.colorTextTertiary
296
+ className: te("table-header", "title"),
297
+ color: se.value.colorTextTertiary
262
298
  })),
263
- dataSource: n(() => t(u).records),
264
- getSearchFormValues: M,
265
- setSearchFormValues: W,
266
- submit: b,
267
- submitWith: I,
268
- reset: C,
269
- refresh: P,
270
- getSearchFormSorterItems: L,
271
- setSearchFormSorterItems: O,
272
- resetSearchFormSorterItems: G
299
+ dataSource: n(() => r(S).records),
300
+ getSearchFormValues: H,
301
+ setSearchFormValues: U,
302
+ submit: x,
303
+ submitWith: j,
304
+ reset: k,
305
+ refresh: L,
306
+ getSearchFormSorterItems: $,
307
+ setSearchFormSorterItems: q,
308
+ resetSearchFormSorterItems: J
273
309
  });
274
- const Re = n(
275
- () => g(o.loading) ? u.loading : o.loading
276
- ), Fe = n(() => [
277
- l(),
278
- o.card ? null : l("wrapper"),
279
- l("adaptive"),
280
- l(`size-${m.value}`)
281
- ].filter(Boolean)), Be = n(() => ({
310
+ const Ke = n(
311
+ () => C(o.loading) ? S.loading : o.loading
312
+ ), Pe = n(() => [
313
+ i(),
314
+ o.card ? null : i("wrapper"),
315
+ i("adaptive"),
316
+ i(`size-${y.value}`)
317
+ ].filter(Boolean)), Ee = n(() => ({
282
318
  height: "100%",
283
319
  ...o.tableStyle || {}
284
- })), xe = (e, r) => {
285
- V({ current: e, pageSize: r });
320
+ })), Ve = (e, t) => {
321
+ W({ current: e, pageSize: t });
286
322
  };
287
- function Te(e) {
288
- const r = e.data;
289
- return F(r);
323
+ function Ie(e) {
324
+ const t = e.data;
325
+ return D(t);
326
+ }
327
+ function Ae(e, t) {
328
+ d.value?.ensureIndexVisible(e, t);
329
+ }
330
+ function Ne(e) {
331
+ o.onRowClicked?.(e.data);
290
332
  }
291
- function ke(e, r) {
292
- p.value?.ensureIndexVisible(e, r);
333
+ function Me(e) {
334
+ o.onScrollEnd?.(e.direction);
293
335
  }
294
- return T(
336
+ return K(
295
337
  () => o.dataSource,
296
338
  (e) => {
297
- de(e);
339
+ ge(e);
298
340
  },
299
341
  { immediate: !0, deep: !0 }
300
- ), T(
342
+ ), K(
301
343
  () => o.size,
302
344
  (e) => {
303
- m.value = e;
345
+ y.value = e;
304
346
  }
305
- ), T(
306
- () => t(u).loading,
347
+ ), K(
348
+ () => r(S).loading,
307
349
  (e) => {
308
350
  o.onLoadingChange?.(e);
309
351
  }
310
- ), X({
311
- submit: b,
312
- reset: C,
313
- refresh: P,
314
- submitWith: I,
315
- setSearchFormValues: W,
316
- getSearchFormValues: M,
317
- getShowColumns: () => t(s),
352
+ ), ee({
353
+ submit: x,
354
+ reset: k,
355
+ refresh: L,
356
+ submitWith: j,
357
+ setSearchFormValues: U,
358
+ getSearchFormValues: H,
359
+ getShowColumns: () => r(p),
318
360
  rowSelection: {
319
- selectedRows: n(() => R.value),
320
- setSelectedRowKeys: Ce,
321
- clearAll: B
361
+ selectedRows: n(() => T.value),
362
+ setSelectedRowKeys: De,
363
+ clearAll: z
322
364
  },
323
- scrollToRow: ke,
324
- getDataSource: () => t(u.records),
325
- getPaging: se,
326
- setPaging: ie,
327
- getSearchFormSorterItems: L,
328
- setSearchFormSorterItems: O,
329
- resetSearchFormSorterItems: G
330
- }), (e, r) => (w(), k("div", {
331
- class: i(Fe.value),
332
- style: v(e.wrapperStyle)
365
+ scrollToRow: Ae,
366
+ getDataSource: () => r(S.records),
367
+ getPaging: fe,
368
+ setPaging: Se,
369
+ getSearchFormSorterItems: $,
370
+ setSearchFormSorterItems: q,
371
+ resetSearchFormSorterItems: J
372
+ }), (e, t) => (h(), P("div", {
373
+ class: u(Pe.value),
374
+ style: E(e.wrapperStyle)
333
375
  }, [
334
- t(g)(e.dataSource) && e.searchForm !== !1 && t(K).length > 0 ? (w(), k("div", {
376
+ r(C)(e.dataSource) && e.searchForm !== !1 && r(N).length > 0 ? (h(), P("div", {
335
377
  key: 0,
336
- class: i(e.card ? t(y)("search-wrapper") : null),
337
- style: v(e.searchFormWrapperStyle)
378
+ class: u(e.card ? r(b)("search-wrapper") : null),
379
+ style: E(e.searchFormWrapperStyle)
338
380
  }, [
339
- D(t(qe).SearchForm, j(e.searchForm || {}, {
381
+ V(r(eo).SearchForm, I(e.searchForm || {}, {
340
382
  ref_key: "formRef",
341
- ref: c,
383
+ ref: f,
342
384
  "custom-reset": "",
343
- "submit-loading": t(N).loading,
344
- onSubmit: t(b),
345
- onReset: t(C)
346
- }), Ve({
347
- default: q(() => [
348
- (w(!0), k(Ie, null, Pe(t(K), (a) => (w(), U(Ee(a.renderNode), {
385
+ "submit-loading": r(O).loading,
386
+ onSubmit: r(x),
387
+ onReset: r(k)
388
+ }), Le({
389
+ default: X(() => [
390
+ (h(!0), P(Ge, null, He(r(N), (a) => (h(), Y(Ue(a.renderNode), {
349
391
  key: a.dataIndex
350
392
  }))), 128))
351
393
  ]),
352
394
  _: 2
353
395
  }, [
354
- z.searchFormExtra ? {
396
+ A.searchFormExtra ? {
355
397
  name: "extra",
356
- fn: q(() => [
357
- J(e.$slots, "searchFormExtra")
398
+ fn: X(() => [
399
+ Z(e.$slots, "searchFormExtra")
358
400
  ]),
359
401
  key: "0"
360
402
  } : void 0
361
403
  ]), 1040, ["submit-loading", "onSubmit", "onReset"])
362
- ], 6)) : $("", !0),
363
- S("div", {
364
- class: i([t(y)("table-wrapper"), e.card ? t(y)("table-wrapper-card") : null]),
365
- style: v(e.tableWrapperStyle)
404
+ ], 6)) : Q("", !0),
405
+ v("div", {
406
+ class: u([r(b)("table-wrapper"), e.card ? r(b)("table-wrapper-card") : null]),
407
+ style: E(e.tableWrapperStyle)
366
408
  }, [
367
- S("div", {
368
- class: i(t(l)("header-wrapper"))
409
+ v("div", {
410
+ class: u(r(i)("header-wrapper"))
369
411
  }, [
370
- J(e.$slots, "title", {
371
- selectedRows: t(R),
372
- selectedRowKeys: t(fe),
373
- shownColumns: t(s),
374
- clearAll: B
412
+ Z(e.$slots, "title", {
413
+ selectedRows: r(T),
414
+ selectedRowKeys: r(Ce),
415
+ shownColumns: r(p),
416
+ clearAll: z
375
417
  })
376
418
  ], 2),
377
- S("div", {
378
- class: i(t(l)("grid-wrapper"))
419
+ v("div", {
420
+ class: u(r(i)("grid-wrapper"))
379
421
  }, [
380
- D(t(Le), {
381
- style: v(Be.value),
382
- "row-data": t(u).records,
383
- "column-defs": t(te),
384
- "default-col-def": t(oe),
422
+ V(r(Je), I(oe(r(ae), r(ne)), {
423
+ style: Ee.value,
424
+ "row-data": r(S).records,
425
+ "column-defs": r(de),
426
+ "default-col-def": r(ie),
385
427
  "suppress-loading-overlay": "",
386
- "row-selection": ye.value,
387
- "selection-column-def": he.value,
388
- "get-row-id": Te,
389
- "pinned-top-row-data": e.summary?.top,
390
- "pinned-bottom-row-data": e.summary?.bottom,
391
- theme: t(Z),
428
+ "row-selection": Fe.value,
429
+ "selection-column-def": xe.value,
430
+ "get-row-id": Ie,
431
+ theme: r(re),
392
432
  "tooltip-show-delay": 500,
393
433
  "enable-browser-tooltips": e.browserTooltips,
394
434
  "tooltip-interaction": "",
395
- "no-rows-overlay-component": io,
396
- onSortChanged: ae,
397
- onGridReady: r[0] || (r[0] = (a) => p.value = a.api),
398
- onRowDataUpdated: E,
399
- onRowSelected: ve,
400
- onFirstDataRendered: be
401
- }, null, 8, ["style", "row-data", "column-defs", "default-col-def", "row-selection", "selection-column-def", "pinned-top-row-data", "pinned-bottom-row-data", "theme", "enable-browser-tooltips"]),
402
- Me(S("div", {
403
- class: i(t(y)("table-loading-wrapper"))
435
+ "no-rows-overlay-component": ho,
436
+ onSortChanged: ue,
437
+ onGridReady: t[0] || (t[0] = (a) => d.value = a.api),
438
+ onRowDataUpdated: G,
439
+ onRowSelected: ke,
440
+ onFirstDataRendered: Te,
441
+ onRowClicked: Ne,
442
+ onBodyScrollEnd: Me
443
+ }), null, 16, ["style", "row-data", "column-defs", "default-col-def", "row-selection", "selection-column-def", "theme", "enable-browser-tooltips"]),
444
+ $e(v("div", {
445
+ class: u(r(b)("table-loading-wrapper"))
404
446
  }, [
405
- D(t(He), { delay: 300 })
447
+ V(r(Ye), { delay: 300 })
406
448
  ], 2), [
407
- [We, Re.value]
449
+ [qe, Ke.value]
408
450
  ])
409
451
  ], 2),
410
- S("div", {
411
- class: i(t(l)("pagination-wrapper"))
452
+ v("div", {
453
+ class: u(r(i)("pagination-wrapper"))
412
454
  }, [
413
- e.pagination !== !1 ? (w(), U(t($e), j({
455
+ e.pagination !== !1 ? (h(), Y(r(Ze), I({
414
456
  key: 0,
415
- class: t(l)("pagination")
416
- }, t(N).pagination, { onChange: xe }), null, 16, ["class"])) : $("", !0)
457
+ class: r(i)("pagination")
458
+ }, r(O).pagination, { onChange: Ve }), null, 16, ["class"])) : Q("", !0)
417
459
  ], 2)
418
460
  ], 6)
419
461
  ], 6));
420
462
  }
421
463
  });
422
464
  export {
423
- No as default
465
+ Uo as default
424
466
  };