vft 0.0.97 → 0.0.99

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 (194) hide show
  1. package/es/components/affix/affix.vue2.js +25 -26
  2. package/es/components/alert/alert.vue2.js +17 -18
  3. package/es/components/backtop/backtop.vue2.js +14 -15
  4. package/es/components/button/button-group.vue2.js +14 -15
  5. package/es/components/button/button.vue2.js +24 -25
  6. package/es/components/card/card.vue2.js +10 -11
  7. package/es/components/check-tag/check-tag.vue2.js +10 -11
  8. package/es/components/checkbox/checkbox-button.vue2.js +13 -14
  9. package/es/components/checkbox/checkbox-group.vue2.js +15 -16
  10. package/es/components/checkbox/checkbox.vue2.js +24 -25
  11. package/es/components/clamp/clamp.vue2.js +16 -17
  12. package/es/components/clamp-toggle/clamp-toggle.vue2.js +13 -14
  13. package/es/components/col/col.vue2.js +20 -21
  14. package/es/components/collapse-transition/src/collapse-transition.vue2.js +12 -13
  15. package/es/components/collection/collection-item.vue2.js +6 -7
  16. package/es/components/collection/collection.vue2.js +5 -7
  17. package/es/components/color-picker/color-picker.vue2.js +45 -46
  18. package/es/components/color-picker/components/alpha-slider.vue2.js +20 -21
  19. package/es/components/config-provider/config-provider.vue2.js +22 -23
  20. package/es/components/container/aside.vue2.js +12 -13
  21. package/es/components/container/container.vue2.js +10 -11
  22. package/es/components/container/footer.vue2.js +11 -12
  23. package/es/components/container/header.vue2.js +10 -11
  24. package/es/components/container/main.vue2.js +12 -13
  25. package/es/components/context-menu/context-menu.vue2.js +18 -19
  26. package/es/components/date-picker/date-picker-com/basic-date-table.vue2.js +87 -87
  27. package/es/components/date-picker/date-picker-com/basic-month-table.vue2.js +1 -1
  28. package/es/components/date-picker/date-picker-com/basic-year-table.vue2.js +1 -1
  29. package/es/components/date-picker/date-picker-com/panel-date-pick.vue2.js +2 -2
  30. package/es/components/date-picker/date-picker-com/panel-month-range.vue2.js +39 -40
  31. package/es/components/date-time-select/date-time-select.vue2.js +20 -21
  32. package/es/components/descriptions/description-item.vue2.js +9 -10
  33. package/es/components/descriptions/description.vue2.js +20 -21
  34. package/es/components/descriptions/descriptions-row.vue2.js +15 -16
  35. package/es/components/dialog/dialog-content.vue2.js +12 -13
  36. package/es/components/dialog/dialog.vue2.js +40 -41
  37. package/es/components/divider/divider.vue2.js +10 -11
  38. package/es/components/dropdown/dropdown.vue2.js +38 -39
  39. package/es/components/empty/empty.vue2.js +11 -12
  40. package/es/components/footer-layout/footer-layout.vue2.js +7 -8
  41. package/es/components/form/form-item.vue2.js +43 -44
  42. package/es/components/form/form.vue2.js +28 -29
  43. package/es/components/full-screen/full-screen.vue2.js +15 -16
  44. package/es/components/header-layout/header-layout.vue2.js +21 -22
  45. package/es/components/horizontal-menu/horizontal-menu.vue2.js +50 -51
  46. package/es/components/icon/icon.vue2.js +12 -13
  47. package/es/components/icon-text/icon-text.vue2.js +13 -14
  48. package/es/components/iframe-layout/iframe-layout.vue2.js +15 -16
  49. package/es/components/iframe-layout/iframe-page.vue2.js +12 -13
  50. package/es/components/image/image.vue2.js +25 -26
  51. package/es/components/image-viewer/image-viewer.vue2.js +54 -55
  52. package/es/components/link/link.vue2.js +11 -12
  53. package/es/components/list-cell/list-cell.vue2.js +21 -22
  54. package/es/components/logo/logo.vue2.js +12 -13
  55. package/es/components/md-comment/md-comment.vue2.js +12 -13
  56. package/es/components/md-container/md-container.vue2.js +33 -34
  57. package/es/components/md-vue-playground/md-vue-playground.vue2.js +18 -19
  58. package/es/components/menu/menu-item-group.vue2.js +13 -14
  59. package/es/components/menu/menu-item.vue2.js +12 -13
  60. package/es/components/menu/menu.vue2.js +44 -45
  61. package/es/components/menu/sub-menu.vue2.js +30 -31
  62. package/es/components/multiple-tabs/multiple-tabs.vue2.js +35 -38
  63. package/es/components/overlay/overlay.vue2.js +23 -24
  64. package/es/components/page-wrapper/page-wrapper.vue2.js +17 -18
  65. package/es/components/pagination/pagination.vue2.js +17 -18
  66. package/es/components/popconfirm/popconfirm.vue2.js +17 -18
  67. package/es/components/popover/popover.vue2.js +31 -32
  68. package/es/components/popper/arrow.vue2.js +15 -16
  69. package/es/components/popper/content.vue2.js +38 -39
  70. package/es/components/popper/popper.vue2.js +13 -14
  71. package/es/components/popper/trigger.vue2.js +11 -12
  72. package/es/components/qrcode/qrcode.vue2.js +21 -22
  73. package/es/components/radio/radio-button.vue2.js +16 -17
  74. package/es/components/radio/radio-group.vue2.js +16 -17
  75. package/es/components/radio/radio.vue2.js +15 -16
  76. package/es/components/result/result.vue2.js +12 -13
  77. package/es/components/router-view-content/router-view-content.vue2.js +10 -11
  78. package/es/components/row/row.vue2.js +17 -18
  79. package/es/components/scrollbar/scrollbar.vue2.js +30 -31
  80. package/es/components/search/search.vue2.js +39 -40
  81. package/es/components/side-menu/side-menu.vue2.js +43 -45
  82. package/es/components/skeleton/skeleton-item.vue2.js +9 -10
  83. package/es/components/skeleton/skeleton.vue2.js +11 -12
  84. package/es/components/switch/switch.vue2.js +27 -28
  85. package/es/components/table/table.vue2.js +53 -50
  86. package/es/components/tabs/tab-nav.vue2.js +28 -29
  87. package/es/components/tabs/tab-pane.vue2.js +23 -24
  88. package/es/components/tabs/tabs.vue2.js +30 -31
  89. package/es/components/time-picker/common/picker.vue2.js +48 -49
  90. package/es/components/time-select/time-select.vue2.js +28 -29
  91. package/es/components/tooltip/content.vue2.js +36 -37
  92. package/es/components/tooltip/tooltip.vue2.js +15 -16
  93. package/es/components/tooltip/trigger.vue2.js +37 -38
  94. package/es/components/verify-code/verify-code.vue2.js +19 -20
  95. package/es/constants/date.js +7 -7
  96. package/es/package.json.js +1 -1
  97. package/lib/components/affix/affix.vue2.cjs +1 -1
  98. package/lib/components/alert/alert.vue2.cjs +1 -1
  99. package/lib/components/backtop/backtop.vue2.cjs +1 -1
  100. package/lib/components/button/button-group.vue2.cjs +1 -1
  101. package/lib/components/button/button.vue2.cjs +1 -1
  102. package/lib/components/card/card.vue2.cjs +1 -1
  103. package/lib/components/check-tag/check-tag.vue2.cjs +1 -1
  104. package/lib/components/checkbox/checkbox-button.vue2.cjs +1 -1
  105. package/lib/components/checkbox/checkbox-group.vue2.cjs +1 -1
  106. package/lib/components/checkbox/checkbox.vue2.cjs +1 -1
  107. package/lib/components/clamp/clamp.vue2.cjs +1 -1
  108. package/lib/components/clamp-toggle/clamp-toggle.vue2.cjs +1 -1
  109. package/lib/components/col/col.vue2.cjs +1 -1
  110. package/lib/components/collapse-transition/src/collapse-transition.vue2.cjs +1 -1
  111. package/lib/components/collection/collection-item.vue2.cjs +1 -1
  112. package/lib/components/collection/collection.vue2.cjs +1 -1
  113. package/lib/components/color-picker/color-picker.vue2.cjs +1 -1
  114. package/lib/components/color-picker/components/alpha-slider.vue2.cjs +1 -1
  115. package/lib/components/config-provider/config-provider.vue2.cjs +1 -1
  116. package/lib/components/container/aside.vue2.cjs +1 -1
  117. package/lib/components/container/container.vue2.cjs +1 -1
  118. package/lib/components/container/footer.vue2.cjs +1 -1
  119. package/lib/components/container/header.vue2.cjs +1 -1
  120. package/lib/components/container/main.vue2.cjs +1 -1
  121. package/lib/components/context-menu/context-menu.vue2.cjs +1 -1
  122. package/lib/components/date-picker/date-picker-com/basic-date-table.vue2.cjs +1 -1
  123. package/lib/components/date-picker/date-picker-com/basic-month-table.vue2.cjs +1 -1
  124. package/lib/components/date-picker/date-picker-com/basic-year-table.vue2.cjs +1 -1
  125. package/lib/components/date-picker/date-picker-com/panel-date-pick.vue2.cjs +1 -1
  126. package/lib/components/date-picker/date-picker-com/panel-month-range.vue2.cjs +1 -1
  127. package/lib/components/date-time-select/date-time-select.vue2.cjs +1 -1
  128. package/lib/components/descriptions/description-item.vue2.cjs +1 -1
  129. package/lib/components/descriptions/description.vue2.cjs +1 -1
  130. package/lib/components/descriptions/descriptions-row.vue2.cjs +1 -1
  131. package/lib/components/dialog/dialog-content.vue2.cjs +1 -1
  132. package/lib/components/dialog/dialog.vue2.cjs +1 -1
  133. package/lib/components/divider/divider.vue2.cjs +1 -1
  134. package/lib/components/dropdown/dropdown.vue2.cjs +1 -1
  135. package/lib/components/empty/empty.vue2.cjs +1 -1
  136. package/lib/components/footer-layout/footer-layout.vue2.cjs +1 -1
  137. package/lib/components/form/form-item.vue2.cjs +1 -1
  138. package/lib/components/form/form.vue2.cjs +1 -1
  139. package/lib/components/full-screen/full-screen.vue2.cjs +1 -1
  140. package/lib/components/header-layout/header-layout.vue2.cjs +1 -1
  141. package/lib/components/horizontal-menu/horizontal-menu.vue2.cjs +1 -1
  142. package/lib/components/icon/icon.vue2.cjs +1 -1
  143. package/lib/components/icon-text/icon-text.vue2.cjs +1 -1
  144. package/lib/components/iframe-layout/iframe-layout.vue2.cjs +1 -1
  145. package/lib/components/iframe-layout/iframe-page.vue2.cjs +1 -1
  146. package/lib/components/image/image.vue2.cjs +1 -1
  147. package/lib/components/image-viewer/image-viewer.vue2.cjs +1 -1
  148. package/lib/components/link/link.vue2.cjs +1 -1
  149. package/lib/components/list-cell/list-cell.vue2.cjs +1 -1
  150. package/lib/components/logo/logo.vue2.cjs +1 -1
  151. package/lib/components/md-comment/md-comment.vue2.cjs +1 -1
  152. package/lib/components/md-container/md-container.vue2.cjs +1 -1
  153. package/lib/components/md-vue-playground/md-vue-playground.vue2.cjs +1 -1
  154. package/lib/components/menu/menu-item-group.vue2.cjs +1 -1
  155. package/lib/components/menu/menu-item.vue2.cjs +1 -1
  156. package/lib/components/menu/menu.vue2.cjs +1 -1
  157. package/lib/components/menu/sub-menu.vue2.cjs +1 -1
  158. package/lib/components/multiple-tabs/multiple-tabs.vue2.cjs +1 -1
  159. package/lib/components/overlay/overlay.vue2.cjs +1 -1
  160. package/lib/components/page-wrapper/page-wrapper.vue2.cjs +1 -1
  161. package/lib/components/pagination/pagination.vue2.cjs +1 -1
  162. package/lib/components/popconfirm/popconfirm.vue2.cjs +1 -1
  163. package/lib/components/popover/popover.vue2.cjs +1 -1
  164. package/lib/components/popper/arrow.vue2.cjs +1 -1
  165. package/lib/components/popper/content.vue2.cjs +1 -1
  166. package/lib/components/popper/popper.vue2.cjs +1 -1
  167. package/lib/components/popper/trigger.vue2.cjs +1 -1
  168. package/lib/components/qrcode/qrcode.vue2.cjs +1 -1
  169. package/lib/components/radio/radio-button.vue2.cjs +1 -1
  170. package/lib/components/radio/radio-group.vue2.cjs +1 -1
  171. package/lib/components/radio/radio.vue2.cjs +1 -1
  172. package/lib/components/result/result.vue2.cjs +1 -1
  173. package/lib/components/router-view-content/router-view-content.vue2.cjs +1 -1
  174. package/lib/components/row/row.vue2.cjs +1 -1
  175. package/lib/components/scrollbar/scrollbar.vue2.cjs +1 -1
  176. package/lib/components/search/search.vue2.cjs +1 -1
  177. package/lib/components/side-menu/side-menu.vue2.cjs +1 -1
  178. package/lib/components/skeleton/skeleton-item.vue2.cjs +1 -1
  179. package/lib/components/skeleton/skeleton.vue2.cjs +1 -1
  180. package/lib/components/switch/switch.vue2.cjs +1 -1
  181. package/lib/components/table/table.vue2.cjs +1 -1
  182. package/lib/components/tabs/tab-nav.vue2.cjs +1 -1
  183. package/lib/components/tabs/tab-pane.vue2.cjs +1 -1
  184. package/lib/components/tabs/tabs.vue2.cjs +1 -1
  185. package/lib/components/time-picker/common/picker.vue2.cjs +1 -1
  186. package/lib/components/time-select/time-select.vue2.cjs +1 -1
  187. package/lib/components/tooltip/content.vue2.cjs +1 -1
  188. package/lib/components/tooltip/tooltip.vue2.cjs +1 -1
  189. package/lib/components/tooltip/trigger.vue2.cjs +1 -1
  190. package/lib/components/verify-code/verify-code.vue2.cjs +1 -1
  191. package/lib/constants/date.cjs +1 -1
  192. package/lib/package.json.cjs +1 -1
  193. package/package.json +8 -8
  194. package/web-types.json +1 -1
