bkui-vue 2.0.1-beta.11 → 2.0.1-beta.110

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 (523) hide show
  1. package/README.md +15 -0
  2. package/dist/index.cjs.js +142 -168
  3. package/dist/index.esm.js +29125 -32074
  4. package/dist/index.umd.js +142 -168
  5. package/dist/style.css +1 -1
  6. package/dist/style.variable.css +1 -1
  7. package/lib/affix/affix.variable.css +1 -0
  8. package/lib/affix/index.d.ts +111 -57
  9. package/lib/affix/index.js +24 -24
  10. package/lib/alert/alert.d.ts +5 -12
  11. package/lib/alert/alert.variable.css +1 -0
  12. package/lib/alert/index.d.ts +131 -93
  13. package/lib/alert/index.js +25 -25
  14. package/lib/animate-number/index.d.ts +96 -33
  15. package/lib/animate-number/index.js +7 -8
  16. package/lib/backtop/backtop.d.ts +1 -1
  17. package/lib/backtop/backtop.variable.css +1 -0
  18. package/lib/backtop/index.d.ts +118 -70
  19. package/lib/backtop/index.js +16 -17
  20. package/lib/badge/badge.variable.css +1 -0
  21. package/lib/badge/index.d.ts +152 -119
  22. package/lib/badge/index.js +20 -20
  23. package/lib/breadcrumb/breadcrumb.variable.css +1 -0
  24. package/lib/breadcrumb/index.d.ts +119 -67
  25. package/lib/breadcrumb/index.js +17 -17
  26. package/lib/button/button.css +188 -144
  27. package/lib/button/button.d.ts +10 -10
  28. package/lib/button/button.less +74 -71
  29. package/lib/button/button.variable.css +189 -144
  30. package/lib/button/index.d.ts +160 -124
  31. package/lib/button/index.js +26 -26
  32. package/lib/card/card.variable.css +1 -0
  33. package/lib/card/index.d.ts +157 -128
  34. package/lib/card/index.js +22 -20
  35. package/lib/cascader/cascader-panel.d.ts +6 -1
  36. package/lib/cascader/cascader.css +4 -0
  37. package/lib/cascader/cascader.d.ts +8 -4
  38. package/lib/cascader/cascader.less +5 -0
  39. package/lib/cascader/cascader.variable.css +5 -0
  40. package/lib/cascader/index.d.ts +355 -393
  41. package/lib/cascader/index.js +377 -308
  42. package/lib/cascader/interface.d.ts +1 -1
  43. package/lib/checkbox/checkbox-group.d.ts +0 -16
  44. package/lib/checkbox/checkbox.css +8 -0
  45. package/lib/checkbox/checkbox.d.ts +40 -8
  46. package/lib/checkbox/checkbox.less +12 -0
  47. package/lib/checkbox/checkbox.variable.css +9 -0
  48. package/lib/checkbox/index.d.ts +194 -127
  49. package/lib/checkbox/index.js +65 -52
  50. package/lib/checkbox/type.d.ts +1 -1
  51. package/lib/code-diff/code-diff.variable.css +1 -0
  52. package/lib/code-diff/index.d.ts +82 -65
  53. package/lib/code-diff/index.js +446 -389
  54. package/lib/collapse/collapse-panel.d.ts +5 -5
  55. package/lib/collapse/collapse.variable.css +1 -0
  56. package/lib/collapse/index.d.ts +180 -161
  57. package/lib/collapse/index.js +31 -30
  58. package/lib/collapse/props.d.ts +2 -2
  59. package/lib/collapse/utils.d.ts +2 -2
  60. package/lib/collapse-transition/collapse-transition.variable.css +1 -0
  61. package/lib/collapse-transition/index.d.ts +94 -19
  62. package/lib/collapse-transition/index.js +3 -4
  63. package/lib/color-picker/color-picker.d.ts +17 -1
  64. package/lib/color-picker/color-picker.variable.css +1 -0
  65. package/lib/color-picker/index.d.ts +168 -124
  66. package/lib/color-picker/index.js +93 -88
  67. package/lib/components.d.ts +30 -32
  68. package/lib/components.js +29 -31
  69. package/lib/config-provider/config-provider.variable.css +1 -0
  70. package/lib/config-provider/index.d.ts +228 -161
  71. package/lib/config-provider/index.js +17 -17
  72. package/lib/container/container.d.ts +1 -1
  73. package/lib/container/container.variable.css +1 -0
  74. package/lib/container/index.d.ts +85 -74
  75. package/lib/container/index.js +32 -35
  76. package/lib/date-picker/base/date-table.d.ts +1 -1
  77. package/lib/date-picker/base/month-table.d.ts +1 -1
  78. package/lib/date-picker/base/picker-dropdown.d.ts +2 -2
  79. package/lib/date-picker/base/time-spinner.d.ts +3 -3
  80. package/lib/date-picker/base/year-table.d.ts +1 -1
  81. package/lib/date-picker/date-picker.d.ts +7 -15
  82. package/lib/date-picker/date-picker.variable.css +1 -0
  83. package/lib/date-picker/index.d.ts +356 -399
  84. package/lib/date-picker/index.js +343 -297
  85. package/lib/date-picker/interface.d.ts +9 -9
  86. package/lib/date-picker/panel/date-range.d.ts +6 -6
  87. package/lib/date-picker/panel/date.d.ts +2 -2
  88. package/lib/date-picker/panel/time-range.d.ts +3 -12
  89. package/lib/date-picker/panel/time.d.ts +3 -12
  90. package/lib/date-picker/props.d.ts +1 -5
  91. package/lib/date-picker/time-picker.d.ts +7 -14
  92. package/lib/date-picker/utils.d.ts +1 -1
  93. package/lib/dialog/dialog.d.ts +47 -31
  94. package/lib/dialog/dialog.variable.css +1 -0
  95. package/lib/dialog/index.d.ts +309 -305
  96. package/lib/dialog/index.js +252 -249
  97. package/lib/dialog/props.d.ts +20 -13
  98. package/lib/directives/index.d.ts +4 -3
  99. package/lib/directives/index.js +219 -197
  100. package/lib/directives/tooltips.d.ts +1 -1
  101. package/lib/dist.index.js +2 -4
  102. package/lib/divider/divider.d.ts +5 -5
  103. package/lib/divider/divider.variable.css +1 -0
  104. package/lib/divider/index.d.ts +116 -62
  105. package/lib/divider/index.js +4 -5
  106. package/lib/divider/props.d.ts +2 -2
  107. package/lib/dropdown/dropdown-item.d.ts +1 -1
  108. package/lib/dropdown/dropdown-menu.d.ts +1 -1
  109. package/lib/dropdown/dropdown.d.ts +7 -7
  110. package/lib/dropdown/dropdown.variable.css +1 -0
  111. package/lib/dropdown/index.d.ts +144 -102
  112. package/lib/dropdown/index.js +32 -32
  113. package/lib/exception/exception.d.ts +9 -9
  114. package/lib/exception/exception.variable.css +1 -0
  115. package/lib/exception/index.d.ts +107 -46
  116. package/lib/exception/index.js +31 -31
  117. package/lib/exception/typings/index.d.ts +1 -1
  118. package/lib/fixed-navbar/fixed-navbar.variable.css +1 -0
  119. package/lib/fixed-navbar/index.d.ts +113 -59
  120. package/lib/fixed-navbar/index.js +4 -5
  121. package/lib/form/form-item.d.ts +7 -19
  122. package/lib/form/form.d.ts +3 -3
  123. package/lib/form/form.variable.css +1 -0
  124. package/lib/form/index.d.ts +139 -94
  125. package/lib/form/index.js +44 -42
  126. package/lib/form/type.d.ts +2 -2
  127. package/lib/icon/angle-double-down-line.js +17 -17
  128. package/lib/icon/angle-double-left-line.js +17 -17
  129. package/lib/icon/angle-double-left.js +17 -17
  130. package/lib/icon/angle-double-right-line.js +17 -17
  131. package/lib/icon/angle-double-right.js +17 -17
  132. package/lib/icon/angle-double-up-line.js +17 -17
  133. package/lib/icon/angle-down-fill.js +17 -17
  134. package/lib/icon/angle-down-line.js +17 -17
  135. package/lib/icon/angle-down.js +17 -17
  136. package/lib/icon/angle-left.js +17 -17
  137. package/lib/icon/angle-right.js +17 -17
  138. package/lib/icon/angle-up-fill.js +17 -17
  139. package/lib/icon/angle-up.js +17 -17
  140. package/lib/icon/archive-fill.js +17 -17
  141. package/lib/icon/arrows-left.js +17 -17
  142. package/lib/icon/arrows-right.js +17 -17
  143. package/lib/icon/assistant.js +17 -17
  144. package/lib/icon/audio-fill.js +17 -17
  145. package/lib/icon/bk.js +17 -17
  146. package/lib/icon/circle.js +17 -17
  147. package/lib/icon/close-line.js +17 -17
  148. package/lib/icon/close.js +17 -17
  149. package/lib/icon/code.js +17 -17
  150. package/lib/icon/cog-shape.js +17 -17
  151. package/lib/icon/collapse-left.js +17 -17
  152. package/lib/icon/copy-shape.js +17 -17
  153. package/lib/icon/copy.js +17 -17
  154. package/lib/icon/data-shape.js +17 -17
  155. package/lib/icon/del.js +17 -17
  156. package/lib/icon/doc-fill.js +17 -17
  157. package/lib/icon/done.js +17 -17
  158. package/lib/icon/down-shape.js +17 -17
  159. package/lib/icon/down-small.js +17 -17
  160. package/lib/icon/edit-line.js +17 -17
  161. package/lib/icon/ellipsis.js +17 -17
  162. package/lib/icon/enlarge-line.js +17 -17
  163. package/lib/icon/error.js +17 -17
  164. package/lib/icon/excel-fill.js +17 -17
  165. package/lib/icon/exclamation-circle-shape.js +17 -17
  166. package/lib/icon/eye.js +17 -17
  167. package/lib/icon/filliscreen-line.js +17 -17
  168. package/lib/icon/fix-line.js +17 -17
  169. package/lib/icon/fix-shape.js +17 -17
  170. package/lib/icon/folder-open.js +17 -17
  171. package/lib/icon/folder-shape-open.js +17 -17
  172. package/lib/icon/folder-shape.js +17 -17
  173. package/lib/icon/folder.js +17 -17
  174. package/lib/icon/funnel.js +17 -17
  175. package/lib/icon/grag-fill.js +17 -17
  176. package/lib/icon/help-document-fill.js +17 -17
  177. package/lib/icon/help-fill.js +17 -17
  178. package/lib/icon/help.js +17 -17
  179. package/lib/icon/image-fill.js +17 -17
  180. package/lib/icon/img-error.js +17 -17
  181. package/lib/icon/img-placehoulder.js +17 -17
  182. package/lib/icon/index.d.ts +11 -11
  183. package/lib/icon/index.js +11 -11
  184. package/lib/icon/info-line.js +17 -17
  185. package/lib/icon/info.js +17 -17
  186. package/lib/icon/left-shape.js +17 -17
  187. package/lib/icon/left-turn-line.js +17 -17
  188. package/lib/icon/loading.js +17 -17
  189. package/lib/icon/narrow-line.js +17 -17
  190. package/lib/icon/original.js +17 -17
  191. package/lib/icon/pdf-fill.js +17 -17
  192. package/lib/icon/play-shape.js +17 -17
  193. package/lib/icon/plus.js +17 -17
  194. package/lib/icon/ppt-fill.js +17 -17
  195. package/lib/icon/qq.js +17 -17
  196. package/lib/icon/right-shape.js +17 -17
  197. package/lib/icon/right-turn-line.js +17 -17
  198. package/lib/icon/search.js +17 -17
  199. package/lib/icon/share.js +17 -17
  200. package/lib/icon/spinner.js +17 -17
  201. package/lib/icon/success.js +17 -17
  202. package/lib/icon/switcher-loading.js +17 -17
  203. package/lib/icon/text-all.js +17 -17
  204. package/lib/icon/text-file.js +17 -17
  205. package/lib/icon/text-fill.js +17 -17
  206. package/lib/icon/transfer.js +17 -17
  207. package/lib/icon/tree-application-shape.js +17 -17
  208. package/lib/icon/unfull-screen.js +17 -17
  209. package/lib/icon/unvisible.js +17 -17
  210. package/lib/icon/up-shape.js +17 -17
  211. package/lib/icon/upload.js +17 -17
  212. package/lib/icon/video-fill.js +17 -17
  213. package/lib/icon/warn.js +17 -17
  214. package/lib/icon/weixin-pro.js +17 -17
  215. package/lib/icon/weixin.js +17 -17
  216. package/lib/image/image-viewer.d.ts +1 -1
  217. package/lib/image/image-viewer.variable.css +1 -0
  218. package/lib/image/image.variable.css +1 -0
  219. package/lib/image/index.d.ts +149 -113
  220. package/lib/image/index.js +46 -48
  221. package/lib/index.d.ts +9 -3
  222. package/lib/index.js +5 -29
  223. package/lib/info-box/index.js +250 -250
  224. package/lib/info-box/info-box.d.ts +15 -15
  225. package/lib/info-box/info-box.variable.css +1 -0
  226. package/lib/input/index.d.ts +299 -332
  227. package/lib/input/index.js +110 -561
  228. package/lib/input/input.css +23 -1
  229. package/lib/input/input.d.ts +15 -15
  230. package/lib/input/input.less +30 -1
  231. package/lib/input/input.variable.css +24 -1
  232. package/lib/link/index.d.ts +127 -78
  233. package/lib/link/index.js +5 -5
  234. package/lib/link/link.d.ts +5 -5
  235. package/lib/link/link.variable.css +1 -0
  236. package/lib/loading/index.d.ts +162 -135
  237. package/lib/loading/index.js +43 -40
  238. package/lib/loading/loading.d.ts +9 -9
  239. package/lib/loading/loading.variable.css +1 -0
  240. package/lib/locale/index.d.ts +1 -1
  241. package/lib/menu/index.d.ts +131 -51
  242. package/lib/menu/index.js +46 -27
  243. package/lib/menu/menu-group.d.ts +9 -0
  244. package/lib/menu/menu-item.d.ts +9 -0
  245. package/lib/menu/menu.css +29 -17
  246. package/lib/menu/menu.less +33 -18
  247. package/lib/menu/menu.variable.css +30 -17
  248. package/lib/menu/submenu.d.ts +1 -0
  249. package/lib/menu/submenu.variable.css +1 -0
  250. package/lib/menu/utils.d.ts +3 -3
  251. package/lib/message/index.js +43 -42
  252. package/lib/message/message.css +2 -1
  253. package/lib/message/message.less +3 -2
  254. package/lib/message/message.variable.css +3 -1
  255. package/lib/message/messageConstructor.d.ts +21 -21
  256. package/lib/modal/index.d.ts +214 -159
  257. package/lib/modal/index.js +68 -47
  258. package/lib/modal/modal.d.ts +24 -8
  259. package/lib/modal/modal.variable.css +1 -0
  260. package/lib/modal/props.mixin.d.ts +10 -3
  261. package/lib/navigation/index.d.ts +188 -152
  262. package/lib/navigation/index.js +27 -29
  263. package/lib/navigation/navigation.d.ts +1 -1
  264. package/lib/navigation/navigation.variable.css +1 -0
  265. package/lib/notify/index.js +25 -24
  266. package/lib/notify/notify.variable.css +1 -0
  267. package/lib/notify/notifyConstructor.d.ts +5 -5
  268. package/lib/overflow-title/components/overflow-title.d.ts +45 -16
  269. package/lib/overflow-title/index.d.ts +298 -328
  270. package/lib/overflow-title/index.js +85 -28
  271. package/lib/overflow-title/overflow-title.css +3 -0
  272. package/lib/overflow-title/overflow-title.less +4 -0
  273. package/lib/overflow-title/overflow-title.variable.css +3 -0
  274. package/lib/overflow-title/props.d.ts +36 -21
  275. package/lib/pagination/index.d.ts +198 -203
  276. package/lib/pagination/index.js +128 -68
  277. package/lib/pagination/pagination.css +8 -8
  278. package/lib/pagination/pagination.d.ts +0 -13
  279. package/lib/pagination/pagination.less +14 -13
  280. package/lib/pagination/pagination.variable.css +9 -8
  281. package/lib/pagination/type.d.ts +1 -1
  282. package/lib/pagination/use-limit.d.ts +1 -1
  283. package/lib/pagination/use-total.d.ts +1 -1
  284. package/lib/plugin-popover/index.js +311 -304
  285. package/lib/pop-confirm/index.d.ts +162 -148
  286. package/lib/pop-confirm/index.js +40 -35
  287. package/lib/pop-confirm/pop-confirm.css +3 -1
  288. package/lib/pop-confirm/pop-confirm.d.ts +10 -20
  289. package/lib/pop-confirm/pop-confirm.less +3 -1
  290. package/lib/pop-confirm/pop-confirm.variable.css +4 -1
  291. package/lib/pop-confirm/props.d.ts +8 -11
  292. package/lib/popover/const.d.ts +3 -3
  293. package/lib/popover/content.d.ts +6 -3
  294. package/lib/popover/index.d.ts +411 -380
  295. package/lib/popover/index.js +311 -304
  296. package/lib/popover/plugin-popover.d.ts +1 -1
  297. package/lib/popover/popover.d.ts +51 -8
  298. package/lib/popover/popover.variable.css +1 -0
  299. package/lib/popover/props.d.ts +28 -4
  300. package/lib/popover/use-floating.d.ts +2 -2
  301. package/lib/popover/use-popover-init.d.ts +2 -1
  302. package/lib/popover/utils.d.ts +2 -0
  303. package/lib/popover2/index.d.ts +83 -8
  304. package/lib/popover2/index.js +2 -2
  305. package/lib/preset.d.ts +0 -1
  306. package/lib/preset.js +0 -1
  307. package/lib/process/index.d.ts +137 -93
  308. package/lib/process/index.js +229 -229
  309. package/lib/process/process.variable.css +1 -0
  310. package/lib/progress/index.d.ts +192 -183
  311. package/lib/progress/index.js +31 -33
  312. package/lib/progress/progress.d.ts +9 -9
  313. package/lib/progress/progress.variable.css +1 -0
  314. package/lib/radio/index.d.ts +155 -106
  315. package/lib/radio/index.js +76 -63
  316. package/lib/radio/radio-button.d.ts +7 -7
  317. package/lib/radio/radio-group.d.ts +7 -7
  318. package/lib/radio/radio.d.ts +7 -7
  319. package/lib/radio/radio.variable.css +1 -0
  320. package/lib/radio/type.d.ts +1 -1
  321. package/lib/rate/index.d.ts +112 -55
  322. package/lib/rate/index.js +28 -27
  323. package/lib/rate/rate.variable.css +1 -0
  324. package/lib/resize-layout/index.d.ts +204 -157
  325. package/lib/resize-layout/index.js +54 -34
  326. package/lib/resize-layout/resize-layout.d.ts +18 -7
  327. package/lib/resize-layout/resize-layout.variable.css +1 -0
  328. package/lib/scrollbar/css/scrollbar.css +109 -0
  329. package/lib/scrollbar/css/scrollbar.less +139 -0
  330. package/lib/scrollbar/{scrollbar.variable.css → css/scrollbar.variable.css} +96 -61
  331. package/lib/scrollbar/handlers/click-rail.d.ts +2 -0
  332. package/lib/scrollbar/handlers/drag-thumb.d.ts +1 -0
  333. package/lib/scrollbar/handlers/keyboard.d.ts +2 -0
  334. package/lib/scrollbar/handlers/mouse-wheel.d.ts +2 -0
  335. package/lib/scrollbar/handlers/touch.d.ts +4 -0
  336. package/lib/scrollbar/helper/class-names.d.ts +21 -0
  337. package/lib/scrollbar/helper/css.d.ts +3 -0
  338. package/lib/scrollbar/helper/dom.d.ts +4 -0
  339. package/lib/scrollbar/helper/event-manager.d.ts +20 -0
  340. package/lib/scrollbar/helper/util.d.ts +11 -0
  341. package/lib/scrollbar/index.d.ts +133 -13
  342. package/lib/scrollbar/index.js +1380 -18482
  343. package/lib/scrollbar/process-scroll-diff.d.ts +1 -0
  344. package/lib/scrollbar/update-geometry.d.ts +8 -0
  345. package/lib/search-select/index.d.ts +946 -701
  346. package/lib/search-select/index.js +644 -486
  347. package/lib/search-select/input.d.ts +20 -8
  348. package/lib/search-select/menu.d.ts +13 -1
  349. package/lib/search-select/search-select.css +45 -47
  350. package/lib/search-select/search-select.d.ts +207 -160
  351. package/lib/search-select/search-select.less +41 -41
  352. package/lib/search-select/search-select.variable.css +46 -47
  353. package/lib/search-select/selected.d.ts +209 -127
  354. package/lib/search-select/utils.d.ts +6 -6
  355. package/lib/select/common.d.ts +4 -4
  356. package/lib/select/index.d.ts +1457 -1384
  357. package/lib/select/index.js +603 -477
  358. package/lib/select/option.d.ts +6 -6
  359. package/lib/select/select.css +9 -4
  360. package/lib/select/select.d.ts +285 -148
  361. package/lib/select/select.less +11 -4
  362. package/lib/select/select.variable.css +10 -4
  363. package/lib/select/selectTagInput.d.ts +9 -8
  364. package/lib/select/type.d.ts +10 -11
  365. package/lib/shared/frame-throttle.d.ts +15 -0
  366. package/lib/shared/index.d.ts +2 -1
  367. package/lib/shared/index.js +166 -101
  368. package/lib/shared/popover.d.ts +3 -3
  369. package/lib/shared/token.d.ts +1 -1
  370. package/lib/shared/vue-types.d.ts +50 -50
  371. package/lib/shared/z-index-manager.d.ts +6 -6
  372. package/lib/sideslider/index.d.ts +220 -182
  373. package/lib/sideslider/index.js +239 -237
  374. package/lib/sideslider/sideslider.css +7 -8
  375. package/lib/sideslider/sideslider.d.ts +24 -8
  376. package/lib/sideslider/sideslider.less +7 -8
  377. package/lib/sideslider/sideslider.variable.css +8 -8
  378. package/lib/slider/index.d.ts +210 -214
  379. package/lib/slider/index.js +246 -249
  380. package/lib/slider/slider.variable.css +1 -0
  381. package/lib/steps/index.d.ts +155 -131
  382. package/lib/steps/index.js +234 -234
  383. package/lib/steps/steps.d.ts +8 -18
  384. package/lib/steps/steps.variable.css +1 -0
  385. package/lib/styles/index.d.ts +1 -0
  386. package/lib/styles/mixins/animate.variable.css +1 -0
  387. package/lib/styles/mixins/popper.variable.css +1 -0
  388. package/lib/styles/mixins/scroll.variable.css +1 -0
  389. package/lib/styles/reset.variable.css +1 -0
  390. package/lib/styles/themes/themes.less +1 -0
  391. package/lib/swiper/index.d.ts +127 -81
  392. package/lib/swiper/index.js +23 -23
  393. package/lib/swiper/swiper.variable.css +1 -0
  394. package/lib/switcher/index.d.ts +179 -157
  395. package/lib/switcher/index.js +24 -22
  396. package/lib/switcher/switcher.d.ts +9 -9
  397. package/lib/switcher/switcher.variable.css +1 -0
  398. package/lib/tab/index.d.ts +220 -258
  399. package/lib/tab/index.js +79 -69
  400. package/lib/tab/props.d.ts +27 -52
  401. package/lib/tab/tab-nav.d.ts +26 -66
  402. package/lib/tab/tab-panel.d.ts +27 -5
  403. package/lib/tab/tab.css +64 -0
  404. package/lib/tab/tab.d.ts +10 -54
  405. package/lib/tab/tab.less +91 -4
  406. package/lib/tab/tab.variable.css +65 -0
  407. package/lib/table/components/ghost-body.d.ts +2 -0
  408. package/lib/table/components/table-cell.d.ts +22 -0
  409. package/lib/table/components/table-column.d.ts +24 -127
  410. package/lib/table/const.d.ts +23 -10
  411. package/lib/table/events.d.ts +16 -112
  412. package/lib/table/hooks/use-cell.d.ts +20 -0
  413. package/lib/table/hooks/use-checkbox-tooltip.d.ts +11 -0
  414. package/lib/table/hooks/use-column-resize.d.ts +7 -0
  415. package/lib/table/hooks/use-column-template.d.ts +5 -0
  416. package/lib/table/hooks/use-columns.d.ts +69 -0
  417. package/lib/table/{plugins → hooks}/use-draggable.d.ts +2 -2
  418. package/lib/table/hooks/use-fixed-column.d.ts +10 -0
  419. package/lib/table/hooks/use-head.d.ts +16 -0
  420. package/lib/table/hooks/use-layout.d.ts +25 -0
  421. package/lib/table/hooks/use-pagination.d.ts +16 -0
  422. package/lib/table/hooks/use-render.d.ts +21 -0
  423. package/lib/table/hooks/use-rows.d.ts +30 -0
  424. package/lib/table/hooks/use-settings.d.ts +138 -0
  425. package/lib/table/{plugins → hooks}/use-shift-key.d.ts +4 -2
  426. package/lib/table/index.d.ts +412 -1029
  427. package/lib/table/index.js +4698 -20825
  428. package/lib/table/plugins/head-filter.css +5 -0
  429. package/lib/table/plugins/head-filter.d.ts +2 -1
  430. package/lib/table/plugins/head-filter.less +4 -0
  431. package/lib/table/plugins/head-filter.variable.css +6 -0
  432. package/lib/table/plugins/head-sort.variable.css +1 -0
  433. package/lib/table/plugins/settings.css +11 -1
  434. package/lib/table/plugins/settings.less +12 -1
  435. package/lib/table/plugins/settings.variable.css +12 -1
  436. package/lib/table/props.d.ts +127 -62
  437. package/lib/table/table.css +503 -302
  438. package/lib/table/table.d.ts +51 -185
  439. package/lib/table/table.less +244 -112
  440. package/lib/table/table.variable.css +504 -302
  441. package/lib/table/utils.d.ts +44 -21
  442. package/lib/table-column/index.d.ts +156 -369
  443. package/lib/table-column/index.js +143 -62
  444. package/lib/tag/index.d.ts +147 -100
  445. package/lib/tag/index.js +21 -22
  446. package/lib/tag/tag.css +1 -1
  447. package/lib/tag/tag.d.ts +5 -5
  448. package/lib/tag/tag.less +1 -1
  449. package/lib/tag/tag.variable.css +2 -1
  450. package/lib/tag-input/common.d.ts +2 -2
  451. package/lib/tag-input/index.d.ts +595 -712
  452. package/lib/tag-input/index.js +150 -17391
  453. package/lib/tag-input/tag-input.css +12 -9
  454. package/lib/tag-input/tag-input.d.ts +60 -24
  455. package/lib/tag-input/tag-input.less +13 -9
  456. package/lib/tag-input/tag-input.variable.css +13 -9
  457. package/lib/tag-input/tag-props.d.ts +25 -2
  458. package/lib/time-picker/index.d.ts +391 -455
  459. package/lib/time-picker/time-picker.variable.css +1 -0
  460. package/lib/timeline/index.d.ts +131 -64
  461. package/lib/timeline/index.js +8 -8
  462. package/lib/timeline/timeline.variable.css +1 -0
  463. package/lib/transfer/const.d.ts +2 -2
  464. package/lib/transfer/index.d.ts +206 -191
  465. package/lib/transfer/index.js +3 -5
  466. package/lib/transfer/transfer.variable.css +1 -0
  467. package/lib/tree/constant.d.ts +22 -20
  468. package/lib/tree/index.d.ts +329 -357
  469. package/lib/tree/index.js +176 -17389
  470. package/lib/tree/props.d.ts +18 -11
  471. package/lib/tree/tree.css +103 -69
  472. package/lib/tree/tree.d.ts +16 -10
  473. package/lib/tree/tree.variable.css +104 -69
  474. package/lib/tree/use-empty.d.ts +1 -1
  475. package/lib/tree/use-node-action.d.ts +10 -9
  476. package/lib/tree/use-node-async.d.ts +2 -1
  477. package/lib/tree/use-node-attribute.d.ts +42 -34
  478. package/lib/tree/use-search.d.ts +1 -1
  479. package/lib/tree/use-tree-init.d.ts +8 -5
  480. package/lib/tree/util.d.ts +21 -21
  481. package/lib/upload/index.d.ts +294 -286
  482. package/lib/upload/index.js +398 -316
  483. package/lib/upload/props.d.ts +11 -2
  484. package/lib/upload/upload-list.d.ts +11 -1
  485. package/lib/upload/upload-trigger.d.ts +11 -1
  486. package/lib/upload/upload.d.ts +25 -4
  487. package/lib/upload/upload.type.d.ts +12 -6
  488. package/lib/upload/upload.variable.css +1 -0
  489. package/lib/upload/use-file-handler.d.ts +1 -1
  490. package/lib/virtual-render/index.d.ts +247 -373
  491. package/lib/virtual-render/index.js +223 -162
  492. package/lib/virtual-render/props.d.ts +2 -9
  493. package/lib/virtual-render/use-fix-top.d.ts +1 -1
  494. package/lib/virtual-render/use-scrollbar.d.ts +4 -17
  495. package/lib/virtual-render/v-virtual-render.d.ts +7 -1
  496. package/lib/virtual-render/virtual-render.css +96 -70
  497. package/lib/virtual-render/virtual-render.d.ts +7 -23
  498. package/lib/virtual-render/virtual-render.less +2 -11
  499. package/lib/virtual-render/virtual-render.variable.css +96 -69
  500. package/lib/volar.components.d.ts +2 -0
  501. package/package.json +17 -55
  502. package/lib/scrollbar/scrollbar-core/can-use-dom.d.ts +0 -2
  503. package/lib/scrollbar/scrollbar-core/helpers.d.ts +0 -5
  504. package/lib/scrollbar/scrollbar-core/index.d.ts +0 -241
  505. package/lib/scrollbar/scrollbar-core/mouse-wheel.d.ts +0 -5
  506. package/lib/scrollbar/scrollbar-core/scrollbar-width.d.ts +0 -1
  507. package/lib/scrollbar/scrollbar.css +0 -75
  508. package/lib/scrollbar/scrollbar.less +0 -94
  509. package/lib/table/plugins/col-group.d.ts +0 -38
  510. package/lib/table/plugins/settings.d.ts +0 -16
  511. package/lib/table/plugins/use-active-columns.d.ts +0 -16
  512. package/lib/table/plugins/use-column-resize.d.ts +0 -35
  513. package/lib/table/plugins/use-column-template.d.ts +0 -7
  514. package/lib/table/plugins/use-fixed-column.d.ts +0 -27
  515. package/lib/table/plugins/use-head-cell.d.ts +0 -7
  516. package/lib/table/plugins/use-pagination.d.ts +0 -23
  517. package/lib/table/use-attributes.d.ts +0 -62
  518. package/lib/table/use-column.d.ts +0 -275
  519. package/lib/table/use-common.d.ts +0 -1679
  520. package/lib/table/use-render.d.ts +0 -11
  521. /package/lib/table/{plugins → components}/body-empty.d.ts +0 -0
  522. /package/lib/table/{plugins → hooks}/use-observer-resize.d.ts +0 -0
  523. /package/lib/table/{plugins → hooks}/use-scroll-loading.d.ts +0 -0
