vft 0.0.455 → 0.0.457

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 (49) hide show
  1. package/dist/index.css +2 -2
  2. package/es/components/carousel/use-carousel.js +1 -1
  3. package/es/components/config-provider/hooks/use-global-config.js +3 -3
  4. package/es/components/input/input.vue2.js +4 -4
  5. package/es/components/input-tag/composables/use-input-tag.js +1 -1
  6. package/es/components/loading/index.d.ts +3 -3
  7. package/es/components/loading/loading.js +1 -1
  8. package/es/components/loading/types.d.ts +2 -1
  9. package/es/components/super-form/super-form-item.vue2.js +1 -1
  10. package/es/components/table/index.d.ts +9 -0
  11. package/es/components/table/table.vue2.js +123 -107
  12. package/es/components/table/types.d.ts +2 -0
  13. package/es/components/table/use/use-data-source.js +45 -46
  14. package/es/package.json.d.ts +1 -1
  15. package/es/package.json.js +1 -1
  16. package/es/utils/vue/vnode.js +1 -1
  17. package/lib/components/input/input.vue2.cjs +1 -1
  18. package/lib/components/loading/index.d.ts +3 -3
  19. package/lib/components/loading/loading.cjs +1 -1
  20. package/lib/components/loading/types.d.ts +2 -1
  21. package/lib/components/table/index.d.ts +9 -0
  22. package/lib/components/table/table.vue2.cjs +1 -1
  23. package/lib/components/table/types.d.ts +2 -0
  24. package/lib/components/table/use/use-data-source.cjs +1 -1
  25. package/lib/package.json.cjs +1 -1
  26. package/lib/package.json.d.ts +1 -1
  27. package/package.json +4 -4
  28. package/theme-style/base.css +2 -2
  29. package/theme-style/index.css +2 -2
  30. package/theme-style/src/common/help.scss +17 -0
  31. package/theme-style/src/common/transition.scss +10 -0
  32. package/theme-style/src/common/var.scss +3 -3
  33. package/theme-style/src/loading.scss +25 -0
  34. package/theme-style/src/spinner.scss +3 -3
  35. package/theme-style/src/table.scss +5 -0
  36. package/theme-style/vft-collapse.css +1 -1
  37. package/theme-style/vft-date-picker.css +1 -1
  38. package/theme-style/vft-input.css +1 -1
  39. package/theme-style/vft-loading.css +1 -1
  40. package/theme-style/vft-md-container.css +1 -1
  41. package/theme-style/vft-menu.css +1 -1
  42. package/theme-style/vft-spinner.css +1 -1
  43. package/theme-style/vft-table.css +1 -1
  44. package/theme-style/vft-tabs.css +1 -1
  45. package/theme-style/vft-time-picker.css +1 -1
  46. package/theme-style/vft-time-select.css +1 -1
  47. package/theme-style/vft-tree.css +1 -1
  48. package/theme-style/vft-var.css +1 -1
  49. package/web-types.json +1 -1
@@ -11,7 +11,7 @@ import "../../hooks/use-model-toggle/index.js";
11
11
  import { useOrderedChildren as ge } from "../../hooks/use-ordered-children/index.js";
12
12
  import "@popperjs/core";
13
13
  import "../../hooks/use-z-index/index.js";
