vxe-table 4.3.4 → 4.3.6-beta.0

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 (521) hide show
  1. package/es/button/style.css +465 -341
  2. package/es/checkbox/style.css +156 -127
  3. package/es/checkbox-group/style.css +1 -1
  4. package/es/colgroup/style.css +1 -1
  5. package/es/column/style.css +1 -1
  6. package/es/edit/style.css +1 -1
  7. package/es/export/src/hook.js +1 -0
  8. package/es/export/style.css +136 -108
  9. package/es/filter/src/hook.js +1 -1
  10. package/es/filter/style.css +103 -82
  11. package/es/footer/src/footer.js +3 -3
  12. package/es/form/src/form.js +5 -4
  13. package/es/form/style.css +201 -168
  14. package/es/form-gather/style.css +1 -1
  15. package/es/form-item/style.css +1 -1
  16. package/es/grid/style.css +61 -50
  17. package/es/header/src/header.js +10 -5
  18. package/es/icon/style/iconfont.1669214286403.ttf +0 -0
  19. package/es/icon/style/iconfont.1669214286403.woff +0 -0
  20. package/es/icon/style/iconfont.1669214286403.woff2 +0 -0
  21. package/es/icon/style.css +406 -178
  22. package/es/iconfont.1669214286403.ttf +0 -0
  23. package/es/iconfont.1669214286403.woff +0 -0
  24. package/es/iconfont.1669214286403.woff2 +0 -0
  25. package/es/input/style.css +771 -595
  26. package/es/keyboard/style.css +1 -1
  27. package/es/list/src/list.js +7 -1
  28. package/es/list/style.css +19 -14
  29. package/es/loading/style.css +52 -48
  30. package/es/locale/lang/en-US.js +0 -1
  31. package/es/locale/lang/ja-JP.js +0 -1
  32. package/es/locale/lang/zh-CN.js +0 -1
  33. package/es/locale/lang/zh-TC.js +0 -1
  34. package/es/menu/style.css +79 -59
  35. package/es/modal/style.css +311 -247
  36. package/es/optgroup/style.css +1 -1
  37. package/es/option/style.css +1 -1
  38. package/es/pager/style.css +307 -257
  39. package/es/pulldown/src/pulldown.js +9 -3
  40. package/es/pulldown/style.css +42 -31
  41. package/es/radio/style.css +184 -151
  42. package/es/radio-button/style.css +1 -1
  43. package/es/radio-group/style.css +1 -1
  44. package/es/select/style.css +108 -79
  45. package/es/style.css +1 -1
  46. package/es/style.min.css +1 -1
  47. package/es/switch/style.css +87 -67
  48. package/es/table/src/column.js +2 -0
  49. package/es/table/src/columnInfo.js +1 -0
  50. package/es/table/src/table.js +36 -40
  51. package/es/table/style.css +1025 -835
  52. package/es/textarea/style.css +57 -41
  53. package/es/toolbar/style.css +216 -174
  54. package/es/tools/log.js +1 -1
  55. package/es/tooltip/style.css +87 -63
  56. package/es/v-x-e-table/index.js +1 -1
  57. package/es/v-x-e-table/style.css +458 -226
  58. package/es/validator/style.css +1 -1
  59. package/es/vxe-button/style.css +465 -341
  60. package/es/vxe-checkbox/style.css +156 -127
  61. package/es/vxe-checkbox-group/style.css +1 -1
  62. package/es/vxe-colgroup/style.css +1 -1
  63. package/es/vxe-column/style.css +1 -1
  64. package/es/vxe-form/style.css +201 -168
  65. package/es/vxe-form-gather/style.css +1 -1
  66. package/es/vxe-form-item/style.css +1 -1
  67. package/es/vxe-grid/style.css +61 -50
  68. package/es/vxe-icon/style.css +406 -178
  69. package/es/vxe-input/style.css +771 -595
  70. package/es/vxe-list/style.css +19 -14
  71. package/es/vxe-loading/style.css +52 -48
  72. package/es/vxe-modal/style.css +311 -247
  73. package/es/vxe-module-edit/style.css +1 -1
  74. package/es/vxe-module-export/style.css +136 -108
  75. package/es/vxe-module-filter/style.css +103 -82
  76. package/es/vxe-module-keyboard/style.css +1 -1
  77. package/es/vxe-module-menu/style.css +79 -59
  78. package/es/vxe-module-validator/style.css +1 -1
  79. package/es/vxe-optgroup/style.css +1 -1
  80. package/es/vxe-option/style.css +1 -1
  81. package/es/vxe-pager/style.css +307 -257
  82. package/es/vxe-pulldown/style.css +42 -31
  83. package/es/vxe-radio/style.css +184 -151
  84. package/es/vxe-radio-button/style.css +1 -1
  85. package/es/vxe-radio-group/style.css +1 -1
  86. package/es/vxe-select/style.css +108 -79
  87. package/es/vxe-switch/style.css +87 -67
  88. package/es/vxe-table/style.css +1025 -835
  89. package/es/vxe-textarea/style.css +57 -41
  90. package/es/vxe-toolbar/style.css +216 -174
  91. package/es/vxe-tooltip/style.css +87 -63
  92. package/lib/all.js +45 -115
  93. package/lib/all.min.js +1 -1
  94. package/lib/button/index.js +1 -7
  95. package/lib/button/index.min.js +1 -1
  96. package/lib/button/src/button.js +48 -113
  97. package/lib/button/src/button.min.js +1 -1
  98. package/lib/button/style/style.css +465 -341
  99. package/lib/button/style/style.min.css +1 -1
  100. package/lib/checkbox/index.js +1 -7
  101. package/lib/checkbox/index.min.js +1 -1
  102. package/lib/checkbox/src/checkbox.js +12 -32
  103. package/lib/checkbox/src/checkbox.min.js +1 -1
  104. package/lib/checkbox/src/group.js +13 -28
  105. package/lib/checkbox/src/group.min.js +1 -1
  106. package/lib/checkbox/style/style.css +156 -127
  107. package/lib/checkbox/style/style.min.css +1 -1
  108. package/lib/checkbox-group/index.js +1 -7
  109. package/lib/checkbox-group/index.min.js +1 -1
  110. package/lib/checkbox-group/style/style.css +1 -1
  111. package/lib/colgroup/index.js +5 -12
  112. package/lib/colgroup/index.min.js +1 -1
  113. package/lib/colgroup/style/style.css +1 -1
  114. package/lib/column/index.js +5 -12
  115. package/lib/column/index.min.js +1 -1
  116. package/lib/column/style/style.css +1 -1
  117. package/lib/dynamics/index.js +1 -5
  118. package/lib/dynamics/index.min.js +1 -1
  119. package/lib/edit/index.js +1 -5
  120. package/lib/edit/index.min.js +1 -1
  121. package/lib/edit/src/hook.js +102 -248
  122. package/lib/edit/src/hook.min.js +1 -1
  123. package/lib/edit/style/style.css +1 -1
  124. package/lib/export/index.js +4 -19
  125. package/lib/export/index.min.js +1 -1
  126. package/lib/export/src/export-panel.js +38 -77
  127. package/lib/export/src/export-panel.min.js +1 -1
  128. package/lib/export/src/hook.js +127 -380
  129. package/lib/export/src/hook.min.js +1 -1
  130. package/lib/export/src/import-panel.js +17 -39
  131. package/lib/export/src/import-panel.min.js +1 -1
  132. package/lib/export/src/util.js +10 -52
  133. package/lib/export/src/util.min.js +1 -1
  134. package/lib/export/style/style.css +136 -108
  135. package/lib/export/style/style.min.css +1 -1
  136. package/lib/filter/index.js +1 -10
  137. package/lib/filter/index.min.js +1 -1
  138. package/lib/filter/src/hook.js +31 -82
  139. package/lib/filter/src/hook.min.js +1 -1
  140. package/lib/filter/src/panel.js +25 -52
  141. package/lib/filter/src/panel.min.js +1 -1
  142. package/lib/filter/style/style.css +103 -82
  143. package/lib/filter/style/style.min.css +1 -1
  144. package/lib/footer/index.js +1 -7
  145. package/lib/footer/index.min.js +1 -1
  146. package/lib/footer/src/footer.js +54 -99
  147. package/lib/footer/src/footer.min.js +1 -1
  148. package/lib/form/index.js +1 -7
  149. package/lib/form/index.min.js +1 -1
  150. package/lib/form/src/form-config-item.js +27 -56
  151. package/lib/form/src/form-config-item.min.js +1 -1
  152. package/lib/form/src/form-gather.js +3 -12
  153. package/lib/form/src/form-gather.min.js +1 -1
  154. package/lib/form/src/form-item.js +23 -52
  155. package/lib/form/src/form-item.min.js +1 -1
  156. package/lib/form/src/form.js +78 -185
  157. package/lib/form/src/form.min.js +1 -1
  158. package/lib/form/src/itemInfo.js +1 -9
  159. package/lib/form/src/render.js +7 -26
  160. package/lib/form/src/render.min.js +1 -1
  161. package/lib/form/src/util.js +4 -28
  162. package/lib/form/src/util.min.js +1 -1
  163. package/lib/form/style/style.css +201 -168
  164. package/lib/form/style/style.min.css +1 -1
  165. package/lib/form-gather/index.js +1 -7
  166. package/lib/form-gather/index.min.js +1 -1
  167. package/lib/form-gather/style/style.css +1 -1
  168. package/lib/form-item/index.js +1 -7
  169. package/lib/form-item/index.min.js +1 -1
  170. package/lib/form-item/style/style.css +1 -1
  171. package/lib/grid/index.js +1 -7
  172. package/lib/grid/index.min.js +1 -1
  173. package/lib/grid/src/grid.js +97 -315
  174. package/lib/grid/src/grid.min.js +1 -1
  175. package/lib/grid/style/style.css +61 -50
  176. package/lib/grid/style/style.min.css +1 -1
  177. package/lib/header/index.js +1 -7
  178. package/lib/header/index.min.js +1 -1
  179. package/lib/header/src/header.js +57 -92
  180. package/lib/header/src/header.min.js +1 -1
  181. package/lib/header/src/util.js +3 -14
  182. package/lib/header/src/util.min.js +1 -1
  183. package/lib/hooks/size.js +0 -2
  184. package/lib/icon/index.js +1 -7
  185. package/lib/icon/index.min.js +1 -1
  186. package/lib/icon/src/icon.js +2 -7
  187. package/lib/icon/style/iconfont.1669214286403.ttf +0 -0
  188. package/lib/icon/style/iconfont.1669214286403.woff +0 -0
  189. package/lib/icon/style/iconfont.1669214286403.woff2 +0 -0
  190. package/lib/icon/style/style.css +406 -178
  191. package/lib/icon/style/style.min.css +719 -1
  192. package/lib/iconfont.1669214286403.ttf +0 -0
  193. package/lib/iconfont.1669214286403.woff +0 -0
  194. package/lib/iconfont.1669214286403.woff2 +0 -0
  195. package/lib/index.common.js +3 -10
  196. package/lib/index.common.min.js +1 -1
  197. package/lib/index.umd.js +14514 -23890
  198. package/lib/index.umd.min.js +1 -1
  199. package/lib/input/index.js +1 -7
  200. package/lib/input/index.min.js +1 -1
  201. package/lib/input/src/date.js +0 -10
  202. package/lib/input/src/date.min.js +1 -1
  203. package/lib/input/src/input.js +217 -553
  204. package/lib/input/src/input.min.js +1 -1
  205. package/lib/input/src/number.js +0 -5
  206. package/lib/input/style/style.css +771 -595
  207. package/lib/input/style/style.min.css +1 -1
  208. package/lib/keyboard/index.js +1 -5
  209. package/lib/keyboard/index.min.js +1 -1
  210. package/lib/keyboard/src/hook.js +40 -106
  211. package/lib/keyboard/src/hook.min.js +1 -1
  212. package/lib/keyboard/style/style.css +1 -1
  213. package/lib/list/index.js +1 -7
  214. package/lib/list/index.min.js +1 -1
  215. package/lib/list/src/list.js +39 -91
  216. package/lib/list/src/list.min.js +1 -1
  217. package/lib/list/style/style.css +19 -14
  218. package/lib/loading/index.js +1 -4
  219. package/lib/loading/index.min.js +1 -1
  220. package/lib/loading/src/loading.js +1 -6
  221. package/lib/loading/style/style.css +52 -48
  222. package/lib/loading/style/style.min.css +1 -1
  223. package/lib/locale/lang/en-US.js +0 -1
  224. package/lib/locale/lang/en-US.min.js +1 -1
  225. package/lib/locale/lang/en-US.umd.js +0 -1
  226. package/lib/locale/lang/ja-JP.js +0 -1
  227. package/lib/locale/lang/ja-JP.min.js +1 -1
  228. package/lib/locale/lang/ja-JP.umd.js +0 -1
  229. package/lib/locale/lang/zh-CN.js +0 -1
  230. package/lib/locale/lang/zh-CN.min.js +1 -1
  231. package/lib/locale/lang/zh-CN.umd.js +0 -1
  232. package/lib/locale/lang/zh-HK.js +0 -3
  233. package/lib/locale/lang/zh-HK.min.js +1 -1
  234. package/lib/locale/lang/zh-HK.umd.js +0 -1
  235. package/lib/locale/lang/zh-MO.js +0 -3
  236. package/lib/locale/lang/zh-MO.min.js +1 -1
  237. package/lib/locale/lang/zh-MO.umd.js +0 -1
  238. package/lib/locale/lang/zh-TC.js +0 -1
  239. package/lib/locale/lang/zh-TC.min.js +1 -1
  240. package/lib/locale/lang/zh-TC.umd.js +0 -1
  241. package/lib/locale/lang/zh-TW.js +0 -3
  242. package/lib/locale/lang/zh-TW.min.js +1 -1
  243. package/lib/locale/lang/zh-TW.umd.js +0 -1
  244. package/lib/menu/index.js +1 -10
  245. package/lib/menu/index.min.js +1 -1
  246. package/lib/menu/src/hooks.js +45 -109
  247. package/lib/menu/src/hooks.min.js +1 -1
  248. package/lib/menu/src/panel.js +10 -19
  249. package/lib/menu/src/panel.min.js +1 -1
  250. package/lib/menu/style/style.css +79 -59
  251. package/lib/menu/style/style.min.css +1 -1
  252. package/lib/modal/index.js +5 -36
  253. package/lib/modal/index.min.js +1 -1
  254. package/lib/modal/src/modal.js +128 -315
  255. package/lib/modal/src/modal.min.js +1 -1
  256. package/lib/modal/style/style.css +311 -247
  257. package/lib/modal/style/style.min.css +1 -1
  258. package/lib/optgroup/index.js +1 -7
  259. package/lib/optgroup/index.min.js +1 -1
  260. package/lib/optgroup/style/style.css +1 -1
  261. package/lib/option/index.js +1 -7
  262. package/lib/option/index.min.js +1 -1
  263. package/lib/option/style/style.css +1 -1
  264. package/lib/pager/index.js +1 -7
  265. package/lib/pager/index.min.js +1 -1
  266. package/lib/pager/src/pager.js +74 -151
  267. package/lib/pager/src/pager.min.js +1 -1
  268. package/lib/pager/style/style.css +307 -257
  269. package/lib/pager/style/style.min.css +1 -1
  270. package/lib/pulldown/index.js +1 -7
  271. package/lib/pulldown/index.min.js +1 -1
  272. package/lib/pulldown/src/pulldown.js +46 -90
  273. package/lib/pulldown/src/pulldown.min.js +1 -1
  274. package/lib/pulldown/style/style.css +42 -31
  275. package/lib/pulldown/style/style.min.css +1 -1
  276. package/lib/radio/index.js +1 -7
  277. package/lib/radio/index.min.js +1 -1
  278. package/lib/radio/src/button.js +14 -32
  279. package/lib/radio/src/button.min.js +1 -1
  280. package/lib/radio/src/group.js +11 -22
  281. package/lib/radio/src/group.min.js +1 -1
  282. package/lib/radio/src/radio.js +15 -34
  283. package/lib/radio/src/radio.min.js +1 -1
  284. package/lib/radio/style/style.css +184 -151
  285. package/lib/radio/style/style.min.css +1 -1
  286. package/lib/radio-button/index.js +1 -7
  287. package/lib/radio-button/index.min.js +1 -1
  288. package/lib/radio-button/style/style.css +1 -1
  289. package/lib/radio-group/index.js +1 -7
  290. package/lib/radio-group/index.min.js +1 -1
  291. package/lib/radio-group/style/style.css +1 -1
  292. package/lib/select/index.js +1 -7
  293. package/lib/select/index.min.js +1 -1
  294. package/lib/select/src/optgroup.js +1 -5
  295. package/lib/select/src/option.js +1 -5
  296. package/lib/select/src/optionInfo.js +1 -9
  297. package/lib/select/src/select.js +103 -256
  298. package/lib/select/src/select.min.js +1 -1
  299. package/lib/select/src/util.js +0 -13
  300. package/lib/select/src/util.min.js +1 -1
  301. package/lib/select/style/style.css +108 -79
  302. package/lib/select/style/style.min.css +1 -1
  303. package/lib/style.css +1 -1
  304. package/lib/style.min.css +1 -1
  305. package/lib/switch/index.js +1 -7
  306. package/lib/switch/index.min.js +1 -1
  307. package/lib/switch/src/switch.js +16 -35
  308. package/lib/switch/src/switch.min.js +1 -1
  309. package/lib/switch/style/style.css +87 -67
  310. package/lib/switch/style/style.min.css +1 -1
  311. package/lib/table/index.js +1 -7
  312. package/lib/table/index.min.js +1 -1
  313. package/lib/table/src/body.js +143 -262
  314. package/lib/table/src/body.min.js +1 -1
  315. package/lib/table/src/cell.js +138 -259
  316. package/lib/table/src/cell.min.js +1 -1
  317. package/lib/table/src/column.js +4 -13
  318. package/lib/table/src/column.min.js +1 -1
  319. package/lib/table/src/columnInfo.js +6 -35
  320. package/lib/table/src/columnInfo.min.js +1 -1
  321. package/lib/table/src/group.js +2 -15
  322. package/lib/table/src/group.min.js +1 -1
  323. package/lib/table/src/props.js +25 -29
  324. package/lib/table/src/props.min.js +1 -1
  325. package/lib/table/src/table.js +670 -1620
  326. package/lib/table/src/table.min.js +1 -1
  327. package/lib/table/src/util.js +32 -102
  328. package/lib/table/src/util.min.js +1 -1
  329. package/lib/table/style/style.css +1025 -835
  330. package/lib/table/style/style.min.css +1 -1
  331. package/lib/textarea/index.js +1 -7
  332. package/lib/textarea/index.min.js +1 -1
  333. package/lib/textarea/src/textarea.js +31 -71
  334. package/lib/textarea/src/textarea.min.js +1 -1
  335. package/lib/textarea/style/style.css +57 -41
  336. package/lib/textarea/style/style.min.css +1 -1
  337. package/lib/toolbar/index.js +1 -7
  338. package/lib/toolbar/index.min.js +1 -1
  339. package/lib/toolbar/src/toolbar.js +60 -167
  340. package/lib/toolbar/src/toolbar.min.js +1 -1
  341. package/lib/toolbar/style/style.css +216 -174
  342. package/lib/toolbar/style/style.min.css +1 -1
  343. package/lib/tools/dom.js +6 -48
  344. package/lib/tools/dom.min.js +1 -1
  345. package/lib/tools/event.js +8 -20
  346. package/lib/tools/event.min.js +1 -1
  347. package/lib/tools/log.js +1 -6
  348. package/lib/tools/log.min.js +1 -1
  349. package/lib/tools/resize.js +3 -27
  350. package/lib/tools/utils.js +0 -16
  351. package/lib/tools/utils.min.js +1 -1
  352. package/lib/tools/vn.js +0 -5
  353. package/lib/tooltip/index.js +1 -8
  354. package/lib/tooltip/index.min.js +1 -1
  355. package/lib/tooltip/src/tooltip.js +47 -111
  356. package/lib/tooltip/src/tooltip.min.js +1 -1
  357. package/lib/tooltip/style/style.css +87 -63
  358. package/lib/v-x-e-table/index.js +13 -44
  359. package/lib/v-x-e-table/index.min.js +1 -1
  360. package/lib/v-x-e-table/src/commands.js +0 -4
  361. package/lib/v-x-e-table/src/conf.js +31 -19
  362. package/lib/v-x-e-table/src/formats.js +0 -4
  363. package/lib/v-x-e-table/src/hooks.js +0 -3
  364. package/lib/v-x-e-table/src/interceptor.js +6 -18
  365. package/lib/v-x-e-table/src/interceptor.min.js +1 -1
  366. package/lib/v-x-e-table/src/menus.js +0 -4
  367. package/lib/v-x-e-table/src/renderer.js +66 -199
  368. package/lib/v-x-e-table/src/renderer.min.js +1 -1
  369. package/lib/v-x-e-table/src/setup.js +1 -6
  370. package/lib/v-x-e-table/src/store.js +3 -19
  371. package/lib/v-x-e-table/style/style.css +458 -226
  372. package/lib/v-x-e-table/style/style.min.css +1 -1
  373. package/lib/validator/index.js +1 -5
  374. package/lib/validator/index.min.js +1 -1
  375. package/lib/validator/src/hook.js +50 -116
  376. package/lib/validator/src/hook.min.js +1 -1
  377. package/lib/validator/style/style.css +1 -1
  378. package/lib/vxe-button/index.js +3 -10
  379. package/lib/vxe-button/index.min.js +1 -1
  380. package/lib/vxe-button/style/style.css +465 -341
  381. package/lib/vxe-button/style/style.min.css +1 -1
  382. package/lib/vxe-checkbox/index.js +3 -10
  383. package/lib/vxe-checkbox/index.min.js +1 -1
  384. package/lib/vxe-checkbox/style/style.css +156 -127
  385. package/lib/vxe-checkbox/style/style.min.css +1 -1
  386. package/lib/vxe-checkbox-group/index.js +3 -10
  387. package/lib/vxe-checkbox-group/index.min.js +1 -1
  388. package/lib/vxe-checkbox-group/style/style.css +1 -1
  389. package/lib/vxe-colgroup/index.js +3 -10
  390. package/lib/vxe-colgroup/index.min.js +1 -1
  391. package/lib/vxe-colgroup/style/style.css +1 -1
  392. package/lib/vxe-column/index.js +3 -10
  393. package/lib/vxe-column/index.min.js +1 -1
  394. package/lib/vxe-column/style/style.css +1 -1
  395. package/lib/vxe-form/index.js +3 -10
  396. package/lib/vxe-form/index.min.js +1 -1
  397. package/lib/vxe-form/style/style.css +201 -168
  398. package/lib/vxe-form/style/style.min.css +1 -1
  399. package/lib/vxe-form-gather/index.js +3 -10
  400. package/lib/vxe-form-gather/index.min.js +1 -1
  401. package/lib/vxe-form-gather/style/style.css +1 -1
  402. package/lib/vxe-form-item/index.js +3 -10
  403. package/lib/vxe-form-item/index.min.js +1 -1
  404. package/lib/vxe-form-item/style/style.css +1 -1
  405. package/lib/vxe-grid/index.js +3 -10
  406. package/lib/vxe-grid/index.min.js +1 -1
  407. package/lib/vxe-grid/style/style.css +61 -50
  408. package/lib/vxe-grid/style/style.min.css +1 -1
  409. package/lib/vxe-icon/index.js +3 -10
  410. package/lib/vxe-icon/index.min.js +1 -1
  411. package/lib/vxe-icon/style/style.css +406 -178
  412. package/lib/vxe-icon/style/style.min.css +1 -1
  413. package/lib/vxe-input/index.js +3 -10
  414. package/lib/vxe-input/index.min.js +1 -1
  415. package/lib/vxe-input/style/style.css +771 -595
  416. package/lib/vxe-input/style/style.min.css +1 -1
  417. package/lib/vxe-list/index.js +3 -10
  418. package/lib/vxe-list/index.min.js +1 -1
  419. package/lib/vxe-list/style/style.css +19 -14
  420. package/lib/vxe-loading/index.js +3 -10
  421. package/lib/vxe-loading/index.min.js +1 -1
  422. package/lib/vxe-loading/style/style.css +52 -48
  423. package/lib/vxe-loading/style/style.min.css +1 -1
  424. package/lib/vxe-modal/index.js +3 -10
  425. package/lib/vxe-modal/index.min.js +1 -1
  426. package/lib/vxe-modal/style/style.css +311 -247
  427. package/lib/vxe-modal/style/style.min.css +1 -1
  428. package/lib/vxe-module-edit/index.js +3 -10
  429. package/lib/vxe-module-edit/index.min.js +1 -1
  430. package/lib/vxe-module-edit/style/style.css +1 -1
  431. package/lib/vxe-module-export/index.js +3 -10
  432. package/lib/vxe-module-export/index.min.js +1 -1
  433. package/lib/vxe-module-export/style/style.css +136 -108
  434. package/lib/vxe-module-export/style/style.min.css +1 -1
  435. package/lib/vxe-module-filter/index.js +3 -10
  436. package/lib/vxe-module-filter/index.min.js +1 -1
  437. package/lib/vxe-module-filter/style/style.css +103 -82
  438. package/lib/vxe-module-filter/style/style.min.css +1 -1
  439. package/lib/vxe-module-keyboard/index.js +3 -10
  440. package/lib/vxe-module-keyboard/index.min.js +1 -1
  441. package/lib/vxe-module-keyboard/style/style.css +1 -1
  442. package/lib/vxe-module-menu/index.js +3 -10
  443. package/lib/vxe-module-menu/index.min.js +1 -1
  444. package/lib/vxe-module-menu/style/style.css +79 -59
  445. package/lib/vxe-module-menu/style/style.min.css +1 -1
  446. package/lib/vxe-module-validator/index.js +3 -10
  447. package/lib/vxe-module-validator/index.min.js +1 -1
  448. package/lib/vxe-module-validator/style/style.css +1 -1
  449. package/lib/vxe-optgroup/index.js +3 -10
  450. package/lib/vxe-optgroup/index.min.js +1 -1
  451. package/lib/vxe-optgroup/style/style.css +1 -1
  452. package/lib/vxe-option/index.js +3 -10
  453. package/lib/vxe-option/index.min.js +1 -1
  454. package/lib/vxe-option/style/style.css +1 -1
  455. package/lib/vxe-pager/index.js +3 -10
  456. package/lib/vxe-pager/index.min.js +1 -1
  457. package/lib/vxe-pager/style/style.css +307 -257
  458. package/lib/vxe-pager/style/style.min.css +1 -1
  459. package/lib/vxe-pulldown/index.js +3 -10
  460. package/lib/vxe-pulldown/index.min.js +1 -1
  461. package/lib/vxe-pulldown/style/style.css +42 -31
  462. package/lib/vxe-pulldown/style/style.min.css +1 -1
  463. package/lib/vxe-radio/index.js +3 -10
  464. package/lib/vxe-radio/index.min.js +1 -1
  465. package/lib/vxe-radio/style/style.css +184 -151
  466. package/lib/vxe-radio/style/style.min.css +1 -1
  467. package/lib/vxe-radio-button/index.js +3 -10
  468. package/lib/vxe-radio-button/index.min.js +1 -1
  469. package/lib/vxe-radio-button/style/style.css +1 -1
  470. package/lib/vxe-radio-group/index.js +3 -10
  471. package/lib/vxe-radio-group/index.min.js +1 -1
  472. package/lib/vxe-radio-group/style/style.css +1 -1
  473. package/lib/vxe-select/index.js +3 -10
  474. package/lib/vxe-select/index.min.js +1 -1
  475. package/lib/vxe-select/style/style.css +108 -79
  476. package/lib/vxe-select/style/style.min.css +1 -1
  477. package/lib/vxe-switch/index.js +3 -10
  478. package/lib/vxe-switch/index.min.js +1 -1
  479. package/lib/vxe-switch/style/style.css +87 -67
  480. package/lib/vxe-switch/style/style.min.css +1 -1
  481. package/lib/vxe-table/index.js +3 -10
  482. package/lib/vxe-table/index.min.js +1 -1
  483. package/lib/vxe-table/style/style.css +1025 -835
  484. package/lib/vxe-table/style/style.min.css +1 -1
  485. package/lib/vxe-textarea/index.js +3 -10
  486. package/lib/vxe-textarea/index.min.js +1 -1
  487. package/lib/vxe-textarea/style/style.css +57 -41
  488. package/lib/vxe-textarea/style/style.min.css +1 -1
  489. package/lib/vxe-toolbar/index.js +3 -10
  490. package/lib/vxe-toolbar/index.min.js +1 -1
  491. package/lib/vxe-toolbar/style/style.css +216 -174
  492. package/lib/vxe-toolbar/style/style.min.css +1 -1
  493. package/lib/vxe-tooltip/index.js +3 -10
  494. package/lib/vxe-tooltip/index.min.js +1 -1
  495. package/lib/vxe-tooltip/style/style.css +87 -63
  496. package/package.json +27 -33
  497. package/packages/export/src/hook.ts +1 -0
  498. package/packages/filter/src/hook.ts +1 -1
  499. package/packages/footer/src/footer.ts +3 -3
  500. package/packages/form/src/form.ts +5 -4
  501. package/packages/header/src/header.ts +13 -9
  502. package/packages/list/src/list.ts +8 -2
  503. package/packages/locale/lang/en-US.ts +0 -1
  504. package/packages/locale/lang/ja-JP.ts +0 -1
  505. package/packages/locale/lang/zh-CN.ts +0 -1
  506. package/packages/locale/lang/zh-TC.ts +0 -1
  507. package/packages/pulldown/src/pulldown.ts +11 -5
  508. package/packages/table/src/column.ts +2 -0
  509. package/packages/table/src/columnInfo.ts +1 -0
  510. package/packages/table/src/table.ts +117 -113
  511. package/packages/table/src/util.ts +1 -1
  512. package/styles/icon/iconfont.ttf +0 -0
  513. package/styles/icon/iconfont.woff +0 -0
  514. package/styles/icon/iconfont.woff2 +0 -0
  515. package/styles/icon.scss +78 -2
  516. package/styles/table.scss +1 -1
  517. package/styles/variable.scss +2 -2
  518. package/types/column.d.ts +6 -1
  519. package/types/list.d.ts +4 -4
  520. package/types/pulldown.d.ts +61 -61
  521. package/types/table.d.ts +11 -1