@@ -52,11 +52,11 @@ declare const _default: import("vue").DefineComponent<{
52
52
  };
53
53
  }, {
54
54
  handleSubmit: (event: Event) => void;
55
- validate: (fields?: string | Array<string>) => Promise<{
55
+ validate: (fields?: Array<string> | string) => Promise<{
56
56
  [key: string]: any;
57
57
  }>;
58
58
  getValidateResult: () => Promise<boolean>;
59
- clearValidate: (fields?: string | Array<string>) => void;
59
+ clearValidate: (fields?: Array<string> | string) => void;
60
60
  resolveClassName: (cls: string) => string;
61
61
  }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
62
62
  submit: any;
@@ -84,7 +84,7 @@ declare const _default: import("vue").DefineComponent<{
84
84
  };
85
85
  };
86
86
  }>> & {
87
- onSubmit?: (...args: any[] | unknown[]) => any;
87
+ onSubmit?: ((...args: any[]) => any) | ((...args: unknown[]) => any);
88
88
  onValidate?: (property: string, result: boolean, message: string) => any;
89
89
  }, {
90
90
  labelWidth: string | number;
@@ -109,6 +109,7 @@
109
109
  --date-picker-dropdown-bg: #fff;
110
110
  --table-bg-color: var(--white-color);
111
111
  --table-border-color: #dcdee5;
112
+ --table-strip-color: #fafbfd;
112
113
  --table-head-bg-color: #fafbfd;
113
114
  --table-head-font-color: #313238;
114
115
  --table-body-font-color: #63656E;
@@ -4,84 +4,145 @@ import { formProps } from './form';
4
4
  import FormItem from './form-item';
5
5
  export * from './type';
6
6
  declare const BkForm: {
7
- new (...args: any[]): import("vue").CreateComponentPublicInstance<Readonly<import("vue").ExtractPropTypes<{
8
- formType: import("vue-types").VueTypeDef<string> & {
9
- default: string;
10
- };
11
- labelWidth: import("vue-types").VueTypeDef<string | number> & {
12
- default: string | number;
13
- };
14
- labelPosition: import("vue-types").VueTypeDef<string>;
15
- model: import("vue-types").VueTypeValidableDef<{
16
- [key: string]: any;
17
- }> & {
18
- default: () => {
7
+ new (...args: any[]): {
8
+ $: import("vue").ComponentInternalInstance;
9
+ $data: {};
10
+ $props: {
11
+ labelWidth?: string | number;
12
+ rules?: {
19
13
  [key: string]: any;
20
14
  };
21
- };
22
- rules: import("vue-types").VueTypeValidableDef<{
23
- [key: string]: any;
24
- }> & {
25
- default: () => {
15
+ formType?: string;
16
+ model?: {
26
17
  [key: string]: any;
27
18
  };
19
+ class?: unknown;
20
+ style?: unknown;
21
+ onSubmit?: ((...args: any[]) => any) | ((...args: unknown[]) => any);
22
+ ref?: import("vue").VNodeRef;
23
+ key?: string | number | symbol;
24
+ ref_for?: boolean;
25
+ ref_key?: string;
26
+ onVnodeBeforeMount?: ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
27
+ [key: string]: any;
28
+ }>) => void) | ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
29
+ [key: string]: any;
30
+ }>) => void)[];
31
+ onVnodeMounted?: ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
32
+ [key: string]: any;
33
+ }>) => void) | ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
34
+ [key: string]: any;
35
+ }>) => void)[];
36
+ onVnodeBeforeUpdate?: ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
37
+ [key: string]: any;
38
+ }>, oldVNode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
39
+ [key: string]: any;
40
+ }>) => void) | ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
41
+ [key: string]: any;
42
+ }>, oldVNode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
43
+ [key: string]: any;
44
+ }>) => void)[];
45
+ onVnodeUpdated?: ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
46
+ [key: string]: any;
47
+ }>, oldVNode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
48
+ [key: string]: any;
49
+ }>) => void) | ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
50
+ [key: string]: any;
51
+ }>, oldVNode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
52
+ [key: string]: any;
53
+ }>) => void)[];
54
+ onVnodeBeforeUnmount?: ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
55
+ [key: string]: any;
56
+ }>) => void) | ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
57
+ [key: string]: any;
58
+ }>) => void)[];
59
+ onVnodeUnmounted?: ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
60
+ [key: string]: any;
61
+ }>) => void) | ((vnode: import("vue").VNode<import("vue").RendererNode, import("vue").RendererElement, {
62
+ [key: string]: any;
63
+ }>) => void)[];
64
+ readonly labelPosition?: string;
65
+ onValidate?: (property: string, result: boolean, message: string) => any;
28
66
  };
