bkui-vue 0.0.2-beta.14 → 0.0.2-beta.141

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 (505) hide show
  1. package/dist/index.cjs.js +142 -160
  2. package/dist/index.esm.js +18004 -19937
  3. package/dist/index.umd.js +142 -160
  4. package/dist/locale/en.esm.js +1 -1
  5. package/dist/locale/en.esm.js.map +1 -1
  6. package/dist/locale/en.umd.js +1 -1
  7. package/dist/locale/en.umd.js.map +1 -1
  8. package/dist/locale/zh-cn.esm.js +1 -1
  9. package/dist/locale/zh-cn.esm.js.map +1 -1
  10. package/dist/locale/zh-cn.umd.js +1 -1
  11. package/dist/locale/zh-cn.umd.js.map +1 -1
  12. package/dist/style.css +1 -1
  13. package/dist/style.variable.css +1 -1
  14. package/lib/affix/affix.d.ts +1 -1
  15. package/lib/affix/affix.variable.css +6 -2
  16. package/lib/affix/index.d.ts +4 -4
  17. package/lib/affix/index.js +322 -1
  18. package/lib/alert/alert.css +7 -0
  19. package/lib/alert/alert.d.ts +5 -5
  20. package/lib/alert/alert.less +16 -6
  21. package/lib/alert/alert.variable.css +13 -2
  22. package/lib/alert/index.d.ts +10 -10
  23. package/lib/alert/index.js +215 -1
  24. package/lib/animate-number/index.d.ts +1 -1
  25. package/lib/animate-number/index.js +155 -1
  26. package/lib/backtop/backtop.css +8 -8
  27. package/lib/backtop/backtop.less +3 -1
  28. package/lib/backtop/backtop.variable.css +17 -13
  29. package/lib/backtop/index.d.ts +1 -1
  30. package/lib/backtop/index.js +189 -1
  31. package/lib/badge/badge.css +8 -2
  32. package/lib/badge/badge.d.ts +2 -2
  33. package/lib/badge/badge.less +8 -4
  34. package/lib/badge/badge.variable.css +14 -4
  35. package/lib/badge/index.d.ts +7 -7
  36. package/lib/badge/index.js +236 -1
  37. package/lib/breadcrumb/breadcrumb.css +4 -4
  38. package/lib/breadcrumb/breadcrumb.variable.css +10 -6
  39. package/lib/breadcrumb/index.d.ts +2 -2
  40. package/lib/breadcrumb/index.js +310 -1
  41. package/lib/button/button-group.d.ts +2 -2
  42. package/lib/button/button.css +30 -7
  43. package/lib/button/button.d.ts +1 -1
  44. package/lib/button/button.less +29 -13
  45. package/lib/button/button.variable.css +44 -17
  46. package/lib/button/index.d.ts +7 -7
  47. package/lib/button/index.js +329 -1
  48. package/lib/card/card.css +11 -11
  49. package/lib/card/card.d.ts +1 -1
  50. package/lib/card/card.less +7 -7
  51. package/lib/card/card.variable.css +17 -13
  52. package/lib/card/index.d.ts +4 -4
  53. package/lib/card/index.js +292 -1
  54. package/lib/cascader/cascader-panel.d.ts +1 -0
  55. package/lib/cascader/cascader.css +7 -7
  56. package/lib/cascader/cascader.d.ts +1 -0
  57. package/lib/cascader/cascader.less +4 -6
  58. package/lib/cascader/cascader.variable.css +13 -9
  59. package/lib/cascader/index.d.ts +6 -2
  60. package/lib/cascader/index.js +2072 -2
  61. package/lib/cascader/interface.d.ts +1 -1
  62. package/lib/checkbox/checkbox-group.d.ts +6 -3
  63. package/lib/checkbox/checkbox.css +13 -1
  64. package/lib/checkbox/checkbox.d.ts +15 -12
  65. package/lib/checkbox/checkbox.less +15 -1
  66. package/lib/checkbox/checkbox.variable.css +19 -3
  67. package/lib/checkbox/common.d.ts +1 -0
  68. package/lib/checkbox/index.d.ts +43 -31
  69. package/lib/checkbox/index.js +570 -1
  70. package/lib/code-diff/code-diff.variable.css +6 -2
  71. package/lib/code-diff/index.d.ts +1 -1
  72. package/lib/code-diff/index.js +5502 -1
  73. package/lib/collapse/collapse.variable.css +6 -2
  74. package/lib/collapse/index.d.ts +2 -2
  75. package/lib/collapse/index.js +571 -1
  76. package/lib/collapse-transition/collapse-transition.variable.css +6 -2
  77. package/lib/collapse-transition/index.d.ts +128 -2
  78. package/lib/collapse-transition/index.js +177 -1
  79. package/lib/color-picker/color-picker.d.ts +16 -0
  80. package/lib/color-picker/color-picker.variable.css +6 -2
  81. package/lib/color-picker/components/recommend-colors.d.ts +16 -0
  82. package/lib/color-picker/index.d.ts +19 -1
  83. package/lib/color-picker/index.js +2666 -1
  84. package/lib/components.js +530 -1
  85. package/lib/config-provider/config-provider.d.ts +21 -0
  86. package/lib/config-provider/config-provider.variable.css +6 -2
  87. package/lib/config-provider/index.d.ts +29 -1
  88. package/lib/config-provider/index.js +365 -1
  89. package/lib/config-provider/token.d.ts +7 -0
  90. package/lib/config-provider/use-global-config.d.ts +2 -0
  91. package/lib/config-provider/use-prefix.d.ts +2 -0
  92. package/lib/container/container.css +4 -4
  93. package/lib/container/container.variable.css +10 -6
  94. package/lib/container/index.d.ts +2 -2
  95. package/lib/container/index.js +392 -1
  96. package/lib/date-picker/common.d.ts +2 -0
  97. package/lib/date-picker/date-picker.d.ts +6 -2
  98. package/lib/date-picker/date-picker.variable.css +6 -2
  99. package/lib/date-picker/index.d.ts +21 -8
  100. package/lib/date-picker/index.js +5636 -1
  101. package/lib/date-picker/panel/date-range.d.ts +2 -1
  102. package/lib/date-picker/panel/date.d.ts +2 -2
  103. package/lib/date-picker/panel/time-range.d.ts +17 -0
  104. package/lib/date-picker/panel/time.d.ts +17 -1
  105. package/lib/date-picker/time-picker.d.ts +3 -1
  106. package/lib/dialog/dialog.css +9 -6
  107. package/lib/dialog/dialog.less +7 -6
  108. package/lib/dialog/dialog.variable.css +15 -8
  109. package/lib/dialog/index.d.ts +1 -1
  110. package/lib/dialog/index.js +984 -2
  111. package/lib/directives/index.js +1387 -2
  112. package/lib/directives/tooltips.d.ts +2 -2
  113. package/lib/dist.index.js +87 -1
  114. package/lib/divider/divider.variable.css +6 -2
  115. package/lib/divider/index.d.ts +1 -1
  116. package/lib/divider/index.js +170 -1
  117. package/lib/dropdown/dropdown.css +2 -1
  118. package/lib/dropdown/dropdown.variable.css +8 -3
  119. package/lib/dropdown/index.d.ts +2 -2
  120. package/lib/dropdown/index.js +376 -1
  121. package/lib/exception/exception.variable.css +6 -2
  122. package/lib/exception/index.d.ts +2 -2
  123. package/lib/exception/index.js +386 -1
  124. package/lib/fixed-navbar/fixed-navbar.variable.css +6 -2
  125. package/lib/fixed-navbar/index.d.ts +1 -1
  126. package/lib/fixed-navbar/index.js +155 -1
  127. package/lib/form/form.css +2 -1
  128. package/lib/form/form.less +3 -2
  129. package/lib/form/form.variable.css +8 -3
  130. package/lib/form/index.d.ts +3 -3
  131. package/lib/form/index.js +953 -1
  132. package/lib/hooks.d.ts +1 -1
  133. package/lib/hooks.js +73 -1
  134. package/lib/icon/angle-double-down-line.js +191 -1
  135. package/lib/icon/angle-double-left-line.js +191 -1
  136. package/lib/icon/angle-double-left.js +191 -1
  137. package/lib/icon/angle-double-right-line.js +191 -1
  138. package/lib/icon/angle-double-right.js +191 -1
  139. package/lib/icon/angle-double-up-line.js +191 -1
  140. package/lib/icon/angle-down-fill.js +191 -1
  141. package/lib/icon/angle-down-line.js +191 -1
  142. package/lib/icon/angle-down.js +191 -1
  143. package/lib/icon/angle-left.js +191 -1
  144. package/lib/icon/angle-right.js +191 -1
  145. package/lib/icon/angle-up-fill.js +191 -1
  146. package/lib/icon/angle-up.js +191 -1
  147. package/lib/icon/archive-fill.js +191 -1
  148. package/lib/icon/arrows-left.js +191 -1
  149. package/lib/icon/arrows-right.js +191 -1
  150. package/lib/icon/assistant.d.ts +4 -0
  151. package/lib/icon/assistant.js +191 -0
  152. package/lib/icon/audio-fill.js +191 -1
  153. package/lib/icon/bk.js +191 -1
  154. package/lib/icon/circle.js +191 -1
  155. package/lib/icon/close-line.js +191 -1
  156. package/lib/icon/close.js +191 -1
  157. package/lib/icon/code.js +191 -1
  158. package/lib/icon/cog-shape.js +191 -1
  159. package/lib/icon/collapse-left.js +191 -1
  160. package/lib/icon/copy-shape.js +191 -1
  161. package/lib/icon/copy.js +191 -1
  162. package/lib/icon/data-shape.js +191 -1
  163. package/lib/icon/del.js +191 -1
  164. package/lib/icon/doc-fill.js +191 -1
  165. package/lib/icon/done.js +191 -1
  166. package/lib/icon/down-shape.js +191 -1
  167. package/lib/icon/down-small.js +191 -1
  168. package/lib/icon/edit-line.js +191 -1
  169. package/lib/icon/ellipsis.js +191 -1
  170. package/lib/icon/enlarge-line.js +191 -1
  171. package/lib/icon/error.js +191 -1
  172. package/lib/icon/excel-fill.js +191 -1
  173. package/lib/icon/exclamation-circle-shape.js +191 -1
  174. package/lib/icon/eye.js +191 -1
  175. package/lib/icon/filliscreen-line.js +191 -1
  176. package/lib/icon/fix-line.js +191 -1
  177. package/lib/icon/fix-shape.js +191 -1
  178. package/lib/icon/folder-open.js +191 -1
  179. package/lib/icon/folder-shape-open.js +191 -1
  180. package/lib/icon/folder-shape.js +191 -1
  181. package/lib/icon/folder.js +191 -1
  182. package/lib/icon/funnel.js +191 -1
  183. package/lib/icon/help-document-fill.js +191 -1
  184. package/lib/icon/help-fill.js +191 -1
  185. package/lib/icon/help.js +191 -1
  186. package/lib/icon/image-fill.js +276 -1
  187. package/lib/icon/img-error.js +276 -1
  188. package/lib/icon/img-placehoulder.js +276 -1
  189. package/lib/icon/index.d.ts +2 -0
  190. package/lib/icon/index.js +2432 -1
  191. package/lib/icon/info-line.js +276 -1
  192. package/lib/icon/info.js +276 -1
  193. package/lib/icon/left-shape.js +276 -1
  194. package/lib/icon/left-turn-line.js +276 -1
  195. package/lib/icon/loading.d.ts +4 -0
  196. package/lib/icon/loading.js +276 -0
  197. package/lib/icon/narrow-line.js +276 -1
  198. package/lib/icon/original.js +276 -1
  199. package/lib/icon/pdf-fill.js +276 -1
  200. package/lib/icon/play-shape.js +276 -1
  201. package/lib/icon/plus.js +276 -1
  202. package/lib/icon/ppt-fill.js +276 -1
  203. package/lib/icon/qq.js +276 -1
  204. package/lib/icon/right-shape.js +276 -1
  205. package/lib/icon/right-turn-line.js +276 -1
  206. package/lib/icon/search.js +276 -1
  207. package/lib/icon/share.js +276 -1
  208. package/lib/icon/spinner.js +276 -1
  209. package/lib/icon/success.js +276 -1
  210. package/lib/icon/switcher-loading.js +276 -1
  211. package/lib/icon/text-file.js +276 -1
  212. package/lib/icon/text-fill.js +276 -1
  213. package/lib/icon/transfer.js +276 -1
  214. package/lib/icon/tree-application-shape.js +276 -1
  215. package/lib/icon/unfull-screen.js +276 -1
  216. package/lib/icon/unvisible.js +276 -1
  217. package/lib/icon/up-shape.js +276 -1
  218. package/lib/icon/upload.js +276 -1
  219. package/lib/icon/video-fill.js +276 -1
  220. package/lib/icon/warn.js +276 -1
  221. package/lib/icon/weixin-pro.js +276 -1
  222. package/lib/icon/weixin.js +276 -1
  223. package/lib/image/image-viewer.variable.css +6 -2
  224. package/lib/image/image.variable.css +6 -2
  225. package/lib/image/index.d.ts +1 -1
  226. package/lib/image/index.js +641 -1
  227. package/lib/index.js +97 -1
  228. package/lib/info-box/index.js +1174 -2
  229. package/lib/info-box/info-box.css +2 -0
  230. package/lib/info-box/info-box.d.ts +4 -0
  231. package/lib/info-box/info-box.less +2 -1
  232. package/lib/info-box/info-box.variable.css +8 -2
  233. package/lib/input/index.d.ts +90 -12
  234. package/lib/input/index.js +1234 -1
  235. package/lib/input/input.css +51 -19
  236. package/lib/input/input.d.ts +79 -6
  237. package/lib/input/input.less +50 -13
  238. package/lib/input/input.variable.css +57 -21
  239. package/lib/input/util.d.ts +6 -0
  240. package/lib/link/index.d.ts +4 -4
  241. package/lib/link/index.js +161 -1
  242. package/lib/link/link.d.ts +1 -1
  243. package/lib/link/link.variable.css +6 -2
  244. package/lib/loading/index.d.ts +5 -5
  245. package/lib/loading/index.js +382 -1
  246. package/lib/loading/loading.css +13 -13
  247. package/lib/loading/loading.d.ts +1 -1
  248. package/lib/loading/loading.less +14 -9
  249. package/lib/loading/loading.variable.css +19 -15
  250. package/lib/locale/index.js +477 -1
  251. package/lib/locale/lang/en.d.ts +7 -0
  252. package/lib/menu/index.d.ts +2 -2
  253. package/lib/menu/index.js +725 -1
  254. package/lib/menu/menu.css +4 -4
  255. package/lib/menu/menu.variable.css +10 -6
  256. package/lib/menu/submenu.variable.css +6 -2
  257. package/lib/message/index.js +1796 -2
  258. package/lib/message/message.css +18 -2
  259. package/lib/message/message.less +16 -2
  260. package/lib/message/message.variable.css +24 -4
  261. package/lib/message/messageConstructor.d.ts +23 -3
  262. package/lib/modal/index.d.ts +2 -2
  263. package/lib/modal/index.js +397 -1
  264. package/lib/modal/modal.css +2 -0
  265. package/lib/modal/modal.variable.css +8 -2
  266. package/lib/navigation/index.d.ts +4 -1
  267. package/lib/navigation/index.js +368 -1
  268. package/lib/navigation/navigation.d.ts +1 -0
  269. package/lib/navigation/navigation.variable.css +6 -2
  270. package/lib/notify/index.js +398 -1
  271. package/lib/notify/notify.css +6 -6
  272. package/lib/notify/notify.less +6 -6
  273. package/lib/notify/notify.variable.css +12 -8
  274. package/lib/notify/notifyConstructor.d.ts +1 -1
  275. package/lib/overflow-title/components/overflow-title.d.ts +257 -2
  276. package/lib/overflow-title/index.d.ts +387 -2
  277. package/lib/overflow-title/index.js +292 -1
  278. package/lib/overflow-title/props.d.ts +129 -0
  279. package/lib/pagination/index.d.ts +6 -6
  280. package/lib/pagination/index.js +894 -1
  281. package/lib/pagination/pagination.css +1 -0
  282. package/lib/pagination/pagination.d.ts +3 -3
  283. package/lib/pagination/pagination.less +1 -0
  284. package/lib/pagination/pagination.variable.css +7 -2
  285. package/lib/plugin-popover/index.js +3833 -1
  286. package/lib/plugins/index.js +63 -1
  287. package/lib/pop-confirm/index.d.ts +43 -4
  288. package/lib/pop-confirm/index.js +294 -1
  289. package/lib/pop-confirm/pop-confirm.css +4 -4
  290. package/lib/pop-confirm/pop-confirm.d.ts +14 -1
  291. package/lib/pop-confirm/pop-confirm.less +4 -4
  292. package/lib/pop-confirm/pop-confirm.variable.css +10 -6
  293. package/lib/popover/content.d.ts +33 -0
  294. package/lib/popover/index.d.ts +74 -16
  295. package/lib/popover/index.js +3842 -1
  296. package/lib/popover/popover.css +2 -1
  297. package/lib/popover/popover.d.ts +40 -7
  298. package/lib/popover/popover.less +4 -3
  299. package/lib/popover/popover.variable.css +8 -3
  300. package/lib/popover/props.d.ts +25 -2
  301. package/lib/popover/use-floating.d.ts +1 -1
  302. package/lib/popover/use-popover-init.d.ts +2 -1
  303. package/lib/popover2/index.d.ts +1 -1
  304. package/lib/popover2/index.js +107 -1
  305. package/lib/preset.d.ts +14 -0
  306. package/lib/preset.js +93 -1
  307. package/lib/process/index.d.ts +1 -1
  308. package/lib/process/index.js +759 -2
  309. package/lib/process/process.variable.css +6 -2
  310. package/lib/progress/index.d.ts +5 -5
  311. package/lib/progress/index.js +432 -1
  312. package/lib/progress/progress.css +11 -7
  313. package/lib/progress/progress.d.ts +3 -3
  314. package/lib/progress/progress.less +8 -3
  315. package/lib/progress/progress.variable.css +17 -9
  316. package/lib/radio/common.d.ts +1 -0
  317. package/lib/radio/index.d.ts +31 -25
  318. package/lib/radio/index.js +636 -1
  319. package/lib/radio/radio-button.d.ts +8 -7
  320. package/lib/radio/radio-group.d.ts +7 -4
  321. package/lib/radio/radio.css +26 -12
  322. package/lib/radio/radio.d.ts +5 -4
  323. package/lib/radio/radio.less +42 -8
  324. package/lib/radio/radio.variable.css +26 -8
  325. package/lib/rate/index.d.ts +12 -8
  326. package/lib/rate/index.js +355 -1
  327. package/lib/rate/rate.d.ts +4 -3
  328. package/lib/rate/rate.variable.css +6 -2
  329. package/lib/rate/star.css +3 -0
  330. package/lib/rate/star.less +3 -0
  331. package/lib/rate/star.variable.css +9 -2
  332. package/lib/resize-layout/index.d.ts +4 -4
  333. package/lib/resize-layout/index.js +430 -1
  334. package/lib/resize-layout/resize-layout.css +14 -2
  335. package/lib/resize-layout/resize-layout.d.ts +1 -1
  336. package/lib/resize-layout/resize-layout.less +14 -2
  337. package/lib/resize-layout/resize-layout.variable.css +20 -4
  338. package/lib/search-select/index.d.ts +62 -29
  339. package/lib/search-select/index.js +2747 -2
  340. package/lib/search-select/input.d.ts +5 -1
  341. package/lib/search-select/menu.d.ts +33 -2
  342. package/lib/search-select/search-select.css +39 -21
  343. package/lib/search-select/search-select.d.ts +23 -20
  344. package/lib/search-select/search-select.less +44 -23
  345. package/lib/search-select/search-select.variable.css +45 -23
  346. package/lib/search-select/selected.d.ts +5 -1
  347. package/lib/search-select/utils.d.ts +13 -5
  348. package/lib/select/common.d.ts +4 -1
  349. package/lib/select/index.d.ts +287 -90
  350. package/lib/select/index.js +2422 -2
  351. package/lib/select/option.d.ts +12 -0
  352. package/lib/select/select.css +16 -5
  353. package/lib/select/select.d.ts +120 -39
  354. package/lib/select/select.less +14 -1
  355. package/lib/select/select.variable.css +46 -31
  356. package/lib/select/selectTagInput.d.ts +10 -5
  357. package/lib/select/type.d.ts +3 -0
  358. package/lib/shared/helper.d.ts +1 -1
  359. package/lib/shared/index.js +2690 -1
  360. package/lib/shared/mask-manager.d.ts +3 -4
  361. package/lib/shared/pop-manager.d.ts +6 -2
  362. package/lib/shared/popover.d.ts +2 -2
  363. package/lib/shared/vue-types.d.ts +4 -3
  364. package/lib/sideslider/index.d.ts +1 -1
  365. package/lib/sideslider/index.js +711 -2
  366. package/lib/sideslider/sideslider.variable.css +6 -2
  367. package/lib/slider/index.d.ts +1 -1
  368. package/lib/slider/index.js +1310 -2
  369. package/lib/slider/slider.css +2 -0
  370. package/lib/slider/slider.less +2 -0
  371. package/lib/slider/slider.variable.css +8 -2
  372. package/lib/steps/index.d.ts +5 -5
  373. package/lib/steps/index.js +826 -2
  374. package/lib/steps/steps.css +18 -6
  375. package/lib/steps/steps.d.ts +3 -3
  376. package/lib/steps/steps.less +26 -5
  377. package/lib/steps/steps.variable.css +24 -8
  378. package/lib/styles/index.d.ts +1 -0
  379. package/lib/styles/mixins/animate.css +4 -4
  380. package/lib/styles/mixins/animate.less +10 -6
  381. package/lib/styles/mixins/animate.variable.css +130 -4
  382. package/lib/styles/mixins/mixins.css +4 -4
  383. package/lib/styles/mixins/mixins.variable.css +4 -4
  384. package/lib/styles/mixins/popper.variable.css +6 -2
  385. package/lib/styles/mixins/scroll.variable.css +6 -2
  386. package/lib/styles/reset.variable.css +6 -2
  387. package/lib/styles/themes/themes.less +7 -3
  388. package/lib/swiper/index.d.ts +1 -1
  389. package/lib/swiper/index.js +337 -1
  390. package/lib/swiper/swiper.css +0 -6
  391. package/lib/swiper/swiper.less +0 -8
  392. package/lib/swiper/swiper.variable.css +6 -8
  393. package/lib/switcher/index.d.ts +34 -20
  394. package/lib/switcher/index.js +278 -1
  395. package/lib/switcher/switcher.css +4 -4
  396. package/lib/switcher/switcher.d.ts +76 -7
  397. package/lib/switcher/switcher.variable.css +10 -6
  398. package/lib/tab/index.d.ts +3 -3
  399. package/lib/tab/index.js +915 -1
  400. package/lib/tab/tab-nav.d.ts +12 -2
  401. package/lib/tab/tab-panel.d.ts +1 -1
  402. package/lib/tab/tab.variable.css +6 -2
  403. package/lib/table/components/table-cell.d.ts +22 -24
  404. package/lib/table/components/table-column.d.ts +100 -71
  405. package/lib/table/const.d.ts +25 -3
  406. package/lib/table/events.d.ts +26 -26
  407. package/lib/table/index.d.ts +309 -191
  408. package/lib/table/index.js +6562 -1
  409. package/lib/table/plugins/body-empty.d.ts +1 -1
  410. package/lib/table/plugins/head-filter.css +4 -28
  411. package/lib/table/plugins/head-filter.d.ts +2 -7
  412. package/lib/table/plugins/head-filter.less +5 -34
  413. package/lib/table/plugins/head-filter.variable.css +10 -30
  414. package/lib/table/plugins/head-sort.d.ts +2 -7
  415. package/lib/table/plugins/head-sort.variable.css +6 -2
  416. package/lib/table/plugins/settings.d.ts +2 -19
  417. package/lib/table/plugins/settings.variable.css +6 -2
  418. package/lib/table/plugins/use-column-resize.d.ts +30 -10
  419. package/lib/table/plugins/use-fixed-column.d.ts +9 -9
  420. package/lib/table/plugins/use-head-cell.d.ts +7 -0
  421. package/lib/table/plugins/use-pagination.d.ts +8 -4
  422. package/lib/table/props.d.ts +84 -52
  423. package/lib/table/table.css +117 -53
  424. package/lib/table/table.d.ts +91 -68
  425. package/lib/table/table.less +70 -26
  426. package/lib/table/table.variable.css +123 -55
  427. package/lib/table/use-attributes.d.ts +59 -0
  428. package/lib/table/use-column.d.ts +264 -53
  429. package/lib/table/use-common.d.ts +1607 -88
  430. package/lib/table/use-render.d.ts +11 -0
  431. package/lib/table/utils.d.ts +34 -31
  432. package/lib/table-column/index.d.ts +356 -113
  433. package/lib/table-column/index.js +775 -1
  434. package/lib/tag/index.d.ts +10 -10
  435. package/lib/tag/index.js +234 -1
  436. package/lib/tag/tag.d.ts +5 -5
  437. package/lib/tag/tag.variable.css +6 -2
  438. package/lib/tag-input/index.d.ts +49 -7
  439. package/lib/tag-input/index.js +1678 -1
  440. package/lib/tag-input/list-tag-render.d.ts +11 -0
  441. package/lib/tag-input/tag-input.css +8 -0
  442. package/lib/tag-input/tag-input.d.ts +46 -6
  443. package/lib/tag-input/tag-input.less +9 -0
  444. package/lib/tag-input/tag-input.variable.css +14 -2
  445. package/lib/tag-input/tag-props.d.ts +16 -2
  446. package/lib/time-picker/index.d.ts +10 -4
  447. package/lib/time-picker/index.js +72 -1
  448. package/lib/time-picker/time-picker.css +4 -3
  449. package/lib/time-picker/time-picker.less +5 -9
  450. package/lib/time-picker/time-picker.variable.css +10 -5
  451. package/lib/timeline/index.d.ts +1 -1
  452. package/lib/timeline/index.js +241 -1
  453. package/lib/timeline/timeline.variable.css +6 -2
  454. package/lib/transfer/index.d.ts +1 -1
  455. package/lib/transfer/index.js +687 -1
  456. package/lib/transfer/transfer.css +2 -2
  457. package/lib/transfer/transfer.less +2 -2
  458. package/lib/transfer/transfer.variable.css +8 -4
  459. package/lib/tree/constant.d.ts +2 -2
  460. package/lib/tree/index.d.ts +70 -40
  461. package/lib/tree/index.js +2603 -1
  462. package/lib/tree/props.d.ts +20 -10
  463. package/lib/tree/tree.css +13 -1
  464. package/lib/tree/tree.d.ts +42 -21
  465. package/lib/tree/tree.variable.css +19 -3
  466. package/lib/tree/use-empty.d.ts +1 -3
  467. package/lib/tree/use-node-action.d.ts +5 -3
  468. package/lib/tree/use-node-attribute.d.ts +17 -8
  469. package/lib/tree/use-search.d.ts +2 -2
  470. package/lib/tree/use-tree-init.d.ts +1 -2
  471. package/lib/tree/util.d.ts +9 -3
  472. package/lib/upload/index.d.ts +1 -1
  473. package/lib/upload/index.js +2888 -2
  474. package/lib/upload/upload.css +4 -4
  475. package/lib/upload/upload.type.d.ts +1 -1
  476. package/lib/upload/upload.variable.css +10 -6
  477. package/lib/upload/use-file-handler.d.ts +2 -2
  478. package/lib/virtual-render/index.d.ts +43 -1
  479. package/lib/virtual-render/index.js +902 -1
  480. package/lib/virtual-render/props.d.ts +15 -0
  481. package/lib/virtual-render/use-fix-top.d.ts +18 -0
  482. package/lib/virtual-render/v-virtual-render.d.ts +24 -1
  483. package/lib/virtual-render/virtual-render.d.ts +25 -0
  484. package/lib/virtual-render/virtual-render.variable.css +6 -2
  485. package/lib/volar.components.d.ts +24 -24
  486. package/package.json +34 -19
  487. package/dist/index.cjs.source.js +0 -45605
  488. package/dist/index.esm.source.js +0 -45605
  489. package/dist/index.umd.source.js +0 -45608
  490. package/lib/cascader/index.js.LICENSE.txt +0 -1
  491. package/lib/dialog/index.js.LICENSE.txt +0 -1
  492. package/lib/directives/index.js.LICENSE.txt +0 -14
  493. package/lib/info-box/index.js.LICENSE.txt +0 -1
  494. package/lib/message/index.js.LICENSE.txt +0 -6
  495. package/lib/process/index.js.LICENSE.txt +0 -1
  496. package/lib/search-select/index.js.LICENSE.txt +0 -1
  497. package/lib/select/index.js.LICENSE.txt +0 -1
  498. package/lib/sideslider/index.js.LICENSE.txt +0 -1
  499. package/lib/slider/index.js.LICENSE.txt +0 -1
  500. package/lib/steps/index.js.LICENSE.txt +0 -1
  501. package/lib/table/render.d.ts +0 -140
  502. package/lib/upload/index.js.LICENSE.txt +0 -1
  503. /package/lib/overflow-title/{overflow.css → overflow-title.css} +0 -0
  504. /package/lib/overflow-title/{overflow.less → overflow-title.less} +0 -0
  505. /package/lib/overflow-title/{overflow.variable.css → overflow-title.variable.css} +0 -0
