@aplus-frontend/ui 0.4.22 → 0.4.24

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 (30) hide show
  1. package/es/src/ap-table/ap-table.vue.d.ts +4 -2
  2. package/es/src/ap-table/ap-table.vue2.mjs +147 -135
  3. package/es/src/ap-table/interface.d.ts +5 -4
  4. package/es/src/business/ap-table-modal/hooks/use-create-table-modal.d.ts +5 -4
  5. package/es/src/business/ap-table-modal/hooks/use-table-modal.d.ts +5 -4
  6. package/es/src/business/ap-table-modal/hooks/use-table-select-modal.d.ts +5 -4
  7. package/es/src/business/ap-table-modal/index.d.ts +19 -9
  8. package/es/src/business/ap-table-modal/table-modal.vue.d.ts +9 -5
  9. package/es/src/business/hooks/usePageListApTable.d.ts +5 -4
  10. package/es/src/business/hooks/useTableRefresh.mjs +27 -30
  11. package/es/src/scroll-bar/index.vue.d.ts +2 -1
  12. package/es/src/scroll-bar/index.vue.mjs +38 -41
  13. package/es/src/scroll-bar/internal.vue.mjs +10 -11
  14. package/es/src/utils/index.d.ts +0 -8
  15. package/index.ts +19 -0
  16. package/lib/src/ap-table/ap-table.vue.d.ts +4 -2
  17. package/lib/src/ap-table/ap-table.vue2.js +1 -1
  18. package/lib/src/ap-table/interface.d.ts +5 -4
  19. package/lib/src/business/ap-table-modal/hooks/use-create-table-modal.d.ts +5 -4
  20. package/lib/src/business/ap-table-modal/hooks/use-table-modal.d.ts +5 -4
  21. package/lib/src/business/ap-table-modal/hooks/use-table-select-modal.d.ts +5 -4
  22. package/lib/src/business/ap-table-modal/index.d.ts +19 -9
  23. package/lib/src/business/ap-table-modal/table-modal.vue.d.ts +9 -5
  24. package/lib/src/business/hooks/usePageListApTable.d.ts +5 -4
  25. package/lib/src/business/hooks/useTableRefresh.js +1 -1
  26. package/lib/src/scroll-bar/index.vue.d.ts +2 -1
  27. package/lib/src/scroll-bar/index.vue.js +1 -1
  28. package/lib/src/scroll-bar/internal.vue.js +1 -1
  29. package/lib/src/utils/index.d.ts +0 -8
  30. package/package.json +1 -1
@@ -2,7 +2,6 @@ import { ApColumnType, ApTableProps } from './interface';
2
2
  import { ColumnsType, ColumnType } from '@aplus-frontend/antdv/es/table';
3
3
  import { RowSelectionReturnType } from './hooks/use-table-row-selection';
4
4
  import { VNodeProps, AllowedComponentProps, ComponentCustomProps, PublicProps, ShallowUnwrapRef, ComputedRef, Ref, VNode, RendererNode, RendererElement } from 'vue';
