ele-admin-plus 1.2.1-beta.2 → 1.2.1-beta.3

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 (357) hide show
  1. package/es/ele-admin-layout/index.d.ts +26 -30
  2. package/es/ele-admin-layout/props.d.ts +11 -10
  3. package/es/ele-alert/index.d.ts +14 -14
  4. package/es/ele-alert/props.d.ts +9 -8
  5. package/es/ele-app/components/message-body.d.ts +5 -4
  6. package/es/ele-app/components/message-box-icon.d.ts +7 -6
  7. package/es/ele-app/style/overwrite/input/index.scss +2 -0
  8. package/es/ele-avatar-group/index.d.ts +15 -14
  9. package/es/ele-avatar-group/props.d.ts +10 -7
  10. package/es/ele-basic-select/index.d.ts +17 -14
  11. package/es/ele-basic-select/index.js +14 -7
  12. package/es/ele-basic-select/props.d.ts +11 -6
  13. package/es/ele-basic-select/props.js +3 -1
  14. package/es/ele-basic-select/util.d.ts +6 -0
  15. package/es/ele-basic-select/util.js +13 -0
  16. package/es/ele-bottom-bar/index.d.ts +4 -4
  17. package/es/ele-bottom-bar/props.d.ts +3 -2
  18. package/es/ele-breadcrumb/index.d.ts +3 -3
  19. package/es/ele-breadcrumb/props.d.ts +1 -1
  20. package/es/ele-card/index.d.ts +14 -14
  21. package/es/ele-card/props.d.ts +8 -6
  22. package/es/ele-check-card/components/card-item.d.ts +3 -2
  23. package/es/ele-check-card/index.d.ts +4 -4
  24. package/es/ele-check-card/index.js +8 -3
  25. package/es/ele-check-card/props.d.ts +3 -2
  26. package/es/ele-config-provider/index.d.ts +4 -4
  27. package/es/ele-config-provider/props.d.ts +3 -3
  28. package/es/ele-config-provider/types.d.ts +1 -0
  29. package/es/ele-copyable/index.d.ts +10 -10
  30. package/es/ele-copyable/props.d.ts +7 -5
  31. package/es/ele-count-up/index.d.ts +1 -1
  32. package/es/ele-cropper/components/cropper-tools.d.ts +4 -3
  33. package/es/ele-cropper/index.d.ts +3 -3
  34. package/es/ele-cropper/props.d.ts +2 -1
  35. package/es/ele-cropper-modal/index.d.ts +4 -4
  36. package/es/ele-cropper-modal/props.d.ts +1 -4
  37. package/es/ele-data-table/index.d.ts +22 -22
  38. package/es/ele-data-table/props.d.ts +16 -16
  39. package/es/ele-data-table/style/index.scss +1 -1
  40. package/es/ele-data-table/types.d.ts +2 -0
  41. package/es/ele-data-table/util.js +5 -1
  42. package/es/ele-drawer/index.d.ts +14 -14
  43. package/es/ele-drawer/props.d.ts +11 -10
  44. package/es/ele-dropdown/index.d.ts +22 -22
  45. package/es/ele-dropdown/index.js +45 -39
  46. package/es/ele-dropdown/props.d.ts +13 -12
  47. package/es/ele-dropdown/types.d.ts +2 -0
  48. package/es/ele-edit-tag/index.d.ts +21 -19
  49. package/es/ele-edit-tag/index.js +10 -2
  50. package/es/ele-edit-tag/props.d.ts +13 -8
  51. package/es/ele-edit-tag/props.js +3 -1
  52. package/es/ele-ellipsis/index.d.ts +5 -4
  53. package/es/ele-ellipsis/props.d.ts +1 -1
  54. package/es/ele-file-list/index.d.ts +4 -4
  55. package/es/ele-icon-select/components/icon-grid.d.ts +8 -6
  56. package/es/ele-icon-select/index.d.ts +37 -36
  57. package/es/ele-icon-select/index.js +6 -2
  58. package/es/ele-icon-select/props.d.ts +18 -14
  59. package/es/ele-icon-select/props.js +2 -0
  60. package/es/ele-loading/index.d.ts +4 -4
  61. package/es/ele-loading/props.d.ts +3 -2
  62. package/es/ele-map-picker/components/map-view.d.ts +26 -28
  63. package/es/ele-map-picker/components/map-view.js +1 -0
  64. package/es/ele-map-picker/index.d.ts +10 -10
  65. package/es/ele-map-picker/props.d.ts +6 -5
  66. package/es/ele-map-picker/style/index.scss +1 -1
  67. package/es/ele-menus/index.d.ts +2 -2
  68. package/es/ele-menus/props.d.ts +1 -1
  69. package/es/ele-menus/style/index.scss +4 -0
  70. package/es/ele-modal/index.d.ts +24 -23
  71. package/es/ele-modal/index.js +30 -64
  72. package/es/ele-modal/props.d.ts +14 -13
  73. package/es/ele-modal/util.d.ts +31 -24
  74. package/es/ele-modal/util.js +235 -132
  75. package/es/ele-pagination/index.d.ts +18 -6
  76. package/es/ele-pagination/index.js +3 -2
  77. package/es/ele-pagination/props.d.ts +8 -2
  78. package/es/ele-pagination/style/index.scss +70 -0
  79. package/es/ele-popconfirm/index.d.ts +32 -32
  80. package/es/ele-popconfirm/props.d.ts +19 -17
  81. package/es/ele-popover/index.d.ts +22 -22
  82. package/es/ele-popover/props.d.ts +11 -10
  83. package/es/ele-printer/index.d.ts +8 -8
  84. package/es/ele-printer/props.d.ts +6 -5
  85. package/es/ele-printer/util.d.ts +5 -5
  86. package/es/ele-printer/util.js +68 -43
  87. package/es/ele-pro-layout/index.d.ts +43 -47
  88. package/es/ele-pro-layout/props.d.ts +16 -14
  89. package/es/ele-pro-table/components/table-tools.d.ts +402 -32
  90. package/es/ele-pro-table/components/table-tools.js +223 -140
  91. package/es/ele-pro-table/components/tool-column-list.d.ts +12 -0
  92. package/es/ele-pro-table/components/tool-column-list.js +33 -6
  93. package/es/ele-pro-table/components/tool-column.d.ts +8 -7
  94. package/es/ele-pro-table/components/tool-column.js +11 -5
  95. package/es/ele-pro-table/components/tool-export.d.ts +33 -30
  96. package/es/ele-pro-table/components/tool-export.js +204 -184
  97. package/es/ele-pro-table/components/tool-print-body-cell.d.ts +5 -4
  98. package/es/ele-pro-table/components/tool-print-header-cell.d.ts +5 -4
  99. package/es/ele-pro-table/components/tool-print.d.ts +41 -40
  100. package/es/ele-pro-table/components/tool-print.js +357 -336
  101. package/es/ele-pro-table/index.d.ts +1006 -70
  102. package/es/ele-pro-table/index.js +63 -13
  103. package/es/ele-pro-table/props.d.ts +17 -18
  104. package/es/ele-pro-table/props.js +3 -1
  105. package/es/ele-pro-table/style/index.scss +43 -12
  106. package/es/ele-pro-table/types.d.ts +54 -0
  107. package/es/ele-pro-table/util.d.ts +51 -9
  108. package/es/ele-pro-table/util.js +89 -28
  109. package/es/ele-qr-code/components/canvas-render.d.ts +67 -0
  110. package/es/ele-qr-code/components/canvas-render.js +147 -0
  111. package/es/ele-qr-code/index.d.ts +5 -9
  112. package/es/ele-qr-code/index.js +33 -136
  113. package/es/ele-qr-code/props.d.ts +5 -2
  114. package/es/ele-qr-code/props.js +3 -1
  115. package/es/ele-qr-code/types.d.ts +5 -0
  116. package/es/ele-qr-code-svg/index.d.ts +6 -5
  117. package/es/ele-qr-code-svg/index.js +11 -14
  118. package/es/ele-segmented/index.js +3 -0
  119. package/es/ele-split-panel/index.d.ts +7 -7
  120. package/es/ele-split-panel/props.d.ts +4 -3
  121. package/es/ele-steps/index.d.ts +2 -2
  122. package/es/ele-steps/props.d.ts +2 -2
  123. package/es/ele-table/index.d.ts +2 -2
  124. package/es/ele-table/props.d.ts +2 -1
  125. package/es/ele-table-select/index.d.ts +22 -20
  126. package/es/ele-table-select/index.js +5 -2
  127. package/es/ele-table-select/props.d.ts +11 -7
  128. package/es/ele-table-select/props.js +2 -0
  129. package/es/ele-tabs/index.d.ts +19 -34
  130. package/es/ele-tabs/index.js +133 -86
  131. package/es/ele-tabs/props.d.ts +10 -24
  132. package/es/ele-tabs/props.js +3 -1
  133. package/es/ele-tabs/style/index.scss +42 -2
  134. package/es/ele-tabs/types.d.ts +2 -11
  135. package/es/ele-text/index.d.ts +2 -2
  136. package/es/ele-text/props.d.ts +2 -1
  137. package/es/ele-tool/index.d.ts +5 -2
  138. package/es/ele-tool/index.js +2 -5
  139. package/es/ele-tool/props.d.ts +4 -1
  140. package/es/ele-tool/props.js +3 -1
  141. package/es/ele-tool/style/index.scss +13 -0
  142. package/es/ele-toolbar/index.d.ts +17 -17
  143. package/es/ele-toolbar/props.d.ts +4 -3
  144. package/es/ele-tooltip/index.d.ts +13 -12
  145. package/es/ele-tooltip/props.d.ts +7 -6
  146. package/es/ele-tour/index.d.ts +1 -1
  147. package/es/ele-tree-select/index.d.ts +18 -18
  148. package/es/ele-tree-select/index.js +5 -2
  149. package/es/ele-tree-select/props.d.ts +12 -8
  150. package/es/ele-tree-select/props.js +3 -1
  151. package/es/ele-upload-list/index.d.ts +7 -9
  152. package/es/ele-upload-list/props.d.ts +4 -3
  153. package/es/ele-upload-list/style/index.scss +4 -0
  154. package/es/ele-virtual-table/components/body-cell.d.ts +11 -27
  155. package/es/ele-virtual-table/components/body-row.d.ts +13 -29
  156. package/es/ele-virtual-table/components/cell-checkbox.d.ts +3 -2
  157. package/es/ele-virtual-table/components/cell-filter.d.ts +6 -6
  158. package/es/ele-virtual-table/components/footer-row.d.ts +3 -3
  159. package/es/ele-virtual-table/components/header-cell.d.ts +7 -7
  160. package/es/ele-virtual-table/components/header-row.d.ts +7 -7
  161. package/es/ele-virtual-table/index.d.ts +20 -21
  162. package/es/ele-virtual-table/props.d.ts +11 -11
  163. package/es/ele-watermark/index.d.ts +5 -4
  164. package/es/ele-watermark/props.d.ts +2 -1
  165. package/es/ele-xg-player/index.d.ts +3 -3
  166. package/es/icons/SizeCompactOutlined.d.ts +2 -0
  167. package/es/icons/SizeCompactOutlined.js +34 -0
  168. package/es/icons/SizeSlackOutlined.d.ts +2 -0
  169. package/es/icons/SizeSlackOutlined.js +34 -0
  170. package/es/icons/index.d.ts +2 -0
  171. package/es/icons/index.js +46 -42
  172. package/es/lang/en_US.js +1 -0
  173. package/es/lang/zh_CN.js +1 -0
  174. package/es/lang/zh_TW.js +1 -0
  175. package/es/style/themes/default.scss +12 -5
  176. package/es/style/themes/rounded.scss +3 -2
  177. package/es/utils/hook.d.ts +75 -4
  178. package/es/utils/hook.js +155 -6
  179. package/lib/ele-admin-layout/index.d.ts +26 -30
  180. package/lib/ele-admin-layout/props.d.ts +11 -10
  181. package/lib/ele-alert/index.d.ts +14 -14
  182. package/lib/ele-alert/props.d.ts +9 -8
  183. package/lib/ele-app/components/message-body.d.ts +5 -4
  184. package/lib/ele-app/components/message-box-icon.d.ts +7 -6
  185. package/lib/ele-app/style/overwrite/input/index.scss +2 -0
  186. package/lib/ele-avatar-group/index.d.ts +15 -14
  187. package/lib/ele-avatar-group/props.d.ts +10 -7
  188. package/lib/ele-basic-select/index.cjs +14 -7
  189. package/lib/ele-basic-select/index.d.ts +17 -14
  190. package/lib/ele-basic-select/props.cjs +3 -1
  191. package/lib/ele-basic-select/props.d.ts +11 -6
  192. package/lib/ele-basic-select/util.cjs +13 -0
  193. package/lib/ele-basic-select/util.d.ts +6 -0
  194. package/lib/ele-bottom-bar/index.d.ts +4 -4
  195. package/lib/ele-bottom-bar/props.d.ts +3 -2
  196. package/lib/ele-breadcrumb/index.d.ts +3 -3
  197. package/lib/ele-breadcrumb/props.d.ts +1 -1
  198. package/lib/ele-card/index.d.ts +14 -14
  199. package/lib/ele-card/props.d.ts +8 -6
  200. package/lib/ele-check-card/components/card-item.d.ts +3 -2
  201. package/lib/ele-check-card/index.cjs +8 -3
  202. package/lib/ele-check-card/index.d.ts +4 -4
  203. package/lib/ele-check-card/props.d.ts +3 -2
  204. package/lib/ele-config-provider/index.d.ts +4 -4
  205. package/lib/ele-config-provider/props.d.ts +3 -3
  206. package/lib/ele-config-provider/types.d.ts +1 -0
  207. package/lib/ele-copyable/index.d.ts +10 -10
  208. package/lib/ele-copyable/props.d.ts +7 -5
  209. package/lib/ele-count-up/index.d.ts +1 -1
  210. package/lib/ele-cropper/components/cropper-tools.d.ts +4 -3
  211. package/lib/ele-cropper/index.d.ts +3 -3
  212. package/lib/ele-cropper/props.d.ts +2 -1
  213. package/lib/ele-cropper-modal/index.d.ts +4 -4
  214. package/lib/ele-cropper-modal/props.d.ts +1 -4
  215. package/lib/ele-data-table/index.d.ts +22 -22
  216. package/lib/ele-data-table/props.d.ts +16 -16
  217. package/lib/ele-data-table/style/index.scss +1 -1
  218. package/lib/ele-data-table/types.d.ts +2 -0
  219. package/lib/ele-data-table/util.cjs +5 -1
  220. package/lib/ele-drawer/index.d.ts +14 -14
  221. package/lib/ele-drawer/props.d.ts +11 -10
  222. package/lib/ele-dropdown/index.cjs +45 -39
  223. package/lib/ele-dropdown/index.d.ts +22 -22
  224. package/lib/ele-dropdown/props.d.ts +13 -12
  225. package/lib/ele-dropdown/types.d.ts +2 -0
  226. package/lib/ele-edit-tag/index.cjs +10 -2
  227. package/lib/ele-edit-tag/index.d.ts +21 -19
  228. package/lib/ele-edit-tag/props.cjs +3 -1
  229. package/lib/ele-edit-tag/props.d.ts +13 -8
  230. package/lib/ele-ellipsis/index.d.ts +5 -4
  231. package/lib/ele-ellipsis/props.d.ts +1 -1
  232. package/lib/ele-file-list/index.d.ts +4 -4
  233. package/lib/ele-icon-select/components/icon-grid.d.ts +8 -6
  234. package/lib/ele-icon-select/index.cjs +9 -5
  235. package/lib/ele-icon-select/index.d.ts +37 -36
  236. package/lib/ele-icon-select/props.cjs +2 -0
  237. package/lib/ele-icon-select/props.d.ts +18 -14
  238. package/lib/ele-loading/index.d.ts +4 -4
  239. package/lib/ele-loading/props.d.ts +3 -2
  240. package/lib/ele-map-picker/components/map-view.cjs +1 -0
  241. package/lib/ele-map-picker/components/map-view.d.ts +26 -28
  242. package/lib/ele-map-picker/index.d.ts +10 -10
  243. package/lib/ele-map-picker/props.d.ts +6 -5
  244. package/lib/ele-map-picker/style/index.scss +1 -1
  245. package/lib/ele-menus/index.d.ts +2 -2
  246. package/lib/ele-menus/props.d.ts +1 -1
  247. package/lib/ele-menus/style/index.scss +4 -0
  248. package/lib/ele-modal/index.cjs +28 -62
  249. package/lib/ele-modal/index.d.ts +24 -23
  250. package/lib/ele-modal/props.d.ts +14 -13
  251. package/lib/ele-modal/util.cjs +235 -132
  252. package/lib/ele-modal/util.d.ts +31 -24
  253. package/lib/ele-pagination/index.cjs +3 -2
  254. package/lib/ele-pagination/index.d.ts +18 -6
  255. package/lib/ele-pagination/props.d.ts +8 -2
  256. package/lib/ele-pagination/style/index.scss +70 -0
  257. package/lib/ele-popconfirm/index.d.ts +32 -32
  258. package/lib/ele-popconfirm/props.d.ts +19 -17
  259. package/lib/ele-popover/index.d.ts +22 -22
  260. package/lib/ele-popover/props.d.ts +11 -10
  261. package/lib/ele-printer/index.d.ts +8 -8
  262. package/lib/ele-printer/props.d.ts +6 -5
  263. package/lib/ele-printer/util.cjs +68 -43
  264. package/lib/ele-printer/util.d.ts +5 -5
  265. package/lib/ele-pro-layout/index.d.ts +43 -47
  266. package/lib/ele-pro-layout/props.d.ts +16 -14
  267. package/lib/ele-pro-table/components/table-tools.cjs +221 -138
  268. package/lib/ele-pro-table/components/table-tools.d.ts +402 -32
  269. package/lib/ele-pro-table/components/tool-column-list.cjs +32 -5
  270. package/lib/ele-pro-table/components/tool-column-list.d.ts +12 -0
  271. package/lib/ele-pro-table/components/tool-column.cjs +10 -4
  272. package/lib/ele-pro-table/components/tool-column.d.ts +8 -7
  273. package/lib/ele-pro-table/components/tool-export.cjs +201 -181
  274. package/lib/ele-pro-table/components/tool-export.d.ts +33 -30
  275. package/lib/ele-pro-table/components/tool-print-body-cell.d.ts +5 -4
  276. package/lib/ele-pro-table/components/tool-print-header-cell.d.ts +5 -4
  277. package/lib/ele-pro-table/components/tool-print.cjs +354 -333
  278. package/lib/ele-pro-table/components/tool-print.d.ts +41 -40
  279. package/lib/ele-pro-table/index.cjs +60 -10
  280. package/lib/ele-pro-table/index.d.ts +1006 -70
  281. package/lib/ele-pro-table/props.cjs +3 -1
  282. package/lib/ele-pro-table/props.d.ts +17 -18
  283. package/lib/ele-pro-table/style/index.scss +43 -12
  284. package/lib/ele-pro-table/types.d.ts +54 -0
  285. package/lib/ele-pro-table/util.cjs +89 -28
  286. package/lib/ele-pro-table/util.d.ts +51 -9
  287. package/lib/ele-qr-code/components/canvas-render.cjs +146 -0
  288. package/lib/ele-qr-code/components/canvas-render.d.ts +67 -0
  289. package/lib/ele-qr-code/index.cjs +32 -135
  290. package/lib/ele-qr-code/index.d.ts +5 -9
  291. package/lib/ele-qr-code/props.cjs +3 -1
  292. package/lib/ele-qr-code/props.d.ts +5 -2
  293. package/lib/ele-qr-code/types.d.ts +5 -0
  294. package/lib/ele-qr-code-svg/index.cjs +10 -13
  295. package/lib/ele-qr-code-svg/index.d.ts +6 -5
  296. package/lib/ele-segmented/index.cjs +3 -0
  297. package/lib/ele-split-panel/index.d.ts +7 -7
  298. package/lib/ele-split-panel/props.d.ts +4 -3
  299. package/lib/ele-steps/index.d.ts +2 -2
  300. package/lib/ele-steps/props.d.ts +2 -2
  301. package/lib/ele-table/index.d.ts +2 -2
  302. package/lib/ele-table/props.d.ts +2 -1
  303. package/lib/ele-table-select/index.cjs +20 -17
  304. package/lib/ele-table-select/index.d.ts +22 -20
  305. package/lib/ele-table-select/props.cjs +2 -0
  306. package/lib/ele-table-select/props.d.ts +11 -7
  307. package/lib/ele-tabs/index.cjs +132 -85
  308. package/lib/ele-tabs/index.d.ts +19 -34
  309. package/lib/ele-tabs/props.cjs +3 -1
  310. package/lib/ele-tabs/props.d.ts +10 -24
  311. package/lib/ele-tabs/style/index.scss +42 -2
  312. package/lib/ele-tabs/types.d.ts +2 -11
  313. package/lib/ele-text/index.d.ts +2 -2
  314. package/lib/ele-text/props.d.ts +2 -1
  315. package/lib/ele-tool/index.cjs +2 -5
  316. package/lib/ele-tool/index.d.ts +5 -2
  317. package/lib/ele-tool/props.cjs +3 -1
  318. package/lib/ele-tool/props.d.ts +4 -1
  319. package/lib/ele-tool/style/index.scss +13 -0
  320. package/lib/ele-toolbar/index.d.ts +17 -17
  321. package/lib/ele-toolbar/props.d.ts +4 -3
  322. package/lib/ele-tooltip/index.d.ts +13 -12
  323. package/lib/ele-tooltip/props.d.ts +7 -6
  324. package/lib/ele-tour/index.d.ts +1 -1
  325. package/lib/ele-tree-select/index.cjs +4 -1
  326. package/lib/ele-tree-select/index.d.ts +18 -18
  327. package/lib/ele-tree-select/props.cjs +3 -1
  328. package/lib/ele-tree-select/props.d.ts +12 -8
  329. package/lib/ele-upload-list/index.d.ts +7 -9
  330. package/lib/ele-upload-list/props.d.ts +4 -3
  331. package/lib/ele-upload-list/style/index.scss +4 -0
  332. package/lib/ele-virtual-table/components/body-cell.d.ts +11 -27
  333. package/lib/ele-virtual-table/components/body-row.d.ts +13 -29
  334. package/lib/ele-virtual-table/components/cell-checkbox.d.ts +3 -2
  335. package/lib/ele-virtual-table/components/cell-filter.d.ts +6 -6
  336. package/lib/ele-virtual-table/components/footer-row.d.ts +3 -3
  337. package/lib/ele-virtual-table/components/header-cell.d.ts +7 -7
  338. package/lib/ele-virtual-table/components/header-row.d.ts +7 -7
  339. package/lib/ele-virtual-table/index.d.ts +20 -21
  340. package/lib/ele-virtual-table/props.d.ts +11 -11
  341. package/lib/ele-watermark/index.d.ts +5 -4
  342. package/lib/ele-watermark/props.d.ts +2 -1
  343. package/lib/ele-xg-player/index.d.ts +3 -3
  344. package/lib/icons/SizeCompactOutlined.cjs +33 -0
  345. package/lib/icons/SizeCompactOutlined.d.ts +2 -0
  346. package/lib/icons/SizeSlackOutlined.cjs +33 -0
  347. package/lib/icons/SizeSlackOutlined.d.ts +2 -0
  348. package/lib/icons/index.cjs +4 -0
  349. package/lib/icons/index.d.ts +2 -0
  350. package/lib/lang/en_US.cjs +1 -0
  351. package/lib/lang/zh_CN.cjs +1 -0
  352. package/lib/lang/zh_TW.cjs +1 -0
  353. package/lib/style/themes/default.scss +12 -5
  354. package/lib/style/themes/rounded.scss +3 -2
  355. package/lib/utils/hook.cjs +154 -5
  356. package/lib/utils/hook.d.ts +75 -4
  357. package/package.json +14 -13