14
- import { carouselContextKey as Se, CAROUSEL_ITEM_NAME as H } from "./constants.js";
14
+ import { CAROUSEL_ITEM_NAME as H, carouselContextKey as Se } from "./constants.js";
15
15
  const L = 300, ze = (t, O, M) => {
16
16
  const {
17
17
  children: o,
@@ -1,7 +1,7 @@
1
1
  import { keysOf as f } from "@vft/utils";
2
2
  import "@vueuse/core";
3
3
  import { debugWarn as v } from "../../../utils/error.js";
4
- import { ref as g, getCurrentInstance as l, computed as i, unref as p, provide as C, inject as x } from "vue";
4
+ import { getCurrentInstance as l, computed as i, unref as p, provide as g, ref as C, inject as x } from "vue";
5
5
  import "lodash-es";
6
6
  import "../../form/index.js";
7
7
  import { namespaceContextKey as I, useNamespace as b, defaultNamespace as y } from "../../../hooks/use-namespace/index.js";
@@ -9,7 +9,7 @@ import "../../../hooks/use-model-toggle/index.js";
9
9
  import "@popperjs/core";
10
10
  import { zIndexContextKey as G, useZIndex as z, defaultInitialZIndex as K } from "../../../hooks/use-z-index/index.js";
11
11
  import { configProviderContextKey as m } from "../constants.js";
12
- const a = g();
12
+ const a = C();
13
13
  function d(o, e = void 0) {
14
14
  const n = l() ? x(m, a) : a;
15
15
  return o ? i(() => n?.value?.[o] ?? e) : n;
@@ -27,7 +27,7 @@ function B(o) {
27
27
  };
28
28
  }
29
29
  const S = (o, e, n = !1) => {
30
- const t = !!l(), r = t ? d() : void 0, u = e?.provide ?? (t ? C : void 0);
30
+ const t = !!l(), r = t ? d() : void 0, u = e?.provide ?? (t ? g : void 0);
31
31
  if (!u) {
32
32
  v(
33
33
  "provideGlobalConfig",
@@ -13,8 +13,8 @@ import "../../hooks/use-z-index/index.js";
13
13
  import { UPDATE_MODEL_EVENT as Q } from "@vft/constants";
14
14
  import { useAttrs as Ze, useCursor as _e } from "@vft/use";
15
15
  import { calcTextareaHeight as he } from "./utils.js";
16
- import { useFormItem as et, useFormItemInputId as tt } from "../form/hooks/use-form-item.js";
17
- import { useFormSize as at, useFormDisabled as nt } from "../form/hooks/use-form-common-props.js";
16
+ import { useFormSize as et, useFormDisabled as tt } from "../form/hooks/use-form-common-props.js";
17
+ import { useFormItem as at, useFormItemInputId as nt } from "../form/hooks/use-form-item.js";
18
18
  const ot = ["role"], lt = ["id", "type", "disabled", "formatter", "parser", "readonly", "autocomplete", "tabindex", "aria-label", "placeholder", "form"], st = ["id", "tabindex", "disabled", "readonly", "autocomplete", "aria-label", "placeholder", "form"], It = /* @__PURE__ */ Oe({
19
19
  __name: "input",
20
20
  props: {
@@ -85,9 +85,9 @@ const ot = ["role"], lt = ["id", "type", "disabled", "formatter", "parser", "rea
85
85
  n.is("focus", v.value)
86
86
  ]), d = Ze({
87
87
  excludeKeys: l(() => Object.keys(X.value))
88
- }), { form: Ce, formItem: F } = et(), { inputId: Y } = tt(we.props, {
88
+ }), { form: Ce, formItem: F } = at(), { inputId: Y } = nt(we.props, {
89
89
  formItemContext: F
90
- }), ke = at(), x = nt(), n = ye("input"), Z = ye("textarea"), M = H(), p = H(), v = S(!1), N = S(!1), C = S(!1), K = S(!1), _ = S(), O = H(e.inputStyle), k = l(() => M.value || p.value), T = l(() => G(e.prefixIcon, "icon", { size: 16 })), ee = l(() => G(e.suffixIcon, "icon", { size: 16 })), Ie = l(() => G(e.clearIcon, "icon", {
90
+ }), ke = et(), x = tt(), n = ye("input"), Z = ye("textarea"), M = H(), p = H(), v = S(!1), N = S(!1), C = S(!1), K = S(!1), _ = S(), O = H(e.inputStyle), k = l(() => M.value || p.value), T = l(() => G(e.prefixIcon, "icon", { size: 16 })), ee = l(() => G(e.suffixIcon, "icon", { size: 16 })), Ie = l(() => G(e.clearIcon, "icon", {
91
91
  icon: "icon-circle-close",
92
92
  size: 16
93
93
  })), te = l(() => Ce?.statusIcon ?? !1), I = l(() => F?.validateState || ""), ae = l(
@@ -1,6 +1,6 @@
1
1
  import { shallowRef as B, ref as L, computed as c, watch as G } from "vue";
2
2
  import { EVENT_CODE as g } from "../../../constants/aria.js";
3
- import { CHANGE_EVENT as i, UPDATE_MODEL_EVENT as d, INPUT_EVENT as H } from "../../../constants/event.js";
3
+ import { CHANGE_EVENT as i, INPUT_EVENT as H, UPDATE_MODEL_EVENT as d } from "../../../constants/event.js";
4
4
  import "@vueuse/core";
5
5
  import { isUndefined as K } from "@vft/utils";
6
6
  import { debugWarn as C } from "../../../utils/error.js";
@@ -1,11 +1,11 @@
1
1
  import type { App } from 'vue';
2
- import { vLoading, createLoadingDirective } from './directive';
2
+ import { vLoading, createLoadingDirective, type LoadingBinding } from './directive';
3
3
  import { Loading } from './service';
4
4
  export declare const VftLoading: {
5
5
  install(app: App): void;
6
- directive: import("vue").Directive<import("./directive").VftLoading, import("./directive").LoadingBinding>;
6
+ directive: import("vue").Directive<import("./directive").VftLoading, LoadingBinding>;
7
7
  service: (options?: import("./types").LoadingOptions) => import("./loading").LoadingInstance;
8
8
  };
9
9
  export default VftLoading;
10
- export { vLoading as VftLoadingDirective, Loading as VftLoadingService, vLoading, createLoadingDirective };
10
+ export { vLoading as VftLoadingDirective, Loading as VftLoadingService, vLoading, createLoadingDirective, type LoadingBinding, };
11
11
  export * from './types';
@@ -76,7 +76,7 @@ function K(r) {
76
76
  fill: "none"
77
77
  })
78
78
  ]
79
- ), h = e.text ? o("p", { class: n.b("text") }, e.text) : void 0;
79
+ ), h = e.text ? o("p", { class: n.b("text") }, [e.text]) : void 0;
80
80
  return o(
81
81
  k,
82
82
  {
@@ -1,5 +1,6 @@
1
1
  import type { IconProps } from 'vft/es/components/icon';
2
2
  import type { MaybeRef } from '@vueuse/core';
3
+ import type { VNode } from 'vue';
3
4
  export type LoadingOptionsResolved = {
4
5
  parent: LoadingParentElement;
5
6
  background: MaybeRef<string>;
@@ -8,7 +9,7 @@ export type LoadingOptionsResolved = {
8
9
  spinner: MaybeRef<boolean | string>;
9
10
  img: MaybeRef<boolean | string>;
10
11
  icon: MaybeRef<IconProps | string>;
11
- text: MaybeRef<string>;
12
+ text: MaybeRef<string | VNode | VNode[]>;
12
13
  fullscreen: boolean;
13
14
  rotate: MaybeRef<boolean | string>;
14
15
  lock: boolean;
@@ -1,4 +1,4 @@
1
- import { defineComponent as X, computed as j, ref as re, unref as c, useSlots as oe, createVNode as a, mergeProps as q, withDirectives as ie, vShow as ne, createTextVNode as O, isVNode as le, resolveComponent as N } from "vue";
1
+ import { defineComponent as X, computed as j, ref as re, unref as c, useSlots as oe, createVNode as a, mergeProps as q, withDirectives as ie, vShow as ne, isVNode as le, createTextVNode as O, resolveComponent as N } from "vue";
2
2
  import "../alert/index.js";
3
3
  import "../avatar/index.js";
4
4
  import "../avatar-stack/index.js";
@@ -69,6 +69,9 @@ export declare const VftTable: import("vft/es/utils").SFCWithInstall<{
69
69
  emptyCfg: {
70
70
  type: import("vue").PropType<import("vft/es/vft").EmptyProps>;
71
71
  };
72
+ loadingCfg: {
73
+ type: import("vue").PropType<import("vft/es/vft").LoadingBinding>;
74
+ };
72
75
  layouts: {
73
76
  type: import("vue").PropType<import("vxe-table").VxeGridPropTypes.Layouts>;
74
77
  };
@@ -982,6 +985,9 @@ export declare const VftTable: import("vft/es/utils").SFCWithInstall<{
982
985
  emptyCfg: {
983
986
  type: import("vue").PropType<import("vft/es/vft").EmptyProps>;
984
987
  };
988
+ loadingCfg: {
989
+ type: import("vue").PropType<import("vft/es/vft").LoadingBinding>;
990
+ };
985
991
  layouts: {
986
992
  type: import("vue").PropType<import("vxe-table").VxeGridPropTypes.Layouts>;
987
993
  };
@@ -1779,6 +1785,9 @@ export declare const VftTable: import("vft/es/utils").SFCWithInstall<{
1779
1785
  emptyCfg: {
1780
1786
  type: import("vue").PropType<import("vft/es/vft").EmptyProps>;
1781
1787
  };
1788
+ loadingCfg: {
1789
+ type: import("vue").PropType<import("vft/es/vft").LoadingBinding>;
1790
+ };
1782
1791
  layouts: {
1783
1792
  type: import("vue").PropType<import("vxe-table").VxeGridPropTypes.Layouts>;
1784
1793
  };
@@ -1,42 +1,40 @@
1
- import { defineComponent as N, useAttrs as ae, ref as s, getCurrentInstance as te, computed as P, unref as e, watch as oe, nextTick as le, toRaw as re, createBlock as f, openBlock as m, withCtx as c, createElementVNode as H, normalizeClass as ne, createVNode as p, createCommentVNode as D, mergeProps as _, withDirectives as ce, renderSlot as h, normalizeProps as ie, guardReactiveProps as se } from "vue";
2
- import { VftEmpty as ge } from "../empty/index.js";
3
- import { vLoading as de } from "../loading/directive.js";
4
- import { deepMerge as F, isClient as ue, omit as fe, isFunction as me } from "@vft/utils";
5
- import { FormCompEnum as pe } from "../../utils/form-register.js";
1
+ import { defineComponent as V, createVNode as c, useAttrs as ae, ref as g, getCurrentInstance as te, computed as D, unref as e, watch as oe, nextTick as le, toRaw as re, createBlock as m, openBlock as p, withCtx as i, createElementVNode as H, normalizeClass as ne, createCommentVNode as F, mergeProps as T, withDirectives as ce, vShow as ie, renderSlot as h, normalizeProps as se, guardReactiveProps as ge, createTextVNode as de } from "vue";
2
+ import { VftEmpty as ue } from "../empty/index.js";
3
+ import { vLoading as fe } from "../loading/directive.js";
4
+ import { deepMerge as _, isClient as me, omit as pe, isFunction as he } from "@vft/utils";
5
+ import { FormCompEnum as be } from "../../utils/form-register.js";
6
6
  import "@vueuse/core";
7
7
  import "../config-provider/hooks/use-global-config.js";
8
8
  import "lodash-es";
9
- import { useForm as he } from "../super-form/use/use-form.js";
10
- import { useNamespace as be } from "../../hooks/use-namespace/index.js";
9
+ import { useForm as Ce } from "../super-form/use/use-form.js";
10
+ import { useNamespace as ye } from "../../hooks/use-namespace/index.js";
11
11
  import "../../hooks/use-model-toggle/index.js";
12
12
  import "@popperjs/core";
13
13
  import "../../hooks/use-z-index/index.js";
14
14
  import "../icon/index.js";
15
- import { VftClientOnly as Ce } from "../client-only/index.js";
16
- import { VftPagination as ye } from "../pagination/index.js";
17
- import { VftSkeleton as we } from "../skeleton/index.js";
18
- import { VftSuperForm as ve } from "../super-form/index.js";
19
- import { VxeGrid as xe } from "vxe-table";
20
- import ke from "xe-utils";
21
- import { PageSize as T } from "./constants.js";
22
- import { useColumns as Se } from "./use/use-columns.js";
23
- import { useDataSource as Be } from "./use/use-data-source.js";
24
- import { useLoading as ze } from "./use/use-loading.js";
25
- import { usePagination as Re } from "./use/use-pagination.js";
26
- import { EmptyEnum as Pe } from "../empty/constants.js";
27
- const He = {
28
- "vft-loading-text": "加载中..."
29
- }, De = N({
15
+ import { VftClientOnly as we } from "../client-only/index.js";
16
+ import { VftPagination as ve } from "../pagination/index.js";
17
+ import { VftSkeleton as xe } from "../skeleton/index.js";
18
+ import { VftSuperForm as ke } from "../super-form/index.js";
19
+ import { VxeGrid as Se } from "vxe-table";
20
+ import Be from "xe-utils";
21
+ import { PageSize as N } from "./constants.js";
22
+ import { useColumns as ze } from "./use/use-columns.js";
23
+ import { useDataSource as Re } from "./use/use-data-source.js";
24
+ import { useLoading as Pe } from "./use/use-loading.js";
25
+ import { usePagination as De } from "./use/use-pagination.js";
26
+ import { EmptyEnum as He } from "../empty/constants.js";
27
+ const Fe = V({
30
28
  name: "vft-table"
31
- }), la = /* @__PURE__ */ N({
32
- ...De,
29
+ }), ra = /* @__PURE__ */ V({
30
+ ...Fe,
33
31
  props: {
34
32
  sticky: {
35
33
  type: [Boolean, Object]
36
34
  },
37
35
  api: {},
38
36
  pageSize: {
39
- default: T
37
+ default: N
40
38
  },
41
39
  total: {},
42
40
  rowkey: {
@@ -81,7 +79,16 @@ const He = {
81
79
  onChange: {},
82
80
  emptyCfg: {
83
81
  default: () => ({
84
- type: Pe.NoData
82
+ type: He.NoData
83
+ })
84
+ },
85
+ loadingCfg: {
86
+ type: Boolean,
87
+ default: () => ({
88
+ customClass: "vft-card-loading",
89
+ text: c("div", null, [c("span", null, [de("加载中")]), c("span", {
90
+ class: "dot"
91
+ }, null)])
85
92
  })
86
93
  },
87
94
  layouts: {},
@@ -393,26 +400,26 @@ const He = {
393
400
  "toolbar-tool-click",
394
401
  "zoom"
395
402
  ],
396
- setup(_e, {
397
- expose: O,
398
- emit: V
403
+ setup(Te, {
404
+ expose: A,
405
+ emit: E
399
406
  }) {
400
- const r = V, g = be("table"), A = ae(), b = s(), C = s(), E = s([]), d = s(), M = te(), t = P(() => F(M.props, e(d))), {
407
+ const n = E, d = ye("table"), O = ae(), b = g(), C = g(), q = g([]), u = g(), M = te(), t = D(() => _(M.props, e(u))), {
401
408
  getLoading: $,
402
- setLoading: q
403
- } = ze(t), {
404
- getPaginationInfo: i,
405
- setPagination: u,
409
+ setLoading: L
410
+ } = Pe(t), {
411
+ getPaginationInfo: s,
412
+ setPagination: f,
406
413
  getCurrentPage: G
407
- } = Re(t), {
414
+ } = De(t), {
408
415
  getViewColumns: I,
409
416
  setColumns: K
410
- } = Se(t);
417
+ } = ze(t);
411
418
  oe(() => G(), (a) => {
412
419
  le(() => {
413
420
  y({
414
421
  seqConfig: {
415
- startIndex: (a - 1) * (i.value?.pageSize || e(t).pageSize || T)
422
+ startIndex: (a - 1) * (s.value?.pageSize || e(t).pageSize || N)
416
423
  }
417
424
  });
418
425
  });
@@ -420,39 +427,39 @@ const He = {
420
427
  immediate: !0
421
428
  });
422
429
  function y(a) {
423
- d.value = {
424
- ...e(d),
430
+ u.value = {
431
+ ...e(u),
425
432
  ...a
426
433
  };
427
434
  }
428
435
  const {
429
436
  getDataSourceRef: w,
430
- handleTableChange: L,
431
- reload: X,
432
- deleteTableDataRecord: Y,
433
- insertTableDataRecord: j,
437
+ handleTableChange: X,
438
+ reload: v,
439
+ deleteTableDataRecord: j,
440
+ insertTableDataRecord: Y,
434
441
  updateTableData: W,
435
442
  updateTableDataRecord: U,
436
- setTableData: v,
443
+ setTableData: x,
437
444
  getDataSource: J,
438
- getRawDataSource: x,
439
- tableSearch: k
440
- } = Be(t, {
441
- tableData: E,
442
- setLoading: q,
443
- getPaginationInfo: i,
444
- setPagination: u
445
- }, r);
446
- function S(a) {
447
- a?.pageSize && u({
445
+ getRawDataSource: k,
446
+ tableSearch: S
447
+ } = Re(t, {
448
+ tableData: q,
449
+ setLoading: L,
450
+ getPaginationInfo: s,
451
+ setPagination: f
452
+ }, n);
453
+ function B(a) {
454
+ a?.pageSize && f({
448
455
  currentPage: 1
449
- }), L(a), r("change", a);
456
+ }), X(a), n("change", a);
450
457
  const {
451
458
  onChange: o
452
459
  } = e(t);
453
- o && me(o) && o(a);
460
+ o && he(o) && o(a);
454
461
  }
455
- const B = {};
462
+ const z = {};
456
463
  [
457
464
  "update:data",
458
465
  "keydown-start",
@@ -574,57 +581,66 @@ const He = {
574
581
  "toolbar-tool-click",
575
582
  "zoom"
576
583
  ].forEach((a) => {
577
- const o = ke.camelCase(`on-${a}`);
578
- B[o] = (...l) => r(a, ...l);
584
+ const o = Be.camelCase(`on-${a}`);
585
+ z[o] = (...r) => n(a, ...r);
579
586
  });
580
- const n = P(() => {
587
+ const l = D(() => {
581
588
  const a = e(w), o = {
582
- ...A,
589
+ ...O,
583
590
  ...e(t),
584
591
  columns: re(e(I)),
585
592
  loading: e($),
586
593
  data: a,
587
- ...B
594
+ ...z
588
595
  };
589
- if (ue) {
596
+ if (me) {
590
597
  (e(t)?.addMaxHeight || e(t)?.maxHeight) && (o.maxHeight = e(t)?.maxHeight ? e(t)?.maxHeight : `${window.innerHeight - e(t)?.extraSysHeight - (t.value?.showPager ? t.value?.pageHeight || 40 : 0)}px`);
591
- const l = e(t)?.minHeight;
592
- o.minHeight = l || (l !== 0 && e(t)?.toolbarConfig?.custom ? 300 : void 0);
598
+ const r = e(t)?.minHeight;
599
+ o.minHeight = r || (r !== 0 && e(t)?.toolbarConfig?.custom ? 300 : void 0);
593
600
  }
594
- return o;
595
- }), z = {
596
- setPagination: u,
597
- emit: r,
601
+ return e(t)?.toolbarConfig?.refresh && (o.proxyConfig = e(t)?.proxyConfig || {
602
+ response: {
603
+ result: e(t)?.fetchSetting?.listField,
604
+ total: e(t)?.fetchSetting?.totalField
605
+ },
606
+ autoLoad: !1,
607
+ ajax: {
608
+ query: async () => await v()
609
+ }
610
+ }), o;
611
+ }), R = {
612
+ setPagination: f,
613
+ emit: n,
598
614
  setProps: y,
599
- reload: X,
600
- deleteTableDataRecord: Y,
601
- insertTableDataRecord: j,
615
+ reload: v,
616
+ deleteTableDataRecord: j,
617
+ insertTableDataRecord: Y,
602
618
  updateTableDataRecord: U,
603
619
  updateTableData: W,
604
- setTableData: v,
620
+ setTableData: x,
605
621
  getDataSource: J,
606
622
  getDataSourceRef: w,
607
623
  setColumns: K,
608
- getRawDataSource: x,
609
- tableSearch: k
624
+ getRawDataSource: k,
625
+ tableSearch: S
610
626
  };
611
- r("register", z);
627
+ n("register", R);
612
628
  const Q = {
613
629
  field: "_filterTableData",
614
630
  label: "",
615
- type: pe.Search,
631
+ type: be.Search,
616
632
  itemProps: {
617
633
  class: "search-all-form-item"
618
634
  },
619
635
  componentProps: () => ({
620
636
  onChange: (a) => {
621
- R({
637
+ P({
622
638
  _filterTableData: a
623
639
  });
624
640
  }
625
641
  })
626
- }, [Z] = he(F({
627
- schemas: [n.value?.formOptions?.addSearchAllSchema ? Q : {}],
642
+ }, [Z] = Ce(_({
643
+ schemas: [l.value?.formOptions?.addSearchAllSchema ? Q : {}],
628
644
  rowProps: {
629
645
  justify: "start"
630
646
  },
@@ -638,53 +654,53 @@ const He = {
638
654
  btnText: "搜索"
639
655
  },
640
656
  actionInline: !0
641
- }, fe(
642
- n.value?.formOptions,
657
+ }, pe(
658
+ l.value?.formOptions,
643
659
  ["showActionForm", "addSearchAllSchema"]
644
660
  // 'union' | 'intersection' | 'concat' | 'replace' = 'union'
645
- ), "replace")), R = (a) => {
646
- Reflect.has(a, "_filterTableData") && k(a._filterTableData), r("form-submit", a);
661
+ ), "replace")), P = (a) => {
662
+ Reflect.has(a, "_filterTableData") && S(a._filterTableData), n("form-submit", a);
647
663
  }, ee = () => {
648
- v(x()), r("form-reset");
664
+ x(k()), n("form-reset");
649
665
  };
650
- return O({
666
+ return A({
651
667
  table: b,
652
668
  pageRef: C,
653
- ...z
654
- }), (a, o) => (m(), f(e(Ce), null, {
655
- fallback: c(() => [p(e(we))]),
656
- default: c(() => [H("div", {
657
- class: ne([e(g).b()])
658
- }, [p(e(xe), _({
669
+ ...R
670
+ }), (a, o) => (p(), m(e(we), null, {
671
+ fallback: i(() => [c(e(xe))]),
672
+ default: i(() => [H("div", {
673
+ class: ne([e(d).b()])
674
+ }, [c(e(Se), T({
659
675
  ref_key: "xGrid",
660
676
  ref: b
661
- }, n.value), {
662
- toolbarButtons: c(() => [h(a.$slots, "toolbar-left"), n.value?.formOptions?.showActionForm ? (m(), f(e(ve), {
677
+ }, l.value), {
678
+ toolbarButtons: i(() => [h(a.$slots, "toolbar-left"), l.value?.formOptions?.showActionForm ? (p(), m(e(ke), {
663
679
  key: 0,
664
680
  onRegister: e(Z),
665
- onSubmit: R,
681
+ onSubmit: P,
666
682
  onReset: ee
667
- }, null, 8, ["onRegister"])) : D("", !0), h(a.$slots, "toolbar-right")]),
668
- empty: c(() => [h(a.$slots, "empty", {}, () => [p(e(ge), ie(se(n.value.emptyCfg)), null, 16)])]),
669
- loading: c(() => [ce(H("div", He, null, 512), [[e(de), !!n.value.loading]])]),
683
+ }, null, 8, ["onRegister"])) : F("", !0), h(a.$slots, "toolbar-right")]),
684
+ empty: i(() => [h(a.$slots, "empty", {}, () => [c(e(ue), se(ge(l.value.emptyCfg)), null, 16)])]),
685
+ loading: i(() => [ce(H("div", null, null, 512), [[ie, l.value.loading], [e(fe), l.value.loadingCfg || {}]])]),
670
686
  _: 3
671
- }, 16), n.value.showPager ? (m(), f(e(ye), _({
687
+ }, 16), l.value.showPager ? (p(), m(e(ve), T({
672
688
  key: 0,
673
689
  ref_key: "pageRef",
674
690
  ref: C
675
- }, e(i), {
676
- class: [e(g).e("pager"), e(g).m(`pager-${e(i)?.pagePlacement}`)],
677
- onCurrentChange: o[0] || (o[0] = (l) => S({
678
- currentPage: l
691
+ }, e(s), {
692
+ class: [e(d).e("pager"), e(d).m(`pager-${e(s)?.pagePlacement}`)],
693
+ onCurrentChange: o[0] || (o[0] = (r) => B({
694
+ currentPage: r
679
695
  })),
680
- onSizeChange: o[1] || (o[1] = (l) => S({
681
- pageSize: l
696
+ onSizeChange: o[1] || (o[1] = (r) => B({
697
+ pageSize: r
682
698
  }))
683
- }), null, 16, ["class"])) : D("", !0)], 2)]),
699
+ }), null, 16, ["class"])) : F("", !0)], 2)]),
684
700
  _: 3
685
701
  }));
686
702
  }
687
703
  });
688
704
  export {
689
- la as default
705
+ ra as default
690
706
  };
@@ -1,4 +1,5 @@
1
1
  import type { EmptyProps } from 'vft/es/components/empty';
2
+ import type { LoadingBinding } from 'vft/es/components/loading';
2
3
  import { type PaginationProps } from 'vft/es/components/pagination';
3
4
  import type { VxeGridInstance, VxeGridProps, VxeTableDefines } from 'vxe-table';
4
5
  import { type SuperFormProps } from '../super-form';
@@ -76,6 +77,7 @@ export interface TableProps extends VxeGridProps {
76
77
  onChange?: (...args: any[]) => void;
77
78
  /** 空状态配置,用于自定义空数据时的显示内容 */
78
79
  emptyCfg?: EmptyProps;
80
+ loadingCfg?: LoadingBinding;
79
81
  }
80
82
  /** 列项属性类型,继承自 VXE Table 的列选项 */
81
83
  export type ColumnItemProps = VxeTableDefines.ColumnOptions;