@@ -1,4 +1,4 @@
1
- import { defineComponent as q, useAttrs as J, ref as s, computed as h, watch as y, createVNode as C, reactive as K, onMounted as Q, resolveComponent as U, openBlock as b, createElementBlock as Z, normalizeClass as S, unref as n, createBlock as L, mergeProps as w, createCommentVNode as R, createSlots as _, withCtx as P, withDirectives as ee, createElementVNode as O, vShow as te } from "vue";
1
+ import { defineComponent as Y, useAttrs as J, ref as s, computed as v, watch as y, createVNode as b, reactive as K, onMounted as Q, resolveComponent as U, openBlock as C, createElementBlock as Z, normalizeClass as w, unref as n, createBlock as H, mergeProps as S, createCommentVNode as L, createSlots as _, withCtx as R, withDirectives as ee, createElementVNode as O, vShow as te } from "vue";
2
2
  import { VftEmpty as ae } from "../empty/index.js";
3
3
  import { VftPagination as W } from "../pagination/index.js";
4
4
  import { useNamespace as le } from "../../hooks/use-namespace/index.js";
@@ -13,10 +13,9 @@ import { EmptyEnum as re } from "../empty/constants.js";
13
13
  const r = (
14
14
  /* hoist-static*/
15
15
  le("table")
16
- ), ie = q({
17
- name: r.b()
18
- }), be = /* @__PURE__ */ q({
19
- ...ie,
16
+ ), be = /* @__PURE__ */ Y({
17
+ name: r.b(),
18
+ __name: "table",
20
19
  props: {
21
20
  maxHeight: {},
22
21
  columns: {},
@@ -44,6 +43,10 @@ const r = (
44
43
  sticky: {
45
44
  type: [Boolean, Object]
46
45
  },
46
+ showPager: {
47
+ type: Boolean,
48
+ default: !0
49
+ },
47
50
  pagePlacement: {
48
51
  default: "bottom-right"
49
52
  },
@@ -51,18 +54,18 @@ const r = (
51
54
  },
52
55
  emits: ["page-change", "sort-change", "update:pageNum"],
53
56
  setup(l, {
54
- expose: T,
57
+ expose: q,
55
58
  emit: d
56
59
  }) {
57
- const V = J(), $ = s(0), i = s(), A = ne(() => G(), 120), k = h(() => l.pagePlacement.startsWith("bottom")), D = h(() => l.columns.map((e) => (e.align || (e.align = "center"), !e.formatter && !e.slots && !e.cellRender && (e.formatter = ({
60
+ const T = J(), V = s(0), i = s(), $ = ne(() => D(), 120), k = v(() => l.pagePlacement.startsWith("bottom")), A = v(() => l.columns.map((e) => (e.align || (e.align = "center"), !e.formatter && !e.slots && !e.cellRender && (e.formatter = ({
58
61
  cellValue: t
59
62
  }) => t || "-"), e)));
60
63
  y([() => l.loading, () => l.data, () => l.columns], () => {
61
- A();
64
+ $();
62
65
  }, {
63
66
  immediate: !0
64
67
  });
65
- function G() {
68
+ function D() {
66
69
  g.data = l.data, N(l.pageNum);
67
70
  }
68
71
  I.renderer.add("Encrypt", {
@@ -70,11 +73,11 @@ const r = (
70
73
  renderDefault(e, t) {
71
74
  const {
72
75
  row: a,
73
- column: f
76
+ column: p
74
77
  } = t;
75
- return C("span", {
78
+ return b("span", {
76
79
  class: "line-clamp",
77
- innerHTML: a[f.field] || "-"
80
+ innerHTML: a[p.field] || "-"
78
81
  }, null);
79
82
  }
80
83
  }), I.formats.mixin({
@@ -84,13 +87,13 @@ const r = (
84
87
  return e || "-";
85
88
  }
86
89
  });
87
- function M(e) {
90
+ function G(e) {
88
91
  d("page-change", e), d("update:pageNum", e);
89
92
  }
90
- const X = () => ({
93
+ const M = () => ({
91
94
  maxHeight: "88px",
92
95
  height: "44px"
93
- }), j = (e) => {
96
+ }), X = (e) => {
94
97
  var a;
95
98
  const {
96
99
  column: t
@@ -111,12 +114,12 @@ const r = (
111
114
  orders: ["desc", "asc", null]
112
115
  },
113
116
  seqConfig: {
114
- startIndex: $.value
117
+ startIndex: V.value
115
118
  },
116
119
  cellClassName: "cellClass",
117
120
  rowClassName: "rowClass",
118
- cellStyle: j,
119
- rowStyle: X,
121
+ cellStyle: X,
122
+ rowStyle: M,
120
123
  headerRowClassName: "headerRowClass",
121
124
  headerAlign: "center",
122
125
  columnConfig: {
@@ -133,8 +136,8 @@ const r = (
133
136
  enabled: !1
134
137
  },
135
138
  ...l.tableConfig,
136
- ...V
137
- }), F = (e) => {
139
+ ...T
140
+ }), j = (e) => {
138
141
  d("sort-change", e);
139
142
  };
140
143
  y(() => l.pageNum, (e) => {
@@ -143,37 +146,37 @@ const r = (
143
146
  const N = (e) => {
144
147
  g.seqConfig && (g.seqConfig.startIndex = (e - 1) * l.pageSize);
145
148
  }, u = s(), z = s();
146
- let p = s(!1), o = s(null), m = s(null);
147
- const c = h(() => {
149
+ let f = s(!1), o = s(null), m = s(null);
150
+ const c = v(() => {
148
151
  var e;
149
152
  return ((e = l.sticky) == null ? void 0 : e.getContainer) || document.documentElement || document.body;
150
153
  });
151
154
  y(() => [i, l.sticky], () => {
152
155
  var e, t, a;
153
- (e = i.value) != null && e.$el && l.sticky && ((t = c.value) == null || t.removeEventListener("scroll", v), (a = c.value) == null || a.addEventListener("scroll", v), setTimeout(() => {
154
- E();
156
+ (e = i.value) != null && e.$el && l.sticky && ((t = c.value) == null || t.removeEventListener("scroll", h), (a = c.value) == null || a.addEventListener("scroll", h), setTimeout(() => {
157
+ B();
155
158
  }, 50));
156
159
  }, {
157
160
  immediate: !0,
158
161
  deep: !0
159
162
  });
160
- function E() {
161
- if (!o.value || !m.value || (v(), !p.value))
163
+ function B() {
164
+ if (!o.value || !m.value || (h(), !f.value))
162
165
  return;
163
166
  const e = o.value.clientWidth, t = m.value.offsetWidth;
164
167
  u.value.style.width = e - 1 + "px", z.value.style.width = t + "px";
165
168
  }
166
- function v() {
167
- var x, B, H;
168
- if (!((x = i.value) != null && x.$el) || !o.value || !c.value)
169
+ function h() {
170
+ var E, P, x;
171
+ if (!((E = i.value) != null && E.$el) || !o.value || !c.value)
169
172
  return;
170
- const e = ((B = c.value) == null ? void 0 : B.clientHeight) || window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight, {
173
+ const e = ((P = c.value) == null ? void 0 : P.clientHeight) || window.innerHeight || document.documentElement.clientHeight || document.body.clientHeight, {
171
174
  top: t,
172
175
  bottom: a
173
- } = o.value.getBoundingClientRect(), f = ((H = c.value) == null ? void 0 : H.getBoundingClientRect().top) || document.body.getBoundingClientRect().top;
174
- p.value = t < e && a > e && a - f > e, u.value.scrollLeft = o.value.scrollLeft;
176
+ } = o.value.getBoundingClientRect(), p = ((x = c.value) == null ? void 0 : x.getBoundingClientRect().top) || document.body.getBoundingClientRect().top;
177
+ f.value = t < e && a > e && a - p > e, u.value.scrollLeft = o.value.scrollLeft;
175
178
  }
176
- const Y = () => {
179
+ const F = () => {
177
180
  var t;
178
181
  const e = (t = i.value) == null ? void 0 : t.$el;
179
182
  e && (o.value = e.querySelector(".vxe-table--body-wrapper"), m.value = e.querySelector(".vxe-table--body"), !(!o.value && !m.value) && (o.value.addEventListener("scroll", function(a) {
@@ -183,61 +186,61 @@ const r = (
183
186
  })));
184
187
  };
185
188
  return Q(() => {
186
- l.sticky && (Y(), oe(i, () => E()));
187
- }), T({
189
+ l.sticky && (F(), oe(i, () => B()));
190
+ }), q({
188
191
  table: i
189
192
  }), (e, t) => {
190
193
  const a = U("vxe-grid");
191
- return b(), Z("div", {
192
- class: S(n(r).b())
193
- }, [k.value ? R("", !0) : (b(), L(n(W), w({
194
+ return C(), Z("div", {
195
+ class: w(n(r).b())
196
+ }, [e.showPager && !k.value ? (C(), H(n(W), S({
194
197
  key: 0,
195
198
  class: [n(r).e("pager"), n(r).m("pager-" + e.pagePlacement)],
196
199
  layout: "prev, pager, next"
197
200
  }, e.pageOptions, {
198
201
  total: e.total,
199
202
  "page-size": e.pageSize,
200
- onCurrentChange: t[0] || (t[0] = (f) => d("page-change", e.pageNum)),
203
+ onCurrentChange: t[0] || (t[0] = (p) => d("page-change", e.pageNum)),
201
204
  "current-page": e.pageNum
202
- }), null, 16, ["class", "total", "page-size", "current-page"])), C(a, w({
205
+ }), null, 16, ["class", "total", "page-size", "current-page"])) : L("", !0), b(a, S({
203
206
  ref_key: "xGrid",
204
207
  ref: i
205
208
  }, g, {
206
209
  height: e.height,
207
210
  "max-height": e.maxHeight,
208
- columns: D.value,
211
+ columns: A.value,
209
212
  data: e.data,
210
213
  "auto-resize": "",
211
214
  loading: e.loading,
212
215
  resizable: "",
213
- onSortChange: F
216
+ onSortChange: j
214
217
  }), _({
215
- empty: P(() => [C(n(ae), {
218
+ empty: R(() => [b(n(ae), {
216
219
  type: n(re).NO_DATA
217
220
  }, null, 8, ["type"])]),
218
221
  _: 2
219
222
  }, [e.sticky ? {
220
223
  name: "bottom",
221
- fn: P(() => [ee(O("div", {
224
+ fn: R(() => [ee(O("div", {
222
225
  ref_key: "stickyScroll",
223
226
  ref: u,
224
- class: S(n(r).e("sticky-scroll-warpper"))
227
+ class: w(n(r).e("sticky-scroll-warpper"))
225
228
  }, [O("div", {
226
229
  ref_key: "stickyScrollBar",
227
230
  ref: z,
228
- class: S(n(r).e("sticky-scroll-bar"))
229
- }, null, 2)], 2), [[te, n(p)]])]),
231
+ class: w(n(r).e("sticky-scroll-bar"))
232
+ }, null, 2)], 2), [[te, n(f)]])]),
230
233
  key: "0"
231
- } : void 0]), 1040, ["height", "max-height", "columns", "data", "loading"]), k.value ? (b(), L(n(W), w({
234
+ } : void 0]), 1040, ["height", "max-height", "columns", "data", "loading"]), e.showPager && k.value ? (C(), H(n(W), S({
232
235
  key: 1,
233
236
  class: [n(r).e("pager"), n(r).m("pager-" + e.pagePlacement)],
234
237
  layout: "prev, pager, next"
235
238
  }, e.pageOptions, {
236
239
  total: e.total,
237
240
  "page-size": e.pageSize,
238
- onCurrentChange: M,
241
+ onCurrentChange: G,
239
242
  "current-page": e.pageNum
240
- }), null, 16, ["class", "total", "page-size", "current-page"])) : R("", !0)], 2);
243
+ }), null, 16, ["class", "total", "page-size", "current-page"])) : L("", !0)], 2);
241
244
  };
242
245
  }
243
246
  });
@@ -1,4 +1,4 @@
1
- import { defineComponent as E, getCurrentInstance as Z, inject as _, ref as g, computed as I, watch as O, onMounted as tt, onUpdated as ot, createVNode as l, nextTick as et } from "vue";
1
+ import { defineComponent as Q, getCurrentInstance as Z, inject as _, ref as g, computed as I, watch as O, onMounted as tt, onUpdated as ot, createVNode as l, nextTick as et } from "vue";
2
2
  import { capitalize as $ } from "@vft/utils";
3
3
  import { throwError as it } from "../../utils/error.js";
4
4
  import "lodash";
@@ -88,13 +88,12 @@ import "../../hooks/use-z-index/index.js";
88
88
  import { EVENT_CODE as T } from "@vft/constants";
89
89
  import { TabsRootContextKey as st } from "./types.js";
90
90
  import lt from "./tab-bar.vue2.js";
91
- const V = (
91
+ const E = (
92
92
  /* hoist-static*/
93
93
  K("tab-nav")
94
- ), ct = E({
95
- name: V.b()
96
- }), Xo = /* @__PURE__ */ E({
97
- ...ct,
94
+ ), Uo = /* @__PURE__ */ Q({
95
+ name: E.b(),
96
+ __name: "tab-nav",
98
97
  props: {
99
98
  panes: {},
100
99
  editable: {
@@ -117,20 +116,20 @@ const V = (
117
116
  },
118
117
  emits: ["tabClick", "tabRemove", "tabAdd", "tabContextmenu"],
119
118
  setup(n, {
120
- expose: D,
119
+ expose: V,
121
120
  emit: h
122
121
  }) {
123
122
  var A;
124
- const M = Z(), d = _(st);
125
- d || it(V.b(), "<vft-tabs><tab-nav /></vft-tabs>");
126
- const e = K("tabs"), q = nt(), H = rt(), y = g(), v = g(), C = g(), m = g(!1), f = g(0), k = g(!1), x = g(!0), w = I(() => ["top", "bottom"].includes(d.props.tabPosition) ? "width" : "height"), W = I(() => ({
123
+ const D = Z(), d = _(st);
124
+ d || it(E.b(), "<vft-tabs><tab-nav /></vft-tabs>");
125
+ const e = K("tabs"), M = nt(), q = rt(), y = g(), v = g(), C = g(), m = g(!1), f = g(0), k = g(!1), x = g(!0), w = I(() => ["top", "bottom"].includes(d.props.tabPosition) ? "width" : "height"), H = I(() => ({
127
126
  transform: `translate${w.value === "width" ? "X" : "Y"}(-${f.value}px)`
128
- })), j = () => {
127
+ })), W = () => {
129
128
  if (!v.value)
130
129
  return;
131
130
  const o = v.value[`offset${$(w.value)}`], t = f.value;
132
131
  t && (f.value = t > o ? t - o : 0);
133
- }, U = () => {
132
+ }, j = () => {
134
133
  if (!v.value || !C.value)
135
134
  return;
136
135
  const o = C.value[`offset${$(w.value)}`], t = v.value[`offset${$(w.value)}`], i = f.value;
@@ -151,7 +150,7 @@ const V = (
151
150
  return;
152
151
  const o = C.value[`offset${$(w.value)}`], t = v.value[`offset${$(w.value)}`], i = f.value;
153
152
  t < o ? (m.value = m.value || {}, m.value.prev = i, m.value.next = i + t < o, o - i < t && (f.value = o - t)) : (m.value = !1, i > 0 && (f.value = 0));
154
- }, X = (o) => {
153
+ }, U = (o) => {
155
154
  const t = o.code, {
156
155
  up: i,
157
156
  down: b,
@@ -166,26 +165,26 @@ const V = (
166
165
  }, P = () => {
167
166
  x.value && (k.value = !0);
168
167
  }, S = () => k.value = !1;
169
- O(q, (o) => {
168
+ O(M, (o) => {
170
169
  o === "hidden" ? x.value = !1 : o === "visible" && setTimeout(() => x.value = !0, 50);
171
- }), O(H, (o) => {
170
+ }), O(q, (o) => {
172
171
  o ? setTimeout(() => x.value = !0, 50) : x.value = !1;
173
- }), at(y, z), tt(() => setTimeout(() => R(), 0)), ot(() => z()), D({
172
+ }), at(y, z), tt(() => setTimeout(() => R(), 0)), ot(() => z()), V({
174
173
  scrollToActiveTab: R,
175
174
  removeFocus: S
176
- }), O(() => n.panes, () => M.update(), {
175
+ }), O(() => n.panes, () => D.update(), {
177
176
  flush: "post"
178
177
  });
179
- const Y = I(() => {
178
+ const X = I(() => {
180
179
  var o, t;
181
180
  return m.value ? [l("span", {
182
181
  class: [e.e("nav-prev"), e.is("disabled", !m.value.prev)],
183
- onClick: j
182
+ onClick: W
184
183
  }, [(o = n.arrowLeftIconCfg) != null && o.icon ? l(B, n.arrowLeftIconCfg, null) : null]), l("span", {
185
184
  class: [e.e("nav-next"), e.is("disabled", !m.value.next)],
186
- onClick: U
185
+ onClick: j
187
186
  }, [(t = n.arrowRightIconCfg) != null && t.icon ? l(B, n.arrowRightIconCfg, null) : null])] : null;
188
- }), G = I(() => {
187
+ }), Y = I(() => {
189
188
  var o;
190
189
  return (o = n.panes) == null ? void 0 : o.map((t, i) => {
191
190
  var N, F, L;
@@ -194,7 +193,7 @@ const V = (
194
193
  const c = u ? l("span", {
195
194
  class: "is-icon-close",
196
195
  onClick: (p) => h("tabRemove", t, p)
197
- }, [(N = n.closeIconCfg) != null && N.icon ? l(B, n.closeIconCfg, null) : null]) : null, a = ((L = (F = t.slots).label) == null ? void 0 : L.call(F)) || t.props.label, Q = !s && t.active ? 0 : -1;
196
+ }, [(N = n.closeIconCfg) != null && N.icon ? l(B, n.closeIconCfg, null) : null]) : null, a = ((L = (F = t.slots).label) == null ? void 0 : L.call(F)) || t.props.label, J = !s && t.active ? 0 : -1;
198
197
  return l("div", {
199
198
  ref: `tab-${b}`,
200
199
  class: [e.e("item"), e.is(d.props.tabPosition), e.is("active", t.active), e.is("disabled", s), e.is("closable", u), e.is("focus", k.value)],
@@ -203,7 +202,7 @@ const V = (
203
202
  "aria-controls": `pane-${r}`,
204
203
  role: "tab",
205
204
  "aria-selected": t.active,
206
- tabindex: Q,
205
+ tabindex: J,
207
206
  onFocus: () => P(),
208
207
  onBlur: () => S(),
209
208
  onClick: (p) => {
@@ -221,7 +220,7 @@ const V = (
221
220
  }
222
221
  }, [a, c]);
223
222
  });
224
- }), J = n.editable || n.addable ? l("span", {
223
+ }), G = n.editable || n.addable ? l("span", {
225
224
  class: e.e("new-tab"),
226
225
  tabindex: "0",
227
226
  onClick: () => h("tabAdd"),
@@ -232,20 +231,20 @@ const V = (
232
231
  return () => l("div", {
233
232
  ref: y,
234
233
  class: [e.e("nav-wrap"), e.is("scrollable", !!m.value), e.is(d.props.tabPosition)]
235
- }, [Y.value, l("div", {
234
+ }, [X.value, l("div", {
236
235
  class: e.e("nav-scroll"),
237
236
  ref: v
238
237
  }, [l("div", {
239
238
  class: [e.e("nav"), e.is(d.props.tabPosition), e.is("stretch", n.stretch && ["top", "bottom"].includes(d.props.tabPosition))],
240
239
  ref: C,
241
- style: W.value,
240
+ style: H.value,
242
241
  role: "tablist",
243
- onKeydown: X
242
+ onKeydown: U
244
243
  }, [n.showBar ? l(lt, {
245
244
  tabs: [...n.panes]
246
- }, null) : null, G.value]), J])]);
245
+ }, null) : null, Y.value]), G])]);
247
246
  }
248
247
  });
249
248
  export {
250
- Xo as default
249
+ Uo as default
251
250
  };
@@ -1,20 +1,19 @@
1
- import { defineComponent as b, getCurrentInstance as y, useSlots as C, inject as B, ref as m, computed as d, watch as g, reactive as w, onMounted as N, onUnmounted as k, unref as o, withDirectives as x, openBlock as z, createElementBlock as R, normalizeClass as S, renderSlot as _, vShow as $, createCommentVNode as E } from "vue";
1
+ import { defineComponent as h, getCurrentInstance as y, useSlots as C, inject as B, ref as u, computed as d, watch as g, reactive as w, onMounted as N, onUnmounted as k, unref as o, withDirectives as x, openBlock as z, createElementBlock as R, normalizeClass as S, renderSlot as $, vShow as E, createCommentVNode as P } from "vue";
2
2
  import "@vft/utils";
3
- import { throwError as P } from "../../utils/error.js";
3
+ import { throwError as j } from "../../utils/error.js";
4
4
  import "lodash";
5
5
  import { eagerComputed as p } from "@vueuse/core";
6
6
  import "../../utils/ns-cover.js";
7
- import { TabsRootContextKey as j } from "./types.js";
8
- import { useNamespace as D } from "../../hooks/use-namespace/index.js";
7
+ import { TabsRootContextKey as D } from "./types.js";
8
+ import { useNamespace as I } from "../../hooks/use-namespace/index.js";
9
9
  import "@popperjs/core";
10
10
  import "../../hooks/use-z-index/index.js";
11
- const I = ["id", "aria-hidden", "aria-labelledby"], i = (
11
+ const K = ["id", "aria-hidden", "aria-labelledby"], i = (
12
12
  /* hoist-static*/
13
- D("tab-pane")
14
- ), K = b({
15
- name: i.b()
16
- }), O = /* @__PURE__ */ b({
17
- ...K,
13
+ I("tab-pane")
14
+ ), L = /* @__PURE__ */ h({
15
+ name: i.b(),
16
+ __name: "tab-pane",
18
17
  props: {
19
18
  label: {},
20
19
  name: {},
@@ -23,27 +22,27 @@ const I = ["id", "aria-hidden", "aria-labelledby"], i = (
23
22
  lazy: { type: Boolean }
24
23
  },
25
24
  setup(a) {
26
- const n = y(), v = C(), t = B(j);
27
- t || P(i.b(), "usage: <vft-tabs><vft-tab-pane /></vft-tabs/>");
28
- const r = m(), f = d(() => a.closable || t.props.closable), e = p(() => t.currentName.value === (a.name ?? r.value)), c = m(e.value), s = d(() => a.name ?? r.value), h = p(() => !a.lazy || c.value || e.value);
25
+ const n = y(), b = C(), t = B(D);
26
+ t || j(i.b(), "usage: <vft-tabs><vft-tab-pane /></vft-tabs/>");
27
+ const r = u(), v = d(() => a.closable || t.props.closable), e = p(() => t.currentName.value === (a.name ?? r.value)), c = u(e.value), s = d(() => a.name ?? r.value), f = p(() => !a.lazy || c.value || e.value);
29
28
  g(e, (l) => {
30
29
  l && (c.value = !0);
31
30
  });
32
- const u = w({
31
+ const m = w({
33
32
  uid: n.uid,
34
- slots: v,
33
+ slots: b,
35
34
  props: n.props,
36
35
  paneName: s,
37
36
  active: e,
38
37
  index: r,
39
- isClosable: f,
38
+ isClosable: v,
40
39
  attrs: n.attrs
41
40
  });
42
41
  return N(() => {
43
- t.registerPane(u);
42
+ t.registerPane(m);
44
43
  }), k(() => {
45
- t.unregisterPane(u.uid);
46
- }), (l, M) => o(h) ? x((z(), R("div", {
44
+ t.unregisterPane(m.uid);
45
+ }), (l, M) => o(f) ? x((z(), R("div", {
47
46
  key: 0,
48
47
  id: `pane-${s.value}`,
49
48
  class: S(o(i).b()),
@@ -51,12 +50,12 @@ const I = ["id", "aria-hidden", "aria-labelledby"], i = (
51
50
  "aria-hidden": !o(e),
52
51
  "aria-labelledby": `tab-${s.value}`
53
52
  }, [
54
- _(l.$slots, "default")
55
- ], 10, I)), [
56
- [$, o(e)]
57
- ]) : E("", !0);
53
+ $(l.$slots, "default")
54
+ ], 10, K)), [
55
+ [E, o(e)]
56
+ ]) : P("", !0);
58
57
  }
59
58
  });
60
59
  export {
61
- O as default
60
+ L as default
62
61
  };
@@ -1,4 +1,4 @@
1
- import { defineComponent as w, getCurrentInstance as g, useSlots as M, ref as h, watch as p, nextTick as D, computed as d, createVNode as l, provide as O } from "vue";
1
+ import { defineComponent as z, getCurrentInstance as g, useSlots as M, ref as h, watch as p, nextTick as D, computed as d, createVNode as l, provide as O } from "vue";
2
2
  import { useNamespace as U } from "../../hooks/use-namespace/index.js";
3
3
  import "@popperjs/core";
4
4
  import "lodash";
@@ -13,10 +13,9 @@ import { TabsRootContextKey as S } from "./types.js";
13
13
  const s = (
14
14
  /* hoist-static*/
15
15
  U("tabs")
16
- ), j = w({
17
- name: s.b()
18
- }), oe = /* @__PURE__ */ w({
19
- ...j,
16
+ ), te = /* @__PURE__ */ z({
17
+ name: s.b(),
18
+ __name: "tabs",
20
19
  props: {
21
20
  closable: {
22
21
  type: Boolean
@@ -62,27 +61,27 @@ const s = (
62
61
  expose: c,
63
62
  emit: t
64
63
  }) {
65
- const T = g(), i = M(), u = h(), r = h(a.modelValue ?? "0"), R = (e) => {
64
+ const w = g(), i = M(), u = h(), r = h(a.modelValue ?? "0"), T = (e) => {
66
65
  r.value = e, t("update:modelValue", e), t("tabChange", e);
67
66
  }, m = async (e) => {
68
67
  var o, n, v;
69
68
  if (!(r.value === e || I(e)))
70
69
  try {
71
- await ((o = a.beforeLeave) == null ? void 0 : o.call(a, e, r.value)) !== !1 && (R(e), (v = (n = u.value) == null ? void 0 : n.removeFocus) == null || v.call(n));
70
+ await ((o = a.beforeLeave) == null ? void 0 : o.call(a, e, r.value)) !== !1 && (T(e), (v = (n = u.value) == null ? void 0 : n.removeFocus) == null || v.call(n));
72
71
  } catch {
73
72
  }
74
- }, x = (e, o, n) => {
73
+ }, R = (e, o, n) => {
75
74
  e.props.disabled || (m(o), t("tabClick", e, n));
76
- }, y = (e, o) => {
75
+ }, x = (e, o) => {
77
76
  e.props.disabled || I(e.props.name) || (o.stopPropagation(), t("edit", e.props.name, "remove"), t("tabRemove", e.props.name));
78
77
  };
79
78
  p(() => a.modelValue, (e) => m(e)), p(r, async () => {
80
79
  var e;
81
80
  await D(), (e = u.value) == null || e.scrollToActiveTab();
82
81
  });
83
- const L = () => {
82
+ const y = () => {
84
83
  t("edit", void 0, "add"), t("tabAdd");
85
- }, N = (e, o, n) => {
84
+ }, L = (e, o, n) => {
86
85
  t("tabContextMenu", e, o, n);
87
86
  }, b = d(() => {
88
87
  var e;
@@ -90,31 +89,31 @@ const s = (
90
89
  class: s.e("content")
91
90
  }, [(e = i.default) == null ? void 0 : e.call(i)]);
92
91
  }), {
93
- children: B,
94
- addChild: P,
95
- removeChild: A
92
+ children: N,
93
+ addChild: B,
94
+ removeChild: P
96
95
  } = $(g(), "vft-tab-pane");
97
96
  O(S, {
98
- props: T.props,
97
+ props: w.props,
99
98
  currentName: r,
100
- registerPane: P,
101
- unregisterPane: A
99
+ registerPane: B,
100
+ unregisterPane: P
102
101
  }), c({
103
102
  currentName: r
104
103
  });
105
- const E = d(() => ({
104
+ const A = d(() => ({
106
105
  icon: "ico-ep:plus",
107
106
  size: 12,
108
107
  ...a.addIconCfg
109
- })), V = d(() => ({
108
+ })), E = d(() => ({
110
109
  icon: "ico-ep:close",
111
110
  size: 14,
112
111
  ...a.closeIconCfg
113
- })), k = d(() => ({
112
+ })), V = d(() => ({
114
113
  icon: "ico-ep:arrow-left",
115
114
  size: 18,
116
115
  ...a.arrowLeftIconCfg
117
- })), z = d(() => ({
116
+ })), k = d(() => ({
118
117
  icon: "ico-ep:arrow-right",
119
118
  size: 18,
120
119
  ...a.arrowRightIconCfg
@@ -125,19 +124,19 @@ const s = (
125
124
  }, [l(K, {
126
125
  ref: u,
127
126
  currentName: r.value,
128
- panes: B.value,
127
+ panes: N.value,
129
128
  stretch: a.stretch,
130
129
  showBar: a.showBar,
131
- closeIconCfg: V.value,
132
- addIconCfg: E.value,
133
- arrowRightIconCfg: z.value,
134
- arrowLeftIconCfg: k.value,
130
+ closeIconCfg: E.value,
131
+ addIconCfg: A.value,
132
+ arrowRightIconCfg: k.value,
133
+ arrowLeftIconCfg: V.value,
135
134
  editable: a.editable,
136
135
  addable: a.addable,
137
- onTabClick: x,
138
- onTabRemove: y,
139
- onTabAdd: L,
140
- onTabContextmenu: N
136
+ onTabClick: R,
137
+ onTabRemove: x,
138
+ onTabAdd: y,
139
+ onTabContextmenu: L
141
140
  }, null), (e = i.headerRight) == null ? void 0 : e.call(i)]);
142
141
  });
143
142
  return () => l("div", {
@@ -146,5 +145,5 @@ const s = (
146
145
  }
147
146
  });
148
147
  export {
149
- oe as default
148
+ te as default
150
149
  };