29
- }>> & {
30
- onSubmit?: (...args: any[] | unknown[]) => any;
31
- onValidate?: (property: string, result: boolean, message: string) => any;
32
- }, {
33
- handleSubmit: (event: Event) => void;
34
- validate: (fields?: string | string[]) => Promise<{
35
- [key: string]: any;
36
- }>;
37
- getValidateResult: () => Promise<boolean>;
38
- clearValidate: (fields?: string | string[]) => void;
39
- resolveClassName: (cls: string) => string;
40
- }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
41
- submit: any;
42
- validate: (property: string, result: boolean, message: string) => boolean;
43
- }, import("vue").VNodeProps & import("vue").AllowedComponentProps & import("vue").ComponentCustomProps & Readonly<import("vue").ExtractPropTypes<{
44
- formType: import("vue-types").VueTypeDef<string> & {
45
- default: string;
67
+ $attrs: {
68
+ [x: string]: unknown;
46
69
  };
47
- labelWidth: import("vue-types").VueTypeDef<string | number> & {
48
- default: string | number;
70
+ $refs: {
71
+ [x: string]: unknown;
49
72
  };
50
- labelPosition: import("vue-types").VueTypeDef<string>;
51
- model: import("vue-types").VueTypeValidableDef<{
52
- [key: string]: any;
53
- }> & {
54
- default: () => {
73
+ $slots: Readonly<{
74
+ [name: string]: import("vue").Slot<any>;
75
+ }>;
76
+ $root: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string, {}>, {}, {}>;
77
+ $parent: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string, {}>, {}, {}>;
78
+ $emit: ((event: "submit", ...args: unknown[]) => void) & ((event: "submit", ...args: any[]) => void) & ((event: "validate", property: string, result: boolean, message: string) => void);
79
+ $el: any;
80
+ $options: import("vue").ComponentOptionsBase<Readonly<import("vue").ExtractPropTypes<{
81
+ formType: import("vue-types").VueTypeDef<string> & {
82
+ default: string;
83
+ };
84
+ labelWidth: import("vue-types").VueTypeDef<string | number> & {
85
+ default: string | number;
86
+ };
87
+ labelPosition: import("vue-types").VueTypeDef<string>;
88
+ model: import("vue-types").VueTypeValidableDef<{
55
89
  [key: string]: any;
90
+ }> & {
91
+ default: () => {
92
+ [key: string]: any;
93
+ };
56
94
  };
57
- };
58
- rules: import("vue-types").VueTypeValidableDef<{
59
- [key: string]: any;
60
- }> & {
61
- default: () => {
95
+ rules: import("vue-types").VueTypeValidableDef<{
62
96
  [key: string]: any;
97
+ }> & {
98
+ default: () => {
99
+ [key: string]: any;
100
+ };
63
101
  };
64
- };
65
- }>> & {
66
- onSubmit?: (...args: any[] | unknown[]) => any;
67
- onValidate?: (property: string, result: boolean, message: string) => any;
68
- }, {
69
- labelWidth: string | number;
70
- rules: {
71
- [key: string]: any;
72
- };
73
- formType: string;
74
- model: {
75
- [key: string]: any;
76
- };
77
- }, true, {}, {}, {
78
- P: {};
79
- B: {};
80
- D: {};
81
- C: {};
82
- M: {};
83
- Defaults: {};
84
- }, Readonly<import("vue").ExtractPropTypes<{
102
+ }>> & {
103
+ onSubmit?: ((...args: any[]) => any) | ((...args: unknown[]) => any);
104
+ onValidate?: (property: string, result: boolean, message: string) => any;
105
+ }, {
106
+ handleSubmit: (event: Event) => void;
107
+ validate: (fields?: string | string[]) => Promise<{
108
+ [key: string]: any;
109
+ }>;
110
+ getValidateResult: () => Promise<boolean>;
111
+ clearValidate: (fields?: string | string[]) => void;
112
+ resolveClassName: (cls: string) => string;
113
+ }, unknown, {}, {}, import("vue").ComponentOptionsMixin, import("vue").ComponentOptionsMixin, {
114
+ submit: any;
115
+ validate: (property: string, result: boolean, message: string) => boolean;
116
+ }, string, {
117
+ labelWidth: string | number;
118
+ rules: {
119
+ [key: string]: any;
120
+ };
121
+ formType: string;
122
+ model: {
123
+ [key: string]: any;
124
+ };
125
+ }, {}, string, {}> & {
126
+ beforeCreate?: (() => void) | (() => void)[];
127
+ created?: (() => void) | (() => void)[];
128
+ beforeMount?: (() => void) | (() => void)[];
129
+ mounted?: (() => void) | (() => void)[];
130
+ beforeUpdate?: (() => void) | (() => void)[];
131
+ updated?: (() => void) | (() => void)[];
132
+ activated?: (() => void) | (() => void)[];
133
+ deactivated?: (() => void) | (() => void)[];
134
+ beforeDestroy?: (() => void) | (() => void)[];
135
+ beforeUnmount?: (() => void) | (() => void)[];
136
+ destroyed?: (() => void) | (() => void)[];
137
+ unmounted?: (() => void) | (() => void)[];
138
+ renderTracked?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
139
+ renderTriggered?: ((e: import("vue").DebuggerEvent) => void) | ((e: import("vue").DebuggerEvent) => void)[];
140
+ errorCaptured?: ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string, {}>, {}, {}>, info: string) => boolean | void) | ((err: unknown, instance: import("vue").ComponentPublicInstance<{}, {}, {}, {}, {}, {}, {}, {}, false, import("vue").ComponentOptionsBase<any, any, any, any, any, any, any, any, any, {}, {}, string, {}>, {}, {}>, info: string) => boolean | void)[];
141
+ };
142
+ $forceUpdate: () => void;
143
+ $nextTick: typeof import("vue").nextTick;
144
+ $watch<T extends string | ((...args: any) => any)>(source: T, cb: T extends (...args: any) => infer R ? (args_0: R, args_1: R) => any : (...args: any) => any, options?: import("vue").WatchOptions<boolean>): import("vue").WatchStopHandle;
145
+ } & Readonly<import("vue").ExtractPropTypes<{
85
146
  formType: import("vue-types").VueTypeDef<string> & {
86
147
  default: string;
87
148
  };
@@ -104,9 +165,9 @@ declare const BkForm: {
104
165
  };
105
166
  };
106
167
  }>> & {
107
- onSubmit?: (...args: any[] | unknown[]) => any;
168
+ onSubmit?: ((...args: any[]) => any) | ((...args: unknown[]) => any);
108
169
  onValidate?: (property: string, result: boolean, message: string) => any;
109
- }, {
170
+ } & import("vue").ShallowUnwrapRef<{
110
171
  handleSubmit: (event: Event) => void;
111
172
  validate: (fields?: string | string[]) => Promise<{
112
173
  [key: string]: any;
@@ -114,16 +175,7 @@ declare const BkForm: {
114
175
  getValidateResult: () => Promise<boolean>;
115
176
  clearValidate: (fields?: string | string[]) => void;
116
177
  resolveClassName: (cls: string) => string;
117
- }, {}, {}, {}, {
118
- labelWidth: string | number;
119
- rules: {
120
- [key: string]: any;
121
- };
122
- formType: string;
123
- model: {
124
- [key: string]: any;
125
- };
126
- }>;
178
+ }> & {} & import("vue").ComponentCustomProperties & {};
127
179
  __isFragment?: never;
128
180
  __isTeleport?: never;
129
181
  __isSuspense?: never;
@@ -150,7 +202,7 @@ declare const BkForm: {
150
202
  };
151
203
  };
152
204
  }>> & {
153
- onSubmit?: (...args: any[] | unknown[]) => any;
205
+ onSubmit?: ((...args: any[]) => any) | ((...args: unknown[]) => any);
154
206
  onValidate?: (property: string, result: boolean, message: string) => any;
155
207
  }, {
156
208
  handleSubmit: (event: Event) => void;
@@ -206,11 +258,6 @@ declare const BkForm: {
206
258
  rules: import("vue-types").VueTypeValidableDef<unknown[]> & {
207
259
  default: () => unknown[];
208
260
  };
209
- autoCheck: import("vue-types").VueTypeValidableDef<boolean> & {
210
- default: boolean;
211
- } & {
212
- default: boolean;
213
- };
214
261
  description: import("vue-types").VueTypeValidableDef<string> & {
215
262
  default: string;
216
263
  };
@@ -219,9 +266,13 @@ declare const BkForm: {
219
266
  };
220
267
  }, {
221
268
  isShowLabel: import("vue").ComputedRef<boolean>;
222
- labelStyles: import("vue").ComputedRef<any>;
269
+ labelStyles: import("vue").ComputedRef<{
270
+ width: string;
271
+ paddingRight: string;
272
+ textAlign: string;
273
+ }>;
223
274
  contentStyles: import("vue").ComputedRef<{
224
- "margin-left": any;
275
+ "margin-left": string;
225
276
  }>;
226
277
  isFormTypeVertical: import("vue").ComputedRef<boolean>;
227
278
  validate: (trigger?: string, showError?: boolean) => Promise<boolean>;
@@ -262,11 +313,6 @@ declare const BkForm: {
262
313
  rules: import("vue-types").VueTypeValidableDef<unknown[]> & {
263
314
  default: () => unknown[];
264
315
  };
265
- autoCheck: import("vue-types").VueTypeValidableDef<boolean> & {
266
- default: boolean;
267
- } & {
268
- default: boolean;
269
- };
270
316
  description: import("vue-types").VueTypeValidableDef<string> & {
271
317
  default: string;
272
318
  };
@@ -276,14 +322,13 @@ declare const BkForm: {
276
322
  }>>, {
277
323
  required: boolean;
278
324
  label: string;
325
+ description: string;
279
326
  email: boolean;
280
327
  property: string;
281
328
  max: number;
282
329
  min: number;
283
330
  maxlength: number;
284
331
  rules: unknown[];
285
- autoCheck: boolean;
286
- description: string;
287
332
  errorDisplayType: string;
288
333
  }, {}>;
289
334
  ComposeFormItem: import("vue").DefineComponent<{
package/lib/form/index.js CHANGED
@@ -5,10 +5,10 @@ import * as __WEBPACK_EXTERNAL_MODULE_vue__ from "vue";
5
5
  import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_config_provider_fe8577a3__ from "../config-provider";
6
6
  import * as __WEBPACK_EXTERNAL_MODULE_lodash_isBoolean_dcb66997__ from "lodash/isBoolean";
7
7
  import * as __WEBPACK_EXTERNAL_MODULE_lodash_isString_e6fa8a5b__ from "lodash/isString";
8
- import * as __WEBPACK_EXTERNAL_MODULE_lodash_get_9427f899__ from "lodash/get";
9
- import * as __WEBPACK_EXTERNAL_MODULE_lodash_isFunction_f90b20d6__ from "lodash/isFunction";
10
8
  import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_directives_45d4776f__ from "../directives";
11
9
  import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__ from "../icon";
10
+ import * as __WEBPACK_EXTERNAL_MODULE_lodash_get_9427f899__ from "lodash/get";
11
+ import * as __WEBPACK_EXTERNAL_MODULE_lodash_isFunction_f90b20d6__ from "lodash/isFunction";
12
12
  import * as __WEBPACK_EXTERNAL_MODULE_lodash_isDate_b457317b__ from "lodash/isDate";
13
13
  import * as __WEBPACK_EXTERNAL_MODULE_lodash_isEmpty_e109fd6b__ from "lodash/isEmpty";
14
14
  /******/ // The require scope
@@ -165,38 +165,38 @@ var isCustomComponent = function isCustomComponent(node) {
165
165
  }
166
166
  }));
167
167
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/typeof.js
168
- function _typeof(o) {
168
+ function _typeof(obj) {
169
169
  "@babel/helpers - typeof";
170
170
 
171
- return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
172
- return typeof o;
173
- } : function (o) {
174
- return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
175
- }, _typeof(o);
171
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
172
+ return typeof obj;
173
+ } : function (obj) {
174
+ return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
175
+ }, _typeof(obj);
176
176
  }
