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
@@ -0,0 +1,395 @@
1
+ import { defineComponent, ref, inject, unref, h, withDirectives, openBlock, createElementBlock, Fragment, createCommentVNode, renderList, createBlock, resolveDynamicComponent, withCtx, createVNode, renderSlot, createElementVNode, toDisplayString } from 'vue';
2
+ import { MoreFilled, ArrowDownBold } from '@element-plus/icons-vue';
3
+ import { ElTooltip, ElPopconfirm, ElIcon, ElButton, ElLink, ElMessageBox, ElDropdown, ElDropdownMenu, ElDropdownItem } from 'element-plus';
4
+ import '../../utils/index.mjs';
5
+ import '../../../hooks/index.mjs';
6
+ import '../../../constants/index.mjs';
7
+ import { useLocale } from '../../../hooks/useLocale.mjs';
8
+ import { TableFormRefInjectionKey } from '../../../constants/form.mjs';
9
+ import { isFunction, isPlainObject } from '../../utils/is.mjs';
10
+
11
+ const _hoisted_1 = {
12
+ key: 0,
13
+ class: "plus-table-action-bar__dropdown__link"
14
+ };
15
+ const _hoisted_2 = { class: "plus-table-action-bar__dropdown__link" };
16
+ const _hoisted_3 = { class: "plus-table-action-bar__more-text" };
17
+ var _sfc_main = /* @__PURE__ */ defineComponent({
18
+ ...{
19
+ name: "PlusTableActionBarContent"
20
+ },
21
+ __name: "table-action-bar-content",
22
+ props: {
23
+ row: {},
24
+ index: {},
25
+ rest: { default: () => ({}) },
26
+ showNumber: { type: [Number, Function], default: 3 },
27
+ showLimitIncludeMore: { type: Boolean, default: false },
28
+ type: { default: "link" },
29
+ buttons: { default: () => [] },
30
+ confirmType: { default: "messageBox" },
31
+ moreType: { default: "text" }
32
+ },
33
+ emits: ["clickAction", "clickActionConfirmCancel"],
34
+ setup(__props, { emit: __emit }) {
35
+ const props = __props;
36
+ const emit = __emit;
37
+ const { t } = useLocale();
38
+ const hideOnClick = ref(true);
39
+ const formRefs = inject(TableFormRefInjectionKey);
40
+ const getButtonKey = (buttonRow, row, index) => {
41
+ var _a, _b;
42
+ const text = isFunction(buttonRow.text) ? buttonRow.text(row, index, buttonRow) : buttonRow.text;
43
+ return String((_b = (_a = unref(text)) != null ? _a : buttonRow.code) != null ? _b : "");
44
+ };
45
+ const getSubButtons = (row, index) => {
46
+ const data = props.buttons.filter((item) => {
47
+ if (isFunction(item.show)) {
48
+ const tempFunction = item.show;
49
+ const isShow = tempFunction(row, index, item);
50
+ return unref(isShow) !== false;
51
+ }
52
+ return unref(item.show) !== false;
53
+ });
54
+ const showNumber = isFunction(props.showNumber) ? props.showNumber(row, index) : props.showNumber;
55
+ const showMore = data.length > showNumber;
56
+ if (!showMore) {
57
+ return {
58
+ showMore,
59
+ preButtons: data,
60
+ nextButtons: []
61
+ };
62
+ }
63
+ if (props.showLimitIncludeMore) {
64
+ return {
65
+ showMore,
66
+ preButtons: data.slice(0, showNumber - 1),
67
+ nextButtons: data.slice(showNumber - 1)
68
+ };
69
+ }
70
+ return {
71
+ showMore,
72
+ preButtons: data.slice(0, showNumber),
73
+ nextButtons: data.slice(showNumber)
74
+ };
75
+ };
76
+ const createCallbackParams = (params, e) => {
77
+ var _a;
78
+ return {
79
+ /**
80
+ * 解析后的按钮数据中的text
81
+ * @version v0.1.17
82
+ */
83
+ text: params.text,
84
+ row: params.row,
85
+ buttonRow: params.buttonRow,
86
+ index: params.index,
87
+ rowIndex: params.index,
88
+ e,
89
+ formRefs: (_a = formRefs == null ? void 0 : formRefs.value) == null ? void 0 : _a[params.index],
90
+ ...params.rest
91
+ };
92
+ };
93
+ const getConfirmMsg = (buttonRow, callbackParams) => {
94
+ var _a, _b;
95
+ let message = t("plus.table.confirmToPerformThisOperation");
96
+ let title = t("plus.table.prompt");
97
+ let options = void 0;
98
+ let appContext = null;
99
+ if (isPlainObject(buttonRow.confirm)) {
100
+ const tempTitle = isFunction(buttonRow.confirm.title) ? buttonRow.confirm.title(callbackParams) : buttonRow.confirm.title;
101
+ if (tempTitle) {
102
+ title = tempTitle;
103
+ }
104
+ const tempMessage = isFunction(buttonRow.confirm.message) ? buttonRow.confirm.message(callbackParams) : buttonRow.confirm.message;
105
+ if (tempMessage) {
106
+ message = tempMessage;
107
+ }
108
+ options = (_a = buttonRow.confirm) == null ? void 0 : _a.options;
109
+ appContext = (_b = buttonRow.confirm) == null ? void 0 : _b.appContext;
110
+ }
111
+ return { message, title, options, appContext };
112
+ };
113
+ const render = (row, buttonRow, index, rest) => {
114
+ var _a;
115
+ const buttonRowProps = isFunction(buttonRow.props) ? buttonRow.props(row, index, buttonRow) : unref(buttonRow.props);
116
+ const text = isFunction(buttonRow.text) ? unref(buttonRow.text(row, index, buttonRow)) : unref(buttonRow.text);
117
+ const params = {
118
+ text,
119
+ row,
120
+ buttonRow,
121
+ index,
122
+ rest
123
+ };
124
+ const getPopconfirmTitle = () => props.confirmType === "popconfirm" && buttonRow.confirm ? getConfirmMsg(buttonRow, createCallbackParams(params)).message : text;
125
+ if (props.type === "icon") {
126
+ return h(
127
+ ElTooltip,
128
+ { placement: "top", content: text, ...buttonRow.tooltipProps },
129
+ () => {
130
+ var _a2;
131
+ return props.confirmType === "popconfirm" && buttonRow.confirm ? h(
132
+ "span",
133
+ {
134
+ class: "el-icon"
135
+ },
136
+ h(
137
+ ElPopconfirm,
138
+ {
139
+ trigger: "click",
140
+ ...isPlainObject(buttonRow.confirm) ? (_a2 = buttonRow.confirm) == null ? void 0 : _a2.popconfirmProps : {},
141
+ title: getPopconfirmTitle(),
142
+ onConfirm: (event) => handleConfirm(createCallbackParams(params, event)),
143
+ onCancel: (event) => handleCancel(createCallbackParams(params, event))
144
+ },
145
+ {
146
+ reference: () => withDirectives(
147
+ h(
148
+ ElIcon,
149
+ {
150
+ size: 16,
151
+ style: { margin: 0 },
152
+ ...buttonRowProps,
153
+ onClick: () => {
154
+ hideOnClick.value = false;
155
+ if (isFunction(buttonRow.onClick)) {
156
+ buttonRow.onClick(createCallbackParams(params));
157
+ }
158
+ }
159
+ },
160
+ () => buttonRow.icon ? h(buttonRow.icon) : ""
161
+ ),
162
+ buttonRow.directives || []
163
+ )
164
+ }
165
+ )
166
+ ) : withDirectives(
167
+ h(
168
+ ElIcon,
169
+ {
170
+ size: 16,
171
+ ...buttonRowProps,
172
+ onClick: (event) => handleClickAction(createCallbackParams(params, event))
173
+ },
174
+ () => buttonRow.icon ? h(buttonRow.icon) : ""
175
+ ),
176
+ buttonRow.directives || []
177
+ );
178
+ }
179
+ );
180
+ } else {
181
+ const Tag = props.type === "button" ? ElButton : ElLink;
182
+ const defaultProps = props.type === "link" ? { href: "javaScript:;" } : {};
183
+ return props.confirmType === "popconfirm" && buttonRow.confirm ? h(
184
+ ElPopconfirm,
185
+ {
186
+ trigger: "click",
187
+ ...isPlainObject(buttonRow.confirm) ? (_a = buttonRow.confirm) == null ? void 0 : _a.popconfirmProps : {},
188
+ title: getPopconfirmTitle(),
189
+ onConfirm: (event) => handleConfirm(createCallbackParams(params, event)),
190
+ onCancel: (event) => handleCancel(createCallbackParams(params, event))
191
+ },
192
+ {
193
+ reference: () => withDirectives(
194
+ h(
195
+ Tag,
196
+ {
197
+ size: "small",
198
+ ...defaultProps,
199
+ ...buttonRowProps,
200
+ onClick: () => {
201
+ hideOnClick.value = false;
202
+ if (isFunction(buttonRow.onClick)) {
203
+ buttonRow.onClick(createCallbackParams(params));
204
+ }
205
+ }
206
+ },
207
+ () => text
208
+ ),
209
+ buttonRow.directives || []
210
+ )
211
+ }
212
+ ) : withDirectives(
213
+ h(
214
+ Tag,
215
+ {
216
+ size: "small",
217
+ ...defaultProps,
218
+ ...buttonRowProps,
219
+ onClick: (event) => handleClickAction(createCallbackParams(params, event))
220
+ },
221
+ () => text
222
+ ),
223
+ buttonRow.directives || []
224
+ );
225
+ }
226
+ };
227
+ const handleConfirm = (callbackParams) => {
228
+ if (isFunction(callbackParams.buttonRow.onConfirm)) {
229
+ callbackParams.buttonRow.onConfirm(callbackParams);
230
+ }
231
+ emit("clickAction", callbackParams);
232
+ };
233
+ const handleCancel = (callbackParams) => {
234
+ if (isFunction(callbackParams.buttonRow.onCancel)) {
235
+ callbackParams.buttonRow.onCancel(callbackParams);
236
+ }
237
+ emit("clickActionConfirmCancel", callbackParams);
238
+ };
239
+ const handleClickAction = (callbackParams) => {
240
+ hideOnClick.value = true;
241
+ const { buttonRow } = callbackParams;
242
+ if (isFunction(buttonRow.onClick)) {
243
+ buttonRow.onClick(callbackParams);
244
+ }
245
+ if (buttonRow.confirm) {
246
+ if (props.confirmType === "messageBox") {
247
+ const { message, title, options, appContext } = getConfirmMsg(buttonRow, callbackParams);
248
+ ElMessageBox.confirm(message, title, options, appContext).then(() => {
249
+ if (isFunction(buttonRow.onConfirm)) {
250
+ buttonRow.onConfirm(callbackParams);
251
+ }
252
+ emit("clickAction", callbackParams);
253
+ }).catch(() => {
254
+ if (isFunction(buttonRow.onCancel)) {
255
+ buttonRow.onCancel(callbackParams);
256
+ }
257
+ emit("clickActionConfirmCancel", callbackParams);
258
+ });
259
+ }
260
+ } else {
261
+ emit("clickAction", callbackParams);
262
+ }
263
+ };
264
+ return (_ctx, _cache) => {
265
+ return openBlock(), createElementBlock(
266
+ Fragment,
267
+ null,
268
+ [
269
+ 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 "),
270
+ (openBlock(true), createElementBlock(
271
+ Fragment,
272
+ null,
273
+ renderList([getSubButtons(_ctx.row, _ctx.index)], (cell) => {
274
+ return openBlock(), createElementBlock(
275
+ Fragment,
276
+ {
277
+ key: cell.preButtons.length
278
+ },
279
+ [
280
+ createCommentVNode(" \u663E\u793A\u51FA\u6765\u7684\u6309\u94AE "),
281
+ (openBlock(true), createElementBlock(
282
+ Fragment,
283
+ null,
284
+ renderList(cell.preButtons, (buttonRow) => {
285
+ return openBlock(), createBlock(resolveDynamicComponent(render(_ctx.row, buttonRow, _ctx.index, _ctx.rest)), {
286
+ key: getButtonKey(buttonRow, _ctx.row, _ctx.index)
287
+ });
288
+ }),
289
+ 128
290
+ /* KEYED_FRAGMENT */
291
+ )),
292
+ createCommentVNode(" \u9690\u85CF\u7684\u6309\u94AE "),
293
+ cell.showMore ? (openBlock(), createBlock(unref(ElDropdown), {
294
+ key: 0,
295
+ persistent: false,
296
+ trigger: "click",
297
+ class: "plus-table-action-bar__dropdown",
298
+ "hide-on-click": hideOnClick.value
299
+ }, {
300
+ dropdown: withCtx(() => [
301
+ createVNode(
302
+ unref(ElDropdownMenu),
303
+ null,
304
+ {
305
+ default: withCtx(() => [
306
+ (openBlock(true), createElementBlock(
307
+ Fragment,
308
+ null,
309
+ renderList(cell.nextButtons, (buttonRow) => {
310
+ return openBlock(), createBlock(
311
+ unref(ElDropdownItem),
312
+ {
313
+ key: getButtonKey(buttonRow, _ctx.row, _ctx.index)
314
+ },
315
+ {
316
+ default: withCtx(() => [
317
+ (openBlock(), createBlock(resolveDynamicComponent(render(_ctx.row, buttonRow, _ctx.index, _ctx.rest))))
318
+ ]),
319
+ _: 2
320
+ /* DYNAMIC */
321
+ },
322
+ 1024
323
+ /* DYNAMIC_SLOTS */
324
+ );
325
+ }),
326
+ 128
327
+ /* KEYED_FRAGMENT */
328
+ ))
329
+ ]),
330
+ _: 2
331
+ /* DYNAMIC */
332
+ },
333
+ 1024
334
+ /* DYNAMIC_SLOTS */
335
+ )
336
+ ]),
337
+ default: withCtx(() => [
338
+ _ctx.moreType === "icon" ? (openBlock(), createElementBlock("span", _hoisted_1, [
339
+ renderSlot(_ctx.$slots, "action-bar-more-icon", {}, () => [
340
+ createVNode(unref(ElIcon), null, {
341
+ default: withCtx(() => [
342
+ createVNode(unref(MoreFilled))
343
+ ]),
344
+ _: 1
345
+ /* STABLE */
346
+ })
347
+ ])
348
+ ])) : (openBlock(), createElementBlock(
349
+ Fragment,
350
+ { key: 1 },
351
+ [
352
+ createCommentVNode(" \u9ED8\u8BA4 "),
353
+ createElementVNode("span", _hoisted_2, [
354
+ createElementVNode(
355
+ "span",
356
+ _hoisted_3,
357
+ toDisplayString(unref(t)("plus.table.more")),
358
+ 1
359
+ /* TEXT */
360
+ ),
361
+ renderSlot(_ctx.$slots, "action-bar-more-icon", {}, () => [
362
+ createVNode(unref(ElIcon), null, {
363
+ default: withCtx(() => [
364
+ createVNode(unref(ArrowDownBold))
365
+ ]),
366
+ _: 1
367
+ /* STABLE */
368
+ })
369
+ ])
370
+ ])
371
+ ],
372
+ 64
373
+ /* STABLE_FRAGMENT */
374
+ ))
375
+ ]),
376
+ _: 2
377
+ /* DYNAMIC */
378
+ }, 1032, ["hide-on-click"])) : createCommentVNode("v-if", true)
379
+ ],
380
+ 64
381
+ /* STABLE_FRAGMENT */
382
+ );
383
+ }),
384
+ 128
385
+ /* KEYED_FRAGMENT */
386
+ ))
387
+ ],
388
+ 2112
389
+ /* STABLE_FRAGMENT, DEV_ROOT_FRAGMENT */
390
+ );
391
+ };
392
+ }
393
+ });
394
+
395
+ export { _sfc_main as default };
@@ -1,7 +1,7 @@
1
+ import { RecordType } from 'tabula-vue';
1
2
  import { TableColumnCtx } from 'element-plus';