@@ -19,6 +19,7 @@ declare const _default: import('vue').DefineComponent<{
19
19
  sortable: BooleanConstructor;
20
20
  mousewheel: BooleanConstructor;
21
21
  handleClick: BooleanConstructor;
22
+ flexTable: BooleanConstructor;
22
23
  closable: BooleanConstructor;
23
24
  addable: BooleanConstructor;
24
25
  modelValue: {
@@ -28,13 +29,13 @@ declare const _default: import('vue').DefineComponent<{
28
29
  __epPropKey: true;
29
30
  };
30
31
  editable: BooleanConstructor;
31
- tabPosition: import('element-plus/es/utils/index').EpPropFinalized<StringConstructor, "top" | "bottom" | "right" | "left", unknown, "top", boolean>;
32
- beforeLeave: import('element-plus/es/utils/index').EpPropFinalized<(new (...args: any[]) => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | (() => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | {
33
- (): (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>;
32
+ tabPosition: import('element-plus/es/utils/index').EpPropFinalized<StringConstructor, "top" | "bottom" | "left" | "right", unknown, "top", boolean>;
33
+ beforeLeave: import('element-plus/es/utils/index').EpPropFinalized<(new (...args: any[]) => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | (() => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | {
34
+ (): (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>;
34
35
  new (): any;
35
36
  readonly prototype: any;
36
- } | ((new (...args: any[]) => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | (() => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | {
37
- (): (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>;
37
+ } | ((new (...args: any[]) => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | (() => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | {
38
+ (): (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>;
38
39
  new (): any;
39
40
  readonly prototype: any;
40
41
  })[], unknown, unknown, () => true, boolean>;
@@ -53,7 +54,7 @@ declare const _default: import('vue').DefineComponent<{
53
54
  handleTabChange: (name: TabPaneName) => void;
54
55
  handleTabRemove: (name: TabPaneName) => void;
55
56
  handleTabAdd: () => void;
56
- handleEdit: (name: TabPaneName | undefined, action: 'remove' | 'add') => void;
57
+ handleEdit: (name: TabPaneName | undefined, action: "remove" | "add") => void;
57
58
  handleItemClick: (option: TabEventOption) => void;
58
59
  handleItemContextMenu: (option: TabEventOption) => void;
59
60
  handleItemContextOpen: (ref: EleDropdownInstance) => void;
@@ -66,25 +67,9 @@ declare const _default: import('vue').DefineComponent<{
66
67
  tabContextOpen: (_ref: EleDropdownInstance) => boolean;
67
68
  tabSortChange: (_data: TabPaneItem[]) => boolean;
68
69
  "update:modelValue": (name: TabPaneName) => boolean;
69
- tabClick: (pane: {
70
- uid: number;
71
- slots: Readonly<{
72
- [name: string]: import('vue').Slot<any> | undefined;
73
- }>;
74
- props: {
75
- readonly label: string;
76
- readonly closable: boolean;
77
- readonly disabled: boolean;
78
- readonly lazy: boolean;
79
- readonly name?: import('element-plus/es/utils/index').EpPropMergeType<readonly [StringConstructor, NumberConstructor], unknown, unknown> | undefined;
80
- };
81
- paneName: string | number | undefined;
82
- active: boolean;
83
- index: string | undefined;
84
- isClosable: boolean;
85
- }, ev: Event) => boolean;
70
+ tabClick: (pane: TabsPaneContext, ev: Event) => boolean;
86
71
  tabChange: (name: TabPaneName) => boolean;
87
- edit: (paneName: TabPaneName | undefined, action: "add" | "remove") => boolean;
72
+ edit: (paneName: TabPaneName | undefined, action: "remove" | "add") => boolean;
88
73
  tabRemove: (name: TabPaneName) => boolean;
89
74
  tabAdd: () => boolean;
90
75
  }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
@@ -100,6 +85,7 @@ declare const _default: import('vue').DefineComponent<{
100
85
  sortable: BooleanConstructor;
101
86
  mousewheel: BooleanConstructor;
102
87
  handleClick: BooleanConstructor;
88
+ flexTable: BooleanConstructor;
103
89
  closable: BooleanConstructor;
104
90
  addable: BooleanConstructor;
105
91
  modelValue: {
@@ -109,13 +95,13 @@ declare const _default: import('vue').DefineComponent<{
109
95
  __epPropKey: true;
110
96
  };
111
97
  editable: BooleanConstructor;
112
- tabPosition: import('element-plus/es/utils/index').EpPropFinalized<StringConstructor, "top" | "bottom" | "right" | "left", unknown, "top", boolean>;
113
- beforeLeave: import('element-plus/es/utils/index').EpPropFinalized<(new (...args: any[]) => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | (() => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | {
114
- (): (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>;
98
+ tabPosition: import('element-plus/es/utils/index').EpPropFinalized<StringConstructor, "top" | "bottom" | "left" | "right", unknown, "top", boolean>;
99
+ beforeLeave: import('element-plus/es/utils/index').EpPropFinalized<(new (...args: any[]) => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | (() => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | {
100
+ (): (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>;
115
101
  new (): any;
116
102
  readonly prototype: any;
117
- } | ((new (...args: any[]) => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | (() => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | {
118
- (): (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>;
103
+ } | ((new (...args: any[]) => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | (() => (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | {
104
+ (): (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>;
119
105
  new (): any;
120
106
  readonly prototype: any;
121
107
  })[], unknown, unknown, () => true, boolean>;
@@ -124,9 +110,7 @@ declare const _default: import('vue').DefineComponent<{
124
110
  "onUpdate:modelValue"?: ((name: TabPaneName) => any) | undefined;
125
111
  onTabClick?: ((pane: {
126
112
  uid: number;
127
- slots: Readonly<{
128
- [name: string]: import('vue').Slot<any> | undefined;
129
- }>;
113
+ slots: import('vue').Slots;
130
114
  props: {
131
115
  readonly label: string;
132
116
  readonly closable: boolean;
@@ -148,15 +132,16 @@ declare const _default: import('vue').DefineComponent<{
148
132
  onTabContextOpen?: ((_ref: EleDropdownInstance) => any) | undefined;
149
133
  onTabSortChange?: ((_data: TabPaneItem[]) => any) | undefined;
150
134
  }, {
135
+ mousewheel: boolean;
151
136
  closable: boolean;
152
137
  center: boolean;
153
- beforeLeave: (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>;
138
+ beforeLeave: (newName: TabPaneName, oldName: TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>;
154
139
  sortable: boolean;
155
140
  addable: boolean;
156
141
  editable: boolean;
157
142
  tabPosition: import('element-plus/es/utils/index').EpPropMergeType<StringConstructor, "top" | "bottom" | "right" | "left", unknown>;
158
143
  stretch: boolean;
159
144
  handleClick: boolean;
160
- mousewheel: boolean;
145
+ flexTable: boolean;
161
146
  }, {}>;
162
147
  export default _default;
@@ -1,7 +1,8 @@
1
- import { defineComponent, inject, ref, computed, onMounted, onBeforeUnmount, watch, resolveComponent, openBlock, createBlock, mergeProps, createSlots, withCtx, createElementBlock, Fragment, renderList, createVNode, renderSlot } from "vue";
1
+ import { defineComponent, inject, ref, computed, onMounted, nextTick, onBeforeUnmount, watch, resolveComponent, openBlock, createBlock, mergeProps, createSlots, withCtx, createElementBlock, Fragment, renderList, createVNode, renderSlot, createCommentVNode } from "vue";
2
2
  import SortableJs from "sortablejs";
3
3
  import { ElTabs, ElTabPane } from "element-plus";
4
4
  import { pick, omit } from "../utils/core";
5
+ import { useTimer, useMousewheel, useTouchEvent } from "../utils/hook";
5
6
  import TabTitle from "./components/tab-title";
6
7
  import { tabsProps, tabsEmits, TAB_WRAP_KEY, tabPropKeys } from "./props";
7
8
  const _sfc_main = defineComponent({
@@ -10,8 +11,25 @@ const _sfc_main = defineComponent({
10
11
  props: tabsProps,
11
12
  emits: tabsEmits,
12
13
  setup(props, { emit }) {
14
+ const [startScrollTimer, _stopScrollTimer, scrollWaiting] = useTimer(320);
15
+ let sortableIns = null;
13
16
  const wrapProps = inject(TAB_WRAP_KEY, null);
14
- const current = { sortIns: null, isScroll: false };
17
+ const { bindMousewheel, unbindMousewheel } = useMousewheel((param) => {
18
+ const { e, direction } = param;
19
+ scrollTabs(direction === "up" ? "prev" : "next", () => {
20
+ e.preventDefault();
21
+ e.stopPropagation();
22
+ });
23
+ });
24
+ const { bindTouchEvent, unbindTouchEvent } = useTouchEvent({
25
+ end: (param) => {
26
+ if (param.distanceX && param.distanceX > 80) {
27
+ scrollTabs("prev");
28
+ } else if (param.distanceX && param.distanceX < 80) {
29
+ scrollTabs("next");
30
+ }
31
+ }
32
+ });
15
33
  const tabRef = ref(null);
16
34
  const itemRefs = ref([]);
17
35
  const isWrap = computed(() => wrapProps == null);
@@ -57,7 +75,7 @@ const _sfc_main = defineComponent({
57
75
  const handleItemContextOpen = (ref2) => {
58
76
  if (itemRefs.value) {
59
77
  itemRefs.value.forEach((r) => {
60
- if ((r == null ? void 0 : r.dropdownRef) && r.dropdownRef !== ref2) {
78
+ if (r && r.dropdownRef && r.dropdownRef !== ref2) {
61
79
  r.dropdownRef.handleClose();
62
80
  }
63
81
  });
@@ -73,7 +91,7 @@ const _sfc_main = defineComponent({
73
91
  const hideAllDropdown = () => {
74
92
  if (itemRefs.value) {
75
93
  itemRefs.value.forEach((r) => {
76
- if (r == null ? void 0 : r.dropdownRef) {
94
+ if (r && r.dropdownRef) {
77
95
  r.dropdownRef.handleClose();
78
96
  }
79
97
  });
@@ -88,15 +106,6 @@ const _sfc_main = defineComponent({
88
106
  const headerEl = getHeaderEl();
89
107
  return headerEl ? headerEl.querySelector(".el-tabs__nav") : void 0;
90
108
  };
91
- const getBtnEl = (el, e, firefox) => {
92
- const wheelDelta = e.wheelDelta || e.detail;
93
- const delta = firefox ? -wheelDelta : wheelDelta;
94
- if (delta > 0) {
95
- return el.querySelector(".el-tabs__nav-prev");
96
- } else if (delta < 0) {
97
- return el.querySelector(".el-tabs__nav-next");
98
- }
99
- };
100
109
  const updateActiveBar = () => {
101
110
  const el = getNavEl();
102
111
  if (el) {
@@ -106,13 +115,35 @@ const _sfc_main = defineComponent({
106
115
  }
107
116
  }
108
117
  };
118
+ const scrollTabs = (direction, done) => {
119
+ const tabEl = getHeaderEl();
120
+ if (tabEl && !scrollWaiting.value) {
121
+ const el = tabEl.querySelector(`.el-tabs__nav-${direction}`);
122
+ if (el && !el.classList.contains("is-disabled")) {
123
+ startScrollTimer();
124
+ done && done();
125
+ el.click();
126
+ }
127
+ }
128
+ };
129
+ const checkScrollActive = () => {
130
+ const active = props.modelValue;
131
+ if (props.items && active != null) {
132
+ const index2 = props.items.findIndex((item) => item.name === active);
133
+ if (index2 === 0) {
134
+ scrollTabs("prev");
135
+ } else if (index2 === props.items.length - 1) {
136
+ scrollTabs("next");
137
+ }
138
+ }
139
+ };
109
140
  const bindDragSort = () => {
110
141
  unbindDragSort();
111
142
  const el = getNavEl();
112
143
  if (!props.sortable || !el) {
113
144
  return;
114
145
  }
115
- current.sortIns = new SortableJs(el, {
146
+ sortableIns = new SortableJs(el, {
116
147
  animation: 300,
117
148
  draggable: ".el-tabs__item",
118
149
  onUpdate: ({ oldDraggableIndex, newDraggableIndex }) => {
@@ -131,42 +162,40 @@ const _sfc_main = defineComponent({
131
162
  });
132
163
  };
133
164
  const unbindDragSort = () => {
134
- current.sortIns && current.sortIns.destroy();
135
- current.sortIns = null;
165
+ sortableIns && sortableIns.destroy();
166
+ sortableIns = null;
136
167
  };
137
- const handleMousewheel = (e, isFirefox) => {
138
- const tabEl = e.currentTarget;
139
- if (tabEl && !current.isScroll) {
140
- const el = getBtnEl(tabEl, e, isFirefox);
141
- if (el && !el.classList.contains("is-disabled")) {
142
- current.isScroll = true;
143
- e.preventDefault();
144
- e.stopPropagation();
145
- el.click();
146
- setTimeout(() => {
147
- current.isScroll = false;
148
- }, 300);
168
+ const initMousewheelEvent = () => {
169
+ const el = getHeaderEl();
170
+ if (el != null) {
171
+ unbindMousewheel(el);
172
+ if (props.mousewheel) {
173
+ bindMousewheel(el);
149
174
  }
150
175
  }
151
176
  };
152
- const handleFirefoxMousewheel = (e) => {
153
- handleMousewheel(e, true);
177
+ const initTouchEvent = () => {
178
+ const el = getHeaderEl();
179
+ if (el != null) {
180
+ unbindTouchEvent(el);
181
+ if (!props.sortable) {
182
+ bindTouchEvent(el);
183
+ }
184
+ }
154
185
  };
155
186
  onMounted(() => {
187
+ nextTick(() => {
188
+ checkScrollActive();
189
+ });
190
+ initMousewheelEvent();
191
+ initTouchEvent();
156
192
  bindDragSort();
157
- const el = getHeaderEl();
158
- if (props.mousewheel && el) {
159
- el.addEventListener("mousewheel", handleMousewheel, {
160
- passive: false
161
- });
162
- el.addEventListener("DOMMouseScroll", handleFirefoxMousewheel);
163
- }
164
193
  });
165
194
  onBeforeUnmount(() => {
166
195
  const el = getHeaderEl();
167
- if (el) {
168
- el.removeEventListener("mousewheel", handleMousewheel);
169
- el.removeEventListener("DOMMouseScroll", handleFirefoxMousewheel);
196
+ if (el != null) {
197
+ unbindMousewheel(el);
198
+ unbindTouchEvent(el);
170
199
  }
171
200
  unbindDragSort();
172
201
  });
@@ -174,6 +203,21 @@ const _sfc_main = defineComponent({
174
203
  () => props.sortable,
175
204
  () => {
176
205
  bindDragSort();
206
+ initTouchEvent();
207
+ }
208
+ );
209
+ watch(
210
+ () => props.mousewheel,
211
+ () => {
212
+ initMousewheelEvent();
213
+ }
214
+ );
215
+ watch(
216
+ () => props.modelValue,
217
+ () => {
218
+ nextTick(() => {
219
+ checkScrollActive();
220
+ });
177
221
  }
178
222
  );
179
223
  return {
@@ -225,7 +269,8 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
225
269
  { "is-indicator": _ctx.tabType === "indicator" },
226
270
  { "is-button": _ctx.tabType === "button" },
227
271
  { "is-tag": _ctx.tabType === "tag" },
228
- { "is-center": _ctx.center }
272
+ { "is-center": _ctx.center },
273
+ { "is-flex-table": _ctx.flexTable }
229
274
  ],
230
275
  "onUpdate:modelValue": _ctx.updateModelValue,
231
276
  onTabClick: _ctx.handleTabClick,
@@ -237,52 +282,54 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) {
237
282
  }), createSlots({
238
283
  default: withCtx(() => [
239
284
  (openBlock(true), createElementBlock(Fragment, null, renderList(_ctx.items, (item, index2) => {
240
- return openBlock(), createBlock(_component_ElTabPane, mergeProps({
241
- key: index2 + "-" + item.name + "-" + item.label,
242
- ref_for: true
243
- }, _ctx.omit(item, ["slot", "meta"])), createSlots({
244
- label: withCtx(() => [
245
- createVNode(_component_TabTitle, {
246
- ref_for: true,
247
- ref: "itemRefs",
248
- item,
249
- label: item.label,
250
- tabName: item.name,
251
- active: _ctx.modelValue,
252
- handleClick: _ctx.handleClick,
253
- contextMenu: _ctx.contextMenu,
254
- contextMenus: _ctx.getContextMenus(item),
255
- onContextMenu: _ctx.handleItemContextMenu,
256
- onContextOpen: _ctx.handleItemContextOpen,
257
- onItemClick: _ctx.handleItemClick
258
- }, createSlots({ _: 2 }, [
259
- _ctx.$slots.label ? {
260
- name: "label",
261
- fn: withCtx((slotProps) => [
262
- renderSlot(_ctx.$slots, "label", mergeProps({ ref_for: true }, slotProps || {}))
263
- ]),
264
- key: "0"
265
- } : void 0,
266
- _ctx.$slots.contextMenu ? {
267
- name: "contextMenu",
268
- fn: withCtx((slotProps) => [
269
- renderSlot(_ctx.$slots, "contextMenu", mergeProps({ ref_for: true }, slotProps || {}))
270
- ]),
271
- key: "1"
272
- } : void 0
273
- ]), 1032, ["item", "label", "tabName", "active", "handleClick", "contextMenu", "contextMenus", "onContextMenu", "onContextOpen", "onItemClick"])
274
- ]),
275
- _: 2
276
- }, [
277
- item.name && _ctx.$slots[item.slot || item.name] ? {
278
- name: "default",
279
- fn: withCtx(() => [
280
- renderSlot(_ctx.$slots, item.slot || item.name, { item })
285
+ return openBlock(), createElementBlock(Fragment, null, [
286
+ (item.vIf == null ? true : item.vIf) ? (openBlock(), createBlock(_component_ElTabPane, mergeProps({
287
+ key: index2 + "-" + item.name + "-" + item.label,
288
+ ref_for: true
289
+ }, _ctx.omit(item, ["slot", "meta", "vIf"])), createSlots({
290
+ label: withCtx(() => [
291
+ createVNode(_component_TabTitle, {
292
+ ref_for: true,
293
+ ref: "itemRefs",
294
+ item,
295
+ label: item.label,
296
+ tabName: item.name,
297
+ active: _ctx.modelValue,
298
+ handleClick: _ctx.handleClick,
299
+ contextMenu: _ctx.contextMenu,
300
+ contextMenus: _ctx.getContextMenus(item),
301
+ onContextMenu: _ctx.handleItemContextMenu,
302
+ onContextOpen: _ctx.handleItemContextOpen,
303
+ onItemClick: _ctx.handleItemClick
304
+ }, createSlots({ _: 2 }, [
305
+ _ctx.$slots.label ? {
306
+ name: "label",
307
+ fn: withCtx((slotProps) => [
308
+ renderSlot(_ctx.$slots, "label", mergeProps({ ref_for: true }, slotProps || {}))
309
+ ]),
310
+ key: "0"
311
+ } : void 0,
312
+ _ctx.$slots.contextMenu ? {
313
+ name: "contextMenu",
314
+ fn: withCtx((slotProps) => [
315
+ renderSlot(_ctx.$slots, "contextMenu", mergeProps({ ref_for: true }, slotProps || {}))
316
+ ]),
317
+ key: "1"
318
+ } : void 0
319
+ ]), 1032, ["item", "label", "tabName", "active", "handleClick", "contextMenu", "contextMenus", "onContextMenu", "onContextOpen", "onItemClick"])
281
320
  ]),
282
- key: "0"
283
- } : void 0
284
- ]), 1040);
285
- }), 128))
321
+ _: 2
322
+ }, [
323
+ item.name && _ctx.$slots[item.slot || item.name] ? {
324
+ name: "default",
325
+ fn: withCtx(() => [
326
+ renderSlot(_ctx.$slots, item.slot || item.name, { item })
327
+ ]),
328
+ key: "0"
329
+ } : void 0
330
+ ]), 1040)) : createCommentVNode("", true)
331
+ ], 64);
332
+ }), 256))
286
333
  ]),
287
334
  _: 2
288
335
  }, [
@@ -29,22 +29,24 @@ export declare const tabsProps: {
29
29
  mousewheel: BooleanConstructor;
30
30
  /** 是否自己处理页签点击事件 */
31
31
  handleClick: BooleanConstructor;
32
+ /** 内部表格是否弹性布局 */
33
+ flexTable: BooleanConstructor;
32
34
  closable: BooleanConstructor;
33
35
  addable: BooleanConstructor;
34
36
  modelValue: {
35
- readonly type: PropType<import('element-plus/es/utils/index').EpPropMergeType<readonly [StringConstructor, NumberConstructor], unknown, unknown>>;
37
+ readonly type: import('vue').PropType<import('element-plus/es/utils/index').EpPropMergeType<readonly [StringConstructor, NumberConstructor], unknown, unknown>>;
36
38
  readonly required: false;
37
39
  readonly validator: ((val: unknown) => boolean) | undefined;
38
40
  __epPropKey: true;
39
41
  };
40
42
  editable: BooleanConstructor;
41
- tabPosition: import('element-plus/es/utils/index').EpPropFinalized<StringConstructor, "top" | "bottom" | "right" | "left", unknown, "top", boolean>;
42
- beforeLeave: import('element-plus/es/utils/index').EpPropFinalized<(new (...args: any[]) => (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | (() => (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | {
43
- (): (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>;
43
+ tabPosition: import('element-plus/es/utils/index').EpPropFinalized<StringConstructor, "top" | "bottom" | "left" | "right", unknown, "top", boolean>;
44
+ beforeLeave: import('element-plus/es/utils/index').EpPropFinalized<(new (...args: any[]) => (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | (() => (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | {
45
+ (): (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>;
44
46
  new (): any;
45
47
  readonly prototype: any;
46
- } | ((new (...args: any[]) => (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | (() => (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>) | {
47
- (): (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<boolean | void>;
48
+ } | ((new (...args: any[]) => (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | (() => (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>) | {
49
+ (): (newName: import('element-plus').TabPaneName, oldName: import('element-plus').TabPaneName) => import('element-plus/es/utils/typescript').Awaitable<void | boolean>;
48
50
  new (): any;
49
51
  readonly prototype: any;
50
52
  })[], unknown, unknown, () => true, boolean>;
@@ -64,25 +66,9 @@ export declare const tabsEmits: {
64
66
  /** 拖动排序改变事件 */
65
67
  tabSortChange: (_data: TabPaneItem[]) => boolean;
66
68
  "update:modelValue": (name: import('element-plus').TabPaneName) => boolean;
67
- tabClick: (pane: {
68
- uid: number;
69
- slots: Readonly<{
70
- [name: string]: import('vue').Slot<any> | undefined;
71
- }>;
72
- props: {
73
- readonly closable: boolean;
74
- readonly disabled: boolean;
75
- readonly label: string;
76
- readonly lazy: boolean;
77
- readonly name?: import('element-plus/es/utils/index').EpPropMergeType<readonly [StringConstructor, NumberConstructor], unknown, unknown> | undefined;
78
- };
79
- paneName: string | number | undefined;
80
- active: boolean;
81
- index: string | undefined;
82
- isClosable: boolean;
83
- }, ev: Event) => boolean;
69
+ tabClick: (pane: import('element-plus').TabsPaneContext, ev: Event) => boolean;
84
70
  tabChange: (name: import('element-plus').TabPaneName) => boolean;
85
- edit: (paneName: import('element-plus').TabPaneName | undefined, action: "add" | "remove") => boolean;
71
+ edit: (paneName: import('element-plus').TabPaneName | undefined, action: "remove" | "add") => boolean;
86
72
  tabRemove: (name: import('element-plus').TabPaneName) => boolean;
87
73
  tabAdd: () => boolean;
88
74
  };
@@ -21,7 +21,9 @@ const tabsProps = {
21
21
  /** 是否支持鼠标滚轮滑动 */
22
22
  mousewheel: Boolean,
23
23
  /** 是否自己处理页签点击事件 */
24
- handleClick: Boolean
24
+ handleClick: Boolean,
25
+ /** 内部表格是否弹性布局 */
26
+ flexTable: Boolean
25
27
  };
26
28
  const tabsEmits = {
27
29
  ...tabsEmits$1,
@@ -6,6 +6,7 @@
6
6
 
7
7
  /* 标签页 */
8
8
  .ele-tabs.el-tabs > .el-tabs__header {
9
+ flex-shrink: 0;
9
10
  margin: 0;
10
11
 
11
12
  .el-tabs__nav-wrap {
@@ -122,8 +123,14 @@
122
123
  }
123
124
 
124
125
  /* 拖动 */
125
- .el-tabs__item.sortable-ghost {
126
- opacity: 0;
126
+ .el-tabs__item {
127
+ &.sortable-chosen {
128
+ user-select: none;
129
+ }
130
+
131
+ &.sortable-ghost {
132
+ opacity: 0;
133
+ }
127
134
  }
128
135
 
129
136
  /* 左右箭头 */
@@ -1056,3 +1063,36 @@
1056
1063
  }
1057
1064
  }
1058
1065
  }
1066
+
1067
+ /* 内部表格高度铺满 */
1068
+ .ele-tabs.is-flex-table {
1069
+ flex: 1;
1070
+ display: flex;
1071
+ flex-direction: column;
1072
+ overflow: auto;
1073
+
1074
+ & > .el-tabs__content {
1075
+ flex: 1;
1076
+ overflow: auto;
1077
+
1078
+ & > .el-tab-pane {
1079
+ height: 100%;
1080
+ display: flex;
1081
+ flex-direction: column;
1082
+ box-sizing: border-box;
1083
+
1084
+ & > .ele-pro-table {
1085
+ flex: 1;
1086
+ display: flex;
1087
+ flex-direction: column;
1088
+ overflow: auto;
1089
+
1090
+ & > .ele-pro-table-view {
1091
+ flex: 1;
1092
+ height: 100%;
1093
+ overflow: hidden;
1094
+ }
1095
+ }
1096
+ }
1097
+ }
1098
+ }
@@ -1,4 +1,3 @@
1
- import type SortableJs from 'sortablejs';
2
1
  import type { ElTabPaneProps } from '../ele-app/el';
3
2
  import type { DropdownItem } from '../ele-dropdown/types';
4
3
 
@@ -10,6 +9,8 @@ export interface TabPaneItem extends ElTabPaneProps {
10
9
  slot?: string;
11
10
  /** 元数据 */
12
11
  meta?: any;
12
+ /** 显示条件 */
13
+ vIf?: any;
13
14
  }
14
15
 
15
16
  /**
@@ -54,16 +55,6 @@ export type ContextMenusFunc = (item?: TabPaneItem) => DropdownItem[];
54
55
  */
55
56
  export type ContextMenus = DropdownItem[] | ContextMenusFunc;
56
57
 
57
- /**
58
- * 页签实例数据
59
- */
60
- export interface TabCurrent {
61
- /** 拖拽排序实例 */
62
- sortIns?: SortableJs | null;
63
- /** 鼠标滚轮事件节流 */
64
- isScroll?: boolean;
65
- }
66
-
67
58
  /**
68
59
  * 标签页容器属性
69
60
  */
@@ -11,7 +11,7 @@ declare const _default: import('vue').DefineComponent<{
11
11
  italic: BooleanConstructor;
12
12
  icon: import('vue').PropType<import('./types').TextIcon>;
13
13
  iconProps: import('vue').PropType<import('../ele-app/el').ElIconProps>;
14
- iconStyle: import('vue').PropType<Partial<import('vue').CSSProperties>>;
14
+ iconStyle: import('vue').PropType<import('../ele-app/types').StyleValue>;
15
15
  }, unknown, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
16
16
  tag: {
17
17
  type: StringConstructor;
@@ -25,7 +25,7 @@ declare const _default: import('vue').DefineComponent<{
25
25
  italic: BooleanConstructor;
26
26
  icon: import('vue').PropType<import('./types').TextIcon>;
27
27
  iconProps: import('vue').PropType<import('../ele-app/el').ElIconProps>;
28
- iconStyle: import('vue').PropType<Partial<import('vue').CSSProperties>>;
28
+ iconStyle: import('vue').PropType<import('../ele-app/types').StyleValue>;
29
29
  }>>, {
30
30
  tag: string;
31
31
  underline: boolean;
@@ -1,4 +1,5 @@
1
1
  import { PropType, ExtractPropTypes } from 'vue';
2
+ import { StyleValue } from '../ele-app/types';
2
3
  import { ElIconProps } from '../ele-app/el';
3
4
  import { TextType, TextSize, TextIcon } from './types';
4
5
 
@@ -28,7 +29,7 @@ export declare const textProps: {
28
29
  /** 图标属性 */
29
30
  iconProps: PropType<ElIconProps>;
30
31
  /** 图标样式 */
31
- iconStyle: PropType<Partial<import('vue').CSSProperties>>;
32
+ iconStyle: PropType<StyleValue>;
32
33
  };
33
34
  export type TextProps = ExtractPropTypes<typeof textProps>;
34
35
  export type TextPropKeys = Array<keyof typeof textProps>;