177
177
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toPrimitive.js
178
178
 
179
- function toPrimitive(t, r) {
180
- if ("object" != _typeof(t) || !t) return t;
181
- var e = t[Symbol.toPrimitive];
182
- if (void 0 !== e) {
183
- var i = e.call(t, r || "default");
184
- if ("object" != _typeof(i)) return i;
179
+ function _toPrimitive(input, hint) {
180
+ if (_typeof(input) !== "object" || input === null) return input;
181
+ var prim = input[Symbol.toPrimitive];
182
+ if (prim !== undefined) {
183
+ var res = prim.call(input, hint || "default");
184
+ if (_typeof(res) !== "object") return res;
185
185
  throw new TypeError("@@toPrimitive must return a primitive value.");
186
186
  }
187
- return ("string" === r ? String : Number)(t);
187
+ return (hint === "string" ? String : Number)(input);
188
188
  }
189
189
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js
190
190
 
191
191
 
192
- function toPropertyKey(t) {
193
- var i = toPrimitive(t, "string");
194
- return "symbol" == _typeof(i) ? i : String(i);
192
+ function _toPropertyKey(arg) {
193
+ var key = _toPrimitive(arg, "string");
194
+ return _typeof(key) === "symbol" ? key : String(key);
195
195
  }
196
196
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/defineProperty.js
197
197
 
198
198
  function _defineProperty(obj, key, value) {
199
- key = toPropertyKey(key);
199
+ key = _toPropertyKey(key);
200
200
  if (key in obj) {
201
201
  Object.defineProperty(obj, key, {
202
202
  value: value,
@@ -266,7 +266,6 @@ var formEvents = {
266
266
  }
267
267
  };
268
268
  /* harmony default export */ const src_form = ((0,external_vue_namespaceObject.defineComponent)({
269
- // eslint-disable-next-line vue/no-reserved-component-names
270
269
  name: 'Form',
271
270
  props: formProps,
272
271
  emits: formEvents,
@@ -375,8 +374,8 @@ var formEvents = {
375
374
  };
376
375
  },
377
376
  render: function render() {
378
- var _this$$slots$default, _this$$slots;
379
- var formClasses = (0,shared_namespaceObject.classes)(_defineProperty(_defineProperty({}, "".concat(this.resolveClassName('form')), true), "".concat(this.resolveClassName("form--".concat(this.formType))), true));
377
+ var _classes, _this$$slots$default, _this$$slots;
378
+ var formClasses = (0,shared_namespaceObject.classes)((_classes = {}, _defineProperty(_classes, "".concat(this.resolveClassName('form')), true), _defineProperty(_classes, "".concat(this.resolveClassName("form--".concat(this.formType))), true), _classes));
380
379
  return (0,external_vue_namespaceObject.createVNode)("form", {
381
380
  "class": formClasses,
382
381
  "onSubmit": this.handleSubmit
@@ -420,14 +419,6 @@ function _nonIterableSpread() {
420
419
  function _toConsumableArray(arr) {
421
420
  return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
422
421
  }
423
- ;// CONCATENATED MODULE: external "lodash/get"
424
- var get_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
425
- var get_y = x => () => x
426
- const get_namespaceObject = get_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_get_9427f899__["default"] });
427
- ;// CONCATENATED MODULE: external "lodash/isFunction"
428
- var isFunction_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
429
- var isFunction_y = x => () => x
430
- const isFunction_namespaceObject = isFunction_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_isFunction_f90b20d6__["default"] });
431
422
  ;// CONCATENATED MODULE: external "../directives"
432
423
  var directives_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
433
424
  var directives_y = x => () => x
@@ -436,6 +427,14 @@ const directives_namespaceObject = directives_x({ ["bkTooltips"]: () => __WEBPAC
436
427
  var icon_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
437
428
  var icon_y = x => () => x
438
429
  const icon_namespaceObject = icon_x({ ["ExclamationCircleShape"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.ExclamationCircleShape });
430
+ ;// CONCATENATED MODULE: external "lodash/get"
431
+ var get_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
432
+ var get_y = x => () => x
433
+ const get_namespaceObject = get_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_get_9427f899__["default"] });
434
+ ;// CONCATENATED MODULE: external "lodash/isFunction"
435
+ var isFunction_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
436
+ var isFunction_y = x => () => x
437
+ const isFunction_namespaceObject = isFunction_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_isFunction_f90b20d6__["default"] });
439
438
  ;// CONCATENATED MODULE: ../../packages/form/src/utils.ts
440
439
  /*
441
440
  * Tencent is pleased to support the open source community by making
@@ -580,7 +579,6 @@ var formItemProps = {
580
579
  min: shared_namespaceObject.PropTypes.number,
581
580
  maxlength: shared_namespaceObject.PropTypes.number,
582
581
  rules: shared_namespaceObject.PropTypes.array,
583
- autoCheck: shared_namespaceObject.PropTypes.bool.def(false),
584
582
  description: shared_namespaceObject.PropTypes.string,
585
583
  errorDisplayType: shared_namespaceObject.PropTypes.oneOf(['tooltips', 'normal']).def('normal')
586
584
  };
@@ -797,17 +795,19 @@ var isValid = function isValid(value) {
797
795
  var rule = rules[stepIndex];
798
796
  return Promise.resolve().then(function () {
799
797
  var result = rule.validator(value);
800
- var errorMessage = getRuleMessage(rule);
801
798
  // 异步验证(validator 返回一个 Promise)
802
- if (typeof result !== 'boolean' && typeof result.then === 'function') {
799
+ if (typeof result !== 'boolean' && typeof result !== 'string' && typeof result.then === 'function') {
803
800
  return result.then(function (data) {
804
801
  // 异步验证结果为 false
805
802
  if (data === false) {
806
- return Promise.reject(errorMessage);
803
+ return Promise.reject(getRuleMessage(rule));
804
+ }
805
+ if (typeof data === 'string') {
806
+ return Promise.reject(data);
807
807
  }
808
808
  }).then(function () {
809
809
  return doValidate();
810
- }, function () {
810
+ }, function (errorMessage) {
811
811
  if (showError) {
812
812
  state.isError = true;
813
813
  state.errorMessage = errorMessage;
@@ -817,7 +817,8 @@ var isValid = function isValid(value) {
817
817
  });
818
818
  }
819
819
  // 同步验证失败
820
- if (!result) {
820
+ if (result === false) {
821
+ var errorMessage = getRuleMessage(rule);
821
822
  if (showError) {
822
823
  state.isError = true;
823
824
  // 验证结果返回的是 String 表示验证失败,返回结果作为错误信息
@@ -867,12 +868,13 @@ var isValid = function isValid(value) {
867
868
  });
868
869
  },
869
870
  render: function render() {
870
- var _this = this,
871
+ var _classes,
872
+ _this = this,
871
873
  _this$$slots$labelApp,
872
874
  _this$$slots,
873
875
  _this$$slots$default,
874
876
  _this$$slots2;
875
- var itemClassees = (0,shared_namespaceObject.classes)(_defineProperty(_defineProperty(_defineProperty({}, "".concat(this.resolveClassName('form-item')), true), 'is-error', this.isError), 'is-required', this.required));
877
+ var itemClassees = (0,shared_namespaceObject.classes)((_classes = {}, _defineProperty(_classes, "".concat(this.resolveClassName('form-item')), true), _defineProperty(_classes, 'is-error', this.isError), _defineProperty(_classes, 'is-required', this.required), _classes));
876
878
  var renderLabel = function renderLabel() {
877
879
  if (_this.$slots.label) {
878
880
  return (0,external_vue_namespaceObject.createVNode)("span", null, [_this.$slots.label()]);
@@ -903,11 +905,11 @@ var isValid = function isValid(value) {
903
905
  return (0,external_vue_namespaceObject.createVNode)("div", {
904
906
  "class": itemClassees
905
907
  }, [this.isShowLabel && (0,external_vue_namespaceObject.createVNode)("div", {
906
- "class": "".concat(this.resolveClassName('form-label')),
907
- "style": this.labelStyles
908
+ "style": this.labelStyles,
909
+ "class": "".concat(this.resolveClassName('form-label'))
908
910
  }, [renderLabel(), this.isFormTypeVertical && ((_this$$slots$labelApp = (_this$$slots = this.$slots).labelAppend) === null || _this$$slots$labelApp === void 0 ? void 0 : _this$$slots$labelApp.call(_this$$slots))]), (0,external_vue_namespaceObject.createVNode)("div", {
909
- "class": "".concat(this.resolveClassName('form-content')),
910
- "style": this.contentStyles
911
+ "style": this.contentStyles,
912
+ "class": "".concat(this.resolveClassName('form-content'))
911
913
  }, [(_this$$slots$default = (_this$$slots2 = this.$slots)["default"]) === null || _this$$slots$default === void 0 ? void 0 : _this$$slots$default.call(_this$$slots2), renderError()])]);
912
914
  }
913
915
  }));
@@ -18,7 +18,7 @@ export interface IFormItemRule {
18
18
  max?: number;
19
19
  maxlength?: number;
20
20
  pattern?: RegExp;
21
- validator?: (any: any) => boolean | Promise<boolean>;
22
- message: string | (() => string);
21
+ validator?: (any: any) => Promise<boolean> | boolean;
22
+ message: (() => string) | string;
23
23
  trigger: 'blur' | 'change';
24
24
  }
@@ -29,38 +29,38 @@ __webpack_require__.d(__webpack_exports__, {
29
29
  });
30
30
 
31
31
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/typeof.js
32
- function _typeof(o) {
32
+ function _typeof(obj) {
33
33
  "@babel/helpers - typeof";
34
34
 
35
- return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (o) {
36
- return typeof o;
37
- } : function (o) {
38
- return o && "function" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? "symbol" : typeof o;
39
- }, _typeof(o);
35
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
36
+ return typeof obj;
37
+ } : function (obj) {
38
+ return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
39
+ }, _typeof(obj);
40
40
  }
41
41
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toPrimitive.js
42
42
 
43
- function toPrimitive(t, r) {
44
- if ("object" != _typeof(t) || !t) return t;
45
- var e = t[Symbol.toPrimitive];
46
- if (void 0 !== e) {
47
- var i = e.call(t, r || "default");
48
- if ("object" != _typeof(i)) return i;
43
+ function _toPrimitive(input, hint) {
44
+ if (_typeof(input) !== "object" || input === null) return input;
45
+ var prim = input[Symbol.toPrimitive];
46
+ if (prim !== undefined) {
47
+ var res = prim.call(input, hint || "default");
48
+ if (_typeof(res) !== "object") return res;
49
49
  throw new TypeError("@@toPrimitive must return a primitive value.");
50
50
  }
51
- return ("string" === r ? String : Number)(t);
51
+ return (hint === "string" ? String : Number)(input);
52
52
  }
53
53
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js
54
54
 
55
55
 
56
- function toPropertyKey(t) {
57
- var i = toPrimitive(t, "string");
58
- return "symbol" == _typeof(i) ? i : String(i);
56
+ function _toPropertyKey(arg) {
57
+ var key = _toPrimitive(arg, "string");
58
+ return _typeof(key) === "symbol" ? key : String(key);
59
59
  }
60
60
  ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/defineProperty.js
61
61
 
62
62
  function _defineProperty(obj, key, value) {
63
- key = toPropertyKey(key);
63
+ key = _toPropertyKey(key);
64
64
  if (key in obj) {
65
65
  Object.defineProperty(obj, key, {
66
66
  value: value,