bkui-vue 0.0.2-beta.9 → 0.0.2-beta.91

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 (407) hide show
  1. package/dist/index.cjs.js +143 -161
  2. package/dist/index.esm.js +21050 -23162
  3. package/dist/index.umd.js +143 -161
  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/index.d.ts +4 -4
  16. package/lib/affix/index.js +321 -1
  17. package/lib/alert/alert.css +7 -0
  18. package/lib/alert/alert.d.ts +5 -5
  19. package/lib/alert/alert.less +16 -6
  20. package/lib/alert/alert.variable.css +7 -0
  21. package/lib/alert/index.d.ts +10 -10
  22. package/lib/alert/index.js +214 -1
  23. package/lib/animate-number/index.d.ts +1 -1
  24. package/lib/animate-number/index.js +155 -1
  25. package/lib/backtop/backtop.css +8 -8
  26. package/lib/backtop/backtop.less +3 -1
  27. package/lib/backtop/backtop.variable.css +11 -11
  28. package/lib/backtop/index.d.ts +1 -1
  29. package/lib/backtop/index.js +188 -1
  30. package/lib/badge/badge.d.ts +2 -2
  31. package/lib/badge/index.d.ts +7 -7
  32. package/lib/badge/index.js +235 -1
  33. package/lib/breadcrumb/breadcrumb.css +4 -4
  34. package/lib/breadcrumb/breadcrumb.variable.css +4 -4
  35. package/lib/breadcrumb/index.d.ts +2 -2
  36. package/lib/breadcrumb/index.js +309 -1
  37. package/lib/button/button.css +20 -0
  38. package/lib/button/button.less +105 -94
  39. package/lib/button/button.variable.css +20 -0
  40. package/lib/button/index.d.ts +2 -2
  41. package/lib/button/index.js +321 -1
  42. package/lib/card/card.css +4 -4
  43. package/lib/card/card.d.ts +1 -1
  44. package/lib/card/card.variable.css +4 -4
  45. package/lib/card/index.d.ts +4 -4
  46. package/lib/card/index.js +285 -1
  47. package/lib/cascader/cascader.css +4 -4
  48. package/lib/cascader/cascader.d.ts +1 -0
  49. package/lib/cascader/cascader.variable.css +4 -4
  50. package/lib/cascader/index.d.ts +5 -2
  51. package/lib/cascader/index.js +2036 -2
  52. package/lib/cascader/interface.d.ts +1 -1
  53. package/lib/checkbox/checkbox-group.d.ts +6 -3
  54. package/lib/checkbox/checkbox.d.ts +6 -4
  55. package/lib/checkbox/index.d.ts +28 -19
  56. package/lib/checkbox/index.js +545 -1
  57. package/lib/code-diff/index.d.ts +1 -1
  58. package/lib/code-diff/index.js +5501 -1
  59. package/lib/collapse/index.d.ts +2 -2
  60. package/lib/collapse/index.js +570 -1
  61. package/lib/collapse-transition/index.d.ts +128 -2
  62. package/lib/collapse-transition/index.js +177 -1
  63. package/lib/color-picker/color-picker.d.ts +16 -0
  64. package/lib/color-picker/components/recommend-colors.d.ts +16 -0
  65. package/lib/color-picker/index.d.ts +19 -1
  66. package/lib/color-picker/index.js +2665 -1
  67. package/lib/components.js +530 -1
  68. package/lib/config-provider/config-provider.d.ts +3 -0
  69. package/lib/config-provider/index.d.ts +5 -1
  70. package/lib/config-provider/index.js +365 -1
  71. package/lib/config-provider/token.d.ts +1 -0
  72. package/lib/config-provider/use-global-config.d.ts +2 -0
  73. package/lib/config-provider/use-prefix.d.ts +2 -0
  74. package/lib/container/container.css +4 -4
  75. package/lib/container/container.variable.css +4 -4
  76. package/lib/container/index.d.ts +2 -2
  77. package/lib/container/index.js +391 -1
  78. package/lib/date-picker/date-picker.d.ts +4 -2
  79. package/lib/date-picker/index.d.ts +15 -8
  80. package/lib/date-picker/index.js +5555 -1
  81. package/lib/date-picker/panel/date-range.d.ts +2 -1
  82. package/lib/date-picker/time-picker.d.ts +1 -1
  83. package/lib/dialog/dialog.css +2 -0
  84. package/lib/dialog/dialog.variable.css +2 -0
  85. package/lib/dialog/index.d.ts +1 -1
  86. package/lib/dialog/index.js +975 -2
  87. package/lib/directives/index.js +1376 -2
  88. package/lib/directives/tooltips.d.ts +3 -2
  89. package/lib/dist.index.js +87 -1
  90. package/lib/divider/index.d.ts +1 -1
  91. package/lib/divider/index.js +169 -1
  92. package/lib/dropdown/dropdown.css +1 -0
  93. package/lib/dropdown/dropdown.variable.css +1 -0
  94. package/lib/dropdown/index.d.ts +2 -2
  95. package/lib/dropdown/index.js +369 -1
  96. package/lib/exception/index.d.ts +2 -2
  97. package/lib/exception/index.js +385 -1
  98. package/lib/fixed-navbar/index.d.ts +1 -1
  99. package/lib/fixed-navbar/index.js +154 -1
  100. package/lib/form/index.d.ts +3 -3
  101. package/lib/form/index.js +952 -1
  102. package/lib/hooks.d.ts +1 -1
  103. package/lib/hooks.js +73 -1
  104. package/lib/icon/angle-double-down-line.js +191 -1
  105. package/lib/icon/angle-double-left-line.js +191 -1
  106. package/lib/icon/angle-double-left.js +191 -1
  107. package/lib/icon/angle-double-right-line.js +191 -1
  108. package/lib/icon/angle-double-right.js +191 -1
  109. package/lib/icon/angle-double-up-line.js +191 -1
  110. package/lib/icon/angle-down-fill.js +191 -1
  111. package/lib/icon/angle-down-line.js +191 -1
  112. package/lib/icon/angle-down.js +191 -1
  113. package/lib/icon/angle-left.js +191 -1
  114. package/lib/icon/angle-right.js +191 -1
  115. package/lib/icon/angle-up-fill.js +191 -1
  116. package/lib/icon/angle-up.js +191 -1
  117. package/lib/icon/archive-fill.js +191 -1
  118. package/lib/icon/arrows-left.js +191 -1
  119. package/lib/icon/arrows-right.js +191 -1
  120. package/lib/icon/assistant.d.ts +4 -0
  121. package/lib/icon/assistant.js +191 -0
  122. package/lib/icon/audio-fill.js +191 -1
  123. package/lib/icon/bk.js +191 -1
  124. package/lib/icon/circle.js +191 -1
  125. package/lib/icon/close-line.js +191 -1
  126. package/lib/icon/close.js +191 -1
  127. package/lib/icon/code.js +191 -1
  128. package/lib/icon/cog-shape.js +191 -1
  129. package/lib/icon/collapse-left.js +191 -1
  130. package/lib/icon/copy-shape.js +191 -1
  131. package/lib/icon/copy.js +191 -1
  132. package/lib/icon/data-shape.js +191 -1
  133. package/lib/icon/del.js +191 -1
  134. package/lib/icon/doc-fill.js +191 -1
  135. package/lib/icon/done.js +191 -1
  136. package/lib/icon/down-shape.js +191 -1
  137. package/lib/icon/down-small.js +191 -1
  138. package/lib/icon/edit-line.js +191 -1
  139. package/lib/icon/ellipsis.js +191 -1
  140. package/lib/icon/enlarge-line.js +191 -1
  141. package/lib/icon/error.js +191 -1
  142. package/lib/icon/excel-fill.js +191 -1
  143. package/lib/icon/exclamation-circle-shape.js +191 -1
  144. package/lib/icon/eye.js +191 -1
  145. package/lib/icon/filliscreen-line.js +191 -1
  146. package/lib/icon/fix-line.js +191 -1
  147. package/lib/icon/fix-shape.js +191 -1
  148. package/lib/icon/folder-open.js +191 -1
  149. package/lib/icon/folder-shape-open.js +191 -1
  150. package/lib/icon/folder-shape.js +191 -1
  151. package/lib/icon/folder.js +191 -1
  152. package/lib/icon/funnel.js +191 -1
  153. package/lib/icon/help-document-fill.js +191 -1
  154. package/lib/icon/help-fill.js +191 -1
  155. package/lib/icon/help.js +191 -1
  156. package/lib/icon/image-fill.js +276 -1
  157. package/lib/icon/img-error.js +276 -1
  158. package/lib/icon/img-placehoulder.js +276 -1
  159. package/lib/icon/index.d.ts +1 -0
  160. package/lib/icon/index.js +2399 -1
  161. package/lib/icon/info-line.js +276 -1
  162. package/lib/icon/info.js +276 -1
  163. package/lib/icon/left-shape.js +276 -1
  164. package/lib/icon/left-turn-line.js +276 -1
  165. package/lib/icon/narrow-line.js +276 -1
  166. package/lib/icon/original.js +276 -1
  167. package/lib/icon/pdf-fill.js +276 -1
  168. package/lib/icon/play-shape.js +276 -1
  169. package/lib/icon/plus.js +276 -1
  170. package/lib/icon/ppt-fill.js +276 -1
  171. package/lib/icon/qq.js +276 -1
  172. package/lib/icon/right-shape.js +276 -1
  173. package/lib/icon/right-turn-line.js +276 -1
  174. package/lib/icon/search.js +276 -1
  175. package/lib/icon/share.js +276 -1
  176. package/lib/icon/spinner.js +276 -1
  177. package/lib/icon/success.js +276 -1
  178. package/lib/icon/switcher-loading.js +276 -1
  179. package/lib/icon/text-file.js +276 -1
  180. package/lib/icon/text-fill.js +276 -1
  181. package/lib/icon/transfer.js +276 -1
  182. package/lib/icon/tree-application-shape.js +276 -1
  183. package/lib/icon/unfull-screen.js +276 -1
  184. package/lib/icon/unvisible.js +276 -1
  185. package/lib/icon/up-shape.js +276 -1
  186. package/lib/icon/upload.js +276 -1
  187. package/lib/icon/video-fill.js +276 -1
  188. package/lib/icon/warn.js +276 -1
  189. package/lib/icon/weixin-pro.js +276 -1
  190. package/lib/icon/weixin.js +276 -1
  191. package/lib/image/index.d.ts +1 -1
  192. package/lib/image/index.js +641 -1
  193. package/lib/index.js +97 -1
  194. package/lib/info-box/index.js +1165 -2
  195. package/lib/info-box/info-box.css +2 -0
  196. package/lib/info-box/info-box.less +2 -1
  197. package/lib/info-box/info-box.variable.css +2 -0
  198. package/lib/input/index.d.ts +146 -50
  199. package/lib/input/index.js +1218 -1
  200. package/lib/input/input.css +38 -10
  201. package/lib/input/input.d.ts +100 -11
  202. package/lib/input/input.less +53 -14
  203. package/lib/input/input.variable.css +38 -10
  204. package/lib/input/util.d.ts +6 -0
  205. package/lib/link/index.d.ts +4 -4
  206. package/lib/link/index.js +160 -1
  207. package/lib/link/link.d.ts +1 -1
  208. package/lib/loading/index.d.ts +2 -2
  209. package/lib/loading/index.js +381 -1
  210. package/lib/loading/loading.css +4 -4
  211. package/lib/loading/loading.variable.css +4 -4
  212. package/lib/locale/index.js +465 -1
  213. package/lib/locale/lang/en.d.ts +1 -0
  214. package/lib/menu/index.d.ts +2 -2
  215. package/lib/menu/index.js +724 -1
  216. package/lib/menu/menu.css +4 -4
  217. package/lib/menu/menu.variable.css +4 -4
  218. package/lib/message/index.js +1795 -2
  219. package/lib/message/message.css +33 -9
  220. package/lib/message/message.less +78 -54
  221. package/lib/message/message.variable.css +33 -9
  222. package/lib/message/messageConstructor.d.ts +25 -4
  223. package/lib/modal/index.d.ts +2 -2
  224. package/lib/modal/index.js +396 -1
  225. package/lib/modal/modal.css +2 -0
  226. package/lib/modal/modal.variable.css +2 -0
  227. package/lib/navigation/index.d.ts +4 -1
  228. package/lib/navigation/index.js +367 -1
  229. package/lib/navigation/navigation.d.ts +1 -0
  230. package/lib/notify/index.js +397 -1
  231. package/lib/notify/notifyConstructor.d.ts +1 -1
  232. package/lib/overflow-title/components/overflow-title.d.ts +257 -1
  233. package/lib/overflow-title/index.d.ts +387 -2
  234. package/lib/overflow-title/index.js +461 -1
  235. package/lib/overflow-title/props.d.ts +129 -0
  236. package/lib/pagination/index.d.ts +2 -2
  237. package/lib/pagination/index.js +880 -1
  238. package/lib/plugin-popover/index.js +3905 -1
  239. package/lib/plugins/index.js +63 -1
  240. package/lib/pop-confirm/index.d.ts +1 -1
  241. package/lib/pop-confirm/index.js +273 -1
  242. package/lib/popover/content.d.ts +33 -0
  243. package/lib/popover/index.d.ts +74 -16
  244. package/lib/popover/index.js +3913 -1
  245. package/lib/popover/popover.css +1 -0
  246. package/lib/popover/popover.d.ts +40 -7
  247. package/lib/popover/popover.less +3 -2
  248. package/lib/popover/popover.variable.css +1 -0
  249. package/lib/popover/props.d.ts +25 -2
  250. package/lib/popover/use-floating.d.ts +1 -1
  251. package/lib/popover/use-popover-init.d.ts +2 -1
  252. package/lib/popover2/index.d.ts +1 -1
  253. package/lib/popover2/index.js +107 -1
  254. package/lib/preset.d.ts +2 -0
  255. package/lib/preset.js +93 -1
  256. package/lib/process/index.d.ts +1 -1
  257. package/lib/process/index.js +759 -2
  258. package/lib/progress/index.d.ts +1 -1
  259. package/lib/progress/index.js +431 -1
  260. package/lib/progress/progress.css +4 -4
  261. package/lib/progress/progress.variable.css +4 -4
  262. package/lib/radio/index.d.ts +23 -23
  263. package/lib/radio/index.js +627 -1
  264. package/lib/radio/radio-button.d.ts +4 -4
  265. package/lib/radio/radio-group.d.ts +4 -4
  266. package/lib/radio/radio.d.ts +4 -4
  267. package/lib/rate/index.d.ts +8 -4
  268. package/lib/rate/index.js +338 -1
  269. package/lib/rate/rate.d.ts +2 -1
  270. package/lib/resize-layout/index.d.ts +4 -4
  271. package/lib/resize-layout/index.js +429 -1
  272. package/lib/resize-layout/resize-layout.css +12 -0
  273. package/lib/resize-layout/resize-layout.d.ts +1 -1
  274. package/lib/resize-layout/resize-layout.less +12 -0
  275. package/lib/resize-layout/resize-layout.variable.css +12 -0
  276. package/lib/search-select/index.d.ts +62 -29
  277. package/lib/search-select/index.js +2729 -2
  278. package/lib/search-select/input.d.ts +5 -1
  279. package/lib/search-select/menu.d.ts +33 -2
  280. package/lib/search-select/search-select.css +38 -20
  281. package/lib/search-select/search-select.d.ts +23 -20
  282. package/lib/search-select/search-select.less +35 -14
  283. package/lib/search-select/search-select.variable.css +38 -20
  284. package/lib/search-select/selected.d.ts +5 -1
  285. package/lib/search-select/utils.d.ts +13 -5
  286. package/lib/select/common.d.ts +1 -0
  287. package/lib/select/index.d.ts +198 -72
  288. package/lib/select/index.js +2254 -2
  289. package/lib/select/option.d.ts +11 -0
  290. package/lib/select/select.css +13 -5
  291. package/lib/select/select.d.ts +83 -31
  292. package/lib/select/select.less +11 -1
  293. package/lib/select/select.variable.css +37 -29
  294. package/lib/select/selectTagInput.d.ts +8 -5
  295. package/lib/shared/helper.d.ts +1 -1
  296. package/lib/shared/index.js +2689 -1
  297. package/lib/shared/mask-manager.d.ts +3 -4
  298. package/lib/shared/pop-manager.d.ts +6 -2
  299. package/lib/shared/popover.d.ts +2 -2
  300. package/lib/shared/vue-types.d.ts +3 -2
  301. package/lib/sideslider/index.d.ts +1 -1
  302. package/lib/sideslider/index.js +714 -2
  303. package/lib/slider/index.d.ts +1 -1
  304. package/lib/slider/index.js +1291 -2
  305. package/lib/steps/index.d.ts +1 -1
  306. package/lib/steps/index.js +825 -2
  307. package/lib/styles/mixins/animate.css +4 -4
  308. package/lib/styles/mixins/animate.less +10 -6
  309. package/lib/styles/mixins/animate.variable.css +126 -4
  310. package/lib/styles/mixins/clearfix.css +8 -0
  311. package/lib/styles/mixins/clearfix.less +10 -0
  312. package/lib/styles/mixins/clearfix.variable.css +8 -0
  313. package/lib/styles/mixins/mixins.css +72 -0
  314. package/lib/styles/mixins/mixins.less +5 -0
  315. package/lib/styles/mixins/mixins.variable.css +72 -0
  316. package/lib/styles/mixins/popper.less +6 -5
  317. package/lib/swiper/index.d.ts +1 -1
  318. package/lib/swiper/index.js +336 -1
  319. package/lib/swiper/swiper.css +0 -6
  320. package/lib/swiper/swiper.less +0 -8
  321. package/lib/swiper/swiper.variable.css +0 -6
  322. package/lib/switcher/index.d.ts +30 -16
  323. package/lib/switcher/index.js +277 -1
  324. package/lib/switcher/switcher.css +4 -4
  325. package/lib/switcher/switcher.d.ts +74 -5
  326. package/lib/switcher/switcher.variable.css +4 -4
  327. package/lib/tab/index.d.ts +3 -3
  328. package/lib/tab/index.js +914 -1
  329. package/lib/tab/tab-nav.d.ts +12 -2
  330. package/lib/tab/tab-panel.d.ts +1 -1
  331. package/lib/table/components/table-cell.d.ts +22 -24
  332. package/lib/table/components/table-column.d.ts +125 -82
  333. package/lib/table/const.d.ts +24 -2
  334. package/lib/table/events.d.ts +26 -26
  335. package/lib/table/index.d.ts +281 -295
  336. package/lib/table/index.js +6243 -1
  337. package/lib/table/plugins/head-filter.css +3 -0
  338. package/lib/table/plugins/head-filter.less +3 -0
  339. package/lib/table/plugins/head-filter.variable.css +3 -0
  340. package/lib/table/plugins/settings.d.ts +7 -17
  341. package/lib/table/plugins/use-column-resize.d.ts +30 -10
  342. package/lib/table/plugins/use-fixed-column.d.ts +9 -9
  343. package/lib/table/plugins/use-pagination.d.ts +7 -4
  344. package/lib/table/props.d.ts +118 -58
  345. package/lib/table/render.d.ts +7 -17
  346. package/lib/table/table.css +83 -11
  347. package/lib/table/table.d.ts +95 -72
  348. package/lib/table/table.less +59 -21
  349. package/lib/table/table.variable.css +83 -11
  350. package/lib/table/use-attributes.d.ts +55 -0
  351. package/lib/table/use-column.d.ts +264 -49
  352. package/lib/table/use-common.d.ts +1608 -88
  353. package/lib/table/use-render.d.ts +11 -0
  354. package/lib/table/utils.d.ts +30 -29
  355. package/lib/table-column/index.d.ts +241 -408
  356. package/lib/table-column/index.js +766 -1
  357. package/lib/tag/index.d.ts +10 -10
  358. package/lib/tag/index.js +233 -1
  359. package/lib/tag/tag.d.ts +5 -5
  360. package/lib/tag-input/index.d.ts +49 -7
  361. package/lib/tag-input/index.js +1660 -1
  362. package/lib/tag-input/tag-input.css +9 -1
  363. package/lib/tag-input/tag-input.d.ts +32 -4
  364. package/lib/tag-input/tag-input.less +13 -4
  365. package/lib/tag-input/tag-input.variable.css +9 -1
  366. package/lib/tag-input/tag-props.d.ts +16 -2
  367. package/lib/time-picker/index.d.ts +4 -4
  368. package/lib/time-picker/index.js +71 -1
  369. package/lib/timeline/index.d.ts +1 -1
  370. package/lib/timeline/index.js +241 -1
  371. package/lib/transfer/index.d.ts +1 -1
  372. package/lib/transfer/index.js +673 -1
  373. package/lib/tree/constant.d.ts +2 -2
  374. package/lib/tree/index.d.ts +58 -22
  375. package/lib/tree/index.js +2512 -1
  376. package/lib/tree/props.d.ts +18 -6
  377. package/lib/tree/tree.d.ts +32 -11
  378. package/lib/tree/use-node-action.d.ts +5 -3
  379. package/lib/tree/use-node-attribute.d.ts +17 -8
  380. package/lib/tree/use-search.d.ts +2 -2
  381. package/lib/tree/use-tree-init.d.ts +1 -2
  382. package/lib/tree/util.d.ts +8 -3
  383. package/lib/upload/index.d.ts +1 -1
  384. package/lib/upload/index.js +2874 -2
  385. package/lib/upload/upload.css +4 -4
  386. package/lib/upload/upload.type.d.ts +1 -1
  387. package/lib/upload/upload.variable.css +4 -4
  388. package/lib/upload/use-file-handler.d.ts +2 -2
  389. package/lib/virtual-render/index.d.ts +43 -1
  390. package/lib/virtual-render/index.js +865 -1
  391. package/lib/virtual-render/props.d.ts +15 -0
  392. package/lib/virtual-render/v-virtual-render.d.ts +19 -1
  393. package/lib/virtual-render/virtual-render.d.ts +25 -0
  394. package/lib/volar.components.d.ts +24 -24
  395. package/package.json +29 -17
  396. package/lib/cascader/index.js.LICENSE.txt +0 -1
  397. package/lib/dialog/index.js.LICENSE.txt +0 -1
  398. package/lib/directives/index.js.LICENSE.txt +0 -14
  399. package/lib/info-box/index.js.LICENSE.txt +0 -1
  400. package/lib/message/index.js.LICENSE.txt +0 -6
  401. package/lib/process/index.js.LICENSE.txt +0 -1
  402. package/lib/search-select/index.js.LICENSE.txt +0 -1
  403. package/lib/select/index.js.LICENSE.txt +0 -1
  404. package/lib/sideslider/index.js.LICENSE.txt +0 -1
  405. package/lib/slider/index.js.LICENSE.txt +0 -1
  406. package/lib/steps/index.js.LICENSE.txt +0 -1
  407. package/lib/upload/index.js.LICENSE.txt +0 -1