@@ -4,24 +4,15 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.default = void 0;
7
-
8
7
  var _vue = require("vue");
9
-
10
8
  var _xeUtils = _interopRequireDefault(require("xe-utils"));
11
-
12
9
  var _conf = _interopRequireDefault(require("../../v-x-e-table/src/conf"));
13
-
14
10
  var _size = require("../../hooks/size");
15
-
16
11
  var _dom = require("../../tools/dom");
17
-
18
12
  var _utils = require("../../tools/utils");
19
-
20
13
  var _event = require("../../tools/event");
21
-
22
14
  function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }
23
-
24
- var _default2 = (0, _vue.defineComponent)({
15
+ var _default = (0, _vue.defineComponent)({
25
16
  name: 'VxeButton',
26
17
  props: {
27
18
  /**
@@ -29,84 +20,70 @@ var _default2 = (0, _vue.defineComponent)({
29
20
  */
30
21
  type: String,
31
22
  className: String,
32
-
33
23
  /**
34
24
  * 按钮尺寸
35
25
  */
36
26
  size: {
37
27
  type: String,
38
- default: function _default() {
28
+ default: function () {
39
29
  return _conf.default.button.size || _conf.default.size;
40
30
  }
41
31
  },
42
-
43
32
  /**
44
33
  * 用来标识这一项
45
34
  */
46
35
  name: [String, Number],
47
-
48
36
  /**
49
37
  * 按钮内容
50
38
  */
51
39
  content: String,
52
-
53
40
  /**
54
41
  * 固定显示下拉面板的方向
55
42
  */
56
43
  placement: String,
57
-
58
44
  /**
59
45
  * 按钮状态
60
46
  */
61
47
  status: String,
62
-
63
48
  /**
64
49
  * 按钮的图标
65
50
  */
66
51
  icon: String,
67
-
68
52
  /**
69
53
  * 圆角边框
70
54
  */
71
55
  round: Boolean,
72
-
73
56
  /**
74
57
  * 圆角按钮
75
58
  */
76
59
  circle: Boolean,
77
-
78
60
  /**
79
61
  * 是否禁用
80
62
  */
81
63
  disabled: Boolean,
82
-
83
64
  /**
84
65
  * 是否加载中
85
66
  */
86
67
  loading: Boolean,
87
-
88
68
  /**
89
69
  * 在下拉面板关闭时销毁内容
90
70
  */
91
71
  destroyOnClose: Boolean,
92
-
93
72
  /**
94
73
  * 是否将弹框容器插入于 body 内
95
74
  */
96
75
  transfer: {
97
76
  type: Boolean,
98
- default: function _default() {
77
+ default: function () {
99
78
  return _conf.default.button.transfer;
100
79
  }
101
80
  }
102
81
  },
103
82
  emits: ['click', 'dropdown-click'],
104
- setup: function setup(props, context) {
83
+ setup: function (props, context) {
105
84
  var slots = context.slots,
106
- emit = context.emit;
107
-
85
+ emit = context.emit;
108
86
  var xID = _xeUtils.default.uniqueId();
109
-
110
87
  var computeSize = (0, _size.useSize)(props);
111
88
  var reactData = (0, _vue.reactive)({
112
89
  inited: false,
@@ -131,39 +108,34 @@ var _default2 = (0, _vue.defineComponent)({
131
108
  context: context,
132
109
  reactData: reactData,
133
110
  internalData: internalData,
134
- getRefMaps: function getRefMaps() {
111
+ getRefMaps: function () {
135
112
  return refMaps;
136
113
  }
137
114
  };
138
115
  var buttonMethods = {};
139
116
  var computeIsFormBtn = (0, _vue.computed)(function () {
140
117
  var type = props.type;
141
-
142
118
  if (type) {
143
119
  return ['submit', 'reset', 'button'].indexOf(type) > -1;
144
120
  }
145
-
146
121
  return false;
147
122
  });
148
123
  var computeBtnType = (0, _vue.computed)(function () {
149
124
  var type = props.type;
150
125
  return type && type === 'text' ? type : 'button';
151
126
  });
152
-
153
- var updateZindex = function updateZindex() {
127
+ var updateZindex = function () {
154
128
  if (reactData.panelIndex < (0, _utils.getLastZIndex)()) {
155
129
  reactData.panelIndex = (0, _utils.nextZIndex)();
156
130
  }
157
131
  };
158
-
159
- var updatePlacement = function updatePlacement() {
132
+ var updatePlacement = function () {
160
133
  return (0, _vue.nextTick)().then(function () {
161
134
  var transfer = props.transfer,
162
- placement = props.placement;
135
+ placement = props.placement;
163
136
  var panelIndex = reactData.panelIndex;
164
137
  var targetElem = refButton.value;
165
138
  var panelElem = refBtnPanel.value;
166
-
167
139
  if (panelElem && targetElem) {
168
140
  var targetHeight = targetElem.offsetHeight;
169
141
  var targetWidth = targetElem.offsetWidth;
@@ -173,20 +145,16 @@ var _default2 = (0, _vue.defineComponent)({
173
145
  var panelStyle = {
174
146
  zIndex: panelIndex
175
147
  };
176
-
177
148
  var _a = (0, _dom.getAbsolutePos)(targetElem),
178
- top_1 = _a.top,
179
- left = _a.left,
180
- boundingTop = _a.boundingTop,
181
- visibleHeight = _a.visibleHeight,
182
- visibleWidth = _a.visibleWidth;
183
-
149
+ top_1 = _a.top,
150
+ left = _a.left,
151
+ boundingTop = _a.boundingTop,
152
+ visibleHeight = _a.visibleHeight,
153
+ visibleWidth = _a.visibleWidth;
184
154
  var panelPlacement = 'bottom';
185
-
186
155
  if (transfer) {
187
156
  var btnLeft = left + targetWidth - panelWidth;
188
157
  var btnTop = top_1 + targetHeight;
189
-
190
158
  if (placement === 'top') {
191
159
  panelPlacement = 'top';
192
160
  btnTop = top_1 - panelHeight;
@@ -195,25 +163,21 @@ var _default2 = (0, _vue.defineComponent)({
195
163
  if (boundingTop + targetHeight + panelHeight + marginSize > visibleHeight) {
196
164
  panelPlacement = 'top';
197
165
  btnTop = top_1 - panelHeight;
198
- } // 如果上面不够放,则向下(优先)
199
-
200
-
166
+ }
167
+ // 如果上面不够放,则向下(优先)
201
168
  if (btnTop < marginSize) {
202
169
  panelPlacement = 'bottom';
203
170
  btnTop = top_1 + targetHeight;
204
171
  }
205
- } // 如果溢出右边
206
-
207
-
172
+ }
173
+ // 如果溢出右边
208
174
  if (btnLeft + panelWidth + marginSize > visibleWidth) {
209
175
  btnLeft -= btnLeft + panelWidth + marginSize - visibleWidth;
210
- } // 如果溢出左边
211
-
212
-
176
+ }
177
+ // 如果溢出左边
213
178
  if (btnLeft < marginSize) {
214
179
  btnLeft = marginSize;
215
180
  }
216
-
217
181
  Object.assign(panelStyle, {
218
182
  left: "".concat(btnLeft, "px"),
219
183
  right: 'auto',
@@ -235,41 +199,33 @@ var _default2 = (0, _vue.defineComponent)({
235
199
  }
236
200
  }
237
201
  }
238
-
239
202
  reactData.panelStyle = panelStyle;
240
203
  reactData.panelPlacement = panelPlacement;
241
204
  return (0, _vue.nextTick)();
242
205
  }
243
206
  });
244
207
  };
245
-
246
- var clickEvent = function clickEvent(evnt) {
208
+ var clickEvent = function (evnt) {
247
209
  buttonMethods.dispatchEvent('click', {
248
210
  $event: evnt
249
211
  }, evnt);
250
212
  };
251
-
252
- var mousedownDropdownEvent = function mousedownDropdownEvent(evnt) {
213
+ var mousedownDropdownEvent = function (evnt) {
253
214
  var isLeftBtn = evnt.button === 0;
254
-
255
215
  if (isLeftBtn) {
256
216
  evnt.stopPropagation();
257
217
  }
258
218
  };
259
-
260
- var clickDropdownEvent = function clickDropdownEvent(evnt) {
219
+ var clickDropdownEvent = function (evnt) {
261
220
  var dropdownElem = evnt.currentTarget;
262
221
  var panelElem = refBtnPanel.value;
263
-
264
222
  var _a = (0, _dom.getEventTargetNode)(evnt, dropdownElem, 'vxe-button'),
265
- flag = _a.flag,
266
- targetElem = _a.targetElem;
267
-
223
+ flag = _a.flag,
224
+ targetElem = _a.targetElem;
268
225
  if (flag) {
269
226
  if (panelElem) {
270
227
  panelElem.dataset.active = 'N';
271
228
  }
272
-
273
229
  reactData.showPanel = false;
274
230
  setTimeout(function () {
275
231
  if (!panelElem || panelElem.dataset.active !== 'Y') {
@@ -282,10 +238,8 @@ var _default2 = (0, _vue.defineComponent)({
282
238
  }, evnt);
283
239
  }
284
240
  };
285
-
286
- var mouseenterEvent = function mouseenterEvent() {
241
+ var mouseenterEvent = function () {
287
242
  var panelElem = refBtnPanel.value;
288
-
289
243
  if (panelElem) {
290
244
  panelElem.dataset.active = 'Y';
291
245
  reactData.animatVisible = true;
@@ -303,17 +257,13 @@ var _default2 = (0, _vue.defineComponent)({
303
257
  }, 20);
304
258
  }
305
259
  };
306
-
307
- var mouseenterTargetEvent = function mouseenterTargetEvent() {
260
+ var mouseenterTargetEvent = function () {
308
261
  var panelElem = refBtnPanel.value;
309
-
310
262
  if (panelElem) {
311
263
  panelElem.dataset.active = 'Y';
312
-
313
264
  if (!reactData.inited) {
314
265
  reactData.inited = true;
315
266
  }
316
-
317
267
  internalData.showTime = setTimeout(function () {
318
268
  if (panelElem.dataset.active === 'Y') {
319
269
  mouseenterEvent();
@@ -323,11 +273,9 @@ var _default2 = (0, _vue.defineComponent)({
323
273
  }, 250);
324
274
  }
325
275
  };
326
-
327
- var closePanel = function closePanel() {
276
+ var closePanel = function () {
328
277
  var panelElem = refBtnPanel.value;
329
278
  clearTimeout(internalData.showTime);
330
-
331
279
  if (panelElem) {
332
280
  panelElem.dataset.active = 'N';
333
281
  setTimeout(function () {
@@ -345,17 +293,14 @@ var _default2 = (0, _vue.defineComponent)({
345
293
  reactData.showPanel = false;
346
294
  }
347
295
  };
348
-
349
- var mouseleaveEvent = function mouseleaveEvent() {
296
+ var mouseleaveEvent = function () {
350
297
  closePanel();
351
298
  };
352
-
353
- var renderContent = function renderContent() {
299
+ var renderContent = function () {
354
300
  var content = props.content,
355
- icon = props.icon,
356
- loading = props.loading;
301
+ icon = props.icon,
302
+ loading = props.loading;
357
303
  var contVNs = [];
358
-
359
304
  if (loading) {
360
305
  contVNs.push((0, _vue.h)('i', {
361
306
  class: ['vxe-button--loading-icon', _conf.default.icon.BUTTON_LOADING]
@@ -369,7 +314,6 @@ var _default2 = (0, _vue.defineComponent)({
369
314
  class: ['vxe-button--icon', icon]
370
315
  }));
371
316
  }
372
-
373
317
  if (slots.default) {
374
318
  contVNs.push((0, _vue.h)('span', {
375
319
  class: 'vxe-button--content'
@@ -379,23 +323,21 @@ var _default2 = (0, _vue.defineComponent)({
379
323
  class: 'vxe-button--content'
380
324
  }, (0, _utils.getFuncText)(content)));
381
325
  }
382
-
383
326
  return contVNs;
384
327
  };
385
-
386
328
  buttonMethods = {
387
- dispatchEvent: function dispatchEvent(type, params, evnt) {
329
+ dispatchEvent: function (type, params, evnt) {
388
330
  emit(type, Object.assign({
389
331
  $button: $xebutton,
390
332
  $event: evnt
391
333
  }, params));
392
334
  },
393
- focus: function focus() {
335
+ focus: function () {
394
336
  var btnElem = refButton.value;
395
337
  btnElem.focus();
396
338
  return (0, _vue.nextTick)();
397
339
  },
398
- blur: function blur() {
340
+ blur: function () {
399
341
  var btnElem = refButton.value;
400
342
  btnElem.blur();
401
343
  return (0, _vue.nextTick)();
@@ -405,7 +347,6 @@ var _default2 = (0, _vue.defineComponent)({
405
347
  (0, _vue.onMounted)(function () {
406
348
  _event.GlobalEvent.on($xebutton, 'mousewheel', function (evnt) {
407
349
  var panelElem = refBtnPanel.value;
408
-
409
350
  if (reactData.showPanel && !(0, _dom.getEventTargetNode)(evnt, panelElem).flag) {
410
351
  closePanel();
411
352
  }
@@ -414,26 +355,23 @@ var _default2 = (0, _vue.defineComponent)({
414
355
  (0, _vue.onUnmounted)(function () {
415
356
  _event.GlobalEvent.off($xebutton, 'mousewheel');
416
357
  });
417
-
418
- var renderVN = function renderVN() {
358
+ var renderVN = function () {
419
359
  var _a, _b, _c, _d;
420
-
421
360
  var className = props.className,
422
- transfer = props.transfer,
423
- type = props.type,
424
- round = props.round,
425
- circle = props.circle,
426
- destroyOnClose = props.destroyOnClose,
427
- status = props.status,
428
- name = props.name,
429
- disabled = props.disabled,
430
- loading = props.loading;
361
+ transfer = props.transfer,
362
+ type = props.type,
363
+ round = props.round,
364
+ circle = props.circle,
365
+ destroyOnClose = props.destroyOnClose,
366
+ status = props.status,
367
+ name = props.name,
368
+ disabled = props.disabled,
369
+ loading = props.loading;
431
370
  var inited = reactData.inited,
432
- showPanel = reactData.showPanel;
371
+ showPanel = reactData.showPanel;
433
372
  var isFormBtn = computeIsFormBtn.value;
434
373
  var btnType = computeBtnType.value;
435
374
  var vSize = computeSize.value;
436
-
437
375
  if (slots.dropdowns) {
438
376
  return (0, _vue.h)('div', {
439
377
  ref: refElem,
@@ -465,7 +403,6 @@ var _default2 = (0, _vue.defineComponent)({
465
403
  onMouseleave: mouseleaveEvent
466
404
  }, destroyOnClose && !showPanel ? [] : slots.dropdowns({}))] : [])])]);
467
405
  }
468
-
469
406
  return (0, _vue.h)('button', {
470
407
  ref: refButton,
471
408
  class: ['vxe-button', "type--".concat(btnType), (_d = {}, _d["size--".concat(vSize)] = vSize, _d["theme--".concat(status)] = status, _d['is--round'] = round, _d['is--circle'] = circle, _d['is--disabled'] = disabled || loading, _d['is--loading'] = loading, _d)],
@@ -475,13 +412,11 @@ var _default2 = (0, _vue.defineComponent)({
475
412
  onClick: clickEvent
476
413
  }, renderContent());
477
414
  };
478
-
479
415
  $xebutton.renderVN = renderVN;
480
416
  return $xebutton;
481
417
  },
482
- render: function render() {
418
+ render: function () {
483
419
  return this.renderVN();
484
420
  }
485
421
  });
486
-
487
- exports.default = _default2;
422
+ exports.default = _default;
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0;var _vue=require("vue"),_xeUtils=_interopRequireDefault(require("xe-utils")),_conf=_interopRequireDefault(require("../../v-x-e-table/src/conf")),_size=require("../../hooks/size"),_dom=require("../../tools/dom"),_utils=require("../../tools/utils"),_event=require("../../tools/event");function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var _default2=(0,_vue.defineComponent)({name:"VxeButton",props:{type:String,className:String,size:{type:String,default:function(){return _conf.default.button.size||_conf.default.size}},name:[String,Number],content:String,placement:String,status:String,icon:String,round:Boolean,circle:Boolean,disabled:Boolean,loading:Boolean,destroyOnClose:Boolean,transfer:{type:Boolean,default:function(){return _conf.default.button.transfer}}},emits:["click","dropdown-click"],setup:function(m,e){function _(e){u.dispatchEvent("click",{$event:e},e)}function b(e){0===e.button&&e.stopPropagation()}function h(e){var t=e.currentTarget,n=z.value,t=(o=(0,_dom.getEventTargetNode)(e,t,"vxe-button")).flag,o=o.targetElem;t&&(n&&(n.dataset.active="N"),P.showPanel=!1,setTimeout(function(){n&&"Y"===n.dataset.active||(P.animatVisible=!1)},350),u.dispatchEvent("dropdown-click",{name:o.getAttribute("name"),$event:e},e))}function x(){var e=z.value;e&&(e.dataset.active="Y",P.inited||(P.inited=!0),n.showTime=setTimeout(function(){"Y"===e.dataset.active?q():P.animatVisible=!1},250))}function g(){l()}function w(){var e=m.content,t=m.icon,n=[];return m.loading?n.push((0,_vue.h)("i",{class:["vxe-button--loading-icon",_conf.default.icon.BUTTON_LOADING]})):T.icon?n.push((0,_vue.h)("span",{class:"vxe-button--custom-icon"},T.icon({}))):t&&n.push((0,_vue.h)("i",{class:["vxe-button--icon",t]})),T.default?n.push((0,_vue.h)("span",{class:"vxe-button--content"},T.default({}))):e&&n.push((0,_vue.h)("span",{class:"vxe-button--content"},(0,_utils.getFuncText)(e))),n}var T=e.slots,o=e.emit,t=_xeUtils.default.uniqueId(),y=(0,_size.useSize)(m),P=(0,_vue.reactive)({inited:!1,showPanel:!1,animatVisible:!1,panelIndex:0,panelStyle:{},panelPlacement:""}),n={showTime:null},N=(0,_vue.ref)(),k=(0,_vue.ref)(),z=(0,_vue.ref)(),a={refElem:N},i={xID:t,props:m,context:e,reactData:P,internalData:n,getRefMaps:function(){return a}},u={},O=(0,_vue.computed)(function(){var e=m.type;return!!e&&-1<["submit","reset","button"].indexOf(e)}),S=(0,_vue.computed)(function(){var e=m.type;return e&&"text"===e?e:"button"}),s=function(){P.panelIndex<(0,_utils.getLastZIndex)()&&(P.panelIndex=(0,_utils.nextZIndex)())},c=function(){return(0,_vue.nextTick)().then(function(){var e=m.transfer,t=m.placement,n=P.panelIndex,o=k.value,a=z.value;if(a&&o){var i=o.offsetHeight,u=o.offsetWidth,s=a.offsetHeight,c=a.offsetWidth,l={zIndex:n},r=(0,_dom.getAbsolutePos)(o),d=r.top,v=r.left,a=r.boundingTop,n=r.visibleHeight,o=r.visibleWidth,r="bottom";return e?(e=d+i,"top"===t?(r="top",e=d-s):t||(n<a+i+s+5&&(r="top",e=d-s),e<5&&(r="bottom",e=d+i)),o<(v=v+u-c)+c+5&&(v-=v+c+5-o),v<5&&(v=5),Object.assign(l,{left:"".concat(v,"px"),right:"auto",top:"".concat(e,"px"),minWidth:"".concat(u,"px")})):"top"===t?(r="top",l.bottom="".concat(i,"px")):t||n<a+i+s&&5<a-i-s&&(r="top",l.bottom="".concat(i,"px")),P.panelStyle=l,P.panelPlacement=r,(0,_vue.nextTick)()}})},q=function(){var e=z.value;e&&(e.dataset.active="Y",P.animatVisible=!0,setTimeout(function(){"Y"===e.dataset.active&&(P.showPanel=!0,s(),c(),setTimeout(function(){P.showPanel&&c()},50))},20))},l=function(){var e=z.value;clearTimeout(n.showTime),e?(e.dataset.active="N",setTimeout(function(){"Y"!==e.dataset.active&&(P.showPanel=!1,setTimeout(function(){"Y"!==e.dataset.active&&(P.animatVisible=!1)},350))},100)):(P.animatVisible=!1,P.showPanel=!1)},u={dispatchEvent:function(e,t,n){o(e,Object.assign({$button:i,$event:n},t))},focus:function(){return k.value.focus(),(0,_vue.nextTick)()},blur:function(){return k.value.blur(),(0,_vue.nextTick)()}};Object.assign(i,u),(0,_vue.onMounted)(function(){_event.GlobalEvent.on(i,"mousewheel",function(e){var t=z.value;P.showPanel&&!(0,_dom.getEventTargetNode)(e,t).flag&&l()})}),(0,_vue.onUnmounted)(function(){_event.GlobalEvent.off(i,"mousewheel")});return i.renderVN=function(){var e=m.className,t=m.transfer,n=m.type,o=m.round,a=m.circle,i=m.destroyOnClose,u=m.status,s=m.name,c=m.disabled,l=m.loading,r=P.inited,d=P.showPanel,v=O.value,f=S.value,p=y.value;return T.dropdowns?(0,_vue.h)("div",{ref:N,class:["vxe-button--dropdown",e,((e={})["size--".concat(p)]=p,e["is--active"]=d,e)]},[(0,_vue.h)("button",{ref:k,class:["vxe-button","type--".concat(f),((e={})["size--".concat(p)]=p,e["theme--".concat(u)]=u,e["is--round"]=o,e["is--circle"]=a,e["is--disabled"]=c||l,e["is--loading"]=l,e)],name:s,type:v?n:"button",disabled:c||l,onMouseenter:x,onMouseleave:g,onClick:_},w().concat([(0,_vue.h)("i",{class:"vxe-button--dropdown-arrow ".concat(_conf.default.icon.BUTTON_DROPDOWN)})])),(0,_vue.h)(_vue.Teleport,{to:"body",disabled:!t||!r},[(0,_vue.h)("div",{ref:z,class:["vxe-button--dropdown-panel",((t={})["size--".concat(p)]=p,t["animat--leave"]=P.animatVisible,t["animat--enter"]=d,t)],placement:P.panelPlacement,style:P.panelStyle},r?[(0,_vue.h)("div",{class:"vxe-button--dropdown-wrapper",onMousedown:b,onClick:h,onMouseenter:q,onMouseleave:g},i&&!d?[]:T.dropdowns({}))]:[])])]):(0,_vue.h)("button",{ref:k,class:["vxe-button","type--".concat(f),((f={})["size--".concat(p)]=p,f["theme--".concat(u)]=u,f["is--round"]=o,f["is--circle"]=a,f["is--disabled"]=c||l,f["is--loading"]=l,f)],name:s,type:v?n:"button",disabled:c||l,onClick:_},w())},i},render:function(){return this.renderVN()}});exports.default=_default2;
1
+ "use strict";Object.defineProperty(exports,"__esModule",{value:!0}),exports.default=void 0;var _vue=require("vue"),_xeUtils=_interopRequireDefault(require("xe-utils")),_conf=_interopRequireDefault(require("../../v-x-e-table/src/conf")),_size=require("../../hooks/size"),_dom=require("../../tools/dom"),_utils=require("../../tools/utils"),_event=require("../../tools/event");function _interopRequireDefault(e){return e&&e.__esModule?e:{default:e}}var _default=(0,_vue.defineComponent)({name:"VxeButton",props:{type:String,className:String,size:{type:String,default:function(){return _conf.default.button.size||_conf.default.size}},name:[String,Number],content:String,placement:String,status:String,icon:String,round:Boolean,circle:Boolean,disabled:Boolean,loading:Boolean,destroyOnClose:Boolean,transfer:{type:Boolean,default:function(){return _conf.default.button.transfer}}},emits:["click","dropdown-click"],setup:function(m,e){function _(e){u.dispatchEvent("click",{$event:e},e)}function b(e){0===e.button&&e.stopPropagation()}function h(e){var t=e.currentTarget,n=z.value,o=(t=(0,_dom.getEventTargetNode)(e,t,"vxe-button")).flag,t=t.targetElem;o&&(n&&(n.dataset.active="N"),P.showPanel=!1,setTimeout(function(){n&&"Y"===n.dataset.active||(P.animatVisible=!1)},350),u.dispatchEvent("dropdown-click",{name:t.getAttribute("name"),$event:e},e))}function x(){var e=z.value;e&&(e.dataset.active="Y",P.inited||(P.inited=!0),n.showTime=setTimeout(function(){"Y"===e.dataset.active?q():P.animatVisible=!1},250))}function g(){l()}function w(){var e=m.content,t=m.icon,n=[];return m.loading?n.push((0,_vue.h)("i",{class:["vxe-button--loading-icon",_conf.default.icon.BUTTON_LOADING]})):T.icon?n.push((0,_vue.h)("span",{class:"vxe-button--custom-icon"},T.icon({}))):t&&n.push((0,_vue.h)("i",{class:["vxe-button--icon",t]})),T.default?n.push((0,_vue.h)("span",{class:"vxe-button--content"},T.default({}))):e&&n.push((0,_vue.h)("span",{class:"vxe-button--content"},(0,_utils.getFuncText)(e))),n}var T=e.slots,o=e.emit,t=_xeUtils.default.uniqueId(),y=(0,_size.useSize)(m),P=(0,_vue.reactive)({inited:!1,showPanel:!1,animatVisible:!1,panelIndex:0,panelStyle:{},panelPlacement:""}),n={showTime:null},N=(0,_vue.ref)(),k=(0,_vue.ref)(),z=(0,_vue.ref)(),a={refElem:N},i={xID:t,props:m,context:e,reactData:P,internalData:n,getRefMaps:function(){return a}},u={},O=(0,_vue.computed)(function(){var e=m.type;return!!e&&-1<["submit","reset","button"].indexOf(e)}),S=(0,_vue.computed)(function(){var e=m.type;return e&&"text"===e?e:"button"}),s=function(){P.panelIndex<(0,_utils.getLastZIndex)()&&(P.panelIndex=(0,_utils.nextZIndex)())},c=function(){return(0,_vue.nextTick)().then(function(){var e,t,n,o,a,i,u,s,c=m.transfer,l=m.placement,r=P.panelIndex,d=k.value,v=z.value;if(v&&d)return e=d.offsetHeight,t=d.offsetWidth,n=v.offsetHeight,v=v.offsetWidth,r={zIndex:r},s=(d=(0,_dom.getAbsolutePos)(d)).top,o=d.left,a=d.boundingTop,i=d.visibleHeight,d=d.visibleWidth,u="bottom",c?(c=s+e,"top"===l?(u="top",c=s-n):l||(i<a+e+n+5&&(u="top",c=s-n),c<5&&(u="bottom",c=s+e)),d<(s=o+t-v)+v+5&&(s-=s+v+5-d),s<5&&(s=5),Object.assign(r,{left:"".concat(s,"px"),right:"auto",top:"".concat(c,"px"),minWidth:"".concat(t,"px")})):"top"===l?(u="top",r.bottom="".concat(e,"px")):l||i<a+e+n&&5<a-e-n&&(u="top",r.bottom="".concat(e,"px")),P.panelStyle=r,P.panelPlacement=u,(0,_vue.nextTick)()})},q=function(){var e=z.value;e&&(e.dataset.active="Y",P.animatVisible=!0,setTimeout(function(){"Y"===e.dataset.active&&(P.showPanel=!0,s(),c(),setTimeout(function(){P.showPanel&&c()},50))},20))},l=function(){var e=z.value;clearTimeout(n.showTime),e?(e.dataset.active="N",setTimeout(function(){"Y"!==e.dataset.active&&(P.showPanel=!1,setTimeout(function(){"Y"!==e.dataset.active&&(P.animatVisible=!1)},350))},100)):(P.animatVisible=!1,P.showPanel=!1)},u={dispatchEvent:function(e,t,n){o(e,Object.assign({$button:i,$event:n},t))},focus:function(){return k.value.focus(),(0,_vue.nextTick)()},blur:function(){return k.value.blur(),(0,_vue.nextTick)()}};Object.assign(i,u),(0,_vue.onMounted)(function(){_event.GlobalEvent.on(i,"mousewheel",function(e){var t=z.value;P.showPanel&&!(0,_dom.getEventTargetNode)(e,t).flag&&l()})}),(0,_vue.onUnmounted)(function(){_event.GlobalEvent.off(i,"mousewheel")});return i.renderVN=function(){var e=m.className,t=m.transfer,n=m.type,o=m.round,a=m.circle,i=m.destroyOnClose,u=m.status,s=m.name,c=m.disabled,l=m.loading,r=P.inited,d=P.showPanel,v=O.value,f=S.value,p=y.value;return T.dropdowns?(0,_vue.h)("div",{ref:N,class:["vxe-button--dropdown",e,((e={})["size--".concat(p)]=p,e["is--active"]=d,e)]},[(0,_vue.h)("button",{ref:k,class:["vxe-button","type--".concat(f),((e={})["size--".concat(p)]=p,e["theme--".concat(u)]=u,e["is--round"]=o,e["is--circle"]=a,e["is--disabled"]=c||l,e["is--loading"]=l,e)],name:s,type:v?n:"button",disabled:c||l,onMouseenter:x,onMouseleave:g,onClick:_},w().concat([(0,_vue.h)("i",{class:"vxe-button--dropdown-arrow ".concat(_conf.default.icon.BUTTON_DROPDOWN)})])),(0,_vue.h)(_vue.Teleport,{to:"body",disabled:!t||!r},[(0,_vue.h)("div",{ref:z,class:["vxe-button--dropdown-panel",((e={})["size--".concat(p)]=p,e["animat--leave"]=P.animatVisible,e["animat--enter"]=d,e)],placement:P.panelPlacement,style:P.panelStyle},r?[(0,_vue.h)("div",{class:"vxe-button--dropdown-wrapper",onMousedown:b,onClick:h,onMouseenter:q,onMouseleave:g},i&&!d?[]:T.dropdowns({}))]:[])])]):(0,_vue.h)("button",{ref:k,class:["vxe-button","type--".concat(f),((t={})["size--".concat(p)]=p,t["theme--".concat(u)]=u,t["is--round"]=o,t["is--circle"]=a,t["is--disabled"]=c||l,t["is--loading"]=l,t)],name:s,type:v?n:"button",disabled:c||l,onClick:_},w())},i},render:function(){return this.renderVN()}});exports.default=_default;