5
- import { ScrollBarExpose } from '../scroll-bar';
6
5
  declare const _default: <RecordType>(__VLS_props: NonNullable<Awaited<typeof __VLS_setup>>["props"], __VLS_ctx?: __VLS_PrettifyLocal<Pick<NonNullable<Awaited<typeof __VLS_setup>>, "attrs" | "emit" | "slots">>, __VLS_expose?: NonNullable<Awaited<typeof __VLS_setup>>["expose"], __VLS_setup?: Promise<{
7
6
  props: __VLS_PrettifyLocal<Pick<Partial<{}> & Omit<{} & VNodeProps & AllowedComponentProps & ComponentCustomProps, never>, never> & ApTableProps<RecordType> & Partial<{}>> & PublicProps;
8
7
  expose(exposed: ShallowUnwrapRef<{
@@ -24,7 +23,10 @@ declare const _default: <RecordType>(__VLS_props: NonNullable<Awaited<typeof __V
24
23
  selectedRows: ComputedRef<RecordType[]>;
25
24
  };
26
25
  scrollBar: {
27
- x: Ref< ScrollBarExpose | undefined, ScrollBarExpose | undefined>;
26
+ x: {
27
+ getCurrentScroll: () => 0 | Ref<number, number>;
28
+ scroll: (percent: number) => void | undefined;
29
+ };
28
30
  y: undefined;
29
31
  };
30
32
  }>): void;
@@ -1,11 +1,11 @@
1
- import { defineComponent as ze, useSlots as Pe, ref as S, computed as s, unref as t, createVNode as f, Fragment as J, watchEffect as Ne, watch as Q, openBlock as p, createElementBlock as F, normalizeClass as m, normalizeStyle as X, mergeProps as h, createSlots as Y, withCtx as w, renderList as Z, createBlock as ee, resolveDynamicComponent as Ie, renderSlot as R, createCommentVNode as oe, createElementVNode as N, normalizeProps as Ee, guardReactiveProps as Ke } from "vue";
1
+ import { defineComponent as ze, useSlots as Pe, ref as h, computed as s, unref as l, createVNode as p, Fragment as J, watchEffect as Ne, watch as Q, openBlock as m, createElementBlock as k, normalizeClass as y, normalizeStyle as X, mergeProps as w, createSlots as Y, withCtx as v, renderList as Z, createBlock as ee, resolveDynamicComponent as Ie, renderSlot as R, createCommentVNode as oe, createElementVNode as I, normalizeProps as Ee, guardReactiveProps as Ke } from "vue";
2
2
  import { Divider as Oe, Table as Le } from "@aplus-frontend/antdv";
3
3
  import { useToken as Ve } from "@aplus-frontend/antdv/es/theme/internal";
4
4
  import { ApForm as Ae } from "../ap-form/index.mjs";
5
5
  import { noRenderAsFormItemValueList as ae } from "./constants.mjs";
6
6
  import "../config-provider/index.mjs";
7
7
  import { useTablePaging as De } from "./hooks/use-table-paging-ng.mjs";
8
- import { isUndefined as y, omit as re, isBoolean as $e } from "lodash-unified";
8
+ import { isUndefined as g, omit as re, isBoolean as $e } from "lodash-unified";
9
9
  import { getColumnOrder as te, updateFormProps as We, getFieldProps as je, getSearchFormItemRenderNode as _e, recursionApColumns as le, apColumnToColumn as He, getTableTitle as Ue, getTableRenderType as qe, getTableRenderProps as Me, getTableCellRenderNode as Ge, falseToUndefined as Je } from "./utils.mjs";
10
10
  import Qe from "./hooks/use-table-content-height.mjs";
11
11
  import Xe from "./hooks/use-table-row-selection.mjs";
@@ -149,85 +149,85 @@ const No = /* @__PURE__ */ ze({
149
149
  expose: se
150
150
  }) {
151
151
  const o = ne;
152
- let I = 0;
152
+ let E = 0;
153
153
  const C = Pe(), [, de] = Ve(), {
154
- e: x,
155
- b: i,
156
- be: E,
154
+ e: B,
155
+ b: c,
156
+ be: K,
157
157
  m: ue
158
- } = ao("ap-table"), K = ro("valueTypeMap"), {
158
+ } = ao("ap-table"), O = ro("valueTypeMap"), {
159
159
  height: ie,
160
160
  contentRef: ce
161
- } = Qe(), O = S(), L = S(), {
162
- isStickyMode: V,
163
- scrollBarRef: A
164
- } = eo(O), k = S(o.size), u = S([]), D = S([]);
161
+ } = Qe(), L = h(), V = h(), {
162
+ isStickyMode: A,
163
+ scrollBarRef: i
164
+ } = eo(L), z = h(o.size), u = h([]), D = h([]);
165
165
  Ze({
166
166
  columns: s(() => u.value),
167
167
  columnsBackup: s(() => D.value),
168
- size: s(() => k.value),
168
+ size: s(() => z.value),
169
169
  updateColumns(e) {
170
170
  u.value = e;
171
171
  },
172
172
  updateSize(e) {
173
- k.value = e;
173
+ z.value = e;
174
174
  },
175
- dataSource: s(() => t(g).records)
175
+ dataSource: s(() => l(b).records)
176
176
  });
177
177
  const $ = s(() => {
178
- var e, l, a;
179
- return I++, ((a = (l = (e = o.columns) == null ? void 0 : e.filter((r) => !r.hideInSearch && r.dataIndex && (r.valueType || r.customRenderFormItem) && !ae.includes(r.valueType))) == null ? void 0 : l.sort((r, d) => {
180
- let n = te(r.order);
178
+ var e, r, a;
179
+ return E++, ((a = (r = (e = o.columns) == null ? void 0 : e.filter((t) => !t.hideInSearch && t.dataIndex && (t.valueType || t.customRenderFormItem) && !ae.includes(t.valueType))) == null ? void 0 : r.sort((t, d) => {
180
+ let n = te(t.order);
181
181
  return te(d.order) - n;
182
- })) == null ? void 0 : a.map((r) => {
183
- const d = We(r, je(r.fieldProps, {})), n = {
184
- ...r,
182
+ })) == null ? void 0 : a.map((t) => {
183
+ const d = We(t, je(t.fieldProps, {})), n = {
184
+ ...t,
185
185
  fieldProps: {
186
- label: r.title,
187
- name: r.dataIndex,
186
+ label: t.title,
187
+ name: t.dataIndex,
188
188
  ...d || {},
189
- _signal: I
189
+ _signal: E
190
190
  },
191
191
  renderNode: void 0
192
192
  };
193
- return n.renderNode = _e(n, t(K)), n;
193
+ return n.renderNode = _e(n, l(O)), n;
194
194
  })) || [];
195
- }), fe = s(() => le(t(u), (e) => {
195
+ }), fe = s(() => le(l(u), (e) => {
196
196
  if (e.sorter === !0)
197
197
  return e.key || e.dataIndex;
198
- }).filter(Boolean)), pe = s(() => le(t(u), (e) => {
198
+ }).filter(Boolean)), pe = s(() => le(l(u), (e) => {
199
199
  if (e.filters && !e.onFilter)
200
200
  return e.key || e.dataIndex;
201
- }).filter(Boolean)), me = s(() => y(o.dataSource) ? g.records : o.dataSource), {
202
- rowSelection: v,
203
- selectedRows: T,
204
- ...B
201
+ }).filter(Boolean)), me = s(() => g(o.dataSource) ? b.records : o.dataSource), {
202
+ rowSelection: T,
203
+ selectedRows: F,
204
+ ...x
205
205
  } = Xe({
206
206
  fixed: !0,
207
207
  ...o.rowSelection === !0 ? {} : o.rowSelection,
208
208
  rowKey: o.rowKey,
209
209
  dataSource: me
210
210
  }), {
211
- formRef: z,
211
+ formRef: P,
212
212
  submit: W,
213
213
  reset: j,
214
214
  tableProps: _,
215
215
  refresh: ye,
216
- data: g,
216
+ data: b,
217
217
  setDataSource: ge,
218
218
  getColumnSFConfig: be
219
219
  } = De({
220
220
  async request(e) {
221
- var a, r;
222
- if (!v.value.preserveSelectedRowKeys && y(o.dataSource) && B.clearAll(), !y(o.dataSource))
221
+ var a, t;
222
+ if (!T.value.preserveSelectedRowKeys && g(o.dataSource) && x.clearAll(), !g(o.dataSource))
223
223
  return {
224
224
  data: o.dataSource || [],
225
225
  total: o.dataSource.length || 0
226
226
  };
227
- const l = await ((a = o.request) == null ? void 0 : a.call(o, e));
228
- return (r = o.onLoad) == null || r.call(o, (l == null ? void 0 : l.data) || []), {
229
- data: (l == null ? void 0 : l.data) || [],
230
- total: (l == null ? void 0 : l.total) || 0
227
+ const r = await ((a = o.request) == null ? void 0 : a.call(o, e));
228
+ return (t = o.onLoad) == null || t.call(o, (r == null ? void 0 : r.data) || []), {
229
+ data: (r == null ? void 0 : r.data) || [],
230
+ total: (r == null ? void 0 : r.total) || 0
231
231
  };
232
232
  },
233
233
  filterFields: pe,
@@ -239,55 +239,55 @@ const No = /* @__PURE__ */ ze({
239
239
  pagination: o.pagination
240
240
  }), Se = () => {
241
241
  var a;
242
- let e = ((a = o.columns) == null ? void 0 : a.filter((r) => !r.hideInTable)) || [];
243
- function l(r, d) {
244
- return r.map((n) => ({
242
+ let e = ((a = o.columns) == null ? void 0 : a.filter((t) => !t.hideInTable)) || [];
243
+ function r(t, d) {
244
+ return t.map((n) => ({
245
245
  resizable: Ye(n.resizable) ? n.resizable : o.columnResizable,
246
246
  ...re(He(n), ["ellipsis"]),
247
247
  ...be(n),
248
248
  fixed: d ? d.fixed : n.fixed,
249
- title: Ue(n, E("table-header", "title"), C.headerCell, t(de).colorPrimary),
249
+ title: Ue(n, K("table-header", "title"), C.headerCell, l(de).colorPrimary),
250
250
  customRender({
251
- value: c,
252
- ...b
251
+ value: f,
252
+ ...S
253
253
  }) {
254
254
  var M, G;
255
- const U = qe(n), Fe = Me({
255
+ const U = qe(n), xe = Me({
256
256
  ...n,
257
257
  valueType: U
258
258
  }, {
259
- value: c,
260
- ...b
261
- }), xe = Ge(U, Fe, b.record, t(K)), q = ((M = n.renderText) == null ? void 0 : M.call(n, {
262
- value: c,
263
- ...b
264
- })) || c, ke = n.renderText ? f(J, null, [(G = n.renderText) == null ? void 0 : G.call(n, {
265
- value: c,
266
- ...b
267
- })]) : xe;
268
- let P = Ce(n, q, ke);
269
- return n.customRender && (P = n.customRender({
270
- value: c,
271
- ...b,
259
+ value: f,
260
+ ...S
261
+ }), ke = Ge(U, xe, S.record, l(O)), q = ((M = n.renderText) == null ? void 0 : M.call(n, {
262
+ value: f,
263
+ ...S
264
+ })) || f, Be = n.renderText ? p(J, null, [(G = n.renderText) == null ? void 0 : G.call(n, {
265
+ value: f,
266
+ ...S
267
+ })]) : ke;
268
+ let N = Re(n, q, Be);
269
+ return n.customRender && (N = n.customRender({
270
+ value: f,
271
+ ...S,
272
272
  column: n,
273
- originalNode: P,
273
+ originalNode: N,
274
274
  originalText: q
275
- })), P;
275
+ })), N;
276
276
  },
277
- children: l(n.children || [], d || n)
277
+ children: r(n.children || [], d || n)
278
278
  }));
279
279
  }
280
- return l(e);
280
+ return r(e);
281
281
  };
282
282
  Ne(() => {
283
283
  const e = Se();
284
284
  u.value = e, D.value = e;
285
285
  });
286
286
  const he = s(() => {
287
- var l, a;
288
- if (o.adaptive && (g.total > 0 || ((l = o.dataSource) == null ? void 0 : l.length)))
287
+ var r, a;
288
+ if (o.adaptive && (b.total > 0 || ((r = o.dataSource) == null ? void 0 : r.length)))
289
289
  return {
290
- y: t(ie),
290
+ y: l(ie),
291
291
  x: ((a = o.scroll) == null ? void 0 : a.x) || "100%"
292
292
  };
293
293
  if (o.scroll)
@@ -296,26 +296,29 @@ const No = /* @__PURE__ */ ze({
296
296
  var e;
297
297
  if (o.tableLayout)
298
298
  return o.tableLayout;
299
- if ((e = o.columns) != null && e.some((l) => l.ellipsis))
299
+ if ((e = o.columns) != null && e.some((r) => r.ellipsis))
300
300
  return "fixed";
301
301
  }), H = s(() => {
302
302
  var a;
303
- const e = t(_), l = t(v);
303
+ const e = l(_), r = l(T);
304
304
  return {
305
305
  ...o,
306
306
  ...e,
307
307
  rowSelection: o.rowSelection === !0 || ((a = o.rowSelection) == null ? void 0 : a.mode) === "internal" ? {
308
- ...l,
308
+ ...r,
309
309
  // tips 如果是前端分页,则默认会走缓存
310
- preserveSelectedRowKeys: y(o.dataSource) ? l.preserveSelectedRowKeys : !0
310
+ preserveSelectedRowKeys: g(o.dataSource) ? r.preserveSelectedRowKeys : !0
311
311
  } : Je(o.rowSelection),
312
- loading: y(o.loading) ? e.loading : o.loading,
312
+ loading: g(o.loading) ? e.loading : o.loading,
313
313
  pagination: o.pagination === !1 ? !1 : e.pagination,
314
- scroll: t(he)
314
+ scroll: l(he)
315
315
  };
316
- }), Re = s(() => [i(), o.card ? null : i("wrapper"), o.adaptive ? i("adaptive") : null, V ? ue(`sticky-${oo === 0 ? "absolute" : "relative"}`) : null].filter(Boolean));
317
- function Ce(e, l, a) {
318
- return ae.includes(e.valueType) ? a : e.copyable || e.ellipsis ? f(to, {
316
+ }), ve = s(() => {
317
+ var e;
318
+ return [c(), o.card ? null : c("wrapper"), o.adaptive ? c("adaptive") : null, A.value && ((e = i.value) != null && e.visible) ? ue(`sticky-${oo === 0 ? "absolute" : "relative"}`) : null].filter(Boolean);
319
+ });
320
+ function Re(e, r, a) {
321
+ return ae.includes(e.valueType) ? a : e.copyable || e.ellipsis ? p(to, {
319
322
  copyable: e.copyable,
320
323
  ellipsis: e.ellipsis ? $e(e.ellipsis) ? {
321
324
  tooltip: a,
@@ -327,59 +330,68 @@ const No = /* @__PURE__ */ ze({
327
330
  content: a
328
331
  }, null) : a;
329
332
  }
330
- Q(() => t(g).loading, (e) => {
331
- var l;
332
- (l = o.onLoadingChange) == null || l.call(o, e);
333
+ Q(() => l(b).loading, (e) => {
334
+ var r;
335
+ (r = o.onLoadingChange) == null || r.call(o, e);
333
336
  }), Q(() => o.dataSource, (e) => {
334
337
  ge(e);
335
338
  }, {
336
339
  immediate: !0
337
340
  });
338
- function ve(e) {
339
- var l, a, r;
340
- (r = (a = (l = z.value) == null ? void 0 : l.apForm) == null ? void 0 : a.setFieldsValue) == null || r.call(a, e);
341
+ function Ce(e) {
342
+ var r, a, t;
343
+ (t = (a = (r = P.value) == null ? void 0 : r.apForm) == null ? void 0 : a.setFieldsValue) == null || t.call(a, e);
341
344
  }
342
345
  function Te(e = !1) {
343
- var a, r, d;
344
- const l = e ? "getFieldsValueTransformed" : "getFieldsValue";
345
- return (d = (r = (a = z.value) == null ? void 0 : a.apForm) == null ? void 0 : r[l]) == null ? void 0 : d.call(r, !0);
346
+ var a, t, d;
347
+ const r = e ? "getFieldsValueTransformed" : "getFieldsValue";
348
+ return (d = (t = (a = P.value) == null ? void 0 : a.apForm) == null ? void 0 : t[r]) == null ? void 0 : d.call(t, !0);
346
349
  }
347
- function Be() {
348
- return t(u);
350
+ function Fe() {
351
+ return l(u);
349
352
  }
350
353
  return se({
351
354
  submit: () => W(),
352
355
  reset: () => j(),
353
356
  refresh: () => ye(),
354
- setSearchFormValues: ve,
357
+ setSearchFormValues: Ce,
355
358
  getSearchFormValues: Te,
356
- getShownColumns: Be,
357
- dataSource: s(() => t(g).records),
359
+ getShownColumns: Fe,
360
+ dataSource: s(() => l(b).records),
358
361
  rowSelection: {
359
- selectedRows: s(() => t(T)),
360
- ...B
362
+ selectedRows: s(() => l(F)),
363
+ ...x
361
364
  },
362
365
  scrollBar: {
363
- x: A,
366
+ x: {
367
+ getCurrentScroll: () => {
368
+ var e;
369
+ return ((e = i == null ? void 0 : i.value) == null ? void 0 : e.currentScroll) ?? 0;
370
+ },
371
+ scroll: (e) => {
372
+ var r, a;
373
+ return (a = (r = i == null ? void 0 : i.value) == null ? void 0 : r.scroll) == null ? void 0 : a.call(r, e);
374
+ }
375
+ },
364
376
  y: void 0
365
377
  }
366
- }), (e, l) => (p(), F("div", {
378
+ }), (e, r) => (m(), k("div", {
367
379
  ref_key: "tableWrapperRef",
368
- ref: O,
369
- class: m(Re.value)
370
- }, [t(y)(e.dataSource) && e.searchForm !== !1 && $.value.length > 0 ? (p(), F("div", {
380
+ ref: L,
381
+ class: y(ve.value)
382
+ }, [l(g)(e.dataSource) && e.searchForm !== !1 && $.value.length > 0 ? (m(), k("div", {
371
383
  key: 0,
372
- class: m(e.card ? t(x)("search-wrapper") : null),
384
+ class: y(e.card ? l(B)("search-wrapper") : null),
373
385
  style: X(e.searchFormWrapperStyle)
374
- }, [f(t(Ae).SearchForm, h(e.searchForm || {}, {
386
+ }, [p(l(Ae).SearchForm, w(e.searchForm || {}, {
375
387
  ref_key: "formRef",
376
- ref: z,
388
+ ref: P,
377
389
  "custom-reset": "",
378
- "submit-loading": t(_).loading,
379
- onSubmit: t(W),
380
- onReset: t(j)
390
+ "submit-loading": l(_).loading,
391
+ onSubmit: l(W),
392
+ onReset: l(j)
381
393
  }), Y({
382
- default: w(() => [(p(!0), F(J, null, Z($.value, (a) => (p(), ee(Ie(a.renderNode.Comp), h({
394
+ default: v(() => [(m(!0), k(J, null, Z($.value, (a) => (m(), ee(Ie(a.renderNode.Comp), w({
383
395
  key: a.dataIndex,
384
396
  item: a,
385
397
  ref_for: !0
@@ -390,65 +402,65 @@ const No = /* @__PURE__ */ ze({
390
402
  _: 2
391
403
  }, [C.searchFormExtra ? {
392
404
  name: "extra",
393
- fn: w(() => [R(e.$slots, "searchFormExtra")]),
405
+ fn: v(() => [R(e.$slots, "searchFormExtra")]),
394
406
  key: "0"
395
- } : void 0]), 1040, ["submit-loading", "onSubmit", "onReset"])], 6)) : oe("", !0), N("div", {
407
+ } : void 0]), 1040, ["submit-loading", "onSubmit", "onReset"])], 6)) : oe("", !0), I("div", {
396
408
  ref_key: "contentRef",
397
409
  ref: ce,
398
- class: m([t(x)("table-wrapper"), e.card ? t(x)("table-wrapper-card") : null]),
410
+ class: y([l(B)("table-wrapper"), e.card ? l(B)("table-wrapper-card") : null]),
399
411
  style: X(e.tableWrapperStyle)
400
- }, [N("div", {
401
- class: m(t(i)("header-wrapper"))
402
- }, [e.settings ? (p(), F("div", {
412
+ }, [I("div", {
413
+ class: y(l(c)("header-wrapper"))
414
+ }, [e.settings ? (m(), k("div", {
403
415
  key: 0,
404
- class: m(t(i)("header"))
405
- }, [N("div", {
406
- class: m(t(E)("header", "title"))
407
- }, [R(e.$slots, "title", h({
408
- selectedRows: t(T),
409
- selectedRowKeys: t(v).selectedRowKeys,
416
+ class: y(l(c)("header"))
417
+ }, [I("div", {
418
+ class: y(l(K)("header", "title"))
419
+ }, [R(e.$slots, "title", w({
420
+ selectedRows: l(F),
421
+ selectedRowKeys: l(T).selectedRowKeys,
410
422
  shownColumns: u.value
411
- }, B))], 2), C.title ? (p(), ee(t(Oe), {
423
+ }, x))], 2), C.title ? (m(), ee(l(Oe), {
412
424
  key: 0,
413
425
  type: "vertical"
414
- })) : oe("", !0), f(lo, {
426
+ })) : oe("", !0), p(lo, {
415
427
  config: e.settings === !0 ? {} : e.settings
416
- }, null, 8, ["config"])], 2)) : R(e.$slots, "title", h({
428
+ }, null, 8, ["config"])], 2)) : R(e.$slots, "title", w({
417
429
  key: 1,
418
- selectedRows: t(T),
419
- selectedRowKeys: t(v).selectedRowKeys,
430
+ selectedRows: l(F),
431
+ selectedRowKeys: l(T).selectedRowKeys,
420
432
  shownColumns: u.value
421
- }, B))], 2), f(t(Le), h({
433
+ }, x))], 2), p(l(Le), w({
422
434
  ref_key: "antdTableRef",
423
- ref: L,
424
- class: t(i)("table")
435
+ ref: V,
436
+ class: l(c)("table")
425
437
  }, H.value, {
426
- size: k.value,
438
+ size: z.value,
427
439
  "table-layout": we.value,
428
440
  columns: u.value,
429
- onResizeColumn: l[0] || (l[0] = (a, r) => r.width = a)
441
+ onResizeColumn: r[0] || (r[0] = (a, t) => t.width = a)
430
442
  }), Y({
431
- summary: w(() => [R(e.$slots, "summary", {
443
+ summary: v(() => [R(e.$slots, "summary", {
432
444
  columns: u.value,
433
445
  records: H.value.dataSource,
434
- selectedRows: t(T)
446
+ selectedRows: l(F)
435
447
  })]),
436
448
  _: 2
437
- }, [t(V) ? {
449
+ }, [l(A) ? {
438
450
  name: "bottomPaginationTop",
439
- fn: w(() => {
440
- var a, r;
441
- return [f(t(no), {
451
+ fn: v(() => {
452
+ var a, t;
453
+ return [p(l(no), {
442
454
  ref_key: "scrollBarRef",
443
- ref: A,
444
- "scroll-container": (r = (a = L.value) == null ? void 0 : a.table) == null ? void 0 : r.scrollBodyRef,
455
+ ref: i,
456
+ "scroll-container": (t = (a = V.value) == null ? void 0 : a.table) == null ? void 0 : t.scrollBodyRef,
445
457
  direction: "horizontal"
446
458
  }, null, 8, ["scroll-container"])];
447
459
  }),
448
460
  key: "0"
449
- } : void 0, Z(t(re)(C, ["title", "searchFormExtra", "headerCell", "summary"]), (a, r) => ({
450
- name: r,
451
- fn: w((d) => [R(e.$slots, r, Ee(Ke(d || {})))])
461
+ } : void 0, Z(l(re)(C, ["title", "searchFormExtra", "headerCell", "summary"]), (a, t) => ({
462
+ name: t,
463
+ fn: v((d) => [R(e.$slots, t, Ee(Ke(d || {})))])
452
464
  }))]), 1040, ["class", "size", "table-layout", "columns"])], 6)], 2));
453
465
  }
454
466
  });
@@ -8,8 +8,6 @@ import { ApActionGroupProps } from '../ap-action';
8
8
  import { ApTableIndexProps } from './components/interface';
9
9
  import { EllipsisConfig } from '@aplus-frontend/antdv/es/typography/Base';
10
10
  import { RowSelectionReturnType } from './hooks/use-table-row-selection';
11
- import { ScrollBarExpose } from '../scroll-bar/interface';
12
- import { UnwrapRefProps } from '../utils';
13
11
  export type ValueEnumType = {
14
12
  text: string;
15
13
  /**
@@ -374,7 +372,10 @@ export type ApTableExpose<SearchParamsType = Recordable, RecordType = any> = {
374
372
  * 滚动条实例
375
373
  */
376
374
  scrollBar: {
377
- x: Ref<UnwrapRefProps<ScrollBarExpose>>;
378
- y: Ref<UnwrapRefProps<ScrollBarExpose>>;
375
+ x: {
376
+ getCurrentScroll: () => number;
377
+ scroll: (percent: number) => void | undefined;
378
+ };
379
+ y: undefined;
379
380
  };
380
381
  };
@@ -1,8 +1,6 @@
1
1
  import { OpenOptions, UseCreateTableModalProps, OpenReturnType } from '../interface';
2
2
  import { Recordable } from '../../../type';
3
3
  import { TableColumnsType } from '@aplus-frontend/antdv';
4
- import { UnwrapRefProps } from '../../../utils';
5
- import { ScrollBarExpose } from '../../../scroll-bar';
6
4
  export declare function useCreateTableModal(props: UseCreateTableModalProps): {
7
5
  readonly openModal: <T>(selected?: any[], options?: OpenOptions) => Promise< OpenReturnType<T> | undefined>;
8
6
  readonly closeModal: () => void;
@@ -28,8 +26,11 @@ export declare function useCreateTableModal(props: UseCreateTableModalProps): {
28
26
  } | undefined;
29
27
  getShownColumns: () => TableColumnsType<any>;
30
28
  scrollBar: {
31
- x: UnwrapRefProps<ScrollBarExpose>;
32
- y: UnwrapRefProps<ScrollBarExpose>;
29
+ x: {
30
+ getCurrentScroll: () => number;
31
+ scroll: (percent: number) => void | undefined;
32
+ };
33
+ y: undefined;
33
34
  };
34
35
  } | null | undefined;
35
36
  readonly isDestroyed: true;
@@ -1,8 +1,6 @@
1
1
  import { ApTableModalProps, OpenOptions } from '../interface';
2
2
  import { Recordable } from '../../../type';
3
3
  import { TableColumnsType } from '@aplus-frontend/antdv';
4
- import { UnwrapRefProps } from '../../../utils';
5
- import { ScrollBarExpose } from '../../..';
6
4
  /** 函数式调用弹框表格 */
7
5
  export declare function useTableModal<TableRowType = Record<string, any>>(props: ApTableModalProps<TableRowType>): {
8
6
  reloadApTableData: () => void;
@@ -26,8 +24,11 @@ export declare function useTableModal<TableRowType = Record<string, any>>(props:
26
24
  } | undefined;
27
25
  getShownColumns: () => TableColumnsType<any>;
28
26
  scrollBar: {
29
- x: UnwrapRefProps<ScrollBarExpose>;
30
- y: UnwrapRefProps<ScrollBarExpose>;
27
+ x: {
28
+ getCurrentScroll: () => number;
29
+ scroll: (percent: number) => void | undefined;
30
+ };
31
+ y: undefined;
31
32
  };
32
33
  } | null | undefined;
33
34
  isDestroyed: true;
@@ -1,8 +1,6 @@
1
1
  import { OpenOptions, UseTableSelectModalProps } from '../interface';
2
2
  import { Recordable } from '../../../type';
3
3
  import { TableColumnsType } from '@aplus-frontend/antdv';
4
- import { UnwrapRefProps } from '../../../utils';
5
- import { ScrollBarExpose } from '../../..';
6
4
  export declare function useTableSelectModal<TableRowType = Record<string, any>>(props: UseTableSelectModalProps<TableRowType>): {
7
5
  reloadApTableData: () => void;
8
6
  resetApTableData: () => void;
@@ -25,8 +23,11 @@ export declare function useTableSelectModal<TableRowType = Record<string, any>>(
25
23
  } | undefined;
26
24
  getShownColumns: () => TableColumnsType<any>;
27
25
  scrollBar: {
28
- x: UnwrapRefProps<ScrollBarExpose>;
29
- y: UnwrapRefProps<ScrollBarExpose>;
26
+ x: {
27
+ getCurrentScroll: () => number;
28
+ scroll: (percent: number) => void | undefined;
29
+ };
30
+ y: undefined;
30
31
  };
31
32
  } | null | undefined;
32
33
  isDestroyed: true;
@@ -4,8 +4,6 @@ import { CreateComponentPublicInstanceWithMixins, ComponentOptionsMixin, PublicP
4
4
  import { ApTableModalProps, OpenOptions, OpenReturnType } from './interface';
5
5
  import { Recordable } from '../../type';
6
6
  import { TableColumnsType } from '@aplus-frontend/antdv';
7
- import { UnwrapRefProps } from '../../utils';
8
- import { ScrollBarExpose } from '../..';
9
7
  /**
10
8
  *
11
9
  */
@@ -34,8 +32,11 @@ declare const ApTableModal: {
34
32
  } | undefined;
35
33
  getShownColumns: () => TableColumnsType<any>;
36
34
  scrollBar: {
37
- x: UnwrapRefProps<ScrollBarExpose>;
38
- y: UnwrapRefProps<ScrollBarExpose>;
35
+ x: {
36
+ getCurrentScroll: () => number;
37
+ scroll: (percent: number) => void | undefined;
38
+ };
39
+ y: undefined;
39
40
  };
40
41
  } | null;
41
42
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {
@@ -77,7 +78,10 @@ declare const ApTableModal: {
77
78
  selectedRows: ComputedRef<any[]>;
78
79
  };
79
80
  scrollBar: {
80
- x: Ref< ScrollBarExpose | undefined, ScrollBarExpose | undefined>;
81
+ x: {
82
+ getCurrentScroll: () => 0 | Ref<number, number>;
83
+ scroll: (percent: number) => void | undefined;
84
+ };
81
85
  y: undefined;
82
86
  };
83
87
  }> | null;
@@ -112,8 +116,11 @@ declare const ApTableModal: {
112
116
  } | undefined;
113
117
  getShownColumns: () => TableColumnsType<any>;
114
118
  scrollBar: {
115
- x: UnwrapRefProps<ScrollBarExpose>;
116
- y: UnwrapRefProps<ScrollBarExpose>;
119
+ x: {
120
+ getCurrentScroll: () => number;
121
+ scroll: (percent: number) => void | undefined;
122
+ };
123
+ y: undefined;
117
124
  };
118
125
  } | null;
119
126
  }, {}, {}, {}, {
@@ -161,8 +168,11 @@ declare const ApTableModal: {
161
168
  } | undefined;
162
169
  getShownColumns: () => TableColumnsType<any>;
163
170
  scrollBar: {
164
- x: UnwrapRefProps<ScrollBarExpose>;
165
- y: UnwrapRefProps<ScrollBarExpose>;
171
+ x: {
172
+ getCurrentScroll: () => number;
173
+ scroll: (percent: number) => void | undefined;
174
+ };
175
+ y: undefined;
166
176
  };
167
177
  } | null;
168
178
  }, {}, {}, {}, ComponentOptionsMixin, ComponentOptionsMixin, {