@@ -1 +1,2689 @@
1
- !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("vue"),require("lodash"),require("@popperjs/core"),require("vue-types"));else if("function"==typeof define&&define.amd)define(["vue","lodash","@popperjs/core","vue-types"],t);else{var n="object"==typeof exports?t(require("vue"),require("lodash"),require("@popperjs/core"),require("vue-types")):t(e.vue,e.lodash,e["@popperjs/core"],e["vue-types"]);for(var i in n)("object"==typeof exports?exports:e)[i]=n[i]}}(self,((e,t,n,i)=>(()=>{var r={8022:(e,t,n)=>{var i=n(4481),r=n(6426),o=r;o.v1=i,o.v4=r,e.exports=o},8725:e=>{for(var t=[],n=0;n<256;++n)t[n]=(n+256).toString(16).substr(1);e.exports=function(e,n){var i=n||0,r=t;return[r[e[i++]],r[e[i++]],r[e[i++]],r[e[i++]],"-",r[e[i++]],r[e[i++]],"-",r[e[i++]],r[e[i++]],"-",r[e[i++]],r[e[i++]],"-",r[e[i++]],r[e[i++]],r[e[i++]],r[e[i++]],r[e[i++]],r[e[i++]]].join("")}},9157:e=>{var t="undefined"!=typeof crypto&&crypto.getRandomValues&&crypto.getRandomValues.bind(crypto)||"undefined"!=typeof msCrypto&&"function"==typeof window.msCrypto.getRandomValues&&msCrypto.getRandomValues.bind(msCrypto);if(t){var n=new Uint8Array(16);e.exports=function(){return t(n),n}}else{var i=new Array(16);e.exports=function(){for(var e,t=0;t<16;t++)0==(3&t)&&(e=4294967296*Math.random()),i[t]=e>>>((3&t)<<3)&255;return i}}},4481:(e,t,n)=>{var i,r,o=n(9157),s=n(8725),a=0,u=0;e.exports=function(e,t,n){var c=t&&n||0,l=t||[],p=(e=e||{}).node||i,f=void 0!==e.clockseq?e.clockseq:r;if(null==p||null==f){var d=o();null==p&&(p=i=[1|d[0],d[1],d[2],d[3],d[4],d[5]]),null==f&&(f=r=16383&(d[6]<<8|d[7]))}var h=void 0!==e.msecs?e.msecs:(new Date).getTime(),v=void 0!==e.nsecs?e.nsecs:u+1,y=h-a+(v-u)/1e4;if(y<0&&void 0===e.clockseq&&(f=f+1&16383),(y<0||h>a)&&void 0===e.nsecs&&(v=0),v>=1e4)throw new Error("uuid.v1(): Can't create more than 10M uuids/sec");a=h,u=v,r=f;var g=(1e4*(268435455&(h+=122192928e5))+v)%4294967296;l[c++]=g>>>24&255,l[c++]=g>>>16&255,l[c++]=g>>>8&255,l[c++]=255&g;var m=h/4294967296*1e4&268435455;l[c++]=m>>>8&255,l[c++]=255&m,l[c++]=m>>>24&15|16,l[c++]=m>>>16&255,l[c++]=f>>>8|128,l[c++]=255&f;for(var k=0;k<6;++k)l[c+k]=p[k];return t||s(l)}},6426:(e,t,n)=>{var i=n(9157),r=n(8725);e.exports=function(e,t,n){var o=t&&n||0;"string"==typeof e&&(t="binary"===e?new Array(16):null,e=null);var s=(e=e||{}).random||(e.rng||i)();if(s[6]=15&s[6]|64,s[8]=63&s[8]|128,t)for(var a=0;a<16;++a)t[o+a]=s[a];return t||r(s)}},5798:e=>{"use strict";e.exports=n},467:e=>{"use strict";e.exports=t},748:t=>{"use strict";t.exports=e},210:e=>{"use strict";e.exports=i}},o={};function s(e){var t=o[e];if(void 0!==t)return t.exports;var n=o[e]={exports:{}};return r[e](n,n.exports,s),n.exports}s.d=(e,t)=>{for(var n in t)s.o(t,n)&&!s.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},s.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),s.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var a={};return(()=>{"use strict";s.r(a),s.d(a,{AlignEnum:()=>ce,BKLAYERD_INDEX_EFAULT_VALUE:()=>H,BKLAYERTYPE:()=>j,BKPopIndexManager:()=>K,BKPopover:()=>$,BkMaskManager:()=>q,DialogTypeEnum:()=>he,DirectionEnum:()=>ve,EMPTY_OBJ:()=>Be,InputBehaviorEnum:()=>me,InputBehaviorType:()=>Ue,LineStyleEnum:()=>ye,PlacementEnum:()=>pe,Placements:()=>ae,ProgressEnum:()=>be,ProgressStrokeLineCapEnum:()=>ke,ProgressStrokeLineCapType:()=>Ne,ProgressType:()=>Pe,PropTypes:()=>_e,RenderDirectiveEnum:()=>ue,RenderType:()=>de,SelectedType:()=>Fe,SelectedTypeEnum:()=>De,SizeEnum:()=>se,SwitcherThemeEnum:()=>Te,SwitcherThemeType:()=>je,TagThemeEnum:()=>ge,TagThemeType:()=>Le,ThemeEnum:()=>le,TriggerEnum:()=>fe,alignType:()=>Se,arrayEqual:()=>Je,bKMaskManager:()=>z,bkPopIndexManager:()=>W,bkZIndexManager:()=>B,capitalize:()=>D,checkOverflow:()=>_,classes:()=>He,clone:()=>h,debounce:()=>Ye,dialogTypeUnion:()=>Ae,directionType:()=>Re,elementsEqual:()=>d,filterProperty:()=>Ze,finiteOrDefault:()=>p,formItemKey:()=>S,formKey:()=>E,getPopContainerId:()=>ee,hasOverflowEllipsis:()=>T,isArray:()=>u,isElement:()=>b,isEmpty:()=>o,isEmptyObj:()=>ze,isFinite:()=>l,isNullOrUndef:()=>r,isObject:()=>c,lineStyleType:()=>Ce,maybeShowTooltip:()=>I,merge:()=>g,mergeIf:()=>m,mergerFn:()=>y,mergerIfFn:()=>k,noop:()=>Ve,observerResize:()=>U,off:()=>t,on:()=>e,placementType:()=>Me,random:()=>P,renderDirectiveType:()=>Ee,renderEmptyVNode:()=>qe,renderType:()=>xe,resolveClassName:()=>Ge,scrollTop:()=>n,scrollbarWidth:()=>te,stringEnum:()=>Oe,triggerType:()=>we,useForm:()=>M,useFormItem:()=>w,valueOrDefault:()=>f,withInstall:()=>Ke,withInstallProps:()=>We});var e=document.addEventListener?function(e,t,n){e&&t&&n&&e.addEventListener(t,n,!0)}:function(e,t,n){e&&t&&n&&e.attachEvent("on".concat(t),n)},t=document.removeEventListener?function(e,t,n){e&&t&&e.removeEventListener(t,n,!0)}:function(e,t,n){e&&t&&e.detachEvent("on".concat(t),n)};function n(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2?arguments[2]:void 0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:500,r=arguments.length>4?arguments[4]:void 0,o=Math.abs(t-n);!function t(n,i,o){if(n!==i){var s=n+o>i?i:n+o;n>i&&(s=n-o<i?i:n-o),e===window?window.scrollTo(s,s):e.scrollTop=s,window.requestAnimationFrame((function(){return t(s,i,o)}))}else null==r||r()}(t,n,Math.ceil(o/i*50))}function i(e){return i="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},i(e)}function r(e){return null==e}function o(e){return""===e||!(arguments.length>1&&void 0!==arguments[1]&&!arguments[1])&&r(e)}function u(e){if(Array.isArray(e))return!0;var t=Object.prototype.toString.call(e);return"[object"===t.substr(0,7)&&"Array]"===t.substr(-6)}function c(e){return null!==e&&/^\[object (Object|Module)\]/.test(Object.prototype.toString.call(e))}var l=function(e){return("number"==typeof e||e instanceof Number)&&isFinite(+e)};function p(e,t){return l(e)?e:t}function f(e,t){return void 0===e?t:e}function d(e,t){var n,i,r,o;if(!e||!t||e.length!==t.length)return!1;for(n=0,i=e.length;n<i;++n)if(r=e[n],o=t[n],r.datasetIndex!==o.datasetIndex||r.index!==o.index)return!1;return!0}function h(e){if(u(e))return e.map(h);if(c(e)){for(var t=Object.create(null),n=Object.keys(e),i=n.length,r=0;r<i;++r)t[n[r]]=h(e[n[r]]);return t}return e}function v(e){return-1===["__proto__","prototype","constructor"].indexOf(e)}function y(e,t,n,i){if(v(e)){var r=t[e],o=n[e];c(r)&&c(o)?g(r,o,i):t[e]=h(o)}}function g(e,t,n){var i=u(t)?t:[t],r=i.length;if(!c(e))return e;for(var o=(n=n||{}).merger||y,s=0;s<r;++s)if(c(t=i[s]))for(var a=Object.keys(t),l=0,p=a.length;l<p;++l)o(a[l],e,t,n);return e}function m(e,t){return g(e,t,{merger:k})}function k(e,t,n){if(v(e)){var i=t[e],r=n[e];c(i)&&c(r)?m(i,r):Object.prototype.hasOwnProperty.call(t,e)||(t[e]=h(r))}}function b(e){try{return e instanceof HTMLElement}catch(t){return"object"===i(e)&&1===e.nodeType&&"object"===i(e.style)&&"object"===i(e.ownerDocument)}}function T(e){return e.offsetWidth<e.scrollWidth||e.offsetHeight<e.scrollHeight}function I(e,t){T(e)?e.setAttribute("title",t):e.removeAttribute("title")}var O=s(748),E=Symbol("form"),S=Symbol("formItem"),M=function(){return(0,O.inject)(E)},w=function(){return(0,O.inject)(S,void 0)};function x(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function A(e){var t=function(e,t){if("object"!==i(e)||null===e)return e;var n=e[Symbol.toPrimitive];if(void 0!==n){var r=n.call(e,"string");if("object"!==i(r))return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}(e);return"symbol"===i(t)?t:String(t)}function R(e,t){for(var n=0;n<t.length;n++){var i=t[n];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,A(i.key),i)}}function C(e,t,n){return t&&R(e.prototype,t),n&&R(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var L,j,N=s(467),P=function(e){for(var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"abcdefghijklmnopqrstuvwxyz0123456789",n="",i=0;i<e;i++)n+=t[parseInt((Math.random()*t.length).toString(),10)];return n},U=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:60,i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=(0,N.throttle)((function(){"function"==typeof t&&t()}),n),o=new ResizeObserver((function(){r()}));return i&&"function"==typeof t&&t(),{start:function(){o.observe(e)},stop:function(){o.disconnect(),o.unobserve(e)}}},D=function(e){return e[0].toUpperCase()+e.slice(1)};function _(e){if(!e)return!1;var t=!1;try{var n=window.getComputedStyle(e,null);if("none"!==n.webkitLineClamp){var i=parseFloat(n.height),r=function(e,t){var n=document.createElement("div"),i=parseFloat(t.width)?"".concat(Math.ceil(parseFloat(t.width)),"px"):t.width;return n.style.cssText="\n width: ".concat(i,";\n line-height: ").concat(t["line-height"],";\n font-size: ").concat(t["font-size"],";\n word-break: ").concat(t["word-break"],";\n padding: ").concat(t.padding,";\n "),n.textContent=e.textContent,n}(e,n);document.body.appendChild(r);var o=window.getComputedStyle(r,null).height;document.body.removeChild(r),t=i<parseFloat(o)}else t=e.clientWidth<e.scrollWidth||e.clientHeight<e.scrollHeight}catch(e){console.warn("There is an error when check element overflow state: ",e)}return t}function F(e,t,n){return(t=A(t))in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}!function(e){e.BOTTOM="bottom",e.CONTENT="content",e.NAVI="navi",e.FULLSCREEN="fullScreen",e.PLUGINS="plugins",e.MODAL="modal",e.MESSAGE="message",e.POPPER="popper"}(j||(j={}));var H=(F(L={},j.BOTTOM,0),F(L,j.CONTENT,1),F(L,j.NAVI,100),F(L,j.FULLSCREEN,1e3),F(L,j.MODAL,3e3),F(L,j.PLUGINS,8e3),F(L,j.MESSAGE,1e4),F(L,j.POPPER,99999),L),B=new(function(){function e(){x(this,e),this.storageLayerIndexValue={},this.copyDefaultValue()}return C(e,[{key:"getNextIndex",value:function(e){return Object.prototype.hasOwnProperty.call(this.storageLayerIndexValue,e)?(this.storageLayerIndexValue[e]=this.storageLayerIndexValue[e]+1,this.storageLayerIndexValue[e]):(this.storageLayerIndexValue[j.MODAL]=this.storageLayerIndexValue[j.MODAL]+1,this.storageLayerIndexValue[j.MODAL])}},{key:"getModalNextIndex",value:function(){return this.getNextIndex(j.MODAL)}},{key:"getMessageNextIndex",value:function(){return this.getNextIndex(j.MESSAGE)}},{key:"getFullScreenNextIndex",value:function(){return this.getNextIndex(j.FULLSCREEN)}},{key:"getNaviNextIndex",value:function(){return this.getNextIndex(j.NAVI)}},{key:"getPopperIndex",value:function(){return H.popper}},{key:"setDefaultZIndex",value:function(e){var t=this;Object.keys(e||{}).forEach((function(n){Object.prototype.hasOwnProperty.call(t.storageLayerIndexValue.__proto__,n)&&Object.assign(t.storageLayerIndexValue.__proto__,F({},n,e[n]))})),this.copyDefaultValue()}},{key:"resetZIndex",value:function(e){var t=this;Object.keys(e||{}).forEach((function(n){Object.prototype.hasOwnProperty.call(t.storageLayerIndexValue,n)&&Object.assign(t.storageLayerIndexValue,F({},n,e[n]))}))}},{key:"copyDefaultValue",value:function(){var e=Object.keys(H).reduce((function(e,t){return Object.assign(e,F({},t,{value:H[t],writable:!0,configurable:!0}))}),{});this.storageLayerIndexValue=Object.create(H,e)}}]),e}());"__bk_mask_".concat(P(16));var V=new(function(){function e(){x(this,e),this.timer=null,this.store=[],this.maskMap=new WeakMap}return C(e,[{key:"appendMaker",value:function(e){this.store.push(e),this.executeMaker()}},{key:"pushMaskStyle",value:function(e,t){var n=this.getMaskMap(e);(null==n?void 0:n.styles)?n.styles.push(t):this.setMaskMap(e,Object.assign({styles:[t]},n||{}))}},{key:"getMaskStyles",value:function(e){var t;return(null===(t=this.getMaskMap(e))||void 0===t?void 0:t.styles)||[]}},{key:"setMaskId",value:function(e,t){var n=this.getMaskMap(e);n?(Object.assign(n,{id:t}),this.setMaskMap(e,n)):this.setMaskMap(e,Object.assign({id:t},n||{}))}},{key:"getMaskId",value:function(e){var t;return null===(t=this.getMaskMap(e))||void 0===t?void 0:t.id}},{key:"setMaskMap",value:function(e,t){this.maskMap.set(e,t)}},{key:"getMaskMap",value:function(e){return this.maskMap.get(e)}},{key:"executeMaker",value:function(){var e=this;this.timer&&cancelAnimationFrame(this.timer),this.timer=requestAnimationFrame((function(){var t=e.store.pop();"function"==typeof t&&(Reflect.apply(t,e,[]),e.executeMaker())}))}}]),e}()),q=function(){function e(t){var n=this;x(this,e),this.multiInstance=!1,this.uniqueMaskAttrTag="",this.parentNode=document.body,this.activeInstance=void 0,this.zIndexStore=new Map,this.lastUUID=null,this.maskStyle={position:"fixed",left:0,top:0,bottom:0,right:0,display:"none","background-color":"rgba(0,0,0,.6)"},this.isInit=!1,this.maskAttrTag="auto";var i=t||{},r=i.multiInstance,o=void 0!==r&&r,s=i.maskAttrTag,a=void 0===s?"auto":s,u=i.parentNode,c=void 0===u?document.body:u,l=i.maskStyle,p=void 0===l?{}:l,f=i.onClick,d=void 0===f?null:f,h=i.popInstance,v=void 0===h?null:h;this.parentNode=c||document,this.maskAttrTag=a,this.onClick=d,this.activeInstance=void 0,this.multiInstance=o,this.popInstance=v,this.uniqueMaskAttrTag=this.getMaskAttrTag(a),V.appendMaker((function(){n.initInstance(p)}))}return C(e,[{key:"setOption",value:function(e){var t=e||{},n=t.parentNode,i=void 0===n?document.body:n,r=t.maskStyle,o=void 0===r?{}:r,s=t.onClick,a=void 0===s?null:s,u=t.maskAttrTag,c=void 0===u?this.maskAttrTag:u;this.onClick=a,this.parentNode=i||document,this.setMaskStyle(Object.assign({},this.maskStyle,o)),this.uniqueMaskAttrTag=this.getMaskAttrTag(c)}},{key:"show",value:function(e,t){var n=!(arguments.length>2&&void 0!==arguments[2])||arguments[2],i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:{},r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:null,o=arguments.length>5&&void 0!==arguments[5]&&arguments[5],s=null!=r?r:P(16),a=/-?\d+/.test("".concat(t))?t:B.getModalNextIndex(),u=Object.assign({},this.maskStyle,i||{});if(!n&&this.lastUUID){var c=this.zIndexStore.get(this.lastUUID);c&&(u=null==c?void 0:c.style)}this.storeMaskInsCfg({zIndex:a,style:Object.assign({},u),uuid:s,preUID:this.lastUUID}),Object.assign(u,{display:"block","z-index":"".concat(a),"pointer-events":"all"}),this.initInstance(u),this.catchClickEvent(),this.setMaskStyle(u),V.pushMaskStyle(this.parentNode,Object.assign({},u)),this.backupMask.style.setProperty("z-index","".concat(a-1)),n||(this.mask.style.setProperty("pointer-events","none"),null==e||e.style.setProperty("pointer-events","all")),e&&(o&&e.style.setProperty("z-index","".concat(a+1)),this.activeInstance=e,this.appendContentToMask(e))}},{key:"hide",value:function(){var e,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0],n=arguments.length>1?arguments[1]:void 0,i=arguments.length>2?arguments[2]:void 0,r=null!=i?i:this.lastUUID;t||(null==n||n.remove(),null===(e=this.activeInstance)||void 0===e||e.remove()),this.removeClickEvent(),this.activeInstance=void 0,this.popIndexStore(r);var o=V.getMaskStyles(this.parentNode);if(null==o||o.pop(),null==o?void 0:o.length){var s=o.slice(-1)[0];this.setMaskStyle(s)}else this.mask.style.setProperty("display","none")}},{key:"storeMaskInsCfg",value:function(e){return this.zIndexStore.set(e.uuid,e),this.lastUUID=e.uuid,this.zIndexStore.get(e.uuid)}},{key:"popIndexStore",value:function(e){if(this.zIndexStore.has(e)){var t=this.zIndexStore.get(e);return this.lastUUID=t.preUID,this.zIndexStore.delete(e)}return this.lastUUID=null,!1}},{key:"backupActiveInstance",value:function(){this.activeInstance&&this.backupMask.append(this.activeInstance)}},{key:"backupContentElement",value:function(e){e&&this.backupMask.append(e)}},{key:"getActiveContentInstance",value:function(){return this.activeInstance}},{key:"initInstance",value:function(e){if(!this.isInit){this.isInit=!0;var t=this.getMask(),n=t.instance,i=t.isExist;this.mask=n,this.backupMask=this.getBackupMask(),!i&&this.setMaskStyle(Object.assign({},this.maskStyle,e))}}},{key:"getMask",value:function(){if(this.multiInstance)return{instance:this.createMask(),isExist:!1};var e=!0,t=this.parentNode.querySelector("[data-bk-mask-uid='".concat(this.uniqueMaskAttrTag,"']"));return t||(e=!1,t=this.createMask()),{instance:t,isExist:e}}},{key:"catchClickEvent",value:function(){var e=this;this.mask&&this.mask.addEventListener("click",(function(t){return e.handleMaskClick(t)}),!0)}},{key:"removeClickEvent",value:function(){this.mask&&this.mask.removeEventListener("click",this.handleMaskClick)}},{key:"handleMaskClick",value:function(e){e.target===this.mask&&"function"==typeof this.onClick&&Reflect.apply(this.onClick,this.popInstance||this,[e])}},{key:"getBackupMask",value:function(){var e="data-bk-backup-uid",t=this.parentNode.querySelector("[".concat(e,"]"));return t||(t=this.createMask(e)),t}},{key:"createMask",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"data-bk-mask-uid",t=document.createElement("div");return t.setAttribute(e,this.uniqueMaskAttrTag),this.parentNode.append(t),t}},{key:"setMaskStyle",value:function(){var e=this,t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};this.mask&&Object.entries(t).forEach((function(t){return e.mask.style.setProperty(t[0],t[1])}))}},{key:"getMaskAttrTag",value:function(e){return/^(auto|\s+)$/i.test(e)||null==e||""===e?(V.getMaskId(this.parentNode)||V.setMaskId(this.parentNode,"__bk_mask_".concat(P(16))),V.getMaskId(this.parentNode)):e}},{key:"appendContentToMask",value:function(e){this.mask.append(e)}}]),e}(),z=new q({}),K=function(){function e(t){x(this,e),this.popInstanceList=[],this.clickFn=void 0,this.uuidAttrName="data-bk-pop-uuid",this.bKMaskManagerInstance=new q({parentNode:this.getParentNode(null==t?void 0:t.transfer),popInstance:this,onClick:this.onMaskClickFn})}return C(e,[{key:"getParentNode",value:function(e){if("string"==typeof e){var t=document.querySelector(e);if(t)return t}return b(e)?e:document.body}},{key:"onMaskClick",value:function(e,t){this.clickFn={fn:e,target:t}}},{key:"show",value:function(e){var t=!(arguments.length>1&&void 0!==arguments[1])||arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},i=arguments.length>3&&void 0!==arguments[3]&&arguments[3],r=arguments.length>4&&void 0!==arguments[4]?arguments[4]:void 0;if(e){var o="number"==typeof r?r:B.getModalNextIndex(),s=P(16);e.setAttribute(this.uuidAttrName,s),this.popInstanceList.push({uuid:s,zIndex:o,content:e,showMask:t,appendStyle:n}),t&&this.bKMaskManagerInstance.backupActiveInstance(),this.bKMaskManagerInstance.show(e,o,t,n,s,i)}else console.warn("pop show error: content is null or undefined")}},{key:"destroy",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];this.clickFn=void 0,this.hide(e,t)}},{key:"popHide",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];if(this.popInstanceList.length){if(e){var t=this.popInstanceList.pop();this.bKMaskManagerInstance.popIndexStore(t.uuid),t.remove()}if(this.popInstanceList.length){var n=this.popInstanceList.slice(-1)[0],i=n.zIndex,r=n.content,o=n.showMask,s=n.appendStyle,a=n.uuid;this.bKMaskManagerInstance.show(r,i,o,s,a)}else this.bKMaskManagerInstance.hide()}}},{key:"hide",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=null==e?void 0:e.getAttribute(this.uuidAttrName);if(n){var i=this.popInstanceList.findIndex((function(e){return e.uuid===n}));i>=0&&(t||this.popInstanceList[i].content.remove(),this.popInstanceList.splice(i,1),this.bKMaskManagerInstance.popIndexStore(n),this.popInstanceList.length?this.popHide(!1):this.bKMaskManagerInstance.hide(t))}else null==e||e.remove()}},{key:"onMaskClickFn",value:function(e){if(this.clickFn){var t=this.clickFn.fn;t&&Reflect.apply(t,this,[e])}}}]),e}(),W=new K;function G(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,i=new Array(t);n<t;n++)i[n]=e[n];return i}function Y(e){return function(e){if(Array.isArray(e))return G(e)}(e)||function(e){if("undefined"!=typeof Symbol&&null!=e[Symbol.iterator]||null!=e["@@iterator"])return Array.from(e)}(e)||function(e,t){if(e){if("string"==typeof e)return G(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)?G(e,t):void 0}}(e)||function(){throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}()}var Z,J=s(8022),X=s(5798),$=function(){function e(t,n,i){var r,o;x(this,e),this.isShow=!1,this.trigger=void 0,this.instance=void 0,this.always=!1,this.reference=void 0,this.referenceTarget=void 0,this.popperRefer=void 0,this.delay=50,this.isInnerPopper=!1,this.disabled=!1,this.afterShow=null,this.afterHidden=null,this.appendTo="parent",this.container=null,this.fixOnBoundary=!1,this.instanceOptions=this.initDefaultOptions(i),this.reference=this.resolveInputSelectorToHtmlElement(t),this.popperRefer=this.resolveInputSelectorToHtmlElement(n),this.referenceTarget=this.getTargetReferenceElement(),this.container=null===(r=this.popperRefer)||void 0===r?void 0:r.parentElement,this.isShow=!!(null===(o=this.instanceOptions)||void 0===o?void 0:o.isShow),this.always=this.instanceOptions.always,this.trigger=this.instanceOptions.trigger,this.disabled=this.instanceOptions.disabled,this.appendTo=this.instanceOptions.appendTo,this.afterHidden="function"==typeof i.afterHidden?i.afterHidden:function(){},this.afterShow="function"==typeof i.afterShow?i.afterShow:function(){},this.fixOnBoundary=this.instanceOptions.fixOnBoundary,this.initInstance(),this.registerEvents(),(this.isShow||this.always)&&this.show(null)}return C(e,[{key:"forceUpdate",value:function(){var e;null===(e=this.instance)||void 0===e||e.forceUpdate()}},{key:"update",value:function(){var e;null===(e=this.instance)||void 0===e||e.update()}},{key:"updateOptions",value:function(e){var t;this.instanceOptions=this.initDefaultOptions(e),this.isShow=!!(null===(t=this.instanceOptions)||void 0===t?void 0:t.isShow),this.trigger=this.instanceOptions.trigger,this.disabled=this.instanceOptions.disabled,this.setOptions(this.instanceOptions)}},{key:"setOptions",value:function(e){var t;null===(t=this.instance)||void 0===t||t.setOptions(e)}},{key:"destroy",value:function(){var e;null===(e=this.instance)||void 0===e||e.destroy()}},{key:"updateDisabled",value:function(e){this.disabled=null!=e?e:!this.disabled,this.disabled&&this.hide()}},{key:"show",value:function(e){var t;this.disabled||(null===(t=this.popperRefer)||void 0===t||t.setAttribute("data-show",""),this.setOptions({modifiers:[].concat(Y(this.instanceOptions.modifiers||[]),[{name:"eventListeners",enabled:!0}])}),this.update(),this.isShow=!0,this.afterShow(),this.fixOnBoundary||this.appendToTarget())}},{key:"hide",value:function(){var e;this.always||(null===(e=this.popperRefer)||void 0===e||e.removeAttribute("data-show"),this.setOptions({modifiers:[].concat(Y(this.instanceOptions.modifiers||[]),[{name:"eventListeners",enabled:!1}])}),this.isShow=!1,this.isInnerPopper=!1,this.afterHidden(),this.fixOnBoundary||this.restorePopContent())}},{key:"restorePopContent",value:function(){var e=this.getAppendToTarget();b(e)&&e.contains(this.popperRefer)&&this.container&&!this.container.contains(this.popperRefer)&&this.container.append(this.popperRefer)}},{key:"appendToTarget",value:function(){var e=this.getAppendToTarget();b(e)&&e.contains(this.popperRefer)&&e.append(this.popperRefer)}},{key:"getAppendToTarget",value:function(){var e=this.appendTo,t=e;return"parent"!==e&&"string"==typeof e&&(t=document.querySelector(e)),t}},{key:"initDefaultOptions",value:function(e){var t=this,n=g({placement:"top",modifiers:[{name:"offset",options:{offset:[0,8]}}],strategy:"absolute",onFirstUpdate:void 0,isShow:!1,theme:"dark",trigger:"hover",disabled:!1},e||{}),i=n.onFirstUpdate;return n.onFirstUpdate=function(e){"function"==typeof i&&(i.call(t,e),t.handleFirstUpdate())},n}},{key:"handleFirstUpdate",value:function(){this.fixOnBoundary&&this.appendToTarget()}},{key:"getTargetReferenceElement",value:function(){return this.isElement(this.reference)&&1===this.reference.childElementCount?this.reference.firstElementChild:this.reference}},{key:"initInstance",value:function(){var e,t;this.referenceTarget&&(this.referenceTarget&&this.popperRefer?(this.instance=(0,X.createPopper)(this.referenceTarget,this.popperRefer,this.instanceOptions),null===(e=this.popperRefer)||void 0===e||e.setAttribute("data-theme",null!==(t=this.instanceOptions.theme)&&void 0!==t?t:"dark")):console.error("reference or popperRefer is null, please check html element."))}},{key:"resolveInputSelectorToHtmlElement",value:function(e){if(this.isElement(e))return e;if("string"==typeof e)return document.querySelector(e);if("object"===i(e)){if(Object.prototype.hasOwnProperty.call(e,"getBoundingClientRect"))return e}else console.error("'getBoundingClientRect' is needed when use virtual elements");return null}},{key:"isElement",value:function(e){return b(e)}},{key:"registerEvents",value:function(){var e=this;this.isElement(this.referenceTarget)&&"hover"===this.trigger&&(["mouseenter","focus"].forEach((function(t){e.referenceTarget.addEventListener(t,(function(n){"mouseenter"===t&&(e.isInnerPopper=!0),e.show(n)}))})),["mouseleave","blur"].forEach((function(t){e.referenceTarget.addEventListener(t,(function(){e.isInnerPopper=!1,setTimeout((function(){!e.isInnerPopper&&e.hide()}),e.delay)}))})),this.isElement(this.popperRefer)&&["mouseenter","mouseleave"].forEach((function(t){e.popperRefer.addEventListener(t,(function(){"mouseenter"===t&&(e.isInnerPopper=!0),"mouseleave"===t&&e.hide()}))}))),"click"===this.trigger&&["click"].forEach((function(t){document.body.addEventListener(t,(function(t){e.isSameElement(t.target,e.reference)||e.reference.contains(t.target)?e.show(t):!e.isShow||e.isSameElement(t.target,e.popperRefer)||e.popperRefer.contains(t.target)||e.hide()}))}))}},{key:"isSameElement",value:function(e,t){return e&&(e===t||e===t.firstElementChild)}}]),e}(),Q=null,ee=function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"#";if(null===Q){Q="id_".concat((0,J.v4)());var t=document.createElement("div");t.setAttribute("id",Q),t.setAttribute("data-popper-id",Q),document.body.append(t)}return"".concat(e).concat(Q)};function te(){if(void 0!==Z)return Z;var e=document.createElement("div");e.className="bk-scrollbar-wrap",e.style.visibility="hidden",e.style.width="100px",e.style.position="absolute",e.style.top="-9999px",document.body.appendChild(e);var t=e.offsetWidth;e.style.overflow="scroll";var n=document.createElement("div");n.style.width="100%",e.appendChild(n);var i=n.offsetWidth;return e.parentNode.removeChild(e),Z=t-i}function ne(e,t){return ne=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(e,t){return e.__proto__=t,e},ne(e,t)}function ie(e){return ie=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},ie(e)}var re=s(210);function oe(e){var t=function(){if("undefined"==typeof Reflect||!Reflect.construct)return!1;if(Reflect.construct.sham)return!1;if("function"==typeof Proxy)return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],(function(){}))),!0}catch(e){return!1}}();return function(){var n,r=ie(e);if(t){var o=ie(this).constructor;n=Reflect.construct(r,arguments,o)}else n=r.apply(this,arguments);return function(e,t){if(t&&("object"===i(t)||"function"==typeof t))return t;if(void 0!==t)throw new TypeError("Derived constructors may only return object or undefined");return function(e){if(void 0===e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}(e)}(this,n)}}var se,ae,ue,ce,le,pe,fe,de,he,ve,ye,ge,me,ke,be,Te,Ie=(0,re.createTypes)({});function Oe(e){return e.reduce((function(e,t){return e[t]=t,e}),Object.create(null))}function Ee(){return(0,re.string)().def(ue.SHOW)}function Se(){return(0,re.string)().def(ce.LEFT)}function Me(){return(0,re.string)().def(pe.BOTTOM)}function we(){return(0,re.string)().def(fe.HOVER)}function xe(){return(0,re.toType)("popRenderType",{}).def(de.SHOWN)}function Ae(){return(0,re.toType)("dialogType",{default:he.OPERATION})}function Re(){return(0,re.toType)("direction",{}).def(ve.HORIZONTAL)}function Ce(){return(0,re.toType)("lineType",{}).def(ye.DASHED)}function Le(){return(0,re.toType)("tagTheme",{}).def()}function je(){return(0,re.toType)("switcherTheme",{}).def(Te.SUCCESS)}function Ne(){return(0,re.toType)("progressStrokeLineCap",{}).def(ke.ROUNDE)}function Pe(){return(0,re.toType)("progress",{}).def(be.LINE)}function Ue(){return(0,re.toType)("behavior",{}).def(me.NORMAL)}!function(e){e.SMALL="small",e.LARGE="large",e.DEFAULT="default"}(se||(se={})),function(e){e.Top="top",e.Left="left",e.Right="right",e.Bottom="bottom"}(ae||(ae={})),function(e){e.IF="if",e.SHOW="show"}(ue||(ue={})),function(e){e.LEFT="left",e.CENTER="center",e.RIGHT="right"}(ce||(ce={})),function(e){e.PRIMARY="primary",e.WARNING="warning",e.SUCCESS="success",e.DANGER="danger"}(le||(le={})),function(e){e.AUTO="auto",e.AUTO_START="auto-start",e.AUTO_END="auto-end",e.TOP="top",e.RIGHT="right",e.BOTTOM="bottom",e.LEFT="left",e.TOP_START="top-start",e.TOP_END="top-end",e.BOTTOM_START="bottom-start",e.BOTTOM_END="bottom-end",e.RIGHT_START="right-start",e.RIGHT_END="right-end",e.LEFT_START="left-start",e.LEFT_END="left-end"}(pe||(pe={})),function(e){e.HOVER="hover",e.CLICK="click",e.MANUAL="manual"}(fe||(fe={})),function(e){e.AUTO="auto",e.SHOWN="shown"}(de||(de={})),function(e){e.SHOW="show",e.OPERATION="operation",e.CONFIRM="confirm",e.PROCESS="process"}(he||(he={})),function(e){e.HORIZONTAL="horizontal",e.VERTICAL="vertical"}(ve||(ve={})),function(e){e.DASHED="dashed",e.SOLID="solid"}(ye||(ye={})),function(e){e.SUCCESS="success",e.INFO="info",e.WARNING="warning",e.DANGER="danger"}(ge||(ge={})),function(e){e.SIMPLICITY="simplicity",e.NORMAL="normal"}(me||(me={})),function(e){e.BUTT="butt",e.SQUARE="square",e.ROUNDE="round"}(ke||(ke={})),function(e){e.LINE="line",e.CIRCLE="circle",e.DASHBOARD="dashboard"}(be||(be={})),function(e){e.SUCCESS="success",e.PRIMARY="primary"}(Te||(Te={}));var De,_e=function(e){!function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&ne(e,t)}(n,e);var t=oe(n);function n(){return x(this,n),t.apply(this,arguments)}return C(n,null,[{key:"size",value:function(){var e=["small","default","large"];return(0,re.toType)("Size",{validator:function(t){return!(t&&!e.includes(t)&&(console.error("invalid theme, ".concat(t,", the theme must be one of 【").concat(e.join(" | "),"】")),1))},default:"default"})}},{key:"theme",value:function(){var e=["primary","warning","success","danger"];return(0,re.toType)("Theme",{validator:function(t){return!(t&&!e.includes(t)&&(console.error("invalid theme, ".concat(t,", the theme must be one of 【").concat(e.join(" | "),"】")),1))}})}},{key:"placement",value:function(){var e=["top","left","right","bottom"];return(0,re.toType)("Placements",{validator:function(t){return!(t&&!e.includes(t))},default:"top"})}},{key:"style",value:function(){return(0,re.toType)("Style",{type:[String,Object]})}},{key:"position",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:["top-left","top-right","bottom-left","bottom-right"];return(0,re.toType)("positions",{type:String,validator:function(t){return!(t&&!e.includes(t)&&(console.error("invalid positions, ".concat(t,", the position must be one of 【").concat(e.join(" | "),"】")),1))},default:"top-center"})}}]),n}(Ie);function Fe(){return(0,re.toType)("selectedStyle",{}).def(De.CHECK)}function He(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";return Object.entries(e).filter((function(e){return e[1]})).map((function(e){return e[0]})).join(" ").concat(t?" ".concat(t):"")}!function(e){e.CHECKBOX="checkbox",e.CHECK="check"}(De||(De={}));var Be=Object.create({}),Ve=function(){},qe=function(){return null},ze=function(e){return Object.keys(e).length<1},Ke=function(e){return e.install=function(t){var n=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).prefix,i=t.config.globalProperties.bkUIPrefix||n||"Bk";t.component(i+e.name,e)},e},We=function(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2],i=arguments.length>3?arguments[3]:void 0;return e.install=function(r){var o=(arguments.length>1&&void 0!==arguments[1]?arguments[1]:{}).prefix,s=r.config.globalProperties.bkUIPrefix||o||"Bk";i&&r.directive(s+i.name,i.directive),r.component(s+e.name,e),!n&&Object.values(t).forEach((function(e){r.component(s+e.name,e)}))},Object.keys(t).forEach((function(n){e[n]=t[n]})),e};function Ge(e){return"".concat(arguments.length>1&&void 0!==arguments[1]?arguments[1]:"bk","-").concat(e)}function Ye(){var e,t,n=arguments.length>0&&void 0!==arguments[0]?arguments[0]:300,i=arguments.length>1?arguments[1]:void 0,r=arguments.length>2&&void 0!==arguments[2]&&arguments[2],o=function(){var o=this,s=arguments;if(e&&clearTimeout(e),r){var a=!e;e=setTimeout((function(){e=null}),n),a&&(t=i.apply(o,s))}else e=setTimeout((function(){i.apply(o,s)}),n);return t};return o.cancel=function(){clearTimeout(e),e=null},o}function Ze(e,t){return JSON.parse(JSON.stringify(e,(function(e,n){if(!t.includes(e))return n})))}function Je(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[];if(e.length!==t.length)return!1;for(var n=0;n<e.length;n++){if(Array.isArray(e[n]))return Je(e[n],t[n]);if(e[n]!==t[n])return!1}return!0}})(),a})()));
1
+ import * as __WEBPACK_EXTERNAL_MODULE_vue__ from "vue";
2
+ import * as __WEBPACK_EXTERNAL_MODULE_lodash_throttle_a7b7506a__ from "lodash/throttle";
3
+ import * as __WEBPACK_EXTERNAL_MODULE__popperjs_core_a5c7319c__ from "@popperjs/core";
4
+ import * as __WEBPACK_EXTERNAL_MODULE_vue_types_22de060a__ from "vue-types";
5
+ /******/ // The require scope
6
+ /******/ var __webpack_require__ = {};
7
+ /******/
8
+ /************************************************************************/
9
+ /******/ /* webpack/runtime/define property getters */
10
+ /******/ (() => {
11
+ /******/ // define getter functions for harmony exports
12
+ /******/ __webpack_require__.d = (exports, definition) => {
13
+ /******/ for(var key in definition) {
14
+ /******/ if(__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
15
+ /******/ Object.defineProperty(exports, key, { enumerable: true, get: definition[key] });
16
+ /******/ }
17
+ /******/ }
18
+ /******/ };
19
+ /******/ })();
20
+ /******/
21
+ /******/ /* webpack/runtime/hasOwnProperty shorthand */
22
+ /******/ (() => {
23
+ /******/ __webpack_require__.o = (obj, prop) => (Object.prototype.hasOwnProperty.call(obj, prop))
24
+ /******/ })();
25
+ /******/
26
+ /************************************************************************/
27
+ var __webpack_exports__ = {};
28
+
29
+ // EXPORTS
30
+ __webpack_require__.d(__webpack_exports__, {
31
+ oY: () => (/* reexport */ AlignEnum),
32
+ p3: () => (/* reexport */ BKLAYERD_INDEX_EFAULT_VALUE),
33
+ Ql: () => (/* reexport */ BKLAYERTYPE),
34
+ Eo: () => (/* reexport */ BKPopIndexManager),
35
+ mZ: () => (/* reexport */ BKPopover),
36
+ Wg: () => (/* reexport */ BkMaskManager),
37
+ _D: () => (/* reexport */ DialogTypeEnum),
38
+ dq: () => (/* reexport */ DirectionEnum),
39
+ kT: () => (/* binding */ EMPTY_OBJ),
40
+ WF: () => (/* reexport */ InputBehaviorEnum),
41
+ Gl: () => (/* reexport */ InputBehaviorType),
42
+ VS: () => (/* reexport */ LineStyleEnum),
43
+ Um: () => (/* reexport */ PlacementEnum),
44
+ _h: () => (/* reexport */ Placements),
45
+ rU: () => (/* reexport */ ProgressEnum),
46
+ _q: () => (/* reexport */ ProgressStrokeLineCapEnum),
47
+ Hl: () => (/* reexport */ ProgressStrokeLineCapType),
48
+ Mc: () => (/* reexport */ ProgressType),
49
+ ng: () => (/* reexport */ PropTypes),
50
+ Pi: () => (/* reexport */ RenderDirectiveEnum),
51
+ y2: () => (/* reexport */ RenderType),
52
+ qt: () => (/* reexport */ SelectedType),
53
+ aL: () => (/* reexport */ SelectedTypeEnum),
54
+ mO: () => (/* reexport */ SizeEnum),
55
+ BZ: () => (/* reexport */ SwitcherThemeEnum),
56
+ p: () => (/* reexport */ SwitcherThemeType),
57
+ XR: () => (/* reexport */ TagThemeEnum),
58
+ gg: () => (/* reexport */ TagThemeType),
59
+ bY: () => (/* reexport */ ThemeEnum),
60
+ os: () => (/* reexport */ TriggerEnum),
61
+ WW: () => (/* reexport */ alignType),
62
+ h6: () => (/* binding */ arrayEqual),
63
+ Lx: () => (/* reexport */ bKMaskManager),
64
+ aR: () => (/* reexport */ bkPopIndexManager),
65
+ ue: () => (/* reexport */ bkZIndexManager),
66
+ kC: () => (/* reexport */ capitalize),
67
+ ao: () => (/* reexport */ checkOverflow),
68
+ Sh: () => (/* binding */ classes),
69
+ d9: () => (/* reexport */ clone),
70
+ Ds: () => (/* binding */ debounce),
71
+ ou: () => (/* reexport */ dialogTypeUnion),
72
+ zo: () => (/* reexport */ directionType),
73
+ cA: () => (/* reexport */ elementsEqual),
74
+ w$: () => (/* binding */ filterProperty),
75
+ b_: () => (/* reexport */ finiteOrDefault),
76
+ xE: () => (/* reexport */ formItemKey),
77
+ vh: () => (/* reexport */ formKey),
78
+ ks: () => (/* reexport */ getPopContainerId),
79
+ Hv: () => (/* reexport */ hasOverflowEllipsis),
80
+ kJ: () => (/* reexport */ isArray),
81
+ kK: () => (/* reexport */ helper_isElement),
82
+ xb: () => (/* reexport */ isEmpty),
83
+ SI: () => (/* binding */ isEmptyObj),
84
+ xV: () => (/* reexport */ isNumberFinite),
85
+ sS: () => (/* reexport */ isNullOrUndef),
86
+ Kn: () => (/* reexport */ isObject),
87
+ zW: () => (/* reexport */ lineStyleType),
88
+ oq: () => (/* reexport */ maybeShowTooltip),
89
+ TS: () => (/* reexport */ merge),
90
+ NG: () => (/* reexport */ mergeIf),
91
+ WC: () => (/* reexport */ mergerFn),
92
+ Zd: () => (/* reexport */ mergerIfFn),
93
+ ZT: () => (/* binding */ noop),
94
+ z3: () => (/* reexport */ observerResize),
95
+ S1: () => (/* reexport */ off),
96
+ on: () => (/* reexport */ on),
97
+ Tf: () => (/* reexport */ placementType),
98
+ MX: () => (/* reexport */ random),
99
+ OB: () => (/* reexport */ renderDirectiveType),
100
+ Ay: () => (/* binding */ renderEmptyVNode),
101
+ wB: () => (/* reexport */ renderType),
102
+ h5: () => (/* binding */ resolveClassName),
103
+ SM: () => (/* reexport */ scrollTop),
104
+ LF: () => (/* reexport */ scrollbarWidth),
105
+ b: () => (/* reexport */ stringEnum),
106
+ _7: () => (/* reexport */ triggerType),
107
+ cI: () => (/* reexport */ useForm),
108
+ A9: () => (/* reexport */ useFormItem),
109
+ Be: () => (/* reexport */ valueOrDefault),
110
+ nz: () => (/* binding */ withInstall),
111
+ B: () => (/* binding */ withInstallProps)
112
+ });
113
+
114
+ ;// CONCATENATED MODULE: ../../packages/shared/src/dom.ts
115
+ /*
116
+ * Tencent is pleased to support the open source community by making
117
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
118
+ *
119
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
120
+ *
121
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
122
+ *
123
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
124
+ *
125
+ * ---------------------------------------------------
126
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
127
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
128
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
129
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
130
+ *
131
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
132
+ * the Software.
133
+ *
134
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
135
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
136
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
137
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
138
+ * IN THE SOFTWARE.
139
+ */
140
+ var on = function () {
141
+ if (document.addEventListener) {
142
+ return function (element, event, handler) {
143
+ if (element && event && handler) {
144
+ element.addEventListener(event, handler, true);
145
+ }
146
+ };
147
+ }
148
+ return function (element, event, handler) {
149
+ if (element && event && handler) {
150
+ element.attachEvent("on".concat(event), handler);
151
+ }
152
+ };
153
+ }();
154
+ // 兼容浏览器,移除事件监听器
155
+ var off = function () {
156
+ if (document.removeEventListener) {
157
+ return function (element, event, handler) {
158
+ if (element && event) {
159
+ element.removeEventListener(event, handler, true);
160
+ }
161
+ };
162
+ }
163
+ return function (element, event, handler) {
164
+ if (element && event) {
165
+ element.detachEvent("on".concat(event), handler);
166
+ }
167
+ };
168
+ }();
169
+ // scrollTop animation
170
+ function scrollTop(el) {
171
+ var from = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 0;
172
+ var to = arguments.length > 2 ? arguments[2] : undefined;
173
+ var duration = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : 500;
174
+ var endCallback = arguments.length > 4 ? arguments[4] : undefined;
175
+ var difference = Math.abs(from - to);
176
+ var step = Math.ceil(difference / duration * 50);
177
+ function scroll(start, end, step) {
178
+ if (start === end) {
179
+ endCallback === null || endCallback === void 0 ? void 0 : endCallback();
180
+ return;
181
+ }
182
+ var d = start + step > end ? end : start + step;
183
+ if (start > end) {
184
+ d = start - step < end ? end : start - step;
185
+ }
186
+ if (el === window) {
187
+ window.scrollTo(d, d);
188
+ } else {
189
+ el.scrollTop = d;
190
+ }
191
+ window.requestAnimationFrame(function () {
192
+ return scroll(d, end, step);
193
+ });
194
+ }
195
+ scroll(from, to, step);
196
+ }
197
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/typeof.js
198
+ function _typeof(obj) {
199
+ "@babel/helpers - typeof";
200
+
201
+ return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) {
202
+ return typeof obj;
203
+ } : function (obj) {
204
+ return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj;
205
+ }, _typeof(obj);
206
+ }
207
+ ;// CONCATENATED MODULE: ../../packages/shared/src/helper.ts
208
+
209
+ /*
210
+ * Tencent is pleased to support the open source community by making
211
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
212
+ *
213
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
214
+ *
215
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
216
+ *
217
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
218
+ *
219
+ * ---------------------------------------------------
220
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
221
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
222
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
223
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
224
+ *
225
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
226
+ * the Software.
227
+ *
228
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
229
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
230
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
231
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
232
+ * IN THE SOFTWARE.
233
+ */
234
+ /* eslint-disable no-underscore-dangle */
235
+ /**
236
+ * Returns true if `value` is neither null nor undefined, else returns false.
237
+ * @param {*} value - The value to test.
238
+ * @returns {boolean}
239
+ * @since 2.7.0
240
+ */
241
+ function isNullOrUndef(value) {
242
+ return value === null || typeof value === 'undefined';
243
+ }
244
+ function isEmpty(value) {
245
+ var IncludeNullUndefined = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
246
+ return value === '' || (IncludeNullUndefined ? isNullOrUndef(value) : false);
247
+ }
248
+ /**
249
+ * Returns true if `value` is an array (including typed arrays), else returns false.
250
+ * @param {*} value - The value to test.
251
+ * @returns {boolean}
252
+ * @function
253
+ */
254
+ function isArray(value) {
255
+ if (Array.isArray(value)) {
256
+ return true;
257
+ }
258
+ var type = Object.prototype.toString.call(value);
259
+ if (type.substr(0, 7) === '[object' && type.substr(-6) === 'Array]') {
260
+ return true;
261
+ }
262
+ return false;
263
+ }
264
+ /**
265
+ * Returns true if `value` is an object (excluding null), else returns false.
266
+ * @param {*} value - The value to test.
267
+ * @returns {boolean}
268
+ * @since 2.7.0
269
+ */
270
+ function isObject(value) {
271
+ return value !== null && /^\[object (Object|Module)\]/.test(Object.prototype.toString.call(value));
272
+ }
273
+ /**
274
+ * Returns true if `value` is a finite number, else returns false
275
+ * @param {*} value - The value to test.
276
+ * @returns {boolean}
277
+ */
278
+ var isNumberFinite = function isNumberFinite(value) {
279
+ return (typeof value === 'number' || value instanceof Number) && isFinite(+value);
280
+ };
281
+
282
+ /**
283
+ * Returns `value` if finite, else returns `defaultValue`.
284
+ * @param {*} value - The value to return if defined.
285
+ * @param {*} defaultValue - The value to return if `value` is not finite.
286
+ * @returns {*}
287
+ */
288
+ function finiteOrDefault(value, defaultValue) {
289
+ return isNumberFinite(value) ? value : defaultValue;
290
+ }
291
+ /**
292
+ * Returns `value` if defined, else returns `defaultValue`.
293
+ * @param {*} value - The value to return if defined.
294
+ * @param {*} defaultValue - The value to return if `value` is undefined.
295
+ * @returns {*}
296
+ */
297
+ function valueOrDefault(value, defaultValue) {
298
+ return typeof value === 'undefined' ? defaultValue : value;
299
+ }
300
+ /**
301
+ * Returns true if the `a0` and `a1` arrays have the same content, else returns false.
302
+ * @param {Array} a0 - The array to compare
303
+ * @param {Array} a1 - The array to compare
304
+ * @returns {boolean}
305
+ * @private
306
+ */
307
+ function elementsEqual(a0, a1) {
308
+ var i;
309
+ var ilen;
310
+ var v0;
311
+ var v1;
312
+ if (!a0 || !a1 || a0.length !== a1.length) {
313
+ return false;
314
+ }
315
+ for (i = 0, ilen = a0.length; i < ilen; ++i) {
316
+ v0 = a0[i];
317
+ v1 = a1[i];
318
+ if (v0.datasetIndex !== v1.datasetIndex || v0.index !== v1.index) {
319
+ return false;
320
+ }
321
+ }
322
+ return true;
323
+ }
324
+ /**
325
+ * Returns a deep copy of `source` without keeping references on objects and arrays.
326
+ * @param {*} source - The value to clone.
327
+ * @returns {*}
328
+ */
329
+ function clone(source) {
330
+ if (isArray(source)) {
331
+ return source.map(clone);
332
+ }
333
+ if (isObject(source)) {
334
+ var target = Object.create(null);
335
+ var keys = Object.keys(source);
336
+ var klen = keys.length;
337
+ var k = 0;
338
+ for (; k < klen; ++k) {
339
+ target[keys[k]] = clone(source[keys[k]]);
340
+ }
341
+ return target;
342
+ }
343
+ return source;
344
+ }
345
+ function isValidKey(key) {
346
+ return ['__proto__', 'prototype', 'constructor'].indexOf(key) === -1;
347
+ }
348
+ /**
349
+ * The default merger when Chart.helpers.merge is called without merger option.
350
+ * Note(SB): also used by mergeConfig and mergeScaleConfig as fallback.
351
+ * @private
352
+ */
353
+ function mergerFn(key, target, source, options) {
354
+ if (!isValidKey(key)) {
355
+ return;
356
+ }
357
+ var tval = target[key];
358
+ var sval = source[key];
359
+ if (isObject(tval) && isObject(sval)) {
360
+ // eslint-disable-next-line no-use-before-define
361
+ merge(tval, sval, options);
362
+ } else {
363
+ // eslint-disable-next-line no-param-reassign
364
+ target[key] = clone(sval);
365
+ }
366
+ }
367
+ /**
368
+ * Recursively deep copies `source` properties into `target` with the given `options`.
369
+ * IMPORTANT: `target` is not cloned and will be updated with `source` properties.
370
+ * @param {object} target - The target object in which all sources are merged into.
371
+ * @param {object|object[]} source - Object(s) to merge into `target`.
372
+ * @param {object} [options] - Merging options:
373
+ * @param {function} [options.merger] - The merge method (key, target, source, options)
374
+ * @returns {object} The `target` object.
375
+ */
376
+ function merge(target, source, options) {
377
+ var sources = isArray(source) ? source : [source];
378
+ var ilen = sources.length;
379
+ if (!isObject(target)) {
380
+ return target;
381
+ }
382
+ // eslint-disable-next-line no-param-reassign
383
+ options = options || {};
384
+ var merger = options.merger || mergerFn;
385
+ for (var i = 0; i < ilen; ++i) {
386
+ // eslint-disable-next-line no-param-reassign
387
+ source = sources[i];
388
+ if (!isObject(source)) {
389
+ continue;
390
+ }
391
+ var keys = Object.keys(source);
392
+ for (var k = 0, klen = keys.length; k < klen; ++k) {
393
+ merger(keys[k], target, source, options);
394
+ }
395
+ }
396
+ return target;
397
+ }
398
+ /**
399
+ * Recursively deep copies `source` properties into `target` *only* if not defined in target.
400
+ * IMPORTANT: `target` is not cloned and will be updated with `source` properties.
401
+ * @param {object} target - The target object in which all sources are merged into.
402
+ * @param {object|object[]} source - Object(s) to merge into `target`.
403
+ * @returns {object} The `target` object.
404
+ */
405
+ function mergeIf(target, source) {
406
+ // eslint-disable-next-line no-use-before-define
407
+ return merge(target, source, {
408
+ merger: mergerIfFn
409
+ });
410
+ }
411
+ /**
412
+ * Merges source[key] in target[key] only if target[key] is undefined.
413
+ * @private
414
+ */
415
+ function mergerIfFn(key, target, source) {
416
+ if (!isValidKey(key)) {
417
+ return;
418
+ }
419
+ var tval = target[key];
420
+ var sval = source[key];
421
+ if (isObject(tval) && isObject(sval)) {
422
+ mergeIf(tval, sval);
423
+ } else if (!Object.prototype.hasOwnProperty.call(target, key)) {
424
+ // eslint-disable-next-line no-param-reassign
425
+ target[key] = clone(sval);
426
+ }
427
+ }
428
+ /**
429
+ * 检查当前元素是否为Html元素
430
+ * @param obj
431
+ * @returns
432
+ */
433
+ function helper_isElement(obj) {
434
+ try {
435
+ return obj instanceof HTMLElement;
436
+ } catch (e) {
437
+ return _typeof(obj) === 'object' && obj.nodeType === 1 && _typeof(obj.style) === 'object' && _typeof(obj.ownerDocument) === 'object';
438
+ }
439
+ }
440
+ /**
441
+ * Whether the text content is clipped due to CSS overflow, as in showing `...`.
442
+ */
443
+ function hasOverflowEllipsis(element) {
444
+ return element.offsetWidth < element.scrollWidth || element.offsetHeight < element.scrollHeight;
445
+ }
446
+ /**
447
+ * Sets the `title` attribute in the event's element target, when the text
448
+ * content is clipped due to CSS overflow, as in showing `...`.
449
+ */
450
+ function maybeShowTooltip(target, title) {
451
+ if (hasOverflowEllipsis(target)) {
452
+ target.setAttribute('title', title);
453
+ } else {
454
+ target.removeAttribute('title');
455
+ }
456
+ }
457
+ ;// CONCATENATED MODULE: external "vue"
458
+ var x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
459
+ var y = x => () => x
460
+ const external_vue_namespaceObject = x({ ["inject"]: () => __WEBPACK_EXTERNAL_MODULE_vue__.inject });
461
+ ;// CONCATENATED MODULE: ../../packages/shared/src/token.ts
462
+ /*
463
+ * Tencent is pleased to support the open source community by making
464
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
465
+ *
466
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
467
+ *
468
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
469
+ *
470
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
471
+ *
472
+ * ---------------------------------------------------
473
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
474
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
475
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
476
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
477
+ *
478
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
479
+ * the Software.
480
+ *
481
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
482
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
483
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
484
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
485
+ * IN THE SOFTWARE.
486
+ */
487
+ var formKey = Symbol('form');
488
+ var formItemKey = Symbol('formItem');
489
+ ;// CONCATENATED MODULE: ../../packages/shared/src/hooks/use-form.ts
490
+ /*
491
+ * Tencent is pleased to support the open source community by making
492
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
493
+ *
494
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
495
+ *
496
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
497
+ *
498
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
499
+ *
500
+ * ---------------------------------------------------
501
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
502
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
503
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
504
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
505
+ *
506
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
507
+ * the Software.
508
+ *
509
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
510
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
511
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
512
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
513
+ * IN THE SOFTWARE.
514
+ */
515
+
516
+
517
+ var useForm = function useForm() {
518
+ return (0,external_vue_namespaceObject.inject)(formKey);
519
+ };
520
+ ;// CONCATENATED MODULE: ../../packages/shared/src/hooks/use-form-item.ts
521
+ /*
522
+ * Tencent is pleased to support the open source community by making
523
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
524
+ *
525
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
526
+ *
527
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
528
+ *
529
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
530
+ *
531
+ * ---------------------------------------------------
532
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
533
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
534
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
535
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
536
+ *
537
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
538
+ * the Software.
539
+ *
540
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
541
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
542
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
543
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
544
+ * IN THE SOFTWARE.
545
+ */
546
+
547
+
548
+ var useFormItem = function useFormItem() {
549
+ return (0,external_vue_namespaceObject.inject)(formItemKey, undefined);
550
+ };
551
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/classCallCheck.js
552
+ function _classCallCheck(instance, Constructor) {
553
+ if (!(instance instanceof Constructor)) {
554
+ throw new TypeError("Cannot call a class as a function");
555
+ }
556
+ }
557
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toPrimitive.js
558
+
559
+ function _toPrimitive(input, hint) {
560
+ if (_typeof(input) !== "object" || input === null) return input;
561
+ var prim = input[Symbol.toPrimitive];
562
+ if (prim !== undefined) {
563
+ var res = prim.call(input, hint || "default");
564
+ if (_typeof(res) !== "object") return res;
565
+ throw new TypeError("@@toPrimitive must return a primitive value.");
566
+ }
567
+ return (hint === "string" ? String : Number)(input);
568
+ }
569
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toPropertyKey.js
570
+
571
+
572
+ function _toPropertyKey(arg) {
573
+ var key = _toPrimitive(arg, "string");
574
+ return _typeof(key) === "symbol" ? key : String(key);
575
+ }
576
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/createClass.js
577
+
578
+ function _defineProperties(target, props) {
579
+ for (var i = 0; i < props.length; i++) {
580
+ var descriptor = props[i];
581
+ descriptor.enumerable = descriptor.enumerable || false;
582
+ descriptor.configurable = true;
583
+ if ("value" in descriptor) descriptor.writable = true;
584
+ Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor);
585
+ }
586
+ }
587
+ function _createClass(Constructor, protoProps, staticProps) {
588
+ if (protoProps) _defineProperties(Constructor.prototype, protoProps);
589
+ if (staticProps) _defineProperties(Constructor, staticProps);
590
+ Object.defineProperty(Constructor, "prototype", {
591
+ writable: false
592
+ });
593
+ return Constructor;
594
+ }
595
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/defineProperty.js
596
+
597
+ function _defineProperty(obj, key, value) {
598
+ key = _toPropertyKey(key);
599
+ if (key in obj) {
600
+ Object.defineProperty(obj, key, {
601
+ value: value,
602
+ enumerable: true,
603
+ configurable: true,
604
+ writable: true
605
+ });
606
+ } else {
607
+ obj[key] = value;
608
+ }
609
+ return obj;
610
+ }
611
+ ;// CONCATENATED MODULE: external "lodash/throttle"
612
+ var throttle_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
613
+ var throttle_y = x => () => x
614
+ const throttle_namespaceObject = throttle_x({ ["default"]: () => __WEBPACK_EXTERNAL_MODULE_lodash_throttle_a7b7506a__["default"] });
615
+ ;// CONCATENATED MODULE: ../../packages/shared/src/utils.ts
616
+ /*
617
+ * Tencent is pleased to support the open source community by making
618
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
619
+ *
620
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
621
+ *
622
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
623
+ *
624
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
625
+ *
626
+ * ---------------------------------------------------
627
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
628
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
629
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
630
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
631
+ *
632
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
633
+ * the Software.
634
+ *
635
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
636
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
637
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
638
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
639
+ * IN THE SOFTWARE.
640
+ */
641
+
642
+ var lowerStr = 'abcdefghijklmnopqrstuvwxyz0123456789';
643
+ /**
644
+ * 生成n位长度的字符串
645
+ * @param {Number} n
646
+ * @param str,默认26位字母及数字
647
+ */
648
+ var random = function random(n) {
649
+ var str = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : lowerStr;
650
+ var result = '';
651
+ for (var i = 0; i < n; i++) {
652
+ result += str[parseInt((Math.random() * str.length).toString(), 10)];
653
+ }
654
+ return result;
655
+ };
656
+ /**
657
+ * 监听目标元素的Resize事件
658
+ * @param root 目标元素
659
+ * @param callbackFn 执行函数
660
+ * @param delay 延迟执行时间,默认 60
661
+ * @param immediate 是否立即执行回调函数
662
+ * @returns "{ start: () => void, stop: () => void }"
663
+ */
664
+ var observerResize = function observerResize(root, callbackFn) {
665
+ var delay = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 60;
666
+ var immediate = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
667
+ var callFn = (0,throttle_namespaceObject["default"])(function () {
668
+ if (typeof callbackFn === 'function') {
669
+ callbackFn();
670
+ }
671
+ }, delay);
672
+ var resizeObserver = new ResizeObserver(function () {
673
+ callFn();
674
+ });
675
+ if (immediate) {
676
+ if (typeof callbackFn === 'function') {
677
+ callbackFn();
678
+ }
679
+ }
680
+ return {
681
+ start: function start() {
682
+ resizeObserver.observe(root);
683
+ },
684
+ stop: function stop() {
685
+ resizeObserver.disconnect();
686
+ resizeObserver.unobserve(root);
687
+ }
688
+ };
689
+ };
690
+ var capitalize = function capitalize(str) {
691
+ return str[0].toUpperCase() + str.slice(1);
692
+ };
693
+ /**
694
+ * 判断元素是否溢出容器
695
+ * @param {*} el
696
+ * @returns
697
+ */
698
+ function checkOverflow(el) {
699
+ if (!el) return false;
700
+ var createDom = function createDom(el, css) {
701
+ var dom = document.createElement('div');
702
+ var width = parseFloat(css.width) ? "".concat(Math.ceil(parseFloat(css.width)), "px") : css.width;
703
+ dom.style.cssText = "\n width: ".concat(width, ";\n line-height: ").concat(css['line-height'], ";\n font-size: ").concat(css['font-size'], ";\n word-break: ").concat(css['word-break'], ";\n padding: ").concat(css.padding, ";\n ");
704
+ dom.textContent = el.textContent;
705
+ return dom;
706
+ };
707
+ var isOverflow = false;
708
+ try {
709
+ var css = window.getComputedStyle(el, null);
710
+ var lineClamp = css.webkitLineClamp;
711
+ if (lineClamp !== 'none') {
712
+ var targetHeight = parseFloat(css.height);
713
+ var dom = createDom(el, css);
714
+ document.body.appendChild(dom);
715
+ var domHeight = window.getComputedStyle(dom, null).height;
716
+ document.body.removeChild(dom);
717
+ isOverflow = targetHeight < parseFloat(domHeight);
718
+ } else {
719
+ isOverflow = el.clientWidth < el.scrollWidth || el.clientHeight < el.scrollHeight;
720
+ }
721
+ } catch (e) {
722
+ console.warn('There is an error when check element overflow state: ', e);
723
+ }
724
+ return isOverflow;
725
+ }
726
+ ;// CONCATENATED MODULE: ../../packages/shared/src/z-index-manager.ts
727
+
728
+
729
+
730
+ var _BKLAYERD_INDEX_EFAUL;
731
+ /**
732
+ * Tencent is pleased to support the open source community by making
733
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
734
+ *
735
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
736
+ *
737
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
738
+ *
739
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
740
+ *
741
+ * ---------------------------------------------------
742
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
743
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
744
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
745
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
746
+ *
747
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
748
+ * the Software.
749
+ *
750
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
751
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
752
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
753
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
754
+ * IN THE SOFTWARE.
755
+ */
756
+ /**
757
+ * 页面框架层级
758
+ */
759
+ var BKLAYERTYPE;
760
+ (function (BKLAYERTYPE) {
761
+ /** 网站内容的背景、拓扑的画布等 */
762
+ BKLAYERTYPE["BOTTOM"] = "bottom";
763
+ /** 页面呈现的各类内容 */
764
+ BKLAYERTYPE["CONTENT"] = "content";
765
+ /** 顶部导航、侧边导航以及用户信息等 */
766
+ BKLAYERTYPE["NAVI"] = "navi";
767
+ /** 页面需全屏操作的部分功能或编辑器的全屏模式 */
768
+ BKLAYERTYPE["FULLSCREEN"] = "fullScreen";
769
+ /** 各类功能插件 */
770
+ BKLAYERTYPE["PLUGINS"] = "plugins";
771
+ /** 各类弹窗或抽屉(非模态弹窗不考虑) */
772
+ BKLAYERTYPE["MODAL"] = "modal";
773
+ /** 各类消息提示 */
774
+ BKLAYERTYPE["MESSAGE"] = "message";
775
+ /** 各类popper提示 */
776
+ BKLAYERTYPE["POPPER"] = "popper";
777
+ })(BKLAYERTYPE || (BKLAYERTYPE = {}));
778
+ /** 定义不同分层默认值 */
779
+ var BKLAYERD_INDEX_EFAULT_VALUE = (_BKLAYERD_INDEX_EFAUL = {}, _defineProperty(_BKLAYERD_INDEX_EFAUL, BKLAYERTYPE.BOTTOM, 0), _defineProperty(_BKLAYERD_INDEX_EFAUL, BKLAYERTYPE.CONTENT, 1), _defineProperty(_BKLAYERD_INDEX_EFAUL, BKLAYERTYPE.NAVI, 100), _defineProperty(_BKLAYERD_INDEX_EFAUL, BKLAYERTYPE.FULLSCREEN, 1000), _defineProperty(_BKLAYERD_INDEX_EFAUL, BKLAYERTYPE.MODAL, 3000), _defineProperty(_BKLAYERD_INDEX_EFAUL, BKLAYERTYPE.PLUGINS, 8000), _defineProperty(_BKLAYERD_INDEX_EFAUL, BKLAYERTYPE.MESSAGE, 10000), _defineProperty(_BKLAYERD_INDEX_EFAUL, BKLAYERTYPE.POPPER, 99999), _BKLAYERD_INDEX_EFAUL);
780
+ var BKZIndexManager = /*#__PURE__*/function () {
781
+ function BKZIndexManager() {
782
+ _classCallCheck(this, BKZIndexManager);
783
+ _defineProperty(this, "storageLayerIndexValue", {});
784
+ this.copyDefaultValue();
785
+ }
786
+ /**
787
+ *
788
+ * @param type
789
+ * @returns
790
+ */
791
+ _createClass(BKZIndexManager, [{
792
+ key: "getNextIndex",
793
+ value: function getNextIndex(type) {
794
+ if (Object.prototype.hasOwnProperty.call(this.storageLayerIndexValue, type)) {
795
+ this.storageLayerIndexValue[type] = this.storageLayerIndexValue[type] + 1;
796
+ return this.storageLayerIndexValue[type];
797
+ }
798
+ this.storageLayerIndexValue[BKLAYERTYPE.MODAL] = this.storageLayerIndexValue[BKLAYERTYPE.MODAL] + 1;
799
+ return this.storageLayerIndexValue[BKLAYERTYPE.MODAL];
800
+ }
801
+ /** 获取弹窗类型最新zIndex的值 */
802
+ }, {
803
+ key: "getModalNextIndex",
804
+ value: function getModalNextIndex() {
805
+ return this.getNextIndex(BKLAYERTYPE.MODAL);
806
+ }
807
+ /** 获取Message类型最新zIndex的值 */
808
+ }, {
809
+ key: "getMessageNextIndex",
810
+ value: function getMessageNextIndex() {
811
+ return this.getNextIndex(BKLAYERTYPE.MESSAGE);
812
+ }
813
+ /** 获取全屏类型最新zIndex的值 */
814
+ }, {
815
+ key: "getFullScreenNextIndex",
816
+ value: function getFullScreenNextIndex() {
817
+ return this.getNextIndex(BKLAYERTYPE.FULLSCREEN);
818
+ }
819
+ /** 获取导航类型最新zIndex的值 */
820
+ }, {
821
+ key: "getNaviNextIndex",
822
+ value: function getNaviNextIndex() {
823
+ return this.getNextIndex(BKLAYERTYPE.NAVI);
824
+ }
825
+ /** 获取导航类型最新zIndex的值 */
826
+ }, {
827
+ key: "getPopperIndex",
828
+ value: function getPopperIndex() {
829
+ return BKLAYERD_INDEX_EFAULT_VALUE.popper;
830
+ }
831
+ /**
832
+ * 更新自定义默认zIndex配置
833
+ * @param config 配置项
834
+ */
835
+ }, {
836
+ key: "setDefaultZIndex",
837
+ value: function setDefaultZIndex(config) {
838
+ var _this = this;
839
+ Object.keys(config || {}).forEach(function (key) {
840
+ if (Object.prototype.hasOwnProperty.call(_this.storageLayerIndexValue.__proto__, key)) {
841
+ Object.assign(_this.storageLayerIndexValue.__proto__, _defineProperty({}, key, config[key]));
842
+ }
843
+ });
844
+ this.copyDefaultValue();
845
+ }
846
+ /**
847
+ * 重置zIndex
848
+ * @param config 配置项
849
+ */
850
+ }, {
851
+ key: "resetZIndex",
852
+ value: function resetZIndex(config) {
853
+ var _this2 = this;
854
+ Object.keys(config || {}).forEach(function (key) {
855
+ if (Object.prototype.hasOwnProperty.call(_this2.storageLayerIndexValue, key)) {
856
+ Object.assign(_this2.storageLayerIndexValue, _defineProperty({}, key, config[key]));
857
+ }
858
+ });
859
+ }
860
+ /**
861
+ * 根据默认设置创建副本
862
+ */
863
+ }, {
864
+ key: "copyDefaultValue",
865
+ value: function copyDefaultValue() {
866
+ var properties = Object.keys(BKLAYERD_INDEX_EFAULT_VALUE).reduce(function (props, key) {
867
+ return Object.assign(props, _defineProperty({}, key, {
868
+ value: BKLAYERD_INDEX_EFAULT_VALUE[key],
869
+ writable: true,
870
+ configurable: true
871
+ }));
872
+ }, {});
873
+ this.storageLayerIndexValue = Object.create(BKLAYERD_INDEX_EFAULT_VALUE, properties);
874
+ }
875
+ }]);
876
+ return BKZIndexManager;
877
+ }();
878
+ var bkZIndexManager = new BKZIndexManager();
879
+ ;// CONCATENATED MODULE: ../../packages/shared/src/mask-manager.ts
880
+
881
+
882
+
883
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
884
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { _defineProperty(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
885
+ /*
886
+ * Tencent is pleased to support the open source community by making
887
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
888
+ *
889
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
890
+ *
891
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
892
+ *
893
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
894
+ *
895
+ * ---------------------------------------------------
896
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
897
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
898
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
899
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
900
+ *
901
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
902
+ * the Software.
903
+ *
904
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
905
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
906
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
907
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
908
+ * IN THE SOFTWARE.
909
+ */
910
+
911
+
912
+ // eslint-disable-next-line @typescript-eslint/naming-convention
913
+ var DEFAULT_MASK_UUID = function DEFAULT_MASK_UUID() {};
914
+ DEFAULT_MASK_UUID.prototype.def_val = "__bk_mask_".concat(random(16));
915
+ var MaskEventMap = new WeakMap();
916
+ var getMaskEvent = function getMaskEvent(mask) {
917
+ if (MaskEventMap.has(mask)) {
918
+ return MaskEventMap.get(mask);
919
+ }
920
+ return [];
921
+ };
922
+ var setMaskEvent = function setMaskEvent(mask, event, args, content, instanceId) {
923
+ var maskEvent = getMaskEvent(mask);
924
+ if (maskEvent.some(function (evet) {
925
+ return evet.instanceId === instanceId;
926
+ })) {
927
+ return;
928
+ }
929
+ maskEvent.push({
930
+ event: event,
931
+ args: args,
932
+ content: content,
933
+ instanceId: instanceId
934
+ });
935
+ MaskEventMap.set(mask, maskEvent);
936
+ };
937
+ var setMaskEventIns = function setMaskEventIns(mask, maskEvent) {
938
+ MaskEventMap.set(mask, maskEvent);
939
+ };
940
+ var MaskQueueMaker = /*#__PURE__*/function () {
941
+ function MaskQueueMaker() {
942
+ _classCallCheck(this, MaskQueueMaker);
943
+ _defineProperty(this, "timer", null);
944
+ _defineProperty(this, "store", []);
945
+ _defineProperty(this, "maskMap", new WeakMap());
946
+ }
947
+ _createClass(MaskQueueMaker, [{
948
+ key: "appendMaker",
949
+ value: function appendMaker(fn) {
950
+ this.store.push(fn);
951
+ this.executeMaker();
952
+ }
953
+ }, {
954
+ key: "pushMaskStyle",
955
+ value: function pushMaskStyle(parentNode, style) {
956
+ var value = this.getMaskMap(parentNode);
957
+ this.setMaskMap(parentNode, _objectSpread({
958
+ styles: [style]
959
+ }, value || {}));
960
+ }
961
+ }, {
962
+ key: "getMaskStyles",
963
+ value: function getMaskStyles(parentNode) {
964
+ var _this$getMaskMap;
965
+ return ((_this$getMaskMap = this.getMaskMap(parentNode)) === null || _this$getMaskMap === void 0 ? void 0 : _this$getMaskMap.styles) || [];
966
+ }
967
+ }, {
968
+ key: "setMaskId",
969
+ value: function setMaskId(parentNode, id) {
970
+ var value = this.getMaskMap(parentNode);
971
+ if (!value) {
972
+ this.setMaskMap(parentNode, _objectSpread({
973
+ id: id
974
+ }, value || {}));
975
+ } else {
976
+ Object.assign(value, {
977
+ id: id
978
+ });
979
+ this.setMaskMap(parentNode, value);
980
+ }
981
+ }
982
+ }, {
983
+ key: "getMaskId",
984
+ value: function getMaskId(parentNode) {
985
+ var _this$getMaskMap2;
986
+ return (_this$getMaskMap2 = this.getMaskMap(parentNode)) === null || _this$getMaskMap2 === void 0 ? void 0 : _this$getMaskMap2.id;
987
+ }
988
+ }, {
989
+ key: "setMaskMap",
990
+ value: function setMaskMap(key, value) {
991
+ this.maskMap.set(key, value);
992
+ }
993
+ }, {
994
+ key: "getMaskMap",
995
+ value: function getMaskMap(key) {
996
+ return this.maskMap.get(key);
997
+ }
998
+ }, {
999
+ key: "executeMaker",
1000
+ value: function executeMaker() {
1001
+ var _this = this;
1002
+ this.timer && cancelAnimationFrame(this.timer);
1003
+ this.timer = requestAnimationFrame(function () {
1004
+ var fn = _this.store.pop();
1005
+ if (typeof fn === 'function') {
1006
+ Reflect.apply(fn, _this, []);
1007
+ _this.executeMaker();
1008
+ }
1009
+ });
1010
+ }
1011
+ }]);
1012
+ return MaskQueueMaker;
1013
+ }();
1014
+ var bkMaskMaker = new MaskQueueMaker();
1015
+ var BkMaskManager = /*#__PURE__*/function () {
1016
+ /**
1017
+ * 遮罩管理器
1018
+ *
1019
+ * @param multiInstance 是否允许多实例
1020
+ * @param maskAttrTag 遮罩DOM唯一标志,支持自定义和 auto
1021
+ */
1022
+ function BkMaskManager(config) {
1023
+ var _this2 = this;
1024
+ _classCallCheck(this, BkMaskManager);
1025
+ /** 遮罩容器 */
1026
+ /** 遮罩备份容器,用于多个组件实例显示,遮罩只显示最后一个 **/
1027
+ /** 是否允许多个遮罩实例 */
1028
+ _defineProperty(this, "multiInstance", false);
1029
+ /** 遮罩控制器唯一标识 */
1030
+ _defineProperty(this, "uniqueMaskAttrTag", '');
1031
+ /** 设置弹出层父级组件,默认是body */
1032
+ _defineProperty(this, "parentNode", document.body);
1033
+ /** 遮罩当前显示组件实例 **/
1034
+ _defineProperty(this, "activeInstance", undefined);
1035
+ /** 记录已在使用的z-index */
1036
+ _defineProperty(this, "zIndexStore", new Map());
1037
+ /** 记录最后一个UUID */
1038
+ _defineProperty(this, "lastUUID", null);
1039
+ /** 遮罩样式 **/
1040
+ _defineProperty(this, "maskStyle", {
1041
+ position: 'fixed',
1042
+ left: 0,
1043
+ top: 0,
1044
+ bottom: 0,
1045
+ right: 0,
1046
+ display: 'none',
1047
+ 'background-color': 'rgba(0,0,0,.6)'
1048
+ });
1049
+ // 用于判定是否已经初始化过当前实例
1050
+ _defineProperty(this, "isInit", false);
1051
+ _defineProperty(this, "maskAttrTag", 'auto');
1052
+ var _ref = config || {},
1053
+ _ref$multiInstance = _ref.multiInstance,
1054
+ multiInstance = _ref$multiInstance === void 0 ? false : _ref$multiInstance,
1055
+ _ref$maskAttrTag = _ref.maskAttrTag,
1056
+ maskAttrTag = _ref$maskAttrTag === void 0 ? 'auto' : _ref$maskAttrTag,
1057
+ _ref$parentNode = _ref.parentNode,
1058
+ parentNode = _ref$parentNode === void 0 ? document.body : _ref$parentNode,
1059
+ _ref$maskStyle = _ref.maskStyle,
1060
+ maskStyle = _ref$maskStyle === void 0 ? {} : _ref$maskStyle;
1061
+ this.parentNode = parentNode || document;
1062
+ this.maskAttrTag = maskAttrTag;
1063
+ this.activeInstance = undefined;
1064
+ this.multiInstance = multiInstance;
1065
+ this.uniqueMaskAttrTag = this.getMaskAttrTag(maskAttrTag);
1066
+ // 避免多个实例多处初始化,此处会做队列处理
1067
+ // 合并重复的处理请求
1068
+ // 如果当前实例初始化时,仍未执行完队列,则需要进行请求合并
1069
+ bkMaskMaker.appendMaker(function () {
1070
+ _this2.initInstance(maskStyle);
1071
+ });
1072
+ }
1073
+ _createClass(BkMaskManager, [{
1074
+ key: "setOption",
1075
+ value: function setOption(option) {
1076
+ var _ref2 = option || {},
1077
+ _ref2$parentNode = _ref2.parentNode,
1078
+ parentNode = _ref2$parentNode === void 0 ? document.body : _ref2$parentNode,
1079
+ _ref2$maskStyle = _ref2.maskStyle,
1080
+ maskStyle = _ref2$maskStyle === void 0 ? {} : _ref2$maskStyle,
1081
+ _ref2$maskAttrTag = _ref2.maskAttrTag,
1082
+ maskAttrTag = _ref2$maskAttrTag === void 0 ? this.maskAttrTag : _ref2$maskAttrTag;
1083
+ this.parentNode = parentNode || document;
1084
+ this.setMaskStyle(Object.assign({}, this.maskStyle, maskStyle));
1085
+ this.uniqueMaskAttrTag = this.getMaskAttrTag(maskAttrTag);
1086
+ }
1087
+ }, {
1088
+ key: "destroyEvent",
1089
+ value: function destroyEvent(id) {
1090
+ if (this.mask) {
1091
+ var events = getMaskEvent(this.mask) || [];
1092
+ var index = events.findIndex(function (evt) {
1093
+ return evt.instanceId === id;
1094
+ });
1095
+ if (index >= 0) {
1096
+ events.splice(index, 1);
1097
+ setMaskEventIns(this.mask, events);
1098
+ }
1099
+ }
1100
+ }
1101
+ /**
1102
+ * 显示遮罩
1103
+ * @param content 遮罩内容
1104
+ * @param zIndex z-index
1105
+ * @param showMask 是否显示遮罩
1106
+ * @param appendStyle 追加样式
1107
+ * @param transfer 是否显示将内容加入遮罩下
1108
+ */
1109
+ }, {
1110
+ key: "show",
1111
+ value: function show(content, zIndex) {
1112
+ var showMask = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : true;
1113
+ var appendStyle = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : {};
1114
+ var uuid = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : null;
1115
+ var transfer = arguments.length > 5 && arguments[5] !== undefined ? arguments[5] : false;
1116
+ var onMaskClick = arguments.length > 6 ? arguments[6] : undefined;
1117
+ var instanceId = arguments.length > 7 ? arguments[7] : undefined;
1118
+ var uid = uuid !== null && uuid !== void 0 ? uuid : random(16);
1119
+ // @ts-ignore
1120
+ var localZIndex = /-?\d+/.test("".concat(zIndex)) ? zIndex : bkZIndexManager.getModalNextIndex();
1121
+ var style = Object.assign({}, this.maskStyle, appendStyle || {});
1122
+ /**
1123
+ * 如果不显示遮罩,此处遮罩继承父级
1124
+ * 同时,如果父级弹出层有遮罩,此处不能覆盖
1125
+ */
1126
+ if (!showMask) {
1127
+ if (this.lastUUID) {
1128
+ var preStore = this.zIndexStore.get(this.lastUUID);
1129
+ if (preStore) {
1130
+ style = preStore === null || preStore === void 0 ? void 0 : preStore.style;
1131
+ }
1132
+ }
1133
+ }
1134
+ /** 缓存当前z-index */
1135
+ this.storeMaskInsCfg({
1136
+ zIndex: localZIndex,
1137
+ style: _objectSpread({}, style),
1138
+ uuid: uid,
1139
+ preUID: this.lastUUID
1140
+ });
1141
+ Object.assign(style, {
1142
+ display: 'block',
1143
+ 'z-index': "".concat(localZIndex),
1144
+ 'pointer-events': 'all'
1145
+ });
1146
+ this.initInstance(style);
1147
+ if (onMaskClick) {
1148
+ this.catchClickEvent(content, onMaskClick, instanceId);
1149
+ }
1150
+ this.setMaskStyle(style);
1151
+ bkMaskMaker.pushMaskStyle(this.parentNode, _objectSpread({}, style));
1152
+ this.backupMask.style.setProperty('z-index', "".concat(localZIndex - 1));
1153
+ if (!showMask) {
1154
+ this.mask.style.setProperty('pointer-events', 'none');
1155
+ content === null || content === void 0 ? void 0 : content.style.setProperty('pointer-events', 'all');
1156
+ }
1157
+ if (content) {
1158
+ if (transfer) content.style.setProperty('z-index', "".concat(localZIndex + 1)); // 表明内容不在遮罩下,内容区z-index + 1
1159
+ this.activeInstance = content;
1160
+ this.appendContentToMask(content); // 表明内容在body下,即在遮罩下
1161
+ }
1162
+ }
1163
+ }, {
1164
+ key: "hide",
1165
+ value: function hide() {
1166
+ var transfer = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
1167
+ var content = arguments.length > 1 ? arguments[1] : undefined;
1168
+ var uuid = arguments.length > 2 ? arguments[2] : undefined;
1169
+ var uid = uuid !== null && uuid !== void 0 ? uuid : this.lastUUID;
1170
+ if (!transfer) {
1171
+ var _this$activeInstance;
1172
+ content === null || content === void 0 ? void 0 : content.remove();
1173
+ (_this$activeInstance = this.activeInstance) === null || _this$activeInstance === void 0 ? void 0 : _this$activeInstance.remove();
1174
+ }
1175
+ this.removeClickEvent();
1176
+ this.activeInstance = undefined;
1177
+ this.popIndexStore(uid);
1178
+ var maskList = bkMaskMaker.getMaskStyles(this.parentNode);
1179
+ maskList === null || maskList === void 0 ? void 0 : maskList.pop();
1180
+ if (!(maskList !== null && maskList !== void 0 && maskList.length)) {
1181
+ this.mask.style.setProperty('display', 'none');
1182
+ } else {
1183
+ var style = maskList.slice(-1)[0];
1184
+ this.setMaskStyle(style);
1185
+ }
1186
+ }
1187
+ }, {
1188
+ key: "storeMaskInsCfg",
1189
+ value: function storeMaskInsCfg(config) {
1190
+ this.zIndexStore.set(config.uuid, config);
1191
+ this.lastUUID = config.uuid;
1192
+ return this.zIndexStore.get(config.uuid);
1193
+ }
1194
+ /**
1195
+ * 移除最后一次缓存数据
1196
+ */
1197
+ }, {
1198
+ key: "popIndexStore",
1199
+ value: function popIndexStore(uuid) {
1200
+ if (this.zIndexStore.has(uuid)) {
1201
+ var rmIns = this.zIndexStore.get(uuid);
1202
+ this.lastUUID = rmIns.preUID;
1203
+ return this.zIndexStore["delete"](uuid);
1204
+ }
1205
+ this.lastUUID = null;
1206
+ return false;
1207
+ }
1208
+ }, {
1209
+ key: "backupActiveInstance",
1210
+ value: function backupActiveInstance() {
1211
+ if (this.activeInstance) {
1212
+ this.backupMask.append(this.activeInstance);
1213
+ }
1214
+ }
1215
+ }, {
1216
+ key: "backupContentElement",
1217
+ value: function backupContentElement(content) {
1218
+ var _this$backupMask;
1219
+ content && ((_this$backupMask = this.backupMask) === null || _this$backupMask === void 0 ? void 0 : _this$backupMask.append(content));
1220
+ }
1221
+ }, {
1222
+ key: "getActiveContentInstance",
1223
+ value: function getActiveContentInstance() {
1224
+ return this.activeInstance;
1225
+ }
1226
+ }, {
1227
+ key: "removeClickEvent",
1228
+ value: function removeClickEvent() {
1229
+ // if (this.mask) {
1230
+ // const events = getMaskEvent(this.mask);
1231
+ // if (!events.length) {
1232
+ // console.log('removeEventListener handleMaskClick');
1233
+ // this.mask.removeEventListener('click', this.handleMaskClick);
1234
+ // }
1235
+ // }
1236
+ }
1237
+ }, {
1238
+ key: "initInstance",
1239
+ value: function initInstance(maskStyle) {
1240
+ if (!this.isInit) {
1241
+ this.isInit = true;
1242
+ this.backupMask = this.getBackupMask();
1243
+ var _this$getMask = this.getMask(),
1244
+ instance = _this$getMask.instance,
1245
+ isExist = _this$getMask.isExist;
1246
+ this.mask = instance;
1247
+ !isExist && this.setMaskStyle(Object.assign({}, this.maskStyle, maskStyle));
1248
+ }
1249
+ }
1250
+ /**
1251
+ * 初始化当前遮罩管理器
1252
+ * @returns 当前遮罩容器
1253
+ */
1254
+ }, {
1255
+ key: "getMask",
1256
+ value: function getMask() {
1257
+ var _this3 = this;
1258
+ if (this.multiInstance) {
1259
+ return {
1260
+ instance: this.createMask(),
1261
+ isExist: false
1262
+ };
1263
+ }
1264
+ var isExist = true;
1265
+ var div = this.parentNode.querySelector("[data-bk-mask-uid='".concat(this.uniqueMaskAttrTag, "']"));
1266
+ if (!div) {
1267
+ isExist = false;
1268
+ div = this.createMask();
1269
+ div.addEventListener('click', function (e) {
1270
+ return _this3.handleMaskClick(e);
1271
+ }, true);
1272
+ }
1273
+ return {
1274
+ instance: div,
1275
+ isExist: isExist
1276
+ };
1277
+ }
1278
+ }, {
1279
+ key: "catchClickEvent",
1280
+ value: function catchClickEvent(content, onMaskClick, instanceId) {
1281
+ if (this.mask) {
1282
+ setMaskEvent(this.mask, onMaskClick, [], content, instanceId);
1283
+ }
1284
+ }
1285
+ }, {
1286
+ key: "handleMaskClick",
1287
+ value: function handleMaskClick(e) {
1288
+ if (e.target !== this.mask) {
1289
+ return;
1290
+ }
1291
+ var events = getMaskEvent(this.mask);
1292
+ if (events.length) {
1293
+ var event = events.slice(-1)[0].event;
1294
+ if (typeof event === 'function') {
1295
+ event(e);
1296
+ }
1297
+ }
1298
+ }
1299
+ }, {
1300
+ key: "getBackupMask",
1301
+ value: function getBackupMask() {
1302
+ var attrName = 'data-bk-backup-uid';
1303
+ var div = this.parentNode.querySelector("[".concat(attrName, "]"));
1304
+ if (!div) {
1305
+ div = this.createMask(attrName);
1306
+ }
1307
+ return div;
1308
+ }
1309
+ /**
1310
+ * 创建遮罩层DOM
1311
+ * @returns 返回DOM
1312
+ */
1313
+ }, {
1314
+ key: "createMask",
1315
+ value: function createMask() {
1316
+ var attrName = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 'data-bk-mask-uid';
1317
+ var div = document.createElement('div');
1318
+ div.setAttribute(attrName, this.uniqueMaskAttrTag);
1319
+ this.parentNode.append(div);
1320
+ return div;
1321
+ }
1322
+ }, {
1323
+ key: "setMaskStyle",
1324
+ value: function setMaskStyle() {
1325
+ var _this4 = this;
1326
+ var maskStyle = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : {};
1327
+ if (this.mask) {
1328
+ Object.entries(maskStyle).forEach(function (cfg) {
1329
+ return _this4.mask.style.setProperty(cfg[0], cfg[1]);
1330
+ });
1331
+ }
1332
+ }
1333
+ /**
1334
+ * 根据输入生成唯一遮罩标识
1335
+ * @param tag 输入标识
1336
+ * @returns string 返回唯一标识
1337
+ */
1338
+ }, {
1339
+ key: "getMaskAttrTag",
1340
+ value: function getMaskAttrTag(tag) {
1341
+ if (/^(auto|\s+)$/i.test(tag) || tag === null || tag === undefined || tag === '') {
1342
+ if (!bkMaskMaker.getMaskId(this.parentNode)) {
1343
+ bkMaskMaker.setMaskId(this.parentNode, "__bk_mask_".concat(random(16)));
1344
+ }
1345
+ return bkMaskMaker.getMaskId(this.parentNode);
1346
+ }
1347
+ return tag;
1348
+ }
1349
+ }, {
1350
+ key: "appendContentToMask",
1351
+ value: function appendContentToMask(content) {
1352
+ this.mask.append(content);
1353
+ }
1354
+ }]);
1355
+ return BkMaskManager;
1356
+ }();
1357
+ var bKMaskManager = new BkMaskManager({});
1358
+ ;// CONCATENATED MODULE: ../../packages/shared/src/pop-manager.ts
1359
+
1360
+
1361
+ /*
1362
+ * Tencent is pleased to support the open source community by making
1363
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
1364
+ *
1365
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
1366
+ *
1367
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
1368
+ *
1369
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
1370
+ *
1371
+ * ---------------------------------------------------
1372
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
1373
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
1374
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
1375
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
1376
+ *
1377
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
1378
+ * the Software.
1379
+ *
1380
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
1381
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1382
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
1383
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
1384
+ * IN THE SOFTWARE.
1385
+ */
1386
+
1387
+
1388
+
1389
+
1390
+ var popInstanceStore = new WeakMap();
1391
+ var BKPopIndexManager = /*#__PURE__*/function () {
1392
+ /** 用来缓存弹出层实例 */
1393
+
1394
+ function BKPopIndexManager(options) {
1395
+ _classCallCheck(this, BKPopIndexManager);
1396
+ this.clickFn = undefined;
1397
+ this.uuidAttrName = 'data-bk-pop-uuid';
1398
+ this.uniqId = random(16);
1399
+ this.transfer = this.getParentNode(options === null || options === void 0 ? void 0 : options.transfer);
1400
+ this.bKMaskManagerInstance = new BkMaskManager({
1401
+ parentNode: this.getParentNode(options === null || options === void 0 ? void 0 : options.transfer),
1402
+ popInstance: this,
1403
+ onClick: this.onMaskClickFn
1404
+ });
1405
+ }
1406
+ _createClass(BKPopIndexManager, [{
1407
+ key: "popInstanceList",
1408
+ get: function get() {
1409
+ if (!popInstanceStore.has(this.transfer)) {
1410
+ popInstanceStore.set(this.transfer, []);
1411
+ }
1412
+ return popInstanceStore.get(this.transfer);
1413
+ },
1414
+ set: function set(val) {
1415
+ popInstanceStore.set(this.transfer, val);
1416
+ }
1417
+ }, {
1418
+ key: "getParentNode",
1419
+ value: function getParentNode(transfer) {
1420
+ if (typeof transfer === 'string') {
1421
+ var target = document.querySelector(transfer);
1422
+ if (target) {
1423
+ return target;
1424
+ }
1425
+ }
1426
+ if (helper_isElement(transfer)) {
1427
+ return transfer;
1428
+ }
1429
+ return document.body;
1430
+ }
1431
+ }, {
1432
+ key: "onMaskClick",
1433
+ value: function onMaskClick(callFn, target) {
1434
+ this.clickFn = {
1435
+ fn: callFn,
1436
+ target: target
1437
+ };
1438
+ }
1439
+ /**
1440
+ * 展示弹窗
1441
+ * @param content 弹窗内容
1442
+ * @param showMask 是否显示遮罩
1443
+ * @param appendStyle 追加样式
1444
+ * @param transfer 是否显示在body内(即是否显示在div#app内,默认为false)
1445
+ * @returns
1446
+ */
1447
+ }, {
1448
+ key: "show",
1449
+ value: function show(content) {
1450
+ var showMask = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
1451
+ var appendStyle = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
1452
+ var transfer = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : false;
1453
+ var zindex = arguments.length > 4 && arguments[4] !== undefined ? arguments[4] : undefined;
1454
+ var onMaskClick = arguments.length > 5 ? arguments[5] : undefined;
1455
+ if (!content) {
1456
+ console.warn('pop show error: content is null or undefined');
1457
+ return;
1458
+ }
1459
+ var zIndex = typeof zindex === 'number' ? zindex : bkZIndexManager.getModalNextIndex();
1460
+ var uuid = random(16);
1461
+ content.setAttribute(this.uuidAttrName, uuid);
1462
+ if (this.popInstanceList.length > 0) {
1463
+ showMask && this.bKMaskManagerInstance.backupContentElement(this.popInstanceList.slice(-1)[0].content);
1464
+ }
1465
+ this.popInstanceList.push({
1466
+ uuid: uuid,
1467
+ zIndex: zIndex,
1468
+ content: content,
1469
+ showMask: showMask,
1470
+ appendStyle: appendStyle
1471
+ });
1472
+ this.bKMaskManagerInstance.show(content, zIndex, showMask, appendStyle, uuid, transfer, onMaskClick, this.uniqId);
1473
+ }
1474
+ /**
1475
+ * 销毁指定实例
1476
+ * @param content 指定实例内容
1477
+ * @param transfer
1478
+ */
1479
+ }, {
1480
+ key: "destroy",
1481
+ value: function destroy(content) {
1482
+ var transfer = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
1483
+ this.clickFn = undefined;
1484
+ this.hide(content, transfer);
1485
+ }
1486
+ /**
1487
+ * 关闭最后一个弹窗 如果当前还有父级弹窗,则激活父级弹窗
1488
+ * @param removeLastContent 默认:true 是否自动关闭最后一个弹窗实例 某些场景下,已经主动关闭最后一个弹窗,此处只需要处理其他逻辑
1489
+ */
1490
+ }, {
1491
+ key: "popHide",
1492
+ value: function popHide() {
1493
+ var removeLastContent = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : true;
1494
+ if (this.popInstanceList.length) {
1495
+ if (removeLastContent) {
1496
+ var lastItem = this.popInstanceList.pop();
1497
+ this.bKMaskManagerInstance.popIndexStore(lastItem.uuid);
1498
+ lastItem.remove();
1499
+ }
1500
+ if (this.popInstanceList.length) {
1501
+ var activeItem = this.popInstanceList.slice(-1)[0];
1502
+ var zIndex = activeItem.zIndex,
1503
+ content = activeItem.content,
1504
+ showMask = activeItem.showMask,
1505
+ appendStyle = activeItem.appendStyle,
1506
+ uuid = activeItem.uuid;
1507
+ this.bKMaskManagerInstance.show(content, zIndex, showMask, appendStyle, uuid);
1508
+ } else {
1509
+ this.bKMaskManagerInstance.hide();
1510
+ // this.clickFn.length = 0;
1511
+ }
1512
+ }
1513
+ }
1514
+ /**
1515
+ * 关闭指定弹窗
1516
+ * @param content { HTMLElement } 关闭弹窗内容
1517
+ * **/
1518
+ }, {
1519
+ key: "hide",
1520
+ value: function hide(content) {
1521
+ var transfer = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
1522
+ /** 检查当前实例是否存在于已缓存列表 */
1523
+ var uuid = content === null || content === void 0 ? void 0 : content.getAttribute(this.uuidAttrName);
1524
+ if (uuid) {
1525
+ var itemIndex = this.popInstanceList.findIndex(function (item) {
1526
+ return item.uuid === uuid;
1527
+ });
1528
+ if (itemIndex >= 0) {
1529
+ if (!transfer) this.popInstanceList[itemIndex].content.remove();
1530
+ this.popInstanceList.splice(itemIndex, 1);
1531
+ this.bKMaskManagerInstance.popIndexStore(uuid);
1532
+ if (!this.popInstanceList.length) {
1533
+ this.bKMaskManagerInstance.hide(transfer);
1534
+ } else {
1535
+ this.popHide(false);
1536
+ }
1537
+ }
1538
+ } else {
1539
+ content === null || content === void 0 ? void 0 : content.remove();
1540
+ }
1541
+ this.bKMaskManagerInstance.removeClickEvent();
1542
+ }
1543
+ }, {
1544
+ key: "removeLastEvent",
1545
+ value: function removeLastEvent() {
1546
+ this.bKMaskManagerInstance.destroyEvent(this.uniqId);
1547
+ }
1548
+ }, {
1549
+ key: "onMaskClickFn",
1550
+ value: function onMaskClickFn(e) {
1551
+ if (this.clickFn) {
1552
+ var fn = this.clickFn.fn;
1553
+ if (fn) {
1554
+ Reflect.apply(fn, this, [e]);
1555
+ }
1556
+ }
1557
+ }
1558
+ }]);
1559
+ return BKPopIndexManager;
1560
+ }();
1561
+ var bkPopIndexManager = new BKPopIndexManager();
1562
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/arrayLikeToArray.js
1563
+ function _arrayLikeToArray(arr, len) {
1564
+ if (len == null || len > arr.length) len = arr.length;
1565
+ for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
1566
+ return arr2;
1567
+ }
1568
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/arrayWithoutHoles.js
1569
+
1570
+ function _arrayWithoutHoles(arr) {
1571
+ if (Array.isArray(arr)) return _arrayLikeToArray(arr);
1572
+ }
1573
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/iterableToArray.js
1574
+ function _iterableToArray(iter) {
1575
+ if (typeof Symbol !== "undefined" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
1576
+ }
1577
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/unsupportedIterableToArray.js
1578
+
1579
+ function _unsupportedIterableToArray(o, minLen) {
1580
+ if (!o) return;
1581
+ if (typeof o === "string") return _arrayLikeToArray(o, minLen);
1582
+ var n = Object.prototype.toString.call(o).slice(8, -1);
1583
+ if (n === "Object" && o.constructor) n = o.constructor.name;
1584
+ if (n === "Map" || n === "Set") return Array.from(o);
1585
+ if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen);
1586
+ }
1587
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/nonIterableSpread.js
1588
+ function _nonIterableSpread() {
1589
+ throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
1590
+ }
1591
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/toConsumableArray.js
1592
+
1593
+
1594
+
1595
+
1596
+ function _toConsumableArray(arr) {
1597
+ return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread();
1598
+ }
1599
+ ;// CONCATENATED MODULE: ../../node_modules/uuid/dist/esm-browser/native.js
1600
+ const randomUUID = typeof crypto !== 'undefined' && crypto.randomUUID && crypto.randomUUID.bind(crypto);
1601
+ /* harmony default export */ const esm_browser_native = ({
1602
+ randomUUID
1603
+ });
1604
+ ;// CONCATENATED MODULE: ../../node_modules/uuid/dist/esm-browser/rng.js
1605
+ // Unique ID creation requires a high quality random # generator. In the browser we therefore
1606
+ // require the crypto API and do not support built-in fallback to lower quality random number
1607
+ // generators (like Math.random()).
1608
+ let getRandomValues;
1609
+ const rnds8 = new Uint8Array(16);
1610
+ function rng() {
1611
+ // lazy load so that environments that need to polyfill have a chance to do so
1612
+ if (!getRandomValues) {
1613
+ // getRandomValues needs to be invoked in a context where "this" is a Crypto implementation.
1614
+ getRandomValues = typeof crypto !== 'undefined' && crypto.getRandomValues && crypto.getRandomValues.bind(crypto);
1615
+
1616
+ if (!getRandomValues) {
1617
+ throw new Error('crypto.getRandomValues() not supported. See https://github.com/uuidjs/uuid#getrandomvalues-not-supported');
1618
+ }
1619
+ }
1620
+
1621
+ return getRandomValues(rnds8);
1622
+ }
1623
+ ;// CONCATENATED MODULE: ../../node_modules/uuid/dist/esm-browser/stringify.js
1624
+
1625
+ /**
1626
+ * Convert array of 16 byte values to UUID string format of the form:
1627
+ * XXXXXXXX-XXXX-XXXX-XXXX-XXXXXXXXXXXX
1628
+ */
1629
+
1630
+ const byteToHex = [];
1631
+
1632
+ for (let i = 0; i < 256; ++i) {
1633
+ byteToHex.push((i + 0x100).toString(16).slice(1));
1634
+ }
1635
+
1636
+ function unsafeStringify(arr, offset = 0) {
1637
+ // Note: Be careful editing this code! It's been tuned for performance
1638
+ // and works in ways you may not expect. See https://github.com/uuidjs/uuid/pull/434
1639
+ return byteToHex[arr[offset + 0]] + byteToHex[arr[offset + 1]] + byteToHex[arr[offset + 2]] + byteToHex[arr[offset + 3]] + '-' + byteToHex[arr[offset + 4]] + byteToHex[arr[offset + 5]] + '-' + byteToHex[arr[offset + 6]] + byteToHex[arr[offset + 7]] + '-' + byteToHex[arr[offset + 8]] + byteToHex[arr[offset + 9]] + '-' + byteToHex[arr[offset + 10]] + byteToHex[arr[offset + 11]] + byteToHex[arr[offset + 12]] + byteToHex[arr[offset + 13]] + byteToHex[arr[offset + 14]] + byteToHex[arr[offset + 15]];
1640
+ }
1641
+
1642
+ function stringify(arr, offset = 0) {
1643
+ const uuid = unsafeStringify(arr, offset); // Consistency check for valid UUID. If this throws, it's likely due to one
1644
+ // of the following:
1645
+ // - One or more input array values don't map to a hex octet (leading to
1646
+ // "undefined" in the uuid)
1647
+ // - Invalid input values for the RFC `version` or `variant` fields
1648
+
1649
+ if (!validate(uuid)) {
1650
+ throw TypeError('Stringified UUID is invalid');
1651
+ }
1652
+
1653
+ return uuid;
1654
+ }
1655
+
1656
+ /* harmony default export */ const esm_browser_stringify = ((/* unused pure expression or super */ null && (stringify)));
1657
+ ;// CONCATENATED MODULE: ../../node_modules/uuid/dist/esm-browser/v4.js
1658
+
1659
+
1660
+
1661
+
1662
+ function v4(options, buf, offset) {
1663
+ if (esm_browser_native.randomUUID && !buf && !options) {
1664
+ return esm_browser_native.randomUUID();
1665
+ }
1666
+
1667
+ options = options || {};
1668
+ const rnds = options.random || (options.rng || rng)(); // Per 4.4, set bits for version and `clock_seq_hi_and_reserved`
1669
+
1670
+ rnds[6] = rnds[6] & 0x0f | 0x40;
1671
+ rnds[8] = rnds[8] & 0x3f | 0x80; // Copy bytes to buffer, if provided
1672
+
1673
+ if (buf) {
1674
+ offset = offset || 0;
1675
+
1676
+ for (let i = 0; i < 16; ++i) {
1677
+ buf[offset + i] = rnds[i];
1678
+ }
1679
+
1680
+ return buf;
1681
+ }
1682
+
1683
+ return unsafeStringify(rnds);
1684
+ }
1685
+
1686
+ /* harmony default export */ const esm_browser_v4 = (v4);
1687
+ ;// CONCATENATED MODULE: external "@popperjs/core"
1688
+ var core_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
1689
+ var core_y = x => () => x
1690
+ const core_namespaceObject = core_x({ ["createPopper"]: () => __WEBPACK_EXTERNAL_MODULE__popperjs_core_a5c7319c__.createPopper });
1691
+ ;// CONCATENATED MODULE: ../../packages/shared/src/popover.ts
1692
+
1693
+
1694
+
1695
+
1696
+
1697
+ /*
1698
+ * Tencent is pleased to support the open source community by making
1699
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
1700
+ *
1701
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
1702
+ *
1703
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
1704
+ *
1705
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
1706
+ *
1707
+ * ---------------------------------------------------
1708
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
1709
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
1710
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
1711
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
1712
+ *
1713
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
1714
+ * the Software.
1715
+ *
1716
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
1717
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
1718
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
1719
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
1720
+ * IN THE SOFTWARE.
1721
+ */
1722
+
1723
+
1724
+
1725
+ var BKPopover = /*#__PURE__*/function () {
1726
+ function BKPopover(reference, popperRefer, options) {
1727
+ var _this$popperRefer, _this$instanceOptions;
1728
+ _classCallCheck(this, BKPopover);
1729
+ /** 当前提内容是否弹出 */
1730
+ _defineProperty(this, "isShow", false);
1731
+ /** 触发条件 */
1732
+ _defineProperty(this, "trigger", undefined);
1733
+ /** 当前popperjs实例 */
1734
+ _defineProperty(this, "instance", undefined);
1735
+ /** 是否总是可见 */
1736
+ _defineProperty(this, "always", false);
1737
+ /** Popover 外层容器,触发Pop的元素 */
1738
+ _defineProperty(this, "reference", undefined);
1739
+ /** Popover 弹出内容外层占位容器 */
1740
+ _defineProperty(this, "referenceTarget", undefined);
1741
+ /** Popover Content 外层容器,目标元素:实际弹出内容 */
1742
+ _defineProperty(this, "popperRefer", undefined);
1743
+ /** hide延时 */
1744
+ _defineProperty(this, "delay", 50);
1745
+ /** 是否进入popperRefer */
1746
+ _defineProperty(this, "isInnerPopper", false);
1747
+ /** 是否为禁用状态 */
1748
+ _defineProperty(this, "disabled", false);
1749
+ /** 执行显示函数 */
1750
+ _defineProperty(this, "afterShow", null);
1751
+ /** 执行隐藏函数 */
1752
+ _defineProperty(this, "afterHidden", null);
1753
+ /** 弹出内容AppendTo */
1754
+ _defineProperty(this, "appendTo", 'parent');
1755
+ /** 父级容器 */
1756
+ _defineProperty(this, "container", null);
1757
+ /**
1758
+ * 如果设置了appendTo为指定DOM,此配置项生效
1759
+ * 是否将弹出内容固定到目标元素位置
1760
+ * 例如:appendTo = document.body, fixOnBoundary = true,则弹出内容会一直固定到body
1761
+ */
1762
+ _defineProperty(this, "fixOnBoundary", false);
1763
+ this.instanceOptions = this.initDefaultOptions(options);
1764
+ this.reference = this.resolveInputSelectorToHtmlElement(reference);
1765
+ this.popperRefer = this.resolveInputSelectorToHtmlElement(popperRefer);
1766
+ this.referenceTarget = this.getTargetReferenceElement();
1767
+ this.container = (_this$popperRefer = this.popperRefer) === null || _this$popperRefer === void 0 ? void 0 : _this$popperRefer.parentElement;
1768
+ this.isShow = !!((_this$instanceOptions = this.instanceOptions) !== null && _this$instanceOptions !== void 0 && _this$instanceOptions.isShow);
1769
+ this.always = this.instanceOptions.always;
1770
+ this.trigger = this.instanceOptions.trigger;
1771
+ this.disabled = this.instanceOptions.disabled;
1772
+ this.appendTo = this.instanceOptions.appendTo;
1773
+ this.afterHidden = typeof options.afterHidden === 'function' ? options.afterHidden : function () {};
1774
+ this.afterShow = typeof options.afterShow === 'function' ? options.afterShow : function () {};
1775
+ this.fixOnBoundary = this.instanceOptions.fixOnBoundary;
1776
+ this.initInstance();
1777
+ this.registerEvents();
1778
+ /** 默认弹出 */
1779
+ if (this.isShow || this.always) {
1780
+ this.show(null);
1781
+ }
1782
+ }
1783
+ // Synchronously updates the popper instance. Use this for low-frequency
1784
+ // updates.
1785
+ _createClass(BKPopover, [{
1786
+ key: "forceUpdate",
1787
+ value: function forceUpdate() {
1788
+ var _this$instance;
1789
+ (_this$instance = this.instance) === null || _this$instance === void 0 ? void 0 : _this$instance.forceUpdate();
1790
+ }
1791
+ // Asynchronously updates the popper instance, and returns a promise. Use this
1792
+ // for high-frequency updates.
1793
+ }, {
1794
+ key: "update",
1795
+ value: function update() {
1796
+ var _this$instance2;
1797
+ (_this$instance2 = this.instance) === null || _this$instance2 === void 0 ? void 0 : _this$instance2.update();
1798
+ }
1799
+ }, {
1800
+ key: "updateOptions",
1801
+ value: function updateOptions(options) {
1802
+ var _this$instanceOptions2;
1803
+ this.instanceOptions = this.initDefaultOptions(options);
1804
+ this.isShow = !!((_this$instanceOptions2 = this.instanceOptions) !== null && _this$instanceOptions2 !== void 0 && _this$instanceOptions2.isShow);
1805
+ this.trigger = this.instanceOptions.trigger;
1806
+ this.disabled = this.instanceOptions.disabled;
1807
+ this.setOptions(this.instanceOptions);
1808
+ }
1809
+ // Updates the options of the instance.
1810
+ }, {
1811
+ key: "setOptions",
1812
+ value: function setOptions(options) {
1813
+ var _this$instance3;
1814
+ (_this$instance3 = this.instance) === null || _this$instance3 === void 0 ? void 0 : _this$instance3.setOptions(options);
1815
+ }
1816
+ // Cleans up the instance.
1817
+ }, {
1818
+ key: "destroy",
1819
+ value: function destroy() {
1820
+ var _this$instance4;
1821
+ (_this$instance4 = this.instance) === null || _this$instance4 === void 0 ? void 0 : _this$instance4.destroy();
1822
+ }
1823
+ // 更新禁用状态
1824
+ }, {
1825
+ key: "updateDisabled",
1826
+ value: function updateDisabled(disabled) {
1827
+ this.disabled = disabled !== null && disabled !== void 0 ? disabled : !this.disabled;
1828
+ this.disabled && this.hide();
1829
+ }
1830
+ /**
1831
+ * 展示Pop
1832
+ * @param _event 触发事件
1833
+ */
1834
+ }, {
1835
+ key: "show",
1836
+ value: function show(_event) {
1837
+ if (!this.disabled) {
1838
+ var _this$popperRefer2;
1839
+ // Make the tooltip visible
1840
+ (_this$popperRefer2 = this.popperRefer) === null || _this$popperRefer2 === void 0 ? void 0 : _this$popperRefer2.setAttribute('data-show', '');
1841
+ // Enable the event listeners
1842
+ this.setOptions({
1843
+ modifiers: [].concat(_toConsumableArray(this.instanceOptions.modifiers || []), [{
1844
+ name: 'eventListeners',
1845
+ enabled: true
1846
+ }])
1847
+ });
1848
+ // Update its position
1849
+ this.update();
1850
+ this.isShow = true;
1851
+ this.afterShow();
1852
+ if (!this.fixOnBoundary) {
1853
+ this.appendToTarget();
1854
+ }
1855
+ }
1856
+ }
1857
+ /**
1858
+ * 隐藏
1859
+ * @param event 触发事件
1860
+ */
1861
+ }, {
1862
+ key: "hide",
1863
+ value: function hide() {
1864
+ var _this$popperRefer3;
1865
+ if (this.always) return;
1866
+ // Hide the tooltip
1867
+ (_this$popperRefer3 = this.popperRefer) === null || _this$popperRefer3 === void 0 ? void 0 : _this$popperRefer3.removeAttribute('data-show');
1868
+ // Disable the event listeners
1869
+ this.setOptions({
1870
+ modifiers: [].concat(_toConsumableArray(this.instanceOptions.modifiers || []), [{
1871
+ name: 'eventListeners',
1872
+ enabled: false
1873
+ }])
1874
+ });
1875
+ this.isShow = false;
1876
+ this.isInnerPopper = false;
1877
+ this.afterHidden();
1878
+ if (!this.fixOnBoundary) {
1879
+ this.restorePopContent();
1880
+ }
1881
+ }
1882
+ /**
1883
+ * 还原PopContent到初试位置
1884
+ */
1885
+ }, {
1886
+ key: "restorePopContent",
1887
+ value: function restorePopContent() {
1888
+ var target = this.getAppendToTarget();
1889
+ if (helper_isElement(target) && target.contains(this.popperRefer) && this.container && !this.container.contains(this.popperRefer)) {
1890
+ this.container.append(this.popperRefer);
1891
+ }
1892
+ }
1893
+ /**
1894
+ * 挂载PopContent到目标位置
1895
+ */
1896
+ }, {
1897
+ key: "appendToTarget",
1898
+ value: function appendToTarget() {
1899
+ var target = this.getAppendToTarget();
1900
+ if (helper_isElement(target) && target.contains(this.popperRefer)) {
1901
+ target.append(this.popperRefer);
1902
+ }
1903
+ }
1904
+ /**
1905
+ * 获取目标位置元素
1906
+ * @returns
1907
+ */
1908
+ }, {
1909
+ key: "getAppendToTarget",
1910
+ value: function getAppendToTarget() {
1911
+ var appendTo = this.appendTo;
1912
+ var target = appendTo;
1913
+ if (appendTo !== 'parent') {
1914
+ if (typeof appendTo === 'string') {
1915
+ target = document.querySelector(appendTo);
1916
+ }
1917
+ }
1918
+ return target;
1919
+ }
1920
+ /**
1921
+ * 初始化默认配置
1922
+ * @param opts
1923
+ * @returns
1924
+ */
1925
+ }, {
1926
+ key: "initDefaultOptions",
1927
+ value: function initDefaultOptions(opts) {
1928
+ var _this = this;
1929
+ var defaultCfg = {
1930
+ placement: 'top',
1931
+ modifiers: [{
1932
+ name: 'offset',
1933
+ options: {
1934
+ offset: [0, 8]
1935
+ }
1936
+ }],
1937
+ strategy: 'absolute',
1938
+ onFirstUpdate: undefined,
1939
+ isShow: false,
1940
+ theme: 'dark',
1941
+ trigger: 'hover',
1942
+ disabled: false
1943
+ };
1944
+ var targetOptions = merge(defaultCfg, opts || {});
1945
+ var sourceOnFirstUpdate = targetOptions.onFirstUpdate;
1946
+ targetOptions.onFirstUpdate = function (state) {
1947
+ if (typeof sourceOnFirstUpdate === 'function') {
1948
+ sourceOnFirstUpdate.call(_this, state);
1949
+ _this.handleFirstUpdate();
1950
+ }
1951
+ };
1952
+ return targetOptions;
1953
+ }
1954
+ /**
1955
+ * 判定是否需要将PopContent挂载到目标元素
1956
+ */
1957
+ }, {
1958
+ key: "handleFirstUpdate",
1959
+ value: function handleFirstUpdate() {
1960
+ if (this.fixOnBoundary) {
1961
+ this.appendToTarget();
1962
+ }
1963
+ }
1964
+ /**
1965
+ * 剔除 Pop 外层容器,获取目标元素
1966
+ * @returns
1967
+ */
1968
+ }, {
1969
+ key: "getTargetReferenceElement",
1970
+ value: function getTargetReferenceElement() {
1971
+ if (this.isElement(this.reference)) {
1972
+ return this.reference.childElementCount === 1 ? this.reference.firstElementChild : this.reference;
1973
+ }
1974
+ return this.reference;
1975
+ }
1976
+ /**
1977
+ * 初始化Pop Instance
1978
+ */
1979
+ }, {
1980
+ key: "initInstance",
1981
+ value: function initInstance() {
1982
+ if (this.referenceTarget) {
1983
+ if (this.referenceTarget && this.popperRefer) {
1984
+ var _this$popperRefer4, _this$instanceOptions3;
1985
+ this.instance = (0,core_namespaceObject.createPopper)(this.referenceTarget, this.popperRefer, this.instanceOptions);
1986
+ (_this$popperRefer4 = this.popperRefer) === null || _this$popperRefer4 === void 0 ? void 0 : _this$popperRefer4.setAttribute('data-theme', (_this$instanceOptions3 = this.instanceOptions.theme) !== null && _this$instanceOptions3 !== void 0 ? _this$instanceOptions3 : 'dark');
1987
+ } else {
1988
+ console.error('reference or popperRefer is null, please check html element.');
1989
+ }
1990
+ }
1991
+ }
1992
+ /**
1993
+ * 解析当前参数为对应的Html Element
1994
+ * @param refer Html Element Selector Or Html Element
1995
+ * @param checkVirtualDom 是否检查虚拟DOM
1996
+ * @returns Html Element Or Null
1997
+ */
1998
+ }, {
1999
+ key: "resolveInputSelectorToHtmlElement",
2000
+ value: function resolveInputSelectorToHtmlElement(refer) {
2001
+ if (this.isElement(refer)) {
2002
+ return refer;
2003
+ }
2004
+ if (typeof refer === 'string') {
2005
+ return document.querySelector(refer);
2006
+ }
2007
+ if (_typeof(refer) === 'object') {
2008
+ if (Object.prototype.hasOwnProperty.call(refer, 'getBoundingClientRect')) {
2009
+ return refer;
2010
+ }
2011
+ } else {
2012
+ console.error("'getBoundingClientRect' is needed when use virtual elements");
2013
+ }
2014
+ return null;
2015
+ }
2016
+ /**
2017
+ * 检查当前元素是否为Html元素
2018
+ * @param obj
2019
+ * @returns
2020
+ */
2021
+ }, {
2022
+ key: "isElement",
2023
+ value: function isElement(obj) {
2024
+ return helper_isElement(obj);
2025
+ }
2026
+ }, {
2027
+ key: "registerEvents",
2028
+ value: function registerEvents() {
2029
+ var _this2 = this;
2030
+ if (this.isElement(this.referenceTarget)) {
2031
+ if (this.trigger === 'hover') {
2032
+ var showEvents = ['mouseenter', 'focus'];
2033
+ var hideEvents = ['mouseleave', 'blur'];
2034
+ var contentEvents = ['mouseenter', 'mouseleave'];
2035
+ showEvents.forEach(function (event) {
2036
+ _this2.referenceTarget.addEventListener(event, function (evt) {
2037
+ if (event === 'mouseenter') _this2.isInnerPopper = true;
2038
+ _this2.show(evt);
2039
+ });
2040
+ });
2041
+ hideEvents.forEach(function (event) {
2042
+ _this2.referenceTarget.addEventListener(event, function () {
2043
+ _this2.isInnerPopper = false;
2044
+ setTimeout(function () {
2045
+ !_this2.isInnerPopper && _this2.hide();
2046
+ }, _this2.delay);
2047
+ });
2048
+ });
2049
+ if (this.isElement(this.popperRefer)) {
2050
+ contentEvents.forEach(function (event) {
2051
+ _this2.popperRefer.addEventListener(event, function () {
2052
+ if (event === 'mouseenter') _this2.isInnerPopper = true;
2053
+ if (event === 'mouseleave') _this2.hide();
2054
+ });
2055
+ });
2056
+ }
2057
+ }
2058
+ }
2059
+ if (this.trigger === 'click') {
2060
+ var _showEvents = ['click'];
2061
+ _showEvents.forEach(function (event) {
2062
+ document.body.addEventListener(event, function (event) {
2063
+ if (_this2.isSameElement(event.target, _this2.reference) || _this2.reference.contains(event.target)) {
2064
+ _this2.show(event);
2065
+ } else {
2066
+ if (_this2.isShow && !_this2.isSameElement(event.target, _this2.popperRefer) && !_this2.popperRefer.contains(event.target)) {
2067
+ _this2.hide();
2068
+ }
2069
+ }
2070
+ });
2071
+ });
2072
+ }
2073
+ }
2074
+ }, {
2075
+ key: "isSameElement",
2076
+ value: function isSameElement(source, target) {
2077
+ return source && (source === target || source === target.firstElementChild);
2078
+ }
2079
+ }]);
2080
+ return BKPopover;
2081
+ }();
2082
+ var popContainerId = null;
2083
+ var getPopContainerId = function getPopContainerId() {
2084
+ var prefix = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : '#';
2085
+ if (popContainerId === null) {
2086
+ popContainerId = "id_".concat(esm_browser_v4());
2087
+ var popContainer = document.createElement('div');
2088
+ popContainer.setAttribute('id', popContainerId);
2089
+ popContainer.setAttribute('data-popper-id', popContainerId);
2090
+ document.body.append(popContainer);
2091
+ }
2092
+ return "".concat(prefix).concat(popContainerId);
2093
+ };
2094
+ ;// CONCATENATED MODULE: ../../packages/shared/src/scrollbar-width.ts
2095
+ /*
2096
+ * Tencent is pleased to support the open source community by making
2097
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
2098
+ *
2099
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
2100
+ *
2101
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
2102
+ *
2103
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
2104
+ *
2105
+ * ---------------------------------------------------
2106
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
2107
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
2108
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
2109
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
2110
+ *
2111
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
2112
+ * the Software.
2113
+ *
2114
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
2115
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
2116
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
2117
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
2118
+ * IN THE SOFTWARE.
2119
+ */
2120
+ var scrollBarWidth;
2121
+ function scrollbarWidth() {
2122
+ if (scrollBarWidth !== undefined) return scrollBarWidth;
2123
+ var outer = document.createElement('div');
2124
+ outer.className = 'bk-scrollbar-wrap';
2125
+ outer.style.visibility = 'hidden';
2126
+ outer.style.width = '100px';
2127
+ outer.style.position = 'absolute';
2128
+ outer.style.top = '-9999px';
2129
+ document.body.appendChild(outer);
2130
+ var widthNoScroll = outer.offsetWidth;
2131
+ outer.style.overflow = 'scroll';
2132
+ var inner = document.createElement('div');
2133
+ inner.style.width = '100%';
2134
+ outer.appendChild(inner);
2135
+ var widthWithScroll = inner.offsetWidth;
2136
+ outer.parentNode.removeChild(outer);
2137
+ scrollBarWidth = widthNoScroll - widthWithScroll;
2138
+ return scrollBarWidth;
2139
+ }
2140
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/setPrototypeOf.js
2141
+ function _setPrototypeOf(o, p) {
2142
+ _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function _setPrototypeOf(o, p) {
2143
+ o.__proto__ = p;
2144
+ return o;
2145
+ };
2146
+ return _setPrototypeOf(o, p);
2147
+ }
2148
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/inherits.js
2149
+
2150
+ function _inherits(subClass, superClass) {
2151
+ if (typeof superClass !== "function" && superClass !== null) {
2152
+ throw new TypeError("Super expression must either be null or a function");
2153
+ }
2154
+ subClass.prototype = Object.create(superClass && superClass.prototype, {
2155
+ constructor: {
2156
+ value: subClass,
2157
+ writable: true,
2158
+ configurable: true
2159
+ }
2160
+ });
2161
+ Object.defineProperty(subClass, "prototype", {
2162
+ writable: false
2163
+ });
2164
+ if (superClass) _setPrototypeOf(subClass, superClass);
2165
+ }
2166
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/assertThisInitialized.js
2167
+ function _assertThisInitialized(self) {
2168
+ if (self === void 0) {
2169
+ throw new ReferenceError("this hasn't been initialised - super() hasn't been called");
2170
+ }
2171
+ return self;
2172
+ }
2173
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/possibleConstructorReturn.js
2174
+
2175
+
2176
+ function _possibleConstructorReturn(self, call) {
2177
+ if (call && (_typeof(call) === "object" || typeof call === "function")) {
2178
+ return call;
2179
+ } else if (call !== void 0) {
2180
+ throw new TypeError("Derived constructors may only return object or undefined");
2181
+ }
2182
+ return _assertThisInitialized(self);
2183
+ }
2184
+ ;// CONCATENATED MODULE: ../../node_modules/@babel/runtime/helpers/esm/getPrototypeOf.js
2185
+ function _getPrototypeOf(o) {
2186
+ _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function _getPrototypeOf(o) {
2187
+ return o.__proto__ || Object.getPrototypeOf(o);
2188
+ };
2189
+ return _getPrototypeOf(o);
2190
+ }
2191
+ ;// CONCATENATED MODULE: external "vue-types"
2192
+ var external_vue_types_x = y => { var x = {}; __webpack_require__.d(x, y); return x; }
2193
+ var external_vue_types_y = x => () => x
2194
+ const external_vue_types_namespaceObject = external_vue_types_x({ ["createTypes"]: () => __WEBPACK_EXTERNAL_MODULE_vue_types_22de060a__.createTypes, ["string"]: () => __WEBPACK_EXTERNAL_MODULE_vue_types_22de060a__.string, ["toType"]: () => __WEBPACK_EXTERNAL_MODULE_vue_types_22de060a__.toType });
2195
+ ;// CONCATENATED MODULE: ../../packages/shared/src/vue-types.ts
2196
+
2197
+
2198
+
2199
+
2200
+
2201
+ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
2202
+ function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
2203
+ /*
2204
+ * Tencent is pleased to support the open source community by making
2205
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) available.
2206
+ *
2207
+ * Copyright (C) 2021 THL A29 Limited, a Tencent company. All rights reserved.
2208
+ *
2209
+ * 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition) is licensed under the MIT License.
2210
+ *
2211
+ * License for 蓝鲸智云PaaS平台社区版 (BlueKing PaaS Community Edition):
2212
+ *
2213
+ * ---------------------------------------------------
2214
+ * Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated
2215
+ * documentation files (the "Software"), to deal in the Software without restriction, including without limitation
2216
+ * the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and
2217
+ * to permit persons to whom the Software is furnished to do so, subject to the following conditions:
2218
+ *
2219
+ * The above copyright notice and this permission notice shall be included in all copies or substantial portions of
2220
+ * the Software.
2221
+ *
2222
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO
2223
+ * THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
2224
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF
2225
+ * CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS
2226
+ * IN THE SOFTWARE.
2227
+ */
2228
+
2229
+ var propTypesNS = (0,external_vue_types_namespaceObject.createTypes)({});
2230
+ // 用于创建字符串列表映射至 `K: V` 的函数
2231
+ function stringEnum(o) {
2232
+ return o.reduce(function (res, key) {
2233
+ res[key] = key;
2234
+ return res;
2235
+ }, Object.create(null));
2236
+ }
2237
+ var SizeEnum;
2238
+ (function (SizeEnum) {
2239
+ SizeEnum["SMALL"] = "small";
2240
+ SizeEnum["LARGE"] = "large";
2241
+ SizeEnum["DEFAULT"] = "default";
2242
+ })(SizeEnum || (SizeEnum = {}));
2243
+ var Placements;
2244
+ (function (Placements) {
2245
+ Placements["Top"] = "top";
2246
+ Placements["Left"] = "left";
2247
+ Placements["Right"] = "right";
2248
+ Placements["Bottom"] = "bottom";
2249
+ })(Placements || (Placements = {}));
2250
+ var RenderDirectiveEnum;
2251
+ (function (RenderDirectiveEnum) {
2252
+ RenderDirectiveEnum["IF"] = "if";
2253
+ RenderDirectiveEnum["SHOW"] = "show";
2254
+ })(RenderDirectiveEnum || (RenderDirectiveEnum = {}));
2255
+ function renderDirectiveType() {
2256
+ return (0,external_vue_types_namespaceObject.string)().def(RenderDirectiveEnum.SHOW);
2257
+ }
2258
+ var AlignEnum;
2259
+ (function (AlignEnum) {
2260
+ AlignEnum["LEFT"] = "left";
2261
+ AlignEnum["CENTER"] = "center";
2262
+ AlignEnum["RIGHT"] = "right";
2263
+ })(AlignEnum || (AlignEnum = {}));
2264
+ function alignType() {
2265
+ return (0,external_vue_types_namespaceObject.string)().def(AlignEnum.LEFT);
2266
+ }
2267
+ var ThemeEnum;
2268
+ (function (ThemeEnum) {
2269
+ ThemeEnum["PRIMARY"] = "primary";
2270
+ ThemeEnum["WARNING"] = "warning";
2271
+ ThemeEnum["SUCCESS"] = "success";
2272
+ ThemeEnum["DANGER"] = "danger";
2273
+ })(ThemeEnum || (ThemeEnum = {}));
2274
+ /** 弹层出现位置选项 */
2275
+ var PlacementEnum;
2276
+ (function (PlacementEnum) {
2277
+ PlacementEnum["AUTO"] = "auto";
2278
+ PlacementEnum["AUTO_START"] = "auto-start";
2279
+ PlacementEnum["AUTO_END"] = "auto-end";
2280
+ PlacementEnum["TOP"] = "top";
2281
+ PlacementEnum["RIGHT"] = "right";
2282
+ PlacementEnum["BOTTOM"] = "bottom";
2283
+ PlacementEnum["LEFT"] = "left";
2284
+ PlacementEnum["TOP_START"] = "top-start";
2285
+ PlacementEnum["TOP_END"] = "top-end";
2286
+ PlacementEnum["BOTTOM_START"] = "bottom-start";
2287
+ PlacementEnum["BOTTOM_END"] = "bottom-end";
2288
+ PlacementEnum["RIGHT_START"] = "right-start";
2289
+ PlacementEnum["RIGHT_END"] = "right-end";
2290
+ PlacementEnum["LEFT_START"] = "left-start";
2291
+ PlacementEnum["LEFT_END"] = "left-end";
2292
+ })(PlacementEnum || (PlacementEnum = {}));
2293
+ function placementType() {
2294
+ return (0,external_vue_types_namespaceObject.string)().def(PlacementEnum.BOTTOM);
2295
+ }
2296
+ /** 弹层触发选项 */
2297
+ var TriggerEnum;
2298
+ (function (TriggerEnum) {
2299
+ TriggerEnum["HOVER"] = "hover";
2300
+ TriggerEnum["CLICK"] = "click";
2301
+ TriggerEnum["MANUAL"] = "manual";
2302
+ })(TriggerEnum || (TriggerEnum = {}));
2303
+ function triggerType() {
2304
+ return (0,external_vue_types_namespaceObject.string)().def(TriggerEnum.HOVER);
2305
+ }
2306
+ /** 内容渲染类型:目前是在popover内容渲染时使用 */
2307
+ var RenderType;
2308
+ (function (RenderType) {
2309
+ RenderType["AUTO"] = "auto";
2310
+ RenderType["SHOWN"] = "shown";
2311
+ })(RenderType || (RenderType = {}));
2312
+ function renderType() {
2313
+ return (0,external_vue_types_namespaceObject.toType)('popRenderType', {}).def(RenderType.SHOWN);
2314
+ }
2315
+ var DialogTypeEnum;
2316
+ (function (DialogTypeEnum) {
2317
+ DialogTypeEnum["SHOW"] = "show";
2318
+ DialogTypeEnum["OPERATION"] = "operation";
2319
+ DialogTypeEnum["CONFIRM"] = "confirm";
2320
+ DialogTypeEnum["PROCESS"] = "process";
2321
+ })(DialogTypeEnum || (DialogTypeEnum = {}));
2322
+ function dialogTypeUnion() {
2323
+ return (0,external_vue_types_namespaceObject.toType)('dialogType', {
2324
+ "default": DialogTypeEnum.OPERATION
2325
+ });
2326
+ }
2327
+ var DirectionEnum;
2328
+ (function (DirectionEnum) {
2329
+ DirectionEnum["HORIZONTAL"] = "horizontal";
2330
+ DirectionEnum["VERTICAL"] = "vertical";
2331
+ })(DirectionEnum || (DirectionEnum = {}));
2332
+ function directionType() {
2333
+ return (0,external_vue_types_namespaceObject.toType)('direction', {}).def(DirectionEnum.HORIZONTAL);
2334
+ }
2335
+ var LineStyleEnum;
2336
+ (function (LineStyleEnum) {
2337
+ LineStyleEnum["DASHED"] = "dashed";
2338
+ LineStyleEnum["SOLID"] = "solid";
2339
+ })(LineStyleEnum || (LineStyleEnum = {}));
2340
+ function lineStyleType() {
2341
+ return (0,external_vue_types_namespaceObject.toType)('lineType', {}).def(LineStyleEnum.DASHED);
2342
+ }
2343
+ var TagThemeEnum;
2344
+ (function (TagThemeEnum) {
2345
+ TagThemeEnum["UNKNOWN"] = "";
2346
+ TagThemeEnum["SUCCESS"] = "success";
2347
+ TagThemeEnum["INFO"] = "info";
2348
+ TagThemeEnum["WARNING"] = "warning";
2349
+ TagThemeEnum["DANGER"] = "danger";
2350
+ })(TagThemeEnum || (TagThemeEnum = {}));
2351
+ function TagThemeType() {
2352
+ return (0,external_vue_types_namespaceObject.toType)('tagTheme', {}).def();
2353
+ }
2354
+ var InputBehaviorEnum;
2355
+ (function (InputBehaviorEnum) {
2356
+ InputBehaviorEnum["SIMPLICITY"] = "simplicity";
2357
+ InputBehaviorEnum["NORMAL"] = "normal";
2358
+ })(InputBehaviorEnum || (InputBehaviorEnum = {}));
2359
+ var ProgressStrokeLineCapEnum;
2360
+ (function (ProgressStrokeLineCapEnum) {
2361
+ ProgressStrokeLineCapEnum["BUTT"] = "butt";
2362
+ ProgressStrokeLineCapEnum["SQUARE"] = "square";
2363
+ ProgressStrokeLineCapEnum["ROUNDE"] = "round";
2364
+ })(ProgressStrokeLineCapEnum || (ProgressStrokeLineCapEnum = {}));
2365
+ var ProgressEnum;
2366
+ (function (ProgressEnum) {
2367
+ ProgressEnum["LINE"] = "line";
2368
+ ProgressEnum["CIRCLE"] = "circle";
2369
+ ProgressEnum["DASHBOARD"] = "dashboard";
2370
+ })(ProgressEnum || (ProgressEnum = {}));
2371
+ var SwitcherThemeEnum;
2372
+ (function (SwitcherThemeEnum) {
2373
+ SwitcherThemeEnum["SUCCESS"] = "success";
2374
+ SwitcherThemeEnum["PRIMARY"] = "primary";
2375
+ })(SwitcherThemeEnum || (SwitcherThemeEnum = {}));
2376
+ function SwitcherThemeType() {
2377
+ return (0,external_vue_types_namespaceObject.toType)('switcherTheme', {}).def(SwitcherThemeEnum.SUCCESS);
2378
+ }
2379
+ function ProgressStrokeLineCapType() {
2380
+ return (0,external_vue_types_namespaceObject.toType)('progressStrokeLineCap', {}).def(ProgressStrokeLineCapEnum.ROUNDE);
2381
+ }
2382
+ function ProgressType() {
2383
+ return (0,external_vue_types_namespaceObject.toType)('progress', {}).def(ProgressEnum.LINE);
2384
+ }
2385
+ function InputBehaviorType() {
2386
+ return (0,external_vue_types_namespaceObject.toType)('behavior', {}).def(InputBehaviorEnum.NORMAL);
2387
+ }
2388
+ var PropTypes = /*#__PURE__*/function (_propTypesNS) {
2389
+ _inherits(PropTypes, _propTypesNS);
2390
+ var _super = _createSuper(PropTypes);
2391
+ function PropTypes() {
2392
+ _classCallCheck(this, PropTypes);
2393
+ return _super.apply(this, arguments);
2394
+ }
2395
+ _createClass(PropTypes, null, [{
2396
+ key: "size",
2397
+ value: function size() {
2398
+ var defaultList = ['small', 'default', 'large'];
2399
+ return (0,external_vue_types_namespaceObject.toType)('Size', {
2400
+ validator: function validator(val) {
2401
+ if (!val || defaultList.includes(val)) {
2402
+ return true;
2403
+ }
2404
+ console.error("invalid theme, ".concat(val, ", the theme must be one of \u3010").concat(defaultList.join(' | '), "\u3011"));
2405
+ return false;
2406
+ },
2407
+ "default": 'default'
2408
+ });
2409
+ }
2410
+ }, {
2411
+ key: "theme",
2412
+ value: function theme() {
2413
+ var themes = ['primary', 'warning', 'success', 'danger'];
2414
+ return (0,external_vue_types_namespaceObject.toType)('Theme', {
2415
+ validator: function validator(val) {
2416
+ if (!val || themes.includes(val)) {
2417
+ return true;
2418
+ }
2419
+ console.error("invalid theme, ".concat(val, ", the theme must be one of \u3010").concat(themes.join(' | '), "\u3011"));
2420
+ return false;
2421
+ }
2422
+ });
2423
+ }
2424
+ }, {
2425
+ key: "placement",
2426
+ value: function placement() {
2427
+ var placements = ['top', 'left', 'right', 'bottom'];
2428
+ return (0,external_vue_types_namespaceObject.toType)('Placements', {
2429
+ validator: function validator(val) {
2430
+ if (!val || placements.includes(val)) {
2431
+ return true;
2432
+ }
2433
+ return false;
2434
+ },
2435
+ "default": 'top'
2436
+ });
2437
+ }
2438
+ }, {
2439
+ key: "style",
2440
+ value: function style() {
2441
+ return (0,external_vue_types_namespaceObject.toType)('Style', {
2442
+ type: [String, Object]
2443
+ });
2444
+ }
2445
+ }, {
2446
+ key: "position",
2447
+ value: function position() {
2448
+ var positions = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : ['top-left', 'top-right', 'bottom-left', 'bottom-right'];
2449
+ return (0,external_vue_types_namespaceObject.toType)('positions', {
2450
+ type: String,
2451
+ validator: function validator(val) {
2452
+ if (!val || positions.includes(val)) {
2453
+ return true;
2454
+ }
2455
+ console.error("invalid positions, ".concat(val, ", the position must be one of \u3010").concat(positions.join(' | '), "\u3011"));
2456
+ return false;
2457
+ },
2458
+ "default": 'top-center'
2459
+ });
2460
+ }
2461
+ }]);
2462
+ return PropTypes;
2463
+ }(propTypesNS);
2464
+ var SelectedTypeEnum;
2465
+ (function (SelectedTypeEnum) {
2466
+ SelectedTypeEnum["CHECKBOX"] = "checkbox";
2467
+ SelectedTypeEnum["CHECK"] = "check";
2468
+ })(SelectedTypeEnum || (SelectedTypeEnum = {}));
2469
+ function SelectedType() {
2470
+ return (0,external_vue_types_namespaceObject.toType)('selectedStyle', {}).def(SelectedTypeEnum.CHECK);
2471
+ }
2472
+ ;// CONCATENATED MODULE: ../../packages/shared/src/index.ts
2473
+
2474
+
2475
+
2476
+
2477
+
2478
+
2479
+
2480
+
2481
+
2482
+
2483
+
2484
+
2485
+ function classes(dynamicCls) {
2486
+ var constCls = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '';
2487
+ return Object.entries(dynamicCls).filter(function (entry) {
2488
+ return entry[1];
2489
+ }).map(function (entry) {
2490
+ return entry[0];
2491
+ }).join(' ').concat(constCls ? " ".concat(constCls) : '');
2492
+ }
2493
+ var EMPTY_OBJ = Object.create({});
2494
+ var noop = function noop() {};
2495
+ var renderEmptyVNode = function renderEmptyVNode() {
2496
+ return null;
2497
+ };
2498
+ var isEmptyObj = function isEmptyObj(target) {
2499
+ return Object.keys(target).length < 1;
2500
+ };
2501
+ var withInstall = function withInstall(component) {
2502
+ component.install = function (app) {
2503
+ var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},
2504
+ prefix = _ref.prefix;
2505
+ var pre = app.config.globalProperties.bkUIPrefix || prefix || 'Bk';
2506
+ app.component(pre + component.name, component);
2507
+ };
2508
+ return component;
2509
+ };
2510
+ var withInstallProps = function withInstallProps(component, childComponents) {
2511
+ var isProps = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
2512
+ var directive = arguments.length > 3 ? arguments[3] : undefined;
2513
+ component.install = function (app) {
2514
+ var _ref2 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},
2515
+ prefix = _ref2.prefix;
2516
+ var pre = app.config.globalProperties.bkUIPrefix || prefix || 'Bk';
2517
+ if (directive) {
2518
+ app.directive(pre + directive.name, directive.directive);
2519
+ }
2520
+ app.component(pre + component.name, component);
2521
+ !isProps && Object.values(childComponents).forEach(function (child) {
2522
+ app.component(pre + child.name, child);
2523
+ });
2524
+ };
2525
+ Object.keys(childComponents).forEach(function (key) {
2526
+ component[key] = childComponents[key];
2527
+ });
2528
+ return component;
2529
+ };
2530
+ /**
2531
+ * 解析当前组件ClassName,自动添加前缀
2532
+ * @param clsName 当前ClassName
2533
+ * @param prefix 前缀,默认为bk
2534
+ * @returns prefix-clsName
2535
+ */
2536
+ function resolveClassName(clsName) {
2537
+ var prefix = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : 'bk';
2538
+ return "".concat(prefix, "-").concat(clsName);
2539
+ }
2540
+ /**
2541
+ * 函数防抖
2542
+ * @param {*} fn 执行的函数
2543
+ * @param {*} delay 延时时间
2544
+ * @param {*} immediate 是否立即执行
2545
+ */
2546
+ function debounce() {
2547
+ var delay = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 300;
2548
+ var fn = arguments.length > 1 ? arguments[1] : undefined;
2549
+ var immediate = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : false;
2550
+ var timeout;
2551
+ var result;
2552
+ var debounced = function debounced() {
2553
+ // eslint-disable-next-line @typescript-eslint/no-this-alias
2554
+ var ctx = this; // 当前上下文
2555
+ // eslint-disable-next-line prefer-rest-params
2556
+ var args = arguments; // fn的参数
2557
+ // 取消之前的延时调用
2558
+ if (timeout) clearTimeout(timeout);
2559
+ if (immediate) {
2560
+ var applyImmediate = !timeout; // 是否执行过
2561
+ timeout = setTimeout(function () {
2562
+ timeout = null; // 标志是否执行过,与clearTimeout有区别,clearTimeout之后timeout不为null而是一个系统分配的队列ID
2563
+ }, delay);
2564
+ if (applyImmediate) result = fn.apply(ctx, args); // 立即调用
2565
+ } else {
2566
+ timeout = setTimeout(function () {
2567
+ fn.apply(ctx, args);
2568
+ }, delay);
2569
+ }
2570
+ return result;
2571
+ };
2572
+ debounced.cancel = function () {
2573
+ clearTimeout(timeout);
2574
+ timeout = null;
2575
+ };
2576
+ return debounced;
2577
+ }
2578
+ /**
2579
+ * 过滤(去除)对象中的某个属性
2580
+ * @param data 需要处理的对象
2581
+ * @param filter 过滤关键字
2582
+ * @returns object 去除属性之后的对象
2583
+ */
2584
+ function filterProperty(data, filter) {
2585
+ return JSON.parse(JSON.stringify(data, function (key, value) {
2586
+ if (filter.includes(key)) {
2587
+ return undefined;
2588
+ }
2589
+ return value;
2590
+ }));
2591
+ }
2592
+ function arrayEqual() {
2593
+ var arr1 = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : [];
2594
+ var arr2 = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
2595
+ if (arr1.length !== arr2.length) {
2596
+ return false;
2597
+ }
2598
+ for (var i = 0; i < arr1.length; i++) {
2599
+ if (Array.isArray(arr1[i])) {
2600
+ return arrayEqual(arr1[i], arr2[i]);
2601
+ }
2602
+ if (arr1[i] !== arr2[i]) {
2603
+ return false;
2604
+ }
2605
+ }
2606
+ return true;
2607
+ }
2608
+ var __webpack_exports__AlignEnum = __webpack_exports__.oY;
2609
+ var __webpack_exports__BKLAYERD_INDEX_EFAULT_VALUE = __webpack_exports__.p3;
2610
+ var __webpack_exports__BKLAYERTYPE = __webpack_exports__.Ql;
2611
+ var __webpack_exports__BKPopIndexManager = __webpack_exports__.Eo;
2612
+ var __webpack_exports__BKPopover = __webpack_exports__.mZ;
2613
+ var __webpack_exports__BkMaskManager = __webpack_exports__.Wg;
2614
+ var __webpack_exports__DialogTypeEnum = __webpack_exports__._D;
2615
+ var __webpack_exports__DirectionEnum = __webpack_exports__.dq;
2616
+ var __webpack_exports__EMPTY_OBJ = __webpack_exports__.kT;
2617
+ var __webpack_exports__InputBehaviorEnum = __webpack_exports__.WF;
2618
+ var __webpack_exports__InputBehaviorType = __webpack_exports__.Gl;
2619
+ var __webpack_exports__LineStyleEnum = __webpack_exports__.VS;
2620
+ var __webpack_exports__PlacementEnum = __webpack_exports__.Um;
2621
+ var __webpack_exports__Placements = __webpack_exports__._h;
2622
+ var __webpack_exports__ProgressEnum = __webpack_exports__.rU;
2623
+ var __webpack_exports__ProgressStrokeLineCapEnum = __webpack_exports__._q;
2624
+ var __webpack_exports__ProgressStrokeLineCapType = __webpack_exports__.Hl;
2625
+ var __webpack_exports__ProgressType = __webpack_exports__.Mc;
2626
+ var __webpack_exports__PropTypes = __webpack_exports__.ng;
2627
+ var __webpack_exports__RenderDirectiveEnum = __webpack_exports__.Pi;
2628
+ var __webpack_exports__RenderType = __webpack_exports__.y2;
2629
+ var __webpack_exports__SelectedType = __webpack_exports__.qt;
2630
+ var __webpack_exports__SelectedTypeEnum = __webpack_exports__.aL;
2631
+ var __webpack_exports__SizeEnum = __webpack_exports__.mO;
2632
+ var __webpack_exports__SwitcherThemeEnum = __webpack_exports__.BZ;
2633
+ var __webpack_exports__SwitcherThemeType = __webpack_exports__.p;
2634
+ var __webpack_exports__TagThemeEnum = __webpack_exports__.XR;
2635
+ var __webpack_exports__TagThemeType = __webpack_exports__.gg;
2636
+ var __webpack_exports__ThemeEnum = __webpack_exports__.bY;
2637
+ var __webpack_exports__TriggerEnum = __webpack_exports__.os;
2638
+ var __webpack_exports__alignType = __webpack_exports__.WW;
2639
+ var __webpack_exports__arrayEqual = __webpack_exports__.h6;
2640
+ var __webpack_exports__bKMaskManager = __webpack_exports__.Lx;
2641
+ var __webpack_exports__bkPopIndexManager = __webpack_exports__.aR;
2642
+ var __webpack_exports__bkZIndexManager = __webpack_exports__.ue;
2643
+ var __webpack_exports__capitalize = __webpack_exports__.kC;
2644
+ var __webpack_exports__checkOverflow = __webpack_exports__.ao;
2645
+ var __webpack_exports__classes = __webpack_exports__.Sh;
2646
+ var __webpack_exports__clone = __webpack_exports__.d9;
2647
+ var __webpack_exports__debounce = __webpack_exports__.Ds;
2648
+ var __webpack_exports__dialogTypeUnion = __webpack_exports__.ou;
2649
+ var __webpack_exports__directionType = __webpack_exports__.zo;
2650
+ var __webpack_exports__elementsEqual = __webpack_exports__.cA;
2651
+ var __webpack_exports__filterProperty = __webpack_exports__.w$;
2652
+ var __webpack_exports__finiteOrDefault = __webpack_exports__.b_;
2653
+ var __webpack_exports__formItemKey = __webpack_exports__.xE;
2654
+ var __webpack_exports__formKey = __webpack_exports__.vh;
2655
+ var __webpack_exports__getPopContainerId = __webpack_exports__.ks;
2656
+ var __webpack_exports__hasOverflowEllipsis = __webpack_exports__.Hv;
2657
+ var __webpack_exports__isArray = __webpack_exports__.kJ;
2658
+ var __webpack_exports__isElement = __webpack_exports__.kK;
2659
+ var __webpack_exports__isEmpty = __webpack_exports__.xb;
2660
+ var __webpack_exports__isEmptyObj = __webpack_exports__.SI;
2661
+ var __webpack_exports__isFinite = __webpack_exports__.xV;
2662
+ var __webpack_exports__isNullOrUndef = __webpack_exports__.sS;
2663
+ var __webpack_exports__isObject = __webpack_exports__.Kn;
2664
+ var __webpack_exports__lineStyleType = __webpack_exports__.zW;
2665
+ var __webpack_exports__maybeShowTooltip = __webpack_exports__.oq;
2666
+ var __webpack_exports__merge = __webpack_exports__.TS;
2667
+ var __webpack_exports__mergeIf = __webpack_exports__.NG;
2668
+ var __webpack_exports__mergerFn = __webpack_exports__.WC;
2669
+ var __webpack_exports__mergerIfFn = __webpack_exports__.Zd;
2670
+ var __webpack_exports__noop = __webpack_exports__.ZT;
2671
+ var __webpack_exports__observerResize = __webpack_exports__.z3;
2672
+ var __webpack_exports__off = __webpack_exports__.S1;
2673
+ var __webpack_exports__on = __webpack_exports__.on;
2674
+ var __webpack_exports__placementType = __webpack_exports__.Tf;
2675
+ var __webpack_exports__random = __webpack_exports__.MX;
2676
+ var __webpack_exports__renderDirectiveType = __webpack_exports__.OB;
2677
+ var __webpack_exports__renderEmptyVNode = __webpack_exports__.Ay;
2678
+ var __webpack_exports__renderType = __webpack_exports__.wB;
2679
+ var __webpack_exports__resolveClassName = __webpack_exports__.h5;
2680
+ var __webpack_exports__scrollTop = __webpack_exports__.SM;
2681
+ var __webpack_exports__scrollbarWidth = __webpack_exports__.LF;
2682
+ var __webpack_exports__stringEnum = __webpack_exports__.b;
2683
+ var __webpack_exports__triggerType = __webpack_exports__._7;
2684
+ var __webpack_exports__useForm = __webpack_exports__.cI;
2685
+ var __webpack_exports__useFormItem = __webpack_exports__.A9;
2686
+ var __webpack_exports__valueOrDefault = __webpack_exports__.Be;
2687
+ var __webpack_exports__withInstall = __webpack_exports__.nz;
2688
+ var __webpack_exports__withInstallProps = __webpack_exports__.B;
2689
+ export { __webpack_exports__AlignEnum as AlignEnum, __webpack_exports__BKLAYERD_INDEX_EFAULT_VALUE as BKLAYERD_INDEX_EFAULT_VALUE, __webpack_exports__BKLAYERTYPE as BKLAYERTYPE, __webpack_exports__BKPopIndexManager as BKPopIndexManager, __webpack_exports__BKPopover as BKPopover, __webpack_exports__BkMaskManager as BkMaskManager, __webpack_exports__DialogTypeEnum as DialogTypeEnum, __webpack_exports__DirectionEnum as DirectionEnum, __webpack_exports__EMPTY_OBJ as EMPTY_OBJ, __webpack_exports__InputBehaviorEnum as InputBehaviorEnum, __webpack_exports__InputBehaviorType as InputBehaviorType, __webpack_exports__LineStyleEnum as LineStyleEnum, __webpack_exports__PlacementEnum as PlacementEnum, __webpack_exports__Placements as Placements, __webpack_exports__ProgressEnum as ProgressEnum, __webpack_exports__ProgressStrokeLineCapEnum as ProgressStrokeLineCapEnum, __webpack_exports__ProgressStrokeLineCapType as ProgressStrokeLineCapType, __webpack_exports__ProgressType as ProgressType, __webpack_exports__PropTypes as PropTypes, __webpack_exports__RenderDirectiveEnum as RenderDirectiveEnum, __webpack_exports__RenderType as RenderType, __webpack_exports__SelectedType as SelectedType, __webpack_exports__SelectedTypeEnum as SelectedTypeEnum, __webpack_exports__SizeEnum as SizeEnum, __webpack_exports__SwitcherThemeEnum as SwitcherThemeEnum, __webpack_exports__SwitcherThemeType as SwitcherThemeType, __webpack_exports__TagThemeEnum as TagThemeEnum, __webpack_exports__TagThemeType as TagThemeType, __webpack_exports__ThemeEnum as ThemeEnum, __webpack_exports__TriggerEnum as TriggerEnum, __webpack_exports__alignType as alignType, __webpack_exports__arrayEqual as arrayEqual, __webpack_exports__bKMaskManager as bKMaskManager, __webpack_exports__bkPopIndexManager as bkPopIndexManager, __webpack_exports__bkZIndexManager as bkZIndexManager, __webpack_exports__capitalize as capitalize, __webpack_exports__checkOverflow as checkOverflow, __webpack_exports__classes as classes, __webpack_exports__clone as clone, __webpack_exports__debounce as debounce, __webpack_exports__dialogTypeUnion as dialogTypeUnion, __webpack_exports__directionType as directionType, __webpack_exports__elementsEqual as elementsEqual, __webpack_exports__filterProperty as filterProperty, __webpack_exports__finiteOrDefault as finiteOrDefault, __webpack_exports__formItemKey as formItemKey, __webpack_exports__formKey as formKey, __webpack_exports__getPopContainerId as getPopContainerId, __webpack_exports__hasOverflowEllipsis as hasOverflowEllipsis, __webpack_exports__isArray as isArray, __webpack_exports__isElement as isElement, __webpack_exports__isEmpty as isEmpty, __webpack_exports__isEmptyObj as isEmptyObj, __webpack_exports__isFinite as isFinite, __webpack_exports__isNullOrUndef as isNullOrUndef, __webpack_exports__isObject as isObject, __webpack_exports__lineStyleType as lineStyleType, __webpack_exports__maybeShowTooltip as maybeShowTooltip, __webpack_exports__merge as merge, __webpack_exports__mergeIf as mergeIf, __webpack_exports__mergerFn as mergerFn, __webpack_exports__mergerIfFn as mergerIfFn, __webpack_exports__noop as noop, __webpack_exports__observerResize as observerResize, __webpack_exports__off as off, __webpack_exports__on as on, __webpack_exports__placementType as placementType, __webpack_exports__random as random, __webpack_exports__renderDirectiveType as renderDirectiveType, __webpack_exports__renderEmptyVNode as renderEmptyVNode, __webpack_exports__renderType as renderType, __webpack_exports__resolveClassName as resolveClassName, __webpack_exports__scrollTop as scrollTop, __webpack_exports__scrollbarWidth as scrollbarWidth, __webpack_exports__stringEnum as stringEnum, __webpack_exports__triggerType as triggerType, __webpack_exports__useForm as useForm, __webpack_exports__useFormItem as useFormItem, __webpack_exports__valueOrDefault as valueOrDefault, __webpack_exports__withInstall as withInstall, __webpack_exports__withInstallProps as withInstallProps };