2
- import { ButtonsCallBackParams, ActionBarButtonsRow, ActionBarProps } from './type';
3
- import { RecordType } from 'tabula-vue/es/types';
4
- import { ComputedRef, DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, PropType } from 'vue';
3
+ import { DefineComponent, ComponentOptionsMixin, PublicProps, ExtractPropTypes, ComputedRef, PropType } from 'vue';
4
+ import { ActionBarProps, ButtonsCallBackParams, ActionBarButtonsRow } from './type';
5
5
 
6
6
  export interface PlusTableActionBarEmits {
7
7
  (e: 'clickAction', data: ButtonsCallBackParams): void;
@@ -40,10 +40,10 @@ declare const _default: __VLS_WithTemplateSlots< DefineComponent<__VLS_WithDefau
40
40
  type: "link" | "icon" | "button";
41
41
  label: string | ComputedRef<string>;
42
42
  fixed: string;
43
+ actionBarTableColumnProps: Partial< TableColumnCtx<RecordType>>;
43
44
  showNumber: number | ((row: RecordType, index: number) => number);
44
45
  showLimitIncludeMore: boolean;
45
46
  buttons: ActionBarButtonsRow[];
46
- actionBarTableColumnProps: Partial< TableColumnCtx<RecordType>>;
47
47
  confirmType: "messageBox" | "popconfirm";
48
48
  moreType: "text" | "icon";
49
49
  }, {}>, {