@@ -1 +1,894 @@
1
- !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("../shared"),require("vue"),require("../config-provider"),require("../select"),require("../icon"),require("../popover"));else if("function"==typeof define&&define.amd)define(["../shared","vue","../config-provider","../select","../icon","../popover"],t);else{var n="object"==typeof exports?t(require("../shared"),require("vue"),require("../config-provider"),require("../select"),require("../icon"),require("../popover")):t(e["../shared"],e.vue,e["../config-provider"],e["../select"],e["../icon"],e["../popover"]);for(var a in n)("object"==typeof exports?exports:e)[a]=n[a]}}(self,((e,t,n,a,r,o)=>(()=>{"use strict";var i={2717:e=>{e.exports=n},6870:e=>{e.exports=r},5537:e=>{e.exports=o},6422:e=>{e.exports=a},4212:t=>{t.exports=e},748:e=>{e.exports=t}},l={};function u(e){var t=l[e];if(void 0!==t)return t.exports;var n=l[e]={exports:{}};return i[e](n,n.exports,u),n.exports}u.n=e=>{var t=e&&e.__esModule?()=>e.default:()=>e;return u.d(t,{a:t}),t},u.d=(e,t)=>{for(var n in t)u.o(t,n)&&!u.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},u.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),u.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var c={};return(()=>{u.r(c),u.d(c,{BkPagination:()=>g,default:()=>y});var e=u(4212);function t(e){return t="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(e)}function n(e,n,a){return(n=function(e){var n=function(e,n){if("object"!==t(e)||null===e)return e;var a=e[Symbol.toPrimitive];if(void 0!==a){var r=a.call(e,"string");if("object"!==t(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===t(n)?n:String(n)}(n))in e?Object.defineProperty(e,n,{value:a,enumerable:!0,configurable:!0,writable:!0}):e[n]=a,e}function a(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,a=new Array(t);n<t;n++)a[n]=e[n];return a}function r(e,t){return function(e){if(Array.isArray(e))return e}(e)||function(e,t){var n=null==e?null:"undefined"!=typeof Symbol&&e[Symbol.iterator]||e["@@iterator"];if(null!=n){var a,r,o,i,l=[],u=!0,c=!1;try{if(o=(n=n.call(e)).next,0===t){if(Object(n)!==n)return;u=!1}else for(;!(u=(a=o.call(n)).done)&&(l.push(a.value),l.length!==t);u=!0);}catch(e){c=!0,r=e}finally{try{if(!u&&null!=n.return&&(i=n.return(),Object(i)!==i))return}finally{if(c)throw r}}return l}}(e,t)||function(e,t){if(e){if("string"==typeof e)return a(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);return"Object"===n&&e.constructor&&(n=e.constructor.name),"Map"===n||"Set"===n?Array.from(e):"Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)?a(e,t):void 0}}(e,t)||function(){throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var o=u(748),i=u(2717),l=u(6422),s=u.n(l),f=u(6870),d=u(5537),v=u.n(d);var p={modelValue:e.PropTypes.number.def(1),count:e.PropTypes.number.def(0).isRequired,limit:e.PropTypes.number.def(10),limitList:e.PropTypes.arrayOf(Number).def([10,20,50,100]),showLimit:e.PropTypes.bool.def(!0),type:e.PropTypes.oneOf(["default","compact"]).def("default"),location:e.PropTypes.oneOf(["left","right"]).def("right"),align:e.PropTypes.oneOf(["left","center","right"]).def("left"),size:e.PropTypes.size(),small:e.PropTypes.bool.def(!1),showTotalCount:e.PropTypes.bool.def(!0),prevText:e.PropTypes.string,nextText:e.PropTypes.string,disabled:e.PropTypes.bool.def(!1),beforeChange:e.PropTypes.func,layout:e.PropTypes.custom((function(e){var t={total:!0,list:!0,limit:!0};return e.some((function(e){return t[e]}))}),"layout 的值只支持 * total、list、limit *").def(["total","list","limit"])};const m=(0,o.defineComponent)({name:"Pagination",props:p,emits:["update:modelValue","change","update:limit","limitChange"],setup:function(e,t){var a=(0,i.useLocale)("pagination"),u=(0,o.ref)(0),c=(0,o.toRefs)(e),d=c.count,p=c.limit,m=function(e){return function(t){var a,r=t.isFirst,l=t.isLast,u=(0,o.getCurrentInstance)().props;if(!u.showTotalCount)return null;var c=(0,i.usePrefix)().resolveClassName;return(0,o.createVNode)("div",(0,o.mergeProps)({class:(a={},n(a,"".concat(c("pagination-total")),!0),n(a,"is-first",r),n(a,"is-last",l),a)},{disabled:u.disabled}),[e.value.total,(0,o.createVNode)("div",{class:"".concat(c("pagination-total-num"))},[u.count]),e.value.strip])}}(a),g=function(){var e=(0,o.getCurrentInstance)().proxy,t=(0,o.ref)(1),a=(0,o.computed)((function(){return 1===t.value})),r=(0,o.computed)((function(){return t.value===e.totalPageNum})),l=(0,o.ref)(!1),u=(0,o.ref)(!1),c=(0,o.computed)((function(){l.value=!1,u.value=!1;var n=[];if(e.totalPageNum<=7){for(var a=2;a<=e.totalPageNum-1;a++)n.push(a);return n}var r=Math.floor(2.5);e.totalPageNum>5&&(l.value=t.value-r>2,u.value=t.value+r<e.totalPageNum-1);for(var o=Math.min(e.totalPageNum-5,Math.max(2,t.value-r)),i=o;i<o+5;i++)n.push(i);return n}));(0,o.watch)((function(){return e.modelValue}),(function(n){(0,o.nextTick)((function(){n>=1&&n<=e.totalPageNum?t.value=n:t.value=n<1?1:e.totalPageNum}))}),{immediate:!0}),(0,o.nextTick)((function(){(0,o.watch)((function(){return e.totalPageNum}),(function(e){t.value>e&&(t.value=e)}))}));var s=function(){a.value||(t.value=t.value-1)},d=function(){r.value||(t.value=t.value+1)},v=function(e){e!==t.value&&(t.value=e)},p=function(){t.value=Math.max(1,t.value-5)},m=function(){t.value=Math.min(e.totalPageNum,t.value+5)},g=(0,i.usePrefix)().resolveClassName;return{current:t,render:function(i){var y,b,h,N,P,x=i.isFirst,V=i.isLast;return(0,o.createVNode)("div",{class:(y={},n(y,"".concat(g("pagination-list")),!0),n(y,"is-first",x),n(y,"is-last",V),y)},[(0,o.createVNode)("div",{class:(b={},n(b,"".concat(g("pagination-list-pre")),!0),n(b,"is-disabled",a.value),b),onClick:s},[e.prevText||(0,o.createVNode)(f.AngleLeft,null,null)]),(0,o.createVNode)("div",{class:(h={},n(h,"".concat(g("pagination-list-item")),!0),n(h,"is-active",1===t.value),h),key:"1",onClick:function(){return v(1)}},[(0,o.createTextVNode)("1")]),l.value&&(0,o.createVNode)("div",{key:"pre-batch",class:"".concat(g("pagination-list-pre-batch")),onClick:p},[(0,o.createVNode)(f.Ellipsis,null,null)]),c.value.map((function(e){var a;return(0,o.createVNode)("div",{class:(a={},n(a,"".concat(g("pagination-list-item")),!0),n(a,"is-active",t.value===e),a),key:e,onClick:function(){return v(e)}},[e])})),u.value&&(0,o.createVNode)("div",{key:"next-batch",class:"".concat(g("pagination-list-next-batch")),onClick:m},[(0,o.createVNode)(f.Ellipsis,null,null)]),e.totalPageNum>1&&(0,o.createVNode)("div",{class:(N={},n(N,"".concat(g("pagination-list-item")),!0),n(N,"is-active",t.value===e.totalPageNum),N),key:"last",onClick:function(){return v(e.totalPageNum)}},[e.totalPageNum]),(0,o.createVNode)("div",{class:(P={},n(P,"".concat(g("pagination-list-pre")),!0),n(P,"is-disabled",r.value),P),onClick:d},[e.nextText||(0,o.createVNode)(f.AngleRight,null,null)])])}}}(),y=g.current,b=g.render,h=function(){var e=(0,o.getCurrentInstance)().proxy,t=(0,o.ref)(null),a=(0,o.ref)(!1),r=(0,o.ref)(1),l=(0,o.computed)((function(){return 1===r.value})),u=(0,o.computed)((function(){return r.value===e.totalPageNum})),c=0,s=(0,o.computed)((function(){for(var t=[],n=1;n<=e.totalPageNum;n++)t.push(n);return t}));(0,o.watch)((function(){return e.modelValue}),(function(t){(0,o.nextTick)((function(){t>=1&&t<=e.totalPageNum?r.value=t:r.value=t<1?1:e.totalPageNum,c=r.value}))}),{immediate:!0}),(0,o.nextTick)((function(){(0,o.watch)((function(){return e.totalPageNum}),(function(e){r.value>e&&(r.value=e)}))}));var d=function(){l.value||(r.value=r.value-1)},p=function(){u.value||(r.value=r.value+1)},m=function(){a.value=!0},g=function(){a.value=!1,t.value.textContent="".concat(c),c!==r.value&&(r.value=c)},y=function(t){var n=t.target,a=Number(n.textContent);!a||a<1||a>e.totalPageNum||a===r.value||(c=a)},b=function(e){["Enter","NumpadEnter"].includes(e.code)&&(e.preventDefault(),g())},h=(0,i.usePrefix)().resolveClassName;return{current:r,render:function(){var i,N;return(0,o.createVNode)("div",{class:"".concat(h("pagination-small-list"))},[(0,o.createVNode)("div",{class:(i={},n(i,"".concat(h("pagination-btn-pre")),!0),n(i,"is-disabled",l.value),i),onClick:d},[(0,o.createVNode)(f.AngleLeft,null,null)]),(0,o.createVNode)(v(),{theme:"light",trigger:"click",arrow:!1,width:56,boundary:"body",placement:"bottom"},{default:function(){var i;return(0,o.createVNode)("div",{class:(i={},n(i,"".concat(h("pagination-picker")),!0),n(i,"is-focused",a.value),i)},[(0,o.createVNode)("span",{ref:t,class:"".concat(h("pagination-editor")),contenteditable:!0,spellcheck:"false",onFocus:m,onBlur:g,onInput:y,onKeydown:b},[r.value]),(0,o.createVNode)("span",null,[(0,o.createTextVNode)("/")]),(0,o.createVNode)("span",{class:"".concat(h("pagination-small-list-total"))},[e.totalPageNum])])},content:function(){return(0,o.createVNode)("div",{class:"".concat(h("pagination-picker-list"))},[s.value.map((function(e){return(0,o.createVNode)("div",{class:{item:!0,"is-actived":e===r.value},key:e,onClick:function(){return function(e){c=e,g()}(e)}},[e])}))])}}),(0,o.createVNode)("div",{class:(N={},n(N,"".concat(h("pagination-btn-next")),!0),n(N,"is-disabled",u.value),N),onClick:p},[(0,o.createVNode)(f.AngleRight,null,null)])])}}}(),N=h.current,P=h.render,x=function(e){var t=(0,o.getCurrentInstance)().proxy,a=(0,o.ref)(t.limit);(0,o.watch)((function(){return t.limit}),(function(e){a.value=e})),(0,o.watch)((function(){return t.limitList}),(function(e){(0,o.nextTick)((function(){if(!e.includes(a.value)){var t=r(e,1);a.value=t[0]}}))}),{immediate:!0});var u=function(e){a.value=e},c=(0,i.usePrefix)().resolveClassName;return{limit:a,render:function(r){var i,f,d,v=r.isFirst,p=r.isLast;return t.showLimit?(0,o.createVNode)("div",(0,o.mergeProps)({class:(f={},n(f,c("pagination-limit"),!0),n(f,"is-first",v),n(f,"is-last",p),f)},{disabled:t.disabled}),[(0,o.createVNode)("div",null,[e.value.eachPage]),(0,o.createVNode)(s(),{class:"".concat(c("pagination-limit-select")),clearable:!1,size:"small",withValidate:!1,modelValue:a.value,onChange:u,disabled:t.disabled},(d=i=t.limitList.map((function(e,t){return(0,o.createVNode)(l.BkOption,{id:e,name:"".concat(e),key:"".concat(t,"_").concat(e)},null)})),"function"==typeof d||"[object Object]"===Object.prototype.toString.call(d)&&!(0,o.isVNode)(d)?i:{default:function(){return[i]}})),(0,o.createVNode)("div",null,[e.value.strip])]):null}}}(a),V=x.limit,T=x.render;(0,o.watch)([d,V,p],(function(e){var t=r(e,2),n=t[0],a=t[1],o=Math.ceil(n/a);u.value=o<1?1:o}),{immediate:!0}),(0,o.watch)(y,(function(e){t.emit("update:modelValue",e),t.emit("change",e)})),(0,o.watch)(N,(function(n){e.small&&(t.emit("update:modelValue",n),t.emit("change",n))})),(0,o.watch)(V,(function(e){t.emit("limitChange",e)}));var C=(0,i.usePrefix)().resolveClassName;return{totalPageNum:u,renderTotal:m,renderList:b,renderLimit:T,renderSmallList:P,resolveClassName:C}},render:function(){var t,a=this,r=(0,e.classes)((n(t={},"".concat(this.resolveClassName("pagination")),!0),n(t,"".concat(this.resolveClassName("pagination--".concat(this.size))),!0),n(t,"is-align-".concat(this.align),!0),t)),i={total:this.renderTotal,list:this.small?this.renderSmallList:this.renderList,limit:this.renderLimit};return(0,o.createVNode)("div",{class:r},[this.layout.map((function(e,t){return i[e]({isFirst:0===t,isLast:t===a.layout.length-1})}))])}});var g=(0,e.withInstall)(m);const y=g})(),c})()));
1
+ import "./pagination.less";
2
+ import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_shared_edbdfb03__ from "../shared";
3
+ import * as __WEBPACK_EXTERNAL_MODULE_vue__ from "vue";
4
+ import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_config_provider_fe8577a3__ from "../config-provider";
5
+ import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_select_1a0d1ad7__ from "../select";
6
+ import "../select/select.less";
7
+ import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__ from "../icon";
8
+ import * as __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_popover_9b03f19d__ from "../popover";
9
+ import "../popover/popover.less";
10
+ /******/ // The require scope
11
+ /******/ var __webpack_require__ = {};
12
+ /******/
13
+ /************************************************************************/
14
+ /******/ /* webpack/runtime/define property getters */
15
+ /******/ (() => {
16
+ /******/ // define getter functions for harmony exports
17
+ /******/ __webpack_require__.d = (exports, definition) => {
18
+ /******/ for(var key in definition) {
19
+ /******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
20
+ /******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
21
+ /******/ }
22
+ /******/ }
23
+ /******/ };
24
+ /******/ })();
25
+ /******/
26
+ /******/ /* webpack/runtime/hasOwnProperty shorthand */
27
+ /******/ (() => {
28
+ /******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
29
+ /******/ })();
30
+ /******/
31
+ /************************************************************************/
32
+ var __webpack_exports__ = {};
33
+
34
+ // EXPORTS
35
+ __webpack_require__.d(__webpack_exports__, {
36
+ h: () => (/* binding */ BkPagination),
37
+ Z: () => (/* binding */ src)
38
+ });
39
+
40
+ ;// CONCATENATED MODULE: external "../shared"
41
+ var x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
42
+ var y = x => () => x
43
+ const shared_namespaceObject = x({ ["PropTypes"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_shared_edbdfb03__.PropTypes, ["classes"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_shared_edbdfb03__.classes, ["withInstall"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_shared_edbdfb03__.withInstall });
44
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/typeof.js
45
+ function _typeof(obj) {
46
+ "@babel/helpers - typeof";
47
+
48
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
49
+ return typeof obj;
50
+ } : function (obj) {
51
+ return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
52
+ }, _typeof(obj);
53
+ }
54
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toPrimitive.js
55
+
56
+ function _toPrimitive(input, hint) {
57
+ if (_typeof(input) !== "object" || input === null) return input;
58
+ var prim = input[Symbol.toPrimitive];
59
+ if (prim !== undefined) {
60
+ var res = prim.call(input, hint || "default");
61
+ if (_typeof(res) !== "object") return res;
62
+ throw new TypeError("@@toPrimitive must return a primitive value.");
63
+ }
64
+ return (hint === "string" ? String : Number)(input);
65
+ }
66
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js
67
+
68
+
69
+ function _toPropertyKey(arg) {
70
+ var key = _toPrimitive(arg, "string");
71
+ return _typeof(key) === "symbol" ? key : String(key);
72
+ }
73
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/defineProperty.js
74
+
75
+ function _defineProperty(obj, key, value) {
76
+ key = _toPropertyKey(key);
77
+ if (key in obj) {
78
+ Object.defineProperty(obj, key, {
79
+ value: value,
80
+ enumerable: true,
81
+ configurable: true,
82
+ writable: true
83
+ });
84
+ } else {
85
+ obj[key] = value;
86
+ }
87
+ return obj;
88
+ }
89
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/arrayWithHoles.js
90
+ function _arrayWithHoles(arr) {
91
+ if (Array.isArray(arr)) return arr;
92
+ }
93
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/iterableToArrayLimit.js
94
+ function _iterableToArrayLimit(arr, i) {
95
+ var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"];
96
+ if (null != _i) {
97
+ var _s,
98
+ _e,
99
+ _x,
100
+ _r,
101
+ _arr = [],
102
+ _n = !0,
103
+ _d = !1;
104
+ try {
105
+ if (_x = (_i = _i.call(arr)).next, 0 === i) {
106
+ if (Object(_i) !== _i) return;
107
+ _n = !1;
108
+ } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0);
109
+ } catch (err) {
110
+ _d = !0, _e = err;
111
+ } finally {
112
+ try {
113
+ if (!_n && null != _i["return"] && (_r = _i["return"](), Object(_r) !== _r)) return;
114
+ } finally {
115
+ if (_d) throw _e;
116
+ }
117
+ }
118
+ return _arr;
119
+ }
120
+ }
121
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js
122
+ function _arrayLikeToArray(arr, len) {
123
+ if (len == null || len > arr.length) len = arr.length;
124
+ for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
125
+ return arr2;
126
+ }
127
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js
128
+
129
+ function _unsupportedIterableToArray(o, minLen) {
130
+ if (!o) return;
131
+ if (typeof o === "string") return _arrayLikeToArray(o, minLen);
132
+ var n = Object.prototype.toString.call(o).slice(8, -1);
133
+ if (n === "Object" && o.constructor) n = o.constructor.name;
134
+ if (n === "Map" || n === "Set") return Array.from(o);
135
+ if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
136
+ }
137
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/nonIterableRest.js
138
+ function _nonIterableRest() {
139
+ throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
140
+ }
141
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/slicedToArray.js
142
+
143
+
144
+
145
+
146
+ function _slicedToArray(arr, i) {
147
+ return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest();
148
+ }
149
+ ;// CONCATENATED MODULE: external "vue"
150
+ var external_vue_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
151
+ var external_vue_y = x => () => x
152
+ const external_vue_namespaceObject = external_vue_x({ ["computed"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.computed, ["createTextVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.createTextVNode, ["createVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.createVNode, ["defineComponent"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.defineComponent, ["getCurrentInstance"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.getCurrentInstance, ["isVNode"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.isVNode, ["mergeProps"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.mergeProps, ["nextTick"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.nextTick, ["ref"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.ref, ["toRefs"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.toRefs, ["watch"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.watch });
153
+ ;// CONCATENATED MODULE: external "../config-provider"
154
+ var config_provider_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
155
+ var config_provider_y = x => () => x
156
+ const config_provider_namespaceObject = config_provider_x({ ["useLocale"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_config_provider_fe8577a3__.useLocale, ["usePrefix"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_config_provider_fe8577a3__.usePrefix });
157
+ ;// CONCATENATED MODULE: external "../select"
158
+ var select_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
159
+ var select_y = x => () => x
160
+ const select_namespaceObject = select_x({ ["BkOption"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_select_1a0d1ad7__.BkOption, ["default"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_select_1a0d1ad7__["default"] });
161
+ ;// CONCATENATED MODULE: external "../select/select.less"
162
+ var select_less_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
163
+ var select_less_y = x => () => x
164
+ const select_less_namespaceObject = select_less_x({ });
165
+ ;// CONCATENATED MODULE: ../../packages/pagination/src/use-limit.tsx
166
+
167
+
168
+
169
+ /*
170
+ * Tencent is pleased to support the open source community by making
171
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
172
+ *
173
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
174
+ *
175
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
176
+ *
177
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
178
+ *
179
+ * ---------------------------------------------------
180
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
181
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
182
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
183
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
184
+ *
185
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
186
+ * the Software.
187
+ *
188
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
189
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
190
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
191
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
192
+ * IN THE SOFTWARE.
193
+ */
194
+
195
+
196
+
197
+
198
+
199
+ function _isSlot(s) {
200
+ return typeof s === 'function' || Object.prototype.toString.call(s) === '[object Object]' && !(0,external_vue_namespaceObject.isVNode)(s);
201
+ }
202
+ /* harmony default export */ const use_limit = (function (t) {
203
+ var _getCurrentInstance = (0,external_vue_namespaceObject.getCurrentInstance)(),
204
+ proxy = _getCurrentInstance.proxy;
205
+ var localLimit = (0,external_vue_namespaceObject.ref)(proxy.limit);
206
+ /**
207
+ * @desc 同步props.limit的变化
208
+ */
209
+ (0,external_vue_namespaceObject.watch)(function () {
210
+ return proxy.limit;
211
+ }, function (limit) {
212
+ localLimit.value = limit;
213
+ });
214
+ /**
215
+ * @desc 同步props.limitlist的变化并判断props.limit的合法性
216
+ */
217
+ (0,external_vue_namespaceObject.watch)(function () {
218
+ return proxy.limitList;
219
+ }, function (limitList) {
220
+ (0,external_vue_namespaceObject.nextTick)(function () {
221
+ if (!limitList.includes(localLimit.value)) {
222
+ var _limitList = _slicedToArray(limitList, 1);
223
+ localLimit.value = _limitList[0];
224
+ }
225
+ });
226
+ }, {
227
+ immediate: true
228
+ });
229
+ /**
230
+ * @desc 选择每页条数
231
+ */
232
+ var handleLimitChange = function handleLimitChange(limit) {
233
+ localLimit.value = limit;
234
+ };
235
+ var _usePrefix = (0,config_provider_namespaceObject.usePrefix)(),
236
+ resolveClassName = _usePrefix.resolveClassName;
237
+ var render = function render(_ref) {
238
+ var _slot;
239
+ var _ref2;
240
+ var isFirst = _ref.isFirst,
241
+ isLast = _ref.isLast;
242
+ if (!proxy.showLimit) {
243
+ return null;
244
+ }
245
+ return (0,external_vue_namespaceObject.createVNode)("div", (0,external_vue_namespaceObject.mergeProps)({
246
+ "class": (_ref2 = {}, _defineProperty(_ref2, resolveClassName('pagination-limit'), true), _defineProperty(_ref2, 'is-first', isFirst), _defineProperty(_ref2, 'is-last', isLast), _ref2)
247
+ }, {
248
+ disabled: proxy.disabled
249
+ }), [(0,external_vue_namespaceObject.createVNode)("div", null, [t.value.eachPage]), (0,external_vue_namespaceObject.createVNode)(select_namespaceObject["default"], {
250
+ "class": "".concat(resolveClassName('pagination-limit-select')),
251
+ "clearable": false,
252
+ "size": "small",
253
+ "withValidate": false,
254
+ "modelValue": localLimit.value,
255
+ "onChange": handleLimitChange,
256
+ "disabled": proxy.disabled
257
+ }, _isSlot(_slot = proxy.limitList.map(function (num, index) {
258
+ return (0,external_vue_namespaceObject.createVNode)(select_namespaceObject.BkOption, {
259
+ "id": num,
260
+ "name": "".concat(num),
261
+ "key": "".concat(index, "_").concat(num)
262
+ }, null);
263
+ })) ? _slot : {
264
+ "default": function _default() {
265
+ return [_slot];
266
+ }
267
+ }), (0,external_vue_namespaceObject.createVNode)("div", null, [t.value.strip])]);
268
+ };
269
+ return {
270
+ limit: localLimit,
271
+ render: render
272
+ };
273
+ });
274
+ ;// CONCATENATED MODULE: external "../icon"
275
+ var icon_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
276
+ var icon_y = x => () => x
277
+ const icon_namespaceObject = icon_x({ ["AngleLeft"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.AngleLeft, ["AngleRight"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.AngleRight, ["Ellipsis"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_icon_a97c79c3__.Ellipsis });
278
+ ;// CONCATENATED MODULE: ../../packages/pagination/src/use-list.tsx
279
+
280
+
281
+ /*
282
+ * Tencent is pleased to support the open source community by making
283
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
284
+ *
285
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
286
+ *
287
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
288
+ *
289
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
290
+ *
291
+ * ---------------------------------------------------
292
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
293
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
294
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
295
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
296
+ *
297
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
298
+ * the Software.
299
+ *
300
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
301
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
302
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
303
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
304
+ * IN THE SOFTWARE.
305
+ */
306
+
307
+
308
+
309
+ var PAGE_ITEMS_NUM = 5;
310
+ /* harmony default export */ const use_list = (function () {
311
+ var _getCurrentInstance = (0,external_vue_namespaceObject.getCurrentInstance)(),
312
+ proxy = _getCurrentInstance.proxy;
313
+ var localCurrent = (0,external_vue_namespaceObject.ref)(1);
314
+ var isPagePreDisabled = (0,external_vue_namespaceObject.computed)(function () {
315
+ return localCurrent.value === 1;
316
+ });
317
+ var isPageNextDisabled = (0,external_vue_namespaceObject.computed)(function () {
318
+ return localCurrent.value === proxy.totalPageNum;
319
+ });
320
+ var showPreBatch = (0,external_vue_namespaceObject.ref)(false);
321
+ var showNextBatch = (0,external_vue_namespaceObject.ref)(false);
322
+ var list = (0,external_vue_namespaceObject.computed)(function () {
323
+ showPreBatch.value = false;
324
+ showNextBatch.value = false;
325
+ var stack = [];
326
+ if (proxy.totalPageNum <= PAGE_ITEMS_NUM + 2) {
327
+ for (var i = 2; i <= proxy.totalPageNum - 1; i++) {
328
+ stack.push(i);
329
+ }
330
+ return stack;
331
+ }
332
+ var pageItemsNumHalf = Math.floor(PAGE_ITEMS_NUM / 2);
333
+ if (proxy.totalPageNum > PAGE_ITEMS_NUM) {
334
+ showPreBatch.value = localCurrent.value - pageItemsNumHalf > 2;
335
+ showNextBatch.value = localCurrent.value + pageItemsNumHalf < proxy.totalPageNum - 1;
336
+ }
337
+ var start = Math.min(proxy.totalPageNum - PAGE_ITEMS_NUM, Math.max(2, localCurrent.value - pageItemsNumHalf));
338
+ for (var _i = start; _i < start + PAGE_ITEMS_NUM; _i++) {
339
+ stack.push(_i);
340
+ }
341
+ return stack;
342
+ });
343
+ (0,external_vue_namespaceObject.watch)(function () {
344
+ return proxy.modelValue;
345
+ }, function (modelValue) {
346
+ // nextTick延后执行,保证proxy.totalPageNum计算正确
347
+ (0,external_vue_namespaceObject.nextTick)(function () {
348
+ if (modelValue >= 1 && modelValue <= proxy.totalPageNum) {
349
+ localCurrent.value = modelValue;
350
+ } else if (modelValue < 1) {
351
+ localCurrent.value = 1;
352
+ } else {
353
+ localCurrent.value = proxy.totalPageNum;
354
+ }
355
+ });
356
+ }, {
357
+ immediate: true
358
+ });
359
+ // 切换limit时会导致totalPageNum变小旧的current可能会超出范围,修正localCurrent
360
+ (0,external_vue_namespaceObject.nextTick)(function () {
361
+ (0,external_vue_namespaceObject.watch)(function () {
362
+ return proxy.totalPageNum;
363
+ }, function (totalPageNum) {
364
+ if (localCurrent.value > totalPageNum) {
365
+ localCurrent.value = totalPageNum;
366
+ }
367
+ });
368
+ });
369
+ /**
370
+ * @desc 上一页
371
+ */
372
+ var handlePrePage = function handlePrePage() {
373
+ if (isPagePreDisabled.value) {
374
+ return;
375
+ }
376
+ localCurrent.value = localCurrent.value - 1;
377
+ };
378
+ /**
379
+ * @desc 下一页
380
+ */
381
+ var handleNextPage = function handleNextPage() {
382
+ if (isPageNextDisabled.value) {
383
+ return;
384
+ }
385
+ localCurrent.value = localCurrent.value + 1;
386
+ };
387
+ /**
388
+ * @desc 跳转指定页码
389
+ * @param { Number } totalPageNum
390
+ */
391
+ var handleItemClick = function handleItemClick(totalPageNum) {
392
+ if (totalPageNum === localCurrent.value) {
393
+ return;
394
+ }
395
+ localCurrent.value = totalPageNum;
396
+ };
397
+ /**
398
+ * @desc 上一批分页
399
+ */
400
+ var handlePreBatch = function handlePreBatch() {
401
+ localCurrent.value = Math.max(1, localCurrent.value - PAGE_ITEMS_NUM);
402
+ };
403
+ /**
404
+ * @desc 下一批分页
405
+ */
406
+ var handleNextBatch = function handleNextBatch() {
407
+ localCurrent.value = Math.min(proxy.totalPageNum, localCurrent.value + PAGE_ITEMS_NUM);
408
+ };
409
+ var _usePrefix = (0,config_provider_namespaceObject.usePrefix)(),
410
+ resolveClassName = _usePrefix.resolveClassName;
411
+ var render = function render(_ref) {
412
+ var _ref2, _ref3, _ref4, _ref6, _ref7;
413
+ var isFirst = _ref.isFirst,
414
+ isLast = _ref.isLast;
415
+ return (0,external_vue_namespaceObject.createVNode)("div", {
416
+ "class": (_ref2 = {}, _defineProperty(_ref2, "".concat(resolveClassName('pagination-list')), true), _defineProperty(_ref2, 'is-first', isFirst), _defineProperty(_ref2, 'is-last', isLast), _ref2)
417
+ }, [(0,external_vue_namespaceObject.createVNode)("div", {
418
+ "class": (_ref3 = {}, _defineProperty(_ref3, "".concat(resolveClassName('pagination-list-pre')), true), _defineProperty(_ref3, 'is-disabled', isPagePreDisabled.value), _ref3),
419
+ "onClick": handlePrePage
420
+ }, [proxy.prevText || (0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.AngleLeft, null, null)]), (0,external_vue_namespaceObject.createVNode)("div", {
421
+ "class": (_ref4 = {}, _defineProperty(_ref4, "".concat(resolveClassName('pagination-list-item')), true), _defineProperty(_ref4, 'is-active', localCurrent.value === 1), _ref4),
422
+ "key": "1",
423
+ "onClick": function onClick() {
424
+ return handleItemClick(1);
425
+ }
426
+ }, [(0,external_vue_namespaceObject.createTextVNode)("1")]), showPreBatch.value && (0,external_vue_namespaceObject.createVNode)("div", {
427
+ "key": "pre-batch",
428
+ "class": "".concat(resolveClassName('pagination-list-pre-batch')),
429
+ "onClick": handlePreBatch
430
+ }, [(0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.Ellipsis, null, null)]), list.value.map(function (num) {
431
+ var _ref5;
432
+ return (0,external_vue_namespaceObject.createVNode)("div", {
433
+ "class": (_ref5 = {}, _defineProperty(_ref5, "".concat(resolveClassName('pagination-list-item')), true), _defineProperty(_ref5, 'is-active', localCurrent.value === num), _ref5),
434
+ "key": num,
435
+ "onClick": function onClick() {
436
+ return handleItemClick(num);
437
+ }
438
+ }, [num]);
439
+ }), showNextBatch.value && (0,external_vue_namespaceObject.createVNode)("div", {
440
+ "key": "next-batch",
441
+ "class": "".concat(resolveClassName('pagination-list-next-batch')),
442
+ "onClick": handleNextBatch
443
+ }, [(0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.Ellipsis, null, null)]), proxy.totalPageNum > 1 && (0,external_vue_namespaceObject.createVNode)("div", {
444
+ "class": (_ref6 = {}, _defineProperty(_ref6, "".concat(resolveClassName('pagination-list-item')), true), _defineProperty(_ref6, 'is-active', localCurrent.value === proxy.totalPageNum), _ref6),
445
+ "key": "last",
446
+ "onClick": function onClick() {
447
+ return handleItemClick(proxy.totalPageNum);
448
+ }
449
+ }, [proxy.totalPageNum]), (0,external_vue_namespaceObject.createVNode)("div", {
450
+ "class": (_ref7 = {}, _defineProperty(_ref7, "".concat(resolveClassName('pagination-list-pre')), true), _defineProperty(_ref7, 'is-disabled', isPageNextDisabled.value), _ref7),
451
+ "onClick": handleNextPage
452
+ }, [proxy.nextText || (0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.AngleRight, null, null)])]);
453
+ };
454
+ return {
455
+ current: localCurrent,
456
+ render: render
457
+ };
458
+ });
459
+ ;// CONCATENATED MODULE: external "../popover"
460
+ var popover_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
461
+ var popover_y = x => () => x
462
+ const popover_namespaceObject = popover_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_bkui_vue_lib_popover_9b03f19d__["default"] });
463
+ ;// CONCATENATED MODULE: external "../popover/popover.less"
464
+ var popover_less_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
465
+ var popover_less_y = x => () => x
466
+ const popover_less_namespaceObject = popover_less_x({ });
467
+ ;// CONCATENATED MODULE: ../../packages/pagination/src/use-small-list.tsx
468
+
469
+
470
+ /*
471
+ * Tencent is pleased to support the open source community by making
472
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
473
+ *
474
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
475
+ *
476
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
477
+ *
478
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
479
+ *
480
+ * ---------------------------------------------------
481
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
482
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
483
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
484
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
485
+ *
486
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
487
+ * the Software.
488
+ *
489
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
490
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
491
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
492
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
493
+ * IN THE SOFTWARE.
494
+ */
495
+
496
+
497
+
498
+
499
+
500
+ /* harmony default export */ const use_small_list = (function () {
501
+ var _getCurrentInstance = (0,external_vue_namespaceObject.getCurrentInstance)(),
502
+ proxy = _getCurrentInstance.proxy;
503
+ var inputRef = (0,external_vue_namespaceObject.ref)(null);
504
+ var isFocused = (0,external_vue_namespaceObject.ref)(false);
505
+ var localCurrent = (0,external_vue_namespaceObject.ref)(1);
506
+ var isPagePreDisabled = (0,external_vue_namespaceObject.computed)(function () {
507
+ return localCurrent.value === 1;
508
+ });
509
+ var isPageNextDisabled = (0,external_vue_namespaceObject.computed)(function () {
510
+ return localCurrent.value === proxy.totalPageNum;
511
+ });
512
+ // 缓存input输入,失焦或者enter键触发提交
513
+ var inputMemo = 0;
514
+ // 页码可选列表
515
+ var list = (0,external_vue_namespaceObject.computed)(function () {
516
+ var stack = [];
517
+ for (var i = 1; i <= proxy.totalPageNum; i++) {
518
+ stack.push(i);
519
+ }
520
+ return stack;
521
+ });
522
+ (0,external_vue_namespaceObject.watch)(function () {
523
+ return proxy.modelValue;
524
+ }, function (modelValue) {
525
+ // nextTick延后执行,保证proxy.totalPageNum计算正确
526
+ (0,external_vue_namespaceObject.nextTick)(function () {
527
+ if (modelValue >= 1 && modelValue <= proxy.totalPageNum) {
528
+ localCurrent.value = modelValue;
529
+ } else if (modelValue < 1) {
530
+ localCurrent.value = 1;
531
+ } else {
532
+ localCurrent.value = proxy.totalPageNum;
533
+ }
534
+ inputMemo = localCurrent.value;
535
+ });
536
+ }, {
537
+ immediate: true
538
+ });
539
+ // 切换limit时会导致totalPageNum变小旧的current可能会超出范围,修正localCurrent
540
+ (0,external_vue_namespaceObject.nextTick)(function () {
541
+ (0,external_vue_namespaceObject.watch)(function () {
542
+ return proxy.totalPageNum;
543
+ }, function (totalPageNum) {
544
+ if (localCurrent.value > totalPageNum) {
545
+ localCurrent.value = totalPageNum;
546
+ }
547
+ });
548
+ });
549
+ /**
550
+ * @desc 上一页
551
+ */
552
+ var handlePrePage = function handlePrePage() {
553
+ if (isPagePreDisabled.value) {
554
+ return;
555
+ }
556
+ localCurrent.value = localCurrent.value - 1;
557
+ };
558
+ /**
559
+ * @desc 下一页
560
+ */
561
+ var handleNextPage = function handleNextPage() {
562
+ if (isPageNextDisabled.value) {
563
+ return;
564
+ }
565
+ localCurrent.value = localCurrent.value + 1;
566
+ };
567
+ /**
568
+ * @desc 获得焦点
569
+ */
570
+ var handlePageEditorFocus = function handlePageEditorFocus() {
571
+ isFocused.value = true;
572
+ };
573
+ /**
574
+ * @desc 失去焦点
575
+ */
576
+ var handlePageEditorBlur = function handlePageEditorBlur() {
577
+ isFocused.value = false;
578
+ inputRef.value.textContent = "".concat(inputMemo);
579
+ if (inputMemo !== localCurrent.value) {
580
+ localCurrent.value = inputMemo;
581
+ }
582
+ };
583
+ /**
584
+ * @desc 键盘输入
585
+ * @param { Event } event
586
+ */
587
+ var handlePageEditorInput = function handlePageEditorInput(event) {
588
+ var $target = event.target;
589
+ var value = Number($target.textContent);
590
+ // 无效值不抛出事件
591
+ if (!value || value < 1 || value > proxy.totalPageNum || value === localCurrent.value) {
592
+ return;
593
+ }
594
+ inputMemo = value;
595
+ };
596
+ /**
597
+ * @desc 处理Enter事件
598
+ * @param { KeyboardEvent } event
599
+ */
600
+ var handlePageEditorKeydown = function handlePageEditorKeydown(event) {
601
+ // 阻止默认enter事件(keycode判断可能会被弃用)
602
+ if (['Enter', 'NumpadEnter'].includes(event.code)) {
603
+ event.preventDefault();
604
+ handlePageEditorBlur();
605
+ }
606
+ };
607
+ /**
608
+ * @desc 更新
609
+ */
610
+ var handlePageChange = function handlePageChange(item) {
611
+ inputMemo = item;
612
+ handlePageEditorBlur();
613
+ };
614
+ var _usePrefix = (0,config_provider_namespaceObject.usePrefix)(),
615
+ resolveClassName = _usePrefix.resolveClassName;
616
+ var render = function render() {
617
+ var _ref, _ref3;
618
+ return (0,external_vue_namespaceObject.createVNode)("div", {
619
+ "class": "".concat(resolveClassName('pagination-small-list'))
620
+ }, [(0,external_vue_namespaceObject.createVNode)("div", {
621
+ "class": (_ref = {}, _defineProperty(_ref, "".concat(resolveClassName('pagination-btn-pre')), true), _defineProperty(_ref, 'is-disabled', isPagePreDisabled.value), _ref),
622
+ "onClick": handlePrePage
623
+ }, [(0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.AngleLeft, null, null)]), (0,external_vue_namespaceObject.createVNode)(popover_namespaceObject["default"], {
624
+ "theme": "light",
625
+ "trigger": "click",
626
+ "arrow": false,
627
+ "width": 56,
628
+ "boundary": "body",
629
+ "placement": "bottom"
630
+ }, {
631
+ "default": function _default() {
632
+ var _ref2;
633
+ return (0,external_vue_namespaceObject.createVNode)("div", {
634
+ "class": (_ref2 = {}, _defineProperty(_ref2, "".concat(resolveClassName('pagination-picker')), true), _defineProperty(_ref2, 'is-focused', isFocused.value), _ref2)
635
+ }, [(0,external_vue_namespaceObject.createVNode)("span", {
636
+ "ref": inputRef,
637
+ "class": "".concat(resolveClassName('pagination-editor')),
638
+ "contenteditable": true,
639
+ "spellcheck": "false",
640
+ "onFocus": handlePageEditorFocus,
641
+ "onBlur": handlePageEditorBlur,
642
+ "onInput": handlePageEditorInput,
643
+ "onKeydown": handlePageEditorKeydown
644
+ }, [localCurrent.value]), (0,external_vue_namespaceObject.createVNode)("span", null, [(0,external_vue_namespaceObject.createTextVNode)("/")]), (0,external_vue_namespaceObject.createVNode)("span", {
645
+ "class": "".concat(resolveClassName('pagination-small-list-total'))
646
+ }, [proxy.totalPageNum])]);
647
+ },
648
+ content: function content() {
649
+ return (0,external_vue_namespaceObject.createVNode)("div", {
650
+ "class": "".concat(resolveClassName('pagination-picker-list'))
651
+ }, [list.value.map(function (item) {
652
+ return (0,external_vue_namespaceObject.createVNode)("div", {
653
+ "class": {
654
+ item: true,
655
+ 'is-actived': item === localCurrent.value
656
+ },
657
+ "key": item,
658
+ "onClick": function onClick() {
659
+ return handlePageChange(item);
660
+ }
661
+ }, [item]);
662
+ })]);
663
+ }
664
+ }), (0,external_vue_namespaceObject.createVNode)("div", {
665
+ "class": (_ref3 = {}, _defineProperty(_ref3, "".concat(resolveClassName('pagination-btn-next')), true), _defineProperty(_ref3, 'is-disabled', isPageNextDisabled.value), _ref3),
666
+ "onClick": handleNextPage
667
+ }, [(0,external_vue_namespaceObject.createVNode)(icon_namespaceObject.AngleRight, null, null)])]);
668
+ };
669
+ return {
670
+ current: localCurrent,
671
+ render: render
672
+ };
673
+ });
674
+ ;// CONCATENATED MODULE: ../../packages/pagination/src/use-total.tsx
675
+
676
+
677
+ /*
678
+ * Tencent is pleased to support the open source community by making
679
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
680
+ *
681
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
682
+ *
683
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
684
+ *
685
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
686
+ *
687
+ * ---------------------------------------------------
688
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
689
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
690
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
691
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
692
+ *
693
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
694
+ * the Software.
695
+ *
696
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
697
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
698
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
699
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
700
+ * IN THE SOFTWARE.
701
+ */
702
+
703
+
704
+ /* harmony default export */ const use_total = (function (t) {
705
+ return function (_ref) {
706
+ var _ref2;
707
+ var isFirst = _ref.isFirst,
708
+ isLast = _ref.isLast;
709
+ var _getCurrentInstance = (0,external_vue_namespaceObject.getCurrentInstance)(),
710
+ props = _getCurrentInstance.props;
711
+ if (!props.showTotalCount) {
712
+ return null;
713
+ }
714
+ var _usePrefix = (0,config_provider_namespaceObject.usePrefix)(),
715
+ resolveClassName = _usePrefix.resolveClassName;
716
+ return (0,external_vue_namespaceObject.createVNode)("div", (0,external_vue_namespaceObject.mergeProps)({
717
+ "class": (_ref2 = {}, _defineProperty(_ref2, "".concat(resolveClassName('pagination-total')), true), _defineProperty(_ref2, 'is-first', isFirst), _defineProperty(_ref2, 'is-last', isLast), _ref2)
718
+ }, {
719
+ disabled: props.disabled
720
+ }), [t.value.total, (0,external_vue_namespaceObject.createVNode)("div", {
721
+ "class": "".concat(resolveClassName('pagination-total-num'))
722
+ }, [props.count]), t.value.strip]);
723
+ };
724
+ });
725
+ ;// CONCATENATED MODULE: ../../packages/pagination/src/pagination.tsx
726
+
727
+
728
+
729
+ /*
730
+ * Tencent is pleased to support the open source community by making
731
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
732
+ *
733
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
734
+ *
735
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
736
+ *
737
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
738
+ *
739
+ * ---------------------------------------------------
740
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
741
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
742
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
743
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
744
+ *
745
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
746
+ * the Software.
747
+ *
748
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
749
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
750
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
751
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
752
+ * IN THE SOFTWARE.
753
+ */
754
+
755
+
756
+
757
+
758
+
759
+
760
+
761
+ var paginationProps = {
762
+ modelValue: shared_namespaceObject.PropTypes.number.def(1),
763
+ count: shared_namespaceObject.PropTypes.number.def(0).isRequired,
764
+ limit: shared_namespaceObject.PropTypes.number.def(10),
765
+ limitList: shared_namespaceObject.PropTypes.arrayOf(Number).def([10, 20, 50, 100]),
766
+ showLimit: shared_namespaceObject.PropTypes.bool.def(true),
767
+ type: shared_namespaceObject.PropTypes.oneOf(['default', 'compact']).def('default'),
768
+ location: shared_namespaceObject.PropTypes.oneOf(['left', 'right']).def('right'),
769
+ align: shared_namespaceObject.PropTypes.oneOf(['left', 'center', 'right']).def('left'),
770
+ size: shared_namespaceObject.PropTypes.size(),
771
+ small: shared_namespaceObject.PropTypes.bool.def(false),
772
+ showTotalCount: shared_namespaceObject.PropTypes.bool.def(true),
773
+ prevText: shared_namespaceObject.PropTypes.string,
774
+ nextText: shared_namespaceObject.PropTypes.string,
775
+ disabled: shared_namespaceObject.PropTypes.bool.def(false),
776
+ beforeChange: shared_namespaceObject.PropTypes.func,
777
+ layout: shared_namespaceObject.PropTypes.custom(function (value) {
778
+ var layoutNameMap = {
779
+ total: true,
780
+ list: true,
781
+ limit: true
782
+ };
783
+ return value.some(function (item) {
784
+ return layoutNameMap[item];
785
+ });
786
+ }, 'layout 的值只支持 * total、list、limit *').def(['total', 'list', 'limit'])
787
+ };
788
+ /* harmony default export */ const pagination = ((0,external_vue_namespaceObject.defineComponent)({
789
+ name: 'Pagination',
790
+ props: paginationProps,
791
+ emits: ['update:modelValue', 'change', 'update:limit', 'limitChange'],
792
+ setup: function setup(props, context) {
793
+ var t = (0,config_provider_namespaceObject.useLocale)('pagination');
794
+ var totalPageNum = (0,external_vue_namespaceObject.ref)(0);
795
+ var _toRefs = (0,external_vue_namespaceObject.toRefs)(props),
796
+ count = _toRefs.count,
797
+ limit = _toRefs.limit;
798
+ var renderTotal = use_total(t);
799
+ var _useList = use_list(),
800
+ listCurrent = _useList.current,
801
+ renderList = _useList.render;
802
+ var _useSmallList = use_small_list(),
803
+ smallListCurrent = _useSmallList.current,
804
+ renderSmallList = _useSmallList.render;
805
+ var _useLimit = use_limit(t),
806
+ localLimit = _useLimit.limit,
807
+ renderLimit = _useLimit.render;
808
+ (0,external_vue_namespaceObject.watch)([count, localLimit, limit], function (_ref) {
809
+ var _ref2 = _slicedToArray(_ref, 2),
810
+ count = _ref2[0],
811
+ localLimit = _ref2[1];
812
+ var total = Math.ceil(count / localLimit);
813
+ totalPageNum.value = total < 1 ? 1 : total;
814
+ }, {
815
+ immediate: true
816
+ });
817
+ (0,external_vue_namespaceObject.watch)(listCurrent, function (listCurrent) {
818
+ context.emit('update:modelValue', listCurrent);
819
+ context.emit('change', listCurrent);
820
+ });
821
+ (0,external_vue_namespaceObject.watch)(smallListCurrent, function (smallListCurrent) {
822
+ if (!props.small) {
823
+ return;
824
+ }
825
+ context.emit('update:modelValue', smallListCurrent);
826
+ context.emit('change', smallListCurrent);
827
+ });
828
+ (0,external_vue_namespaceObject.watch)(localLimit, function (localLimit) {
829
+ context.emit('limitChange', localLimit);
830
+ });
831
+ var _usePrefix = (0,config_provider_namespaceObject.usePrefix)(),
832
+ resolveClassName = _usePrefix.resolveClassName;
833
+ return {
834
+ totalPageNum: totalPageNum,
835
+ renderTotal: renderTotal,
836
+ renderList: renderList,
837
+ renderLimit: renderLimit,
838
+ renderSmallList: renderSmallList,
839
+ resolveClassName: resolveClassName
840
+ };
841
+ },
842
+ render: function render() {
843
+ var _classes,
844
+ _this = this;
845
+ var paginationClass = (0,shared_namespaceObject.classes)((_classes = {}, _defineProperty(_classes, "".concat(this.resolveClassName('pagination')), true), _defineProperty(_classes, "".concat(this.resolveClassName("pagination--".concat(this.size))), true), _defineProperty(_classes, "is-align-".concat(this.align), true), _classes));
846
+ var layoutMap = {
847
+ total: this.renderTotal,
848
+ list: this.small ? this.renderSmallList : this.renderList,
849
+ limit: this.renderLimit
850
+ };
851
+ return (0,external_vue_namespaceObject.createVNode)("div", {
852
+ "class": paginationClass
853
+ }, [this.layout.map(function (layout, index) {
854
+ return layoutMap[layout]({
855
+ isFirst: index === 0,
856
+ isLast: index === _this.layout.length - 1
857
+ });
858
+ })]);
859
+ }
860
+ }));
861
+ ;// CONCATENATED MODULE: ../../packages/pagination/src/index.ts
862
+ /*
863
+ * Tencent is pleased to support the open source community by making
864
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
865
+ *
866
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
867
+ *
868
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
869
+ *
870
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
871
+ *
872
+ * ---------------------------------------------------
873
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
874
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
875
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
876
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
877
+ *
878
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
879
+ * the Software.
880
+ *
881
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
882
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
883
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
884
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
885
+ * IN THE SOFTWARE.
886
+ */
887
+
888
+
889
+ var BkPagination = (0,shared_namespaceObject.withInstall)(pagination);
890
+ /* harmony default export */ const src = (BkPagination);
891
+
892
+ var __webpack_exports__BkPagination = __webpack_exports__.h;
893
+ var __webpack_exports__default = __webpack_exports__.Z;
894
+ export { __webpack_exports__BkPagination as BkPagination, __webpack_exports__default as default };