tabula-vue 1.0.0 → 1.0.2

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 (204) hide show
  1. package/es/component.mjs +4 -0
  2. package/es/components/dialog/index.d.ts +30 -30
  3. package/es/components/dialog/src/index.vue.d.ts +2 -2
  4. package/es/components/dialog-form/index.d.ts +2 -2
  5. package/es/components/dialog-form/src/index.vue.d.ts +2 -2
  6. package/es/components/display-item/index.d.ts +25 -25
  7. package/es/components/display-item/src/index.vue.d.ts +7 -7
  8. package/es/components/drawer-form/index.d.ts +50 -50
  9. package/es/components/drawer-form/src/index.vue.d.ts +10 -10
  10. package/es/components/form/index.d.ts +99 -99
  11. package/es/components/form/src/form-content.vue.d.ts +12 -12
  12. package/es/components/form/src/index.vue.d.ts +11 -11
  13. package/es/components/form-item/index.d.ts +80 -80
  14. package/es/components/form-item/src/index.vue.d.ts +9 -9
  15. package/es/components/index.d.ts +2 -0
  16. package/es/components/index.mjs +6 -0
  17. package/es/components/input-tag/index.d.ts +6 -6
  18. package/es/components/input-tag/src/index.vue.d.ts +6 -6
  19. package/es/components/layout/index.d.ts +30 -30
  20. package/es/components/layout/src/index.vue.d.ts +10 -10
  21. package/es/components/page/index.d.ts +9087 -4864
  22. package/es/components/page/src/index.vue.d.ts +1903 -513
  23. package/es/components/page/src/index.vue2.mjs +43 -12
  24. package/es/components/popover/index.d.ts +49 -49
  25. package/es/components/popover/src/index.vue.d.ts +3 -3
  26. package/es/components/render/index.d.ts +14 -14
  27. package/es/components/render/src/index.vue.d.ts +1 -1
  28. package/es/components/search/index.d.ts +298 -298
  29. package/es/components/search/src/index.vue.d.ts +84 -84
  30. package/es/components/sidebar/index.d.ts +31 -31
  31. package/es/components/sidebar/src/index.vue.d.ts +5 -5
  32. package/es/components/table/index.d.ts +165 -180
  33. package/es/components/table/index.mjs +3 -0
  34. package/es/components/table/src/index.vue.d.ts +12 -21
  35. package/es/components/table/src/index.vue2.mjs +11 -34
  36. package/es/components/table/src/table-action-bar-content.vue.d.ts +78 -0
  37. package/es/components/table/src/table-action-bar-content.vue.mjs +6 -0
  38. package/es/components/table/src/table-action-bar-content.vue2.mjs +395 -0
  39. package/es/components/table/src/table-action-bar.vue.d.ts +4 -4
  40. package/es/components/table/src/table-action-bar.vue2.mjs +30 -353
  41. package/es/components/table/src/table-column-drag-sort.vue.d.ts +1 -1
  42. package/es/components/table/src/table-column-index.vue.d.ts +1 -1
  43. package/es/components/table/src/table-column.vue.d.ts +22 -29
  44. package/es/components/table/src/table-column.vue2.mjs +4 -57
  45. package/es/components/table/src/table-title-bar.vue.d.ts +2 -2
  46. package/es/components/table/src/type.d.ts +0 -11
  47. package/es/components/table/src/use-columns.d.ts +26 -0
  48. package/es/components/table/src/use-columns.mjs +40 -0
  49. package/es/components/table-lite/index.d.ts +1783 -0
  50. package/es/components/table-lite/index.mjs +6 -0
  51. package/es/components/table-lite/src/index.vue.d.ts +672 -0
  52. package/es/components/table-lite/src/index.vue.mjs +6 -0
  53. package/es/components/table-lite/src/index.vue2.mjs +681 -0
  54. package/es/components/table-lite/src/type.d.ts +91 -0
  55. package/es/components/table-lite/src/type.mjs +1 -0
  56. package/es/components/table-lite/style/css.d.ts +16 -0
  57. package/es/components/table-lite/style/css.mjs +16 -0
  58. package/es/components/table-lite/style/index.d.ts +16 -0
  59. package/es/components/table-lite/style/index.mjs +16 -0
  60. package/es/components/table-v2/index.d.ts +174 -0
  61. package/es/components/table-v2/index.mjs +7 -0
  62. package/es/components/table-v2/src/column-converter.d.ts +27 -0
  63. package/es/components/table-v2/src/column-converter.mjs +42 -0
  64. package/es/components/table-v2/src/index.vue.d.ts +157 -0
  65. package/es/components/table-v2/src/index.vue.mjs +6 -0
  66. package/es/components/table-v2/src/index.vue2.mjs +491 -0
  67. package/es/components/table-v2/src/special-columns.d.ts +61 -0
  68. package/es/components/table-v2/src/special-columns.mjs +76 -0
  69. package/es/components/table-v2/src/table-v2-cell.d.ts +104 -0
  70. package/es/components/table-v2/src/table-v2-cell.mjs +139 -0
  71. package/es/components/table-v2/src/table-v2-header-cell.vue.d.ts +61 -0
  72. package/es/components/table-v2/src/table-v2-header-cell.vue.mjs +6 -0
  73. package/es/components/table-v2/src/table-v2-header-cell.vue2.mjs +92 -0
  74. package/es/components/table-v2/src/type.d.ts +95 -0
  75. package/es/components/table-v2/src/type.mjs +1 -0
  76. package/es/components/table-v2/src/use-table-v2-columns.d.ts +43 -0
  77. package/es/components/table-v2/src/use-table-v2-columns.mjs +47 -0
  78. package/es/components/table-v2/style/css.d.ts +17 -0
  79. package/es/components/table-v2/style/css.mjs +17 -0
  80. package/es/components/table-v2/style/index.d.ts +17 -0
  81. package/es/components/table-v2/style/index.mjs +17 -0
  82. package/es/index.mjs +6 -0
  83. package/es/version.d.ts +1 -1
  84. package/es/version.mjs +1 -1
  85. package/index.css +1 -1
  86. package/index.js +1850 -279
  87. package/index.min.js +9 -6
  88. package/index.min.mjs +9 -6
  89. package/index.mjs +1813 -248
  90. package/lib/component.js +42 -38
  91. package/lib/components/dialog/index.d.ts +30 -30
  92. package/lib/components/dialog/src/index.vue.d.ts +2 -2
  93. package/lib/components/dialog-form/index.d.ts +2 -2
  94. package/lib/components/dialog-form/src/index.vue.d.ts +2 -2
  95. package/lib/components/display-item/index.d.ts +25 -25
  96. package/lib/components/display-item/src/index.vue.d.ts +7 -7
  97. package/lib/components/drawer-form/index.d.ts +50 -50
  98. package/lib/components/drawer-form/src/index.vue.d.ts +10 -10
  99. package/lib/components/form/index.d.ts +99 -99
  100. package/lib/components/form/src/form-content.vue.d.ts +12 -12
  101. package/lib/components/form/src/index.vue.d.ts +11 -11
  102. package/lib/components/form-item/index.d.ts +80 -80
  103. package/lib/components/form-item/src/index.vue.d.ts +9 -9
  104. package/lib/components/index.d.ts +2 -0
  105. package/lib/components/index.js +51 -39
  106. package/lib/components/input-tag/index.d.ts +6 -6
  107. package/lib/components/input-tag/src/index.vue.d.ts +6 -6
  108. package/lib/components/layout/index.d.ts +30 -30
  109. package/lib/components/layout/src/index.vue.d.ts +10 -10
  110. package/lib/components/page/index.d.ts +9087 -4864
  111. package/lib/components/page/src/index.vue.d.ts +1903 -513
  112. package/lib/components/page/src/index.vue2.js +46 -15
  113. package/lib/components/popover/index.d.ts +49 -49
  114. package/lib/components/popover/src/index.vue.d.ts +3 -3
  115. package/lib/components/render/index.d.ts +14 -14
  116. package/lib/components/render/src/index.vue.d.ts +1 -1
  117. package/lib/components/search/index.d.ts +298 -298
  118. package/lib/components/search/src/index.vue.d.ts +84 -84
  119. package/lib/components/sidebar/index.d.ts +31 -31
  120. package/lib/components/sidebar/src/index.vue.d.ts +5 -5
  121. package/lib/components/table/index.d.ts +165 -180
  122. package/lib/components/table/index.js +6 -0
  123. package/lib/components/table/src/index.vue.d.ts +12 -21
  124. package/lib/components/table/src/index.vue2.js +10 -33
  125. package/lib/components/table/src/table-action-bar-content.vue.d.ts +78 -0
  126. package/lib/components/table/src/table-action-bar-content.vue.js +10 -0
  127. package/lib/components/table/src/table-action-bar-content.vue2.js +399 -0
  128. package/lib/components/table/src/table-action-bar.vue.d.ts +4 -4
  129. package/lib/components/table/src/table-action-bar.vue2.js +28 -351
  130. package/lib/components/table/src/table-column-drag-sort.vue.d.ts +1 -1
  131. package/lib/components/table/src/table-column-index.vue.d.ts +1 -1
  132. package/lib/components/table/src/table-column.vue.d.ts +22 -29
  133. package/lib/components/table/src/table-column.vue2.js +2 -55
  134. package/lib/components/table/src/table-title-bar.vue.d.ts +2 -2
  135. package/lib/components/table/src/type.d.ts +0 -11
  136. package/lib/components/table/src/use-columns.d.ts +26 -0
  137. package/lib/components/table/src/use-columns.js +42 -0
  138. package/lib/components/table-lite/index.d.ts +1783 -0
  139. package/lib/components/table-lite/index.js +8 -0
  140. package/lib/components/table-lite/src/index.vue.d.ts +672 -0
  141. package/lib/components/table-lite/src/index.vue.js +10 -0
  142. package/lib/components/table-lite/src/index.vue2.js +685 -0
  143. package/lib/components/table-lite/src/type.d.ts +91 -0
  144. package/lib/components/table-lite/src/type.js +2 -0
  145. package/lib/components/table-lite/style/css.d.ts +16 -0
  146. package/lib/components/table-lite/style/css.js +19 -0
  147. package/lib/components/table-lite/style/index.d.ts +16 -0
  148. package/lib/components/table-lite/style/index.js +19 -0
  149. package/lib/components/table-v2/index.d.ts +174 -0
  150. package/lib/components/table-v2/index.js +10 -0
  151. package/lib/components/table-v2/src/column-converter.d.ts +27 -0
  152. package/lib/components/table-v2/src/column-converter.js +44 -0
  153. package/lib/components/table-v2/src/index.vue.d.ts +157 -0
  154. package/lib/components/table-v2/src/index.vue.js +10 -0
  155. package/lib/components/table-v2/src/index.vue2.js +495 -0
  156. package/lib/components/table-v2/src/special-columns.d.ts +61 -0
  157. package/lib/components/table-v2/src/special-columns.js +80 -0
  158. package/lib/components/table-v2/src/table-v2-cell.d.ts +104 -0
  159. package/lib/components/table-v2/src/table-v2-cell.js +143 -0
  160. package/lib/components/table-v2/src/table-v2-header-cell.vue.d.ts +61 -0
  161. package/lib/components/table-v2/src/table-v2-header-cell.vue.js +10 -0
  162. package/lib/components/table-v2/src/table-v2-header-cell.vue2.js +96 -0
  163. package/lib/components/table-v2/src/type.d.ts +95 -0
  164. package/lib/components/table-v2/src/type.js +2 -0
  165. package/lib/components/table-v2/src/use-table-v2-columns.d.ts +43 -0
  166. package/lib/components/table-v2/src/use-table-v2-columns.js +51 -0
  167. package/lib/components/table-v2/style/css.d.ts +17 -0
  168. package/lib/components/table-v2/style/css.js +20 -0
  169. package/lib/components/table-v2/style/index.d.ts +17 -0
  170. package/lib/components/table-v2/style/index.js +20 -0
  171. package/lib/index.js +51 -39
  172. package/lib/version.d.ts +1 -1
  173. package/lib/version.js +1 -1
  174. package/locale/en.js +1 -1
  175. package/locale/en.min.js +1 -1
  176. package/locale/en.min.mjs +1 -1
  177. package/locale/en.mjs +1 -1
  178. package/locale/ja.js +1 -1
  179. package/locale/ja.min.js +1 -1
  180. package/locale/ja.min.mjs +1 -1
  181. package/locale/ja.mjs +1 -1
  182. package/locale/ko.js +1 -1
  183. package/locale/ko.min.js +1 -1
  184. package/locale/ko.min.mjs +1 -1
  185. package/locale/ko.mjs +1 -1
  186. package/locale/zh-cn.js +1 -1
  187. package/locale/zh-cn.min.js +1 -1
  188. package/locale/zh-cn.min.mjs +1 -1
  189. package/locale/zh-cn.mjs +1 -1
  190. package/locale/zh-hk.js +1 -1
  191. package/locale/zh-hk.min.js +1 -1
  192. package/locale/zh-hk.min.mjs +1 -1
  193. package/locale/zh-hk.mjs +1 -1
  194. package/locale/zh-tw.js +1 -1
  195. package/locale/zh-tw.min.js +1 -1
  196. package/locale/zh-tw.min.mjs +1 -1
  197. package/locale/zh-tw.mjs +1 -1
  198. package/package.json +1 -1
  199. package/theme-chalk/index.css +1 -1
  200. package/theme-chalk/plus-table-lite.css +1 -0
  201. package/theme-chalk/plus-table-v2.css +1 -0
  202. package/theme-chalk/src/index.scss +2 -0
  203. package/theme-chalk/src/table-lite.scss +53 -0
  204. package/theme-chalk/src/table-v2.scss +71 -0
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! tabula-vue v1.0.0 */
1
+ /*! tabula-vue v1.0.2 */
2
2
  (function (global, factory) {
3
3
  typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('vue'), require('element-plus')) :
4
4
  typeof define === 'function' && define.amd ? define(['exports', 'vue', 'element-plus'], factory) :
@@ -350,7 +350,7 @@
350
350
  * _.toNumber('3.2');
351
351
  * // => 3.2
352
352
  */
353
- function toNumber(value) {
353
+ function toNumber$1(value) {
354
354
  if (typeof value == 'number') {
355
355
  return value;
356
356
  }
@@ -1546,7 +1546,7 @@
1546
1546
  ListCache.prototype.set = listCacheSet;
1547
1547
 
1548
1548
  /* Built-in method references that are verified to be native. */
1549
- var Map = getNative(root$1, 'Map');
1549
+ var Map$1 = getNative(root$1, 'Map');
1550
1550
 
1551
1551
  /**
1552
1552
  * Removes all key-value entries from the map.
@@ -1559,7 +1559,7 @@
1559
1559
  this.size = 0;
1560
1560
  this.__data__ = {
1561
1561
  'hash': new Hash,
1562
- 'map': new (Map || ListCache),
1562
+ 'map': new (Map$1 || ListCache),
1563
1563
  'string': new Hash
1564
1564
  };
1565
1565
  }
@@ -1997,7 +1997,7 @@
1997
1997
  var data = this.__data__;
1998
1998
  if (data instanceof ListCache) {
1999
1999
  var pairs = data.__data__;
2000
- if (!Map || (pairs.length < LARGE_ARRAY_SIZE - 1)) {
2000
+ if (!Map$1 || (pairs.length < LARGE_ARRAY_SIZE - 1)) {
2001
2001
  pairs.push([key, value]);
2002
2002
  this.size = ++data.size;
2003
2003
  return this;
@@ -2260,7 +2260,7 @@
2260
2260
 
2261
2261
  /** Used to detect maps, sets, and weakmaps. */
2262
2262
  var dataViewCtorString = toSource(DataView),
2263
- mapCtorString = toSource(Map),
2263
+ mapCtorString = toSource(Map$1),
2264
2264
  promiseCtorString = toSource(Promise$1),
2265
2265
  setCtorString = toSource(Set$1),
2266
2266
  weakMapCtorString = toSource(WeakMap);
@@ -2276,7 +2276,7 @@
2276
2276
 
2277
2277
  // Fallback for data views, maps, sets, and weak maps in IE 11 and promises in Node.js < 6.
2278
2278
  if ((DataView && getTag(new DataView(new ArrayBuffer(1))) != dataViewTag$3) ||
2279
- (Map && getTag(new Map) != mapTag$4) ||
2279
+ (Map$1 && getTag(new Map$1) != mapTag$4) ||
2280
2280
  (Promise$1 && getTag(Promise$1.resolve()) != promiseTag) ||
2281
2281
  (Set$1 && getTag(new Set$1) != setTag$4) ||
2282
2282
  (WeakMap && getTag(new WeakMap) != weakMapTag$1)) {
@@ -3692,11 +3692,11 @@
3692
3692
  if (typeof func != 'function') {
3693
3693
  throw new TypeError(FUNC_ERROR_TEXT);
3694
3694
  }
3695
- wait = toNumber(wait) || 0;
3695
+ wait = toNumber$1(wait) || 0;
3696
3696
  if (isObject$1(options)) {
3697
3697
  leading = !!options.leading;
3698
3698
  maxing = 'maxWait' in options;
3699
- maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;
3699
+ maxWait = maxing ? nativeMax(toNumber$1(options.maxWait) || 0, wait) : maxWait;
3700
3700
  trailing = 'trailing' in options ? !!options.trailing : trailing;
3701
3701
  }
3702
3702
 
@@ -4481,8 +4481,8 @@
4481
4481
  };
4482
4482
  }
4483
4483
 
4484
- const _hoisted_1$j = { class: "plus-dialog-body" };
4485
- var _sfc_main$u = /* @__PURE__ */ vue.defineComponent({
4484
+ const _hoisted_1$l = { class: "plus-dialog-body" };
4485
+ var _sfc_main$y = /* @__PURE__ */ vue.defineComponent({
4486
4486
  ...{
4487
4487
  name: "PlusDialog",
4488
4488
  inheritAttrs: false
@@ -4532,7 +4532,7 @@
4532
4532
  class: "plus-dialog"
4533
4533
  }, _ctx.$attrs), vue.createSlots({
4534
4534
  default: vue.withCtx(() => [
4535
- vue.createElementVNode("div", _hoisted_1$j, [
4535
+ vue.createElementVNode("div", _hoisted_1$l, [
4536
4536
  vue.renderSlot(_ctx.$slots, "default")
4537
4537
  ])
4538
4538
  ]),
@@ -4604,11 +4604,11 @@
4604
4604
  return target;
4605
4605
  };
4606
4606
 
4607
- var Dialog = /* @__PURE__ */ _export_sfc(_sfc_main$u, [["__file", "index.vue"]]);
4607
+ var Dialog = /* @__PURE__ */ _export_sfc(_sfc_main$y, [["__file", "index.vue"]]);
4608
4608
 
4609
4609
  const PlusDialog = Dialog;
4610
4610
 
4611
- const _hoisted_1$i = /* @__PURE__ */ vue.createElementVNode(
4611
+ const _hoisted_1$k = /* @__PURE__ */ vue.createElementVNode(
4612
4612
  "span",
4613
4613
  null,
4614
4614
  null,
@@ -4622,7 +4622,7 @@
4622
4622
  -1
4623
4623
  /* HOISTED */
4624
4624
  );
4625
- var _sfc_main$t = /* @__PURE__ */ vue.defineComponent({
4625
+ var _sfc_main$x = /* @__PURE__ */ vue.defineComponent({
4626
4626
  ...{
4627
4627
  name: "PlusPagination"
4628
4628
  },
@@ -4664,7 +4664,7 @@
4664
4664
  },
4665
4665
  [
4666
4666
  _ctx.align === "right" || _ctx.align === "center" ? vue.renderSlot(_ctx.$slots, "pagination-left", { key: 0 }, () => [
4667
- _hoisted_1$i
4667
+ _hoisted_1$k
4668
4668
  ]) : vue.createCommentVNode("v-if", true),
4669
4669
  vue.createVNode(vue.unref(elementPlus.ElPagination), vue.mergeProps({
4670
4670
  layout: "total, sizes, prev, pager, next, jumper",
@@ -4688,11 +4688,11 @@
4688
4688
  }
4689
4689
  });
4690
4690
 
4691
- var Pagination = /* @__PURE__ */ _export_sfc(_sfc_main$t, [["__file", "index.vue"]]);
4691
+ var Pagination = /* @__PURE__ */ _export_sfc(_sfc_main$x, [["__file", "index.vue"]]);
4692
4692
 
4693
4693
  const PlusPagination = Pagination;
4694
4694
 
4695
- var _sfc_main$s = /* @__PURE__ */ vue.defineComponent({
4695
+ var _sfc_main$w = /* @__PURE__ */ vue.defineComponent({
4696
4696
  ...{
4697
4697
  name: "PlusRadio"
4698
4698
  },
@@ -4877,7 +4877,7 @@
4877
4877
  }
4878
4878
  });
4879
4879
 
4880
- var Radio = /* @__PURE__ */ _export_sfc(_sfc_main$s, [["__file", "index.vue"]]);
4880
+ var Radio = /* @__PURE__ */ _export_sfc(_sfc_main$w, [["__file", "index.vue"]]);
4881
4881
 
4882
4882
  const PlusRadio = Radio;
4883
4883
 
@@ -5118,26 +5118,25 @@
5118
5118
  // src/components/user.vue
5119
5119
  var user_default = user_vue_vue_type_script_setup_true_lang_default;
5120
5120
 
5121
- const _hoisted_1$h = {
5121
+ const _hoisted_1$j = {
5122
5122
  key: 0,
5123
5123
  class: "plus-table-action-bar__dropdown__link"
5124
5124
  };
5125
5125
  const _hoisted_2$9 = { class: "plus-table-action-bar__dropdown__link" };
5126
5126
  const _hoisted_3$4 = { class: "plus-table-action-bar__more-text" };
5127
- var _sfc_main$r = /* @__PURE__ */ vue.defineComponent({
5127
+ var _sfc_main$v = /* @__PURE__ */ vue.defineComponent({
5128
5128
  ...{
5129
- name: "PlusTableActionBar"
5129
+ name: "PlusTableActionBarContent"
5130
5130
  },
5131
- __name: "table-action-bar",
5131
+ __name: "table-action-bar-content",
5132
5132
  props: {
5133
- label: { default: "" },
5134
- fixed: { default: "right" },
5133
+ row: {},
5134
+ index: {},
5135
+ rest: { default: () => ({}) },
5135
5136
  showNumber: { type: [Number, Function], default: 3 },
5136
5137
  showLimitIncludeMore: { type: Boolean, default: false },
5137
5138
  type: { default: "link" },
5138
5139
  buttons: { default: () => [] },
5139
- width: { default: 200 },
5140
- actionBarTableColumnProps: { default: () => ({}) },
5141
5140
  confirmType: { default: "messageBox" },
5142
5141
  moreType: { default: "text" }
5143
5142
  },
@@ -5184,20 +5183,23 @@
5184
5183
  nextButtons: data.slice(showNumber)
5185
5184
  };
5186
5185
  };
5187
- const createCallbackParams = (params, e) => ({
5188
- /**
5189
- * 解析后的按钮数据中的text
5190
- * @version v0.1.17
5191
- */
5192
- text: params.text,
5193
- row: params.row,
5194
- buttonRow: params.buttonRow,
5195
- index: params.index,
5196
- rowIndex: params.index,
5197
- e,
5198
- formRefs: formRefs.value[params.index],
5199
- ...params.rest
5200
- });
5186
+ const createCallbackParams = (params, e) => {
5187
+ var _a;
5188
+ return {
5189
+ /**
5190
+ * 解析后的按钮数据中的text
5191
+ * @version v0.1.17
5192
+ */
5193
+ text: params.text,
5194
+ row: params.row,
5195
+ buttonRow: params.buttonRow,
5196
+ index: params.index,
5197
+ rowIndex: params.index,
5198
+ e,
5199
+ formRefs: (_a = formRefs == null ? void 0 : formRefs.value) == null ? void 0 : _a[params.index],
5200
+ ...params.rest
5201
+ };
5202
+ };
5201
5203
  const getConfirmMsg = (buttonRow, callbackParams) => {
5202
5204
  var _a, _b;
5203
5205
  let message = t("plus.table.confirmToPerformThisOperation");
@@ -5370,30 +5372,28 @@
5370
5372
  }
5371
5373
  };
5372
5374
  return (_ctx, _cache) => {
5373
- return vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElTableColumn), vue.mergeProps({
5374
- key: "actionBar",
5375
- "class-name": "plus-table-action-bar",
5376
- label: vue.unref(_ctx.label) || vue.unref(t)("plus.table.action"),
5377
- fixed: _ctx.fixed || "right",
5378
- width: _ctx.width || 200
5379
- }, _ctx.actionBarTableColumnProps), {
5380
- default: vue.withCtx(({ row, $index, ...rest }) => [
5381
- vue.createCommentVNode("\n \u7528\u5355\u5143\u7D20\u6570\u7EC4\u8BA9 getSubButtons \u6BCF\u884C\u53EA\u6267\u884C\u4E00\u6B21\uFF1A\n \u539F\u5148 preButtons / showMore / nextButtons \u5404\u8C03\u7528\u4E00\u6B21\uFF0C\n 500 \u884C \xD7 11 \u4E2A\u6309\u94AE \u2248 \u4E0A\u4E07\u6B21 show()\uFF08\u542B\u6743\u9650\u5224\u65AD\uFF09\u3002\n "),
5375
+ return vue.openBlock(), vue.createElementBlock(
5376
+ vue.Fragment,
5377
+ null,
5378
+ [
5379
+ vue.createCommentVNode("\n \u7528\u5355\u5143\u7D20\u6570\u7EC4\u8BA9 getSubButtons \u6BCF\u884C\u53EA\u6267\u884C\u4E00\u6B21\uFF1A\n preButtons / showMore / nextButtons \u5171\u7528\u540C\u4E00\u4EFD\u8BA1\u7B97\u7ED3\u679C\n "),
5382
5380
  (vue.openBlock(true), vue.createElementBlock(
5383
5381
  vue.Fragment,
5384
5382
  null,
5385
- vue.renderList([getSubButtons(row, $index)], (cell) => {
5383
+ vue.renderList([getSubButtons(_ctx.row, _ctx.index)], (cell) => {
5386
5384
  return vue.openBlock(), vue.createElementBlock(
5387
5385
  vue.Fragment,
5388
- { key: $index },
5386
+ {
5387
+ key: cell.preButtons.length
5388
+ },
5389
5389
  [
5390
5390
  vue.createCommentVNode(" \u663E\u793A\u51FA\u6765\u7684\u6309\u94AE "),
5391
5391
  (vue.openBlock(true), vue.createElementBlock(
5392
5392
  vue.Fragment,
5393
5393
  null,
5394
5394
  vue.renderList(cell.preButtons, (buttonRow) => {
5395
- return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(render(row, buttonRow, $index, rest)), {
5396
- key: getButtonKey(buttonRow, row, $index)
5395
+ return vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(render(_ctx.row, buttonRow, _ctx.index, _ctx.rest)), {
5396
+ key: getButtonKey(buttonRow, _ctx.row, _ctx.index)
5397
5397
  });
5398
5398
  }),
5399
5399
  128
@@ -5420,11 +5420,11 @@
5420
5420
  return vue.openBlock(), vue.createBlock(
5421
5421
  vue.unref(elementPlus.ElDropdownItem),
5422
5422
  {
5423
- key: getButtonKey(buttonRow, row, $index)
5423
+ key: getButtonKey(buttonRow, _ctx.row, _ctx.index)
5424
5424
  },
5425
5425
  {
5426
5426
  default: vue.withCtx(() => [
5427
- (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(render(row, buttonRow, $index, rest))))
5427
+ (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(render(_ctx.row, buttonRow, _ctx.index, _ctx.rest))))
5428
5428
  ]),
5429
5429
  _: 2
5430
5430
  /* DYNAMIC */
@@ -5445,7 +5445,7 @@
5445
5445
  )
5446
5446
  ]),
5447
5447
  default: vue.withCtx(() => [
5448
- _ctx.moreType === "icon" ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$h, [
5448
+ _ctx.moreType === "icon" ? (vue.openBlock(), vue.createElementBlock("span", _hoisted_1$j, [
5449
5449
  vue.renderSlot(_ctx.$slots, "action-bar-more-icon", {}, () => [
5450
5450
  vue.createVNode(vue.unref(elementPlus.ElIcon), null, {
5451
5451
  default: vue.withCtx(() => [
@@ -5494,6 +5494,73 @@
5494
5494
  128
5495
5495
  /* KEYED_FRAGMENT */
5496
5496
  ))
5497
+ ],
5498
+ 2112
5499
+ /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
5500
+ );
5501
+ };
5502
+ }
5503
+ });
5504
+
5505
+ var PlusTableActionBarContent = /* @__PURE__ */ _export_sfc(_sfc_main$v, [["__file", "table-action-bar-content.vue"]]);
5506
+
5507
+ var _sfc_main$u = /* @__PURE__ */ vue.defineComponent({
5508
+ ...{
5509
+ name: "PlusTableActionBar"
5510
+ },
5511
+ __name: "table-action-bar",
5512
+ props: {
5513
+ label: { default: "" },
5514
+ fixed: { default: "right" },
5515
+ showNumber: { type: [Number, Function], default: 3 },
5516
+ showLimitIncludeMore: { type: Boolean, default: false },
5517
+ type: { default: "link" },
5518
+ buttons: { default: () => [] },
5519
+ width: { default: 200 },
5520
+ actionBarTableColumnProps: { default: () => ({}) },
5521
+ confirmType: { default: "messageBox" },
5522
+ moreType: { default: "text" }
5523
+ },
5524
+ emits: ["clickAction", "clickActionConfirmCancel"],
5525
+ setup(__props, { emit: __emit }) {
5526
+ const emit = __emit;
5527
+ const { t } = useLocale();
5528
+ const handleClickAction = (data) => emit("clickAction", data);
5529
+ const handleClickActionConfirmCancel = (data) => emit("clickActionConfirmCancel", data);
5530
+ return (_ctx, _cache) => {
5531
+ return vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElTableColumn), vue.mergeProps({
5532
+ key: "actionBar",
5533
+ "class-name": "plus-table-action-bar",
5534
+ label: vue.unref(_ctx.label) || vue.unref(t)("plus.table.action"),
5535
+ fixed: _ctx.fixed || "right",
5536
+ width: _ctx.width || 200
5537
+ }, _ctx.actionBarTableColumnProps), {
5538
+ default: vue.withCtx(({ row, $index, ...rest }) => [
5539
+ vue.createCommentVNode(" \u6309\u94AE\u5185\u5BB9\u903B\u8F91\u4E0E PlusTableV2 \u5171\u7528 "),
5540
+ vue.createVNode(PlusTableActionBarContent, {
5541
+ row,
5542
+ index: $index,
5543
+ rest,
5544
+ type: _ctx.type,
5545
+ buttons: _ctx.buttons,
5546
+ "show-number": _ctx.showNumber,
5547
+ "show-limit-include-more": _ctx.showLimitIncludeMore,
5548
+ "confirm-type": _ctx.confirmType,
5549
+ "more-type": _ctx.moreType,
5550
+ onClickAction: handleClickAction,
5551
+ onClickActionConfirmCancel: handleClickActionConfirmCancel
5552
+ }, vue.createSlots({
5553
+ _: 2
5554
+ /* DYNAMIC */
5555
+ }, [
5556
+ _ctx.$slots["action-bar-more-icon"] ? {
5557
+ name: "action-bar-more-icon",
5558
+ fn: vue.withCtx(() => [
5559
+ vue.renderSlot(_ctx.$slots, "action-bar-more-icon")
5560
+ ]),
5561
+ key: "0"
5562
+ } : void 0
5563
+ ]), 1032, ["row", "index", "rest", "type", "buttons", "show-number", "show-limit-include-more", "confirm-type", "more-type"])
5497
5564
  ]),
5498
5565
  _: 3
5499
5566
  /* FORWARDED */
@@ -5502,9 +5569,9 @@
5502
5569
  }
5503
5570
  });
5504
5571
 
5505
- var PlusTableActionBar = /* @__PURE__ */ _export_sfc(_sfc_main$r, [["__file", "table-action-bar.vue"]]);
5572
+ var PlusTableActionBar = /* @__PURE__ */ _export_sfc(_sfc_main$u, [["__file", "table-action-bar.vue"]]);
5506
5573
 
5507
- var _sfc_main$q = /* @__PURE__ */ vue.defineComponent({
5574
+ var _sfc_main$t = /* @__PURE__ */ vue.defineComponent({
5508
5575
  ...{
5509
5576
  name: "PlusRender"
5510
5577
  },
@@ -5574,12 +5641,12 @@
5574
5641
  }
5575
5642
  });
5576
5643
 
5577
- var Render = /* @__PURE__ */ _export_sfc(_sfc_main$q, [["__file", "index.vue"]]);
5644
+ var Render = /* @__PURE__ */ _export_sfc(_sfc_main$t, [["__file", "index.vue"]]);
5578
5645
 
5579
5646
  const PlusRender = Render;
5580
5647
 
5581
- const _hoisted_1$g = { class: "plus-date-picker__middle" };
5582
- var _sfc_main$p = /* @__PURE__ */ vue.defineComponent({
5648
+ const _hoisted_1$i = { class: "plus-date-picker__middle" };
5649
+ var _sfc_main$s = /* @__PURE__ */ vue.defineComponent({
5583
5650
  ...{
5584
5651
  name: "PlusDatePicker"
5585
5652
  },
@@ -5684,7 +5751,7 @@
5684
5751
  }), null, 16, ["modelValue", "type", "value-format", "placeholder", "disabled"]),
5685
5752
  vue.createElementVNode(
5686
5753
  "span",
5687
- _hoisted_1$g,
5754
+ _hoisted_1$i,
5688
5755
  vue.toDisplayString(_ctx.rangeSeparator),
5689
5756
  1
5690
5757
  /* TEXT */
@@ -5715,11 +5782,11 @@
5715
5782
  }
5716
5783
  });
5717
5784
 
5718
- var DatePicker = /* @__PURE__ */ _export_sfc(_sfc_main$p, [["__file", "index.vue"]]);
5785
+ var DatePicker = /* @__PURE__ */ _export_sfc(_sfc_main$s, [["__file", "index.vue"]]);
5719
5786
 
5720
5787
  const PlusDatePicker = DatePicker;
5721
5788
 
5722
- var _sfc_main$o = /* @__PURE__ */ vue.defineComponent({
5789
+ var _sfc_main$r = /* @__PURE__ */ vue.defineComponent({
5723
5790
  ...{
5724
5791
  name: "PlusInputTag"
5725
5792
  },
@@ -5856,7 +5923,7 @@
5856
5923
  }
5857
5924
  });
5858
5925
 
5859
- var InputTag = /* @__PURE__ */ _export_sfc(_sfc_main$o, [["__file", "index.vue"]]);
5926
+ var InputTag = /* @__PURE__ */ _export_sfc(_sfc_main$r, [["__file", "index.vue"]]);
5860
5927
 
5861
5928
  const PlusInputTag = InputTag;
5862
5929
 
@@ -5953,9 +6020,9 @@
5953
6020
  );
5954
6021
  const getFieldComponent = (valueType) => Reflect.get(FieldComponentMap, valueType) || {};
5955
6022
 
5956
- const _hoisted_1$f = { class: "el-form-item__error" };
6023
+ const _hoisted_1$h = { class: "el-form-item__error" };
5957
6024
  const _hoisted_2$8 = { class: "plus-form-item__label" };
5958
- var _sfc_main$n = /* @__PURE__ */ vue.defineComponent({
6025
+ var _sfc_main$q = /* @__PURE__ */ vue.defineComponent({
5959
6026
  ...{
5960
6027
  name: "PlusFormItem"
5961
6028
  },
@@ -6510,7 +6577,7 @@
6510
6577
  vue.unref(isFunction)(_ctx.renderErrorMessage) ? {
6511
6578
  name: "error",
6512
6579
  fn: vue.withCtx(({ error }) => [
6513
- vue.createElementVNode("div", _hoisted_1$f, [
6580
+ vue.createElementVNode("div", _hoisted_1$h, [
6514
6581
  (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(_ctx.renderErrorMessage), vue.mergeProps(props, {
6515
6582
  value: state.value,
6516
6583
  error,
@@ -6581,11 +6648,11 @@
6581
6648
  }
6582
6649
  });
6583
6650
 
6584
- var FormItem = /* @__PURE__ */ _export_sfc(_sfc_main$n, [["__file", "index.vue"]]);
6651
+ var FormItem = /* @__PURE__ */ _export_sfc(_sfc_main$q, [["__file", "index.vue"]]);
6585
6652
 
6586
6653
  const PlusFormItem = FormItem;
6587
6654
 
6588
- var _sfc_main$m = /* @__PURE__ */ vue.defineComponent({
6655
+ var _sfc_main$p = /* @__PURE__ */ vue.defineComponent({
6589
6656
  ...{
6590
6657
  name: "PlusCollapseTransition"
6591
6658
  },
@@ -6636,9 +6703,9 @@
6636
6703
  }
6637
6704
  });
6638
6705
 
6639
- var PlusCollapseTransition = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["__file", "collapse-transition.vue"]]);
6706
+ var PlusCollapseTransition = /* @__PURE__ */ _export_sfc(_sfc_main$p, [["__file", "collapse-transition.vue"]]);
6640
6707
 
6641
- const _hoisted_1$e = {
6708
+ const _hoisted_1$g = {
6642
6709
  key: 0,
6643
6710
  class: "plus-form-item-previous"
6644
6711
  };
@@ -6646,7 +6713,7 @@
6646
6713
  key: 1,
6647
6714
  class: "plus-form-item-extra"
6648
6715
  };
6649
- var _sfc_main$l = /* @__PURE__ */ vue.defineComponent({
6716
+ var _sfc_main$o = /* @__PURE__ */ vue.defineComponent({
6650
6717
  ...{
6651
6718
  name: "PlusFormContent"
6652
6719
  },
@@ -6711,7 +6778,7 @@
6711
6778
  {
6712
6779
  default: vue.withCtx(() => [
6713
6780
  vue.createCommentVNode(" el-form-item\u4E0A\u4E00\u884C\u7684\u5185\u5BB9 "),
6714
- item.renderPrevious || _ctx.$slots[vue.unref(getPreviousSlotName)(item.prop)] ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$e, [
6781
+ item.renderPrevious || _ctx.$slots[vue.unref(getPreviousSlotName)(item.prop)] ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$g, [
6715
6782
  vue.unref(isFunction)(item.renderPrevious) ? (vue.openBlock(), vue.createBlock(
6716
6783
  vue.resolveDynamicComponent(item.renderPrevious),
6717
6784
  vue.normalizeProps(vue.mergeProps({ key: 0 }, item)),
@@ -6790,10 +6857,10 @@
6790
6857
  }
6791
6858
  });
6792
6859
 
6793
- var PlusFormContent = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["__file", "form-content.vue"]]);
6860
+ var PlusFormContent = /* @__PURE__ */ _export_sfc(_sfc_main$o, [["__file", "form-content.vue"]]);
6794
6861
 
6795
- const _hoisted_1$d = { class: "plus-form__group__item__icon" };
6796
- var _sfc_main$k = /* @__PURE__ */ vue.defineComponent({
6862
+ const _hoisted_1$f = { class: "plus-form__group__item__icon" };
6863
+ var _sfc_main$n = /* @__PURE__ */ vue.defineComponent({
6797
6864
  ...{
6798
6865
  name: "PlusForm",
6799
6866
  inheritAttrs: false
@@ -6943,7 +7010,7 @@
6943
7010
  icon: groupItem.icon,
6944
7011
  index
6945
7012
  }, () => [
6946
- vue.createElementVNode("div", _hoisted_1$d, [
7013
+ vue.createElementVNode("div", _hoisted_1$f, [
6947
7014
  groupItem.icon ? (vue.openBlock(), vue.createBlock(
6948
7015
  vue.unref(elementPlus.ElIcon),
6949
7016
  { key: 0 },
@@ -7088,7 +7155,7 @@
7088
7155
  }
7089
7156
  });
7090
7157
 
7091
- var Form = /* @__PURE__ */ _export_sfc(_sfc_main$k, [["__file", "index.vue"]]);
7158
+ var Form = /* @__PURE__ */ _export_sfc(_sfc_main$n, [["__file", "index.vue"]]);
7092
7159
 
7093
7160
  const PlusForm = Form;
7094
7161
 
@@ -7131,7 +7198,7 @@
7131
7198
  const hasDisplayComponent = (valueType) => Object.keys(DisplayComponentMap).includes(valueType);
7132
7199
  const getDisplayComponent = (valueType) => Reflect.get(DisplayComponentMap, valueType) || {};
7133
7200
 
7134
- const _hoisted_1$c = ["innerHTML"];
7201
+ const _hoisted_1$e = ["innerHTML"];
7135
7202
  const _hoisted_2$6 = { class: "plus-display-item" };
7136
7203
  const _hoisted_3$3 = /* @__PURE__ */ vue.createElementVNode(
7137
7204
  "svg",
@@ -7152,7 +7219,7 @@
7152
7219
  -1
7153
7220
  /* HOISTED */
7154
7221
  );
7155
- var _sfc_main$j = /* @__PURE__ */ vue.defineComponent({
7222
+ var _sfc_main$m = /* @__PURE__ */ vue.defineComponent({
7156
7223
  ...{
7157
7224
  name: "PlusDisplayItem"
7158
7225
  },
@@ -7523,7 +7590,7 @@
7523
7590
  vue.createElementVNode("span", {
7524
7591
  class: "plus-display-item",
7525
7592
  innerHTML: _ctx.column.renderHTML(displayValue.value, renderParams.value)
7526
- }, null, 8, _hoisted_1$c)
7593
+ }, null, 8, _hoisted_1$e)
7527
7594
  ],
7528
7595
  2112
7529
7596
  /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
@@ -7790,13 +7857,12 @@
7790
7857
  }
7791
7858
  });
7792
7859
 
7793
- var DisplayItem = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["__file", "index.vue"]]);
7860
+ var DisplayItem = /* @__PURE__ */ _export_sfc(_sfc_main$m, [["__file", "index.vue"]]);
7794
7861
 
7795
7862
  const PlusDisplayItem = DisplayItem;
7796
7863
 
7797
- const _hoisted_1$b = { class: "plus-table-column__header" };
7798
- const _hoisted_2$5 = { class: "plus-display-item" };
7799
- var _sfc_main$i = /* @__PURE__ */ vue.defineComponent({
7864
+ const _hoisted_1$d = { class: "plus-table-column__header" };
7865
+ var _sfc_main$l = /* @__PURE__ */ vue.defineComponent({
7800
7866
  ...{
7801
7867
  name: "PlusTableColumn"
7802
7868
  },
@@ -7806,14 +7872,12 @@
7806
7872
  editable: { type: [Boolean, String], default: false },
7807
7873
  tableDataLength: { default: 0 },
7808
7874
  subPageInfo: { default: () => ({}) },
7809
- emptyValue: { default: void 0 },
7810
- plainTextCell: { type: Boolean, default: false }
7875
+ emptyValue: { default: void 0 }
7811
7876
  },
7812
7877
  emits: ["formChange"],
7813
7878
  setup(__props, { expose: __expose, emit: __emit }) {
7814
7879
  const props = __props;
7815
7880
  const emit = __emit;
7816
- const slots = vue.useSlots();
7817
7881
  const instance = vue.getCurrentInstance();
7818
7882
  const store = vue.computed(() => {
7819
7883
  var _a;
@@ -7832,36 +7896,6 @@
7832
7896
  );
7833
7897
  const plusDisplayItemInstance = vue.ref();
7834
7898
  const formRefs = vue.inject(TableFormRefInjectionKey);
7835
- const PLAIN_VALUE_TYPE_SET = /* @__PURE__ */ new Set([void 0, "", "input"]);
7836
- const isPlainColumn = (item) => {
7837
- if (!props.plainTextCell) return false;
7838
- if (props.editable !== false) return false;
7839
- if (item.editable === true) return false;
7840
- if (!PLAIN_VALUE_TYPE_SET.has(item.valueType)) return false;
7841
- if (item.render || item.renderHTML || item.formatter || item.customGetStatus) return false;
7842
- if (item.fieldProps !== void 0 && item.fieldProps !== null) return false;
7843
- if (item.formProps !== void 0 && item.formProps !== null) return false;
7844
- if (item.fieldSlots && Object.keys(item.fieldSlots).length) return false;
7845
- if (slots && slots[getTableCellSlotName(item.prop)]) return false;
7846
- return true;
7847
- };
7848
- const plainColumnSet = vue.computed(() => {
7849
- const set2 = /* @__PURE__ */ new Set();
7850
- props.columns.forEach((item) => {
7851
- var _a;
7852
- if ((_a = item.children) == null ? void 0 : _a.length) return;
7853
- if (isPlainColumn(item)) set2.add(item);
7854
- });
7855
- return set2;
7856
- });
7857
- const getPlainValue = (item, row) => {
7858
- var _a, _b;
7859
- const value = getValue(row, item.prop);
7860
- if (value === null || value === void 0 || value === "") {
7861
- return (_b = (_a = item.emptyValue) != null ? _a : props.emptyValue) != null ? _b : "";
7862
- }
7863
- return value;
7864
- };
7865
7899
  const setFormRef = () => {
7866
7900
  var _a, _b;
7867
7901
  if (!((_a = plusDisplayItemInstance.value) == null ? void 0 : _a.length)) return;
@@ -7874,11 +7908,7 @@
7874
7908
  set(formRefs.value[item.rowIndex], item.cellIndex, item);
7875
7909
  }
7876
7910
  };
7877
- const needFormRefs = vue.computed(
7878
- () => props.editable !== false || !props.plainTextCell || props.columns.some((item) => item.editable === true)
7879
- );
7880
7911
  const cellInstanceSignature = vue.computed(() => {
7881
- if (!needFormRefs.value) return "";
7882
7912
  const list = plusDisplayItemInstance.value;
7883
7913
  if (!(list == null ? void 0 : list.length)) return "";
7884
7914
  return list.map((item) => {
@@ -7889,7 +7919,6 @@
7889
7919
  vue.watch(
7890
7920
  () => [props.tableDataLength, cellInstanceSignature.value, props.subPageInfo],
7891
7921
  () => {
7892
- if (!needFormRefs.value) return;
7893
7922
  setFormRef();
7894
7923
  },
7895
7924
  {
@@ -7931,7 +7960,7 @@
7931
7960
  "min-width": item.minWidth
7932
7961
  }), {
7933
7962
  header: vue.withCtx((scoped) => [
7934
- vue.createElementVNode("span", _hoisted_1$b, [
7963
+ vue.createElementVNode("span", _hoisted_1$d, [
7935
7964
  item.renderHeader && vue.unref(isFunction)(item.renderHeader) ? (vue.openBlock(), vue.createBlock(vue.unref(PlusRender), {
7936
7965
  key: 0,
7937
7966
  render: item.renderHeader,
@@ -8024,23 +8053,8 @@
8024
8053
  ],
8025
8054
  64
8026
8055
  /* STABLE_FRAGMENT */
8027
- )) : plainColumnSet.value.has(item) ? (vue.openBlock(), vue.createElementBlock(
8028
- vue.Fragment,
8029
- { key: 1 },
8030
- [
8031
- vue.createCommentVNode(" \u7EAF\u6587\u672C\u5217\u5FEB\u8DEF\u5F84\uFF1A\u4E0D\u521B\u5EFA\u7EC4\u4EF6\u5B9E\u4F8B\u3001\u4E0D\u6CE8\u518C\u4EFB\u4F55 watcher "),
8032
- vue.createElementVNode(
8033
- "span",
8034
- _hoisted_2$5,
8035
- vue.toDisplayString(getPlainValue(item, row)),
8036
- 1
8037
- /* TEXT */
8038
- )
8039
- ],
8040
- 2112
8041
- /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
8042
8056
  )) : (vue.openBlock(), vue.createBlock(vue.unref(PlusDisplayItem), {
8043
- key: 2,
8057
+ key: 1,
8044
8058
  ref_for: true,
8045
8059
  ref_key: "plusDisplayItemInstance",
8046
8060
  ref: plusDisplayItemInstance,
@@ -8077,9 +8091,9 @@
8077
8091
  }
8078
8092
  });
8079
8093
 
8080
- var PlusTableColumn = /* @__PURE__ */ _export_sfc(_sfc_main$i, [["__file", "table-column.vue"]]);
8094
+ var PlusTableColumn = /* @__PURE__ */ _export_sfc(_sfc_main$l, [["__file", "table-column.vue"]]);
8081
8095
 
8082
- var _sfc_main$h = /* @__PURE__ */ vue.defineComponent({
8096
+ var _sfc_main$k = /* @__PURE__ */ vue.defineComponent({
8083
8097
  ...{
8084
8098
  name: "PlusTableTableColumnIndex"
8085
8099
  },
@@ -8153,7 +8167,7 @@
8153
8167
  }
8154
8168
  });
8155
8169
 
8156
- var PlusTableTableColumnIndex = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["__file", "table-column-index.vue"]]);
8170
+ var PlusTableTableColumnIndex = /* @__PURE__ */ _export_sfc(_sfc_main$k, [["__file", "table-column-index.vue"]]);
8157
8171
 
8158
8172
  /**!
8159
8173
  * Sortable 1.15.0
@@ -11175,8 +11189,8 @@
11175
11189
  Sortable.mount(new AutoScrollPlugin());
11176
11190
  Sortable.mount(Remove, Revert);
11177
11191
 
11178
- const _hoisted_1$a = { class: "plus-table-column-drag-icon" };
11179
- var _sfc_main$g = /* @__PURE__ */ vue.defineComponent({
11192
+ const _hoisted_1$c = { class: "plus-table-column-drag-icon" };
11193
+ var _sfc_main$j = /* @__PURE__ */ vue.defineComponent({
11180
11194
  ...{
11181
11195
  name: "PlusTableColumnDragSort"
11182
11196
  },
@@ -11227,7 +11241,7 @@
11227
11241
  "class-name": "plus-table-column-drag-sort"
11228
11242
  }, _ctx.dragSortableTableColumnProps), {
11229
11243
  default: vue.withCtx(() => [
11230
- vue.createElementVNode("span", _hoisted_1$a, [
11244
+ vue.createElementVNode("span", _hoisted_1$c, [
11231
11245
  vue.renderSlot(_ctx.$slots, "drag-sort-icon", {}, () => [
11232
11246
  vue.createTextVNode("\u2637")
11233
11247
  ])
@@ -11240,13 +11254,13 @@
11240
11254
  }
11241
11255
  });
11242
11256
 
11243
- var PlusTableColumnDragSort = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["__file", "table-column-drag-sort.vue"]]);
11257
+ var PlusTableColumnDragSort = /* @__PURE__ */ _export_sfc(_sfc_main$j, [["__file", "table-column-drag-sort.vue"]]);
11244
11258
 
11245
- const _hoisted_1$9 = {
11259
+ const _hoisted_1$b = {
11246
11260
  key: 0,
11247
11261
  style: { "padding-top": "12px" }
11248
11262
  };
11249
- var _sfc_main$f = /* @__PURE__ */ vue.defineComponent({
11263
+ var _sfc_main$i = /* @__PURE__ */ vue.defineComponent({
11250
11264
  ...{
11251
11265
  name: "PlusPopover"
11252
11266
  },
@@ -11292,7 +11306,7 @@
11292
11306
  ]),
11293
11307
  default: vue.withCtx(() => [
11294
11308
  vue.renderSlot(_ctx.$slots, "default"),
11295
- _ctx.hasShowBottomButton ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$9, [
11309
+ _ctx.hasShowBottomButton ? (vue.openBlock(), vue.createElementBlock("div", _hoisted_1$b, [
11296
11310
  vue.createVNode(vue.unref(elementPlus.ElButton), {
11297
11311
  size: "small",
11298
11312
  plain: "",
@@ -11333,12 +11347,12 @@
11333
11347
  }
11334
11348
  });
11335
11349
 
11336
- var Popover = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["__file", "index.vue"]]);
11350
+ var Popover = /* @__PURE__ */ _export_sfc(_sfc_main$i, [["__file", "index.vue"]]);
11337
11351
 
11338
11352
  const PlusPopover = Popover;
11339
11353
 
11340
- const _hoisted_1$8 = { class: "plus-table-title-bar" };
11341
- const _hoisted_2$4 = { class: "plus-table-title-bar__title" };
11354
+ const _hoisted_1$a = { class: "plus-table-title-bar" };
11355
+ const _hoisted_2$5 = { class: "plus-table-title-bar__title" };
11342
11356
  const _hoisted_3$2 = { class: "plus-table-title-bar__toolbar" };
11343
11357
  const _hoisted_4$2 = { class: "plus-table-title-bar__toolbar__density" };
11344
11358
  const _hoisted_5$2 = /* @__PURE__ */ vue.createElementVNode(
@@ -11363,7 +11377,7 @@
11363
11377
  };
11364
11378
  const _hoisted_8$1 = { key: 1 };
11365
11379
  const _hoisted_9$1 = { key: 1 };
11366
- var _sfc_main$e = /* @__PURE__ */ vue.defineComponent({
11380
+ var _sfc_main$h = /* @__PURE__ */ vue.defineComponent({
11367
11381
  ...{
11368
11382
  name: "PlusTableToolbar"
11369
11383
  },
@@ -11514,8 +11528,8 @@
11514
11528
  });
11515
11529
  return (_ctx, _cache) => {
11516
11530
  var _a, _b, _c;
11517
- return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$8, [
11518
- vue.createElementVNode("div", _hoisted_2$4, [
11531
+ return vue.openBlock(), vue.createElementBlock("div", _hoisted_1$a, [
11532
+ vue.createElementVNode("div", _hoisted_2$5, [
11519
11533
  vue.renderSlot(_ctx.$slots, "title", {}, () => [
11520
11534
  vue.createTextVNode(
11521
11535
  vue.toDisplayString(titleBarConfig.value.title),
@@ -11816,10 +11830,46 @@
11816
11830
  }
11817
11831
  });
11818
11832
 
11819
- var PlusTableTitleBar = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__file", "table-title-bar.vue"]]);
11833
+ var PlusTableTitleBar = /* @__PURE__ */ _export_sfc(_sfc_main$h, [["__file", "table-title-bar.vue"]]);
11834
+
11835
+ const useTableColumns = ({ columns, skipEqual = true }) => {
11836
+ const filterColumns = vue.shallowRef([]);
11837
+ const subColumns = vue.shallowRef([]);
11838
+ const columnsIsChange = vue.ref(false);
11839
+ const resolveSubColumns = (list) => list.filter((item) => vue.unref(item.hideInTable) !== true && item.headerIsChecked !== false);
11840
+ vue.watch(
11841
+ columns,
11842
+ (val, oldVal) => {
11843
+ if (skipEqual && oldVal && isEqual(val, oldVal)) return;
11844
+ const filterOriginColumns = val.filter((item) => vue.unref(item.hideInTable) !== true);
11845
+ filterColumns.value = filterOriginColumns.map((item) => {
11846
+ var _a;
11847
+ return {
11848
+ ...item,
11849
+ headerIsChecked: (_a = item.headerIsChecked) != null ? _a : true
11850
+ };
11851
+ });
11852
+ subColumns.value = filterOriginColumns.filter((item) => vue.unref(item.headerIsChecked) !== false);
11853
+ columnsIsChange.value = !columnsIsChange.value;
11854
+ },
11855
+ {
11856
+ immediate: true
11857
+ }
11858
+ );
11859
+ const setFilterColumns = (_columns) => {
11860
+ filterColumns.value = _columns;
11861
+ subColumns.value = resolveSubColumns(_columns);
11862
+ };
11863
+ return {
11864
+ filterColumns,
11865
+ subColumns,
11866
+ columnsIsChange,
11867
+ setFilterColumns
11868
+ };
11869
+ };
11820
11870
 
11821
- const _hoisted_1$7 = { class: "plus-table-expand-col" };
11822
- var _sfc_main$d = /* @__PURE__ */ vue.defineComponent({
11871
+ const _hoisted_1$9 = { class: "plus-table-expand-col" };
11872
+ var _sfc_main$g = /* @__PURE__ */ vue.defineComponent({
11823
11873
  ...{
11824
11874
  name: "PlusTable",
11825
11875
  inheritAttrs: false
@@ -11860,8 +11910,7 @@
11860
11910
  editable: { type: [Boolean, String], default: false },
11861
11911
  adaptive: { type: [Boolean, Object], default: false },
11862
11912
  filterTableHeaderOverflowLabelLength: {},
11863
- emptyValue: { default: void 0 },
11864
- plainTextCell: { type: Boolean, default: false }
11913
+ emptyValue: { default: void 0 }
11865
11914
  },
11866
11915
  emits: ["paginationChange", "clickAction", "clickActionConfirmCancel", "dragSortEnd", "formChange", "refresh", "edited", "cell-click", "cell-dblclick", "filterTableHeader", "radioChange"],
11867
11916
  setup(__props, { expose: __expose, emit: __emit }) {
@@ -11869,9 +11918,6 @@
11869
11918
  const props = __props;
11870
11919
  const emit = __emit;
11871
11920
  const radioRow = vue.ref();
11872
- const subColumns = vue.shallowRef([]);
11873
- const columnsIsChange = vue.ref(false);
11874
- const filterColumns = vue.shallowRef([]);
11875
11921
  const tableInstance = vue.shallowRef(null);
11876
11922
  const tableWrapperInstance = vue.ref(null);
11877
11923
  const paginationInstance = vue.ref(null);
@@ -11914,25 +11960,9 @@
11914
11960
  vue.provide(TableFormRefInjectionKey, formRefs);
11915
11961
  const formFieldRefs = vue.shallowRef({});
11916
11962
  vue.provide(TableFormFieldRefInjectionKey, formFieldRefs);
11917
- vue.watch(
11918
- () => props.columns,
11919
- (val, oldVal) => {
11920
- if (oldVal && isEqual(val, oldVal)) return;
11921
- const filterOriginColumns = val.filter((item) => vue.unref(item.hideInTable) !== true);
11922
- filterColumns.value = filterOriginColumns.map((item) => {
11923
- var _a2;
11924
- return {
11925
- ...item,
11926
- headerIsChecked: (_a2 = item.headerIsChecked) != null ? _a2 : true
11927
- };
11928
- });
11929
- subColumns.value = filterOriginColumns.filter((item) => vue.unref(item.headerIsChecked) !== false);
11930
- columnsIsChange.value = !columnsIsChange.value;
11931
- },
11932
- {
11933
- immediate: true
11934
- }
11935
- );
11963
+ const { subColumns, filterColumns, columnsIsChange, setFilterColumns } = useTableColumns({
11964
+ columns: () => props.columns
11965
+ });
11936
11966
  vue.watch(
11937
11967
  () => props.defaultSelectedRadioRow,
11938
11968
  (val) => {
@@ -11952,11 +11982,8 @@
11952
11982
  emit("clickActionConfirmCancel", callbackParams);
11953
11983
  };
11954
11984
  const handleFilterTableConfirm = (_columns, eventType) => {
11955
- filterColumns.value = _columns;
11985
+ setFilterColumns(_columns);
11956
11986
  emit("filterTableHeader", _columns, eventType);
11957
- subColumns.value = _columns.filter(
11958
- (item) => vue.unref(item.hideInTable) !== true && item.headerIsChecked !== false
11959
- );
11960
11987
  };
11961
11988
  const handleClickDensity = (size2) => {
11962
11989
  state.size = size2;
@@ -12072,9 +12099,9 @@
12072
12099
  _ctx.titleBar ? (vue.openBlock(), vue.createBlock(PlusTableTitleBar, {
12073
12100
  key: 0,
12074
12101
  "origin-columns": _ctx.columns,
12075
- columns: filterColumns.value,
12102
+ columns: vue.unref(filterColumns),
12076
12103
  "default-size": vue.unref(size),
12077
- "columns-is-change": columnsIsChange.value,
12104
+ "columns-is-change": vue.unref(columnsIsChange),
12078
12105
  "title-bar": _ctx.titleBar,
12079
12106
  onClickDensity: handleClickDensity,
12080
12107
  onFilterTableHeader: handleFilterTableConfirm,
@@ -12203,7 +12230,7 @@
12203
12230
  }, _ctx.expandTableColumnProps),
12204
12231
  {
12205
12232
  default: vue.withCtx((scoped) => [
12206
- vue.createElementVNode("div", _hoisted_1$7, [
12233
+ vue.createElementVNode("div", _hoisted_1$9, [
12207
12234
  vue.renderSlot(_ctx.$slots, "expand", vue.mergeProps({
12208
12235
  index: scoped.$index
12209
12236
  }, scoped))
@@ -12226,12 +12253,11 @@
12226
12253
  vue.renderSlot(_ctx.$slots, "default", {}, () => [
12227
12254
  vue.createCommentVNode("\u914D\u7F6E\u6E32\u67D3\u680F "),
12228
12255
  vue.createVNode(PlusTableColumn, {
12229
- columns: subColumns.value,
12256
+ columns: vue.unref(subColumns),
12230
12257
  editable: _ctx.editable,
12231
12258
  "sub-page-info": vue.unref(subPageInfo),
12232
12259
  "table-data-length": tableDataLength.value,
12233
12260
  "empty-value": _ctx.emptyValue,
12234
- "plain-text-cell": _ctx.plainTextCell,
12235
12261
  onFormChange: handleFormChange
12236
12262
  }, vue.createSlots({
12237
12263
  _: 2
@@ -12245,7 +12271,7 @@
12245
12271
  ])
12246
12272
  };
12247
12273
  })
12248
- ]), 1032, ["columns", "editable", "sub-page-info", "table-data-length", "empty-value", "plain-text-cell"])
12274
+ ]), 1032, ["columns", "editable", "sub-page-info", "table-data-length", "empty-value"])
12249
12275
  ]),
12250
12276
  vue.createCommentVNode(" \u64CD\u4F5C\u680F "),
12251
12277
  _ctx.actionBar ? (vue.openBlock(), vue.createBlock(
@@ -12315,95 +12341,1603 @@
12315
12341
  }
12316
12342
  });
12317
12343
 
12318
- var _Table = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["__file", "index.vue"]]);
12344
+ var _Table = /* @__PURE__ */ _export_sfc(_sfc_main$g, [["__file", "index.vue"]]);
12319
12345
 
12320
12346
  const PlusTable = _Table;
12321
12347
 
12322
- var _sfc_main$c = /* @__PURE__ */ vue.defineComponent({
12348
+ const _hoisted_1$8 = { class: "plus-table-lite__header" };
12349
+ const _hoisted_2$4 = ["innerHTML"];
12350
+ var _sfc_main$f = /* @__PURE__ */ vue.defineComponent({
12323
12351
  ...{
12324
- name: "PlusDescriptions"
12352
+ name: "PlusTableLite",
12353
+ inheritAttrs: false
12325
12354
  },
12326
12355
  __name: "index",
12327
12356
  props: {
12328
- data: { default: () => ({}) },
12357
+ tableData: { default: void 0 },
12358
+ data: { default: void 0 },
12329
12359
  columns: { default: () => [] },
12330
- column: { default: 3 },
12331
- title: { default: "" },
12360
+ defaultSize: { default: "default" },
12361
+ pagination: { type: [Boolean, Object], default: false },
12362
+ actionBar: { type: [Boolean, Object], default: false },
12363
+ hasIndexColumn: { type: Boolean, default: false },
12364
+ titleBar: { type: [Boolean, Object], default: true },
12365
+ isSelection: { type: Boolean, default: false },
12366
+ specialColumnsOrder: { default: void 0 },
12367
+ loadingStatus: { type: Boolean, default: false },
12368
+ rowKey: { type: [String, Function], default: "id" },
12369
+ defaultSelectedKeys: { default: () => [] },
12370
+ selectionTableColumnProps: { default: () => ({ width: 40 }) },
12371
+ indexTableColumnProps: { default: () => ({}) },
12372
+ indexContentStyle: { type: [Object, Function], default: () => ({}) },
12373
+ headerCellStyle: { default: () => ({
12374
+ "background-color": "var(--el-fill-color-light)"
12375
+ }) },
12376
+ emptyValue: { default: void 0 },
12377
+ size: {},
12378
+ width: {},
12379
+ height: {},
12380
+ maxHeight: {},
12381
+ fit: { type: Boolean },
12382
+ stripe: { type: Boolean },
12332
12383
  border: { type: Boolean, default: true },
12333
- editable: { type: Boolean, default: false },
12334
- formProps: { default: void 0 },
12335
- descriptionsItemProps: { default: void 0 }
12384
+ context: {},
12385
+ showHeader: { type: Boolean },
12386
+ showSummary: { type: Boolean },
12387
+ sumText: {},
12388
+ summaryMethod: {},
12389
+ rowClassName: {},
12390
+ rowStyle: {},
12391
+ cellClassName: {},
12392
+ cellStyle: {},
12393
+ headerRowClassName: {},
12394
+ headerRowStyle: {},
12395
+ headerCellClassName: {},
12396
+ highlightCurrentRow: { type: Boolean },
12397
+ currentRowKey: {},
12398
+ emptyText: {},
12399
+ expandRowKeys: {},
12400
+ defaultExpandAll: { type: Boolean },
12401
+ defaultSort: {},
12402
+ tooltipEffect: {},
12403
+ tooltipOptions: {},
12404
+ spanMethod: {},
12405
+ selectOnIndeterminate: { type: Boolean },
12406
+ indent: {},
12407
+ treeProps: {},
12408
+ lazy: { type: Boolean },
12409
+ load: {},
12410
+ className: {},
12411
+ style: {},
12412
+ tableLayout: {},
12413
+ scrollbarAlwaysOn: { type: Boolean },
12414
+ flexible: { type: Boolean },
12415
+ showOverflowTooltip: { type: [Boolean, Object] }
12336
12416
  },
12337
- emits: ["formChange"],
12417
+ emits: ["selection-change", "paginationChange", "clickAction", "clickActionConfirmCancel", "refresh", "filterTableHeader"],
12338
12418
  setup(__props, { expose: __expose, emit: __emit }) {
12419
+ var _a, _b;
12339
12420
  const props = __props;
12340
12421
  const emit = __emit;
12341
- const slots = vue.useSlots();
12342
- const plusDisplayItemInstance = vue.ref();
12343
- const elBorder = vue.computed(() => props.editable ? true : props.border);
12344
- const formRefs = vue.shallowRef([]);
12345
- const subColumns = vue.computed(
12346
- () => props.columns.filter((item) => vue.unref(item.hideInDescriptions) !== true)
12347
- );
12348
- const getDisplayValue = (prop) => getValue(props.data, prop);
12349
- const hasDescSlot = (prop) => !!slots[getDescSlotName(prop)];
12350
- const hasDescLabelSlot = (prop) => !!slots[getDescLabelSlotName(prop)];
12351
- const subColumnsKey = vue.computed(() => subColumns.value.map((i) => i.prop).join(","));
12352
- const setFormRef = () => {
12353
- var _a, _b;
12354
- if (!((_a = plusDisplayItemInstance.value) == null ? void 0 : _a.length)) return;
12355
- const list = ((_b = plusDisplayItemInstance.value) == null ? void 0 : _b.map((item) => ({
12356
- ...item,
12357
- ...item == null ? void 0 : item.getDisplayItemInstance()
12358
- }))) || [];
12359
- formRefs.value = list;
12360
- };
12361
- vue.watch(
12362
- plusDisplayItemInstance,
12363
- () => {
12364
- setFormRef();
12365
- },
12366
- {
12367
- deep: true,
12368
- flush: "post"
12422
+ const { t } = useLocale();
12423
+ const tableInstance = vue.shallowRef(null);
12424
+ const wrapperInstance = vue.ref(null);
12425
+ const paginationInstance = vue.ref(null);
12426
+ const state = vue.reactive({
12427
+ size: props.defaultSize,
12428
+ subPageInfo: {
12429
+ ...((_a = props.pagination) == null ? void 0 : _a.modelValue) || DefaultPageInfo
12369
12430
  }
12370
- );
12371
- const getIsRequired = (item, index) => {
12372
- var _a;
12373
- const itemFormProps = isFunction(item.formProps) ? item.formProps(props.data[item.prop], { row: props.data, index }) : vue.unref(item.formProps);
12374
- const rules = Reflect.get((itemFormProps == null ? void 0 : itemFormProps.rules) || ((_a = props.formProps) == null ? void 0 : _a.rules) || {}, item.prop) || {};
12375
- const isRequired = Object.values(rules).some((i) => i.required);
12376
- return isRequired;
12431
+ });
12432
+ const __tableData = vue.computed(() => {
12433
+ var _a2, _b2;
12434
+ return (_b2 = (_a2 = props.tableData) != null ? _a2 : props.data) != null ? _b2 : [];
12435
+ });
12436
+ const { subColumns, filterColumns, columnsIsChange, setFilterColumns } = useTableColumns({
12437
+ columns: () => props.columns || []
12438
+ });
12439
+ const resolveEmptyText = (column) => {
12440
+ var _a2, _b2;
12441
+ return (_b2 = (_a2 = column.emptyValue) != null ? _a2 : props.emptyValue) != null ? _b2 : "";
12377
12442
  };
12378
- const handleChange = (data, index, item) => {
12379
- const formChangeCallBackParams = { ...data, index, column: { ...item } };
12380
- emit("formChange", formChangeCallBackParams);
12443
+ const toVNode = (result) => {
12444
+ if (result === null || result === void 0 || result === "") return vue.createTextVNode("");
12445
+ if (isString(result) || typeof result === "number") return vue.createTextVNode(String(result));
12446
+ if (vue.isVNode(result)) return result;
12447
+ return vue.h(result);
12381
12448
  };
12382
- const validate = async () => {
12383
- var _a;
12384
- try {
12385
- await Promise.all(
12386
- (_a = formRefs.value) == null ? void 0 : _a.map((item) => {
12387
- var _a2;
12388
- return (_a2 = item.formInstance.value) == null ? void 0 : _a2.validate();
12389
- })
12390
- );
12391
- } catch (errors) {
12392
- return Promise.reject(errors);
12449
+ const getByPath = (target, path) => {
12450
+ const keys = path.replace(/\[(\w+)\]/g, ".$1").split(".").filter(Boolean);
12451
+ let current = target;
12452
+ for (const key of keys) {
12453
+ if (current === null || current === void 0) return void 0;
12454
+ current = current[key];
12393
12455
  }
12456
+ return current;
12394
12457
  };
12395
- const clearValidate = () => {
12396
- var _a;
12397
- (_a = formRefs.value) == null ? void 0 : _a.forEach((item) => {
12398
- var _a2;
12399
- (_a2 = item.formInstance.value) == null ? void 0 : _a2.clearValidate();
12400
- });
12401
- };
12402
- __expose({
12403
- formRefs,
12404
- validate,
12405
- clearValidate
12406
- });
12458
+ const preparedColumns = vue.computed(
12459
+ () => subColumns.value.map((column) => {
12460
+ const prop = column.prop;
12461
+ const label = getLabel(column.label);
12462
+ const isSimpleProp = !prop.includes(".") && !prop.includes("[");
12463
+ const readValue = isSimpleProp ? (row) => row == null ? void 0 : row[prop] : (row) => getByPath(row, prop);
12464
+ const cellText = (row, index) => {
12465
+ const value = readValue(row);
12466
+ if (isFunction(column.formatter)) {
12467
+ const formatted = column.formatter(value, { row, column, index });
12468
+ return String(
12469
+ formatted === null || formatted === void 0 ? resolveEmptyText(column) : formatted
12470
+ );
12471
+ }
12472
+ return value === null || value === void 0 || value === "" ? String(resolveEmptyText(column)) : String(value);
12473
+ };
12474
+ const prepared = {
12475
+ key: getTableKey(column, true),
12476
+ prop,
12477
+ column,
12478
+ tableColumnProps: column.tableColumnProps || {},
12479
+ label,
12480
+ width: column.width,
12481
+ minWidth: column.minWidth,
12482
+ headerSlotName: getTableHeaderSlotName(prop),
12483
+ cellSlotName: getTableCellSlotName(prop),
12484
+ tooltip: !!column.tooltip,
12485
+ tooltipProps: getTooltip(column.tooltip),
12486
+ readValue,
12487
+ cellText
12488
+ };
12489
+ if (isFunction(column.renderHeader)) {
12490
+ prepared.headerRender = () => {
12491
+ var _a2;
12492
+ return toVNode((_a2 = column.renderHeader) == null ? void 0 : _a2.call(column, label, column));
12493
+ };
12494
+ }
12495
+ if (isFunction(column.render)) {
12496
+ prepared.cellRender = ({ row, index }) => {
12497
+ var _a2;
12498
+ return toVNode((_a2 = column.render) == null ? void 0 : _a2.call(column, readValue(row), { row, column, index }));
12499
+ };
12500
+ } else if (isFunction(column.renderHTML)) {
12501
+ prepared.cellHTML = (row, index) => {
12502
+ var _a2, _b2;
12503
+ return String((_b2 = (_a2 = column.renderHTML) == null ? void 0 : _a2.call(column, readValue(row), { row, column, index })) != null ? _b2 : "");
12504
+ };
12505
+ }
12506
+ return prepared;
12507
+ })
12508
+ );
12509
+ const getRowKeyValue = (row) => {
12510
+ const { rowKey } = props;
12511
+ if (isFunction(rowKey)) return rowKey(row);
12512
+ return row == null ? void 0 : row[rowKey];
12513
+ };
12514
+ const selectedKeys = vue.ref(new Set(props.defaultSelectedKeys));
12515
+ let selectedRowCache = /* @__PURE__ */ new Map();
12516
+ function isRowSelectable(row, index) {
12517
+ var _a2;
12518
+ const selectable = (_a2 = props.selectionTableColumnProps) == null ? void 0 : _a2.selectable;
12519
+ return isFunction(selectable) ? selectable(row, index) !== false : true;
12520
+ }
12521
+ const selectableRows = vue.computed(
12522
+ () => __tableData.value.filter((row, index) => isRowSelectable(row, index))
12523
+ );
12524
+ const isRowSelected = (row) => {
12525
+ const key = getRowKeyValue(row);
12526
+ return key === void 0 ? false : selectedKeys.value.has(key);
12527
+ };
12528
+ const isAllSelected = vue.computed(
12529
+ () => selectableRows.value.length > 0 && selectableRows.value.every((row) => selectedKeys.value.has(getRowKeyValue(row)))
12530
+ );
12531
+ const isIndeterminate = vue.computed(
12532
+ () => !isAllSelected.value && selectableRows.value.some((row) => selectedKeys.value.has(getRowKeyValue(row)))
12533
+ );
12534
+ const getSelectedRows = () => {
12535
+ const rows = [];
12536
+ selectedRowCache.forEach((row, key) => {
12537
+ if (selectedKeys.value.has(key)) rows.push(row);
12538
+ });
12539
+ return rows;
12540
+ };
12541
+ const handleToggleRow = (row, checked) => {
12542
+ const key = getRowKeyValue(row);
12543
+ if (key === void 0) return;
12544
+ if (checked) {
12545
+ selectedKeys.value.add(key);
12546
+ selectedRowCache.set(key, row);
12547
+ } else {
12548
+ selectedKeys.value.delete(key);
12549
+ selectedRowCache.delete(key);
12550
+ }
12551
+ emit("selection-change", getSelectedRows());
12552
+ };
12553
+ const handleToggleAll = () => {
12554
+ const nextAllSelected = !isAllSelected.value;
12555
+ selectableRows.value.forEach((row) => {
12556
+ const key = getRowKeyValue(row);
12557
+ if (key === void 0) return;
12558
+ if (nextAllSelected) {
12559
+ selectedKeys.value.add(key);
12560
+ selectedRowCache.set(key, row);
12561
+ } else {
12562
+ selectedKeys.value.delete(key);
12563
+ selectedRowCache.delete(key);
12564
+ }
12565
+ });
12566
+ emit("selection-change", getSelectedRows());
12567
+ };
12568
+ const clearSelection = () => {
12569
+ selectedKeys.value = /* @__PURE__ */ new Set();
12570
+ selectedRowCache = /* @__PURE__ */ new Map();
12571
+ };
12572
+ const syncSelectedRowCache = (rows) => {
12573
+ if (!selectedKeys.value.size || !(rows == null ? void 0 : rows.length)) return;
12574
+ rows.forEach((row) => {
12575
+ const key = getRowKeyValue(row);
12576
+ if (key !== void 0 && selectedKeys.value.has(key)) {
12577
+ selectedRowCache.set(key, row);
12578
+ }
12579
+ });
12580
+ };
12581
+ vue.watch(
12582
+ () => __tableData.value,
12583
+ (rows) => syncSelectedRowCache(rows || []),
12584
+ { immediate: true }
12585
+ );
12586
+ vue.watch(
12587
+ () => props.defaultSelectedKeys,
12588
+ (keys) => {
12589
+ if (!(keys == null ? void 0 : keys.length)) return;
12590
+ keys.forEach((key) => selectedKeys.value.add(key));
12591
+ syncSelectedRowCache(__tableData.value);
12592
+ }
12593
+ );
12594
+ const specialColumns = vue.computed(() => {
12595
+ const active = [];
12596
+ if (props.isSelection) active.push("selection");
12597
+ if (props.hasIndexColumn) active.push("index");
12598
+ const defaultOrder = ["selection", "index"];
12599
+ const order = [...props.specialColumnsOrder || [], ...defaultOrder].filter(
12600
+ (item, index, array) => array.indexOf(item) === index
12601
+ );
12602
+ return order.filter((item) => active.includes(item));
12603
+ });
12604
+ const selectionProps = vue.computed(() => props.selectionTableColumnProps || {});
12605
+ const selectionWidth = vue.computed(() => selectionProps.value.width || 40);
12606
+ const selectionAlign = vue.computed(() => selectionProps.value.align || "center");
12607
+ const selectionFixed = vue.computed(
12608
+ () => {
12609
+ var _a2;
12610
+ return (_a2 = selectionProps.value.fixed) != null ? _a2 : "left";
12611
+ }
12612
+ );
12613
+ const indexProps = vue.computed(() => props.indexTableColumnProps || {});
12614
+ const indexFixed = vue.computed(
12615
+ () => indexProps.value.fixed || "left"
12616
+ );
12617
+ const getIndexValue = (index) => {
12618
+ const customIndex = indexProps.value.index;
12619
+ if (isFunction(customIndex)) return customIndex(index);
12620
+ if (typeof customIndex === "number") return customIndex;
12621
+ const { page, pageSize } = state.subPageInfo;
12622
+ return (page - 1) * pageSize + index + 1;
12623
+ };
12624
+ const getIndexStyle = (row, index) => {
12625
+ const style = props.indexContentStyle;
12626
+ if (isFunction(style)) return style(row, index);
12627
+ if (isPlainObject(style)) return style;
12628
+ return {};
12629
+ };
12630
+ const actionBarLabel = vue.computed(
12631
+ () => props.actionBar ? vue.unref(props.actionBar.label) || t("plus.table.action") : ""
12632
+ );
12633
+ const actionBarFixed = vue.computed(
12634
+ () => (props.actionBar ? props.actionBar.fixed : void 0) || "right"
12635
+ );
12636
+ const handlePaginationChange = () => {
12637
+ emit("paginationChange", { ...state.subPageInfo });
12638
+ };
12639
+ const handleRefresh = () => emit("refresh");
12640
+ const handleClickDensity = (size) => {
12641
+ state.size = size;
12642
+ };
12643
+ const handleFilterTableConfirm = (list, eventType) => {
12644
+ setFilterColumns(list);
12645
+ emit("filterTableHeader", list, eventType);
12646
+ };
12647
+ const adaptiveHeight = vue.ref();
12648
+ const resolvedHeight = vue.computed(() => {
12649
+ const height = props.height;
12650
+ return height !== void 0 ? height : adaptiveHeight.value;
12651
+ });
12652
+ const hasAdaptive = vue.computed(() => props.height === void 0 && !!props.adaptive);
12653
+ const calcAdaptiveHeight = () => {
12654
+ var _a2;
12655
+ if (!wrapperInstance.value) return;
12656
+ let offsetBottom = 20;
12657
+ if (isPlainObject(props.adaptive)) {
12658
+ offsetBottom = (_a2 = props.adaptive.offsetBottom) != null ? _a2 : offsetBottom;
12659
+ }
12660
+ const paginationHeight = paginationInstance.value && props.pagination ? paginationInstance.value.$el.offsetHeight : 0;
12661
+ const top = wrapperInstance.value.getBoundingClientRect().top;
12662
+ adaptiveHeight.value = Math.max(window.innerHeight - top - offsetBottom - paginationHeight, 100);
12663
+ };
12664
+ const debounceCalcAdaptiveHeight = debounce(
12665
+ calcAdaptiveHeight,
12666
+ isPlainObject(props.adaptive) ? (_b = props.adaptive.timeout) != null ? _b : 60 : 60
12667
+ );
12668
+ vue.onMounted(() => {
12669
+ if (hasAdaptive.value) {
12670
+ calcAdaptiveHeight();
12671
+ window.addEventListener("resize", debounceCalcAdaptiveHeight);
12672
+ }
12673
+ });
12674
+ vue.onBeforeUnmount(() => {
12675
+ window.removeEventListener("resize", debounceCalcAdaptiveHeight);
12676
+ });
12677
+ vue.provide(TableFormRefInjectionKey, vue.shallowRef({}));
12678
+ __expose({
12679
+ /** el-table 实例,可用于 doLayout 等 */
12680
+ tableInstance,
12681
+ /** 获取所有已选行(跨页累计) */
12682
+ getSelectedRows,
12683
+ /** 清空所有已选(跨页) */
12684
+ clearSelection,
12685
+ /** 当前已选 rowKey 列表 */
12686
+ getSelectedKeys: () => Array.from(selectedKeys.value)
12687
+ });
12688
+ return (_ctx, _cache) => {
12689
+ return vue.openBlock(), vue.createElementBlock(
12690
+ "div",
12691
+ {
12692
+ ref_key: "wrapperInstance",
12693
+ ref: wrapperInstance,
12694
+ class: "plus-table-lite"
12695
+ },
12696
+ [
12697
+ vue.createCommentVNode(" \u6807\u9898\u680F\uFF1A\u5237\u65B0 / \u5BC6\u5EA6 / \u5217\u8BBE\u7F6E\uFF0C\u4E0E PlusTable \u5171\u7528\u540C\u4E00\u4EFD\u5B9E\u73B0 "),
12698
+ _ctx.titleBar ? (vue.openBlock(), vue.createBlock(vue.unref(PlusTableTitleBar), {
12699
+ key: 0,
12700
+ "origin-columns": _ctx.columns || [],
12701
+ columns: vue.unref(filterColumns),
12702
+ "default-size": state.size,
12703
+ "columns-is-change": vue.unref(columnsIsChange),
12704
+ "title-bar": _ctx.titleBar,
12705
+ onClickDensity: handleClickDensity,
12706
+ onFilterTableHeader: handleFilterTableConfirm,
12707
+ onRefresh: handleRefresh
12708
+ }, vue.createSlots({
12709
+ title: vue.withCtx(() => [
12710
+ vue.renderSlot(_ctx.$slots, "title")
12711
+ ]),
12712
+ toolbar: vue.withCtx(() => [
12713
+ vue.renderSlot(_ctx.$slots, "toolbar")
12714
+ ]),
12715
+ _: 2
12716
+ /* DYNAMIC */
12717
+ }, [
12718
+ _ctx.$slots["drag-sort-icon"] ? {
12719
+ name: "drag-sort-icon",
12720
+ fn: vue.withCtx(() => [
12721
+ vue.renderSlot(_ctx.$slots, "drag-sort-icon")
12722
+ ]),
12723
+ key: "0"
12724
+ } : void 0,
12725
+ _ctx.$slots["column-settings-icon"] ? {
12726
+ name: "column-settings-icon",
12727
+ fn: vue.withCtx(() => [
12728
+ vue.renderSlot(_ctx.$slots, "column-settings-icon")
12729
+ ]),
12730
+ key: "1"
12731
+ } : void 0,
12732
+ _ctx.$slots["density-icon"] ? {
12733
+ name: "density-icon",
12734
+ fn: vue.withCtx(() => [
12735
+ vue.renderSlot(_ctx.$slots, "density-icon")
12736
+ ]),
12737
+ key: "2"
12738
+ } : void 0
12739
+ ]), 1032, ["origin-columns", "columns", "default-size", "columns-is-change", "title-bar"])) : vue.createCommentVNode("v-if", true),
12740
+ vue.withDirectives((vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElTable), vue.mergeProps({
12741
+ ref_key: "tableInstance",
12742
+ ref: tableInstance,
12743
+ data: __tableData.value,
12744
+ border: _ctx.border,
12745
+ height: resolvedHeight.value,
12746
+ "header-cell-style": _ctx.headerCellStyle,
12747
+ size: state.size,
12748
+ "row-key": _ctx.rowKey
12749
+ }, _ctx.$attrs), {
12750
+ empty: vue.withCtx(() => [
12751
+ vue.renderSlot(_ctx.$slots, "empty")
12752
+ ]),
12753
+ default: vue.withCtx(() => [
12754
+ (vue.openBlock(true), vue.createElementBlock(
12755
+ vue.Fragment,
12756
+ null,
12757
+ vue.renderList(specialColumns.value, (type) => {
12758
+ return vue.openBlock(), vue.createElementBlock(
12759
+ vue.Fragment,
12760
+ { key: type },
12761
+ [
12762
+ vue.createCommentVNode("\n \u591A\u9009\u5217\n \u52FE\u9009\u72B6\u6001\u7531\u7EC4\u4EF6\u81EA\u8EAB\u7684 selectedKeys \u7EF4\u62A4\uFF0C\u56E0\u6B64\u7FFB\u9875\u540E\u4F9D\u7136\u4FDD\u7559\uFF1B\n \u4E0D\u4F7F\u7528 el-table \u5185\u7F6E\u7684 reserve-selection\uFF08\u5176\u884C\u4E3A\u4F9D\u8D56 selection \u5185\u90E8\u72B6\u6001\uFF0C\u8DE8\u9875\u4E0D\u53EF\u9760\uFF09\u3002\n "),
12763
+ type === "selection" ? (vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElTableColumn), {
12764
+ key: "selection",
12765
+ "class-name": "plus-table-lite-selection",
12766
+ width: selectionWidth.value,
12767
+ align: selectionAlign.value,
12768
+ fixed: selectionFixed.value
12769
+ }, {
12770
+ header: vue.withCtx(() => [
12771
+ vue.createVNode(vue.unref(elementPlus.ElCheckbox), {
12772
+ "model-value": isAllSelected.value,
12773
+ indeterminate: isIndeterminate.value,
12774
+ onChange: handleToggleAll
12775
+ }, null, 8, ["model-value", "indeterminate"])
12776
+ ]),
12777
+ default: vue.withCtx(({ row, $index }) => [
12778
+ vue.createVNode(vue.unref(elementPlus.ElCheckbox), {
12779
+ "model-value": isRowSelected(row),
12780
+ disabled: !isRowSelectable(row, $index),
12781
+ onChange: (checked) => handleToggleRow(row, !!checked)
12782
+ }, null, 8, ["model-value", "disabled", "onChange"])
12783
+ ]),
12784
+ _: 1
12785
+ /* STABLE */
12786
+ }, 8, ["width", "align", "fixed"])) : (vue.openBlock(), vue.createElementBlock(
12787
+ vue.Fragment,
12788
+ { key: 1 },
12789
+ [
12790
+ vue.createCommentVNode(" \u5E8F\u53F7\u5217 "),
12791
+ vue.createVNode(vue.unref(elementPlus.ElTableColumn), {
12792
+ key: "index",
12793
+ type: "index",
12794
+ label: "#",
12795
+ "class-name": "plus-table-lite-index",
12796
+ width: indexProps.value.width || 60,
12797
+ fixed: indexFixed.value,
12798
+ align: "center",
12799
+ index: getIndexValue
12800
+ }, {
12801
+ default: vue.withCtx(({ $index }) => [
12802
+ vue.createElementVNode(
12803
+ "div",
12804
+ {
12805
+ class: "plus-table-lite-index__content",
12806
+ style: vue.normalizeStyle(getIndexStyle(__tableData.value[$index], $index))
12807
+ },
12808
+ vue.toDisplayString(getIndexValue($index)),
12809
+ 5
12810
+ /* TEXT, STYLE */
12811
+ )
12812
+ ]),
12813
+ _: 1
12814
+ /* STABLE */
12815
+ }, 8, ["width", "fixed"])
12816
+ ],
12817
+ 2112
12818
+ /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
12819
+ ))
12820
+ ],
12821
+ 64
12822
+ /* STABLE_FRAGMENT */
12823
+ );
12824
+ }),
12825
+ 128
12826
+ /* KEYED_FRAGMENT */
12827
+ )),
12828
+ (vue.openBlock(true), vue.createElementBlock(
12829
+ vue.Fragment,
12830
+ null,
12831
+ vue.renderList(preparedColumns.value, (col) => {
12832
+ return vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElTableColumn), vue.mergeProps({
12833
+ key: col.key
12834
+ }, col.tableColumnProps, {
12835
+ prop: col.prop,
12836
+ label: col.label,
12837
+ width: col.width,
12838
+ "min-width": col.minWidth
12839
+ }), {
12840
+ header: vue.withCtx((scoped) => [
12841
+ vue.createElementVNode("span", _hoisted_1$8, [
12842
+ vue.renderSlot(_ctx.$slots, col.headerSlotName, vue.mergeProps(scoped, {
12843
+ prop: col.prop,
12844
+ label: col.label,
12845
+ column: col.column
12846
+ }), () => [
12847
+ col.headerRender ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(col.headerRender), { key: 0 })) : (vue.openBlock(), vue.createElementBlock(
12848
+ vue.Fragment,
12849
+ { key: 1 },
12850
+ [
12851
+ vue.createTextVNode(
12852
+ vue.toDisplayString(col.label),
12853
+ 1
12854
+ /* TEXT */
12855
+ )
12856
+ ],
12857
+ 64
12858
+ /* STABLE_FRAGMENT */
12859
+ ))
12860
+ ]),
12861
+ col.tooltip ? (vue.openBlock(), vue.createBlock(
12862
+ vue.unref(elementPlus.ElTooltip),
12863
+ vue.mergeProps({
12864
+ key: 0,
12865
+ placement: "top"
12866
+ }, col.tooltipProps),
12867
+ {
12868
+ default: vue.withCtx(() => [
12869
+ vue.renderSlot(_ctx.$slots, "tooltip-icon", {}, () => [
12870
+ vue.createVNode(vue.unref(elementPlus.ElIcon), {
12871
+ class: "plus-table-lite__header__icon",
12872
+ size: 16
12873
+ }, {
12874
+ default: vue.withCtx(() => [
12875
+ vue.createVNode(vue.unref(question_filled_default))
12876
+ ]),
12877
+ _: 1
12878
+ /* STABLE */
12879
+ })
12880
+ ])
12881
+ ]),
12882
+ _: 2
12883
+ /* DYNAMIC */
12884
+ },
12885
+ 1040
12886
+ /* FULL_PROPS, DYNAMIC_SLOTS */
12887
+ )) : vue.createCommentVNode("v-if", true)
12888
+ ])
12889
+ ]),
12890
+ default: vue.withCtx(({ row, $index }) => [
12891
+ vue.renderSlot(_ctx.$slots, col.cellSlotName, {
12892
+ row,
12893
+ index: $index,
12894
+ value: col.readValue(row),
12895
+ column: col.column
12896
+ }, () => [
12897
+ vue.createCommentVNode(" \u81EA\u5B9A\u4E49 render\uFF1A\u552F\u4E00\u9700\u8981\u7EC4\u4EF6\u7684\u4F4D\u7F6E\uFF0C\u6309\u5217\u521B\u5EFA\u4E00\u6B21 "),
12898
+ col.cellRender ? (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(col.cellRender), {
12899
+ key: 0,
12900
+ row,
12901
+ index: $index
12902
+ }, null, 8, ["row", "index"])) : col.cellHTML ? (vue.openBlock(), vue.createElementBlock(
12903
+ vue.Fragment,
12904
+ { key: 1 },
12905
+ [
12906
+ vue.createCommentVNode(" renderHTML "),
12907
+ vue.createElementVNode("span", {
12908
+ innerHTML: col.cellHTML(row, $index)
12909
+ }, null, 8, _hoisted_2$4)
12910
+ ],
12911
+ 2112
12912
+ /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
12913
+ )) : (vue.openBlock(), vue.createElementBlock(
12914
+ vue.Fragment,
12915
+ { key: 2 },
12916
+ [
12917
+ vue.createCommentVNode(" \u7EAF\u6587\u672C\uFF1A\u96F6\u5B9E\u4F8B "),
12918
+ vue.createTextVNode(
12919
+ vue.toDisplayString(col.cellText(row, $index)),
12920
+ 1
12921
+ /* TEXT */
12922
+ )
12923
+ ],
12924
+ 64
12925
+ /* STABLE_FRAGMENT */
12926
+ ))
12927
+ ])
12928
+ ]),
12929
+ _: 2
12930
+ /* DYNAMIC */
12931
+ }, 1040, ["prop", "label", "width", "min-width"]);
12932
+ }),
12933
+ 128
12934
+ /* KEYED_FRAGMENT */
12935
+ )),
12936
+ _ctx.actionBar ? (vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElTableColumn), vue.mergeProps({
12937
+ key: 0,
12938
+ "class-name": "plus-table-action-bar",
12939
+ label: actionBarLabel.value,
12940
+ fixed: actionBarFixed.value,
12941
+ width: _ctx.actionBar.width || 200
12942
+ }, _ctx.actionBar.actionBarTableColumnProps), {
12943
+ default: vue.withCtx(({ row, $index }) => [
12944
+ vue.createVNode(vue.unref(PlusTableActionBarContent), {
12945
+ row,
12946
+ index: $index,
12947
+ type: _ctx.actionBar.type,
12948
+ buttons: _ctx.actionBar.buttons,
12949
+ "show-number": _ctx.actionBar.showNumber,
12950
+ "show-limit-include-more": _ctx.actionBar.showLimitIncludeMore,
12951
+ "confirm-type": _ctx.actionBar.confirmType,
12952
+ "more-type": _ctx.actionBar.moreType,
12953
+ onClickAction: _cache[0] || (_cache[0] = (data) => emit("clickAction", data)),
12954
+ onClickActionConfirmCancel: _cache[1] || (_cache[1] = (data) => emit("clickActionConfirmCancel", data))
12955
+ }, vue.createSlots({
12956
+ _: 2
12957
+ /* DYNAMIC */
12958
+ }, [
12959
+ _ctx.$slots["action-bar-more-icon"] ? {
12960
+ name: "action-bar-more-icon",
12961
+ fn: vue.withCtx(() => [
12962
+ vue.renderSlot(_ctx.$slots, "action-bar-more-icon")
12963
+ ]),
12964
+ key: "0"
12965
+ } : void 0
12966
+ ]), 1032, ["row", "index", "type", "buttons", "show-number", "show-limit-include-more", "confirm-type", "more-type"])
12967
+ ]),
12968
+ _: 3
12969
+ /* FORWARDED */
12970
+ }, 16, ["label", "fixed", "width"])) : vue.createCommentVNode("v-if", true)
12971
+ ]),
12972
+ _: 3
12973
+ /* FORWARDED */
12974
+ }, 16, ["data", "border", "height", "header-cell-style", "size", "row-key"])), [
12975
+ [vue.unref(elementPlus.vLoading), _ctx.loadingStatus]
12976
+ ]),
12977
+ vue.createCommentVNode(" \u5206\u9875 "),
12978
+ _ctx.pagination ? (vue.openBlock(), vue.createBlock(vue.unref(PlusPagination), vue.mergeProps({
12979
+ key: 1,
12980
+ ref_key: "paginationInstance",
12981
+ ref: paginationInstance,
12982
+ modelValue: state.subPageInfo,
12983
+ "onUpdate:modelValue": _cache[2] || (_cache[2] = ($event) => state.subPageInfo = $event)
12984
+ }, _ctx.pagination, { onChange: handlePaginationChange }), vue.createSlots({
12985
+ _: 2
12986
+ /* DYNAMIC */
12987
+ }, [
12988
+ _ctx.$slots["pagination-left"] ? {
12989
+ name: "pagination-left",
12990
+ fn: vue.withCtx(() => [
12991
+ vue.renderSlot(_ctx.$slots, "pagination-left")
12992
+ ]),
12993
+ key: "0"
12994
+ } : void 0,
12995
+ _ctx.$slots["pagination-right"] ? {
12996
+ name: "pagination-right",
12997
+ fn: vue.withCtx(() => [
12998
+ vue.renderSlot(_ctx.$slots, "pagination-right")
12999
+ ]),
13000
+ key: "1"
13001
+ } : void 0
13002
+ ]), 1040, ["modelValue"])) : vue.createCommentVNode("v-if", true)
13003
+ ],
13004
+ 512
13005
+ /* NEED_PATCH */
13006
+ );
13007
+ };
13008
+ }
13009
+ });
13010
+
13011
+ var TableLite = /* @__PURE__ */ _export_sfc(_sfc_main$f, [["__file", "index.vue"]]);
13012
+
13013
+ const PlusTableLite = TableLite;
13014
+
13015
+ const _hoisted_1$7 = { class: "plus-table-v2-header" };
13016
+ var _sfc_main$e = /* @__PURE__ */ vue.defineComponent({
13017
+ ...{
13018
+ name: "PlusTableV2HeaderCell"
13019
+ },
13020
+ __name: "table-v2-header-cell",
13021
+ props: {
13022
+ column: {},
13023
+ cellIndex: {}
13024
+ },
13025
+ setup(__props) {
13026
+ const props = __props;
13027
+ const labelText = vue.computed(() => getLabel(props.column.label));
13028
+ return (_ctx, _cache) => {
13029
+ return vue.openBlock(), vue.createElementBlock(
13030
+ vue.Fragment,
13031
+ null,
13032
+ [
13033
+ vue.createCommentVNode(" \u8868\u5934\u5355\u5143\u683C\uFF1A\u4E0E el-table \u7248\u672C\u7684 PlusTableColumn header \u903B\u8F91\u4FDD\u6301\u4E00\u81F4 "),
13034
+ vue.createElementVNode("span", _hoisted_1$7, [
13035
+ _ctx.column.renderHeader && vue.unref(isFunction)(_ctx.column.renderHeader) ? (vue.openBlock(), vue.createBlock(vue.unref(PlusRender), {
13036
+ key: 0,
13037
+ render: _ctx.column.renderHeader,
13038
+ params: { column: _ctx.column, cellIndex: _ctx.cellIndex },
13039
+ "callback-value": labelText.value
13040
+ }, null, 8, ["render", "params", "callback-value"])) : (vue.openBlock(), vue.createElementBlock(
13041
+ vue.Fragment,
13042
+ { key: 1 },
13043
+ [
13044
+ vue.createCommentVNode("\u8868\u683C\u5355\u5143\u683C Header \u7684\u63D2\u69FD "),
13045
+ vue.renderSlot(_ctx.$slots, vue.unref(getTableHeaderSlotName)(_ctx.column.prop), {
13046
+ prop: _ctx.column.prop,
13047
+ label: labelText.value,
13048
+ fieldProps: _ctx.column.fieldProps,
13049
+ valueType: _ctx.column.valueType,
13050
+ cellIndex: _ctx.cellIndex,
13051
+ column: _ctx.column
13052
+ }, () => [
13053
+ vue.createTextVNode(
13054
+ vue.toDisplayString(labelText.value),
13055
+ 1
13056
+ /* TEXT */
13057
+ )
13058
+ ])
13059
+ ],
13060
+ 2112
13061
+ /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
13062
+ )),
13063
+ _ctx.column.tooltip ? (vue.openBlock(), vue.createBlock(
13064
+ vue.unref(elementPlus.ElTooltip),
13065
+ vue.mergeProps({
13066
+ key: 2,
13067
+ placement: "top"
13068
+ }, vue.unref(getTooltip)(_ctx.column.tooltip)),
13069
+ {
13070
+ default: vue.withCtx(() => [
13071
+ vue.renderSlot(_ctx.$slots, "tooltip-icon", {}, () => [
13072
+ vue.createVNode(vue.unref(elementPlus.ElIcon), {
13073
+ class: "plus-table-v2-header__icon",
13074
+ size: 16
13075
+ }, {
13076
+ default: vue.withCtx(() => [
13077
+ vue.createVNode(vue.unref(question_filled_default))
13078
+ ]),
13079
+ _: 1
13080
+ /* STABLE */
13081
+ })
13082
+ ])
13083
+ ]),
13084
+ _: 3
13085
+ /* FORWARDED */
13086
+ },
13087
+ 16
13088
+ /* FULL_PROPS */
13089
+ )) : vue.createCommentVNode("v-if", true)
13090
+ ])
13091
+ ],
13092
+ 2112
13093
+ /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
13094
+ );
13095
+ };
13096
+ }
13097
+ });
13098
+
13099
+ var TableV2HeaderCell = /* @__PURE__ */ _export_sfc(_sfc_main$e, [["__file", "table-v2-header-cell.vue"]]);
13100
+
13101
+ const buildDataColumns = ({
13102
+ columns,
13103
+ renderCell,
13104
+ slots
13105
+ }) => {
13106
+ const headerSlots = {};
13107
+ Object.keys(slots || {}).forEach((key) => {
13108
+ if (key.startsWith("plus-header-") || key === "tooltip-icon") {
13109
+ headerSlots[key] = slots == null ? void 0 : slots[key];
13110
+ }
13111
+ });
13112
+ return columns.filter((col) => {
13113
+ var _a;
13114
+ return !((_a = col.children) == null ? void 0 : _a.length);
13115
+ }).map((col, columnIndex) => {
13116
+ const tableColumnProps = col.tableColumnProps || {};
13117
+ const fixed = tableColumnProps.fixed === true ? "left" : tableColumnProps.fixed;
13118
+ return {
13119
+ key: getTableKey(col, true),
13120
+ dataKey: col.prop,
13121
+ title: getLabel(col.label),
13122
+ width: typeof col.width === "number" ? col.width : Number(col.width) || void 0,
13123
+ minWidth: typeof col.minWidth === "number" ? col.minWidth : Number(col.minWidth) || void 0,
13124
+ fixed,
13125
+ align: tableColumnProps.align,
13126
+ class: tableColumnProps.className,
13127
+ cellRenderer: ({ rowData, rowIndex }) => renderCell({
13128
+ column: col,
13129
+ row: rowData,
13130
+ rowIndex,
13131
+ columnIndex
13132
+ }),
13133
+ headerCellRenderer: () => vue.h(TableV2HeaderCell, { column: col, cellIndex: columnIndex }, headerSlots)
13134
+ };
13135
+ });
13136
+ };
13137
+
13138
+ const toNumber = (value, fallback) => {
13139
+ const num = Number(value);
13140
+ return Number.isFinite(num) && num > 0 ? num : fallback;
13141
+ };
13142
+ const buildIndexColumn = ({
13143
+ pageInfo,
13144
+ indexContentStyle,
13145
+ columnProps = {}
13146
+ }) => {
13147
+ const getIndex = isNumber(columnProps.index) ? () => columnProps.index : isFunction(columnProps.index) ? columnProps.index : (index) => (((pageInfo == null ? void 0 : pageInfo.page) || 1) - 1) * ((pageInfo == null ? void 0 : pageInfo.pageSize) || 10) + index + 1;
13148
+ const resolveStyle = (row, index) => {
13149
+ if (isFunction(indexContentStyle)) return indexContentStyle(row, index);
13150
+ if (isPlainObject(indexContentStyle)) return indexContentStyle;
13151
+ return {};
13152
+ };
13153
+ return {
13154
+ key: "index",
13155
+ title: "#",
13156
+ width: toNumber(columnProps.width, 60),
13157
+ fixed: elementPlus.TableV2FixedDir.LEFT,
13158
+ align: "center",
13159
+ cellRenderer: ({ rowData, rowIndex }) => vue.h("div", { class: "plus-table-v2-index", style: resolveStyle(rowData, rowIndex) }, [
13160
+ String(getIndex(rowIndex))
13161
+ ])
13162
+ };
13163
+ };
13164
+ const buildRadioColumn = ({
13165
+ radioRow,
13166
+ onChange,
13167
+ radioProps,
13168
+ columnProps = {}
13169
+ }) => ({
13170
+ key: "radio",
13171
+ title: "",
13172
+ width: toNumber(columnProps.width, 50),
13173
+ fixed: elementPlus.TableV2FixedDir.LEFT,
13174
+ align: "center",
13175
+ cellRenderer: ({ rowData }) => vue.h(PlusRadio, {
13176
+ modelValue: isEqual(radioRow(), rowData),
13177
+ options: [{ value: true }],
13178
+ ...radioProps,
13179
+ onChange: (value) => onChange(value, rowData)
13180
+ })
13181
+ });
13182
+ const buildSelectionColumn = ({
13183
+ isSelected,
13184
+ isAllSelected,
13185
+ isIndeterminate,
13186
+ onToggleRow,
13187
+ onToggleAll,
13188
+ columnProps = {}
13189
+ }) => ({
13190
+ key: "selection",
13191
+ title: "",
13192
+ width: toNumber(columnProps.width, 40),
13193
+ fixed: elementPlus.TableV2FixedDir.LEFT,
13194
+ align: "center",
13195
+ headerCellRenderer: () => vue.h(elementPlus.ElCheckbox, {
13196
+ modelValue: isAllSelected(),
13197
+ indeterminate: isIndeterminate(),
13198
+ "onUpdate:modelValue": (checked) => onToggleAll(Boolean(checked))
13199
+ }),
13200
+ cellRenderer: ({ rowData }) => vue.h(elementPlus.ElCheckbox, {
13201
+ modelValue: isSelected(rowData),
13202
+ "onUpdate:modelValue": (checked) => onToggleRow(rowData, Boolean(checked))
13203
+ })
13204
+ });
13205
+
13206
+ const DEFAULT_TABLE_V2_MIN_WIDTH = 100;
13207
+ const toColumnNumber = (value) => {
13208
+ if (typeof value === "number") return Number.isFinite(value) ? value : 0;
13209
+ if (typeof value === "string") return Number.parseFloat(value) || 0;
13210
+ return 0;
13211
+ };
13212
+ const useTableV2Columns = ({
13213
+ columns,
13214
+ containerWidth,
13215
+ excludeKeys = [],
13216
+ defaultMinWidth = DEFAULT_TABLE_V2_MIN_WIDTH
13217
+ }) => {
13218
+ const resolvedColumns = vue.computed(() => {
13219
+ const cols = columns();
13220
+ const floors = cols.map(
13221
+ (col) => toColumnNumber(col.minWidth) || toColumnNumber(col.width) || defaultMinWidth
13222
+ );
13223
+ const sumFloor = floors.reduce((total, item) => total + item, 0);
13224
+ const target = Math.max(sumFloor, containerWidth());
13225
+ const stretchableIndexes = cols.map(
13226
+ (col, index) => col.fixed || col.key !== void 0 && excludeKeys.includes(String(col.key)) ? -1 : index
13227
+ ).filter((index) => index >= 0);
13228
+ const extra = target - sumFloor;
13229
+ const stretchCount = stretchableIndexes.length;
13230
+ const base = stretchCount ? Math.floor(extra / stretchCount) : 0;
13231
+ let remainder = stretchCount ? extra % stretchCount : 0;
13232
+ const widths = floors.map((floor, index) => {
13233
+ if (!stretchableIndexes.includes(index)) return floor;
13234
+ let width = floor + base;
13235
+ if (remainder > 0) {
13236
+ width += 1;
13237
+ remainder -= 1;
13238
+ }
13239
+ return width;
13240
+ });
13241
+ return cols.map((col, index) => ({
13242
+ ...col,
13243
+ minWidth: floors[index],
13244
+ width: widths[index]
13245
+ }));
13246
+ });
13247
+ return { resolvedColumns };
13248
+ };
13249
+
13250
+ const TableV2Cell = vue.defineComponent({
13251
+ name: "PlusTableV2Cell",
13252
+ props: {
13253
+ /** 列配置 */
13254
+ column: {
13255
+ type: Object,
13256
+ required: true
13257
+ },
13258
+ /** 行数据 */
13259
+ row: {
13260
+ type: Object,
13261
+ required: true
13262
+ },
13263
+ /** 行索引 */
13264
+ index: {
13265
+ type: Number,
13266
+ default: 0
13267
+ },
13268
+ /** 单元格列索引 */
13269
+ cellIndex: {
13270
+ type: Number,
13271
+ default: 0
13272
+ },
13273
+ /** 是否可编辑 */
13274
+ editable: {
13275
+ type: [Boolean, String],
13276
+ default: false
13277
+ },
13278
+ /** 空值默认值 */
13279
+ emptyValue: {
13280
+ type: [String, Number],
13281
+ default: void 0
13282
+ },
13283
+ /** 透传给展示组件的额外参数 */
13284
+ rest: {
13285
+ type: Object,
13286
+ default: () => ({})
13287
+ }
13288
+ },
13289
+ emits: {
13290
+ /** 单元格点击 */
13291
+ cellClick: (_row, _column, _event) => true,
13292
+ /** 单元格双击 */
13293
+ cellDblclick: (_row, _column, _event) => true,
13294
+ /** 表单值变化 */
13295
+ formChange: (_data) => true
13296
+ },
13297
+ setup(props, { emit, slots, expose }) {
13298
+ const displayItemInstance = vue.ref(null);
13299
+ const cellInstance = vue.ref(null);
13300
+ const formRefs = vue.inject(
13301
+ TableFormRefInjectionKey,
13302
+ null
13303
+ );
13304
+ const handleClick = (event) => {
13305
+ emit("cellClick", props.row, props.column, event);
13306
+ };
13307
+ const handleDblclick = (event) => {
13308
+ emit("cellDblclick", props.row, props.column, event);
13309
+ };
13310
+ const handleChange = (data) => {
13311
+ emit("formChange", {
13312
+ ...data,
13313
+ index: props.index,
13314
+ rowIndex: props.index,
13315
+ cellIndex: props.cellIndex,
13316
+ column: { ...props.rest.column, ...props.column }
13317
+ });
13318
+ };
13319
+ const syncFormRef = () => {
13320
+ const instance = displayItemInstance.value;
13321
+ if (!formRefs || !instance) return;
13322
+ const info = {
13323
+ ...instance,
13324
+ ...instance.getDisplayItemInstance(),
13325
+ index: props.index,
13326
+ rowIndex: props.index,
13327
+ cellIndex: props.cellIndex
13328
+ };
13329
+ set(formRefs.value, [props.index, props.cellIndex], info);
13330
+ };
13331
+ vue.watch(
13332
+ () => [props.index, props.cellIndex, props.column.prop, displayItemInstance.value],
13333
+ syncFormRef,
13334
+ {
13335
+ flush: "post",
13336
+ immediate: true
13337
+ }
13338
+ );
13339
+ expose({
13340
+ cellInstance,
13341
+ startCellEdit: () => {
13342
+ var _a;
13343
+ return (_a = displayItemInstance.value) == null ? void 0 : _a.startCellEdit();
13344
+ },
13345
+ stopCellEdit: () => {
13346
+ var _a;
13347
+ return (_a = displayItemInstance.value) == null ? void 0 : _a.stopCellEdit();
13348
+ },
13349
+ getDisplayItemInstance: () => {
13350
+ var _a;
13351
+ return (_a = displayItemInstance.value) == null ? void 0 : _a.getDisplayItemInstance();
13352
+ }
13353
+ });
13354
+ return () => vue.h(
13355
+ "div",
13356
+ {
13357
+ ref: cellInstance,
13358
+ class: "plus-table-v2-cell",
13359
+ onClick: handleClick,
13360
+ onDblclick: handleDblclick
13361
+ },
13362
+ [
13363
+ vue.h(
13364
+ PlusDisplayItem,
13365
+ {
13366
+ ref: displayItemInstance,
13367
+ column: props.column,
13368
+ row: props.row,
13369
+ index: props.index,
13370
+ editable: props.editable,
13371
+ rest: props.rest,
13372
+ emptyValue: props.emptyValue,
13373
+ onChange: handleChange
13374
+ },
13375
+ slots
13376
+ )
13377
+ ]
13378
+ );
13379
+ }
13380
+ });
13381
+
13382
+ var _sfc_main$d = /* @__PURE__ */ vue.defineComponent({
13383
+ ...{
13384
+ name: "PlusTableV2",
13385
+ inheritAttrs: false
13386
+ },
13387
+ __name: "index",
13388
+ props: {
13389
+ tableData: { default: () => [] },
13390
+ data: { default: () => [] },
13391
+ columns: { default: () => [] },
13392
+ defaultSize: { default: "default" },
13393
+ pagination: { type: [Boolean, Object], default: false },
13394
+ actionBar: { type: [Boolean, Object], default: false },
13395
+ hasIndexColumn: { type: Boolean, default: false },
13396
+ titleBar: { type: [Boolean, Object], default: true },
13397
+ isSelection: { type: Boolean, default: false },
13398
+ isRadio: { type: Boolean, default: false },
13399
+ specialColumnsOrder: { default: () => ["radio", "selection", "index"] },
13400
+ loadingStatus: { type: Boolean, default: false },
13401
+ height: { default: void 0 },
13402
+ width: { default: void 0 },
13403
+ rowHeight: { default: void 0 },
13404
+ headerHeight: { default: 50 },
13405
+ headerCellStyle: { default: () => ({
13406
+ "background-color": "var(--el-fill-color-light)"
13407
+ }) },
13408
+ rowKey: { default: "id" },
13409
+ defaultSelectedRadioRow: { default: void 0 },
13410
+ radioProps: { default: void 0 },
13411
+ selectionTableColumnProps: { default: () => ({ width: 40 }) },
13412
+ radioTableColumnProps: { default: () => ({ width: 50 }) },
13413
+ indexTableColumnProps: { default: () => ({}) },
13414
+ indexContentStyle: { type: [Object, Function], default: () => ({}) },
13415
+ editable: { type: [Boolean, String], default: false },
13416
+ adaptive: { type: [Boolean, Object], default: false },
13417
+ emptyValue: { default: void 0 }
13418
+ },
13419
+ emits: ["paginationChange", "clickAction", "clickActionConfirmCancel", "formChange", "refresh", "edited", "cell-click", "cell-dblclick", "filterTableHeader", "radioChange", "selection-change", "row-click", "row-dblclick"],
13420
+ setup(__props, { expose: __expose, emit: __emit }) {
13421
+ var _a, _b;
13422
+ const props = __props;
13423
+ const emit = __emit;
13424
+ const { t } = useLocale();
13425
+ const slots = vue.useSlots();
13426
+ const tableWrapperInstance = vue.ref(null);
13427
+ const tableInstance = vue.shallowRef(null);
13428
+ const paginationInstance = vue.ref(null);
13429
+ const state = vue.reactive({
13430
+ size: props.defaultSize,
13431
+ subPageInfo: {
13432
+ ...((_a = props.pagination) == null ? void 0 : _a.modelValue) || DefaultPageInfo
13433
+ }
13434
+ });
13435
+ const __tableData = vue.computed(
13436
+ () => {
13437
+ var _a2;
13438
+ return ((_a2 = props.tableData) == null ? void 0 : _a2.length) ? props.tableData : props.data;
13439
+ }
13440
+ );
13441
+ const { subColumns, filterColumns, columnsIsChange, setFilterColumns } = useTableColumns({
13442
+ columns: () => props.columns
13443
+ });
13444
+ const formRefs = vue.shallowRef({});
13445
+ const formFieldRefs = vue.shallowRef({});
13446
+ const sizeRowHeightMap = {
13447
+ default: 50,
13448
+ large: 60,
13449
+ small: 40
13450
+ };
13451
+ const currentRowHeight = vue.computed(() => {
13452
+ var _a2, _b2;
13453
+ return (_b2 = (_a2 = props.rowHeight) != null ? _a2 : sizeRowHeightMap[state.size]) != null ? _b2 : 50;
13454
+ });
13455
+ const containerWidth = vue.ref(0);
13456
+ const fillHeight = vue.ref(400);
13457
+ const tableWidth = vue.computed(() => {
13458
+ if (props.width !== void 0) return toColumnNumber(props.width);
13459
+ return Math.max(containerWidth.value, 1);
13460
+ });
13461
+ const tableHeight = vue.computed(() => {
13462
+ if (props.height !== void 0) return toColumnNumber(props.height);
13463
+ return fillHeight.value;
13464
+ });
13465
+ const bodyHeight = vue.computed(() => `${tableHeight.value}px`);
13466
+ const calcFillHeight = () => {
13467
+ var _a2;
13468
+ if (!tableWrapperInstance.value) return;
13469
+ let offsetBottom = 20;
13470
+ if (isPlainObject(props.adaptive)) {
13471
+ offsetBottom = (_a2 = props.adaptive.offsetBottom) != null ? _a2 : offsetBottom;
13472
+ }
13473
+ const paginationHeight = paginationInstance.value && props.pagination ? paginationInstance.value.$el.offsetHeight : 0;
13474
+ const top = tableWrapperInstance.value.getBoundingClientRect().top;
13475
+ fillHeight.value = Math.max(window.innerHeight - top - offsetBottom - paginationHeight, 100);
13476
+ };
13477
+ const handleResize = ({ width }) => {
13478
+ containerWidth.value = width;
13479
+ };
13480
+ const debounceCalcFillHeight = debounce(
13481
+ calcFillHeight,
13482
+ isPlainObject(props.adaptive) ? (_b = props.adaptive.timeout) != null ? _b : 60 : 60
13483
+ );
13484
+ const radioRow = vue.ref({});
13485
+ vue.watch(
13486
+ () => props.defaultSelectedRadioRow,
13487
+ (val) => {
13488
+ radioRow.value = val != null ? val : {};
13489
+ },
13490
+ { immediate: true }
13491
+ );
13492
+ const selectedRows = vue.ref([]);
13493
+ const getRowKeyValue = (row) => row == null ? void 0 : row[props.rowKey];
13494
+ const isRowSelected = (row) => {
13495
+ const key = getRowKeyValue(row);
13496
+ return selectedRows.value.some((item) => getRowKeyValue(item) === key);
13497
+ };
13498
+ const isAllSelected = () => __tableData.value.length > 0 && selectedRows.value.length === __tableData.value.length;
13499
+ const isIndeterminate = () => selectedRows.value.length > 0 && selectedRows.value.length < __tableData.value.length;
13500
+ const handleToggleRow = (row, checked) => {
13501
+ const key = getRowKeyValue(row);
13502
+ const rest = selectedRows.value.filter((item) => getRowKeyValue(item) !== key);
13503
+ selectedRows.value = checked ? [...rest, row] : rest;
13504
+ emit("selection-change", selectedRows.value);
13505
+ };
13506
+ const handleToggleAll = (checked) => {
13507
+ selectedRows.value = checked ? [...__tableData.value] : [];
13508
+ emit("selection-change", selectedRows.value);
13509
+ };
13510
+ const handleRadioChange = (value, row) => {
13511
+ radioRow.value = value ? row : {};
13512
+ emit("radioChange", row, __tableData.value.indexOf(row), !!value);
13513
+ };
13514
+ const handleFormChange = (data) => {
13515
+ emit("formChange", data);
13516
+ };
13517
+ const handleRefresh = () => {
13518
+ emit("refresh");
13519
+ };
13520
+ const handleClickDensity = (size) => {
13521
+ state.size = size;
13522
+ };
13523
+ const handleFilterTableConfirm = (list, eventType) => {
13524
+ setFilterColumns(list);
13525
+ emit("filterTableHeader", list, eventType);
13526
+ };
13527
+ const handlePaginationChange = () => {
13528
+ emit("paginationChange", { ...state.subPageInfo });
13529
+ };
13530
+ const getCellForm = (row, column) => {
13531
+ var _a2;
13532
+ const rowIndex = __tableData.value.indexOf(row);
13533
+ const columnIndex = subColumns.value.findIndex((item) => item.prop === column.prop);
13534
+ if (rowIndex < 0 || columnIndex < 0) return null;
13535
+ return ((_a2 = formRefs.value[rowIndex]) == null ? void 0 : _a2[columnIndex]) || null;
13536
+ };
13537
+ const currentForm = vue.shallowRef(null);
13538
+ const startCellEdit = (row, column) => {
13539
+ var _a2;
13540
+ const cellForm = getCellForm(row, column);
13541
+ if (!cellForm) return;
13542
+ document.addEventListener("click", handleStopEditClick);
13543
+ (_a2 = currentForm.value) == null ? void 0 : _a2.stopCellEdit();
13544
+ currentForm.value = cellForm;
13545
+ cellForm.startCellEdit();
13546
+ const unwatch = vue.watch(
13547
+ () => formFieldRefs.value.valueIsReady,
13548
+ (val) => {
13549
+ var _a3, _b2;
13550
+ if ((val == null ? void 0 : val.value) && ((_b2 = (_a3 = formFieldRefs.value) == null ? void 0 : _a3.fieldInstance) == null ? void 0 : _b2.focus)) {
13551
+ formFieldRefs.value.fieldInstance.focus();
13552
+ unwatch();
13553
+ }
13554
+ }
13555
+ );
13556
+ };
13557
+ const handleStopEditClick = (event) => {
13558
+ var _a2;
13559
+ if (!tableWrapperInstance.value || !currentForm.value) return;
13560
+ const target = event == null ? void 0 : event.target;
13561
+ if ((_a2 = target == null ? void 0 : target.classList) == null ? void 0 : _a2.contains("el-icon")) return;
13562
+ if (tableWrapperInstance.value.contains(target)) return;
13563
+ currentForm.value.stopCellEdit();
13564
+ currentForm.value = null;
13565
+ emit("edited");
13566
+ document.removeEventListener("click", handleStopEditClick);
13567
+ };
13568
+ const handleCellClick = (row, column, event) => {
13569
+ if (props.editable === "click") startCellEdit(row, column);
13570
+ emit("cell-click", row, column, event.currentTarget, event);
13571
+ };
13572
+ const handleCellDblclick = (row, column, event) => {
13573
+ if (props.editable === "dblclick") startCellEdit(row, column);
13574
+ emit("cell-dblclick", row, column, event.currentTarget, event);
13575
+ };
13576
+ const getCellSlots = () => {
13577
+ const cellSlots = {};
13578
+ Object.keys(slots).forEach((key) => {
13579
+ if (key.startsWith("plus-") || key === "edit-icon") {
13580
+ cellSlots[key] = slots[key];
13581
+ }
13582
+ });
13583
+ return cellSlots;
13584
+ };
13585
+ const renderCell = ({
13586
+ column,
13587
+ row,
13588
+ rowIndex,
13589
+ columnIndex
13590
+ }) => vue.h(
13591
+ TableV2Cell,
13592
+ {
13593
+ column,
13594
+ row,
13595
+ index: rowIndex,
13596
+ cellIndex: columnIndex,
13597
+ editable: props.editable,
13598
+ emptyValue: props.emptyValue,
13599
+ onCellClick: handleCellClick,
13600
+ onCellDblclick: handleCellDblclick,
13601
+ onFormChange: handleFormChange
13602
+ },
13603
+ getCellSlots()
13604
+ );
13605
+ const dataColumns = vue.computed(
13606
+ () => buildDataColumns({
13607
+ columns: subColumns.value,
13608
+ renderCell,
13609
+ slots
13610
+ })
13611
+ );
13612
+ const actionBarColumn = vue.computed(() => {
13613
+ var _a2;
13614
+ if (!props.actionBar) return null;
13615
+ const actionBar = props.actionBar;
13616
+ return {
13617
+ key: "actionBar",
13618
+ title: actionBar.label || t("plus.table.action"),
13619
+ width: toColumnNumber(actionBar.width) || 200,
13620
+ fixed: actionBar.fixed || "right",
13621
+ align: (_a2 = actionBar.actionBarTableColumnProps) == null ? void 0 : _a2.align,
13622
+ cellRenderer: ({ rowData, rowIndex }) => vue.h(
13623
+ PlusTableActionBarContent,
13624
+ {
13625
+ row: rowData,
13626
+ index: rowIndex,
13627
+ type: actionBar.type,
13628
+ buttons: actionBar.buttons,
13629
+ showNumber: actionBar.showNumber,
13630
+ showLimitIncludeMore: actionBar.showLimitIncludeMore,
13631
+ confirmType: actionBar.confirmType,
13632
+ moreType: actionBar.moreType,
13633
+ onClickAction: (data) => emit("clickAction", data),
13634
+ onClickActionConfirmCancel: (data) => emit("clickActionConfirmCancel", data)
13635
+ },
13636
+ {
13637
+ "action-bar-more-icon": () => {
13638
+ var _a3;
13639
+ return (_a3 = slots["action-bar-more-icon"]) == null ? void 0 : _a3.call(slots);
13640
+ }
13641
+ }
13642
+ )
13643
+ };
13644
+ });
13645
+ const specialColumns = vue.computed(() => {
13646
+ const activeList = [];
13647
+ if (props.isRadio) activeList.push("radio");
13648
+ if (props.isSelection) activeList.push("selection");
13649
+ if (props.hasIndexColumn) activeList.push("index");
13650
+ const defaultOrder = ["radio", "selection", "index"];
13651
+ const order = [...props.specialColumnsOrder || [], ...defaultOrder].filter(
13652
+ (item, index, array) => array.indexOf(item) === index
13653
+ );
13654
+ return order.filter((item) => activeList.includes(item)).map((item) => {
13655
+ if (item === "radio") {
13656
+ return buildRadioColumn({
13657
+ radioRow: () => radioRow.value,
13658
+ onChange: handleRadioChange,
13659
+ radioProps: props.radioProps,
13660
+ columnProps: props.radioTableColumnProps
13661
+ });
13662
+ }
13663
+ if (item === "selection") {
13664
+ return buildSelectionColumn({
13665
+ isSelected: isRowSelected,
13666
+ isAllSelected,
13667
+ isIndeterminate,
13668
+ onToggleRow: handleToggleRow,
13669
+ onToggleAll: handleToggleAll,
13670
+ columnProps: props.selectionTableColumnProps
13671
+ });
13672
+ }
13673
+ return buildIndexColumn({
13674
+ pageInfo: state.subPageInfo,
13675
+ indexContentStyle: props.indexContentStyle,
13676
+ columnProps: props.indexTableColumnProps
13677
+ });
13678
+ });
13679
+ });
13680
+ const allColumns = vue.computed(() => {
13681
+ const list = [...specialColumns.value, ...dataColumns.value];
13682
+ if (actionBarColumn.value) list.push(actionBarColumn.value);
13683
+ return list;
13684
+ });
13685
+ const { resolvedColumns } = useTableV2Columns({
13686
+ columns: () => allColumns.value,
13687
+ containerWidth: () => tableWidth.value
13688
+ });
13689
+ const headerCellProps = () => ({ style: props.headerCellStyle });
13690
+ const rowEventHandlers = vue.computed(() => ({
13691
+ onClick: ({ rowData, rowIndex, event }) => {
13692
+ emit("row-click", rowData, rowIndex, event);
13693
+ },
13694
+ onDblclick: ({ rowData, rowIndex, event }) => {
13695
+ emit("row-dblclick", rowData, rowIndex, event);
13696
+ }
13697
+ }));
13698
+ vue.onMounted(() => {
13699
+ calcFillHeight();
13700
+ window.addEventListener("resize", debounceCalcFillHeight);
13701
+ });
13702
+ vue.onBeforeUnmount(() => {
13703
+ window.removeEventListener("resize", debounceCalcFillHeight);
13704
+ document.removeEventListener("click", handleStopEditClick);
13705
+ });
13706
+ vue.provide(TableFormRefInjectionKey, formRefs);
13707
+ vue.provide(TableFormFieldRefInjectionKey, formFieldRefs);
13708
+ __expose({
13709
+ formRefs,
13710
+ tableInstance,
13711
+ /** 滚动到指定垂直位置 */
13712
+ scrollToTop: (top) => {
13713
+ var _a2;
13714
+ return (_a2 = tableInstance.value) == null ? void 0 : _a2.scrollToTop(top);
13715
+ },
13716
+ /** 滚动到指定水平位置 */
13717
+ scrollToLeft: (left) => {
13718
+ var _a2;
13719
+ return (_a2 = tableInstance.value) == null ? void 0 : _a2.scrollToLeft(left);
13720
+ },
13721
+ /** 滚动到指定行 */
13722
+ scrollToRow: (row, strategy) => {
13723
+ var _a2;
13724
+ return (_a2 = tableInstance.value) == null ? void 0 : _a2.scrollToRow(row, strategy);
13725
+ }
13726
+ });
13727
+ return (_ctx, _cache) => {
13728
+ return vue.openBlock(), vue.createElementBlock(
13729
+ "div",
13730
+ {
13731
+ ref_key: "tableWrapperInstance",
13732
+ ref: tableWrapperInstance,
13733
+ class: "plus-table-v2"
13734
+ },
13735
+ [
13736
+ vue.createCommentVNode(" \u6807\u9898\u680F\uFF1A\u5237\u65B0 / \u5BC6\u5EA6 / \u5217\u8BBE\u7F6E\uFF0C\u4E0E el-table \u7248\u672C\u590D\u7528\u540C\u4E00\u7EC4\u4EF6 "),
13737
+ _ctx.titleBar ? (vue.openBlock(), vue.createBlock(vue.unref(PlusTableTitleBar), {
13738
+ key: 0,
13739
+ "origin-columns": _ctx.columns,
13740
+ columns: vue.unref(filterColumns),
13741
+ "default-size": state.size,
13742
+ "columns-is-change": vue.unref(columnsIsChange),
13743
+ "title-bar": _ctx.titleBar,
13744
+ onClickDensity: handleClickDensity,
13745
+ onFilterTableHeader: handleFilterTableConfirm,
13746
+ onRefresh: handleRefresh
13747
+ }, vue.createSlots({
13748
+ title: vue.withCtx(() => [
13749
+ vue.renderSlot(_ctx.$slots, "title")
13750
+ ]),
13751
+ toolbar: vue.withCtx(() => [
13752
+ vue.renderSlot(_ctx.$slots, "toolbar")
13753
+ ]),
13754
+ _: 2
13755
+ /* DYNAMIC */
13756
+ }, [
13757
+ _ctx.$slots["column-settings-icon"] ? {
13758
+ name: "column-settings-icon",
13759
+ fn: vue.withCtx(() => [
13760
+ vue.renderSlot(_ctx.$slots, "column-settings-icon")
13761
+ ]),
13762
+ key: "0"
13763
+ } : void 0,
13764
+ _ctx.$slots["density-icon"] ? {
13765
+ name: "density-icon",
13766
+ fn: vue.withCtx(() => [
13767
+ vue.renderSlot(_ctx.$slots, "density-icon")
13768
+ ]),
13769
+ key: "1"
13770
+ } : void 0
13771
+ ]), 1032, ["origin-columns", "columns", "default-size", "columns-is-change", "title-bar"])) : vue.createCommentVNode("v-if", true),
13772
+ vue.createCommentVNode(" \u865A\u62DF\u8868\u683C\u4E3B\u4F53\uFF1A\u5BBD\u5EA6\u6491\u6EE1\u7236\u5BB9\u5668\uFF0C\u9AD8\u5EA6\u6309 props.height / adaptive \u8BA1\u7B97 "),
13773
+ vue.withDirectives((vue.openBlock(), vue.createElementBlock(
13774
+ "div",
13775
+ {
13776
+ class: "plus-table-v2__body",
13777
+ style: vue.normalizeStyle({ height: bodyHeight.value })
13778
+ },
13779
+ [
13780
+ vue.createVNode(vue.unref(elementPlus.ElAutoResizer), {
13781
+ "disable-height": true,
13782
+ "on-resize": handleResize
13783
+ }, {
13784
+ default: vue.withCtx(() => [
13785
+ vue.createVNode(vue.unref(elementPlus.ElTableV2), vue.mergeProps({
13786
+ ref_key: "tableInstance",
13787
+ ref: tableInstance,
13788
+ columns: vue.unref(resolvedColumns),
13789
+ data: __tableData.value,
13790
+ width: tableWidth.value,
13791
+ height: tableHeight.value,
13792
+ "row-height": currentRowHeight.value,
13793
+ "header-height": _ctx.headerHeight,
13794
+ "row-key": _ctx.rowKey,
13795
+ "header-cell-props": headerCellProps,
13796
+ "row-event-handlers": rowEventHandlers.value,
13797
+ fixed: true,
13798
+ "scrollbar-always-on": true
13799
+ }, _ctx.$attrs), {
13800
+ empty: vue.withCtx(() => [
13801
+ vue.renderSlot(_ctx.$slots, "empty", {}, () => [
13802
+ vue.createVNode(vue.unref(elementPlus.ElEmpty))
13803
+ ])
13804
+ ]),
13805
+ _: 3
13806
+ /* FORWARDED */
13807
+ }, 16, ["columns", "data", "width", "height", "row-height", "header-height", "row-key", "row-event-handlers"])
13808
+ ]),
13809
+ _: 3
13810
+ /* FORWARDED */
13811
+ })
13812
+ ],
13813
+ 4
13814
+ /* STYLE */
13815
+ )), [
13816
+ [vue.unref(elementPlus.vLoading), _ctx.loadingStatus]
13817
+ ]),
13818
+ vue.createCommentVNode(" \u5206\u9875 "),
13819
+ _ctx.pagination ? (vue.openBlock(), vue.createBlock(vue.unref(PlusPagination), vue.mergeProps({
13820
+ key: 1,
13821
+ ref_key: "paginationInstance",
13822
+ ref: paginationInstance,
13823
+ modelValue: state.subPageInfo,
13824
+ "onUpdate:modelValue": _cache[0] || (_cache[0] = ($event) => state.subPageInfo = $event)
13825
+ }, _ctx.pagination, { onChange: handlePaginationChange }), vue.createSlots({
13826
+ _: 2
13827
+ /* DYNAMIC */
13828
+ }, [
13829
+ _ctx.$slots["pagination-left"] ? {
13830
+ name: "pagination-left",
13831
+ fn: vue.withCtx(() => [
13832
+ vue.renderSlot(_ctx.$slots, "pagination-left")
13833
+ ]),
13834
+ key: "0"
13835
+ } : void 0,
13836
+ _ctx.$slots["pagination-right"] ? {
13837
+ name: "pagination-right",
13838
+ fn: vue.withCtx(() => [
13839
+ vue.renderSlot(_ctx.$slots, "pagination-right")
13840
+ ]),
13841
+ key: "1"
13842
+ } : void 0
13843
+ ]), 1040, ["modelValue"])) : vue.createCommentVNode("v-if", true)
13844
+ ],
13845
+ 512
13846
+ /* NEED_PATCH */
13847
+ );
13848
+ };
13849
+ }
13850
+ });
13851
+
13852
+ var TableV2 = /* @__PURE__ */ _export_sfc(_sfc_main$d, [["__file", "index.vue"]]);
13853
+
13854
+ const PlusTableV2 = TableV2;
13855
+
13856
+ var _sfc_main$c = /* @__PURE__ */ vue.defineComponent({
13857
+ ...{
13858
+ name: "PlusDescriptions"
13859
+ },
13860
+ __name: "index",
13861
+ props: {
13862
+ data: { default: () => ({}) },
13863
+ columns: { default: () => [] },
13864
+ column: { default: 3 },
13865
+ title: { default: "" },
13866
+ border: { type: Boolean, default: true },
13867
+ editable: { type: Boolean, default: false },
13868
+ formProps: { default: void 0 },
13869
+ descriptionsItemProps: { default: void 0 }
13870
+ },
13871
+ emits: ["formChange"],
13872
+ setup(__props, { expose: __expose, emit: __emit }) {
13873
+ const props = __props;
13874
+ const emit = __emit;
13875
+ const slots = vue.useSlots();
13876
+ const plusDisplayItemInstance = vue.ref();
13877
+ const elBorder = vue.computed(() => props.editable ? true : props.border);
13878
+ const formRefs = vue.shallowRef([]);
13879
+ const subColumns = vue.computed(
13880
+ () => props.columns.filter((item) => vue.unref(item.hideInDescriptions) !== true)
13881
+ );
13882
+ const getDisplayValue = (prop) => getValue(props.data, prop);
13883
+ const hasDescSlot = (prop) => !!slots[getDescSlotName(prop)];
13884
+ const hasDescLabelSlot = (prop) => !!slots[getDescLabelSlotName(prop)];
13885
+ const subColumnsKey = vue.computed(() => subColumns.value.map((i) => i.prop).join(","));
13886
+ const setFormRef = () => {
13887
+ var _a, _b;
13888
+ if (!((_a = plusDisplayItemInstance.value) == null ? void 0 : _a.length)) return;
13889
+ const list = ((_b = plusDisplayItemInstance.value) == null ? void 0 : _b.map((item) => ({
13890
+ ...item,
13891
+ ...item == null ? void 0 : item.getDisplayItemInstance()
13892
+ }))) || [];
13893
+ formRefs.value = list;
13894
+ };
13895
+ vue.watch(
13896
+ plusDisplayItemInstance,
13897
+ () => {
13898
+ setFormRef();
13899
+ },
13900
+ {
13901
+ deep: true,
13902
+ flush: "post"
13903
+ }
13904
+ );
13905
+ const getIsRequired = (item, index) => {
13906
+ var _a;
13907
+ const itemFormProps = isFunction(item.formProps) ? item.formProps(props.data[item.prop], { row: props.data, index }) : vue.unref(item.formProps);
13908
+ const rules = Reflect.get((itemFormProps == null ? void 0 : itemFormProps.rules) || ((_a = props.formProps) == null ? void 0 : _a.rules) || {}, item.prop) || {};
13909
+ const isRequired = Object.values(rules).some((i) => i.required);
13910
+ return isRequired;
13911
+ };
13912
+ const handleChange = (data, index, item) => {
13913
+ const formChangeCallBackParams = { ...data, index, column: { ...item } };
13914
+ emit("formChange", formChangeCallBackParams);
13915
+ };
13916
+ const validate = async () => {
13917
+ var _a;
13918
+ try {
13919
+ await Promise.all(
13920
+ (_a = formRefs.value) == null ? void 0 : _a.map((item) => {
13921
+ var _a2;
13922
+ return (_a2 = item.formInstance.value) == null ? void 0 : _a2.validate();
13923
+ })
13924
+ );
13925
+ } catch (errors) {
13926
+ return Promise.reject(errors);
13927
+ }
13928
+ };
13929
+ const clearValidate = () => {
13930
+ var _a;
13931
+ (_a = formRefs.value) == null ? void 0 : _a.forEach((item) => {
13932
+ var _a2;
13933
+ (_a2 = item.formInstance.value) == null ? void 0 : _a2.clearValidate();
13934
+ });
13935
+ };
13936
+ __expose({
13937
+ formRefs,
13938
+ validate,
13939
+ clearValidate
13940
+ });
12407
13941
  return (_ctx, _cache) => {
12408
13942
  return vue.openBlock(), vue.createBlock(vue.unref(elementPlus.ElDescriptions), vue.mergeProps({
12409
13943
  key: subColumnsKey.value,
@@ -13099,6 +14633,9 @@
13099
14633
  request: {},
13100
14634
  search: { type: [Boolean, Object], default: () => ({}) },
13101
14635
  table: { default: () => ({}) },
14636
+ tableType: { default: "table" },
14637
+ tableV2: { default: void 0 },
14638
+ tableLite: { default: void 0 },
13102
14639
  params: { default: () => ({}) },
13103
14640
  postData: { type: Function, default: void 0 },
13104
14641
  beforeSearchSubmit: { type: Function, default: void 0 },
@@ -13117,7 +14654,7 @@
13117
14654
  searchSlot: { type: Boolean, default: false },
13118
14655
  resetSearch: { type: Boolean, default: true }
13119
14656
  },
13120
- emits: ["update:searchValues", "search", "reset", "searchChange", "paginationChange", "requestError", "requestComplete"],
14657
+ emits: ["update:searchValues", "search", "reset", "searchChange", "paginationChange", "selectionChange", "requestError", "requestComplete"],
13121
14658
  setup(__props, { expose: __expose, emit: __emit }) {
13122
14659
  var _a, _b;
13123
14660
  const props = __props;
@@ -13152,6 +14689,30 @@
13152
14689
  const values = vue.ref(
13153
14690
  (_b = props.searchValues) != null ? _b : { ...(_a = props.search) == null ? void 0 : _a.defaultValues }
13154
14691
  );
14692
+ const tableComponentMap = /* @__PURE__ */ new Map([
14693
+ ["table", PlusTable],
14694
+ ["table-v2", PlusTableV2],
14695
+ ["table-lite", PlusTableLite]
14696
+ ]);
14697
+ const tableComponent = vue.computed(() => tableComponentMap.get(props.tableType) || PlusTable);
14698
+ const tableProps = vue.computed(() => {
14699
+ if (props.tableType === "table-v2") {
14700
+ return { ...props.table, ...props.tableV2 };
14701
+ }
14702
+ if (props.tableType === "table-lite") {
14703
+ return { ...props.table, ...props.tableLite };
14704
+ }
14705
+ return props.table;
14706
+ });
14707
+ const tablePagination = vue.computed(() => {
14708
+ if (props.pagination === false) return void 0;
14709
+ return {
14710
+ ...props.pagination,
14711
+ total: total.value,
14712
+ modelValue: pageInfo.value,
14713
+ pageSizeList: computedDefaultPageSizeList.value
14714
+ };
14715
+ });
13155
14716
  vue.watch(
13156
14717
  () => props.searchValues,
13157
14718
  (val) => {
@@ -13201,6 +14762,12 @@
13201
14762
  getList();
13202
14763
  emit("paginationChange", _pageInfo);
13203
14764
  };
14765
+ const handleTablePaginationChange = (data) => {
14766
+ handlePaginationChange(data);
14767
+ };
14768
+ const handleTableSelectionChange = (data) => {
14769
+ emit("selectionChange", data || []);
14770
+ };
13204
14771
  const handleSearchChange = (val, column) => {
13205
14772
  emit("update:searchValues", val);
13206
14773
  emit("searchChange", val, column);
@@ -13315,22 +14882,18 @@
13315
14882
  class: "plus-page__table_wrapper"
13316
14883
  }, {
13317
14884
  default: vue.withCtx(() => [
13318
- vue.createVNode(vue.unref(PlusTable), vue.mergeProps({
14885
+ (vue.openBlock(), vue.createBlock(vue.resolveDynamicComponent(tableComponent.value), vue.mergeProps({
13319
14886
  ref_key: "plusTableInstance",
13320
14887
  ref: plusTableInstance,
13321
14888
  "title-bar": { refresh: true }
13322
- }, _ctx.table, {
14889
+ }, tableProps.value, {
13323
14890
  "table-data": vue.unref(tableData),
13324
14891
  "loading-status": vue.unref(loadingStatus),
13325
14892
  columns: _ctx.columns,
13326
- pagination: _ctx.pagination === false ? void 0 : {
13327
- ..._ctx.pagination,
13328
- total: vue.unref(total),
13329
- modelValue: vue.unref(pageInfo),
13330
- pageSizeList: computedDefaultPageSizeList.value
13331
- },
13332
- onPaginationChange: handlePaginationChange,
13333
- onRefresh: handleRefresh
14893
+ pagination: tablePagination.value,
14894
+ onPaginationChange: handleTablePaginationChange,
14895
+ onRefresh: handleRefresh,
14896
+ onSelectionChange: handleTableSelectionChange
13334
14897
  }), vue.createSlots({
13335
14898
  _: 2
13336
14899
  /* DYNAMIC */
@@ -13378,7 +14941,7 @@
13378
14941
  ])
13379
14942
  };
13380
14943
  })
13381
- ]), 1040, ["table-data", "loading-status", "columns", "pagination"])
14944
+ ]), 1040, ["table-data", "loading-status", "columns", "pagination"]))
13382
14945
  ]),
13383
14946
  _: 3
13384
14947
  /* FORWARDED */
@@ -14773,6 +16336,8 @@
14773
16336
  PlusDialog,
14774
16337
  PlusPagination,
14775
16338
  PlusTable,
16339
+ PlusTableLite,
16340
+ PlusTableV2,
14776
16341
  PlusRadio,
14777
16342
  PlusDatePicker,
14778
16343
  PlusDescriptions,
@@ -14796,7 +16361,7 @@
14796
16361
 
14797
16362
  var installer = makeInstaller([...plugins]);
14798
16363
 
14799
- const version = "1.0.0";
16364
+ const version = "1.0.2";
14800
16365
 
14801
16366
  const install = installer.install;
14802
16367
 
@@ -14826,6 +16391,10 @@
14826
16391
  exports.PlusSidebarItem = PlusSidebarItem;
14827
16392
  exports.PlusStepsForm = PlusStepsForm;
14828
16393
  exports.PlusTable = PlusTable;
16394
+ exports.PlusTableActionBarContent = PlusTableActionBarContent;
16395
+ exports.PlusTableLite = PlusTableLite;
16396
+ exports.PlusTableTitleBar = PlusTableTitleBar;
16397
+ exports.PlusTableV2 = PlusTableV2;
14829
16398
  exports.TableFormFieldRefInjectionKey = TableFormFieldRefInjectionKey;
14830
16399
  exports.TableFormRefInjectionKey = TableFormRefInjectionKey;
14831
16400
  exports.TableFormRowInfoInjectionKey = TableFormRowInfoInjectionKey;
@@ -14842,6 +16411,8 @@
14842
16411
  exports.useGetOptions = useGetOptions;
14843
16412
  exports.useLocale = useLocale;
14844
16413
  exports.useTable = useTable;
16414
+ exports.useTableColumns = useTableColumns;
16415
+ exports.useTableV2Columns = useTableV2Columns;
14845
16416
  exports.version = version;
14846
16417
 
14847
16418
  Object.defineProperty(exports, '__esModule', { value: true });