@cldemo/ui-kit 1.0.17 → 1.1.1

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 (846) hide show
  1. package/COMPONENT_CATALOG.md +5 -5
  2. package/README.md +15 -69
  3. package/buildLibs/{mobile/BallColor4-DpnfFrBL.js → all/BallColor4-CYDMNYIL.js} +1 -1
  4. package/buildLibs/all/{BallColor4-DkQt6rSf.cjs → BallColor4-CaqTfMcX.cjs} +1 -1
  5. package/buildLibs/all/{ToastRing-B-erJp2o.js → ToastRing-BW0hddZN.js} +1 -1
  6. package/buildLibs/{web/ToastRing-DKVLp5rZ.cjs → all/ToastRing-DqiGLTLN.cjs} +1 -1
  7. package/buildLibs/all/{Video-BwDG93FI.cjs → Video-BV-GRW4X.cjs} +1 -1
  8. package/buildLibs/all/{Video-CMkViuqG.js → Video-Bbk0_YWw.js} +1 -1
  9. package/buildLibs/all/index-Cap0WJgK.cjs +14 -0
  10. package/buildLibs/all/{index-DA_I2NVO.js → index-sPYdePtz.js} +17012 -16694
  11. package/buildLibs/all/index.cjs +1 -1
  12. package/buildLibs/all/index.css +1 -1
  13. package/buildLibs/all/index.js +75 -75
  14. package/buildLibs/common/Common/Element/Event/drag.d.ts +7 -1
  15. package/buildLibs/common/Common/Tools/device.d.ts +2 -2
  16. package/buildLibs/common/Common/base.d.ts +2 -2
  17. package/buildLibs/common/Common/browserProgress.d.ts +3 -1
  18. package/buildLibs/common/Common/globalConfig.d.ts +18 -3
  19. package/buildLibs/common/Element/Event/drag.cjs +1 -1
  20. package/buildLibs/common/Element/Event/drag.js +26 -14
  21. package/buildLibs/common/Tools/device.cjs +1 -1
  22. package/buildLibs/common/Tools/device.js +27 -27
  23. package/buildLibs/common/axios.cjs +1 -1
  24. package/buildLibs/common/axios.js +20 -14
  25. package/buildLibs/common/base.cjs +1 -1
  26. package/buildLibs/common/base.js +10 -10
  27. package/buildLibs/common/browserProgress.cjs +1 -1
  28. package/buildLibs/common/browserProgress.js +24 -15
  29. package/buildLibs/common/day.js +14 -5
  30. package/buildLibs/{web/BallColor4-BahMtWFj.cjs → mobile/BallColor4-C7lQaABY.cjs} +1 -1
  31. package/buildLibs/{all/BallColor4-UHANgP7D.js → mobile/BallColor4-DogqtiHo.js} +1 -1
  32. package/buildLibs/mobile/{ToastRing-hBf9THbv.cjs → ToastRing-BQAASeWu.cjs} +1 -1
  33. package/buildLibs/mobile/{ToastRing-Dj7ooJtL.js → ToastRing-ZSOlED5s.js} +1 -1
  34. package/buildLibs/mobile/{index-BugOQA6Z.js → index-Bh4jt080.js} +7986 -7774
  35. package/buildLibs/mobile/index-DmdxP8hd.cjs +10 -0
  36. package/buildLibs/mobile/index.cjs +1 -1
  37. package/buildLibs/mobile/index.css +1 -1
  38. package/buildLibs/mobile/index.js +67 -67
  39. package/buildLibs/modules/actionSheet.js +5 -5
  40. package/buildLibs/modules/anchorNav.js +4 -4
  41. package/buildLibs/modules/backTop.js +3 -3
  42. package/buildLibs/modules/badge.js +1 -1
  43. package/buildLibs/modules/banner.js +4 -4
  44. package/buildLibs/modules/breadcrumb.js +3 -3
  45. package/buildLibs/modules/button.js +1 -1
  46. package/buildLibs/modules/calendar.js +32 -32
  47. package/buildLibs/modules/calendarM.js +61 -65
  48. package/buildLibs/modules/callout.js +2 -2
  49. package/buildLibs/modules/card.js +1 -1
  50. package/buildLibs/modules/cardColor.js +2 -2
  51. package/buildLibs/modules/cell.js +3 -3
  52. package/buildLibs/modules/cellSwipe.js +2 -2
  53. package/buildLibs/modules/checkbox.js +1 -1
  54. package/buildLibs/modules/checkboxOne.js +1 -1
  55. package/buildLibs/modules/clipboard.js +1 -1
  56. package/buildLibs/modules/codeLegend.js +3 -3
  57. package/buildLibs/modules/codeLegendM.js +4 -4
  58. package/buildLibs/modules/collapse.js +3 -3
  59. package/buildLibs/modules/colorPicker.js +8 -8
  60. package/buildLibs/modules/countDown.js +2 -2
  61. package/buildLibs/modules/cropper.js +1 -1
  62. package/buildLibs/modules/cropperM.js +6 -6
  63. package/buildLibs/modules/cropperPreview.js +6 -6
  64. package/buildLibs/modules/darg.js +2 -2
  65. package/buildLibs/modules/dateTime.js +1 -1
  66. package/buildLibs/modules/divider.js +2 -80
  67. package/buildLibs/modules/dropdownMenu.js +110 -48
  68. package/buildLibs/modules/dropdownMenuItem.js +44 -27
  69. package/buildLibs/modules/dropdownMenuM.js +2 -2
  70. package/buildLibs/modules/dropdownMenuMItem.js +4 -4
  71. package/buildLibs/modules/dropdownPopup.js +3 -3
  72. package/buildLibs/modules/echarts.js +1 -1
  73. package/buildLibs/modules/echartsLineAxisTag.js +4 -4
  74. package/buildLibs/modules/ellipsis.js +1 -1
  75. package/buildLibs/modules/empty.js +2 -2
  76. package/buildLibs/modules/fileUpload.js +1 -1
  77. package/buildLibs/modules/floatBubble.cjs +5 -0
  78. package/buildLibs/modules/floatBubble.d.ts +1 -0
  79. package/buildLibs/modules/{floatingBubble.js → floatBubble.js} +39 -39
  80. package/buildLibs/modules/floatPanel.cjs +5 -0
  81. package/buildLibs/modules/floatPanel.d.ts +1 -0
  82. package/buildLibs/modules/{floatingPanel.js → floatPanel.js} +96 -96
  83. package/buildLibs/modules/form.js +1 -1
  84. package/buildLibs/modules/formGroupBtns.js +3 -3
  85. package/buildLibs/modules/formGroupHorizontal.js +1 -1
  86. package/buildLibs/modules/formGroupVertical.js +2 -2
  87. package/buildLibs/modules/formValidate.js +1 -1
  88. package/buildLibs/modules/framePhone.js +1 -1
  89. package/buildLibs/modules/grid.js +3 -3
  90. package/buildLibs/modules/iconFont.js +1 -1
  91. package/buildLibs/modules/image.js +1 -1
  92. package/buildLibs/modules/indexBar.js +2 -2
  93. package/buildLibs/modules/input.js +1 -1
  94. package/buildLibs/modules/inputCaptcha.js +3 -3
  95. package/buildLibs/modules/inputNumber.js +1 -1
  96. package/buildLibs/modules/inputNumberStepper.js +1 -1
  97. package/buildLibs/modules/inputPassword.js +4 -4
  98. package/buildLibs/modules/inputPin.cjs +5 -0
  99. package/buildLibs/modules/inputPin.d.ts +1 -0
  100. package/buildLibs/modules/inputPin.js +182 -0
  101. package/buildLibs/modules/inputSearch.js +1 -1
  102. package/buildLibs/modules/inputTag.js +1 -1
  103. package/buildLibs/modules/inputTextarea.js +1 -1
  104. package/buildLibs/modules/link.js +1 -1
  105. package/buildLibs/modules/load.js +1 -1
  106. package/buildLibs/modules/loadFullCenter.js +2 -2
  107. package/buildLibs/modules/loadIng.js +1 -1
  108. package/buildLibs/modules/loadScreen.js +4 -4
  109. package/buildLibs/modules/loadWarp.js +3 -3
  110. package/buildLibs/modules/modal.js +1 -1
  111. package/buildLibs/modules/navBar.js +3 -3
  112. package/buildLibs/modules/noticeBar.js +19 -19
  113. package/buildLibs/modules/notifyM.js +199 -97
  114. package/buildLibs/modules/numberKeyboard.js +36 -36
  115. package/buildLibs/modules/numberRoll.js +2 -2
  116. package/buildLibs/modules/overlay.js +1 -1
  117. package/buildLibs/modules/paginate.js +1 -1
  118. package/buildLibs/modules/picker.js +1 -1
  119. package/buildLibs/modules/pickerArea.cjs +5 -0
  120. package/buildLibs/modules/pickerArea.d.ts +1 -0
  121. package/buildLibs/modules/pickerArea.js +255 -0
  122. package/buildLibs/modules/pickerCascader.js +4 -4
  123. package/buildLibs/modules/pickerDate.js +71 -71
  124. package/buildLibs/modules/pickerTime.js +56 -56
  125. package/buildLibs/modules/popup.js +1 -1
  126. package/buildLibs/modules/portlet.js +2 -2
  127. package/buildLibs/modules/previewExample.js +1 -1
  128. package/buildLibs/modules/progress.js +3 -3
  129. package/buildLibs/modules/pullToRefresh.js +1 -1
  130. package/buildLibs/modules/radio.js +1 -1
  131. package/buildLibs/modules/radioOne.js +1 -1
  132. package/buildLibs/modules/rate.js +3 -3
  133. package/buildLibs/modules/scrollCard.js +220 -200
  134. package/buildLibs/modules/scrollXFence.js +1 -1
  135. package/buildLibs/modules/select.js +1 -1
  136. package/buildLibs/modules/selectCascade.js +1 -1
  137. package/buildLibs/modules/selectMove.js +8 -8
  138. package/buildLibs/modules/selectTag.js +1 -1
  139. package/buildLibs/modules/selectTree.js +6 -6
  140. package/buildLibs/modules/sharePanel.cjs +5 -0
  141. package/buildLibs/modules/sharePanel.d.ts +1 -0
  142. package/buildLibs/modules/{shareSheet.js → sharePanel.js} +52 -52
  143. package/buildLibs/modules/shared/{BallColor4-DLGMFp7g.js → BallColor4-Dw8bQzLW.js} +1 -1
  144. package/buildLibs/{utils/Shared/Base.vue_vue_type_script_setup_true_lang-Z6sD7O6T.js → modules/shared/Base.vue_vue_type_script_setup_true_lang-DaZg8_tt.js} +81 -70
  145. package/buildLibs/modules/shared/Column.vue_vue_type_script_setup_true_lang-rT_ICHhO.js +174 -0
  146. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-B8nfrdHt.js → Index.vue_vue_type_script_setup_true_lang-5TIkYSxG.js} +2 -2
  147. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-Axa69KHA.js +939 -0
  148. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-DZRko_Hq.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-B9M3m9HE.js} +6 -6
  149. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-CG4BhqfV.js → Index.vue_vue_type_script_setup_true_lang-BkR-sQJt.js} +2 -2
  150. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-EjdgvHF5.js → Index.vue_vue_type_script_setup_true_lang-C1bquiI9.js} +2 -2
  151. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-BvcWTBEv.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-C2EI2VnJ.js} +4 -4
  152. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-BH8ejOuv.js → Index.vue_vue_type_script_setup_true_lang-C5i17oB9.js} +5 -5
  153. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-1gL-yfzx.js → Index.vue_vue_type_script_setup_true_lang-CQ-_RRa-.js} +3 -3
  154. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-CkUfNTb6.js → Index.vue_vue_type_script_setup_true_lang-CSV3c0_h.js} +3 -3
  155. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-x28PWOid.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-CVSATrNA.js} +3 -3
  156. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-XWxNmuC2.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-CYRh_OzP.js} +5 -5
  157. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-BESTuFHY.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-CoQ8bldZ.js} +2 -2
  158. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-DTtbdgoO.js → Index.vue_vue_type_script_setup_true_lang-Cp5rYwnC.js} +28 -25
  159. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-CqIT3zxY.js +82 -0
  160. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-D0LqAmBY.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-D0_5BgAN.js} +9 -9
  161. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-e41SaSkr.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-D0oA7-eQ.js} +2 -2
  162. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-CMK-TwEo.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-D0s2DEcR.js} +13 -13
  163. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-D5akRc9d.js +380 -0
  164. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-BgFzdwmp.js → Index.vue_vue_type_script_setup_true_lang-D6gcg5sW.js} +46 -46
  165. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-Cukt_Rkd.js → Index.vue_vue_type_script_setup_true_lang-D8H72Fc9.js} +2 -2
  166. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-DEi_COkc.js → Index.vue_vue_type_script_setup_true_lang-DB10zsLZ.js} +5 -5
  167. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-BZSJp1GF.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-DBo8NT25.js} +3 -3
  168. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-bmKRziC6.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-DG98f73r.js} +3 -3
  169. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-DKe5rvrv.js +213 -0
  170. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-Dt9cW3rp.js → Index.vue_vue_type_script_setup_true_lang-DWJ1bJbw.js} +8 -8
  171. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-iMbGY-sX.js → Index.vue_vue_type_script_setup_true_lang-DX5H6qmm.js} +108 -108
  172. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-CVBKgYfQ.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-DapaVMSO.js} +2 -2
  173. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-B0I5VIPk.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-DkCTGpCo.js} +3 -3
  174. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-Cy8lSIYw.js → Index.vue_vue_type_script_setup_true_lang-DpEMLNQd.js} +23 -18
  175. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-Bn3j7iE7.js → Index.vue_vue_type_script_setup_true_lang-DtsjjKBG.js} +6 -6
  176. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-BBVM_RnZ.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-Dy6W7sIl.js} +5 -5
  177. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-B9byrXKx.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-GSyMXu17.js} +22 -22
  178. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-BZHTSznV.js → Index.vue_vue_type_script_setup_true_lang-N3rQdrH6.js} +47 -50
  179. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-B0wTFrxX.js → Index.vue_vue_type_script_setup_true_lang-Ohuu4j9n.js} +54 -49
  180. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-3KP-rPyM.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-UCm0Csto.js} +4 -4
  181. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-DcAEnje5.js → Index.vue_vue_type_script_setup_true_lang-X9pUZWHF.js} +1 -1
  182. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-BBiQbTaJ.js → Index.vue_vue_type_script_setup_true_lang-dwaD7E4N.js} +101 -98
  183. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-B7H-n7gl.js → Index.vue_vue_type_script_setup_true_lang-o-s4A6rG.js} +5 -5
  184. package/buildLibs/{utils/Shared/Ing.vue_vue_type_script_setup_true_lang-DprFXKbk.js → modules/shared/Ing.vue_vue_type_script_setup_true_lang-Bnc9BIaT.js} +3 -3
  185. package/buildLibs/modules/shared/{List.vue_vue_type_script_setup_true_lang-8UJTbHh3.js → List.vue_vue_type_script_setup_true_lang-1SlAzQsU.js} +4 -4
  186. package/buildLibs/modules/shared/{One.vue_vue_type_script_setup_true_lang-BiqtUBqP.js → One.vue_vue_type_script_setup_true_lang-BkfhsInn.js} +4 -4
  187. package/buildLibs/modules/shared/{One.vue_vue_type_script_setup_true_lang-C4lt4POB.js → One.vue_vue_type_script_setup_true_lang-rkbdx8Aq.js} +4 -4
  188. package/buildLibs/modules/shared/{Popup.vue_vue_type_script_setup_true_lang-CeZQDd0z.js → Popup.vue_vue_type_script_setup_true_lang-YVBgERG9.js} +3 -3
  189. package/buildLibs/{utils/Shared/ToastRing-CqDvSDSQ.js → modules/shared/ToastRing-DZoETg0y.js} +1 -1
  190. package/buildLibs/modules/shared/{Validate.vue_vue_type_script_setup_true_lang-Clw81Klm.js → Validate.vue_vue_type_script_setup_true_lang-FZ6qiA6w.js} +6 -6
  191. package/buildLibs/modules/shared/{base-C5l51ld_.js → base-fr2I80sU.js} +10 -10
  192. package/buildLibs/modules/shared/{day-Bfolruvp.js → day-B3hhmAm_.js} +15 -6
  193. package/buildLibs/modules/shared/drag-BBk0X740.js +53 -0
  194. package/buildLibs/modules/shared/focusTrap-BYhFRjSm.js +82 -0
  195. package/buildLibs/modules/shared/{index-wdK75uN2.js → index-B477PjJ3.js} +1 -1
  196. package/buildLibs/modules/shared/{index-Clwouce_.js → index-C91QEnIE.js} +2 -2
  197. package/buildLibs/modules/shared/{language-TSK4pJka.js → language-pMmux6Js.js} +2 -2
  198. package/buildLibs/modules/shared/{resize-5FVpVwWr.js → resize-CyrJxi6F.js} +2 -2
  199. package/buildLibs/modules/shared/{use-Cn_GITQ7.js → use-CRdlCpEV.js} +1 -1
  200. package/buildLibs/modules/sideMenu.js +4 -4
  201. package/buildLibs/modules/sidebar.js +2 -2
  202. package/buildLibs/modules/sidebarSelect.js +3 -3
  203. package/buildLibs/modules/signature.js +34 -34
  204. package/buildLibs/modules/slider.js +1 -1
  205. package/buildLibs/modules/steps.js +45 -41
  206. package/buildLibs/modules/swipe.js +2 -2
  207. package/buildLibs/modules/switchery.js +3 -3
  208. package/buildLibs/modules/tabM.js +2 -2
  209. package/buildLibs/modules/tabbar.js +4 -4
  210. package/buildLibs/modules/table.js +12 -12
  211. package/buildLibs/modules/tableEdit.js +2 -2
  212. package/buildLibs/modules/tableSimple.js +2 -2
  213. package/buildLibs/modules/tabs.js +5 -5
  214. package/buildLibs/modules/tags.js +1 -1
  215. package/buildLibs/modules/textHighlight.js +2 -2
  216. package/buildLibs/modules/toast.js +4 -4
  217. package/buildLibs/modules/tree.js +1 -1
  218. package/buildLibs/modules/ui-kit.css +1 -1
  219. package/buildLibs/modules/waterfall.js +3 -3
  220. package/buildLibs/modules/waterfallImage.js +1 -1
  221. package/buildLibs/modules/watermark.js +2 -2
  222. package/buildLibs/modules/weekHour.js +5 -5
  223. package/buildLibs/modules/xEditable.js +21 -21
  224. package/buildLibs/resolver/index.cjs +1 -1
  225. package/buildLibs/resolver/index.js +5 -5
  226. package/buildLibs/styles/Common/Overlay-base.css +59 -0
  227. package/buildLibs/styles/Common/Token.css +135 -122
  228. package/buildLibs/styles/Common/meta.json +19 -2
  229. package/buildLibs/styles/Element/ClButton.css +0 -31
  230. package/buildLibs/styles/Element/ClDivider.css +53 -7
  231. package/buildLibs/styles/Element/ClFormGroupBtns.css +5 -5
  232. package/buildLibs/styles/Element/ClFormGroupHorizontal.css +5 -5
  233. package/buildLibs/styles/Element/ClLoadFullCenter.css +0 -31
  234. package/buildLibs/styles/Element/ClLoadScreen.css +0 -31
  235. package/buildLibs/styles/Element/ClModal.css +0 -40
  236. package/buildLibs/styles/Element/ClTags.css +123 -28
  237. package/buildLibs/styles/Mobile/ClCodeLegendM.css +5 -5
  238. package/buildLibs/styles/Mobile/ClCropperM.css +2 -0
  239. package/buildLibs/styles/Mobile/ClFloatBubble.css +18 -0
  240. package/buildLibs/styles/Mobile/ClFloatPanel.css +86 -0
  241. package/buildLibs/styles/Mobile/ClInputPin.css +104 -0
  242. package/buildLibs/styles/Mobile/ClNoticeBar.css +5 -5
  243. package/buildLibs/styles/Mobile/ClNotifyM.css +50 -2
  244. package/buildLibs/styles/Mobile/ClNumberKeyboard.css +3 -31
  245. package/buildLibs/styles/Mobile/ClPickerArea.css +286 -0
  246. package/buildLibs/styles/Mobile/ClPickerCascader.css +17 -5
  247. package/buildLibs/styles/Mobile/ClPullToRefresh.css +1 -1
  248. package/buildLibs/styles/Mobile/ClScrollCard.css +159 -11
  249. package/buildLibs/styles/Mobile/ClSharePanel.css +202 -0
  250. package/buildLibs/styles/Mobile/ClSidebarSelect.css +5 -0
  251. package/buildLibs/styles/Mobile/ClSteps.css +24 -14
  252. package/buildLibs/styles/Mobile/ClTextHighlight.css +2 -2
  253. package/buildLibs/styles/Mobile/__provide__/NotifyM.css +50 -2
  254. package/buildLibs/styles/Web/ClColorpicker.css +8 -7
  255. package/buildLibs/styles/Web/ClCropper.css +0 -40
  256. package/buildLibs/styles/Web/ClCropperPreview.css +0 -40
  257. package/buildLibs/styles/Web/ClDatetime.css +8 -38
  258. package/buildLibs/styles/Web/ClDropdownMenu.css +90 -7
  259. package/buildLibs/styles/Web/ClDropdownPopup.css +8 -7
  260. package/buildLibs/styles/Web/ClEchartsLineAxisTag.css +0 -31
  261. package/buildLibs/styles/Web/ClFileUpload.css +0 -31
  262. package/buildLibs/styles/Web/ClInputTag.css +131 -35
  263. package/buildLibs/styles/Web/ClPaginate.css +131 -35
  264. package/buildLibs/styles/Web/ClSelect.css +131 -35
  265. package/buildLibs/styles/Web/ClSelectCascade.css +131 -35
  266. package/buildLibs/styles/Web/ClSelectTree.css +8 -7
  267. package/buildLibs/styles/Web/ClSelectmove.css +8 -7
  268. package/buildLibs/styles/Web/ClTable.css +131 -35
  269. package/buildLibs/styles/Web/ClXeditable.css +131 -66
  270. package/buildLibs/styles/Web/__provide__/Alert.css +0 -40
  271. package/buildLibs/styles/Web/__provide__/Preview.css +0 -31
  272. package/buildLibs/types/Common/Element/Event/drag.d.ts +7 -1
  273. package/buildLibs/types/Common/Tools/device.d.ts +2 -2
  274. package/buildLibs/types/Common/base.d.ts +2 -2
  275. package/buildLibs/types/Common/browserProgress.d.ts +3 -1
  276. package/buildLibs/types/Common/day.d.ts +2 -2
  277. package/buildLibs/types/Common/globalConfig.d.ts +18 -3
  278. package/buildLibs/types/Element/Overlay/Index.vue.d.ts +1 -1
  279. package/buildLibs/types/Element/Slider/Button.vue.d.ts +31 -0
  280. package/buildLibs/types/Element/Slider/Index.vue.d.ts +2 -0
  281. package/buildLibs/types/Element/Tags/Index.vue.d.ts +33 -3
  282. package/buildLibs/types/Element/core.d.ts +4 -2
  283. package/buildLibs/types/Element/installCommon.d.ts +10 -3
  284. package/buildLibs/types/Mobile/CalendarM/Panel.vue.d.ts +2 -2
  285. package/buildLibs/types/Mobile/DropdownMenuM/Item.vue.d.ts +1 -1
  286. package/buildLibs/types/Mobile/{FloatingBubble → FloatBubble}/Index.vue.d.ts +3 -3
  287. package/buildLibs/types/Mobile/{InputOtp → InputPin}/Index.vue.d.ts +11 -0
  288. package/buildLibs/types/Mobile/NoticeBar/Index.vue.d.ts +3 -3
  289. package/buildLibs/types/Mobile/NotifyM/Index.vue.d.ts +20 -0
  290. package/buildLibs/types/Mobile/NumberKeyboard/Index.vue.d.ts +4 -4
  291. package/buildLibs/types/Mobile/Picker/Column.vue.d.ts +9 -9
  292. package/buildLibs/types/Mobile/Picker/Index.vue.d.ts +18 -18
  293. package/buildLibs/types/Mobile/{AreaM → PickerArea}/Index.vue.d.ts +4 -4
  294. package/buildLibs/types/Mobile/PickerCascader/Index.vue.d.ts +1 -1
  295. package/buildLibs/types/Mobile/PickerDate/Index.vue.d.ts +16 -16
  296. package/buildLibs/types/Mobile/PickerTime/Index.vue.d.ts +16 -16
  297. package/buildLibs/types/Mobile/Popup/Index.vue.d.ts +1 -1
  298. package/buildLibs/types/Mobile/ScrollCard/Index.vue.d.ts +33 -20
  299. package/buildLibs/types/Mobile/{ShareSheet → SharePanel}/Index.vue.d.ts +5 -5
  300. package/buildLibs/types/Mobile/Signature/Index.vue.d.ts +3 -3
  301. package/buildLibs/types/Mobile/components.d.ts +5 -5
  302. package/buildLibs/types/Use/focusTrap.d.ts +13 -0
  303. package/buildLibs/types/Web/DropdownLayer/Base.vue.d.ts +9 -0
  304. package/buildLibs/types/Web/DropdownMenu/Index.vue.d.ts +12 -0
  305. package/buildLibs/utils/Element/ClBadge.cjs +1 -1
  306. package/buildLibs/utils/Element/ClBadge.js +1 -1
  307. package/buildLibs/utils/Element/ClBreadcrumb.cjs +1 -1
  308. package/buildLibs/utils/Element/ClBreadcrumb.js +3 -3
  309. package/buildLibs/utils/Element/ClButton.cjs +1 -1
  310. package/buildLibs/utils/Element/ClButton.js +2 -1
  311. package/buildLibs/utils/Element/ClCallout.cjs +1 -1
  312. package/buildLibs/utils/Element/ClCallout.js +2 -2
  313. package/buildLibs/utils/Element/ClCard.cjs +1 -1
  314. package/buildLibs/utils/Element/ClCard.js +1 -1
  315. package/buildLibs/utils/Element/ClCardColor.cjs +1 -1
  316. package/buildLibs/utils/Element/ClCardColor.js +2 -2
  317. package/buildLibs/utils/Element/ClCheckbox.cjs +1 -1
  318. package/buildLibs/utils/Element/ClCheckbox.js +1 -1
  319. package/buildLibs/utils/Element/ClCheckboxOne.cjs +1 -1
  320. package/buildLibs/utils/Element/ClCheckboxOne.js +1 -1
  321. package/buildLibs/utils/Element/ClClipboard.cjs +1 -1
  322. package/buildLibs/utils/Element/ClClipboard.js +1 -1
  323. package/buildLibs/utils/Element/ClCollapse.cjs +1 -1
  324. package/buildLibs/utils/Element/ClCollapse.js +3 -3
  325. package/buildLibs/utils/Element/ClCountDown.cjs +1 -1
  326. package/buildLibs/utils/Element/ClCountDown.js +2 -2
  327. package/buildLibs/utils/Element/ClDarg.cjs +1 -1
  328. package/buildLibs/utils/Element/ClDarg.js +2 -2
  329. package/buildLibs/utils/Element/ClDivider.cjs +1 -1
  330. package/buildLibs/utils/Element/ClDivider.js +2 -80
  331. package/buildLibs/utils/Element/ClEllipsis.cjs +1 -1
  332. package/buildLibs/utils/Element/ClEllipsis.js +1 -1
  333. package/buildLibs/utils/Element/ClEmpty.cjs +1 -1
  334. package/buildLibs/utils/Element/ClEmpty.js +2 -2
  335. package/buildLibs/utils/Element/ClForm.cjs +1 -1
  336. package/buildLibs/utils/Element/ClForm.js +1 -1
  337. package/buildLibs/utils/Element/ClFormGroupBtns.cjs +1 -1
  338. package/buildLibs/utils/Element/ClFormGroupBtns.js +3 -3
  339. package/buildLibs/utils/Element/ClFormGroupHorizontal.cjs +1 -1
  340. package/buildLibs/utils/Element/ClFormGroupHorizontal.js +1 -1
  341. package/buildLibs/utils/Element/ClFormGroupVertical.cjs +1 -1
  342. package/buildLibs/utils/Element/ClFormGroupVertical.js +2 -2
  343. package/buildLibs/utils/Element/ClFormValidate.cjs +1 -1
  344. package/buildLibs/utils/Element/ClFormValidate.js +1 -1
  345. package/buildLibs/utils/Element/ClIconFont.cjs +1 -1
  346. package/buildLibs/utils/Element/ClIconFont.js +1 -1
  347. package/buildLibs/utils/Element/ClImage.cjs +1 -1
  348. package/buildLibs/utils/Element/ClImage.js +1 -1
  349. package/buildLibs/utils/Element/ClInput.cjs +1 -1
  350. package/buildLibs/utils/Element/ClInput.js +1 -1
  351. package/buildLibs/utils/Element/ClInputCaptcha.cjs +1 -1
  352. package/buildLibs/utils/Element/ClInputCaptcha.js +3 -3
  353. package/buildLibs/utils/Element/ClInputNumber.cjs +1 -1
  354. package/buildLibs/utils/Element/ClInputNumber.js +1 -1
  355. package/buildLibs/utils/Element/ClInputNumberStepper.cjs +1 -1
  356. package/buildLibs/utils/Element/ClInputNumberStepper.js +1 -1
  357. package/buildLibs/utils/Element/ClInputPassword.cjs +1 -1
  358. package/buildLibs/utils/Element/ClInputPassword.js +4 -4
  359. package/buildLibs/utils/Element/ClInputPin.css +1 -0
  360. package/buildLibs/utils/Element/ClInputSearch.cjs +1 -1
  361. package/buildLibs/utils/Element/ClInputSearch.js +1 -1
  362. package/buildLibs/utils/Element/ClInputTextarea.cjs +1 -1
  363. package/buildLibs/utils/Element/ClInputTextarea.js +1 -1
  364. package/buildLibs/utils/Element/ClLink.cjs +1 -1
  365. package/buildLibs/utils/Element/ClLink.js +1 -1
  366. package/buildLibs/utils/Element/ClLoad.cjs +1 -1
  367. package/buildLibs/utils/Element/ClLoad.js +1 -1
  368. package/buildLibs/utils/Element/ClLoadFullCenter.cjs +1 -1
  369. package/buildLibs/utils/Element/ClLoadFullCenter.js +3 -2
  370. package/buildLibs/utils/Element/ClLoadIng.cjs +1 -1
  371. package/buildLibs/utils/Element/ClLoadIng.js +1 -1
  372. package/buildLibs/utils/Element/ClLoadScreen.cjs +1 -1
  373. package/buildLibs/utils/Element/ClLoadScreen.css +1 -0
  374. package/buildLibs/utils/Element/ClLoadScreen.js +73 -2
  375. package/buildLibs/utils/Element/ClLoadWarp.cjs +1 -1
  376. package/buildLibs/utils/Element/ClLoadWarp.js +3 -3
  377. package/buildLibs/utils/Element/ClModal.cjs +1 -1
  378. package/buildLibs/utils/Element/ClModal.js +2 -1
  379. package/buildLibs/utils/Element/ClNumberRoll.cjs +1 -1
  380. package/buildLibs/utils/Element/ClNumberRoll.js +2 -2
  381. package/buildLibs/utils/Element/ClOverlay.cjs +1 -1
  382. package/buildLibs/utils/Element/ClOverlay.js +2 -2
  383. package/buildLibs/utils/Element/ClProgress.cjs +1 -1
  384. package/buildLibs/utils/Element/ClProgress.js +3 -3
  385. package/buildLibs/utils/Element/ClRadio.cjs +1 -1
  386. package/buildLibs/utils/Element/ClRadio.js +1 -1
  387. package/buildLibs/utils/Element/ClRadioOne.cjs +1 -1
  388. package/buildLibs/utils/Element/ClRadioOne.js +1 -1
  389. package/buildLibs/utils/Element/ClSlider.cjs +1 -1
  390. package/buildLibs/utils/Element/ClSlider.js +1 -1
  391. package/buildLibs/utils/Element/ClSwitchery.cjs +1 -1
  392. package/buildLibs/utils/Element/ClSwitchery.js +3 -3
  393. package/buildLibs/utils/Element/ClTags.cjs +1 -1
  394. package/buildLibs/utils/Element/ClTags.js +1 -1
  395. package/buildLibs/utils/Element/ClWaterfall.cjs +1 -1
  396. package/buildLibs/utils/Element/ClWaterfall.js +3 -3
  397. package/buildLibs/utils/Element/ClWaterfallImage.cjs +1 -1
  398. package/buildLibs/utils/Element/ClWaterfallImage.js +1 -1
  399. package/buildLibs/utils/Mobile/ClActionSheet.cjs +1 -1
  400. package/buildLibs/utils/Mobile/ClActionSheet.js +5 -5
  401. package/buildLibs/utils/Mobile/ClBackTop.cjs +1 -1
  402. package/buildLibs/utils/Mobile/ClBackTop.js +3 -3
  403. package/buildLibs/utils/Mobile/ClBanner.cjs +1 -1
  404. package/buildLibs/utils/Mobile/ClBanner.js +4 -4
  405. package/buildLibs/utils/Mobile/ClCalendarM.cjs +1 -1
  406. package/buildLibs/utils/Mobile/ClCalendarM.js +61 -65
  407. package/buildLibs/utils/Mobile/ClCell.cjs +1 -1
  408. package/buildLibs/utils/Mobile/ClCell.js +3 -3
  409. package/buildLibs/utils/Mobile/ClCellSwipe.cjs +1 -1
  410. package/buildLibs/utils/Mobile/ClCellSwipe.js +2 -2
  411. package/buildLibs/utils/Mobile/ClCodeLegendM.cjs +1 -1
  412. package/buildLibs/utils/Mobile/ClCodeLegendM.js +4 -4
  413. package/buildLibs/utils/Mobile/ClCropperM.cjs +1 -1
  414. package/buildLibs/utils/Mobile/ClCropperM.js +6 -6
  415. package/buildLibs/utils/Mobile/ClDropdownMenuM.cjs +1 -1
  416. package/buildLibs/utils/Mobile/ClDropdownMenuM.js +2 -2
  417. package/buildLibs/utils/Mobile/ClDropdownMenuMItem.cjs +1 -1
  418. package/buildLibs/utils/Mobile/ClDropdownMenuMItem.js +4 -4
  419. package/buildLibs/utils/Mobile/ClFloatBubble.cjs +1 -0
  420. package/buildLibs/utils/Mobile/ClFloatBubble.css +1 -0
  421. package/buildLibs/utils/Mobile/ClFloatBubble.d.ts +1 -0
  422. package/buildLibs/utils/Mobile/{ClFloatingBubble.js → ClFloatBubble.js} +40 -40
  423. package/buildLibs/utils/Mobile/ClFloatPanel.cjs +1 -0
  424. package/buildLibs/utils/Mobile/ClFloatPanel.css +1 -0
  425. package/buildLibs/utils/Mobile/ClFloatPanel.d.ts +1 -0
  426. package/buildLibs/utils/Mobile/{ClFloatingPanel.js → ClFloatPanel.js} +97 -97
  427. package/buildLibs/utils/Mobile/ClGrid.cjs +1 -1
  428. package/buildLibs/utils/Mobile/ClGrid.js +3 -3
  429. package/buildLibs/utils/Mobile/ClIndexBar.cjs +1 -1
  430. package/buildLibs/utils/Mobile/ClIndexBar.js +2 -2
  431. package/buildLibs/utils/Mobile/ClInputPin.cjs +1 -0
  432. package/buildLibs/utils/Mobile/ClInputPin.d.ts +1 -0
  433. package/buildLibs/utils/Mobile/ClInputPin.js +184 -0
  434. package/buildLibs/utils/Mobile/ClNavBar.cjs +1 -1
  435. package/buildLibs/utils/Mobile/ClNavBar.js +3 -3
  436. package/buildLibs/utils/Mobile/ClNoticeBar.cjs +1 -1
  437. package/buildLibs/utils/Mobile/ClNoticeBar.css +1 -1
  438. package/buildLibs/utils/Mobile/ClNoticeBar.js +19 -19
  439. package/buildLibs/utils/Mobile/ClNotifyM.cjs +1 -1
  440. package/buildLibs/utils/Mobile/ClNotifyM.js +2 -1
  441. package/buildLibs/utils/Mobile/ClNumberKeyboard.cjs +1 -1
  442. package/buildLibs/utils/Mobile/ClNumberKeyboard.js +37 -36
  443. package/buildLibs/utils/Mobile/ClPicker.cjs +1 -1
  444. package/buildLibs/utils/Mobile/ClPicker.js +1 -1
  445. package/buildLibs/utils/Mobile/ClPickerArea.cjs +1 -0
  446. package/buildLibs/utils/Mobile/ClPickerArea.css +1 -0
  447. package/buildLibs/utils/Mobile/ClPickerArea.d.ts +1 -0
  448. package/buildLibs/utils/Mobile/ClPickerArea.js +257 -0
  449. package/buildLibs/utils/Mobile/ClPickerCascader.cjs +1 -1
  450. package/buildLibs/utils/Mobile/ClPickerCascader.css +1 -1
  451. package/buildLibs/utils/Mobile/ClPickerCascader.js +4 -4
  452. package/buildLibs/utils/Mobile/ClPickerDate.cjs +1 -1
  453. package/buildLibs/utils/Mobile/ClPickerDate.js +71 -71
  454. package/buildLibs/utils/Mobile/ClPickerTime.cjs +1 -1
  455. package/buildLibs/utils/Mobile/ClPickerTime.js +56 -56
  456. package/buildLibs/utils/Mobile/ClPopup.cjs +1 -1
  457. package/buildLibs/utils/Mobile/ClPopup.js +1 -1
  458. package/buildLibs/utils/Mobile/ClPullToRefresh.cjs +1 -1
  459. package/buildLibs/utils/Mobile/ClPullToRefresh.js +1 -1
  460. package/buildLibs/utils/Mobile/ClRate.cjs +1 -1
  461. package/buildLibs/utils/Mobile/ClRate.js +3 -3
  462. package/buildLibs/utils/Mobile/ClScrollCard.cjs +1 -1
  463. package/buildLibs/utils/Mobile/ClScrollCard.css +1 -1
  464. package/buildLibs/utils/Mobile/ClScrollCard.js +220 -200
  465. package/buildLibs/utils/Mobile/ClSharePanel.cjs +1 -0
  466. package/buildLibs/utils/Mobile/ClSharePanel.css +1 -0
  467. package/buildLibs/utils/Mobile/ClSharePanel.d.ts +1 -0
  468. package/buildLibs/utils/Mobile/{ClShareSheet.js → ClSharePanel.js} +53 -53
  469. package/buildLibs/utils/Mobile/ClSidebar.cjs +1 -1
  470. package/buildLibs/utils/Mobile/ClSidebar.js +2 -2
  471. package/buildLibs/utils/Mobile/ClSidebarSelect.cjs +1 -1
  472. package/buildLibs/utils/Mobile/ClSidebarSelect.css +1 -1
  473. package/buildLibs/utils/Mobile/ClSidebarSelect.js +3 -3
  474. package/buildLibs/utils/Mobile/ClSignature.cjs +1 -1
  475. package/buildLibs/utils/Mobile/ClSignature.js +34 -34
  476. package/buildLibs/utils/Mobile/ClSteps.cjs +1 -1
  477. package/buildLibs/utils/Mobile/ClSteps.css +1 -1
  478. package/buildLibs/utils/Mobile/ClSteps.js +45 -41
  479. package/buildLibs/utils/Mobile/ClSwipe.cjs +1 -1
  480. package/buildLibs/utils/Mobile/ClSwipe.js +2 -2
  481. package/buildLibs/utils/Mobile/ClTabM.cjs +1 -1
  482. package/buildLibs/utils/Mobile/ClTabM.js +2 -2
  483. package/buildLibs/utils/Mobile/ClTabbar.cjs +1 -1
  484. package/buildLibs/utils/Mobile/ClTabbar.js +4 -4
  485. package/buildLibs/utils/Mobile/ClTextHighlight.cjs +1 -1
  486. package/buildLibs/utils/Mobile/ClTextHighlight.css +1 -1
  487. package/buildLibs/utils/Mobile/ClTextHighlight.js +2 -2
  488. package/buildLibs/utils/Mobile/ClToast.cjs +1 -1
  489. package/buildLibs/utils/Mobile/ClToast.js +1 -1
  490. package/buildLibs/utils/Mobile/ClWatermark.cjs +1 -1
  491. package/buildLibs/utils/Mobile/ClWatermark.js +2 -2
  492. package/buildLibs/utils/Mobile/__provide__/NotifyM.cjs +1 -1
  493. package/buildLibs/utils/Mobile/__provide__/NotifyM.js +2 -1
  494. package/buildLibs/utils/Mobile/__provide__/Toast.cjs +1 -1
  495. package/buildLibs/utils/Mobile/__provide__/Toast.js +1 -1
  496. package/buildLibs/utils/Shared/{BallColor4-C2XdKmEn.js → BallColor4-BgsHLeZA.js} +1 -1
  497. package/buildLibs/utils/Shared/{BallColor4-Ds3O9chf.js → BallColor4-qLMVzbAS.js} +1 -1
  498. package/buildLibs/utils/Shared/Base.css +1 -1
  499. package/buildLibs/utils/Shared/Base.vue_vue_type_script_setup_true_lang-5_vbZ_4R.js +1 -0
  500. package/buildLibs/{modules/shared/Base.vue_vue_type_script_setup_true_lang-4j7ikB3n.js → utils/Shared/Base.vue_vue_type_script_setup_true_lang-BReU8HHD.js} +81 -70
  501. package/buildLibs/utils/Shared/BaseTransition.vue_vue_type_script_setup_true_lang-CmETUA__.js +1 -0
  502. package/buildLibs/utils/Shared/BaseTransition.vue_vue_type_script_setup_true_lang-D4VcdHQo.js +193 -0
  503. package/buildLibs/utils/Shared/Column.css +1 -0
  504. package/buildLibs/utils/Shared/Column.vue_vue_type_script_setup_true_lang-ByGDRcgX.js +1 -0
  505. package/buildLibs/utils/Shared/Column.vue_vue_type_script_setup_true_lang-dm0Ii8XP.js +174 -0
  506. package/buildLibs/utils/Shared/Index.css +1 -1
  507. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BHO4QsuM.js → Index.vue_vue_type_script_setup_true_lang-08Gdtb7o.js} +101 -98
  508. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Bexqe3oM.js → Index.vue_vue_type_script_setup_true_lang-0GHFohjQ.js} +2 -2
  509. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DGMzmwmG.js → Index.vue_vue_type_script_setup_true_lang-0xVPFBUW.js} +7 -8
  510. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BY5YgoqV.js → Index.vue_vue_type_script_setup_true_lang-8-8svPDH.js} +1 -1
  511. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-DqUgH7kW.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-B-K0phQ2.js} +4 -4
  512. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DsWuFFm8.js → Index.vue_vue_type_script_setup_true_lang-B-LBJS_U.js} +1 -1
  513. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Dn2mAxQN.js → Index.vue_vue_type_script_setup_true_lang-B0NaQAuE.js} +5 -5
  514. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Bh9eiZXZ.js → Index.vue_vue_type_script_setup_true_lang-B2cccX6M.js} +1 -1
  515. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DImXx9OJ.js → Index.vue_vue_type_script_setup_true_lang-B2kyuq50.js} +1 -1
  516. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DXQ2H_E6.js → Index.vue_vue_type_script_setup_true_lang-B4dpfPSy.js} +1 -1
  517. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-B-QoYEZX.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-B5MSug5Q.js} +5 -5
  518. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BmA34nLj.js → Index.vue_vue_type_script_setup_true_lang-B9xISM7N.js} +1 -1
  519. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-BDCMqHLL.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-BAUA1fQJ.js} +2 -2
  520. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-Dn7loQye.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-BFq7G64T.js} +22 -22
  521. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BwvnxiF-.js → Index.vue_vue_type_script_setup_true_lang-BJuly3Dc.js} +1 -1
  522. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BLoX4k7J.js +213 -0
  523. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-1634m2dj.js → Index.vue_vue_type_script_setup_true_lang-BLr46kTp.js} +8 -8
  524. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-W7-2HMLt.js → Index.vue_vue_type_script_setup_true_lang-BO2XU-fq.js} +4 -4
  525. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BRJ2Ll2r.js +1 -0
  526. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BRyvdWb7.js +1 -0
  527. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-n7xMYytH.js → Index.vue_vue_type_script_setup_true_lang-BTikeo7T.js} +5 -5
  528. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DeQDuJWX.js → Index.vue_vue_type_script_setup_true_lang-BXQl9ZJr.js} +1 -1
  529. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-B5STWqf2.js → Index.vue_vue_type_script_setup_true_lang-BahSP_of.js} +22 -17
  530. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BbxnIsLt.js +1 -0
  531. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-Co1P4Ez3.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-Bd56L0m6.js} +5 -5
  532. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-Ix_0hpqL.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-BhGGH7ms.js} +13 -13
  533. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Bn3f-2m-.js +1 -0
  534. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-C8n67_vn.js → Index.vue_vue_type_script_setup_true_lang-BppPP2_o.js} +5 -5
  535. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DkvbBq5f.js → Index.vue_vue_type_script_setup_true_lang-BsE_zUs_.js} +2 -2
  536. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BWhUEMe2.js → Index.vue_vue_type_script_setup_true_lang-BxWYROZH.js} +1 -1
  537. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Bp1npEqw.js → Index.vue_vue_type_script_setup_true_lang-C1Z3g7mN.js} +1 -1
  538. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DARNgU78.js → Index.vue_vue_type_script_setup_true_lang-C242QFDV.js} +1 -1
  539. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-ZN6OLOcr.js → Index.vue_vue_type_script_setup_true_lang-CAEbDVL3.js} +1 -1
  540. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DG2gOqUV.js → Index.vue_vue_type_script_setup_true_lang-CDslbo4h.js} +1 -1
  541. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CFNQBTiQ.js +1 -0
  542. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-eYOa2n8R.js → Index.vue_vue_type_script_setup_true_lang-CIky1_fS.js} +28 -25
  543. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DkO0Tw8l.js → Index.vue_vue_type_script_setup_true_lang-COprcd8r.js} +46 -46
  544. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CPwtuGiA.js +1 -0
  545. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-BdU06Zy_.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-CQVg87mD.js} +3 -3
  546. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DnB4CiG6.js → Index.vue_vue_type_script_setup_true_lang-CSt6K9AQ.js} +1 -1
  547. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CyRAlV4P.js → Index.vue_vue_type_script_setup_true_lang-Cb49VSDS.js} +1 -1
  548. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DD7Wsxy0.js → Index.vue_vue_type_script_setup_true_lang-CgNMWZqs.js} +53 -48
  549. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-4r0yj-AP.js → Index.vue_vue_type_script_setup_true_lang-Cm8_ZNJ7.js} +1 -1
  550. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CnLyIXBs.js +939 -0
  551. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-BI_FbhEm.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-CtBOIjdU.js} +6 -6
  552. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Cw8P2xE-.js → Index.vue_vue_type_script_setup_true_lang-Cx56SGXr.js} +47 -50
  553. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Dzw8LxdI.js → Index.vue_vue_type_script_setup_true_lang-CyYCIkzr.js} +1 -1
  554. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-v03zJOqX.js → Index.vue_vue_type_script_setup_true_lang-D15_sdie.js} +1 -1
  555. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CUGhrsCV.js → Index.vue_vue_type_script_setup_true_lang-D3h6Q_pB.js} +2 -2
  556. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DnLaqNB3.js → Index.vue_vue_type_script_setup_true_lang-D4BokTL9.js} +1 -1
  557. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-afm0gWnG.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-D53FO2PF.js} +4 -4
  558. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-D8TDafMl.js +1 -0
  559. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DAuZLHen.js +277 -0
  560. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DBEuF9lY.js +1 -0
  561. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-t2B1qQvc.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-DQBXyVuV.js} +2 -2
  562. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DeqkYoiB.js → Index.vue_vue_type_script_setup_true_lang-DTnllTwD.js} +2 -2
  563. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DYj0GzN0.js +1 -0
  564. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DZSulESm.js +1 -0
  565. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-Dq5DVoF_.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-DiFMOo2n.js} +9 -9
  566. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BJw-_EOe.js → Index.vue_vue_type_script_setup_true_lang-DjwVdgdl.js} +6 -6
  567. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DlFdXr6k.js +82 -0
  568. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DlaLkFjd.js +1 -0
  569. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Dnw-Opme.js +1 -0
  570. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Dk4V2JmM.js → Index.vue_vue_type_script_setup_true_lang-Dq-sCBRz.js} +1 -1
  571. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CBIhuvnz.js → Index.vue_vue_type_script_setup_true_lang-DsTDQ4p-.js} +1 -1
  572. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DtTJLC6m.js +1 -0
  573. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-D3hrURiG.js → Index.vue_vue_type_script_setup_true_lang-Dyo4Sh1B.js} +1 -1
  574. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Gp7OJJx5.js +1 -0
  575. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-COItePPk.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-K7pBVuwe.js} +3 -3
  576. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-24C15gSt.js → Index.vue_vue_type_script_setup_true_lang-M72THnHz.js} +1 -1
  577. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-PQ1DyzI3.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-PraAnYLk.js} +3 -3
  578. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CcJjZsqO.js → Index.vue_vue_type_script_setup_true_lang-SE1_-Y3D.js} +1 -1
  579. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-C0GnaTPr.js → Index.vue_vue_type_script_setup_true_lang-WePMnXeI.js} +1 -1
  580. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-CyKHq3tv.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-afRTRRcb.js} +2 -2
  581. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DaQXxBad.js → Index.vue_vue_type_script_setup_true_lang-b4R4PHf0.js} +108 -108
  582. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CfIJDVo7.js → Index.vue_vue_type_script_setup_true_lang-bKzsLLvg.js} +1 -1
  583. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Bat5bJ6h.js → Index.vue_vue_type_script_setup_true_lang-d8FRnWoo.js} +1 -1
  584. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-oFF20mhc.js +152 -0
  585. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-CDFEcM1i.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-qOys54ns.js} +3 -3
  586. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-bG1Y_BJw.js → Index.vue_vue_type_script_setup_true_lang-yQG3rOxU.js} +2 -2
  587. package/buildLibs/utils/Shared/Index10.css +1 -1
  588. package/buildLibs/utils/Shared/Index11.css +1 -1
  589. package/buildLibs/utils/Shared/Index12.css +1 -1
  590. package/buildLibs/utils/Shared/Index13.css +1 -1
  591. package/buildLibs/utils/Shared/Index14.css +1 -1
  592. package/buildLibs/utils/Shared/Index15.css +1 -1
  593. package/buildLibs/utils/Shared/Index16.css +1 -1
  594. package/buildLibs/utils/Shared/Index17.css +1 -1
  595. package/buildLibs/utils/Shared/Index18.css +1 -1
  596. package/buildLibs/utils/Shared/Index21.css +1 -1
  597. package/buildLibs/utils/Shared/Index23.css +1 -1
  598. package/buildLibs/utils/Shared/Index24.css +1 -1
  599. package/buildLibs/utils/Shared/Index25.css +1 -1
  600. package/buildLibs/utils/Shared/Index26.css +1 -1
  601. package/buildLibs/utils/Shared/Index27.css +1 -1
  602. package/buildLibs/utils/Shared/Index28.css +1 -1
  603. package/buildLibs/utils/Shared/Index29.css +1 -1
  604. package/buildLibs/utils/Shared/Index30.css +1 -1
  605. package/buildLibs/utils/Shared/Index31.css +1 -1
  606. package/buildLibs/utils/Shared/Index32.css +1 -1
  607. package/buildLibs/utils/Shared/Index33.css +1 -1
  608. package/buildLibs/utils/Shared/Index34.css +1 -1
  609. package/buildLibs/utils/Shared/Index35.css +1 -1
  610. package/buildLibs/utils/Shared/Index36.css +1 -1
  611. package/buildLibs/utils/Shared/Index37.css +1 -1
  612. package/buildLibs/utils/Shared/Index38.css +1 -1
  613. package/buildLibs/utils/Shared/Index5.css +1 -1
  614. package/buildLibs/utils/Shared/{Ing.vue_vue_type_script_setup_true_lang-D2lxtF5j.js → Ing.vue_vue_type_script_setup_true_lang-DPFunPx2.js} +1 -1
  615. package/buildLibs/{modules/shared/Ing.vue_vue_type_script_setup_true_lang-CbxKiYq1.js → utils/Shared/Ing.vue_vue_type_script_setup_true_lang-Zb0-4POE.js} +3 -3
  616. package/buildLibs/utils/Shared/{List.vue_vue_type_script_setup_true_lang-B5YIPqGh.js → List.vue_vue_type_script_setup_true_lang-BLgui2Zv.js} +4 -4
  617. package/buildLibs/utils/Shared/{List.vue_vue_type_script_setup_true_lang-bFNMd-te.js → List.vue_vue_type_script_setup_true_lang-DJAqJJnH.js} +1 -1
  618. package/buildLibs/utils/Shared/{One.vue_vue_type_script_setup_true_lang-DQ_7aqC8.js → One.vue_vue_type_script_setup_true_lang-BC8yzPg5.js} +1 -1
  619. package/buildLibs/utils/Shared/{One.vue_vue_type_script_setup_true_lang-DcjKaZQ_.js → One.vue_vue_type_script_setup_true_lang-BKTdt1M7.js} +1 -1
  620. package/buildLibs/utils/Shared/{One.vue_vue_type_script_setup_true_lang-CmnkkHBx.js → One.vue_vue_type_script_setup_true_lang-BRIVGray.js} +3 -3
  621. package/buildLibs/utils/Shared/{One.vue_vue_type_script_setup_true_lang-Bz2OX9PQ.js → One.vue_vue_type_script_setup_true_lang-Du9X7x9H.js} +3 -3
  622. package/buildLibs/utils/Shared/{Popup.vue_vue_type_script_setup_true_lang-gwQgBwlR.js → Popup.vue_vue_type_script_setup_true_lang-d2TT0lCU.js} +1 -1
  623. package/buildLibs/utils/Shared/{Popup.vue_vue_type_script_setup_true_lang-ltEkWlAH.js → Popup.vue_vue_type_script_setup_true_lang-hfNlyh_i.js} +3 -3
  624. package/buildLibs/{modules/shared/ToastRing-CLhmoOCN.js → utils/Shared/ToastRing-2rl8qS1H.js} +1 -1
  625. package/buildLibs/utils/Shared/{ToastRing-CUCc2KYf.js → ToastRing-B1qc5Ig_.js} +1 -1
  626. package/buildLibs/utils/Shared/Validate.vue_vue_type_script_setup_true_lang-DidPD12P.js +411 -0
  627. package/buildLibs/utils/Shared/Validate.vue_vue_type_script_setup_true_lang-DyOZ5QGN.js +1 -0
  628. package/buildLibs/utils/Shared/{Video-DlqsnyxL.js → Video-BBXD_6D-.js} +1 -1
  629. package/buildLibs/utils/Shared/{Video-yVSuj26v.js → Video-BillcMo0.js} +1 -1
  630. package/buildLibs/utils/Shared/{base-DmcbRUB5.js → base-DbuX_Y3x.js} +1 -1
  631. package/buildLibs/utils/Shared/{base-C5l51ld_.js → base-fr2I80sU.js} +10 -10
  632. package/buildLibs/utils/Shared/{day-Bfolruvp.js → day-B3hhmAm_.js} +15 -6
  633. package/buildLibs/utils/Shared/{day-C3XuCUKG.js → day-C_LrDb1h.js} +1 -1
  634. package/buildLibs/utils/Shared/drag-BB4KOliP.js +1 -0
  635. package/buildLibs/utils/Shared/drag-BBk0X740.js +53 -0
  636. package/buildLibs/utils/Shared/focusTrap-95OmT9bf.js +1 -0
  637. package/buildLibs/utils/Shared/focusTrap-BYhFRjSm.js +82 -0
  638. package/buildLibs/utils/Shared/{index-wdK75uN2.js → index-B477PjJ3.js} +1 -1
  639. package/buildLibs/utils/Shared/{index-CXRfOfiT.js → index-rFJmbgyH.js} +1 -1
  640. package/buildLibs/utils/Shared/language-Q4AGYtUe.js +1 -0
  641. package/buildLibs/utils/Shared/{index-DX8TWPlf.js → language-pMmux6Js.js} +151 -44
  642. package/buildLibs/utils/Shared/{resize-5FVpVwWr.js → resize-CyrJxi6F.js} +2 -2
  643. package/buildLibs/utils/Shared/{resize-BqfiqIio.js → resize-Ds0ycOGI.js} +1 -1
  644. package/buildLibs/utils/Shared/use-BBpYjALT.js +1 -0
  645. package/buildLibs/utils/Shared/{lazy--M9Mmsjn.js → use-CRdlCpEV.js} +48 -35
  646. package/buildLibs/utils/Web/ClAnchorNav.cjs +1 -1
  647. package/buildLibs/utils/Web/ClAnchorNav.js +3 -3
  648. package/buildLibs/utils/Web/ClCalendar.cjs +1 -1
  649. package/buildLibs/utils/Web/ClCalendar.js +32 -32
  650. package/buildLibs/utils/Web/ClCodeLegend.cjs +1 -1
  651. package/buildLibs/utils/Web/ClCodeLegend.js +3 -3
  652. package/buildLibs/utils/Web/ClCodeLegendM.css +1 -1
  653. package/buildLibs/utils/Web/ClColorPicker.cjs +1 -1
  654. package/buildLibs/utils/Web/ClColorPicker.js +8 -8
  655. package/buildLibs/utils/Web/ClCropper.cjs +1 -1
  656. package/buildLibs/utils/Web/ClCropper.js +2 -1
  657. package/buildLibs/utils/Web/ClCropperPreview.cjs +1 -1
  658. package/buildLibs/utils/Web/ClCropperPreview.js +7 -6
  659. package/buildLibs/utils/Web/ClDateTime.cjs +1 -1
  660. package/buildLibs/utils/Web/ClDateTime.js +2 -1
  661. package/buildLibs/utils/Web/ClDropdownMenu.cjs +1 -1
  662. package/buildLibs/utils/Web/ClDropdownMenu.css +1 -1
  663. package/buildLibs/utils/Web/ClDropdownMenu.js +110 -48
  664. package/buildLibs/utils/Web/ClDropdownMenuItem.cjs +1 -1
  665. package/buildLibs/utils/Web/ClDropdownMenuItem.js +44 -27
  666. package/buildLibs/utils/Web/ClDropdownPopup.cjs +1 -1
  667. package/buildLibs/utils/Web/ClDropdownPopup.js +3 -3
  668. package/buildLibs/utils/Web/ClEcharts.cjs +1 -1
  669. package/buildLibs/utils/Web/ClEcharts.js +1 -1
  670. package/buildLibs/utils/Web/ClEchartsLineAxisTag.cjs +1 -1
  671. package/buildLibs/utils/Web/ClEchartsLineAxisTag.js +5 -4
  672. package/buildLibs/utils/Web/ClFileUpload.cjs +1 -1
  673. package/buildLibs/utils/Web/ClFileUpload.js +2 -1
  674. package/buildLibs/utils/Web/ClFramePhone.cjs +1 -1
  675. package/buildLibs/utils/Web/ClFramePhone.js +1 -1
  676. package/buildLibs/utils/Web/ClInputTag.cjs +1 -1
  677. package/buildLibs/utils/Web/ClInputTag.js +1 -1
  678. package/buildLibs/utils/Web/ClPaginate.cjs +1 -1
  679. package/buildLibs/utils/Web/ClPaginate.js +1 -1
  680. package/buildLibs/utils/Web/ClPortlet.cjs +1 -1
  681. package/buildLibs/utils/Web/ClPortlet.js +2 -2
  682. package/buildLibs/utils/Web/ClPreviewExample.cjs +1 -1
  683. package/buildLibs/utils/Web/ClPreviewExample.js +1 -1
  684. package/buildLibs/utils/Web/ClScrollXFence.cjs +1 -1
  685. package/buildLibs/utils/Web/ClScrollXFence.js +1 -1
  686. package/buildLibs/utils/Web/ClSelect.cjs +1 -1
  687. package/buildLibs/utils/Web/ClSelect.js +1 -1
  688. package/buildLibs/utils/Web/ClSelectCascade.cjs +1 -1
  689. package/buildLibs/utils/Web/ClSelectCascade.js +1 -1
  690. package/buildLibs/utils/Web/ClSelectMove.cjs +1 -1
  691. package/buildLibs/utils/Web/ClSelectMove.js +8 -8
  692. package/buildLibs/utils/Web/ClSelectTag.cjs +1 -1
  693. package/buildLibs/utils/Web/ClSelectTag.js +1 -1
  694. package/buildLibs/utils/Web/ClSelectTree.cjs +1 -1
  695. package/buildLibs/utils/Web/ClSelectTree.js +6 -6
  696. package/buildLibs/utils/Web/ClSideMenu.cjs +1 -1
  697. package/buildLibs/utils/Web/ClSideMenu.js +4 -4
  698. package/buildLibs/utils/Web/ClTable.cjs +1 -1
  699. package/buildLibs/utils/Web/ClTable.js +11 -11
  700. package/buildLibs/utils/Web/ClTableEdit.cjs +1 -1
  701. package/buildLibs/utils/Web/ClTableEdit.js +2 -2
  702. package/buildLibs/utils/Web/ClTableSimple.cjs +1 -1
  703. package/buildLibs/utils/Web/ClTableSimple.js +2 -2
  704. package/buildLibs/utils/Web/ClTabs.cjs +1 -1
  705. package/buildLibs/utils/Web/ClTabs.js +5 -5
  706. package/buildLibs/utils/Web/ClTree.cjs +1 -1
  707. package/buildLibs/utils/Web/ClTree.js +1 -1
  708. package/buildLibs/utils/Web/ClWeekHour.cjs +1 -1
  709. package/buildLibs/utils/Web/ClWeekHour.js +5 -5
  710. package/buildLibs/utils/Web/ClXEditable.cjs +1 -1
  711. package/buildLibs/utils/Web/ClXEditable.js +22 -21
  712. package/buildLibs/utils/Web/__directive__/Tooltip.cjs +1 -1
  713. package/buildLibs/utils/Web/__directive__/Tooltip.js +2 -2
  714. package/buildLibs/utils/Web/__directive__/Waves.cjs +1 -1
  715. package/buildLibs/utils/Web/__directive__/Waves.js +1 -1
  716. package/buildLibs/utils/Web/__provide__/Alert.cjs +1 -1
  717. package/buildLibs/utils/Web/__provide__/Alert.js +5 -4
  718. package/buildLibs/utils/Web/__provide__/Notify.cjs +1 -1
  719. package/buildLibs/utils/Web/__provide__/Notify.js +3 -3
  720. package/buildLibs/utils/Web/__provide__/Preview.cjs +1 -1
  721. package/buildLibs/utils/Web/__provide__/Preview.js +7 -6
  722. package/buildLibs/web/BallColor4-Bk0PbmjR.js +36 -0
  723. package/buildLibs/{mobile/BallColor4-9BeLWzwc.cjs → web/BallColor4-CvdyEpUB.cjs} +1 -1
  724. package/buildLibs/web/ToastRing-DxVDUCSx.js +26 -0
  725. package/buildLibs/{all/ToastRing-C0GKGyt2.cjs → web/ToastRing-KEtXZej2.cjs} +1 -1
  726. package/buildLibs/web/{Video-DuP0_H4b.cjs → Video-7bB5a3gv.cjs} +1 -1
  727. package/buildLibs/web/{Video-BDwetEWQ.js → Video-D36W46Pk.js} +1 -1
  728. package/buildLibs/web/{index-DPNEslm1.js → index-ai_LrIsJ.js} +10664 -10473
  729. package/buildLibs/web/index-jOBQ0InH.cjs +12 -0
  730. package/buildLibs/web/index.cjs +1 -1
  731. package/buildLibs/web/index.css +1 -1
  732. package/buildLibs/web/index.js +1 -1
  733. package/docs/components/Element/Divider.md +5 -3
  734. package/docs/components/Element/Slider.md +1 -0
  735. package/docs/components/Element/Tags.md +34 -8
  736. package/docs/components/Mobile/{FloatingBubble.md → FloatBubble.md} +17 -17
  737. package/docs/components/Mobile/{FloatingPanel.md → FloatPanel.md} +30 -30
  738. package/docs/components/Mobile/{InputOtp.md → InputPin.md} +25 -12
  739. package/docs/components/Mobile/NoticeBar.md +4 -4
  740. package/docs/components/Mobile/NotifyM.md +11 -0
  741. package/docs/components/Mobile/NumberKeyboard.md +8 -8
  742. package/docs/components/Mobile/Picker.md +8 -8
  743. package/docs/components/Mobile/{AreaM.md → PickerArea.md} +12 -12
  744. package/docs/components/Mobile/PickerDate.md +5 -5
  745. package/docs/components/Mobile/PickerTime.md +5 -5
  746. package/docs/components/Mobile/ScrollCard.md +43 -10
  747. package/docs/components/Mobile/{ShareSheet.md → SharePanel.md} +11 -11
  748. package/docs/components/Mobile/Signature.md +3 -3
  749. package/docs/tokens/design-token.md +17 -2
  750. package/docs/tools/CommonDay.md +3 -3
  751. package/package.json +2 -1
  752. package/buildLibs/all/index-CS39FBSI.cjs +0 -14
  753. package/buildLibs/common/browserProgress.css +0 -1
  754. package/buildLibs/mobile/index-0Bk83khG.cjs +0 -10
  755. package/buildLibs/modules/areaM.cjs +0 -5
  756. package/buildLibs/modules/areaM.d.ts +0 -1
  757. package/buildLibs/modules/areaM.js +0 -255
  758. package/buildLibs/modules/floatingBubble.cjs +0 -5
  759. package/buildLibs/modules/floatingBubble.d.ts +0 -1
  760. package/buildLibs/modules/floatingPanel.cjs +0 -5
  761. package/buildLibs/modules/floatingPanel.d.ts +0 -1
  762. package/buildLibs/modules/inputOtp.cjs +0 -5
  763. package/buildLibs/modules/inputOtp.d.ts +0 -1
  764. package/buildLibs/modules/inputOtp.js +0 -175
  765. package/buildLibs/modules/shareSheet.cjs +0 -5
  766. package/buildLibs/modules/shareSheet.d.ts +0 -1
  767. package/buildLibs/modules/shared/Index-aam7IdIy.js +0 -174
  768. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-BBz5WLtl.js +0 -898
  769. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-CM64ExS-.js +0 -201
  770. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-Dt1s66Uw.js +0 -442
  771. package/buildLibs/modules/shared/drag-CBokh_eH.js +0 -41
  772. package/buildLibs/styles/Element/ClOverlay.css +0 -32
  773. package/buildLibs/utils/Element/ClDivider.css +0 -1
  774. package/buildLibs/utils/Element/ClInputOtp.css +0 -1
  775. package/buildLibs/utils/Element/__directive__/LazyImage.cjs +0 -1
  776. package/buildLibs/utils/Element/__directive__/LazyImage.d.ts +0 -1
  777. package/buildLibs/utils/Element/__directive__/LazyImage.js +0 -14
  778. package/buildLibs/utils/Element/__provide__/Clipboard.cjs +0 -1
  779. package/buildLibs/utils/Element/__provide__/Clipboard.d.ts +0 -1
  780. package/buildLibs/utils/Element/__provide__/Clipboard.js +0 -37
  781. package/buildLibs/utils/Element/__provide__/LanguagePack.cjs +0 -1
  782. package/buildLibs/utils/Element/__provide__/LanguagePack.d.ts +0 -1
  783. package/buildLibs/utils/Element/__provide__/LanguagePack.js +0 -28
  784. package/buildLibs/utils/Element/__provide__/LoadScreen.cjs +0 -1
  785. package/buildLibs/utils/Element/__provide__/LoadScreen.d.ts +0 -1
  786. package/buildLibs/utils/Element/__provide__/LoadScreen.js +0 -22
  787. package/buildLibs/utils/Element/__provide__/Validate.cjs +0 -1
  788. package/buildLibs/utils/Element/__provide__/Validate.d.ts +0 -1
  789. package/buildLibs/utils/Element/__provide__/Validate.js +0 -104
  790. package/buildLibs/utils/Mobile/ClAreaM.cjs +0 -1
  791. package/buildLibs/utils/Mobile/ClAreaM.css +0 -1
  792. package/buildLibs/utils/Mobile/ClAreaM.d.ts +0 -1
  793. package/buildLibs/utils/Mobile/ClAreaM.js +0 -257
  794. package/buildLibs/utils/Mobile/ClFloatingBubble.cjs +0 -1
  795. package/buildLibs/utils/Mobile/ClFloatingBubble.css +0 -1
  796. package/buildLibs/utils/Mobile/ClFloatingBubble.d.ts +0 -1
  797. package/buildLibs/utils/Mobile/ClFloatingPanel.cjs +0 -1
  798. package/buildLibs/utils/Mobile/ClFloatingPanel.css +0 -1
  799. package/buildLibs/utils/Mobile/ClFloatingPanel.d.ts +0 -1
  800. package/buildLibs/utils/Mobile/ClInputOtp.cjs +0 -1
  801. package/buildLibs/utils/Mobile/ClInputOtp.d.ts +0 -1
  802. package/buildLibs/utils/Mobile/ClInputOtp.js +0 -177
  803. package/buildLibs/utils/Mobile/ClShareSheet.cjs +0 -1
  804. package/buildLibs/utils/Mobile/ClShareSheet.css +0 -1
  805. package/buildLibs/utils/Mobile/ClShareSheet.d.ts +0 -1
  806. package/buildLibs/utils/Shared/Base.vue_vue_type_script_setup_true_lang-CiIYjt-L.js +0 -1
  807. package/buildLibs/utils/Shared/BaseTransition.vue_vue_type_script_setup_true_lang-BD35JTIP.js +0 -1
  808. package/buildLibs/utils/Shared/BaseTransition.vue_vue_type_script_setup_true_lang-DHyNMo5z.js +0 -255
  809. package/buildLibs/utils/Shared/Index-BBs91jFy.js +0 -174
  810. package/buildLibs/utils/Shared/Index-qL-h43DD.js +0 -1
  811. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-B9PGQ2ms.js +0 -1
  812. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BVFmiu-5.js +0 -1
  813. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BlFq1X5t.js +0 -1
  814. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Bo91q9Ij.js +0 -1
  815. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CIBERZly.js +0 -1
  816. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CKNVMM02.js +0 -74
  817. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CrNoVcn8.js +0 -120
  818. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CvgyjDiU.js +0 -898
  819. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DGT_No-k.js +0 -1
  820. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DGXwL6RV.js +0 -201
  821. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DIbQI2wQ.js +0 -1
  822. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DIdU8GIV.js +0 -1
  823. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DKbCcnPs.js +0 -1
  824. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Db4Zb3Yy.js +0 -1
  825. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DcOTqPR-.js +0 -1
  826. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DgWoxi-r.js +0 -1
  827. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DlvzgFMo.js +0 -175
  828. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Drp93I0i.js +0 -1
  829. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-s0crAk8w.js +0 -1
  830. package/buildLibs/utils/Shared/Index39.css +0 -1
  831. package/buildLibs/utils/Shared/Validate.vue_vue_type_script_setup_true_lang-3Ig7bOGx.js +0 -1
  832. package/buildLibs/utils/Shared/Validate.vue_vue_type_script_setup_true_lang-57tbyvPI.js +0 -313
  833. package/buildLibs/utils/Shared/drag-CBokh_eH.js +0 -41
  834. package/buildLibs/utils/Shared/drag-CnnSwz5k.js +0 -1
  835. package/buildLibs/utils/Shared/index-C6VS0w0n.js +0 -1
  836. package/buildLibs/utils/Shared/language-BAyxuenq.js +0 -1
  837. package/buildLibs/utils/Shared/language-Br_W-GD8.js +0 -111
  838. package/buildLibs/utils/Shared/lazy-CHlfoPOo.js +0 -1
  839. package/buildLibs/utils/Shared/use-CaPct63w.js +0 -17
  840. package/buildLibs/utils/Shared/use-DpwlHmqI.js +0 -1
  841. package/buildLibs/web/BallColor4-B90sCDaX.js +0 -36
  842. package/buildLibs/web/ToastRing-DGR6ZoRQ.js +0 -26
  843. package/buildLibs/web/index-Bfw6k91_.cjs +0 -12
  844. /package/buildLibs/types/Mobile/{FloatingPanel → FloatPanel}/Index.vue.d.ts +0 -0
  845. /package/buildLibs/types/Mobile/{AreaM → PickerArea}/area-data.d.ts +0 -0
  846. /package/buildLibs/utils/Shared/{index40.css → index39.css} +0 -0
@@ -1,12 +0,0 @@
1
- "use strict";var Hs=Object.create;var xa=Object.defineProperty;var Us=Object.getOwnPropertyDescriptor;var zs=Object.getOwnPropertyNames;var Js=Object.getPrototypeOf,Ks=Object.prototype.hasOwnProperty;var Ws=(n,a,i,t)=>{if(a&&typeof a=="object"||typeof a=="function")for(let s of zs(a))!Ks.call(n,s)&&s!==i&&xa(n,s,{get:()=>a[s],enumerable:!(t=Us(a,s))||t.enumerable});return n};var Rt=(n,a,i)=>(i=n!=null?Hs(Js(n)):{},Ws(a||!n||!n.__esModule?xa(i,"default",{value:n,enumerable:!0}):i,n));const e=require("vue"),Ie=require("dayjs");require("dayjs/locale/zh-cn.js");require("dayjs/locale/en.js");const js=require("dayjs/plugin/localeData"),Ys=require("dayjs/plugin/objectSupport"),qs=require("dayjs/plugin/isSameOrAfter"),Xs=require("dayjs/plugin/isSameOrBefore"),Gs=require("dayjs/plugin/isoWeek"),Qs=require("dayjs/plugin/utc"),Zs=require("dayjs/plugin/timezone"),el=require("@popperjs/core"),li={};function Wo(n,a){li[n]=a}class o{static getTypeof(a){return typeof a}static _toStringCall(a){return Object.prototype.toString.call(a)}static isUndefined(a){return this.getTypeof(a)==="undefined"||a===null}static isNaN(a){return Number.isNaN(Number(a))}static isFinite(a){return Number.isFinite(Number(a))}static isBoolean(a){return this.getTypeof(a)==="boolean"}static isString(a){return this.getTypeof(a)==="string"}static isNonEmptyString(a){return!!(this.isString(a)&&!this.isEmpty(a))}static isFunction(a){return this.getTypeof(a)==="function"}static isObject(a){return!this.isUndefined(a)&&this.getTypeof(a)==="object"}static isBlob(a){return this._toStringCall(a)==="[object Blob]"}static isFile(a){return this._toStringCall(a)==="[object File]"}static isNumber(a){let i=!1;return this.isString(a)?/^(-)?(([1-9]\d*)|0)(\.\d+)?$/.test(a):(this.getTypeof(a)==="number"&&(i=!0),i)}static isInt(a){return this.isUndefined(a)||typeof a!="string"&&typeof a!="number"?!1:/^[1-9]\d*$|^0$/.test(a.toString())}static isHtml(a){return/<[a-z][a-z0-9]*(?:\s[^>]*)?>|<\/[a-z][a-z0-9]*>/i.test(a)}static isHtmlPair(a){return this.isString(a)?/<([a-z][a-z0-9-]*)[^>]*>[\s\S]*?<\/\1>/i.test(a):!1}static isJson(a){let i=!1;if(this.isString(a))try{const t=JSON.parse(a);this.isObject(t)&&(i=!0)}catch{}else this.isObject(a)&&(i=!0);return i}static isWindow(a){return!this.isUndefined(a)&&a===a.window}static _isEmptyObject(a){return this.isUndefined(a)?!0:Object.keys(a).length===0}static isArray(a){return Array.isArray(a)&&this._toStringCall(a)==="[object Array]"}static isLocationLngLat(a){let i=!1;if(!this.isEmpty(a)){let t;if(this.isString(a)?t=this.split(a):this.isArray(a)?t=a:t=[],t.length===2){const s=t[0],l=t[1],d=/^-?(180(\.0+)?|1[0-7]?\d?(\.\d+)?|[1-9]?\d?(\.\d+)?)$/,u=/^-?(90(\.0+)?|[1-8]?\d?(\.\d+)?)$/;i=d.test(s)&&u.test(l)}}return i}static isEmpty(a,i){let t=this.isUndefined(a);if(!t){const s=this.getTypeof(a);if(this.isString(a)?t=this.trim(a).length===0:this.isArray(a)?t=a.length===0:s==="object"&&(this.isFile(a)?t=!1:t=this._isEmptyObject(a)),!t&&!this.isUndefined(i)){let l=a;this.isNumber(a)&&(l=l.toString());let d=i;this.isNumber(i)&&(d=d.toString()),t=this.isEqual(l,d)}}return t}static isEqual(a,i){return Object.is(a,i)}static isEqualArr(a,i,t=!1){let s=!1;const l=this.isEmpty(a),d=this.isEmpty(i);if(l&&d)s=!0;else if(a.length===i.length)if(s=!0,t){for(let u=0;u<a.length;u++)if(a[u].toString()!==i[u].toString()){s=!1;break}}else{const u=this.getArrConvertJson(i);for(let r=0;r<a.length;r++)if(!this.isExistJsonKey(u,a[r].toString())){s=!1;break}}else s=!1;return s}static isEqualList(a,i,t=["id"]){let s=!1;const l=this.isEmpty(a),d=this.isEmpty(i);if(l&&d)s=!0;else if(a.length===i.length){const u=a.map(r=>t.map(c=>r[c].toString()).join(","));s=!0,i.some(r=>{const c=t.map(m=>r[m].toString()).join(",");if(!this.isExistValue(u,c))return s=!1,!0})}else s=!1;return s}static isContainArr(a,i){let t=!1;const s=this.isEmpty(a),l=this.isEmpty(i);return s&&l?t=!0:a.length>=i.length?(t=!0,i.some(d=>{if(!this.isExistValue(a,d))return t=!1,!0})):t=!1,t}static isExistValue(a,i){return this.isUndefined(a)?!1:a.includes?a.includes(i):a.indexOf(i)>-1}static isExistJsonKey(a,i){return this.isUndefined(a)?!1:Object.prototype.hasOwnProperty.call(a,i)}static osType(){if(typeof navigator>"u")return{isTablet:!1,isIOS:!1,isAndroid:!1,isMobile:!1,isPc:!0};const a=navigator.userAgent,i=/(?:Android)/.test(a),t=/(?:Firefox)/.test(a),s=/(?:iPad|PlayBook)/.test(a)||i&&!/(?:Mobile)/.test(a)||t&&/(?:Tablet)/.test(a),l=/(?:iPhone)/.test(a)&&!s;return{isTablet:s,isIOS:l,isAndroid:i,isMobile:l||i,isPc:!l&&!i}}static trim(a){if(this.isUndefined(a))return a;const i=a.toString();return i.trim?i.trim():i.replace(/^\s+|\s+$/gm,"")}static split(a,i=",",t=!0){i===" "&&(t=!1);let s;if(this.isEmpty(a))s=[];else{let l=a;i===","&&(l=l.replace(/,/g,",")),s=l.toString().split(i)}return t&&(s=s.filter(l=>!this.isEmpty(l))),s}static kebabCase(a){const i=a.replace(/([A-Z])/g," $1").trim();return this.split(i," ",!1).join("-").toLowerCase()}static getByteLen(a){let i=0;for(let t=0;t<a.length;t+=1)a.charAt(t).match(/[^\x00-\xff]/gi)!==null?i+=3:i+=1;return i}static getJsonClone(a,i=!1,t={}){if(i)return this._getJsonCloneDeep(a,t);{const s=this.isUndefined(t.exclude)?[]:t.exclude;if(s.length===0)return this.getJsonMerge(a);{const l={};return Object.keys(a).forEach(d=>{this.isExistValue(s,d)||(l[d]=a[d])}),l}}}static _getJsonCloneDeep(a,i={}){const t=this.isArray(a)?[]:{},s=this.isUndefined(i.exclude)?[]:i.exclude;return Object.keys(a).forEach(l=>{if(s.length===0||!this.isExistValue(s,l)){const u=a[l];this.isUndefined(u)||!this.isObject(u)?this.isArray(u)?t[l]=this.getListClone(u,!0):t[l]=u:t[l]=this._getJsonCloneDeep(u)}}),t}static getJsonCloneByKeyArr(a,i){const t={};return i.forEach(s=>{const l=a[s];t[s]=this.isUndefined(l)?"":this.isObject(l)?this.getJsonClone(l):l}),t}static getJsonCloneByKeyJson(a,i){const t=Object.keys(i);return this.getJsonCloneByKeyArr(a,t)}static getJsonCloneByRemoveArr(a,i){const t={};return i.length===0?a:(Object.keys(a).forEach(s=>{this.isExistValue(i,s)||(t[s]=a[s])}),t)}static getStringByJson(a,i){return this.isObject(a)?Object.keys(a).filter(t=>a[t]).join(i):""}static getJsonMerge(...a){return Object.assign({},...a)}static getJsonReversal(a){const i={};return Object.keys(a).forEach(t=>{i[a[t]]=t}),i}static getJsonMergeDeep(...a){const i={},t=a.length;for(let s=0;s<t;s++)this._mergeJsonDeep(i,a[s]||{});return i}static _mergeJsonDeep(a,i){Object.keys(i).forEach(t=>{const s=i[t];this.isUndefined(s)?a[t]=s:this.isArray(s)?a[t]=this.getListClone(s,!0):this.isObject(s)&&this.isExistJsonKey(a,t)?this._mergeJsonDeep(a[t],s):a[t]=s})}static getJsonMap(a,i,t=!1){const s={};if(!this.isEmpty(a)&&!this._isEmptyObject(i))for(const[l,d]of Object.entries(i)){let u=d.toString(),r="";if(u.indexOf("|")>-1){const c=this.split(u,"|");u=c[0],r=c[1]}if(u.indexOf(".")>-1){const c=this.split(u,".");let m=this.getJsonClone(a,!0);c.forEach((p,f)=>{const h=m[p],g=this.isEmpty(h);f===c.length-1?this.isUndefined(h)?m=t?"":h:g?m="":r&&r.length>0?m=this.isEmpty(h)?"":this.getValueByFormat(h,r):m=h:m=g?{}:h}),s[l]=this.isString(m)?this.trim(m):m}else if(this.isExistJsonKey(a,u)){const c=a[u];let m;this.isUndefined(c)?m=t?"":c:r&&r.length>0?m=this.isEmpty(c)?"":this.getValueByFormat(c,r):m=c,s[l]=this.isString(m)?this.trim(m):m}else t&&(s[l]="")}return s}static getJsonByList(a,i,t=!1){const s={};if(!this.isEmpty(a)){const l=i&&!this.isEmpty(i)?i:"id";a.forEach(d=>{let u="";t?i&&(u=this.convertStringFormat(i,d)):u=this.isExistJsonKey(d,l)?d[l].toString():"",u.length>0&&(s[u]=this.getJsonClone(d))})}return s}static getJsonByArr(a){const i={};return this.isEmpty(a)||a.forEach(t=>{i[t]=t}),i}static getGroupByList(a,i){const t={};return this.isEmpty(a)||a.forEach(s=>{const l=this.isExistJsonKey(s,i)?s[i].toString():"";l.length>0&&(this.isExistJsonKey(t,l)||(t[l]=[]),t[l].push(this.getJsonClone(s)))}),t}static getJsonByBlob(a){return new Promise((i,t)=>{const s=new FileReader;s.onload=()=>{try{const l=JSON.parse(s.result);i(l)}catch(l){t(l)}},s.onerror=t,s.readAsText(a)})}static getBase64ByFile(a){return new Promise(i=>{let t=null;if(a instanceof Blob?t=a:a&&a.length>0&&(t=a[0]),!(t instanceof Blob)){i("");return}const s=new FileReader;s.onload=l=>{i(l.target.result)},s.onerror=()=>{i("")},s.readAsDataURL(t)})}static getTreeList(a){let i=[];const t=[],s={},l={};return this.isEmpty(a)||(a.forEach(d=>{const u=d.id.toString(),r=d.parentId.toString();r==="0"&&t.push(u),s[u]=d,this.isExistJsonKey(l,r)||(l[r]=[]),l[r].push(d)}),t.forEach(d=>{i=i.concat(this._recursionChild(d,l,s))})),{tree:i,group:l,json:s,list:a}}static getTreeLastParent(a,i,t=!0){let s=[];return this.isExistJsonKey(i,a)&&(s=this._recursionParent(a,i),t||s.splice(0,1),s.reverse()),s}static _recursionChild(a,i,t){const s=[],l=this.getJsonClone(t[a]);return this.isExistJsonKey(i,a)&&(l.list=[],i[a].forEach(u=>{const r=u.id.toString();l.list=l.list.concat(this._recursionChild(r,i,t))})),s.push(l),s}static _recursionParent(a,i){let t=[];if(this.isExistJsonKey(i,a)){const s=i[a],l=s.parentId.toString();t.push(s),t=t.concat(this._recursionParent(l,i))}return t}static getListByTree(a,i={}){const t=this.isEmpty(i.idKey)?"id":i.idKey,s=this.isEmpty(i.cKey)?"list":i.cKey,l=this.isEmpty(i.pKey)?"parentId":i.pKey,d=this.isEmpty(i.topPV)?"0":i.topPV;return this._recursionListByTree(a,d,{idKey:t,cKey:s,pKey:l})}static _recursionListByTree(a,i,t){const s=[];return a.forEach(l=>{const d=this.getJsonClone(l,!1,{exclude:[t.cKey]});d[t.pKey]=i;const u=this.isUndefined(l[t.cKey]);if(d.isLastLevel=u,s.push(d),!u){const r=this._recursionListByTree(l[t.cKey],d[t.idKey],t);s.push(...r)}}),s}static getListClone(a,i=!1){return this.isEmpty(a)?[]:a.map(t=>this.isObject(t)?this.getJsonClone(t,i):t)}static getListMergeDeep(a,i,t="id"){const s=[];if(a.length>0){const l=this.getJsonByList(i,t);a.forEach(d=>{let u={},r=d[t];this.isEmpty(r)||(r=r.toString(),u=this.isExistJsonKey(l,r)?l[r]:{});const c=this.getJsonMergeDeep(u,d);s.push(c)})}return s}static getRecursionParentList(a,i,t="parentId"){let s=[];const l=i.toString();if(l!=="0"&&this.isExistJsonKey(a,l)){const d=a[l];s.push(d);const u=d[t].toString(),r=this.getRecursionParentList(a,u);this.isEmpty(r)||(s=s.concat(r))}return s}static getListExistValue(a,i,t="id"){let s,l=-1;return this.isEmpty(a)||a.forEach((d,u)=>{this.isExistJsonKey(d,t)&&d[t].toString()===i.toString()&&(s=this.getJsonClone(d),l=u)}),l===-1?null:{info:s,inx:l}}static getArrClone(a){return this.isEmpty(a)?[]:a.map(i=>i)}static getArrByList(a,i="id"){const t=[];return this.isEmpty(a)||a.forEach(s=>{this.isExistJsonKey(s,i)&&t.push(s[i])}),t}static getArrRemoveById(a,i){if(this.isEmpty(i))return a;const t=[],s=this.isArray(i)?i:this.split(i.toString()),l=this.getArrConvertJson(s);return a.forEach(d=>{this.isExistJsonKey(l,d.toString())||t.push(d)}),t}static getArrByMinMax(a=1,i){const t=[];for(let s=a;s<=i;s+=1)t.push(s);return t}static getArrUnique(a){const i=[];if(a.length>0){const t={};let s=null;for(let l=0;l<a.length;l+=1)s=a[l],s!==null&&!t[s]&&(i.push(s),t[s]=!0)}return i}static getArrConvertJson(a){const i={};return a.forEach(t=>{i[t.toString()]=!0}),i}static getArrAsc(a,i){let t;switch(i){case"date":t=(s,l)=>Date.parse(s)-Date.parse(l);break;case"number":t=(s,l)=>s-l;break;default:t=(s,l)=>this._arrSortString(s.toString(),l.toString())}return a.sort(t)}static getArrDesc(a,i){let t;switch(i){case"date":t=(s,l)=>Date.parse(l)-Date.parse(s);break;case"number":t=(s,l)=>l-s;break;default:t=(s,l)=>this._arrSortString(l.toString(),s.toString())}return a.sort(t)}static _arrSortString(a,i){let t=0;for(let s=0;;s++){if(!a[s]||!i[s]){t=a.length-i.length;break}const l=a[s],d=this._getChartType(l),u=i[s],r=this._getChartType(u);if(d[0]===r[0]){if(l===u)continue;d[0]==="zh"?t=l.localeCompare(u):d[0]==="en"?t=l.charCodeAt(0)-u.charCodeAt(0):t=l-u;break}else{t=d[1]-r[1];break}}return t}static _getChartType(a){return/^[0-9]$/.test(a)?["number",100]:/^[a-zA-Z]$/.test(a)?["en",200]:/^[\u4e00-\u9fa5]$/.test(a)?["zh",300]:["others",999]}static getZeroCount(a){if(a<=0)return"";const i=[];for(let t=0;t<a;t+=1)i.push("0");return i.join("")}static getFillZero(a,i=2,t="l"){const s=this.getZeroCount(i),l=this.isEmpty(a)?"":a.toString();let d="",u="";return t==="l"?(d=s+l,u=d.substring(d.length-i)):(d=l.toString()+s,u=d.substring(0,i)),u}static getRandom(a=3){const i=a>0?a:1;let t=Math.random();return t=Math.ceil(t*10**(i-1)),this.getFillZero(t,a,"r")}static getRandomRange(a,i,t=!0){const s=i-a,l=Math.random();return a+(t?Math.round(s*l):s*l)}static getCaptcha(a=6){const i="0123456789";let t="";for(let s=0;s<a;s++)t+=i.charAt(Math.floor(Math.random()*i.length));return t}static getValueByFormat(a,i,t={}){let s;switch(i){case"num":case"int":case"float":case"float2":case"float3":case"number":{if(this.isNumber(a))if(this.isEmpty(a))s=(this.isBoolean(t.isEmptyDefault)?t.isEmptyDefault:!0)?"0":a;else{let l=a.toString();if(l=this.isExistValue(l,",")?this.removeReplace(l):l,i==="number")s=Number(l);else{let d=0;if(i==="num"?d=this.isExistValue(l,".")?2:0:i==="int"?d=0:i==="float"?this.isNumber(t.decimalNum)&&(d=parseInt(t.decimalNum)):i==="float2"?d=2:i==="float3"&&(d=3),this.isBoolean(t.isRounding)?t.isRounding:!0)s=parseFloat(l).toFixed(d);else if(d>0){const c=this.split(l,"."),m=c[1].length;s=c[0]+"."+c[1].substring(0,m>d?d:m)}else s=parseInt(l).toString();s=Number(s).toFixed(d),(this.isBoolean(t.isThousands)?t.isThousands:!0)&&(s=this.getFormatThousands(s))}}else s=a;break}case"date":case"dateTime":case"time":{if(this.isEmpty(a))s=a;else{let l="";this.isEmpty(t.dateFormat)?i==="dateTime"?l="YYYY-MM-DD HH:mm:ss":i==="time"?l="HH:mm:ss":l="YYYY-MM-DD":l=t.dateFormat;const d=li[i];d?s=d(a,l):s=a}break}case"string":s=a.toString();break;case"intArray":s=this.split(a).map(l=>parseInt(l));break;default:s=a}return s}static getHourInterval(a,i=""){const t=this.isEmpty(i)?a:i;return`${this.getFillZero(a)}:00-${this.getFillZero(t)}:59`}static getFormatThousands(a){if(!this.isNumber(a))return"";const i=this.split(a.toString(),".");return i[0].replace(/(\d{1,3})(?=(?:\d{3})+(?!\d))/g,"$1,")+(i.length>1?`.${i[1]}`:"")}static getNumCeil(a,i={}){if(!this.isNumber(a))return 0;const t=Number(a),s=t<0,l=Math.abs(t);if(l===0)return 0;const d=l<1;let u=0,r=l.toString(),c=-1;if(d){if(c=-1,l>0){const O=this.split(r,".")[1];r=Number(O).toString(),u=O.length-r.length}}else u=0,c=r.indexOf("."),c>-1&&(r=r.replace(".",""));const m=this.isBoolean(i.isCeil)?i.isCeil:!0,p=this.isUndefined(i.inxPos)?2:parseInt(i.inxPos),f=this.isBoolean(i.isEndFive)?i.isEndFive:!1,h=this.isBoolean(i.isRounding)?i.isRounding:!1;let g,y="";p<r.length?(g=r.substring(0,p),y=r.substring(p)):g=r;let V="";const E=m||h&&y.length>0&&parseInt(y.substring(0,1))>=5?(parseInt(g)+1).toString():parseInt(g).toString(),B=parseInt(E.substring(E.length-1));if(f)if(B===5||B===0)V=E;else{const O=parseInt(E.substring(0,p-1));B>5?V=`${O+1}0`:B<5&&(V=`${O}5`),E.length>p&&V.length===p&&(V=`${V}0`)}else V=E;let T="",D=0;c===-1?D=y.length:c<p?(D=0,V=(Number(V)/((p-c)*10)).toString()):c>p&&(D=c-p),T=this.getZeroCount(D),d&&(V=`0.${this.getZeroCount(u)}${V}`);const x=V+T;return Number(x)*(s?-1:1)}static removeReplace(a,i=","){if(this.isUndefined(a))return"";const t=new RegExp(`[${i}]`,"g");return a.toString().replace(t,"")}static conversionEmptyZero(a,i,t){const s=a;if(!this.isEmpty(i)){let l=0,d=0;if(t){let u={};this.isString(t)?u.emptyDef=t:this.isObject(t)&&(u=t);const r=this.isEmpty(u.undefinedDef);r||(d=u.undefinedDef),this.isEmpty(u.emptyDef)||(l=u.emptyDef,r&&(d=u.emptyDef))}i.forEach(u=>{this.isEmpty(a[u])&&(this.isUndefined(a[u])?s[u]=d:s[u]=l)})}return s}static conversionPercentage(a,i,t=!0){const s=a;return this.isEmpty(i)||i.forEach(l=>{const d=a[l];this.isEmpty(d)?s[l]=0:this.isNumber(d)?s[l]=t?d*100:d/100:s[l]=d}),s}static convertStringFormat(a,i){let t=a;return this.isEmpty(i)||(t=a.replace(/[$]{[^}]+}/g,s=>{const l=s.replace("${","").replace("}","");return this.isExistJsonKey(i,l)?i[l]:s})),t}static convertStringFormatEncodeHTML(a,i){let t=a;return this.isEmpty(i)||(t=a.replace(/[$]{[^}]+}/g,s=>{const l=s.replace("${","").replace("}","");if(this.isExistJsonKey(i,l)){const d=i[l];return this.isString(d)?this.encodeHTML(d):d}return s})),t}static getQueryString(a,i){const t=new RegExp(`(^|&)${i}=([^&]*)(&|$)`,"i"),s=a.substring(a.indexOf("?")+1).match(t);return s!==null?decodeURI(s[2]):""}static getQueryStringByHash(a){return this.getQueryString(window.location.hash,a)}static encodeHTML(a){return String(a).replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#39;")}static removeHTMLTags(a){return a.replace(/<[^>]*>/g,"")}static requestAnimationFrame(a){const i=window.requestAnimationFrame||window.webkitRequestAnimationFrame||window.mozRequestAnimationFrame||window.oRequestAnimationFrame||window.msRequestAnimationFrame;return i?i.call(window,a):window.setTimeout(a,1e3/60)}static cancelAnimationFrame(a){const i=window.cancelAnimationFrame||window.webkitCancelAnimationFrame||window.mozCancelAnimationFrame||window.oCancelAnimationFrame||window.msCancelAnimationFrame;i?i.call(window,a):window.clearTimeout(a)}}class tl{promise(a){return new Promise(i=>{i(a)})}promiseFun(a){return new Promise(i=>{a&&a(i)})}resolve(a){return Promise.resolve(a)}all(a){return Promise.all(a)}allByJson(a){return new Promise(i=>{if(o.isEmpty(a))return i({result:{},errors:{}});let t=0;const s=Object.keys(a),l=s.length,d={},u={},r=c=>{Promise.resolve(a[c]).then(m=>{t+=1,d[c]=m,t===l&&i({result:d,errors:u})},m=>{t+=1,u[c]=m,t===l&&i({result:d,errors:u})})};s.forEach(c=>{r(c)})})}}const ri=new tl;let nl=class{_elCanvasTextWidth;constructor(){this._elCanvasTextWidth=null}_getArrClassBySplit(a){return a.split(" ").filter(i=>!o.isEmpty(i))}_getClasssByReal(a,i){return a.filter(t=>!o.isExistValue(i,t)&&!o.isEmpty(t))}onListener(a,i,t,s=!1){a&&i&&t&&a.addEventListener(i,t,s)}offListener(a,i,t,s=!1){a&&i&&t&&a.removeEventListener(i,t,s)}getTextWidth(a,i="normal 12px Microsoft YaHei"){this._elCanvasTextWidth||(this._elCanvasTextWidth=document.createElement("canvas"));const t=this._elCanvasTextWidth.getContext("2d");return t.font=i,t.measureText(a).width}getClassNameJson(a){const i={};return o.isNonEmptyString(a)&&this._getArrClassBySplit(a).forEach(t=>{i[t]=!0}),i}conversionClassToString(...a){return this.getAddClass(a)}getAddClass(...a){let i=[];return a.forEach(t=>{if(o.isString(t)){const s=this._getArrClassBySplit(t);i=i.concat(this._getClasssByReal(s,i))}else if(o.isArray(t))i=i.concat(this._getClasssByReal(t,i));else if(o.isObject(t))for(const[s,l]of Object.entries(t))o.isExistJsonKey(t,s)&&l?i.push(s):i=i.filter(d=>d!==s||d===s&&l)}),i.join(" ")}getRemoveClass(a,i){const t=this._getArrClassBySplit(i);return this._getArrClassBySplit(a).filter(l=>!o.isExistValue(t,l)).join(" ")}checkHasClass(a,i){const t=this._getArrClassBySplit(a),s=this._getArrClassBySplit(i);return o.isContainArr(t,s)}_getBoundingClientRect(a){const i=o.isUndefined(a.getBoundingClientRect)?{}:a.getBoundingClientRect(),t={width:i.width||0,height:i.height||0,top:i.top||0,right:0,bottom:0,left:i.left||0,x:i.left||0,y:i.top||0},s=this.getWinHeight(),l=this.getWinWidth();return t.right=l-i.right||0,t.bottom=s-i.bottom||0,t}_getWindow(a){if(a&&a.toString()!=="[object Window]"){const i=a.ownerDocument;return i&&i.defaultView||window}return a}isElementHtml(a){const i=this._getWindow(a).HTMLElement;return a instanceof i||a instanceof HTMLElement}isElementBody(a){return o.isUndefined(a)?!1:this.isElementHtml(a)&&a.tagName.toLocaleLowerCase()==="body"}getWinScrollTop(){return document.documentElement.scrollTop||document.body.scrollTop||window.pageYOffset}getWinWidth(){return document.documentElement.clientWidth||document.body.clientWidth||window.innerWidth}getWinHeight(){return document.documentElement.clientHeight||document.body.clientHeight||window.innerHeight}getStyle(a){return window.getComputedStyle?window.getComputedStyle(a,null):a.currentStyle}_isElementScroll(a){const i=this.getStyle(a),t=i.overflow,s=i.overflowX,l=i.overflowY;return/auto|scroll|overlay|hidden/.test(t+l+s)}isHidden(a){return this.getStyle(a).display==="none"}isHiddenParent(a){let i=!1,t=a,s=!1;for(;t&&t.nodeType!==9&&!s;)t.nodeType===1&&(s=this.isHidden(t),s&&(i=!0)),t=t.parentNode;return i}getParentCheckBody(a,i,t=!0){let s=null;return i?o.isString(i)?i.toLocaleLowerCase()!=="body"&&(s=this.getParent(a,i)):this.isElementBody(i)||(t?i.contains(a)&&(s=i):s=i):this.isElementBody(a.parentNode)||(s=a.parentNode),s}getParent(a,i,t,s=!0){if(o.isEmpty(i))return a.parentNode;let d=null;const u=!o.isUndefined(t);if(this._checkElementByAttr(a,i))d=a;else{let c=a.parentNode,m=!1;for(;c&&c.nodeType!==9&&!m;)c.nodeType===1&&(m=this._checkElementByAttr(c,i),m?d=c:u&&(m=c===t,m&&s&&(d=c))),c=c.parentNode}return d}getParentList(a,i){const t=o.isEmpty(i)?"body":i;return this._recursionParents(a,t)}_recursionParents(a,i){const t=[];if(this._checkElementByAttr(a,i))t.push(a);else if(a.parentNode&&a.parentElement&&!this.isElementBody(a.parentElement)){t.push(a.parentNode);const s=this._recursionParents(a.parentNode,i);t.push(...s)}return t}getParentScrollList(a,i,t=!0){const s=[];return this.getParentList(a,i).forEach(d=>{this._isElementScroll(d)&&(t?s.push(d):this._checkElementByAttr(d,i)||s.push(d))}),s}_checkElementByAttr(a,i){let t=!1;if(!o.isEmpty(i))if(o.isString(i)){const s=i.substr(0,1),l=i.substring(1);switch(s){case"#":t=a.id===l;break;case".":t=o.isString(a.className)?o.isExistValue(a.className.split(" "),l):!1;break;default:t=a.tagName.toLocaleLowerCase()===i}}else this.isElementHtml(i)&&(t=a===i);return t}getOffset(a,i=null){const t=this.getPositionView(a,i);if(t.viewEl)return{top:t.top+t.viewEl.scrollTop-t.viewEl.clientTop,left:t.left+t.viewEl.scrollLeft-t.viewEl.clientLeft};{const l=(a&&a.ownerDocument).documentElement,d=this._getWindow(l);return{top:t.top+(d.pageYOffset||l.scrollTop)-(l.clientTop||0),left:t.left+(d.pageXOffset||l.scrollLeft)-(l.clientLeft||0)}}}getPositionView(a,i=null){const t={top:0,left:0,viewEl:null};if(!this.isElementHtml(a))return t;const s=this._getBoundingClientRect(a);t.top=s.top,t.right=s.right,t.bottom=s.bottom,t.left=s.left,t.width=s.width,t.height=s.height;const l={top:0,right:0,bottom:0,left:0},d=o.isUndefined(i)?null:this.getParentCheckBody(a,i,!0);if(d){const u=this._getBoundingClientRect(d);l.top=u.top,l.right=u.right,l.bottom=u.bottom,l.left=u.left,t.viewWidth=u.width,t.viewHeight=u.height,t.top=s.top-(l.top<0?0:l.top),t.right=s.right-(l.right<0?0:l.right),t.bottom=s.bottom-(l.bottom<0?0:l.bottom),t.left=s.left-(l.left<0?0:l.left),t.elViewBox={top:s.top-l.top,right:s.right-l.right,bottom:s.bottom-l.bottom,left:s.left-l.left}}return t.viewEl=d,t}getPosition(a,i=null){const t=o.isUndefined(i)?a.parentNode:i;return this.getPositionView(a,t)}getElementIndex(a){return this.getPrevAll(a).length}getPrev(a){if(o.isUndefined(a.previousElementSibling)){let i=a.previousSibling;for(;i&&i.nodeType!==1;)i=i.previousSibling;return i}else return a.previousElementSibling}getPrevAll(a){const i=[];let t=this.getPrev(a);for(;t;)i.push(t),t=this.getPrev(t);return i.reverse()}getNext(a){if(o.isUndefined(a.nextElementSibling)){let i=a.nextSibling;for(;i&&i.nodeType!==1;)i=i.nextSibling;return i}else return a.nextElementSibling}insertAfter(a,i){const t=a.parentNode;t.lastChild==a?t.appendChild(i):t.insertBefore(i,a.nextSibling)}getFocusSelection(a){const i={};if(o.isUndefined(a.selectionStart)){a.focus();const t=document.selection.createRange();i.length=t.text.length,t.moveStart("character",-a.value.length),i.end=t.text.length,i.start=i.end-i.length}else i.start=a.selectionStart,i.end=a.selectionEnd,i.length=i.end-i.start;return i}setFocusSelection(a,i,t){if(o.isUndefined(a.selectionStart)){a.focus();const s=a.createTextRange();s.collapse(!0),s.moveEnd("character",t),s.moveStart("character",i),s.select()}else a.selectionStart=i,a.selectionEnd=t}calculationDropdownPosition(a,i,t,s,l){const d=l?this.getParentCheckBody(a,l):null,u=o.isUndefined(d),r=i.offsetWidth,c=i.offsetHeight,m=t.offsetWidth,p=t.offsetHeight;let f=0,h=0;o.isUndefined(s)||(f=s.offsetWidth,h=s.offsetHeight);const g=f/2,y=this.getWinHeight(),V=this.getWinWidth();let E=0,B=0,T={top:0,left:0},D={top:0,left:0};u?(E=V,B=y,T=this.getOffset(a),D=this.getPositionView(a)):(E=d.clientWidth,B=d.clientHeight,T=this.getOffset(a,d),D=this.getPositionView(a,d));const x=D.top,O=m+f,w=p+h,M=c+w,b={winWidth:V,winHeight:y,containerWidth:E,containerHeight:B,controlOffset:T,controlPosView:D,textWidth:r,textHeight:c,dropDownWidth:m,dropDownHeight:p,arrowWidth:f,arrowHeight:h};let N="down";x+M>B&&(x>w||T.top>w)&&(N="up"),b.dropDownPosDown=N;let J="up";x<w&&T.top<w&&(J="down"),b.dropDownPosUp=J;let q="left";D.left<O&&T.right>=w&&(q="right"),b.dropDownPosLeft=q;const z="right";D.right<O&&T.left>=w&&(q="left"),b.dropDownPosRight=z;let H="left";E-T.left<m&&(H=T.left+r>=m?"right":"left"),b.arrowPosLeft=H;let v="right";T.left+r<m&&(v=E-T.left>=m?"left":"right"),b.arrowPosRight=v;const S="center";b.arrowPosCenterLR=S;const C={dropDownLeft:0,arrowLeft:0},$=this.getOffset(i,a),k=r/2,I=t.clientWidth,L=$.left+k;let _=L-I/2;const R=!o.isEmpty(l),P=R&&T.left||0,Q=R?P+_:D.left+_,oe=0,ue=V-I;let Y=Q;Y<oe?Y=oe:Y>ue&&(Y=ue),_=R?Y-P:Y-D.left,ue<oe&&(_=R?oe-P:oe-D.left);const Z=L-_;return C.dropDownLeft=_,C.arrowLeft=Z-g,b.arrowPosCenterLRInfo=C,b.arrowPosTop="top",b.arrowPosBottom="bottom",b.arrowPosCenterTB="center",b}getElementData(a){const i={};if(!o.isEmpty(a))for(const[t,s]of Object.entries(a)){const l=t.split("-"),d=[];l.forEach((u,r)=>{if(r>0){const c=u.toLowerCase();r===1?d.push(c):d.push(c.replace(c[0],c[0].toUpperCase()))}}),d.length>0&&(i[d.join("")]=s)}return i}async getTextDataByFile(a){const i=[];if(!o.isEmpty(a))for(let t=0;t<a.length;t++){const s=await this._getTextDataFileOne(a[t]);i.push(...s)}return i}_getTextDataFileOne(a){return ri.promiseFun(i=>{const t=new FileReader;t.readAsText(a,"utf-8"),t.onload=s=>{const l=[];s.target.result.split(`
2
- `).forEach(d=>{const u=o.trim(d);o.isEmpty(u)||l.push(u)}),i(l)}})}getClientXY(a){let i,t;return a.type==="touchend"?(t=a.changedTouches[0].clientY,i=a.changedTouches[0].clientX):a.type.startsWith("touch")?(t=a.touches[0].clientY,i=a.touches[0].clientX):(t=a.clientY,i=a.clientX),{clientX:i,clientY:t}}};const de=new nl,ol=["id"],Gt=e.defineComponent({name:"ClBadge",__name:"Index",props:{id:String,className:String,num:[String,Number],color:{type:String,default:"default"},colorSty:String,maxNum:{type:Number,default:-1},isHideZero:{type:Boolean,default:!0},isDot:{type:Boolean,default:!1}},setup(n){const a=n,i=a.id,t=()=>{let u="";if(!o.isEmpty(a.num)){const r=Number(a.num);o.isFinite(r)?r===0&&a.isHideZero?u="":r>a.maxNum&&a.maxNum>0?u=`${a.maxNum}+`:u=r.toString():u=""}return u},s=e.computed(()=>t()),l=e.computed(()=>{let u={badge:!0};return!o.isEmpty(a.color)&&o.isEmpty(a.colorSty)&&(u[`bg-${a.color}`]=!0),u=o.getJsonMerge(u,de.getClassNameJson(a.className)),a.isDot&&o.isEmpty(t())&&(u["badge-dot"]=!0),u}),d=e.computed(()=>{const u={};return a.colorSty&&!o.isEmpty(a.colorSty)&&(u["background-color"]=a.colorSty),u});return(u,r)=>(e.openBlock(),e.createElementBlock("span",{id:e.unref(i),class:e.normalizeClass(l.value),style:e.normalizeStyle(d.value),role:"status"},e.toDisplayString(s.value),15,ol))}}),al={common:{submit:"确定",save:"保存",cancel:"取消",update:"修改",close:"关闭",delete:"删除",deleteAll:"全部删除",upload:"上传",download:"下载",preview:"预览",restore:"还原",clear:"清除",clearEmpty:"清空",clearAll:"全部清除",copy:"复制",custom:"自定义",loading:"加载中",noDataText:"暂无数据",noResultsText:"未找到结果",checkboxAll:"全选",selected:"已选",count:"个",add:"添加",checkAddMax:"最多添加",checkAddMin:"最少保留",pleaseSelect:"请选择"},validate:{required:"此项不能为空",number:"请输入数字",integer:"请输入整数",integerPositive:"请输入正整数",alphanum:"请输入数字或字母",email:"邮箱格式不正确",minLen:"输入值的长度不能小于 %s 个字",maxLen:"输入值的长度不能大于 %s 个字",minByte:"输入值的长度不能小于 %s 个字节",maxByte:"输入值的长度不能大于 %s 个字节",minGreater:"输入值请大于 %s",maxGreater:"输入值请小于 %s",minGreaterEqual:"输入值请大于或等于 %s",maxGreaterEqual:"输入值请小于或等于 %s",phone:"手机号不正确",equalto:"两次输入值不同"},dataTime:{am:"上午",pm:"下午",year:"年",prevYear:"上一年",prevMonth:"上一月",nextYear:"下一年",nextMonth:"下一月",prevYear10:"前十年",nextYear10:"后十年",today:"今天",yesterDay:"昨天",pastDays7:"过去7天",pastDays30:"过去30天",montCurrent:"本月",montLast:"上月",montLately6:"最近半年",yearCurrent:"今年",yearLast:"去年",rangeStartLabel:"开始",checkEndMinLabel:"结束时间不能小于设置的最小时间",checkStartMaxLabel:"时间不能大于设置的最大时间",checkStartMinLabel:"时间不能小于设置的最小时间",checkStartEndLabel:" ",checkRangeEmptyLabel:"请选择完整的开始时间,结束时间"},fileUpload:{checkImageWHLabel:"图片宽高不匹配",checkSuffixMimeLabel:"类型不匹配",checkSizeLabel:"大小不匹配",uploadFile:"上传文件"},weekHour:{daily:"每日",monday:"周一",tuesday:"周二",wednesday:"周三",thursday:"周四",friday:"周五",saturday:"周六",sunday:"周日",weekday:"工作日",weekend:"周末",restDay:"休息日",dawn:"凌晨",morning:"上午",noon:"中午",afternoon:"下午",evening:"傍晚",night:"晚上",selected:"已定向",selectedNot:"未定向"},paginate:{page:"页",pageStrip:"页/条",jumpTo:"跳转至",statistic:"显示第 ${s} 至 ${e} 项结果,共 ${_total} 项"},xEditable:{required:"此项不能为空",submitCallback:"submitCallback的返回格式不正确"}},il={common:{submit:"Submit",save:"Save",cancel:"Cancel",update:"Modify",close:"Close",delete:"Delete",deleteAll:"Delete All",upload:"Upload",download:"Download",preview:"Preview",restore:"Restore",clear:"Clear",clearEmpty:"Clear All",clearAll:"Clear All",copy:"Copy",custom:"Custom",loading:"Loading",noDataText:"No Data",noResultsText:"No Result",checkboxAll:"Select All",selected:"Selected",count:"Count",add:"Add",checkAddMax:"Add Maximum",checkAddMin:"Add Minimum",pleaseSelect:"Select"},validate:{required:"Required",number:"Please enter number",integer:"Please enter integer",integerPositive:"Please enter positive integer",alphanum:"Please enter number or letter",email:"Error Email",minLen:"Cannot less than %s characters",maxLen:"Cannot more than %s characters",minByte:"Cannot less than %s Bytes",maxByte:"Cannot more than %s Bytes",minGreater:"Must more than %s",maxGreater:"Must less than %s",minGreaterEqual:"Cannot less than %s",maxGreaterEqual:"Cannot more than %s",phone:"Error phone number",equalto:"Different Value"},dataTime:{am:"am",pm:"pm",year:"year",prevYear:"Last Year",prevMonth:"Last Month",nextYear:"Next Year",nextMonth:"Next Month",prevYear10:"Last Decade",nextYear10:"Next Decade",today:"Today",yesterDay:"Yesterday",pastDays7:"Last 7 Days",pastDays30:"Last 30 Days",montCurrent:"This Month",montLast:"Last Month",montLately6:"Last Half Year",yearCurrent:"This Year",yearLast:"Last Year",rangeStartLabel:"Start",checkEndMinLabel:"Error end time",checkStartMaxLabel:"Error end time",checkStartMinLabel:"Error start time",checkStartEndLabel:"End time cannot before start time",checkRangeEmptyLabel:"Select start and end time"},fileUpload:{checkImageWHLabel:"Error image dimension",checkSuffixMimeLabel:"Error type",checkSizeLabel:"Error file size",uploadFile:"Upload File"},weekHour:{daily:"Daily",monday:"Monday",tuesday:"Tuesday",wednesday:"Wednesday",thursday:"Thursday",friday:"Friday",saturday:"Saturday",sunday:"Sunday",weekday:"Weekday",weekend:"Weekend",restDay:"Rest day",dawn:"Midnight",morning:"AM",noon:"Noon",afternoon:"PM",evening:"Evenfall",night:"Evening",selected:"Include",selectedNot:"Exclude"},paginate:{page:"Page",pageStrip:"Lines/Page",jumpTo:"Page to",statistic:"Records ${s} to ${e} , ${_total} Records in Total"},xEditable:{required:"Required",submitCallback:"Error SubmitCallback"}};Ie.locale("zh-cn");Ie.extend(js);Ie.extend(Ys);Ie.extend(qs);Ie.extend(Xs);Ie.extend(Gs);Ie.extend(Qs);Ie.extend(Zs);let Ba=!1;class ze{static objDay=Ie;static timezone="PRC";static async ensureLunar(){if(Ba)return;const a=await import("dayjs-lunar");Ie.extend(a.default),Ba=!0}static initDay(a){return(o.isUndefined(a)?Ie():a).tz(this.timezone)}static getDayjsObject(a){if(o.isEmpty(a)&&!(a instanceof Date))return this.initDay(Ie());if(Ie.isDayjs(a))return this.initDay(a.clone());let i;return a instanceof Date?i=a:o.isString(a)?i=a.replace(/[/]/g,"-").replace(/:/g,":"):o.isInt(a)?i=new Date(parseInt(a,10)):o.isObject(a)&&(i=a),this.initDay(Ie(i,"YYYY-MM-DD HH:mm:ss"))}static initFormat(a){let i={value:"",format:"YYYY-MM-DD"},t;return o.isObject(a)?Ie.isDayjs(a)?t=a:(a.format&&(i=o.getJsonMerge(i,a)),a.value||a.format?t=this.getDayjsObject(a.value||""):t=this.getDayjsObject(a)):t=this.getDayjsObject(a),t.format(i.format)}static addTime(a,i,t="days"){return this.getDayjsObject(a).add(i,t)}static subtractTime(a,i,t="days"){return this.getDayjsObject(a).subtract(i,t)}static diffTime(a,i,t="millisecond"){return this.getDayjsObject(a).diff(this.getDayjsObject(i),t)}}Wo("date",(n,a)=>ze.initFormat({value:n,format:a}));Wo("dateTime",(n,a)=>ze.initFormat({value:n,format:a}));Wo("time",(n,a)=>ze.initFormat({value:n,format:a}));class sl{_type;_typeDef;_packageData;constructor(){this._type="zh_cn",this._typeDef="zh_cn",this._packageData={zh_cn:al,en:il}}initMerge(a){const i=o.isEmpty(a.type);return i||(this._type=a.type),o.isEmpty(a.packageData)||(i?this._packageData[this._typeDef]=o.getJsonMergeDeep(this._packageData[this._typeDef],a.packageData):this._packageData=o.getJsonMergeDeep(this._packageData,a.packageData)),{type:this._type,packageData:this._packageData}}_getType(){let a=this._type;return o.isEmpty(a)&&(a=this._typeDef),{type:a,def:this._typeDef}}_getData(a){let i={};const t=this._packageData;if(a)i=t[a];else{const s=this._getType();o.isExistJsonKey(t,s.type)&&(i=t[s.type]),o.isEmpty(i)&&(i=t[s.def])}return i}_getKeyValue(a,i){let t;if(o.isExistValue(a,".")){const s=o.split(a,".");let l=o.getJsonClone(i,!0);s.forEach((d,u)=>{const r=l[d];u===s.length-1?l=r:l=o.isEmpty(r)?{}:r}),t=l}else t=i[a];return t}_getKey(a,i){let t;const s=i?this._getData(i):this._getData();return o.isEmpty(s)||(t=this._getKeyValue(a,s),o.isObject(t)&&(t=o.getJsonClone(t,!0))),t}getType(){return this._getType()}getAll(){return this._getData()}getCommon(){const a=this._getKey("common"),i=this._getKey("common",this._typeDef);return o.getJsonMergeDeep(i||{},a||{})}getValue(a){let i=this._getKey(a);return o.isEmpty(i)&&(i=this._getKey(a,this._typeDef)),i}getPage(a){let i={};const t=this.getCommon();if(a==="common")i=t;else{const s=this._getKey(a,this._typeDef),l=this._getKey(a),d=o.getJsonMergeDeep(s,l);let u={};if(o.isExistValue(a,".")){const r=o.split(a,".");r[r.length-1]="common";const c=r.join("."),m=this._getKey(c,this._typeDef),p=this._getKey(c);u=o.getJsonMergeDeep(m,p)}i=o.getJsonMerge(d,{common:t,pageCommon:u})}return i}setType(a){switch(this._type=a,a){case"zh_cn":ze.objDay.locale("zh-cn");break;case"en":ze.objDay.locale("en");break}}}const nt=new sl,ll={zh_cn:{common:{confirm:"确认",submit:"提交",search:"搜索",remove:"移除",clearInput:"清除输入内容",clearAll:"清除全部",loading:"加载中",overlay:"遮罩层",breadcrumb:"面包屑导航",copy:"复制",showPassword:"显示密码",hidePassword:"隐藏密码",increase:"增加",decrease:"减少",close:"关闭",dialog:"对话框",textarea:"文本输入区域",expand:"展开",collapse:"折叠",areaTitle:"地区选择"}},en:{common:{confirm:"Confirm",submit:"Submit",search:"Search",remove:"Remove",clearInput:"Clear input",clearAll:"Clear all",loading:"Loading",overlay:"Overlay backdrop",breadcrumb:"Breadcrumb",copy:"Copy",showPassword:"Show password",hidePassword:"Hide password",increase:"Increase",decrease:"Decrease",close:"Close",dialog:"Dialog",textarea:"Text input area",expand:"Expand",collapse:"Collapse",areaTitle:"Select region"}}},an=e.reactive({}),rl=n=>{o.isObject(n)&&Object.keys(n).forEach(a=>{const i=n[a],t=an[a];if(o.isUndefined(i)){delete an[a];return}if(o.isObject(i)){an[a]=o.getJsonMergeDeep(t||{},i);return}o.isObject(t)||(an[a]=i)})},Nt=n=>an[n];nt.initMerge({packageData:ll});const cl="locale",ul="zh_cn";function Da(){const n=Nt(cl);if(typeof n=="string"&&n.length>0)return n;const a=nt.getType();if(typeof a=="string"&&a.length>0)return a;if(a&&typeof a=="object"&&"type"in a){const i=a.type;if(typeof i=="string"&&i.length>0)return i}return ul}function ci(){const n=e.ref(Da());return e.watch(Da,a=>{n.value=a}),{optLocale:n}}function qn(){const{optLocale:n}=ci(),a=e.ref({}),i=()=>{const t=nt.getCommon()||{},s={};Object.keys(t).forEach(l=>{const d=t[l];typeof d=="string"&&(s[l]=d)}),a.value=s};return i(),e.watch(n,i),{optA11yText:a}}const Le=()=>{const n=e.ref({}),{optLocale:a}=ci(),i=r=>{n.value=nt.getPage(r)};let t="";const s=r=>{t=r,i(r)};return e.watch(a,()=>{t&&i(t)}),{optPageLanguage:n,optLocale:a,getPageLanguage:s,getLanguageValue:r=>nt.getValue(r),getLanguageType:()=>nt.getType(),getCommonText:(r,c)=>{const m=nt.getValue(`common.${r}`);return typeof m=="string"&&m.length>0?m:c}}},dl=["id","aria-label"],ml=["onClick"],pl={key:1},fl={class:"breadcrumb-item"},ui=e.defineComponent({name:"ClBreadcrumb",__name:"Index",props:{id:String,className:String,list:{type:Array,default:()=>[]},title:{type:String,default:""}},emits:{onClickUrl:(n,a)=>!0},setup(n,{emit:a}){const{optA11yText:i}=qn(),t=n,s=a,l=`breadcrumb-${o.getRandom(5)}`,d=t.id,u=e.computed(()=>{const f={"panel-breadcrumb":!0};return o.getJsonMerge(f,de.getClassNameJson(t.className))}),r=e.computed(()=>!Array.isArray(t.list)||o.isEmpty(t.list)?[]:t.list.slice(0,-1).filter(Boolean)),c=e.computed(()=>{if(!Array.isArray(t.list)||o.isEmpty(t.list))return"";const f=t.list[t.list.length-1];return o.isEmpty(t.title)?f?.name??"":t.title}),m=f=>!o.isEmpty(f),p=(f,h)=>{s("onClickUrl",f,h)};return(f,h)=>{const g=e.resolveComponent("router-link");return e.openBlock(),e.createElementBlock("ol",{id:e.unref(d),class:e.normalizeClass(u.value),"aria-label":e.unref(i).breadcrumb||"面包屑导航"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(y,V)=>(e.openBlock(),e.createElementBlock("li",{class:"breadcrumb-item",key:`${l}-${V}`},[m(y.href)?(e.openBlock(),e.createBlock(g,{key:0,to:y.href},{default:e.withCtx(()=>[e.createElementVNode("span",{onClick:E=>p(y,E)},e.toDisplayString(y.name??""),9,ml)]),_:2},1032,["to"])):(e.openBlock(),e.createElementBlock("span",pl,e.toDisplayString(y.name??""),1))]))),128)),e.createElementVNode("li",fl,[e.createElementVNode("span",null,e.toDisplayString(c.value),1)])],10,dl)}}}),Ia="[ui-kit]";function Ta(){const n=Nt("debug"),a=!1;return n===!0?{warn:!0,error:!0}:n===!1?{warn:!1,error:!1}:n&&typeof n=="object"?{warn:n.warn??a,error:n.error??!0}:{warn:a,error:!0}}function Na(n,a){return[n?`${Ia}[${n}]`:Ia,...a]}const Se={warn(n,...a){Ta().warn&&console.warn(...Na(n,a))},error(n,...a){Ta().error&&console.error(...Na(n,a))}},hl=["id","aria-label"],lt=e.defineComponent({name:"ClLoad",__name:"Index",props:{id:String,className:String,theme:{type:String,default:"rotaryLine",validator:n=>["rotaryLine","circleNotch","circleBubble","ballColor4","dotTyping","dotWave","dotBounce","dotPulse","dotOrbit","dotFlow","dotSlide","dotSlider","dotFold","dotSquare","barEqualizer","barWave","barPulse","barStretch","barMeter","barBounce","barRamp","ringRotate","ringDot","ringPulse","ringClip","ringFan","circleSpinner","dotRipple","dotRipple3","ringCross","squareTrace","squareTrace2","crossMove","snakePath","squareMirror","dotPulse5","diamondShuttle","barStream","newtonCradle","dotSpin","orbitSwap","typingBounce","ringGlow","toastRing"].indexOf(n)!==-1},size:{type:String,default:"small",validator:n=>["xxl","xl","large","small","xs"].indexOf(n)!==-1},color:{type:String,default:""}},setup(n){const{optA11yText:a}=qn(),i=n,t=i.id,s={rotaryLine:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./RotaryLine-Cwu3YLpU.cjs"))),circleNotch:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./CircleNotch-D9prya89.cjs"))),circleBubble:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./CircleBubble-BszXrNmg.cjs"))),ballColor4:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BallColor4-BahMtWFj.cjs"))),dotTyping:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotTyping-QDey1yRa.cjs"))),dotWave:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotWave-DRXlC1W2.cjs"))),dotBounce:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotBounce-7MaAbigp.cjs"))),dotPulse:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotPulse-D98JVErY.cjs"))),dotOrbit:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotOrbit-BuOQPsSW.cjs"))),dotFlow:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotFlow-DvBJQulU.cjs"))),dotSlide:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotSlide-CS-Q4uKe.cjs"))),dotSlider:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotSlider-BNNqD9Dl.cjs"))),dotFold:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotFold-CieHpsj-.cjs"))),dotSquare:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotSquare-DEuA5KzQ.cjs"))),barEqualizer:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BarEqualizer-DWlqf8FS.cjs"))),barWave:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BarWave-Rt8wvaB7.cjs"))),barPulse:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BarPulse-BHFsltR9.cjs"))),barStretch:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BarStretch-BbNcMDZV.cjs"))),barMeter:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BarMeter-BN9p-esq.cjs"))),barBounce:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BarBounce-BGuvEO50.cjs"))),barRamp:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BarRamp-DtnspfKx.cjs"))),ringRotate:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./RingRotate-0ZwepWdq.cjs"))),ringDot:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./RingDot-B1efcLcT.cjs"))),ringPulse:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./RingPulse-C0b5UoQz.cjs"))),ringClip:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./RingClip-CxuSQ6UC.cjs"))),ringFan:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./RingFan-AXfUH1gy.cjs"))),dotRipple:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotRipple-D82MFEU4.cjs"))),circleSpinner:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./CircleSpinner-Dds2ZKpY.cjs"))),dotRipple3:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotRipple3-Fb61jLTU.cjs"))),ringCross:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./RingCross-CZun0bQg.cjs"))),squareTrace:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./SquareTrace-Cixaklmc.cjs"))),squareTrace2:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./SquareTrace2-LEwK57wv.cjs"))),crossMove:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./CrossMove-CF_BJxYr.cjs"))),snakePath:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./SnakePath-BYu2xCmy.cjs"))),squareMirror:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./SquareMirror-DRlm59jF.cjs"))),dotPulse5:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotPulse5-C1FaRhsY.cjs"))),diamondShuttle:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DiamondShuttle-Bmc425vI.cjs"))),barStream:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./BarStream-BPpZOi65.cjs"))),newtonCradle:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./NewtonCradle-BrcU-Kg4.cjs"))),dotSpin:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./DotSpin-DJ4Gesdz.cjs"))),orbitSwap:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./OrbitSwap-4AETRFM-.cjs"))),typingBounce:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./TypingBounce-DZojpNTJ.cjs"))),ringGlow:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./RingGlow-DPoHUjcB.cjs"))),toastRing:e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./ToastRing-DKVLp5rZ.cjs")))},l=new Set(["ballColor4","diamondShuttle","orbitSwap","ringGlow"]),d=e.computed(()=>i.theme||"rotaryLine"),u=e.computed(()=>s[d.value]||null),r=e.computed(()=>i.size==="large"),c=e.computed(()=>i.size==="xl"),m=e.computed(()=>i.size==="xxl"),p=e.computed(()=>i.size==="xs"),f=e.computed(()=>{const g=i.color||"";return g?l.has(d.value)?g:o.isString(g)?g.split("|")[0].trim():"":""}),h=e.computed(()=>o.getJsonMerge({"panel-load":!0,"size-large":r.value,"size-xl":c.value,"size-xxl":m.value,"size-xs":p.value},de.getClassNameJson(i.className)));return(g,y)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(h.value),id:e.unref(t),role:"status","aria-label":e.unref(a).loading||"加载中"},[u.value?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(u.value),{key:0,color:f.value,size:n.size},null,8,["color","size"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,hl))}}),Hn=new Map;function gl(n){if(!n)return;const a=Hn.get(n);if(a){a.count+=1;return}Hn.set(n,{count:1,overflow:n.style.overflow,className:n.className}),n.style.overflow="hidden",/\bmodal-open\b/.test(n.className)||(n.className=`${n.className} modal-open`.trim())}function yl(n){if(!n)return;const a=Hn.get(n);if(a){if(a.count>1){a.count-=1;return}Hn.delete(n),n.isConnected&&(n.style.overflow=a.overflow,n.className=a.className)}}const vl=["id","aria-label"],Lt=e.defineComponent({name:"ClOverlay",__name:"Index",props:{id:String,className:String,show:Boolean,zIndex:{type:Number,default:2e3},duration:{type:Number,default:300},isLockScroll:{type:Boolean,default:!0},background:{type:String,default:"var(--cl-overlay, rgba(0, 0, 0, 0.7))"},teleportTarget:{type:String,default:""}},emits:["update:show","onClick"],setup(n,{emit:a}){const{optA11yText:i}=qn(),t=n,s=a,l=t.id,d=e.ref(t.show);let u=null;const r=e.useTemplateRef("refElOverlay"),c=e.computed(()=>o.isNonEmptyString(t.teleportTarget)?D(t.teleportTarget):"body"),m=e.computed(()=>t.teleportTarget==="self"),p=e.computed(()=>m.value),f=e.computed(()=>{const w=t.duration;return o.isNumber(w)&&o.isFinite(w)&&w>=0&&w<=1e4?w:300}),h=e.computed(()=>{const w=t.zIndex;return o.isNumber(w)&&o.isFinite(w)&&w>=0?w:2e3}),g=e.computed(()=>{const w={"panel-overlay":!0};return m.value&&(w["panel-overlay-self"]=!0),o.getJsonMerge(w,de.getClassNameJson(t.className))}),y=e.computed(()=>({zIndex:h.value,background:o.isNonEmptyString(t.background)?t.background:"var(--cl-overlay, rgba(0, 0, 0, 0.7))","--overlay-duration":`${f.value}ms`})),V=w=>{gl(w)},E=w=>{yl(w)},B=()=>{if(m.value){const b=r.value?r.value.parentElement:null;if(!b)return null;let N=b;for(;N&&N!==document.body;){if(window.getComputedStyle(N).position!=="static")return N;N=N.parentElement}return document.body}const w=c.value;if(w==="body")return document.body;const M=document.querySelector(w);return M===document.body?document.body:M??document.body},T=()=>{if(t.isLockScroll&&t.show){const w=B();w&&u!==w&&(u&&E(u),u=w,V(w))}else u&&(E(u),u=null)},D=w=>{if(w==="self")return w;try{return document.querySelector(w)?w:(Se.warn("Overlay",`teleportTarget「${w}」未匹配到元素,已回退到 body`),"body")}catch{return Se.warn("Overlay",`teleportTarget「${w}」不是合法的 CSS 选择器,已回退到 body`),"body"}};e.onBeforeUnmount(()=>{u&&(E(u),u=null)}),e.watch(()=>[t.show,t.isLockScroll],()=>{t.show&&(d.value=!0),e.nextTick(()=>{T()})},{immediate:!0}),e.onMounted(()=>{T()});const x=()=>{s("onClick"),s("update:show",!1)},O=()=>{t.show||(d.value=!1)};return(w,M)=>d.value?(e.openBlock(),e.createBlock(e.Teleport,{key:0,to:c.value,disabled:p.value},[e.createVNode(e.Transition,{name:"panel-overlay-fade",duration:f.value,appear:"",onAfterLeave:O},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{ref_key:"refElOverlay",ref:r,id:e.unref(l),class:e.normalizeClass(g.value),style:e.normalizeStyle(y.value),onClick:e.withModifiers(x,["self"]),role:"button","aria-label":e.unref(i).overlay||"遮罩层"},[e.renderSlot(w.$slots,"default")],14,vl),[[e.vShow,n.show]])]),_:3},8,["duration"])],8,["to","disabled"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}),kl=["PPT","activity","address-book","aixin","aixin1","album","album-baby","all-circle","all-circle-fill","all-square","android","android1","angle-double-down","angle-double-left","angle-double-right","angle-double-up","angle-down","angle-left","angle-line-down","angle-line-left","angle-line-right","angle-line-up","angle-linelong-down","angle-linelong-down-left","angle-linelong-down-right","angle-linelong-left","angle-linelong-right","angle-linelong-up","angle-linelong-up-left","angle-linelong-up-right","angle-right","angle-up","arrow-circle-down","arrow-circle-down-line","arrow-circle-down-line-fill","arrow-circle-left","arrow-circle-right","arrow-circle-up","back-bottom","back-top","back-up1","banshixinxingxing","baseInfo","basicdata","bell","bitian","book","calendar","calendar1","camera","camera1","caret-down","caret-left","caret-right","caret-up","check","check-circle","check-circle-fill","check-square","check-square-fill","check1","check2","chemicals","chose-image","clear","clock","close","close-circle","close-circle-fill","close1","clothes","column-show","config","contract","cooperation","copy","cropper","customer","dashboard","dashboard1","dazhongdianping","delete","diqiu","dollar","douyin","douyin1","download","download-cloud","download-cloud-1","download-cloud-2","earth","edit","edit1","edit2","email","empty","equipment","excel","exclamation","exclamation-circle","exclamation-circle-fill","eye","eye-no","file","file-excel","file-gif","file-image","file-pdf","file-ppt","file-search","file-text","file-word","file-zip","film","filter","finance","gesture-enlarge","gesture-narrow","gif","goumai","guanliyuan","guidance","home","home1","image","image-multiple","image-rmb","image1","info","info-circle","info-circle-fill","ios","ios1","jiaoxue","jin","jingxiupian","kebiao","kefu","kefunan","kefunv","language","language1","layout-left","layout-top","layout-top-left","liebiao","liebiao-1","liebiao-image","liebiao-pubuliu","like","list-empty5","lock","lock-un","look","looklove","luxian","marker","marker-qidian","marker-qidian1","meiyuan","minus","minus-circle","minus-circle-fill","minus-square","minus-square-fill","mobanpeizhi","more","more1","move","music","new","new-triangle-left-2","new-triangle-left-4","new-triangle-right","new-triangle-right-2","new2","order","orderPre","paixu","pdf","phone","phone-code","photoFrame1","pile","pile-fill","pintu","pintu1","pintu2","play","plus","plus-circle","plus-circle-fill","plus-square","plus-square-fill","purchase","qrcode","question","question-circle","question-circle-fill","refresh","remove","renminbi","reply","report","restore","rmb","rmb-circle","rmb-circle-fill","rotate-left","rotate-left1","rotate-right","rotate-right1","save","scenery","schedule","screen-full","screen-narrow","search","search-minus","search-plus","security","security-accidents","security-check","security-education","share","sheji","shezhi","shiyanshiyuyue1","shopcart","shouji1","shouru","sign-out","sign-out-2","sign-out1","sort-down","sort-up","sorting","square","systemSet","taiyang","taocan","tel","test","text","time","tool","total-circle-fill","touxiang","tuijian","tupianyulan","tupianyulan1","upload","upload-cloud","upload-cloud-1","upload-cloud-2","use-registration","user","user-account","user-info1","video","wangzhan","warn","warn-fill","weixin","weixin1","weixin2","word","xiangji","xin","xin1","xing","xing-fill","xingxing-banshixin","xinshenger","yanzhengma","yanzhengma1","yanzhengma2","yinger-nan","yinger-nv","yinger-unknown","yuexing","yulan","yulan1","yunfu","yunfu1","yuyue","yuyuedan","zhichu","zhongyao","zhuti","zhutice","zip","zuhu","zuhu1","zuopin"],Sl=["id"],ve=e.defineComponent({name:"ClIconFont",__name:"Index",props:{id:{},name:{},className:{},size:{},color:{}},setup(n){const a=new Set(kl),i=n,t=i.id,s=e.computed(()=>{let d={"panel-icon-font":!0};const u=i.name;return o.isNonEmptyString(u)&&(a.has(u)?(d.clIconFont=!0,d[`clIcon-${u}`]=!0):d=o.getJsonMerge(d,de.getClassNameJson(u))),d=o.getJsonMerge(d,de.getClassNameJson(i.className)),d}),l=e.computed(()=>{const d={};return i.size!==void 0&&i.size!==null&&(d["font-size"]=o.isFinite(i.size)?`${i.size}px`:String(i.size)),i.color&&(d.color=i.color),d});return(d,u)=>(e.openBlock(),e.createElementBlock("i",{id:e.unref(t),class:e.normalizeClass(s.value),style:e.normalizeStyle(l.value)},null,14,Sl))}});let di=500;const $o=new WeakMap;function wl(n,a,i){const t=n.getElementsByClassName("cl-waves-ripple");if(t.length>1)for(let p=0;p<t.length-1;p++){const f=t[p];parseFloat(f.style.opacity||"1")<.3&&f.remove()}const s=document.createElement("span");s.className="cl-waves-ripple";const l=n.getBoundingClientRect(),d=a.clientX-l.left,u=a.clientY-l.top,r=o.isObject(i.value)?i.value:{},c=r.color==="white";s.style.top=`${u}px`,s.style.left=`${d}px`,c&&s.classList.add("waves-light");const m=o.isNumber(r.duration)?r.duration:di;s.style.transitionDuration=`${m}ms`,n.appendChild(s),requestAnimationFrame(()=>{const p=(l.width/100*3).toFixed(2);s.style.transform=`scale(${p}) translate(0, 0)`,s.style.opacity="1";const f=()=>{s.removeEventListener("transitionend",f),s.parentNode&&s.parentNode.removeChild(s)};s.addEventListener("transitionend",f)})}const Fo={mounted(n,a){a.value&&El(n,a)},unmounted(n){const a=$o.get(n);a&&(n.removeEventListener("click",a),$o.delete(n))}};function El(n,a){n.style.position=n.style.position||"relative",n.style.overflow="hidden";const i=t=>wl(n,t,a);$o.set(n,i),n.addEventListener("click",i)}function bl(n){n?.duration&&(di=n.duration)}const Cl="clwaves",xl=n=>(bl(n),{deep:!0,mounted:Fo.mounted,unmounted:Fo.unmounted}),mi={mounted:Fo.mounted},pi=Object.freeze(Object.defineProperty({__proto__:null,directive:xl,name:Cl,wavesBind:mi},Symbol.toStringTag,{value:"Module"})),Bl=["id"],Dl=["disabled","aria-label"],Il={key:2,class:"btn-label"},Tl={key:0,class:"btn-loading"},Nl={class:"btn-body-backdrop-container"},Vl={class:"btn-body-backdrop-text"},Qe=e.defineComponent({name:"ClButton",directives:{clwaves:mi},__name:"Index",props:{id:String,className:String,disabled:{type:Boolean,default:!1},classBtn:String,label:String,icon:String,iconName:String,color:{type:String,default:"default"},size:{type:String,validator:n=>n===void 0||["large","small","xl"].indexOf(n)!==-1},isShowLoad:{type:Boolean,default:!1},loadPos:{type:String,default:"right",validator:n=>["right","zoom-out","fixedCenter"].indexOf(n)!==-1},loadTheme:{type:String,default:"rotaryLine"},loadColor:String,loadDrift:{type:Boolean,default:!0},loadText:{type:String,default:"加载中"},isShowBackDrop:{type:Boolean,default:!1},teleportTarget:{type:String,default:""},backdropOpacity:{type:Number,default:.02,validator:n=>n>=0&&n<=1},isShowWaves:{type:Boolean,default:!0},wavesColor:{type:String,default:"white"},loadStatusIsIng:{type:[Boolean,null],default:null}},emits:{onClick:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useSlots(),u=e.ref(!1),r=e.ref(!1),c=e.ref(!1),m=e.useTemplateRef("refElBtn"),p=e.useTemplateRef("refElContent"),f=e.ref(!1),h=e.ref("");let g=null,y=!1,V=null;typeof window<"u"&&o.isEmpty(t.label)&&o.isEmpty(t.icon)&&o.isEmpty(t.iconName)&&!d.default&&Se.warn("ClButton","警告:label、icon、iconName 或默认插槽必须传一个值");const E=e.computed(()=>!o.isEmpty(t.label)||!!d.default),B=e.computed(()=>{const Y=t.icon||t.iconName;return o.isNonEmptyString(Y)?Y:""}),T=e.computed(()=>E.value&&t.label||"按钮"),D=e.computed(()=>t.disabled?!0:u.value),x=e.computed(()=>t.loadPos==="fixedCenter"),O=e.computed(()=>t.loadColor||"var(--cl-bg, #ffffff)"),w=e.computed(()=>t.loadColor||h.value),M=e.computed(()=>`rgba(0, 0, 0, ${t.backdropOpacity})`),b=e.computed(()=>{let Y=t.wavesColor||"white";return(o.isExistValue(t.color,"white")||o.isExistValue(t.color,"grayLight")||o.isExistValue(t.color,"text"))&&(Y="black"),Y}),N=e.computed(()=>t.isShowWaves?{color:b.value}:!1),J=e.computed(()=>{let Y=t.loadPos||"right";return o.isExistValue(t.classBtn,"btn-circle")&&o.isExistValue(Y,"right")&&(Y="zoom-out"),Y}),q=e.computed(()=>{let Y="";switch(t.loadTheme){case"rotaryLine":Y=o.isExistValue(t.classBtn,"btn-circle")?"":"large";break;case"circleNotch":default:Y="large";break;case"circleBubble":Y="";break}return Y}),z=e.computed(()=>{const Y={"panel-button":!0};return o.getJsonMerge(Y,de.getClassNameJson(t.className))}),H=e.computed(()=>{let Y={"btn-parent":!0,btn:!0};return o.isEmpty(t.color)||(Y[`btn-${t.color}`]=!0),Y=o.getJsonMerge(Y,de.getClassNameJson(t.classBtn)),o.isEmpty(t.size)||(Y[`btn-${t.size}`]=!0),Y["btn-load-ing"]=u.value,u.value&&(Y[`btn-load-${J.value}`]=!0,Y[`btn-load-${t.loadTheme}`]=!0,Y["btn-load-nodrift"]=!t.loadDrift||J.value==="right"&&f.value),Y}),v=e.computed(()=>{const Y=u.value&&x.value;return{"btn-body-backdrop-main":!0,animated:!0,zoomIn:Y,zoomOut:!Y}}),S=e.computed(()=>{const Y={};return(E.value||B.value)&&J.value==="zoom-out"&&u.value&&!x.value&&(Y.opacity=0),Y}),C=()=>{s("onClick")},$=()=>{if(o.isExistValue(t.classBtn,"btn-circle"))return 20;switch(t.loadTheme){case"circleNotch":return 24;case"circleBubble":return 30;case"rotaryLine":default:return t.size==="small"?20:30}},k=()=>{if(typeof window>"u"||!m.value)return;const Y=m.value.querySelector(".btn-label")||m.value.querySelector(".btn-icon")||m.value,Z=window.getComputedStyle(Y).color;o.isEmpty(Z)||(h.value=Z)},I=()=>{if(typeof window>"u"||!m.value||!p.value||u.value)return;const Y=m.value,se=p.value.children;if(!se.length){f.value=!0;return}const K=Y.getBoundingClientRect(),W=se[se.length-1].getBoundingClientRect(),U=W.right-se[0].getBoundingClientRect().left,ae=K.right-W.right,X=$()+6+5;f.value=ae>=X&&U>0},L=()=>{_(),!(typeof window>"u"||!m.value||!window.ResizeObserver)&&(V=new window.ResizeObserver(()=>{I()}),V.observe(m.value))},_=()=>{V&&(V.disconnect(),V=null)},R=()=>{u.value||(g&&(clearTimeout(g),g=null),t.isShowBackDrop&&(r.value=!0,c.value=!0),u.value=!0)},P=()=>{t.isShowBackDrop&&(x.value?e.nextTick(()=>{y||(g=setTimeout(()=>{y||(r.value=!1,c.value=!1,g=null)},200))}):r.value=!1),u.value=!1};e.onMounted(()=>{e.nextTick(()=>{k(),I(),L()})}),e.onBeforeUnmount(()=>{y=!0,_(),g&&(clearTimeout(g),g=null)}),e.watch(()=>[t.label,t.icon,t.iconName,t.size,t.loadTheme,t.classBtn,t.loadDrift,t.color],()=>{e.nextTick(()=>{k(),I()})}),e.watch(()=>t.loadStatusIsIng,Y=>{o.isBoolean(Y)&&(Y?R():P())},{immediate:!0});const Q=()=>{t.disabled||(t.isShowLoad&&R(),C())};return a({loadStart:()=>{R()},loadStop:()=>{P()}}),(Y,Z)=>{const se=e.resolveDirective("clwaves");return e.openBlock(),e.createElementBlock("span",{id:e.unref(l),class:e.normalizeClass(z.value)},[e.withDirectives((e.openBlock(),e.createElementBlock("button",{type:"button",class:e.normalizeClass(H.value),disabled:D.value,"aria-label":T.value,ref_key:"refElBtn",ref:m,onClick:Q},[e.createElementVNode("span",{style:e.normalizeStyle(S.value),ref_key:"refElContent",ref:p},[B.value?(e.openBlock(),e.createBlock(ve,{key:0,name:B.value,className:"btn-icon"},null,8,["name"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),E.value?(e.openBlock(),e.createElementBlock("span",Il,[e.renderSlot(Y.$slots,"default",{},()=>[e.createTextVNode(e.toDisplayString(n.label),1)])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],4),u.value&&!x.value?(e.openBlock(),e.createElementBlock("span",Tl,[e.createVNode(lt,{theme:n.loadTheme,size:q.value,color:w.value},null,8,["theme","size","color"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,Dl)),[[se,N.value]]),r.value?(e.openBlock(),e.createBlock(Lt,{key:0,show:r.value,zIndex:1000001,duration:0,isLockScroll:!1,background:M.value,teleportTarget:n.teleportTarget},{default:e.withCtx(()=>[x.value&&c.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(v.value)},[e.createElementVNode("div",Nl,[e.createVNode(lt,{theme:n.loadTheme,size:q.value,color:O.value},null,8,["theme","size","color"]),e.createElementVNode("div",Vl,e.toDisplayString(n.loadText||"加载中"),1)])],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),_:1},8,["show","background","teleportTarget"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,Bl)}}}),_l=["id"],Ml={key:0,class:"callout-title"},Ol={class:"callout-content"},fi=e.defineComponent({name:"ClCallout",__name:"Index",props:{id:String,className:String,type:{type:String,default:"info"},title:String},setup(n){const a=n,i=a.id,t=e.computed(()=>o.getJsonMerge({"panel-callout":!0,[`callout-${a.type||"info"}`]:!0},de.getClassNameJson(a.className)));return(s,l)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(t.value),id:e.unref(i),role:"note"},[n.title?(e.openBlock(),e.createElementBlock("div",Ml,e.toDisplayString(n.title),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",Ol,[e.renderSlot(s.$slots,"default")])],10,_l))}}),Al=["id"],Ll={key:0,class:"card-head"},$l={key:0,class:"card-head-flex"},Fl={class:"card-title"},Pl={key:1,class:"card-title"},Rl={key:2,class:"card-explain"},Hl={key:2,class:"card-footer"},jo=e.defineComponent({name:"ClCard",__name:"Index",props:{id:String,className:String,classBody:String,theme:{type:String,default:"default"},isInnerPadZero:{type:Boolean,default:!1}},setup(n){const a=n,i=a.id,t=e.computed(()=>({"panel-card":!0,"card-box":!0,...de.getClassNameJson(a.className),[`card-${a.theme||"default"}`]:!0})),s=e.computed(()=>({"card-body":!0,"card-body-padding-0":a.isInnerPadZero,...de.getClassNameJson(a.classBody)}));return(l,d)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(t.value),id:e.unref(i)},[l.$slots.headTitle||l.$slots.headExplain||l.$slots.headFlex?(e.openBlock(),e.createElementBlock("div",Ll,[l.$slots.headFlex?(e.openBlock(),e.createElementBlock("div",$l,[e.createElementVNode("div",Fl,[e.renderSlot(l.$slots,"headTitle")]),e.renderSlot(l.$slots,"headFlex")])):(e.openBlock(),e.createElementBlock("div",Pl,[e.renderSlot(l.$slots,"headTitle")])),l.$slots.headExplain?(e.openBlock(),e.createElementBlock("div",Rl,[e.renderSlot(l.$slots,"headExplain")])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",{class:e.normalizeClass(s.value)},[e.renderSlot(l.$slots,"default")],2),l.$slots.foot?(e.openBlock(),e.createElementBlock("div",Hl,[e.renderSlot(l.$slots,"foot")])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],10,Al))}}),Ul=["id"],hi=e.defineComponent({name:"ClCardColor",__name:"Index",props:{id:String,className:String,classBody:String,color:{type:String,default:"var(--cl-shadow-sm, rgba(0, 0, 0, 0.04))"},isInnerPadZero:{type:Boolean,default:!1}},setup(n){const a=n,i=a.id,t=e.computed(()=>{const d={"card-color":!0};return o.getJsonMerge(d,de.getClassNameJson(a.className))}),s=e.computed(()=>({"card-color-body":!0,"card-color-body--pad-zero":a.isInnerPadZero,...de.getClassNameJson(a.classBody)})),l=e.computed(()=>({backgroundColor:o.isNonEmptyString(a.color)?a.color:"var(--cl-shadow-sm, rgba(0, 0, 0, 0.04))"}));return(d,u)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(i),class:e.normalizeClass(t.value),style:e.normalizeStyle(l.value)},[e.createElementVNode("div",{class:e.normalizeClass(s.value)},[e.renderSlot(d.$slots,"default")],2)],14,Ul))}}),zl=["click","hover","focus"],ho={fade:"fade",show:"show"},Jl={type:"tooltip",placement:"top",trigger:"click",theme:"white",wrap:"body",template:"",contentBody:"",contentHeader:"",selectorBody:"",selectorHead:"",selectorArrow:".arrow",isLoad:!1,loadOnCallback:null,loadOffCallback:null,isRunTrigger:!0,isStopPropagation:!0,isInitShow:!0,isHtml:!0,className:""};let Kl=class{elementModal;optionModal;pageData;pageObject;constructor(a,i){this.elementModal={},this.elementModal.rely=a,this.optionModal=o.getJsonMerge(Jl,i),this.pageData={isOpen:!1,events:[],scrollParents:[]},this.pageObject=null,["listenerOn","listenerOff","listenerHide","listenerRelatedMouseLeave","onScrollParentScroll"].forEach(t=>{this[t]=this[t].bind(this)}),this.init()}init(){if(!o.isEmpty(this.optionModal.template)){const a=this.getEventType();this.setEventListener(a)}}getEventType(){const a=[],i=[];let t=[];return o.isArray(this.optionModal.trigger)?t=this.optionModal.trigger:o.isString(this.optionModal.trigger)&&(t=this.optionModal.trigger.split(",")),t.forEach(s=>{switch(o.isExistValue(zl,s)?s:""){case"hover":a.push("mouseenter"),i.push("mouseleave");break;case"focus":a.push("focus"),i.push("blur");break;case"click":a.push("click"),i.push("click");break}}),{on:a,off:i}}setEventListener(a){o.isEmpty(a.on)||a.on.forEach(i=>{this.pageData.events.push({on:i,func:this.listenerOn,eventName:i}),this.elementModal.rely.addEventListener(i,this.listenerOn)}),o.isEmpty(a.off)||a.off.forEach(i=>{this.pageData.events.push({off:i,func:this.listenerOff,eventName:i}),this.elementModal.rely.addEventListener(i,this.listenerOff)})}listenerOn(a){if(this.optionModal.isInitShow){if(this.optionModal.isStopPropagation&&(a.preventDefault(),a.stopPropagation()),this.pageData.isOpen||!this.optionModal.isRunTrigger)return;a.useOpenToTip=!0,this.show(),this.optionModal.isLoad&&o.isFunction(this.optionModal.loadOnCallback)&&this.optionModal.loadOnCallback()}}listenerOff(a){!this.optionModal.isRunTrigger||o.isBoolean(a.useOpenToTip)&&a.useOpenToTip||(this.hide(a),this.optionModal.isLoad&&o.isFunction(this.optionModal.loadOffCallback)&&this.optionModal.loadOffCallback())}show(){if(o.isString(this.optionModal.wrap)){const a=window.document.querySelector(this.optionModal.wrap);if(o.isUndefined(a))return}this.pageData.isOpen||this.operateShow()}operateShow(){if(!this.pageData.isOpen){if(this.pageData.isOpen=!0,o.isUndefined(this.elementModal.tip)){this.elementModal.tip=this.createElement();const i=this.getWrapElement();o.isUndefined(i)||i.appendChild(this.elementModal.tip);const t={placement:this.optionModal.placement};t.modifiers=[{name:"offset",options:{offset:[0,8]}}],this.pageObject=el.createPopper(this.elementModal.rely,this.elementModal.tip,t)}else this.elementModal.tip.style.opacity="",this.elementModal.tip.style.pointerEvents="",this.pageObject.setOptions({modifiers:[{name:"eventListeners",enabled:!0}]});this.setContentBody(this.optionModal.contentBody),this.setContentHeader(this.optionModal.contentHeader);const a=[ho.fade,ho.show,`bs-${this.optionModal.type}-${this.optionModal.placement}`,`tooltip-${this.optionModal.theme}`];o.isEmpty(this.optionModal.className)||this.optionModal.className.split(" ").forEach(i=>{o.isEmpty(i)||a.push(i)}),this.elementModal.tip.className=de.getAddClass(this.elementModal.tip.className,a),setTimeout(()=>{this.pageObject.update()},50),this.pageData.scrollParents=this.getScrollParents(),o.isEmpty(this.pageData.scrollParents)||this.pageData.scrollParents.forEach(i=>{i.addEventListener("scroll",this.onScrollParentScroll,{passive:!0})})}}createElement(){const a=window.document.createElement("div");return a.innerHTML=this.optionModal.template,a.childNodes[0]}setContentBody(a){if(!o.isEmpty(this.optionModal.selectorBody)&&!o.isEmpty(a))if(o.isUndefined(this.elementModal.tip))this.optionModal.contentBody=a;else{const i=this.elementModal.tip.querySelector(this.optionModal.selectorBody);if(!o.isUndefined(i)){if(this.optionModal.isHtml){const t=a.replace(/\\n/g,"<br>").replace(/\n/g,"<br>");i.innerHTML=t}else i.innerText=a;this.optionModal.contentBody=a,this.pageObject.update()}}}setInitShow(a){this.optionModal.isInitShow=a}setContentHeader(a){if(!o.isEmpty(this.optionModal.selectorHead)){const i=this.elementModal.tip.querySelector(this.optionModal.selectorHead);if(!o.isUndefined(i)){const t=o.isEmpty(a)?"":a;this.optionModal.isHtml?i.innerHTML=t:i.innerText=t,this.optionModal.contentHeader=t,this.pageObject.update()}}}getWrapElement(){let a;return o.isString(this.optionModal.wrap)?a=window.document.querySelector(this.optionModal.wrap):this.optionModal.wrap===!1&&(a=this.elementModal.rely.parentNode),a}getScrollParents(){const a=[];let i=this.elementModal.rely.parentElement;for(;i;){const t=window.getComputedStyle(i),s=t.overflow+t.overflowX+t.overflowY;/auto|scroll|overlay/.test(s)&&a.push(i),i=i.parentElement}return a}isVisibleInScrollParents(){const a=this.elementModal.rely.getBoundingClientRect();for(const i of this.pageData.scrollParents){const t=i.getBoundingClientRect();if(!!(a.right<=t.left||a.left>=t.right||a.bottom<=t.top||a.top>=t.bottom))return!1}return!0}onScrollParentScroll(){if(!this.pageData.isOpen||!this.elementModal.tip)return;const a=this.isVisibleInScrollParents();this.elementModal.tip.style.opacity=a?"":"0",this.elementModal.tip.style.pointerEvents=a?"":"none"}hide(a){if(!this.pageData.isOpen||!document.body.contains(this.elementModal.tip))return;let i=!0;if(a.type==="mouseleave"){const t=a.relatedreference||a.toElement||a.relatedTarget;this.elementModal.tip.contains(t)&&(i=!1,this.elementModal.tip.addEventListener(a.type,this.listenerRelatedMouseLeave))}i&&this.operateHide()}listenerRelatedMouseLeave(a){const i=a.relatedreference||a.toElement||a.relatedTarget;this.elementModal.tip.removeEventListener(a.type,this.listenerRelatedMouseLeave),this.elementModal.rely.contains(i)||this.hide(a)}operateHide(){this.pageData.isOpen&&(this.pageData.isOpen=!1,o.isEmpty(this.pageData.scrollParents)||(this.pageData.scrollParents.forEach(a=>{a.removeEventListener("scroll",this.onScrollParentScroll)}),this.pageData.scrollParents=[]),this.pageObject.setOptions({modifiers:[{name:"eventListeners",enabled:!1}]}),this.elementModal.tip.className=de.getRemoveClass(this.elementModal.tip.className,ho.show),this.elementModal.tip.removeEventListener("mouseenter",this.listenerHide),this.elementModal.tip.removeEventListener("click",this.listenerHide),this.elementModal.tip.parentNode.removeChild(this.elementModal.tip),this.elementModal.tip=null)}listenerHide(){this.operateHide()}setRunTrigger(a){this.optionModal.isRunTrigger=a}dispose(){this.pageData.events.forEach(({eventName:a,func:i})=>{this.elementModal.rely.removeEventListener(a,i)}),this.pageData.events=[],this.pageObject&&(this.operateHide(),this.pageObject.destroy())}clShow(){this.operateShow()}clHide(){this.operateHide()}clToggle(){this.pageData.isOpen?this.operateHide():this.operateShow()}clSetContentBody(a){this.setContentBody(a)}clSetContentHeader(a){this.setContentHeader(a)}clSetRunTrigger(a){this.setRunTrigger(a)}clSetInitShow(a){this.setInitShow(a)}clDispose(){this.dispose()}};const _e={positions:{top:"top",topLeft:"top-start",topRight:"top-end",right:"right",rightTop:"right-start",rightBottom:"right-end",bottom:"bottom",bottomLeft:"bottom-start",bottomRight:"bottom-end",left:"left",leftTop:"left-start",leftBottom:"left-end"},triggers:["hover","click","focus"],themes:["white","black"],options:{position:"top",trigger:"hover",theme:"white",template:"<div class='tooltip'><div class='tooltip-inner'></div><div class='arrow' data-popper-arrow></div></div>",selectorBody:".tooltip-inner",selectorArrow:".arrow",isHtml:!0,isRunTrigger:!0,isFixedVisible:!1,isStopPropagation:!0,className:""},bind:(n,a)=>{_e.create(n,a)},create:(n,a)=>{if(o.isObject(a)&&!o.isUndefined(a.value)&&_e.getIsInit(a)){const t=_e._getValueHtml(a.value);if(!o.isEmpty(t)){const s=_e.getOptions();s.contentBody=t,s.placement=_e.getPosition(a),s.trigger=_e.getTrigger(a),s.theme=_e.getTheme(a),s.isHtml=_e.getIsHtml(a),s.isFixedVisible=_e.getFixedVisible(a),s.isStopPropagation=_e.getStopPropagation(a),s.className=_e.getClassName(a);try{const l=new Kl(n,s);l._vueEl=n,n._tooltip=l}catch{}}}},getIsInit:n=>o.isObject(n.value)&&o.isBoolean(n.value.init)?n.value.init:!0,getOptions:()=>o.getJsonClone(_e.options),_getValueHtml:n=>{let a="";switch(o.getTypeof(n)){case"string":case"number":a=n.toString();break;case"object":o.isEmpty(n.html)||(a=n.html);break;default:a=""}return a},getPosition:n=>{let a=o.isObject(n.value)?n.value.position:"";if(o.isEmpty(a))for(const[i,t]of Object.entries(_e.positions))n.modifiers[i]&&(a=t);else o.isExistJsonKey(_e.positions,a)&&(a=_e.positions[a]);return o.isEmpty(a)?_e.options.position:a},getTrigger:n=>{let a=o.isObject(n.value)?n.value.trigger:"";return o.isEmpty(a)&&_e.triggers.forEach(i=>{n.modifiers[i]&&(a=i)}),o.isEmpty(a)?_e.options.trigger:a},getTheme:n=>{let a=o.isObject(n.value)?n.value.theme:"";return o.isEmpty(a)&&_e.themes.forEach(i=>{n.modifiers[i]&&(a=i)}),o.isEmpty(a)?_e.options.theme:a},getIsHtml:n=>{const a=o.isObject(n.value)?n.value.isHtml:!0;return o.isBoolean(a)?a:_e.options.isHtml},getIsRunTrigger:n=>o.isObject(n)&&o.isBoolean(n.isRunTrigger)?n.isRunTrigger:!0,getFixedVisible:n=>{const a=o.isObject(n.value)?n.value.isFixedVisible:!1;return o.isBoolean(a)?a:_e.options.isFixedVisible},getStopPropagation:n=>{const a=o.isObject(n.value)?n.value.isStopPropagation:!1;return o.isBoolean(a)?a:_e.options.isStopPropagation},getClassName:n=>{const a=o.isObject(n.value)?n.value.className:"";return o.isEmpty(a)?_e.options.className:a},update:(n,a)=>{const i=_e.getIsInit(a);if(i){!n._tooltip&&i&&_e.create(n,a);const t=_e._getValueHtml(a.value),s=_e._getValueHtml(a.oldValue),l=o.isObject(a.value);let d=!1;if(t!==s)d=!0;else if(l&&!o.isUndefined(a.value.updRefreshInx)){const u=a.value.updRefreshInx,r=a.oldValue.updRefreshInx;u!==r&&(d=!0)}if(n._tooltip){d&&n._tooltip.clSetContentBody(t),n._tooltip.clSetInitShow(i);const u=_e.getIsRunTrigger(a.value),r=_e.getIsRunTrigger(a.oldValue);(!u||!i)&&n._tooltip.clHide(),u!==r&&n._tooltip.clSetRunTrigger(u)}}else _e.destroy(n)},destroy:n=>{n._tooltip&&(n._tooltip.clDispose(),delete n._tooltip)},show:n=>{n._tooltip&&n._tooltip.clShow()},hide:n=>{n._tooltip&&n._tooltip.clHide()}},Wl="clTooltip",jl=()=>({deep:!0,mounted:_e.bind,updated:_e.update,unmounted:_e.destroy}),ct={mounted:_e.bind,updated:_e.update},Po={show:_e.show,hide:_e.hide},gi=Object.freeze(Object.defineProperty({__proto__:null,directive:jl,name:Wl,tooltipCommon:Po,tooltipDirectives:ct},Symbol.toStringTag,{value:"Module"})),Yl=["id"],ql={key:0,class:"cl-plaintext-value"},Xl=["id","name","value","disabled","checked","onClick"],Gl=["for"],Ql={key:0},Yo=e.defineComponent({name:"ClCheckbox",directives:{cltooltip:ct},__name:"Index",props:{id:String,name:{type:String,required:!0},value:{type:String,required:!0},className:String,disabled:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},circle:{type:Boolean,default:!1},width:String,isInline:{type:Boolean,default:!0},tipMode:{type:String,default:"tooltip",validator:n=>["tooltip","clickCallback"].includes(n)},checkChangeBefore:{type:Function,default:void 0},isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:","}},emits:["update:value","update:modelValue","onChange","onInit","onError","onTipClick"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=`checkbox-${o.getRandom(5)}`,d=o.isEmpty(t.name)?l+"_name":t.name,u=t.id,r=e.ref(o.split(t.value)),c=e.ref(!1);let m={};const p=e.ref(0),f={isProcessing:!1,_initEmitted:!1},h=e.computed(()=>t.isPlaintext?[]:t.list),g=e.computed(()=>{const S=o.isString(t.plaintextSeparator)?t.plaintextSeparator:",";t.list,p.value;const C=[];return r.value.forEach($=>{const k=o.isExistJsonKey(m,$)?m[$]:void 0;k&&o.isNonEmptyString(k.name)&&C.push(k.name)}),C.join(S)}),y=e.computed(()=>o.getJsonMerge({"panel-checkbox":!0},de.getClassNameJson(t.className))),V=e.computed(()=>{const S={checkbox:!0,"checkbox-default":!0};return S["checkbox-inline"]=t.isInline,S["checkbox-circle"]=t.circle,S}),E=S=>{const C={},{width:$}=t;return S&&!o.isEmpty(S.width)?C.width=S.width:o.isEmpty($)||(C.width=t.width),C},B=S=>{s("update:value",S),s("update:modelValue",S)},T=S=>{const C=[];o.isEmpty(S)||o.split(S).forEach(k=>{o.isExistJsonKey(m,k)&&C.push(o.getJsonClone(m[k]))});const $=C.length>0&&C.length===(t.list?.length??0);B(S),s("onChange",S,C,$)},D=()=>{f._initEmitted||(f._initEmitted=!0,e.nextTick(()=>{s("onInit")}))},x=()=>{const S=[];return r.value.forEach(C=>{o.isExistJsonKey(m,C)&&S.push(C)}),S},O=S=>{m=o.isEmpty(S)?{}:o.getJsonByList(S),p.value+=1},w=()=>{if(c.value&&!o.isEmpty(r.value)){const S=x();o.isEqualArr(r.value,S)||(r.value=S,B(S.join(",")))}},M=S=>{const C=o.split(S);let $=o.isEqualArr(r.value,C);$&&($=S===r.value.join(",")),$||(r.value=C)},b=()=>{c.value=(t.list?.length??0)!==0,O(t.list),w()};e.onMounted(()=>{e.nextTick(()=>{b()})}),e.watch(c,S=>{S&&D()}),e.watch(()=>t.list,S=>{c.value||(c.value=!0,S.length===0&&w(),D())}),e.watch([()=>t.value,()=>t.list],([S,C])=>{const $=C;!c.value&&$.length>0&&(c.value=!0,D()),O($),M(S),w()});const N=S=>{s("onTipClick",S)},J=async S=>{if(!(!S||S.isDisabled||t.disabled||f.isProcessing)&&!o.isEmpty(S.id)){f.isProcessing=!0;try{const C=String(S.id??"");let $=o.getArrClone(r.value);o.isExistValue(r.value,C)?$=o.getArrRemoveById($,C):$.push(C);const k=$.join(",");let I=!0;if(t.checkChangeBefore)try{I=await t.checkChangeBefore(k),I=o.isBoolean(I)?I:!0}catch{I=!1}if(t.disabled||S.isDisabled)return;I&&(r.value=$,T(k))}catch(C){s("onError",C)}finally{f.isProcessing=!1}}};return a({getValue:()=>x().join(","),getValueData:()=>{const S=[];return r.value.forEach(C=>{o.isExistJsonKey(m,C)&&S.push(o.getJsonClone(m[C]))}),S},setValue:S=>{f.isProcessing||(M(S),w())},runInitComplete:()=>{c.value||(c.value=!0,O(t.list),M(t.value),w(),D())}}),(S,C)=>{const $=e.resolveDirective("cltooltip");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(y.value),id:e.unref(u)},[n.isPlaintext?(e.openBlock(),e.createElementBlock("div",ql,e.toDisplayString(g.value),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(k,I)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${l}-${k.id??""}-${I}`},[k.isShow||k.isShow===void 0?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(V.value),style:e.normalizeStyle(E(k))},[e.createElementVNode("span",null,[e.createElementVNode("span",null,[e.createElementVNode("input",{type:"checkbox",id:`${l}_${e.unref(d)}_${k.id??""}`,name:e.unref(d),value:k.id??"",disabled:k.isDisabled||n.disabled,checked:r.value.includes(String(k.id??"")),onClick:L=>J(k)},null,8,Xl),e.createElementVNode("label",{for:`${l}_${e.unref(d)}_${k.id??""}`},[e.renderSlot(S.$slots,"default",{data:k},()=>[k.icon&&k.icon.length>0?e.withDirectives((e.openBlock(),e.createElementBlock("span",Ql,[e.createVNode(ve,{name:k.icon},null,8,["name"])])),[[$,{html:k.name,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(k.name),1)],64))])],8,Gl)]),k.tipMsg&&k.tipMsg.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.tipMode==="tooltip"?e.withDirectives((e.openBlock(),e.createBlock(ve,{key:0,name:e.unref(o).isNonEmptyString(k.tipIcon)?void 0:"question-circle",className:e.unref(o).isNonEmptyString(k.tipIcon)?k.tipIcon:void 0,class:"checkbox-icon-tip"},null,8,["name","className"])),[[$,{html:k.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createBlock(ve,{key:1,name:e.unref(o).isNonEmptyString(k.tipIcon)?void 0:"question-circle",className:e.unref(o).isNonEmptyString(k.tipIcon)?k.tipIcon:void 0,class:"checkbox-icon-tip",onClick:e.withModifiers(L=>N(k),["stop"])},null,8,["name","className","onClick"]))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])],6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))),128))],10,Yl)}}}),Zl=["id"],er=["id","name","checked","disabled"],tr=["for"],nr={key:0},dt=e.defineComponent({name:"ClCheckboxOne",directives:{cltooltip:ct},__name:"One",props:{id:{},name:{},value:{type:Boolean},className:{},forId:{},label:{},disabled:{type:Boolean},circle:{type:Boolean},indeterminate:{type:Boolean},icon:{},tipMsg:{},tipIcon:{},tipMode:{}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:n=>!0,onTipClick:()=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,l=o.isEmpty(i.forId)?`cb_${i.name||""}_${o.getRandom(8)}`:i.forId,d=e.computed(()=>{const p={checkbox:!0,"checkbox-default":!0,"checkbox-inline":!0};return i.circle&&(p["checkbox-circle"]=!0),o.getJsonMerge(p,de.getClassNameJson(i.className))}),u=e.computed(()=>({indeterminate:i.indeterminate})),r=(p,f)=>{t("update:value",f),t("update:modelValue",f),t("onChange",{event:p,value:f})},c=()=>{t("onTipClick")},m=p=>{r(p,p.currentTarget.checked)};return(p,f)=>{const h=e.resolveDirective("cltooltip");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(d.value),id:e.unref(s)},[e.createElementVNode("span",null,[e.createElementVNode("span",null,[e.createElementVNode("input",{type:"checkbox",id:e.unref(l),name:n.name,class:e.normalizeClass(u.value),checked:n.value,disabled:n.disabled,onClick:m},null,10,er),e.createElementVNode("label",{for:e.unref(l)},[n.icon?e.withDirectives((e.openBlock(),e.createElementBlock("span",nr,[e.createVNode(ve,{name:n.icon},null,8,["name"])])),[[h,{html:n.label,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(n.label),1)],64))],8,tr)]),n.tipMsg?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.tipMode==="tooltip"?e.withDirectives((e.openBlock(),e.createBlock(ve,{key:0,name:e.unref(o).isNonEmptyString(i.tipIcon)?void 0:"question-circle",className:e.unref(o).isNonEmptyString(i.tipIcon)?i.tipIcon:void 0,class:"checkbox-icon-tip"},null,8,["name","className"])),[[h,{html:n.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createBlock(ve,{key:1,name:e.unref(o).isNonEmptyString(i.tipIcon)?void 0:"question-circle",className:e.unref(o).isNonEmptyString(i.tipIcon)?i.tipIcon:void 0,class:"checkbox-icon-tip",onClick:e.withModifiers(c,["stop"])},null,8,["name","className"]))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])],10,Zl)}}}),or=()=>typeof window<"u";let kt=null;const ar=()=>(kt||(kt=document.createElement("textarea"),kt.setAttribute("readonly",""),kt.style.position="fixed",kt.style.left="-9999px",kt.style.top="-9999px",kt.style.opacity="0",document.body.appendChild(kt)),kt),ir=n=>typeof n=="function"?n():n,Va=(n,a)=>{try{const i=ar();i.value=n,i.select(),i.setSelectionRange(0,99999),document.execCommand("copy")?a.successCallback?.():a.errorCallback?.(n)}catch{a.errorCallback?.(n)}finally{window.getSelection()?.removeAllRanges()}},sr=n=>{const a=typeof n=="string"?{text:n}:n;if(!or()){a.errorCallback?.();return}let i;try{i=ir(a.text)}catch{a.errorCallback?.();return}if(!i){a.errorCallback?.();return}if(navigator.clipboard?.writeText){navigator.clipboard.writeText(i).then(()=>a.successCallback?.()).catch(()=>Va(i,a));return}Va(i,a)},qo=()=>({copy:sr}),lr=["id","onKeydown"],rr={class:"clipboard-btn"},cr={key:0,class:"clipboard-operate-result"},yn=e.defineComponent({name:"ClClipboard",__name:"Index",props:{id:String,className:String,iconColorClass:String,isUseSuccess:{type:Boolean,default:!0},textLabel:{type:[String,Function],required:!0}},emits:{onCopySuccess:()=>!0,onCopyError:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,l=e.reactive({isHover:!1,isShowSuccess:!1});let d=null,u=!1;const r=e.computed(()=>{let h={"panel-clipboard":!0};return h=o.getJsonMerge(h,de.getClassNameJson(i.className)),h}),c=()=>{d=qo()};e.onMounted(()=>{e.nextTick(()=>{c()})});const m=()=>{if(u)return;let h="";const{textLabel:g}=i;if(g)switch(typeof g){case"function":try{h=g()}catch{h="",t("onCopyError","复制失败 textLabel()")}break;case"string":h=g;break;default:h="";break}o.isEmpty(h)||!d||(u=!0,d.copy({text:h,successCallback:()=>{l.isShowSuccess=!0,t("onCopySuccess"),u=!1},errorCallback:()=>{l.isShowSuccess=!1,t("onCopyError",h),u=!1}}))},p=()=>{l.isHover=!0},f=()=>{l.isShowSuccess=!1,l.isHover=!1};return(h,g)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(r.value),id:e.unref(s),tabindex:"0",role:"button","aria-label":"复制",onMouseenter:p,onMouseleave:f,onClick:e.withModifiers(m,["stop"]),onKeydown:[e.withKeys(e.withModifiers(m,["prevent"]),["enter"]),e.withKeys(e.withModifiers(m,["prevent"]),["space"])]},[e.createElementVNode("div",rr,[e.renderSlot(h.$slots,"default",{},()=>[e.createVNode(ve,{name:"copy",className:i.iconColorClass},null,8,["className"])])]),n.isUseSuccess&&l.isHover&&l.isShowSuccess?(e.openBlock(),e.createElementBlock("div",cr,[e.createVNode(ve,{name:"check1"})])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],42,lr))}}),vn=e.defineComponent({name:"ClTransitionSlideUpDown",__name:"SlideUpDown",setup(n){const a=e.reactive({oldPaddingTop:"",oldPaddingBottom:"",oldOverflow:""}),i=(c,m)=>{const p=function(){m(),c.removeEventListener("transitionend",p,!1),c.removeEventListener("transitioncancel",p,!1)};c.addEventListener("transitionend",p,!1),c.addEventListener("transitioncancel",p,!1)},t=c=>{const m=c;a.oldPaddingBottom=m.style.paddingBottom,a.oldPaddingTop=m.style.paddingTop,a.oldOverflow=m.style.overflow,m.style.paddingTop="0",m.style.paddingBottom="0",m.style.maxHeight="0"},s=(c,m)=>{const p=c,f=p.scrollHeight;if(f>0?p.style.maxHeight=f+"px":p.style.maxHeight="0",p.style.paddingTop=a.oldPaddingTop,p.style.paddingBottom=a.oldPaddingBottom,f===0&&!a.oldPaddingTop&&!a.oldPaddingBottom){m();return}p.style.overflow="hidden",i(c,m)},l=c=>{const m=c;m.style.maxHeight="",m.style.overflow=a.oldOverflow},d=c=>{const m=c;a.oldPaddingBottom=m.style.paddingBottom,a.oldPaddingTop=m.style.paddingTop,a.oldOverflow=m.style.overflow,m.style.maxHeight=m.scrollHeight+"px",m.style.overflow="hidden"},u=(c,m)=>{const p=c;if(p.scrollHeight!==0)p.style.maxHeight="0",p.style.paddingBottom="0",p.style.paddingTop="0";else{m();return}i(c,m)},r=c=>{const m=c;m.style.maxHeight="",m.style.overflow=a.oldOverflow,m.style.paddingBottom=a.oldPaddingBottom,m.style.paddingTop=a.oldPaddingTop,a.oldOverflow=a.oldPaddingBottom=a.oldPaddingTop=""};return(c,m)=>(e.openBlock(),e.createBlock(e.Transition,{name:"clSlideUpDown",onBeforeEnter:t,onEnter:s,onAfterEnter:l,onBeforeLeave:d,onLeave:u,onAfterLeave:r},{default:e.withCtx(()=>[e.renderSlot(c.$slots,"default")]),_:3}))}}),ur=["id"],dr=["tabindex","role","aria-expanded"],mr={class:"collapse-title"},pr=["tabindex","role","aria-expanded","aria-label","onKeydown"],fr={key:0,class:"collapse-body"},hr=300,gr=50,yi=e.defineComponent({name:"ClCollapse",__name:"Index",props:{id:String,className:String,isOperate:{type:Boolean,default:!0},isExpanded:{type:Boolean,default:!0},isCollapseOnTitle:{type:Boolean,default:!1},isDestroyOnCollapse:{type:Boolean,default:!1}},emits:{onCollapse:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=`collapse-${o.getRandom(8)}`,l=e.reactive({isExpanded:o.isBoolean(i.isExpanded)?i.isExpanded:!0,isAnimating:!1});let d=null;const u=hr+gr,r=e.computed(()=>o.isBoolean(i.isCollapseOnTitle)?i.isCollapseOnTitle:!1),c=e.computed(()=>o.isNonEmptyString(i.id)?i.id:s),m=e.computed(()=>o.getJsonMerge({"panel-collapse":!0},de.getClassNameJson(i.className))),p=e.computed(()=>({"collapse-operate":!0,"icon-rotate":!0,"rotate-180":!l.isExpanded})),f=e.computed(()=>({"collapse-head":!0,"collapse-head-clickable":r.value})),h=()=>{d!==null&&(clearTimeout(d),d=null)};e.onUnmounted(()=>{h()}),e.watch(()=>i.isExpanded,E=>{const B=o.isBoolean(E)?E:!0;l.isExpanded!==B&&(h(),l.isAnimating=!1,l.isExpanded=B)});const g=()=>{l.isAnimating||(l.isAnimating=!0,l.isExpanded=!l.isExpanded,h(),d=setTimeout(()=>{d=null,l.isAnimating=!1},u),t("onCollapse",l.isExpanded))},y=E=>{if(!r.value)return;const B=E.target;B instanceof Element&&(B.closest(".collapse-operate")||(E.key==="Enter"||E.key===" ")&&(E.preventDefault(),g()))},V=E=>{if(!r.value)return;const B=E.target;B instanceof Element&&(B.closest(".collapse-operate")||g())};return(E,B)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(m.value),id:c.value},[e.createElementVNode("div",{class:e.normalizeClass(f.value),tabindex:r.value?0:void 0,role:r.value?"button":void 0,"aria-expanded":r.value?l.isExpanded:void 0,onClick:V,onKeydown:y},[e.createElementVNode("div",mr,[e.renderSlot(E.$slots,"title")]),e.withDirectives(e.createElementVNode("i",{class:e.normalizeClass(p.value),tabindex:r.value?-1:0,role:r.value?void 0:"button","aria-expanded":r.value?void 0:l.isExpanded,"aria-label":r.value?void 0:l.isExpanded?"折叠":"展开",onClick:g,onKeydown:[e.withKeys(e.withModifiers(g,["prevent"]),["enter"]),e.withKeys(e.withModifiers(g,["prevent"]),["space"])]},[e.createVNode(ve,{name:"angle-down"})],42,pr),[[e.vShow,e.unref(o).isBoolean(n.isOperate)?n.isOperate:!0]])],42,dr),e.createVNode(vn,null,{default:e.withCtx(()=>[!n.isDestroyOnCollapse||l.isExpanded?e.withDirectives((e.openBlock(),e.createElementBlock("div",fr,[e.renderSlot(E.$slots,"default")],512)),[[e.vShow,l.isExpanded]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),_:3})],10,ur))}}),yr=["id"],vr={key:1,class:"countdown-num"},_a=864e5,Ma=36e5,Oa=6e4,kr=100,Sr=1e3,vi=e.defineComponent({name:"ClCountDown",__name:"Index",props:{id:String,className:String,time:{type:Number,default:0},format:{type:String,default:"HH:mm:ss"},isAutoStart:{type:Boolean,default:!0},isMillisecond:{type:Boolean,default:!1}},emits:["onChange","onFinish"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=`countdown-${o.getRandom(5)}`,d=t.id,u=e.ref(0);let r=null,c=0,m=!1;const p=e.computed(()=>t.isMillisecond?kr:Sr),f=e.computed(()=>{const M=Math.max(0,u.value),b=Math.floor(M/_a),N=Math.floor(M%_a/Ma),J=Math.floor(M%Ma/Oa),q=Math.floor(M%Oa/1e3),z=M%1e3,H={DD:String(b).padStart(2,"0"),HH:String(N).padStart(2,"0"),mm:String(J).padStart(2,"0"),ss:String(q).padStart(2,"0"),SSS:String(z).padStart(3,"0")},v=[],S=t.isMillisecond?/(DD|HH|mm|ss|SSS)/g:/(DD|HH|mm|ss)/g;let C=0,$;for(;($=S.exec(t.format))!==null;){if($.index>C){const k=t.format.slice(C,$.index);v.push({type:g(k)?"sep":"text",value:k})}v.push({type:"num",value:H[$[0]]||$[0]}),C=$.index+$[0].length}if(C<t.format.length){const k=t.format.slice(C);v.push({type:g(k)?"sep":"text",value:k})}return v}),h=e.computed(()=>{const M={"panel-count-down":!0};return o.getJsonMerge(M,de.getClassNameJson(t.className))}),g=M=>{const b=M.trim();return b?/^[\p{P}\p{S}]+$/u.test(b):!1},y=()=>{const M=Number(t.time);return o.isFinite(M)&&M>0?M:0},V=M=>{u.value=Math.max(0,M),c=Date.now()+Math.max(0,M),m=!0,T(),r=setInterval(T,p.value)},E=()=>{if(m)return;const M=y();if(M<=0){u.value=0,s("onFinish");return}V(M)},B=()=>{if(!m){if(u.value<=0){E();return}V(u.value)}},T=()=>{const M=Math.max(0,c-Date.now());u.value=M,s("onChange",M),M<=0&&(D(),s("onFinish"))},D=()=>{r&&(clearInterval(r),r=null),m=!1};return e.onMounted(()=>{t.isAutoStart?E():u.value=y()}),e.onBeforeUnmount(()=>{D()}),e.watch(()=>t.time,()=>{D(),u.value=y(),t.isAutoStart&&u.value>0&&V(u.value)}),e.watch(()=>t.isAutoStart,M=>{M&&!m&&u.value>0&&V(u.value)}),e.watch(p,()=>{m&&(r&&clearInterval(r),r=setInterval(T,p.value))}),a({start:()=>{B()},pause:()=>{D()},reset:()=>{D(),u.value=y()}}),(M,b)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(d),class:e.normalizeClass(h.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(N,J)=>(e.openBlock(),e.createElementBlock("span",{key:`${l}-${J}`,class:e.normalizeClass(["countdown-part",{"countdown-sep":N.type==="sep"}])},[N.type!=="num"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(N.value),1)],64)):(e.openBlock(),e.createElementBlock("span",vr,e.toDisplayString(N.value),1))],2))),128))],10,yr))}});/**!
3
- * Sortable 1.15.0
4
- * @author RubaXa <trash@rubaxa.org>
5
- * @author owenm <owen23355@gmail.com>
6
- * @license MIT
7
- */function Aa(n,a){var i=Object.keys(n);if(Object.getOwnPropertySymbols){var t=Object.getOwnPropertySymbols(n);a&&(t=t.filter(function(s){return Object.getOwnPropertyDescriptor(n,s).enumerable})),i.push.apply(i,t)}return i}function gt(n){for(var a=1;a<arguments.length;a++){var i=arguments[a]!=null?arguments[a]:{};a%2?Aa(Object(i),!0).forEach(function(t){wr(n,t,i[t])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(i)):Aa(Object(i)).forEach(function(t){Object.defineProperty(n,t,Object.getOwnPropertyDescriptor(i,t))})}return n}function An(n){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?An=function(a){return typeof a}:An=function(a){return a&&typeof Symbol=="function"&&a.constructor===Symbol&&a!==Symbol.prototype?"symbol":typeof a},An(n)}function wr(n,a,i){return a in n?Object.defineProperty(n,a,{value:i,enumerable:!0,configurable:!0,writable:!0}):n[a]=i,n}function Et(){return Et=Object.assign||function(n){for(var a=1;a<arguments.length;a++){var i=arguments[a];for(var t in i)Object.prototype.hasOwnProperty.call(i,t)&&(n[t]=i[t])}return n},Et.apply(this,arguments)}function Er(n,a){if(n==null)return{};var i={},t=Object.keys(n),s,l;for(l=0;l<t.length;l++)s=t[l],!(a.indexOf(s)>=0)&&(i[s]=n[s]);return i}function br(n,a){if(n==null)return{};var i=Er(n,a),t,s;if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(n);for(s=0;s<l.length;s++)t=l[s],!(a.indexOf(t)>=0)&&Object.prototype.propertyIsEnumerable.call(n,t)&&(i[t]=n[t])}return i}var Cr="1.15.0";function wt(n){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(n)}var Ct=wt(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),kn=wt(/Edge/i),La=wt(/firefox/i),un=wt(/safari/i)&&!wt(/chrome/i)&&!wt(/android/i),ki=wt(/iP(ad|od|hone)/i),Si=wt(/chrome/i)&&wt(/android/i),wi={capture:!1,passive:!1};function Ae(n,a,i){n.addEventListener(a,i,!Ct&&wi)}function Me(n,a,i){n.removeEventListener(a,i,!Ct&&wi)}function Un(n,a){if(a){if(a[0]===">"&&(a=a.substring(1)),n)try{if(n.matches)return n.matches(a);if(n.msMatchesSelector)return n.msMatchesSelector(a);if(n.webkitMatchesSelector)return n.webkitMatchesSelector(a)}catch{return!1}return!1}}function xr(n){return n.host&&n!==document&&n.host.nodeType?n.host:n.parentNode}function ft(n,a,i,t){if(n){i=i||document;do{if(a!=null&&(a[0]===">"?n.parentNode===i&&Un(n,a):Un(n,a))||t&&n===i)return n;if(n===i)break}while(n=xr(n))}return null}var $a=/\s+/g;function ot(n,a,i){if(n&&a)if(n.classList)n.classList[i?"add":"remove"](a);else{var t=(" "+n.className+" ").replace($a," ").replace(" "+a+" "," ");n.className=(t+(i?" "+a:"")).replace($a," ")}}function Ve(n,a,i){var t=n&&n.style;if(t){if(i===void 0)return document.defaultView&&document.defaultView.getComputedStyle?i=document.defaultView.getComputedStyle(n,""):n.currentStyle&&(i=n.currentStyle),a===void 0?i:i[a];!(a in t)&&a.indexOf("webkit")===-1&&(a="-webkit-"+a),t[a]=i+(typeof i=="string"?"":"px")}}function Yt(n,a){var i="";if(typeof n=="string")i=n;else do{var t=Ve(n,"transform");t&&t!=="none"&&(i=t+" "+i)}while(!a&&(n=n.parentNode));var s=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return s&&new s(i)}function Ei(n,a,i){if(n){var t=n.getElementsByTagName(a),s=0,l=t.length;if(i)for(;s<l;s++)i(t[s],s);return t}return[]}function st(){var n=document.scrollingElement;return n||document.documentElement}function je(n,a,i,t,s){if(!(!n.getBoundingClientRect&&n!==window)){var l,d,u,r,c,m,p;if(n!==window&&n.parentNode&&n!==st())l=n.getBoundingClientRect(),d=l.top,u=l.left,r=l.bottom,c=l.right,m=l.height,p=l.width;else{var f=document.documentElement.clientWidth||document.body.clientWidth||window.innerWidth,h=document.documentElement.clientHeight||document.body.clientHeight||window.innerHeight;d=0,u=0,r=h,c=f,m=h,p=f}if((a||i)&&n!==window&&(s=s||n.parentNode,!Ct))do if(s&&s.getBoundingClientRect&&(Ve(s,"transform")!=="none"||i&&Ve(s,"position")!=="static")){var g=s.getBoundingClientRect();d-=g.top+parseInt(Ve(s,"border-top-width")),u-=g.left+parseInt(Ve(s,"border-left-width")),r=d+l.height,c=u+l.width;break}while(s=s.parentNode);if(t&&n!==window){var y=Yt(s||n),V=y&&y.a,E=y&&y.d;y&&(d/=E,u/=V,p/=V,m/=E,r=d+m,c=u+p)}return{top:d,left:u,bottom:r,right:c,width:p,height:m}}}function Fa(n,a,i){for(var t=Tt(n,!0),s=je(n)[a];t;){var l=je(t)[i],d=void 0;if(d=s>=l,!d)return t;if(t===st())break;t=Tt(t,!1)}return!1}function Xt(n,a,i,t){for(var s=0,l=0,d=n.children;l<d.length;){if(d[l].style.display!=="none"&&d[l]!==Te.ghostClone&&(t||d[l]!==Te.dragged)&&ft(d[l],i.draggable,n,!1)){if(s===a)return d[l];s++}l++}return null}function Xo(n,a){for(var i=n.lastElementChild;i&&(i===Te.ghostClone||Ve(i,"display")==="none"||a&&!Un(i,a));)i=i.previousElementSibling;return i||null}function it(n,a){var i=0;if(!n||!n.parentNode)return-1;for(;n=n.previousElementSibling;)n.nodeName.toUpperCase()!=="TEMPLATE"&&n!==Te.clone&&(!a||Un(n,a))&&i++;return i}function Pa(n){var a=0,i=0,t=st();if(n)do{var s=Yt(n),l=s.a,d=s.d;a+=n.scrollLeft*l,i+=n.scrollTop*d}while(n!==t&&(n=n.parentNode));return[a,i]}function Br(n,a){for(var i in n)if(n.hasOwnProperty(i)){for(var t in a)if(a.hasOwnProperty(t)&&a[t]===n[i][t])return Number(i)}return-1}function Tt(n,a){if(!n||!n.getBoundingClientRect)return st();var i=n,t=!1;do if(i.clientWidth<i.scrollWidth||i.clientHeight<i.scrollHeight){var s=Ve(i);if(i.clientWidth<i.scrollWidth&&(s.overflowX=="auto"||s.overflowX=="scroll")||i.clientHeight<i.scrollHeight&&(s.overflowY=="auto"||s.overflowY=="scroll")){if(!i.getBoundingClientRect||i===document.body)return st();if(t||a)return i;t=!0}}while(i=i.parentNode);return st()}function Dr(n,a){if(n&&a)for(var i in a)a.hasOwnProperty(i)&&(n[i]=a[i]);return n}function go(n,a){return Math.round(n.top)===Math.round(a.top)&&Math.round(n.left)===Math.round(a.left)&&Math.round(n.height)===Math.round(a.height)&&Math.round(n.width)===Math.round(a.width)}var dn;function bi(n,a){return function(){if(!dn){var i=arguments,t=this;i.length===1?n.call(t,i[0]):n.apply(t,i),dn=setTimeout(function(){dn=void 0},a)}}}function Ir(){clearTimeout(dn),dn=void 0}function Ci(n,a,i){n.scrollLeft+=a,n.scrollTop+=i}function xi(n){var a=window.Polymer,i=window.jQuery||window.Zepto;return a&&a.dom?a.dom(n).cloneNode(!0):i?i(n).clone(!0)[0]:n.cloneNode(!0)}var Ge="Sortable"+new Date().getTime();function Tr(){var n=[],a;return{captureAnimationState:function(){if(n=[],!!this.options.animation){var t=[].slice.call(this.el.children);t.forEach(function(s){if(!(Ve(s,"display")==="none"||s===Te.ghostClone)){n.push({target:s,rect:je(s)});var l=gt({},n[n.length-1].rect);if(s.thisAnimationDuration){var d=Yt(s,!0);d&&(l.top-=d.f,l.left-=d.e)}s.fromRect=l}})}},addAnimationState:function(t){n.push(t)},removeAnimationState:function(t){n.splice(Br(n,{target:t}),1)},animateAll:function(t){var s=this;if(!this.options.animation){clearTimeout(a),typeof t=="function"&&t();return}var l=!1,d=0;n.forEach(function(u){var r=0,c=u.target,m=c.fromRect,p=je(c),f=c.prevFromRect,h=c.prevToRect,g=u.rect,y=Yt(c,!0);y&&(p.top-=y.f,p.left-=y.e),c.toRect=p,c.thisAnimationDuration&&go(f,p)&&!go(m,p)&&(g.top-p.top)/(g.left-p.left)===(m.top-p.top)/(m.left-p.left)&&(r=Vr(g,f,h,s.options)),go(p,m)||(c.prevFromRect=m,c.prevToRect=p,r||(r=s.options.animation),s.animate(c,g,p,r)),r&&(l=!0,d=Math.max(d,r),clearTimeout(c.animationResetTimer),c.animationResetTimer=setTimeout(function(){c.animationTime=0,c.prevFromRect=null,c.fromRect=null,c.prevToRect=null,c.thisAnimationDuration=null},r),c.thisAnimationDuration=r)}),clearTimeout(a),l?a=setTimeout(function(){typeof t=="function"&&t()},d):typeof t=="function"&&t(),n=[]},animate:function(t,s,l,d){if(d){Ve(t,"transition",""),Ve(t,"transform","");var u=Yt(this.el),r=u&&u.a,c=u&&u.d,m=(s.left-l.left)/(r||1),p=(s.top-l.top)/(c||1);t.animatingX=!!m,t.animatingY=!!p,Ve(t,"transform","translate3d("+m+"px,"+p+"px,0)"),this.forRepaintDummy=Nr(t),Ve(t,"transition","transform "+d+"ms"+(this.options.easing?" "+this.options.easing:"")),Ve(t,"transform","translate3d(0,0,0)"),typeof t.animated=="number"&&clearTimeout(t.animated),t.animated=setTimeout(function(){Ve(t,"transition",""),Ve(t,"transform",""),t.animated=!1,t.animatingX=!1,t.animatingY=!1},d)}}}}function Nr(n){return n.offsetWidth}function Vr(n,a,i,t){return Math.sqrt(Math.pow(a.top-n.top,2)+Math.pow(a.left-n.left,2))/Math.sqrt(Math.pow(a.top-i.top,2)+Math.pow(a.left-i.left,2))*t.animation}var Ht=[],yo={initializeByDefault:!0},Sn={mount:function(a){for(var i in yo)yo.hasOwnProperty(i)&&!(i in a)&&(a[i]=yo[i]);Ht.forEach(function(t){if(t.pluginName===a.pluginName)throw"Sortable: Cannot mount plugin ".concat(a.pluginName," more than once")}),Ht.push(a)},pluginEvent:function(a,i,t){var s=this;this.eventCanceled=!1,t.cancel=function(){s.eventCanceled=!0};var l=a+"Global";Ht.forEach(function(d){i[d.pluginName]&&(i[d.pluginName][l]&&i[d.pluginName][l](gt({sortable:i},t)),i.options[d.pluginName]&&i[d.pluginName][a]&&i[d.pluginName][a](gt({sortable:i},t)))})},initializePlugins:function(a,i,t,s){Ht.forEach(function(u){var r=u.pluginName;if(!(!a.options[r]&&!u.initializeByDefault)){var c=new u(a,i,a.options);c.sortable=a,c.options=a.options,a[r]=c,Et(t,c.defaults)}});for(var l in a.options)if(a.options.hasOwnProperty(l)){var d=this.modifyOption(a,l,a.options[l]);typeof d<"u"&&(a.options[l]=d)}},getEventProperties:function(a,i){var t={};return Ht.forEach(function(s){typeof s.eventProperties=="function"&&Et(t,s.eventProperties.call(i[s.pluginName],a))}),t},modifyOption:function(a,i,t){var s;return Ht.forEach(function(l){a[l.pluginName]&&l.optionListeners&&typeof l.optionListeners[i]=="function"&&(s=l.optionListeners[i].call(a[l.pluginName],t))}),s}};function _r(n){var a=n.sortable,i=n.rootEl,t=n.name,s=n.targetEl,l=n.cloneEl,d=n.toEl,u=n.fromEl,r=n.oldIndex,c=n.newIndex,m=n.oldDraggableIndex,p=n.newDraggableIndex,f=n.originalEvent,h=n.putSortable,g=n.extraEventProperties;if(a=a||i&&i[Ge],!!a){var y,V=a.options,E="on"+t.charAt(0).toUpperCase()+t.substr(1);window.CustomEvent&&!Ct&&!kn?y=new CustomEvent(t,{bubbles:!0,cancelable:!0}):(y=document.createEvent("Event"),y.initEvent(t,!0,!0)),y.to=d||i,y.from=u||i,y.item=s||i,y.clone=l,y.oldIndex=r,y.newIndex=c,y.oldDraggableIndex=m,y.newDraggableIndex=p,y.originalEvent=f,y.pullMode=h?h.lastPutMode:void 0;var B=gt(gt({},g),Sn.getEventProperties(t,a));for(var T in B)y[T]=B[T];i&&i.dispatchEvent(y),V[E]&&V[E].call(a,y)}}var Mr=["evt"],tt=function(a,i){var t=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},s=t.evt,l=br(t,Mr);Sn.pluginEvent.bind(Te)(a,i,gt({dragEl:ye,parentEl:Je,ghostEl:Ne,rootEl:$e,nextEl:At,lastDownEl:Ln,cloneEl:Ue,cloneHidden:It,dragStarted:ln,putSortable:Xe,activeSortable:Te.active,originalEvent:s,oldIndex:jt,oldDraggableIndex:mn,newIndex:at,newDraggableIndex:Dt,hideGhostForTarget:Ti,unhideGhostForTarget:Ni,cloneNowHidden:function(){It=!0},cloneNowShown:function(){It=!1},dispatchSortableEvent:function(u){et({sortable:i,name:u,originalEvent:s})}},l))};function et(n){_r(gt({putSortable:Xe,cloneEl:Ue,targetEl:ye,rootEl:$e,oldIndex:jt,oldDraggableIndex:mn,newIndex:at,newDraggableIndex:Dt},n))}var ye,Kt,Je,Ne,sn,nn,$e,At,Ln,Ue,It,jt,at,mn,Dt,Ut,Xe,Wt=!1,zn=!1,Jn=[],rt,ut,vo,ko,Ra,Ha,ln,zt,pn,fn=!1,Tn=!1,$n,He,So=[],Ro=!1,Kn=[],on=null,pt=null,wo=null,St=null,Xn=typeof document<"u",Jt=ki,Ua=kn||Ct?"cssFloat":"float",Or=Xn&&!Si&&!ki&&"draggable"in document.createElement("div"),Bi=(function(){if(Xn){if(Ct)return!1;var n=document.createElement("x");return n.style.cssText="pointer-events:auto",n.style.pointerEvents==="auto"}})(),Di=function(a,i){var t=Ve(a),s=parseInt(t.width)-parseInt(t.paddingLeft)-parseInt(t.paddingRight)-parseInt(t.borderLeftWidth)-parseInt(t.borderRightWidth),l=Xt(a,0,i),d=Xt(a,1,i),u=l&&Ve(l),r=d&&Ve(d),c=u&&parseInt(u.marginLeft)+parseInt(u.marginRight)+je(l).width,m=r&&parseInt(r.marginLeft)+parseInt(r.marginRight)+je(d).width;if(t.display==="flex")return t.flexDirection==="column"||t.flexDirection==="column-reverse"?"vertical":"horizontal";if(t.display==="grid")return t.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(l&&u.float&&u.float!=="none"){var p=u.float==="left"?"left":"right";return d&&(r.clear==="both"||r.clear===p)?"vertical":"horizontal"}return l&&(u.display==="block"||u.display==="flex"||u.display==="table"||u.display==="grid"||c>=s&&t[Ua]==="none"||d&&t[Ua]==="none"&&c+m>s)?"vertical":"horizontal"},Ar=function(a,i,t){var s=t?a.left:a.top,l=t?a.right:a.bottom,d=t?a.width:a.height,u=t?i.left:i.top,r=t?i.right:i.bottom,c=t?i.width:i.height;return s===u||l===r||s+d/2===u+c/2},Lr=function(a,i){var t;return Jn.some(function(s){var l=s[Ge].options.emptyInsertThreshold;if(!(!l||Xo(s))){var d=je(s),u=a>=d.left-l&&a<=d.right+l,r=i>=d.top-l&&i<=d.bottom+l;if(u&&r)return t=s}}),t},Ii=function(a){function i(l,d){return function(u,r,c,m){var p=u.options.group.name&&r.options.group.name&&u.options.group.name===r.options.group.name;if(l==null&&(d||p))return!0;if(l==null||l===!1)return!1;if(d&&l==="clone")return l;if(typeof l=="function")return i(l(u,r,c,m),d)(u,r,c,m);var f=(d?u:r).options.group.name;return l===!0||typeof l=="string"&&l===f||l.join&&l.indexOf(f)>-1}}var t={},s=a.group;(!s||An(s)!="object")&&(s={name:s}),t.name=s.name,t.checkPull=i(s.pull,!0),t.checkPut=i(s.put),t.revertClone=s.revertClone,a.group=t},Ti=function(){!Bi&&Ne&&Ve(Ne,"display","none")},Ni=function(){!Bi&&Ne&&Ve(Ne,"display","")};Xn&&!Si&&document.addEventListener("click",function(n){if(zn)return n.preventDefault(),n.stopPropagation&&n.stopPropagation(),n.stopImmediatePropagation&&n.stopImmediatePropagation(),zn=!1,!1},!0);var Mt=function(a){if(ye){a=a.touches?a.touches[0]:a;var i=Lr(a.clientX,a.clientY);if(i){var t={};for(var s in a)a.hasOwnProperty(s)&&(t[s]=a[s]);t.clientX=a.clientX,t.clientY=a.clientY,t.pageX=a.pageX!==void 0?a.pageX:a.clientX,t.pageY=a.pageY!==void 0?a.pageY:a.clientY,t.target=t.rootEl=i,t.preventDefault=void 0,t.stopPropagation=void 0,i[Ge]._onDragOver(t)}}},$r=function(a){if(ye){var i=ke._findOwnerSortable(ye.parentNode);i&&i._isOutsideThisEl(a.target)}};function Te(n,a){if(!(n&&n.nodeType&&n.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(n));this.el=n,this.options=a=Et({},a),n[Ge]=this;var i={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(n.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return Di(n,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(d,u){d.setData("Text",u.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:Te.supportPointer!==!1&&"PointerEvent"in window&&!un,emptyInsertThreshold:5,extOption:{boundary:{isOut:!1,element:"",x:0,y:0},wrapBody:{isWrap:!1,element:""},cross:{isCross:!1,isSameStruct:!0,dropEndBeforeCallback:null},tree:{isTree:!1,maxDepth:3,indentThreshold:20,isOnlyInnerMove:!1,isDragToChild:!0,isDragToParent:!0,rootId:"",regionCls:".darg-region"}}};Sn.initializePlugins(this,n,i);for(var t in i)!(t in a)&&(a[t]=i[t]);Ii(a);for(var s in this)s.charAt(0)==="_"&&typeof this[s]=="function"&&(this[s]=this[s].bind(this));this.nativeDraggable=a.forceFallback?!1:Or,this.nativeDraggable&&(this.options.touchStartThreshold=1),a.supportPointer?Ae(n,"pointerdown",this._onTapStart):(Ae(n,"mousedown",this._onTapStart),Ae(n,"touchstart",this._onTapStart)),this.nativeDraggable&&(Ae(n,"dragover",this),Ae(n,"dragenter",this)),Jn.push(this.el),a.store&&a.store.get&&this.sort(a.store.get(this)||[]),Et(this,Tr())}Te.prototype={constructor:Te,_isOutsideThisEl:function(a){!this.el.contains(a)&&a!==this.el&&(zt=null)},_getDirection:function(a,i){return typeof this.options.direction=="function"?this.options.direction.call(this,a,i,ye):this.options.direction},_onTapStart:function(a){if(a.cancelable){var i=this,t=this.el,s=this.options,l=s.preventOnFilter,d=a.type,u=a.touches&&a.touches[0]||a.pointerType&&a.pointerType==="touch"&&a,r=(u||a).target,c=a.target.shadowRoot&&(a.path&&a.path[0]||a.composedPath&&a.composedPath()[0])||r,m=s.filter;if(Kr(t),!ye&&!(/mousedown|pointerdown/.test(d)&&a.button!==0||s.disabled)&&!c.isContentEditable&&!(!this.nativeDraggable&&un&&r&&r.tagName.toUpperCase()==="SELECT")){var p=t;if(ke.isTreeMode(s)){var f=ke._treeRegionCls(s),h=ke.getOwnerRegion(r,f);h&&(p=h)}if(r=ft(r,s.draggable,p,!1),!(r&&r.animated)&&Ln!==r){if(jt=it(r),mn=it(r,s.draggable),typeof m=="function"){if(m.call(this,a,r,this)){et({sortable:i,rootEl:c,name:"filter",targetEl:r,toEl:t,fromEl:t}),tt("filter",i,{evt:a}),l&&a.cancelable&&a.preventDefault();return}}else if(m&&(m=m.split(",").some(function(g){if(g=ft(c,g.trim(),t,!1),g)return et({sortable:i,rootEl:g,name:"filter",targetEl:r,fromEl:t,toEl:t}),tt("filter",i,{evt:a}),!0}),m)){l&&a.cancelable&&a.preventDefault();return}s.handle&&!ft(c,s.handle,t,!1)||this._prepareDragStart(a,u,r)}}}},_prepareDragStart:function(a,i,t){var s=this,l=s.el,d=s.options,u=l.ownerDocument,r,c=!!(d.extOption&&d.extOption.tree&&d.extOption.tree.isTree),m=!1;if(t&&!ye){if(t.parentNode===l)m=!0;else if(c&&l.contains(t)){var p=ke.findNearestTreeRoot(t,l);m=p===l}}if(m){var f=je(t);if($e=l,ye=t,Je=ye.parentNode,At=ye.nextSibling,Ln=t,Ut=d.group,Te.dragged=ye,rt={target:ye,clientX:(i||a).clientX,clientY:(i||a).clientY},Ra=rt.clientX-f.left,Ha=rt.clientY-f.top,this._lastX=(i||a).clientX,this._lastY=(i||a).clientY,ke.isTreeMode(d)){var h=i||a;ke._tree.startPageX=h.pageX!==void 0?h.pageX:h.clientX,ke._tree.dropInfo=null,ke._tree.startDragDepth=ke.getNodeDepth(ye,ke._treeRegionCls(d));var g=window.pageXOffset||document.documentElement.scrollLeft||0;ke._tree.startLeftPage=ye.getBoundingClientRect().left+g}if(ye.style["will-change"]="transform",r=function(){if(tt("delayEnded",s,{evt:a}),Te.eventCanceled){s._onDrop();return}s._disableDelayedDragEvents(),!La&&s.nativeDraggable&&(ye.draggable=!0),s._triggerDragStart(a,i),et({sortable:s,name:"choose",originalEvent:a}),ot(ye,d.chosenClass,!0)},d.ignore.split(",").forEach(function(y){Ei(ye,y.trim(),Eo)}),Ae(u,"dragover",Mt),Ae(u,"mousemove",Mt),Ae(u,"touchmove",Mt),Ae(u,"mouseup",s._onDrop),Ae(u,"touchend",s._onDrop),Ae(u,"touchcancel",s._onDrop),La&&this.nativeDraggable&&(this.options.touchStartThreshold=4,ye.draggable=!0),tt("delayStart",this,{evt:a}),d.delay&&(!d.delayOnTouchOnly||i)&&(!this.nativeDraggable||!(kn||Ct))){if(Te.eventCanceled){this._onDrop();return}Ae(u,"mouseup",s._disableDelayedDrag),Ae(u,"touchend",s._disableDelayedDrag),Ae(u,"touchcancel",s._disableDelayedDrag),Ae(u,"mousemove",s._delayedDragTouchMoveHandler),Ae(u,"touchmove",s._delayedDragTouchMoveHandler),d.supportPointer&&Ae(u,"pointermove",s._delayedDragTouchMoveHandler),s._dragStartTimer=setTimeout(r,d.delay)}else r()}},_delayedDragTouchMoveHandler:function(a){var i=a.touches?a.touches[0]:a;Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){ye&&Eo(ye),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var a=this.el.ownerDocument;Me(a,"mouseup",this._disableDelayedDrag),Me(a,"touchend",this._disableDelayedDrag),Me(a,"touchcancel",this._disableDelayedDrag),Me(a,"mousemove",this._delayedDragTouchMoveHandler),Me(a,"touchmove",this._delayedDragTouchMoveHandler),Me(a,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(a,i){i=i||a.pointerType=="touch"&&a,!this.nativeDraggable||i?this.options.supportPointer?Ae(document,"pointermove",this._onTouchMove):i?Ae(document,"touchmove",this._onTouchMove):Ae(document,"mousemove",this._onTouchMove):(Ae(ye,"dragend",this),Ae($e,"dragstart",this._onDragStart));try{document.selection?Fn(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(a,i){if(Wt=!1,$e&&ye){tt("dragStarted",this,{evt:i}),this.nativeDraggable&&Ae(document,"dragover",$r);var t=this.options;!a&&ot(ye,t.dragClass,!1),ot(ye,t.ghostClass,!0),Te.active=this,a&&this._appendGhost(),et({sortable:this,name:"start",originalEvent:i})}else this._nulling()},_emulateDragOver:function(){if(ut){this._lastX=ut.clientX,this._lastY=ut.clientY,Ti();for(var a=document.elementFromPoint(ut.clientX,ut.clientY),i=a;a&&a.shadowRoot&&(a=a.shadowRoot.elementFromPoint(ut.clientX,ut.clientY),a!==i);)i=a;var t=ke._findOwnerSortable(ye.parentNode);if(t&&t._isOutsideThisEl(a),i)do{if(i[Ge]){var s=void 0;if(s=i[Ge]._onDragOver({clientX:ut.clientX,clientY:ut.clientY,target:a,rootEl:i}),s&&!this.options.dragoverBubble)break}a=i}while(i=i.parentNode);Ni()}},_onTouchMove:function(a){if(rt){var i=this.options,t=i.fallbackTolerance,s=i.fallbackOffset,l=a.touches?a.touches[0]:a,d=Ne&&(wo||(wo=Yt(Ne,!0))),u=Ne&&d&&d.a,r=Ne&&d&&d.d,c,m=Jt&&He?st():null,p,f;if(Jt&&He&&(St&&St.el===He&&St.scrollLeft===He.scrollLeft&&St.scrollTop===He.scrollTop&&St.winTop===m.scrollTop&&St.winLeft===m.scrollLeft?c=St.offset:(c=Pa(He),St={el:He,scrollLeft:He.scrollLeft,scrollTop:He.scrollTop,winTop:m.scrollTop,winLeft:m.scrollLeft,offset:c})),p=(l.clientX-rt.clientX+s.x)/(u||1)+(c?c[0]-So[0]:0)/(u||1),f=(l.clientY-rt.clientY+s.y)/(r||1)+(c?c[1]-So[1]:0)/(r||1),!Te.active&&!Wt){if(t&&Math.max(Math.abs(l.clientX-this._lastX),Math.abs(l.clientY-this._lastY))<t)return;this._onDragStart(a,!0)}if(Ne){d?(d.e+=p-(vo||0),d.f+=f-(ko||0)):d={a:1,b:0,c:0,d:1,e:p,f};var h="matrix(".concat(d.a,",").concat(d.b,",").concat(d.c,",").concat(d.d,",").concat(d.e,",").concat(d.f,")");Ve(Ne,"transform",h),vo=p,ko=f,ut=l;const V=ke.checkMoveOutBoundary(Ne,this.el,this.options);if(V.isOut){var g=0;Jt||(on==null&&(on=st().scrollTop),g=st().scrollTop-on),nn?(d.e=nn.e,d.f=nn.f-g):(V.top&&(d.f=V.x*-1-g),V.right&&(d.e=V.y),V.bottom&&(d.f=V.x-g),V.left&&(d.e=V.y*-1));var y="matrix(".concat(d.a,",").concat(d.b,",").concat(d.c,",").concat(d.d,",").concat(d.e,",").concat(d.f,")");Ve(Ne,"transform",y)}else on=null,nn={a:d.a,b:d.b,c:d.c,d:d.d,e:d.e,f:d.f}}a.cancelable&&a.preventDefault()}},_appendGhost:function(){if(!Ne){var a=this.options.fallbackOnBody?document.body:$e,i=je(ye,!0,Jt,!0,a),t=this.options;if(Jt){for(He=a;Ve(He,"position")==="static"&&Ve(He,"transform")==="none"&&He!==document;)He=He.parentNode;He!==document.body&&He!==document.documentElement?(He===document&&(He=st()),i.top+=He.scrollTop,i.left+=He.scrollLeft):He=st(),So=Pa(He)}sn=ye.cloneNode(!0),Ne=ye.cloneNode(!0),Ne=ke.setWrapBody(Ne,this.el,this.options),ot(Ne,t.ghostClass,!1),ot(Ne,t.fallbackClass,!0),ot(Ne,t.dragClass,!0),Ve(Ne,"transition",""),Ve(Ne,"transform",""),Ve(Ne,"box-sizing","border-box"),Ve(Ne,"margin",0),Ve(Ne,"top",i.top),Ve(Ne,"left",i.left),Ve(Ne,"width",i.width),Ve(Ne,"height",i.height),Ve(Ne,"opacity","0.8"),Ve(Ne,"position",Jt?"absolute":"fixed"),Ve(Ne,"zIndex","100000"),Ve(Ne,"pointerEvents","none"),Te.ghost=Ne,Te.ghostClone=sn,a.appendChild(Ne),Ve(Ne,"transform-origin",Ra/parseInt(Ne.style.width)*100+"% "+Ha/parseInt(Ne.style.height)*100+"%")}},_onDragStart:function(a,i){var t=this,s=a.dataTransfer,l=t.options;if(tt("dragStart",this,{evt:a}),Te.eventCanceled){this._onDrop();return}tt("setupClone",this),Te.eventCanceled||(Ue=xi(ye),Ue.removeAttribute("id"),Ue.draggable=!1,Ue.style["will-change"]="",this._hideClone(),ot(Ue,this.options.chosenClass,!1),Te.clone=Ue),t.cloneId=Fn(function(){tt("clone",t),!Te.eventCanceled&&(t.options.removeCloneOnHide||$e.insertBefore(Ue,ye),t._hideClone(),et({sortable:t,name:"clone"}))}),!i&&ot(ye,l.dragClass,!0),i?(zn=!0,t._loopId=setInterval(t._emulateDragOver,50)):(Me(document,"mouseup",t._onDrop),Me(document,"touchend",t._onDrop),Me(document,"touchcancel",t._onDrop),s&&(s.effectAllowed="move",l.setData&&l.setData.call(t,s,ye)),Ae(document,"drop",t),Ve(ye,"transform","translateZ(0)")),Wt=!0,t._dragStartId=Fn(t._dragStarted.bind(t,i,a)),Ae(document,"selectstart",t),ln=!0,un&&Ve(document.body,"user-select","none")},_onDragOver:function(a){var i=this.el,t=a.target,s,l,d,u=this.options,r=u.group,c=Te.active,m=Ut===r,p=u.sort,f=Xe||c,h,g=this,y=!1;if(Ro)return;if(ke.isTreeMode(u)){var V=m;if(!V&&r&&Ut){var E=!!r.name&&r.name===Ut.name;E&&(V=typeof r.checkPut=="function"?!!r.checkPut(this,c,ye,a):!0)}if(!V){ke._tree.dropInfo={isReject:!0,reason:"out-of-group"},ke.renderTreeIndicator(this,a),a.cancelable&&a.preventDefault();return}ke.treeDragOver(this,a,t),ke.renderTreeIndicator(this,a),a.cancelable&&a.preventDefault();return}function B(I,L){tt(I,g,gt({evt:a,isOwner:m,axis:h?"vertical":"horizontal",revert:d,dragRect:s,targetRect:l,canSort:p,fromSortable:f,target:t,completed:D,onMove:function(R,P){return Nn($e,i,ye,s,R,je(R),a,P)},changed:x},L))}function T(){B("dragOverAnimationCapture"),g.captureAnimationState(),g!==f&&f.captureAnimationState()}function D(I){if(B("dragOverCompleted",{insertion:I}),I&&(m?c._hideClone():c._showClone(g),g!==f&&(ot(ye,Xe?Xe.options.ghostClass:c.options.ghostClass,!1),ot(ye,u.ghostClass,!0)),Xe!==g&&g!==Te.active?Xe=g:g===Te.active&&Xe&&(Xe=null),f===g&&(g._ignoreWhileAnimating=t),g.animateAll(function(){B("dragOverAnimationComplete"),g._ignoreWhileAnimating=null}),g!==f&&(f.animateAll(),f._ignoreWhileAnimating=null)),(t===ye&&!ye.animated||t===i&&!t.animated)&&(zt=null),!u.dragoverBubble&&!a.rootEl&&t!==document){var L=ke._findOwnerSortable(ye.parentNode);L&&L._isOutsideThisEl(a.target),!I&&Mt(a)}return!u.dragoverBubble&&a.stopPropagation&&a.stopPropagation(),y=!0}function x(){at=it(ye),Dt=it(ye,u.draggable),et({sortable:g,name:"change",toEl:i,newIndex:at,newDraggableIndex:Dt,originalEvent:a})}if(a.preventDefault!==void 0&&a.cancelable&&a.preventDefault(),t=ft(t,u.draggable,i,!0),B("dragOver"),Te.eventCanceled)return y;if(ye.contains(a.target)||t.animated&&t.animatingX&&t.animatingY||g._ignoreWhileAnimating===t)return D(!1);if(zn=!1,c&&!u.disabled&&(m?p||(d=Je!==$e):Xe===this||(this.lastPutMode=Ut.checkPull(this,c,ye,a))&&r.checkPut(this,c,ye,a))){if(h=this._getDirection(a,t)==="vertical",s=je(ye),B("dragOverValid"),Te.eventCanceled)return y;if(d)return Je=$e,T(),this._hideClone(),B("revert"),Te.eventCanceled||(ke.setCrossEl(t,this.options),At?$e.insertBefore(ye,At):$e.appendChild(ye)),D(!0);var O=Xo(i,u.draggable);if(!O||Hr(a,h,this)&&!O.animated){if(O===ye)return D(!1);if(O&&i===a.target&&(t=O),t&&(l=je(t)),Nn($e,i,ye,s,t,l,a,!!t)!==!1)return T(),ke.setCrossEl(t,this.options),O&&O.nextSibling?i.insertBefore(ye,O.nextSibling):i.appendChild(ye),Je=i,x(),D(!0)}else if(O&&Rr(a,h,this)){var w=Xt(i,0,u,!0);if(w===ye)return D(!1);if(t=w,l=je(t),Nn($e,i,ye,s,t,l,a,!1)!==!1)return T(),ke.setCrossEl(t,this.options),i.insertBefore(ye,w),Je=i,x(),D(!0)}else if(t.parentNode===i){l=je(t);var M=0,b,N=ye.parentNode!==i,J=!Ar(ye.animated&&ye.toRect||s,t.animated&&t.toRect||l,h),q=h?"top":"left",z=Fa(t,"top","top")||Fa(ye,"top","top"),H=z?z.scrollTop:void 0;zt!==t&&(b=l[q],fn=!1,Tn=!J&&u.invertSwap||N),M=Ur(a,t,l,h,J?1:u.swapThreshold,u.invertedSwapThreshold==null?u.swapThreshold:u.invertedSwapThreshold,Tn,zt===t);var v;if(M!==0){var S=it(ye);do S-=M,v=Je.children[S];while(v&&(Ve(v,"display")==="none"||v===sn))}if(M===0||v===t)return D(!1);zt=t,pn=M;var C=t.nextElementSibling,$=!1;$=M===1;var k=Nn($e,i,ye,s,t,l,a,$);if(k!==!1)return(k===1||k===-1)&&($=k===1),Ro=!0,setTimeout(Pr,30),T(),ke.setCrossEl(t,this.options),$&&!C?i.appendChild(ye):t.parentNode.insertBefore(ye,$?C:t),z&&Ci(z,0,H-z.scrollTop),Je=ye.parentNode,b!==void 0&&!Tn&&($n=Math.abs(b-je(t)[q])),x(),D(!0)}if(i.contains(ye))return D(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){Me(document,"mousemove",this._onTouchMove),Me(document,"touchmove",this._onTouchMove),Me(document,"pointermove",this._onTouchMove),Me(document,"dragover",Mt),Me(document,"mousemove",Mt),Me(document,"touchmove",Mt)},_offUpEvents:function(){var a=this.el.ownerDocument;Me(a,"mouseup",this._onDrop),Me(a,"touchend",this._onDrop),Me(a,"pointerup",this._onDrop),Me(a,"touchcancel",this._onDrop),Me(document,"selectstart",this)},_onDrop:function(a){ke.crossDropEnd(this.options,this.el).then(i=>{if(!this.el){this._nulling();return}if(i){var t=this.el,s=this.options;if(at=it(ye),Dt=it(ye,s.draggable),tt("drop",this,{evt:a}),Je=ye&&ye.parentNode,at=it(ye),Dt=it(ye,s.draggable),ke.isTreeMode(s)&&typeof s.onUpdate=="function"&&s.onUpdate(),Te.eventCanceled){this._nulling();return}Wt=!1,Tn=!1,fn=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),Ho(this.cloneId),Ho(this._dragStartId),this.nativeDraggable&&(Me(document,"drop",this),Me(t,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),un&&Ve(document.body,"user-select",""),Ve(ye,"transform",""),a&&(ln&&(a.cancelable&&a.preventDefault(),!s.dropBubble&&a.stopPropagation()),Ne&&Ne.parentNode&&Ne.parentNode.removeChild(Ne),($e===Je||Xe&&Xe.lastPutMode!=="clone")&&Ue&&Ue.parentNode&&Ue.parentNode.removeChild(Ue),ye&&(this.nativeDraggable&&Me(ye,"dragend",this),Eo(ye),ye.style["will-change"]="",ln&&!Wt&&ot(ye,Xe?Xe.options.ghostClass:this.options.ghostClass,!1),ot(ye,this.options.chosenClass,!1),et({sortable:this,name:"unchoose",toEl:Je,newIndex:null,newDraggableIndex:null,originalEvent:a}),$e!==Je?(at>=0&&(et({rootEl:Je,name:"add",toEl:Je,fromEl:$e,originalEvent:a}),et({sortable:this,name:"remove",toEl:Je,originalEvent:a}),et({rootEl:Je,name:"sort",toEl:Je,fromEl:$e,originalEvent:a}),et({sortable:this,name:"sort",toEl:Je,originalEvent:a})),Xe&&Xe.save()):at!==jt&&at>=0&&(et({sortable:this,name:"update",toEl:Je,originalEvent:a}),et({sortable:this,name:"sort",toEl:Je,originalEvent:a})),Te.active&&((at==null||at===-1)&&(at=jt,Dt=mn),et({sortable:this,name:"end",toEl:Je,originalEvent:a}),this.save()))),this._nulling()}})},_nulling:function(){tt("nulling",this),$e=ye=Kt=Je=Ne=sn=At=Ue=Ln=It=rt=ut=ln=at=Dt=jt=mn=zt=pn=Xe=Ut=Te.dragged=Te.ghost=Te.ghostClone=Te.clone=Te.active=nn=on=wo=St=null,ke._clearHiddenBox(),ke.resetTreeState(),Kn.forEach(function(a){a.checked=!0}),Kn.length=vo=ko=0},handleEvent:function(a){switch(a.type){case"drop":case"dragend":this._onDrop(a);break;case"dragenter":case"dragover":ye&&(this._onDragOver(a),Fr(a));break;case"selectstart":a.preventDefault();break}},toArray:function(a){for(var i=[],t,s=this.el.children,l=0,d=s.length,u=this.options;l<d;l++)t=s[l],ft(t,u.draggable,this.el,!1)&&i.push(t.getAttribute(u.dataIdAttr)||Jr(t));return i},sort:function(a,i){var t={},s=this.el;this.toArray().forEach(function(l,d){var u=s.children[d];ft(u,this.options.draggable,s,!1)&&(t[l]=u)},this),i&&this.captureAnimationState(),a.forEach(function(l){t[l]&&(s.removeChild(t[l]),s.appendChild(t[l]))}),i&&this.animateAll()},save:function(){var a=this.options.store;a&&a.set&&a.set(this)},closest:function(a,i){return ft(a,i||this.options.draggable,this.el,!1)},option:function(a,i){var t=this.options;if(i===void 0)return t[a];var s=Sn.modifyOption(this,a,i);typeof s<"u"?t[a]=s:t[a]=i,a==="group"&&Ii(t)},destroy:function(){tt("destroy",this);var a=this.el;a[Ge]=null,Me(a,"mousedown",this._onTapStart),Me(a,"touchstart",this._onTapStart),Me(a,"pointerdown",this._onTapStart),this.nativeDraggable&&(Me(a,"dragover",this),Me(a,"dragenter",this)),Array.prototype.forEach.call(a.querySelectorAll("[draggable]"),function(i){i.removeAttribute("draggable")}),this._offMoveEvents(),this._offUpEvents(),this._onDrop(),Ne&&Ne.parentNode&&(Ne.parentNode.removeChild(Ne),Ne=null),this._disableDelayedDragEvents(),Jn.splice(Jn.indexOf(this.el),1),this.el=a=null},_hideClone:function(){if(!It){if(tt("hideClone",this),Te.eventCanceled)return;Ve(Ue,"display","none"),this.options.removeCloneOnHide&&Ue.parentNode&&Ue.parentNode.removeChild(Ue),It=!0}},_showClone:function(a){if(a.lastPutMode!=="clone"){this._hideClone();return}if(It){if(tt("showClone",this),Te.eventCanceled)return;ye.parentNode==$e&&!this.options.group.revertClone?$e.insertBefore(Ue,ye):At?$e.insertBefore(Ue,At):$e.appendChild(Ue),this.options.group.revertClone&&this.animate(ye,Ue),Ve(Ue,"display",""),It=!1}}};function Fr(n){n.dataTransfer&&(n.dataTransfer.dropEffect="move"),n.cancelable&&n.preventDefault()}function Nn(n,a,i,t,s,l,d,u){var r,c=n[Ge],m=c.options.onMove,p;return window.CustomEvent&&!Ct&&!kn?r=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(r=document.createEvent("Event"),r.initEvent("move",!0,!0)),r.to=a,r.from=n,r.dragged=i,r.draggedRect=t,r.related=s||a,r.relatedRect=l||je(a),r.willInsertAfter=u,r.originalEvent=d,n.dispatchEvent(r),m&&(p=m.call(c,r,d)),p}function Eo(n){n.draggable=!1}function Pr(){Ro=!1}function Rr(n,a,i){var t=je(Xt(i.el,0,i.options,!0)),s=10;return a?n.clientX<t.left-s||n.clientY<t.top&&n.clientX<t.right:n.clientY<t.top-s||n.clientY<t.bottom&&n.clientX<t.left}function Hr(n,a,i){var t=je(Xo(i.el,i.options.draggable)),s=10;return a?n.clientX>t.right+s||n.clientX<=t.right&&n.clientY>t.bottom&&n.clientX>=t.left:n.clientX>t.right&&n.clientY>t.top||n.clientX<=t.right&&n.clientY>t.bottom+s}function Ur(n,a,i,t,s,l,d,u){var r=t?n.clientY:n.clientX,c=t?i.height:i.width,m=t?i.top:i.left,p=t?i.bottom:i.right,f=!1;if(!d){if(u&&$n<c*s){if(!fn&&(pn===1?r>m+c*l/2:r<p-c*l/2)&&(fn=!0),fn)f=!0;else if(pn===1?r<m+$n:r>p-$n)return-pn}else if(r>m+c*(1-s)/2&&r<p-c*(1-s)/2)return zr(a)}return f=f||d,f&&(r<m+c*l/2||r>p-c*l/2)?r>m+c/2?1:-1:0}function zr(n){return it(ye)<it(n)?1:-1}function Jr(n){for(var a=n.tagName+n.className+n.src+n.href+n.textContent,i=a.length,t=0;i--;)t+=a.charCodeAt(i);return t.toString(36)}function Kr(n){Kn.length=0;for(var a=n.getElementsByTagName("input"),i=a.length;i--;){var t=a[i];t.checked&&Kn.push(t)}}function Fn(n){return setTimeout(n,0)}function Ho(n){return clearTimeout(n)}Xn&&Ae(document,"touchmove",function(n){(Te.active||Wt)&&n.cancelable&&n.preventDefault()});Te.utils={on:Ae,off:Me,css:Ve,find:Ei,is:function(a,i){return!!ft(a,i,a,!1)},extend:Dr,throttle:bi,closest:ft,toggleClass:ot,clone:xi,index:it,nextTick:Fn,cancelNextTick:Ho,detectDirection:Di,getChild:Xt};Te.get=function(n){return n[Ge]};Te.mount=function(){for(var n=arguments.length,a=new Array(n),i=0;i<n;i++)a[i]=arguments[i];a[0].constructor===Array&&(a=a[0]),a.forEach(function(t){if(!t.prototype||!t.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(t));t.utils&&(Te.utils=gt(gt({},Te.utils),t.utils)),Sn.mount(t)})};Te.create=function(n,a){return new Te(n,a)};Te.version=Cr;var We=[],rn,Uo,zo=!1,bo,Co,Wn,cn;function Wr(){function n(){this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var a in this)a.charAt(0)==="_"&&typeof this[a]=="function"&&(this[a]=this[a].bind(this))}return n.prototype={dragStarted:function(i){var t=i.originalEvent;this.sortable.nativeDraggable?Ae(document,"dragover",this._handleAutoScroll):this.options.supportPointer?Ae(document,"pointermove",this._handleFallbackAutoScroll):t.touches?Ae(document,"touchmove",this._handleFallbackAutoScroll):Ae(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(i){var t=i.originalEvent;!this.options.dragOverBubble&&!t.rootEl&&this._handleAutoScroll(t)},drop:function(){this.sortable.nativeDraggable?Me(document,"dragover",this._handleAutoScroll):(Me(document,"pointermove",this._handleFallbackAutoScroll),Me(document,"touchmove",this._handleFallbackAutoScroll),Me(document,"mousemove",this._handleFallbackAutoScroll)),za(),Pn(),Ir()},nulling:function(){Wn=Uo=rn=zo=cn=bo=Co=null,We.length=0},_handleFallbackAutoScroll:function(i){this._handleAutoScroll(i,!0)},_handleAutoScroll:function(i,t){var s=this,l=(i.touches?i.touches[0]:i).clientX,d=(i.touches?i.touches[0]:i).clientY,u=document.elementFromPoint(l,d);if(Wn=i,t||this.options.forceAutoScrollFallback||kn||Ct||un){xo(i,this.options,u,t);var r=Tt(u,!0);zo&&(!cn||l!==bo||d!==Co)&&(cn&&za(),cn=setInterval(function(){var c=Tt(document.elementFromPoint(l,d),!0);c!==r&&(r=c,Pn()),xo(i,s.options,c,t)},10),bo=l,Co=d)}else{if(!this.options.bubbleScroll||Tt(u,!0)===st()){Pn();return}xo(i,this.options,Tt(u,!1),!1)}}},Et(n,{pluginName:"scroll",initializeByDefault:!0})}function Pn(){We.forEach(function(n){clearInterval(n.pid)}),We=[]}function za(){clearInterval(cn)}var xo=bi(function(n,a,i,t){if(a.scroll){var s=(n.touches?n.touches[0]:n).clientX,l=(n.touches?n.touches[0]:n).clientY,d=a.scrollSensitivity,u=a.scrollSpeed,r=st(),c=!1,m;Uo!==i&&(Uo=i,Pn(),rn=a.scroll,m=a.scrollFn,rn===!0&&(rn=Tt(i,!0)));var p=0,f=rn;do{var h=f,g=je(h),y=g.top,V=g.bottom,E=g.left,B=g.right,T=g.width,D=g.height,x=void 0,O=void 0,w=h.scrollWidth,M=h.scrollHeight,b=Ve(h),N=h.scrollLeft,J=h.scrollTop;h===r?(x=T<w&&(b.overflowX==="auto"||b.overflowX==="scroll"||b.overflowX==="visible"),O=D<M&&(b.overflowY==="auto"||b.overflowY==="scroll"||b.overflowY==="visible")):(x=T<w&&(b.overflowX==="auto"||b.overflowX==="scroll"),O=D<M&&(b.overflowY==="auto"||b.overflowY==="scroll"));var q=x&&(Math.abs(B-s)<=d&&N+T<w)-(Math.abs(E-s)<=d&&!!N),z=O&&(Math.abs(V-l)<=d&&J+D<M)-(Math.abs(y-l)<=d&&!!J);if(!We[p])for(var H=0;H<=p;H++)We[H]||(We[H]={});(We[p].vx!=q||We[p].vy!=z||We[p].el!==h)&&(We[p].el=h,We[p].vx=q,We[p].vy=z,clearInterval(We[p].pid),(q!=0||z!=0)&&(c=!0,We[p].pid=setInterval(function(){t&&this.layer===0&&Te.active._onTouchMove(Wn);var v=We[this.layer].vy?We[this.layer].vy*u:0,S=We[this.layer].vx?We[this.layer].vx*u:0;typeof m=="function"&&m.call(Te.dragged.parentNode[Ge],S,v,n,Wn,We[this.layer].el)!=="continue"||Ci(We[this.layer].el,S,v)}.bind({layer:p}),24))),p++}while(a.bubbleScroll&&f!==r&&(f=Tt(f,!1)));zo=c}},30),Vi=function(a){var i=a.originalEvent,t=a.putSortable,s=a.dragEl,l=a.activeSortable,d=a.dispatchSortableEvent,u=a.hideGhostForTarget,r=a.unhideGhostForTarget;if(i){var c=t||l;u();var m=i.changedTouches&&i.changedTouches.length?i.changedTouches[0]:i,p=document.elementFromPoint(m.clientX,m.clientY);r(),c&&!c.el.contains(p)&&(d("spill"),this.onSpill({dragEl:s,putSortable:t}))}};function Go(){}Go.prototype={startIndex:null,dragStart:function(a){var i=a.oldDraggableIndex;this.startIndex=i},onSpill:function(a){var i=a.dragEl,t=a.putSortable;this.sortable.captureAnimationState(),t&&t.captureAnimationState();var s=Xt(this.sortable.el,this.startIndex,this.options);s?this.sortable.el.insertBefore(i,s):this.sortable.el.appendChild(i),this.sortable.animateAll(),t&&t.animateAll()},drop:Vi};Et(Go,{pluginName:"revertOnSpill"});function Qo(){}Qo.prototype={onSpill:function(a){var i=a.dragEl,t=a.putSortable,s=t||this.sortable;s.captureAnimationState(),i.parentNode&&i.parentNode.removeChild(i),s.animateAll()},drop:Vi};Et(Qo,{pluginName:"removeOnSpill"});const ke={isBoolean:n=>typeof n=="boolean",isFunction:n=>typeof n=="function",isUndefined:n=>typeof n>"u"||n===null,isFiniteNumber:n=>typeof n=="number"&&isFinite(n),getOffset:n=>{const a=n.getBoundingClientRect(),t=(n&&n.ownerDocument).documentElement;let s;if(t.toString()!=="[object Window]"){const l=n.ownerDocument;s=l&&l.defaultView||window}else s=t;return{top:a.top+(s.pageYOffset||t.scrollTop)-(t.clientTop||0),left:a.left+(s.pageXOffset||t.scrollLeft)-(t.clientLeft||0),width:a.width,height:a.height}},createElement:n=>{if(n.substring(0,1)==="<"){const i=document.createElement("div");return i.innerHTML=n,i.children[0]}else return document.createElement(n)},getElementData:(n,a)=>{const i=[],t=n.children,s=t.length;let l;for(let d=0;d<s;d++){l=t[d];const u=l.getAttribute(a.dataIdAttr);u&&u.length>0&&i.push(u)}return i},_getHiddenBox:()=>(pt||(pt=document.createElement("div"),pt.style.cssText="position:fixed;left:-99999px;top:0;width:1px;height:1px;overflow:hidden;pointer-events:none;",document.body.appendChild(pt)),pt),_moveToHiddenBox:n=>{n&&n.parentNode&&ke._getHiddenBox().appendChild(n)},_clearHiddenBox:()=>{pt&&pt.parentNode&&(pt.parentNode.removeChild(pt),pt=null)},checkMoveOutBoundary:(n,a,i)=>{let t=!0,s={};const l=i.extOption.boundary;if(l){let d=l.isOut;if(d=ke.isBoolean(d)?d:!0,!d){let u;if(l.element&&l.element.length>0){const r=window.document.querySelector(l.element);r&&(u=ke.getOffset(r))}else u=ke.getOffset(a);if(u){const r=ke.getOffset(n);let c=Number(l.x);isNaN(c)&&(c=0);let m=Number(l.y);isNaN(m)&&(m=0);const p=u.top-c>r.top,f=u.left+u.width+m<r.left+r.width,h=u.top+u.height+c<r.top+r.height,g=u.left-m>r.left;t=!(p||f||h||g),t||(s={top:p,right:f,bottom:h,left:g,x:c,y:m})}}}return s.isOut=!t,s},setWrapBody:(n,a,i)=>{let t=n,s=i.extOption.wrapBody;if(i.fallbackOnBody&&(s?i.extOption.wrapBody.isWrap=!0:i.extOption.wrapBody={isWrap:!0},s=i.extOption.wrapBody),s){let l=s.isWrap;if(l=ke.isBoolean(l)?l:!1,l)if(s.element&&s.element.length>0)t=ke.createElement(s.element),t.appendChild(n);else switch(t=a.cloneNode(),t.appendChild(n),t.tagName.toLocaleLowerCase()){case"tbody":const d=a.parentNode.cloneNode();d.appendChild(t),t=d;break}}return t},checkCross:(n,a,i)=>{const t=i.extOption.cross;let s={newEl:null,isSameStruct:!0};if(t){let l=t.isCross;if(l=ke.isBoolean(l)?l:!1,n.parentNode===a.parentNode&&(l=!1),l){let d=t.isSameStruct;if(d=ke.isBoolean(d)?d:!0,!d){const u=a.tagName.toLocaleLowerCase(),r=ke.createElement(u),c=[],m=["darg-select","darg-placeholder"];switch(a.className.split(" ").forEach(p=>{m.indexOf(p)===-1&&c.push(p)}),c.push(...m),r.className=c.join(" "),Ve(r,"height",a.clientHeight),u){case"tr":let p=0;for(let h=0;h<a.children.length;h++){const g=a.children[h].getAttribute("colspan");p+=ke.isUndefined(g)?1:Number(g)}const f=ke.createElement("td");f.setAttribute("colspan",p),r.appendChild(f);break}s.isSameStruct=!1,s.newEl=r}}}return s},setCrossEl:(n,a)=>{var i=ke.checkCross(ye,n,a);if(!i.isSameStruct){const t=ye.cloneNode(!0);ke._moveToHiddenBox(ye),Kt?(ye=Kt,Kt=null):ye=i.newEl,Kt||(Kt=t)}},crossDropEnd:(n,a)=>new Promise((i,t)=>{const s=n.extOption.cross;let l=!1;const d=ye&&ye.parentNode;if(s){let r=s.isCross;if(r=ke.isBoolean(r)?r:!1,r){let c=!1;if(d)if(ke.isTreeMode(n)){var u=a||Te.active&&Te.active.el||n.el;c=!!u&&!u.contains(ye)}else c=$e!==d;c&&s.dropEndBeforeCallback&&(l=!0)}}if(l){const r=sn||ye,c=r&&r.getAttribute?r.getAttribute(n.dataIdAttr):null,m=ke.getElementData(d,n),p=s.dropEndBeforeCallback({data:c,inx:it(ye),arrSortId:m});if(p&&p.then&&ke.isFunction(p.then))ke._crossDropLoad(!0),p.then(f=>{ke._crossDropLoad(!1);const h=ke._crossDropEndCb(f);i({success:h})});else{const f=ke._crossDropEndCb(p);i({success:f})}}else i({success:!0})}),_crossDropLoad:n=>{let a;const i=ye.tagName.toLocaleLowerCase();if(ye.children.length===0)a=ye;else switch(i){case"tr":a=ye.children[0];break}if(n){const t=ke.createElement("div");t.className="panel-darg-loading",t.innerHTML='<div class="darg-add-loading"></div>',a.appendChild(t)}else{const t=ye.querySelector(".panel-darg-loading");t&&t.parentNode&&t.parentNode.removeChild(t)}},_crossDropEndCb:n=>{var a=ke.isBoolean(n)?n:!0;return a&&ye&&ye.parentNode&&ye.parentNode.removeChild(ye),a},_tree:{startPageX:0,startDragDepth:null,startLeftPage:null,depthCache:null,dropInfo:null},_findOwnerSortable:n=>{for(var a=n;a;){var i=a[Ge];if(i&&ke.isFunction(i._isOutsideThisEl))return i;a=a.parentNode}return null},_treeRegionCls:n=>n&&n.extOption&&n.extOption.tree&&n.extOption.tree.regionCls||".darg-region",isTreeMode:n=>!!(n&&n.extOption&&n.extOption.tree&&n.extOption.tree.isTree),findNearestTreeRoot:(n,a)=>{for(var i=n;i;){if(i[Ge]&&i[Ge].options&&ke.isTreeMode(i[Ge].options))return i;i=i.parentNode}return a},getNodeDepth:(n,a)=>{for(var i=0,t=n;t&&(t.matches&&t.matches(a)&&i++,!(t.matches&&t[Ge]&&t[Ge].options));)t=t.parentNode;return i},getOwnerRegion:(n,a)=>{for(var i=n.parentNode;i;){if(i.matches&&i.matches(a))return i;i=i.parentNode}return null},getChildRegion:(n,a)=>{for(var i=n.children||[],t=0;t<i.length;t++)if(i[t].matches&&i[t].matches(a))return i[t];return null},findSiblingFallback:(n,a)=>{var i="data-id",t=h=>!!h&&h.getAttribute&&h.getAttribute(i)!==null,s=n&&n.parentNode;if(s){var l=Array.from(s.children).filter(h=>t(h)&&h!==n&&!n.contains(h));if(l.length){var d=a&&a.getBoundingClientRect?a.getBoundingClientRect():null;if(d)for(var u=d.top+d.height/2,r=0;r<l.length;r++){var c=l[r].getBoundingClientRect();if(u>=c.top&&u<=c.bottom)return l[r]}return l[0]}}for(var m=s,p=0;m&&p++<20;){var f=m.parentNode;if(t(f)&&f!==n&&!n.contains(f))return f;m=f?f.parentNode:null}return null},resolveTreeDrop:(n,a,i,t,s)=>{for(var l=t.extOption.tree||{},d=ke._treeRegionCls(t),u={isReject:!1,reason:"",targetDepth:0,hoverNode:null,intent:"same"},r=t.dataIdAttr||"data-id",c=a;c&&c!==t.el&&!(c.getAttribute&&c.getAttribute(r)!==null);)c=c.parentNode;if(!c||c===t.el)return u.isReject=!0,u.reason="no-node",u;if(c===n||n.contains(c)){var m=ke.findSiblingFallback(n,a);m&&(c=m)}if(u.hoverNode=c,n.contains(c))return u.isReject=!0,u.reason="cycle",u;if(l.isOnlyInnerMove){var p=ke.findNearestTreeRoot(n,null),f=ke.findNearestTreeRoot(c,null);if(p!==f)return u.isReject=!0,u.reason="out-of-group",u}var h=ke.getOwnerRegion(c,d),g=h?ke.getNodeDepth(c,d):1;g<1&&(g=1);var y=Number(l.indentThreshold);(isNaN(y)||y<=0)&&(y=20);var V=window.pageXOffset||document.documentElement.scrollLeft||0,E=c.getBoundingClientRect().left+V,B=E-(g-1)*y,T=1+Math.round((s-B)/y);T<1&&(T=1);var D=Number(l.maxDepth);isNaN(D)&&(D=3);var x=ke._tree.startDragDepth!==null&&ke._tree.startDragDepth!==void 0?ke._tree.startDragDepth:ke.getNodeDepth(n,d),O=T,w=!1;return O>x&&!l.isDragToChild&&(O=x,w=!0),O<x&&!l.isDragToParent&&(O=x,w=!0),D>0&&O>D&&(O=D,O<x&&(O=x)),u.targetDepth=O,u.isDepthForced=w,O>x?u.intent="child":O<x?u.intent="parent":u.intent="same",u.dragDepth=x,u.hoverDepth=g,u},resolveTreeInsert:(n,a,i,t)=>{var s=ke._treeRegionCls(i),l={container:null,refNode:null};if(!a)return l;if(n.intent==="child"){var d=ke.getChildRegion(a,s);return d||(d=ke.createChildRegion(a,i)),l.container=d,l.refNode=ke.findInsertRef(d,t,i),l}for(var u=n.targetDepth!==void 0?n.targetDepth:n.hoverDepth,r=a,c=n.hoverDepth;r&&c>u;){var m=ke.getOwnerRegion(r,s);if(!m||!m.parentNode)break;var p=m.parentNode;if(!p.getAttribute||p.getAttribute(i.dataIdAttr||"data-id")===null)break;r=p,c--}for(;r&&c<u;){var f=ke.getChildRegion(r,s);if(!f)break;if(r=f,c++,c<u){for(var h=null,g=f.children||[],y=0;y<g.length;y++)g[y].getAttribute&&g[y].getAttribute(i.dataIdAttr||"data-id")!==null&&g[y]!==ye&&(h=g[y]);if(!h){c--;break}r=h}}var V;r&&r.matches&&r.matches(s)?V=r:V=ke.getOwnerRegion(r,s);var E=n.isDepthForced===!0;if(E&&c!==u){var B=ke.getOwnerRegion(ye,s);if(B)return l.container=B,l.refNode=ke.findInsertRef(B,t,i),l}return V&&(l.container=V,l.refNode=ke.findInsertRef(V,t,i)),l},findInsertRef:(n,a,i)=>{for(var t=i.dataIdAttr||"data-id",s=[],l=n.children||[],d=0;d<l.length;d++){var u=l[d];u.getAttribute&&u.getAttribute(t)!==null&&u!==ye&&s.push(u)}for(var r=0;r<s.length;r++){var c=s[r].getBoundingClientRect(),m=c.top+c.height/2;if(a<m)return s[r]}return null},createChildRegion:(n,a)=>{var i=ke._treeRegionCls(a),t=ke.getOwnerRegion(n,i),s=t?t.tagName.toLocaleLowerCase():"ul",l=ke.createElement(s),d=i.charAt(0)==="."?i.slice(1):i;return l.className=d+" "+ke.TREE_AUTO_REGION_CLS,n.appendChild(l),l},TREE_AUTO_REGION_CLS:"darg-region-auto",cleanupEmptyAutoRegions:n=>{var a=n||document;if(!(!a||!a.querySelectorAll))for(var i=a.querySelectorAll("."+ke.TREE_AUTO_REGION_CLS),t=i.length-1;t>=0;t--){for(var s=i[t],l=!1,d=s.children||[],u=0;u<d.length;u++)if(d[u].getAttribute&&d[u].getAttribute("data-id")!==null){l=!0;break}l||ye&&(s===ye.parentNode||s.contains(ye))||s.parentNode&&s.parentNode.removeChild(s)}},treeDragOver:(n,a,i)=>{var t=n.options,s=a.clientX,l=a.clientY;if(!ke.isFiniteNumber(s)||!ke.isFiniteNumber(l))if(rt&&ke.isFiniteNumber(rt.clientX)&&ke.isFiniteNumber(rt.clientY))s=rt.clientX,l=rt.clientY;else return!1;var d=a.pageX!==void 0&&ke.isFiniteNumber(a.pageX)?a.pageX:s,u=document.elementFromPoint(s,l),r=u||i;r&&(r===ye||r.closest(".sortable-fallback"))&&(r=i);var c=ke.resolveTreeDrop(ye,r,a,t,d);if(ke._tree.dropInfo=c,c.isReject)return!1;var m=ke.resolveTreeInsert(c,c.hoverNode,t,l);if(!m.container)return!1;if(ye.contains(m.container))return ke._tree.dropInfo={isReject:!0,reason:"cycle-container"},!1;if(m.container===ye.parentNode&&(m.refNode===ye||m.refNode===ye.nextSibling))return!1;var p=m.refNode;return p?m.container.insertBefore(ye,p):m.container.appendChild(ye),ke.cleanupEmptyAutoRegions(n.el||document),!0},renderTreeIndicator:(n,a)=>{var i=n.options,t=ke._tree.dropInfo,s=document.body,l=s.querySelector(".darg-tree-indicator");if(!t||t.isReject||!t.hoverNode){l&&l.parentNode&&l.parentNode.removeChild(l);return}l||(l=ke.createElement("div"),l.className="darg-tree-indicator",s.appendChild(l)),ke._treeRegionCls(i);var d=t.hoverNode.getBoundingClientRect(),u=Number(i.extOption.tree.indentThreshold)||20,r=(t.targetDepth-t.hoverDepth)*u,c=d.left+r,m=d.width-r;m<20&&(m=20);var p=t.intent==="child"?d.bottom-1:d.top;l.style.cssText="position:fixed;pointer-events:none;z-index:100001;height:2px;background:#409eff;left:"+c+"px;top:"+p+"px;width:"+m+"px;border-radius:1px;"},clearTreeIndicator:()=>{var n=document.querySelector(".darg-tree-indicator");n&&n.parentNode&&n.parentNode.removeChild(n),ke._tree.dropInfo=null},resetTreeState:()=>{ke._tree.startPageX=0,ke._tree.startDragDepth=null,ke._tree.startLeftPage=null,ke._tree.depthCache=null,ke._tree.dropInfo=null,ke.clearTreeIndicator(),ke.cleanupEmptyAutoRegions(document)}};Te.mount(new Wr);Te.mount(Qo,Go);const jr=["id"],_i=e.defineComponent({name:"ClDarg",__name:"Index",props:{id:String,className:String,group:[String,Object],dargRegionCls:{type:String,default:".darg-region"},handleCls:{type:String,default:".darg-handle"},selectCls:{type:String,default:"darg-select"},placeholderCls:{type:String,default:"darg-placeholder"},isBoundaryOut:{type:Boolean,default:!0},boundaryElement:String,isWrapBody:{type:Boolean,default:!0},wrapBodyElement:String,isDisabledInner:{type:Boolean,default:!1},isDisabledOutsideInto:{type:Boolean,default:!1},isGroupSameStruct:{type:Boolean,default:!0},keyAttrId:{type:String,default:"data-id"},animation:{type:Number,default:150},groupDropEndBeforeCallback:Function,isTree:{type:Boolean,default:!1},maxDepth:{type:Number,default:3},indentThreshold:{type:Number,default:20},isOnlyInnerMove:{type:Boolean,default:!1},isDragToChild:{type:Boolean,default:!0},isDragToParent:{type:Boolean,default:!0}},emits:{onChangeSort:n=>!0,onError:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElTop"),u={sortableObj:null},r=e.computed(()=>{let h={"panel-darg":!0};return h=o.getJsonMerge(h,de.getClassNameJson(t.className)),h}),c=()=>{const h=d.value;if(!h)return[];const g=t.keyAttrId||"data-id",y=t.dargRegionCls||".darg-region",V=T=>{const D={id:T.getAttribute(g)||"",children:[]};return Array.from(T.children).filter(O=>O.matches&&O.matches(y)).forEach(O=>{Array.from(O.children).forEach(w=>{w.matches&&w.matches("li,[data-id]")&&D.children.push(V(w))})}),D},E=[];return Array.from(h.querySelectorAll(y)).filter(T=>{let D=T.parentElement;for(;D&&D!==h;){if(D.matches&&D.matches(y))return!1;D=D.parentElement}return!0}).forEach(T=>{Array.from(T.children).forEach(D=>{D.matches&&D.matches("li,[data-id]")&&E.push(V(D))})}),E},m=()=>{if(t.isTree){s("onChangeSort",c());return}const h=u.sortableObj?.toArray?.()||[];s("onChangeSort",h)},p=()=>{e.nextTick(()=>{let h=null;try{if(h=d.value?.querySelector(t.dargRegionCls||".darg-region"),!h){Se.warn("ClDarg","未找到拖拽区域元素:",t.dargRegionCls||".darg-region"),s("onError","未找到拖拽区域元素");return}const{group:g,placeholderCls:y,handleCls:V,selectCls:E,isBoundaryOut:B,boundaryElement:T,isWrapBody:D,wrapBodyElement:x,isDisabledInner:O,isDisabledOutsideInto:w,isGroupSameStruct:M,groupDropEndBeforeCallback:b,keyAttrId:N,isTree:J,maxDepth:q,indentThreshold:z,isOnlyInnerMove:H,isDragToChild:v,isDragToParent:S}=t;let C=M;J&&!M&&(C=!0,Se.warn("ClDarg","树形拖拽仅支持同结构,isGroupSameStruct 已被强制为 true(原值 false 被忽略)"),s("onError","树形拖拽仅支持同结构,isGroupSameStruct 已被强制为 true"));const $={sort:!O,forceFallback:!0,fallbackOnBody:D,fallbackTolerance:0,handle:V,ghostClass:y,chosenClass:E,dragClass:"darg-moveing",animation:t.animation,dataIdAttr:N,extOption:{boundary:{isOut:B,element:T,x:5,y:20},wrapBody:{isWrap:D,element:x},cross:{isCross:!1,isSameStruct:C,dropEndBeforeCallback:b||null},tree:{isTree:J,maxDepth:q,indentThreshold:z,isOnlyInnerMove:H,isDragToChild:v,isDragToParent:S,rootId:l||""}},onUpdate:()=>{m()}};if(g&&!o.isEmpty(g))if($.extOption.cross.isCross=!0,w){const k=o.isObject(g)?g.name:g;$.group={name:k,pull:"clone",put:!1},$.animation=0}else $.group=g;u.sortableObj=new Te(h,$)}catch(g){Se.warn("ClDarg","Sortable 初始化失败:",g),s("onError","拖拽组件初始化失败")}})};return e.onMounted(()=>{p()}),e.onUpdated(()=>{if(!u.sortableObj)return;const h=d.value?.querySelector(t.dargRegionCls||".darg-region");if(h&&u.sortableObj.el!==h){try{u.sortableObj.destroy()}catch(g){Se.warn("ClDarg","重建前销毁旧实例失败:",g)}u.sortableObj=null,p()}}),e.onBeforeUnmount(()=>{if(u.sortableObj){try{u.sortableObj.destroy()}catch(h){Se.warn("ClDarg","销毁拖拽实例失败:",h)}u.sortableObj=null}}),a({getArrSort:()=>t.isTree?c():u.sortableObj?.toArray?u.sortableObj.toArray():[]}),(h,g)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"refElTop",ref:d,id:e.unref(l),class:e.normalizeClass(r.value)},[e.renderSlot(h.$slots,"default")],10,jr))}}),Yr=["id"],qr={key:0,class:"divider-text"},Mi=e.defineComponent({name:"ClDivider",__name:"Index",props:{id:String,className:String,dashed:Boolean,hairline:{type:Boolean,default:!0},contentPosition:{type:String,default:"center",validator:n=>["center","left","right"].indexOf(n)!==-1},margin:{type:[Number,String],default:16},theme:{type:String,default:"default"},lineColor:String,textColor:String},emits:["onClick"],setup(n,{emit:a}){const i=n,t=a,s=i.id,l=e.useSlots(),d=e.computed(()=>{const m=l.default?.();return Array.isArray(m)&&m.length>0}),u=e.computed(()=>{const m={"panel-divider":!0,"panel-divider--dashed":i.dashed,"panel-divider--hairline":i.hairline,"panel-divider--left":i.contentPosition==="left","panel-divider--right":i.contentPosition==="right","panel-divider--text":d.value,"panel-divider--gold":i.theme==="gold"};return o.getJsonMerge(m,de.getClassNameJson(i.className))}),r=e.computed(()=>{const m=i.margin,p=o.isFinite(m)?`${m}px`:String(m??""),f={marginLeft:p,marginRight:p};return o.isNonEmptyString(i.lineColor)&&(f["--divider-line-color"]=i.lineColor),o.isNonEmptyString(i.textColor)&&(f["--divider-text-color"]=i.textColor),f}),c=()=>{t("onClick")};return(m,p)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(s),class:e.normalizeClass(u.value),style:e.normalizeStyle(r.value),onClick:c},[d.value?(e.openBlock(),e.createElementBlock("span",qr,[e.renderSlot(m.$slots,"default")])):e.createCommentVNode("",!0)],14,Yr))}}),Xr=["id"],Gr=["title"],Zo=e.defineComponent({name:"ClEllipsis",directives:{cltooltip:ct},__name:"Index",props:{id:String,className:String,text:String,lines:{type:Number,default:1},isUseTooltipAuto:{type:Boolean,default:!1},tooltipTheme:String,tooltipPosition:String,tooltipTrigger:String,tooltipIsHtml:{type:Boolean,default:!1},tooltipHtml:String,isShowNativeTitle:{type:Boolean,default:!1}},setup(n){const a=n,i=a.id,t=e.useTemplateRef("refElParent"),s=e.useTemplateRef("refElSpan"),l=e.reactive({isPosParent:!1,isPosSpan:!1,isUseTooltip:!1,isUseTooltipAuto:a.isUseTooltipAuto}),d=e.computed(()=>l.isUseTooltip?"":a.isShowNativeTitle&&a.text||""),u=e.computed(()=>{if(!o.isFinite(a.lines))return 1;const p=Number(a.lines);return p===1||p===2||p===3?p:1}),r=e.computed(()=>{let p={"panel-ellipsis":!0,"ellipsis-txt-title":!0};return p[`ellipsis-txt-lines-${u.value}`]=!0,a.tooltipTrigger==="click"&&(p["ellipsis-txt-click"]=!0),p=o.getJsonMerge(p,de.getClassNameJson(a.className)),p}),c=()=>{const p=Nt("ellipsis");p&&o.isExistJsonKey(p,"isUseTooltipAuto")&&(l.isUseTooltipAuto=p.isUseTooltipAuto)},m=()=>{if(l.isUseTooltipAuto&&a.text&&a.text.length>0&&t.value&&s.value)if(u.value>1){const p=s.value,f=p.clientHeight;p.style.webkitLineClamp="unset";const h=p.offsetHeight;p.style.webkitLineClamp="";const g=h>f;l.isUseTooltip=g,l.isPosSpan=!0,l.isPosParent=!1}else{const p=t.value.clientWidth,f=s.value.offsetWidth;if(p>0&&f>0){const h=p>=f,g=p<f;l.isUseTooltip=g,l.isPosSpan=h,l.isPosParent=g}}};return e.onMounted(()=>{e.nextTick(()=>{c(),m()})}),e.watch(()=>a.text,()=>{e.nextTick(()=>{m()})}),e.watch(()=>a.isUseTooltipAuto,p=>{l.isUseTooltipAuto=p,p||(l.isUseTooltip=!1),e.nextTick(()=>{m()})}),e.watch(()=>a.lines,()=>{e.nextTick(()=>{m()})}),(p,f)=>{const h=e.resolveDirective("cltooltip");return e.withDirectives((e.openBlock(),e.createElementBlock("div",{ref_key:"refElParent",ref:t,id:e.unref(i),class:e.normalizeClass(r.value)},[e.withDirectives((e.openBlock(),e.createElementBlock("span",{ref_key:"refElSpan",ref:s,class:e.normalizeClass(`ellipsis-txt-lines-${u.value}`),title:d.value},[e.createTextVNode(e.toDisplayString(n.text),1)],10,Gr)),[[h,{init:l.isUseTooltip&&l.isPosSpan,html:n.tooltipHtml||n.text,theme:n.tooltipTheme,position:n.tooltipPosition,trigger:n.tooltipTrigger,isHtml:n.tooltipIsHtml}]])],10,Xr)),[[h,{init:l.isUseTooltip&&l.isPosParent,html:n.tooltipHtml||n.text,theme:n.tooltipTheme,position:n.tooltipPosition,trigger:n.tooltipTrigger,isHtml:n.tooltipIsHtml}]])}}}),Qr=["id"],Zr={key:0,class:"empty-description"},ec={key:1,class:"empty-footer"},tc=80,Oi=e.defineComponent({name:"ClEmpty",__name:"Index",props:{id:String,className:String,description:String,imageSize:{type:Number,default:80}},setup(n){const a=n,i=a.id,t=e.useSlots(),s=e.computed(()=>o.isNonEmptyString(a.description)?a.description:""),l=e.computed(()=>{const r=t.default?.();return Array.isArray(r)&&r.length>0}),d=e.computed(()=>{const r={"panel-empty":!0};return o.getJsonMerge(r,de.getClassNameJson(a.className))}),u=e.computed(()=>{const r=o.isFinite(a.imageSize)&&a.imageSize>0?a.imageSize:tc;return{width:`${r}px`,height:`${r}px`}});return(r,c)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(i),class:e.normalizeClass(d.value)},[e.createElementVNode("div",{class:"empty-image",style:e.normalizeStyle(u.value)},[e.renderSlot(r.$slots,"image",{},()=>[c[0]||(c[0]=e.createElementVNode("i",{class:"empty-image-default clIconFont clIcon-empty"},null,-1))])],4),s.value?(e.openBlock(),e.createElementBlock("div",Zr,e.toDisplayString(s.value),1)):e.createCommentVNode("",!0),l.value?(e.openBlock(),e.createElementBlock("div",ec,[e.renderSlot(r.$slots,"default")])):e.createCommentVNode("",!0)],10,Qr))}});class Ai{_fun;_time;_cb;constructor(a,i=200){this._cb=a,this._time=i}stopRun(){this._fun&&(clearTimeout(this._fun),this._fun=null)}run(a){const i=a||this._cb;i&&(this.stopRun(),this._fun=setTimeout(()=>{i()},this._time))}}class nc{startTime;startPos;endPos;duration;runEasing;runIngFun;lastPos;lastInterval;timeAnimate;constructor(a){this.startTime=0,this.startPos=0,this.endPos=0,this.duration=0,this.runEasing=null,this.runIngFun=a.runIngCallback,this.lastPos=0,this.lastInterval=0}_easing={linear:(a,i,t,s)=>t*a/s+i,easeInCubic:(a,i,t,s)=>t*(a/=s)*a*a+i,easeOutCubic:(a,i,t,s)=>t*((a=a/s-1)*a*a+1)+i};start(a,i,t,s="linear"){const l=this;return new Promise(d=>{this.startTime=+new Date,this.startPos=a,this.endPos=i,this.duration=t,this.runEasing=l._easing[s],l.timeAnimate=o.requestAnimationFrame(function u(){l.step()===!1?(l.stop(),d(l.lastInterval)):l.timeAnimate=o.requestAnimationFrame(u)})})}step(){const a=+new Date;if(a>=this.startTime+this.duration)return this.runIngFun(this.endPos),!1;const i=this.runEasing(a-this.startTime,this.startPos,this.endPos-this.startPos,this.duration);return this.lastInterval=Math.abs(i-this.lastPos),this.lastPos=i,this.runIngFun(i),!0}stop(){this.timeAnimate&&o.cancelAnimationFrame(this.timeAnimate)}}const oc=["id"],ea=e.defineComponent({name:"ClForm",__name:"Index",props:{id:String,theme:String,className:String,isAwaitRun:{type:Boolean,default:!0},preScroll:Number,pElError:String,isScrollToErr:{type:Boolean,default:!0}},emits:["submit"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElTop"),u=e.reactive({isRun:!t.isAwaitRun}),r={_scrollUpAnimate:null,parentScroll:null,isScrollWindow:!0,tabindexEls:new Set},c=e.computed(()=>{const B={"data-cl-validate":""};return u.isRun&&(B["data-run"]=""),o.isNonEmptyString(t.theme)&&(B["data-theme"]=t.theme),B}),m=e.computed(()=>{let B={"panel-form":!0,"form-validate":!0};return B=o.getJsonMerge(B,de.getClassNameJson(t.className)),B}),p=()=>{s("submit")},f=B=>{const T=B.querySelector('input:not([type="hidden"]), select, textarea');return T instanceof HTMLElement?T:B},h=B=>{let T=!0;u.isRun&&B instanceof HTMLElement&&d.value?.contains(B)&&B.runValidate&&(T=!!B.runValidate());const D=f(B);return T?D.removeAttribute("aria-invalid"):D.setAttribute("aria-invalid","true"),T},g=()=>{const B=d.value?.querySelectorAll("[data-validate-error]");if(!o.isUndefined(B)&&B.length>0){let T=B[0];const{preScroll:D,pElError:x}=t,O=!o.isEmpty(T.pElError),w=!o.isEmpty(x);if(O||w){const q=de.getParent(T,O?T.pElError:x,d.value);o.isUndefined(q)||(T=q)}const b=de.getOffset(T,r.isScrollWindow?null:r.parentScroll).top-10-(D??0),N=r._scrollUpAnimate,J=r.parentScroll;N&&J&&(N.stop(),N.start(J.scrollTop,b,200)),T.tabIndex<0&&(T.setAttribute("tabindex","-1"),r.tabindexEls.add(T)),T.focus({preventScroll:!0})}},y=()=>{const B=de.getParentScrollList(d.value,null,!1);r.isScrollWindow=B.length===0;const T=r.isScrollWindow?document.documentElement:B[0];r.parentScroll=o.isUndefined(T)?document.documentElement:T,r._scrollUpAnimate=new nc({runIngCallback:D=>{const x=r.parentScroll;x&&(x.scrollTop=D)}})};return e.onMounted(()=>{e.nextTick(()=>{y()})}),e.onBeforeUnmount(()=>{r._scrollUpAnimate?.stop()}),a({validate:B=>ri.promiseFun(T=>{let D=!0;try{if(o.isUndefined(B))u.isRun=!0,e.nextTick(()=>{u.isRun=!0;try{const x=d.value?.querySelectorAll("[data-validate-el]");!o.isUndefined(x)&&x.length>0&&x.forEach(O=>{h(O)||(D=!1)}),D||t.isScrollToErr&&e.nextTick(()=>{try{g()}catch{}}),T(D)}catch{T(!1)}});else{u.isRun=!0;const x=B;e.nextTick(()=>{try{D=h(x),!D&&t.isScrollToErr&&e.nextTick(()=>{try{g()}catch{}}),T(D)}catch{T(!1)}})}}catch{T(!1)}}),reset:()=>{u.isRun=!1,r._scrollUpAnimate?.stop(),d.value?.removeAttribute("data-run");const B=d.value?.querySelectorAll("[data-validate-el]");!o.isUndefined(B)&&B.length>0&&B.forEach(T=>{if(f(T).removeAttribute("aria-invalid"),T.runReset)try{T.runReset()}catch{}}),r.tabindexEls.forEach(T=>{T.removeAttribute("tabindex")}),r.tabindexEls.clear()}}),(B,T)=>(e.openBlock(),e.createElementBlock("form",e.mergeProps({ref_key:"refElTop",ref:d,autocomplete:"off",novalidate:"",onSubmit:e.withModifiers(p,["prevent"]),id:e.unref(l),class:m.value},c.value),[e.renderSlot(B.$slots,"default")],16,oc))}}),ac=["id","aria-labelledby"],ic={key:0,class:"tip-must"},sc=["id"],jn=e.defineComponent({name:"ClFormGroupHorizontal",__name:"Index",props:{id:String,className:{type:String,default:""},colRatio:{type:String,default:"2:10"},label:String,isTipMust:{type:Boolean,default:!1},isPlaintext:{type:Boolean,default:!1}},setup(n){const a=n,i=a.id,t=e.computed(()=>{let r={"panel-form-group-horizontal":!0,"form-group":!0,"form-group-plaintext":a.isPlaintext,row:!0};return r=o.getJsonMerge(r,de.getClassNameJson(a.className)),r}),s=e.computed(()=>a.colRatio.split(":")),l=e.computed(()=>{const r=s.value,c=u(r[0],2),m={"control-label":!0};return m[`col-sm-${c}`]=!0,m[`col-${c}`]=!0,m}),d=e.computed(()=>{const r=s.value,c=u(r[1],10),m={"form-group-content":!0};return m[`col-sm-${c}`]=!0,m[`col-${c}`]=!0,m}),u=(r,c)=>{if(!o.isNonEmptyString(r))return c;const m=parseInt(r,10);return isNaN(m)||m<1||m>12?c:m};return e.watch(s,([r,c])=>{if(!o.isNonEmptyString(r)||!o.isNonEmptyString(c))return;const m=parseInt(r,10),p=parseInt(c,10);if(isNaN(m)||isNaN(p)||m<1||m>12||p<1||p>12){Se.warn("ClFormGroupHorizontal",`colRatio 值 "${r}:${c}" 不在 1-12 有效范围内,已使用默认值 2:10`);return}m+p!==12&&Se.warn("ClFormGroupHorizontal",`colRatio 两值之和需为 12(当前 ${m}+${p}=${m+p}),布局可能出现异常`)},{immediate:!0}),(r,c)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(i),class:e.normalizeClass(t.value),role:"group","aria-labelledby":`${e.unref(i)}-label`},[e.createElementVNode("div",{class:e.normalizeClass(l.value)},[e.createElementVNode("span",null,[n.isTipMust?(e.openBlock(),e.createElementBlock("span",ic,"*")):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("span",{class:"control-label-text",id:`${e.unref(i)}-label`},e.toDisplayString(n.label),9,sc),e.renderSlot(r.$slots,"labelExtend")])],2),e.createElementVNode("div",{class:e.normalizeClass(d.value)},[e.renderSlot(r.$slots,"default")],2)],10,ac))}}),lc={key:0,class:"form-group-btns-fixed"},rc=["id"],cc=["id"],Li=e.defineComponent({name:"ClFormGroupBtns",__name:"Index",props:{id:String,className:{type:String,default:""},isFixed:{type:Boolean,default:!1},isHorizontal:{type:Boolean,default:!1},colRatioHorizontal:String},setup(n){const a=n,i=a.id,t=e.computed(()=>{const s={"form-group-btns":!0};return o.getStringByJson(o.getJsonMerge(s,de.getClassNameJson(a.className))," ")});return(s,l)=>n.isHorizontal?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.isFixed?(e.openBlock(),e.createElementBlock("div",lc,[e.createElementVNode("div",null,[e.createVNode(jn,{id:e.unref(i),className:t.value,colRatio:n.colRatioHorizontal},{default:e.withCtx(()=>[e.renderSlot(s.$slots,"default")]),_:3},8,["id","className","colRatio"])])])):(e.openBlock(),e.createBlock(jn,{key:1,id:e.unref(i),className:t.value,colRatio:n.colRatioHorizontal},{default:e.withCtx(()=>[e.renderSlot(s.$slots,"default")]),_:3},8,["id","className","colRatio"]))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n.isFixed?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(i),class:"form-group-btns-fixed"},[e.createElementVNode("div",{class:e.normalizeClass(t.value)},[e.renderSlot(s.$slots,"default")],2)],8,rc)):(e.openBlock(),e.createElementBlock("div",{key:1,id:e.unref(i),class:e.normalizeClass(t.value)},[e.renderSlot(s.$slots,"default")],10,cc))],64))}}),uc=["id","aria-labelledby"],dc={class:"form-group-title"},mc={key:0,class:"tip-must"},pc=["id"],fc={class:"form-group-content"},$i=e.defineComponent({name:"ClFormGroupVertical",__name:"Index",props:{id:String,className:{type:String,default:""},label:String,isTipMust:{type:Boolean,default:!1},isPlaintext:{type:Boolean,default:!1}},setup(n){const a=n,i=a.id,t=e.computed(()=>{const s={"form-group":!0,"form-group-vertical":!0,"form-group-plaintext":a.isPlaintext};return o.getJsonMerge(s,de.getClassNameJson(a.className))});return(s,l)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(i),class:e.normalizeClass(t.value),role:"group","aria-labelledby":`${e.unref(i)}-label`},[e.createElementVNode("div",dc,[n.isTipMust?(e.openBlock(),e.createElementBlock("span",mc,"*")):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("span",{class:"form-group-title-label",id:`${e.unref(i)}-label`},e.toDisplayString(n.label)+":",9,pc),e.renderSlot(s.$slots,"labelExtend")]),e.createElementVNode("div",fc,[e.renderSlot(s.$slots,"default")])],10,uc))}}),hc={required:n=>!o.isEmpty(n),number:n=>{let a=!0;if(!o.isEmpty(n)){const i=o.removeReplace(n);a=/^-?(\d*\.)?\d+(e[-+]?\d+)?$/i.test(i)}return a},integer:n=>{let a=!0;if(!o.isEmpty(n)){const i=o.removeReplace(n);a=/^-?\d+$/.test(i)}return a},integerPositive:n=>{let a=!0;if(!o.isEmpty(n)){const i=o.removeReplace(n);a=/^[1-9]\d*$/.test(i)}return a},alphanum:n=>{let a=!0;return o.isEmpty(n)||(a=/^\w+$/i.test(n)),a},email:n=>{let a=!0;return o.isEmpty(n)||(a=/^((([a-z]|\d|[!#\$%&"\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&"\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i.test(n)),a},minLen:(n,a)=>{let i=!0;return o.isEmpty(n)||(i=n.length>=parseInt(a,10)),i},maxLen:(n,a)=>{let i=!0;return o.isEmpty(n)||(i=n.length<=parseInt(a,10)),i},minByte:(n,a)=>{let i=!0;return o.isEmpty(n)||(i=o.getByteLen(n)>=parseInt(a,10)),i},maxByte:(n,a)=>{let i=!0;return o.isEmpty(n)||(i=o.getByteLen(n)<=parseInt(a,10)),i},minGreater:(n,a)=>{let i=!0;if(!o.isEmpty(n)){const t=o.removeReplace(n);i=parseFloat(t)>parseFloat(a)}return i},maxGreater:(n,a)=>{let i=!0;if(!o.isEmpty(n)){const t=o.removeReplace(n);i=parseFloat(t)<parseFloat(a)}return i},minGreaterEqual:(n,a)=>{let i=!0;if(!o.isEmpty(n)){const t=o.removeReplace(n);i=parseFloat(t)>=parseFloat(a)}return i},maxGreaterEqual:(n,a)=>{let i=!0;if(!o.isEmpty(n)){const t=o.removeReplace(n);i=parseFloat(t)<=parseFloat(a)}return i},phone:n=>{let a=!0;return o.isEmpty(n)||(a=/^1\d{10}$/.test(n)),a},equalto:(n,a)=>!o.isEmpty(n)&&!o.isEmpty(a)?n===a:!0,regular:(n,a)=>{let i=!0;return!o.isEmpty(n)&&!o.isEmpty(a)&&(i=new RegExp(a,"g").test(n)),i},urlHttp:n=>{let a=!0;return o.isEmpty(n)||(a=/^(http|https):\/\/[^\s]+$/.test(n)),a}},Fi=(n={})=>({type:o.isEmpty(n.type)?"tip":n.type,rules:o.getJsonMerge(hc,n.rules),messages:o.getJsonMergeDeep({},n.messages)}),gc={key:1,class:"error-text-el"},Gn=e.defineComponent({name:"ClFormValidate",directives:{cltooltip:ct},__name:"Validate",props:{className:String,checkValue:[String,Number],rules:{type:Array,default:()=>[]},isCheck:{type:Boolean,default:!0},msgElementId:String,msgType:{type:String,validator:n=>["tip","text"].includes(n)},pElError:String,isShowMsg:{type:Boolean,default:!0}},setup(n,{expose:a}){const i=n,{optPageLanguage:t,getPageLanguage:s,getLanguageType:l}=Le();s("validate");const d=e.inject("$ClGlobals",null),u=e.useTemplateRef("refElTop"),r=e.useTemplateRef("refElMsg"),c=e.reactive({type:"",msgHtml:"",check:0}),m={form:null},p={rules:{},messages:{}};let f=null;const h=()=>{if(o.isUndefined(f)){const $=Fi(),k=d?.validate;k?o.isEmpty(k.rules)&&o.isEmpty(k.messages)?(f=o.isNonEmptyString(k.type)?{...$,type:k.type}:$,Se.warn("ClFormValidate","[cl-form-validate] 全局校验规则表($ClGlobals.validate)缺少 rules/messages,已回退内置默认规则")):f={...$,...k,type:k.type??$.type,rules:k.rules??$.rules,messages:k.messages??$.messages}:(f=$,Se.warn("ClFormValidate","[cl-form-validate] 未检测到全局校验规则表($ClGlobals.validate),已回退内置默认规则"))}return f},g=e.computed(()=>{const $={"data-validate-el":""};if(i.isCheck){switch(c.check){case 1:$["data-validate-success"]="";break;case 2:$["data-validate-error"]="";break}$["aria-invalid"]=c.check===2?"true":"false"}return $}),y=e.computed(()=>{const $={};return i.isCheck&&($["panel-form-validate"]=!0),o.getJsonMerge($,de.getClassNameJson(i.className))}),V=e.computed(()=>{const $={"panel-validate-errors":!0};return $[`validate-errors-${c.type}`]=!0,$}),E=e.computed(()=>c.msgHtml.replace(/<[^>]*>/g," ").trim()),B=$=>{if(!o.isArray($)){Se.warn("ClFormValidate","[cl-form-validate] rules 应为数组,已忽略");return}const k={},I={};$.forEach(L=>{if(typeof L=="string"){if(!o.isEmpty(L))if(o.isExistValue(L,"|")){const _=L.split("|");k[_[0]]=_[1],_.length>2&&Se.warn("ClFormValidate",'[cl-form-validate] 字符串规则 "'+L+'" 含多个参数段,仅取前两段,建议改用对象形式')}else k[L]=""}else if(typeof L=="object"&&!o.isUndefined(L)){let _=!0;o.isBoolean(L.isCheck)?_=L.isCheck===!0:(L.isCheck==="false"||L.isCheck==="0")&&(_=!1),!o.isEmpty(L.r)&&_&&(k[L.r]=String(L.p??""),o.isEmpty(L.m)||(I[L.r]=L.m??""))}}),p.rules=k,p.messages=I},T=()=>{const $=[],k={},I={};if(u.value&&!o.isEmpty(u.value.dataset)&&Object.keys(u.value.dataset).forEach(L=>{if(L.indexOf("validate")===0){const R=L.replace(/[A-Z]/g,P=>`-${P.toLowerCase()}`).split("-");if(R.length===3){const P=R[2].toLowerCase(),Q=u.value.dataset[L];switch(R[1]){case"check":!o.isEmpty(Q)&&Q.toLowerCase()==="false"&&$.push(P);break;case"param":k[P]=Q;break;case"message":I[P]=Q;break}}}}),!o.isEmpty(p.rules)&&(!o.isEmpty($)||!o.isEmpty(k))){const L={};for(const[_,R]of Object.entries(p.rules)){const P=_.toLowerCase();o.isExistValue($,P)||(L[_]=o.isExistJsonKey(k,P)?k[P]:R)}p.rules=L}if(!o.isEmpty(p.messages)&&!o.isEmpty(I)){const L={};for(const[_,R]of Object.entries(p.messages)){const P=_.toLowerCase();L[_]=o.isExistJsonKey(I,P)?I[P]:R}p.messages=L}},D=$=>{const k={},I=h().rules??{};if(!o.isEmpty(p.rules)){const L=o.isEmpty($)||o.getTypeof($)==="number"&&o.isNaN($),_=L?"":o.trim($);for(const[R,P]of Object.entries(p.rules))if(o.isExistJsonKey(I,R)&&o.isFunction(I[R])){let Q=!0;R==="required"?Q=I.required(_):L||(Q=I[R](_,P)),Q||(k[R]=P)}else Se.warn("ClFormValidate",'[cl-form-validate] 校验规则 "'+R+'" 未注册或非函数,已跳过')}return k},x=()=>{s("validate");const $=e.toRaw(t.value),k=e.toRaw(h().messages??{}),I=l(),L=o.isExistJsonKey(k,I.type)||o.isExistJsonKey(k,I.def)?o.getJsonMerge({},k[I.def]||{},k[I.type]||{}):k;return o.getJsonMerge({},$,L)},O=$=>{const k=x(),I=[];return Object.keys($).forEach(L=>{let _="";if(o.isNonEmptyString(p.messages[L])?_=p.messages[L]:o.isNonEmptyString(k[L])&&(_=k[L]),!o.isEmpty(_)){const R=$[L],P=o.isExistValue(_,"%s")?_.replace(/%s/g,o.isEmpty(R)?"":String(R)):_;I.push(P)}}),I},w=()=>(m.form&&!m.form.isConnected&&(m.form=null),o.isUndefined(m.form)&&u.value&&(m.form=de.getParent(u.value,"form")),m.form),M=()=>{w();let $=h().type;m.form&&!o.isEmpty(m.form.dataset.theme)&&($=m.form.dataset.theme),o.isNonEmptyString(i.msgType)&&($=i.msgType),$!=="tip"&&$!=="text"&&($="tip"),c.type=$},b=()=>{let $=!0;return w(),!o.isUndefined(m.form)&&m.form&&(o.isUndefined(m.form.dataset.clValidate)||($=!o.isUndefined(m.form.dataset.run))),$},N=$=>{const k=o.isNonEmptyString($)?$:"";if(o.isEmpty(k))c.msgHtml="",c.check=1;else if(c.msgHtml=k,c.check=2,o.isNonEmptyString(i.msgElementId))try{const I=window.document.querySelector(i.msgElementId);I?e.nextTick(()=>{r.value&&I.isConnected?I.appendChild(r.value):r.value&&Se.warn("ClFormValidate","[cl-form-validate] msgElementId 目标已脱离文档:"+i.msgElementId+",消息展示在组件内部")}):Se.warn("ClFormValidate","[cl-form-validate] 未找到 msgElementId 目标元素:"+i.msgElementId+",消息展示在组件内部")}catch{Se.warn("ClFormValidate","[cl-form-validate] msgElementId 选择器无效:"+i.msgElementId)}},J=()=>{c.msgHtml="",c.check=0},q=($,k)=>{let I="";if(!o.isEmpty($))switch(k){case"tip":I=$.map(L=>`<div>${L}</div>`).join("");break;case"text":I=$.join(",");break}return I},z=()=>{let $=!0;try{if(i.isCheck&&b()){M(),T();const k=D(i.checkValue);if($=o.isEmpty(k),$)N("");else{let I=q(O(k),c.type);if(o.isEmpty(I)){const L=Object.keys(k)[0];I=o.isNonEmptyString(L)?L:"校验未通过"}N(I)}}else J()}catch{Se.warn("ClFormValidate","[cl-form-validate] 校验执行异常,已按未通过处理"),J(),$=!1}return $},H=()=>{if(B(i.rules||[]),w(),u.value){const $=u.value;$.pElError=i.pElError,$.runValidate=z,$.runErrMsg=S,$.runReset=C}};e.onMounted(()=>{e.nextTick(()=>{H()})}),e.onBeforeUnmount(()=>{r.value?.remove()}),e.watch(()=>i.checkValue,()=>{z()}),e.watch([()=>i.rules,()=>i.isCheck],([$])=>{B($||[]),z()},{deep:!0});const v=()=>z(),S=$=>{M(),N($)},C=()=>{M(),J()};return a({runValidate:v,runErrMsg:S,runReset:C}),($,k)=>{const I=e.resolveDirective("cltooltip");return e.openBlock(),e.createElementBlock("div",e.mergeProps({ref_key:"refElTop",ref:u,class:y.value},g.value),[e.renderSlot($.$slots,"default"),c.msgHtml.length>0&&n.isShowMsg?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"refElMsg",ref:r,class:e.normalizeClass(V.value),role:"alert"},[c.type==="tip"?e.withDirectives((e.openBlock(),e.createBlock(ve,{key:0,name:"exclamation-circle-fill",class:"error-tip-el",role:"img","aria-label":E.value},null,8,["aria-label"])),[[I,c.msgHtml]]):c.type==="text"?(e.openBlock(),e.createElementBlock("span",gc,e.toDisplayString(c.msgHtml),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],16)}}}),Ze={loading:"data:image/gif;base64,R0lGODlhEAAQAPQAAP///wAAAPDw8IqKiuDg4EZGRnp6egAAAFhYWCQkJKysrL6+vhQUFJycnAQEBDY2NmhoaAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAACH/C05FVFNDQVBFMi4wAwEAAAAh/hpDcmVhdGVkIHdpdGggYWpheGxvYWQuaW5mbwAh+QQJCgAAACwAAAAAEAAQAAAFdyAgAgIJIeWoAkRCCMdBkKtIHIngyMKsErPBYbADpkSCwhDmQCBethRB6Vj4kFCkQPG4IlWDgrNRIwnO4UKBXDufzQvDMaoSDBgFb886MiQadgNABAokfCwzBA8LCg0Egl8jAggGAA1kBIA1BAYzlyILczULC2UhACH5BAkKAAAALAAAAAAQABAAAAV2ICACAmlAZTmOREEIyUEQjLKKxPHADhEvqxlgcGgkGI1DYSVAIAWMx+lwSKkICJ0QsHi9RgKBwnVTiRQQgwF4I4UFDQQEwi6/3YSGWRRmjhEETAJfIgMFCnAKM0KDV4EEEAQLiF18TAYNXDaSe3x6mjidN1s3IQAh+QQJCgAAACwAAAAAEAAQAAAFeCAgAgLZDGU5jgRECEUiCI+yioSDwDJyLKsXoHFQxBSHAoAAFBhqtMJg8DgQBgfrEsJAEAg4YhZIEiwgKtHiMBgtpg3wbUZXGO7kOb1MUKRFMysCChAoggJCIg0GC2aNe4gqQldfL4l/Ag1AXySJgn5LcoE3QXI3IQAh+QQJCgAAACwAAAAAEAAQAAAFdiAgAgLZNGU5joQhCEjxIssqEo8bC9BRjy9Ag7GILQ4QEoE0gBAEBcOpcBA0DoxSK/e8LRIHn+i1cK0IyKdg0VAoljYIg+GgnRrwVS/8IAkICyosBIQpBAMoKy9dImxPhS+GKkFrkX+TigtLlIyKXUF+NjagNiEAIfkECQoAAAAsAAAAABAAEAAABWwgIAICaRhlOY4EIgjH8R7LKhKHGwsMvb4AAy3WODBIBBKCsYA9TjuhDNDKEVSERezQEL0WrhXucRUQGuik7bFlngzqVW9LMl9XWvLdjFaJtDFqZ1cEZUB0dUgvL3dgP4WJZn4jkomWNpSTIyEAIfkECQoAAAAsAAAAABAAEAAABX4gIAICuSxlOY6CIgiD8RrEKgqGOwxwUrMlAoSwIzAGpJpgoSDAGifDY5kopBYDlEpAQBwevxfBtRIUGi8xwWkDNBCIwmC9Vq0aiQQDQuK+VgQPDXV9hCJjBwcFYU5pLwwHXQcMKSmNLQcIAExlbH8JBwttaX0ABAcNbWVbKyEAIfkECQoAAAAsAAAAABAAEAAABXkgIAICSRBlOY7CIghN8zbEKsKoIjdFzZaEgUBHKChMJtRwcWpAWoWnifm6ESAMhO8lQK0EEAV3rFopIBCEcGwDKAqPh4HUrY4ICHH1dSoTFgcHUiZjBhAJB2AHDykpKAwHAwdzf19KkASIPl9cDgcnDkdtNwiMJCshACH5BAkKAAAALAAAAAAQABAAAAV3ICACAkkQZTmOAiosiyAoxCq+KPxCNVsSMRgBsiClWrLTSWFoIQZHl6pleBh6suxKMIhlvzbAwkBWfFWrBQTxNLq2RG2yhSUkDs2b63AYDAoJXAcFRwADeAkJDX0AQCsEfAQMDAIPBz0rCgcxky0JRWE1AmwpKyEAIfkECQoAAAAsAAAAABAAEAAABXkgIAICKZzkqJ4nQZxLqZKv4NqNLKK2/Q4Ek4lFXChsg5ypJjs1II3gEDUSRInEGYAw6B6zM4JhrDAtEosVkLUtHA7RHaHAGJQEjsODcEg0FBAFVgkQJQ1pAwcDDw8KcFtSInwJAowCCA6RIwqZAgkPNgVpWndjdyohACH5BAkKAAAALAAAAAAQABAAAAV5ICACAimc5KieLEuUKvm2xAKLqDCfC2GaO9eL0LABWTiBYmA06W6kHgvCqEJiAIJiu3gcvgUsscHUERm+kaCxyxa+zRPk0SgJEgfIvbAdIAQLCAYlCj4DBw0IBQsMCjIqBAcPAooCBg9pKgsJLwUFOhCZKyQDA3YqIQAh+QQJCgAAACwAAAAAEAAQAAAFdSAgAgIpnOSonmxbqiThCrJKEHFbo8JxDDOZYFFb+A41E4H4OhkOipXwBElYITDAckFEOBgMQ3arkMkUBdxIUGZpEb7kaQBRlASPg0FQQHAbEEMGDSVEAA1QBhAED1E0NgwFAooCDWljaQIQCE5qMHcNhCkjIQAh+QQJCgAAACwAAAAAEAAQAAAFeSAgAgIpnOSoLgxxvqgKLEcCC65KEAByKK8cSpA4DAiHQ/DkKhGKh4ZCtCyZGo6F6iYYPAqFgYy02xkSaLEMV34tELyRYNEsCQyHlvWkGCzsPgMCEAY7Cg04Uk48LAsDhRA8MVQPEF0GAgqYYwSRlycNcWskCkApIyEAOwAAAAAAAAAAAA==",error:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAYAAABXAvmHAAAAAXNSR0IArs4c6QAABbFJREFUaEPtWV1sFFUUPufOLmjpD7G0nXtm11igD0Q0CpqImsiDEcGoIVEReeBBNGgkEQSjwUR4MQZ/MBr/MeFFFIkxYAR9MGr84cFijBJ9UFPD7r3TqtWWLsVuO3PM3ew20+3uzizTxpDsTSa7e+ec75zvnPtz7l2E87zhee4/NAj83xlsZKCRgZgRaAyhmAGMrV4zA5lM5sJEItGcz+dbhBDN5gGAZkRsQcTCd/Mwc0vpu+k3v5l5yHGcDUEPtdY7AeAsIp4t/5yYmCj0myefz//LzGfNY/p7enrGqjGtSEAp9ZgQYgsz07mGiJk3OY7zVklfKbULEZ88FzxE1L7vv+Q4ztPl+tMIZLPZFUKIb87FUFBHCLHQtu2+Up/WmuNi+r5/bSqVOh7EmUZAa70VAJ6PYwwRJ6SUyRKG67odzPxHHMyi7jYi2luTgOu6O5h5T1xjiLhDSvlsIAOfAcDKOLiI+KiU8pmwDGwGgFfjGCrqDhLRgkAWHmTml2PiPkBEr4URuAcA3o5pqKR+PxG9aX7M0DDaQEQHahJQSt2KiEdmiMA7RGQCUmha61jDiJlvcxznw7A5cAMzfz4TBHzfvzGVSn1qsDKZzErLsgyBac0skwBwwvf9HCKuBoD5VeRWSim/CMvAMkQ8MQME+ohoYZToE9HkapjNZq9AxFcQcUW5D8y83HGc72oSyGQyiy3L+qUeAsx8yMgj4p0BvZ1E9FRY9Jl5t+M4u4L2tNaPA0BBN9g8z+tJp9O/1iTQ39/f6fv+QB0ExoQQS4aGhv5qa2s7zsyXGl0hRJdt24W1P2TsbyWiF4L2lFL3IuK+ch+CmKV30zYyU/9YljVaB4EDRFSoeUrj3CwCUsrbw6JftPE9EV1ZloFhAGitkIGmdDpt6qjJVrEWcl03z8yTO2kImTuI6P2STDabfUQIsYqIbjJ91aJZhjkCANuZeSkArEbExeU2EXFcSjlnWn8l55RSg4h4UVgWELHPtu1FiDilzlFKmaxsNEa11ksA4KcwrLD3zPy34zjtkQhorU0RdkkYqJloRGRK5ClNKXUxIposFDax8kIOEfczcxsArI1goyTyOxF1RyKglPoBES+LAH4VEVVccrXWa4nogyKBXgBYXnR8DxH9XOz/EgCuj2AHmPlHx3Euj0RAa/0VAFwXAvw1EdU03tfXN7+7u3tIa73X87zD6XR6ygaZzWavEUJMKY9r2Kxor9okPsrMZkes1TYT0etRoldLxnXdF5l5SxgOIh6TUq6JlAGl1EFEvKsWqO/7C1Kp1GCY4bD3zDzHdd2TANBTS5aZ33McZ10kAlprM/k2VQNExENSypoEwxwPvndddyMz7w/R2UdE90UlYE5k5mRWsVWqCutxuJKs1tqUyetr4Owlom2RCLiuu4uZqx3A/yGi0D2iXkKnTp1amkgkTKVZERsRd0spp9RMxkbFSVzcTSePg2XOFNbjwcFBs9W35vP5Vs/z2oQQrYjY6vt+4dOs86ZI01o/AQA5Zs5ZljUyMTGRE0KMmN/JZHJkdHQ019TUNNLZ2ZmrVTP5vr89lUo9FykDWmsz1t6oN4pBeSHE+vHx8cN11lW1TE6e7oJCFTPQ39+/zvf9d+MQYOZlxc2rsBvHbUKIu23bPhgpA67rrmHmj2IY/bNYihiMWDcRJR8Q8RYp5dFIBAYGBhZ5njfl4FAvGSnlBUqph4QQ1eZSXZCWZS3u6ur6LRIBI6S1/hgAVkW0wsx8GhFPA8AIIuYA4OTw8PDDLS0txxBxXukutXiPOi8ibknsEyK6uZJO1ctds8qMjY2Zc+nVAFBwzjjJzCOJRCKXz+fPJJNJ46h5zti2fSaqU729vcmOjo5my7LmBS6MDSlzcdzseV7w8vjbuXPnHm9vbzfBmdYa/w9EjfpsyTUyMFuRjYrbyEDUSM2WXCMDsxXZqLjnfQb+A8eWU0/QfZYsAAAAAElFTkSuQmCC",attr:{timeOutId:"data-lazy-timeout-id"}};class Pi{options={loading:Ze.loading,error:Ze.error,observerOptions:{rootMargin:"0px",threshold:0},log:!1,callback:{}};_images=new WeakMap;constructor(a){this.config(a)}config(a={}){this.options=o.getJsonMergeDeep(this.options,a)}_initValue(a,i){let t="",s=this.options.loading,l=this.options.error,d=this.options.callback,u=this.options.delay;return o.isObject(a)?(t=a.src,s=o.isUndefined(a.loading)?this.options.loading:a.loading,l=o.isUndefined(a.error)?this.options.error:a.error,d=o.isUndefined(a.callback)?this.options.callback:a.callback,u=o.isUndefined(a.delay)?this.options.delay:a.delay):o.isString(a)?t=a:o.isUndefined(a)&&(t=i&&i.src||""),{src:t,loading:s,error:l,callback:d,delay:u}}mount(a,i){if(o.isUndefined(a))return;const t=o.isString(i)?i:i.value,{src:s,loading:l,error:d,callback:u,delay:r}=this._initValue(t,a);if(this._setCallback(a,"loading",u),a.setAttribute("src",l||Ze.loading),!this._checkIntersectionObserver()){this._setImageSrc(a,s,d,u),this._log(()=>{throw new Error("Not support IntersectionObserver!")});return}this._initIntersectionObserver(a,s,d,u,r)}update(a,i){if(o.isUndefined(a))return;this._realObserver(a)?.unobserve(a),a.hasAttribute(Ze.attr.timeOutId)&&(clearTimeout(Number(a.getAttribute(Ze.attr.timeOutId))),a.removeAttribute(Ze.attr.timeOutId));const t=o.isString(i)?i:i.value,{src:s,error:l,callback:d,delay:u}=this._initValue(t,a);this._initIntersectionObserver(a,s,l,d,u)}unmount(a){if(!o.isUndefined(a)){if(this._realObserver(a)?.unobserve(a),a.hasAttribute(Ze.attr.timeOutId)&&(clearTimeout(Number(a.getAttribute(Ze.attr.timeOutId))),a.removeAttribute(Ze.attr.timeOutId)),a.tagName.toLowerCase()==="img"){const i=a;i.onload=null,i.onerror=null}this._images.delete(a)}}_setImageSrc(a,i,t,s){if(a.tagName.toLowerCase()==="img"){const l=a;o.isEmpty(i)?(l.onload=null,this._setCallback(l,"error",s),this._realObserver(l)?.disconnect(),t?l.setAttribute("src",t):l.removeAttribute("src")):(this.options.isCrossOrigin&&(l.crossOrigin="Anonymous"),i&&l.getAttribute("src")!==i&&l.setAttribute("src",i),l.onload=()=>{i&&this._setCallback(l,"loaded",s)},l.onerror=()=>{l.onload=null,this._setCallback(l,"error",s),this._realObserver(l)?.disconnect(),t&&l.getAttribute("src")!==t&&l.setAttribute("src",t),this._log(()=>{throw new Error(`Image failed to load!And failed src was: ${i} `)})})}else a.style.backgroundImage=`url('${i}')`}_setCallback(a,i,t){switch(a?.setAttribute("lazy",i),i){case"loading":t?.loading&&t.loading(a);break;case"loaded":t?.loaded&&t.loaded(a);break;case"error":t?.error&&t.error(a);break}}_realObserver(a){return this._images.get(a)}_checkIntersectionObserver(){if(typeof window<"u"&&window!==null&&"IntersectionObserver"in window&&"IntersectionObserverEntry"in window&&"intersectionRatio"in window.IntersectionObserverEntry.prototype){if(!("isIntersecting"in window.IntersectionObserverEntry.prototype))try{Object.defineProperty(window.IntersectionObserverEntry.prototype,"isIntersecting",{get(){return this.intersectionRatio>0}})}catch{return!1}return!0}return!1}_initIntersectionObserver(a,i,t,s,l){const d=this.options.observerOptions;this._images.set(a,new IntersectionObserver(u=>{Array.prototype.forEach.call(u,r=>{l&&l>0?this._delayedIntersectionCallback(a,r,l,i,t,s):this._intersectionCallback(a,r,i,t,s)})},d)),this._realObserver(a)?.observe(a)}_intersectionCallback(a,i,t,s,l){i.isIntersecting&&(this._realObserver(a)?.unobserve(i.target),this._setImageSrc(a,t,s,l))}_delayedIntersectionCallback(a,i,t,s,l,d){if(i.isIntersecting){if(i.target.hasAttribute(Ze.attr.timeOutId))return;const u=setTimeout(()=>{this._intersectionCallback(a,i,s,l,d),i.target.removeAttribute(Ze.attr.timeOutId)},t);i.target.setAttribute(Ze.attr.timeOutId,String(u))}else i.target.hasAttribute(Ze.attr.timeOutId)&&(clearTimeout(Number(i.target.getAttribute(Ze.attr.timeOutId))),i.target.removeAttribute(Ze.attr.timeOutId))}_log(a){this.options.log&&a()}}const Ri=(n,a,i)=>{const t=new Pi(i);e.onMounted(()=>{e.nextTick(()=>{n.value&&t.mount(n.value,a)})}),e.onUnmounted(()=>{n.value&&t.unmount(n.value)}),e.watch(a,s=>{n.value&&t.update(n.value,s)})},yc=["id"],vc=["alt"],Yn=e.defineComponent({name:"ClImage",__name:"Index",props:{id:{},className:{},src:{},alt:{},height:{},width:{},isCircle:{type:Boolean},fit:{},isCrossOrigin:{type:Boolean}},emits:["onInit"],setup(n,{emit:a}){const i=n,t=a,s=e.ref(o.isNonEmptyString(i.src)?i.src:""),l=e.useTemplateRef("refElImage"),d=e.computed(()=>o.isNonEmptyString(i.alt)?i.alt:""),u=i.id;Ri(l,s,{callback:{loaded:()=>{p()},error:()=>{p()}},isCrossOrigin:i.isCrossOrigin});const r=e.computed(()=>{let f={"panel-image":!0,"imageBox-circle":i.isCircle};return f=o.getJsonMerge(f,de.getClassNameJson(i.className)),f}),c=e.computed(()=>{const{width:f,height:h}=i,g={};return o.isNonEmptyString(f)&&(g.width=f),o.isNonEmptyString(h)&&(g.height=h),g}),m=e.computed(()=>{const{width:f,height:h,fit:g}=i,y={};return o.isNonEmptyString(g)&&(y["object-fit"]=g,o.isNonEmptyString(f)&&(y.width=f),o.isNonEmptyString(h)&&(y.height=h)),y});function p(){t("onInit")}return e.watch(()=>i.src,f=>{s.value=o.isNonEmptyString(f)?f:""}),(f,h)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(u),class:e.normalizeClass(r.value),style:e.normalizeStyle(c.value)},[e.createElementVNode("img",{ref_key:"refElImage",ref:l,alt:d.value,style:e.normalizeStyle(m.value)},null,12,vc)],14,yc))}}),kc=["id"],Sc=["type","inputmode","name","value","placeholder","disabled","readonly"],wc={key:0,class:"input-floating-label"},Ec={key:3,class:"input-suffix"},Bo=e.defineComponent({name:"ClInputContainer",components:{ClIconFont:ve},__name:"Container",props:{id:String,name:String,value:[String,Number],inputType:{type:String,default:"text"},inputmode:{type:String,default:""},autocomplete:{type:String,default:"off"},placeholder:String,label:String,isFloating:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},isReadonly:{type:Boolean,default:!1},isClean:{type:Boolean,default:!0},isShowSuffix:{type:Boolean,default:!1}},emits:["onInputText","onKeydown","onKeyup","onFocus","onBlur","onClear"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElInput"),u=e.computed(()=>{let O=t.name;return o.isEmpty(O)&&(O=`input_${o.getRandom(8)}`),O}),r=e.computed(()=>o.isEmpty(t.inputmode)?void 0:t.inputmode),c=e.computed(()=>{const O={};return o.isNonEmptyString(t.autocomplete)&&(O.autocomplete=t.autocomplete),O}),m=e.computed(()=>t.isClean&&!t.disabled&&!t.isReadonly),p=e.computed(()=>m.value&&!o.isEmpty(t.value)),f=e.computed(()=>t.isFloating?t.label||t.placeholder:""),h=e.computed(()=>({"input-container":!0,"input-clean":t.isClean,"input-suffix":t.isShowSuffix,"input-floating":t.isFloating})),g=O=>{const w=O.target;w&&s("onInputText",w.value)},y=O=>{s("onKeydown",O)},V=O=>{s("onKeyup",O)},E=()=>{s("onFocus")},B=()=>{s("onBlur")},T=()=>{s("onClear")};return a({getInputElement:()=>d.value,focus:()=>{d.value?.focus()}}),(O,w)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(h.value)},[e.createElementVNode("input",e.mergeProps({ref_key:"refElInput",ref:d,type:n.inputType,inputmode:r.value,name:u.value},c.value,{class:"form-control",value:n.value,placeholder:n.placeholder,disabled:n.disabled,readonly:n.isReadonly,onInput:g,onKeydown:y,onKeyup:V,onFocus:E,onBlur:B}),null,16,Sc),f.value?(e.openBlock(),e.createElementBlock("label",wc,e.toDisplayString(f.value),1)):e.createCommentVNode("",!0),p.value?(e.openBlock(),e.createBlock(ve,{key:1,name:"close-circle-fill",class:"input-clear-icon","aria-label":"清除输入内容",role:"button",tabindex:"-1",onClick:e.withModifiers(T,["stop"]),onKeydown:[e.withKeys(e.withModifiers(T,["stop"]),["enter"]),e.withKeys(e.withModifiers(T,["stop","prevent"]),["space"])]},null,8,["onKeydown"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64)),n.isShowSuffix?(e.openBlock(),e.createElementBlock("div",Ec,[e.renderSlot(O.$slots,"suffix")])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64))],10,kc))}}),bc=["id"],Cc={key:0,class:"cl-plaintext-value"},xc={key:0,class:"input-group-prepend"},Bc={class:"input-group-text"},Dc={key:2,class:"input-group-append"},Ic={class:"input-group-text"},Pe=e.defineComponent({name:"ClInput",components:{ClInputContainer:Bo},__name:"Index",props:{id:String,name:String,value:[String,Number],className:String,disabled:{type:Boolean,default:!1},theme:{type:String,default:"default"},inputType:String,inputmode:{type:String,default:""},autocomplete:{type:String,default:"off"},width:String,placeholder:String,label:String,isFloating:{type:Boolean,default:!1},isReadonly:{type:Boolean,default:!1},isClean:{type:Boolean,default:!0},isPlaintext:{type:Boolean,default:!1},changeDelayTime:{type:Number,default:200}},emits:["update:value","update:modelValue","onChange","onFocus","onBlur","onChangeBlur","onKeyupEnter","onClear","onInit","onKeydown","onKeyup","onChangeDelay"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElContainer"),u=e.ref(!1),r=o.isString(t.value)?t.value:t.value!==void 0&&o.isNumber(t.value)&&o.isFinite(t.value)?t.value.toString():"",c=e.ref(r),m=e.ref(r),p=e.ref(r),f={prevDelayValue:r,valueDelayRun:!1};let h=null;const g=e.computed(()=>{let P={"panel-input":!0,"input-disabled":t.disabled,"input-readonly":t.isReadonly};return P=o.getJsonMerge(P,de.getClassNameJson(t.className)),o.isEmpty(t.theme,"default")||(P[`input-${t.theme}`]=!0),P}),y=e.computed(()=>{const P={};return o.isNonEmptyString(t.width)&&(P.width=t.width),P}),V=P=>{E(),f.valueDelayRun=!0,h=setTimeout(()=>{h=null,m.value===P&&(f.valueDelayRun=!1,f.prevDelayValue!==P&&(f.prevDelayValue=P,s("onChangeDelay",P)))},t.changeDelayTime)},E=()=>{h&&(clearTimeout(h),h=null),f.valueDelayRun=!1},B=P=>{if(P!==m.value){m.value=P;const Q=N(P);s("update:value",Q),s("update:modelValue",Q),s("onChange",Q),V(Q)}},T=P=>{u.value=!0,p.value=P,s("onFocus",P)},D=P=>{u.value=!1,s("onBlur",P),P!==p.value&&(p.value=P,s("onChangeBlur",P))},x=P=>{s("onKeyupEnter",P)},O=P=>{s("onKeydown",P)},w=P=>{s("onKeyup",P)},M=()=>{s("onClear")},b=()=>{e.nextTick(()=>{s("onInit")})},N=P=>o.isString(P)||o.isNumber(P)&&o.isFinite(P)?P.toString():"",J=()=>{d.value?.focus()},q=()=>{const P=N(t.value);o.isEmpty(P)||(c.value=P,m.value=P),b()};e.onMounted(()=>{q()}),e.onBeforeUnmount(()=>{E()}),e.watch(()=>t.value,P=>{const Q=N(P);Q!==c.value&&(c.value=Q,m.value=Q,f.prevDelayValue=Q,f.valueDelayRun&&E())});const z=P=>{c.value=P,B(P)},H=P=>{O(P)},v=P=>{const Q=P.key,oe=P.keyCode;if(Q==="Enter"||oe===13){const ue=P.target,Y=N(ue.value);x(Y)}else w(P)},S=()=>{const P=N(c.value);T(P)},C=()=>{const P=N(c.value);D(P)},$=()=>{c.value="",B(""),M(),J()},k=()=>{const P=d.value;return P?P.getInputElement():null},I=()=>N(c.value);return a({getValue:I,getValueData:()=>({value:I(),show:c.value}),setValue:(P,Q)=>{const oe=N(P);c.value=oe,m.value=oe,f.prevDelayValue=oe,f.valueDelayRun&&E(),Q&&(s("update:value",oe),s("update:modelValue",oe))},focus:()=>{J()},getInputElement:k}),(P,Q)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(g.value),style:e.normalizeStyle(y.value)},[n.isPlaintext?(e.openBlock(),e.createElementBlock("div",Cc,e.toDisplayString(c.value),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[P.$slots.prepend||P.$slots.append?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass({"input-group":!0,"input-group-focus":u.value})},[P.$slots.prepend?(e.openBlock(),e.createElementBlock("div",xc,[e.createElementVNode("span",Bc,[e.renderSlot(P.$slots,"prepend")])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createVNode(Bo,{ref_key:"refElContainer",ref:d,value:c.value,inputType:n.inputType,inputmode:n.inputmode,autocomplete:n.autocomplete,name:n.name,placeholder:n.placeholder,disabled:n.disabled,isReadonly:n.isReadonly,isClean:n.isClean,isShowSuffix:!!P.$slots.suffix,label:n.label,isFloating:n.isFloating,onOnInputText:z,onOnKeydown:H,onOnKeyup:v,onOnFocus:S,onOnBlur:C,onOnClear:$},e.createSlots({_:2},[P.$slots.suffix?{name:"suffix",fn:e.withCtx(()=>[e.renderSlot(P.$slots,"suffix")]),key:"0"}:{name:"suffix",fn:e.withCtx(()=>[]),key:"1"}]),1032,["value","inputType","inputmode","autocomplete","name","placeholder","disabled","isReadonly","isClean","isShowSuffix","label","isFloating"]),P.$slots.append?(e.openBlock(),e.createElementBlock("div",Dc,[e.createElementVNode("span",Ic,[e.renderSlot(P.$slots,"append")])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],2)):(e.openBlock(),e.createBlock(Bo,{key:1,ref_key:"refElContainer",ref:d,value:c.value,inputType:n.inputType,inputmode:n.inputmode,autocomplete:n.autocomplete,name:n.name,placeholder:n.placeholder,disabled:n.disabled,isReadonly:n.isReadonly,isClean:n.isClean,isShowSuffix:!!P.$slots.suffix,label:n.label,isFloating:n.isFloating,onOnInputText:z,onOnKeydown:H,onOnKeyup:v,onOnFocus:S,onOnBlur:C,onOnClear:$},e.createSlots({_:2},[P.$slots.suffix?{name:"suffix",fn:e.withCtx(()=>[e.renderSlot(P.$slots,"suffix")]),key:"0"}:{name:"suffix",fn:e.withCtx(()=>[]),key:"1"}]),1032,["value","inputType","inputmode","autocomplete","name","placeholder","disabled","isReadonly","isClean","isShowSuffix","label","isFloating"]))],64))],14,bc))}}),_t=e.defineComponent({name:"ClInputNumber",components:{ClInput:Pe},__name:"Index",props:{id:String,name:{type:String,default:""},value:{type:[String,Number],default:""},className:{type:String,default:""},disabled:{type:Boolean,default:!1},theme:{type:String,default:"default"},inputType:{type:String,default:""},inputmode:{type:String,default:""},autocomplete:{type:String,default:"off"},width:{type:String,default:""},placeholder:{type:String,default:""},label:String,isFloating:{type:Boolean,default:!1},isReadonly:{type:Boolean,default:!1},isClean:{type:Boolean,default:!0},isNumber:{type:Boolean,default:!0},decimal:{type:Number,default:0,validator:n=>n>=-1&&n<=100&&n%1===0},isThousand:{type:Boolean,default:!0},isImmediateThousand:{type:Boolean,default:!0},changeDelayTime:{type:Number,default:200,validator:n=>o.isFinite(n)&&n>=0},isPlaintext:{type:Boolean,default:!1}},emits:["update:value","update:modelValue","onChange","onFocus","onBlur","onChangeBlur","onKeyupEnter","onClear","onInit","onKeydown","onKeyup","onChangeDelay"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElInput"),u=e.ref(t.value),r=e.ref(t.value),c=e.computed(()=>{let k={"panel-input-number":!0};return k=o.getJsonMerge(k,de.getClassNameJson(t.className)),o.getStringByJson(k," ")}),m=e.computed(()=>o.isNonEmptyString(t.inputmode)?t.inputmode:t.decimal===0?"numeric":"decimal"),p=k=>{if(k!==r.value){r.value=k;const I=E(k);s("update:value",I),s("update:modelValue",I),s("onChange",I)}},f=k=>{let I=o.isNumber(k);if(!I)if(o.isNaN(+k))k==="-"&&(I=!0);else{const L=k.split(".");L.length===2&&(I=(o.isNumber(L[0])||o.isEmpty(L[0]))&&(o.isEmpty(L[1])||o.isNumber(L[1])))}return I},h=(k,I,L=!0,_=!0)=>{let R=k;if(t.isNumber){let P=o.removeReplace(k);if(P.length>0)if(f(P)){if(P!=="-"){const{decimal:oe}=t;if(L&&oe!==0&&(oe===-1||oe>=0&&oe<=100)&&oe!==-1){const ue=parseFloat(P);if(o.isFinite(ue)){const Y=ue.toFixed(oe);P=Y.indexOf("e")>-1?P:Y}}if(_){const ue=P.split("."),Y=o.isEmpty(ue[0])?"0":ue[0];if(P=t.isThousand?o.getFormatThousands(Y):Y,ue.length===2&&oe!==0){const Z=oe===-1?ue[1]:ue[1].slice(0,oe);P+=`.${Z}`}}}}else P=I;else P="";R=P}return R},g=(k,I)=>{const L=I.split(""),_=new RegExp("^"+L.map(Q=>Q.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")).join(".*?")),R=k.match(_);let P;return R&&(P=R[0].length),P},y=(k,I,L)=>{const _=de.getFocusSelection(k);let R=I.substring(0,_.start);R=o.removeReplace(R);const P=I.substring(_.start);let Q=f(R);R.indexOf(".")>-1&&P.indexOf(".")>-1&&(Q=!1);let oe=_.start;Q?oe=g(L,R):oe=L.lastIndexOf(P),(o.isUndefined(oe)||oe>L.length||oe<0)&&(oe=L.length),e.nextTick(()=>{de.setFocusSelection(k,oe,oe)})},V=()=>{const k=u.value;if(o.isEmpty(k))return k;{let I=k.toString();if(t.isNumber){const{decimal:L}=t;if(I=o.removeReplace(I),I==="-")return I;if(L!==0&&L!==-1){const P=parseFloat(I);if(o.isFinite(P)&&L>=0&&L<=100){const Q=P.toFixed(L);I=Q.indexOf("e")>-1?I:Q}}const _=I.split("."),R=o.isEmpty(_[0])?"0":_[0];_[0]=t.isThousand?o.getFormatThousands(R):R,L===0?I=_[0]:_.length===2?(_[1]=L===-1?_[1]:o.getFillZero(_[1],L,"r"),I=_.join(".")):I=_[0]}return I}},E=k=>{let I="";if(!o.isEmpty(k)&&(I=k.toString(),t.isNumber&&I!=="-")){const{decimal:L}=t,_=I.split(".");let R=o.removeReplace(_[0]);if(_.length===2&&L!==0){let P="";L===-1?P=_[1]:P=o.getFillZero(_[1],L,"r"),R+=`.${P}`}I=R}return I},B=()=>{d.value?.focus()},T=()=>{if(!o.isEmpty(t.value)){const k=h(t.value,"");u.value=k,r.value=k}};e.onMounted(()=>{T()}),e.watch(()=>t.value,(k,I)=>{if(k!==I&&k!==u.value){let L=!0;if(t.isNumber){const _=o.removeReplace(k),R=o.removeReplace(u.value),P=o.isEmpty(_),Q=o.isEmpty(R);P&&Q?L=!1:!P&&!Q&&(L=Number(_)!==Number(R))}if(L){const _=h(k,I);u.value=_,r.value=_}}}),e.watch([()=>t.isNumber,()=>t.decimal,()=>t.isThousand],()=>{const k=h(u.value,"");u.value=k,p(k)});const D=k=>{const I=h(k,r.value,!1,t.isImmediateThousand);u.value=I,d.value?.setValue(I),t.isNumber&&e.nextTick(()=>{const L=d.value?.getInputElement();L&&u.value===I&&y(L,k,String(I))}),p(I)},x=()=>{const k=V();u.value=k,r.value=k;const I=E(k);s("onFocus",I)},O=()=>{const k=V();u.value=k,r.value=k;const I=E(k);s("onBlur",I)},w=k=>{s("onChangeBlur",E(k))},M=k=>{s("onKeyupEnter",E(k))},b=k=>{s("onKeydown",k)},N=k=>{s("onKeyup",k)},J=()=>{s("onClear")},q=()=>{s("onInit")},z=k=>{s("onChangeDelay",E(k))},H=()=>E(u.value);return a({getValue:H,getValueData:()=>({value:H(),show:o.isEmpty(u.value)?"":u.value.toString()}),setValue:(k,I)=>{const L=o.isEmpty(k)?"":h(k,"");if(u.value=L,r.value=L,d.value?.setValue(L),I){const _=E(L);s("update:value",_),s("update:modelValue",_),s("onChange",_)}},focus:()=>{B()},getInputElement:()=>d.value?.getInputElement()??null}),(k,I)=>(e.openBlock(),e.createBlock(Pe,{ref_key:"refElInput",ref:d,id:e.unref(l),value:u.value,name:n.name,className:c.value,inputType:n.inputType,inputmode:m.value,autocomplete:n.autocomplete,placeholder:n.placeholder,label:n.label,isFloating:n.isFloating,disabled:n.disabled,isReadonly:n.isReadonly,isClean:n.isClean,width:n.width,theme:n.theme,isPlaintext:n.isPlaintext,changeDelayTime:n.changeDelayTime,onOnChange:D,onOnFocus:x,onOnBlur:O,onOnChangeBlur:w,onOnKeyupEnter:M,onOnKeydown:b,onOnKeyup:N,onOnClear:J,onOnInit:q,onOnChangeDelay:z},e.createSlots({_:2},[k.$slots.prepend?{name:"prepend",fn:e.withCtx(()=>[e.renderSlot(k.$slots,"prepend")]),key:"0"}:void 0,k.$slots.append?{name:"append",fn:e.withCtx(()=>[e.renderSlot(k.$slots,"append")]),key:"1"}:void 0,k.$slots.suffix?{name:"suffix",fn:e.withCtx(()=>[e.renderSlot(k.$slots,"suffix")]),key:"2"}:void 0]),1032,["id","value","name","className","inputType","inputmode","autocomplete","placeholder","label","isFloating","disabled","isReadonly","isClean","width","theme","isPlaintext","changeDelayTime"]))}}),Tc=["id"],Nc={key:0,class:"inputCaptcha-count"},Do=120,Io=1e3,Hi=e.defineComponent({name:"ClInputCaptcha",components:{ClInputNumber:_t},__name:"Index",props:{id:{},value:{default:""},className:{},theme:{default:"default"},placeholder:{},autocomplete:{default:"one-time-code"},countdownMax:{default:Do},onSendBefore:{}},emits:["update:value","update:modelValue","onChange","onKeyupEnter","onSend","onError"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.reactive({value:o.isString(t.value)?t.value:"",isSend:!1,isCountdown:!1,countdown:Do}),u={intervalCountdownId:null,isSending:!1,isUnmounted:!1},r=e.computed(()=>{let T={"panel-input-captcha":!0};return T=o.getJsonMerge(T,de.getClassNameJson(t.className)),T[`inputCaptcha-theme-${t.theme}`]=!0,T}),c=e.computed(()=>({"inputCaptcha-send":!0,"inputCaptcha-send-ing":d.isCountdown})),m=T=>{s("update:value",T),s("update:modelValue",T),s("onChange",T)},p=()=>{s("onKeyupEnter",d.value)},f=()=>{s("onSend")},h=()=>{const{countdownMax:T}=t;return o.isNumber(T)&&o.isFinite(T)&&T>0?Math.floor(T):Do},g=T=>o.isNonEmptyString(T)?T:"";e.onBeforeUnmount(()=>{u.isUnmounted=!0,u.intervalCountdownId&&(clearInterval(u.intervalCountdownId),u.intervalCountdownId=null)}),e.watch(()=>t.value,T=>{const D=g(T);d.value!==D&&(d.value=D)});const y=T=>{m(T)},V=()=>{p()},E=async()=>{if(d.isCountdown||u.isSending)return;u.isSending=!0;let T=!1;if(t.onSendBefore)if(!o.isFunction(t.onSendBefore))Se.warn("ClInputCaptcha","InputCaptcha: onSendBefore 需为函数"),s("onError","onSendBefore 需为函数");else try{const D=await t.onSendBefore(d.value);o.isBoolean(D)?T=D:(Se.warn("ClInputCaptcha","InputCaptcha: onSendBefore 需返回 boolean,本次按校验失败处理"),s("onError","onSendBefore 返回值需为 boolean"))}catch{T=!1,s("onError","发送前校验异常")}else T=!0;if(u.isSending=!1,!(u.isUnmounted||d.isCountdown)&&(d.isSend=T,T)){f(),d.isCountdown=!0,d.countdown=h();const D=Date.now()+d.countdown*Io,x=setInterval(()=>{const O=Math.ceil((D-Date.now())/Io);O<=0?(clearInterval(x),u.intervalCountdownId=null,d.countdown=h(),d.isCountdown=!1):d.countdown=O},Io);u.intervalCountdownId=x}};return a({getValue:()=>d.value}),(T,D)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(r.value)},[e.createVNode(_t,{theme:n.theme,isNumber:!0,decimal:0,isThousand:!1,value:d.value,"onUpdate:value":D[0]||(D[0]=x=>d.value=x),placeholder:n.placeholder,autocomplete:n.autocomplete,isClean:!0,onOnKeyupEnter:V,onOnChange:y},null,8,["theme","value","placeholder","autocomplete"]),e.createElementVNode("div",{class:e.normalizeClass(c.value)},[d.isSend?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[d.isCountdown?(e.openBlock(),e.createElementBlock("span",Nc,e.toDisplayString(d.countdown)+"秒后重发",1)):(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"inputCaptcha-btn",onClick:e.withModifiers(E,["stop"])}," 重新发送 "))],64)):(e.openBlock(),e.createElementBlock("button",{key:1,type:"button",class:"inputCaptcha-btn",onClick:e.withModifiers(E,["stop"])}," 发送验证码 "))],2)],10,Tc))}});class bt{optionsDrag;_isDragging;_bindRunDragStart;_bindRunDragIng;_bindRunDragEnd;constructor(a,i){this.optionsDrag=i,this._isDragging=!1,this._init(a)}_init(a){this._bindRunDragStart=this._runDragStart.bind(this),this._bindRunDragIng=this._runDraggIng.bind(this),this._bindRunDragEnd=this._runDragEnd.bind(this),de.onListener(a,"mousedown",this._bindRunDragStart),de.onListener(a,"touchstart",this._bindRunDragStart)}_runDragStart(a){if(this._isDragging)return;const i=de.getClientXY(a);let t=!0;this.optionsDrag.start&&(t=this.optionsDrag.start(a,i)),t=o.isBoolean(t)?t:!0,t?(a.preventDefault(),a.stopPropagation(),document.onselectstart=()=>!1,document.ondragstart=()=>!1,this._isDragging=!0,de.onListener(window,"mousemove",this._bindRunDragIng),de.onListener(window,"touchmove",this._bindRunDragIng),de.onListener(window,"mouseup",this._bindRunDragEnd),de.onListener(window,"touchend",this._bindRunDragEnd),de.onListener(window,"contextmenu",this._bindRunDragEnd)):this._isDragging=!1}_runDraggIng(a){if(!this._isDragging)return;const i=de.getClientXY(a);this.optionsDrag.ing&&this.optionsDrag.ing(a,i)}_runDragEnd(a){if(!this._isDragging)return;this._isDragging=!1;const i=de.getClientXY(a);this.optionsDrag.end&&this.optionsDrag.end(a,i),this._offListener()}_offListener(){de.offListener(window,"mousemove",this._bindRunDragIng),de.offListener(window,"touchmove",this._bindRunDragIng),de.offListener(window,"mouseup",this._bindRunDragEnd),de.offListener(window,"touchend",this._bindRunDragEnd),de.offListener(window,"contextmenu",this._bindRunDragEnd)}end(){this._isDragging=!1,this._offListener()}}class ht{options;_isWinResize;_isRunDelay;_runDelayFun;_bindWinResize;_objResizeObserver;constructor(a){this._isWinResize=o.isUndefined(a.element),this._isRunDelay=!!(!o.isBoolean(a.isDelay)||a.isDelay),this.options=a,this._init()}_init(){this._isRunDelay&&(this._runDelayFun=new Ai(this.options.callback,this.options.delayTime)),this._isWinResize?(this._bindWinResize=this._onWinResize.bind(this),de.onListener(window,"resize",this._bindWinResize)):this._initResizeObserver()}_onWinResize(){this._isRunDelay?this._runDelayFun.run():this.options.callback&&this.options.callback()}_initResizeObserver(){window&&"ResizeObserver"in window&&(this._objResizeObserver=new ResizeObserver(a=>{const i=a[0];this._isRunDelay?this._runDelayFun.run(()=>{this.options.callback(i)}):this.options.callback(i)}),this._objResizeObserver.observe(this.options.element))}destroy(){this._isWinResize?de.offListener(window,"resize",this._bindWinResize):this._objResizeObserver&&(this._objResizeObserver.disconnect(),this._objResizeObserver=null)}}const Vc=["aria-disabled"],To=e.defineComponent({name:"ClInputnumberstepperButton",__name:"Button",props:{className:{},disabled:{type:Boolean},checkDownBeforeCallback:{type:Function}},emits:["onLongDownStart","onLongDownEnd"],setup(n,{emit:a}){const i=n,t=a,s=e.useTemplateRef("refElButton"),l={longDownInterval:null,isMoveBoundary:!1,isLongDownActive:!1,isKeyDown:!1,dragEvent:null,sessionSource:null},d=e.computed(()=>{const B=o.getJsonMerge({"inputNumberStepper-controls":!0},de.getClassNameJson(i.className));return B["inputNumberStepper-controls-disabled"]=!!i.disabled,B}),u=()=>{t("onLongDownStart")},r=B=>{t("onLongDownEnd",B)},c=()=>{let B=!0;if(i.checkDownBeforeCallback){try{B=i.checkDownBeforeCallback()}catch(T){Se.warn("ClInputnumberstepperButton","长按开始回调执行失败,按允许处理",T),B=!0}B=o.isBoolean(B)?B:!0}return B},m=()=>{l.longDownInterval&&(clearInterval(l.longDownInterval),l.longDownInterval=null)},p=B=>{l.isLongDownActive&&l.sessionSource!==B||(l.isLongDownActive=!0,l.sessionSource=B,u(),m(),l.longDownInterval=setInterval(()=>{i.disabled?h():u()},200))},f=B=>{if(l.sessionSource!=="mouse")return;const T=B.target;s.value===B.target||s.value?.contains(T)?l.isMoveBoundary&&(l.isMoveBoundary=!1,!i.disabled&&c()&&p("mouse")):(m(),l.isMoveBoundary=!0)},h=(B,T)=>{if(l.isLongDownActive){if(B&&l.sessionSource&&B!==l.sessionSource)return;m(),l.isLongDownActive=!1,l.sessionSource=null,l.isKeyDown=!1,r(T)}},g=()=>{const B={start(T){if(i.disabled)return!1;const D=T,x=T;let O=!1;return(D.buttons===1||T.type==="touchstart"||(x.touches?.length??0)>0)&&(O=c(),O&&(l.isMoveBoundary=!1,p("mouse"))),O},ing:T=>{f(T)},end:()=>{h("mouse")}};s.value&&(l.dragEvent=new bt(s.value,B))};e.onMounted(()=>{e.nextTick(()=>{g()})}),e.onBeforeUnmount(()=>{h(),l.dragEvent&&(l.dragEvent.end(),l.dragEvent=null)});const y=B=>{const T=B.key;if(T==="Enter"||T===" "){if(i.disabled)return;B.preventDefault(),!l.isKeyDown&&!l.isLongDownActive&&c()&&(l.isKeyDown=!0,p("keyboard"))}},V=B=>{const T=B.key;(T==="Enter"||T===" ")&&l.isKeyDown&&h("keyboard")},E=()=>{(l.isKeyDown||l.isLongDownActive)&&h(void 0,!0)};return(B,T)=>(e.openBlock(),e.createElementBlock("span",{ref_key:"refElButton",ref:s,class:e.normalizeClass(d.value),role:"button",tabindex:"0","aria-disabled":i.disabled,onKeydown:y,onKeyup:V,onBlur:E},[e.renderSlot(B.$slots,"icon")],42,Vc))}}),_c=["id"],hn=e.defineComponent({name:"ClInputNumberStepper",components:{ClInputNumber:_t,ClInputnumberstepperButton:To,ClIconFont:ve},__name:"Index",props:{id:String,value:{type:[String,Number],default:""},className:{type:String,default:""},disabled:{type:Boolean,default:!1},size:{type:String,default:"large"},btnShowType:{type:String,default:"fixed"},btnTheme:{type:String,default:"leftRight",validator:n=>["leftRight","upDown"].indexOf(n)!==-1},btnShape:{type:String,default:"square",validator:n=>["square","circle"].indexOf(n)!==-1},placeholder:{type:String,default:""},isClean:{type:Boolean,default:!0},isTextRead:{type:Boolean,default:!1},min:Number,max:Number,isLoop:{type:Boolean,default:!1},decimal:{type:Number,default:0},fillZeroCount:{type:Number,default:0},btnStep:{type:Number,default:1},btnClsIconSub:{type:String,default:""},btnClsIconAdd:{type:String,default:""},operateBtnDownBeforeCallback:{type:Function,default:void 0},calculationOperateValueCallback:{type:Function,default:void 0},isPlaintext:{type:Boolean,default:!1}},emits:["update:value","update:modelValue","onChange","onError"],setup(n,{emit:a}){const i=n,t=a,s=e.useTemplateRef("refElInput"),l=e.reactive({isFocus:!1}),d=e.ref(""),u=e.reactive({subtractDisabled:!1,addDisabled:!1}),r=i.id,c={upDown:{subtract:"angle-up",add:"angle-down"},leftRight:{subtract:"minus",add:"plus"}};let m=null;const p=()=>{const z=i.btnStep;return o.isFinite(z)&&z>0?z:1},f=e.computed(()=>{const z=i.decimal,H=p().toString();let v=z;if(H.indexOf(".")>-1){const S=H.split(".")[1].length;z<S&&(v=S)}return v===-1?-1:Math.max(0,Math.min(100,Math.round(v)))}),h=e.computed(()=>i.fillZeroCount>0&&o.isFinite(i.fillZeroCount)),g=e.computed(()=>{if(o.isNonEmptyString(i.btnClsIconSub))return"";const z=i.btnTheme||"leftRight";return c[z]?c[z].subtract:""}),y=e.computed(()=>{if(o.isNonEmptyString(i.btnClsIconAdd))return"";const z=i.btnTheme||"leftRight";return c[z]?c[z].add:""}),V=e.computed(()=>{if(i.isPlaintext){let H={"cl-plaintext-stepper":!0};return H=o.getJsonMerge(H,de.getClassNameJson(i.className)),H}let z={"panel-input-number-stepper":!0,"inputNumberStepper-disabled":i.disabled||!1};return z=o.getJsonMerge(z,de.getClassNameJson(i.className)),z[`inputNumberStepper-btn-${i.btnTheme||"leftRight"}`]=!0,z[`inputNumberStepper-btn-${i.btnShowType||"fixed"}`]=!0,(i.btnTheme||"leftRight")==="leftRight"&&i.btnShape==="circle"&&(z["inputNumberStepper-btnShape-circle"]=!0),z["inputNumberStepper-focus"]=l.isFocus,z[`inputNumberStepper-${i.size||"large"}`]=!0,z}),E=()=>{const z=d.value;t("update:value",z),t("update:modelValue",z),t("onChange",z)},B=z=>{o.isEmpty(z)||s.value?.setValue(z),d.value=z},T=(z,H)=>{o.isUndefined(z)&&(z=""),o.isString(z)&&(z=o.removeReplace(z));const v=z.toString();let S=z,C=!1,$=!1,k=!1;if(i.calculationOperateValueCallback){let I=null;try{const L=i.calculationOperateValueCallback({value:z,type:H});L&&(I=L)}catch{t("onError","数值计算回调执行失败")}I&&(o.isString(I.value)||typeof I.value=="number"&&o.isFinite(I.value))&&(S=I.value,C=I.subtractDisabled||!1,$=I.addDisabled||!1)}else{const I=H&&!o.isEmpty(H);if(I||!o.isEmpty(z)){const L=o.isEmpty(z)?0:Number(z);if(o.isFinite(L)){const _=i.min,R=i.max,{isLoop:P=!1}=i,Q=o.isUndefined(_),oe=o.isUndefined(R),ue=p();let Y=L;if(I){Y+=ue*(H==="subtract"?-1:1);const Z=Y.toString();if(Z.indexOf(".")>-1){const se=Z.split(".")[1].length,K=f.value;K>=0&&se>K&&(Y=Number(Y.toFixed(K)))}}!Q&&Y<=_?(P||(C=!0),S=Y<_&&P&&!oe?R:_,k=Y!==S):!oe&&Y>=R?(P||($=!0),S=Y>R&&P&&!Q?_:R,k=Y!==S):S=Y}}}if(typeof S=="number"&&f.value>0&&(S.toString().indexOf(".")>-1||v.indexOf(".")>-1)&&(S=S.toFixed(f.value)),!o.isString(S)&&!(typeof S=="number"&&o.isFinite(S))&&(S=""),h.value&&!o.isEmpty(S)&&o.isFinite(S)){const I=i.fillZeroCount;I>10&&Se.warn("ClInputNumberStepper","fillZeroCount 超过 10,按 10 处理",I);const L=S.toString(),_=L.charAt(0)==="-",R=_?L.slice(1):L,P=R.indexOf("."),Q=P>-1?R.slice(0,P):R,oe=P>-1?R.slice(P):"",Y=!/[eE]/.test(R)&&Q.length<I?o.getFillZero(Q,Math.min(I,10)):Q;S=(_?"-":"")+Y+oe}return B(S.toString()),u.subtractDisabled=C,u.addDisabled=$,k},D=z=>{l.isFocus=z,z&&s.value?.focus()},x=z=>["ArrowLeft","ArrowRight","ArrowUp","ArrowDown"].indexOf(z.key)!==-1;e.onBeforeUnmount(()=>{m&&(clearTimeout(m),m=null)}),e.watch(()=>i.value,(z,H)=>{z!==H&&z!==d.value&&T(z)&&E()},{immediate:!0});const O=z=>{i.disabled||(z=o.removeReplace(z),B(z),m&&(clearTimeout(m),m=null),m=setTimeout(()=>{o.isEmpty(d.value)?(u.subtractDisabled=!1,u.addDisabled=!1):T(d.value),E()},100))},w=z=>{if(!i.disabled&&!i.isTextRead&&x(z)){z.preventDefault(),m&&(clearTimeout(m),m=null);const H=z.key;H==="ArrowLeft"||H==="ArrowDown"?T(d.value,"subtract"):T(d.value,"add"),E(),D(!0)}},M=z=>{!i.disabled&&!i.isTextRead&&x(z)&&(m&&(clearTimeout(m),m=null),D(!0))},b=()=>{D(!0)},N=z=>{D(!1),i.disabled||B(z)},J=z=>{m&&(clearTimeout(m),m=null),T(d.value,z)},q=z=>{m&&(clearTimeout(m),m=null),E(),z||D(!0)};return(z,H)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(r),class:e.normalizeClass(V.value)},[e.createVNode(_t,{ref_key:"refElInput",ref:s,value:d.value,placeholder:n.placeholder,disabled:n.disabled,isReadonly:n.isTextRead,isClean:n.isClean,isNumber:!h.value,decimal:f.value,isPlaintext:n.isPlaintext,theme:"icon",onOnChange:O,onOnKeydown:w,onOnKeyup:M,onOnFocus:b,onOnBlur:N},e.createSlots({_:2},[z.$slots.textPrepend?{name:"prepend",fn:e.withCtx(()=>[e.renderSlot(z.$slots,"textPrepend")]),key:"0"}:void 0]),1032,["value","placeholder","disabled","isReadonly","isClean","isNumber","decimal","isPlaintext"]),n.isPlaintext?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(To,{className:"inputNumberStepper-subtract","aria-label":"减少",disabled:n.disabled||u.subtractDisabled,checkDownBeforeCallback:n.operateBtnDownBeforeCallback,onOnLongDownStart:H[0]||(H[0]=v=>J("subtract")),onOnLongDownEnd:q},{icon:e.withCtx(()=>[e.createVNode(ve,{name:g.value,className:n.btnClsIconSub},null,8,["name","className"])]),_:1},8,["disabled","checkDownBeforeCallback"]),e.createVNode(To,{className:"inputNumberStepper-add","aria-label":"增加",disabled:n.disabled||u.addDisabled,checkDownBeforeCallback:n.operateBtnDownBeforeCallback,onOnLongDownStart:H[1]||(H[1]=v=>J("add")),onOnLongDownEnd:q},{icon:e.withCtx(()=>[e.createVNode(ve,{name:y.value,className:n.btnClsIconAdd},null,8,["name","className"])]),_:1},8,["disabled","checkDownBeforeCallback"])],64))],10,_c))}}),Ui=e.defineComponent({name:"ClInputPassword",components:{ClIconFont:ve,ClInput:Pe},__name:"Index",props:{id:String,name:String,value:[String,Number],className:String,disabled:Boolean,theme:{type:String,default:"default"},width:String,placeholder:String,label:String,isFloating:{type:Boolean,default:!1},isReadonly:Boolean,isClean:{type:Boolean,default:!0}},emits:["update:value","update:modelValue","onChange","onFocus","onBlur","onChangeBlur","onKeyupEnter","onClear","onInit","onKeydown","onKeyup"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElInput"),u=e.ref(!1),r=e.computed(()=>u.value?"text":"password"),c=e.computed(()=>{let b={"panel-input-password":!0};return b=o.getJsonMerge(b,de.getClassNameJson(t.className)),o.getStringByJson(b," ")}),m=b=>{s("update:value",b),s("update:modelValue",b),s("onChange",b)},p=b=>{m(b)},f=b=>{s("onFocus",b)},h=b=>{s("onBlur",b)},g=b=>{s("onChangeBlur",b)},y=b=>{s("onKeyupEnter",b)},V=b=>{s("onKeydown",b)},E=b=>{s("onKeyup",b)},B=()=>{s("onClear")},T=()=>{s("onInit")},D=()=>{t.disabled||(u.value=!u.value)};return a({getValue:()=>d.value?.getValue(),getValueData:()=>d.value?.getValueData(),setValue:(b,N)=>{d.value?.setValue(b,N)},focus:()=>{d.value?.focus()}}),(b,N)=>(e.openBlock(),e.createBlock(Pe,{ref_key:"refElInput",ref:d,id:e.unref(l),name:n.name,value:n.value,inputType:r.value,className:c.value,placeholder:n.placeholder,label:n.label,isFloating:n.isFloating,disabled:n.disabled,isReadonly:n.isReadonly,isClean:n.isClean,width:n.width,theme:n.theme,onOnChange:p,onOnFocus:f,onOnBlur:h,onOnChangeBlur:g,onOnKeyupEnter:y,onOnKeydown:V,onOnKeyup:E,onOnClear:B,onOnInit:T},e.createSlots({suffix:e.withCtx(()=>[e.createVNode(ve,{class:"input-password-icon",name:u.value?"eye":"eye-no",role:"button","aria-label":u.value?"隐藏密码":"显示密码","aria-disabled":n.disabled,tabindex:n.disabled?-1:0,onClick:D,onKeydown:[e.withKeys(e.withModifiers(D,["prevent"]),["enter"]),e.withKeys(e.withModifiers(D,["prevent"]),["space"])]},null,8,["name","aria-label","aria-disabled","tabindex","onKeydown"])]),_:2},[b.$slots.prepend?{name:"prepend",fn:e.withCtx(()=>[e.renderSlot(b.$slots,"prepend")]),key:"0"}:void 0,b.$slots.append?{name:"append",fn:e.withCtx(()=>[e.renderSlot(b.$slots,"append")]),key:"1"}:void 0]),1032,["id","name","value","inputType","className","placeholder","label","isFloating","disabled","isReadonly","isClean","width","theme"]))}}),Mc=["id"],Oc=["aria-label","tabindex","onKeydown"],Qt=e.defineComponent({name:"ClInputSearch",components:{ClInput:Pe,ClIconFont:ve},__name:"Index",props:{id:String,value:{type:String,default:""},className:{type:String,default:""},disabled:{type:Boolean,default:!1},placeholder:{type:String,default:""},textLabel:{type:String,default:""},changeDelayTime:{type:Number,default:200},theme:{type:String,default:"icon",validator:n=>["icon","text"].indexOf(n)!==-1},location:{type:String,default:"right",validator:n=>["left","right"].indexOf(n)!==-1}},emits:["update:value","update:modelValue","onChange","onSearch","onFocus","onBlur"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElInput");let u=o.isNonEmptyString(t.value)?t.value:"";const r=e.ref(o.isNonEmptyString(t.value)?t.value:"");let c=null,m=null;const p=e.computed(()=>o.isFinite(t.changeDelayTime)&&t.changeDelayTime>=0?t.changeDelayTime:200),f=e.computed(()=>{let H="append";return o.isEmpty(t.location)||(H=t.location==="left"?"prepend":"append"),H}),h=e.computed(()=>{let H={"panel-input-search":!0,"input-search-disabled":t.disabled};const v=o.isEmpty(t.theme)?"icon":t.theme;return H[`input-search-${v}`]=!0,o.getJsonMerge(H,de.getClassNameJson(t.className))}),g=H=>{s("update:value",H),s("update:modelValue",H),s("onChange",H)},y=H=>{s("onSearch",H)},V=H=>{s("onFocus",H)},E=H=>{s("onBlur",H)},B=()=>{c&&(clearTimeout(c),c=null)},T=()=>{m&&(clearTimeout(m),m=null)},D=()=>{B(),T(),u!==r.value&&(u=r.value,g(r.value)),y(r.value)};e.onBeforeUnmount(()=>{B(),T()}),e.watch(()=>t.value,H=>{r.value=o.isNonEmptyString(H)?H:"",u=r.value});const x=H=>{t.disabled||(B(),c=setTimeout(()=>{!t.disabled&&r.value===H&&u!==H&&(u=H,g(H)),c=null},p.value))},O=()=>{t.disabled||(T(),m=setTimeout(()=>{t.disabled||D()},p.value))},w=H=>{t.disabled||V(H)},M=H=>{t.disabled||E(H)},b=()=>{t.disabled||D()},N=()=>{t.disabled||(B(),T(),u="",g(""),y(""))};return a({getValue:()=>r.value,setValue:(H,v)=>{const S=o.isNonEmptyString(H)?H:"";B(),T(),u=S,r.value=S,v&&(s("update:value",S),s("update:modelValue",S))},focus:()=>{d.value?.focus()}}),(H,v)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(h.value)},[e.createVNode(Pe,{ref_key:"refElInput",ref:d,value:r.value,"onUpdate:value":v[0]||(v[0]=S=>r.value=S),theme:"icon",placeholder:n.placeholder,isClean:!0,disabled:n.disabled,onOnChange:x,onOnKeyupEnter:O,onOnFocus:w,onOnBlur:M,onOnClear:N},{[f.value]:e.withCtx(()=>[n.theme==="text"&&!e.unref(o).isEmpty(n.textLabel)?(e.openBlock(),e.createElementBlock("span",{key:0,role:"button","aria-label":n.textLabel,tabindex:n.disabled?-1:0,onClick:b,onKeydown:[e.withKeys(e.withModifiers(b,["prevent"]),["enter"]),e.withKeys(e.withModifiers(b,["prevent"]),["space"])]},e.toDisplayString(n.textLabel),41,Oc)):(e.openBlock(),e.createBlock(ve,{key:1,name:"search",role:"button","aria-label":"搜索",tabindex:n.disabled?-1:0,onClick:b,onKeydown:[e.withKeys(e.withModifiers(b,["prevent"]),["enter"]),e.withKeys(e.withModifiers(b,["prevent"]),["space"])]},null,8,["tabindex","onKeydown"]))]),_:2},1032,["value","placeholder","disabled"])],10,Mc))}}),Ac=["id"],Lc=["name","placeholder","disabled","aria-label"],Vn="100px",Qn=e.defineComponent({name:"ClInputTextarea",__name:"Index",props:{id:{type:String,default:""},name:{type:String,default:""},value:{type:String,default:""},className:{type:String,default:""},disabled:{type:Boolean,default:!1},width:{type:String,default:""},height:{type:String,default:"100px"},placeholder:{type:String,default:""},isClean:{type:Boolean,default:!1},isAutoHeight:{type:Boolean,default:!1},changeDelayTime:{type:Number,default:200},heightMax:{type:String,default:""},isPlaintext:{type:Boolean,default:!1}},emits:["update:value","update:modelValue","onChange","onInit","onKeydownEnter","onKeyupEnter","onFocus","onBlur","onChangeDelay"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElTextarea"),u=e.reactive({height:t.height||Vn}),r=e.ref(o.isString(t.value)?t.value:""),c={lastValue:o.isString(t.value)?t.value:"",prevDelayValue:o.isString(t.value)?t.value:"",valueDelayRun:!1},m=e.computed(()=>{let C=t.name;return o.isEmpty(C)&&(C=`textarea_${o.getRandom(8)}`),C}),p=e.computed(()=>t.isClean&&!t.disabled&&!o.isEmpty(r.value)),f=e.computed(()=>{let C={"panel-input-textarea":!0,"textarea-clean":t.isClean&&!t.isPlaintext};return t.isPlaintext&&(C["cl-plaintext-value"]=!0,C["cl-plaintext-value-pre"]=!0),C=o.getJsonMerge(C,de.getClassNameJson(t.className)),C}),h=e.computed(()=>{const C=r.value;return o.isString(C)?C.replace(/<\/?br\s*\/?>/gi,`
8
- `):""}),g=e.computed(()=>{const{width:C,heightMax:$}=t,k={};return o.isNonEmptyString(C)&&(k.width=C),t.isPlaintext||(o.isEmpty(u.height)||(k.height=u.height),o.isNonEmptyString($)&&(k["max-height"]=$)),k});let y;const V=C=>{y&&(clearTimeout(y),y=null),c.valueDelayRun=!0,y=setTimeout(()=>{c.valueDelayRun=!1,c.prevDelayValue!==C&&(c.prevDelayValue=C,s("onChangeDelay",C))},Math.max(t.changeDelayTime,0))},E=C=>{C!==c.lastValue&&(c.lastValue=C,s("update:value",C),s("update:modelValue",C),s("onChange",C),V(C))},B=()=>{if(t.isAutoHeight){const C=d.value;if(C){C.style.height=t.height||Vn;const $=C.scrollHeight+C.scrollTop+(C.offsetHeight-C.clientHeight);C.style.height="100%",u.height=$>0?`${$}px`:t.height||Vn}}},T=()=>{d.value?.focus()},D=()=>{e.nextTick(()=>{s("onInit")})};e.onMounted(()=>{D()}),e.onBeforeUnmount(()=>{y&&(clearTimeout(y),y=null)}),e.watch(()=>t.value,(C,$)=>{C!==$&&(r.value=o.isString(C)?C:"",c.lastValue=o.isString(C)?C:"",requestAnimationFrame(()=>B()),c.valueDelayRun||(c.prevDelayValue=C||""))});const x=C=>{const $=C.target;if(!$)return;const k=$.value;requestAnimationFrame(()=>B()),E(k)},O=C=>{C.key==="Enter"&&s("onKeydownEnter",C)},w=C=>{C.key==="Enter"&&s("onKeyupEnter",C)},M=()=>{r.value="",E(""),T()},b=()=>{s("onFocus")},N=()=>{s("onBlur")},J=()=>o.trim(r.value);return a({getValue:J,getValueData:()=>({value:J(),show:r.value}),setValue:C=>{y&&(clearTimeout(y),y=null,c.valueDelayRun=!1);const $=o.isEmpty(C)?"":C;c.lastValue=$,c.prevDelayValue=$,r.value=$,B()},initHeight:()=>{u.height=t.height||Vn,t.isAutoHeight&&B()},focus:()=>{T()},getParentElement:()=>d.value?.parentElement||null}),(C,$)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(f.value),style:e.normalizeStyle(g.value)},[n.isPlaintext?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createTextVNode(e.toDisplayString(h.value),1)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.withDirectives(e.createElementVNode("textarea",{ref_key:"refElTextarea",ref:d,class:"form-control text-area","onUpdate:modelValue":$[0]||($[0]=k=>r.value=k),name:m.value,placeholder:n.placeholder,disabled:n.disabled,"aria-label":n.placeholder||"文本输入区域",onInput:x,onKeydown:O,onKeyup:w,onFocus:b,onBlur:N},null,40,Lc),[[e.vModelText,r.value]]),p.value?(e.openBlock(),e.createBlock(ve,{key:0,name:"close-circle-fill",class:"textarea-clear-icon","aria-label":"清除输入内容",onClick:e.withModifiers(M,["stop"])})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))],14,Ac))}}),$c=["id"],Fc=["id","href","target","rel"],Pc=["id","href"],Rc=["id"],Vt=e.defineComponent({name:"ClLink",__name:"Index",props:{id:String,className:{type:String,default:""},disabled:{type:Boolean,default:!1},url:{type:[String,Object],default:""},isHideUnderline:{type:Boolean,default:!1},isLight:{type:Boolean,default:!1},isTargetBlank:{type:Boolean,default:!1},isOutside:{type:Boolean,default:!1},isStopPropagation:{type:Boolean,default:!1},theme:{type:String,default:"link",validator:n=>["link","button"].indexOf(n)!==-1}},emits:{onClick:n=>!0,onHoverIn:n=>!0,onHoverOut:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,l=e.computed(()=>!o.isEmpty(i.url)),d=e.computed(()=>o.isString(i.url)?i.url:(o.isEmpty(i.url)||Se.warn("ClLink","Link 组件:url 为 Router 对象时不应同时使用 isOutside 或 isTargetBlank,请传入 String 类型 url"),"")),u=e.computed(()=>{if(i.theme==="button"){let V={btn:!0,"btn-disabled":i.disabled};const E=["btn-green","btn-red","btn-yellow","btn-white","btn-grayLight","btn-transparent","btn-text"],B=de.getClassNameJson(i.className);return E.some(D=>!!B[D])||(V["btn-default"]=!0),o.getJsonMerge(V,B)}let y={"panel-link":!0,"btn-link":!0,"btn-link-disabled":i.disabled,"always-light":i.isLight,"underline-none":i.isHideUnderline};return y=o.getJsonMerge(y,de.getClassNameJson(i.className)),y}),r=g=>{t("onClick",g)},c=g=>{t("onHoverIn",g)},m=g=>{t("onHoverOut",g)},p=g=>{i.disabled||(r(g),i.isStopPropagation&&(g?.preventDefault(),g?.stopPropagation()))},f=g=>{i.disabled||c(g)},h=g=>{i.disabled||m(g)};return(g,y)=>{const V=e.resolveComponent("router-link");return n.url&&l.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.disabled?(e.openBlock(),e.createElementBlock("span",{key:0,id:e.unref(s),class:e.normalizeClass(u.value),role:"link","aria-disabled":"true"},[e.renderSlot(g.$slots,"default")],10,$c)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n.isOutside?(e.openBlock(),e.createElementBlock("a",{key:0,id:e.unref(s),class:e.normalizeClass(u.value),href:d.value,target:n.isTargetBlank?"_blank":void 0,rel:n.isTargetBlank?"noopener noreferrer":void 0,onClick:p,onMouseenter:f,onMouseleave:h},[e.createElementVNode("span",null,[e.renderSlot(g.$slots,"default")])],42,Fc)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n.isTargetBlank?(e.openBlock(),e.createElementBlock("a",{key:0,id:e.unref(s),class:e.normalizeClass(u.value),href:d.value,target:"_blank",rel:"noopener noreferrer",onClick:e.withModifiers(p,["stop"]),onMouseenter:f,onMouseleave:h},[e.createElementVNode("span",null,[e.renderSlot(g.$slots,"default")])],42,Pc)):(e.openBlock(),e.createBlock(V,{key:1,id:e.unref(s),class:e.normalizeClass(u.value),to:n.url,onClick:e.withModifiers(p,["stop"])},{default:e.withCtx(()=>[e.createElementVNode("span",{onMouseenter:f,onMouseleave:h},[e.renderSlot(g.$slots,"default")],32)]),_:3},8,["id","class","to"]))],64))],64))],64)):(e.openBlock(),e.createElementBlock("a",{key:1,id:e.unref(s),class:e.normalizeClass(u.value),href:"javascript:",onClick:p,onMouseenter:f,onMouseleave:h},[e.createElementVNode("span",null,[e.renderSlot(g.$slots,"default")])],42,Rc))}}}),Hc={class:"loading-content"},zi=e.defineComponent({name:"ClLoadFullCenter",__name:"FullCenter",props:{id:{},className:{},show:{type:Boolean,default:!0},teleportTarget:{},zIndex:{},background:{},theme:{},size:{},color:{}},setup(n){return(a,i)=>(e.openBlock(),e.createBlock(Lt,{show:n.show,id:n.id,zIndex:n.zIndex,teleportTarget:n.teleportTarget||"self",background:n.background||"var(--cl-overlay, rgba(0, 0, 0, 0.5))",duration:0,className:n.className,isLockScroll:!1},{default:e.withCtx(()=>[e.createElementVNode("div",Hc,[e.createVNode(lt,{theme:n.theme,size:n.size,color:n.color},null,8,["theme","size","color"])])]),_:1},8,["show","id","zIndex","teleportTarget","background","className"]))}}),Uc=["id"],zc={key:0,class:"loading-content"},Jc={key:1,class:"loading-nothing"},Zt=e.defineComponent({name:"ClLoadIng",__name:"Ing",props:{id:{},className:{},theme:{},size:{},isLoadIng:{type:Boolean},isEmpty:{type:Boolean},noDataText:{},color:{}},setup(n){const a=n,i=a.id,t=e.computed(()=>o.getJsonMerge({"panel-load-ing":!0},de.getClassNameJson(a.className)));return(s,l)=>n.isLoadIng||n.isEmpty?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(t.value),id:e.unref(i)},[n.isLoadIng?(e.openBlock(),e.createElementBlock("div",zc,[e.createVNode(lt,{theme:n.theme,size:n.size,color:n.color},null,8,["theme","size","color"])])):n.isEmpty?(e.openBlock(),e.createElementBlock("div",Jc,[e.createElementVNode("div",null,[e.renderSlot(s.$slots,"nothingData",{},()=>[e.createElementVNode("span",null,e.toDisplayString(n.noDataText||"暂无数据"),1)])])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))],10,Uc)):e.createCommentVNode("",!0)}}),Kc=["aria-label"],Wc={class:"loadScreen-main"},jc={key:0,class:"loadScreen-text"},ta=e.defineComponent({name:"ClLoadScreen",__name:"Index",props:{id:String,className:String,teleportTarget:{type:String,default:"body"}},setup(n,{expose:a}){const{optA11yText:i}=qn(),s=n.id||`loadscreen-${o.getRandom(5)}`,l=e.ref(!1),d=e.reactive({id:s,text:""});let u=null;const r=p=>{u&&(clearTimeout(u),u=null),u=setTimeout(()=>{l.value=!1,u=null},p)};return e.onBeforeUnmount(()=>{u&&(clearTimeout(u),u=null),l.value=!1}),a({show:(p,f)=>{u&&(clearTimeout(u),u=null),d.id=o.isNonEmptyString(f?.id)?f.id:s,d.text=o.isNonEmptyString(p)?p:"",l.value=!0},hide:(p=0)=>{p>0?r(p):(u&&(clearTimeout(u),u=null),l.value=!1)}}),(p,f)=>(e.openBlock(),e.createBlock(Lt,{id:d.id,show:l.value,teleportTarget:n.teleportTarget,zIndex:1000002,duration:0,isLockScroll:!1,background:"var(--cl-mask, rgba(0, 0, 0, 0.4))",className:n.className},{default:e.withCtx(()=>[e.createElementVNode("div",{class:"loadScreen-container",role:"alert","aria-label":e.unref(i).loading||"加载中"},[e.createElementVNode("div",Wc,[d.text.length>0?(e.openBlock(),e.createElementBlock("span",jc,e.toDisplayString(d.text),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createVNode(lt,{color:"white",size:"large"})])],8,Kc)]),_:1},8,["id","show","teleportTarget","className"]))}}),Yc=["id"],Ji=e.defineComponent({name:"ClLoadWarp",__name:"Warp",props:{id:{},className:{},theme:{},size:{},isLoadIng:{type:Boolean},isEmpty:{type:Boolean},height:{},minHeight:{},noDataText:{},color:{}},setup(n){const a=n,i=a.id,t=e.computed(()=>o.getJsonMerge({"panel-load-warp":!0},de.getClassNameJson(a.className))),s=e.computed(()=>{const l={},{height:d,minHeight:u,isLoadIng:r}=a;return r&&(l["min-height"]="100px"),o.isNonEmptyString(d)?l.height=d:o.isNonEmptyString(u)&&(l["min-height"]=u),l});return(l,d)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(t.value),style:e.normalizeStyle(s.value),id:e.unref(i)},[e.renderSlot(l.$slots,"default"),e.createVNode(Zt,{isLoadIng:n.isLoadIng,isEmpty:n.isEmpty,theme:n.theme,size:n.size,color:n.color,noDataText:n.noDataText},{nothingData:e.withCtx(()=>[e.renderSlot(l.$slots,"nothingData")]),_:3},8,["isLoadIng","isEmpty","theme","size","color","noDataText"])],14,Yc))}}),qc=["a[href]","area[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])","iframe","audio[controls]","video[controls]",'[contenteditable]:not([contenteditable="false"])','[tabindex]:not([tabindex="-1"])'].join(",");function Ja(n){return Array.from(n.querySelectorAll(qc)).filter(a=>!(a.hasAttribute("disabled")||a.getAttribute("aria-hidden")==="true"||a.offsetParent===null&&getComputedStyle(a).position!=="fixed"))}function Xc(n,a,i={}){let t=null;const s=()=>n.value??null,l=r=>{if(!a.value)return;const c=s();if(!c)return;if(r.key==="Escape"){if(i.isEscapeClose&&!i.isEscapeClose()||!i.onEscape)return;r.stopPropagation(),i.onEscape();return}if(r.key!=="Tab")return;const m=Ja(c);if(m.length===0){r.preventDefault(),c.focus();return}const p=m[0],f=m[m.length-1],h=document.activeElement;if(!(h?c.contains(h):!1)){r.preventDefault(),(r.shiftKey?f:p).focus();return}r.shiftKey&&h===p?(r.preventDefault(),f.focus()):!r.shiftKey&&h===f&&(r.preventDefault(),p.focus())},d=()=>{t=document.activeElement,document.addEventListener("keydown",l,!0),i.isAutoFocus!==!1&&requestAnimationFrame(()=>{const r=s();if(!r)return;const c=Ja(r);c.length>0?c[0].focus():r.focus()})},u=()=>{document.removeEventListener("keydown",l,!0);const r=t;t=null,r&&requestAnimationFrame(()=>{r.isConnected&&r.focus()})};e.watch(a,r=>{r?d():u()},{immediate:!0}),e.onBeforeUnmount(()=>{document.removeEventListener("keydown",l,!0)})}const Gc=["id"],Qc={class:"modal-content"},Ki=e.defineComponent({name:"ClModalTransition",__name:"BaseTransition",props:{id:String,className:String,isBackClick:{type:Boolean,default:!0},width:{type:String,default:"600px"},classTransitionEnter:{type:String,default:"animated fadeInDown"},classTransitionLeave:{type:String,default:"animated fadeOutUp"},teleportTarget:{type:String,default:""},isEscapeClose:{type:Boolean,default:!0},isFocusTrap:{type:Boolean,default:!0}},emits:{onClickBack:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=new Map;let d=!1;const u=new Map,r=e.useTemplateRef("refElParent"),c=e.useTemplateRef("refElDialog"),m=e.reactive({isShow:!1}),p=e.computed(()=>o.getJsonMerge({"panel-modal":!0},de.getClassNameJson(t.className))),f=e.computed(()=>({modal:!0,fade:!0,show:m.isShow})),h=e.computed(()=>{const b={};return o.isEmpty(t.width)||(b.width=t.width),b}),g=()=>{s("onClickBack")},y=b=>{const N=l.get(b)??0;l.set(b,N+1),!(N>0||/\bmodal-open\b/.test(b.className))&&(u.set(b,b===document.body?{x:window.scrollX,y:window.scrollY}:{x:b.scrollLeft,y:b.scrollTop}),b.className+=" modal-open",b===document.body&&(d=!0))},V=b=>{const N=l.get(b)??0;if(!(N<=0))if(N===1){l.delete(b),b===document.body?d&&(b.className=b.className.replace(/\bmodal-open\b/g,"").trim(),d=!1):b.className=b.className.replace(/\bmodal-open\b/g,"").trim();const J=u.get(b);J&&(u.delete(b),requestAnimationFrame(()=>{b===document.body?window.scrollTo(J.x,J.y):(b.scrollTop=J.y,b.scrollLeft=J.x)}))}else l.set(b,N-1)},E=()=>{const b=t.teleportTarget;if(o.isEmpty(b)||b==="body")return document.body;if(b==="self"){const J=r.value?r.value.parentElement:null;if(!J)return null;let q=J;for(;q&&q!==document.body;){if(window.getComputedStyle(q).position!=="static")return q;q=q.parentElement}return document.body}const N=document.querySelector(b);return N===document.body?document.body:N??document.body},B=()=>{if(m.isShow){const b=E();b&&y(b)}else{const b=E();b&&V(b)}},T=()=>{m.isShow=!1};Xc(c,e.computed(()=>t.isFocusTrap&&m.isShow),{onEscape:()=>{t.isEscapeClose&&T()},isEscapeClose:()=>t.isEscapeClose}),e.onBeforeUnmount(()=>{m.isShow&&B()}),e.watch(()=>m.isShow,()=>{B()});const D=b=>{t.isBackClick&&b.currentTarget===b.target&&(T(),g())},x=()=>{},O=()=>{};return a({show:()=>{m.isShow=!0},hide:()=>{T()}}),(b,N)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(p.value),id:n.id,ref_key:"refElParent",ref:r},[e.createVNode(e.Transition,{"enter-active-class":n.classTransitionEnter,"leave-active-class":n.classTransitionLeave,onEnter:x,onAfterLeave:O},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{class:e.normalizeClass(f.value),role:"dialog","aria-modal":"true",tabindex:"-1",ref_key:"refElDialog",ref:c},[e.createElementVNode("div",{class:"modal-wrapper",onClick:D},[e.createElementVNode("div",{class:"modal-dialog",style:e.normalizeStyle(h.value)},[e.createElementVNode("div",Qc,[e.renderSlot(b.$slots,"default")])],4)])],2),[[e.vShow,m.isShow]])]),_:3},8,["enter-active-class","leave-active-class"]),e.createVNode(Lt,{show:m.isShow,zIndex:999999,isLockScroll:!1,background:"var(--cl-mask, rgba(0, 0, 0, 0.3))",duration:150,teleportTarget:n.teleportTarget},null,8,["show","teleportTarget"])],10,Gc))}}),Zc={key:0,class:"modal-header"},eu={class:"modal-title"},tu={class:"modal-body"},nu={key:2,class:"modal-footer"},ou={key:3,class:"modal-footer-hide"},na=e.defineComponent({name:"ClModal",__name:"Index",props:{id:String,className:String,posSubmitClose:{type:String,default:"CloseSubmit",validator:n=>["CloseSubmit","SubmitClose"].indexOf(n)!==-1},width:{type:String,default:"600px"},titleName:String,isBackClick:{type:Boolean,default:!0},isShowHeader:{type:Boolean,default:!0},isShowFooter:{type:Boolean,default:!0},isShowSubmit:{type:Boolean,default:!0},isShowSubmitLoad:{type:Boolean,default:!0},closeLabel:String,submitLabel:String,classTransitionEnter:{type:String,default:"animated fadeInDown"},classTransitionLeave:{type:String,default:"animated fadeOutUp"},teleportTarget:{type:String,default:""}},emits:{onSubmit:()=>!0,onClose:()=>!0},setup(n,{expose:a,emit:i}){const t=n,{optLocale:s}=Le(),l=(O,w)=>{s.value;const M=nt.getValue(`common.${O}`);return typeof M=="string"&&M.length>0?M:w},d=e.computed(()=>t.closeLabel||l("cancel","取消")),u=e.computed(()=>t.submitLabel||l("submit","提交")),r=i,c=e.useTemplateRef("refElTransition"),m=e.useTemplateRef("refElBtnSubmit"),p=e.reactive({isLoadBackClick:!0,disabledSubmit:!1}),f=()=>{r("onSubmit")},h=()=>{r("onClose")},g=()=>{c.value&&c.value.hide()},y=()=>{t.isShowSubmitLoad&&(p.isLoadBackClick=!1),f()},V=()=>{g(),h()},E=()=>{h()},B=()=>{D(),p.disabledSubmit=!1,c.value&&c.value.show()},T=()=>{p.isLoadBackClick=!0,t.isShowSubmitLoad&&m.value&&m.value.loadStop(),g()},D=()=>{p.isLoadBackClick=!0,t.isShowSubmitLoad&&m.value&&m.value.loadStop()};return a({show:B,hide:T,loadStop:D,disabledSubmit:O=>{const w=o.isBoolean(O)?O:!0;p.disabledSubmit=w}}),(O,w)=>(e.openBlock(),e.createBlock(Ki,{id:n.id,className:n.className,isBackClick:n.isBackClick&&p.isLoadBackClick,classTransitionEnter:n.classTransitionEnter,classTransitionLeave:n.classTransitionLeave,width:n.width,teleportTarget:n.teleportTarget,onOnClickBack:E,ref_key:"refElTransition",ref:c},{default:e.withCtx(()=>[n.isShowHeader?(e.openBlock(),e.createElementBlock("div",Zc,[e.createElementVNode("h4",eu,e.toDisplayString(n.titleName),1),e.createElementVNode("button",{type:"button",class:"close","aria-label":"关闭",onClick:V},[e.createVNode(ve,{name:"close"})])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",tu,[e.renderSlot(O.$slots,"default")]),n.isShowFooter?(e.openBlock(),e.createElementBlock("div",nu,[n.posSubmitClose==="CloseSubmit"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(Qe,{label:d.value,color:"grayLight",onOnClick:V},null,8,["label"]),n.isShowSubmit?(e.openBlock(),e.createBlock(Qe,{key:0,ref_key:"refElBtnSubmit",ref:m,disabled:p.disabledSubmit,isShowLoad:n.isShowSubmitLoad,loadColor:"var(--cl-bg, #ffffff)",isShowBackDrop:!0,label:u.value,onOnClick:y},null,8,["disabled","isShowLoad","label"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64)):n.posSubmitClose==="SubmitClose"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n.isShowSubmit?(e.openBlock(),e.createBlock(Qe,{key:0,ref_key:"refElBtnSubmit",ref:m,disabled:p.disabledSubmit,isShowLoad:n.isShowSubmitLoad,loadColor:"var(--cl-bg, #ffffff)",isShowBackDrop:!0,label:u.value,onOnClick:y},null,8,["disabled","isShowLoad","label"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createVNode(Qe,{label:d.value,color:"grayLight",onOnClick:V},null,8,["label"])],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))])):(e.openBlock(),e.createElementBlock("div",ou))]),_:3},8,["id","className","isBackClick","classTransitionEnter","classTransitionLeave","width","teleportTarget"]))}}),au=["id"],Wi=e.defineComponent({name:"ClNumberRoll",__name:"Index",props:{id:String,value:[String,Number],className:String,decimal:{type:Number,default:0},isThousand:{type:Boolean,default:!0},separator:{type:String,default:","},animationTime:{type:Number,default:.5}},setup(n){const a=n,i=a.id,t=e.ref("");let s=null;const l=e.computed(()=>{const c={"panel-number-roll":!0};return o.getJsonMerge(c,de.getClassNameJson(a.className))}),d=c=>{const m=Math.max(0,Math.min(100,a.decimal)),p=a.separator,f=a.isThousand,g=c.toFixed(m).split(".");return f&&(g[0]=g[0].replace(/\B(?=(\d{3})+(?!\d))/g,()=>p)),g.join(".")},u=(c,m,p)=>{if(s!==null&&(cancelAnimationFrame(s),s=null),c===m){t.value=d(m);return}const f=performance.now(),h=p*1e3,g=y=>{const V=Math.min((y-f)/h,1),E=V===1?1:1-Math.pow(2,-10*V);t.value=d(c+(m-c)*E),V<1?s=requestAnimationFrame(g):s=null};s=requestAnimationFrame(g)},r=(c,m)=>{const p=a.animationTime,f=g=>{if(g==null||g==="")return 0;const y=Number(g);return o.isFinite(y)?y:0},h=f(c);if(p>0){const g=f(m);u(g,h,p)}else t.value=d(h)};return e.onMounted(()=>{e.nextTick(()=>{r(a.value)})}),e.onActivated(()=>{}),e.onDeactivated(()=>{s!==null&&(cancelAnimationFrame(s),s=null);const c=m=>{if(m==null||m==="")return 0;const p=Number(m);return o.isFinite(p)?p:0};t.value=d(c(a.value))}),e.onBeforeUnmount(()=>{s!==null&&(cancelAnimationFrame(s),s=null)}),e.watch(()=>a.value,(c,m)=>{c!==m&&r(c,m)}),(c,m)=>(e.openBlock(),e.createElementBlock("span",{id:e.unref(i),class:e.normalizeClass(l.value)},e.toDisplayString(t.value),11,au))}}),iu=["id"],su={key:0,class:"progress"},lu=["aria-valuenow"],ru=["aria-valuenow"],cu={class:"progress-circular-line circular-line-left"},ji=e.defineComponent({name:"ClProgress",__name:"Index",props:{id:String,className:String,ratio:{type:[Number,String],required:!0},theme:{type:String,default:"horizontal",validator:n=>["horizontal","circular"].includes(n)},color:String,isShowNum:{type:Boolean,default:!0},isAnimation:{type:Boolean,default:!0},diameter:{type:String,default:"50px"},showNumText:String,showNumPos:{type:String,default:"out-center"},showNumTrigger:{type:String,default:"hover"},showNumColor:String},setup(n){const a=n,i=a.id,t=e.useTemplateRef("refElTopParent"),s=e.useTemplateRef("refElBar"),l=e.reactive({isHorizontal:a.theme==="horizontal",isCircular:a.theme==="circular",ratioHundred:"0%",circularLeftRotate:-45,circularLeftTime:0,circularRightRotate:-45,circularRightTime:0,posText:{inOut:"out",lcr:"center",isOverflow:!1}}),d={lastRatio:"",lastRotateLeft:-45,lastRotateRight:-45,runTimeCircularRotate:null,_initVersion:0,_resizeTimer:null,resizeEvent:null},u=e.computed(()=>{let B="";const{showNumText:T}=a;if(o.isNonEmptyString(T))B=T;else{let D=l.ratioHundred;D=D.substring(0,D.length-1),B=o.getFormatThousands(D)+"%"}return B}),r=e.computed(()=>{const B={"panel-progress":!0};B[`progress-${a.theme}`]=!0;const{className:T,isShowNum:D,showNumTrigger:x}=a;return D&&x!=="none"&&(B[`progress-${x}-num`]=!0),Object.assign(B,de.getClassNameJson(T)),B}),c=e.computed(()=>({"progress-bar":!0,"progress-bar-striped":a.isAnimation,"striped-animation":a.isAnimation})),m=e.computed(()=>{const B={};return l.isCircular&&(o.isEmpty(a.diameter)||(B.width=a.diameter,B.height=a.diameter)),B}),p=e.computed(()=>{const B={};if(B.width=l.ratioHundred,o.isEmpty(a.color)||(B["background-color"]=a.color),l.isHorizontal&&l.posText.inOut==="in"){let T="center";switch(l.posText.lcr){case"left":T="flex-start";break;case"center":T="center";break;case"right":T="flex-end";break;default:T="center";break}l.posText.isOverflow&&(T="flex-start"),B["justify-content"]=T}return B}),f=e.computed(()=>{const B={},{showNumColor:T}=a;if(o.isNonEmptyString(T)&&(B.color=T),l.isHorizontal&&l.posText.inOut==="out")switch(l.posText.lcr){case"left":B.left="0";break;case"center":break;case"right":B.right="0";break}return B}),h=e.computed(()=>{const B={};return B.transform=`rotate(${l.circularRightRotate}deg)`,l.circularRightTime>0&&(B["transition-duration"]=`${l.circularRightTime}ms`),o.isEmpty(a.color)||(B["border-bottom-color"]=a.color,B["border-right-color"]=a.color),B}),g=e.computed(()=>{const B={};return B.transform=`rotate(${l.circularLeftRotate}deg)`,l.circularLeftTime>0&&(B["transition-duration"]=`${l.circularLeftTime}ms`),o.isEmpty(a.color)||(B["border-bottom-color"]=a.color,B["border-right-color"]=a.color),B}),y=()=>{const{showNumPos:B}=a;if(o.isEmpty(B))return;const T=B.split("-");T.length===2?(l.posText.inOut=o.isExistValue(["in","out"],T[0])?T[0]:"out",l.posText.lcr=o.isExistValue(["left","center","right"],T[1])?T[1]:"center"):Se.warn("ClProgress",'showNumPos 格式无效,期望 "in/out-left/center/right",实际传入',B)},V=B=>{let T=o.isEmpty(B)?0:Number(B);if(o.isNaN(T)&&(T=0),T<=0?T=0:T>=100&&(T=100),l.ratioHundred=`${T}%`,l.isCircular){d.runTimeCircularRotate&&clearTimeout(d.runTimeCircularRotate);const D=T/100*360;let x=0,O=0;D<180?(x=D+-45,O=-45):(x=135,O=D-180-45);let w=!0;o.isEmpty(d.lastRatio)||(w=T>=Number(d.lastRatio));let b=0,N=0;const J=Math.abs(x-d.lastRotateRight),q=Math.abs(O-d.lastRotateLeft);if(J>0||q>0){const v=400/(J+q);b=J*v,N=q*v}const z=++d._initVersion;w?(l.circularRightRotate=x,l.circularRightTime=b,e.nextTick(()=>{z===d._initVersion&&(d.runTimeCircularRotate=setTimeout(()=>{l.circularLeftRotate=O,l.circularLeftTime=N},b))})):(l.circularLeftRotate=O,l.circularLeftTime=N,e.nextTick(()=>{z===d._initVersion&&(d.runTimeCircularRotate=setTimeout(()=>{l.circularRightRotate=x,l.circularRightTime=b},N))})),d.lastRotateRight=x,d.lastRotateLeft=O}d.lastRatio=String(T)},E=()=>{y(),V(a.ratio),s.value&&(d.resizeEvent=new ht({element:s.value,callback:()=>{d._resizeTimer&&clearTimeout(d._resizeTimer),d._resizeTimer=setTimeout(()=>{if(a.isShowNum&&l.isHorizontal&&l.posText.inOut==="in"&&t.value){const B=t.value.querySelector(".progress-bar"),T=t.value.querySelector(".progress-num");if(B&&T){const D=B.clientWidth,x=T.clientWidth;let O=!1;D===0&&x===0?O=!1:D===0&&x>0?O=!0:O=D>0&&x>D,l.posText.isOverflow=O}}},150)}}))};return e.onMounted(()=>{e.nextTick(()=>{E()})}),e.onUnmounted(()=>{d._resizeTimer&&clearTimeout(d._resizeTimer),d.runTimeCircularRotate&&clearTimeout(d.runTimeCircularRotate),d.resizeEvent&&d.resizeEvent.destroy()}),e.watch(()=>a.ratio,(B,T)=>{B!==T&&V(B)}),(B,T)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"refElTopParent",ref:t,id:e.unref(i),class:e.normalizeClass(r.value),style:e.normalizeStyle(m.value)},[l.isHorizontal?(e.openBlock(),e.createElementBlock("div",su,[e.createElementVNode("div",{ref_key:"refElBar",ref:s,class:e.normalizeClass(c.value),style:e.normalizeStyle(p.value),role:"progressbar","aria-valuenow":Number(l.ratioHundred.replace("%","")),"aria-valuemin":"0","aria-valuemax":"100"},[n.isShowNum&&l.posText.inOut==="in"?(e.openBlock(),e.createElementBlock("span",{key:0,class:"progress-num",style:e.normalizeStyle(f.value)},e.toDisplayString(u.value),5)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],14,lu)])):l.isCircular?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",{class:"progress-circular-line circular-line-right",role:"progressbar","aria-valuenow":Number(l.ratioHundred.replace("%","")),"aria-valuemin":"0","aria-valuemax":"100"},[e.createElementVNode("div",{class:"progress-circular-bar",style:e.normalizeStyle(h.value)},null,4)],8,ru),e.createElementVNode("div",cu,[e.createElementVNode("div",{class:"progress-circular-bar",style:e.normalizeStyle(g.value)},null,4)])],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64)),n.isShowNum&&l.posText.inOut==="out"?(e.openBlock(),e.createElementBlock("span",{key:3,class:"progress-num",style:e.normalizeStyle(f.value)},e.toDisplayString(u.value),5)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64))],14,iu))}}),uu=["id"],du={key:0,class:"cl-plaintext-value"},mu=["id","name","value","disabled","checked","onClick"],pu=["for"],fu={key:0},oa=e.defineComponent({name:"ClRadio",directives:{cltooltip:ct},__name:"Index",props:{id:String,name:{type:String,required:!0},value:{type:[String,Number],required:!0},className:String,disabled:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},width:String,isInline:{type:Boolean,default:!0},tipMode:{type:String,default:"tooltip",validator:n=>["tooltip","clickCallback"].includes(n)},checkChangeBefore:{type:Function,default:void 0},isPlaintext:{type:Boolean,default:!1}},emits:["update:value","update:modelValue","onChange","onInit","onError","onTipClick"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=`rd-${o.getRandom(8)}`,d=o.isEmpty(t.name)?l+"_name":t.name,u=t.id,r=e.ref(t.value?.toString()||"");let c={};const m=e.ref(0),p=e.ref(!1),f={isProcessing:!1,_initEmitted:!1},h=e.computed(()=>t.isPlaintext?[]:t.list),g=e.computed(()=>{t.list,m.value;const S=r.value;if(o.isEmpty(S))return"";const C=o.isExistJsonKey(c,S)?c[S]:void 0;return C&&o.isNonEmptyString(C.name)?C.name:S}),y=e.computed(()=>o.getJsonMerge({"panel-radio":!0},de.getClassNameJson(t.className))),V=e.computed(()=>{const S={radio:!0,"radio-default":!0};return S["radio-inline"]=t.isInline??!0,S}),E=S=>{s("update:value",S),s("update:modelValue",S)},B=S=>{const C=S.id?.toString()??"";E(C),s("onChange",C,o.getJsonClone(S))},T=()=>{f._initEmitted||(f._initEmitted=!0,e.nextTick(()=>{s("onInit")}))},D=S=>{const C={},{width:$}=t;return S&&!o.isEmpty(S.width)?C.width=S.width:o.isEmpty($)||(C.width=t.width),C},x=()=>o.isExistJsonKey(c,r.value)?r.value:"",O=S=>{c=o.isEmpty(S)?{}:o.getJsonByList(S),m.value+=1},w=()=>{if(p.value){const S=o.isEmpty(r.value)?"":r.value;o.isExistJsonKey(c,S)||(r.value="",E(""))}},M=S=>{S!==r.value&&(r.value=S?.toString()||"")},b=()=>{p.value=t.list.length!==0,O(t.list),w()};e.onMounted(()=>{e.nextTick(()=>{b()})}),e.onBeforeUnmount(()=>{c={},p.value=!1,f._initEmitted=!1}),e.watch(p,S=>{S&&T()}),e.watch(()=>t.list,S=>{p.value||(p.value=!0,S.length===0&&w(),T())},{deep:!0}),e.watch([()=>t.value,()=>t.list],([S,C])=>{const $=C||[];!p.value&&$.length>0&&(p.value=!0,T()),O($),M(S),w()},{deep:!0});const N=S=>{s("onTipClick",S)},J=async S=>{if(!(!S||S.isDisabled||t.disabled||f.isProcessing)&&!o.isEmpty(S.id)){f.isProcessing=!0;try{const C=String(S.id??"");if(C===r.value)return;let $=!0;if(t.checkChangeBefore)try{$=await t.checkChangeBefore(C),$=o.isBoolean($)?$:!0}catch{$=!1}if(t.disabled||S.isDisabled)return;$&&(r.value=C,B(S))}catch(C){s("onError",C)}finally{f.isProcessing=!1}}},q=()=>x();return a({getValue:q,getValueData:()=>{const S=q();return o.isExistJsonKey(c,S)?o.getJsonClone(c[S]):{}},setValue:S=>{f.isProcessing||(M(S),w())},runInitComplete:()=>{p.value||(p.value=!0,O(t.list),M(t.value),w(),T())}}),(S,C)=>{const $=e.resolveDirective("cltooltip");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(y.value),id:e.unref(u)},[n.isPlaintext?(e.openBlock(),e.createElementBlock("div",du,e.toDisplayString(g.value),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(k,I)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${l}-${k.id??""}-${I}`},[k&&(k.isShow||k.isShow===void 0)?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(V.value),style:e.normalizeStyle(D(k))},[e.createElementVNode("span",null,[e.createElementVNode("span",null,[e.createElementVNode("input",{type:"radio",id:`${l}_${e.unref(d)}_${k.id??""}`,name:e.unref(d),value:k.id??"",disabled:k.isDisabled||n.disabled,checked:(k.id?.toString()??"")===r.value,onClick:L=>J(k)},null,8,mu),e.createElementVNode("label",{for:`${l}_${e.unref(d)}_${k.id??""}`},[e.renderSlot(S.$slots,"default",{data:k},()=>[k.icon&&k.icon.length>0?e.withDirectives((e.openBlock(),e.createElementBlock("span",fu,[e.createVNode(ve,{name:k.icon},null,8,["name"])])),[[$,{html:k.name,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(k.name),1)],64))])],8,pu)]),k.tipMsg&&k.tipMsg.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.tipMode==="tooltip"?e.withDirectives((e.openBlock(),e.createBlock(ve,{key:0,name:e.unref(o).isNonEmptyString(k.tipIcon)?void 0:"question-circle",className:e.unref(o).isNonEmptyString(k.tipIcon)?k.tipIcon:void 0,class:"radio-icon-tip"},null,8,["name","className"])),[[$,{html:k.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createBlock(ve,{key:1,name:e.unref(o).isNonEmptyString(k.tipIcon)?void 0:"question-circle",className:e.unref(o).isNonEmptyString(k.tipIcon)?k.tipIcon:void 0,class:"radio-icon-tip",onClick:e.withModifiers(L=>N(k),["stop"])},null,8,["name","className","onClick"]))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])],6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))),128))],10,uu)}}}),hu=["id"],gu=["id","name","checked","disabled"],yu=["for"],vu={key:0},aa=e.defineComponent({name:"ClRadioOne",directives:{cltooltip:ct},__name:"One",props:{id:{type:String,default:""},name:{type:String,default:""},value:{type:Boolean,default:!1},className:{type:String,default:""},disabled:{type:Boolean,default:!1},forId:{type:String,default:""},label:{type:String,default:""},icon:{type:String,default:""},tipMsg:{type:String,default:""},tipIcon:{type:String,default:""},tipMode:{type:String,default:"tooltip",validator:n=>["tooltip","clickCallback"].includes(n)}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:n=>!0,onTipClick:()=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,l=e.computed(()=>o.isEmpty(i.forId)?`rd_${i.name||""}_${o.getRandom(8)}`:i.forId),d=e.computed(()=>{const m={"panel-radio-one":!0,radio:!0,"radio-default":!0,"radio-inline":!0};return o.getJsonMerge(m,de.getClassNameJson(i.className))}),u=m=>{t("update:value",m),t("update:modelValue",m),t("onChange",m)},r=()=>{t("onTipClick")},c=m=>{const p=m.currentTarget;p&&p.checked&&u(!0)};return(m,p)=>{const f=e.resolveDirective("cltooltip");return e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(d.value),id:e.unref(s)},[e.createElementVNode("span",null,[e.createElementVNode("span",null,[e.createElementVNode("input",{type:"radio",id:l.value,name:n.name,checked:n.value,disabled:n.disabled,onClick:c},null,8,gu),e.createElementVNode("label",{for:l.value},[n.icon&&n.icon.length>0?e.withDirectives((e.openBlock(),e.createElementBlock("span",vu,[e.createVNode(ve,{name:n.icon},null,8,["name"])])),[[f,{html:n.label,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(n.label),1)],64))],8,yu)]),n.tipMsg&&n.tipMsg.length>0?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.tipMode==="tooltip"?e.withDirectives((e.openBlock(),e.createBlock(ve,{key:0,name:e.unref(o).isNonEmptyString(i.tipIcon)?void 0:"question-circle",className:e.unref(o).isNonEmptyString(i.tipIcon)?i.tipIcon:void 0,class:"radio-icon-tip"},null,8,["name","className"])),[[f,{html:n.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createBlock(ve,{key:1,name:e.unref(o).isNonEmptyString(i.tipIcon)?void 0:"question-circle",className:e.unref(o).isNonEmptyString(i.tipIcon)?i.tipIcon:void 0,class:"radio-icon-tip",onClick:e.withModifiers(r,["stop"])},null,8,["name","className"]))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])],10,hu)}}}),ku=["id"],Su=e.defineComponent({name:"ClSliderBar",__name:"Bar",props:{id:String,className:String,left:{type:Number,default:0},width:{type:Number,default:0},disabled:{type:Boolean,default:!1},isVertical:{type:Boolean,default:!1},isBarDrag:{type:Boolean,default:!1}},emits:{onMoveStart:()=>!0,onMoveIng:n=>!0,onMoveEnd:()=>!0,onMouseover:()=>!0,onMouseout:()=>!0,onClick:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=e.inject("$SliderTop"),l=e.useTemplateRef("refElBar"),d=i.id,u=e.reactive({left:i.left}),r=e.reactive({isClick:!1,isDragging:!1,dragStart:0,dragStartRatio:0}),c=e.ref(null),m=e.computed(()=>{let T={"slider-bar":!0,"slider-bar-drag":i.isBarDrag};return T=o.getJsonMerge(T,de.getClassNameJson(i.className)),T}),p=e.computed(()=>{const T={};return i.isVertical?(T.bottom=`${u.left}%`,T.height=`${i.width}%`):(T.left=`${u.left}%`,T.width=`${i.width}%`),T}),f=(T,D)=>{D&&(r.isClick=!0,r.isDragging=!1,r.dragStart=i.isVertical?D.clientY:D.clientX,r.dragStartRatio=i.left,t("onMoveStart"))},h=(T,D)=>{if(!s||!D)return;r.isClick=!1,r.isDragging=!0;let x=0;i.isVertical?x=r.dragStart-D.clientY:x=D.clientX-r.dragStart;const O=s.getDragValueInfo(x,r.dragStartRatio);u.left=O.ratio,t("onMoveIng",O.ratio)},g=T=>{r.isClick?t("onClick",T):t("onMoveEnd"),r.isClick=!1,r.isDragging=!1},y=()=>{if(!l.value)return;const T={start(D,x){let O=!1;return!i.disabled&&i.isBarDrag&&D.buttons===1&&(O=!0,f(D,x)),O},ing:(D,x)=>{h(D,x)},end:D=>{g(D)}};c.value=new bt(l.value,T)};e.onMounted(()=>{e.nextTick(()=>{y()})}),e.onBeforeUnmount(()=>{c.value&&(c.value.end(),c.value=null)}),e.watch(()=>i.left,(T,D)=>{T!==D&&T!==u.left&&(u.left=T)});const V=T=>{!i.disabled&&!i.isBarDrag&&t("onClick",T)},E=()=>{t("onMouseover")},B=()=>{r.isDragging||t("onMouseout")};return(T,D)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"refElBar",ref:l,id:e.unref(d),class:e.normalizeClass(m.value),style:e.normalizeStyle(p.value),onMouseover:E,onMouseout:B,onClick:V},null,46,ku))}}),wu=["id"],No=e.defineComponent({name:"ClSliderButton",__name:"Button",props:{id:String,value:[String,Number],className:String,ratio:{type:Number,default:0},disabled:{type:Boolean,default:!1},isVertical:{type:Boolean,default:!1},tooltipFormat:String},emits:{onMoveIng:n=>!0,onMoveEnd:n=>!0,onDblClick:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.inject("$SliderTop"),d=ct,u=e.useTemplateRef("refElButton"),r=t.id,c=e.reactive({isHover:!1,ratio:t.ratio,value:t.value}),m=e.reactive({dragStart:0,dragStartRatio:0,isMoveIng:!1}),p=e.ref(null),f=e.computed(()=>{let v=c.value;if(v!=null){const S=t.tooltipFormat;v=o.getFormatThousands(v.toString()),o.isNonEmptyString(S)&&(v=o.convertStringFormat(S,{_value:v}))}return v??""}),h=e.computed(()=>t.isVertical?"right":"top"),g=e.computed(()=>{let v={"slider-button":!0,hover:c.isHover};return v=o.getJsonMerge(v,de.getClassNameJson(t.className)),v}),y=e.computed(()=>{const v={},S=c.ratio;return t.isVertical?v.bottom=`${o.isFinite(S)?S:0}%`:v.left=`${o.isFinite(S)?S:0}%`,v}),V=()=>{u.value&&Po.show(u.value)},E=()=>{u.value&&Po.hide(u.value)},B=(v,S)=>{if(!l||!S)return{ratio:c.ratio,value:c.value};let C=0;t.isVertical?C=m.dragStart-S.clientY:C=S.clientX-m.dragStart;const $=l.getDragValueInfo(C,m.dragStartRatio);return c.ratio=$.ratio,c.value=$.value,$},T=(v,S)=>{S&&(m.dragStart=t.isVertical?S.clientY:S.clientX,m.dragStartRatio=t.ratio)},D=(v,S)=>{const C=B(v,S);V(),s("onMoveIng",{value:C.ratio,runType:"drag"})},x=(v,S)=>{B(v,S),c.isHover||u.value===v.target||u.value?.contains(v.target)||E(),s("onMoveEnd",{runType:"drag"})},O=v=>{if(!l)return;m.isMoveIng=!0;const S=l.getButtonMoveValueInfo(v,t.ratio);c.ratio=S.ratio,c.value=S.value,s("onMoveIng",{value:S.ratio,runType:"keydown"})},w=()=>{if(!u.value)return;const v={start(S,C){let $=!1;return!t.disabled&&S.buttons===1&&($=!0,T(S,C)),$},ing:(S,C)=>{D(S,C)},end:(S,C)=>{x(S,C)}};p.value=new bt(u.value,v)};e.onMounted(()=>{e.nextTick(()=>{w()})}),e.onBeforeUnmount(()=>{p.value&&(p.value.end(),p.value=null),m.isMoveIng=!1}),e.watch(()=>t.value,(v,S)=>{v!==S&&v!==c.value&&(c.value=v)}),e.watch(()=>t.ratio,(v,S)=>{v!==S&&v!==c.ratio&&(c.ratio=v)});const M=v=>{t.disabled||(v.preventDefault(),v.stopPropagation(),O("left"))},b=v=>{t.disabled||(v.preventDefault(),v.stopPropagation(),O("right"))},N=()=>{t.disabled||(c.isHover=!0)},J=()=>{t.disabled||(c.isHover=!1,m.isMoveIng&&(m.isMoveIng=!1,s("onMoveEnd",{runType:"keydown"})))},q=()=>{t.disabled||s("onDblClick")};return a({showTooltip:()=>{V()},hideTooltip:()=>{E()}}),(v,S)=>e.withDirectives((e.openBlock(),e.createElementBlock("div",{ref_key:"refElButton",ref:u,id:e.unref(r),class:e.normalizeClass(g.value),style:e.normalizeStyle(y.value),tabindex:"0",onDblclick:q,onFocus:N,onBlur:J,onKeydown:[e.withKeys(M,["down"]),e.withKeys(b,["up"]),e.withKeys(M,["left"]),e.withKeys(b,["right"])]},[...S[0]||(S[0]=[e.createElementVNode("div",{class:"slider-button-icon"},null,-1)])],46,wu)),[[e.unref(d),{trigger:["hover","focus"],position:h.value,html:f.value,updRefreshInx:c.ratio},void 0,{black:!0}]])}}),Eu=["id"],bu=e.defineComponent({name:"ClSliderDot",__name:"Dot",props:{id:String,className:String,itemInfo:{type:Object,default:()=>({})},isHover:{type:Boolean,default:!1},isVertical:{type:Boolean,default:!1},isTooltip:{type:Boolean,default:!0},tooltipFormat:String},emits:{onMouseover:()=>!0,onMouseout:()=>!0,onClick:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,l=ct,d=e.computed(()=>i.isVertical?"right":"top"),u=e.computed(()=>{const h=i.itemInfo.value;if(h!=null){let g=o.getFormatThousands(h.toString());const y=i.tooltipFormat;return o.isNonEmptyString(y)&&(g=o.convertStringFormat(y,{_value:g})),g}return""}),r=e.computed(()=>{let h={"slider-dot":!0,"slider-dot-active":i.itemInfo.isActive??!1,"slider-dot-hide":i.itemInfo.isHide??!1,hover:i.isHover};return h=o.getJsonMerge(h,de.getClassNameJson(i.className)),h}),c=e.computed(()=>{const h={},g=i.itemInfo.ratio;return g!=null&&(i.isVertical?h.bottom=`${g}%`:h.left=`${g}%`),h}),m=()=>{t("onMouseover")},p=()=>{t("onMouseout")},f=()=>{t("onClick")};return(h,g)=>e.withDirectives((e.openBlock(),e.createElementBlock("div",{id:e.unref(s),class:e.normalizeClass(r.value),style:e.normalizeStyle(c.value),onMouseover:m,onMouseout:p,onClick:f},[...g[0]||(g[0]=[e.createElementVNode("div",{class:"slider-dot-icon"},null,-1)])],46,Eu)),[[e.unref(l),{init:n.isTooltip,position:d.value,html:u.value},void 0,{black:!0,hover:!0}]])}}),Cu=["id"],xu=["id"],Bu={class:"slider-container"},Du={key:2,class:"slider-dots"},Iu={key:0,class:"slider-marks"},Tu=["innerHTML","onMouseover"],ia=e.defineComponent({name:"ClSlider",__name:"Index",props:{id:String,className:String,disabled:{type:Boolean,default:!1},value:[String,Number],min:{type:Number,default:0},max:{type:Number,default:100},isRange:{type:Boolean,default:!1},isBarDrag:{type:Boolean,default:!1},splitNumber:{type:Number,default:0},isShowDot:{type:Boolean,default:!0},isShowDotActive:{type:Boolean,default:!0},marks:{type:Array,default:()=>[]},isVertical:{type:Boolean,default:!1},verticalHeight:String,size:{type:String,default:"large"},numType:{type:String,default:"int",validator:n=>["int","float2","float3"].indexOf(n)>-1},tooltipFormat:String,isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:" - "}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:(n,a)=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=`slider-${o.getRandom(5)}`,d=e.useTemplateRef("refElTrack"),u=e.useTemplateRef("refBtnStart"),r=e.useTemplateRef("refBtnEnd"),c=t.id,m=e.reactive({track:void 0,bar:void 0,btnStart:void 0,btnEnd:void 0,dots:void 0,marks:void 0});o.isNonEmptyString(c)&&(m.track=`${c}-track`,m.bar=`${c}-bar`,m.btnStart=`${c}-btn-start`,m.btnEnd=`${c}-btn-end`,m.dots=`${c}-dots`,m.marks=`${c}-marks`);const p=e.reactive({markHoverIndex:-1}),f=e.reactive({left:0,width:0}),h=e.reactive({start:t.min,end:t.min,startRatio:0,endRatio:0}),g=X=>{const ee=t.tooltipFormat;return o.isNonEmptyString(ee)?o.convertStringFormat(ee,{_value:X}):X.toString()},y=e.computed(()=>{if(!t.isRange)return g(h.end);const X=o.isString(t.plaintextSeparator)?t.plaintextSeparator:" - ";return`${g(h.start)}${X}${g(h.end)}`}),V=e.ref([]),E=e.ref([]),B=e.computed(()=>Math.abs(t.max-t.min)),T=e.computed(()=>t.marks.length>0),D=e.computed(()=>{const{isRange:X,isBarDrag:ee}=t;let F=!1;return X&&(F=ee),F}),x=e.computed(()=>{let X={"panel-slider":!0,"slider-disabled":t.disabled,"slider-vertical":t.isVertical,"slider-level":!t.isVertical},ee=t.size;return o.isEmpty(ee)&&(ee="large"),X[`slider-${ee}`]=!0,X=o.getJsonMerge(X,de.getClassNameJson(t.className)),X}),O=e.computed(()=>{const X={};return t.isVertical&&o.isNonEmptyString(t.verticalHeight)&&(X.height=t.verticalHeight),X}),w=(X,ee=2)=>o.isFinite(X)?Number((X*100).toFixed(ee)):0,M=X=>{const ee=B.value;return ee>0?w((X-t.min)/ee):0},b=X=>{let ee=0;if(X<=0)ee=t.min;else if(X>=100)ee=t.max;else{const{numType:F}=t,le=B.value*X/100,me=o.getValueByFormat(le.toString(),F,{isThousands:!1});if(ee=t.min+Number(me),o.isExistValue(["float2","float3"],F)){const ie=Number(F.replace("float","")),ne=ee.toString();o.isExistValue(ne,".")&&ne.split(".")[1].length>ie&&(ee=Number(ee.toFixed(ie)))}}return ee},N=X=>{let ee=Number(X),F=!0;return o.isFinite(ee)?ee<=t.min?(ee=t.min,F=!1):ee>=t.max&&(ee=t.max,F=!1):(ee=t.min,F=!1),{value:ee,check:F}},J=()=>{if(T.value){const X=[];t.marks.forEach(ee=>{if(!ee)return;const F=o.getJsonClone(ee);F.value=Number(F.value),o.isFinite(F.value)&&(F.ratio=M(F.value),o.isString(F.mark)?F.safeMark=o.isHtml(F.mark)?o.encodeHTML(F.mark):F.mark:F.safeMark="",X.push(F))}),X.sort((ee,F)=>ee.value-F.value),E.value=X}},q=()=>{const X=[];if(T.value)E.value.forEach(ee=>{X.push({ratio:ee.ratio,value:ee.value,isActive:!1,isHide:!1})});else if(t.splitNumber>1){const ee=100/t.splitNumber,F=ee/2;for(let j=1;j<t.splitNumber;j++){const le=ee*j,me=b(le);X.push({value:me,ratio:w(le/100),isActive:!1,isHide:!1,left:w((le-F)/100),right:w((le+F)/100)})}}V.value=X},z=()=>{if(V.value.length>0){const{isShowDot:X,isShowDotActive:ee,min:F,max:j}=t,le=T.value,me=f.left,ie=me+f.width,ne=[];V.value.forEach(A=>{const te=o.getJsonClone(A),ce=A.ratio>=me&&A.ratio<=ie;te.isActive=ce;let pe=!1;le?pe=!0:X?(pe=!0,ce&&(ee?pe=!0:pe=!1)):pe=!1,(A.value===F||A.value===j)&&(pe=!1),te.isHide=!pe,ne.push(te)}),V.value=ne}},H=X=>{const ee=X.startRatio>X.endRatio?X.endRatio:X.startRatio,F=Math.abs(X.endRatio-X.startRatio);f.left=ee,f.width=F},v=X=>{e.nextTick(()=>{t.isRange?X?(u.value?.showTooltip(),r.value?.showTooltip()):(u.value?.hideTooltip(),r.value?.hideTooltip()):X?r.value?.showTooltip():r.value?.hideTooltip()})},S=X=>{H(X),h.start=X.start,h.end=X.end,h.startRatio=X.startRatio,h.endRatio=X.endRatio,z()},C=X=>{let ee,F;if(X&&!o.isEmpty(X)){const me=X.toString();if(me==="")ee=t.min,F=t.min;else{const ie=me.split(","),ne=N(ie[0]);if(t.isRange){if(ee=ne.value,F=ee,ie.length>1){const A=N(ie[1]);A.value>ee&&(F=A.value)}}else ee=t.min,F=ne.value}}else ee=t.min,F=t.min;const j=M(ee),le=M(F);S({start:ee,end:F,startRatio:j,endRatio:le})},$=X=>{if(!o.isFinite(X))return 0;let ee=w(X);const F=V.value;if(!T.value&&F.length>0){if(ee<F[0].left)ee=0;else if(ee>F[F.length-1].right)ee=100;else for(let j=0;j<F.length;j++)if(ee>=F[j].left&&ee<=F[j].right){ee=F[j].ratio;break}}return ee},k=X=>{const ee=$(X),F=b(ee);let{start:j,startRatio:le,end:me,endRatio:ie}=h,ne="";if(t.isRange)if(ee<=le)ne="start";else if(ee>=ie)ne="end";else{const A=(ie-le)/2;ee>le&&ee<=le+A?ne="start":ee>=ie-A&&ee<ie&&(ne="end")}else ne="end";switch(ne){case"start":j=F,le=ee;break;case"end":me=F,ie=ee;break}return{start:j,end:me,startRatio:le,endRatio:ie}},I=X=>{const ee=X?.start??h.start,F=X?.end??h.end;let j=ee,le=F;j>le&&(j=F,le=ee);const me=t.isRange?`${j},${le}`:le.toString();s("update:value",me),s("update:modelValue",me),s("onChange",me,{start:j,end:le})},L=X=>{if(!X)return{};const ee={};return t.isVertical?ee.bottom=`${X.ratio}%`:ee.left=`${X.ratio}%`,o.isEmpty(X.color)||(ee.color=X.color),ee},_=()=>{J(),q(),C(t.value)};e.onMounted(()=>{e.nextTick(()=>{_()})}),e.watch(()=>t.value,(X,ee)=>{if(X!==ee){let F=!0;const j=X!=null?X.toString():"";if(j==="")F=!0;else{const le=j.split(","),me=Number(le[0]);if(t.isRange){const ie=le.length>1?Number(le[1]):me;(me===h.start&&ie===h.end||me===h.end&&ie===h.start)&&(F=!1)}else F=me!==h.end}F&&C(X)}},{immediate:!0}),e.watch(()=>t.marks,()=>{J(),q()});const R=X=>{if(!t.disabled&&X){X.preventDefault(),X.stopPropagation();const ee=d.value;if(!ee)return;const F=ee.getBoundingClientRect(),j=t.isVertical?(F.bottom-X.clientY)/ee.clientHeight:(X.clientX-F.left)/ee.clientWidth;if(!o.isFinite(j))return;const le=k(j);S(le),I(le)}},P=(X,ee)=>{let{startRatio:F,endRatio:j}=h;const le=X.value;ee==="start"?(F=le,h.start=b(le),h.startRatio=le):(j=le,h.end=b(le),h.endRatio=le),H({startRatio:F,endRatio:j}),z(),X.runType==="keydown"&&I()},Q=X=>{const{left:ee,width:F}=f,j={startRatio:ee,endRatio:ee+F};j.start=b(j.startRatio),j.end=b(j.endRatio),S(j),X.runType==="drag"&&I(j)},oe=X=>{if(t.isRange){let{start:ee,startRatio:F,end:j,endRatio:le}=h;X==="start"?(le=F,j=ee):(F=le,ee=j);const me={start:ee,startRatio:F,end:j,endRatio:le};S(me),I(me)}},ue=()=>{v(!0)},Y=X=>{const ee=X;h.start=b(X),h.startRatio=X;const F=X+f.width;h.end=b(F),h.endRatio=F,H({startRatio:ee,endRatio:F}),z(),v(!0)},Z=()=>{I(),v(!1)},se=()=>{v(!0)},K=()=>{v(!1)},W=X=>{T.value&&(p.markHoverIndex=X)},U=()=>{p.markHoverIndex=-1},ae=()=>t.isRange?`${h.start},${h.end}`:h.end.toString();return a({getValue:ae,getValueData:()=>({value:ae(),show:ae()})}),e.provide("$SliderTop",{getDragValueInfo:(X,ee)=>{const F=d.value;if(!F)return{ratio:ee/100,value:b(ee/100)};const j=t.isVertical?F.clientHeight:F.clientWidth;if(j<=0)return{ratio:ee/100,value:b(ee/100)};const le=X/j;let me=ee/100+le;me>=1?me=1:me<=0&&(me=0),me=$(me);const ie=b(me);return{ratio:me,value:ie}},getButtonMoveValueInfo:(X,ee)=>{const F=X==="left"?-1:1,j=Number(ee);let le;const me=V.value,ie=me.length;if(!T.value&&ie>0){let A=-1;if(j<me[0].ratio)A=-1;else if(j>me[ie-1].ratio)A=ie;else for(let ce=0;ce<ie;ce++)if(j>=me[ce].ratio&&ce+1<ie&&j<me[ce+1].ratio){A=ce;break}const te=A+F;te<0?le=0:te>=ie?le=100:le=me[te].ratio}else le=j+F;le>=100?le=100:le<=0&&(le=0);const ne=b(le);return{ratio:le,value:ne}}}),(X,ee)=>n.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(c),class:"cl-plaintext-value"},e.toDisplayString(y.value),9,Cu)):(e.openBlock(),e.createElementBlock("div",{key:1,id:e.unref(c),class:e.normalizeClass(x.value),style:e.normalizeStyle(O.value)},[e.createElementVNode("div",Bu,[e.createElementVNode("div",{ref_key:"refElTrack",ref:d,class:"slider-track",onClick:R},null,512),e.createVNode(Su,{id:m.bar,disabled:n.disabled,isVertical:n.isVertical,isBarDrag:D.value,left:f.left,width:f.width,onOnMoveStart:ue,onOnMoveIng:Y,onOnMoveEnd:Z,onOnClick:R,onOnMouseover:se,onOnMouseout:K},null,8,["id","disabled","isVertical","isBarDrag","left","width"]),n.isRange?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(No,{ref_key:"refBtnStart",ref:u,id:m.btnStart,disabled:n.disabled,isVertical:n.isVertical,value:h.start,ratio:h.startRatio,tooltipFormat:n.tooltipFormat,onOnMoveIng:ee[0]||(ee[0]=F=>P(F,"start")),onOnMoveEnd:Q,onOnDblClick:ee[1]||(ee[1]=F=>oe("start"))},null,8,["id","disabled","isVertical","value","ratio","tooltipFormat"]),e.createVNode(No,{ref_key:"refBtnEnd",ref:r,id:m.btnEnd,disabled:n.disabled,isVertical:n.isVertical,value:h.end,ratio:h.endRatio,tooltipFormat:n.tooltipFormat,onOnMoveIng:ee[2]||(ee[2]=F=>P(F,"end")),onOnMoveEnd:Q,onOnDblClick:ee[3]||(ee[3]=F=>oe("end"))},null,8,["id","disabled","isVertical","value","ratio","tooltipFormat"])],64)):(e.openBlock(),e.createBlock(No,{key:1,ref_key:"refBtnEnd",ref:r,id:m.btnEnd,disabled:n.disabled,isVertical:n.isVertical,value:h.end,ratio:h.endRatio,tooltipFormat:n.tooltipFormat,onOnMoveIng:ee[4]||(ee[4]=F=>P(F,"end")),onOnMoveEnd:Q},null,8,["id","disabled","isVertical","value","ratio","tooltipFormat"])),V.value.length>0?(e.openBlock(),e.createElementBlock("div",Du,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(V.value,(F,j)=>(e.openBlock(),e.createBlock(bu,{key:`${l}-dot-${j}`,id:m.dots?`${m.dots}-${j}`:void 0,isVertical:n.isVertical,itemInfo:F,isHover:p.markHoverIndex===j,isTooltip:!T.value,tooltipFormat:n.tooltipFormat,onOnMouseover:le=>W(j),onOnMouseout:U,onOnClick:R},null,8,["id","isVertical","itemInfo","isHover","isTooltip","tooltipFormat","onOnMouseover"]))),128))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))]),T.value?(e.openBlock(),e.createElementBlock("div",Iu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,(F,j)=>(e.openBlock(),e.createElementBlock("div",{key:`${l}-mark-${j}`,class:e.normalizeClass({"slider-mark":!0,hover:p.markHoverIndex===j}),style:e.normalizeStyle(L(F)),innerHTML:F.safeMark,onMouseover:le=>W(j),onMouseout:U},null,46,Tu))),128))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],14,xu))}}),Nu=["id"],Vu=["id"],_u=["name","checked"],Mu=["aria-checked"],Ou={key:0,class:"switchery-txt"},Au=["innerHTML"],Lu=["innerHTML"],$u={key:0,class:"switchery-load-bg"},Fu=22,Pu=40,Yi=e.defineComponent({name:"ClSwitchery",__name:"Index",props:{id:String,name:String,value:{type:Boolean,default:!1},className:{type:String,default:""},disabled:{type:Boolean,default:!1},color:{type:[String,Object],validator:n=>o.isObject(n)?!!(n.checked||n.unChecked):o.isString(n)},isUseOnChangeCheck:{type:Boolean,default:!1},isShowLoad:{type:Boolean,default:!0},activeHtml:String,inactiveHtml:String,changeCallback:Function,isPlaintext:{type:Boolean,default:!1}},emits:["update:value","update:modelValue","onChange","onError"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.useAttrs(),d=t.id,u=e.useTemplateRef("refElContainer");let r=!1,c=null;const m=e.reactive({isFirstComplete:!1,isOpen:t.value,buttonLeft:0,isRunLoad:!1,colorChecked:"var(--cl-primary, #2196f3)",colorUnChecked:"var(--cl-bg, #ffffff)",txtWidth:0}),p=e.computed(()=>{let H=t.name;return o.isEmpty(H)&&(H=`switchery_${o.getRandom(8)}`),H}),f=e.computed(()=>{const H=m.isOpen?t.activeHtml:t.inactiveHtml;return o.isNonEmptyString(H)?o.removeHTMLTags(H):m.isOpen?"是":"否"}),h=e.computed(()=>{const{colorChecked:H}=m;let v="";const S=t.color;if(o.isUndefined(S))v=H;else if(o.isString(S))v=S;else if(o.isObject(S)){const C=S;v=o.isExistJsonKey(C,"checked")?C.checked:H}return v}),g=e.computed(()=>{const{colorUnChecked:H}=m;let v="";const S=t.color;return o.isObject(S)&&o.isExistJsonKey(S,"unChecked")?v=S.unChecked||H:v=H,v}),y=e.computed(()=>{const H=de.getClassNameJson(t.className),v={"panel-switchery":!0,"switchery-transition-immediately":!m.isFirstComplete};return o.getJsonMerge(v,H)}),V=e.computed(()=>!o.isEmpty(t.activeHtml)||!o.isEmpty(t.inactiveHtml)),E=e.computed(()=>({"switchery-container":!0,"switchery-open":m.isOpen,"switchery-disabled":t.disabled,"switchery-has-txt":V.value})),B=e.computed(()=>{const H=m.isOpen,v=H?h.value:g.value,S={"background-color":v};return m.txtWidth>0&&(S.width=`${m.txtWidth}px`),S.transition=H?"border 0.4s, box-shadow 0.4s, background-color 1.2s":"border 0.4s, box-shadow 0.4s",S["box-shadow"]=H?`${v} 0px 0px 0px 11px inset`:`${v} 0px 0px 0px 0px inset`,(H||o.isObject(t.color)&&o.isExistJsonKey(t.color,"unChecked"))&&(S["border-color"]=v),S}),T=e.computed(()=>{const H={left:"0"};return m.isOpen&&(H.left=`${m.buttonLeft}px`),H}),D=H=>{const v=de.getElementData(l);s("update:value",H),s("update:modelValue",H),s("onChange",H,v)},x=()=>{const H=Nt("switchery");H&&(o.isExistJsonKey(H,"colorChecked")&&(m.colorChecked=H.colorChecked),o.isExistJsonKey(H,"colorUnChecked")&&(m.colorUnChecked=H.colorUnChecked))},O=()=>{if(!u.value)return;const H=u.value.clientWidth,v=u.value.querySelector(".switchery-button");if(!v)return;const S=v.clientWidth;m.buttonLeft=H===0?22:H-S},w=(H,v)=>{if(o.isEmpty(H))return 0;const S=v.querySelector(".switchery-txt > span"),C=document.createElement("span");if(C.style.position="absolute",C.style.visibility="hidden",C.style.left="-9999px",C.style.top="0",C.style.display="inline-block",C.style.whiteSpace="nowrap",S){const k=getComputedStyle(S);C.style.font=k.font,C.style.letterSpacing=k.letterSpacing}C.innerHTML=H,document.body.appendChild(C);const $=C.scrollWidth;return C.remove(),$},M=()=>{if(!V.value||!u.value){m.txtWidth=0;return}const H=u.value,v=w(t.activeHtml||"",H),S=w(t.inactiveHtml||"",H),C=Math.max(v,S);if(C===0){m.txtWidth=0;return}m.txtWidth=Math.max(C+Fu+2,Pu)},b=()=>{x(),M(),e.nextTick(()=>{O()}),c=setTimeout(()=>{m.isFirstComplete=!0},250)};e.onMounted(()=>{e.nextTick(()=>{b()})}),e.onBeforeUnmount(()=>{c&&(clearTimeout(c),c=null)}),e.watch(()=>t.value,H=>{m.isOpen=H}),e.watch(()=>[t.activeHtml,t.inactiveHtml],()=>{e.nextTick(()=>{M(),O()})});const N=async()=>{if(t.disabled||r)return;O();const H=!m.isOpen;if(t.changeCallback&&o.isFunction(t.changeCallback)){r=!0,m.isRunLoad=!0;const v=de.getElementData(l);try{const S=await t.changeCallback(H,v);let C=!1;o.isBoolean(S)?C=S:o.isObject(S)&&o.isBoolean(S.success)&&(C=S.success),C&&(m.isOpen=H)}catch{s("onError","回调changeCallback执行异常")}finally{m.isRunLoad=!1,r=!1}}else t.isUseOnChangeCheck?m.isRunLoad=!0:m.isOpen=H,D(H)};return a({getValue:()=>m.isOpen,setValue:(H,v=!1)=>{m.isOpen=H,v&&D(H)},setOnChangeResult:()=>{t.isUseOnChangeCheck&&o.isUndefined(t.changeCallback)&&(m.isOpen=!m.isOpen,m.isRunLoad=!1,r=!1)}}),(H,v)=>n.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(d),class:"cl-plaintext-value"},e.toDisplayString(f.value),9,Nu)):(e.openBlock(),e.createElementBlock("label",{key:1,id:e.unref(d),class:e.normalizeClass(y.value)},[e.createElementVNode("input",{type:"checkbox",class:"switchery-input",name:p.value,checked:m.isOpen},null,8,_u),e.createElementVNode("span",{class:e.normalizeClass(E.value),style:e.normalizeStyle(B.value),onClick:N,ref_key:"refElContainer",ref:u,role:"switch","aria-checked":m.isOpen,tabindex:"0"},[n.activeHtml||n.inactiveHtml?(e.openBlock(),e.createElementBlock("span",Ou,[m.isOpen?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:n.activeHtml},null,8,Au)):(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:n.inactiveHtml},null,8,Lu))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("span",{class:"switchery-button",style:e.normalizeStyle(T.value)},[n.isShowLoad&&m.isRunLoad?(e.openBlock(),e.createBlock(lt,{key:0,theme:"rotaryLine",size:"xs"})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],4)],14,Mu),n.isShowLoad&&m.isRunLoad?(e.openBlock(),e.createElementBlock("div",$u)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,Vu))}}),Ru=["id"],Hu=["onClick"],Uu=["innerHTML"],zu={key:1},Zn=e.defineComponent({name:"ClTags",__name:"Index",props:{id:String,className:String,disabled:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},isRemove:{type:Boolean,default:!0},showTextFormat:String,isRemoveAll:{type:Boolean,default:!1},theme:{type:String,default:"default",validator:n=>["default","code"].indexOf(n)!==-1},isFormatHtml:{type:Boolean,default:!1}},emits:["onRemove","onClickTag"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=`tags-${o.getRandom(5)}`,d=t.id,u=e.ref(t.disabled),r=e.ref([]),c=e.reactive({status:0,startColor:"#FFFF80",endColor:"var(--cl-transparent, rgba(0, 0, 0, 0))",hID:""}),m=e.computed(()=>{const{theme:q}=t;let z={"panel-tags":!0};q!=="default"&&(z[`tags-${q}`]=!0),t.isRemoveAll&&r.value.length>0&&(z["tags-region"]=!0);const H=de.getClassNameJson(t.className);return z=o.getJsonMerge(z,H),z}),p=q=>o.isEmpty(q)?"":o.isEmpty(t.showTextFormat)?o.isNonEmptyString(q.name)?q.name:"":o.convertStringFormatEncodeHTML(t.showTextFormat,q),f=q=>{if(o.isEmpty(q))return{};const{theme:z}=t;let H={};return z==="default"?(H={tag:!0,"tag-disabled":!!q.isShowDisabled,"tag-remove":t.isRemove&&!q.isShowDisabled},(o.isNonEmptyString(q.id)||typeof q.id=="number")&&(H["tag-hlight"]=q.id.toString()===c.hID&&c.status===2)):z==="code"&&(H["tag-code"]=!0),H},h=q=>{const z={};if(o.isEmpty(q)||o.isEmpty(q.id))return z;if(q.id.toString()===c.hID)switch(c.status){case 1:z["background-color"]=c.startColor;break;case 2:z["background-color"]=c.endColor;break}return z},g=q=>{if(o.isEmpty(q))return;const z=u.value;let H=!1;z?H=!0:H=o.isBoolean(q.isDisabled)?!!q.isDisabled:!1,q.isShowDisabled=H},y=q=>{const z=[];return!o.isArray(q)||o.isEmpty(q)||q.forEach(H=>{if(o.isEmpty(H))return;const v=o.getJsonClone(H);g(v),z.push(v)}),z},V=q=>{u.value=q;const z=y(r.value);r.value=z};let E=null,B=null;const T=()=>{E!==null&&(clearTimeout(E),E=null),B!==null&&(clearTimeout(B),B=null)},D=q=>{o.isEmpty(q)||(T(),c.hID=q.toString(),c.status=1,e.nextTick(()=>{E=setTimeout(()=>{c.status=2},10),B=setTimeout(()=>{c.status=0,c.hID=""},1500)}))},x=()=>{const q=y(t.list);r.value=q};e.onMounted(()=>{e.nextTick(()=>{x()})}),e.onBeforeUnmount(()=>{T()}),e.watch(()=>t.disabled,q=>{V(q)}),e.watch(()=>t.list,q=>{const z=y(q);r.value=z},{deep:!0});const O=(q,z)=>{s("onClickTag",z)},w=(q,z,H)=>{if(q.preventDefault(),q.stopPropagation(),t.isRemove&&!z.isShowDisabled&&H>=0&&H<r.value.length){r.value.splice(H,1);const v=o.isNonEmptyString(z.id)||typeof z.id=="number"?z.id.toString():"";s("onRemove",v)}},M=()=>{r.value=[],s("onRemove","")};return a({setDisabled:(q=!0)=>{V(q)},addInfo:q=>{if(o.isEmpty(q))return;const z=o.getListExistValue(r.value,q.name||"","name");if(o.isEmpty(z)){const H=o.getJsonClone(q);g(H),r.value.push(H)}else z.info&&!o.isEmpty(z.info.id)&&D(z.info.id)},getData:()=>o.getListClone(r.value)}),(q,z)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(d),class:e.normalizeClass(m.value)},[r.value.length>0?e.renderSlot(q.$slots,"head",{key:0}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(H,v)=>(e.openBlock(),e.createElementBlock("span",{key:`${l}-list-${v}-${H.id}`,class:e.normalizeClass(f(H)),style:e.normalizeStyle(h(H)),onClick:e.withModifiers(S=>O(S,H),["stop"])},[H.isHtml||n.isFormatHtml?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:p(H)},null,8,Uu)):(e.openBlock(),e.createElementBlock("span",zu,e.toDisplayString(p(H)),1)),n.isRemove&&!H.isShowDisabled?(e.openBlock(),e.createBlock(ve,{key:2,class:"tag-close",name:"close","aria-label":"移除",onClick:S=>w(S,H,v)},null,8,["onClick"])):e.createCommentVNode("",!0)],14,Hu))),128)),n.isRemoveAll&&r.value.length>0&&!n.disabled?(e.openBlock(),e.createBlock(ve,{key:2,class:"tag-closeAll",name:"close","aria-label":"清除全部",onClick:M})):e.createCommentVNode("",!0)],10,Ru))}}),Ju=["id"],qi=e.defineComponent({name:"ClWaterfall",__name:"Index",props:{id:String,className:String,list:{type:Array,default:()=>[]},itemKey:{type:String,default:"id"},width:{type:Number,default:-1},colNum:{type:Number,default:-1},spacing:{type:Number,default:10},animationName:{type:String,default:"animated fadeIn"}},setup(n,{expose:a}){const i=n,t=`waterfall-${o.getRandom(5)}`,s=i.id,l=e.useTemplateRef("refElList"),d=e.reactive({pWidth:0,pHeight:0}),u=e.ref([]),r=e.ref(!0),c={colPosY:[],resizeEvent:null,resizeDelayFun:null,deletedList:[]},m=e.computed(()=>{const O=d.pWidth,{width:w,colNum:M,spacing:b}=i;let N=300;const J=w>0,q=M>0,z=q?Math.max(1,parseInt(((O+b)/M).toString())-b):0;if(J&&q){const H=(w+b)*M-b;N=O>=H?w:z}else!J&&q?N=z:J&&!q&&(N=O>w?w:O);return N}),p=e.computed(()=>{const O=d.pWidth,w=m.value,{colNum:M,spacing:b}=i,N=M>0;let J=-1;const q=Math.max(1,parseInt(((O+b)/(w+b)).toString()));if(N){const z=(w+b)*M-b;J=O>=z?M:q}else J=q;return J}),f=e.computed(()=>{const O=d.pWidth,w=m.value,M=p.value,{spacing:b}=i,N=(w+b)*M-b;return parseInt(((O-N)/2).toString())}),h=e.computed(()=>{const O={"panel-waterfall":!0};return o.getJsonMerge(O,de.getClassNameJson(i.className))}),g=()=>{r.value=!0;const{list:O,itemKey:w}=i;O.forEach(M=>{r.value&&(r.value=o.isExistJsonKey(M,w))})},y=()=>{u.value=i.list.filter(O=>!c.deletedList.includes(O)),c.deletedList=c.deletedList.filter(O=>i.list.includes(O))},V=()=>{const{spacing:O}=i;c.colPosY=new Array(p.value).fill(O)},E=O=>{const{spacing:w}=i,M=m.value;return f.value+(M+w)*O},B=()=>{let O;if(l.value&&(O=l.value.querySelectorAll(".waterfall-item")),o.isUndefined(O)||!O){d.pHeight=0;return}if(O.length===0){d.pHeight=0;return}V();const w=m.value,{spacing:M,animationName:b}=i;for(let N=0;N<O.length;N++){const J=O[N],q=de.getPositionView(J).height,z=Math.min.apply(null,c.colPosY),H=c.colPosY.indexOf(z),v=E(H);J.style.width=`${w}px`,J.style.transform=`translate3d(${v}px,${z}px, 0)`,c.colPosY[H]+=q+M;const S=J.firstChild;S.style.visibility="visible",S.className=de.getRemoveClass(S.className,b),de.checkHasClass(S.className,b)||(S.style.animationDuration="1000ms",S.style.animationDelay="200ms",S.style.animationFillMode="both",S.className=de.getAddClass(S.className,b))}d.pHeight=Math.max.apply(null,c.colPosY)},T=()=>{const O=()=>{y(),e.nextTick(()=>{B()})};c.resizeDelayFun?c.resizeDelayFun.run(O):e.nextTick(O)},D=()=>{l.value&&(d.pWidth=l.value.offsetWidth,c.resizeDelayFun=new Ai(null,200),c.resizeEvent=new ht({element:l.value,callback:O=>{d.pWidth=O?.contentRect?.width??d.pWidth}}))};return e.onMounted(()=>{e.nextTick(()=>{D()})}),e.onUnmounted(()=>{c.resizeEvent&&c.resizeEvent.destroy(),c.resizeDelayFun&&c.resizeDelayFun.stopRun()}),e.watch(()=>[d.pWidth,m.value,i.list],()=>{g(),T()},{deep:!0}),e.provide("$WaterfallTop",{imgCallback:T}),a({deleteItem:O=>{const w=u.value[O];return w!==void 0&&(c.deletedList.push(w),u.value.splice(O,1),T()),w}}),(O,w)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(s),class:e.normalizeClass(h.value)},[e.createElementVNode("div",{ref_key:"refElList",ref:l,class:"waterfall-list",style:e.normalizeStyle({height:`${d.pHeight}px`})},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(M,b)=>(e.openBlock(),e.createElementBlock("div",{key:r.value?`${t}-${M[n.itemKey]}`:`${t}-${b}`,class:"waterfall-item"},[e.createElementVNode("div",null,[e.renderSlot(O.$slots,"default",{data:M,index:b})])]))),128))],4)],10,Ju))}}),Ku={class:"waterfall-imageBox"},Wu=["alt"],Xi=e.defineComponent({name:"ClWaterfallImage",__name:"Image",props:{url:{type:String,default:""},alt:{type:String,default:""}},setup(n){const a=n,i=e.inject("$WaterfallTop"),t=e.useTemplateRef("refElImage"),s=e.computed(()=>a.url),l=d=>{i?.imgCallback?i.imgCallback():Se.warn("ClWaterfallImage",`未检测到 $WaterfallTop 容器注入,图片${d==="loaded"?"完成":"加载失败"}回调失效`)};return e.onBeforeUnmount(()=>{t.value&&(t.value.onload=null,t.value.onerror=null)}),Ri(t,s,{callback:{loaded:()=>{l("loaded")},error:()=>{l("error")}}}),(d,u)=>(e.openBlock(),e.createElementBlock("div",Ku,[e.createElementVNode("img",{ref_key:"refElImage",ref:t,class:"waterfall-image",alt:n.alt},null,8,Wu)]))}}),Gi=()=>({getPage:n=>nt.getPage(n),getValue:n=>nt.getValue(n),getType:()=>nt.getType(),setType:n=>nt.setType(n),getAll:()=>nt.getAll(),getCommon:()=>nt.getCommon()}),ju=["id"],Yu=["onKeydown","aria-expanded","aria-label"],qu=["onClick","onKeydown","aria-label"],Xu={class:"anchor-label"},Qi=e.defineComponent({name:"ClAnchorNav",directives:{cltooltip:ct},__name:"Index",props:{id:String,className:String,list:{type:Array,required:!0},isOpen:{type:Boolean,default:!1},offsetShow:{type:Number,default:100}},setup(n){const a=n,i=`anchorNav-${o.getRandom(5)}`,t=a.id,s=e.ref(""),l=e.ref(!1),d=e.ref(!a.isOpen);let u=null;const r=e.computed(()=>{const y={"panel-anchor-nav":!0,"is-fixed":l.value,"is-collapsed":d.value};return o.getJsonMerge(y,de.getClassNameJson(a.className))}),c=e.computed(()=>(a.list||[]).filter(y=>!!y)),m=()=>{a.list&&u===null&&(u=requestAnimationFrame(()=>{if(u=null,!a.list)return;const y=window.scrollY,V=window.innerHeight;l.value=y>(o.isFinite(a.offsetShow)?a.offsetShow:100);const E=c.value.map(T=>({id:T.id,element:document.getElementById(T.id)})).filter(T=>T.element!==null);if(E.length===0){s.value="";return}if(y+V>=document.documentElement.scrollHeight-1){s.value=E[E.length-1].id;return}let B=!1;for(let T=E.length-1;T>=0;T--)if(E[T].element.getBoundingClientRect().top<=V/2){s.value=E[T].id,B=!0;break}B||(s.value="")}))},p=()=>{window.addEventListener("scroll",m),window.addEventListener("resize",m)},f=()=>{u!==null&&(cancelAnimationFrame(u),u=null),window.removeEventListener("scroll",m),window.removeEventListener("resize",m)};e.onMounted(()=>{p(),m()}),e.onActivated(()=>{p(),m()}),e.onDeactivated(()=>{f()}),e.onUnmounted(()=>{f()}),e.watch(()=>a.list,()=>{m()},{deep:!0});const h=()=>{d.value=!d.value},g=y=>{const V=document.getElementById(y);V&&(V.scrollIntoView({behavior:"smooth",block:"start"}),V.hasAttribute("tabindex")||V.setAttribute("tabindex","-1"),V.focus({preventScroll:!0}))};return(y,V)=>{const E=e.resolveDirective("cltooltip");return e.openBlock(),e.createElementBlock("div",{id:e.unref(t),class:e.normalizeClass(r.value),role:"navigation","aria-label":"页面锚点导航"},[e.createElementVNode("div",{class:"anchor-toggle",onClick:h,onKeydown:[e.withKeys(h,["enter"]),e.withKeys(e.withModifiers(h,["prevent"]),["space"])],role:"button","aria-expanded":!d.value,"aria-label":d.value?"展开导航":"收起导航",tabindex:"0"},[e.createVNode(ve,{name:d.value?"caret-left":"caret-right"},null,8,["name"])],40,Yu),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(B,T)=>e.withDirectives((e.openBlock(),e.createElementBlock("div",{key:`${i}-${B.id}-${T}`,class:e.normalizeClass(["anchor-item",{active:s.value===B.id}]),onClick:D=>g(B.id),onKeydown:[e.withKeys(D=>g(B.id),["enter"]),e.withKeys(e.withModifiers(D=>g(B.id),["prevent"]),["space"])],role:"link","aria-label":B.label??"",tabindex:"0"},[V[0]||(V[0]=e.createElementVNode("span",{class:"anchor-dot"},null,-1)),e.createElementVNode("span",Xu,e.toDisplayString(B.label??""),1)],42,qu)),[[E,d.value?{html:B.label??"",position:"left",className:"tooltip-anchorNav",isHtml:!1}:{init:!1}]])),128))],10,ju)}}}),Gu=["id"],Qu={class:"calendar-container table-base"},Zu={colspan:"7"},ed={class:"calendar-head-label"},td=["title","onKeydown"],nd={class:"calendar-head-label-year"},od={class:"calendar-head-label-month"},ad={class:"calendar-head-label-next"},id=["title","onKeydown"],sd={class:"calendar-head-Week"},ld=["tabindex","aria-label","aria-selected","onClick","onMouseover","onMouseout","onKeydown"],rd={key:0,class:"day-today"},cd={class:"day-num"},ud={key:3,class:"day-lunar-num"},Zi=e.defineComponent({name:"ClCalendar",__name:"Index",props:{id:String,className:String,viewDateTime:String,weekFirst:{type:String,default:"sunday",validator:n=>{const a=["monday","sunday"].includes(n);return a||Se.warn("ClCalendar",`警告:weekFirst 仅支持 'monday' 或 'sunday',收到 '${n}',已按 sunday 处理`),a}},isShowLunar:Boolean,isWeekendRest:{type:Boolean,default:void 0},restDays:{type:Array,default:()=>[]},workDays:{type:Array,default:()=>[]}},emits:{onChange:n=>!0,onClick:n=>!0,onHover:(n,a)=>!0,onInit:n=>!0,onError:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=`calendar-${o.getRandom(5)}`,l=i.id,{optPageLanguage:d,getPageLanguage:u}=Le();u("dataTime");const r=e.reactive({selectId:"",focusedId:""}),c=e.reactive({titleYear:"",titleMonth:""}),m=e.useTemplateRef("calendarRoot"),p=e.ref([]),f=e.ref([]),h={viewDate:null,currentDate:ze.initDay(),isAnimating:!1},g=e.computed(()=>{if(i.isWeekendRest!==void 0)return i.isWeekendRest;const k=Nt("calendar");return k?.isWeekendRest!==void 0?k.isWeekendRest:!0}),y=e.computed(()=>i.restDays.length>0?i.restDays:Nt("calendar")?.restDays||[]),V=e.computed(()=>i.workDays.length>0?i.workDays:Nt("calendar")?.workDays||[]),E=e.computed(()=>{const k={"panel-calendar":!0};return o.getJsonMerge(k,de.getClassNameJson(i.className))}),B=()=>{if(!h.viewDate)return;const k=h.viewDate.localeData(),I=h.viewDate.year(),L=k.monthsShort(h.viewDate);c.titleYear=`${I}${d.value.year}`,c.titleMonth=L;const _=k.weekdaysMin(),R=k.firstDayOfWeek();let P=[];i.weekFirst==="sunday"?P=_:_.forEach((Q,oe)=>{P[(7+oe-R)%7]=Q}),p.value=P};let T=null;const D=e.ref(!1),x=async()=>{if(!D.value)try{T=(await import("lunar-typescript")).Lunar,D.value=!0}catch(k){Se.warn("ClCalendar","农历插件加载失败,本次不显示农历",k)}},O=k=>{if(!T)return"";try{const I=T.fromDate(k.toDate()),L=I.getFestivals();if(o.isNonEmptyString(L[0]))return L[0];const _=I.getJieQi();if(o.isNonEmptyString(_))return _;const R=I.getDayInChinese();return o.isNonEmptyString(R)?R:""}catch(I){return Se.warn("ClCalendar","农历计算异常,该格不显示农历",I),""}},w=k=>{const I=L=>L.some(_=>ze.objDay(_).isSame(k,"day"));if(V.value.length>0&&I(V.value))return{text:"班"};if(y.value.length>0&&I(y.value))return{text:"休"};if(g.value){const L=k.day();if(L===0||L===6)return{text:"休"}}return null},M=(k,I,L,_)=>{const R=k.date(),P=ze.initFormat(k),Q=i.isShowLunar&&D.value?O(k):"",oe=w(k),ue=k.year()===I&&k.month()<L||k.year()<I,Y=k.year()===I&&k.month()>L||k.year()>I,Z=_&&k.isSame(_,"day")&&!ue&&!Y;return{id:`day-${P}`,cls:de.getAddClass("calendar-day",{old:ue,new:Y,today:Z}),day:P,dayNum:R,lunar:Q,restMark:oe?oe.text:void 0,isOld:ue,isNew:Y,isCurrentMonth:!ue&&!Y,isToday:Z}},b=()=>{const k=h.viewDate.clone(),I=h.currentDate;let L=k.clone().subtract(1,"months");L=L.date(L.daysInMonth()).startOf("week"),i.weekFirst==="sunday"&&(L=L.subtract(1,"days"));const _=[];let R=[];for(let P=0;P<42;P+=1){P>0&&(L=L.add(1,"days"));const Q=M(L.clone(),k.year(),k.month(),I);R.push(Q),Q.isCurrentMonth&&!o.isEmpty(r.selectId)&&Q.dayNum===r.selectId&&(r.selectId=Q.id),R.length===7&&(_.push({days:R}),R=[])}if(f.value=_,!o.isEmpty(r.selectId))r.focusedId=r.selectId;else{const P=_.flatMap(Q=>Q.days).find(Q=>Q.isCurrentMonth);r.focusedId=P?P.id:""}},N=k=>{h.viewDate=o.isEmpty(k)?ze.initDay():ze.getDayjsObject(k),h.viewDate&&typeof h.viewDate.isValid=="function"&&h.viewDate.isValid()||(h.viewDate=ze.initDay()),B(),b()},J=k=>!k||!o.isString(k)||o.isEmpty(k)?(r.selectId=ze.getDayjsObject("").date(),ze.initFormat({format:"YYYY-MM"})):k.split("-").length===3?(r.selectId=ze.getDayjsObject(k).date(),ze.initFormat({value:k,format:"YYYY-MM"})):(r.selectId="",k),q=()=>{N(J(i.viewDateTime)),e.nextTick(()=>{z(r.focusedId),!o.isEmpty(r.selectId)&&o.isString(r.selectId)&&t("onInit",r.selectId.replace("day-",""))})},z=k=>{if(o.isEmpty(k)||!m.value)return;const I=m.value.querySelector(`[aria-label="${k.replace("day-","")}"]`);if(!I)return;I.focus({preventScroll:!0});const L=I.getBoundingClientRect();(L.top<0||L.bottom>window.innerHeight)&&I.scrollIntoView({block:"nearest",behavior:"auto"})};e.onMounted(async()=>{i.isShowLunar&&await x(),e.nextTick(()=>{q(),i.isShowLunar&&D.value&&N(J(i.viewDateTime))})}),e.watch(()=>i.isShowLunar,k=>{k?x().then(()=>{N(J(i.viewDateTime)),e.nextTick(()=>z(r.focusedId))}):N(J(i.viewDateTime))}),e.watch(()=>i.viewDateTime,k=>{o.isEmpty(k)||(N(J(k)),e.nextTick(()=>z(r.focusedId)))});const H=(k,I)=>{k.preventDefault(),k.stopPropagation(),I.isCurrentMonth&&(r.focusedId=I.id,e.nextTick(()=>z(I.id)),r.selectId!==I.id&&(r.selectId=I.id,t("onClick",I.day)))},v=(k,I,L)=>{k.preventDefault(),k.stopPropagation(),I.isCurrentMonth&&t("onHover",I.day,L)},S=(k,I,L)=>{const _=f.value.flatMap(Q=>Q.days);if(_.length===0)return;const R=I*7+L;let P=R;switch(k.key){case"ArrowLeft":k.preventDefault(),P=Math.max(0,R-1);break;case"ArrowRight":k.preventDefault(),P=Math.min(41,R+1);break;case"ArrowUp":k.preventDefault(),P=Math.max(0,R-7);break;case"ArrowDown":k.preventDefault(),P=Math.min(41,R+7);break;case"Enter":case" ":k.preventDefault(),H(k,_[R]);return;default:return}if(P!==R){const Q=_[P];if(!Q.isCurrentMonth)return;r.focusedId=Q.id,e.nextTick(()=>z(Q.id))}},C=()=>{if(!h.isAnimating){h.isAnimating=!0;try{const k=h.viewDate.clone();let I=ze.subtractTime(k,1,"months");I=ze.initFormat({value:I,format:"YYYY-MM"}),N(I),t("onChange",I),e.nextTick(()=>z(r.focusedId))}catch{t("onError","切换到上一月失败")}finally{h.isAnimating=!1}}},$=()=>{if(!h.isAnimating){h.isAnimating=!0;try{const k=h.viewDate.clone();let I=ze.addTime(k,1,"months");I=ze.initFormat({value:I,format:"YYYY-MM"}),N(I),t("onChange",I),e.nextTick(()=>z(r.focusedId))}catch{t("onError","切换到下一月失败")}finally{h.isAnimating=!1}}};return(k,I)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(E.value),id:e.unref(l),ref_key:"calendarRoot",ref:m},[e.createElementVNode("table",Qu,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",Zu,[e.createElementVNode("div",ed,[e.createElementVNode("span",{class:"calendar-head-label-prev-month",title:e.unref(d).prevMonth,role:"button",tabindex:"0",onClick:C,onKeydown:[e.withKeys(e.withModifiers(C,["prevent"]),["enter"]),e.withKeys(e.withModifiers(C,["prevent"]),["space"])]},[e.createVNode(ve,{name:"angle-left"})],40,td),e.createElementVNode("span",null,[e.createElementVNode("span",nd,e.toDisplayString(c.titleYear),1),e.createElementVNode("span",od,e.toDisplayString(c.titleMonth),1)]),e.createElementVNode("span",ad,[e.createElementVNode("span",{class:"calendar-head-label-next-month",title:e.unref(d).nextMonth,role:"button",tabindex:"0",onClick:$,onKeydown:[e.withKeys(e.withModifiers($,["prevent"]),["enter"]),e.withKeys(e.withModifiers($,["prevent"]),["space"])]},[e.createVNode(ve,{name:"angle-right"})],40,id)])])])]),e.createElementVNode("tr",sd,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(L,_)=>(e.openBlock(),e.createElementBlock("th",{key:`${s}-week-${_}`},e.toDisplayString(L),1))),128))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(L,_)=>(e.openBlock(),e.createElementBlock("tr",{key:`${s}-days-${_}`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(L.days,(R,P)=>(e.openBlock(),e.createElementBlock("td",{key:`${s}-day-${P}`,class:e.normalizeClass([R.cls,r.selectId===R.id?"calendar-day-select":"",r.focusedId===R.id?"calendar-day-focused":""]),tabindex:R.isCurrentMonth?r.focusedId===R.id?"0":"-1":void 0,role:"gridcell","aria-label":R.day,"aria-selected":r.selectId===R.id?"true":"false",onClick:e.withModifiers(Q=>H(Q,R),["stop"]),onMouseover:Q=>v(Q,R,!0),onMouseout:Q=>v(Q,R,!1),onKeydown:Q=>S(Q,_,P)},[R.isToday?(e.openBlock(),e.createElementBlock("span",rd,"今")):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",cd,e.toDisplayString(R.dayNum),1),R.restMark?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(["day-rest",R.restMark==="班"?"day-rest-work":"day-rest-rest"])},e.toDisplayString(R.restMark),3)):e.createCommentVNode("",!0),R.lunar?(e.openBlock(),e.createElementBlock("div",ud,e.toDisplayString(R.lunar),1)):e.createCommentVNode("",!0),R.isCurrentMonth?e.renderSlot(k.$slots,"day",{key:4,time:R.day,data:R.dayNum}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))],42,ld))),128))]))),128))])])],10,Gu))}}),dd={class:"code-legend-demo"},md={class:"code-legend-code"},pd=["aria-label"],Ka=25,fd=100,es=e.defineComponent({name:"ClCodeLegend",__name:"Index",props:{id:{},className:{},title:{}},setup(n){const a=n,i=a.id,t=e.useTemplateRef("refElCard"),s=e.useTemplateRef("refElFoot"),l=e.ref(!1),d=e.ref(!1),u=e.ref("auto");let r=null,c=null,m=null;const p=e.computed(()=>{const b=["code-legend"];return a.className&&o.isString(a.className)&&!o.isEmpty(a.className)&&a.className.split(" ").forEach(N=>{o.isEmpty(N)||b.push(N)}),b.join(" ")}),f=e.computed(()=>({"code-legend-footer":!0,"card-footer-fixed":d.value})),h=e.computed(()=>({"icon-rotate":!0,"rotate-180":l.value})),g=()=>{r&&(clearTimeout(r),r=null),c&&(clearTimeout(c),c=null)},y=()=>{if(l.value){const b=t.value?.$el;if(!b)return;const N=b.clientWidth,J=s.value;if(!J)return;const q=J.getBoundingClientRect(),z=b.getBoundingClientRect(),H=window.innerHeight;z.top<H&&z.bottom>H?(d.value=!0,u.value=N.toString()+"px",J.style.left=q.left+"px"):(d.value=!1,u.value="auto",J.style.left="")}else d.value=!1,u.value="auto"},V=()=>{m||(m=setTimeout(()=>{m=null,y()},fd))};e.watch(()=>l.value,(b,N)=>{b!==N&&(g(),b?w():M())});const E=()=>{l.value=!l.value},B=b=>{(b.key==="Enter"||b.key===" ")&&(b.preventDefault(),E())},T=b=>{const N=b;N.style.height="auto";const J=window.getComputedStyle(N,null).height;N.style.height="0",r=setTimeout(function(){N.style.height=J},Ka)},D=b=>{const N=b;c=setTimeout(function(){N.style.height="0"},Ka)},x=()=>{e.nextTick(()=>{y()})},O=()=>{e.nextTick(()=>{y()})},w=()=>{window.addEventListener("scroll",V)},M=()=>{window.removeEventListener("scroll",V),m&&(clearTimeout(m),m=null)};return e.onMounted(()=>{l.value&&w()}),e.onActivated(()=>{l.value&&(w(),y())}),e.onDeactivated(()=>{M(),g()}),e.onUnmounted(()=>{M(),g()}),(b,N)=>(e.openBlock(),e.createBlock(jo,{ref_key:"refElCard",ref:t,id:e.unref(i),theme:"loopline",className:p.value},{headTitle:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(n.title),1)]),headExplain:e.withCtx(()=>[b.$slots.remark?e.renderSlot(b.$slots,"remark",{key:0}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),default:e.withCtx(()=>[e.createElementVNode("div",dd,[e.renderSlot(b.$slots,"demo")]),e.createVNode(e.Transition,{name:"slide-fade",onEnter:T,onAfterEnter:x,onLeave:D,onAfterLeave:O},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",null,[e.createElementVNode("div",md,[e.renderSlot(b.$slots,"code")])],512),[[e.vShow,l.value]])]),_:3})]),foot:e.withCtx(()=>[b.$slots.code?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"refElFoot",ref:s,class:e.normalizeClass(f.value),role:"button",tabindex:"0","aria-label":l.value?"收起代码":"展开代码",onClick:E,onKeydown:B,style:e.normalizeStyle({width:u.value})},[e.createVNode(ve,{name:"caret-down",class:e.normalizeClass(h.value)},null,8,["class"])],46,pd)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),_:3},8,["id","className"]))}}),hd=["id"],gd=["aria-expanded"],yd=["id"],ts=e.defineComponent({name:"ClDropdownlayer",__name:"Base",props:{id:String,classParent:{type:[String,Object]},classText:{type:[String,Object]},classDropDown:{type:[String,Object]},isDisabled:{type:Boolean,default:!1},dropdownArrowPos:{type:String,default:"left",validator:n=>["left","right","center","top","bottom"].includes(n)},dropDownPos:{type:String,default:"down",validator:n=>["down","up","left","right"].includes(n)},isUseDropdownArrow:{type:Boolean,default:!1},isCloseDestroy:{type:Boolean,default:!0},transitionEnter:{type:String,default:"zoomInTop"},transitionLeave:{type:String,default:"zoomOutTop"},isInitDelayComplete:{type:Boolean,default:!1},appendContainer:{type:String,default:""},appendFollowWidth:{type:Boolean,default:!1},triggers:{type:String,default:"click",validator:n=>["click","hover"].includes(n)},onOpenBeforeCallback:Function},emits:{onChangeOpen:n=>!0,onChangePosition:n=>!0,onOpenComplete:()=>!0,onAfterLeave:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=o.isNonEmptyString(t.id)?t.id:`dropdownLayer-${o.getRandom(8)}`,d=e.useTemplateRef("refElTopParent"),u=e.useTemplateRef("refElText"),r=e.useTemplateRef("refElDropdown"),c=e.reactive({isOpen:!1,isShowOpen:!1,isInitFirstOpen:!1,dropDownPos:"down",arrowPos:"left",dropDownTop:"",dropDownLeft:"",arrowLeft:"",isOpacity0:!1,dropdownId:`${l}-dropdown`}),m=e.ref(!1),p=e.ref(null),f=e.ref([]),h=e.ref(null),g=e.ref(null);let y=null,V=null,E=null,B=null,T=!1;const D=e.computed(()=>{let F={"panel-dropdownlayer":!0,"dropdownLayer-arrow":t.isUseDropdownArrow,"dropdownLayer-disabled":t.isDisabled};return o.isNonEmptyString(t.classParent)?F=o.getJsonMerge(F,de.getClassNameJson(t.classParent)):o.isObject(t.classParent)&&(F=o.getJsonMerge(F,t.classParent)),F}),x=e.computed(()=>{let F={"dropdownLayer-text":!0,"dropdownLayer-text-open":c.isShowOpen};return!o.isEmpty(c.dropDownPos)&&c.isShowOpen&&(F[`dropdownLayer-text-${c.dropDownPos}`]=!0),o.isNonEmptyString(t.classText)?F=o.getJsonMerge(F,de.getClassNameJson(t.classText)):o.isObject(t.classText)&&(F=o.getJsonMerge(F,t.classText)),F}),O=e.computed(()=>{let F={"dropdownLayer-dropdown":!0,"dropdownLayer-dropdown-open":c.isShowOpen,"dropdownLayer-dropdown-arrow":t.isUseDropdownArrow,"dropdownLayer-dropdown-opacity0":c.isOpacity0};return F[`dropdownLayer-dropdown-${c.dropDownPos}`]=!0,F[`dropdownLayer-dropdown-arrow-${c.arrowPos}`]=!0,o.isNonEmptyString(t.classDropDown)?F=o.getJsonMerge(F,de.getClassNameJson(t.classDropDown)):o.isObject(t.classDropDown)&&(F=o.getJsonMerge(F,t.classDropDown)),F}),w=e.computed(()=>!o.isEmpty(t.appendContainer)),M=e.computed(()=>{const F={},{dropDownPos:j,dropdownArrowPos:le}=t,{dropDownTop:me,dropDownLeft:ie}=c;return j==="down"||j==="up"?(F.top=me,(le==="center"||le==="top"||le==="bottom"||w.value)&&(F.left=ie)):(j==="left"||j==="right")&&(F.left=ie,F.top=me),F}),b=e.computed(()=>{const F={};return(t.dropdownArrowPos==="center"||t.dropdownArrowPos==="top"||t.dropdownArrowPos==="bottom")&&(F.left=c.arrowLeft),F}),N=(F,j)=>{const le=t.isUseDropdownArrow,me={};return j==="down"?me.top=le?F.textHeight+F.arrowHeight-1:F.textHeight:j==="up"?me.top=le?-(F.dropDownHeight+F.arrowHeight-3):-F.dropDownHeight:j==="left"?(me.left=le?-(F.dropDownWidth+F.arrowWidth-1):-F.dropDownWidth,me.top=0):j==="right"&&(me.left=le?F.textWidth+F.arrowWidth-1:F.textWidth,me.top=0),me},J=F=>{!r.value||!d.value||(r.value.style.width=F&&t.appendFollowWidth?`${d.value.offsetWidth}px`:"")},q=()=>{c.isShowOpen&&e.nextTick(()=>{if(!d.value||!u.value||!r.value)return;const F=t.isUseDropdownArrow?r.value.querySelector(".arrow"):null,j=!o.isEmpty(t.appendContainer),le=j?t.appendContainer:null;J(j);let me=u.value;if(g.value){const pe=de.getParent(g.value,".dropdownLayer-arrow-anchorPoint",u.value,!1);o.isUndefined(pe)||(me=pe)}const ie=de.calculationDropdownPosition(d.value,me,r.value,F,le),A=ie[{down:"dropDownPosDown",up:"dropDownPosUp",left:"dropDownPosLeft",right:"dropDownPosRight"}[t.dropDownPos]||"dropDownPosDown"];c.dropDownPos=A;const te=z(ie,A);c.arrowPos=te;const ce=N(ie,A);(te==="center"||te==="top"||te==="bottom")&&(A==="down"||A==="up")&&(ce.left=ie.arrowPosCenterLRInfo?.dropDownLeft,c.arrowLeft=ie.arrowPosCenterLRInfo?.arrowLeft!=null?`${ie.arrowPosCenterLRInfo.arrowLeft}px`:""),j&&(ce.top=(ce.top||0)+(ie.controlOffset?.top||0),ce.left=(ce.left||0)+(ie.controlOffset?.left||0),te==="right"&&(ce.left=(ie.controlOffset?.left||0)+d.value.offsetWidth-r.value.offsetWidth)),c.dropDownTop=ce.top!=null?`${ce.top}px`:"",c.dropDownLeft=ce.left!=null?`${ce.left}px`:"",s("onChangePosition",{use:{dropDownPos:A,arrowPos:te,dropDownTop:ce.top,dropDownLeft:ce.left,arrowLeft:c.arrowLeft},original:ie})})},z=(F,j)=>{switch(t.dropdownArrowPos){case"left":return F.arrowPosLeft;case"right":return F.arrowPosRight;case"top":return F.arrowPosTop;case"bottom":return F.arrowPosBottom;case"center":return j==="down"||j==="up"?F.arrowPosCenterLR:j==="left"||j==="right"?F.arrowPosCenterTB:F.arrowPosLeft;default:return F.arrowPosLeft}},H=F=>{p.value=F},v=F=>{c.isShowOpen&&F?.target&&C(F)},S=F=>F?r.value&&r.value.contains(F)?!1:o.isUndefined(de.getParent(F,`#${c.dropdownId}`,d.value)):!0,C=F=>{if(d.value){S(F?.target)&&S(p.value?.target)&&(c.isOpen=!1);return}if(o.isNonEmptyString(t.appendContainer))try{document.querySelectorAll(`${t.appendContainer}>#${c.dropdownId}`).forEach(j=>j.parentNode?.removeChild(j))}catch{Se.warn("DropdownLayer","appendContainer 选择器非法,残留面板清理已跳过")}I(),c.isOpen=!1},$=F=>{if(c.isShowOpen){if(V)return;const j=F.currentTarget;V=requestAnimationFrame(()=>{V=null,q();const le=de.getPositionView(d.value,j),me=j.dataset,ie={right:0,left:0};ie.right=o.isUndefined(me.padRight)?0:parseInt(me.padRight.replace("px","")),ie.left=o.isUndefined(me.padLeft)?0:parseInt(me.padLeft.replace("px",""));let ne=!1;le.top+le.height/2<=0&&(ne=!0),le.right+le.width/2<=ie.right&&ie.right>=0&&(ne=!0),le.left+le.width/2<=ie.left&&ie.left>=0&&(ne=!0),c.isOpacity0=ne})}else k(!1)},k=(F=!0)=>{f.value.length>0&&f.value.forEach(j=>{F?j.addEventListener("scroll",$):j.removeEventListener("scroll",$)})},I=()=>{clearTimeout(B),B=null;const F=document.querySelector("body");F&&T&&F.removeEventListener("mousedown",H),T&&document.body.removeEventListener("click",v),T=!1,k(!1),c.isShowOpen=!1,R(),g.value=null,p.value=null},L=()=>{h.value=new ht({callback:()=>{c.isOpen&&q()}});const{dropDownPos:F}=t;F==="down"||F==="up"?(c.dropDownPos="down",c.arrowPos="left"):(F==="left"||F==="right")&&(c.dropDownPos="left",c.arrowPos="top")},_=()=>{y||!r.value||typeof window>"u"||!window.ResizeObserver||(y=new window.ResizeObserver(()=>{c.isOpen&&r.value&&q()}),y.observe(r.value))},R=()=>{y&&(y.disconnect(),y=null)},P=F=>{if(!t.isDisabled){if(g.value=F.target,!c.isOpen&&t.onOpenBeforeCallback)try{const j=t.onOpenBeforeCallback();if(o.isBoolean(j)&&!j)return}catch{Se.warn("DropdownLayer","onOpenBeforeCallback 执行异常,已按不阻止打开处理")}c.isOpen?Q():oe()}},Q=()=>{c.isOpen=!1},oe=()=>{if(c.isShowOpen){ue();return}if(t.isCloseDestroy&&c.isInitFirstOpen){ue();return}c.isOpen=!0},ue=()=>{m.value=!0,c.isInitFirstOpen=!1,c.isShowOpen=!1,e.nextTick(()=>{c.isOpen=!c.isOpen})};e.onMounted(()=>{e.nextTick(()=>{L()})}),e.onActivated(()=>{h.value||e.nextTick(()=>{L()})}),e.onDeactivated(()=>{clearTimeout(E),h.value?.destroy(),h.value=null,R(),I(),c.isOpen=!1}),e.onUnmounted(()=>{clearTimeout(E),h.value?.destroy(),I()}),e.watch(()=>c.isOpen,F=>{c.isInitFirstOpen||(c.isInitFirstOpen=!0,o.isEmpty(t.appendContainer)||e.nextTick(()=>{let j=de.getParentCheckBody(d.value,t.appendContainer);o.isUndefined(j)&&(j=document.querySelector("body")),r.value&&j.appendChild(r.value),f.value=de.getParentScrollList(d.value,t.appendContainer,!1),k()})),F||I(),s("onChangeOpen",F),F&&(c.isOpacity0=!1,B=setTimeout(()=>{if(B=null,!c.isOpen||T)return;T=!0;const j=document.querySelector("body");j&&j.addEventListener("mousedown",H),document.body.addEventListener("click",v)}),t.isInitDelayComplete||e.nextTick(()=>{c.isShowOpen=!0,q()}))});const Y=F=>{(t.triggers==="click"||F instanceof KeyboardEvent)&&P(F)};e.watch(()=>r.value,F=>{F&&_()});const Z=F=>{t.triggers==="hover"&&(clearTimeout(E),c.isOpen||P(F))},se=F=>{t.triggers==="hover"&&(E=setTimeout(()=>{r.value?.matches(":hover")||c.isOpen&&P(F)},150))},K=()=>{_(),s("onOpenComplete")},W=()=>{m.value=!1},U=()=>{if(m.value){m.value=!1;return}t.isCloseDestroy&&(c.isInitFirstOpen=!1),s("onAfterLeave")};return a({setOpen:F=>{if(!o.isBoolean(F)){Se.warn("DropdownLayer","setOpen 参数必须为 boolean,已忽略");return}if(F&&t.onOpenBeforeCallback)try{const j=t.onOpenBeforeCallback();if(o.isBoolean(j)&&!j){Se.warn("DropdownLayer","setOpen 打开被 onOpenBeforeCallback 阻止");return}}catch{Se.warn("DropdownLayer","onOpenBeforeCallback 执行异常,已按不阻止打开处理")}c.isOpen=F},calculationPosition:()=>q(),initCompleteOpen:()=>{c.isOpen&&e.nextTick(()=>{c.isOpen&&(c.isShowOpen=!0,r.value?q():e.nextTick(()=>{q()}))})},getIsShowOpen:()=>c.isShowOpen}),(F,j)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(D.value),ref_key:"refElTopParent",ref:d},[e.createElementVNode("div",{class:e.normalizeClass(x.value),onClick:j[0]||(j[0]=le=>Y(le)),onMouseover:j[1]||(j[1]=le=>Z(le)),onMouseleave:j[2]||(j[2]=le=>se(le)),onKeydown:[j[3]||(j[3]=e.withKeys(e.withModifiers(le=>Y(le),["prevent"]),["enter"])),j[4]||(j[4]=e.withKeys(e.withModifiers(le=>Y(le),["prevent"]),["space"]))],role:"combobox",tabindex:"0","aria-expanded":c.isOpen,"aria-haspopup":"listbox",ref_key:"refElText",ref:u},[e.renderSlot(F.$slots,"labelText")],42,gd),c.isInitFirstOpen?(e.openBlock(),e.createBlock(e.Transition,{key:0,name:"dropdown-transit","enter-active-class":n.transitionEnter,"leave-active-class":n.transitionLeave,onEnter:K,onAfterLeave:U,onLeaveCancelled:W},{default:e.withCtx(()=>[e.withDirectives(e.createElementVNode("div",{id:c.dropdownId,class:e.normalizeClass(O.value),style:e.normalizeStyle(M.value),ref_key:"refElDropdown",ref:r,onMouseleave:j[5]||(j[5]=le=>se(le))},[n.isUseDropdownArrow?(e.openBlock(),e.createElementBlock("div",{key:0,class:"arrow",style:e.normalizeStyle(b.value)},null,4)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.renderSlot(F.$slots,"dropdown")],46,yd),[[e.vShow,c.isShowOpen]])]),_:3},8,["enter-active-class","leave-active-class"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,hd))}}),eo=e.defineComponent({name:"ClDropdownlayerPopup",__name:"Popup",props:{id:String,classParent:String,classText:String,classDropDown:String,isDisabled:{type:Boolean,default:!1},dropdownArrowPos:{type:String,default:"left",validator:n=>["left","right","center","top","bottom"].includes(n)},dropDownPos:{type:String,default:"down",validator:n=>["down","up","left","right"].includes(n)},isUseDropdownArrow:{type:Boolean,default:!1},isCloseDestroy:{type:Boolean,default:!1},isInitDelayComplete:{type:Boolean,default:!1},transitionEnter:{type:String,default:"zoomInTop"},transitionLeave:{type:String,default:"zoomOutTop"},appendContainer:{type:String,default:""},triggers:{type:String,default:"click",validator:n=>["click","hover"].includes(n)},onOpenBeforeCallback:Function},emits:{onChangeOpen:n=>!0,onChangePosition:n=>!0,onOpenComplete:()=>!0,onAfterLeave:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElDropdownLayer"),u=e.computed(()=>{let E={"dropdownLayer-theme-popup":!0,"panel-dropdownlayerpopup":!0};return E=o.getJsonMerge(E,de.getClassNameJson(t.classParent)),E}),r=e.computed(()=>{let E={"dropdownLayer-dropdown-theme-popup":!0};return E=o.getJsonMerge(E,de.getClassNameJson(t.classDropDown)),E}),c=E=>{E&&t.isInitDelayComplete&&y(),s("onChangeOpen",E)},m=E=>{s("onChangePosition",E)},p=()=>{s("onOpenComplete")},f=()=>{s("onAfterLeave")},h=E=>{if(!d.value){Se.warn("DropdownLayer","子组件尚未挂载,setOpen 调用已忽略");return}d.value.setOpen(E)},g=()=>{if(!d.value){Se.warn("DropdownLayer","子组件尚未挂载,calculationPosition 调用已忽略");return}return d.value.calculationPosition()},y=()=>{if(!d.value){Se.warn("DropdownLayer","子组件尚未挂载,initCompleteOpen 调用已忽略");return}e.nextTick(()=>{d.value?.initCompleteOpen()})};return a({setOpen:h,calculationPosition:g,initCompleteOpen:y,checkIsShowOpen:()=>{if(!d.value){Se.warn("DropdownLayer","子组件尚未挂载,checkIsShowOpen 调用已忽略");return}return d.value.getIsShowOpen()}}),(E,B)=>(e.openBlock(),e.createBlock(ts,{ref_key:"refElDropdownLayer",ref:d,id:e.unref(l),classParent:u.value,classText:n.classText,classDropDown:r.value,isDisabled:n.isDisabled,dropdownArrowPos:n.dropdownArrowPos,dropDownPos:n.dropDownPos,isUseDropdownArrow:n.isUseDropdownArrow,isCloseDestroy:n.isCloseDestroy,isInitDelayComplete:n.isInitDelayComplete,appendContainer:n.appendContainer,transitionEnter:n.transitionEnter,transitionLeave:n.transitionLeave,triggers:n.triggers,onOpenBeforeCallback:n.onOpenBeforeCallback,onOnChangeOpen:c,onOnChangePosition:m,onOnOpenComplete:p,onOnAfterLeave:f},{labelText:e.withCtx(()=>[e.renderSlot(E.$slots,"label")]),dropdown:e.withCtx(()=>[e.renderSlot(E.$slots,"dropdown")]),_:3},8,["id","classParent","classText","classDropDown","isDisabled","dropdownArrowPos","dropDownPos","isUseDropdownArrow","isCloseDestroy","isInitDelayComplete","appendContainer","transitionEnter","transitionLeave","triggers","onOpenBeforeCallback"]))}}),Wa=(n,a)=>Object.prototype.hasOwnProperty.call(n,a),vd=(n,a,i)=>{const t=(2-a)*i/2,s=t===0||t===1?0:a*i/(t<.5?t*2:2-t*2);return[n,s,t]},kd=n=>typeof n=="string"&&n.includes(".")&&Number.parseFloat(n)===1,Sd=n=>typeof n=="string"&&n.includes("%"),qt=(n,a)=>{kd(n)&&(n="100%");const i=Sd(n);return n=Math.min(a,Math.max(0,Number.parseFloat(`${n}`))),i&&(n=Number.parseInt(`${n*a}`,10)/100),Math.abs(n-a)<1e-6?1:n%a/Number.parseFloat(a)},ja={10:"A",11:"B",12:"C",13:"D",14:"E",15:"F"},Rn=n=>{n=Math.min(Math.round(n),255);const a=Math.floor(n/16),i=n%16;return`${ja[a]||a}${ja[i]||i}`},Ya=({r:n,g:a,b:i})=>Number.isNaN(+n)||Number.isNaN(+a)||Number.isNaN(+i)?"":`#${Rn(n)}${Rn(a)}${Rn(i)}`,Vo={A:10,B:11,C:12,D:13,E:14,F:15},Ot=n=>n.length===2?(Vo[n[0].toUpperCase()]||+n[0])*16+(Vo[n[1].toUpperCase()]||+n[1]):Vo[n[1].toUpperCase()]||+n[1],wd=(n,a,i)=>{a=a/100,i=i/100;let t=a;const s=Math.max(i,.01);i*=2,a*=i<=1?i:2-i,t*=s<=1?s:2-s;const l=(i+a)/2,d=i===0?2*t/(s+t):2*a/(i+a);return{h:n,s:d*100,v:l*100}},qa=(n,a,i)=>{n=qt(n,255),a=qt(a,255),i=qt(i,255);const t=Math.max(n,a,i),s=Math.min(n,a,i);let l=0;const d=t,u=t-s,r=t===0?0:u/t;if(t===s)l=0;else{switch(t){case n:{l=(a-i)/u+(a<i?6:0);break}case a:{l=(i-n)/u+2;break}case i:{l=(n-a)/u+4;break}}l/=6}return{h:l*360,s:r*100,v:d*100}},_n=(n,a,i)=>{n=qt(n,360)*6,a=qt(a,100),i=qt(i,100);const t=Math.floor(n),s=n-t,l=i*(1-a),d=i*(1-s*a),u=i*(1-(1-s)*a),r=t%6,c=[i,d,l,l,u,i][r],m=[u,i,i,d,l,l][r],p=[l,l,u,i,i,d][r];return{r:Math.round(c*255),g:Math.round(m*255),b:Math.round(p*255)}};class Ed{_hue=0;_saturation=100;_value=100;_alpha=100;enableAlpha=!1;format="hex";value="";selected;constructor(a){a=a||{};for(const i in a)Wa(a,i)&&(this[i]=a[i]);a.value?this.fromString(a.value):this.doOnChange()}set(a,i){if(arguments.length===1&&typeof a=="object"){for(const t in a)Wa(a,t)&&this.set(t,a[t]);return}this[`_${a}`]=i,this.doOnChange()}get(a){return a==="alpha"?Math.floor(this[`_${a}`]):this[`_${a}`]}toRgb(){return _n(this._hue,this._saturation,this._value)}fromString(a){if(!a)return;const i=this._convertValueInfo(a);i&&(this._hue=i.hue,this._saturation=i.saturation,this._value=i.value,this._alpha=i.alpha,this.doOnChange())}compare(a){return Math.abs(a._hue-this._hue)<2&&Math.abs(a._saturation-this._saturation)<1&&Math.abs(a._value-this._value)<1&&Math.abs(a._alpha-this._alpha)<1}doOnChange(){const{_hue:a,_saturation:i,_value:t,_alpha:s,format:l}=this,d={hue:a,saturation:i,value:t,alpha:s};let u=this._convertFormat(l,d);u.length===0&&(u=this._getValueRGB(d)),this.value=u}checkValue(a){let i=!1,t="";if(/^rgb\(/.test(a)?t="^[rR][gG][Bb][\\(]([\\s]*(2[0-4][0-9]|25[0-5]|[01]?[0-9][0-9]?)[\\s]*,){2}[\\s]*(2[0-4]\\d|25[0-5]|[01]?\\d\\d?)[\\s]*[\\)]{1}$":/^rgba\(/.test(a)?t="^[rR][gG][Bb][Aa][\\(]([\\s]*(2[0-4][0-9]|25[0-5]|[01]?[0-9][0-9]?)[\\s]*,){3}[\\s]*(1|1.0|0|0.[0-9])[\\s]*[\\)]{1}$":/^#/.test(a)?t="^#([0-9a-fA-F]{6}|[0-9a-fA-F]{3})$":/^hsl\(/.test(a)?t="^[hH][Ss][Ll][\\(]([\\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\\s]*,)([\\s]*((100|[0-9][0-9]?)%|0)[\\s]*,)([\\s]*((100|[0-9][0-9]?)%|0)[\\s]*)[\\)]$":/^hsla\(/.test(a)?t="^[hH][Ss][Ll][Aa][\\(]([\\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\\s]*,)([\\s]*((100|[0-9][0-9]?)%|0)[\\s]*,){2}([\\s]*(1|1.0|0|0.[0-9])[\\s]*)[\\)]$":/^hsv\(/.test(a)?t="^[hH][Ss][Vv][\\(]([\\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\\s]*,)([\\s]*((100|[0-9][0-9]?)%|0)[\\s]*,)([\\s]*((100|[0-9][0-9]?)%|0)[\\s]*)[\\)]$":/^hsva\(/.test(a)&&(t="^[hH][Ss][Vv][Aa][\\(]([\\s]*(2[0-9][0-9]|360|3[0-5][0-9]|[01]?[0-9][0-9]?)[\\s]*,)([\\s]*((100|[0-9][0-9]?)%|0)[\\s]*,){2}([\\s]*(1|1.0|0|0.[0-9])[\\s]*)[\\)]$"),t.length>0){const s=new RegExp(t);i=a.match(s)!==null}return i}getValueFormat(a,i){const t=this._convertValueInfo(a);return t?this._convertFormat(i,t):a}_convertValueInfo(a){let i=0,t=100,s=100,l=100;if(a){let d;if(a.includes("hsl")){const u=a.replace(/hsla|hsl|\(|\)/gm,"").split(/\s|,/g).filter(r=>r!=="").map((r,c)=>c>2?Number.parseFloat(r):Number.parseInt(r,10));u.length===4?(l=Number.parseFloat(u[3].toString()),l=l>1?1:l,l=l*100):u.length===3&&(l=100),u.length>=3&&(d=wd(u[0],u[1],u[2]))}else if(a.includes("hsv")){const u=a.replace(/hsva|hsv|\(|\)/gm,"").split(/\s|,/g).filter(r=>r!=="").map((r,c)=>c>2?Number.parseFloat(r):Number.parseInt(r,10));u.length===4?(l=Number.parseFloat(u[3].toString()),l=l>1?1:l,l=l*100):u.length===3&&(l=100),u.length>=3&&(d={h:u[0],s:u[1],v:u[2]})}else if(a.includes("rgb")){const u=a.replace(/rgba|rgb|\(|\)/gm,"").split(/\s|,/g).filter(r=>r!=="").map((r,c)=>c>2?Number.parseFloat(r):Number.parseInt(r,10));u.length===4?(l=Number.parseFloat(u[3].toString()),l=l>1?1:l,l=l*100):u.length===3&&(l=100),u.length>=3&&(d=qa(u[0],u[1],u[2]))}else if(a.includes("#")){const u=a.replace("#","").trim();if(!/^[0-9a-fA-F]{3}$|^[0-9a-fA-F]{6}$|^[0-9a-fA-F]{8}$/.test(u))return;let r=0,c=0,m=0;u.length===3?(r=Ot(u[0]+u[0]),c=Ot(u[1]+u[1]),m=Ot(u[2]+u[2])):(u.length===6||u.length===8)&&(r=Ot(u.slice(0,2)),c=Ot(u.slice(2,4)),m=Ot(u.slice(4,6))),u.length===8?(l=Ot(u.slice(6))/255,l=l>1?1:l,l=l*100):(u.length===3||u.length===6)&&(l=100),d=qa(r,c,m)}d&&(i=Math.max(0,Math.min(360,d.h)),t=Math.max(0,Math.min(100,d.s)),s=Math.max(0,Math.min(100,d.v)))}return{hue:i,saturation:t,value:s,alpha:l}}_convertFormat(a,i){let t="";switch(a){case"hsl":{t=this._getValueHSL(i);break}case"hsv":{t=this._getValueHSV(i);break}case"rgb":{t=this._getValueRGB(i);break}case"hex":t=this._getValueHEX(i)}return t}_isShowAlpha(a){return a!==100}_getValueHSL(a){const i=Math.floor(a.alpha),t=this._isShowAlpha(a.alpha),s=vd(a.hue,a.saturation/100,a.value/100),l=Math.round(a.hue),d=Math.round(s[1]*100),u=Math.round(s[2]*100);return t?`hsla(${l}, ${d}%, ${u}%, ${i/100})`:`hsl(${l}, ${d}%, ${u}%)`}_getValueHSV(a){const i=Math.floor(a.alpha),t=this._isShowAlpha(i),s=Math.round(a.hue),l=Math.round(a.saturation),d=Math.round(a.value);return t?`hsva(${s}, ${l}%, ${d}%, ${i/100})`:`hsv(${s}, ${l}%, ${d}%)`}_getValueHEX(a){const i=Math.floor(a.alpha);return this._isShowAlpha(i)?`${Ya(_n(a.hue,a.saturation,a.value))}${Rn(i*255/100)}`:Ya(_n(a.hue,a.saturation,a.value))}_getValueRGB(a){const i=Math.floor(a.alpha),t=this._isShowAlpha(i),{r:s,g:l,b:d}=_n(a.hue,a.saturation,a.value);return t?`rgba(${s}, ${l}, ${d}, ${this.get("alpha")/100})`:`rgb(${s}, ${l}, ${d})`}}const bd=e.defineComponent({name:"ClColorPickerPalette",__name:"Palette",props:{color:{type:Object,required:!0}},setup(n){const a=n,i=e.useTemplateRef("refElTopParent"),t=e.reactive({background:"hsl(0, 100%, 50%)",btnLeft:0,btnTop:0}),s=e.computed(()=>{const r=a.color.get("hue"),c=a.color.get("value");return{hue:r,value:c}}),l=(r,c)=>{const p=i.value.getBoundingClientRect();let f=c.clientX-p.left,h=c.clientY-p.top;f=Math.max(0,f),f=Math.min(f,p.width),h=Math.max(0,h),h=Math.min(h,p.height),t.btnLeft=f,t.btnTop=h,a.color.set({saturation:f/p.width*100,value:100-h/p.height*100})},d=()=>{const r=i.value,c=a.color.get("saturation"),m=a.color.get("value"),{clientWidth:p,clientHeight:f}=r;t.btnLeft=c*p/100,t.btnTop=(100-m)*f/100,t.background=`hsl(${a.color.get("hue")}, 100%, 50%)`},u=()=>{const r={ing:(c,m)=>{l(c,m)},end:(c,m)=>{l(c,m)}};new bt(i.value,r),d()};return e.onMounted(()=>{e.nextTick(()=>{u()})}),e.watch(()=>s.value,()=>{d()}),(r,c)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"refElTopParent",ref:i,class:"panel-colorpicker-palette",style:e.normalizeStyle({backgroundColor:t.background})},[c[1]||(c[1]=e.createElementVNode("div",{class:"panel-colorpicker-palette-white"},null,-1)),c[2]||(c[2]=e.createElementVNode("div",{class:"panel-colorpicker-palette-black"},null,-1)),e.createElementVNode("div",{class:"panel-colorpicker-palette-btn",style:e.normalizeStyle({top:t.btnTop+"px",left:t.btnLeft+"px"})},[...c[0]||(c[0]=[e.createElementVNode("div",null,null,-1)])],4)],4))}}),Cd=e.defineComponent({name:"ClColorPickerHue",__name:"Hue",props:{color:{type:Object,required:!0}},setup(n){const a=n,i=e.useTemplateRef("refElTopParent"),t=e.useTemplateRef("refElContainer"),s=e.useTemplateRef("refElBtn"),l=e.reactive({btnTop:0}),d=e.computed(()=>a.color.get("hue")),u=(f,h)=>{const y=i.value.getBoundingClientRect();let V=h.clientY-y.top;V=Math.max(0,V),V=Math.min(V,y.height);const E=Math.round(V/y.height*360);a.color.set("hue",E)},r=()=>{const f=i.value,h=a.color.get("hue");return Math.round(h*f.offsetHeight/360)},c=()=>{l.btnTop=r()},m=()=>{const f={ing:(h,g)=>{u(h,g)},end:(h,g)=>{u(h,g)}};new bt(t.value,f),new bt(s.value,f),c()};e.onMounted(()=>{e.nextTick(()=>{m()})}),e.watch(()=>d.value,()=>{c()});const p=f=>{if(f.target!==s.value){const g=de.getClientXY(f);u(f,g)}};return(f,h)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"refElTopParent",ref:i,class:"panel-colorpicker-hue"},[e.createElementVNode("div",{ref_key:"refElContainer",ref:t,class:"panel-colorpicker-hue-container",onClick:p},null,512),e.createElementVNode("div",{ref_key:"refElBtn",ref:s,class:"panel-colorpicker-hue-btn",style:e.normalizeStyle({top:l.btnTop+"px"})},null,4)],512))}}),xd=e.defineComponent({name:"ClColorPickerAlpha",__name:"Alpha",props:{color:{type:Object,required:!0}},setup(n){const a=n,i=e.useTemplateRef("refElTopParent"),t=e.useTemplateRef("refElContainer"),s=e.useTemplateRef("refElBtn"),l=e.reactive({background:null,btnLeft:0}),d=e.computed(()=>a.color.get("alpha")),u=(h,g)=>{const V=i.value.getBoundingClientRect();let E=g.clientX-V.left;E=Math.max(0,E),E=Math.min(E,V.width);const B=Math.round(E/V.width*100);a.color.set("alpha",B)},r=()=>{const h=i.value,g=a.color.get("alpha");return Math.round(g*h.offsetWidth/100)},c=()=>{if(a.color&&a.color.value){const{r:h,g,b:y}=a.color.toRgb();return`linear-gradient(to right, rgba(${h}, ${g}, ${y}, 0) 0%, rgba(${h}, ${g}, ${y}, 1) 100%)`}return null},m=()=>{l.btnLeft=r(),l.background=c()},p=()=>{const h={ing:(g,y)=>{u(g,y)},end:(g,y)=>{u(g,y)}};new bt(t.value,h),new bt(s.value,h),m()};e.onMounted(()=>{e.nextTick(()=>{p()})}),e.watch(()=>d.value,()=>{m()}),e.watch(()=>a.color.value,()=>{m()});const f=h=>{if(h.target!==s.value){const y=de.getClientXY(h);u(h,y)}};return(h,g)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"refElTopParent",ref:i,class:"panel-colorpicker-alpha"},[e.createElementVNode("div",{ref_key:"refElContainer",ref:t,class:"panel-colorpicker-alpha-container",style:e.normalizeStyle({background:l.background}),onClick:f},null,4),e.createElementVNode("div",{ref_key:"refElBtn",ref:s,class:"panel-colorpicker-alpha-btn",style:e.normalizeStyle({left:l.btnLeft+"px"})},null,4)],512))}}),ns=e.defineComponent({name:"ClColorPickerItemBlock",__name:"ItemBlock",props:{className:String,color:String},emits:{onClick:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=e.computed(()=>{let d="panel-colorpicker-item-block ";const{className:u}=i;return u&&!o.isEmpty(u)&&(d+=u),d}),l=()=>{t("onClick",i.color||"")};return(d,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(s.value),onClick:l},[u[0]||(u[0]=e.createElementVNode("div",{class:"panel-colorpicker-bg-alpha"},null,-1)),e.createElementVNode("div",{style:e.normalizeStyle({background:n.color})},null,4)],2))}}),Bd={class:"panel-colorpicker-preset"},Dd=e.defineComponent({name:"ClColorPickerPreset",__name:"Preset",emits:{onClick:n=>!0},setup(n,{emit:a}){const i=a,t=e.reactive({keyIndex:`ColorpickerPreset-${o.getRandom(8)}`}),s=e.ref([]),l=()=>{const u=["var(--cl-text-primary, #323233)","var(--cl-bg, #ffffff)","#f44336","#E91E63","#9c27b0","#673AB7","#3F51B5","#2196F3","#03A9F4","#00BCD4","#009688","#4CAF50","#8BC34A","#CDDC39","#FFEB3B","#FFC107","#FF9800","#FF5722","#795548","#9E9E9E","#607D8B","rgba(255, 69, 0, 0.68)","rgba(31, 147, 255, 0.73)","var(--cl-transparent, rgba(0, 0, 0, 0))"];s.value=u};e.onMounted(()=>{l()});const d=u=>{i("onClick",u)};return(u,r)=>(e.openBlock(),e.createElementBlock("div",Bd,[e.createElementVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(c,m)=>(e.openBlock(),e.createElementBlock("li",{key:`${t.keyIndex}-${m}`},[e.createVNode(ns,{color:c,onOnClick:d},null,8,["color"])]))),128))])]))}}),Id={class:"panel-colorpicker-value"},Td={key:0,class:"panel-colorpicker-hex"},Nd={key:1,class:"panel-colorpicker-rgb"},Vd={key:2,class:"panel-colorpicker-hsl"},_d={key:3,class:"panel-colorpicker-hsv"},Md=e.defineComponent({name:"ClColorPickerValue",__name:"Value",props:{color:{type:Object,required:!0}},emits:{onChangeType:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.reactive({type:"hex",hex:"",rgb:"",hsl:"",hsv:""}),d=e.ref(""),u=e.reactive({r:"",g:"",b:"",a:""}),r=e.reactive({h:"",s:"",l:"",a:""}),c=e.reactive({h:"",s:"",v:"",a:""}),m={typeList:["hex","rgb","hsl","hsv"]},p=e.computed(()=>t.color.value),f=b=>{const J=b.substring(b.indexOf("(")+1,b.indexOf(")")).split(",").map(q=>o.trim(q));return J.length===3&&J.push("1"),J},h=(b,N)=>{const J=b||p.value,{color:q}=t,z=N==="hex"?J:q.getValueFormat(J,"hex"),H=q.getValueFormat(J,"rgb"),v=q.getValueFormat(J,"hsl"),S=q.getValueFormat(J,"hsv");l.hex=z,l.rgb=H,l.hsl=v,l.hsv=S,e.nextTick(()=>{d.value=z;const C=f(H);u.r=C[0],u.g=C[1],u.b=C[2],u.a=C[3];const $=f(v);r.h=$[0],r.s=$[1],r.l=$[2],r.a=$[3];const k=f(S);c.h=k[0],c.s=k[1],c.v=k[2],c.a=k[3]})},g=b=>{let N=m.typeList.indexOf(l.type);N+=b;const J=m.typeList.length;N<0?N=J-1:N>=J&&(N=0);const q=m.typeList[N];l.type=q,s("onChangeType",q)},y=b=>{let N="";switch(b){case"hex":{d.value.length>0&&(N=d.value);break}case"rgb":{u.r.length>0&&u.g.length>0&&u.b.length>0&&u.a.length>0&&(N=`rgba(${u.r}, ${u.g}, ${u.b},${u.a})`);break}case"hsl":{r.h.length>0&&r.s.length>0&&r.l.length>0&&r.a.length>0&&(N=`hsla(${r.h}, ${r.s}, ${r.l},${r.a})`);break}case"hsv":{c.h.length>0&&c.s.length>0&&c.v.length>0&&c.a.length>0&&(N=`hsva(${c.h}, ${c.s}, ${c.v},${c.a})`);break}}if(N.length>0&&t.color.checkValue(N)){const J=t.color.getValueFormat(N,b);N!==J&&(h(N,b),e.nextTick(()=>{t.color.fromString(N)}),s("onChangeType",b))}},V=()=>{h()};e.onMounted(()=>{e.nextTick(()=>{V()})}),e.watch(()=>p.value,b=>{const N=t.color.getValueFormat(b,"rgb");l.rgb!==N&&h()});const E=()=>{y("hex")},B=()=>{y("rgb")},T=()=>{y("hsl")},D=()=>{y("hsv")},x=()=>{g(-1)},O=()=>{g(1)};return a({setType:b=>{l.type=b},clearInputs:()=>{d.value="",u.r="",u.g="",u.b="",u.a="",r.h="",r.s="",r.l="",r.a="",c.h="",c.s="",c.v="",c.a=""}}),(b,N)=>(e.openBlock(),e.createElementBlock("div",Id,[e.createElementVNode("div",null,[l.type==="hex"?(e.openBlock(),e.createElementBlock("div",Td,[e.createElementVNode("div",null,[e.createVNode(Pe,{value:d.value,"onUpdate:value":N[0]||(N[0]=J=>d.value=J),isClean:!1,onOnChange:E},null,8,["value"]),N[13]||(N[13]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"十六进制",-1))])])):l.type==="rgb"?(e.openBlock(),e.createElementBlock("div",Nd,[e.createElementVNode("div",null,[e.createVNode(Pe,{value:u.r,"onUpdate:value":N[1]||(N[1]=J=>u.r=J),isClean:!1,onOnChange:B},null,8,["value"]),N[14]||(N[14]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"R",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:u.g,"onUpdate:value":N[2]||(N[2]=J=>u.g=J),isClean:!1,onOnChange:B},null,8,["value"]),N[15]||(N[15]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"G",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:u.b,"onUpdate:value":N[3]||(N[3]=J=>u.b=J),isClean:!1,onOnChange:B},null,8,["value"]),N[16]||(N[16]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"B",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:u.a,"onUpdate:value":N[4]||(N[4]=J=>u.a=J),isClean:!1,onOnChange:B},null,8,["value"]),N[17]||(N[17]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"A",-1))])])):l.type==="hsl"?(e.openBlock(),e.createElementBlock("div",Vd,[e.createElementVNode("div",null,[e.createVNode(Pe,{value:r.h,"onUpdate:value":N[5]||(N[5]=J=>r.h=J),isClean:!1,onOnChange:T},null,8,["value"]),N[18]||(N[18]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"H",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:r.s,"onUpdate:value":N[6]||(N[6]=J=>r.s=J),isClean:!1,onOnChange:T},null,8,["value"]),N[19]||(N[19]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"S",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:r.l,"onUpdate:value":N[7]||(N[7]=J=>r.l=J),isClean:!1,onOnChange:T},null,8,["value"]),N[20]||(N[20]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"L",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:r.a,"onUpdate:value":N[8]||(N[8]=J=>r.a=J),isClean:!1,onOnChange:T},null,8,["value"]),N[21]||(N[21]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"A",-1))])])):l.type==="hsv"?(e.openBlock(),e.createElementBlock("div",_d,[e.createElementVNode("div",null,[e.createVNode(Pe,{value:c.h,"onUpdate:value":N[9]||(N[9]=J=>c.h=J),isClean:!1,onOnChange:D},null,8,["value"]),N[22]||(N[22]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"H",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:c.s,"onUpdate:value":N[10]||(N[10]=J=>c.s=J),isClean:!1,onOnChange:D},null,8,["value"]),N[23]||(N[23]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"S",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:c.v,"onUpdate:value":N[11]||(N[11]=J=>c.v=J),isClean:!1,onOnChange:D},null,8,["value"]),N[24]||(N[24]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"V",-1))]),e.createElementVNode("div",null,[e.createVNode(Pe,{value:c.a,"onUpdate:value":N[12]||(N[12]=J=>c.a=J),isClean:!1,onOnChange:D},null,8,["value"]),N[25]||(N[25]=e.createElementVNode("div",{class:"panel-colorpicker-value-lable"},"A",-1))])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64))]),e.createElementVNode("div",null,[e.createVNode(ve,{name:"caret-up",onClick:x}),e.createVNode(ve,{name:"caret-down",onClick:O})])]))}}),Od={key:0,class:"panel-colorpicker-copy-icon"},Xa=e.defineComponent({name:"ClColorPickerCopy",__name:"Copy",props:{className:String,color:String,getTxtCallback:Function},setup(n){const a=n,i=e.useSlots(),t=e.reactive({isHover:!1}),s=e.computed(()=>!o.isUndefined(i.default)),l=e.computed(()=>{let c=!1;return s.value?c=t.isHover:c=!0,c}),d=e.computed(()=>{const c={"panel-colorpicker-copy":!0,"panel-colorpicker-copy-hover":t.isHover},{className:m}=a;return m&&!o.isEmpty(m)&&m.split(" ").forEach(p=>{o.isEmpty(p)||(c[p]=!0)}),c}),u=()=>{s.value&&(t.isHover=!0)},r=()=>{s.value&&(t.isHover=!1)};return(c,m)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(d.value),onMouseenter:u,onMouseleave:r},[e.renderSlot(c.$slots,"default"),l.value?(e.openBlock(),e.createElementBlock("div",Od,[e.createVNode(yn,{textLabel:n.getTxtCallback||n.color||""},null,8,["textLabel"])])):e.createCommentVNode("",!0)],34))}}),Ad={class:"panel-colorpicker-container"},Ld={key:0},$d={key:0,class:"panel-colorpicker-format"},Fd={class:"panel-colorpicker-format-show"},Pd={key:1,class:"panel-colorpicker-operate"},Ga=e.defineComponent({name:"ClColorPickerBase",__name:"Color",props:{value:String,disabled:{type:Boolean,default:!1},isAlpha:{type:Boolean,default:!0},isFormat:{type:Boolean,default:!0},isOperate:{type:Boolean,default:!0},isPreset:{type:Boolean,default:!0},isDropdown:{type:Boolean,default:!0}},emits:{onChange:n=>!0,onSubmit:()=>!0,onInit:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("common");const u=e.useTemplateRef("refElColorResult"),r=e.useTemplateRef("refElColorValue"),c=e.reactive({isShowColorResult:!1,colorResult:"",formatShow:"hex"}),m=e.reactive(new Ed({value:t.value,format:"",enableAlpha:!0})),p={isColorChangeResult:!0},f=()=>m.get("alpha").toString()==="100"?"hex":"rgb",h=(b,N=!0)=>{let J="";b&&!o.isEmpty(b)&&c.isShowColorResult&&(J=m.getValueFormat(b,c.formatShow)),c.colorResult=J,N&&s("onChange",J)},g=b=>{b&&!o.isEmpty(b)?(c.isShowColorResult=!0,m.fromString(b),h(m.value,!1)):(c.isShowColorResult=!1,p.isColorChangeResult=!1,h("",!1),m.fromString(""),e.nextTick(()=>{p.isColorChangeResult=!0}))},y=()=>{const{value:b}=t;g(b),s("onInit")};e.onMounted(()=>{e.nextTick(()=>{y()})}),e.watch(()=>t.value,b=>{g(b)}),e.watch(()=>m.value,b=>{o.isEmpty(t.value)&&(c.isShowColorResult=!0),p.isColorChangeResult&&h(b),p.isColorChangeResult=!0});const V=()=>m.getValueFormat(m.value,c.formatShow),E=b=>{m.fromString(b)},B=b=>{c.formatShow=b,h(m.value,!1)},T=()=>{const b=t.value||"";c.isShowColorResult=!o.isEmpty(b),o.isEmpty(b)?m.set({hue:0,saturation:0,value:100,alpha:100}):(p.isColorChangeResult=!1,h(b),m.fromString(b))},D=()=>{m.set({hue:0,saturation:0,value:100,alpha:100})},x=()=>{s("onSubmit")};return a({getValue:()=>{let b=c.colorResult;if(b.length>0){const N=f();b=m.getValueFormat(b,N)}return b},setValue:b=>{g(b)},initValueType:()=>{const b=f();c.formatShow=b,r.value&&r.value.setType(b)}}),(b,N)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(["panel-colorpicker-wrapper",{"panel-colorpicker-wrapper-disabled":n.disabled}])},[e.createElementVNode("div",Ad,[e.createElementVNode("div",null,[e.createVNode(bd,{color:m},null,8,["color"]),e.createVNode(Cd,{color:m},null,8,["color"])]),n.isAlpha?(e.openBlock(),e.createElementBlock("div",Ld,[e.createVNode(xd,{color:m},null,8,["color"]),N[0]||(N[0]=e.createElementVNode("div",null,null,-1))])):e.createCommentVNode("",!0)]),n.isFormat?(e.openBlock(),e.createElementBlock("div",$d,[e.createElementVNode("div",Fd,[e.createVNode(Xa,{className:"panel-colorpicker-tip-current",getTxtCallback:V},{default:e.withCtx(()=>[e.createVNode(ns,{color:m.value},null,8,["color"])]),_:1})]),e.createVNode(Md,{ref_key:"refElColorValue",ref:r,color:m,onOnChangeType:B},null,8,["color"])])):e.createCommentVNode("",!0),n.isOperate?(e.openBlock(),e.createElementBlock("div",Pd,[e.createElementVNode("div",{ref_key:"refElColorResult",ref:u},e.toDisplayString(c.colorResult),513),e.createElementVNode("div",null,[e.createElementVNode("div",{onClick:T},[e.createVNode(ve,{name:"restore",title:e.unref(l).restore},null,8,["title"])]),e.createElementVNode("div",{onClick:D},[e.createVNode(ve,{name:"clear",title:e.unref(l).clearEmpty},null,8,["title"])]),e.createVNode(Xa,{color:c.colorResult},null,8,["color"]),n.isDropdown?(e.openBlock(),e.createElementBlock("div",{key:0,onClick:x},[e.createVNode(ve,{name:"check",title:e.unref(l).submit},null,8,["title"])])):e.createCommentVNode("",!0)])])):e.createCommentVNode("",!0),n.isPreset?(e.openBlock(),e.createBlock(Dd,{key:2,onOnClick:E})):e.createCommentVNode("",!0)],2))}}),Rd={class:"panel-colorpicker-dropdown-text"},Hd={key:0,class:"panel-colorpicker-dropdown-arrow"},os=e.defineComponent({name:"ClColorPicker",__name:"Index",props:{id:String,value:String,className:String,disabled:{type:Boolean,default:!1},isDropdown:{type:Boolean,default:!0},isAlpha:{type:Boolean,default:!0},isFormat:{type:Boolean,default:!0},isOperate:{type:Boolean,default:!0},isPreset:{type:Boolean,default:!0},isPlaintext:{type:Boolean,default:!1}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:n=>!0,onInit:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=t.id,l=i,d=e.useTemplateRef("refElDropdownLayer"),u=e.useTemplateRef("refElColorpicker"),r=e.reactive({isInitShow:!t.isDropdown,dropdownTextValue:"",currentValue:""}),c={lastValue:""},m=e.computed(()=>{let M="panel-colorpicker ";const{className:b}=t;return b&&!o.isEmpty(b)&&(M+=b),t.isPlaintext&&(M+="cl-plaintext-static "),M}),p=()=>{const M=r.currentValue;let b=!1;t.isDropdown?b=M!==c.lastValue:b=!0,b&&(c.lastValue=M,l("update:value",M),l("update:modelValue",M),l("onChange",M))},f=M=>{let b="transparent";M&&!o.isEmpty(M)&&(b=M),r.dropdownTextValue=b},h=M=>{const b=M||"";c.lastValue=b,t.isDropdown||(r.currentValue=b),f(b)},g=()=>{const M=u.value.getValue();r.dropdownTextValue=M,r.currentValue=M,p()},y=()=>{h(t.value)};e.watch(()=>t.value,M=>{h(M)}),e.onMounted(()=>{e.nextTick(()=>{y()})});const V=()=>{l("onInit")},E=M=>{t.disabled||(M?u.value&&u.value.initValueType():t.isOperate?r.currentValue!==u.value.getValue()&&r.currentValue===c.lastValue&&u.value.setValue(c.lastValue):g())},B=()=>{r.isInitShow=!0,r.currentValue=c.lastValue},T=()=>{t.isDropdown||g()},D=()=>{g(),t.isDropdown&&d.value&&d.value.setOpen(!1)};return a({getValue:()=>r.currentValue,getValueData:()=>({value:r.currentValue}),setValue:M=>{h(M)}}),(M,b)=>n.isDropdown?(e.openBlock(),e.createBlock(eo,{key:0,ref_key:"refElDropdownLayer",ref:d,id:e.unref(s),classParent:m.value,classDropDown:"panel-colorpicker-dropdown",isUseDropdownArrow:!0,isDisabled:n.disabled,onOnChangeOpen:E,onOnOpenComplete:B},{label:e.withCtx(()=>[e.createElementVNode("div",Rd,[b[0]||(b[0]=e.createElementVNode("div",{class:"panel-colorpicker-bg-alpha"},null,-1)),e.createElementVNode("div",{style:e.normalizeStyle({"background-color":r.dropdownTextValue})},null,4),n.isPlaintext?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)):(e.openBlock(),e.createElementBlock("div",Hd,[e.createVNode(ve,{name:"angle-down"})]))])]),dropdown:e.withCtx(()=>[r.isInitShow?(e.openBlock(),e.createBlock(Ga,{key:0,ref_key:"refElColorpicker",ref:u,value:r.currentValue,isAlpha:n.isAlpha,isFormat:n.isFormat,isOperate:n.isOperate,isPreset:n.isPreset,isDropdown:n.isDropdown,onOnChange:T,onOnSubmit:D,onOnInit:V},null,8,["value","isAlpha","isFormat","isOperate","isPreset","isDropdown"])):e.createCommentVNode("",!0)]),_:1},8,["id","classParent","isDisabled"])):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(m.value)},[r.isInitShow?(e.openBlock(),e.createBlock(Ga,{key:0,ref_key:"refElColorpicker",ref:u,value:r.currentValue,disabled:n.disabled,isAlpha:n.isAlpha,isFormat:n.isFormat,isOperate:n.isOperate,isPreset:n.isPreset,isDropdown:n.isDropdown,onOnChange:T,onOnSubmit:D,onOnInit:V},null,8,["value","disabled","isAlpha","isFormat","isOperate","isPreset","isDropdown"])):e.createCommentVNode("",!0)],2))}}),Ud={class:"imgCropper-container"},zd={style:{position:"relative"}},Jd={class:"imgCropper-main"},Kd={class:"frame-alignline"},Wd={class:"imgCropper-btns"},jd={key:0,class:"imgCropper-upload"},Yd=["id","name"],qd=["for"],Xd={class:"imgCropper-btns-opt"},Gd={key:0,class:"imgCropper-loading-mask"},Qd=["src"],Zd={key:0,class:"imgCropper-loading-mask"},em={key:0,class:"frame-alignline"},Qa=e.defineComponent({name:"ClCropperBase",__name:"Base",props:{className:String,src:{type:String,required:!0},width:{type:Number,required:!0},height:{type:Number,required:!0},isPreview:{type:Boolean,default:!0},previewShape:{type:String,default:"square"},isShowUpload:{type:Boolean,default:!0},isShowSave:{type:Boolean,default:!1},isCenterBox:{type:Boolean,default:!1},fillColor:{type:String,default:"transparent"},alignLine:{type:String,default:"center"},isPreviewAlignLine:{type:Boolean,default:!1}},emits:{onImgLoad:n=>!0,onImgSave:()=>!0},setup(n,{expose:a,emit:i}){const t=e.defineAsyncComponent(()=>import("cropper-next-vue").then(_=>(Promise.resolve().then(()=>require("./index-Dyvby5gX.cjs")),_.VueCropper))),s=n,l=i,d=o.getRandom(8),u=`cropperBase-${d}`,r=e.useTemplateRef("refElCropper"),c=e.ref(!1),m=e.reactive({uploadAgainId:`btnImgCropper_uploadAgain_${d}`,isInitImageLoading:!1}),p=e.reactive({img:"",wrapper:{width:400,height:400},cropLayout:{width:s.width,height:s.height},color:s.fillColor,outputSize:1,outputType:"png",full:!0,original:!1,maxSideLength:3e3,mode:"contain",centerBox:s.isCenterBox,centerWrapper:!1}),f=e.reactive({src:"",style:{},pStyle:{}}),h=e.ref({}),g=e.ref(0),y=e.ref(0),V=e.ref(!0),E=e.computed(()=>{const{alignLine:_}=s;return o.isNonEmptyString(_)?_.split(","):[]}),B=e.computed(()=>{const _={"panel-imgCropper":!0};return o.getJsonMerge(_,de.getClassNameJson(s.className))}),T=e.computed(()=>{const{previewShape:_}=s,R=o.isNonEmptyString(_)?_:"square",P={"imgCropper-preview":!0};return P[`imgCropper-preview-${R}`]=!0,P}),D=e.computed(()=>({width:`${(s.width??0)+6}px`,height:`${(s.height??0)+6}px`,backgroundColor:s.fillColor})),x=()=>{p.cropLayout={width:Math.max(1,s.width??1),height:Math.max(1,s.height??1)}},O=()=>{const{src:_}=s;let R="";if(o.isNonEmptyString(_)){if(_.substring(0,5)!=="data:")if(/^(http|https):\/\/[^\s]+$/.test(_)){const P=`_t=${new Date().getTime()}`,Q=_.indexOf("?")===-1?"?":"&";R=_+Q+P}else R=_;else R=_;m.isInitImageLoading=!0,y.value=0,g.value=0}else m.isInitImageLoading=!1;p.img=R},w=()=>{x(),O()};e.onMounted(()=>{e.nextTick(()=>{w()})}),e.onBeforeUnmount(()=>{V.value=!1}),e.watch(()=>s.src,(_,R)=>{_!==R&&O()}),e.watch(()=>[s.width,s.height,s.fillColor,s.isCenterBox],([_,R,P,Q],[oe,ue,Y,Z])=>{(_!==oe||R!==ue)&&x(),P!==Y&&(p.color=P),Q!==Z&&(p.centerBox=Q)});const M=_=>{if(!_)return;const{url:R,img:P,w:Q,h:oe}=_;f.src=R??"",f.style=P??{},f.pStyle={width:typeof Q=="number"?`${Q}px`:`${s.width}px`,height:typeof oe=="number"?`${oe}px`:`${s.height}px`};const ue=P?.transform?.match(/scale\(([^)]+)\)/);ue&&(g.value=parseFloat(ue[1]),y.value||(y.value=g.value));const Y=Q??s.width,Z=oe??s.height;if(Y>0&&Z>0&&(Y>s.width||Z>s.height)){const se=Math.min(s.width/Y,s.height/Z);h.value={transform:`scale(${se})`}}else h.value={}},b=_=>{if(!_){m.isInitImageLoading=!1,l("onImgLoad",!1);return}const R=_.type==="success";m.isInitImageLoading=!1,l("onImgLoad",R)},N=_=>{const R=_.currentTarget;!R||!R.files||R.files.length===0||(y.value=0,g.value=0,m.isInitImageLoading=!0,o.getBase64ByFile(R.files).then(P=>{if(V.value){if(!P){m.isInitImageLoading=!1;return}p.img=P}}).catch(()=>{V.value&&(m.isInitImageLoading=!1)}))},J=()=>{},q=()=>{r.value?.zoomIn(.02)},z=()=>{r.value?.zoomOut(.02)},H=()=>{r.value?.rotateLeft()},v=()=>{r.value?.rotateRight()},S=()=>{r.value&&(m.isInitImageLoading=!0,r.value.reload())},C=()=>{l("onImgSave")};return a({getImageBase64:()=>r.value?r.value.getCropData("base64"):Promise.reject(new Error("vue-cropper 实例未就绪")),refresh:()=>{if(!r.value){Se.warn("ClCropperBase","refresh 调用无效:vue-cropper 实例未就绪");return}r.value.reload()},loadingStart:()=>{c.value=!0},loadingStop:()=>{c.value=!1}}),(_,R)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(B.value),id:u},[e.createElementVNode("div",Ud,[e.createElementVNode("div",zd,[e.createElementVNode("div",Jd,[e.createVNode(e.unref(t),e.mergeProps({ref_key:"refElCropper",ref:r},p,{onRealTime:M,onImgLoad:b}),{loading:e.withCtx(()=>[...R[0]||(R[0]=[])]),_:1},16),e.createElementVNode("div",Kd,[E.value.indexOf("center")>-1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[R[1]||(R[1]=e.createElementVNode("div",{class:"alignline-h alignline-center-h"},null,-1)),R[2]||(R[2]=e.createElementVNode("div",{class:"alignline-v alignline-center-v"},null,-1))],64)):E.value.indexOf("nineGrid")>-1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[R[3]||(R[3]=e.createElementVNode("div",{class:"alignline-h alignline-nineGrid-h1"},null,-1)),R[4]||(R[4]=e.createElementVNode("div",{class:"alignline-h alignline-nineGrid-h2"},null,-1)),R[5]||(R[5]=e.createElementVNode("div",{class:"alignline-v alignline-nineGrid-v1"},null,-1)),R[6]||(R[6]=e.createElementVNode("div",{class:"alignline-v alignline-nineGrid-v2"},null,-1))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))])]),e.createElementVNode("div",Wd,[e.createElementVNode("div",null,[n.isShowUpload?(e.openBlock(),e.createElementBlock("div",jd,[e.createElementVNode("input",{type:"file",id:m.uploadAgainId,name:m.uploadAgainId,accept:"image/jpg,image/jpeg,image/pjpeg,image/png,image/x-png",onChange:N},null,40,Yd),e.createElementVNode("label",{for:m.uploadAgainId},[e.createElementVNode("span",{title:"重新上传",onClick:e.withModifiers(J,["stop"])},[e.createVNode(ve,{name:"upload"})])],8,qd)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),e.createElementVNode("div",Xd,[e.createElementVNode("span",{title:"放大","aria-label":"放大",role:"button",tabindex:"0",onClick:e.withModifiers(q,["stop"])},[e.createVNode(ve,{name:"search-plus"})]),e.createElementVNode("span",{title:"缩小","aria-label":"缩小",role:"button",tabindex:"0",onClick:e.withModifiers(z,["stop"])},[e.createVNode(ve,{name:"search-minus"})]),e.createElementVNode("span",{title:"左转90°","aria-label":"左转90度",role:"button",tabindex:"0",onClick:e.withModifiers(H,["stop"])},[e.createVNode(ve,{name:"rotate-left"})]),e.createElementVNode("span",{title:"右转90°","aria-label":"右转90度",role:"button",tabindex:"0",onClick:e.withModifiers(v,["stop"])},[e.createVNode(ve,{name:"rotate-right"})]),e.createElementVNode("span",{title:"重置","aria-label":"重置",role:"button",tabindex:"0",onClick:e.withModifiers(S,["stop"])},[e.createVNode(ve,{name:"restore"})]),n.isShowSave?(e.openBlock(),e.createElementBlock("span",{key:0,title:"保存","aria-label":"保存",role:"button",tabindex:"0",onClick:e.withModifiers(C,["stop"])},[e.createVNode(ve,{name:"save"})])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])]),c.value||m.isInitImageLoading?(e.openBlock(),e.createElementBlock("div",Gd,[e.createVNode(lt,{theme:"circleSpinner",size:"large"})])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),n.isPreview?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(T.value),style:e.normalizeStyle(D.value)},[e.createElementVNode("div",{style:e.normalizeStyle(h.value)},[e.createElementVNode("div",{style:e.normalizeStyle(f.pStyle)},[e.createElementVNode("img",{src:f.src,style:e.normalizeStyle(f.style),alt:""},null,12,Qd)],4),c.value||m.isInitImageLoading?(e.openBlock(),e.createElementBlock("div",Zd)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],4),n.isPreviewAlignLine?(e.openBlock(),e.createElementBlock("div",em,[E.value.indexOf("center")>-1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[R[7]||(R[7]=e.createElementVNode("div",{class:"alignline-h alignline-center-h"},null,-1)),R[8]||(R[8]=e.createElementVNode("div",{class:"alignline-v alignline-center-v"},null,-1))],64)):E.value.indexOf("nineGrid")>-1?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[R[9]||(R[9]=e.createElementVNode("div",{class:"alignline-h alignline-nineGrid-h1"},null,-1)),R[10]||(R[10]=e.createElementVNode("div",{class:"alignline-h alignline-nineGrid-h2"},null,-1)),R[11]||(R[11]=e.createElementVNode("div",{class:"alignline-v alignline-nineGrid-v1"},null,-1)),R[12]||(R[12]=e.createElementVNode("div",{class:"alignline-v alignline-nineGrid-v2"},null,-1))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])],2))}}),tm=["id"],nm={style:{display:"flex","justify-content":"center"}},sa=e.defineComponent({name:"ClCropper",__name:"Index",props:{id:String,className:String,src:{type:String,required:!0},width:{type:Number,required:!0},height:{type:Number,required:!0},isCenterBox:{type:Boolean,default:!1},isPreview:{type:Boolean,default:!0},previewShape:{type:String,default:"square"},isModal:{type:Boolean,default:!0},isShowUpload:{type:Boolean,default:!0},isShowSave:{type:Boolean,default:!1},fillColor:{type:String,default:"transparent"},alignLine:{type:String,default:"center"},isPreviewAlignLine:{type:Boolean,default:!1}},emits:{onSubmit:n=>!0,onImgLoad:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id||`cropper-${o.getRandom(8)}`,d=e.useTemplateRef("refElModal"),u=e.useTemplateRef("refElCropper"),r=e.ref(!t.isModal),c=e.computed(()=>{const O={"panel-cropper":!0};return o.getJsonMerge(O,de.getClassNameJson(t.className))}),m=e.computed(()=>{const{isModal:O,id:w,className:M,...b}=t;return t.isModal?{...b,isShowSave:!1}:b}),p=()=>u.value?u.value.getImageBase64():Promise.reject(new Error("Cropper 未挂载")),f=(O,w,M)=>{s("onSubmit",{success:!w,data:O,msg:w}),M&&d.value?.hide()},h=()=>p().then(O=>{f(O,"",!0)}).catch(O=>{const w=o.isString(O)?O:O?.message||"裁剪失败";f("",w,!0)}),g=O=>{s("onImgLoad",O)},y=()=>p().then(O=>{f(O,"")}).catch(O=>{const w=o.isString(O)?O:O?.message||"保存失败";f("",w)});return a({getImageBase64:()=>p(),refresh:()=>{u.value?u.value.refresh():Se.warn("ClCropper","refresh 调用无效:Cropper 未挂载")},show:()=>{d.value&&t.isModal?(r.value=!0,d.value.show()):Se.warn("ClCropper","show 调用无效:非弹窗模式或 Modal 未挂载")},showAndReset:()=>{d.value&&t.isModal?(r.value=!1,d.value.show(),e.nextTick(()=>{r.value=!0})):Se.warn("ClCropper","showAndReset 调用无效:非弹窗模式或 Modal 未挂载")},loadingStart:()=>{u.value?u.value.loadingStart():Se.warn("ClCropper","loadingStart 调用无效:Cropper 未挂载")},loadingStop:()=>{u.value?u.value.loadingStop():Se.warn("ClCropper","loadingStop 调用无效:Cropper 未挂载")}}),(O,w)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(c.value)},[n.isModal?(e.openBlock(),e.createBlock(na,{key:0,ref_key:"refElModal",ref:d,width:"850px",titleName:"图片裁切",isShowSubmitLoad:!1,closeLabel:"取消",submitLabel:"确定",onOnSubmit:h},{default:e.withCtx(()=>[e.createElementVNode("div",nm,[r.value?(e.openBlock(),e.createBlock(Qa,e.mergeProps({key:0,ref_key:"refElCropper",ref:u},m.value,{onOnImgLoad:g}),null,16)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])]),_:1},512)):(e.openBlock(),e.createBlock(Qa,e.mergeProps({key:1,ref_key:"refElCropper",ref:u},m.value,{onOnImgLoad:g,onOnImgSave:y}),null,16))],10,tm))}}),Ye={format:{img:["jpg","jpe","jpeg","png","gif","bmp","ico"],video:["mp4","rmvb","3gp","avi","asf","asf","dv","mov","mpg4","mpeg","mpg","wm","wmx","flv","mkv","mp4a","rm","wmv","swf","swfl"],audio:["mp3","ogg","wav","wma","mid","ra","ram"],zip:["rar","zip"],excel:["xls","xlsx","csv"],pdf:["pdf"],txt:["txt"],doc:["doc","docx"]},icon:{img:"image",video:"video",audio:"music",txt:"text",zip:"zip",excel:"excel",pdf:"pdf",doc:"word",default:"file"},suffix:{jpg:["jpg","jpe","jpeg"],jpe:["jpg","jpe","jpeg"],jpeg:["jpg","jpe","jpeg"],png:["png"],gif:["gif"],bmp:["bmp"],ico:["ico"],mp4:["mp4"],rmvb:["rmvb"],"3gp":["3gp"],avi:["avi"],asf:["asf"],dv:["dv"],mov:["mov"],mpg4:["mpg4"],mpeg:["mpeg"],mpg:["mpg"],wm:["wm"],wmx:["wmx"],flv:["flv"],mkv:["mkv"],mp4a:["mp4a"],rm:["rm"],wmv:["wmv"],swf:["swf"],swfl:["swfl"],mp3:["mp3"],ogg:["ogg"],wav:["wav"],wma:["wma"],mid:["mid"],ra:["ra"],ram:["ram"],rar:["rar"],zip:["zip"],txt:["txt"],xls:["xls","xlsx","csv"],xlsx:["xls","xlsx","csv"],csv:["xls","xlsx","csv"],pdf:["pdf"],doc:["doc","docx"]},mime:{jpg:["image/jpg","image/jpeg","image/pjpeg"],jpe:["image/jpg","image/jpeg","image/pjpeg"],jpeg:["image/jpg","image/jpeg","image/pjpeg"],png:["image/png","image/x-png"],gif:["image/gif"],bmp:["image/bmp"],ico:["ico"],mp4:["video/mp4"],rmvb:["audio/x-pn-realaudio"],"3gp":["video/3gpp"],avi:["video/x-msvideo"],asf:["video/x-ms-asf"],dv:["video/x-dv"],mov:["video/quicktime"],mpg4:["video/mp4"],mpeg:["video/mpeg"],mpg:["video/mpeg"],wm:["video/x-ms-wmv"],wmx:["video/x-ms-wmx"],flv:["video/x-flv"],mkv:["video/x-matroska"],mp4a:["audio/mp4"],rm:["audio/x-pn-realaudio"],wmv:["audio/x-ms-wmv"],swf:["application/x-shockwave-flash"],swfl:["application/x-shockwave-flash"],mp3:["audio/mpeg"],ogg:["audio/ogg"],wav:["audio/wav"],wma:["audio/x-ms-wma"],mid:["audio/midi"],ra:["audio/x-pn-realaudio"],ram:["audio/x-pn-realaudio"],rar:["application/x-rar-compressed"],zip:["application/zip","application/x-zip-compressed"],txt:["text/plain"],xls:["application/vnd.ms-excel","application/wps-office.xls"],xlsx:["application/vnd.openxmlformats-officedocument.spreadsheetml.sheet","application/wps-office.xlsx"],csv:["text/csv"],pdf:["application/pdf"],doc:["application/msword"],docx:["application/vnd.openxmlformats-officedocument.wordprocessingml.document"]},getFormatGroup:n=>{let a=[];return o.isNonEmptyString(n)&&(n.split(",").forEach(t=>{for(const[s,l]of Object.entries(Ye.format))o.isExistValue(l,t.toLocaleLowerCase())&&a.push(s)}),a=o.getArrUnique(a)),a},getIcon:n=>{let a="";return o.isEmpty(n)?a=Ye.icon.default:a=o.isExistJsonKey(Ye.icon,n)?Ye.icon[n]:Ye.icon.default,a},getSuffix:n=>{let a=[];return o.isEmpty(n)||(n.forEach(i=>{const t=Ye.suffix[i.toLocaleLowerCase()];o.isUndefined(t)||(a=a.concat(t))}),o.isEmpty(a)&&(a=n)),a=o.getArrUnique(a),a},getRegexBySuffix:n=>{if(o.isEmpty(n))return null;const a=`\\.(?:${n.join("|")})$`;return new RegExp(a,"i")},getMime:n=>{let a=[];return o.isEmpty(n)||n.forEach(i=>{const t=Ye.mime[i];o.isUndefined(t)||(a=a.concat(t))}),a=o.getArrUnique(a),a},getRegexByMime:n=>{if(o.isEmpty(n))return null;const a=`^(?:${n.join("|").replace(/\//g,"\\/")})$`;return new RegExp(a,"i")},getImageThumbnail:(n,a,i)=>{let t=null;try{const s=document.createElement("canvas");s.width=a,s.height=i,s.getContext("2d").drawImage(n,0,0,n.width,n.height,0,0,a,i),t=s.toDataURL("image/gif")}catch{t=null}return t}},as=(n,a)=>{let i=n;const t=e.reactive({mime:[],suffix:[],isCheckImgWH:!1});let s=null;const l=E=>{i=o.getJsonMerge(i,E),u()},d=E=>{const B=i.checkMsg;return o.isString(B)&&!o.isEmpty(B)?B:o.isObject(B)&&!o.isEmpty(B[E])?B[E]:a.value[E]},u=()=>{const E=o.isNonEmptyString(i.checkFormat)?Ye.getSuffix(i.checkFormat.split(",")):[],B=Ye.getMime(E),T=!o.isEmpty(i.checkWidth)&&!o.isEmpty(i.checkHeight);t.mime=B,t.suffix=E,t.isCheckImgWH=T},r=E=>{const B=Ye.getIcon(E);return{type:E,icon:B,isImage:E==="img",isVideo:E==="video",isAudio:E==="audio",isTxt:E==="txt",isZip:E==="zip"}},c=(E,B)=>{if(o.isUndefined(s)){s={};for(const[D,x]of Object.entries(Ye.format)){const O=Ye.getSuffix(x),w=Ye.getMime(O),M=Ye.getRegexBySuffix(O),b=Ye.getRegexByMime(w);s[D]={suffix:O,mime:w,regSuffix:M,regMime:b}}}let T="";return Object.keys(s).forEach(D=>{if(T.length===0){const x=s[D];(x.regSuffix&&x.regSuffix.test(E)||B&&x.regMime&&x.regMime.test(B))&&(T=D)}}),r(T)},m=E=>{const B=Ye.getFormatGroup(o.isEmpty(E)?i.checkFormat:E),T=B.length===1?B[0]:"";return r(T)},p=E=>{if(!o.isString(E))return c("");if(E.startsWith("data:")||E.startsWith("blob:")){const T=E.match(/^[a-z]+:([a-zA-Z0-9.+-]+\/[a-zA-Z0-9.+-]+)/);return c("",T?T[1]:"")}const B=E.substring(E.lastIndexOf("/")+1).split("?")[0].split("#")[0];return c(B)},f=(E,B,T,D,x)=>{const O=o.isFinite(T)&&T>0?T:0,w=o.isFinite(D)&&D>0?D:0;let M=x;(M==="height"||M==="contain")&&w===0&&(M="width");let b=1;switch(M){case"height":b=w>0?w/B:1;break;case"contain":b=Math.min(O>0?O/E:1,w>0?w/B:1);break;case"width":default:b=O>0?O/E:1;break}return b>1&&(b=1),{tw:Math.round(E*b),th:Math.round(B*b)}},h=(E,B,T,D)=>new Promise((x,O)=>{const w=document.createElement("img");w.onload=M=>{const b=M.target.width,N=M.target.height,{tw:J,th:q}=f(b,N,B,T,D),z=M.target.src;x({src:z,w:b,h:N,tw:J,th:q,isImage:!0})},w.onerror=()=>{O(new Error("fail: temp create image"))},w.src=E}),g=(E,B)=>{const T=o.isEmpty(i.checkWidth)?0:parseInt(i.checkWidth,10),D=o.isEmpty(i.checkHeight)?0:parseInt(i.checkHeight,10);if(!o.isFinite(T)||!o.isFinite(D)||T===0||D===0)return!0;let x=!0;switch(i.checkWHType){case"greater":x=E>=T&&B>=D;break;case"less":x=E<=T&&B<=D;break;case"equal":x=E===T&&B===D;break;default:x=!0;break}return x},y=(E,B)=>new Promise((T,D)=>{if(E instanceof File){const x=new FileReader;x.onload=O=>{h(O.target.result,B.maxWidth,B.maxHeight,B.imgFit).then(w=>{(t.isCheckImgWH?g(w.w,w.h):!0)?T(w):D(new Error(d("checkImageWHLabel")))}).catch(w=>{D(w)})},x.onerror=()=>{D(new Error("fail: new FileReader image onload()"))},x.readAsDataURL(E)}else D(new Error("fail: file is not a File instance"))}),V=async(E,B)=>{let T=[];const D=[],x=[],O=Ye.getRegexBySuffix(t.suffix),w=Ye.getRegexByMime(t.mime),M=q=>{const z=o.isEmpty(q)?NaN:parseInt(q,10);return o.isFinite(z)?z*1024:null},b=M(i.checkMinSize),N=M(i.checkMaxSize),J=E.length;for(let q=0;q<J;q+=1){const z=[],H=E[q],v={suffix:!1,mime:!1,size:!1},S=H.name;O&&!O.test(S)&&(v.suffix=!0);const C=H.type;!o.isEmpty(C)&&w&&!w.test(C)&&(v.mime=!0),b&&H.size<b&&(v.size=!0),N&&H.size>N&&(v.size=!0),(v.suffix||v.mime)&&z.push(d("checkSuffixMimeLabel")),v.size&&z.push(d("checkSizeLabel"));const $=c(S,C);let k=null;$.isImage&&(k=await y(H,B).catch(I=>{z.push(I.message)})),o.isUndefined(k)&&(k={}),k=o.getJsonMerge(k,$),k.fileName=S,k.file=H,z.length===0?(D.push(H),x.push(k)):J===1?T=z.map(I=>`${d("uploadFile")} ${I}`):T.push(`${S}:${z.join(",")}`)}return new Promise(q=>{setTimeout(()=>{q({errorMsg:T,passFiles:D,passFilesInfo:x,original:E})},200)})};return u(),{optBase:t,getTypeByFormat:m,getTypeByUrl:p,createTempImg:h,checkFile:V,setBaseOptions:l}},is=()=>({setFileInfo:(a,i)=>{const t=i&&i.fileUrl?i.fileUrl:"";if(!o.isString(t))return{name:"",url:"",imgSrc:"",imgWidth:0,imgHeight:0};const s=o.isEmpty(t);let l="";s||t.startsWith("blob:")?l=a.fileName:l=t.substr(t.lastIndexOf("/")+1);let d="",u=0,r=0;return a.isImage&&(d=s?a.src:t,u=a.tw||0,r=a.th||0),{name:l,url:t,imgSrc:d,imgWidth:u,imgHeight:r}}}),ss=()=>{const n=(i,t)=>{window.open(i)};return{downloadHref:n,downloadBlob:i=>{if(!o.isEmpty(i)){const t=i.lastIndexOf("/"),s=i.substring(t+1),l=i.replace(/\\/g,"/"),d=new XMLHttpRequest;d.open("GET",l,!0),d.responseType="blob",d.onload=()=>{if(d.status===200){const u=window.URL||window.webkitURL||window,r=new Blob([d.response]),c=document.createElementNS("http://www.w3.org/1999/xhtml","a");c.href=u.createObjectURL(r),c.download=s,c.click(),setTimeout(()=>URL.revokeObjectURL(c.href),1e3)}else n(i)},d.onerror=()=>{n(i)},d.send()}}}},om=["name","accept"],am=["name"],im={class:"fileUpload-label"},sm={key:0,class:"fileUpload-img"},lm={class:"fileUpload-img-container"},rm=["src","width","height"],cm={key:0,class:"file-complete-img-msg"},um=["title"],dm=["title"],mm={key:1,class:"fileUpload-video"},pm=["src"],fm=["title"],hm={key:2,class:"fileUpload-file"},gm=["title"],ym={key:0,class:"fileUpload-load"},vm=e.defineComponent({name:"ClFileUploadDefault",__name:"Default",props:{name:String,value:[String,Array,Object],className:String,disabled:{type:Boolean,default:!1},defaultHoverTitle:String,defaultIcon:String,checkFormat:String,checkMinSize:[String,Number],checkMaxSize:[String,Number],checkWidth:[String,Number],checkHeight:[String,Number],checkWHType:{type:String,default:"equal",validator:n=>["equal","greater","less"].includes(n)},imgFit:{type:String,default:"width",validator:n=>["width","height","contain"].includes(n)},isServerCallback:Boolean,isShowPreview:{type:Boolean,default:!0},isShowDownload:{type:Boolean,default:!0},isShowCompleteMsg:{type:Boolean,default:!0}},emits:["onChange","onError","onRemove","onPreview","onSaveFile"],setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("fileUpload");const u=e.inject("$FileuploadTop",null);u||Se.warn("FileUpload","Default 主题缺少 $FileuploadTop 注入,使用空校验配置");const{setFileInfo:r}=is(),c=()=>o.getJsonMerge(u?.getFileCheckInfo()??{},{checkFormat:t.checkFormat,checkWidth:t.checkWidth,checkHeight:t.checkHeight,checkWHType:t.checkWHType,checkMinSize:t.checkMinSize,checkMaxSize:t.checkMaxSize}),{optBase:m,getTypeByFormat:p,getTypeByUrl:f,createTempImg:h,checkFile:g,setBaseOptions:y}=as(c(),l),{downloadBlob:V,downloadHref:E}=ss(),B=e.useTemplateRef("refElTopParent"),T=()=>{const A=B.value;if(!A)return{maxWidth:0,maxHeight:0};const te=4,ce=A.clientWidth>0?Math.max(A.clientWidth-te,0):0;let pe=0;if(t.imgFit==="height"||t.imgFit==="contain"){const he=A.parentElement;he&&he.clientHeight>0&&(pe=getComputedStyle(he).height==="auto"?0:Math.max(he.clientHeight-te,0))}return{maxWidth:ce,maxHeight:pe}},D=e.reactive({isImage:!1,isVideo:!1,icon:"",completeMsgTxt:"",isInitFileInput:!0,runOperateType:"init"}),x=e.reactive({name:"",url:"",imgSrc:"",imgWidth:0,imgHeight:0}),O={file:null};let w=0,M=null;const b=`fileUpload_${o.getRandom(8)}`,N=e.computed(()=>{let A=t.name;return o.isEmpty(A)&&(A=`fileUpload_${o.getRandom(8)}`),A}),J=e.computed(()=>{let A={"fileUpload-default":!0};return A=o.getJsonMerge(A,de.getClassNameJson(t.className)),A}),q=e.computed(()=>({"fileUpload-wait":!0,"fileUpload-disabled":t.disabled})),z=e.computed(()=>({"fileUpload-complete":!0,"fileUpload-disabled":t.disabled})),H=A=>{s("onChange",A)},v=A=>{s("onError",A)},S=()=>{s("onRemove")},C=(A,te)=>{s("onPreview",A,te)},$=(A,te)=>{s("onSaveFile",A,te)},k=A=>{D.isImage=A.isImage,D.isVideo=A.isVideo,D.icon=A.icon},I=()=>{const A=p();o.isNonEmptyString(t.defaultIcon)&&(A.icon=t.defaultIcon),k(A)},L=A=>{A!=="load"&&(D.isInitFileInput=!0);let te="";switch(A){case"remove":case"clean":{te="init",I();break}case"fail":{let ce=!0;D.isImage?(!o.isEmpty(x.url)||!o.isEmpty(x.imgSrc))&&(ce=!1):o.isEmpty(x.url)||(ce=!1),te=ce?"init":"complete";break}default:te=A}D.runOperateType=te},_=A=>{const te=x;for(const[ce,pe]of Object.entries(A))o.isUndefined(te[ce])||(te[ce]=pe);O.file=A.file??O.file},R=(A,te)=>{ue(),k(A);const ce=r(A,te);_(ce),L("complete")},P=()=>{let A=null;return o.isString(x.url)&&x.url.startsWith("blob:")?A=O.file:o.isEmpty(x.url)?D.isImage&&!o.isEmpty(x.imgSrc)?A=x.imgSrc:A=O.file:A=x.url,o.isUndefined(A)&&(A=""),A},Q=A=>{if(A.length>0&&D.runOperateType!=="load"){D.isInitFileInput=!1,L("load"),w+=1;const te={...T(),imgFit:t.imgFit};g(A,te).then(ce=>{if(D.runOperateType==="load")if(ce.passFiles.length>0){const pe=ce.passFiles[0],he=ce.passFilesInfo[0];if(he.isImage)t.isServerCallback?($(pe,he),Z()):(R(he,{}),O.file=pe,H(he.src));else if(t.isServerCallback)$(pe,he),Z();else{const Ee={};if(he.isVideo){const be=URL.createObjectURL(pe);Ee.fileUrl=be}R(he,Ee),O.file=pe,H(pe)}}else L("fail"),ce.errorMsg.length>0&&v(ce.errorMsg)}).catch(()=>{D.runOperateType==="load"&&(L("fail"),v(["文件校验失败,请重试"]))})}},oe=A=>{if(!o.isNonEmptyString(A)){(o.isString(A)||o.isUndefined(A))&&se();return}const te=++w,ce=f(A);if(D.isImage&&ce.isImage){const{maxWidth:pe,maxHeight:he}=T();h(A,pe,he,t.imgFit).then(Ee=>{if(te!==w)return;const be=o.getJsonMerge(Ee,ce);R(be,{fileUrl:A})}).catch(()=>{te===w&&(L("fail"),v(["图片加载失败,请检查图片地址"]))})}else R(ce,{fileUrl:A})},ue=()=>{o.isString(x.url)&&x.url.startsWith("blob:")&&URL.revokeObjectURL(x.url)},Y=()=>{M&&(clearTimeout(M),M=null)},Z=()=>{Y(),M=setTimeout(()=>{D.runOperateType==="load"&&(L("fail"),v(["服务端保存超时,请重试"]))},6e4)},se=()=>{w+=1,O.file=null,_({name:"",url:"",imgSrc:"",imgWidth:0,imgHeight:0}),L("init")},K=()=>{if(o.isEmpty(t.value)){I();return}k(f(t.value))},W=()=>{let A=t.defaultHoverTitle;D.isImage&&m.isCheckImgWH&&o.isEmpty(A)&&(A=`${t.checkWidth}x${t.checkHeight}`),D.completeMsgTxt=A},U=()=>{K(),W(),oe(t.value)};e.onMounted(()=>{e.nextTick(()=>{U()})}),e.watch(()=>t.value,(A,te)=>{if(A!==te){const ce=P();A!==ce&&(Y(),K(),oe(A))}}),e.watch([()=>t.checkFormat,()=>t.checkWidth,()=>t.checkHeight,()=>t.checkWHType,()=>t.checkMinSize,()=>t.checkMaxSize],()=>{if(Y(),y(c()),K(),W(),D.runOperateType==="load")return;const A=P();t.value===A&&oe(t.value)});const ae=A=>{A.preventDefault(),A.stopPropagation(),!t.disabled&&A.dataTransfer&&Q(A.dataTransfer.files)},G=A=>{t.disabled||Q(A.currentTarget.files)},X=()=>{Y(),w+=1,ue(),O.file=null,_({name:"",url:"",imgSrc:"",imgWidth:0,imgHeight:0}),L("remove");const A=document.getElementById(b);A&&(A.value=""),S()},ee=A=>{const te=o.isEmpty(x.url)?x.imgSrc:x.url;C(te,"image"),A.preventDefault(),A.stopPropagation()},F=A=>{o.isEmpty(x.url)||C(x.url,"video"),A.preventDefault(),A.stopPropagation()},j=A=>{o.isEmpty(x.url)?E(x.imgSrc,x.name):V(x.url),A.preventDefault(),A.stopPropagation()},le=A=>{if(o.isString(x.url)&&x.url.startsWith("blob:")){const te=document.createElement("a");te.href=x.url,te.download=x.name,te.click()}else V(x.url);A.preventDefault(),A.stopPropagation()};return a({saveServerCallback:A=>{if(Y(),D.runOperateType!=="load")return;if(!A||!A.res||!o.isBoolean(A.res.success)){L("fail"),v(["文件保存失败,请重试"]);return}if(!A.res.success){L("fail"),v(["文件保存失败,请重试"]);return}if(!A.req){L("fail"),v(["文件保存失败,请重试"]);return}let te="";if(o.isString(A.res.fileUrl)?te=A.res.fileUrl:o.isArray(A.res.fileUrl)&&A.res.fileUrl.length>0&&o.isString(A.res.fileUrl[0])&&(te=A.res.fileUrl[0]),o.isEmpty(te)){O.file=null,_({name:"",url:"",imgSrc:"",imgWidth:0,imgHeight:0}),L("init");return}R(A.req,{fileUrl:te}),H(te)},getValue:()=>P(),cleanReduction:()=>{Y(),w+=1,ue(),O.file=null,_({name:"",url:"",imgSrc:"",imgWidth:0,imgHeight:0}),L("clean")}}),e.onBeforeUnmount(()=>{Y(),ue()}),(A,te)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(J.value),ref_key:"refElTopParent",ref:B},[e.createElementVNode("div",{class:"fileUpload-default-container",onDrop:ae,onDragover:te[0]||(te[0]=e.withModifiers(()=>{},["prevent"]))},[e.createElementVNode("label",{for:b},[D.isInitFileInput&&!n.disabled?(e.openBlock(),e.createElementBlock("input",{key:0,type:"file",id:b,name:N.value,onChange:G,accept:e.unref(m).mime.join(",")},null,40,om)):(e.openBlock(),e.createElementBlock("input",{key:1,id:b,name:N.value,style:{display:"none !important"}},null,8,am)),D.runOperateType==="init"?(e.openBlock(),e.createElementBlock("span",{key:2,class:e.normalizeClass(q.value)},[e.createVNode(ve,{name:D.icon,class:"fileUpload-icon"},null,8,["name"]),e.createElementVNode("span",im,[e.renderSlot(A.$slots,"label")])],2)):D.runOperateType==="complete"?(e.openBlock(),e.createElementBlock("span",{key:3,class:e.normalizeClass(z.value)},[D.isImage?(e.openBlock(),e.createElementBlock("span",sm,[e.createElementVNode("span",lm,[e.createElementVNode("img",{src:x.imgSrc,width:x.imgWidth,height:x.imgHeight},null,8,rm)]),n.isShowCompleteMsg?(e.openBlock(),e.createElementBlock("span",cm,e.toDisplayString(D.completeMsgTxt),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isShowPreview&&!n.disabled?(e.openBlock(),e.createElementBlock("i",{key:2,class:"preview-icon",title:e.unref(l).common.preview,onClick:e.withModifiers(ee,["stop"])},[e.createVNode(ve,{name:"search-plus"})],8,um)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),n.isShowDownload&&!n.disabled?(e.openBlock(),e.createElementBlock("i",{key:4,class:"download-icon",title:e.unref(l).common.download,onClick:e.withModifiers(j,["stop"])},[e.createVNode(ve,{name:"download"})],8,dm)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))])):D.isVideo?(e.openBlock(),e.createElementBlock("span",mm,[e.createElementVNode("video",{src:x.url},null,8,pm),n.isShowPreview&&!n.disabled?(e.openBlock(),e.createElementBlock("span",{key:0,class:"preview-icon",onClick:e.withModifiers(F,["stop"])},[e.createVNode(ve,{name:"play"})])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isShowDownload&&!n.disabled?(e.openBlock(),e.createElementBlock("i",{key:2,class:"download-icon",title:e.unref(l).common.download,onClick:e.withModifiers(le,["stop"])},[e.createVNode(ve,{name:"download"})],8,fm)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])):(e.openBlock(),e.createElementBlock("span",hm,[e.createVNode(ve,{name:D.icon,class:"fileUpload-icon"},null,8,["name"]),e.createElementVNode("span",null,e.toDisplayString(x.name),1)])),n.disabled?(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64)):(e.openBlock(),e.createElementBlock("a",{key:3,class:"file-complete-remove",href:"javascript:",title:e.unref(l).common.delete,onClick:e.withModifiers(X,["stop"])},[e.createVNode(ve,{name:"close"})],8,gm))],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64))])],32),D.runOperateType==="load"?(e.openBlock(),e.createElementBlock("div",ym,[e.createVNode(lt,{theme:"circleBubble",size:"large"})])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],2))}}),km=["id","name","multiple","accept"],Sm=["id","name","disabled","accept"],wm=["for"],Em={key:0,class:"fileUpload-list"},bm={key:0,class:"fileUpload-item-icon fileUpload-item-img"},Cm=["src"],xm=["title","onClick"],Bm={key:1,class:"fileUpload-item-icon fileUpload-item-video"},Dm=["src"],Im=["onClick"],Tm={class:"fileUpload-item-name"},Nm={class:"fileUpload-item-operate"},Vm=["title","onClick"],_m=["title","onClick"],Mm=e.defineComponent({name:"ClFileUploadButton",__name:"Button",props:{name:String,value:[String,Array,Object],className:String,disabled:{type:Boolean,default:!1},isMultiple:Boolean,buttonClass:String,buttonLabel:String,buttonIcon:{type:String,default:""},buttonColor:{type:String,default:"default"},checkFormat:String,checkMinSize:[String,Number],checkMaxSize:[String,Number],checkWidth:[String,Number],checkHeight:[String,Number],checkWHType:{type:String,default:"equal",validator:n=>["equal","greater","less"].includes(n)},isServerCallback:Boolean,isShowUploadResult:{type:Boolean,default:!0},isShowUploadIng:{type:Boolean,default:!0},isShowPreview:{type:Boolean,default:!0},isShowDownload:{type:Boolean,default:!0}},emits:["onChange","onError","onRemove","onPreview","onSaveFile"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=`fileupload-${o.getRandom(5)}`,{optPageLanguage:d,getPageLanguage:u}=Le();u("fileUpload");const r=e.inject("$FileuploadTop",null);r||Se.warn("FileUpload","Button 主题缺少 $FileuploadTop 注入,使用空校验配置");const c=()=>o.getJsonMerge(r?.getFileCheckInfo()??{},{checkFormat:t.checkFormat,checkWidth:t.checkWidth,checkHeight:t.checkHeight,checkWHType:t.checkWHType,checkMinSize:t.checkMinSize,checkMaxSize:t.checkMaxSize}),{setFileInfo:m}=is(),{optBase:p,getTypeByUrl:f,checkFile:h,setBaseOptions:g}=as(c(),d),{downloadBlob:y,downloadHref:V}=ss(),E=e.useTemplateRef("refElButton"),B=e.useTemplateRef("refElLabel"),T=o.getRandom(8),D=e.reactive({elFileId:`btnFile${T}`,isInitFileInput:!0}),x=e.ref([]),O=e.ref([]);let w=null,M=null,b=null;const N=e.computed(()=>{let G=t.name;return o.isEmpty(G)&&(G=`fileUpload_${o.getRandom(8)}`),G}),J=e.computed(()=>{let G={"fileUpload-button":!0};return G=o.getJsonMerge(G,de.getClassNameJson(t.className)),G}),q=(G,X)=>{s("onChange",G,X)},z=G=>{s("onError",G)},H=()=>{s("onRemove")},v=(G,X,ee)=>{s("onPreview",G,X,ee)},S=(G,X)=>{s("onSaveFile",G,X)},C=()=>{$(),w=setTimeout(()=>{w=null,D.isInitFileInput||(I("fail"),z(["服务端保存超时,请重试"]))},6e4)},$=()=>{w&&(clearTimeout(w),w=null)},k=()=>{x.value.forEach(G=>{o.isString(G.url)&&G.url.startsWith("blob:")&&URL.revokeObjectURL(G.url)})},I=G=>{switch(G){case"load":t.isShowUploadIng&&E.value?.loadStart();break;case"fail":case"complete":t.isShowUploadIng&&E.value?.loadStop();break}D.isInitFileInput=G!=="load"},L=(G,X)=>{t.isMultiple||(k(),x.value=[]);const ee=[],F=[];x.value.forEach(j=>{ee.push(j),F.push(j.rId)});for(let j=0;j<G.length;j++){let le=X.length>j?{fileUrl:X[j]}:{};o.isEmpty(le.fileUrl)&&G[j].isVideo&&G[j].file&&(le={fileUrl:URL.createObjectURL(G[j].file)});let me=m(G[j],le);me.rId=o.getRandom(9),me=o.getJsonMerge(G[j],me),ee.push(me),F.push(me.rId)}x.value=ee,I("complete"),e.nextTick(()=>{O.value=F})},_=()=>{const G=[];return x.value.forEach(X=>{let ee=null;o.isString(X.url)&&X.url.startsWith("blob:")?ee=X.file:o.isEmpty(X.url)?X.isImage&&!o.isEmpty(X.imgSrc)?ee=X.imgSrc:ee=X.file:ee=X.url,o.isUndefined(ee)||G.push(ee)}),G.length===0?"":t.isMultiple?G:G[0]},R=G=>{if(o.isArray(G)){k(),x.value=[];const F=[],j=[];G.forEach(le=>{if(o.isNonEmptyString(le)){const me=f(le);F.push(me),j.push(le)}}),L(F,j);return}if(!o.isNonEmptyString(G)){o.isString(G)&&P();return}k(),x.value=[];const X=[],ee=[];G.split(",").filter(F=>o.isNonEmptyString(F)).forEach(F=>{const j=f(F);X.push(j),ee.push(F)}),L(X,ee)},P=()=>{k(),I("init"),x.value=[]},Q=()=>{R(t.value)};e.onMounted(()=>{e.nextTick(()=>{Q()})}),e.onBeforeUnmount(()=>{$(),M&&(clearTimeout(M),M=null),k()}),e.watch(()=>t.value,(G,X)=>{if(G!==X){const ee=_();G!==ee&&($(),R(G))}}),e.watch([()=>t.checkFormat,()=>t.checkWidth,()=>t.checkHeight,()=>t.checkWHType,()=>t.checkMinSize,()=>t.checkMaxSize],()=>{D.isInitFileInput&&$(),g(c())});const oe=G=>{t.disabled||D.isInitFileInput&&G.currentTarget.files.length>0&&(I("load"),h(G.currentTarget.files,{}).then(X=>{if(!D.isInitFileInput){if(X.passFiles.length>0)if(t.isServerCallback){const ee=t.isMultiple?X.passFiles:X.passFiles[0],F=t.isMultiple?X.passFilesInfo:X.passFilesInfo[0];S(ee,F),C()}else t.isMultiple?(L(X.passFilesInfo,[]),q(X.passFiles,X.passFilesInfo)):(L(X.passFilesInfo,[]),q(X.passFiles[0],X.passFilesInfo[0]));else X.errorMsg.length===0&&(I("fail"),z(["文件校验失败,请重试"]));X.errorMsg.length>0&&(z(X.errorMsg),X.passFiles.length===0&&I("fail"))}}).catch(()=>{D.isInitFileInput||(I("fail"),z(["文件校验失败,请重试"]))}))},ue=(G,X)=>{const ee=o.isEmpty(G.url)?G.src:G.url;v(ee,"image",X)},Y=(G,X)=>{o.isEmpty(G.url)||v(G.url,"video",X)},Z=G=>{if(b===G)return;b=G,$(),D.isInitFileInput||I("complete");const X=x.value.find(le=>le.rId===G);X&&o.isString(X.url)&&X.url.startsWith("blob:")&&URL.revokeObjectURL(X.url);const ee=[],F=[];x.value.forEach(le=>{le.rId!==G&&(ee.push(le),F.push(le.rId))}),O.value=F;const j=document.getElementById(D.elFileId);j&&(j.value=""),e.nextTick(()=>{ee.length>0?(x.value=ee,b=null,H()):M=setTimeout(()=>{M=null,x.value=x.value.filter(le=>le.rId!==G),b=null,H()},500)})},se=G=>{if(G.isImage&&o.isEmpty(G.url))V(G.imgSrc,G.name);else if(o.isString(G.url)&&G.url.startsWith("blob:")){const X=document.createElement("a");X.href=G.url,X.download=G.name,X.click()}else if(o.isEmpty(G.url)&&G.file){const X=URL.createObjectURL(G.file),ee=document.createElement("a");ee.href=X,ee.download=G.name,ee.click(),setTimeout(()=>{URL.revokeObjectURL(X)},1e3)}else y(G.url)},K=()=>{B.value?.click()};return a({saveServerCallback:G=>{if($(),!D.isInitFileInput){if(o.isUndefined(G)||o.isUndefined(G.res)||!o.isBoolean(G.res.success)||o.isUndefined(G.req)){I("fail"),z(["文件保存失败,请重试"]);return}if(G.res.success){let X=[];const ee=[];if(o.isNonEmptyString(G.res.fileUrl)?(X.push(G.res.fileUrl),ee.push(0)):o.isArray(G.res.fileUrl)&&G.res.fileUrl.forEach((ie,ne)=>{o.isNonEmptyString(ie)&&(X.push(ie),ee.push(ne))}),X.length===0){I("complete");return}const F=t.isMultiple?G.req:[G.req];let j=[],le=[];if(!t.isMultiple)j=X,le=F;else{const ie=x.value.map(ne=>ne.url).filter(ne=>o.isNonEmptyString(ne));X.forEach((ne,A)=>{const te=ee[A];ie.indexOf(ne)>-1||o.isUndefined(F[te])||(ie.push(ne),j.push(ne),le.push(F[te]))})}if(j.length===0){I("complete");return}L(le,j);const me=t.isMultiple?j:j[0];q(me)}else I("fail"),z(["文件保存失败,请重试"])}},getValue:()=>_(),cleanReduction:()=>{$(),P()}}),(G,X)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",{class:e.normalizeClass(J.value)},[D.isInitFileInput&&!n.disabled?(e.openBlock(),e.createElementBlock("input",{key:0,type:"file",id:D.elFileId,name:N.value,multiple:n.isMultiple,accept:e.unref(p).mime.join(","),onChange:oe},null,40,km)):(e.openBlock(),e.createElementBlock("input",{key:1,id:D.elFileId,name:N.value,disabled:n.disabled,accept:e.unref(p).mime.join(","),style:{display:"none !important"},onChange:oe},null,40,Sm)),e.createElementVNode("label",{ref_key:"refElLabel",ref:B,for:D.elFileId},[e.createVNode(Qe,{ref_key:"refElButton",ref:E,className:n.buttonClass,isShowBackDrop:!0,disabled:n.disabled,label:n.buttonLabel||e.unref(d).common.upload,iconName:n.buttonIcon,color:n.buttonColor,onOnClick:K},null,8,["className","disabled","label","iconName","color"])],8,wm)],2),e.renderSlot(G.$slots,"label"),x.value.length>0&&n.isShowUploadResult?(e.openBlock(),e.createElementBlock("ul",Em,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value,(ee,F)=>(e.openBlock(),e.createBlock(e.Transition,{key:`${ee.rId}-${F}`,name:"fileUploadButton","enter-active-class":"fileupload-anim-in","leave-active-class":"fileupload-anim-out"},{default:e.withCtx(()=>[O.value.indexOf(ee.rId)>-1?(e.openBlock(),e.createElementBlock("li",{key:`${l}-${ee.rId}-${F}`,class:"fileUpload-item"},[ee.isImage?(e.openBlock(),e.createElementBlock("span",bm,[e.createElementVNode("img",{src:ee.imgSrc},null,8,Cm),n.isShowPreview?(e.openBlock(),e.createElementBlock("i",{key:0,class:"preview-icon",title:e.unref(d).common.preview,onClick:e.withModifiers(j=>ue(ee,F),["stop"])},[e.createVNode(ve,{name:"search-plus"})],8,xm)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])):ee.isVideo?(e.openBlock(),e.createElementBlock("span",Bm,[e.createElementVNode("video",{src:ee.url},null,8,Dm),n.isShowPreview?(e.openBlock(),e.createElementBlock("span",{key:0,class:"preview-icon",onClick:e.withModifiers(j=>Y(ee,F),["stop"])},[e.createVNode(ve,{name:"play"})],8,Im)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])):(e.openBlock(),e.createBlock(ve,{key:2,name:ee.icon,class:"fileUpload-item-icon"},null,8,["name"])),e.createElementVNode("span",Tm,e.toDisplayString(ee.name),1),e.createElementVNode("span",Nm,[n.isShowDownload?(e.openBlock(),e.createElementBlock("i",{key:0,class:"download-icon",title:e.unref(d).common.download,onClick:e.withModifiers(j=>se(ee),["stop"])},[e.createVNode(ve,{name:"download"})],8,Vm)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.disabled?(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)):(e.openBlock(),e.createElementBlock("a",{key:2,class:"file-complete-remove",href:"javascript:",title:e.unref(d).common.delete,onClick:e.withModifiers(j=>Z(ee.rId),["stop"])},[e.createVNode(ve,{name:"close"})],8,_m))])])):e.createCommentVNode("",!0)]),_:2},1024))),128))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))}}),Om=["id"],Am={key:0,class:"cl-plaintext-value"},Lm=["src","alt"],$m=["src"],Fm={key:0},la=e.defineComponent({name:"ClFileUpload",__name:"Index",props:{id:String,name:String,value:[String,Array,Object],className:String,disabled:{type:Boolean,default:!1},theme:{type:String,default:"default",validator:n=>["default","button"].includes(n)},isMultiple:{type:Boolean,default:!1},defaultHoverTitle:String,defaultIcon:String,isShowCompleteMsg:{type:Boolean,default:!0},buttonClass:String,buttonLabel:String,buttonIcon:String,buttonColor:String,checkFormat:String,checkMinSize:[String,Number],checkMaxSize:[String,Number],checkWidth:[String,Number],checkHeight:[String,Number],checkWHType:{type:String,default:"equal"},imgFit:{type:String,default:"width"},isShowPreview:{type:Boolean,default:!0},isShowDownload:{type:Boolean,default:!0},isShowUploadResult:{type:Boolean,default:!0},isShowUploadIng:{type:Boolean,default:!0},serverFileCallback:Function,isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:","}},emits:["update:value","update:modelValue","onChange","onRemove","onError"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.inject("$ClGlobals",null),d=e.useAttrs(),u=t.id,r=e.useTemplateRef("refElFileDefault"),c=e.useTemplateRef("refElFileButton");let m=0,p=0;const f=e.computed(()=>o.isFunction(t.serverFileCallback)),h=["jpg","jpeg","png","gif","webp","bmp","svg"],g=["mp4","webm","ogg","ogv","mov","avi","mkv"],y=v=>{const S=v.split("?")[0].split("#")[0],C=S.split("/"),$=C.length>0?C[C.length-1]:S;return o.isEmpty($)?v:decodeURIComponent($)},V=e.computed(()=>{const v=t.value,S=Array.isArray(v)?v:o.isEmpty(v)?[]:[v],C=[];return S.forEach($=>{if(o.isString($)){o.isNonEmptyString($)&&C.push({url:$,name:y($),type:"file"});return}$&&o.isNonEmptyString($.name)&&C.push({url:"",name:$.name,type:"file"})}),C.map($=>{if(o.isEmpty($.url))return $;const k=$.name.lastIndexOf("."),I=k>-1?$.name.slice(k+1).toLowerCase():"";let L="file";return h.indexOf(I)>-1?L="image":g.indexOf(I)>-1&&(L="video"),{...$,type:L}})}),E=e.computed(()=>V.value.filter(v=>v.type!=="file")),B=e.computed(()=>{const v=o.isString(t.plaintextSeparator)?t.plaintextSeparator:",";return V.value.filter(S=>S.type==="file").map(S=>S.name).join(v)}),T=e.computed(()=>{let v={"panel-file-upload":!0};return v=o.getJsonMerge(v,de.getClassNameJson(t.className)),v}),D=(v,S,C)=>{s("update:value",v),s("update:modelValue",v),s("onChange",S,C)},x=()=>{s("onRemove")},O=()=>{let v=null;switch(t.theme){case"default":v=r.value?.getValue();break;case"button":v=c.value?.getValue();break}return v},w=(v,S)=>{switch(v){case"default":r.value?.saveServerCallback(S);break;case"button":c.value?.saveServerCallback(S);break}},M=(v,S)=>{const C=O(),$=f.value?C:v;D(C,$,S)},b=v=>{o.isArray(v)&&s("onError",v)},N=()=>{p+=1,x();const v=O();D(v,v)},J=async(v,S,C)=>{l&&await l.preview.show({type:S,src:v,showIndex:C??0})},q=async(v,S)=>{const C=t.theme,$=++m,k=p;let I=!0;if(t.serverFileCallback)try{const _=!t.isMultiple&&o.isObject(S)&&o.isBoolean(S.isImage)?S.isImage:!1,R=de.getElementData(d);I=await t.serverFileCallback(v,_,R)}catch{$===m&&p===k&&t.theme===C&&w(C,{req:S,res:{success:!1}});return}let L={};if(o.isBoolean(I)?L.success=I:o.isUndefined(I)?L.success=!0:o.isString(I)||o.isArray(I)?(L.success=!0,L.fileUrl=I):o.isObject(I)?L=I:L.success=!1,t.theme!==C){s("onError",["保存期间主题已切换,本次保存结果未写入"]);return}$!==m||p!==k||w(C,{req:S,res:L})};return e.provide("$FileuploadTop",e.reactive({getFileCheckInfo:()=>({checkFormat:t.checkFormat,checkWidth:t.checkWidth,checkHeight:t.checkHeight,checkWHType:t.checkWHType,checkMinSize:t.checkMinSize,checkMaxSize:t.checkMaxSize})})),a({getValue:()=>O(),cleanReduction:()=>{switch(t.theme){case"default":r.value?.cleanReduction();break;case"button":c.value?.cleanReduction();break}D("","")}}),(v,S)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(T.value),id:e.unref(u)},[n.isPlaintext?(e.openBlock(),e.createElementBlock("div",Am,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,(C,$)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`plain-${$}`},[C.type==="image"?(e.openBlock(),e.createElementBlock("img",{key:0,src:C.url,alt:C.name,class:"cl-plaintext-media"},null,8,Lm)):(e.openBlock(),e.createElementBlock("video",{key:1,src:C.url,controls:"",class:"cl-plaintext-media"},null,8,$m))],64))),128)),B.value?(e.openBlock(),e.createElementBlock("span",Fm,e.toDisplayString(B.value),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),!n.isPlaintext&&n.theme==="button"?(e.openBlock(),e.createBlock(Mm,{key:2,ref_key:"refElFileButton",ref:c,value:n.value,name:n.name,disabled:n.disabled,isMultiple:n.isMultiple,buttonClass:n.buttonClass,buttonLabel:n.buttonLabel,buttonIcon:n.buttonIcon,buttonColor:n.buttonColor,checkFormat:n.checkFormat,checkMinSize:n.checkMinSize,checkMaxSize:n.checkMaxSize,checkWidth:n.checkWidth,checkHeight:n.checkHeight,checkWHType:n.checkWHType,isServerCallback:f.value,isShowUploadResult:n.isShowUploadResult,isShowUploadIng:n.isShowUploadIng,isShowPreview:n.isShowPreview,isShowDownload:n.isShowDownload,onOnChange:M,onOnError:b,onOnRemove:N,onOnPreview:J,onOnSaveFile:q},{label:e.withCtx(()=>[e.renderSlot(v.$slots,"label")]),_:3},8,["value","name","disabled","isMultiple","buttonClass","buttonLabel","buttonIcon","buttonColor","checkFormat","checkMinSize","checkMaxSize","checkWidth","checkHeight","checkWHType","isServerCallback","isShowUploadResult","isShowUploadIng","isShowPreview","isShowDownload"])):!n.isPlaintext&&n.theme==="default"?(e.openBlock(),e.createBlock(vm,{key:3,ref_key:"refElFileDefault",ref:r,value:n.value,name:n.name,disabled:n.disabled,defaultHoverTitle:n.defaultHoverTitle,defaultIcon:n.defaultIcon,isShowCompleteMsg:n.isShowCompleteMsg,checkFormat:n.checkFormat,checkMinSize:n.checkMinSize,checkMaxSize:n.checkMaxSize,checkWidth:n.checkWidth,checkHeight:n.checkHeight,checkWHType:n.checkWHType,imgFit:n.imgFit,isServerCallback:f.value,isShowPreview:n.isShowPreview,isShowDownload:n.isShowDownload,onOnChange:M,onOnError:b,onOnRemove:N,onOnPreview:J,onOnSaveFile:q},{label:e.withCtx(()=>[e.renderSlot(v.$slots,"label")]),_:3},8,["value","name","disabled","defaultHoverTitle","defaultIcon","isShowCompleteMsg","checkFormat","checkMinSize","checkMaxSize","checkWidth","checkHeight","checkWHType","imgFit","isServerCallback","isShowPreview","isShowDownload"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64))],10,Om))}}),Pm=["id"],Rm={class:"previewExample-image-icon"},Hm={class:"previewExample-video-img previewExample-image"},Um=["onClick"],zm={key:3,class:"previewExample-label-msg"},Jm={key:5,class:"previewExample-totalCount"},ra=e.defineComponent({name:"ClPreviewExample",__name:"Index",props:{id:String,className:String,classContainer:String,classItem:String,type:{type:String,default:"image",validator:n=>["image","video"].includes(n)},width:{type:[Number,String],default:"auto"},height:{type:Number,required:!0},isWidthFull:{type:Boolean,default:!0},list:{type:Array,default:()=>[]},label:String,previewIconSize:{type:String,default:"large"},isShowLoading:{type:Boolean,default:!1},isLoading:{type:Boolean,default:!1},isShowDelete:{type:Boolean,default:!1},showNum:{type:Number,default:-1},srcValueKey:{type:String,default:"value"},isShowCopy:{type:Boolean,default:!0},isClickImagePreview:{type:Boolean,default:!1},previewCallback:Function},emits:["onDelete"],setup(n,{emit:a}){const i=n,t=a,s=e.inject("$ClGlobals",null),l=`previewexample-${o.getRandom(5)}`,d=i.id,u=e.reactive({totalCount:-1}),r=e.ref([]),c=e.computed(()=>{const{width:x}=i;let O=!1;return(o.isEmpty(x)||typeof x=="string"&&x==="auto"||typeof x=="number"&&x<=0)&&(O=!0),O}),m=e.computed(()=>{let x={"panel-preview-example":!0,"previewExample-width-default":i.isWidthFull,"previewExample-width-auto":!i.isWidthFull};return x=o.getJsonMerge(x,de.getClassNameJson(i.className)),x}),p=e.computed(()=>{let x={"previewExample-container":!0};return x=o.getJsonMerge(x,de.getClassNameJson(i.classContainer)),x}),f=e.computed(()=>{const{type:x,previewIconSize:O}=i;let w={"previewExample-item":!0};return w[`previewExample-${x}`]=!0,w[`previewExample-iconSize-${O}`]=!0,w=o.getJsonMerge(w,de.getClassNameJson(i.classItem)),w}),h=e.computed(()=>{const x={height:`${i.height}px`};if(!c.value){let O=i.width.toString();O.indexOf("%")===-1&&(O=`${i.width}px`),x.width=O}return x}),g=x=>{t("onDelete",x)},y=()=>{const{list:x,showNum:O,srcValueKey:w}=i;let M=o.getListClone(x),b=x.length;O>0&&x.length>=O&&(b=O);const N=[];M.forEach((J,q)=>{if(!o.isEmpty(J)&&q+1<=b)if(o.isString(J))N.push({value:J});else{const z=o.isExistJsonKey(J,w)?J[w]:J.value;N.push({...J,value:z})}}),M=N,u.totalCount=x.length,r.value=M},V=()=>{y()},E=x=>{const O={};return o.isEmpty(x.id)||(O["data-id"]=x.id),o.isEmpty(x.ranId)||(O["data-ran-id"]=x.ranId),O};e.onMounted(()=>{e.nextTick(()=>{V()})}),e.watch(()=>i.list,()=>{y()},{deep:!0});const B=(x,O)=>{i.isClickImagePreview&&T(x,O,"image")},T=(x,O,w)=>{try{if(i.previewCallback)i.previewCallback(w,x,O);else{if(!s||o.isEmpty(s.preview))return;const{list:M}=i;let b;M.length===1?b=x.value:b=M.map(N=>o.isString(N)?N:N.value),s.preview.show({type:w,src:b,showIndex:O,isShowCopy:i.isShowCopy})}}catch{}},D=x=>{g(x)};return(x,O)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(d),class:e.normalizeClass(m.value)},[e.createElementVNode("div",{class:e.normalizeClass(p.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(w,M)=>(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:`${l}-${M}`,class:f.value,style:h.value},{ref_for:!0},E(w)),[n.type==="image"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createVNode(Yn,{src:w.value,class:e.normalizeClass({"cursor-pointer":n.isClickImagePreview}),onClick:e.withModifiers(b=>B(w,M),["stop"])},null,8,["src","class","onClick"]),e.createElementVNode("div",Rm,[e.createVNode(ve,{title:"预览",name:"search","aria-label":"预览",onClick:e.withModifiers(b=>T(w,M,"image"),["stop"])},null,8,["onClick"]),n.isShowDelete?(e.openBlock(),e.createBlock(ve,{key:0,title:"删除",name:"close","aria-label":"删除",onClick:e.withModifiers(b=>D(M),["stop"])},null,8,["onClick"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])],64)):n.type==="video"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createElementVNode("div",Hm,[w.imgUrl&&w.imgUrl.length>0?(e.openBlock(),e.createBlock(Yn,{key:0,src:w.imgUrl},null,8,["src"])):e.createCommentVNode("",!0)]),e.createElementVNode("div",{class:"previewExample-video-icon",onClick:e.withModifiers(b=>T(w,M,"video"),["stop"])},[e.createVNode(ve,{name:"play","aria-label":"播放"})],8,Um)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64)),n.label&&n.label.length>0||w.label&&w.label.length>0?(e.openBlock(),e.createElementBlock("div",zm,e.toDisplayString(n.label&&n.label.length>0?n.label:w.label),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64)),n.showNum>-1&&M===r.value.length-1&&u.totalCount>n.showNum?(e.openBlock(),e.createElementBlock("div",Jm,[e.createElementVNode("span",null,"共"+e.toDisplayString(u.totalCount)+e.toDisplayString(n.type==="image"?"张":"个"),1)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:6},[],64)),e.renderSlot(x.$slots,"extend",{data:w,inx:M})],16))),128)),n.isShowLoading&&n.isLoading?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass([`previewExample-${n.type}`]),style:e.normalizeStyle(h.value)},[e.createVNode(lt,{theme:"circleNotch",size:"large"})],6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],2)],10,Pm))}}),Km=["id"],Wm={class:"cropperPreview-box-flex"},ls=e.defineComponent({name:"ClCropperPreview",__name:"Index",props:{id:String,className:String,previewImageUrl:String,coverImageUrl:String,width:{type:Number,default:200},height:{type:Number,default:200},widthPreview:Number,heightPreview:Number,previewShape:{type:String,default:"square"},isCenterBox:{type:Boolean,default:!1},isShowUploadBtn:{type:Boolean,default:!0},getCropperImageUrl:Function,saveImageBase64:Function},emits:{onInitCoverImage:()=>!0,onError:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElCropper"),u=e.reactive({isEmptyPreviewUrl:!1,isEmptyCoverUrl:!1,isAgainCropper:!1,coverImageUrlOriginal:""});let r=!1;const c=e.computed(()=>{const{width:w,widthPreview:M}=t;return o.isFinite(M)?M:w}),m=e.computed(()=>{const{height:w,heightPreview:M}=t;return o.isFinite(M)?M:w}),p=e.computed(()=>({"panel-cropper-preview":!0,...de.getClassNameJson(t.className)})),f=()=>{const{previewImageUrl:w}=t,M=o.isEmpty(w);u.isEmptyPreviewUrl=M,u.isAgainCropper=M},h=()=>{const{coverImageUrl:w}=t,M=o.isEmpty(w);u.isEmptyCoverUrl=M,u.coverImageUrlOriginal=M?"":w},g=()=>{const{width:w,height:M}=t;(w<=0||M<=0)&&Se.warn("ClCropperPreview","裁切区域宽高必须大于 0,当前值 width="+w+" height="+M)},y=()=>{f(),h(),g()};e.onMounted(()=>{e.nextTick(()=>{y()})}),e.watch(()=>t.previewImageUrl,()=>{f()}),e.watch(()=>t.coverImageUrl,()=>{h()});const V=w=>{w===!0&&s("onInitCoverImage")},E=(w,M)=>{if(!r){if(!(w instanceof File)){s("onError","文件读取失败,请重新选择图片");return}r=!0,d.value?.loadingStart(),o.getBase64ByFile([w]).then(b=>{const N=o.isNonEmptyString(b);u.isAgainCropper=!0,N?(u.coverImageUrlOriginal=b,u.isEmptyCoverUrl=!1):(u.isEmptyCoverUrl=o.isEmpty(u.coverImageUrlOriginal),s("onError","文件读取失败,请重新选择图片")),d.value?.loadingStop(),r=!1}).catch(b=>{d.value?.loadingStop(),r=!1,s("onError","文件读取失败,请重新选择图片")})}},B=()=>{u.isAgainCropper=!1},T=()=>{u.isAgainCropper=!0};return a({getValue:async()=>{let w="";try{w=d.value?String(await d.value.getImageBase64()||""):""}catch(M){Se.error("ClCropperPreview","getValue 获取裁切图片失败:",M)}return w},getCropperUrl:async w=>{let M="";try{if(d.value&&o.isFunction(t.getCropperImageUrl))M=await t.getCropperImageUrl(d.value,w);else{const{previewImageUrl:b,coverImageUrl:N}=t;M=o.isNonEmptyString(b)?b:N||""}}catch(b){Se.error("ClCropperPreview","getCropperUrl 调用失败:",b)}return M},getCoverUrlOriginal:async w=>{let M="";try{const{coverImageUrlOriginal:b}=u;if(b.startsWith("data:")&&o.isFunction(t.saveImageBase64)){const N=await t.saveImageBase64(b,w);M=N&&N.success?N.imageUrl:""}else/^(http|https):\/\/[^\s]+$/.test(b)&&(M=b)}catch(b){Se.error("ClCropperPreview","getCoverUrlOriginal 调用失败:",b)}return M}}),(w,M)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(p.value),id:e.unref(l)},[e.createElementVNode("div",Wm,[u.isEmptyPreviewUrl?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[u.isAgainCropper?(e.openBlock(),e.createBlock(Qe,{key:0,iconName:"reply",label:"返回",color:"transparent",onOnClick:B})):(e.openBlock(),e.createBlock(Qe,{key:1,iconName:"cropper",label:"重新裁切",color:"transparent",onOnClick:T}))],64)),n.isShowUploadBtn&&(u.isAgainCropper||u.isEmptyCoverUrl&&u.isEmptyPreviewUrl)?(e.openBlock(),e.createBlock(la,{key:2,theme:"button",checkFormat:"jpg,png",buttonIcon:"upload-cloud",buttonColor:"white",buttonLabel:"选择图片",isShowUploadResult:!1,isShowUploadIng:!1,onOnChange:E})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))]),!u.isEmptyPreviewUrl&&!u.isAgainCropper?(e.openBlock(),e.createBlock(ra,{key:0,type:"image",list:[{value:n.previewImageUrl||"",imgUrl:"",label:""}],width:c.value,height:m.value},null,8,["list","width","height"])):u.isAgainCropper&&(!u.isEmptyPreviewUrl||!u.isEmptyCoverUrl)?(e.openBlock(),e.createBlock(sa,{key:1,ref_key:"refElCropper",ref:d,previewShape:n.previewShape,isCenterBox:n.isCenterBox,src:u.coverImageUrlOriginal,width:n.width,height:n.height,isModal:!1,isShowUpload:!1,onOnImgLoad:V},null,8,["previewShape","isCenterBox","src","width","height"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))],10,Km))}}),jm={key:0,class:"dropdownLayer-text-arrow"},Ym=["title"],qm={key:0,class:"dropdownLayer-placeholder"},Xm=["innerHTML"],Gm={key:2},Qm={key:4,class:"dropdownLayer-text-arrow"},wn=e.defineComponent({name:"ClDropdownlayerList",__name:"List",props:{id:String,classParent:[String,Object],classText:String,classDropDown:String,placeholder:String,isDisabled:{type:Boolean,default:!1},transitionEnter:{type:String,default:"zoomInTop"},transitionLeave:{type:String,default:"zoomOutTop"},isClear:{type:Boolean,default:!1},textLabel:{type:String,default:""},textArrowDirection:{type:String,default:"right",validator:n=>["left","right"].includes(n)},dropdownArrowPos:{type:String,default:"left"},isUseDropdownArrow:{type:Boolean,default:!1},isCloseDestroy:{type:Boolean,default:!0},appendContainer:{type:String,default:""},appendFollowWidth:{type:Boolean,default:!0},onOpenBeforeCallback:Function},emits:{onChangeOpen:n=>!0,onClear:()=>!0,onChangePosition:n=>!0,onOpenComplete:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElDropdownLayer"),u=e.computed(()=>o.isHtml(t.textLabel)),r=e.computed(()=>{const{textLabel:D}=t;return o.isString(D)?o.isHtml(D)?o.removeHTMLTags(D):D:""}),c=e.computed(()=>{let D={"dropdownLayer-theme-list":!0,"panel-dropdownlayerlist":!0};return D=o.getJsonMerge(D,de.getClassNameJson(t.classParent)),D}),m=e.computed(()=>{let D={"dropdownLayer-dropdown-theme-list":!0};return D=o.getJsonMerge(D,de.getClassNameJson(t.classDropDown)),D}),p=e.computed(()=>({"dropdownLayer-text-container":!0,"arrow-pos-left":t.textArrowDirection==="left"})),f=D=>{D&&B(),s("onChangeOpen",D)},h=D=>{s("onChangePosition",D)},g=()=>{s("onClear")},y=()=>{s("onOpenComplete")},V=D=>{if(!d.value){Se.warn("DropdownLayer","子组件尚未挂载,setOpen 调用已忽略");return}d.value.setOpen(D)},E=()=>{if(!d.value){Se.warn("DropdownLayer","子组件尚未挂载,calculationPosition 调用已忽略");return}return d.value.calculationPosition()},B=()=>{if(!d.value){Se.warn("DropdownLayer","子组件尚未挂载,initCompleteOpen 调用已忽略");return}d.value.initCompleteOpen()};return a({setOpen:V,calculationPosition:E,initCompleteOpen:B,checkIsShowOpen:()=>{if(!d.value){Se.warn("DropdownLayer","子组件尚未挂载,checkIsShowOpen 调用已忽略");return}return d.value.getIsShowOpen()}}),(D,x)=>(e.openBlock(),e.createBlock(ts,{ref_key:"refElDropdownLayer",ref:d,id:e.unref(l),classParent:c.value,classText:n.classText,classDropDown:m.value,isDisabled:n.isDisabled,dropdownArrowPos:n.dropdownArrowPos,isUseDropdownArrow:n.isUseDropdownArrow,isCloseDestroy:n.isCloseDestroy,isInitDelayComplete:!0,appendContainer:n.appendContainer,appendFollowWidth:n.appendFollowWidth,onOpenBeforeCallback:n.onOpenBeforeCallback,transitionEnter:n.transitionEnter,transitionLeave:n.transitionLeave,onOnChangeOpen:f,onOnChangePosition:h,onOnOpenComplete:y},{labelText:e.withCtx(()=>[D.$slots.labelCustom?e.renderSlot(D.$slots,"labelCustom",{key:0}):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(p.value)},[n.textArrowDirection==="left"?(e.openBlock(),e.createElementBlock("div",jm,[e.createVNode(ve,{name:"angle-down"})])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",{class:"dropdownLayer-text-render",title:r.value},[n.textLabel?u.value?(e.openBlock(),e.createElementBlock("span",{key:1,innerHTML:n.textLabel},null,8,Xm)):(e.openBlock(),e.createElementBlock("span",Gm,e.toDisplayString(r.value),1)):(e.openBlock(),e.createElementBlock("span",qm,e.toDisplayString(n.placeholder),1))],8,Ym),!n.isDisabled&&n.isClear&&n.textLabel?(e.openBlock(),e.createBlock(ve,{key:2,class:"dropdownLayer-text-clear",name:"close-circle-fill",onClick:e.withModifiers(g,["stop"])})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),e.renderSlot(D.$slots,"textExtend"),n.textArrowDirection==="right"?(e.openBlock(),e.createElementBlock("div",Qm,[e.createVNode(ve,{name:"angle-down"})])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))],2))]),dropdown:e.withCtx(()=>[e.renderSlot(D.$slots,"dropdown"),e.renderSlot(D.$slots,"dropdownExtend")]),_:3},8,["id","classParent","classText","classDropDown","isDisabled","dropdownArrowPos","isUseDropdownArrow","isCloseDestroy","appendContainer","appendFollowWidth","onOpenBeforeCallback","transitionEnter","transitionLeave"]))}}),Zm=["id"],ep={class:"table-base"},tp={class:"time-head time-head-day",colspan:"7"},np={class:"time-prev"},op=["title"],ap=["title"],ip={class:"time-next"},sp=["title"],lp=["title"],rp=["aria-disabled","onClick","onKeydown","onMouseover"],cp=e.defineComponent({name:"ClCalendarsDays",__name:"CalendarsDays",props:{className:String,viewValue:String,selectValue:String,startValue:String,endValue:String,hoverValue:String,minValue:String,maxValue:String},emits:{onChangeDate:n=>!0,onChangeType:n=>!0,onSelectDate:(n,a)=>!0,onHoverDate:(n,a)=>!0,onInitComplete:n=>!0},setup(n,{emit:a}){const i=n,t=a,{optPageLanguage:s,getPageLanguage:l}=Le();l("dataTime");const d=e.inject("$DateTimeTop"),u=e.inject("$DateTimeTopBase"),r=e.inject("$DateTimeBase");(!d||!u||!r)&&Se.warn("ClCalendarsDays","未找到 $DateTimeTop/$DateTimeTopBase/$DateTimeBase 注入,请确保组件在 ClDateTime 组件树内使用");const c=`calendarsDays-${o.getRandom(5)}`,m=d?.elId?`${d.elId}-calendarsDays-${o.getRandom(5)}`:void 0,p=e.computed(()=>{let S={"panel-calendarsdays":!0};return S=o.getJsonMerge(S,de.getClassNameJson(i.className)),S}),f=e.reactive({isPrevYear:!1,isPrevMonth:!1,titleYear:"",titleMonth:"",isNextYear:!1,isNextMonth:!1}),h=e.ref([]),g=e.ref([]),y={viewDate:null,selectDate:null,startDate:null,endDate:null,hoverDate:null},V=()=>{if(!y.viewDate)return;const S=y.viewDate.year(),$=y.viewDate.localeData().monthsShort(y.viewDate),k=y.viewDate.clone().subtract(1,"years").endOf("month"),I=r.checkDataMinMax(k,"day"),L=y.viewDate.clone().subtract(1,"months").endOf("month"),_=r.checkDataMinMax(L,"day"),R=y.viewDate.clone().add(1,"months").startOf("month"),P=r.checkDataMinMax(R,"day"),Q=y.viewDate.clone().add(1,"years").startOf("month"),oe=r.checkDataMinMax(Q,"day");f.isPrevYear=!I,f.isPrevMonth=!_,f.titleYear=`${S}${s.value.year}`,f.titleMonth=$,f.isNextMonth=!P,f.isNextYear=!oe},E=()=>{if(!y.viewDate)return;const S=y.viewDate.localeData(),C=S.weekdaysMin(),$=S.firstDayOfWeek(),k=[];C.forEach((I,L)=>{k[(7+L-$)%7]=I}),h.value=k},B=()=>{if(!y.viewDate)return;const S=y.viewDate.clone(),C=y.selectDate,$=S.year(),k=S.month();let I=S.clone().subtract(1,"months");const L=[];let _=[];I=I.date(I.daysInMonth()).startOf("week");for(let R=0;R<42;R+=1){R>0&&(I=I.add(1,"days"));const P=I.clone(),Q=P.date(),oe=I.year()===$&&I.month()<k||I.year()<$,ue=I.year()===$&&I.month()>k||I.year()>$;let Y=C&&I.isSame(C,"day");const Z=r.checkDataMinMax(P,"day");let se=!1,K=!1,W=!1;u.isRange&&(y.hoverDate?y.startDate&&y.endDate&&y.startDate.isSame(y.hoverDate,"day")&&y.hoverDate.isBefore(y.endDate,"day")?(se=I.isSame(y.startDate,"day"),K=I.isSame(y.endDate,"day"),W=se||K||I.isAfter(y.startDate,"day")&&I.isBefore(y.endDate,"day")):y.startDate?(se=I.isSame(y.startDate,"day"),W=se||I.isSame(y.hoverDate,"day"),W=W||I.isAfter(y.startDate,"day")&&I.isBefore(y.hoverDate,"day"),K=y.hoverDate.isSame(y.startDate,"day")&&se):y.endDate&&(K=I.isSame(y.endDate,"day"),W=K||I.isSame(y.hoverDate,"day"),W=W||I.isAfter(y.hoverDate,"day")&&I.isBefore(y.endDate,"day"),se=y.hoverDate.isSame(y.endDate,"day")&&K):(se=!!(y.startDate&&I.isSame(y.startDate,"day")),y.endDate&&(K=I.isSame(y.endDate,"day"),W=se||K||!!(y.startDate&&I.isAfter(y.startDate,"day")&&I.isBefore(y.endDate,"day")))),Y=se||K);const U=de.getAddClass("day",{old:oe,new:ue,active:Y&&!oe&&!ue&&!Z,disabled:Z,"date-start":se&&!oe&&!ue,"date-end":K&&!oe&&!ue,"range-in":W&&!oe&&!ue});_.push({cls:U,day:Q,value:Q,isDisabled:Z,isOld:oe,isNew:ue}),_.length===7&&(L.push({days:_}),_=[])}g.value=L},T=(S,C,$)=>{if(!y.viewDate)return;const k=y.viewDate.clone()[S](C,$);t("onChangeDate",k)};let D=!1;const x=()=>{D||(D=!0,e.nextTick(()=>{t("onInitComplete","days")}))},O=()=>{y.selectDate=d.getMomentDate(i.selectValue),y.startDate=d.getMomentDate(i.startValue),y.endDate=d.getMomentDate(i.endValue),y.hoverDate=d.getMomentDate(i.hoverValue)},w=(S,C,$)=>{if(C!==$){const k=d.getMomentDate(C);k&&k.isValid()&&(y[S]=k,O(),E(),V(),B(),x())}},M=()=>{if(o.isNonEmptyString(i.viewValue)){const S=d.getMomentDate(i.viewValue);S&&S.isValid()&&(y.viewDate=S,O(),E(),V(),B(),x())}};e.onMounted(()=>{e.nextTick(()=>{M()})}),e.watch(()=>i.viewValue,(S,C)=>{w("viewDate",S,C)}),e.watch([()=>i.selectValue,()=>i.startValue,()=>i.endValue],()=>{y.viewDate&&(y.selectDate=d.getMomentDate(i.selectValue),y.startDate=d.getMomentDate(i.startValue),y.endDate=d.getMomentDate(i.endValue),y.hoverDate=d.getMomentDate(i.hoverValue),B())}),e.watch(()=>i.hoverValue,()=>{y.viewDate&&(y.hoverDate=d.getMomentDate(i.hoverValue),u.isRange&&B())}),e.watch([()=>i.minValue,()=>i.maxValue],()=>{y.viewDate&&(V(),B())});const b=S=>{S.preventDefault(),S.stopPropagation(),T("subtract",1,"years")},N=S=>{S.preventDefault(),S.stopPropagation(),T("subtract",1,"months")},J=S=>{S.preventDefault(),S.stopPropagation(),T("add",1,"months")},q=S=>{S.preventDefault(),S.stopPropagation(),T("add",1,"years")},z=(S,C)=>{S.preventDefault(),S.stopPropagation(),t("onChangeType",C)},H=(S,C)=>{S.preventDefault(),S.stopPropagation(),C.isDisabled||t("onSelectDate","days",C)},v=(S,C)=>{S.preventDefault(),S.stopPropagation(),C.isDisabled||t("onHoverDate","days",C)};return(S,C)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(p.value),id:e.unref(m)},[e.createElementVNode("table",ep,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",tp,[e.createElementVNode("span",np,[f.isPrevYear?(e.openBlock(),e.createElementBlock("span",{key:0,class:"prev-year",title:e.unref(s).prevYear,onClick:b},[e.createVNode(ve,{name:"angle-double-left"})],8,op)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),f.isPrevMonth?(e.openBlock(),e.createElementBlock("span",{key:2,class:"prev-month",title:e.unref(s).prevMonth,onClick:N},[e.createVNode(ve,{name:"angle-left"})],8,ap)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))]),e.createElementVNode("span",{class:"datetime-switch-year",onClick:C[0]||(C[0]=$=>z($,"years"))},e.toDisplayString(f.titleYear),1),e.createElementVNode("span",{class:"datetime-switch-month",onClick:C[1]||(C[1]=$=>z($,"months"))},e.toDisplayString(f.titleMonth),1),e.createElementVNode("span",ip,[f.isNextYear?(e.openBlock(),e.createElementBlock("span",{key:0,class:"next-year",title:e.unref(s).nextYear,onClick:q},[e.createVNode(ve,{name:"angle-double-right"})],8,sp)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),f.isNextMonth?(e.openBlock(),e.createElementBlock("span",{key:2,class:"next-month",title:e.unref(s).nextMonth,onClick:J},[e.createVNode(ve,{name:"angle-right"})],8,lp)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])])]),e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,($,k)=>(e.openBlock(),e.createElementBlock("th",{key:`${c}-week-${k}`},e.toDisplayString($),1))),128))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,($,k)=>(e.openBlock(),e.createElementBlock("tr",{key:`${c}-days-${k}`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList($.days,(I,L)=>(e.openBlock(),e.createElementBlock("td",{key:`${c}-day-${L}`,role:"gridcell",tabindex:"0","aria-disabled":I.isDisabled,class:e.normalizeClass(I.cls),onClick:_=>H(_,I),onKeydown:[e.withKeys(e.withModifiers(_=>H(_,I),["prevent"]),["enter"]),e.withKeys(e.withModifiers(_=>H(_,I),["prevent"]),["space"])],onMouseover:_=>v(_,I)},e.toDisplayString(I.day),43,rp))),128))]))),128))])])],10,Zm))}}),up=["id"],dp={class:"table-base"},mp={class:"time-head time-head-month"},pp={class:"time-prev"},fp=["title"],hp={class:"time-next"},gp=["title"],yp={class:"time-body-month"},vp=["aria-disabled","onClick","onKeydown","onMouseover"],kp=e.defineComponent({name:"ClCalendarsMonths",__name:"CalendarsMonths",props:{className:String,viewValue:String,selectValue:String,startValue:String,endValue:String,hoverValue:String,minValue:String,maxValue:String},emits:{onChangeDate:n=>!0,onChangeType:n=>!0,onSelectDate:(n,a)=>!0,onHoverDate:(n,a)=>!0,onInitComplete:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=`calendarsMonths-${o.getRandom(5)}`,{optPageLanguage:l,getPageLanguage:d}=Le();d("dataTime");const u=e.inject("$DateTimeTop"),r=e.inject("$DateTimeTopBase"),c=e.inject("$DateTimeBase");(!u||!r||!c)&&Se.warn("ClCalendarsMonths","未找到 $DateTimeTop/$DateTimeTopBase/$DateTimeBase 注入,请确保组件在 ClDateTime 组件树内使用");const m=u?.elId?`${u.elId}-calendarsMonths-${o.getRandom(5)}`:void 0,p=e.computed(()=>{let q={"panel-calendarsmonths":!0};return q=o.getJsonMerge(q,de.getClassNameJson(i.className)),q}),f=e.reactive({isPrevYear:!1,titleYear:"",isNextYear:!1}),h=e.ref([]),g={viewDate:null,selectDate:null,startDate:null,endDate:null,hoverDate:null},y=()=>{if(!g.viewDate)return;const q=g.viewDate.year(),z=g.viewDate.clone().subtract(1,"years").endOf("year"),H=c.checkDataMinMax(z,"month"),v=g.viewDate.clone().add(1,"years").startOf("year"),S=c.checkDataMinMax(v,"month");f.isPrevYear=!H,f.titleYear=`${q}${l.value.year}`,f.isNextYear=!S},V=()=>{if(!g.viewDate)return;const q=g.viewDate.clone(),z=c.getFocusDate(),H=g.selectDate,v=q.year(),S=[];q.localeData().monthsShort().forEach((C,$)=>{const k=c.getViewMin(v,$);let I=!!(H&&k.isSame(H,"month")),L=!!(z&&k.isSame(z,"month"));const _=c.checkDataMinMax(k,"month");let R=!1,P=!1,Q=!1;r.isRange&&(L=!1,g.hoverDate?g.startDate&&g.endDate&&g.startDate.isSame(g.hoverDate,"month")&&g.hoverDate.isBefore(g.endDate,"month")?(R=k.isSame(g.startDate,"month"),P=k.isSame(g.endDate,"month"),Q=R||P||k.isAfter(g.startDate,"month")&&k.isBefore(g.endDate,"month")):g.startDate?(R=k.isSame(g.startDate,"month"),Q=R||k.isSame(g.hoverDate,"month"),Q=Q||k.isAfter(g.startDate,"month")&&k.isBefore(g.hoverDate,"month"),P=!!(g.hoverDate&&g.hoverDate.isSame(g.startDate,"month"))&&R):g.endDate&&(P=k.isSame(g.endDate,"month"),Q=P||k.isSame(g.hoverDate,"month"),Q=Q||k.isAfter(g.hoverDate,"month")&&k.isBefore(g.endDate,"month"),R=!!(g.hoverDate&&g.hoverDate.isSame(g.endDate,"month"))&&P):(R=!!(g.startDate&&k.isSame(g.startDate,"month")),g.endDate&&g.startDate&&(P=k.isSame(g.endDate,"month"),Q=k.isAfter(g.startDate,"month")&&k.isBefore(g.endDate,"month"))),I=R||P),r.layerType==="months"&&(L=!1);const oe=de.getAddClass("month",{active:I&&!_,focused:L,disabled:_,"date-start":R,"date-end":P,"range-in":Q});S.push({cls:oe,month:C,isDisabled:_,value:$})}),h.value=S},E=(q,z,H)=>{if(!g.viewDate)return;const v=g.viewDate.clone()[q](z,H);t("onChangeDate",v)};let B=!1;const T=()=>{B||(B=!0,e.nextTick(()=>{t("onInitComplete","months")}))},D=()=>{g.selectDate=u.getMomentDate(i.selectValue),g.startDate=u.getMomentDate(i.startValue),g.endDate=u.getMomentDate(i.endValue),g.hoverDate=u.getMomentDate(i.hoverValue)},x=(q,z,H)=>{if(z!==H){const v=u.getMomentDate(z);v&&v.isValid()&&(g[q]=v,D(),y(),V(),T())}},O=()=>{const q=u.getMomentDate(i.viewValue);q&&q.isValid()&&(g.viewDate=q,D(),y(),V(),T())};e.onMounted(()=>{e.nextTick(()=>{O()})}),e.watch(()=>i.viewValue,(q,z)=>{x("viewDate",q,z)}),e.watch([()=>i.selectValue,()=>i.startValue,()=>i.endValue,()=>i.hoverValue],()=>{g.viewDate&&(g.selectDate=u.getMomentDate(i.selectValue),g.startDate=u.getMomentDate(i.startValue),g.endDate=u.getMomentDate(i.endValue),g.hoverDate=u.getMomentDate(i.hoverValue),V())}),e.watch([()=>i.minValue,()=>i.maxValue],()=>{g.viewDate&&(y(),V())});const w=q=>{q.preventDefault(),q.stopPropagation(),E("subtract",1,"years")},M=q=>{q.preventDefault(),q.stopPropagation(),E("add",1,"years")},b=(q,z)=>{q.preventDefault(),q.stopPropagation(),t("onChangeType",z)},N=(q,z)=>{q.preventDefault(),q.stopPropagation(),z.isDisabled||t("onSelectDate","months",z)},J=(q,z)=>{q.preventDefault(),q.stopPropagation(),z.isDisabled||t("onHoverDate","months",z)};return(q,z)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(p.value),id:e.unref(m)},[e.createElementVNode("table",dp,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",mp,[e.createElementVNode("span",pp,[f.isPrevYear?(e.openBlock(),e.createElementBlock("span",{key:0,class:"prev-year",title:e.unref(l).prevYear,onClick:w},[e.createVNode(ve,{name:"angle-left"})],8,fp)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),e.createElementVNode("span",{class:"datetime-switch-year",onClick:z[0]||(z[0]=H=>b(H,"years"))},e.toDisplayString(f.titleYear),1),e.createElementVNode("span",hp,[f.isNextYear?(e.openBlock(),e.createElementBlock("span",{key:0,class:"next-year",title:e.unref(l).nextYear,onClick:M},[e.createVNode(ve,{name:"angle-right"})],8,gp)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])])])]),e.createElementVNode("tbody",null,[e.createElementVNode("tr",null,[e.createElementVNode("td",yp,[e.createElementVNode("div",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(H,v)=>(e.openBlock(),e.createElementBlock("span",{key:`${s}-month-${v}`,role:"button",tabindex:"0","aria-disabled":H.isDisabled,class:e.normalizeClass(H.cls),onClick:S=>N(S,H),onKeydown:[e.withKeys(e.withModifiers(S=>N(S,H),["prevent"]),["enter"]),e.withKeys(e.withModifiers(S=>N(S,H),["prevent"]),["space"])],onMouseover:S=>J(S,H)},e.toDisplayString(H.month),43,vp))),128))])])])])])],10,up))}}),Sp=["id"],wp={class:"table-base"},Ep={class:"time-head time-head-year"},bp={class:"time-prev"},Cp=["title"],xp={class:"time-next"},Bp=["title"],Dp={class:"time-body-year"},Ip=["aria-disabled","onClick","onKeydown","onMouseover"],Tp=e.defineComponent({name:"ClCalendarsYears",__name:"CalendarsYears",props:{className:String,viewValue:String,selectValue:String,startValue:String,endValue:String,hoverValue:String,minValue:String,maxValue:String},emits:{onChangeDate:n=>!0,onSelectDate:(n,a)=>!0,onHoverDate:(n,a)=>!0,onInitComplete:n=>!0},setup(n,{emit:a}){const i=n,t=a,{optPageLanguage:s,getPageLanguage:l}=Le();l("dataTime");const d=e.inject("$DateTimeTop"),u=e.inject("$DateTimeTopBase"),r=e.inject("$DateTimeBase");(!d||!u||!r)&&Se.warn("ClCalendarsYears","未找到 $DateTimeTop/$DateTimeTopBase/$DateTimeBase 注入,请确保组件在 ClDateTime 组件树内使用");const c=`calendarsYears-${o.getRandom(5)}`,m=d?.elId?`${d.elId}-calendarsYears-${o.getRandom(5)}`:void 0,p=e.computed(()=>{let q={"panel-calendarsyears":!0};return q=o.getJsonMerge(q,de.getClassNameJson(i.className)),q}),f=e.reactive({isPrevYear:!1,titleYear:"",isNextYear:!1}),h=e.ref([]),g={startYear:0,viewDate:null,selectDate:null,startDate:null,endDate:null,hoverDate:null},y=()=>{if(!g.viewDate)return;const q=`${g.startYear}-${g.startYear+9}`,z=d.getMomentDate({year:g.startYear-1,month:11}),H=d.getMomentDate({year:g.startYear+10,month:0}),v=z?r.checkDataMinMax(z.endOf("month"),"year"):!1,S=H?r.checkDataMinMax(H.startOf("month"),"year"):!1;f.isPrevYear=!v,f.titleYear=q,f.isNextYear=!S},V=()=>{const q=r.getFocusDate(),z=g.selectDate,H=[];for(let v=-1;v<11;v+=1){const S=g.startYear+v,C=r.getViewMin(S),$=v===-1,k=v>9;let I=z?C.isSame(z,"year"):!1,L=!!(q&&C.isSame(q,"year"));const _=r.checkDataMinMax(C,"year");let R=!1,P=!1,Q=!1;if(u.isRange){if(L=!1,g.hoverDate){const ue=parseInt(g.hoverDate.format("YYYY"),10);g.startDate&&g.endDate&&g.startDate.isSame(g.hoverDate,"year")&&g.hoverDate.isBefore(g.endDate,"year")?(R=S===parseInt(g.startDate.format("YYYY"),10),P=S===parseInt(g.endDate.format("YYYY"),10),Q=R||P||S>parseInt(g.startDate.format("YYYY"),10)&&S<parseInt(g.endDate.format("YYYY"),10)):g.startDate?(R=S===parseInt(g.startDate.format("YYYY"),10),Q=R||S===ue,Q=Q||C.isAfter(g.startDate,"year")&&C.isBefore(g.hoverDate,"year"),P=!1):g.endDate&&(P=S===parseInt(g.endDate.format("YYYY"),10),Q=P||S===ue,Q=Q||C.isAfter(g.hoverDate,"year")&&C.isBefore(g.endDate,"year"),R=!!(g.hoverDate&&g.hoverDate.isSame(g.endDate,"year"))&&P)}else R=!!(g.startDate&&C.isSame(g.startDate,"year")),g.endDate&&g.startDate&&(P=C.isSame(g.endDate,"year"),Q=C.isAfter(g.startDate,"year")&&C.isBefore(g.endDate,"year"));I=R||P}u.layerType==="years"&&(L=!1);const oe=de.getAddClass("year",{old:$,new:k,active:I&&!$&&!k,focused:L,disabled:_,"date-start":R&&!$&&!k,"date-end":P&&!$&&!k,"range-in":Q&&!$&&!k});H.push({cls:oe,year:S,isDisabled:_,value:S})}h.value=H},E=()=>{g.viewDate&&(g.startYear=Math.floor(g.viewDate.year()/10)*10,y(),V())},B=(q,z,H)=>{g.viewDate&&(g.viewDate=g.viewDate.clone()[q](z,H),E(),t("onChangeDate",g.viewDate))};let T=!1;const D=()=>{T||(T=!0,e.nextTick(()=>{t("onInitComplete","years")}))},x=()=>{g.selectDate=d.getMomentDate(i.selectValue),g.startDate=d.getMomentDate(i.startValue),g.endDate=d.getMomentDate(i.endValue),g.hoverDate=d.getMomentDate(i.hoverValue)},O=(q,z,H)=>{if(z!==H){const v=d.getMomentDate(z);v&&v.isValid()?(g[q]=v,x(),E(),D()):(g.viewDate=null,g.startYear=0,h.value=[],f.isPrevYear=!1,f.isNextYear=!1,f.titleYear="")}},w=()=>{const q=d.getMomentDate(i.viewValue);q&&q.isValid()&&(g.viewDate=q,x(),E(),D())};e.onMounted(()=>{e.nextTick(()=>{w()})}),e.watch(()=>i.viewValue,(q,z)=>{O("viewDate",q,z)}),e.watch([()=>i.selectValue,()=>i.startValue,()=>i.endValue,()=>i.hoverValue],()=>{g.viewDate&&(g.selectDate=d.getMomentDate(i.selectValue),g.startDate=d.getMomentDate(i.startValue),g.endDate=d.getMomentDate(i.endValue),g.hoverDate=d.getMomentDate(i.hoverValue),V())}),e.watch([()=>i.minValue,()=>i.maxValue],()=>{g.viewDate&&(y(),V())});const M=q=>{q.preventDefault(),q.stopPropagation(),B("subtract",10,"years")},b=q=>{q.preventDefault(),q.stopPropagation(),B("add",10,"years")},N=(q,z)=>{q.preventDefault(),q.stopPropagation(),z.isDisabled||t("onSelectDate","years",z)},J=(q,z)=>{q.preventDefault(),q.stopPropagation(),z.isDisabled||t("onHoverDate","years",z)};return(q,z)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(p.value),id:e.unref(m)},[e.createElementVNode("table",wp,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[e.createElementVNode("th",Ep,[e.createElementVNode("span",bp,[f.isPrevYear?(e.openBlock(),e.createElementBlock("span",{key:0,class:"prev-year",title:e.unref(s).prevYear10,onClick:M},[e.createVNode(ve,{name:"angle-left"})],8,Cp)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),e.createElementVNode("span",null,e.toDisplayString(f.titleYear),1),e.createElementVNode("span",xp,[f.isNextYear?(e.openBlock(),e.createElementBlock("span",{key:0,class:"next-year",title:e.unref(s).nextYear10,onClick:b},[e.createVNode(ve,{name:"angle-right"})],8,Bp)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])])])]),e.createElementVNode("tbody",null,[e.createElementVNode("tr",null,[e.createElementVNode("td",Dp,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(H,v)=>(e.openBlock(),e.createElementBlock("span",{key:`${c}-${H.year}-${v}`,role:"button",tabindex:"0","aria-disabled":H.isDisabled,class:e.normalizeClass(H.cls),onClick:S=>N(S,H),onKeydown:[e.withKeys(e.withModifiers(S=>N(S,H),["prevent"]),["enter"]),e.withKeys(e.withModifiers(S=>N(S,H),["prevent"]),["space"])],onMouseover:S=>J(S,H)},e.toDisplayString(H.year),43,Ip))),128))])])])])],10,Sp))}}),Np=["id"],Vp={class:"times-container"},_p=["title"],Mp=["title"],Op={class:"times-clock"},Ap={class:"clock-nums"},Lp=["aria-disabled","onClick","onKeydown"],$p={class:"clock-pointer"},Fp={class:"clock-am"},Pp="2000-01-01",Rp=e.defineComponent({name:"ClCalendarsClocks",__name:"CalendarsClock",props:{className:String,selectDay:String,selectValue:String,minValue:String,maxValue:String,isShowPointer:{type:Boolean,default:!0},isShowSubmit:{type:Boolean,default:!1},isShowCancel:{type:Boolean,default:!1},isClickOverlay:{type:Boolean,default:!1}},emits:{onSubmit:n=>!0,onInitComplete:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=`calendarsClock-${o.getRandom(5)}`,{optPageLanguage:l,getPageLanguage:d}=Le();d("dataTime");const u=e.inject("$DateTimeTop"),r=e.inject("$DateTimeTopBase");(!u||!r)&&Se.warn("ClCalendarsClocks","未找到 $DateTimeTop/$DateTimeTopBase 注入,请确保组件在 ClDateTime 组件树内使用");const c=u?.elId?`${u.elId}-calendarsClock-${o.getRandom(5)}`:void 0,m=e.reactive({isOpen:!1,activePointer:"hour",activeAm:"am"}),p=e.reactive({hour:!0,hourDisabled:!1,minute:!0,minuteDisabled:!1,minuteShowAddSub:!0,second:!0,secondDisabled:!1}),f=e.reactive({hour:-90,hourMinute:0,minute:-90,minuteSecond:0,second:-90}),h=e.reactive({hour:"00",minute:"00",second:"00"}),g=e.ref([]),y={selectDayDate:null,minDate:null,maxDate:null,timeAngle:{hour:30,minute:6,second:6},num:{hourAm:[0,1,2,3,4,5,6,7,8,9,10,11],hourPm:[12,13,14,15,16,17,18,19,20,21,22,23],minute:[0,5,10,15,20,25,30,35,40,45,50,55],second:[0,5,10,15,20,25,30,35,40,45,50,55]},origValue:{hour:"00",minute:"00",second:"00"},lastValue:{hour:"00",minute:"00",second:"00"},isCheckMin:!1,checkMinDiff:null,min:{hour:0,minute:0,second:0},isCheckMax:!1,checkMaxDiff:null,max:{hour:0,minute:0,second:0}},V=e.computed(()=>{let ie={"panel-calendarsclocks":!0,"datetime-times":!0};return ie["times-open"]=m.isOpen,ie=o.getJsonMerge(ie,de.getClassNameJson(i.className)),ie}),E=e.computed(()=>{const ie={"pointer-hour":!0};return ie["pointer-active"]=m.activePointer==="hour",ie["pointer-disabled"]=p.hourDisabled,ie}),B=e.computed(()=>{const ie={"pointer-minute":!0};return ie["pointer-active"]=m.activePointer==="minute",ie["pointer-disabled"]=p.minuteDisabled,ie}),T=e.computed(()=>{const ie={"pointer-second":!0};return ie["pointer-active"]=m.activePointer==="second",ie["pointer-disabled"]=p.secondDisabled,ie}),D=e.computed(()=>{const ie={"am-am":!0};return ie["am-active"]=m.activeAm==="am",ie}),x=e.computed(()=>{const ie={"am-pm":!0};return ie["am-active"]=m.activeAm==="pm",ie}),O=e.computed(()=>{const ie={"clock-set":!0,"clock-set-hour":!0};return ie["clock-set-active"]=m.activePointer==="hour",ie["clock-set-disabled"]=p.hourDisabled,ie}),w=e.computed(()=>{const ie={"clock-set":!0,"clock-set-minute":!0};return ie["clock-set-active"]=m.activePointer==="minute",ie["clock-set-disabled"]=p.minuteDisabled,ie}),M=e.computed(()=>{const ie={"clock-set":!0,"clock-set-second":!0};return ie["clock-set-active"]=m.activePointer==="second",ie["clock-set-disabled"]=p.secondDisabled,ie}),b=(ie,ne)=>{y[ie]=u.getMomentDate(ne)},N=ie=>{let ne=parseInt(y.lastValue[ie],10),A=parseInt(h[ie],10),te=0;return ie==="hour"?(A===0&&ne===23&&(A=24),ne===0&&A===23&&(ne=24),A-ne>6&&(ne+=12),ne-A>=6&&(A+=12),te=A-ne):(A-ne>30&&(ne+=60),ne-A>=30&&(A+=60),te=A-ne),te},J=ie=>{const A=N(ie)*y.timeAngle[ie];return f[ie]+(A>=360?A%360:A)},q=()=>{const ie=J("hour"),ne=y.timeAngle.hour*parseFloat((parseInt(h.minute,10)/60).toString()),A=J("minute"),te=y.timeAngle.second*parseFloat((parseInt(h.second,10)/60).toString()),ce=J("second");f.hour=ie,f.hourMinute=ne,f.minute=A,f.minuteSecond=te,f.second=ce},z=ie=>parseInt(ie,10)<12?"am":"pm",H=(ie,ne)=>{let A=!0;switch(ie){case"hour":A=!0;break;case"minute":A=parseInt(h.hour,10)===y[ne].hour;break;case"second":A=parseInt(h.hour,10)===y[ne].hour&&parseInt(h.minute,10)===y[ne].minute;break}return A},v=()=>y.isCheckMin&&y.isCheckMax&&y.checkMinDiff===0&&y.checkMaxDiff===0&&y.min.hour>y.max.hour,S=(ie,ne)=>{let A=!1;return v()&&ie==="hour"?A=ne<y.min[ie]&&ne>y.max[ie]:y.isCheckMin&&(y.checkMinDiff===0?H(ie,"min")&&(A=ne<y.min[ie]):y.checkMinDiff<0&&(A=!0)),!A&&y.isCheckMax&&(y.checkMaxDiff===0?H(ie,"max")&&(A=ne>y.max[ie]):y.checkMaxDiff>0&&(A=!0)),A},C=ie=>{let ne=ie;ne==="hour"&&(ne=m.activeAm==="am"?"hourAm":"hourPm");const A=p[`${ie}Disabled`],te=[];y.num[ne].forEach((ce,pe)=>{const he={num:ce,cls:"clock-num",isDisabled:!1};he.cls+=` clock-num${pe+1} `,he.isDisabled=A?!0:S(ie,ce),he.isDisabled&&(he.cls+=" clock-nums-disabled "),te.push(he)}),g.value=te},$=ie=>{m.activePointer=ie,ie==="hour"&&(m.activeAm=z(h.hour)),C(ie)},k=ie=>{let ne=null;if(!o.isUndefined(ie)&&!o.isUndefined(y.selectDayDate)){const A=y.selectDayDate.clone().format("YYYY-MM-DD 00:00:00"),te=ie.clone().format("YYYY-MM-DD 00:00:00");ne=u.Dayjs(A).diff(u.Dayjs(te))}return ne},I=(ie=!0)=>{f.hour=-90,f.hourMinute=0,f.minute=-90,f.minuteSecond=0,f.second=-90,y.lastValue={hour:"00",minute:"00",second:"00"},q(),e.nextTick(()=>{const ne=h.hour,A=h.minute,te=h.second;y.lastValue={hour:ne,minute:A,second:te},ie&&(y.origValue={hour:ne,minute:A,second:te})})},L=(ie,ne)=>{y.lastValue.hour=h.hour,y.lastValue.minute=h.minute,y.lastValue.second=h.second,h[ie]=o.getFillZero(ne),q(),i.isShowSubmit||t("onSubmit",`${h.hour}:${h.minute}:${h.second}`)},_=ie=>{let ne=0,A=0,te=0;if(!o.isEmpty(ie)){const ce=(o.isEmpty(y.selectDayDate)?u.getNow():y.selectDayDate).format("YYYY-MM-DD"),pe=u.getMomentDate(`${ce} ${ie}`);pe&&pe.isValid()&&(ne=pe.hour(),A=pe.minute(),te=pe.second())}return{HH:ne,mm:A,ss:te}},R=()=>{let ie=!0,ne=!0;const A=o.isEmpty(y.selectDayDate),te=_(i.selectValue),ce=te.HH,pe=te.mm,he=te.ss;switch(r.layerType){case"hours":ie=!1,ne=!1;break;case"minutes":ne=!1;break}y.isCheckMin=!o.isUndefined(y.minDate),y.isCheckMin&&(y.checkMinDiff=u.checkIsTimes()?0:k(y.minDate),y.min={hour:y.minDate.hour(),minute:y.minDate.minute(),second:y.minDate.second()}),y.isCheckMax=!o.isUndefined(y.maxDate),y.isCheckMax&&(y.checkMaxDiff=u.checkIsTimes()?0:k(y.maxDate),y.max={hour:y.maxDate.hour(),minute:y.maxDate.minute(),second:y.maxDate.second()});const Ee=o.getFillZero(ce);let be=o.getFillZero(pe),xe=o.getFillZero(he);ie||(be="00"),ne||(xe="00"),y.origValue={hour:Ee,minute:be,second:xe},p.hour=!0,p.minute=ie,p.second=ne,h.hour=Ee,h.minute=be,h.second=xe,u.checkIsTimes()||(p.hourDisabled=A,p.minuteDisabled=A,p.secondDisabled=A),r.layerType==="hours"&&(p.minute=!0,p.minuteDisabled=!0,p.minuteShowAddSub=!1),P(),Q()},P=()=>{y.lastValue={hour:"00",minute:"00",second:"00"},f.hour=-90,f.hourMinute=0,f.minute=-90,f.minuteSecond=0,f.second=-90},Q=()=>{q(),m.activeAm=z(h.hour),C(m.activePointer)},oe=()=>{m.isOpen=i.isShowPointer,b("selectDayDate",u.checkIsTimes()?Pp:i.selectDay),b("minDate",u.getValueEffective(i.minValue)),b("maxDate",u.getValueEffective(i.maxValue)),R(),$("hour"),I(),e.nextTick(()=>{t("onInitComplete","times")})},ue=ie=>{let ne=!1;return p[ie]&&!p[`${ie}Disabled`]&&(m.isOpen?ne=!0:(I(!1),m.isOpen=!0,$(ie))),ne},Y=(ie,ne)=>{if(p[ie]&&!p[`${ie}Disabled`]&&m.isOpen){let A=!0,te=0,ce=ie==="hour"?23:59;if(y.isCheckMin&&(y.checkMinDiff===0?H(ie,"min")&&(te=y.min[ie]):y.checkMinDiff<0&&(A=!1)),y.isCheckMax&&(y.checkMaxDiff===0?H(ie,"max")&&(ce=y.max[ie]):y.checkMaxDiff>0&&(A=!1)),A){const pe=parseInt(h[ie],10);let he=0;v()&&ie==="hour"?he=ne==="add"?pe>=23?0:pe+1:pe<=0?23:pe-1:ne==="add"?he=pe<te||pe>=ce?te:pe+1:he=pe>ce||pe<=te?ce:pe-1,S(ie,he)||(L(ie,he),$(ie))}}};e.onMounted(()=>{e.nextTick(()=>{oe()})}),e.watch(()=>i.selectDay,(ie,ne)=>{b("selectDayDate",ie),R()}),e.watch(()=>i.minValue,(ie,ne)=>{const A=u.getValueEffective(ie);b("minDate",A),R()}),e.watch(()=>i.maxValue,(ie,ne)=>{const A=u.getValueEffective(ie);b("maxDate",A),R()}),e.watch(()=>i.selectValue,(ie,ne)=>{const A=_(ie),te=o.getFillZero(A.HH),ce=o.getFillZero(A.mm),pe=o.getFillZero(A.ss);(h.hour!==te||h.minute!==ce||h.second!==pe)&&(h.hour=te,h.minute=ce,h.second=pe,y.origValue={hour:te,minute:ce,second:pe},P(),Q())});const Z=ie=>{p[ie]&&!p[`${ie}Disabled`]&&($(ie),m.isOpen||(I(),m.isOpen=!0))},se=ie=>{if(!ie.isDisabled){const ne=m.activePointer,A=parseInt(h[ne],10),te=ie.num;te!==A&&L(ne,te)}},K=ie=>{m.activeAm=ie,m.activePointer="hour";const ne=parseInt(h.hour,10);ie==="pm"&&ne<12?h.hour=o.getFillZero(ne+12):ie==="am"&&ne>=12&&(h.hour=o.getFillZero(ne-12)),q(),C("hour")},W=()=>ue("hour"),U=ie=>{let ne=!1,A=!1;const te=v();if(y.isCheckMin){if(y.checkMinDiff<0)ne=!0,A=!0;else if(y.checkMinDiff===0){const ce=parseInt(h[ie],10);H(ie,"min")&&(ne=te?ce===y.min[ie]:ce<=y.min[ie])}}if(y.isCheckMax){if(y.checkMaxDiff>0)ne=!0,A=!0;else if(y.checkMaxDiff===0){const ce=parseInt(h[ie],10);H(ie,"max")&&(A=te?ce===y.max[ie]:ce>=y.max[ie])}}return{subtractDisabled:ne,addDisabled:A}},ae=ie=>(o.isEmpty(ie.type)||Y("hour",ie.type),{value:h.hour,...U("hour")}),G=()=>ue("minute"),X=ie=>(o.isEmpty(ie.type)||Y("minute",ie.type),{value:h.minute,...U("minute")}),ee=()=>ue("second"),F=ie=>(o.isEmpty(ie.type)||Y("second",ie.type),{value:h.second,...U("second")}),j=()=>{i.isClickOverlay&&m.isOpen&&(u.checkIsTimes()||(m.isOpen=!1),t("onSubmit",`${h.hour}:${h.minute}:${h.second}`))},le=()=>{u.checkIsTimes()||(m.isOpen=!1),t("onSubmit",`${h.hour}:${h.minute}:${h.second}`)},me=()=>{(h.hour!==y.origValue.hour||h.minute!==y.origValue.minute||h.second!==y.origValue.second)&&(y.lastValue.hour=h.hour,y.lastValue.minute=h.minute,y.lastValue.second=h.second,h.hour=y.origValue.hour,h.minute=y.origValue.minute,h.second=y.origValue.second,Q()),u.checkIsTimes()||(m.isOpen=!1)};return(ie,ne)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(V.value),id:e.unref(c)},[ne[15]||(ne[15]=e.createElementVNode("div",{class:"datetime-times-inner"},null,-1)),e.createElementVNode("div",null,[e.createElementVNode("div",Vp,[e.createElementVNode("div",{class:"times-overlay",onClick:j}),n.isShowCancel?(e.openBlock(),e.createElementBlock("div",{key:0,class:"times-cancel",title:e.unref(l).common.cancel,onClick:me},[e.createVNode(ve,{name:"close1"})],8,_p)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isShowSubmit?(e.openBlock(),e.createElementBlock("div",{key:2,class:"times-submit",title:e.unref(l).common.submit,onClick:le},[e.createVNode(ve,{name:"check1"})],8,Mp)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),e.createElementVNode("div",Op,[e.createElementVNode("div",Ap,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(g.value,(A,te)=>(e.openBlock(),e.createElementBlock("div",{key:`${s}-clock-${te}`,role:"button",tabindex:"0","aria-disabled":A.isDisabled,class:e.normalizeClass(A.cls),onClick:ce=>se(A),onKeydown:[e.withKeys(e.withModifiers(ce=>se(A),["prevent"]),["enter"]),e.withKeys(e.withModifiers(ce=>se(A),["prevent"]),["space"])]},e.toDisplayString(A.num),43,Lp))),128))]),e.createElementVNode("div",$p,[p.hour?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(E.value),onClick:ne[0]||(ne[0]=A=>Z("hour")),style:e.normalizeStyle({transform:`rotate(${f.hour+f.hourMinute}deg)`})},null,6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),p.minute?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(B.value),onClick:ne[1]||(ne[1]=A=>Z("minute")),style:e.normalizeStyle({transform:`rotate(${f.minute+f.minuteSecond}deg)`})},null,6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),p.second?(e.openBlock(),e.createElementBlock("div",{key:4,class:e.normalizeClass(T.value),onClick:ne[2]||(ne[2]=A=>Z("second")),style:e.normalizeStyle({transform:`rotate(${f.second}deg)`})},null,6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))]),e.withDirectives(e.createElementVNode("div",Fp,[e.createElementVNode("small",{role:"button",tabindex:"0",class:e.normalizeClass(D.value),onClick:ne[3]||(ne[3]=A=>K("am")),onKeydown:[ne[4]||(ne[4]=e.withKeys(e.withModifiers(A=>K("am"),["prevent"]),["enter"])),ne[5]||(ne[5]=e.withKeys(e.withModifiers(A=>K("am"),["prevent"]),["space"]))]},e.toDisplayString(e.unref(l).am),35),e.createElementVNode("small",{role:"button",tabindex:"0",class:e.normalizeClass(x.value),onClick:ne[6]||(ne[6]=A=>K("pm")),onKeydown:[ne[7]||(ne[7]=e.withKeys(e.withModifiers(A=>K("pm"),["prevent"]),["enter"])),ne[8]||(ne[8]=e.withKeys(e.withModifiers(A=>K("pm"),["prevent"]),["space"]))]},e.toDisplayString(e.unref(l).pm),35)],512),[[e.vShow,m.activePointer==="hour"]])])]),p.hour?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(O.value),onClick:ne[10]||(ne[10]=A=>Z("hour"))},[e.createVNode(hn,{value:h.hour,"onUpdate:value":ne[9]||(ne[9]=A=>h.hour=A),size:"small",isClean:!1,disabled:p.hourDisabled,isTextRead:!0,fillZeroCount:2,isLoop:!0,btnTheme:"upDown",operateBtnDownBeforeCallback:W,calculationOperateValueCallback:ae},null,8,["value","disabled"])],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),p.minute&&p.minuteShowAddSub?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(w.value),onClick:ne[12]||(ne[12]=A=>Z("minute"))},[e.createVNode(hn,{value:h.minute,"onUpdate:value":ne[11]||(ne[11]=A=>h.minute=A),size:"small",isClean:!1,disabled:p.minuteDisabled,isTextRead:!0,fillZeroCount:2,isLoop:!0,btnTheme:"upDown",operateBtnDownBeforeCallback:G,calculationOperateValueCallback:X},null,8,["value","disabled"])],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),p.second?(e.openBlock(),e.createElementBlock("div",{key:4,class:e.normalizeClass(M.value),onClick:ne[14]||(ne[14]=A=>Z("second"))},[e.createVNode(hn,{value:h.second,"onUpdate:value":ne[13]||(ne[13]=A=>h.second=A),size:"small",isClean:!1,disabled:p.secondDisabled,isTextRead:!0,fillZeroCount:2,isLoop:!0,btnTheme:"upDown",operateBtnDownBeforeCallback:ee,calculationOperateValueCallback:F},null,8,["value","disabled"])],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))])],10,Np))}}),Hp=["id"],Jo=e.defineComponent({name:"ClCalendarsBase",__name:"CalendarsBase",props:{className:String,viewValue:String,selectValue:String,startValue:String,endValue:String,hoverValue:String,minValue:String,maxValue:String},emits:{onSelectDate:n=>!0,onChangeViewValue:n=>!0,onHoverDate:n=>!0,onChangeViewType:n=>!0,onSelectTime:n=>!0,onInitComplete:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=e.inject("$DateTimeTop"),l=e.inject("$DateTimeTopBase");(!s||!l)&&Se.warn("ClCalendarsBase","未找到 $DateTimeTop/$DateTimeTopBase 注入,请确保组件在 ClDateTime 组件树内使用");const d=s?.elId?`${s.elId}-calendarsBase-${o.getRandom(5)}`:void 0,u=e.computed(()=>{let z={"panel-calendarsbase":!0};return z=o.getJsonMerge(z,de.getClassNameJson(i.className)),z}),r=e.reactive({currentView:"",viewValue:"",selectValue:"",selectClockDay:"",selectClockTime:""}),c=e.reactive({isShow:!1,isViewDay:!1,isShowClockPointer:!1,isShowClockSubmit:!1,isShowClockCancel:!1,isClockClickOverlay:!1}),m={viewDate:null,selectDate:null,focusDate:null,minDate:null,maxDate:null},p=(z,H)=>{m[z]=o.isString(H)?s.getMomentDate(H):null},f=z=>{const H=Object.keys(z);o.isExistValue(H,"viewValue")&&l.layerView===z.currentView&&t("onChangeViewValue",z.viewValue),H.forEach(v=>{const S=v,C=z[S];o.isExistJsonKey(r,S)&&r[S]!==C&&(r[S]=C),o.isExistJsonKey(m,S)&&(m[S]=C)})},h=(z,H)=>{let v=!1;return o.isEmpty(z)||o.isNaN(z)||(o.isEmpty(m.minDate)||(v=s.Dayjs(z).isBefore(m.minDate,H)),!v&&!o.isEmpty(m.maxDate)&&(v=s.Dayjs(z).isAfter(m.maxDate,H))),v},g=(z,H)=>{let v=0,S=1;if(o.isEmpty(m.minDate))o.isUndefined(H)||(v=H);else{const C=z===m.minDate.year();let $=!0;o.isUndefined(H)?v=C?m.minDate.month():0:($=H===m.minDate.month(),v=H),S=C&&$?m.minDate.date():1}return s.getMomentDate({year:z,month:v,day:S})??s.getNow().startOf("year")},y=z=>{let H="";switch(z){case"months":H="days";break;case"years":H="months";break;default:H="days";break}return H},V=z=>{const v=(z||m.selectDate||m.viewDate).format("YYYY-MM-DD")+" "+(o.isEmpty(r.selectClockTime)?"00:00:00":r.selectClockTime);return s.Dayjs(v)},E=(z,H)=>{const v=m.viewDate.clone(),S=parseInt(H.value,10);if(o.isNaN(S))return V(v);let C;switch(z){case"days":{let $=0;H.isNew?$=1:H.isOld&&($=-1),C=v.month(v.month()+$).date(S);break}case"months":{const $=m.selectDate||v,k=v.month(S);C=k.date(Math.min($.date(),k.daysInMonth()));break}case"years":C=v.month(0).date(1).year(S);break;default:C=v;break}return V(C)},B=()=>{r.viewValue=m.viewDate.format(l.formatIn),m.focusDate=m.viewDate.clone()},T=z=>{p("selectDate",z==="-1"?"":z);const H=m.selectDate?m.selectDate.format("YYYY-MM-DD"):"";r.selectValue=H,r.selectClockDay=H,r.selectClockTime=m.selectDate?m.selectDate.format("HH:mm:ss"):""},D=()=>{let z=!1,H=!1,v=!1,S=!1,C=!1,$=!1;r.currentView==="times"?(z=!0,v=!0,$=!1,S=l.isDefault&&l.isShowPopup,C=l.isDefault&&l.isShowPopup,l.layerType==="hours"&&(C=!1,S=!1)):r.currentView==="days"&&(H=l.timeType==="datetime",H&&(C=!0,S=!0,v=!1,$=!0)),c.isShow=z,c.isViewDay=H,c.isShowClockPointer=v,c.isShowClockSubmit=S,c.isShowClockCancel=C,c.isClockClickOverlay=$},x=()=>{r.currentView=l.layerView,m.viewDate=s.getViewDate(i.viewValue),B(),T(i.selectValue),p("minDate",i.minValue),p("maxDate",i.maxValue),D()};e.onMounted(()=>{e.nextTick(()=>{x()})}),e.watch(()=>i.viewValue,(z,H)=>{m.viewDate=s.getViewDate(z),B()}),e.watch(()=>i.selectValue,(z,H)=>{const v=l.isRange&&z==="-1";let S=z;const C=r.selectClockTime;v&&(S=""),T(S),v&&(r.selectClockTime=C)}),e.watch(()=>i.minValue,(z,H)=>{p("minDate",z)}),e.watch(()=>i.maxValue,(z,H)=>{p("maxDate",z)});const O=z=>{f({currentView:r.currentView,viewDate:z.clone(),viewValue:z.format(l.formatIn)})},w=z=>{r.currentView=z,m.focusDate=m.viewDate.clone(),D(),t("onChangeViewType",z)},M=(z,H)=>{const v=E(z,H),S=v.format("YYYY-MM-DD"),C={};if(l.layerView===z)C.selectDate=v,C.selectValue=S,l.isRange||(C.selectClockDay=S),f(C),t("onSelectDate",S);else{const $=y(z);if($===z){C.selectDate=v,C.selectValue=S,l.isRange||(C.selectClockDay=S),f(C),t("onSelectDate",S);return}C.viewDate=v.clone().startOf("month"),C.viewValue=C.viewDate.format(l.formatIn),C.currentView=$,f(C),D(),t("onChangeViewType",C.currentView)}},b=(z,H)=>{const v=E(z,H);t("onHoverDate",v)},N=z=>{f({selectClockTime:z}),t("onSelectTime",z)},J=new Set,q=z=>{l.layerView===z&&!J.has(z)&&(J.add(z),t("onInitComplete",z))};return e.provide("$DateTimeBase",{checkDataMinMax:h,getViewMin:g,getFocusDate:()=>m.focusDate&&m.focusDate.clone()}),(z,H)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(d),class:e.normalizeClass(u.value)},[r.currentView==="days"?(e.openBlock(),e.createBlock(cp,{key:0,viewValue:r.viewValue,selectValue:r.selectValue,startValue:n.startValue,endValue:n.endValue,hoverValue:n.hoverValue,minValue:n.minValue,maxValue:n.maxValue,onOnChangeDate:O,onOnChangeType:w,onOnSelectDate:M,onOnHoverDate:b,onOnInitComplete:q},null,8,["viewValue","selectValue","startValue","endValue","hoverValue","minValue","maxValue"])):r.currentView==="months"?(e.openBlock(),e.createBlock(kp,{key:1,viewValue:r.viewValue,selectValue:r.selectValue,startValue:n.startValue,endValue:n.endValue,hoverValue:n.hoverValue,minValue:n.minValue,maxValue:n.maxValue,onOnChangeDate:O,onOnChangeType:w,onOnSelectDate:M,onOnHoverDate:b,onOnInitComplete:q},null,8,["viewValue","selectValue","startValue","endValue","hoverValue","minValue","maxValue"])):r.currentView==="years"?(e.openBlock(),e.createBlock(Tp,{key:2,viewValue:r.viewValue,selectValue:r.selectValue,startValue:n.startValue,endValue:n.endValue,hoverValue:n.hoverValue,minValue:n.minValue,maxValue:n.maxValue,onOnChangeDate:O,onOnSelectDate:M,onOnHoverDate:b,onOnInitComplete:q},null,8,["viewValue","selectValue","startValue","endValue","hoverValue","minValue","maxValue"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),c.isShow||c.isViewDay?(e.openBlock(),e.createElementBlock("div",{key:4,class:e.normalizeClass({"datetime-days-times":c.isViewDay})},[e.createVNode(Rp,{selectDay:r.selectClockDay,selectValue:r.selectClockTime,minValue:n.minValue,maxValue:n.maxValue,isShowPointer:c.isShowClockPointer,isShowSubmit:c.isShowClockSubmit,isShowCancel:c.isShowClockCancel,isClickOverlay:c.isClockClickOverlay,onOnSubmit:N,onOnInitComplete:q},null,8,["selectDay","selectValue","minValue","maxValue","isShowPointer","isShowSubmit","isShowCancel","isClickOverlay"])],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))],10,Hp))}}),Up=["tabindex","aria-disabled","onKeydown"],zp=e.defineComponent({name:"ClDateTimeDefault",__name:"DateTimeDefault",props:{className:String,value:String,minValue:String,maxValue:String},emits:{onSelectValue:n=>!0,onInitComplete:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("dataTime");const u=e.inject("$DateTimeTop"),r=e.inject("$DateTimeTopBase");(!u||!r)&&Se.warn("ClDateTimeDefault","未找到 $DateTimeTop/$DateTimeTopBase 注入,请确保组件在 ClDateTime 组件树内使用");const c=e.reactive({isShowSubmit:!1,isSubmitDisplay:!1}),m=e.reactive({day:"",time:""}),p=e.computed(()=>{let w={"panel-date-time-default":!0,"datetime-default":!0,"datetime-panel-body":!0};return w=o.getJsonMerge(w,de.getClassNameJson(t.className)),w}),f=()=>{const w=u.getMergeDayTime(m.day,m.time),M=u.checkValue(w);c.isSubmitDisplay=o.isEmpty(m.day)||M.errMsg.length>0},h=w=>{let M=!1;r.timeType==="datetime"&&(M=w==="days"),c.isShowSubmit=M},g=w=>{let M="",b="",N=!0;if(o.isNonEmptyString(w)){const J=u.getMomentDate(w);J&&(M=J.format("YYYY-MM-DD"),b=J.format("HH:mm:ss"),N=!1)}m.day=M,m.time=b,c.isSubmitDisplay=N,f()},y=()=>{h(r.layerView),g(t.value)},V=()=>{const w=u.getMomentDate(u.getMergeDayTime(m.day,m.time));w&&s("onSelectValue",w)};e.onMounted(()=>{e.nextTick(()=>{y()})}),e.watch(()=>t.value,(w,M)=>{w!==M&&g(w)}),e.watch([()=>t.minValue,()=>t.maxValue],()=>{f()});const E=w=>{m.day=w,f(),r.timeType==="date"&&V()},B=w=>{m.time=w,f(),(r.timeType==="time"||r.timeType==="datetime"&&!c.isSubmitDisplay)&&V()},T=w=>{h(w)},D=()=>{c.isShowSubmit&&!c.isSubmitDisplay&&V()},x=()=>{s("onInitComplete")};return a({getValue:()=>{const w=u.getMergeDayTime(m.day,m.time);return u.getMomentDate(w)}}),(w,M)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(Jo,{class:e.normalizeClass(p.value),selectValue:n.value,viewValue:n.value,minValue:n.minValue,maxValue:n.maxValue,onOnSelectDate:E,onOnSelectTime:B,onOnChangeViewType:T,onOnInitComplete:x},null,8,["class","selectValue","viewValue","minValue","maxValue"]),c.isShowSubmit?(e.openBlock(),e.createElementBlock("div",{key:0,role:"button",tabindex:c.isSubmitDisplay?-1:0,"aria-disabled":c.isSubmitDisplay,class:e.normalizeClass({"datetime-days-submit":!0,"days-submit-disabled":c.isSubmitDisplay}),onClick:D,onKeydown:[e.withKeys(e.withModifiers(D,["prevent"]),["enter"]),e.withKeys(e.withModifiers(D,["prevent"]),["space"])]},[e.createElementVNode("span",null,e.toDisplayString(e.unref(l).common.submit),1)],42,Up)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))}}),Jp=["id"],Kp={class:"calendar-range calendar-left"},Wp={class:"calendar-text"},jp={class:"time-input-base"},Yp=["value","name"],qp={class:"calendar-panel"},Xp={class:"calendar-range calendar-right"},Gp={class:"calendar-text"},Qp={class:"time-input-base"},Zp=["value","name"],ef={class:"calendar-panel"},tf={class:"calendar-range calendar-quick"},nf=["onClick","onKeydown"],of={key:0,class:"panel-quick-btn"},af=e.defineComponent({name:"ClDateTimeRange",__name:"DateTimeRange",props:{className:String,startValue:String,endValue:String,minValue:String,maxValue:String,rangeQuick:{type:Array,default:()=>[]}},emits:{onSubmit:n=>!0,onCancel:()=>!0,onInitComplete:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=`dateTimeRange-${o.getRandom(5)}`,{optPageLanguage:d,getPageLanguage:u}=Le();u("dataTime");const r=e.inject("$DateTimeTop"),c=e.inject("$DateTimeTopBase");(!r||!c)&&Se.warn("ClDateTimeRange","未找到 $DateTimeTop/$DateTimeTopBase 注入,请确保组件在 ClDateTime 组件树内使用");const m=r?.elId?`${r.elId}-dateTimeRange-${o.getRandom(5)}`:void 0,p=e.computed(()=>{let Z={"panel-date-time-range":!0,"panel-range-calendar":!0,"datetime-range":!0,"datetime-panel-body":!0};return Z=o.getJsonMerge(Z,de.getClassNameJson(t.className)),Z}),f=e.reactive({operateViewDataType:"",selectCount:0,hoverValue:"",activeQuick:"",isCheck:!0,isShowQuickBtn:c.isShowPopup||c.timeType==="datetime",previewStart:"",previewEnd:""}),h=e.reactive({view:"",text:"",name:`input_${o.getRandom(8)}`}),g=e.reactive({view:"",text:"",name:`input_${o.getRandom(8)}`}),y=e.reactive({day:"",time:"",value:""}),V=e.reactive({day:"",time:"",value:""}),E=e.ref([]),B=(Z,se)=>{const K=r.getViewDate(Z),W=c.layerView==="years"?10:1,U=f.operateViewDataType;return K[se](W,U).format(c.formatIn)},T=(Z,se)=>{if(o.isEmpty(Z))return"";const K=se==="right"?c.formatOutEnd:c.formatOut;if(o.isString(Z)){const W=r.getMomentDate(Z);return W?W.format(K):""}return Z.format(K)},D=()=>{const Z=r.getMergeDayTime(y.day,y.time);y.value=Z,h.text=T(Z,"left")},x=()=>{const Z=r.getMergeDayTime(V.day,V.time);V.value=Z,g.text=T(Z,"right")},O=()=>{if(f.selectCount===2){let Z="-1";if(!o.isEmpty(y.day)&&!o.isEmpty(V.day)&&!o.isEmpty(E.value)){const se="YYYY-MM-DD";let K=r.getMomentDate(y.day,se),W=r.getMomentDate(V.day,se);if(K&&W){switch(c.layerType){case"years":if(K=r.getMomentDate(K.startOf("year").format(se),se),W=r.getMomentDate(W.endOf("year").format(se),se),!K||!W){f.activeQuick="-1";return}break;case"months":if(K=r.getMomentDate(K.startOf("month").format(se),se),W=r.getMomentDate(W.endOf("month").format(se),se),!K||!W){f.activeQuick="-1";return}break}const U=K,ae=W;U&&ae&&E.value.forEach(G=>{G.start&&G.end&&U.isSame(ze.getDayjsObject(G.start).format(se))&&ae.isSame(ze.getDayjsObject(G.end).format(se))&&(Z=G.id)})}}f.activeQuick=Z}},w=Z=>{const se=y.value,K=V.value,W=o.isEmpty(se),U=o.isEmpty(K),ae=!W&&U,G=W&&!U;let X=!1,ee=!1;if(Z&&(ae||G)){const F=r.getMomentDate(ae?se:K);F&&(X=Z.isBefore(F,"day"),ee=Z.isSame(F,"day"))}return{isStart:ae,isEnd:G,isBefore:X,isSame:ee}},M=Z=>{if(f.selectCount===1){const se=Z.format("YYYY-MM-DD"),K=y.day,W=V.day,U=w(Z);f.hoverValue=se;let ae="",G="";U.isBefore?(ae=se,G=U.isStart?K:W):(ae=U.isEnd?W:K,G=se),f.previewStart=ae,f.previewEnd=G,h.text=T(r.getMergeDayTime(ae,y.time),"left"),g.text=T(r.getMergeDayTime(G,V.time),"right")}},b=Z=>{switch(f.previewStart="",f.previewEnd="",f.selectCount){case 0:case 2:{f.selectCount=1,f.activeQuick="",y.day=Z,D(),V.day="",V.time="",V.value="",g.text=T(r.getMergeDayTime(Z,""),"right"),f.hoverValue=Z;break}case 1:{f.selectCount=2;const se=r.getMomentDate(Z);if(!se){f.selectCount=1;break}const K=w(se);K.isSame?(y.day=Z,D(),V.day=Z,x()):K.isBefore?(V.day=y.day,V.time=y.time,y.day=Z,D(),x()):(V.day=Z,x()),f.hoverValue="";break}}f.selectCount===2&&O()},N=()=>{!f.isShowQuickBtn&&f.selectCount===2&&f.isCheck&&s("onSubmit",{start:y.value,end:V.value})},J=(Z,se)=>{const K=r.getMomentDate(se),W=K?K.format("YYYY-MM-DD"):"",U=K?K.format("HH:mm:ss"):"",ae=K?r.getMergeDayTime(W,U):"";Z?(y.day=W,y.time=U,y.value=ae,h.text=T(ae,"left")):(V.day=W,V.time=U,V.value=ae,g.text=T(ae,"right"))},q=()=>{let Z="";switch(c.layerType){case"days":Z="months";break;case"months":Z="years";break;case"years":Z="years";break;default:Z="months"}f.operateViewDataType=Z;const se=t.startValue||"",K=t.endValue||"",W=!o.isEmpty(se),U=!o.isEmpty(K);if(f.selectCount=W&&U?2:W||U?1:0,h.view=r.getViewDate(se).format(c.formatIn),g.view=B(h.view,"add"),J(!0,se),J(!1,K),c.timeType==="time"){f.selectCount=2;const ae=c.layerType==="seconds"?"00:00:00":"00:00";o.isEmpty(h.text)&&J(!0,r.getValueEffective(ae)),o.isEmpty(g.text)&&J(!1,r.getValueEffective(ae))}z()},z=()=>{let Z=[];o.isArray(t.rangeQuick)&&(Z=o.getListClone(t.rangeQuick).filter(se=>o.isObject(se)&&o.isNonEmptyString(se.id)),Z.length>0&&Z.push({id:"-1",text:d.value.common.custom})),E.value=Z},H=()=>{q(),O(),e.nextTick(()=>{e.nextTick(()=>{s("onInitComplete")})})},v=()=>{if(f.selectCount===2){const Z=r.checkValue(y.value,V.value);f.isCheck=Z.errMsg.length===0}};e.onMounted(()=>{e.nextTick(()=>{H()})}),e.watch([()=>t.startValue,()=>t.endValue],([Z,se])=>{J(!0,Z),J(!1,se);const K=!o.isEmpty(Z),W=!o.isEmpty(se);f.selectCount=K&&W?2:K||W?1:0,f.selectCount!==2&&(f.activeQuick=""),f.hoverValue="",f.previewStart="",f.previewEnd="",O(),v()}),e.watch(()=>t.rangeQuick,()=>{f.operateViewDataType&&z()});const S=()=>{f.hoverValue="",f.previewStart="",f.previewEnd="",h.text=T(r.getMergeDayTime(y.day,y.time),"left"),g.text=T(r.getMergeDayTime(V.day,V.time),"right")},C=Z=>{h.view=Z,g.view=B(Z,"add")},$=Z=>{b(Z),v(),N()},k=Z=>{y.time=Z,D(),v(),N()},I=Z=>{M(Z)},L=Z=>{h.view=B(Z,"subtract"),g.view=Z},_=Z=>{b(Z),v(),N()},R=Z=>{V.time=Z,x(),v(),N()},P=Z=>{M(Z)},Q=Z=>{if(Z.id!=="-1"){if(o.isEmpty(Z.start)||o.isEmpty(Z.end))return;const se=ze.getDayjsObject(Z.start),K=ze.getDayjsObject(Z.end);if(!se.isValid()||!K.isValid()){Se.warn("ClDateTimeRange",`快捷项 "${Z.text}" 日期无效,已忽略`);return}let W=se.format("YYYY-MM-DD"),U=K.format("YYYY-MM-DD");const ae=r.checkMinMax(W,U,"YYYY-MM-DD");if(!ae.isStartMax||!ae.isEndMin){Se.warn("ClDateTimeRange",`快捷项 "${Z.text}" 超出可选范围,已忽略`);return}ae.isStartMin||(W=ae.minDay),ae.isEndMax||(U=ae.maxDay),y.day=W,D(),V.day=U,x(),h.view=W;const G=o.isEmpty(U)?null:r.getMomentDate(U);g.view=G?G.startOf("month").format(c.formatIn):B(W,"add"),f.hoverValue="",f.previewStart="",f.previewEnd="",f.selectCount=2,f.activeQuick=Z.id,v(),N()}},oe=()=>{f.selectCount===2&&f.isCheck&&(s("onSubmit",{start:y.value,end:V.value}),f.isCheck=!1)},ue=()=>{s("onCancel")};return a({getValue:()=>({start:y.value,end:V.value})}),(Z,se)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(m),class:e.normalizeClass(p.value),onMouseleave:S},[e.createElementVNode("div",Kp,[e.createElementVNode("div",Wp,[e.createElementVNode("div",jp,[e.createElementVNode("input",{class:"form-control time-input",type:"text",readonly:!0,value:h.text,name:h.name},null,8,Yp),e.createVNode(ve,{name:"calendar",className:"time-icon"})])]),e.createElementVNode("div",qp,[e.createVNode(Jo,{selectValue:f.selectCount===2?y.value:"-1",startValue:f.previewStart||y.value,endValue:f.previewEnd||V.value,viewValue:h.view,hoverValue:f.hoverValue,minValue:n.minValue,maxValue:n.maxValue,onOnChangeViewValue:C,onOnSelectDate:$,onOnSelectTime:k,onOnHoverDate:I},null,8,["selectValue","startValue","endValue","viewValue","hoverValue","minValue","maxValue"])])]),e.createElementVNode("div",Xp,[e.createElementVNode("div",Gp,[e.createElementVNode("div",Qp,[e.createElementVNode("input",{class:"form-control time-input",type:"text",readonly:!0,value:g.text,name:g.name},null,8,Zp),e.createVNode(ve,{name:"calendar",className:"time-icon"})])]),e.createElementVNode("div",ef,[e.createVNode(Jo,{selectValue:f.selectCount===2?V.value:"-1",startValue:f.previewStart||y.value,endValue:f.previewEnd||V.value,viewValue:g.view,hoverValue:f.hoverValue,minValue:n.minValue,maxValue:n.maxValue,onOnChangeViewValue:L,onOnSelectDate:_,onOnSelectTime:R,onOnHoverDate:P},null,8,["selectValue","startValue","endValue","viewValue","hoverValue","minValue","maxValue"])])]),e.createElementVNode("div",tf,[e.createElementVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,(K,W)=>(e.openBlock(),e.createElementBlock("li",{key:`${l}-${K.id}-${W}`,role:"button",tabindex:"0",class:e.normalizeClass({active:K.id===f.activeQuick,"calendar-quick-special":K.id==="-1"}),onClick:U=>Q(K),onKeydown:[e.withKeys(e.withModifiers(U=>Q(K),["prevent"]),["enter"]),e.withKeys(e.withModifiers(U=>Q(K),["prevent"]),["space"])]},e.toDisplayString(K.text),43,nf))),128))]),f.isShowQuickBtn?(e.openBlock(),e.createElementBlock("div",of,[e.createVNode(Qe,{className:"quick-submit",label:e.unref(d).common.submit,size:"small",disabled:f.selectCount!==2||!f.isCheck,onOnClick:oe},null,8,["label","disabled"]),e.createVNode(Qe,{className:"quick-cancel",label:e.unref(d).common.cancel,size:"small",color:"grayLight",onOnClick:ue},null,8,["label"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])],42,Jp))}}),sf={key:3,class:"datetime-errmsg",role:"alert"},Za=e.defineComponent({name:"ClDateTimeBase",__name:"DateTimeBase",props:{isDefault:{type:Boolean,default:!1},isRange:{type:Boolean,default:!1},start:String,end:String,minDate:String,maxDate:String,rangeQuick:{type:Array,default:()=>[]},errMsg:{type:Array,default:()=>[]}},emits:{onSelectValue:n=>!0,onClose:()=>!0,onInitComplete:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=`clDatetimeBase-${o.getRandom(5)}`,d=e.inject("$DateTimeTop");d||Se.warn("ClDateTimeBase","未找到 $DateTimeTop 注入,请确保组件在 ClDateTime 组件树内使用");const u=e.computed(()=>!!d);t.isDefault===t.isRange&&Se.warn("ClDateTimeBase",`isDefault(${t.isDefault}) 与 isRange(${t.isRange}) 必须恰好一个为 true`);const r=e.useTemplateRef("refEl");let c=!1;const m=e.computed(()=>o.isArray(t.errMsg)&&t.errMsg.length>0),p=y=>{s("onSelectValue",y)},f=()=>{s("onClose")},h=()=>{c||(c=!0,s("onInitComplete"))};return a({getValue:()=>r.value?r.value.getValue():t.isDefault?o.isNonEmptyString(t.start)?d?.getMomentDate(t.start)??t.start:null:o.isNonEmptyString(t.start)||o.isNonEmptyString(t.end)?{start:t.start,end:t.end}:""}),(y,V)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[u.value&&n.isDefault?(e.openBlock(),e.createBlock(zp,{key:0,ref_key:"refEl",ref:r,value:n.start,minValue:n.minDate,maxValue:n.maxDate,onOnSelectValue:p,onOnInitComplete:h},null,8,["value","minValue","maxValue"])):u.value&&n.isRange?(e.openBlock(),e.createBlock(af,{key:1,ref_key:"refEl",ref:r,rangeQuick:n.rangeQuick,minValue:n.minDate,maxValue:n.maxDate,startValue:n.start,endValue:n.end,onOnSubmit:p,onOnCancel:f,onOnInitComplete:h},null,8,["rangeQuick","minValue","maxValue","startValue","endValue"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64)),m.value?(e.openBlock(),e.createElementBlock("ul",sf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.errMsg,(E,B)=>(e.openBlock(),e.createElementBlock("li",{key:`${l}-err-${B}`},e.toDisplayString(E),1))),128))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64))],64))}}),lf=["id"],rf=["id"],cf="2000-01-01",ca=e.defineComponent({name:"ClDateTime",__name:"Index",props:{id:String,value:String,className:String,placeholder:String,disabled:{type:Boolean,default:!1},theme:{type:String,default:"default",validator:n=>["default","range"].includes(n)},layerType:{type:String,default:"days",validator:n=>["years","months","days","hours","minutes","seconds"].includes(n)},timeType:{type:String,default:"date",validator:n=>["date","time","datetime"].includes(n)},format:String,formatEnd:String,direction:{type:String,default:"left"},minDate:String,maxDate:String,isClear:{type:Boolean,default:!1},rangeQuick:{type:Array,default:()=>[]},isDropdown:{type:Boolean,default:!0},themeStyle:{type:String,default:"default",validator:n=>["default","noBorder"].includes(n)},arrowDirection:{type:String,default:"right"},isUseDropdownArrow:{type:Boolean,default:!0},checkCallback:Function,isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:" ~ "},appendContainer:{type:String,default:""}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:(n,a)=>!0,onInit:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("dataTime");const u=`datetime-${o.getRandom(8)}`,r=t.id,c=e.useTemplateRef("refElDropdownLayer"),m=e.useTemplateRef("refElDatetime"),p=e.reactive({isInit:!1,isDefault:t.theme!=="range",isRange:t.theme==="range",isShowPopup:t.isDropdown,timeType:"",layerType:t.layerType,layerView:"",formatIn:"",formatOut:"",formatOutEnd:"",rangeQuick:[],errMsg:[]}),f=e.reactive({showText:"",start:"",end:""}),h={lastStart:"",lastEnd:""},g=e.computed(()=>{let U=t.arrowDirection;return o.isEmpty(U)&&(U=t.themeStyle==="noBorder"?"left":"right"),U}),y=e.computed(()=>{let U={"panel-date-time":!0};return t.themeStyle==="noBorder"&&(U["datetime-themeStyle-noBorder"]=!0),t.themeStyle==="noBorder"&&o.isEmpty(f.showText)&&(U["datetime-empty"]=!0),t.isDropdown||(U["datetime-noPopup"]=!0,U[`datetime-${t.theme}`]=!0),U=o.getJsonMerge(U,de.getClassNameJson(t.className)),o.getStringByJson(U," ")}),V=e.computed(()=>`datetime-dropdown datetime-${t.theme} datetime-dropdown-${t.theme}`),E=e.computed(()=>{let U={"panel-date-time":!0};return U=o.getJsonMerge(U,de.getClassNameJson(t.className)),`${o.getStringByJson(U," ")} cl-plaintext-value`}),B=e.computed(()=>{const U=f.showText,ae=o.isString(t.plaintextSeparator)?t.plaintextSeparator:" ~ ";return!p.isRange||ae===" ~ "?U:U.split(" ~ ").join(ae)}),T=()=>[{id:"today",text:l.value.today,start:Ie(),end:Ie()},{id:"yesterDay",text:l.value.yesterDay,start:Ie().subtract(1,"day"),end:Ie().subtract(1,"day")},{id:"pastDays7",text:l.value.pastDays7,start:Ie().subtract(7,"day"),end:Ie().subtract(1,"day")},{id:"pastDays30",text:l.value.pastDays30,start:Ie().subtract(30,"day"),end:Ie().subtract(1,"day")},{id:"mont",text:l.value.montCurrent,start:Ie().startOf("month"),end:Ie().endOf("month")},{id:"montLast",text:l.value.montLast,start:Ie().subtract(1,"month").startOf("month"),end:Ie().subtract(1,"month").endOf("month")}],D=()=>[{id:"mont",text:l.value.montCurrent,start:Ie().startOf("month"),end:Ie().endOf("month")},{id:"montLast",text:l.value.montLast,start:Ie().subtract(1,"month").startOf("month"),end:Ie().subtract(1,"month").endOf("month")},{id:"montLately6",text:l.value.montLately6,start:Ie().subtract(5,"month").startOf("month"),end:Ie().endOf("month")},{id:"year",text:l.value.yearCurrent,start:Ie().startOf("year"),end:Ie().endOf("year")},{id:"yearLast",text:l.value.yearLast,start:Ie().subtract(1,"year").startOf("year"),end:Ie().subtract(1,"year").endOf("year")}],x=()=>[{id:"year",text:l.value.yearCurrent,start:Ie().startOf("year"),end:Ie().endOf("year")},{id:"yearLast",text:l.value.yearLast,start:Ie().subtract(1,"year").startOf("year"),end:Ie().subtract(1,"year").endOf("year")}],O=U=>{const ae=o.isEmpty(U.start),G=o.isEmpty(U.end),X=ae?"":Ie(U.start).format(p.formatIn),ee=G?"":Ie(U.end).format(p.formatIn),F=p.isDefault?X:ae||G?"":`${X}~${ee}`,j=p.isDefault?{value:X}:{start:X,end:ee,value:F};return{value:F,info:j}},w=()=>{c.value&&c.value.setOpen(!1)},M=()=>p.timeType==="time",b=U=>{if(!U)return"";const ae=o.isString(U)?o.trim(U):"";return M()?/^\d{4}-\d{2}-\d{2}/.test(ae)?ae:`${cf} ${ae}`:ae},N=()=>Ie(),J=(U,ae)=>{let G=null;if(!o.isEmpty(U)){const X=o.isUndefined(ae)?p.formatIn:ae;G=o.isString(U)?Ie(U,X):Ie(U),G&&!G.isValid()&&(G=null)}return G},q=U=>{const ae=J(U);return ae?ae.startOf("month"):N().startOf("month")},z=(U,ae,G)=>{const X=o.isEmpty(G)?p.formatIn:G;let ee="";if(!o.isEmpty(t.minDate)){const be=J(b(t.minDate));ee=be?be.format(X):""}let F="";if(!o.isEmpty(t.maxDate)){const be=J(b(t.maxDate));F=be?be.format(X):""}let j=!0,le=!0,me=!0,ie=!0,ne=!0,A=!1;const te=o.isEmpty(U),ce=o.isEmpty(ae);let pe;switch(t.layerType){case"years":pe="year";break;case"months":pe="month";break;case"days":pe="day";break;case"hours":pe="hour";break;case"minutes":pe="minute";break;case"seconds":pe="second";break;default:pe="day";break}if(!te){const be=Ie(U);if(be.isValid()&&(o.isEmpty(ee)||(j=be.isSameOrAfter(ee,pe)),o.isEmpty(F)||(le=be.isSameOrBefore(F,pe)),!ce)){const xe=Ie(ae);xe.isValid()&&(o.isEmpty(ee)||(me=xe.isSameOrAfter(ee,pe)),o.isEmpty(F)||(ie=xe.isSameOrBefore(F,pe)),xe.isBefore(be)&&(ne=!1))}}const he=[],Ee=p.isRange?l.value.rangeStartLabel:"";return le?me?(j||he.push(`${Ee}${l.value.checkStartMinLabel}(${J(ee,X)?.format(p.formatOut)??ee})`),ie||he.push(`${l.value.checkEndMaxLabel}(${J(F,X)?.format(p.formatOut)??F})`)):he.push(`${l.value.checkEndMinLabel}(${J(ee,X)?.format(p.formatOut)??ee})`):he.push(`${Ee}${l.value.checkStartMaxLabel}(${J(F,X)?.format(p.formatOut)??F})`),p.isRange&&((te||ce)&&(A=!0,he.push(l.value.checkRangeEmptyLabel)),ne||he.push(l.value.checkStartEndLabel)),{isStartMin:j,isStartMax:le,isEndMin:me,isEndMax:ie,isStartEnd:ne,isRangeEmpty:A,errMsg:he,minDay:ee,maxDay:F}},H=(U,ae,G)=>{const X=z(U,ae||"",G);return p.errMsg=X.errMsg,c.value&&e.nextTick(()=>{c.value?.calculationPosition()}),X},v=()=>{let U=[];switch(t.layerType){case"days":case"hours":case"minutes":case"seconds":U=p.timeType==="time"?[]:T();break;case"months":U=D();break;case"years":U=x();break}return U},S=()=>{let U=[];p.isRange&&(o.isArray(t.rangeQuick)&&t.rangeQuick.length>0?U=[...t.rangeQuick]:U=v()),p.rangeQuick=U},C=()=>{["default","range"].includes(t.theme)||Se.warn("ClDateTime",`theme 非法值 "${t.theme}",可选值 default/range`),["years","months","days","hours","minutes","seconds"].includes(t.layerType)||Se.warn("ClDateTime",`layerType 非法值 "${t.layerType}"`),["date","time","datetime"].includes(t.timeType)||Se.warn("ClDateTime",`timeType 非法值 "${t.timeType}"`),["default","noBorder"].includes(t.themeStyle)||Se.warn("ClDateTime",`themeStyle 非法值 "${t.themeStyle}"`)},$=()=>{C();let U="",ae="",G="";switch(t.layerType){case"years":U="date",ae="YYYY",G=t.layerType;break;case"months":U="date",ae="YYYY-MM",G=t.layerType;break;case"days":U="date",ae="YYYY-MM-DD",G=t.layerType;break;case"hours":U=t.timeType==="date"?"datetime":t.timeType,ae=U==="time"?"HH:00":"YYYY-MM-DD HH:00",G=U==="datetime"?"days":"times";break;case"minutes":U=t.timeType==="date"?"datetime":t.timeType,ae=U==="time"?"HH:mm":"YYYY-MM-DD HH:mm",G=U==="datetime"?"days":"times";break;case"seconds":U=t.timeType==="date"?"datetime":t.timeType,ae=U==="time"?"HH:mm:ss":"YYYY-MM-DD HH:mm:ss",G=U==="datetime"?"days":"times";break;default:U="date",ae="YYYY-MM-DD",G=t.layerType;break}p.timeType=U,p.layerView=G,p.formatIn=U==="date"?"YYYY-MM-DD":"YYYY-MM-DD HH:mm:ss",p.formatOut=o.isNonEmptyString(t.format)?t.format:ae,p.formatOutEnd=o.isNonEmptyString(t.formatEnd)?t.formatEnd:ae},k=U=>{let ae="",G="",X="";if(o.isNonEmptyString(U)){if(p.isDefault){const ee=b(U),F=Ie(ee);F.isValid()&&(G=F.format(p.formatIn),ae=F.format(p.formatOut))}else if(p.isRange){const ee=U.split("~");if(ee.length===2){const F=b(ee[0]),j=b(ee[1]),le=Ie(F),me=Ie(j);le.isValid()&&me.isValid()&&(G=le.format(p.formatIn),X=me.format(p.formatIn),ae=`${le.format(p.formatOut)} ~ ${me.format(p.formatOutEnd)}`)}}}f.start=G,f.end=X,f.showText=ae},I=U=>{let ae=!0;if(t.checkCallback&&!o.isEmpty(U)){try{p.isDefault?ae=t.checkCallback(U):p.isRange&&(ae=t.checkCallback(U.start,U.end))}catch(G){Se.warn("ClDateTime","checkCallback 回调执行异常,本次选择不生效",G),ae=!1}ae=o.isBoolean(ae)?ae:!0}return ae},L=U=>{let ae="",G="",X="",ee=!1;if(p.isDefault){if(!o.isEmpty(U)){const le=J(U);le&&(G=le.format(p.formatIn),ae=le.format(p.formatOut))}ee=G!==h.lastStart}else if(p.isRange){if(!o.isEmpty(U)&&!o.isEmpty(U.start)&&!o.isEmpty(U.end)){const le=J(U.start),me=J(U.end);le&&me&&(G=le.format(p.formatIn),X=me.format(p.formatIn),ae=`${le.format(p.formatOut)} ~ ${me.format(p.formatOutEnd)}`)}ee=G!==h.lastStart||X!==h.lastEnd}const F=z(G,X);let j=!1;return F.errMsg.length===0&&(j=I(U)),p.errMsg=F.errMsg,c.value&&e.nextTick(()=>{c.value?.calculationPosition()}),{start:G,end:X,text:ae,isChange:ee,checkInfo:F,isCheck:j}},_=()=>{$(),S(),k(t.value),e.nextTick(()=>{p.isInit=!0})},R=()=>{const U=m.value?.getValue();let ae="",G="";if(p.isDefault){if(!o.isEmpty(U)){const X=J(U);X&&(ae=X.format(p.formatIn))}}else if(p.isRange){const X=U;if(!o.isEmpty(X?.start)&&!o.isEmpty(X?.end)){const ee=J(X?.start),F=J(X?.end);ee&&F&&(ae=ee.format(p.formatIn),G=F.format(p.formatIn))}}return O({start:ae,end:G})};e.onMounted(()=>{e.nextTick(()=>{_()})}),e.watch(()=>t.value,(U,ae)=>{U!==ae&&(k(U),h.lastStart=f.start,h.lastEnd=f.end)}),e.watch(()=>t.isDropdown,U=>{p.isShowPopup=U}),e.watch([()=>t.theme,()=>t.layerType,()=>t.timeType,()=>t.format,()=>t.formatEnd],()=>{p.isDefault=t.theme!=="range",p.isRange=t.theme==="range",$(),S(),k(t.value),h.lastStart=f.start,h.lastEnd=f.end});const P=U=>{t.disabled||U&&(p.errMsg=[],h.lastStart=f.start,h.lastEnd=f.end,S())},Q=()=>{if(!t.disabled){f.start="",f.end="",f.showText="",h.lastStart="",h.lastEnd="";const U=O(f);s("update:value",U.value),s("update:modelValue",U.value),s("onChange",U.value,U.info)}},oe=U=>{if(!t.disabled){const{start:ae,end:G,text:X,isChange:ee,isCheck:F}=L(U);if(F&&(f.start=ae,f.end=G,f.showText=X,h.lastStart=ae,h.lastEnd=G,w(),ee)){const j=O(f);s("update:value",j.value),s("update:modelValue",j.value),s("onChange",j.value,j.info)}}},ue=()=>{w()};let Y=!1;const Z=()=>{p.isShowPopup&&c.value&&(c.value.checkIsShowOpen()||c.value.initCompleteOpen()),Y||(Y=!0,s("onInit"))};return e.provide("$DateTimeTop",{keyIndex:u,elId:t.id,getMomentDate:J,getViewDate:q,getNow:N,checkIsTimes:M,checkValue:H,checkMinMax:z,getValueEffective:b,getMergeDayTime:(U,ae)=>{let G="";const X=o.isString(U)?o.trim(U):"";let ee=o.isString(ae)?o.trim(ae):"";switch(p.timeType){case"date":G=X;break;case"time":G=b(ee)||"";break;case"datetime":o.isEmpty(X)||(ee=o.isEmpty(ae)?"00:00:00":ee,G=`${X} ${ee}`);break}return G},Dayjs:Ie}),e.provide("$DateTimeTopBase",e.readonly(p)),a({getValue:()=>R().value,getValueData:()=>R().info,setValue:U=>{k(U),h.lastStart=f.start,h.lastEnd=f.end}}),(U,ae)=>n.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(r),class:e.normalizeClass(E.value)},e.toDisplayString(B.value),11,lf)):n.isDropdown?(e.openBlock(),e.createBlock(wn,{key:1,ref_key:"refElDropdownLayer",ref:c,id:e.unref(r),classParent:y.value,classDropDown:V.value,placeholder:n.placeholder,isDisabled:n.disabled,isClear:n.isClear,textLabel:f.showText,textArrowDirection:g.value,dropdownArrowPos:n.direction,isUseDropdownArrow:n.isUseDropdownArrow,appendContainer:n.appendContainer,appendFollowWidth:!1,onOnChangeOpen:P,onOnClear:Q},{textExtend:e.withCtx(()=>[e.createVNode(ve,{name:p.timeType==="time"?"clock":"calendar",className:"datetime-icon","aria-hidden":"true"},null,8,["name"])]),dropdown:e.withCtx(()=>[e.createVNode(Za,{ref_key:"refElDatetime",ref:m,isDefault:p.isDefault,isRange:p.isRange,start:f.start,end:f.end,minDate:n.minDate,maxDate:n.maxDate,rangeQuick:p.rangeQuick,errMsg:p.errMsg,onOnSelectValue:oe,onOnClose:ue,onOnInitComplete:Z},null,8,["isDefault","isRange","start","end","minDate","maxDate","rangeQuick","errMsg"])]),_:1},8,["id","classParent","classDropDown","placeholder","isDisabled","isClear","textLabel","textArrowDirection","dropdownArrowPos","isUseDropdownArrow","appendContainer"])):(e.openBlock(),e.createElementBlock("div",{key:2,id:e.unref(r),class:e.normalizeClass(y.value)},[p.isInit?(e.openBlock(),e.createBlock(Za,{key:0,ref_key:"refElDatetime",ref:m,isDefault:p.isDefault,isRange:p.isRange,start:f.start,end:f.end,minDate:n.minDate,maxDate:n.maxDate,rangeQuick:p.rangeQuick,errMsg:p.errMsg,onOnSelectValue:oe,onOnClose:ue,onOnInitComplete:Z},null,8,["isDefault","isRange","start","end","minDate","maxDate","rangeQuick","errMsg"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,rf))}}),uf={key:0,class:"dropdownLayer-text-container"},df={class:"dropdownLayer-text-render"},mf={class:"dropdownLayer-text-arrow"},rs=e.defineComponent({name:"ClDropdownMenu",__name:"Index",props:{id:String,className:String,classDropDown:String,label:String,direction:{type:String,default:"left",validator:n=>["left","right","center","top","bottom"].includes(n)},dropDownPos:{type:String,default:"down",validator:n=>["down","up","left","right"].includes(n)},isUseLabelArrow:{type:Boolean,default:!1},isUseDropdownArrow:{type:Boolean,default:!1},transitionEnter:String,transitionLeave:String},emits:{onChangeOpen:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,l=e.useTemplateRef("refElDropdownLayer"),d=e.computed(()=>{let r={"panel-dropdown-menu":!0};return r=o.getJsonMerge(r,de.getClassNameJson(i.className)),Object.keys(r).join(" ")}),u=r=>{t("onChangeOpen",r)};return e.provide("$DropdownmenuTop",e.reactive({hideDropdown:()=>{l.value?.setOpen(!1)}})),(r,c)=>(e.openBlock(),e.createBlock(eo,{ref_key:"refElDropdownLayer",ref:l,id:e.unref(s),classParent:d.value,classDropDown:n.classDropDown,dropdownArrowPos:n.direction,dropDownPos:n.dropDownPos,isUseDropdownArrow:n.isUseDropdownArrow,transitionEnter:n.transitionEnter,transitionLeave:n.transitionLeave,onOnChangeOpen:u},{label:e.withCtx(()=>[n.isUseLabelArrow?(e.openBlock(),e.createElementBlock("div",uf,[e.createElementVNode("div",df,[e.renderSlot(r.$slots,"label",{},()=>[e.createTextVNode(e.toDisplayString(n.label),1)])]),e.createElementVNode("div",mf,[e.createVNode(ve,{name:"angle-down"})])])):e.renderSlot(r.$slots,"label",{key:1},()=>[e.createTextVNode(e.toDisplayString(n.label),1)])]),dropdown:e.withCtx(()=>[e.createElementVNode("ul",null,[e.renderSlot(r.$slots,"default")])]),_:3},8,["id","classParent","classDropDown","dropdownArrowPos","dropDownPos","isUseDropdownArrow","transitionEnter","transitionLeave"]))}}),pf=["id"],ff=["id","aria-disabled"],cs=e.defineComponent({name:"ClDropdownMenuItem",__name:"Item",props:{id:String,className:String,url:String,disabled:{type:Boolean,default:!1},isDivider:{type:Boolean,default:!1},extData:Object},emits:{onClick:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,l=e.inject("$DropdownmenuTop"),d=e.computed(()=>{let r={"dropdownMenu-item":!0,"dropdownMenu-item-disabled":i.disabled,"panel-dropdown-menu-item":!0};return r=o.getJsonMerge(r,de.getClassNameJson(i.className)),r}),u=()=>{i.disabled||(l?.hideDropdown(),t("onClick",i.extData))};return(r,c)=>n.isDivider?(e.openBlock(),e.createElementBlock("li",{key:0,id:e.unref(s),role:"separator",class:"dropdownMenu-divider"},null,8,pf)):(e.openBlock(),e.createElementBlock("li",{key:1,id:e.unref(s),role:"menuitem","aria-disabled":n.disabled?"true":void 0,class:e.normalizeClass(d.value)},[e.createVNode(Vt,{url:n.url,disabled:n.disabled,isHideUnderline:!0,onOnClick:u},{default:e.withCtx(()=>[e.renderSlot(r.$slots,"default")]),_:3},8,["url","disabled"])],10,ff))}}),us=e.defineComponent({name:"ClDropdownPopup",__name:"Index",props:{id:String,className:{type:String,default:""},dropdownArrowPos:{type:String,default:"center"},dropDownPos:{type:String,default:"up"},isUseDropdownArrow:{type:Boolean,default:!0},appendContainer:{type:String,default:""},transitionEnter:{type:String,default:"animated fadeIn"},transitionLeave:{type:String,default:"animated fadeOut"},triggers:{type:String,default:"click"}},emits:{onChangeOpen:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElDropdownLayer"),u=e.computed(()=>{let h={"panel-dropdown-popup":!0};return h=o.getJsonMerge(h,de.getClassNameJson(t.className)),Object.keys(h).filter(g=>h[g]).join(" ")}),r=h=>{s("onChangeOpen",h)};return a({setOpen:h=>{if(!d.value){Se.warn("DropdownPopup","子组件尚未挂载,setOpen 调用已忽略");return}d.value.setOpen(h)},calculationPosition:()=>{if(!d.value){Se.warn("DropdownPopup","子组件尚未挂载,calculationPosition 调用已忽略");return}d.value.calculationPosition()},initCompleteOpen:()=>{if(!d.value){Se.warn("DropdownPopup","子组件尚未挂载,initCompleteOpen 调用已忽略");return}d.value.initCompleteOpen()},checkCurrentIsOpen:()=>{if(!d.value){Se.warn("DropdownPopup","子组件尚未挂载,checkCurrentIsOpen 调用已忽略");return}return d.value.checkIsShowOpen()}}),(h,g)=>(e.openBlock(),e.createBlock(eo,{ref_key:"refElDropdownLayer",ref:d,id:e.unref(l),classParent:u.value,classDropDown:"dropdownPopup-dropdown",dropdownArrowPos:n.dropdownArrowPos,dropDownPos:n.dropDownPos,isUseDropdownArrow:n.isUseDropdownArrow,appendContainer:n.appendContainer,transitionEnter:n.transitionEnter,transitionLeave:n.transitionLeave,triggers:n.triggers,onOnChangeOpen:r},{label:e.withCtx(()=>[e.renderSlot(h.$slots,"label")]),dropdown:e.withCtx(()=>[e.renderSlot(h.$slots,"dropdown")]),_:3},8,["id","classParent","dropdownArrowPos","dropDownPos","isUseDropdownArrow","appendContainer","transitionEnter","transitionLeave","triggers"]))}}),hf=["#2ec7c9","#b6a2de","#5ab1ef","#ffb980","#d87a80","#8d98b3","#e5cf0d","#97b552","#95706d","#dc69aa","#07a2a4","#9a7fd1","#588dd5","#f5994e","#c05050","#59678c","#c9ab00","#7eb00a","#6f5553","#c14089"],gf={color:hf,title:{textStyle:{fontWeight:"normal",color:"#008acd"}},visualMap:{itemWidth:15,color:["#5ab1ef","#e0ffff"]},tooltip:{backgroundColor:"rgba(50,50,50,0.5)",axisPointer:{type:"line",lineStyle:{color:"#008acd"},crossStyle:{color:"#008acd"},shadowStyle:{color:"rgba(200,200,200,0.2)"}}},dataZoom:{dataBackgroundColor:"#efefff",fillerColor:"rgba(182,162,222,0.2)",handleColor:"#008acd"},grid:{borderColor:"#eee"},categoryAxis:{axisLine:{lineStyle:{color:"#008acd"}},splitLine:{lineStyle:{color:["#eee"]}}},valueAxis:{axisLine:{lineStyle:{color:"#008acd"}},splitArea:{show:!0,areaStyle:{color:["rgba(250,250,250,0.1)","rgba(200,200,200,0.1)"]}},splitLine:{lineStyle:{color:["#eee"]}}},timeline:{lineStyle:{color:"#008acd"},controlStyle:{color:"#008acd",borderColor:"#008acd"},symbol:"emptyCircle",symbolSize:3},line:{smooth:!0,symbol:"emptyCircle",symbolSize:3},candlestick:{itemStyle:{color:"#d87a80",color0:"#2ec7c9"},lineStyle:{width:1,color:"#d87a80",color0:"#2ec7c9"},areaStyle:{color:"#2ec7c9",color0:"#b6a2de"}},scatter:{symbol:"circle",symbolSize:4},map:{itemStyle:{color:"#2ec7c9"},label:{color:"#000000"}},graph:{itemStyle:{color:"#d87a80"},linkStyle:{color:"#2ec7c9"}},gauge:{axisLine:{lineStyle:{color:[[.2,"#2ec7c9"],[.8,"#5ab1ef"],[1,"#d87a80"]],width:10}},axisTick:{splitNumber:10,length:15,lineStyle:{color:"auto"}},splitLine:{length:22,lineStyle:{color:"auto"}},pointer:{width:5}}},yf=["id"],ua=e.defineComponent({name:"ClEcharts",__name:"Index",props:{id:String,chartOption:Object,className:String,height:{type:[Number,String],default:400},isRunLoad:{type:Boolean,default:!1}},emits:["onInitFirst","onHideResize","onError"],setup(n,{expose:a,emit:i}){let t=null,s=!1;const l=()=>(t||(t=import("echarts")),t),d=n,u=i,r=d.id,c=e.useTemplateRef("refElChart"),m=e.reactive({isShowLoad:d.isRunLoad,isEmptyData:!1}),p={resizeEvent:null,chartObject:null,initTimer:null,isHideEmit:!1},f=e.computed(()=>{let M={"panel-echarts":!0,"chart-loading":m.isShowLoad||m.isEmptyData};return M=o.getJsonMerge(M,de.getClassNameJson(d.className)),M}),h=e.computed(()=>{const M={};return(m.isShowLoad||m.isEmptyData)&&(M.height="100%"),M}),g=e.computed(()=>{const M={},{height:b}=d;return typeof b=="number"&&o.isFinite(b)&&b>0?M.height=`${b}px`:o.isNonEmptyString(b)&&(M.height=b),M}),y=()=>{u("onHideResize")},V=()=>{u("onInitFirst")},E=()=>{p.chartObject&&p.chartObject.resize()},B=async M=>{if(!c.value)return;const b=o.isEmpty(M);if(m.isEmptyData=b,!b&&M)try{const N=await l();s||(N.registerTheme("macarons",gf),s=!0),p.chartObject||(p.chartObject=N.init(c.value,"macarons"),p.initTimer=setTimeout(()=>{V()},50)),p.chartObject.setOption(M,!0),E()}catch{p.initTimer&&(clearTimeout(p.initTimer),p.initTimer=null),u("onError","图表配置异常")}else p.chartObject&&p.chartObject.clear()},T=()=>{p.chartObject&&(de.isHiddenParent(c.value)?p.isHideEmit||(p.isHideEmit=!0,y()):(p.isHideEmit&&(p.isHideEmit=!1),E()))},D=()=>{B(d.chartOption)};return e.onMounted(()=>{p.resizeEvent=new ht({callback:()=>{T()}}),e.nextTick(()=>{D()})}),e.onBeforeUnmount(()=>{p.resizeEvent&&p.resizeEvent.destroy(),p.initTimer&&clearTimeout(p.initTimer),p.chartObject&&(p.chartObject.dispose(),p.chartObject=null)}),e.onActivated(()=>{p.resizeEvent||(p.resizeEvent=new ht({callback:()=>{T()}})),e.nextTick(()=>{E()})}),e.onDeactivated(()=>{p.resizeEvent&&(p.resizeEvent.destroy(),p.resizeEvent=null)}),e.watch(()=>d.isRunLoad,M=>{m.isShowLoad=M}),e.watch(()=>d.chartOption,M=>{B(M)}),a({getChartObject:()=>p.chartObject,getChartElement:()=>c.value,resize:()=>{E()}}),(M,b)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(r),class:e.normalizeClass(f.value),style:e.normalizeStyle(h.value)},[e.renderSlot(M.$slots,"chartHead"),e.createElementVNode("div",{ref_key:"refElChart",ref:c,style:e.normalizeStyle(g.value),role:"img","aria-label":"图表"},null,4),e.createVNode(Zt,{isLoadIng:m.isShowLoad,isEmpty:m.isEmptyData},{nothingData:e.withCtx(()=>[e.renderSlot(M.$slots,"nothingData")]),_:3},8,["isLoadIng","isEmpty"])],14,yf))}});class vf{colorPalette;constructor(){this.colorPalette=["#2ec7c9","#b6a2de","#5ab1ef","#ffb980","#d87a80","#8d98b3","#e5cf0d","#97b552","#95706d","#dc69aa","#07a2a4","#9a7fd1","#588dd5","#f5994e","#c05050","#59678c","#c9ab00","#7eb00a","#6f5553","#c14089"]}_clipRectByRect(a,i){const t=Math.max(a.x,i.x),s=Math.min(a.x+a.width,i.x+i.width),l=Math.max(a.y,i.y),d=Math.min(a.y+a.height,i.y+i.height);if(s>=t&&d>=l)return{x:t,y:l,width:s-t,height:d-l}}getBaseOptions(a){const i={title:{show:!1,text:""},tooltip:{trigger:"item",padding:5,borderWidth:0,textStyle:{color:"#FFFFFF"}},toolbox:{show:!1},legend:{data:[]},series:[]};return o.getJsonMergeDeep(i,a)}getOptionAxis(a){let i=!0;switch(a.chartType){case"hour":i=!1;break;case"day":i=!1;break}const t={interval:"auto"};i?t.interval=0:t.interval=a.chartType==="hour"?0:"auto";const s=o.isEmpty(a.tipTitleFormat)?"":a.tipTitleFormat,l=o.isEmpty(a.seriesNameFormat)?"":a.seriesNameFormat,d=o.isBoolean(a.isMultiple)?a.isMultiple:!1,u=o.isBoolean(a.isTitleMergeSeriesName)?a.isTitleMergeSeriesName:!1;return this.getBaseOptions({title:{text:""},tooltip:{trigger:"axis",formatter:c=>{const m=g=>{const y=d?a.dataOriginal?.[0]?.list?.[g]:a.dataOriginal?.[g];return o.isEmpty(y)?null:y},p=[];let f=c[0].name;switch(o.isObject(c[0].data)&&c[0].data.extInfo&&!o.isUndefined(c[0].data.extInfo.xValueOriginal)&&(f=c[0].data.extInfo.xValueOriginal),a.chartType){case"hour":f=o.getHourInterval(f);break;case"day":f=o.getValueByFormat(f,"date");break}if(s.length>0){const g=m(c[0].dataIndex);if(!o.isEmpty(g)){const y=o.getJsonClone(g);y._title=f,f=o.convertStringFormat(s,y)}}u||p.push(o.encodeHTML(f));const h="<span style='display:inline-block;margin-right:5px;border-radius:10px;width:9px;height:9px;background-color:${color}'></span>";for(let g=0;g<c.length;g++){const y=c[g],V=m(y.dataIndex),E=y.marker||o.convertStringFormatEncodeHTML(h,{color:y.color});let B=y.seriesName;if(l.length>0&&!o.isEmpty(V)){const D=o.getJsonClone(V);D._seriesName=B,B=o.convertStringFormat(l,D)}let T;if(o.isUndefined(y.value))T=null;else if(o.isNumber(y.value)){const D=Number(y.value);if(D<.01)T=o.getNumCeil(D,{isCeil:!1});else{let x="num";const O={isEmptyDefault:!1};D<.1&&(x="float",O.decimalNum=3),T=o.getValueByFormat(y.value,x,O)}}else T=y.value;if(o.isObject(y.data)&&!o.isUndefined(y.data.extInfo)&&y.data.extInfo.tipValueFormat&&y.data.extInfo.tipValueFormat.length>0){const D=o.getJsonClone(V);D._value=T,T=o.convertStringFormat(y.data.extInfo.tipValueFormat,D)}p.push(E+(u?o.encodeHTML(f):o.encodeHTML(B))+" : "+o.encodeHTML(T))}return p.join("<br />")}},legend:{data:[]},grid:{top:"20px",left:"1%",right:"1%",bottom:"1%",containLabel:!0},xAxis:{type:"category",boundaryGap:!0,axisLabel:{interval:t.interval,formatter:c=>{if(i&&a?.element?.clientWidth&&!o.isEmpty(a.dataOriginal)){const m=a.element.clientWidth,p=parseInt(((m-200)/a.dataOriginal.length).toString());if(p>0){const f=c.toString().split(""),h=[];let g=0;for(let V=0;V<f.length&&(g+=Math.ceil(de.getTextWidth(f[V])),!(g>p));V++)h.push(f[V]);let y="";return f.length===h.length?y=c:h.length>3?y=h.slice(0,h.length-3).join("")+"...":y=h.join("")+"...",y}}return c}},splitLine:{show:!1},data:[]},yAxis:[],series:[]})}_getSeriesNumber(a){let i=typeof a=="symbol"?Number.NaN:Number(a);return i.toString()==="NaN"?i=0:i=Number(i.toFixed(2)),i}_getBaseDataInfo(a,i,t,s={}){const l=[],d=[],u=[],r=!o.isUndefined(s.seriesExtData);let c=0;if(a.forEach((f,h)=>{const g=this._getSeriesNumber(f[t]);if(h<s.totalOther||!s.isSumOther){const y=f[i]||"";l.push(y);const V={value:g,name:y};r&&(V.extInfo=s.seriesExtData),d.push(V),u.push(g)}else c+=Number(g)}),s.isSumOther){const f=o.isEmpty(s.otherText)?"其他":s.otherText;l.push(f);const h={value:c,name:f};r&&(h.extInfo=s.seriesExtData),d.push(h),u.push(c)}let m=u.length>0?Math.max.apply(null,u):0;m=o.getNumCeil(m,{isEndFive:Number(m)<100});let p=u.length>0?Math.min.apply(null,u):0;return p=o.getNumCeil(p,{isEndFive:Number(p)<100}),{legendData:l,seriesData:d,seriesMax:m,seriesMin:p}}getBaseData(a,i,t,s={}){const l=o.isEmpty(s.totalOther)?-1:parseInt(s.totalOther),d=l>0&&a.length>l,u=o.isUndefined(s.seriesExtData)?null:s.seriesExtData,r={totalOther:l,isSumOther:d,seriesExtData:u};if(o.isArray(t)){let c=[];const m=[],p=[],f=[];t.forEach((y,V)=>{const E=this._getBaseDataInfo(a,i,y,r);V===0&&(c=E.legendData),m.push({valueKey:y,data:E.seriesData,maxData:E.seriesMax,minData:E.seriesMin}),p.push(E.seriesMax),f.push(E.seriesMin)});const h=Math.max.apply(null,p),g=Math.min.apply(null,f);return{legendData:c,seriesData:m,seriesMax:h,seriesMin:g}}else return this._getBaseDataInfo(a,i,t,r)}_getItemXAxisSeries(a,i,t,s){let l,d;if(!o.isEmpty(i.xKey))if(l=a[i.xKey],d=l,o.isEmpty(l))l="";else{let p=o.isEmpty(t.xValueFormat)?"":t.xValueFormat;switch(t.chartType){case"day":o.isEmpty(t.xValueFormat)&&(p="MM.DD"),l=o.getValueByFormat(l,"date",{dateFormat:p});break}}let u;if(!o.isEmpty(i.seriesKey)){let p=i.seriesKey;o.isString(p)&&o.isExistValue(p,",")&&(p=p.split(",")),o.isString(p)?u=this._getSeriesNumber(a[i.seriesKey]):o.isArray(p)&&(u=[],p.forEach(f=>{let h;f===i.xKey?h=l:h=this._getSeriesNumber(a[f]),u.push(h)}))}let r;o.isEmpty(i.legendKey)||(r=a[i.legendKey]||"");const c=i.colorKey||"color";let m=a[c]||t[c]||"";if(o.isEmpty(m)&&t.isPolychrome){const p=o.isEmpty(t.colorPalette)?this.colorPalette:t.colorPalette,f=p.length,h=s%f;m=p[h]}return{xValue:l,xValueOriginal:d,seriesValue:u,legendValue:r,colorValue:m}}getLineOption(a,i,t={}){let s={type:"line",areaStyle:{},lineStyle:{},smooth:!0};t.seriesItem&&(s=o.getJsonMergeDeep(s,t.seriesItem));const l=o.getJsonMerge(t,{seriesItemBase:s});return this._getOneOptionBase(a,i,l)}getBarOption(a,i,t={}){let s={type:"bar"};const l=o.isBoolean(t.isPositiveNegative)?t.isPositiveNegative:!1;let d;l&&(d=o.isEmpty(t.seriesPos)?"vertical":t.seriesPos,s.label={show:!0}),s=o.getJsonMergeDeep(s,t.seriesItem);const u=o.getJsonMerge(t,{seriesItemBase:s,isPositiveNegative:l,seriesPos:d}),r=this._getOneOptionBase(a,i,u);return r.xAxis.boundaryGap=!0,r}getScatterOption(a,i,t={}){let s={type:"scatter",symbolSize:10};t.seriesItem&&(s=o.getJsonMergeDeep(s,t.seriesItem));const l=o.getJsonMerge(t,{seriesItemBase:s}),d=o.getJsonMerge(i,{seriesKey:[i.xKey,i.seriesKey]}),u=this._getOneOptionBase(a,d,l);return u.legend={show:!1},u.xAxis.axisTick={show:!0,alignWithLabel:!0},u.xAxis.splitLine={show:!1},u.xAxis.splitArea={show:!1},u.yAxis.axisTick={show:!0},u.yAxis.splitLine={show:!1},u.yAxis.splitArea={show:!1},u.tooltip.trigger="item",u.tooltip.formatter=r=>r.marker+r.value[0]+": "+r.value[1],u}_getOneOptionBase(a,i,t={}){const s=[];let l=[];const d=[];let u="";const r=o.getJsonMerge(i,{colorKey:t.colorKey});a.forEach((f,h)=>{const g=this._getItemXAxisSeries(f,r,t,h);if(o.isUndefined(g.xValue)||s.push(g.xValue),o.isUndefined(g.legendValue)||l.push(g.legendValue),!o.isUndefined(g.seriesValue)){const y=g.seriesValue,V={value:g.seriesValue,extInfo:{xValueOriginal:g.xValueOriginal,infoOriginal:f}};t.isPositiveNegative?(V.label={position:t.seriesPos==="horizontal"?y>=0?"left":"right":y>=0?"top":"bottom"},V.itemStyle={color:y>=0?"#1088F0":"#ee3c24"}):(!o.isEmpty(g.colorValue)&&u.length==0&&(u=g.colorValue),t.isPolychrome&&!o.isEmpty(g.colorValue)&&(V.itemStyle={color:g.colorValue})),o.isEmpty(t.seriesDataAddParam)||o.isExistValue(t.seriesDataAddParam,"symbolSize")&&!o.isEmpty(f.symbolSize)&&(V.symbolSize=f.symbolSize),d.push(V)}}),o.isUndefined(i.legendKey)||(l=o.getArrUnique(l));const c=o.getJsonMerge(t.seriesItemBase||{},{name:t.legendData?t.legendData:l[0],data:d});o.isEmpty(u)||(c.itemStyle={color:u});let m={};m=o.getJsonMerge(m,t);const p=this.getOptionAxis(m);return p.legend.data=l,p.xAxis=o.getJsonMergeDeep(p.xAxis,{axisLine:{}},t.xAxisItem||{}),p.xAxis.data=s,p.series=[c],p.yAxis={type:"value",axisLine:{show:!0}},p}getLineMultiOption(a,i,t={}){let s={type:"line",areaStyle:{},smooth:!0};t.seriesItem&&(s=o.getJsonMergeDeep(s,t.seriesItem));const l=o.getJsonMerge(t,{seriesItemBase:s,emptyFill:0});return this._getMultiOptionBase(a,i,l)}getBarMultiOption(a,i,t={}){let s={type:"bar"};t.seriesItem&&(s=o.getJsonMergeDeep(s,t.seriesItem));const l=o.getJsonMerge(t,{seriesItemBase:s}),d=this._getMultiOptionBase(a,i,l);if(o.isBoolean(t.isHideNull)?t.isHideNull:!0){const r=this._setBarMultiCustom(d,t);r.length>0&&(d.series=r,d.legend.show=!1,d.tooltip.formatter=c=>{const m=[];m.push(c[0]?.axisValue);for(let p=0;p<c.length;p++){const f=c[p];m.push(f.marker+o.encodeHTML(f.name)+" : "+o.getValueByFormat(f.value[1],"num"))}return m.join("<br />")})}return d}_setBarMultiCustom(a,i){const t=[],s={};let l=!1;a.series.forEach((u,r)=>{const{name:c,itemStyle:m}=u;u.data.forEach((p,f)=>{const h=o.isObject(p)?p.value:p;if(o.isUndefined(h))l=!0;else{const g=f.toString();o.isExistJsonKey(s,g)||(s[g]=[]),s[g].push(c);const y={name:c,value:[f,h]};if(!o.isUndefined(m))y.itemStyle=m;else{const V=o.isEmpty(i.colorPalette)?this.colorPalette:i.colorPalette,E=r%V.length;y.itemStyle={color:V[E]}}h<0&&(y.label={show:!0,position:"left"}),t.push(y)}})});let d=[];if(l){d=[{type:"custom",renderItem:(c,m)=>{const p=m.value(0),f=m.value(1),h=m.coord([0,p]),g=m.coord([Math.abs(f),p]);let y=m.size([0,1])[1]*.8,V=h[1]-y/2,E=c.coordSys.y;const B=m.value(3),T=m.value(4);let D=y;if(B>1||T>1){B!==T&&(y=y/T*B,V=h[1]-y/2);const w=y/B,M=m.value(2),b=w*(M-1);V+=b,E+=b;const N=w*.1;V+=N,E+=N,D=w*.8}const x={x:h[0],y:V,width:(g[0]-h[0])*.9,height:D};return f<0&&(x.x-=x.width),{type:"rect",shape:this._clipRectByRect(x,{x:c.coordSys.x,y:E,width:c.coordSys.width*.9,height:c.coordSys.height}),style:{fill:m.visual("color")}}},itemStyle:{opacity:1},encode:{x:1,y:0},label:{},data:[]}];const u=t.map(c=>s[c.value[0].toString()].length),r=Math.max.apply(null,u);t.forEach(c=>{const m=c.value[0],p=s[m.toString()],f=p.indexOf(c.name);c.value.push(f+1),c.value.push(p.length),c.value.push(r)}),d[0].data=t,d[0].label=a.series[0].label,d[0].label&&d[0].label.formatter&&(d[0].label.formatter=c=>o.getValueByFormat(c.value[1],"num"))}return d}_getMultiOptionBase(a,i,t={}){let s=[],l=[];const d={},u=[],r=o.isEmpty(t.seriesItemBase)?{}:t.seriesItemBase,c=o.isEmpty(t.emptyFill)?null:t.emptyFill,m=o.isBoolean(t.isCompletionLegendX)?t.isCompletionLegendX:!0,p=!o.isEmpty(t.xAxisSort),f=!o.isEmpty(t.legendSort),h=t.colorKey||"color",g=o.getJsonMerge(i,{colorKey:h});a.forEach(E=>{const B=E[g.legendKey]||"",T={};E.list.forEach((D,x)=>{const O=this._getItemXAxisSeries(D,{xKey:g.xKey},t,x);o.isUndefined(O.xValue)||(s.push(O.xValue),T[O.xValue]=D)}),l.push(B),d[B]=T}),l=o.getArrUnique(l),s=o.getArrUnique(s),f&&(l=t.legendSort),p&&(s=t.xAxisSort),l.forEach(E=>{const B=[];let T="";m?s.forEach((x,O)=>{if(o.isExistJsonKey(d,E)&&o.isExistJsonKey(d[E],x)){const w=this._getItemXAxisSeries(d[E][x],g,t,O);o.isUndefined(w.seriesValue)||B.push({value:w.seriesValue,extInfo:{xValueOriginal:w.xValueOriginal}}),T=w.colorValue}else B.push({value:c})}):o.isExistJsonKey(d,E)?Object.keys(d[E]).forEach((x,O)=>{const w=this._getItemXAxisSeries(d[E][x],g,t,O);o.isUndefined(w.seriesValue)||B.push({value:w.seriesValue,extInfo:{xValueOriginal:w.xValueOriginal}}),T=w.colorValue}):B.push({value:c});const D=o.getJsonMerge(r,{name:E});D.data=B,D.label&&t.isShowLabelThousand&&(D.label.formatter=x=>o.getValueByFormat(x.value,"num")),o.isEmpty(T)||(D.itemStyle={color:T}),u.push(D)});let y={};y=o.getJsonMerge(y,t),y.isMultiple=!0;const V=this.getOptionAxis(y);return V.legend.data=l,V.series=u,V.xAxis=o.getJsonMergeDeep(V.xAxis,t.xAxisItem||{}),V.xAxis.data=s,V.yAxis={type:"value",axisLine:{show:!0}},V}}const kf=new vf,Sf={key:0,class:"lineAxisTag-head"},wf={class:"lineAxisTag-list"},Ef="其他",ds=e.defineComponent({name:"ClEchartsLineAxisTag",__name:"Index",props:{id:String,className:String,type:{type:String,validator:n=>n==="day"||n==="hour"},height:{type:Number,default:400,validator:n=>n>0},isRunLoad:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},isTagShow:{type:Boolean,default:!0},tagList:{type:Array,default:()=>[]},tagSelectCountMax:{type:Number,validator:n=>n>0&&n<=2,default:2},tagInitValue:{type:String,default:""},tagSort:{type:Array,default:()=>[]},xAxisLen:{type:Number,default:-1},xAxisKey:{type:String,default:"name"},xAxisIsShowOther:{type:Boolean,default:!1},isShowY:{type:Boolean,default:!0},isYMinZero:{type:Boolean,default:!0},ySpace:{type:Number,default:5,validator:n=>n>0},yRatio:{type:Number,default:1.5},isYEqual:{type:Boolean,default:!1},seriesType:{type:String,default:"line",validator:n=>o.isString(n)&&n.split(",").every(a=>a==="line"||a==="bar")},tipFormat:String,seriesFormat:String,isShowLineBg:{type:Boolean,default:!0},isXBoundaryGap:{type:Boolean,default:!0},gridInfo:{type:Object,default:()=>({})}},emits:["onInitFirst","onHideResize","onError"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=v=>{s("onError",v)},d=`echartsLineAxisTag-${o.getRandom(5)}`,u=t.id,r=e.useTemplateRef("refElChart"),c=e.ref(),m=e.ref([]),p=e.computed(()=>o.isArray(t.tagList)?t.tagList.filter(v=>!o.isUndefined(v)&&!o.isUndefined(v.id)):[]),f={tagSort:[],tagJson:{},chartTagJson:{},useSeriesType:["line","bar"],isInited:!1},h=e.computed(()=>{const v=t.seriesType,S=o.isNonEmptyString(v)?v.split(","):[],C=S.length===1?S[0]:"line",$=t.tagSelectCountMax>0?t.tagSelectCountMax:2,k=S.length-1,I=[];for(let L=0;L<$;L++)I.push(L<=k&&f.useSeriesType.indexOf(S[L])>-1?S[L]:C);return I}),g=e.computed(()=>{let v={"panel-echarts-line-axis-tag":!0};return v=o.getJsonMerge(v,de.getClassNameJson(t.className)),o.getStringByJson(v," ")}),y=()=>{s("onHideResize")},V=()=>{s("onInitFirst")},E=()=>{let v=[];const S={};if((o.isArray(t.tagList)?t.tagList:[]).forEach($=>{if(o.isUndefined($)||o.isUndefined($.id))return;const k=$.id.toString();S[k]=$,v.push(k)}),!o.isEmpty(t.tagSort)){const $=[];t.tagSort.forEach(k=>{o.isExistJsonKey(S,k)&&$.push(k)}),$.length>0&&(v=$)}f.tagSort=v,f.tagJson=S},B=v=>{if(v.length===0)return[];const S=t.tagSelectCountMax;return Array.from(new Set(v)).sort(($,k)=>f.tagSort.indexOf($)-f.tagSort.indexOf(k)).slice(0,S)},T=v=>{let S=[];o.isNonEmptyString(v)&&(v.split(",").forEach(C=>{o.isExistJsonKey(f.tagJson,C)&&S.push(C)}),S=B(S)),m.value=S},D=v=>{const S={name:[],allName:[]},C={},$=[],k={};f.tagSort.forEach(L=>{const _=o.getJsonClone(f.tagJson[L],!0);_.aliasName=o.isUndefined(_.nameFormat)?_.name:o.convertStringFormat(_.nameFormat,_),_.data=[],_.alldata=[],C[L]=_,k[L]=0});let I=v.length;return t.xAxisLen>0&&(I=I>t.xAxisLen?t.xAxisLen:I),v.forEach((L,_)=>{_<I&&$.push(L);let R=o.isExistJsonKey(L,t.xAxisKey)?L[t.xAxisKey]:"";(o.isUndefined(R)||R===null)&&(R=""),S.allName.push(R),_<I&&(t.type==="day"&&(R=o.getValueByFormat(R,"date",{dateFormat:"MM.DD"})),S.name.push(R)),f.tagSort.forEach(P=>{if(o.isExistJsonKey(L,P)){let Q=Number(L[P]);o.isFinite(Q)||(Q=0),C[P].alldata.push(Q),_<I?C[P].data.push(Q):k[P]+=Q}else C[P].alldata.push(0),_<I&&C[P].data.push(0)})}),{x:S,y:C,data:$,other:k,isEmptyData:I===0}},x=()=>{const v=B(m.value),S=h.value,{xAxisLen:C,xAxisIsShowOther:$,ySpace:k,yRatio:I,isYMinZero:L,isYEqual:_}=t;return v.map((R,P)=>{const Q=f.tagJson[R];let oe=L;return oe=o.isBoolean(Q.isYMinZero)?Q.isYMinZero:oe,{name:R,color:Q.color||null,type:S[P],len:C,isShowOther:$,ySpace:k,yMaxRatio:P===1?_?1:I:1,isYMinZero:oe}})},O=(v,S,C,$)=>{if(v.length===0)return{min:0,max:1,interval:1};const k=S>0?S:1,I=v.map(Y=>Y.value);let L=I.reduce((Y,Z)=>Math.min(Y,Z));L=o.getNumCeil(L,{isEndFive:Number(L)<100});let _=I.reduce((Y,Z)=>Math.max(Y,Z));_=_*1.02,_=o.getNumCeil(_,{isEndFive:Number(L)<100});const R=$?0:L,P=C>1?C:1;let Q=_*P-R;Q<=0&&(Q=1);let oe=o.getNumCeil(Q/k,{isEndFive:Number(L)<100}),ue=Number((k*oe).toFixed(2))+R;return R===ue&&ue===0&&(ue=1,oe=1/k),{min:R,max:ue,interval:oe}},w=(v,S)=>{const C=[],$=[],k=[];let I=[];const L=h.value,_=L.length>0&&L.every(R=>R==="line");if(S.forEach((R,P)=>{const Q=v.y[R.name],oe=Q.name;C.push(oe);const ue={};Q.valueFormat&&(ue.tipValueFormat=Q.valueFormat);let Y=[];v.isEmptyData?Y=[]:(Y=Q.data.map((K,W)=>{const U={value:K,extInfo:o.getJsonClone(ue)};return U.extInfo.xValueOriginal=v.x.allName[W],U}),R.isShowOther&&R.len>0&&R.len<Q.alldata.length&&Y.push({value:o.getValueByFormat(v.other[R.name],"num"),extInfo:ue}));const Z={name:oe,type:R.type,yAxisIndex:P,data:Y};o.isEmpty(R.color)||(Z.itemStyle={color:R.color}),_&&t.isShowLineBg&&(Z.areaStyle={}),$.push(Z);const se=O(Y,R.ySpace,R.yMaxRatio,R.isYMinZero);k.push({type:"value",name:Q.aliasName,nameLocation:"end",nameTextStyle:{color:"#aaa"},splitNumber:R.ySpace,min:v.isEmptyData?0:se.min,max:v.isEmptyData?1:se.max,interval:v.isEmptyData?1:se.interval,axisLine:{show:!0}})}),v.isEmptyData||(I=o.getArrClone(v.x.name),S[0].isShowOther&&S[0].len>0&&S[0].len<v.x.allName.length&&I.push(Ef)),k.length===2&&t.isYEqual){const R=[k[0].min,k[1].min],P=[k[0].max,k[1].max],Q=Math.min.apply(null,R),oe=Math.max.apply(null,P),ue=t.ySpace>0?t.ySpace:1,Y=(oe-Q)/ue,Z=Q,se=o.getNumCeil(Y),K=Number((ue*se).toFixed(2))+Z;k[0].min=k[1].min=Z,k[0].max=k[1].max=K,k[0].interval=k[1].interval=se}return{legendData:C,series:$,yAxis:k,xNames:I,xAxisBoundaryGap:t.isShowLineBg?!_:t.isXBoundaryGap}},M=v=>{const S=x();if(S.length===0){c.value={};return}const C=w(v,S),$={chartType:t.type,dataOriginal:v.data,element:r.value?.getChartElement(),tipTitleFormat:t.tipFormat,seriesNameFormat:t.seriesFormat},k=kf.getOptionAxis($);k.legend.show=!1,k.legend.data=C.legendData,k.xAxis.data=C.xNames,k.yAxis=C.yAxis,k.series=C.series,k.xAxis.boundaryGap=C.xAxisBoundaryGap,k.grid.top="40px",k.grid.left=C.yAxis[0].max===0?"20px":"auto",k.grid.right=C.yAxis.length>1&&C.yAxis[1].max===0?"20px":"auto",k.yAxis.length===1&&!C.xAxisBoundaryGap&&(k.grid.right="20px");const{gridInfo:I}=t;o.isEmpty(I)||["top","left","right","bottom"].forEach(L=>{const _=I[L];o.isEmpty(_)||(k.grid[L]=_)}),k.yAxis.forEach(L=>{L.show=t.isShowY}),c.value=k},b=v=>{const S=o.isArray(v)?v:[];if(f.isInited=!0,f.chartTagJson=D(S),S.length===0){c.value={};return}M(f.chartTagJson)},N=()=>{E(),T(t.tagInitValue),b(t.list)};e.onMounted(()=>{e.nextTick(()=>{f.isInited||N()})}),e.watch([()=>t.list,()=>t.tagList,()=>t.tagSort,()=>t.tagInitValue],()=>{E();const v=m.value.some(S=>!f.tagJson[S]);(m.value.length===0||v)&&T(t.tagInitValue),b(t.list)});const J=v=>{if(o.isUndefined(v))return;const S=v.toString();let C=[];switch(t.tagSelectCountMax){case 1:C=[S];break;case 2:{C=o.getArrClone(m.value);const $=C.indexOf(S);$>-1?C.length>1&&C.splice($,1):(C.push(S),C.length>2&&C.splice(0,1));break}}m.value=C,M(f.chartTagJson)},q=()=>{V()},z=()=>{y()};return a({resize:()=>{r.value?.resize()}}),(v,S)=>(e.openBlock(),e.createBlock(ua,{ref_key:"refElChart",ref:r,id:e.unref(u),chartOption:c.value,className:g.value,height:n.height,isRunLoad:n.isRunLoad,onOnInitFirst:q,onOnHideResize:z,onOnError:l},{chartHead:e.withCtx(()=>[n.isTagShow?(e.openBlock(),e.createElementBlock("div",Sf,[e.createElementVNode("div",null,[e.renderSlot(v.$slots,"title")]),e.createElementVNode("div",wf,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p.value,(C,$)=>(e.openBlock(),e.createElementBlock("span",{key:`${d}-list-${C.id}-${$}`,class:e.normalizeClass({active:m.value.indexOf(C.id.toString())>-1})},[e.createVNode(Qe,{color:"white",label:C.name,onOnClick:k=>J(C.id)},null,8,["label","onOnClick"])],2))),128))])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),nothingData:e.withCtx(()=>[e.renderSlot(v.$slots,"nothingData")]),_:3},8,["id","chartOption","className","height","isRunLoad"]))}}),bf={class:"framephone-statusbar"},Cf={class:"framephone-statusbar-time"},xf={class:"framephone-screen-outer"},ms=e.defineComponent({name:"ClFramePhone",__name:"Index",props:{className:String,width:{type:String,default:"430px"},height:{type:String,default:"750px"},statusBarText:{type:String,default:"9:41"}},setup(n){const a=`fh_${o.getRandom(7)}`,i=e.ref(!1);e.onMounted(()=>{i.value=!0});const t=n,s=e.computed(()=>{const d={"cl-framephone":!0};return o.isNonEmptyString(t.className)&&o.split(t.className," ").forEach(u=>{o.isEmpty(u)||(d[u]=!0)}),d}),l=e.computed(()=>{const d={};return o.isNonEmptyString(t.width)&&(d.width=t.width),o.isNonEmptyString(t.height)&&(d.height=t.height),d});return(d,u)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(s.value),style:e.normalizeStyle(l.value)},[u[1]||(u[1]=e.createElementVNode("div",{class:"framephone-notch"},null,-1)),e.createElementVNode("div",bf,[e.createElementVNode("span",Cf,e.toDisplayString(n.statusBarText),1),u[0]||(u[0]=e.createElementVNode("span",{class:"framephone-statusbar-signal"},[e.createElementVNode("i",{class:"framephone-signal-item framephone-signal-1"}),e.createElementVNode("i",{class:"framephone-signal-item framephone-signal-2"}),e.createElementVNode("i",{class:"framephone-signal-item framephone-signal-3"})],-1))]),e.createElementVNode("div",xf,[e.createElementVNode("div",{class:"framephone-screen",id:a},[i.value?e.renderSlot(d.$slots,"default",{key:0,screenId:a}):e.createCommentVNode("",!0)])]),u[2]||(u[2]=e.createElementVNode("div",{class:"framephone-home"},null,-1))],6))}}),Bf={key:0},Df={key:1},If={class:"inputTag-operate"},ei=e.defineComponent({name:"ClInputTagInput",__name:"Input",props:{value:String,placeholder:String,disabled:Boolean,isClean:{type:Boolean,default:!0},multiple:Boolean,isCopy:Boolean,isCopyMultipleWrap:{type:Boolean,default:!0},copyJoinKey:{type:String,default:","},minHeight:String,joinKey:{type:String,default:","},isDropdownLayer:{type:Boolean,default:!0},textMaxHeight:String,tagsMaxHeight:String,isShowNum:Boolean},emits:["onInit","onChange","onChangeInput","onFocus"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.inject("$InputTagTop"),d=e.useTemplateRef("refElTag"),u=e.useTemplateRef("refElTextarea"),r=e.useTemplateRef("refElInput"),c=e.reactive({isFocus:!1}),m=e.ref([]),p=e.ref([]),f=e.ref(""),h=e.computed(()=>!o.isEmpty(p.value)||!o.isEmpty(f.value)),g=e.computed(()=>t.isClean&&!t.disabled&&h.value),y=e.computed(()=>({"dropdownLayer-text-container":t.isDropdownLayer,"inputTag-container":!0,"inputTag-multiple":t.multiple,"inputTag-focus":c.isFocus})),V=e.computed(()=>{const oe={};return t.multiple&&(t.disabled?oe["min-height"]="40px":o.isNonEmptyString(t.minHeight)&&p.value.length>0&&(oe["min-height"]=t.minHeight)),oe}),E=e.computed(()=>{const oe={},{multiple:ue,tagsMaxHeight:Y}=t;return ue&&o.isNonEmptyString(Y)&&(oe["max-height"]=Y),oe}),B=(oe="tag")=>{const ue=w();s("onChange",ue,oe)},T=()=>{e.nextTick(()=>{s("onInit")})},D=oe=>{s("onChangeInput",oe)},x=oe=>{s("onFocus",oe)},O=()=>{let oe="";if(t.multiple){const ue=t.copyJoinKey+(t.isCopyMultipleWrap?`
9
- `:"");oe=p.value.join(ue)}else oe=f.value;return oe},w=()=>t.multiple?p.value.join(t.joinKey||","):f.value,M=oe=>{if(o.isEmpty(oe))m.value=[],p.value=[],f.value="";else if(oe!==w())if(t.multiple){const ue=[],Y=[];o.split(oe,t.joinKey||",").forEach(Z=>{const se=o.trim(Z);!o.isEmpty(se)&&!o.isExistValue(Y,se)&&(ue.push({id:`inputTag_${o.getRandom(8)}`,name:se}),Y.push(se))}),m.value=ue,p.value=Array.from(new Set(Y))}else f.value=oe},b=oe=>{const ue=o.trim(oe);d.value&&d.value.addInfo({id:`inputTag_${o.getRandom(8)}`,name:ue}),u.value&&(u.value.initHeight(),u.value.setValue(""))},N=()=>{t.multiple?u.value&&u.value.focus():r.value&&r.value.focus()},J=(oe,ue=!0)=>{if(t.multiple){const Y=e.toRaw(p.value);o.split(oe,t.joinKey||",").forEach(Z=>{const se=o.trim(Z);if(!o.isEmpty(se))if(ue)b(se),o.isExistValue(Y,se)||Y.push(se);else{const K=m.value.findIndex(U=>U.name===se);K>-1&&m.value.splice(K,1);const W=Y.indexOf(se);W>-1&&Y.splice(W,1)}}),p.value=Array.from(new Set(Y))}else f.value=ue?oe:"";t.multiple&&N(),B("drop")},q=()=>{M(t.value??""),T()};e.onMounted(()=>{e.nextTick(()=>{q()})}),e.watch(()=>t.value,(oe,ue)=>{oe!==ue&&oe!==w()&&(M(oe??""),u.value&&(u.value.setValue(""),u.value.initHeight()))});const z=oe=>{if(t.multiple){const ue=u.value?u.value.getParentElement():null;(!ue||!ue.contains(oe.target))&&N()}else N()},H=oe=>{if(oe.isComposing||oe.keyCode===229||oe.shiftKey)return;const ue=l?l.getListHoverValueKeydown():"";o.isEmpty(ue)&&(oe.preventDefault(),oe.stopPropagation())},v=oe=>{if(oe.isComposing||oe.keyCode===229||oe.shiftKey)return;const ue=oe.target.value,Y=l?l.getListHoverValueKeydown():"";if(o.isEmpty(Y)){if(oe.preventDefault(),oe.stopPropagation(),!o.isEmpty(ue)){const Z=e.toRaw(p.value);let se=[];o.isExistValue(ue,`
10
- `)?o.split(ue,`
11
- `).forEach(K=>{o.isEmpty(K)||se.push(...o.split(K,t.joinKey||","))}):se=o.split(ue,t.joinKey||","),se.forEach(K=>{const W=o.trim(K);o.isEmpty(W)||(b(W),o.isExistValue(Z,W)||Z.push(W))}),p.value=Array.from(new Set(Z)),B()}}else u.value&&(u.value.initHeight(),u.value.setValue(""))},S=()=>{c.isFocus=!0,x(w())},C=()=>{c.isFocus=!1},$=()=>{if(!d.value)return;const oe=d.value.getData();p.value=oe.filter(ue=>o.isNonEmptyString(ue.name)).map(ue=>ue.name),m.value=oe,D(""),B()},k=()=>{m.value=[],p.value=[],f.value="",u.value&&(u.value.setValue(""),u.value.initHeight()),B(),N()},I=oe=>{D(oe)},L=()=>{x(f.value)};return a({getValue:()=>w(),setValue:oe=>{M(oe),u.value&&(u.value.setValue(""),u.value.initHeight())},focus:()=>{N()},updateValue:(oe,ue=!0)=>{J(oe,ue)}}),(oe,ue)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(y.value),style:e.normalizeStyle(V.value),onClick:e.withModifiers(z,["stop"])},[n.multiple?(e.openBlock(),e.createElementBlock("div",Bf,[e.createElementVNode("div",{class:"inputTag-tags",style:e.normalizeStyle(E.value)},[e.createVNode(Zn,{ref_key:"refElTag",ref:d,disabled:n.disabled,list:m.value,onOnRemove:$},null,8,["disabled","list"])],4),e.withDirectives(e.createVNode(Qn,{ref_key:"refElTextarea",ref:u,height:"24px",heightMax:n.textMaxHeight,disabled:n.disabled,placeholder:n.disabled?"":n.placeholder,isClean:!1,isAutoHeight:!0,onOnKeydownEnter:H,onOnKeyupEnter:v,onOnFocus:S,onOnBlur:C,onOnChangeDelay:I},null,8,["heightMax","disabled","placeholder"]),[[e.vShow,!n.disabled]])])):(e.openBlock(),e.createElementBlock("div",Df,[e.createVNode(Pe,{ref_key:"refElInput",ref:r,value:f.value,"onUpdate:value":ue[0]||(ue[0]=Y=>f.value=Y),placeholder:n.placeholder,isClean:!1,disabled:n.disabled,onOnFocus:L,onOnChangeDelay:I},null,8,["value","placeholder","disabled"])])),e.createElementVNode("div",If,[n.isShowNum&&n.multiple&&p.value.length>1?(e.openBlock(),e.createBlock(Gt,{key:0,num:p.value.length},null,8,["num"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),g.value?(e.openBlock(),e.createBlock(ve,{key:2,name:"close-circle-fill",className:"inputTag-operate-btn","aria-label":"清空",tabindex:"-1",role:"button",onClick:e.withModifiers(k,["stop"]),onKeydown:[e.withKeys(e.withModifiers(k,["stop","prevent"]),["enter"]),e.withKeys(e.withModifiers(k,["stop","prevent"]),["space"])]},null,8,["onKeydown"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),n.isCopy&&h.value?(e.openBlock(),e.createBlock(yn,{key:4,className:"inputTag-operate-btn",textLabel:O})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))])],6))}}),Tf={class:"dropdownLayer-list-container"},Nf={key:0,class:"dropdownLayer-list-search"},Vf={key:2,class:"dropdownLayer-list-checkboxAll"},_f=["aria-activedescendant"],Mf=["id","aria-selected","aria-disabled","onClick","onMouseenter","onMouseleave"],Of={key:0,class:"dropdownLayer-list-checkbox"},Af=["innerHTML"],Lf={key:1},$f={key:0,class:"dropdownLayer-list-empty"},Ff={key:1,class:"inputTag-load"},Pf=180,Rf=50,Hf=100,Uf=130,zf=e.defineComponent({name:"ClDropdownlayerSearchList",__name:"Dropdown",props:{isSearch:Boolean,searchValue:String,searchPlaceholder:String,searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||",validator:n=>["||","&&"].indexOf(n)>-1},isMultiple:Boolean,isCheckBoxAll:Boolean,showDropDownTextFormat:String,showDropDownTextFormatSub:String,isCascade:Boolean,parentSelectable:Boolean,parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"},originalData:{type:Array,default:()=>[]},keyIndex:String,selectId:{type:Array,default:()=>[]},isShowEmptyLabel:{type:Boolean,default:!0},isShowLoading:Boolean,serverCallback:Function},emits:["onChange","onSearchResult","onError"],setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("common");const u=e.inject("$InputTagTop"),r=e.useTemplateRef("refElSearch"),c=e.useTemplateRef("refElList"),m=`inputtag-${o.getRandom(5)}`;let p=0,f=0,h=0,g=0,y=!1,V=!1;const E={start:-1,end:-1,limit:50},B=e.reactive({isRunLoading:!1}),T=`dropdownLayer-list-${t.keyIndex||m}`,D=e.ref(""),x=e.ref([]),O=e.ref([]);let w=[],M=[],b=!1;const N={isScrollLoadIng:!1},J=e.computed(()=>{let ne=!1;return O.value.length>0&&t.selectId.length>=O.value.length&&(ne=o.isContainArr(t.selectId.map(te=>te.toString()),O.value)),ne}),q=e.computed(()=>new Set(t.selectId.map(ne=>ne.toString()))),z=(ne,A)=>{s("onChange",ne,A)},H=(ne,A)=>{s("onSearchResult",{search:o.isNonEmptyString(ne)?ne:"",isEmpty:A})},v=ne=>{s("onError",ne)},S=ne=>o.isEmpty(ne)?[]:ne.filter(A=>A?o.isString(A.id)&&!o.isEmpty(A.id)||o.isNumber(A.id)&&o.isFinite(A.id):!1),C=async ne=>{h++;const A=h;let te=[];if(t.serverCallback){t.isShowLoading&&(B.isRunLoading=!0);try{if(te=await t.serverCallback({search:ne,offset:0}),A!==h)return;e.nextTick(()=>{A===h&&(B.isRunLoading=!1,u&&u.convertListToJson(te),e.nextTick(()=>{$(ne,te)}))})}catch{A===h&&(B.isRunLoading=!1,v("服务端搜索失败,请稍后重试"))}}else if(o.isEmpty(ne))te=t.originalData,$(ne,te);else if(o.isNonEmptyString(ne)){const ce=ne.toLowerCase(),pe=t.searchKey.length,he=t.searchKey;t.originalData.forEach(Ee=>{const be=[];for(let xe=0;xe<pe;xe++){const De=Ee[he[xe]];o.isNonEmptyString(De)&&De.toLowerCase().indexOf(ce)>-1&&be.push(!0)}if(be.length>0)switch(t.searchKeyType){case"||":te.push(Ee);break;case"&&":be.length===pe&&te.push(Ee);break}}),$(ne,te)}},$=(ne,A)=>{t.isCascade?(o.isEmpty(ne)||(A=L(A,t.originalData)),M=A,A=I(A)):A=S(A),w=A,x.value=_(0,E.limit),c.value&&(c.value.scrollTop=0),P(0,E.limit),k(),D.value="",H(ne,A.length===0)},k=()=>{const ne=[],A=t.selectId.map(te=>te.toString());w.forEach(te=>{if(o.isEmpty(te.id))return;const ce=te.id.toString();te.isDisabled?o.isExistValue(A,ce)&&ne.push(ce):ne.push(ce)}),O.value=ne},I=ne=>{const A=t.parentKey||"parentId",te=t.topParentValue||"0",ce={};ne.forEach(xe=>{if(o.isEmpty(xe.id))return;const De=xe[A];if(!o.isEmpty(De)&&De.toString()!==te){const Re=De.toString();ce[Re]||(ce[Re]=[]),ce[Re].push(xe)}});const pe=[],he=ne.filter(xe=>{if(o.isEmpty(xe.id))return!1;const De=xe[A];return o.isEmpty(De)||De.toString()===te}),Ee=new Set,be=(xe,De,Re)=>{xe.forEach(Fe=>{const yt=Fe.id.toString();if(Ee.has(yt))return;Ee.add(yt);const $t=ce[yt]||[];pe.push({...Fe,_level:De,_parentName:Re,_hasChildren:$t.length>0,isDisabled:Fe.isDisabled||$t.length>0&&!t.parentSelectable}),$t.length>0&&be($t,De+1,Fe.name)})};return be(he,0,""),pe},L=(ne,A)=>{const te=t.parentKey||"parentId",ce=t.topParentValue||"0",pe={},he={};A.forEach(De=>{if(o.isEmpty(De.id))return;const Re=De.id.toString();pe[Re]=De;const Fe=De[te];!o.isEmpty(Fe)&&Fe.toString()!==ce&&(he[Fe.toString()]||(he[Fe.toString()]=[]),he[Fe.toString()].push(Re))});const Ee=new Set,be=new Set;ne.forEach(De=>{o.isEmpty(De.id)||be.add(De.id.toString())});const xe=De=>{let Re=pe[De],Fe=0;for(;Re&&Fe<100;){Ee.add(Re.id.toString());const yt=Re[te];if(o.isEmpty(yt)||yt.toString()===ce)break;Re=pe[yt.toString()],Fe++}};return ne.forEach(De=>{if(o.isEmpty(De.id))return;const Re=De.id.toString();xe(Re),he[Re]&&he[Re].forEach(Fe=>{Ee.add(Fe)})}),A.filter(De=>o.isEmpty(De.id)?!1:Ee.has(De.id.toString()))},_=(ne,A)=>{const te=[],ce=w.length,pe=ne<0?0:ne,he=A<=ce?A:ce;if(pe<he)for(let Ee=pe;Ee<he;Ee++)te.push(w[Ee]);return te},R=(ne,A)=>{let te=0,ce=0;switch(A){case"prev":te=ne-E.limit,ce=ne;break;case"next":te=ne,ce=te+E.limit;break}return _(te,ce)},P=(ne,A)=>{let te=E.start;(te===-1||ne<te)&&(te=ne),te=te<=0?0:te;let ce=E.end;A>ce&&(ce=A),ce=A<=w.length?A:w.length,E.start=te,E.end=ce},Q=()=>{let ne=-1,A="";if(!o.isEmpty(t.selectId)){const pe=t.selectId.map(he=>he.toString());w.some((he,Ee)=>{if(o.isEmpty(he.id))return!1;const be=he.id.toString(),xe=o.isExistValue(pe,be);return xe&&(ne=Ee,A=be),xe})}let te=0,ce=0;ne===-1?(p=0,te=0,ce=E.limit):(te=ne-E.limit*1,ce=ne+E.limit*1),x.value=_(te,ce),E.start=te<=0?0:te,E.end=ce>=w.length?w.length:ce,o.isEmpty(A)||x.value.some((pe,he)=>{if(o.isEmpty(pe.id))return!1;const Ee=pe.id.toString()===A;return Ee&&(p=he),Ee})},oe=ne=>{e.nextTick(()=>{const A=c.value;if(!(!A||!A.children[0]))if(ne>0){const te=A.children[0].children[ne];A.scrollTop=te&&te.offsetTop>Pf?te.offsetTop-Rf:0}else A.scrollTop=0})},ue=()=>{t.isCascade?(M=S(t.originalData),w=I(M)):w=S(t.originalData),Q(),e.nextTick(()=>{o.isEmpty(t.searchValue)&&(r.value&&r.value.setValue(""),c.value&&oe(p))})},Y=async ne=>{const A=Date.now(),te=ne.target,ce=te.scrollTop;if(A-g<150){f=ce;return}g=A;const pe=te.offsetHeight;if(!te.children[0]){f=ce;return}const he=te.children[0].offsetHeight;if(ce>f){if(ce+pe+Hf>he&&!N.isScrollLoadIng){if(N.isScrollLoadIng=!0,E.end>=w.length&&t.serverCallback){const Ee=h,be=t.searchValue,xe={offset:w.length};o.isEmpty(be)||(xe.search=be);try{const De=await t.serverCallback(xe);if(V)return;Ee===h&&t.searchValue===be&&(t.isCascade?(M.push(...S(De)),w=I(M)):w.push(...S(De)),k(),u&&u.convertListToJson(w))}catch{Ee===h&&v("服务端加载更多失败,请稍后重试")}}if(E.end<w.length){const Ee=R(E.end,"next");x.value.push(...Ee),P(E.start,E.end+E.limit)}N.isScrollLoadIng=!1}}else if(ce<Uf&&E.start>0){const Ee=R(E.start,"prev"),be=Ee.length;be>0&&(x.value.unshift(...Ee),P(E.start-E.limit,E.end),e.nextTick(()=>{const xe=c.value;if(!xe||!xe.children[0])return;let De=0;const Re=xe.children[0].children;for(let Fe=0;Fe<be&&Re[Fe];Fe++)De+=Re[Fe].offsetHeight;xe.scrollTop+=De}))}f=ce},Z=()=>{b||e.nextTick(()=>{c.value&&(c.value.addEventListener("scroll",Y),b=!0)})},se=ne=>{let A=t.showDropDownTextFormat;if(ne._level>=1&&!o.isEmpty(t.showDropDownTextFormatSub)&&(A=t.showDropDownTextFormatSub),o.isEmpty(A)){if(o.isEmpty(ne.name))return"";const te=ne.name;return o.isString(te)?o.encodeHTML(te):String(te)}return o.convertStringFormatEncodeHTML(A,ne)},K=ne=>{const A=[];return t.isMultiple?(t.selectId.forEach(te=>{te.toString()!==ne&&A.push(te)}),o.isExistValue(t.selectId.map(te=>te.toString()),ne)||A.push(ne)):A.push(ne),A},W=ne=>{const A=x.value;if(A.length===0){D.value="";return}let te=-1;const ce=D.value;ce.length>0?(A.forEach((pe,he)=>{pe.id.toString()===ce&&(te=he)}),te+=ne,te<0?te=0:te>=A.length&&(te=A.length-1)):te=0,D.value=o.isEmpty(A[te].id)?"":A[te].id.toString(),oe(te)},U=ne=>{if(ne.isComposing||ne.keyCode===229)return;let A=ne.keyCode;if(!o.isUndefined(A))switch(A=A.toString(),A){case"13":if(ne.shiftKey)break;ne.preventDefault(),ne.stopPropagation();break;case"38":ne.preventDefault(),ne.stopPropagation(),W(-1);break;case"40":ne.preventDefault(),ne.stopPropagation(),W(1);break}},ae=ne=>{if(ne.isComposing||ne.keyCode===229)return;let A=ne.keyCode;if(!o.isUndefined(A))switch(A=A.toString(),A){case"27":u&&u.setDropdownOpen(!1);break;case"13":{if(ne.shiftKey)break;const te=D.value;if(!o.isEmpty(te)){const ce=x.value.find(pe=>pe.id.toString()===te);if(ce&&!ce.isDisabled){const pe=K(te);z(pe,{id:te,isSelect:t.selectId.map(he=>he.toString()).indexOf(te)===-1})}}break}}},G=()=>{ue(),k(),Z();const{searchValue:ne}=t;o.isNonEmptyString(ne)&&C(ne)};e.onMounted(()=>{G()}),e.onBeforeUnmount(()=>{V=!0,de.offListener(window,"keydown",U,!0),de.offListener(window,"keyup",ae,!0),y=!1,c.value&&c.value.removeEventListener("scroll",Y)}),e.watch(()=>t.originalData,ne=>{t.isCascade?(M=S(ne),w=I(M)):w=S(ne),Q(),k(),Z()}),e.watch(()=>t.searchValue,ne=>{C(ne)});const X=ne=>{C(ne)},ee=ne=>{if(!ne||!t.isMultiple)return;const A=t.selectId.map(be=>be.toString()),te=new Set;w.forEach(be=>{be.isDisabled&&!o.isEmpty(be.id)&&te.add(be.id.toString())});const ce=[],pe=[],he=[];O.value.forEach(be=>{ne.value?o.isExistValue(A,be)||pe.push(be):o.isExistValue(A,be)&&!te.has(be)&&he.push(be),ce.push(be)});const Ee=o.getArrClone(t.selectId);he.length>0&&he.forEach(be=>{const xe=Ee.findIndex(De=>De.toString()===be);xe>-1&&Ee.splice(xe,1)}),pe.length>0&&Ee.push(...pe),z(Ee,{id:ce,isSelect:ne.value})},F=ne=>{if(!ne.isDisabled&&!o.isEmpty(ne.id)){const A=ne.id.toString(),te=K(A);z(te,{id:A,isSelect:t.selectId.map(ce=>ce.toString()).indexOf(A)===-1})}},j=ne=>{!ne||o.isEmpty(ne.id)||(D.value=ne.id.toString())},le=ne=>{!ne||o.isEmpty(ne.id)||D.value===ne.id.toString()&&(D.value="")};return a({initOpenShow:ne=>{ne?y||(de.onListener(window,"keydown",U,!0),de.onListener(window,"keyup",ae,!0),y=!0):y&&(de.offListener(window,"keydown",U,!0),de.offListener(window,"keyup",ae,!0),y=!1)},getHoverKeydown:()=>D.value}),(ne,A)=>(e.openBlock(),e.createElementBlock("div",Tf,[B.isRunLoading?(e.openBlock(),e.createElementBlock("div",Ff,[e.createVNode(Zt,{isLoadIng:B.isRunLoading},null,8,["isLoadIng"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.isSearch?(e.openBlock(),e.createElementBlock("div",Nf,[e.createVNode(Qt,{ref_key:"refElSearch",ref:r,placeholder:n.searchPlaceholder,onOnChange:X},null,8,["placeholder"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isMultiple&&n.isCheckBoxAll?(e.openBlock(),e.createElementBlock("div",Vf,[e.createVNode(dt,{forId:`${T}-cb-all`,label:e.unref(l).checkboxAll,value:J.value,onOnChange:ee},null,8,["forId","label","value"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),e.createElementVNode("div",{class:"dropdownLayer-list-body",ref_key:"refElList",ref:c},[x.value.length>0?(e.openBlock(),e.createElementBlock("ul",{key:0,role:"listbox","aria-activedescendant":D.value?`${T}-opt-${D.value}`:void 0},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(x.value,(te,ce)=>(e.openBlock(),e.createElementBlock("li",{key:`${m}-${te.id}-${ce}`,id:`${T}-opt-${te.id}`,role:"option","aria-selected":q.value.has(te.id.toString()),"aria-disabled":te.isDisabled,class:e.normalizeClass({"option-selected":q.value.has(te.id.toString()),"option-disabled":te.isDisabled,"option-hoverKeydown":D.value===te.id.toString(),"inputTag-dropdown-item-child":te._level>=1}),style:e.normalizeStyle({paddingLeft:te._level?te._level*20+"px":void 0}),onClick:pe=>F(te),onMouseenter:pe=>j(te),onMouseleave:pe=>le(te)},[e.createElementVNode("div",null,[n.isMultiple?(e.openBlock(),e.createElementBlock("div",Of,[e.createVNode(dt,{name:`${T}-cb`,forId:`${T}-cb-${te.id}`,value:q.value.has(te.id.toString()),disabled:te.isDisabled},null,8,["name","forId","value","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",{class:"dropdownLayer-list-title",innerHTML:se(te)},null,8,Af)])],46,Mf))),128))],8,_f)):(e.openBlock(),e.createElementBlock("ul",Lf,[n.isShowEmptyLabel?(e.openBlock(),e.createElementBlock("li",$f,e.toDisplayString(e.unref(l).noResultsText),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]))],512)],64))]))}}),Jf=["id"],da=e.defineComponent({name:"ClInputTag",__name:"Index",props:{id:String,value:String,className:String,placeholder:String,disabled:Boolean,isClean:{type:Boolean,default:!0},multiple:{type:Boolean,default:!0},isCopy:Boolean,isCopyMultipleWrap:{type:Boolean,default:!0},copyJoinKey:{type:String,default:","},minHeight:{type:String,default:"70px"},joinKey:{type:String,default:","},isAutofill:Boolean,list:{type:Array,default:()=>[]},searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||",validator:n=>["||","&&"].indexOf(n)>-1},showDropDownTextFormat:String,showDropDownTextFormatSub:String,isCascade:Boolean,parentSelectable:Boolean,parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"},isFocusShowDrop:Boolean,textMaxHeight:String,tagsMaxHeight:String,isShowNum:Boolean,isShowLoading:Boolean,serverCallback:Function,isPlaintext:{type:Boolean,default:!1},appendContainer:{type:String,default:""}},emits:["onInit","update:value","update:modelValue","onChange","onError"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElDropdownLayer"),u=e.useTemplateRef("refElInput"),r=e.useTemplateRef("refElList"),c=e.reactive({keyIndex:`inputTag-${o.getRandom(8)}`,searchValue:"",dropdownSelectId:[],isUseData:!1}),m={listNameJson:{},listIdJson:{}},p=e.computed(()=>{let v={"panel-input-tag":!0,"inputTag-disabled":t.disabled||t.isPlaintext,"cl-plaintext-static":t.isPlaintext,"cl-plaintext-inputtag":t.isPlaintext};return v=o.getJsonMerge(v,de.getClassNameJson(t.className)),o.getStringByJson(v," ")}),f=e.computed(()=>{let v="inputTag-dropdown ";return c.isUseData||(v+=" inputTag-dropdown-nodata "),v}),h=(v,S="")=>{s("update:value",v),s("update:modelValue",v),s("onChange",v,S)},g=()=>{e.nextTick(()=>{s("onInit")})},y=v=>{const C=o.isEmpty(v)?[]:v.filter($=>{if(!$)return!1;const k=o.isString($.id)&&!o.isEmpty($.id)||o.isNumber($.id)&&o.isFinite($.id),I=o.isNonEmptyString($.name)||o.isNumber($.name)&&!o.isEmpty($.name);return k&&I});m.listNameJson=o.getJsonByList(C,"name"),m.listIdJson=o.getJsonByList(C,"id")},V=v=>{if(d.value){const S=d.value.checkIsShowOpen();if(v){if(!S){const C=[],$=u.value?u.value.getValue():"",k=o.isEmpty($)?[]:o.split($,t.joinKey||",");k.length>0&&k.forEach(I=>{if(o.isExistJsonKey(m.listNameJson,I)){const L=m.listNameJson[I];L&&!o.isEmpty(L.id)&&C.push(L.id.toString())}}),c.dropdownSelectId=C,c.isUseData=!o.isEmpty(t.list)||!!t.serverCallback,d.value.setOpen(!0),e.nextTick(()=>{d.value&&d.value.initCompleteOpen()})}}else c.isUseData=!0,S&&d.value.setOpen(!1)}},E=()=>{o.isEmpty(t.list)||y(t.list)};e.onMounted(()=>{e.nextTick(()=>{E()})}),e.watch(()=>t.list,v=>{y(v),c.isUseData=!o.isEmpty(v)||!!t.serverCallback});const B=()=>{g()},T=v=>{v&&t.disabled||e.nextTick(()=>{r.value&&r.value.initOpenShow(v)})},D=v=>{const S=v.toLowerCase(),C=t.searchKey;let $=!1;return t.list.forEach(k=>{if($)return;let I=0;for(let L=0;L<C.length;L++){const _=k[C[L]];o.isNonEmptyString(_)&&_.toLowerCase().indexOf(S)>-1&&I++}I>0&&(t.searchKeyType==="||"||t.searchKeyType==="&&"&&I===C.length)&&($=!0)}),$},x=v=>{c.searchValue=v;let S=!0;if(o.isNonEmptyString(v)&&(v.indexOf(`
12
- `)>-1||!o.isEmpty(t.joinKey)&&v.indexOf(t.joinKey)>-1)&&(S=!1),S){const C=o.isEmpty(v)?!1:t.serverCallback?!0:D(v);V(C)}else V(!1);t.multiple||h(v,"input")},O=v=>{V(!v.isEmpty&&!o.isEmpty(v.search))},w=v=>{s("onError",v)},M=(v,S)=>{if(o.isEmpty(S)||t.disabled)return;const C=[];(o.isArray(S.id)?S.id:[S.id]).forEach(k=>{o.isExistJsonKey(m.listIdJson,k)&&C.push(m.listIdJson[k].name)}),t.multiple||(c.searchValue=""),u.value&&u.value.updateValue(C.join(t.joinKey||","),S.isSelect)},b=(v,S)=>{h(v,S),t.isAutofill&&V(!1)},N=v=>{t.isAutofill&&t.isFocusShowDrop&&(c.searchValue=v,V(!o.isEmpty(v)))};e.provide("$InputTagTop",{getListHoverValueKeydown:()=>{let v="";return r.value&&(v=r.value.getHoverKeydown()),v},convertListToJson:y,setDropdownOpen:V});const J=()=>u.value?u.value.getValue():"";return a({getValue:J,getValueData:()=>{const v=J();return u.value?o.split(v,t.joinKey||",").filter(C=>!o.isEmpty(C)).map(C=>{const $=m.listNameJson[C];return{name:C,id:$&&!o.isEmpty($.id)?$.id:void 0}}):[]},setValue:v=>{u.value&&u.value.setValue(v)},focus:()=>{u.value&&u.value.focus()}}),(v,S)=>n.isAutofill?(e.openBlock(),e.createBlock(wn,{key:0,ref_key:"refElDropdownLayer",ref:d,id:e.unref(l),classParent:p.value,classDropDown:f.value,transitionLeave:"inputTag-dropdown-leave",appendContainer:n.appendContainer,onOnChangeOpen:T},{labelCustom:e.withCtx(()=>[e.createVNode(ei,{ref_key:"refElInput",ref:u,value:n.value,placeholder:n.placeholder,disabled:n.disabled||n.isPlaintext,isClean:n.isClean,multiple:n.multiple,minHeight:n.minHeight,joinKey:n.joinKey,isCopy:n.isCopy,isCopyMultipleWrap:n.isCopyMultipleWrap,copyJoinKey:n.copyJoinKey,isDropdownLayer:!0,textMaxHeight:n.textMaxHeight,tagsMaxHeight:n.tagsMaxHeight,isShowNum:n.isShowNum,onOnChange:b,onOnChangeInput:x,onOnInit:B,onOnFocus:N},null,8,["value","placeholder","disabled","isClean","multiple","minHeight","joinKey","isCopy","isCopyMultipleWrap","copyJoinKey","textMaxHeight","tagsMaxHeight","isShowNum"])]),dropdown:e.withCtx(()=>[e.createVNode(zf,{ref_key:"refElList",ref:r,keyIndex:c.keyIndex,isSearch:!1,searchValue:c.searchValue,searchKey:n.searchKey,searchKeyType:n.searchKeyType,isMultiple:!1,showDropDownTextFormat:n.showDropDownTextFormat,showDropDownTextFormatSub:n.showDropDownTextFormatSub,isCascade:n.isCascade,parentSelectable:n.parentSelectable,parentKey:n.parentKey,topParentValue:n.topParentValue,isShowEmptyLabel:!1,originalData:n.list,selectId:c.dropdownSelectId,serverCallback:n.serverCallback,isShowLoading:n.isShowLoading,onOnSearchResult:O,onOnChange:M,onOnError:w},null,8,["keyIndex","searchValue","searchKey","searchKeyType","showDropDownTextFormat","showDropDownTextFormatSub","isCascade","parentSelectable","parentKey","topParentValue","originalData","selectId","serverCallback","isShowLoading"])]),_:1},8,["id","classParent","classDropDown","appendContainer"])):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(p.value),id:e.unref(l)},[e.createVNode(ei,{ref_key:"refElInput",ref:u,value:n.value,placeholder:n.placeholder,disabled:n.disabled||n.isPlaintext,isClean:n.isClean,multiple:n.multiple,minHeight:n.minHeight,joinKey:n.joinKey,isCopy:n.isCopy,isCopyMultipleWrap:n.isCopyMultipleWrap,copyJoinKey:n.copyJoinKey,isDropdownLayer:!1,textMaxHeight:n.textMaxHeight,tagsMaxHeight:n.tagsMaxHeight,isShowNum:n.isShowNum,onOnChange:b,onOnChangeInput:x,onOnInit:B,onOnFocus:N},null,8,["value","placeholder","disabled","isClean","multiple","minHeight","joinKey","isCopy","isCopyMultipleWrap","copyJoinKey","textMaxHeight","tagsMaxHeight","isShowNum"])],10,Jf))}}),Kf=["id"],Wf={key:0,class:"select-inDropdown-search",role:"search","aria-label":"搜索选项"},jf={key:2,class:"select-inDropdown-checkboxAll"},Yf=["aria-selected","aria-disabled","onClick"],qf={class:"select-inDropdown-item-inner"},Xf={key:0,class:"select-inDropdown-checkbox"},Gf=["innerHTML"],Qf={key:5,class:"select-inDropdown-body"},Zf={class:"select-inDropdown-empty"},_o=35,eh=210,th=20,nh=e.defineComponent({name:"ClSelectInDropdown",__name:"Dropdown",props:{id:String,disabled:{type:Boolean,default:!1},isSearch:{type:Boolean,default:!1},searchPlaceholder:String,searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||"},isMultiple:{type:Boolean,default:!1},isCheckBoxAll:{type:Boolean,default:!0},showDropDownTextFormat:String,showDropDownTextFormatSub:String,isCascade:{type:Boolean,default:!1},parentSelectable:{type:Boolean,default:!1},parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"},originalData:{type:Array,default:()=>[]},keyIndex:String,isOpen:{type:Boolean,default:!1},selectId:{type:Array,default:()=>[]},serverCallback:Function},emits:{onChange:n=>!0,onInitComplete:()=>!0,onError:n=>!0},setup(n,{expose:a,emit:i}){const t=e.defineAsyncComponent(()=>import("vue-virtual-scroller").then(K=>(Promise.resolve().then(()=>require("./vue-virtual-scroller-Dyvby5gX.cjs")),K.RecycleScroller))),s=n,l=i,{optPageLanguage:d,getPageLanguage:u}=Le();u("common");const r=e.inject("$SelectTop",{}),c=typeof r.getSelectData=="function",m=e.useTemplateRef("refElSearch"),p=e.useTemplateRef("refElScroller"),f=e.useTemplateRef("refElRoot");let h=!0;const g={isScrollLoading:!1,hasMoreData:!0};let y=[],V=0,E=0;const B=s.id,T=`select-inList-${s.keyIndex||""}`;let D=!1;const x=e.ref(""),O=e.ref([]),w=e.ref([]);let M={};const b=K=>{const W=K.id.toString();if(s.isMultiple&&s.isCascade&&K._hasChildren&&c){const ae=r.getAllChildIds(W).filter(X=>!r.getSelectValueInfo(X)?.isDisabled);if(ae.length===0)return 0;const G=ae.filter(X=>o.isExistValue(s.selectId,X)).length;return G===0?0:G===ae.length?2:1}return o.isExistValue(s.selectId,W)?2:0},N=K=>b(K)===2,J=K=>b(K)===1,q=e.computed(()=>{let K=!1;return w.value.length>0&&s.selectId.length>=w.value.length&&(K=o.isContainArr(s.selectId,w.value)),K}),z=K=>{if(!K||typeof K!="object")return"";let W=o.isNonEmptyString(s.showDropDownTextFormat)?s.showDropDownTextFormat:"";K._level>=1&&o.isNonEmptyString(s.showDropDownTextFormatSub)&&(W=s.showDropDownTextFormatSub);let U=o.isEmpty(W)?K.name:o.convertStringFormat(W,K);return o.isHtml(U)?o.isEmpty(W)&&o.isHtml(K.name)?U=o.encodeHTML(K.name):U=o.convertStringFormatEncodeHTML(W,K):typeof U=="string"&&U.indexOf("<")>-1&&(U=o.encodeHTML(U)),U},H=K=>{const W=M[K]||{};if(o.isBoolean(W._isTypeRadio))return W._isTypeRadio;if(c){const U=r.getSelectValueInfo(K);if(o.isBoolean(U?._isTypeRadio))return U._isTypeRadio}return!1},v=()=>{const K=[];M=o.getJsonByList(O.value),O.value.forEach(W=>{if(!o.isObject(W))return;const U=typeof W.id;if(W.id==null||U!=="string"&&(U!=="number"||!o.isFinite(W.id)))return;const ae=W.id.toString();if(!(s.isCascade&&W._hasChildren)&&!H(ae)){if(o.isExistValue(K,ae))return;W.isDisabled?o.isExistValue(s.selectId,ae)&&K.push(ae):K.push(ae)}}),w.value=K},S=K=>{const W=s.parentKey,U=s.topParentValue,ae={};K.forEach(F=>{if(!o.isObject(F)||F.id==null||typeof F.id!="string"&&(typeof F.id!="number"||!o.isFinite(F.id)))return;const j=F[W],le=j!=null&&(typeof j=="string"||typeof j=="number")?j.toString():"";le!==""&&le!==String(U)&&(ae[le]||(ae[le]=[]),ae[le].push(F))});const G=[],X=(F,j,le,me)=>{F.forEach(ie=>{const ne=ie.id.toString();if(me.has(ne))return;me.add(ne);const A=ae[ne]||[];G.push({...ie,_level:j,_parentName:le,_hasChildren:A.length>0}),A.length>0&&X(A,j+1,ie.name,me)})},ee=K.filter(F=>{if(!o.isObject(F)||F.id==null||typeof F.id!="string"&&(typeof F.id!="number"||!o.isFinite(F.id)))return!1;const j=F[W],le=j!=null&&(typeof j=="string"||typeof j=="number")?j.toString():"";return o.isEmpty(le)||le===String(U)});return X(ee,0,"",new Set),G},C=(K,W)=>{if(!c)return K;const U=K.filter(me=>me!=null&&me.id!=null&&(typeof me.id=="string"||typeof me.id=="number"&&o.isFinite(me.id))),ae=W.filter(me=>me!=null&&me.id!=null&&(typeof me.id=="string"||typeof me.id=="number"&&o.isFinite(me.id))),G=s.parentKey,X=s.topParentValue,ee=new Set,F=new Set(U.map(me=>me.id.toString()));U.forEach(me=>{const ie=me.id.toString();ee.add(ie);const ne=new Set;let A=me[G];for(;A!=null&&(typeof A=="string"||typeof A=="number")&&A.toString()!==String(X);){const ce=A.toString();if(ne.has(ce))break;ne.add(ce),F.has(ce)||ee.add(ce),A=r.getSelectValueInfo(ce)?.[G]}r.getAllChildIds(ie).forEach(ce=>{ee.add(ce)})});const j=ae.filter(me=>ee.has(me.id.toString())),le=new Set(j.map(me=>me.id.toString()));return ee.forEach(me=>{if(!le.has(me)){const ie=r.getSelectValueInfo(me);ie&&Object.keys(ie).length>0&&j.push(ie)}}),j},$=()=>{h&&(h=!1,g.hasMoreData=!0,s.isCascade?(y=[...s.originalData||[]],O.value=S(y)):O.value=o.getListClone(s.originalData).filter(K=>K!=null&&K.id!=null&&(typeof K.id=="string"||typeof K.id=="number"&&o.isFinite(K.id))),v(),k(),x.value="",e.nextTick(()=>{m.value&&m.value.setValue("")}))},k=()=>{e.nextTick(()=>{if(p.value&&s.selectId.length>0){const K=O.value.findIndex(W=>W.id!=null&&o.isExistValue(s.selectId,W.id.toString()));K>-1&&p.value.scrollToItem(K)}})},I=K=>{const W=[],U=M[K]||{},ae=s.isCascade&&U._hasChildren;if(s.isMultiple)if(H(K))o.isExistValue(s.selectId,K)?s.selectId.forEach(G=>{G!==K&&W.push(G)}):(s.selectId.forEach(G=>{H(G)||W.push(G)}),W.push(K));else if(ae&&c){const G=r.getAllChildIds(K),X=G.filter(F=>!r.getSelectValueInfo(F)?.isDisabled),ee=X.length>0&&X.every(F=>o.isExistValue(s.selectId,F));s.selectId.forEach(F=>{G.includes(F)?G.includes(F)&&r.getSelectValueInfo(F)?.isDisabled&&W.push(F):W.push(F)}),ee||X.forEach(F=>{o.isExistValue(W,F)||W.push(F)})}else s.selectId.forEach(G=>{G!==K&&W.push(G)}),o.isExistValue(s.selectId,K)||W.push(K);else{if(ae&&!s.parentSelectable)return[...s.selectId];W.push(K)}return W},L=K=>{const W=O.value;if(W.length===0)return;let U=-1;const ae=x.value;ae.length>0?(W.forEach((G,X)=>{G.id.toString()===ae&&(U=X)}),U+=K,U<0?U=0:U>=W.length&&(U=W.length-1)):U=0,x.value=W[U].id.toString(),p.value&&p.value.scrollToItem(U)},_=K=>{let W=K.keyCode;if(!o.isUndefined(W))switch(W=W.toString(),W){case"13":{const U=f.value&&K.target instanceof Node&&f.value.contains(K.target);(K.target===document.body||U)&&(K.preventDefault(),K.stopPropagation());break}case"38":K.preventDefault(),K.stopPropagation(),L(-1);break;case"40":K.preventDefault(),K.stopPropagation(),L(1);break}},R=K=>{let W=K.keyCode;if(!o.isUndefined(W))switch(W=W.toString(),W){case"27":c&&r.closeDropdown?.();break;case"13":{const U=x.value;if(!U||s.disabled||!s.isOpen)break;const ae=f.value&&K.target instanceof Node&&f.value.contains(K.target);if(K.target!==document.body&&!ae||!O.value.some(ee=>ee.id.toString()===U)||M[U]?.isDisabled)break;const X=I(U);l("onChange",X);break}}},P=K=>K.map(W=>{const{_level:U,_parentName:ae,_hasChildren:G,...X}=W;return X}),Q=async()=>{if(s.serverCallback&&!(g.isScrollLoading||!g.hasMoreData)&&(g.isScrollLoading=!0,s.serverCallback)){const K=++E,W=O.value;try{const U={offset:W.length};if(s.isSearch&&m.value){const ee=m.value.getValue();o.isEmpty(ee)||(U.search=ee)}const ae=await s.serverCallback(U);if(K!==E||W!==O.value)return;if(!Array.isArray(ae)){Se.error("ClSelect","_loadMore 服务端返回数据格式异常(非数组):",typeof ae),l("onError","服务端加载失败:返回数据格式异常");return}if(ae.length===0){g.hasMoreData=!1;return}const G=new Set(W.map(ee=>ee?.id?.toString()).filter(Boolean)),X=ae.filter(ee=>{if(ee?.id==null)return!1;const F=typeof ee.id;return F!=="string"&&(F!=="number"||!o.isFinite(ee.id))?!1:!G.has(ee.id.toString())});if(X.length===0){g.hasMoreData=!1;return}s.isCascade?U.search?O.value=S([...O.value,...X]):(y.length===0&&(y=P(O.value)),y.length===0&&(y=[...s.originalData]),y.push(...X),O.value=S(y)):O.value.push(...X),v(),c&&(r.convertListToJson(X),r.refreshDisplayLabels?.())}catch(U){Se.error("ClSelect","_loadMore 服务端加载失败:",U),l("onError","服务端加载失败,请稍后重试")}finally{g.isScrollLoading=!1}}},oe=()=>{$(),l("onInitComplete")};e.onMounted(()=>{oe()}),e.onBeforeUnmount(()=>{de.offListener(window,"keydown",_),de.offListener(window,"keyup",R),D=!1}),e.onDeactivated(()=>{de.offListener(window,"keydown",_),de.offListener(window,"keyup",R),D=!1}),e.onActivated(()=>{s.isOpen&&!D&&(de.onListener(window,"keydown",_),de.onListener(window,"keyup",R),D=!0)}),e.watch(()=>s.isOpen,K=>{K?(h=!0,$()):g.isScrollLoading=!1}),e.watch(()=>s.originalData,K=>{h=!0,s.isCascade?(y=[...K||[]],O.value=S(y)):O.value=o.getListClone(K).filter(W=>W!=null&&W.id!=null&&(typeof W.id=="string"||typeof W.id=="number"&&o.isFinite(W.id))),v(),g.hasMoreData=!0,x.value="",e.nextTick(()=>{m.value&&m.value.setValue("")})});const ue=async K=>{const W=++V;E=Math.max(E,W+1);let U=[];if(s.isCascade&&(y=[]),g.hasMoreData=!0,s.serverCallback){try{if(U=await s.serverCallback({search:K,offset:0}),Array.isArray(U)||(Se.error("ClSelect","onSearch 服务端返回数据格式异常(非数组):",typeof U),l("onError","服务端搜索失败:返回数据格式异常"),U=[]),W!==V)return;c&&r.convertListToJson(U)}catch(ae){Se.error("ClSelect","onSearch 服务端搜索失败:",ae),l("onError","服务端搜索失败,请稍后重试"),U=[]}if(W!==V)return;s.isCascade&&(U=C(U,s.originalData),U=S(U))}else{const ae=s.originalData.filter(G=>G!=null&&G.id!=null&&(typeof G.id=="string"||typeof G.id=="number"&&o.isFinite(G.id)));if(o.isEmpty(K))U=ae;else{s.searchKeyType!=="||"&&s.searchKeyType!=="&&"&&Se.warn("ClSelect","onSearch searchKeyType 未知值,已降级为 OR 匹配:",s.searchKeyType);const G=K.toLowerCase(),X=o.isArray(s.searchKey)?s.searchKey:["name"],ee=X.length;ae.forEach(F=>{const j=[];for(let le=0;le<ee;le++){const me=F[X[le]];if(me==null)continue;String(me).toLowerCase().indexOf(G)>-1&&j.push(!0)}if(j.length>0)switch(s.searchKeyType){case"||":U.push(F);break;case"&&":j.length===ee&&U.push(F);break;default:U.push(F)}})}s.isCascade&&(o.isEmpty(K)||(U=C(U,s.originalData)),U=S(U))}O.value=U.filter(ae=>ae!=null&&ae.id!=null&&(typeof ae.id=="string"||typeof ae.id=="number"&&o.isFinite(ae.id))),v(),x.value="",c&&r.calculationDropdownPosition()},Y=K=>{if(!s.disabled&&s.isMultiple){const W=[],U=[];w.value.forEach(X=>{K.value?o.isExistValue(s.selectId,X)||W.push(X):o.isExistValue(s.selectId,X)&&(M[X]?.isDisabled||U.push(X))});const ae=o.getArrClone(s.selectId);U.length>0&&U.forEach(X=>{const ee=ae.indexOf(X);ee>-1&&ae.splice(ee,1)}),W.length>0&&W.forEach(X=>{o.isExistValue(ae,X)||ae.push(X)});const G=[];ae.forEach(X=>{(!H(X)||o.isExistValue(s.selectId,X))&&G.push(X)}),l("onChange",G)}},Z=K=>{if(K.id==null||typeof K.id!="string"&&(typeof K.id!="number"||!o.isFinite(K.id))||K.isDisabled||s.disabled)return;const W=K.id.toString(),U=I(W);l("onChange",U)};return a({initOpenShow:K=>{K?D||(de.onListener(window,"keydown",_),de.onListener(window,"keyup",R),D=!0):D&&(de.offListener(window,"keydown",_),de.offListener(window,"keyup",R),D=!1)}}),(K,W)=>(e.openBlock(),e.createElementBlock("div",{class:"select-inDropdown-container",id:e.unref(B),ref_key:"refElRoot",ref:f},[n.isSearch?(e.openBlock(),e.createElementBlock("div",Wf,[e.createVNode(Qt,{ref_key:"refElSearch",ref:m,placeholder:n.searchPlaceholder,disabled:n.disabled,onOnChange:ue},null,8,["placeholder","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isMultiple&&n.isCheckBoxAll&&O.value.length>0?(e.openBlock(),e.createElementBlock("div",jf,[e.createVNode(dt,{forId:`${T}-cb-all`,label:e.unref(d).checkboxAll,value:q.value,disabled:n.disabled,onOnChange:Y},null,8,["forId","label","value","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),O.value.length>0?(e.openBlock(),e.createBlock(e.unref(t),{key:4,class:"select-inDropdown-body select-inDropdown-scroller",role:"listbox",style:e.normalizeStyle({height:Math.min(O.value.length*_o,eh)+"px"}),items:O.value,"item-size":_o,"key-field":"id",ref_key:"refElScroller",ref:p,onScrollEnd:Q},{default:e.withCtx(({item:U})=>[e.createElementVNode("div",{role:"option","aria-selected":N(U),"aria-disabled":U.isDisabled||!1,class:e.normalizeClass({"option-selected":N(U),"option-disabled":U.isDisabled,"option-hoverKeydown":x.value===U.id.toString(),"select-inDropdown-item-child":U._level>=1}),style:e.normalizeStyle({height:_o+"px",paddingLeft:U._level?U._level*th+"px":void 0}),onClick:ae=>Z(U)},[e.createElementVNode("div",qf,[n.isMultiple?(e.openBlock(),e.createElementBlock("div",Xf,[e.createVNode(dt,{name:`${T}-cb`,forId:`${T}-cb-${U.id}`,value:N(U),indeterminate:J(U),disabled:U.isDisabled},null,8,["name","forId","value","indeterminate","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",{class:"select-inDropdown-title",innerHTML:z(U)},null,8,Gf)])],14,Yf)]),_:1},8,["style","items"])):(e.openBlock(),e.createElementBlock("div",Qf,[e.createElementVNode("div",Zf,e.toDisplayString(e.unref(d).noResultsText),1)]))],8,Kf))}}),oh=["id"],ah={class:"select-inTag-title"},ih={class:"select-inTag-operate"},sh={class:"select-inTag-body"},lh=e.defineComponent({name:"ClSelectInTags",__name:"Tags",props:{id:String,showTextFormat:String,selectId:{type:Array,default:()=>[]}},emits:{onRemove:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,{optPageLanguage:l,getPageLanguage:d}=Le();d("common");const u=e.inject("$SelectTop",{}),r=typeof u.getSelectData=="function",c=e.computed(()=>r?o.isArray(i.selectId)?u.getSelectData(i.selectId):[]:[]),m=e.computed(()=>r?c.value.length:0),p=e.computed(()=>o.isArray(c.value)?c.value.some(g=>o.isObject(g)?!(o.isBoolean(g.isDisabled)&&g.isDisabled):!1):!1),f=()=>{const g=c.value;if(!o.isArray(g))return;const y=[];let V=!1;g.forEach(E=>{if(!o.isObject(E))return;(o.isBoolean(E.isDisabled)?!!E.isDisabled:!1)?(typeof E.id=="string"&&!o.isEmpty(E.id)||typeof E.id=="number"&&o.isFinite(E.id))&&y.push(E.id.toString()):V=!0}),V&&t("onRemove",y)},h=g=>{if(!o.isArray(i.selectId)||o.isEmpty(g))return;const y=String(g),V=i.selectId.findIndex(B=>String(B)===y);if(V===-1)return;const E=o.getArrClone(i.selectId);E.splice(V,1),t("onRemove",E)};return(g,y)=>(e.openBlock(),e.createElementBlock("div",{class:"select-inTag-container",id:e.unref(s)},[e.createElementVNode("div",ah,[e.createElementVNode("span",null,e.toDisplayString(e.unref(l).selected)+" "+e.toDisplayString(m.value)+" "+e.toDisplayString(e.unref(l).count),1),e.createElementVNode("span",ih,[p.value?(e.openBlock(),e.createBlock(ve,{key:0,class:"select-inTag-deleteAll",name:"remove",title:e.unref(l).deleteAll,"aria-label":e.unref(l).deleteAll,onClick:f},null,8,["title","aria-label"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])]),e.createElementVNode("div",sh,[e.createVNode(Zn,{showTextFormat:n.showTextFormat,list:c.value,onOnRemove:h},null,8,["showTextFormat","list"])])],8,oh))}}),rh=["id"],ch={key:0,class:"select-inText-num"},En=e.defineComponent({name:"ClSelect",__name:"Index",props:{id:String,value:[String,Number],className:String,disabled:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},placeholder:String,classDropDown:String,theme:{type:String,default:"default",validator:n=>["default","noBorder"].includes(n)},multiple:{type:Boolean,default:!1},isClear:{type:Boolean,default:!1},isSearch:{type:Boolean,default:!1},isCheckBoxAll:{type:Boolean,default:!0},isShowTag:{type:Boolean,default:!0},arrowDirection:{type:String,default:"right",validator:n=>["left","right"].includes(n)},transitionLeave:{type:String,default:"zoomOutTop"},searchPlaceholder:String,searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||",validator:n=>["||","&&"].includes(n)},showTextFormat:String,showDropDownTextFormat:String,multipleRealTimeChange:{type:Boolean,default:!1},isCascade:{type:Boolean,default:!1},parentSelectable:{type:Boolean,default:!1},parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"},showDropDownTextFormatSub:String,isOutMerge:{type:Boolean,default:!0},isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:","},plaintextLevelSeparator:{type:String,default:" > "},onOpenBefore:Function,serverCallback:Function,appendContainer:{type:String,default:""}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:(n,a)=>!0,onInit:()=>!0,onOpen:n=>!0,onError:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.useTemplateRef("refElDropdownLayer"),d=e.useTemplateRef("refElList"),u=e.useTemplateRef("refElTags"),r=`select-${o.getRandom(8)}`,c=t.id,m=e.reactive({isOpen:!1,dropDownPos:"down",tagHeight:"",tagLeft:"",tagDirection:"right"});let p=[],f={};const h={childrenMap:{},parentMap:{},lastChildMap:{},allChildMap:{}},g=e.ref(!1),y=e.ref([]),V=e.ref([]),E=e.ref([]);let B=!1;const T=e.computed(()=>o.isNonEmptyString(t.showTextFormat)?t.showTextFormat:t.isCascade?"${name}(${parentName})":""),D=e.computed(()=>{let A={"panel-select":!0};return t.theme==="noBorder"&&(A["select-theme-noBorder"]=!0),A=o.getJsonMerge(A,de.getClassNameJson(t.className)),o.getStringByJson(A," ")}),x=e.computed(()=>`${D.value} cl-plaintext-value`),O=e.computed(()=>{const A=o.isString(t.plaintextSeparator)?t.plaintextSeparator:",";return E.value.join(A)}),w=e.computed(()=>{let A={"select-inDropdown":!0};return t.theme==="noBorder"&&(A["select-inDropdown-noBorder"]=!0),m.isOpen&&t.multiple&&t.isShowTag&&(A["select-inTag-ext"]=!0,A[`select-inTag-${m.tagDirection}`]=!0),A=o.getJsonMerge(A,de.getClassNameJson(t.classDropDown)),o.getStringByJson(A," ")}),M=e.computed(()=>{const A={"select-inTag":!0,"select-inTag-open":m.isOpen};return A[`select-inTag-${m.dropDownPos}`]=!0,A[`select-inTag-${m.tagDirection}`]=!0,A}),b=A=>{s("update:value",A),s("update:modelValue",A)},N=(A,te)=>{b(A),s("onChange",A,te)},J=()=>{B||(B=!0,e.nextTick(()=>{s("onInit")}))},q=A=>{e.nextTick(()=>{s("onOpen",A)})},z=()=>{const A=[];return y.value.forEach(te=>{o.isExistJsonKey(f,te)&&A.push(te)}),A},H=A=>{if(o.isEmpty(A)||!o.isArray(A))return;const te={},ce=t.parentKey,pe=t.topParentValue;if(A.forEach(he=>{if(!o.isObject(he)){Se.warn("ClSelect","_convertListToJson 跳过非对象数据项:",he);return}if(!(typeof he.id=="string"||typeof he.id=="number"&&o.isFinite(he.id))){Se.warn("ClSelect","_convertListToJson 跳过无 id 或 id 类型异常的数据项:",he);return}const be=he.id.toString();te[be]=o.getJsonClone(he)}),f=o.getJsonMerge(f,te),t.serverCallback&&!g.value&&!o.isEmpty(te)&&(g.value=!0,t.value!=null&&t.value!==""&&(_(t.value),L())),t.isCascade&&Object.keys(f).forEach(he=>{const Ee=f[he][ce],be=Ee!=null&&(typeof Ee=="string"||typeof Ee=="number")?Ee.toString():"";if(be!==""&&be!==String(pe)){const xe=f[be];xe?.name&&(f[he].parentName=xe.name)}}),t.isCascade&&(v(),t.isOutMerge&&t.multiple&&y.value.length>0)){const he=k(y.value);o.isEqualArr(y.value,he)||(y.value=he,p=he)}if(t.multiple&&y.value.length>1){const he=y.value.filter(Ee=>{const be=f[Ee];return o.isBoolean(be?._isTypeRadio)&&be._isTypeRadio});if(he.length>1){const Ee=he[he.length-1],be=y.value.filter(xe=>xe===Ee||!he.includes(xe));o.isEqualArr(y.value,be)||(y.value=be,Y())}}y.value.length>0&&(y.value=[...y.value])},v=()=>{const A=t.parentKey,te=t.topParentValue;h.childrenMap={},h.parentMap={},h.lastChildMap={},h.allChildMap={},Object.keys(f).forEach(pe=>{const Ee=f[pe][A],be=Ee!=null&&(typeof Ee=="string"||typeof Ee=="number")?Ee.toString():"";be!==""&&be!==String(te)&&(h.parentMap[pe]=be,h.childrenMap[be]||(h.childrenMap[be]=[]),h.childrenMap[be].push(pe))})},S=A=>{const te=(ce,pe)=>{if(h.lastChildMap[ce])return h.lastChildMap[ce];if(pe.has(ce))return[];pe.add(ce);const he=h.childrenMap[ce];if(!he||he.length===0)return h.lastChildMap[ce]=[ce],[ce];const Ee=[];return he.forEach(be=>{Ee.push(...te(be,new Set(pe)))}),h.lastChildMap[ce]=Ee,Ee};return te(A,new Set)},C=A=>{const te=(ce,pe)=>{if(h.allChildMap[ce])return h.allChildMap[ce];if(pe.has(ce))return[];pe.add(ce);const he=h.childrenMap[ce];if(!he||he.length===0)return h.allChildMap[ce]=[],[];const Ee=[];he.forEach(xe=>{Ee.push(xe),Ee.push(...te(xe,new Set(pe)))});const be=Array.from(new Set(Ee));return h.allChildMap[ce]=be,be};return te(A,new Set)},$=A=>{if(A.length===0)return[];const te=new Set(A),ce=new Set,pe=new Set;for(const he of te){const Ee=h.parentMap[he];Ee&&!pe.has(Ee)&&ce.add(Ee)}for(;ce.size>0;){const he=ce.values().next().value;if(ce.delete(he),pe.has(he))continue;pe.add(he);const Ee=h.childrenMap[he];if(!Ee||Ee.length===0)continue;let be=!0;for(const xe of Ee)if(!te.has(xe)){be=!1;break}if(be){for(const De of Ee)te.delete(De);te.add(he);const xe=h.parentMap[he];xe&&!pe.has(xe)&&ce.add(xe)}}return[...te]},k=A=>{if(A.length===0)return[];const te=[];return A.forEach(ce=>{te.push(...S(ce))}),o.getArrUnique(te)},I=A=>!t.isCascade||!t.multiple?A:t.isOutMerge?$(A):k(A),L=()=>{if(g.value&&!o.isEmpty(y.value)){if(o.isEmpty(f)||t.serverCallback)return;const A=z();if(!o.isEqualArr(y.value,A)){const te=y.value.filter(pe=>!A.includes(pe));te.length>0&&Se.warn("ClSelect","以下 id 在数据列表中不存在,已自动清除:",te),y.value=A,p=A;const ce=I(A);b(ce.join(","))}}},_=A=>{if(A!=null&&typeof A!="string"&&(typeof A!="number"||!o.isFinite(A))){Se.warn("ClSelect","setValue 收到非预期类型值:",typeof A,A);return}let te=A==null||A===""?[]:A.toString().split(",").filter(pe=>pe!=="");te=o.getArrUnique(te),t.isCascade&&t.isOutMerge&&te.length>0&&t.multiple&&(te=k(te));let ce=o.isEqualArr(y.value,te);ce&&(ce=te.join(",")===y.value.join(",")),ce||(p=te,y.value=te)},R=A=>o.isExistJsonKey(f,A)?o.getJsonClone(f[A]):{},P=A=>{const te=o.isArray(A)?A:y.value,ce=[];return te.forEach(pe=>{const he=R(pe);o.isEmpty(he)||ce.push(he)}),ce},Q=A=>{const ce=t.isCascade&&!t.multiple&&(h.childrenMap[A.id?.toString()]?.length>0||!h.parentMap[A.id?.toString()])&&o.isEmpty(t.showTextFormat)?"":T.value;let pe=o.isEmpty(ce)?A.name??"":o.convertStringFormat(ce,A);return o.isHtml(pe)?pe=o.isEmpty(ce)?o.encodeHTML(A.name):o.convertStringFormatEncodeHTML(ce,A):typeof pe=="string"&&pe.indexOf("<")>-1&&(pe=o.encodeHTML(pe)),pe},oe=A=>{if(o.isNonEmptyString(t.showTextFormat))return o.removeHTMLTags(Q(A));const te=o.isString(t.plaintextLevelSeparator)?t.plaintextLevelSeparator:" > ",ce=o.isString(A?.name)?A.name:"",pe=o.isString(A?.parentName)?A.parentName:"",he=t.isCascade&&o.isNonEmptyString(pe)?`${pe}${te}${ce}`:ce;return o.removeHTMLTags(he)},ue=()=>{const A=P();V.value=A.map(te=>Q(te)),E.value=A.map(te=>oe(te))},Y=()=>{const A=z();p=A,y.value=A;const te=I(A),ce=te.join(",");let pe;if(t.multiple){const he=[];te.forEach(Ee=>{const be=R(Ee);o.isEmpty(be)||he.push(be)}),pe=he}else pe=R(ce),o.isEmpty(pe)&&(pe=null);N(ce,pe)},Z=()=>{m.isOpen||!o.isEqualArr(y.value,p)&&Y()},se=()=>{g.value||(g.value=!0,H(t.list),_(t.value),L())},K=()=>{!g.value&&t.list&&t.list.length>0&&se()},W=()=>{import("vue-virtual-scroller").then(()=>{Promise.resolve().then(()=>require("./vue-virtual-scroller-Dyvby5gX.cjs"))})};e.onMounted(()=>{t.isPlaintext||W(),e.nextTick(()=>{K()})}),e.watch(g,A=>{A&&J()}),e.watch(()=>t.list,(A,te)=>{g.value||(A&&A.length>0||te===void 0)&&(g.value=!0)}),e.watch([()=>t.value,()=>t.list],([A,te],[ce,pe])=>{const he=te||[];!g.value&&he.length>0&&(g.value=!0),te!==pe&&(f={},h.childrenMap={},h.parentMap={},h.lastChildMap={},h.allChildMap={}),H(he),A!==void 0&&_(A),L()}),e.watch([y,()=>t.list],([A,te])=>{te&&te.length>0&&o.isEmpty(f)&&H(te),ue()}),e.watch(()=>t.isOutMerge,()=>{t.isCascade&&t.multiple&&y.value.length>0&&I(z()).join(",")!==String(t.value??"")&&Y()}),e.watch([()=>t.parentKey,()=>t.topParentValue],()=>{t.isCascade&&!o.isEmpty(f)&&v()});const U=A=>{A&&t.disabled||(m.isOpen=A,A?p=y.value:Z(),e.nextTick(()=>{d.value&&d.value.initOpenShow(A)}),q(A))},ae=()=>{t.disabled||(y.value=[],t.multiple&&t.multipleRealTimeChange?Y():Z())},G=A=>{if(m.dropDownPos=A.use.dropDownPos,t.multiple&&t.isShowTag){const te=u.value?.$el?.offsetWidth||0;m.tagHeight=t.theme==="default"?`${A.original.dropDownHeight+1}px`:`${A.original.dropDownHeight}px`;const ce=A.original.winWidth-(A.original.controlOffset.left+A.original.dropDownWidth)>=te?"right":"left";m.tagDirection=ce,ce==="right"?m.tagLeft=`${A.original.dropDownWidth-1}px`:m.tagLeft=`${(A.original.dropDownWidth-A.original.textWidth+te+1)*-1}px`}},X=A=>{y.value=A,t.multiple?t.multipleRealTimeChange&&Y():l.value?.setOpen(!1)},ee=A=>{t.disabled||(y.value=A,Y())},F=A=>{s("onError",A)},j=()=>{l.value&&(l.value.checkIsShowOpen()||l.value.initCompleteOpen())};e.provide("$SelectTop",{getSelectData:P,getSelectValueInfo:R,getAllChildIds:C,calculationDropdownPosition:()=>{l.value?.calculationPosition()},convertListToJson:H,closeDropdown:()=>{l.value?.setOpen(!1)},refreshDisplayLabels:()=>{ue()}});const le=()=>{const A=z();return I(A).join(",")};return a({getValue:le,getValueData:()=>{const A=le();if(t.multiple){const ce=A?A.split(","):[],pe=[];return ce.forEach(he=>{const Ee=R(he);o.isEmpty(Ee)||pe.push(Ee)}),pe}if(!A)return null;const te=R(A);return o.isEmpty(te)?null:te},setValue:A=>{_(A),L()},runInitComplete:()=>{se()}}),(A,te)=>n.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(c),class:e.normalizeClass(x.value)},e.toDisplayString(O.value),11,rh)):(e.openBlock(),e.createBlock(wn,{key:1,id:e.unref(c),ref_key:"refElDropdownLayer",ref:l,classParent:D.value,classText:"select-inText",classDropDown:w.value,placeholder:n.placeholder,isDisabled:n.disabled,isClear:n.isClear,textLabel:V.value.join(","),textArrowDirection:n.arrowDirection,transitionLeave:n.transitionLeave,appendContainer:n.appendContainer,appendFollowWidth:n.theme!=="noBorder",onOpenBeforeCallback:n.onOpenBefore,onOnChangeOpen:U,onOnClear:ae,onOnChangePosition:G},{textExtend:e.withCtx(()=>[n.multiple?(e.openBlock(),e.createElementBlock("span",ch,[V.value.length>1?(e.openBlock(),e.createBlock(Gt,{key:0,num:V.value.length},null,8,["num"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),dropdown:e.withCtx(()=>[e.createVNode(nh,{ref_key:"refElList",ref:d,isSearch:n.isSearch,searchPlaceholder:n.searchPlaceholder,searchKey:n.searchKey,searchKeyType:n.searchKeyType,isMultiple:n.multiple,isCheckBoxAll:n.isCheckBoxAll,showDropDownTextFormat:n.showDropDownTextFormat,showDropDownTextFormatSub:n.showDropDownTextFormatSub,isCascade:n.isCascade,parentSelectable:n.parentSelectable,parentKey:n.parentKey,topParentValue:n.topParentValue,originalData:n.list,keyIndex:r,selectId:y.value,disabled:n.disabled,isOpen:m.isOpen,serverCallback:n.serverCallback,onOnChange:X,onOnInitComplete:j,onOnError:F},null,8,["isSearch","searchPlaceholder","searchKey","searchKeyType","isMultiple","isCheckBoxAll","showDropDownTextFormat","showDropDownTextFormatSub","isCascade","parentSelectable","parentKey","topParentValue","originalData","selectId","disabled","isOpen","serverCallback"])]),dropdownExtend:e.withCtx(()=>[n.multiple&&n.isShowTag?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(M.value),style:e.normalizeStyle({height:m.tagHeight,left:m.tagLeft}),ref_key:"refElTags",ref:u},[e.createVNode(lh,{showTextFormat:T.value,selectId:y.value,onOnRemove:ee},null,8,["showTextFormat","selectId"])],6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),_:1},8,["id","classParent","classDropDown","placeholder","isDisabled","isClear","textLabel","textArrowDirection","transitionLeave","appendContainer","appendFollowWidth","onOpenBeforeCallback"]))}}),uh=["id"],dh={class:"paginate-statistic"},mh={class:"paginate-list"},ph={class:"pagination",role:"navigation","aria-label":"pagination"},fh=["tabindex","aria-label","onClick","onKeydown"],hh={key:0},gh={key:1},yh={key:0,class:"paginate-limit"},vh={key:2,class:"paginate-jump"},Mo=10,ma=e.defineComponent({name:"ClPaginate",__name:"Index",props:{id:String,className:String,disabled:{type:Boolean,default:!1},isShowLimit:{type:Boolean,default:!0},limitValue:{type:Number,default:10},limitData:Array,isShowJump:{type:Boolean,default:!0},totalCount:{type:Number,default:0},currentPage:{type:Number,default:1}},emits:["onChange"],setup(n,{emit:a}){const i=n,t=a,{optPageLanguage:s,getPageLanguage:l}=Le();l("paginate");const d=`paginate-${o.getRandom(5)}`,u=i.id,r=e.ref(""),c=e.ref(""),m=e.ref(-1),p=e.ref(-1),f=e.computed(()=>{let w={"panel-paginate":!0,"paginate-disabled":i.disabled};return w=o.getJsonMerge(w,de.getClassNameJson(i.className)),w}),h=e.computed(()=>Math.max(1,parseInt(r.value)||Mo)),g=e.computed(()=>{const w=o.isFinite(i.currentPage)?i.currentPage:1,M=i.totalCount>0?Math.ceil(i.totalCount/h.value):0;return M>0?Math.min(Math.max(1,w),M):w}),y=e.computed(()=>{const w=i.limitData;if(o.isArray(w)&&!o.isEmpty(w)){const N=o.getListClone(w).filter(J=>!o.isEmpty(J)&&!o.isEmpty(J.id));if(N.length>0)return N}const M=s.value.pageStrip,b=o.isNonEmptyString(M)?M:"";return[{id:10,name:`10${b}`},{id:20,name:`20${b}`},{id:30,name:`30${b}`},{id:50,name:`50${b}`},{id:100,name:`100${b}`}]}),V=e.computed(()=>{const w=h.value,M=g.value,b=i.totalCount;let N=(M-1)*w,J=M*w;b>0?(N=N+1,J=J>b?b:J,N>J&&(N=J)):(N=0,J=0);const q=s.value.statistic;return o.isNonEmptyString(q)?o.convertStringFormat(q,{s:N,e:J,_total:b}):""}),E=e.computed(()=>{let w=!1,M=!1,b=!1,N=!1,J=0;const q=h.value,z=i.totalCount;z>0&&(J=Math.ceil(z/q));const H=g.value;w=J>0?H===1:!0,M=w,b=J>0?H===J:!0,N=b;const v=[];if(v.push({icon:"angle-double-left",ariaLabel:"first page",active:!1,disabled:w,page:1}),v.push({icon:"angle-left",ariaLabel:"previous page",active:!1,disabled:M,page:w?1:H-1}),J>0){let $=[];if(J>7){const _=J-5+1+1;H<=4?($=o.getArrByMinMax(1,5),$.push("…"),$.push(J)):H>=_?($=o.getArrByMinMax(_-1,J),$.unshift("…"),$.unshift(1)):($=o.getArrByMinMax(H-1,H+1),$.unshift("…"),$.unshift(1),$.push("…"),$.push(J))}else $=o.getArrByMinMax(1,J);$.forEach(I=>{v.push({title:I,active:I===H,isOmit:I==="…",page:I})})}return v.push({icon:"angle-right",ariaLabel:"next page",active:!1,disabled:N,page:b?J:H+1}),v.push({icon:"angle-double-right",ariaLabel:"last page",active:!1,disabled:b,page:J}),v}),B=(w,M)=>{const b=parseInt(String(w)),N=parseInt(String(M));o.isFinite(b)&&o.isFinite(N)&&(b!==m.value||N!==p.value)&&(m.value=b,p.value=N,t("onChange",b,N))},T=()=>{const w=!o.isEmpty(i.limitValue)&&o.isFinite(i.limitValue)?i.limitValue:Mo;let b=(w>0?w:Mo).toString();if(i.isShowLimit){const N=y.value.map(J=>J.id.toString());N.includes(b)||(b=N[0])}return b};r.value=T(),e.watch(()=>i.limitValue,()=>{const w=T();if(w!==r.value){r.value=w;const M=g.value;M!==i.currentPage&&B(M,w)}}),e.watch(()=>i.limitData,()=>{const w=T();w!==r.value&&(r.value=w,B(g.value,w))}),e.watch(()=>i.currentPage,()=>{m.value=-1,p.value=-1}),e.watch(()=>i.totalCount,()=>{const w=g.value;w!==i.currentPage&&B(w,r.value)});const D=w=>{!i.disabled&&!w.active&&!w.disabled&&!w.isOmit&&(c.value="",B(w.page,r.value))},x=w=>{if(i.disabled)return;y.value.some(b=>b.id.toString()===w)&&(c.value="",r.value=w,B(1,w))},O=w=>{if(i.disabled||!o.isNonEmptyString(w))return;const M=parseInt(w);if(o.isFinite(M)){const b=i.totalCount>0?Math.ceil(i.totalCount/h.value):0;if(M>=1&&(b===0||M<=b)){c.value="",B(M,r.value);return}}c.value=""};return(w,M)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(u),class:e.normalizeClass(f.value)},[e.createElementVNode("div",dh,e.toDisplayString(V.value),1),e.createElementVNode("div",mh,[e.createElementVNode("ul",ph,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(E.value,(b,N)=>(e.openBlock(),e.createElementBlock("li",{key:`${d}-${N}`,class:e.normalizeClass({"paginate-disabled":b.disabled||n.disabled,"paginate-active":b.active,"paginate-omit":b.isOmit}),tabindex:b.disabled||n.disabled?-1:0,role:"button","aria-label":b.ariaLabel||String(b.page),onClick:J=>D(b),onKeydown:[e.withKeys(J=>D(b),["enter"]),e.withKeys(e.withModifiers(J=>D(b),["prevent"]),["space"])]},[b.icon?(e.openBlock(),e.createElementBlock("span",hh,[e.createVNode(ve,{name:b.icon},null,8,["name"])])):(e.openBlock(),e.createElementBlock("span",gh,e.toDisplayString(b.title),1))],42,fh))),128))])]),n.isShowLimit?(e.openBlock(),e.createElementBlock("div",yh,[e.createVNode(En,{list:y.value,value:r.value,disabled:n.disabled,transitionLeave:"dropdownLayer-close-no-anim",onOnChange:x},null,8,["list","value","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isShowJump?(e.openBlock(),e.createElementBlock("div",vh,[e.createElementVNode("span",null,e.toDisplayString(e.unref(s).jumpTo),1),e.createVNode(Pe,{value:c.value,"onUpdate:value":M[0]||(M[0]=b=>c.value=b),disabled:n.disabled,onOnKeyupEnter:O,onOnChangeBlur:O,onOnClear:O},null,8,["value","disabled"]),e.createElementVNode("span",null,e.toDisplayString(e.unref(s).page),1)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],10,uh))}}),kh=["id"],Sh={key:0,class:"portlet-head"},wh={class:"portlet-title"},Eh={class:"portlet-body"},ps=e.defineComponent({name:"ClPortlet",__name:"Index",props:{id:String,className:{type:String,default:""},titleName:String,isShowHead:{type:Boolean,default:!0}},setup(n){const a=n,i=a.id,t=e.computed(()=>{const s={"panel-portlet":!0};return o.getJsonMerge(s,de.getClassNameJson(a.className))});return(s,l)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(i),class:e.normalizeClass(t.value)},[n.isShowHead?(e.openBlock(),e.createElementBlock("div",Sh,[e.createElementVNode("h3",wh,[e.createTextVNode(e.toDisplayString(n.titleName),1),e.renderSlot(s.$slots,"titleExtend")])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",Eh,[e.renderSlot(s.$slots,"default")])],10,kh))}}),bh=["id"],Ch={key:6,class:"fenceScrollX-cover"},gn=e.defineComponent({name:"ClScrollXFence",__name:"Index",props:{id:String,className:String,isShowLeft:{type:Boolean,default:!0},isShowRight:{type:Boolean,default:!0},isShowCorner:{type:Boolean,default:!1},isShowCover:{type:Boolean,default:!1},cornerType:{type:String,default:""},leftWidth:{type:String,default:"0"},centerWidth:{type:String,default:"0"},rightWidth:{type:String,default:"0"},initLeft:String},emits:["onScrollX"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElScrollX"),u=e.computed(()=>{let p={"panel-scroll-x-fence":!0};return t.isShowCorner&&o.isNonEmptyString(t.cornerType)&&(p[`fenceScrollX-showCorner-${t.cornerType}`]=!0),o.osType().isMobile&&(p["fenceScrollX-mob"]=!0),p=o.getJsonMerge(p,de.getClassNameJson(t.className)),p}),r=e.computed(()=>{const p={"fenceScrollX-corner":!0};return o.isNonEmptyString(t.cornerType)&&(p[`fenceScrollX-corner-${t.cornerType}`]=!0),p}),c=p=>{s("onScrollX",p)};return e.onMounted(()=>{e.nextTick(()=>{if(d.value){if(o.isNonEmptyString(t.initLeft)){const p=parseInt(t.initLeft,10);o.isFinite(p)&&(d.value.scrollLeft=p)}d.value.addEventListener("scroll",c)}})}),e.onBeforeUnmount(()=>{d.value&&d.value.removeEventListener("scroll",c)}),e.onActivated(()=>{d.value&&d.value.addEventListener("scroll",c)}),e.onDeactivated(()=>{d.value&&d.value.removeEventListener("scroll",c)}),a({setScrollLeft:p=>{d.value&&o.isFinite(p)&&(d.value.scrollLeft=p)}}),(p,f)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(u.value)},[n.isShowLeft?(e.openBlock(),e.createElementBlock("div",{key:0,class:"fenceScrollX-left",style:e.normalizeStyle({width:n.leftWidth})},[...f[0]||(f[0]=[e.createElementVNode("div",null,null,-1)])],4)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",{class:"fenceScrollX-center",ref_key:"refElScrollX",ref:d},[e.createElementVNode("div",{style:e.normalizeStyle({width:n.centerWidth})},null,4)],512),n.isShowRight?(e.openBlock(),e.createElementBlock("div",{key:2,class:"fenceScrollX-right",style:e.normalizeStyle({width:n.rightWidth})},[...f[1]||(f[1]=[e.createElementVNode("div",null,null,-1)])],4)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),n.isShowCorner?(e.openBlock(),e.createElementBlock("div",{key:4,class:e.normalizeClass(r.value)},null,2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64)),n.isShowCover?(e.openBlock(),e.createElementBlock("div",Ch)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:7},[],64))],10,bh))}}),xh=["id"],Bh=["id"],pa=e.defineComponent({name:"ClSelectCascade",__name:"Index",props:{id:String,value:[String,Number],className:{type:String,default:""},disabled:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},placeholder:String,isClear:{type:Boolean,default:!1},isSearch:{type:Boolean,default:!1},parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"},width:String,isCheckValidate:{type:Boolean,default:!1},validateRules:{type:Array,default:()=>[{r:"required"}]},isShowInMsg:{type:Boolean,default:!0},isPlaintext:{type:Boolean,default:!1},plaintextLevelSeparator:{type:String,default:" > "}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("common");const u=`selectCascade-${o.getRandom(5)}`,r=t.id,c=e.reactive({lastValue:t.value,isFirstDataFinish:!1}),m=e.ref([]),p={dataJson:{},dataGroup:{},parentIdsJson:{}},f=e.ref(0),h=e.computed(()=>l.value.pleaseSelect),g=e.computed(()=>{const{placeholder:k}=t;return o.isNonEmptyString(k)?k.split("|"):[]}),y=e.computed(()=>{const{width:k}=t;return o.isNonEmptyString(k)?k.split("|"):[]}),V=e.computed(()=>{let k={"panel-select-cascade":!0};return k=o.getJsonMerge(k,de.getClassNameJson(t.className)),k}),E=k=>{k!==c.lastValue&&(c.lastValue=k,s("update:value",k),s("update:modelValue",k),s("onChange",k))},B=k=>o.isExistJsonKey(p.dataGroup,k),T=k=>B(k)?p.dataGroup[k]:[],D=k=>o.isExistJsonKey(p.dataJson,k)?p.dataJson[k]:null,x=()=>`top_${t.topParentValue}`,O=k=>{const{parentKey:I,topParentValue:L}=t,_={},R={};o.isEmpty(k)||k.forEach(P=>{const Q=o.getJsonClone(P);if(!o.isExistJsonKey(Q,"id")||!o.isExistJsonKey(Q,I))return;const oe=Q.id.toString(),ue=Q[I].toString();_[oe]=Q;const Y=ue===L.toString()?x():ue;o.isExistJsonKey(R,Y)||(R[Y]=[]),R[Y].push(Q)}),p.dataJson=_,p.dataGroup=R,f.value+=1},w=(k,I)=>{const L={idx:k,pId:I,placeholder:h.value,list:[],sty:{},selected:""};if(!o.isEmpty(I)){const Q=T(I);L.list=o.getListClone(Q)}const _=g.value,R=_.length;R>0&&(R>k?L.placeholder=o.isEmpty(_[k])?h.value:_[k]:R===1&&(L.placeholder=_[0]));const P=y.value;return P.length>k&&(o.isEmpty(P[k])||(L.sty.width=P[k],L.sty.flex="none")),L},M=(k,I)=>{const{parentKey:L,topParentValue:_}=t;let R=[];if(I&&I.indexOf(k)>-1)return[];const P=I?I.concat([k]):[k];if(o.isExistJsonKey(p.parentIdsJson,k))R=p.parentIdsJson[k];else{const Q=D(k);if(Q!=null){const oe=Q[L].toString();if(oe!==_.toString()){const ue=D(oe);if(ue!=null){R.push(oe);const Y=M(oe,P);Y.length>0&&(R=R.concat(Y))}}}p.parentIdsJson[k]=R}return R},b=k=>{let I=o.isUndefined(k)?t.value:k;I!=null&&!o.isEmpty(I)&&!o.isExistJsonKey(p.dataJson,I.toString())&&(I="");const L=[];if(I==null||o.isEmpty(I))L.push(w(0,x())),L.push(w(1,""));else{const _=I.toString(),R=[...M(_)].reverse(),P=R.length;if(P>0){R.forEach((oe,ue)=>{const Y=ue===0?x():R[ue-1],Z=w(ue,Y);Z.selected=oe,L.push(Z)});const Q=w(P,R[P-1]);Q.selected=_,L.push(Q)}else{const Q=w(0,x());Q.selected=_,L.push(Q)}}m.value=L},N=()=>{O(t.list),b(),c.isFirstDataFinish=!0,c.lastValue=t.value};e.onMounted(()=>{e.nextTick(()=>{N()})}),e.watch(()=>t.value,k=>{k!==c.lastValue&&c.isFirstDataFinish&&(b(),c.lastValue=k)}),e.watch(()=>t.list,k=>{if(!c.isFirstDataFinish){c.isFirstDataFinish=!0;return}p.parentIdsJson={},O(k);const{value:I}=t,L=I!=null&&!o.isEmpty(I)&&o.isExistJsonKey(p.dataJson,I.toString())?I:"";b(L),c.lastValue=L});const J=()=>!0,q=(k,I)=>{let L="";if(o.isEmpty(k)&&I===0)b("");else if(o.isEmpty(k)){if(m.value.splice(I+1),I>0){const _=m.value[I-1];_&&(L=_.selected)}}else{const _=k.toString();B(_)?(m.value.splice(I+1),m.value.push(w(I+1,_))):(L=k,m.value.splice(I+1))}E(L)},z=()=>c.lastValue,H=k=>{const I=M(k),L=I.length>0?I.slice().reverse().concat([k]):[k],_=[];return L.forEach(R=>{const P=p.dataJson[R];P!=null&&!o.isEmpty(P.name)&&_.push(P.name)}),_},v=()=>{const k=c.lastValue;let I="";return k!=null&&!o.isEmpty(k)&&(I=H(k.toString()).join(" → ")),{value:k,show:I||(k!=null?k.toString():"")}},S=k=>{const I=[],L=new Set;let _=k;for(;o.isNonEmptyString(_)&&!L.has(_);){L.add(_);const R=D(_);if(R==null)break;o.isNonEmptyString(R.name)&&I.unshift(R.name);const P=R[t.parentKey],Q=P!=null?String(P):"";if(Q===""||Q===String(t.topParentValue))break;_=Q}return I},C=e.computed(()=>{t.list,f.value;const k=c.lastValue;if(k==null||o.isEmpty(k))return"";const I=o.isString(t.plaintextLevelSeparator)?t.plaintextLevelSeparator:" > ",L=S(k.toString());return L.length>0?L.join(I):k.toString()});return a({getValue:z,getValueData:v,setValue:k=>{b(k),c.lastValue=k}}),(k,I)=>n.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(r),class:"cl-plaintext-value"},e.toDisplayString(C.value),9,xh)):(e.openBlock(),e.createElementBlock("div",{key:1,id:e.unref(r),class:e.normalizeClass(V.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(m.value,(L,_)=>(e.openBlock(),e.createElementBlock("div",{key:`${u}-${_}`,class:"selectCascade-item",style:e.normalizeStyle(L.sty)},[e.createVNode(Gn,{isShowMsg:n.isShowInMsg,isCheck:n.isCheckValidate,checkValue:L.selected,rules:n.validateRules},{default:e.withCtx(()=>[e.createVNode(En,{isClear:n.isClear,isSearch:n.isSearch,placeholder:L.placeholder,list:L.list,disabled:n.disabled,value:L.selected,"onUpdate:value":R=>L.selected=R,onOpenBefore:J,onOnChange:R=>q(R,_)},null,8,["isClear","isSearch","placeholder","list","disabled","value","onUpdate:value","onOnChange"])]),_:2},1032,["isShowMsg","isCheck","checkValue","rules"])],4))),128))],10,Bh))}}),Dh=["onClick"],Ih=["innerHTML"],Th=e.defineComponent({name:"ClSelectMoveSearchUl",__name:"SearchTree",props:{list:{type:Array,default:()=>[]}},emits:{onClick:n=>!0},setup(n,{emit:a}){const i=a,t=`selectmove-search-tree-${o.getRandom(5)}`,s=l=>{o.isUndefined(l)||i("onClick",l.toString())};return(l,d)=>{const u=e.resolveComponent("cl-select-move-search-ul");return e.openBlock(),e.createElementBlock("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.list,(r,c)=>(e.openBlock(),e.createElementBlock("li",{key:`${t}-${r.id}-${c}`},[e.createElementVNode("a",{href:"javascript:",tabindex:"-1",class:e.normalizeClass({"tree-hig":r.isHig,"tree-active":r.isSelected}),onClick:e.withModifiers(m=>s(r.id),["stop"])},[e.createVNode(dt,{value:r.isSelected,indeterminate:r.isIndeterminate},null,8,["value","indeterminate"]),e.createElementVNode("span",{class:"tree-text",innerHTML:r.showTextLabel},null,8,Ih)],10,Dh),r.list&&r.list.length>0?(e.openBlock(),e.createBlock(u,{key:0,list:r.list,onOnClick:s},null,8,["list"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]))),128))])}}}),Nh={class:"selectmove-search-list"},Vh={key:1},_h={class:"selectmove-search-empty"},Mh=1e3,Oh=e.defineComponent({name:"ClSelectMoveSearch",__name:"Search",props:{disabled:Boolean,placeholder:String,width:Number,searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||"},searchIsMultiple:{type:Boolean,default:!1},searchMultipleJoin:{type:String,default:","},searchTextFormat:[String,Array],selectId:{type:Array,default:()=>[]},parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"}},emits:{onChange:n=>!0},setup(n,{emit:a}){const i=n,t=a,{optPageLanguage:s,getPageLanguage:l}=Le();l("common");const d=e.inject("$SelectmoveTop"),u=e.inject("$SelectmoveBase");if(o.isUndefined(d)||o.isUndefined(u))throw new Error("SelectMove.Search 缺少容器依赖($SelectmoveTop/$SelectmoveBase),请确保在 ClSelectMove 内使用");const r=e.reactive({isOpen:!1,isInitSelect:!1}),c=e.ref([]),m=e.ref([]);let p="",f=[];const h={jsonSelectIds:{},jsonSelectHalfIds:{}},g=e.computed(()=>({"selectmove-search-input":!0,"selectmove-search-open":r.isOpen})),y=e.computed(()=>({"selectmove-search-dropdown":!0,"selectmove-search-open":r.isOpen})),V=e.computed(()=>{const H={};return i.width&&i.width>0&&(H.width=`${i.width}px`),H}),E=()=>{t("onChange",m.value.join(","))},B=()=>{r.isOpen=!1,c.value=[]},T=H=>{const v=u.convertSelectHalf(H);m.value=H,h.jsonSelectHalfIds=o.getArrConvertJson(v),h.jsonSelectIds=o.getArrConvertJson(H)},D=H=>{const v=H.toLowerCase().trim();if(v===p)return f;const S=[];if(o.isEmpty(i.searchKey))return Se.warn("ClSelectMoveSearch","SelectMove.Search searchKey 为空,搜索将无结果"),p=v,f=S,S;const C=o.isNonEmptyString(i.searchMultipleJoin)?i.searchMultipleJoin:",",$=i.searchIsMultiple?v.split(C).map(_=>_.trim()):[v],k=i.searchKey.length,I=i.searchKey,L=d.getDataList();return o.isArray(L)?(L.forEach(_=>{if(o.isUndefined(_)||o.isUndefined(_.id)||!o.isString(_.id)&&!o.isNumber(_.id))return;const R=_.id.toString(),P=[];let Q=0;for(let oe=0;oe<k;oe++){const ue=_[I[oe]];if(!o.isString(ue)){Q++;continue}const Y=ue.toLowerCase();let Z=!1;for(let se=0;se<$.length;se++)if($[se].length>0&&Y.indexOf($[se])>-1){Z=!0;break}Z&&P.push(!0)}if(P.length>0)switch(i.searchKeyType){case"||":S.push(R);break;case"&&":P.length===k-Q&&S.push(R);break;default:Se.warn("ClSelectMoveSearch",`SelectMove.Search searchKeyType 未知值「${i.searchKeyType}」,按 || 兜底`),S.push(R);break}}),p=v,f=S,S):(p=v,f=S,S)},x=(H,v,S,C,$)=>{const k=[],I=$||[];return o.isExistJsonKey(v,H)&&v[H].forEach(L=>{if(I.indexOf(L)>-1)return;const _=I.concat([L]),R=o.getJsonClone(d.getDataInfo(L));if(o.isEmpty(R))return;let P=o.isNonEmptyString(R.name)?o.encodeHTML(R.name):"";const Q=i.searchTextFormat;if(Q&&Q.length>0){let Y="";o.isArray(Q)?Q.length>S&&(Y=Q[S]):o.isString(Q)&&(Y=Q),o.isEmpty(Y)||(P=o.convertStringFormatEncodeHTML(Y,R))}R.showTextLabel=P;let oe=!1,ue=o.isExistJsonKey(v,L);ue?R.list=x(L,v,S+1,C,_):(oe=!0,R.list=[],d.getDataGroup(L).length>0&&(ue=!0,oe=!1)),R.isIndeterminate=o.isExistJsonKey(h.jsonSelectHalfIds,L),R.isSelected=o.isExistJsonKey(h.jsonSelectIds,L),R.isChild=ue,R.isLast=oe,R.treeLevel=S,R.isHig=o.isExistJsonKey(C,L),k.push(R)}),k},O=H=>{if(H.length===0)return[];const{parentKey:v,topParentValue:S}=i,C={};let $=[];H.forEach(L=>{C[L]=!0;const _=u.getParentIds(L);$.push(..._),$.push(L)}),$=o.getArrUnique($);const k={};$.forEach(L=>{const _=d.getDataInfo(L);if(o.isUndefined(_))return;const R=_[v],P=o.isEmpty(R)?S:R.toString(),Q=P===S?d.getTopParentValue():P;o.isExistJsonKey(k,Q)||(k[Q]=[]),k[Q].push(L)});const I=d.getTopParentValue();return o.isExistJsonKey(k,I)||Se.warn("ClSelectMoveSearch","SelectMove.Search 数据存在环或祖先链断裂,搜索结果可能为空"),x(I,k,0,C)},w=()=>{if(r.isInitSelect=!1,!o.isEqualArr(i.selectId,m.value)){const v=u.convertSelectedValue(i.selectId,!0,[]);T(v)}},M=H=>{if(o.isNonEmptyString(H)){r.isInitSelect&&w();const v=D(H),S=O(v);c.value=S,r.isOpen=!0}else B()},b=H=>{const v=[];return H.forEach(S=>{const C=o.getJsonClone(S);if(o.isUndefined(C)||o.isUndefined(C.id))return;const $=C.id.toString();C.isIndeterminate=o.isExistJsonKey(h.jsonSelectHalfIds,$),C.isSelected=o.isExistJsonKey(h.jsonSelectIds,$),C.list&&C.list.length>0&&(C.list=b(C.list)),v.push(C)}),v},N=H=>{if(r.isOpen){const v=de.getParent(H.target,".selectmove-search");o.isUndefined(v)&&(r.isOpen=!1)}};e.onUnmounted(()=>{document.body.removeEventListener("click",N)}),e.watch(()=>r.isOpen,H=>{H?document.body.addEventListener("click",N):document.body.removeEventListener("click",N)}),e.watch(()=>i.selectId,()=>{r.isInitSelect=!0,r.isOpen&&(w(),c.value=b(c.value))},{immediate:!0}),e.watch(()=>[i.searchKey,i.searchKeyType,i.searchIsMultiple,i.searchMultipleJoin],()=>{p="",f=[]});const J=H=>{M(H)},q=H=>{r.isOpen||M(H)},z=H=>{const v=o.isExistJsonKey(h.jsonSelectIds,H),S=u.convertSelectedValue(H,!v,m.value);T(S),c.value=b(c.value),E()};return(H,v)=>(e.openBlock(),e.createElementBlock("div",{class:"selectmove-search",style:e.normalizeStyle(V.value)},[e.createElementVNode("div",{class:e.normalizeClass(g.value)},[e.createVNode(Qt,{placeholder:n.placeholder,disabled:n.disabled,changeDelayTime:Mh,onOnChange:J,onOnFocus:q},null,8,["placeholder","disabled"])],2),r.isOpen?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(y.value)},[e.createElementVNode("div",Nh,[c.value.length>0?(e.openBlock(),e.createBlock(Th,{key:0,list:c.value,onOnClick:z},null,8,["list"])):(e.openBlock(),e.createElementBlock("ul",Vh,[e.createElementVNode("li",_h,e.toDisplayString(e.unref(s).noResultsText),1)]))])],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],4))}}),Ah={class:"selectmove-tree"},Lh={class:"selectmove-tree-head"},$h={class:"selectmove-tree-head-title"},Fh={class:"selectmove-tree-body"},Ph=["onClick"],Rh=["innerHTML"],ti=10,Hh=e.defineComponent({name:"ClSelectMoveTree",__name:"Tree",props:{disabled:Boolean,maxWidth:Number,width:Number,treeTitle:{type:Array,default:()=>[]},treeShowMinLevel:{type:Number,default:1},treeTextFormat:[String,Array],selectId:{type:Array,default:()=>[]},dataRefreshIndex:Number},emits:{onChange:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=e.inject("$SelectmoveTop"),l=e.inject("$SelectmoveBase");if(o.isUndefined(s)||o.isUndefined(l))throw new Error("SelectMove.Tree 缺少容器依赖($SelectmoveTop/$SelectmoveBase),请确保在 ClSelectMove 内使用");const d=`selectmove-tree-${o.getRandom(5)}`,u=e.reactive({selectIds:[],HalfSelectIds:[],openActiveId:[]}),r=e.ref([]),c=()=>{t("onChange",u.selectIds.join(","))},m=w=>{let M=0;const b=s.getDataGroup(w);if(b.length>0){const N=[],J=[];b.forEach(q=>{const z=q.id.toString();o.isExistValue(u.selectIds,z)&&N.push(z),o.isExistValue(u.HalfSelectIds,z)&&J.push(z)}),(J.length>0||N.length>0)&&(M=2),N.length>0&&N.length===b.length&&(M=1)}return M},p=(w,M,b)=>{const N={idx:w,pId:M,title:!o.isEmpty(i.treeTitle)&&i.treeTitle.length>w?i.treeTitle[w]:b,list:[],checkAll:0,sty:{}};if(i.width&&i.maxWidth&&i.width>0&&i.maxWidth>0){let J=i.width-3;const q=i.maxWidth/i.width;w+1>=q&&(J+=3),N.sty.width=`${J}px`}if(!o.isEmpty(M)){const J=s.getDataGroup(M);J.length>0&&(N.list=J.map(q=>{const z=q.id.toString(),H=o.getJsonClone(q);H.selected=o.isExistValue(u.selectIds,z),H.indeterminate=o.isExistValue(u.HalfSelectIds,z),H.isActive=o.isExistValue(u.openActiveId,z);const v=s.getDataGroup(z);H.isSub=v.length>0;let S=o.isNonEmptyString(q.name)?o.encodeHTML(q.name):"";const C=i.treeTextFormat;if(C&&C.length>0){let $="";o.isArray(C)?C.length>w&&($=C[w]):o.isString(C)&&($=C),o.isEmpty($)||(S=o.convertStringFormatEncodeHTML($,H))}return H.showTextLabel=S,H})),N.checkAll=m(M)}return N},f=w=>{const M=l.convertSelectedValue(w,!0,[]),b=l.convertSelectHalf(M);u.selectIds=M,u.HalfSelectIds=b},h=(w,M)=>{const b=[];if(r.value.forEach((N,J)=>{J<=w&&b.push(p(N.idx,N.pId,N.title))}),s.getDataGroup(M).length>0){const N=s.getDataInfo(M),J=o.isNonEmptyString(N&&N.name)?N.name:"";b.push(p(w+1,M,J))}r.value=b},g=(w,M)=>{const b=w.id.toString(),N=o.getArrClone(u.openActiveId);N.splice(M),N.push(b),u.openActiveId=N,h(M,b)},y=(w,M)=>{const b=l.convertSelectedValue(w,M,u.selectIds),N=l.convertSelectHalf(b);u.selectIds=b,u.HalfSelectIds=N,r.value=r.value.map(J=>p(J.idx,J.pId,J.title)),c()},V=w=>{const M=r.value.length,b=w||[];if(M>0&&u.selectIds.length>0){let N,J=-1;for(let q=M-1;q>=0;q--)if(r.value[q].list.some(H=>{if(H.selected||H.indeterminate)return N=H,!0})){J=q;break}if(J>-1&&!o.isUndefined(N)&&N.isSub){const q=N.id.toString();if(b.indexOf(q)>-1)return;b.push(q),g(N,J),V(b)}}},E=()=>{const w=[];return w.push(p(0,s.getTopParentValue(),"")),w};let B=null;const T=()=>{u.openActiveId=[],o.isEmpty(i.selectId)?(u.selectIds=[],u.HalfSelectIds=[]):f(i.selectId),r.value=E(),V(),B=o.getArrClone(i.selectId),i.treeShowMinLevel>1&&u.selectIds.length===0&&e.nextTick(()=>{const w=r.value.length,M=o.isFinite(i.treeShowMinLevel)?Math.min(i.treeShowMinLevel,ti):ti;if(M>w){const b=[];for(let N=w;N<M;N++)b.push(p(N,"",""));r.value=r.value.concat(b)}})};e.onMounted(()=>{e.nextTick(()=>{T()})}),e.watch(()=>i.dataRefreshIndex,()=>{T()}),e.watch(()=>i.selectId,w=>{(o.isUndefined(B)?!1:o.isEqualArr(w,B))||(B=o.getArrClone(w),f(w),r.value=r.value.map(b=>p(b.idx,b.pId,b.title)),V())});const D=(w,M)=>{const b=s.getDataGroup(M.toString()).map(N=>N.id.toString());y(b,w.value)},x=(w,M)=>{y(M.toString(),w.value)},O=(w,M,b)=>{if(i.disabled)return;const N=M.id.toString();if(o.isEmpty(s.getDataGroup(N))){if(de.getParent(w.target,".selectmove-option-checkbox",".selectmove-option"))return;y(N.toString(),!o.isExistValue(u.selectIds,N))}g(M,b)};return(w,M)=>(e.openBlock(),e.createElementBlock("div",Ah,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(b,N)=>(e.openBlock(),e.createElementBlock("div",{key:`${d}-tree-${N}`,class:"selectmove-tree-item",style:e.normalizeStyle(b.sty)},[e.createElementVNode("div",Lh,[e.withDirectives(e.createVNode(dt,{disabled:n.disabled,value:b.checkAll===1,indeterminate:b.checkAll===2,onOnChange:J=>D(J,b.pId)},null,8,["disabled","value","indeterminate","onOnChange"]),[[e.vShow,b.list.length>0]]),e.createElementVNode("div",$h,e.toDisplayString(b.title),1)]),e.createElementVNode("div",Fh,[e.createElementVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(b.list,(J,q)=>(e.openBlock(),e.createElementBlock("li",{key:`${d}-${J.id}-${q}`,class:e.normalizeClass({"selectmove-option":!0,active:J.isActive}),onClick:z=>O(z,J,N)},[e.createElementVNode("div",null,[e.createVNode(dt,{className:"selectmove-option-checkbox",disabled:n.disabled,value:J.selected,indeterminate:J.indeterminate,onOnChange:z=>x(z,J.id)},null,8,["disabled","value","indeterminate","onOnChange"]),e.createElementVNode("div",{class:"selectmove-option-text",innerHTML:J.showTextLabel},null,8,Rh),J.isSub?(e.openBlock(),e.createBlock(ve,{key:0,name:"angle-right",className:"sub-icon"})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])],10,Ph))),128))])])],4))),128)),e.renderSlot(w.$slots,"tail")]))}}),Uh={class:"selectmove-result"},zh={class:"selectmove-result-head"},Jh=["innerHTML"],Kh={class:"selectmove-result-body"},Wh=["innerHTML"],jh=e.defineComponent({name:"ClSelectMoveResult",__name:"Result",props:{disabled:Boolean,width:Number,resultCountFormat:String,resultTextFormat:String,resultMergeParent:Boolean,selectId:{type:Array,default:()=>[]},dataRefreshIndex:Number},emits:{onChange:n=>!0},setup(n,{emit:a}){const i=n,t=a,{optPageLanguage:s,getPageLanguage:l}=Le();l("common");const d=e.inject("$SelectmoveTop"),u=e.inject("$SelectmoveBase");if(o.isUndefined(d)||o.isUndefined(u))throw new Error("SelectMove.Result 缺少容器依赖($SelectmoveTop/$SelectmoveBase),请确保在 ClSelectMove 内使用");const r=`selectmove-result-${o.getRandom(5)}`,c=e.ref([]),m=e.computed(()=>c.value.length),p=e.computed(()=>o.isNonEmptyString(i.resultCountFormat)?o.convertStringFormat(i.resultCountFormat,{_count:m.value}):`${s.value.selected} ${m.value} ${s.value.count}`),f=e.computed(()=>{const E={};return i.width&&i.width>0&&(E.width=`${i.width}px`),E}),h=E=>{t("onChange",E.join(","))},g=E=>{if(o.isEmpty(E))return[];const B=E.filter(x=>!o.isUndefined(x)&&!o.isEmpty(x)),T=i.resultMergeParent?u.getValueMergeParent(B):u.getValueSplitChild(B),D=[];return T.forEach(x=>{const O=d.getDataInfo(x);if(o.isUndefined(O))return;const w=o.getJsonClone(O);o.isNonEmptyString(i.resultTextFormat)?w.showTextLabel=o.convertStringFormatEncodeHTML(i.resultTextFormat,w):o.isNonEmptyString(w.name)?w.showTextLabel=o.encodeHTML(w.name):w.showTextLabel="",D.push(w)}),D};e.watch(()=>i.selectId,E=>{const T=(o.isEmpty(E)?[]:E).filter(O=>!o.isUndefined(O)&&!o.isEmpty(O)),D=c.value.map(O=>O.id.toString());o.isEqualArr(T,D)||(c.value=g(T))},{immediate:!0}),e.watch(()=>i.dataRefreshIndex,()=>{c.value=g(i.selectId)}),e.watch(()=>i.resultMergeParent,()=>{c.value=g(i.selectId)});const y=()=>{c.value=[],h([])},V=E=>{const B=[],T=[],D=E.id.toString();c.value.forEach(x=>{const O=x.id.toString();O!==D&&(T.push(x),B.push(O))}),c.value=T,h(B)};return(E,B)=>(e.openBlock(),e.createElementBlock("div",Uh,[e.createElementVNode("div",{class:"selectmove-result-container",style:e.normalizeStyle(f.value)},[e.createElementVNode("div",zh,[e.createElementVNode("span",null,[n.disabled?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)):(e.openBlock(),e.createElementBlock("button",{key:0,class:"btn-cleanAll",type:"button",onClick:y},e.toDisplayString(e.unref(s).deleteAll),1))]),e.createElementVNode("span",{innerHTML:p.value},null,8,Jh)]),e.createElementVNode("div",Kh,[e.createElementVNode("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(T,D)=>(e.openBlock(),e.createElementBlock("li",{key:`${r}-${T.id}-${D}`},[e.createElementVNode("div",null,[e.createElementVNode("div",{innerHTML:T.showTextLabel},null,8,Wh),n.disabled?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)):(e.openBlock(),e.createBlock(ve,{key:0,name:"close",className:"btn-clean",onClick:x=>V(T)},null,8,["onClick"]))])]))),128))])])],4)]))}}),Yh={class:"selectmove-body"},qh={key:0,class:"selectmove-result"},Xh=100,Gh=175,ni=e.defineComponent({name:"ClSelectMoveContainer",__name:"Container",props:{disabled:Boolean,width:Number,isSearch:{type:Boolean,default:!0},searchPlaceholder:String,searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||"},searchIsMultiple:{type:Boolean,default:!1},searchMultipleJoin:{type:String,default:","},searchTextFormat:[String,Array],treeTitle:{type:Array,default:()=>[]},treeShowMinLevel:{type:Number,default:1},treeTextFormat:[String,Array],resultIsShowSlot:Boolean,resultIsShowSubUnit:Boolean,resultTextFormat:String,resultCountFormat:String,resultMergeParent:{type:Boolean,default:!0},dataRefreshIndex:{type:Number,default:0},selectId:{type:Array,default:()=>[]},parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"}},emits:{onSelectValue:n=>!0,onInitComplete:()=>!0},setup(n,{emit:a}){const i=n,t=a;let s=!1;const l=e.inject("$SelectmoveTop");if(o.isUndefined(l))throw new Error("SelectMove.Container 缺少容器依赖($SelectmoveTop),请确保在 ClSelectMove 内使用");const d=e.reactive({searchWidth:0,treeWidth:0,resultWidth:0}),u={parentIdsJson:Object.create(null),childIdJson:Object.create(null),childIdsJson:Object.create(null)},r=V=>{t("onSelectValue",V)},c=()=>{e.nextTick(()=>{s||t("onInitComplete")})},m=V=>{let E=[];return o.isExistJsonKey(u.childIdJson,V)?E=u.childIdJson[V]:l.isCheckChildren(V)&&(l.getDataGroup(V).forEach(B=>{o.isUndefined(B)||o.isUndefined(B.id)||E.push(B.id.toString())}),u.childIdJson[V]=E),E},p=(V,E)=>{let B=[];const T=E||[];return T.indexOf(V)>-1||(T.push(V),o.isExistJsonKey(u.childIdsJson,V)?B=u.childIdsJson[V]:(l.isCheckChildren(V)&&l.getDataGroup(V).forEach(D=>{if(o.isUndefined(D)||o.isUndefined(D.id))return;const x=D.id.toString();B.push(x);const O=p(x,T);O.length>0&&(B=B.concat(O))}),u.childIdsJson[V]=B)),B},f=(V,E)=>{const{parentKey:B,topParentValue:T}=i;let D=[];const x=E||[];if(x.indexOf(V)>-1)return D;if(x.push(V),o.isExistJsonKey(u.parentIdsJson,V))D=u.parentIdsJson[V];else{const O=l.getDataInfo(V);if(!o.isUndefined(O)){const w=O[B],M=o.isEmpty(w)?T:w.toString();if(M!==T&&!o.isUndefined(l.getDataInfo(M))){D.push(M);const b=f(M,x);b.length>0&&(D=D.concat(b))}}u.parentIdsJson[V]=D}return D},h=(V,E,B)=>{const T=(o.isUndefined(B)?[]:B).filter(N=>!o.isUndefined(N));if(o.isUndefined(V))return o.getArrClone(T);const D=o.isObject(V)?V:[V];if(!o.isArray(D))return o.getArrClone(T);const x=o.getArrConvertJson(T),O={},w=[],M=[];D.forEach(N=>{if(o.isUndefined(N))return;const J=[],q=[],z=N.toString();if(E){if(!(o.isExistJsonKey(x,z)||o.isExistJsonKey(O,z))){J.push(z);const v=p(z);v&&v.length>0&&J.push(...v);const S=f(z);for(let C=0;C<S.length;C++){const $=S[C].toString();if(o.isExistJsonKey(x,$)||o.isExistJsonKey(O,$))break;const k=m($),I=[];if(k.forEach(L=>{const _=L.toString();(o.isExistJsonKey(x,_)||o.isExistJsonKey(O,_)||J.indexOf(_)>-1)&&I.push(_)}),k.length===I.length)J.push($);else break}}}else{q.push(z);const H=p(z);H&&H.length>0&&q.push(...H);const v=f(z);q.push(...v)}J.length>0&&J.forEach(H=>{w.push(H),O[H]=!0}),q.length>0&&q.forEach(H=>{M.push(H)})});let b=o.getArrClone(T);return b.push(...w),b=o.getArrUnique(b),b=o.getArrRemoveById(b,M),b},g=V=>{if(o.isUndefined(V)||!o.isArray(V))return[];const E=[],B={};V.forEach(x=>{B[x]=!0;const O=f(x);E.push(...O)});const T=[],D={};return E.forEach(x=>{!o.isExistJsonKey(D,x)&&!o.isExistJsonKey(B,x)&&(D[x]=!0,T.push(x))}),T},y=()=>{const V=i.width;if(V!==void 0&&o.isFinite(V)&&V>=350){const E=Math.floor(V/Gh),B=Math.floor(V/E);d.searchWidth=V,d.treeWidth=B,d.resultWidth=B}};return e.onMounted(()=>{y(),c()}),e.onBeforeUnmount(()=>{s=!0}),e.watch(()=>i.dataRefreshIndex,()=>{u.parentIdsJson=Object.create(null),u.childIdJson=Object.create(null),u.childIdsJson=Object.create(null)}),e.watch(()=>i.width,()=>{y()}),e.provide("$SelectmoveBase",{convertSelectedValue:(V,E,B)=>{let T=!1;if(E&&o.isObject(V)&&V.length>Xh&&(T=!0),T){const D=l.getValueMergeParent(V);return h(D,E,B)}else return h(V,E,B)},convertSelectHalf:g,getChildIds:p,getParentIds:f,getLastChildIds:(V,E)=>l.getLastChildIds(V,E),getValueMergeParent:V=>l.getValueMergeParent(V),getValueSplitChild:V=>l.getValueSplitChild(V)}),(V,E)=>(e.openBlock(),e.createElementBlock(e.Fragment,null,[n.isSearch?(e.openBlock(),e.createBlock(Oh,{key:0,disabled:n.disabled,width:d.searchWidth,placeholder:n.searchPlaceholder,searchKey:n.searchKey,searchKeyType:n.searchKeyType,searchIsMultiple:n.searchIsMultiple,searchMultipleJoin:n.searchMultipleJoin,searchTextFormat:n.searchTextFormat,selectId:n.selectId,parentKey:n.parentKey,topParentValue:n.topParentValue,onOnChange:r},null,8,["disabled","width","placeholder","searchKey","searchKeyType","searchIsMultiple","searchMultipleJoin","searchTextFormat","selectId","parentKey","topParentValue"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",Yh,[e.createVNode(Hh,{disabled:n.disabled,maxWidth:d.searchWidth,width:d.treeWidth,treeTitle:n.treeTitle,treeShowMinLevel:n.treeShowMinLevel,treeTextFormat:n.treeTextFormat,selectId:n.selectId,dataRefreshIndex:n.dataRefreshIndex,onOnChange:r},{tail:e.withCtx(()=>[n.resultIsShowSlot?(e.openBlock(),e.createElementBlock("div",qh,[e.renderSlot(V.$slots,"resultSelect")])):n.resultIsShowSubUnit?(e.openBlock(),e.createBlock(jh,{key:1,disabled:n.disabled,width:d.resultWidth,resultTextFormat:n.resultTextFormat,resultCountFormat:n.resultCountFormat,resultMergeParent:n.resultMergeParent,selectId:n.selectId,dataRefreshIndex:n.dataRefreshIndex,onOnChange:r},null,8,["disabled","width","resultTextFormat","resultCountFormat","resultMergeParent","selectId","dataRefreshIndex"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))]),_:3},8,["disabled","maxWidth","width","treeTitle","treeShowMinLevel","treeTextFormat","selectId","dataRefreshIndex"])])],64))}}),Qh=["id"],Zh={className:"selectmove-text-num"},eg={class:"selectmove-container"},tg=["id"],fs=e.defineComponent({name:"ClSelectMove",__name:"Index",props:{id:String,value:String,className:String,disabled:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},isDropdown:{type:Boolean,default:!1},placeholder:String,isClear:{type:Boolean,default:!1},containerWidth:{type:Number,default:350},isSearch:{type:Boolean,default:!0},searchPlaceholder:String,searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||"},searchIsMultiple:{type:Boolean,default:!1},searchMultipleJoin:{type:String,default:","},searchTextFormat:[String,Array],treeTitle:{type:Array,default:()=>[]},treeShowMinLevel:{type:Number,default:1},treeTextFormat:[String,Array],resultIsShow:{type:Boolean,default:!0},resultTextFormat:String,resultCountFormat:String,resultMergeParent:{type:Boolean,default:!0},isOutMerge:{type:Boolean,default:!0},parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"},isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:","},plaintextLevelSeparator:{type:String,default:" > "},appendContainer:{type:String,default:""}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:(n,a)=>!0,onInit:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.useSlots(),d=t.id,u=e.useTemplateRef("refElDropdownLayer"),r=e.reactive({dataRefreshIndex:0,selectedIds:[],IsShowResultSlot:!o.isUndefined(l.resultSelect),isInitEmitDone:!1}),c=e.ref([]),m={dataJson:{},dataGroup:{},childLastIdsJson:{}},p=e.computed(()=>({disabled:t.disabled,width:t.containerWidth,isSearch:t.isSearch,searchPlaceholder:t.searchPlaceholder,searchKey:t.searchKey,searchKeyType:t.searchKeyType,searchIsMultiple:t.searchIsMultiple,searchMultipleJoin:t.searchMultipleJoin,searchTextFormat:t.searchTextFormat,treeTitle:t.treeTitle,treeShowMinLevel:t.treeShowMinLevel,treeTextFormat:t.treeTextFormat,resultIsShowSubUnit:t.resultIsShow,resultIsShowSlot:r.IsShowResultSlot,resultTextFormat:t.resultTextFormat,resultCountFormat:t.resultCountFormat,resultMergeParent:t.resultMergeParent,parentKey:t.parentKey,topParentValue:t.topParentValue})),f=e.computed(()=>{let _="panel-selectmove ";return o.isNonEmptyString(t.className)&&(_+=t.className),t.isDropdown||t.disabled&&(_+=" selectmove-disabled "),_}),h=_=>{s("update:value",_),s("update:modelValue",_)},g=(_,R)=>{h(_),s("onChange",_,R)},y=()=>{s("onInit")},V=()=>t.list,E=_=>o.isExistJsonKey(m.dataGroup,_.toString()),B=_=>{const R=_.toString();return E(R)?m.dataGroup[R]:[]},T=_=>{const R=_.toString();return o.isExistJsonKey(m.dataJson,R)?m.dataJson[R]:null},D=()=>`top_${t.topParentValue}`,x=_=>{const{parentKey:R,topParentValue:P}=t,Q={},oe={};!o.isEmpty(_)&&o.isArray(_)&&_.forEach(ue=>{const Y=o.getJsonClone(ue);if(!o.isString(Y.id)&&!o.isNumber(Y.id))return;const Z=Y.id.toString(),se=o.isEmpty(Y[R])?P:Y[R].toString();Q[Z]=Y;const K=se===P?D():se;o.isExistJsonKey(oe,K)||(oe[K]=[]),oe[K].push(Y)}),m.dataJson=Q,m.dataGroup=oe,m.childLastIdsJson={}};x(t.list);const O=(_,R)=>{let P=[];const Q=R||[];return Q.indexOf(_)>-1||(Q.push(_),o.isExistJsonKey(m.childLastIdsJson,_)&&m.childLastIdsJson[_].length>0?P=m.childLastIdsJson[_]:(E(_)?B(_).forEach(oe=>{const ue=O(oe.id.toString(),Q);ue.length>0&&(P=P.concat(ue))}):P.push(_),m.childLastIdsJson[_]=P)),P},w=(_,R)=>{const{parentKey:P,topParentValue:Q}=t,oe=R||[],ue={},Y=[];let Z=[];if(_.forEach(se=>{const K=T(se);if(!o.isUndefined(K)){const W=K[P],U=o.isUndefined(W)?Q:W.toString();U===Q?Z.push(se):(o.isExistJsonKey(ue,U)||(ue[U]=[]),ue[U].push(se))}}),!o.isEmpty(ue))for(const[se,K]of Object.entries(ue))K.length===B(se).length&&oe.indexOf(se)===-1?Y.push(se):Z=Z.concat(K);if(Y.length>0){Z.push(...Y);const se=o.getArrUnique(Z);return w(se,oe.concat(Y))}else return Z},M=_=>{const R=[],P=o.getArrConvertJson(_);return _.forEach(oe=>{const ue=B(oe);if(o.isEmpty(ue))R.push(oe);else{const Y=[];ue.forEach(Z=>{o.isExistJsonKey(P,Z.id.toString())&&Y.push(Z.id)}),ue.length!==Y.length&&R.push(oe)}}),w(R)},b=_=>{let R=[];return _.forEach(P=>{const Q=O(P);R.push(...Q)}),R=o.getArrUnique(R),R},N=(_,R)=>(o.isBoolean(R)?R:t.isOutMerge)?M(_):b(_),J=_=>{const R=[],P=[];return _.forEach(Q=>{const oe=T(Q);o.isUndefined(oe)||(R.push(oe),P.push(o.isNonEmptyString(oe.name)?o.encodeHTML(oe.name):""))}),{list:R,label:P}},q=_=>{const R=[],P=new Set;let Q=_;for(;o.isNonEmptyString(Q)&&!P.has(Q);){P.add(Q);const oe=T(Q);if(!oe)break;o.isNonEmptyString(oe.name)&&R.unshift(oe.name);const ue=oe[t.parentKey],Y=ue!=null?String(ue):"";if(Y===""||Y===String(t.topParentValue))break;Q=Y}return R},z=e.computed(()=>{if(t.list,o.isEmpty(r.selectedIds))return"";const _=o.isString(t.plaintextLevelSeparator)?t.plaintextLevelSeparator:" > ",R=o.isString(t.plaintextSeparator)?t.plaintextSeparator:",";return N(r.selectedIds,t.resultMergeParent).map(Q=>{const oe=q(Q);return o.removeHTMLTags(oe.length>0?oe.join(_):Q)}).join(R)}),H=()=>{if(t.isDropdown)if(o.isEmpty(r.selectedIds))c.value=[];else{const _=N(r.selectedIds,t.resultMergeParent);c.value=J(_).label}};(()=>{o.isNonEmptyString(t.value)&&(r.selectedIds=o.split(t.value)),H()})(),e.watch(()=>t.value,(_,R)=>{if(_!==R){const P=o.isNonEmptyString(_)?o.split(_):[],Q=N(r.selectedIds);o.isEqualArr(P,Q)||(r.selectedIds=o.isEmpty(P)?[]:P,H())}}),e.watch(()=>t.list,_=>{o.isArray(_)&&(x(_),r.selectedIds=r.selectedIds.filter(R=>!o.isUndefined(T(R))),r.dataRefreshIndex++,H())}),e.watch(()=>t.resultMergeParent,()=>{H()});const S=()=>{t.disabled||(r.selectedIds=[],H(),g("",[]))},C=()=>{t.isDropdown&&(H(),u.value&&(u.value.checkIsShowOpen()||u.value.initCompleteOpen())),r.isInitEmitDone||(r.isInitEmitDone=!0,y())},$=_=>{const R=o.isEmpty(_)?[]:o.split(_);r.selectedIds=R;const P=N(R),Q=J(P);H(),g(P.join(","),Q.list)};return e.provide("$SelectmoveTop",{isCheckChildren:E,getDataGroup:B,getDataInfo:T,getDataList:V,getLastChildIds:O,getValueMergeParent:M,getValueSplitChild:b,getTopParentValue:D}),a({getValue:()=>N(r.selectedIds).join(","),getValueData:()=>{const _=N(r.selectedIds);return J(_).list},setValue:_=>{r.selectedIds=o.isString(_)&&!o.isEmpty(_)?o.split(_):[],H()}}),(_,R)=>n.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(d),class:"cl-plaintext-value"},e.toDisplayString(z.value),9,Qh)):n.isDropdown?(e.openBlock(),e.createBlock(wn,{key:1,id:e.unref(d),ref_key:"refElDropdownLayer",ref:u,classParent:f.value,classText:"selectmove-text",classDropDown:"selectmove-dropdown",placeholder:n.placeholder,isDisabled:n.disabled,isClear:n.isClear,textLabel:c.value.join(","),textArrowDirection:"right",isUseDropdownArrow:!0,appendContainer:n.appendContainer,onOnClear:S},{textExtend:e.withCtx(()=>[e.createElementVNode("span",Zh,[c.value.length>1?(e.openBlock(),e.createBlock(Gt,{key:0,num:c.value.length},null,8,["num"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])]),dropdown:e.withCtx(()=>[e.createElementVNode("div",eg,[e.createVNode(ni,e.mergeProps(p.value,{dataRefreshIndex:r.dataRefreshIndex,selectId:r.selectedIds,onOnSelectValue:$,onOnInitComplete:C}),{resultSelect:e.withCtx(()=>[e.renderSlot(_.$slots,"resultSelect")]),_:3},16,["dataRefreshIndex","selectId"])])]),_:3},8,["id","classParent","placeholder","isDisabled","isClear","textLabel","appendContainer"])):(e.openBlock(),e.createElementBlock("div",{key:2,id:e.unref(d),class:e.normalizeClass(f.value)},[e.createVNode(ni,e.mergeProps(p.value,{dataRefreshIndex:r.dataRefreshIndex,selectId:r.selectedIds,onOnSelectValue:$,onOnInitComplete:C}),{resultSelect:e.withCtx(()=>[e.renderSlot(_.$slots,"resultSelect")]),_:3},16,["dataRefreshIndex","selectId"])],10,tg))}}),ng=["id"],og={key:0,class:"cl-plaintext-value"},ag={key:2,class:"selectTag-container"},ig=["aria-selected","aria-disabled","tabindex"],sg=["aria-selected","aria-disabled","tabindex","onClick","onKeydown"],lg=["innerHTML"],rg={key:1},fa=e.defineComponent({name:"ClSelectTag",__name:"Index",props:{id:String,value:[String,Number],className:String,disabled:Boolean,type:{type:String,required:!0,validator:n=>["checkbox","radio"].indexOf(n)!==-1},list:{type:Array,default:()=>[]},theme:String,width:String,isShowAll:Boolean,showAllLabel:String,isInitRadioValue:{type:Boolean,default:!0},isRadioClickCancel:Boolean,checkChangeBefore:Function,isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:","}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:(n,a,i,t)=>!0,onInit:(n,a,i)=>!0,onError:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("common");const u=`s-${o.getRandom(5)}`,r=t.id,c=e.reactive({theme:""}),m=e.ref(!1),p=P=>{let Q=[];return o.isEmpty(P)||(Q=P.toString().split(",")),Q},f=e.ref(p(t.value));let h=[],g={};const y=e.ref(0),V=e.ref(!1);let E=0;const B=e.computed(()=>{const P=o.isString(t.plaintextSeparator)?t.plaintextSeparator:",";t.list,y.value;const Q=[];return f.value.forEach(oe=>{const ue=o.isExistJsonKey(g,oe)?g[oe]:void 0;ue&&o.isNonEmptyString(ue.name)&&Q.push(ue.name)}),Q.join(P)}),T=e.computed(()=>{const{theme:P}=t,Q={"panel-select-tag":!0};let oe=c.theme;return P&&(oe=P),o.isEmpty(oe)||(Q[`selectTag-${oe}`]=!0),o.getJsonMerge(Q,de.getClassNameJson(t.className))}),D=e.computed(()=>{const P={};return o.isEmpty(t.width)||(P.width=t.width),P}),x=P=>{s("update:value",P),s("update:modelValue",P)},O=P=>{if(!o.isEqualArr(f.value,P)){const Q=o.getArrClone(f.value),oe=M(Q);f.value=o.getArrClone(P);const{value:ue,isAll:Y,info:Z}=M(P);t.isShowAll&&(m.value=Y),x(ue),s("onChange",ue,Z,Y,{value:oe.value,info:oe.info})}},w=()=>{e.nextTick(()=>{const{value:P,isAll:Q,info:oe}=M(f.value);s("onInit",P,oe,Q)})},M=P=>{const Q=[];o.isEmpty(P)||P.forEach(Z=>{o.isExistJsonKey(g,Z)&&Q.push(o.getJsonClone(g[Z]))});const oe=P.join(","),ue=Q.length>0&&Q.length===h.length;let Y;return t.type==="radio"?(Y={},Q.length>0&&(Y=Q[0])):Y=Q,{value:oe,info:Y,isAll:ue}},b=P=>!o.isEmpty(P.id)&&f.value.includes(P.id.toString()),N=P=>{const Q={};return P.isHtml?Q.width="auto":o.isEmpty(P.width)?o.isEmpty(t.width)||(Q.width=t.width):Q.width=P.width,Q},J=()=>{const P=Nt("selectTag");P?.theme&&(c.theme=P.theme)},q=P=>{const Q=[];if(P.length>0){const oe=g[P[0]],ue=oe&&!o.isEmpty(oe.type)?oe.type:t.type;P.forEach(Y=>{if(o.isExistJsonKey(g,Y)){const Z=g[Y];if((o.isEmpty(Z.type)?t.type:Z.type)===ue)switch(ue){case"radio":Q.length===0&&Q.push(Y);break;case"checkbox":Q.push(Y);break}}})}return Q},z=P=>{if(g={},h=[],!o.isEmpty(P)){const Q=o.getArrClone(f.value);P.forEach(oe=>{if(o.isExistJsonKey(oe,"id")){const ue=oe.id.toString();g[ue]=oe,oe.isDisabled?o.isExistValue(Q,ue)&&h.push(ue):h.push(ue)}})}y.value+=1},H=()=>{if(V.value){let P=[];o.isEmpty(f.value)||(P=q(f.value),o.isEqualArr(f.value,P)||(f.value=P,x(P.join(",")))),t.isShowAll&&(m.value=P.length>0&&P.length===h.length)}},v=()=>{if(t.type==="radio"&&t.isInitRadioValue&&o.isEmpty(f.value)&&!o.isEmpty(t.list)){const P=t.list.find(Q=>!Q.isDisabled);if(P&&!o.isEmpty(P.id)){const Q=P.id.toString();f.value=[Q],x(Q)}}},S=P=>{const Q=p(P);o.isEqualArr(f.value,Q)||(f.value=Q,x(Q.join(",")))},C=()=>{J(),V.value=!o.isEmpty(t.list),z(t.list),v(),H()};e.onMounted(()=>{e.nextTick(()=>{C()})}),e.watch(V,P=>{P&&w()}),e.watch([()=>t.list,()=>t.value,()=>t.type],([P,Q],[oe,ue])=>{const Y=P;!V.value&&Y!==oe&&(V.value=!0),Q!==ue&&S(Q),z(Y),Q===ue&&v(),H()});const $=async()=>{if(!t.disabled&&!o.isEmpty(t.list)){const P=++E;if(!t.list.some(Z=>!Z.isDisabled))return;const oe=[];t.list.forEach(Z=>{if(o.isEmpty(Z.id))return;const se=Z.id.toString();Z.isDisabled?o.isExistValue(f.value,se)&&oe.push(se):m.value||oe.push(se)});const ue=q(oe);let Y=!0;if(t.checkChangeBefore){const{value:Z}=M(ue),se=M(o.getArrClone(f.value));try{Y=await t.checkChangeBefore(Z,se.value),Y=o.isBoolean(Y)?Y:!0}catch(K){Y=!1,s("onError",K instanceof Error?K.message:String(K))}}Y&&P===E&&O(ue)}},k=async P=>{if(!P.isDisabled&&!t.disabled&&!o.isEmpty(P.id)){const Q=++E;let oe=t.type;oe=o.isEmpty(P.type)?oe:P.type;const ue=o.getArrClone(f.value);let Y=[];const Z=P.id.toString();if(ue.length===0)Y=[Z];else if(oe==="radio")o.isEqualArr(ue,[Z])?Y=t.isRadioClickCancel?[]:ue:Y=[Z];else{const K=g[ue[0]];(K&&!o.isEmpty(K.type)?K.type:t.type)==="radio"?Y=[Z]:o.isExistValue(ue,Z)?Y=o.getArrRemoveById(ue,Z):(Y=ue,Y.push(Z))}let se=!0;if(t.checkChangeBefore){const{value:K}=M(Y),W=M(ue);try{se=await t.checkChangeBefore(K,W.value),se=o.isBoolean(se)?se:!0}catch(U){se=!1,s("onError",U instanceof Error?U.message:String(U))}}se&&Q===E&&O(Y)}},I=()=>q(f.value).join(",");return a({getValue:I,getValueData:()=>{const{value:P,info:Q}=M(I().split(","));return t.type==="radio"&&o.isEmpty(P)?null:Q},setValue:P=>{S(P),z(t.list),H()},runInitComplete:()=>{V.value||(V.value=!0,S(t.value),z(t.list),v(),H())}}),(P,Q)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(r),class:e.normalizeClass(T.value)},[n.isPlaintext?(e.openBlock(),e.createElementBlock("div",og,e.toDisplayString(B.value),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isPlaintext?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("ul",ag,[n.isShowAll?(e.openBlock(),e.createElementBlock("li",{key:0,role:"option","aria-selected":m.value,"aria-disabled":n.disabled,tabindex:n.disabled?-1:0,class:e.normalizeClass({"selectTag-item":!0,"selectTag-active":m.value,"selectTag-disabled":n.disabled}),style:e.normalizeStyle(D.value),onClick:Q[0]||(Q[0]=oe=>$()),onKeydown:[Q[1]||(Q[1]=e.withKeys(e.withModifiers(oe=>$(),["prevent"]),["enter"])),Q[2]||(Q[2]=e.withKeys(e.withModifiers(oe=>$(),["prevent"]),["space"]))]},[e.createElementVNode("span",null,e.toDisplayString(n.showAllLabel||e.unref(l).checkboxAll),1)],46,ig)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.list,(oe,ue)=>(e.openBlock(),e.createElementBlock("li",{key:`${u}-${oe.id}-${ue}`,role:"option","aria-selected":b(oe),"aria-disabled":oe.isDisabled||n.disabled,tabindex:oe.isDisabled||n.disabled?-1:0,class:e.normalizeClass({"selectTag-item":!0,"selectTag-active":b(oe),"selectTag-disabled":oe.isDisabled||n.disabled}),style:e.normalizeStyle(N(oe)),onClick:Y=>k(oe),onKeydown:[e.withKeys(e.withModifiers(Y=>k(oe),["prevent"]),["enter"]),e.withKeys(e.withModifiers(Y=>k(oe),["prevent"]),["space"])]},[e.renderSlot(P.$slots,"default",{data:oe},()=>[oe.isHtml?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:e.unref(o).encodeHTML(oe.name)},null,8,lg)):(e.openBlock(),e.createElementBlock("span",rg,e.toDisplayString(oe.name),1))])],46,sg))),128))]))],10,ng))}}),cg={class:"tree-ul"},ug=["onClick"],dg=["aria-checked","onClick"],mg=["tabindex","aria-disabled","onClick","onDblclick","onKeydown"],pg=["innerHTML"],fg={key:1},oi=170,hs=e.defineComponent({name:"ClTreeUl",__name:"Ul",props:{list:{type:Array,default:()=>[]},multiple:{type:Boolean,default:!1},isSingleSelectParent:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},firstOpenIds:{type:Array,default:()=>[]},openIds:{type:Array,default:()=>[]},selectIds:{type:Array,default:()=>[]},selectUnIds:{type:Array,default:()=>[]}},emits:["onSelect","onShrink"],setup(n,{emit:a}){const i=n,t=a,s=`tree-${o.getRandom(5)}`;let l=!1;const d=e.inject("$TreeTop",{isCheckChildren:()=>(l||(l=!0,Se.warn("ClTreeUl","未检测到 ClTree 容器提供 $TreeTop,子级判断降级为 false")),!1)}),u={dbClickTimeOut:null},r=e.computed(()=>new Set(i.firstOpenIds)),c=e.computed(()=>new Set(i.selectIds)),m=e.computed(()=>new Set(i.selectUnIds)),p=e.computed(()=>new Set(i.openIds)),f=M=>{o.isUndefined(M)||t("onSelect",M.toString())},h=M=>{o.isUndefined(M)||t("onShrink",M.toString())},g=M=>o.isUndefined(M.id)?"":M.id.toString(),y=M=>{const b=g(M);return c.value.has(b)?"true":m.value.has(b)?"mixed":"false"},V=M=>{const b={"tree-node":!0};if(b["tree-node-end"]=M.isEnd,!M.isEnd){const N=o.isUndefined(M.id)?"":M.id.toString(),J=p.value.has(N);b["tree-node-open"]=J,b["tree-node-closed"]=!J}return b},E=M=>{const b=o.isUndefined(M.id)?"":M.id.toString(),N={"tree-node-text":!0};return N["tree-node-select"]=c.value.has(b),N["tree-node-selectUn"]=m.value.has(b),N};e.onBeforeUnmount(()=>{u.dbClickTimeOut&&window.clearTimeout(u.dbClickTimeOut)});const B=M=>{i.disabled||(window.clearTimeout(u.dbClickTimeOut),h(M.id))},T=M=>{i.disabled||(window.clearTimeout(u.dbClickTimeOut),f(M.id))},D=M=>{if(!i.disabled)if(d.isCheckChildren(M.id)){let b=!0;!i.multiple&&!i.isSingleSelectParent&&(b=!1),b?(window.clearTimeout(u.dbClickTimeOut),u.dbClickTimeOut=window.setTimeout(()=>{i.disabled||f(M.id)},oi)):window.clearTimeout(u.dbClickTimeOut)}else window.clearTimeout(u.dbClickTimeOut),u.dbClickTimeOut=window.setTimeout(()=>{i.disabled||f(M.id)},oi)},x=M=>{i.disabled||d.isCheckChildren(M.id)&&(u.dbClickTimeOut&&window.clearTimeout(u.dbClickTimeOut),h(M.id))},O=M=>{f(M)},w=M=>{h(M)};return(M,b)=>(e.openBlock(),e.createElementBlock("ul",cg,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.list,(N,J)=>(e.openBlock(),e.createElementBlock("li",{key:`${s}-${N.id}-${J}`,class:e.normalizeClass(V(N))},[e.createElementVNode("i",{class:"tree-shrink",onClick:e.withModifiers(q=>B(N),["stop"])},null,8,ug),e.createElementVNode("span",{class:e.normalizeClass(E(N))},[n.multiple?(e.openBlock(),e.createElementBlock("i",{key:0,class:"tree-node-checkbox",role:"checkbox","aria-checked":y(N),onClick:e.withModifiers(q=>T(N),["stop"])},null,8,dg)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("a",{href:"javascript:",tabindex:n.disabled?-1:0,"aria-disabled":n.disabled,onClick:e.withModifiers(q=>D(N),["stop"]),onDblclick:e.withModifiers(q=>x(N),["stop"]),onKeydown:e.withKeys(e.withModifiers(q=>D(N),["prevent"]),["enter"])},[N.showTextLabelHtml?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:N.showTextLabel},null,8,pg)):(e.openBlock(),e.createElementBlock("span",fg,e.toDisplayString(N.showTextLabel),1))],40,mg)],2),r.value.has(g(N))?(e.openBlock(),e.createBlock(vn,{key:0},{default:e.withCtx(()=>[e.withDirectives(e.createVNode(hs,{list:N.list,multiple:n.multiple,isSingleSelectParent:n.isSingleSelectParent,disabled:n.disabled,firstOpenIds:n.firstOpenIds,openIds:n.openIds,selectIds:n.selectIds,selectUnIds:n.selectUnIds,onOnSelect:O,onOnShrink:w},null,8,["list","multiple","isSingleSelectParent","disabled","firstOpenIds","openIds","selectIds","selectUnIds"]),[[e.vShow,p.value.has(g(N))]])]),_:2},1024)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],2))),128))]))}}),hg=["id"],gg=["id"],ha=e.defineComponent({name:"ClTree",__name:"Index",props:{id:String,value:String,className:String,disabled:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},multiple:{type:Boolean,default:!1},isSingleSelectParent:{type:Boolean,default:!1},isOutMerge:{type:Boolean,default:!0},parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"},searchOpenParentIds:{type:String,default:""},searchFoldParentIds:{type:String,default:""},searchKeyword:{type:String,default:""},highlightMode:{type:String,default:""},highlightColor:{type:String,default:""},isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:","},plaintextLevelSeparator:{type:String,default:" > "}},emits:["update:value","update:modelValue","onChange","onInit"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.reactive({firstOpenIds:[],openParentIds:[],selectedIds:[],selectedUnIds:[],list:[]}),u={dataJson:{},dataGroup:{},childLastIdsJson:{},prevSearchOpenParentIds:"",prevSearchFoldParentIds:""},r=e.computed(()=>({multiple:t.multiple,disabled:t.disabled,isSingleSelectParent:t.isSingleSelectParent})),c=e.computed(()=>o.getJsonMerge({"panel-tree":!0},de.getClassNameJson(t.className))),m=Y=>{s("update:value",Y),s("update:modelValue",Y)},p=(Y,Z)=>{m(Y),s("onChange",Y,Z)},f=()=>{e.nextTick(()=>{s("onInit")})},h=Y=>{const Z=o.isUndefined(Y)?"":Y.toString();return o.isExistJsonKey(u.dataGroup,Z)},g=Y=>{const Z=o.isUndefined(Y)?"":Y.toString();return h(Z)?u.dataGroup[Z]:[]},y=e.ref(0),V=Y=>{const Z=Y.toString();return o.isExistJsonKey(u.dataJson,Z)?u.dataJson[Z]:null},E=Y=>{const Z=[],se=new Set;let K=Y;for(;o.isNonEmptyString(K)&&!se.has(K);){se.add(K);const W=V(K);if(!W)break;o.isNonEmptyString(W.name)&&Z.unshift(W.name);const U=W[t.parentKey],ae=U!=null?String(U):"";if(ae===""||ae===String(t.topParentValue))break;K=ae}return Z},B=e.computed(()=>{if(t.list,y.value,o.isEmpty(d.selectedIds))return"";const Y=o.isString(t.plaintextLevelSeparator)?t.plaintextLevelSeparator:" > ",Z=o.isString(t.plaintextSeparator)?t.plaintextSeparator:",";return S(d.selectedIds,t.isOutMerge).map(K=>{const W=E(K);return o.removeHTMLTags(W.length>0?W.join(Y):K)}).join(Z)}),T=(Y,Z,se)=>{const K=[],W=Z+1;return se===void 0&&(se=new Set),se.has(Y)||(se.add(Y),g(Y).forEach(U=>{const ae={...U},G=ae.id.toString(),X=h(G);ae.isEnd=!X,ae.level=W,X&&(ae.list=T(G,W,se)),K.push(ae)})),K},D=Y=>Y.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;"),x=Y=>{const Z=t.searchKeyword,se=t.highlightMode;if(!o.isNonEmptyString(Y)||o.isEmpty(Z))return D(String(Y));const K=o.isNonEmptyString(t.highlightColor)?t.highlightColor:"#ffe58f",W=ee=>`<mark style="background:${K}">${D(ee)}</mark>`;if(se==="full")return Y.includes(Z)?W(Y):D(Y);const U=Y.indexOf(Z);if(U===-1)return D(Y);const ae=D(Y.slice(0,U)),G=W(Y.slice(U,U+Z.length)),X=D(Y.slice(U+Z.length));return`${ae}${G}${X}`},O=Y=>{const{parentKey:Z,topParentValue:se}=t,K=o.isNonEmptyString(se)?se:"0",W={},U={};o.isEmpty(Y)||Y.forEach(ae=>{const G=o.getJsonClone(ae),X=!o.isEmpty(t.searchKeyword)&&!o.isEmpty(t.highlightMode);G.showTextLabelHtml=X,G.showTextLabel=X?x(o.isString(G.name)?G.name:""):o.isString(G.name)?G.name:"";const ee=o.isString(G.id)||typeof G.id=="number"&&o.isFinite(G.id),F=o.isString(G[Z])||typeof G[Z]=="number"&&o.isFinite(G[Z]);if(!ee||!F)return;const j=G.id.toString(),le=G[Z].toString();W[j]=G,o.isExistJsonKey(U,le)||(U[le]=[]),U[le].push(G)}),u.dataJson=W,u.dataGroup=U,u.childLastIdsJson={},d.list=T(K,0),y.value+=1},w=(Y,Z)=>{let se=[];const{parentKey:K,topParentValue:W}=t,U=o.isNonEmptyString(W)?W:"0",ae=o.isEmpty(Y)?"":Y.toString();if(Z===void 0&&(Z=new Set),o.isExistJsonKey(u.dataJson,ae)&&!Z.has(ae)){Z.add(ae),se.push(ae);const G=u.dataJson[ae][K].toString();if(G!==U){const X=w(G,Z);se=se.concat(X)}}return se},M=Y=>{const Z=w(Y);return Z.splice(0,1),Z.reverse(),Z},b=(Y,Z)=>{let se=[];const K=o.isEmpty(Y)?"":Y.toString();return Z===void 0&&(Z=new Set),Z.has(K)||(Z.add(K),se.push(K),h(K)&&g(K).forEach(W=>{const U=W.id.toString(),ae=b(U,Z);se=se.concat(ae)})),se},N=Y=>{const Z=b(Y);return Z.splice(0,1),Z},J=(Y,Z,se,K)=>{const W={add:[],del:[]},U={add:[],del:[]};let ae=o.isUndefined(Z)?o.getArrClone(d.selectedIds):Z,G=o.isUndefined(se)?o.getArrClone(d.selectedUnIds):se;const X=ae.indexOf(Y);K?X===-1&&ae.push(Y):X===-1?ae.push(Y):ae.splice(X,1),G=o.getArrRemoveById(G,Y);const ee=M(Y);return ee.reverse(),ee.length>0&&ee.forEach(F=>{let j=0,le=0;u.dataGroup[F].forEach(ie=>{const ne=ie.id.toString();o.isExistValue(ae,ne)&&(j+=1),o.isExistValue(G,ne)&&(le+=1)});const me=u.dataGroup[F].length;j===0&&le===0?(W.del.push(F),ae=o.getArrRemoveById(ae,F),U.del.push(F),G=o.getArrRemoveById(G,F)):j===me?(W.add.push(F),ae.push(F),U.del.push(F),G=o.getArrRemoveById(G,F)):(W.del.push(F),ae=o.getArrRemoveById(ae,F),U.add.push(F),G.push(F))}),{select:W,selectUn:U}},q=(Y,Z)=>{let se=[];if(Z===void 0&&(Z=new Set),o.isExistJsonKey(u.childLastIdsJson,Y)&&u.childLastIdsJson[Y].length>0)se=u.childLastIdsJson[Y];else{if(Z.has(Y))return se;h(Y)?(Z.add(Y),g(Y).forEach(K=>{const W=q(K.id.toString(),Z);W.length>0&&(se=se.concat(W))})):se.push(Y),u.childLastIdsJson[Y]=se}return se},z=(Y,Z)=>{const{parentKey:se,topParentValue:K}=t,W=o.isNonEmptyString(K)?K:"0",U={},ae=[];let G=[];if(Z===void 0&&(Z=new Set),Y.forEach(X=>{const ee=V(X);if(!o.isUndefined(ee)){const F=ee[se].toString();F===W?G.push(X):(o.isExistJsonKey(U,F)||(U[F]=[]),U[F].push(X))}}),!o.isEmpty(U))for(const[X,ee]of Object.entries(U))ee.length===g(X).length?ae.push(X):G=G.concat(ee);if(ae.length>0){G.push(...ae);const X=o.getArrUnique(G),ee=ae.some(F=>!Z.has(F));return ae.forEach(F=>Z.add(F)),ee?z(X,Z):G}else return G},H=Y=>{const Z=[],se=o.getArrConvertJson(Y);return Y.forEach(W=>{const U=g(W);if(o.isEmpty(U))Z.push(W);else{const ae=[];U.forEach(G=>{o.isExistJsonKey(se,G.id.toString())&&ae.push(G.id)}),U.length!==ae.length&&Z.push(W)}}),z(Z)},v=Y=>{let Z=[];return Y.forEach(se=>{const K=q(se);Z.push(...K)}),Z=o.getArrUnique(Z),Z},S=(Y,Z)=>t.multiple?(o.isBoolean(Z)?Z:t.isOutMerge)?H(Y):v(Y):Y,C=Y=>{const Z=[];return Y.forEach(se=>{const K=V(se);o.isUndefined(K)||Z.push(K)}),Z},$=Y=>{const Z=t.multiple?Y:Y.slice(0,1);let se=[],K=[];Z.forEach(U=>{const ae=V(U);if(!o.isUndefined(ae)){const G=J(U,se,K,!0);se=o.getArrRemoveById(se,G.select.del),G.select.add.length>0&&se.push(...G.select.add),K=o.getArrRemoveById(K,G.selectUn.del),G.selectUn.add.length>0&&K.push(...G.selectUn.add);const X=N(U);se.push(...X),se.push(U),se=o.getArrUnique(se),K=o.getArrUnique(K)}}),d.selectedIds=se;const W=o.getArrRemoveById(K,se);d.selectedUnIds=o.getArrClone(W),d.firstOpenIds=o.getArrUnique(d.firstOpenIds.concat(W)),d.openParentIds=o.getArrUnique(d.openParentIds.concat(W))},k=()=>{if(O(t.list),o.isNonEmptyString(t.value)){const Y=t.value.split(",");$(Y)}f()};e.onMounted(()=>{e.nextTick(()=>{k()})}),e.watch(()=>t.list,Y=>{O(Y);const Z=d.selectedIds,se=o.isNonEmptyString(t.value)?t.value.split(","):[];d.selectedIds=[],$(o.getArrUnique(Z.concat(se)));const K=S(d.selectedIds);K.join(",")!==t.value&&m(K.join(","))}),e.watch(()=>t.value,Y=>{if(Y!==void 0){const Z=d.selectedIds,se=o.isNonEmptyString(Y)?Y.split(","):[],K=S(se),W=S(Z);o.isEqualArr(K,W)||(d.selectedIds=[],$(se))}});const I=()=>{const Y=o.isNonEmptyString(u.prevSearchFoldParentIds)?u.prevSearchFoldParentIds.split(","):[];d.firstOpenIds=o.getArrRemoveById(d.firstOpenIds,Y),(o.isNonEmptyString(t.searchFoldParentIds)?t.searchFoldParentIds.split(","):[]).forEach(se=>{const K=se.toString();d.firstOpenIds.indexOf(K)===-1&&d.firstOpenIds.push(K)}),u.prevSearchFoldParentIds=o.isNonEmptyString(t.searchFoldParentIds)?t.searchFoldParentIds:""},L=()=>{const Y=o.isNonEmptyString(u.prevSearchOpenParentIds)?u.prevSearchOpenParentIds.split(","):[];d.firstOpenIds=o.getArrRemoveById(d.firstOpenIds,Y),d.openParentIds=o.getArrRemoveById(d.openParentIds,Y),(o.isNonEmptyString(t.searchOpenParentIds)?t.searchOpenParentIds.split(","):[]).forEach(se=>{const K=se.toString();d.firstOpenIds.indexOf(K)===-1&&d.firstOpenIds.push(K),d.openParentIds.indexOf(K)===-1&&d.openParentIds.push(K)}),u.prevSearchOpenParentIds=o.isNonEmptyString(t.searchOpenParentIds)?t.searchOpenParentIds:""};e.watch(()=>t.searchOpenParentIds,()=>L()),e.watch(()=>t.searchFoldParentIds,()=>I());const _=Y=>{Array.isArray(Y)&&Y.forEach(Z=>{if(!Z)return;const se=!o.isEmpty(t.searchKeyword)&&!o.isEmpty(t.highlightMode);Z.showTextLabelHtml=se,Z.showTextLabel=se?x(o.isString(Z.name)?Z.name:""):o.isString(Z.name)?Z.name:"",Array.isArray(Z.list)&&_(Z.list)})};e.watch(()=>[t.searchKeyword,t.highlightMode,t.highlightColor],()=>_(d.list));const R=Y=>{const Z=Y.toString();o.isExistValue(d.firstOpenIds,Z)||d.firstOpenIds.push(Z),e.nextTick(()=>{const se=d.openParentIds.indexOf(Z);se===-1?d.openParentIds.push(Z):d.openParentIds.splice(se,1)})},P=Y=>{const Z=Y.toString();if(t.multiple){const W=d.selectedIds.indexOf(Z)===-1,U=N(Z),ae=J(Z);let G=o.getArrClone(d.selectedIds),X=o.getArrClone(d.selectedUnIds);ae.select.del.forEach(j=>{const le=G.indexOf(j);le>-1&&G.splice(le,1)}),ae.select.add.length>0&&(G=G.concat(ae.select.add),G=o.getArrUnique(G)),ae.selectUn.del.forEach(j=>{const le=X.indexOf(j);le>-1&&X.splice(le,1)}),ae.selectUn.add.length>0&&(X=X.concat(ae.selectUn.add),X=o.getArrUnique(X)),U.length>0&&U.forEach(j=>{const le=G.indexOf(j),me=X.indexOf(j);W?le===-1&&G.push(j):le>-1&&G.splice(le,1),me>-1&&X.splice(me,1)});const ee=G.indexOf(Z);ee>-1?G.splice(ee,1):G.push(Z);const F=X.indexOf(Z);F>-1&&X.splice(F,1),d.selectedIds=G,d.selectedUnIds=X}else d.selectedIds=[Z],d.selectedUnIds=[];const se=S(d.selectedIds);p(se.join(","),C(se))};return e.provide("$TreeTop",{isCheckChildren:h}),a({getValue:()=>S(d.selectedIds).join(","),getValueData:()=>{const Y=S(d.selectedIds);return C(Y)},setValue:Y=>{const Z=o.isNonEmptyString(Y)?Y.split(","):[];d.selectedIds=[],$(Z)}}),(Y,Z)=>n.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(l),class:"cl-plaintext-value"},e.toDisplayString(B.value),9,hg)):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(c.value),id:e.unref(l)},[d.list.length>0?(e.openBlock(),e.createBlock(hs,e.mergeProps({key:0,list:d.list,firstOpenIds:d.firstOpenIds,openIds:d.openParentIds,selectIds:d.selectedIds,selectUnIds:d.selectedUnIds},r.value,{onOnSelect:P,onOnShrink:R}),null,16,["list","firstOpenIds","openIds","selectIds","selectUnIds"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,gg))}}),yg=["id"],vg={key:0,class:"selectTree-inText-num"},kg={class:"selectTree-inDropdown-container"},Sg={class:"selectTree-inDropdown-search"},wg={class:"selectTree-inDropdown-body"},gs=e.defineComponent({name:"ClSelectTree",__name:"Index",props:{id:String,value:[String,Number],className:String,disabled:{type:Boolean,default:!1},list:{type:Array,default:()=>[]},placeholder:String,classDropDown:String,multiple:{type:Boolean,default:!1},isClear:{type:Boolean,default:!1},arrowDirection:{type:String,default:"right"},searchPlaceholder:String,searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||",validator:n=>["||","&&"].includes(n)},showTextFormat:String,showDropDownTextFormat:String,isSingleSelectParent:{type:Boolean,default:!1},isOutMerge:{type:Boolean,default:!0},parentKey:{type:String,default:"parentId"},topParentValue:{type:String,default:"0"},onOpenBefore:Function,highlightMode:{type:String,default:"full"},highlightColor:{type:String,default:""},isPlaintext:{type:Boolean,default:!1},plaintextSeparator:{type:String,default:","},plaintextLevelSeparator:{type:String,default:" > "},appendContainer:{type:String,default:""}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:(n,a)=>!0,onInit:()=>!0,onOpen:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElDropdownLayer"),u=e.useTemplateRef("refElList"),r=e.reactive({isOpen:!1,isFirstDataFinish:!1,selectIds:"",selectLabel:[],filterList:[],searchOpenParentIds:"",searchFoldParentIds:"",searchKeyword:""}),c={prevSelectIds:[],originalList:[],dataJson:{}},m=e.computed(()=>{let L={"panel-select-tree":!0};return L=o.getJsonMerge(L,de.getClassNameJson(t.className)),o.getStringByJson(L," ")}),p=e.computed(()=>{let L={"selectTree-inDropdown":!0};return L=o.getJsonMerge(L,de.getClassNameJson(t.classDropDown)),o.getStringByJson(L," ")}),f=L=>{s("update:value",L),s("update:modelValue",L)},h=(L,_)=>{f(L),s("onChange",L,_)},g=()=>{e.nextTick(()=>{s("onInit")})},y=L=>{e.nextTick(()=>{s("onOpen",L)})},V=()=>{if(!r.isOpen){const L=r.selectIds,_=L.split(",");if(!o.isEqualArr(_,c.prevSelectIds)){c.prevSelectIds=_;const P=u.value?u.value.getValueData():[];h(L,P)}}},E=L=>{const _=t.showTextFormat;let R="";return o.isNonEmptyString(_)?R=_.replace(/\$\{(\w+)\}/g,(P,Q)=>o.isString(L?.[Q])?L[Q]:P):R=o.isString(L?.name)?L.name:"",o.encodeHTML(R)},B=L=>o.isEmpty(L)?[]:L.split(",").map(_=>{const R=c.dataJson[_];return R?E(R):o.encodeHTML(_)}),T=L=>{const _=[],R=new Set;let P=L;for(;o.isNonEmptyString(P)&&!R.has(P);){R.add(P);const Q=c.dataJson[P];if(!Q)break;o.isNonEmptyString(Q.name)&&_.unshift(Q.name);const oe=Q[t.parentKey],ue=oe!=null?String(oe):"";if(ue===""||ue===String(t.topParentValue))break;P=ue}return _},D=e.computed(()=>{t.list;const L=o.isString(r.selectIds)?r.selectIds:"";if(o.isEmpty(L))return"";const _=o.isString(t.plaintextLevelSeparator)?t.plaintextLevelSeparator:" > ",R=o.isString(t.plaintextSeparator)?t.plaintextSeparator:",";return L.split(",").map(P=>{const Q=T(P);return o.removeHTMLTags(Q.length>0?Q.join(_):P)}).join(R)}),x=L=>Array.isArray(L)?L.filter(_=>{if(!_)return!1;const R=!o.isUndefined(_.id)&&_.id!==null,P=!o.isEmpty(_[t.parentKey]);return R&&P}):[],O=L=>L===null?"":o.isString(L)||o.isFinite(L)?String(L):"",w=L=>{const _={};return Array.isArray(L)&&L.forEach(R=>{R&&!o.isUndefined(R.id)&&R.id!==null&&(_[String(R.id)]=R)}),_},M=()=>{const L=O(t.value);r.selectIds!==L&&(r.selectIds=L,r.selectLabel=B(L),c.prevSelectIds=L.split(","))},b=(L,_)=>{const R=[];return _===void 0&&(_=new Set),_.has(L)||(_.add(L),c.originalList.forEach(P=>{if(!P)return;const Q=P[t.parentKey];o.isUndefined(Q)||String(Q)===t.topParentValue||String(Q)===String(L)&&(R.push(String(P.id)),R.push(...b(String(P.id),_)))})),R},N=(L,_)=>{if(o.isEmpty(_))return r.searchOpenParentIds="",r.searchFoldParentIds="",L;const R=Array.isArray(t.searchKey)?t.searchKey.filter(W=>o.isString(W)):[];if(R.length===0)return r.searchOpenParentIds="",r.searchFoldParentIds="",L;const P=t.searchKeyType==="&&",Q=L.filter(W=>{if(!W)return!1;const U=R.map(ae=>{const G=W?.[ae];return o.isString(G)?G.includes(_):!1});return P?U.every(Boolean):U.some(Boolean)});if(Q.length===0)return r.searchOpenParentIds="",r.searchFoldParentIds="",L;const oe={};L.forEach(W=>{W&&(oe[String(W.id)]=W)});const ue=new Set,Y=new Set,Z=W=>{const U=oe[String(W)];if(!U)return;const ae=U[t.parentKey];!o.isUndefined(ae)&&String(ae)!==t.topParentValue&&(ue.add(String(ae)),Y.add(String(ae)),Z(String(ae)))};Q.forEach(W=>{const U=String(W.id);ue.add(U),Z(U),b(U).forEach(ae=>ue.add(ae))});const se=L.filter(W=>W&&ue.has(String(W.id)));r.searchOpenParentIds=Array.from(Y).join(",");const K=new Set;return se.forEach(W=>{if(!W)return;const U=String(W.id);if(Y.has(U))return;c.originalList.some(G=>{if(!G)return!1;const X=G[t.parentKey];return!o.isUndefined(X)&&String(X)===U})&&K.add(U)}),r.searchFoldParentIds=Array.from(K).join(","),se},J=()=>{r.isFirstDataFinish||(r.isFirstDataFinish=!0,g())},q=()=>{o.isEmpty(t.list)||J()};e.onMounted(()=>{e.nextTick(()=>{q()})}),e.watch([()=>t.value,()=>t.list],([L,_],[R,P])=>{_!==P&&(c.originalList=x(t.list),c.dataJson=w(c.originalList),r.filterList=c.originalList,r.selectLabel=B(r.selectIds),c.originalList.length>0&&J()),L!==R&&M()},{immediate:!0});const z=L=>{t.disabled||(r.isOpen=L,L?(c.prevSelectIds=r.selectIds.split(","),r.filterList=c.originalList):(r.searchKeyword="",r.searchOpenParentIds="",r.searchFoldParentIds="",V()),y(L))},H=()=>{t.disabled||(r.selectIds="",r.selectLabel=[],c.prevSelectIds=[],V())},v=()=>{d.value&&(d.value.checkIsShowOpen()||d.value.initCompleteOpen())},S=L=>{const _=o.isString(L)?L:"";r.searchKeyword=_,r.filterList=N(c.originalList,_)},C=(L,_)=>{const R=Array.isArray(_)?_:[];r.selectLabel=R.map(P=>E(P)),t.multiple||d.value?.setOpen(!1)};return a({getValue:()=>r.selectIds,getValueData:()=>u.value?u.value.getValueData():[],setValue:L=>{const _=O(L);r.selectIds=_,r.selectLabel=B(_),c.prevSelectIds=_.split(",")}}),(L,_)=>n.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(l),class:"cl-plaintext-value"},e.toDisplayString(D.value),9,yg)):(e.openBlock(),e.createBlock(wn,{key:1,ref_key:"refElDropdownLayer",ref:d,id:e.unref(l),classParent:m.value,classText:"selectTree-inText",classDropDown:p.value,placeholder:n.placeholder,isDisabled:n.disabled,isClear:n.isClear,textLabel:r.selectLabel.join(","),textArrowDirection:n.arrowDirection,appendContainer:n.appendContainer,onOpenBeforeCallback:n.onOpenBefore,onOnChangeOpen:z,onOnClear:H},{textExtend:e.withCtx(()=>[n.multiple?(e.openBlock(),e.createElementBlock("span",vg,[n.multiple&&r.selectLabel.length>1?(e.openBlock(),e.createBlock(Gt,{key:0,num:r.selectLabel.length},null,8,["num"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))]),dropdown:e.withCtx(()=>[e.createElementVNode("div",kg,[e.createElementVNode("div",Sg,[e.createVNode(Qt,{placeholder:n.searchPlaceholder,onOnChange:S},null,8,["placeholder"])]),e.createElementVNode("div",wg,[e.createVNode(ha,{ref_key:"refElList",ref:u,list:r.filterList,value:r.selectIds,"onUpdate:value":_[0]||(_[0]=R=>r.selectIds=R),multiple:n.multiple,textFormat:n.showDropDownTextFormat,isSingleSelectParent:n.isSingleSelectParent,isOutMerge:n.isOutMerge,parentKey:n.parentKey,topParentValue:n.topParentValue,searchOpenParentIds:r.searchOpenParentIds,searchFoldParentIds:r.searchFoldParentIds,searchKeyword:r.searchKeyword,highlightMode:n.highlightMode,highlightColor:n.highlightColor,onOnChange:C,onOnInit:v},null,8,["list","value","multiple","textFormat","isSingleSelectParent","isOutMerge","parentKey","topParentValue","searchOpenParentIds","searchFoldParentIds","searchKeyword","highlightMode","highlightColor"])])])]),_:1},8,["id","classParent","classDropDown","placeholder","isDisabled","isClear","textLabel","textArrowDirection","appendContainer","onOpenBeforeCallback"]))}}),Eg={key:0,class:"sideNav-menu-iconOperate"},ys=e.defineComponent({name:"ClSideMenuMenu",__name:"Menu",props:{activeId:{type:String,default:""},activePId:{type:Array,default:()=>[]},openId:{type:Array,default:()=>[]},list:{type:Array,default:()=>[]}},emits:{onClick:n=>!0},setup(n,{emit:a}){const i=a,t=`sideMenu-${o.getRandom(5)}`,s=d=>!!(d&&d.list&&d.list.length>0),l=d=>{i("onClick",d)};return(d,u)=>(e.openBlock(),e.createElementBlock("ul",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.list,(r,c)=>(e.openBlock(),e.createElementBlock("li",{key:`${t}-${r.id}-${c}`,class:e.normalizeClass({"sideNav-menu-submenu":s(r),"sideNav-menu-active":!s(r)&&n.activeId===r.id,"sideNav-menu-parent-active":s(r)&&n.activePId.includes(r.id)})},[e.createVNode(Vt,{"aria-haspopup":s(r)?"true":void 0,"aria-expanded":s(r)?String(n.openId.includes(r.id)):void 0,"aria-current":s(r)?void 0:n.activeId===r.id?"page":void 0,onOnClick:m=>l(r)},{default:e.withCtx(()=>[s(r)?(e.openBlock(),e.createElementBlock("span",Eg,[e.createVNode(ve,{name:"caret-right",class:e.normalizeClass(["icon-rotate",{"rotate-90":n.openId.includes(r.id)}])},null,8,["class"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("span",null,e.toDisplayString(r.name),1)]),_:2},1032,["aria-haspopup","aria-expanded","aria-current","onOnClick"]),s(r)?(e.openBlock(),e.createBlock(vn,{key:0},{default:e.withCtx(()=>[n.openId.includes(r.id)?(e.openBlock(),e.createBlock(ys,{key:0,activeId:n.activeId,activePId:n.activePId,openId:n.openId,list:r.list,onOnClick:l},null,8,["activeId","activePId","openId","list"])):e.createCommentVNode("",!0)]),_:2},1024)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],2))),128))]))}}),bg=["id"],Cg={class:"sideNav-wrapper sideNav-wrapper-rowMult"},vs=e.defineComponent({name:"ClSideMenu",inheritAttrs:!1,__name:"Index",props:{id:String,className:String,active:String,list:{type:Array,required:!0,default:()=>[]}},emits:{onChangeMenu:n=>!0},setup(n,{emit:a}){const i=n,t=a,s=i.id,l=e.reactive({isMenushrink:!1,menuActive:o.isNonEmptyString(i.active)?i.active:"",menuActiveParent:[],menuOpenPid:[]}),d=e.ref([]),u={menuJson:{}},r=e.computed(()=>{let E={"panel-side-menu":!0};return E=o.getJsonMerge(E,de.getClassNameJson(i.className)),E}),c=E=>{t("onChangeMenu",E)},m=()=>{const E=o.getTreeLastParent(l.menuActive,u.menuJson,!1);let B=[];return E.length>0&&(B=E.map(T=>T.id)),l.menuActiveParent=B,B},p=(E,B,T,D=0)=>{D>50||E.forEach(x=>{if(o.isEmpty(x))return;const{id:O,name:w}=x;if(!o.isNonEmptyString(O)||!o.isUndefined(T[O]))return;const M=x.list,b=o.isArray(M);!b&&!o.isUndefined(M)&&(x.list=void 0),T[O]={id:O,name:w,parentId:B,hasChild:b&&M&&M.length>0},b&&M&&M.length>0&&p(M,O,T,D+1)})},f=E=>E.filter(B=>o.isNonEmptyString(B?.id)).map(B=>{const T=B.list;return o.isArray(T)&&T&&T.length>0&&(B.list=f(T)),B}),h=()=>{const E=f(o.getJsonClone(i.list,!0));if(o.isEmpty(E)){l.menuActive="",l.menuActiveParent=[],l.menuOpenPid=[],u.menuJson={},d.value=[];return}const B=u.menuJson,T=l.menuOpenPid.slice(),D=l.menuActive,x={};p(E,"",x);let O=D;(!o.isNonEmptyString(O)||o.isUndefined(x[O]))&&(O=o.isNonEmptyString(E[0].id)?E[0].id:"");const w=[];Object.keys(x).forEach(M=>{x[M].hasChild&&(o.isUndefined(B[M])||T.includes(M))&&w.push(M)}),u.menuJson=x,d.value=E,l.menuActive=O,l.menuOpenPid=w,O!==D?(m(),o.isNonEmptyString(O)&&c(O)):m()},g=()=>{h()};e.onMounted(()=>{g()}),e.watch(()=>i.list,()=>{h()},{deep:!0}),e.watch(()=>i.active,E=>{if(o.isNonEmptyString(E)&&!o.isUndefined(u.menuJson[E])){l.menuActive=E;const B=m();B.length>0&&B.forEach(T=>{l.menuOpenPid.indexOf(T)===-1&&l.menuOpenPid.push(T)})}});const y=()=>{l.isMenushrink=!l.isMenushrink},V=E=>{const B=E.id;if(o.isNonEmptyString(B))if(E.list&&E.list.length>0){const T=l.menuOpenPid.indexOf(B);T>-1?l.menuOpenPid.splice(T,1):l.menuOpenPid.push(B)}else{if(l.menuActive===B)return;l.menuActive=B,m(),c(l.menuActive)}};return(E,B)=>l.menuActive.length>0?(e.openBlock(),e.createElementBlock("div",e.mergeProps({key:0,id:e.unref(s),class:r.value},E.$attrs),[e.createElementVNode("div",{class:e.normalizeClass({"sideNav-menu":!0,"sideNav-visible":!l.isMenushrink})},[e.createVNode(ys,{list:d.value,activeId:l.menuActive,activePId:l.menuActiveParent,openId:l.menuOpenPid,onOnClick:V},null,8,["list","activeId","activePId","openId"])],2),e.createElementVNode("div",Cg,[e.createVNode(Vt,{className:"sideNav-menu-footer-bar","aria-label":"展开或收起菜单","aria-expanded":String(!l.isMenushrink),onOnClick:y},{default:e.withCtx(()=>[e.createVNode(ve,{name:l.isMenushrink?"angle-double-right":"angle-double-left"},null,8,["name"])]),_:1},8,["aria-expanded"]),e.renderSlot(E.$slots,"default")])],16,bg)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}),ks=n=>{if(o.isNonEmptyString(n)){if(n.indexOf("clIcon-")===0){const a=n.substring(7);return o.isNonEmptyString(a)&&/^[a-zA-Z0-9-]+$/.test(a)?{name:a,className:""}:{name:"question-circle",className:""}}return/^clicon/i.test(n)?{name:"question-circle",className:""}:/^[a-zA-Z0-9-]+$/.test(n)?{name:n,className:""}:{name:"",className:n}}return{name:"question-circle",className:""}},xg=["aria-sort"],Bg=e.defineComponent({name:"ClTableTh",directives:{cltooltip:ct},__name:"Th",props:{isOrder:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},orderSort:{type:Array,default:()=>[]},isUseScrollX:{type:Boolean,default:!1},thIndex:{type:Number,default:0},thInfo:{type:Object,default:()=>({})},fixedLeftIndex:{type:Number,default:-1},fixedRightIndex:{type:Number,default:-1},isInlineWidth:{type:Boolean,default:!1},widthClassPrefix:{type:String,default:"width-"},widthMinClassPrefix:{type:String,default:"width-min-"}},emits:{onClickOrderBy:(n,a,i)=>!0},setup(n,{emit:a}){const i=n,t=a,s=e.computed(()=>ks(i.thInfo?.tipIcon)),l=e.computed(()=>o.isObject(i.thInfo)&&!o.isEmpty(i.thInfo)?i.thInfo:{}),d=e.computed(()=>!i.isOrder||o.isEmpty(l.value)?!1:o.isEmpty(l.value.sort)?!0:l.value.sort===!0),u=e.computed(()=>d.value&&!i.disabled),r=e.computed(()=>{const V=i.thInfo?.tipMsg;if(!o.isNonEmptyString(V))return;const E=o.removeHTMLTags(V);return o.isNonEmptyString(E)?E:void 0}),c=e.computed(()=>{if(!d.value)return"";const V=o.isEmpty(i.orderSort)?[]:i.orderSort;return V.length>0&&V[0]===i.thIndex?V.length===2?V[1]==="asc"||V[1]==="desc"?V[1]:"none":V.length===1?"desc":"none":"none"}),m=e.computed(()=>{if(c.value==="asc")return"ascending";if(c.value==="desc")return"descending";if(c.value==="none")return"none"}),p=e.computed(()=>{const V={},E=l.value;if(!o.isEmpty(E.width)&&g(E.width)&&(V[`${i.widthClassPrefix}${E.width}`]=!0),!o.isEmpty(E.widthMin)&&g(E.widthMin)&&i.isUseScrollX&&(V[`${i.widthMinClassPrefix}${E.widthMin}`]=!0),(i.fixedLeftIndex>-1||i.fixedRightIndex>-1)&&(V["th-hidden"]=i.fixedLeftIndex>-1&&i.thIndex>i.fixedLeftIndex||i.fixedRightIndex>-1&&i.thIndex<i.fixedRightIndex),d.value){V["th-sort"]=!0,V["sort-none"]=!0,V["th-sort-near"]=E.sortNear===!0;const T=c.value;(T==="asc"||T==="desc")&&(V[`sort-${T}`]=!0,V["sort-none"]=!1)}o.isNonEmptyString(E.tipMsg)&&(V["th-tip"]=!0,V["th-tip-sideAlign"]=E.tipSideAlign===!0),i.disabled&&(V["th-disabled"]=!0),o.isNonEmptyString(E.textAlign)&&o.isExistValue(["left","center","right"],E.textAlign)&&(V[`text-${E.textAlign}`]=!0);let B=V;return B=o.getJsonMerge(B,de.getClassNameJson(E.className)),B=o.getJsonMerge(B,de.getClassNameJson(E.classTh)),B}),f=e.computed(()=>{const V={};if(!i.isInlineWidth)return V;const E=l.value;return!o.isEmpty(E.width)&&g(E.width)&&(V.width=o.isFinite(Number(E.width))?`${Number(E.width)}px`:`${E.width}`),!o.isEmpty(E.widthMin)&&g(E.widthMin)&&i.isUseScrollX&&(V.minWidth=o.isFinite(Number(E.widthMin))?`${Number(E.widthMin)}px`:`${E.widthMin}`),V}),h=(V,E)=>{t("onClickOrderBy",V,i.thIndex,E)},g=V=>o.isString(V)||o.getTypeof(V)==="number"&&o.isFinite(V),y=()=>{if(u.value){const V=c.value==="desc"?"asc":"desc";h(l.value,V)}};return(V,E)=>{const B=e.resolveDirective("cltooltip");return!e.unref(o).isBoolean(n.thInfo?.visible)||n.thInfo.visible?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass(p.value),style:e.normalizeStyle(f.value),scope:"col","aria-sort":m.value},[e.createElementVNode("span",{class:"th-title",onClick:y},[e.renderSlot(V.$slots,"default")]),e.unref(o).isNonEmptyString(n.thInfo?.tipMsg)?e.withDirectives((e.openBlock(),e.createBlock(ve,{key:0,name:s.value.name,className:s.value.className,class:"th-tip-icon",role:"img","aria-label":r.value},null,8,["name","className","aria-label"])),[[B,{html:n.thInfo.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),c.value!==""?(e.openBlock(),e.createElementBlock("i",{key:2,class:"tr-sort-icon","aria-hidden":"true",onClick:y})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],14,xg)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}}),Ko=e.defineComponent({name:"ClTableTd",directives:{cltooltip:ct},__name:"Td",props:{tdIndex:{type:Number,default:0},tdInfo:{type:Object,default:()=>({})},isOrder:{type:Boolean,default:!1},isUseScrollX:{type:Boolean,default:!1},fixedLeftIndex:{type:Number,default:-1},fixedRightIndex:{type:Number,default:-1},isInlineWidth:{type:Boolean,default:!1},widthClassPrefix:{type:String,default:"width-"},widthMinClassPrefix:{type:String,default:"width-min-"},useType:{type:String,default:"td",validator:n=>["td","total"].indexOf(n)>-1}},setup(n){const a=n,i=e.computed(()=>ks(a.tdInfo?.tipIcon)),t=e.computed(()=>o.isEmpty(a.tdInfo)?{}:a.tdInfo),s=e.computed(()=>{const r=a.tdInfo?.tipMsg;if(!o.isNonEmptyString(r))return;const c=o.removeHTMLTags(r);return o.isNonEmptyString(c)?c:void 0}),l=e.computed(()=>{const r={},c=t.value;!o.isEmpty(c.width)&&u(c.width)&&(r[`${a.widthClassPrefix}${c.width}`]=!0),!o.isEmpty(c.widthMin)&&u(c.widthMin)&&a.isUseScrollX&&(r[`${a.widthMinClassPrefix}${c.widthMin}`]=!0),(a.fixedLeftIndex>-1||a.fixedRightIndex>-1)&&(r["td-hidden"]=a.fixedLeftIndex>-1&&a.tdIndex>a.fixedLeftIndex||a.fixedRightIndex>-1&&a.tdIndex<a.fixedRightIndex),a.isOrder&&(o.isEmpty(c.sort)||c.sort===!0)&&(r["td-sort"]=!0,r["td-sort-near"]=c.sortNear===!0),o.isNonEmptyString(c.tipMsg)&&(r["td-tip"]=!0,r["td-tip-sideAlign"]=c.tipSideAlign===!0),o.isNonEmptyString(c.textAlign)&&o.isExistValue(["left","center","right"],c.textAlign)&&(r[`text-${c.textAlign}`]=!0);let m=r;return m=o.getJsonMerge(m,de.getClassNameJson(c.className)),a.useType==="td"?m=o.getJsonMerge(m,de.getClassNameJson(c.classTd)):a.useType==="total"&&(m=o.getJsonMerge(m,de.getClassNameJson(c.classTotal))),m}),d=e.computed(()=>{const r={};if(!a.isInlineWidth)return r;const c=t.value;return!o.isEmpty(c.width)&&u(c.width)&&(r.width=o.isFinite(Number(c.width))?`${Number(c.width)}px`:`${c.width}`),!o.isEmpty(c.widthMin)&&u(c.widthMin)&&a.isUseScrollX&&(r.minWidth=o.isFinite(Number(c.widthMin))?`${Number(c.widthMin)}px`:`${c.widthMin}`),r}),u=r=>o.isString(r)||o.getTypeof(r)==="number"&&o.isFinite(r);return(r,c)=>{const m=e.resolveDirective("cltooltip");return!e.unref(o).isBoolean(n.tdInfo?.visible)||n.tdInfo.visible?(e.openBlock(),e.createElementBlock("td",{key:0,class:e.normalizeClass(l.value),style:e.normalizeStyle(d.value)},[e.renderSlot(r.$slots,"default"),e.unref(o).isNonEmptyString(n.tdInfo?.tipMsg)?e.withDirectives((e.openBlock(),e.createBlock(ve,{key:0,name:i.value.name,className:i.value.className,class:"td-tip-icon",role:"img","aria-label":s.value},null,8,["name","className","aria-label"])),[[m,{html:n.tdInfo.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}}),Dg=["aria-hidden"],Ig={key:0},Tg={key:0},Oo=99999999,Ao=e.defineComponent({name:"ClTableHead",__name:"Head",props:{columns:{type:Array,default:()=>[]},isOrder:{type:Boolean,default:!1},orderSort:{type:Array,default:()=>[]},isShowTotal:{type:Boolean,default:!1},totalInfo:{type:Object,default:()=>({})},keyIndex:String,width:{type:String,default:"none"},minWidth:{type:String,default:"none"},hoverIndex:{type:Number,default:-1},isUseScrollX:{type:Boolean,default:!1},isShowRadio:{type:Boolean,default:!1},isShowCheckbox:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},isShowCheckboxAll:{type:Boolean,default:!0},checkboxAllValue:{type:Boolean,default:!1},fixedType:{type:String,default:"",validator:n=>["","left","right"].indexOf(n)>-1},fixedLeftIndex:{type:Number,default:-1,validator:n=>n>=-1},fixedRightIndex:{type:Number,default:-1,validator:n=>n>=-1},isInlineWidth:{type:Boolean,default:!1},widthClassPrefix:{type:String,default:"width-"},widthMinClassPrefix:{type:String,default:"width-min-"}},emits:{onClickAll:()=>!0,onClickOrderBy:(n,a,i)=>!0,onHoverIn:n=>!0,onHoverOut:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.useTemplateRef("refElTable"),d=e.computed(()=>({"table-default":!0,"table-base":!0})),u=e.computed(()=>{const D={};return o.isEmpty(t.fixedType)?t.isUseScrollX&&o.isNonEmptyString(t.minWidth)&&t.minWidth!=="none"&&(D.minWidth=t.minWidth):o.isNonEmptyString(t.width)&&t.width!=="none"&&(D.width=t.width),D}),r=D=>D?o.isUndefined(D.title)?o.isUndefined(D.data)?"":D.data:D.title:"",c=(D,x)=>o.isUndefined(D)||!x?"":o.isEmpty(x.format)?D:o.getValueByFormat(D,x.format??"",x.formatExt),m=(D,x)=>!D||!x?"":c(D[x.data],x);e.watch(()=>t.isShowTotal,D=>{!D&&t.hoverIndex===Oo&&s("onHoverOut")});const p=()=>{s("onClickAll")},f=(D,x,O)=>{s("onClickOrderBy",D,x,O)},h=()=>{s("onHoverIn",Oo)},g=()=>{s("onHoverOut")};return a({getOffsetHeight:()=>l.value?l.value.offsetHeight:0,getRcWidth:()=>{let D=0;if((t.isShowRadio||t.isShowCheckbox)&&l.value){const x=l.value.querySelector(".th-rc");x&&(D=x.clientWidth)}return D},getPaddingLr:()=>{let D=0;if(!l.value)return D;const x=l.value.querySelectorAll("th:not(.th-rc)");for(let O=0;O<x.length;O++){const w=de.getStyle(x[O]),M=parseFloat(w.paddingLeft),b=parseFloat(w.paddingRight),N=o.isFinite(M)?M:0,J=o.isFinite(b)?b:0;D+=N+J}return D},getElTh:()=>l.value?l.value.querySelectorAll("th"):[],getTotalHeight:()=>{let D=0;if(t.isShowTotal&&l.value){const x=l.value.querySelector(".tr-total");x&&(D=x.clientHeight)}return D}}),(D,x)=>(e.openBlock(),e.createElementBlock("table",{class:e.normalizeClass(d.value),style:e.normalizeStyle(u.value),"aria-hidden":!e.unref(o).isEmpty(n.fixedType),ref_key:"refElTable",ref:l},[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[n.isShowRadio||n.isShowCheckbox?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass({"th-rc":!0,"th-hidden":n.fixedRightIndex>-1}),scope:"col"},[n.isShowCheckbox&&n.isShowCheckboxAll?(e.openBlock(),e.createBlock(dt,{key:0,forId:e.unref(o).isNonEmptyString(n.keyIndex)?`${n.keyIndex}_${n.fixedType}_cb_all`:void 0,value:n.checkboxAllValue,disabled:n.disabled,onOnChange:p},null,8,["forId","value","disabled"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.columns,(O,w)=>(e.openBlock(),e.createBlock(Bg,{key:`${n.keyIndex}_${n.fixedType}_head_th_${w}`,thInfo:O,thIndex:w,isOrder:n.isOrder,disabled:n.disabled,orderSort:n.orderSort,isUseScrollX:n.isUseScrollX,fixedLeftIndex:n.fixedLeftIndex,fixedRightIndex:n.fixedRightIndex,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix,onOnClickOrderBy:f},{default:e.withCtx(()=>[e.renderSlot(D.$slots,`th_${O?.data??""}`,{data:O},()=>[e.createElementVNode("span",null,e.toDisplayString(r(O)),1)])]),_:2},1032,["thInfo","thIndex","isOrder","disabled","orderSort","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))])]),n.isShowTotal?(e.openBlock(),e.createElementBlock("tbody",Ig,[e.createElementVNode("tr",{class:e.normalizeClass({"tr-total":!0,"tr-hover":n.hoverIndex===Oo}),onMouseenter:h,onMouseleave:g},[n.isShowRadio||n.isShowCheckbox?(e.openBlock(),e.createElementBlock("td",Tg)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.columns,(O,w)=>(e.openBlock(),e.createBlock(Ko,{key:`${n.keyIndex}_${n.fixedType}_body_total_td_${w}`,isOrder:n.isOrder,tdIndex:w,tdInfo:O,isUseScrollX:n.isUseScrollX,fixedLeftIndex:n.fixedLeftIndex,fixedRightIndex:n.fixedRightIndex,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix,useType:"total"},{default:e.withCtx(()=>[e.renderSlot(D.$slots,`total_${O?.data??""}`,{data:n.totalInfo},()=>[e.createTextVNode(e.toDisplayString(m(n.totalInfo,O)),1)])]),_:2},1032,["isOrder","tdIndex","tdInfo","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))],34)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],14,Dg))}}),Ng=["id"],Vg=e.defineComponent({name:"ClTableTdChecked",__name:"TdChecked",props:{id:String,value:{type:Boolean,default:!1},className:String,disabled:{type:Boolean,default:!1},isShowRadio:{type:Boolean,default:!1},isShowCheckbox:{type:Boolean,default:!1},keyIndex:String,info:{type:Object,default:()=>({})}},setup(n){const a=n,i=a.id,t=e.computed(()=>r("cb")),s=e.computed(()=>r("rd")),l=e.computed(()=>a.value===!0),d=e.computed(()=>a.disabled===!0||o.isBoolean(a.info?.isDisabled)&&a.info.isDisabled),u=e.computed(()=>{const c={"th-rc":!0};return o.getJsonMerge(c,de.getClassNameJson(a.className))}),r=c=>o.isNonEmptyString(a.keyIndex)?`${a.keyIndex}_${c}`:void 0;return(c,m)=>n.isShowRadio||n.isShowCheckbox?(e.openBlock(),e.createElementBlock("td",{key:0,id:e.unref(i),class:e.normalizeClass(u.value)},[n.isShowCheckbox?(e.openBlock(),e.createBlock(dt,{key:0,forId:t.value,value:l.value,disabled:d.value},null,8,["forId","value","disabled"])):n.isShowRadio?(e.openBlock(),e.createBlock(aa,{key:1,forId:s.value,name:s.value,value:l.value,disabled:d.value},null,8,["forId","name","value","disabled"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))],10,Ng)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}),_g=["onClick","onMouseenter"],Mg=["onMouseenter"],Og=["colspan"],Ag={key:0,class:"panel-elastic-load",role:"status","aria-live":"polite"},Lg={class:"elastic-load-container"},$g=["data-elastic-id"],Fg=["onMouseenter"],Pg=["colspan"],Rg={class:"panel-elastic-load",role:"status","aria-live":"polite"},Hg={class:"elastic-load-container"},Ug=["onMouseenter"],zg={key:2},Jg=["colspan"],Kg={class:"panel-table-empty",role:"status"},Lo=e.defineComponent({name:"ClTableBody",__name:"Body",props:{columns:{type:Array,default:()=>[]},list:{type:Array,default:()=>[]},disabled:{type:Boolean,default:!1},isOrder:{type:Boolean,default:!1},selectValue:{type:Array,default:()=>[]},keyIndex:String,width:{type:String,default:"none"},minWidth:{type:String,default:"none"},hoverIndex:{type:Number,default:-1},hoverElasticIndex:{type:Number,default:-1},isUseScrollX:{type:Boolean,default:!1},colspanCount:{type:Number,default:1},isRunLoading:{type:Boolean,default:!1},isShowRadio:{type:Boolean,default:!1},isShowCheckbox:{type:Boolean,default:!1},isElastic:{type:Boolean,default:!1},elasticOpen:{type:Array,default:()=>[]},elasticLoading:{type:Array,default:()=>[]},elasticType:{type:String,default:"default",validator:n=>["default","sameDataStructure"].indexOf(n)>-1},elasticData:{type:Object,default:()=>({})},fixedType:{type:String,default:""},fixedLeftIndex:{type:Number,default:-1},fixedRightIndex:{type:Number,default:-1},isInlineWidth:{type:Boolean,default:!1},widthClassPrefix:{type:String,default:"width-"},widthMinClassPrefix:{type:String,default:"width-min-"},trIntervalNum:{type:Number,default:-1},isStriped:{type:Boolean,default:!1},emptyText:String},emits:{onClickTr:(n,a,i)=>!0,onHoverIn:(n,a)=>!0,onHoverOut:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("common");const u=e.useTemplateRef("refElTable"),r=e.ref(new Set),c=e.computed(()=>new Set((Array.isArray(t.selectValue)?t.selectValue:[]).filter(v=>!o.isUndefined(v)).map(v=>String(v)))),m=e.computed(()=>new Set((Array.isArray(t.elasticLoading)?t.elasticLoading:[]).filter(v=>!o.isUndefined(v)).map(v=>String(v)))),p=e.computed(()=>new Set((Array.isArray(t.elasticOpen)?t.elasticOpen:[]).filter(v=>!o.isUndefined(v)).map(v=>String(v)))),f=e.computed(()=>{const v=Number(t.colspanCount);return o.isFinite(v)&&v>=1?Math.floor(v):1}),h=e.computed(()=>({"table-default":!0,"table-base":!0,"table-empty":o.isEmpty(t.list)})),g=e.computed(()=>{const v={};return o.isNonEmptyString(t.fixedType)?o.isNonEmptyString(t.width)&&t.width!=="none"&&(v.width=t.width):t.isUseScrollX&&o.isNonEmptyString(t.minWidth)&&t.minWidth!=="none"&&(v.minWidth=t.minWidth),v}),y=(v,S,C)=>{s("onClickTr",v,S,C)},V=(v,S=-1)=>{s("onHoverIn",v,S)},E=()=>{s("onHoverOut")},B=(v,S)=>o.isEmpty(v)||!S?"":o.isEmpty(S.format)?v:o.getValueByFormat(v,S.format??"",S.formatExt),T=v=>{const S=t.elasticData||{};return Object.prototype.hasOwnProperty.call(S,v)?S[v]:[]},D=v=>!o.isEmpty(v)&&!o.isEmpty(v.id)&&c.value.has(v.id.toString()),x=v=>!o.isEmpty(v)&&!o.isEmpty(v.id)&&m.value.has(v.id.toString());return a({getWidth:()=>u.value?u.value.clientWidth:0,getHeight:()=>u.value?u.value.clientHeight:0,setElasticWidth:()=>{if(!u.value)return;const v=u.value.parentNode;if(!v)return;const S=u.value.querySelectorAll(".panel-elastic-load"),C=v.clientWidth;for(let $=0;$<S.length;$++)S[$].style.width=`${C}px`},setElasticHeight:v=>{if(!u.value)return;const S=u.value.querySelector(`[data-elastic-id="${CSS.escape(v)}"]`);if(S){const C=S.parentNode;if(C){S.style.height="",C.style.height="";const k=`${S.clientHeight}px`;S.style.height=k,C.style.height=k}const $=r.value;$.has(v)||(r.value=new Set($).add(v))}},removeElasticAbsolute:v=>{if(r.value.has(v)){const S=new Set(r.value);S.delete(v),r.value=S}},clearElasticAbsolute:()=>{r.value.size>0&&(r.value=new Set)},setElasticLoadLeft:v=>{if(!u.value)return;const S=u.value.querySelectorAll(".panel-elastic-load"),C=o.isFinite(v)?Math.max(0,v):0;for(let $=0;$<S.length;$++)S[$].style.left=`${C}px`},setEmptyWidth:()=>{if(!u.value)return;const v=u.value.querySelector(".panel-table-empty");if(v){const S=u.value.parentNode;if(S){const C=S.clientWidth;v.style.width=`${C}px`}}},setEmptyLeft:v=>{const S=u.value?u.value.querySelector(".panel-table-empty"):null;if(S){const C=o.isFinite(v)?Math.max(0,v):0;S.style.left=`${C}px`}}}),(v,S)=>(e.openBlock(),e.createElementBlock("table",{class:e.normalizeClass(h.value),style:e.normalizeStyle(g.value),ref_key:"refElTable",ref:u},[e.createElementVNode("tbody",null,[e.unref(o).isEmpty(n.list)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(n.list,(C,$)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${n.keyIndex}_${n.fixedType}_body_tr_${$}`},[e.createElementVNode("tr",{class:e.normalizeClass({odd:n.isStriped&&$%2===0,"tr-customInterval-odd":n.isStriped&&n.trIntervalNum>0&&Math.floor($/n.trIntervalNum)%2===0,"tr-customInterval-even":n.isStriped&&n.trIntervalNum>0&&Math.floor($/n.trIntervalNum)%2===1,"tr-disabled":e.unref(o).isBoolean(C?.isDisabled)&&C.isDisabled,"tr-selected":D(C),"tr-hover":n.hoverIndex===$}),onClick:k=>y(k,C,$),onMouseenter:k=>V($),onMouseleave:E},[n.isShowRadio||n.isShowCheckbox?(e.openBlock(),e.createBlock(Vg,{key:0,keyIndex:`${n.keyIndex}_${n.fixedType}_body_tr_${$}`,isShowRadio:n.isShowRadio,isShowCheckbox:n.isShowCheckbox,value:D(C),info:C,disabled:n.disabled},null,8,["keyIndex","isShowRadio","isShowCheckbox","value","info","disabled"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.columns,(k,I)=>(e.openBlock(),e.createBlock(Ko,{key:`${n.keyIndex}_${n.fixedType}_body_tr_${$}_td_${I}`,isOrder:n.isOrder,tdIndex:I,tdInfo:k,isUseScrollX:n.isUseScrollX,fixedLeftIndex:n.fixedLeftIndex,fixedRightIndex:n.fixedRightIndex,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix},{default:e.withCtx(()=>[e.renderSlot(v.$slots,`td_${k?.data??""}`,{data:C,trIndex:$},()=>[e.createTextVNode(e.toDisplayString(B(C&&k?C[k.data]:void 0,k)),1)])]),_:2},1032,["isOrder","tdIndex","tdInfo","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))],42,_g),n.isElastic&&!e.unref(o).isEmpty(C?.id)&&p.value.has(C.id.toString())?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.elasticType==="default"?(e.openBlock(),e.createElementBlock("tr",{key:0,class:e.normalizeClass({"tr-elastic":!0,"tr-hover":n.hoverIndex===$}),onMouseenter:k=>V($),onMouseleave:E},[e.createElementVNode("td",{colspan:f.value,class:e.normalizeClass({"td-elastic-load":x(C)})},[x(C)?(e.openBlock(),e.createElementBlock("div",Ag,[e.createElementVNode("div",Lg,[e.createVNode(lt,{theme:"circleBubble",size:"large"})])])):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["elastic-container",{"elastic-container-absolute":r.value.has(C.id.toString())}]),"data-elastic-id":C.id},[e.renderSlot(v.$slots,"tr_elastic_children",{data:C,trIndex:$})],10,$g))],10,Og)],42,Mg)):n.elasticType==="sameDataStructure"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[x(C)?(e.openBlock(),e.createElementBlock("tr",{key:0,class:e.normalizeClass({"tr-elastic":!0,"tr-hover":n.hoverIndex===$}),onMouseenter:k=>V($),onMouseleave:E},[e.createElementVNode("td",{colspan:f.value,class:"td-elastic-load"},[e.createElementVNode("div",Rg,[e.createElementVNode("div",Hg,[e.createVNode(lt,{theme:"circleBubble",size:"large"})])])],8,Pg)],42,Fg)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(T(C.id.toString()),(k,I)=>(e.openBlock(),e.createElementBlock("tr",{key:`${n.keyIndex}_${n.fixedType}_body_tr_${$}_elastic_${I}`,class:e.normalizeClass({"tr-elastic-sameDataStructure":!0,odd:n.isStriped&&I%2===0,"tr-disabled":e.unref(o).isBoolean(k?.isDisabled)&&k.isDisabled,"tr-hover":n.hoverElasticIndex===I&&n.hoverIndex===$}),onMouseenter:L=>V($,I),onMouseleave:E},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(n.columns,(L,_)=>(e.openBlock(),e.createBlock(Ko,{key:`${n.keyIndex}_${n.fixedType}_body_tr_${$}_elastic_${I}_td_${_}`,isOrder:n.isOrder,tdIndex:_,tdInfo:L,isUseScrollX:n.isUseScrollX,fixedLeftIndex:n.fixedLeftIndex,fixedRightIndex:n.fixedRightIndex,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix},{default:e.withCtx(()=>[e.renderSlot(v.$slots,`td_elastic_${L?.data??""}`,{data:k,trIndex:$,trElasticInx:I},()=>[e.createTextVNode(e.toDisplayString(B(k&&L?k[L.data]:void 0,L)),1)])]),_:2},1032,["isOrder","tdIndex","tdInfo","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))],42,Ug))),128))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))),128)),e.unref(o).isEmpty(n.list)&&!n.isRunLoading&&!e.unref(o).isNonEmptyString(n.fixedType)?(e.openBlock(),e.createElementBlock("tr",zg,[e.createElementVNode("td",{colspan:f.value,class:"td-empty"},[e.createElementVNode("div",Kg,e.toDisplayString(e.unref(o).isNonEmptyString(n.emptyText)?n.emptyText:e.unref(l).noResultsText),1)],8,Jg)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])],6))}});function Wg(n){if(!Array.isArray(n))return[];const a=[];return n.forEach(i=>{if(o.isEmpty(i))return;const t=i;!(o.isBoolean(t.isDisabled)?t.isDisabled:!1)&&!o.isEmpty(t.id)&&a.push(String(t.id))}),a}function jg(n,a,i=!1){if(!Array.isArray(n)||n.length===0)return[];const t=[];return n.forEach(s=>{const l=String(s);a.includes(l)&&t.push(l)}),i&&t.length>1?[t[0]]:t}function Yg(n,a){return a.length>0&&a.length===n.length}function qg(n,a){return n.filter(i=>!a.includes(i))}const Xg=["id"],Gg={class:"table-wrapper"},Qg={key:0,class:"table-fixed-column-left"},Zg={key:2,class:"table-fixed-column-right"},ey={key:0,class:"table-scroll-occupy-container"},ty={key:2,class:"table-fixed-column-scrollX"},ny={key:4,class:"table-fixed-head-load"},oy={key:0,class:"table-fixed-column-left"},ay={key:2,class:"table-fixed-column-right"},iy={key:1,class:"table-fixed-column-scrollX"},sy={key:2,class:"table-footer-wrapper"},ly={key:0,class:"table-load",role:"status","aria-live":"polite"},ry={class:"table-load-wrapper"},ai=15,cy=30,uy=180,dy=50,ii=300,Ss=e.defineComponent({name:"ClTable",__name:"Index",props:{id:String,className:String,disabled:{type:Boolean,default:!1},columns:{type:Array,default:()=>[]},list:{type:Array,default:()=>[]},totalLength:Number,totalData:{type:Object,default:()=>({})},isServer:{type:Boolean,default:!0},isParamTriggerServer:{type:Boolean,default:!1},isLoading:{type:Boolean,default:!0},loadTheme:{type:String,default:"circleBubble"},loadColor:{type:String,default:"var(--cl-primary, #1088f0)"},isShowInitLoadIng:{type:Boolean,default:!0},isPaginate:{type:Boolean,default:!0},pageOffset:{type:Number,default:0},isPaginateLimit:{type:Boolean,default:!0},paginateLimit:{type:Number,default:10},paginateLimitData:{type:Array,default:()=>[]},isOrder:{type:Boolean,default:!1},orderSort:{type:Array,default:()=>[]},selectValue:{type:[String,Number],default:""},checkedRowType:{type:String,default:"none",validator:n=>["none","radio","checkbox"].indexOf(n)>-1},isShowCheckboxAll:{type:Boolean,default:!0},isScrollX:{type:Boolean,default:!1},isScrollXBottom:{type:Boolean,default:!1},isFixedHead:{type:Boolean,default:!1},scrollY:{type:Number,default:-1},fixedColumnLeftIndex:{type:Number,default:-1},fixedColumnRightIndex:{type:Number,default:-1},isInlineWidth:{type:Boolean,default:!1},widthClassPrefix:{type:String,default:"width-"},widthMinClassPrefix:{type:String,default:"width-min-"},isClickRowLinkage:{type:Boolean,default:!1},isElastic:{type:Boolean,default:!1},isElasticLoad:{type:Boolean,default:!0},rowClickKeyInvalid:{type:String,default:".tr-click-invalid"},rowClickKeyElastic:{type:String,default:".tr-click-elastic"},elasticIconCls:{type:Array,default:()=>[]},elasticType:{type:String,default:"default",validator:n=>["default","sameDataStructure"].indexOf(n)>-1},elasticData:{type:Object,default:()=>({})},trIntervalNum:{type:Number,default:-1},isStriped:{type:Boolean,default:!1},emptyText:String,isHead:{type:Boolean,default:!0}},emits:{onGetData:n=>!0,onClickRow:(n,a,i)=>!0,onClickElastic:(n,a,i,t,s)=>!0,onChangeChecked:(n,a,i)=>!0,onChangeParams:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.useSlots(),d=re=>{let fe=[];if(t.isOrder){const ge=o.isEmpty(re)?[]:re;let we=[0,"desc"];const Ce=o.isEmpty(t.columns)?[]:t.columns;for(let Be=0;Be<Ce.length;Be+=1){const Oe=Ce[Be];if(o.isEmpty(Oe))continue;const qe=Oe.sort===void 0||Oe.sort===null?!0:Oe.sort===!0,Ke=o.isBoolean(Oe.visible)?Oe.visible:!0;if(qe&&Ke){we=[Be,"desc"];break}}if(ge.length===0)fe=we;else{const Be=Ce[ge[0]];if(o.isEmpty(Be))fe=we;else{const Oe=Be.sort===void 0||Be.sort===null?!0:Be.sort===!0,qe=o.isBoolean(Be.visible)?Be.visible:!0,Ke=Array.isArray(ge)?ge[0]:void 0,Bt=Array.isArray(ge)&&(ge[1]==="asc"||ge[1]==="desc")?ge[1]:void 0;fe=Oe&&qe&&!o.isUndefined(Ke)?[Ke,Bt??"desc"]:we}}}return fe},u=()=>{let re=1;return t.paginateLimit>0&&t.pageOffset>=0&&(re=Math.floor(t.pageOffset/t.paginateLimit)+1),re},r=d(t.orderSort),c={dataJson:o.getJsonByList(t.list),changeNewPaginate:{pages:u(),limit:t.paginateLimit},changeNewSort:{orderIndex:r[0],orderBy:r[1]},sortLocalData:[],scrollBody:{left:0},scrollHead:{left:0},resizeEvent:null,timerBody:null,pendingCanceled:!1},m={observerBodyScrollY:null},p=`table-${o.getRandom(5)}`,f=t.id,h=e.useTemplateRef("refElHeadWrapper"),g=e.useTemplateRef("refElHeadContainer"),y=e.useTemplateRef("refElHeadMain"),V=e.useTemplateRef("refElHeadTable"),E=e.useTemplateRef("refElHeadFixedScrollX"),B=e.useTemplateRef("refElBodyWrapper"),T=e.useTemplateRef("refElBodyContainer"),D=e.useTemplateRef("refElBodyMain"),x=e.useTemplateRef("refElBodyTable"),O=e.useTemplateRef("refElBodyFixedScrollX"),w=e.reactive({isRunLoading:!1,isCheckedRadio:t.checkedRowType==="radio",isCheckedCheckbox:t.checkedRowType==="checkbox",colspanCount:0,hoverTrIndex:-1,hoverTrElasticIndex:-1,totalHeight:"0"}),M=e.ref([]),b=e.reactive({pages:c.changeNewPaginate.pages,limit:c.changeNewPaginate.limit}),N=e.ref(r),J=e.ref(!1),q=()=>{const re=t.selectValue;return o.isNonEmptyString(re)?o.split(re):o.isNumber(re)?o.split(re.toString()):[]},z=e.ref(q()),H=e.reactive({open:[],loading:[]}),v=e.reactive({isShow:!1,minWidth:"auto",posType:"left"}),S=e.ref(!1),C=e.reactive({totalWidth:"0",centerWidth:"0",leftColumnLength:0,leftWidth:"0",rightColumnLength:0,rightWidth:"0"}),$=e.reactive({isShow:!1,width:"auto",height:"auto"}),k=e.reactive({headHeight:0});let I=null,L=null,_=0;const R=e.computed(()=>Object.keys(l).filter(re=>re.indexOf("th_")===0)),P=e.computed(()=>{const re=Object.keys(l).filter(fe=>fe.indexOf("td_")===0&&fe.indexOf("td_elastic_")!==0);return t.isElastic&&re.push("tr_elastic_children"),re}),Q=e.computed(()=>Object.keys(l).filter(re=>re.indexOf("total_")===0)),oe=e.computed(()=>Object.keys(l).filter(re=>re.indexOf("td_elastic_")===0)),ue=e.computed(()=>t.isShowCheckboxAll&&M.value.length>0),Y=e.computed(()=>!o.isEmpty(t.totalData)&&M.value.length>0),Z=e.computed(()=>t.isServer?o.isFinite(t.totalLength)?t.totalLength:0:o.isFinite(t.totalLength)?t.totalLength:t.list?.length||0),se=e.computed(()=>t.isScrollX||t.isScrollXBottom),K=e.computed(()=>t.scrollY>0),W=e.computed(()=>t.isHead&&t.fixedColumnLeftIndex>-1&&se.value),U=e.computed(()=>t.isHead&&t.fixedColumnRightIndex>-1&&se.value&&t.fixedColumnRightIndex>t.fixedColumnLeftIndex+1),ae=e.computed(()=>{const re={"panel-table":!0,"table-disabled":t.disabled};return w.isRunLoading&&(re["table-loading"]=!0),o.osType().isMobile&&(re["table-mob"]=!0),o.getJsonMerge(re,de.getClassNameJson(t.className))}),G=e.computed(()=>{const re={"table-head-wrapper":!0,"table-scrollY":K.value,"table-scroll-occupy-y":S.value};return $.isShow&&(re["table-fixed-head"]=!0),re}),X=e.computed(()=>{const re={"table-head-container":!0};return t.isScrollX&&(re["table-scrollX"]=!0),(W.value||U.value)&&(re["table-fixed-column"]=!0,v.isShow?re[`table-scrollX-${v.posType}`]=!0:re["table-scrollX-none"]=!0),re}),ee=e.computed(()=>{const re={"table-body-wrapper":!0,"table-scrollY":K.value,"table-scrollX":t.isScrollX,"table-scrollX-bottom":v.isShow};return re["table-scroll-borderT0"]=v.isShow&&t.isScrollX,(W.value||U.value)&&(re["table-fixed-column"]=!0,v.isShow?re[`table-scrollX-${v.posType}`]=!0:re["table-scrollX-none"]=!0),re}),F=e.computed(()=>{const re={};if((W.value||U.value)&&K.value){const fe=v.isShow?Math.max(0,t.scrollY-ai):t.scrollY;re.maxHeight=`${fe}px`}return re}),j=e.computed(()=>{const re={};return W.value||U.value||K.value&&(re.maxHeight=`${t.scrollY}px`),re}),le=e.computed(()=>{const re={};return w.isRunLoading&&(re.height=`${k.headHeight}px`),re}),me=re=>{s("onGetData",re)},ie=(re,fe,ge,we,Ce)=>{s("onClickElastic",re,fe,ge,we,Ce)},ne=(re,fe,ge=!1)=>{s("onClickRow",re,fe,ge)},A=(re,fe,ge)=>{s("onChangeChecked",re,fe,ge)},te=()=>{const re=Bn();s("onChangeParams",re)},ce=()=>{e.nextTick(()=>{if(y.value){const re=y.value.querySelector("thead");re&&(k.headHeight=re.offsetHeight)}}),w.isRunLoading=!0},pe=()=>{w.isRunLoading=!1},he=()=>{let re=0,fe=0;(w.isCheckedRadio||w.isCheckedCheckbox)&&(re=1,V.value&&(fe=V.value.getRcWidth())),(o.isEmpty(t.columns)?[]:t.columns).forEach(Ce=>{(o.isBoolean(Ce?.visible)?Ce.visible:!0)&&(re+=1,!o.isEmpty(Ce)&&!o.isEmpty(Ce.width)?fe+=Number(Ce.width)||0:!o.isEmpty(Ce)&&!o.isEmpty(Ce.widthMin)&&(fe+=Number(Ce.widthMin)||0))});const we=V.value?V.value.getPaddingLr():0;fe+=we,w.colspanCount=re,se.value&&(v.minWidth=fe>0?`${fe}px`:"auto")},Ee=()=>new Promise((re,fe)=>{e.nextTick(()=>{try{if(!x.value){re();return}const ge=x.value.getWidth();C.totalWidth=`${ge}px`;let we=ge;if(W.value||U.value){const Ce=[],Be=[];(o.isEmpty(t.columns)?[]:t.columns).forEach((mt,tn)=>{(o.isBoolean(mt?.visible)?mt.visible:!0)&&(W.value&&tn<=t.fixedColumnLeftIndex&&Ce.push(mt),U.value&&tn>=t.fixedColumnRightIndex&&Be.push(mt))});const qe=w.isCheckedRadio||w.isCheckedCheckbox,Ke=V.value?V.value.getElTh():[],Bt=Ke.length;let vt=Ce.length;const en=Be.length;let Ca=vt-1;const Rs=Bt-en;qe&&(vt+=1,Ca+=1);let mo=0,po=0;for(let mt=0;mt<Bt;mt++){const tn=Ke[mt];if(!tn)continue;const fo=tn.clientWidth;mt<=Ca&&(mo+=fo),mt>=Rs&&(po+=fo)}W.value&&(C.leftColumnLength=Ce.length,C.leftWidth=`${mo}px`,we-=mo),U.value&&(C.rightColumnLength=Be.length,C.rightWidth=`${po}px`,we-=po)}we=Math.max(0,we),C.centerWidth=`${we}px`,e.nextTick(()=>{re()})}catch(ge){fe(ge)}})}),be=()=>{e.nextTick(()=>{x.value&&x.value.setElasticWidth()})},xe=re=>{(W.value||U.value)&&x.value&&x.value.setElasticHeight(re)},De=re=>{if(t.isElasticLoad){const fe=o.getArrClone(H.loading);fe.indexOf(re)===-1&&(fe.push(re),H.loading=fe)}},Re=re=>{if(t.isElasticLoad){const fe=o.getArrClone(H.loading),ge=fe.indexOf(re);ge>-1&&(fe.splice(ge,1),H.loading=fe,e.nextTick(()=>{xe(re)}))}},Fe=(re,fe,ge,we)=>{if(o.isEmpty(re)||o.isEmpty(re.id))return;const Ce=re.id.toString(),Be=o.getArrClone(H.open),Oe=Be.indexOf(Ce),qe=Oe===-1;qe?(Be.push(Ce),De(Ce)):(Be.splice(Oe,1),Re(Ce),(W.value||U.value)&&x.value&&x.value.removeElasticAbsolute(Ce)),$t(ge,qe);const Ke=o.isBoolean(we)?we:!0;H.open=Be,Ke&&ie(Ce,re,fe,qe,ge),be()},yt=()=>{const re=[],fe=o.isEmpty(t.elasticIconCls)?[]:t.elasticIconCls;if(fe.length===2){const ge=M.value,we=H.open;ge.forEach(Ce=>{if(!Ce){re.push(Ce);return}const Be=o.getJsonClone(Ce);if(!o.isEmpty(Be.id)){const Oe=Be.id.toString();Be._elasticIconCls=we.indexOf(Oe)>-1?fe[1]:fe[0]}re.push(Be)})}re.length>0&&(M.value=re)},$t=(re,fe=!1)=>{if(re){const ge=[],we=["elastic-expand","elastic-retract"];fe?ge.push("elastic-expand"):ge.push("elastic-retract");const Ce=o.isEmpty(t.elasticIconCls)?[]:t.elasticIconCls;Ce.length===2&&(we.push(Ce[0]),we.push(Ce[1]),fe?ge.push(Ce[1]):ge.push(Ce[0]));let Be=de.getRemoveClass(re.className,we.join(" "));Be=de.getAddClass(Be,ge),re.className=Be}},bn=()=>Wg(M.value),Cn=(re=null)=>{const fe=o.isUndefined(re)||re===null?z.value:re;return jg(fe,bn(),w.isCheckedRadio)},to=()=>{if(w.isCheckedCheckbox){const re=bn(),fe=Cn();J.value=Yg(re,fe)}},ga=()=>{const re=[],fe=Cn(),ge=bn(),we=qg(ge,fe);if(w.isCheckedCheckbox)fe.forEach(Ce=>{const Be=c.dataJson[Ce.toString()];o.isUndefined(Be)||re.push(Be)});else if(w.isCheckedRadio&&fe.length>0){const Ce=c.dataJson[fe[0]];o.isUndefined(Ce)||re.push(Ce)}return{checkedIds:fe,unCheckedIds:we,checkedData:re}},no=()=>{const re=ga();A(re.checkedIds.join(","),re.checkedData,{checkedIds:re.checkedIds,unCheckedIds:re.unCheckedIds})},ya=re=>{if(o.isEmpty(re)||o.isEmpty(re.id))return;const fe=re.id.toString(),ge=z.value;let we=[];if(w.isCheckedCheckbox){const Ce=o.isExistValue(ge,fe);ge.forEach(Be=>{Be!==fe&&we.push(Be)}),Ce||we.push(fe),z.value=we,to(),no()}else ge.length>0&&ge[0]===fe||(we=[fe],z.value=we,no())},oo=()=>{if(se.value&&D.value&&x.value){const re=D.value.clientWidth,fe=x.value.getWidth();v.isShow=fe>re}},ao=()=>{if(K.value&&x.value){const re=x.value.getHeight();let fe=re>t.scrollY;if(fe||(W.value||U.value?T.value&&(fe=re>T.value.clientHeight):D.value&&D.value.offsetHeight>=t.scrollY&&(fe=re>D.value.clientHeight)),fe&&Y.value&&V.value){const ge=V.value.getTotalHeight()-(o.osType().isMobile?2:0);w.totalHeight=`${ge}px`}S.value=fe}},xn=()=>{if((W.value||U.value)&&D.value&&x.value){let re=D.value.scrollLeft;const fe=D.value.clientWidth,ge=x.value.getWidth();let we="left";re>0&&(fe+re>=ge?we="right":we="center"),v.posType=we}},va=()=>{if(!B.value||!x.value)return;let re=y.value?y.value.scrollLeft:0;const fe=B.value.clientWidth,ge=x.value.getWidth();fe+re>ge&&(re=0),H.loading.length>0&&x.value.setElasticLoadLeft(re),M.value.length===0&&x.value.setEmptyLeft(re)},io=re=>{_=re.target.scrollLeft,I===null&&(I=requestAnimationFrame(()=>{I=null;const fe=_;y.value&&(y.value.scrollLeft=fe),D.value&&(D.value.scrollLeft=fe),E.value&&E.value.setScrollLeft(fe),O.value&&O.value.setScrollLeft(fe),xn(),va()}))},ka=re=>{const fe=re.target,ge=fe.scrollLeft;fe.scrollWidth-fe.clientWidth-ge<1&&D.value&&D.value.scrollLeft>ge||(ge!==c.scrollHead.left&&io(re),c.scrollHead.left=ge)},Sa=re=>{const fe=re.target.scrollLeft;fe!==c.scrollBody.left&&io(re),c.scrollBody.left=fe},so=()=>{if(t.isFixedHead&&h.value&&!w.isRunLoading){let re=!1,fe="auto",ge="auto";const we=h.value&&h.value.parentNode?de.getPositionView(h.value.parentNode):null;if(we&&we.top<0&&B.value&&g.value&&V.value){const Ce=B.value.clientHeight;if(we.top>(Ce-cy)*-1){re=!0;const Be=B.value.offsetWidth,Oe=v.isShow&&t.isScrollX?g.value.offsetHeight:V.value.getOffsetHeight();fe=`${Be}px`,ge=`${Oe}px`}}$.isShow=re,$.width=fe,$.height=ge}},lo=()=>{M.value.length===0&&e.nextTick(()=>{x.value&&x.value.setEmptyWidth()})},Bn=()=>{const re={};if(t.isPaginate){const{pages:fe,limit:ge}=c.changeNewPaginate;re.pages=fe,re.limit=ge,re.offset=(re.pages-1)*re.limit}if(t.isOrder){const{orderIndex:fe,orderBy:ge}=c.changeNewSort;re.orderIndex=fe,re.orderBy=ge;const we=t.columns[fe];o.isUndefined(we)||(re.orderColumns=we.data)}return re},As=()=>{t.scrollY>0&&e.nextTick(()=>{if(!D.value)return;const re=D.value.querySelectorAll(".tr-selected");D.value.scrollTop=re&&re.length>0&&re[0].offsetTop>uy?re[0].offsetTop-dy:0})},wa=(re={})=>{if(w.isCheckedRadio||w.isCheckedCheckbox){const fe=q();z.value=Cn(fe),to(),As()}t.isElastic&&((!o.isBoolean(re.isElasticCloseAll)||re.isElasticCloseAll)&&(H.open=[],(W.value||U.value)&&x.value&&x.value.clearElasticAbsolute()),H.loading=[],yt()),w.hoverTrIndex=-1,w.hoverTrElasticIndex=-1,e.nextTick(()=>{t.isPaginate&&(b.pages=c.changeNewPaginate.pages,b.limit=c.changeNewPaginate.limit),t.isOrder&&(N.value=d([c.changeNewSort.orderIndex,c.changeNewSort.orderBy])),pe(),he(),e.nextTick(()=>{ao(),oo(),Ee().then(()=>{xn()}).catch(fe=>{Se.warn("ClTable","表格固定列分析失败",fe)}),lo(),so()})})},Ea=(re,fe)=>{const ge=o.isEmpty(t.list)?[]:t.list;let we=[];if(fe){if(t.isOrder){const Ce={},Be=[];let Oe="string";if(!o.isUndefined(re.orderIndex)){const qe=re.orderColumns,Ke=t.columns[re.orderIndex];if(!o.isUndefined(Ke))if(o.isEmpty(Ke.sortType))switch(Ke.format){case"int":case"float2":case"float3":Oe="number";break;case"date":case"dateTime":case"time":Oe="date";break;default:Oe="string"}else Oe=Ke.sortType;ge.forEach(Bt=>{if(!Bt)return;let vt=Bt[qe];vt=o.isUndefined(vt)||vt===null?"":vt;const en=vt.toString();o.isExistJsonKey(Ce,en)||(Ce[en]=[],Be.push(vt)),Ce[en].push(o.getJsonClone(Bt))})}Be.length>0&&(re.orderBy==="desc"?o.getArrDesc(Be,Oe):o.getArrAsc(Be,Oe)).forEach(Ke=>{we.push(...Ce[Ke.toString()])})}else we=o.getListClone(t.list);c.sortLocalData=we}else we=c.sortLocalData;if(t.isPaginate){const Ce=[],Be=we.length,Oe=re.offset;let qe=re.offset+re.limit;if(qe=Be<qe?Be:qe,Be&&Be>=Oe&&Be>0)for(let Ke=Oe;Ke<qe;Ke+=1)Ce.push(o.getJsonClone(we[Ke]));return Ce}else return we},xt=(re={})=>{const fe=Bn();z.value=[],J.value=!1,ce(),t.isServer?(c.timerBody&&clearTimeout(c.timerBody),c.timerBody=setTimeout(()=>{c.timerBody=null,me(fe)},ii)):(c.timerBody&&clearTimeout(c.timerBody),c.timerBody=setTimeout(()=>{c.timerBody=null;const ge=o.isBoolean(re.isChangePage)?!re.isChangePage:!0;M.value=Ea(fe,ge),wa()},ii))},Ls=()=>{se.value&&(y.value&&y.value.addEventListener("scroll",ka),D.value&&D.value.addEventListener("scroll",Sa))},$s=()=>{if(K.value){const re=window,fe=re.MutationObserver||re.WebKitMutationObserver||re.MozMutationObserver;if(!fe)return;m.observerBodyScrollY=new fe(()=>{ao()});const ge=m.observerBodyScrollY;x.value&&x.value.$el&&ge&&ge.observe(x.value.$el,{childList:!0,subtree:!0})}},Dn=()=>{oo(),Ee().then(()=>{xn()}).catch(re=>{Se.warn("ClTable","表格固定列分析失败",re)}),be(),lo(),va(),e.nextTick(()=>{so()})},In=()=>{L===null&&(L=requestAnimationFrame(()=>{L=null,so()}))},Fs=()=>{he(),e.nextTick(()=>{t.isServer?xt():o.isEmpty(t.list)?t.isShowInitLoadIng?ce():e.nextTick(()=>{lo()}):(xt(),t.isShowInitLoadIng||(w.isRunLoading=!1))})};e.onMounted(()=>{e.nextTick(()=>{Fs(),Ls(),$s(),c.resizeEvent=new ht({isDelay:!0,callback:()=>{Dn()}}),t.isFixedHead&&window.addEventListener("scroll",In)})}),e.onActivated(()=>{t.isFixedHead&&window.addEventListener("scroll",In),c.resizeEvent||(c.resizeEvent=new ht({isDelay:!0,callback:()=>{Dn()}})),Dn(),c.pendingCanceled&&(c.pendingCanceled=!1,xt())}),e.onDeactivated(()=>{window.removeEventListener("scroll",In),c.timerBody&&(clearTimeout(c.timerBody),c.timerBody=null,w.isRunLoading=!1,c.pendingCanceled=!0),c.resizeEvent&&(c.resizeEvent.destroy(),c.resizeEvent=null),I!==null&&(cancelAnimationFrame(I),I=null),L!==null&&(cancelAnimationFrame(L),L=null)}),e.onBeforeUnmount(()=>{c.timerBody&&(clearTimeout(c.timerBody),c.timerBody=null),m.observerBodyScrollY&&(m.observerBodyScrollY.disconnect(),m.observerBodyScrollY.takeRecords(),m.observerBodyScrollY=null),se.value&&(y.value&&y.value.removeEventListener("scroll",ka),D.value&&D.value.removeEventListener("scroll",Sa)),c.resizeEvent&&c.resizeEvent.destroy(),I!==null&&(cancelAnimationFrame(I),I=null),L!==null&&(cancelAnimationFrame(L),L=null),window.removeEventListener("scroll",In)}),e.watch(()=>t.list,(re,fe)=>{const ge=o.isEmpty(re)?[]:re;if(c.timerBody&&(clearTimeout(c.timerBody),c.timerBody=null),c.dataJson=o.getJsonByList(ge),t.isServer)M.value=o.getListClone(ge);else if(t.isParamTriggerServer)M.value=o.getListClone(ge,!0);else{c.changeNewPaginate.pages=1;const Ce=Bn();M.value=Ea(Ce,!0)}const we={};if(t.isElastic){let Ce=!1;if(fe)if(ge.length===fe.length){const Be=new Set(fe.map(Oe=>Oe?.id));Ce=ge.some(Oe=>Oe&&!Be.has(Oe.id))}else Ce=!0;Ce||(we.isElasticCloseAll=!1)}wa(we)},{deep:!0}),e.watch(()=>t.columns,()=>{e.nextTick(()=>{he(),e.nextTick(()=>{ao(),oo(),Ee().then(()=>{xn()}).catch(re=>{Se.warn("ClTable","表格固定列分析失败",re)})})})},{deep:!0}),e.watch(()=>t.selectValue,()=>{const re=q();z.value=Cn(re),to()}),e.watch(()=>t.orderSort,(re,fe)=>{if(re&&re.length>=2&&!(re[0]===c.changeNewSort.orderIndex&&re[1]===c.changeNewSort.orderBy)){const ge=d(t.orderSort);c.changeNewPaginate.pages=1,b.pages=1,c.changeNewSort={orderIndex:ge[0],orderBy:ge[1]},N.value=ge,!t.isServer&&t.isParamTriggerServer?te():xt({isChangePage:!1})}},{deep:!0}),e.watch([()=>t.pageOffset,()=>t.paginateLimit],([re,fe],[ge,we])=>{const Ce=u();c.changeNewPaginate.pages=Ce,c.changeNewPaginate.limit=fe,b.pages=Ce,b.limit=fe,!t.isServer&&t.isParamTriggerServer?te():xt({isChangePage:!0})});const ro=()=>{if(t.disabled)return;const re=!J.value;let fe=[];if(re){const ge=bn(),we=z.value,Ce=[];ge.forEach(Be=>{o.isExistValue(we,Be)||Ce.push(Be)}),fe=we.concat(Ce)}J.value=re,z.value=fe,no()},co=(re,fe,ge)=>{t.disabled||w.isRunLoading||(c.changeNewPaginate.pages=1,b.pages=1,c.changeNewSort.orderIndex=fe,c.changeNewSort.orderBy=ge,!t.isServer&&t.isParamTriggerServer?te():xt({isChangePage:!1}))},uo=(re,fe,ge)=>{if(!fe||o.isEmpty(fe)||o.isBoolean(fe.isDisabled)&&fe.isDisabled||t.disabled)return;const we=o.isNonEmptyString(t.rowClickKeyInvalid)?de.getParent(re.target,t.rowClickKeyInvalid,re.currentTarget,!1):void 0;if(o.isUndefined(we)){if(t.isElastic){const Be=o.isNonEmptyString(t.rowClickKeyElastic)?de.getParent(re.target,t.rowClickKeyElastic,re.currentTarget,!1):void 0;if(o.isUndefined(Be))t.isClickRowLinkage&&Fe(fe,ge);else{Fe(fe,ge,Be);return}}let Ce=!1;if(w.isCheckedRadio||w.isCheckedCheckbox){let Be=de.getParent(re.target,".th-rc",re.currentTarget,!1);Be===re.currentTarget&&(Be=null),o.isUndefined(Be)?t.isClickRowLinkage&&ya(fe):(Ce=!0,ya(fe))}ne(fe,ge,Ce)}},Ft=(re,fe=-1)=>{w.hoverTrIndex=re,w.hoverTrElasticIndex=fe},Pt=()=>{w.hoverTrIndex=-1,w.hoverTrElasticIndex=-1},Ps=(re,fe)=>{t.disabled||w.isRunLoading||t.isPaginate&&(c.changeNewPaginate.pages=re,c.changeNewPaginate.limit=fe,!t.isServer&&t.isParamTriggerServer?te():xt({isChangePage:!0}))},ba=re=>{io(re)};return a({getParamInfo:()=>Bn(),refresh:(re=!0)=>{w.isRunLoading||(re&&(c.changeNewPaginate.pages=1),xt())},getData:()=>{const re=e.toRaw(M.value);return o.getListClone(re)},getDataAll:()=>{if(t.isServer){const re=e.toRaw(M.value);return o.getListClone(re)}return o.getListClone(c.sortLocalData)},getSelectData:()=>{const re=ga();return{ids:(re?.checkedIds||[]).join(","),list:re?.checkedData||[]}},loadStart:()=>{ce()},loadStop:()=>{pe()},loadElasticStart:re=>{o.isUndefined(re)||re===null||De(re.toString())},loadElasticStop:re=>{o.isUndefined(re)||re===null||Re(re.toString())},closeElastic:(re,fe,ge)=>{if(o.isEmpty(re)||o.isEmpty(re.id))return;const we=re.id.toString();if(H.open.indexOf(we)===-1)return;const Ce=ge||(D.value?D.value.querySelector(`[data-elastic-id="${CSS.escape(we)}"]`):null);Fe(re,fe,Ce,!1)},refreshResize:()=>{Dn()}}),(re,fe)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(f),class:e.normalizeClass(ae.value)},[e.createElementVNode("div",Gg,[n.isHead?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",{class:e.normalizeClass(G.value),style:e.normalizeStyle({width:$.width}),ref_key:"refElHeadWrapper",ref:h},[e.createElementVNode("div",{class:e.normalizeClass(X.value),ref_key:"refElHeadContainer",ref:g},[e.createElementVNode("div",{class:"table-head-main",ref_key:"refElHeadMain",ref:y},[e.createVNode(Ao,{minWidth:v.minWidth,columns:n.columns,isOrder:n.isOrder,orderSort:N.value,isShowTotal:Y.value,totalInfo:n.totalData,keyIndex:p,hoverIndex:w.hoverTrIndex,isUseScrollX:se.value,isShowRadio:w.isCheckedRadio,isShowCheckbox:w.isCheckedCheckbox,isShowCheckboxAll:ue.value,disabled:n.disabled,checkboxAllValue:J.value,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix,onOnClickAll:ro,onOnClickOrderBy:co,onOnHoverIn:Ft,onOnHoverOut:Pt,ref_key:"refElHeadTable",ref:V},e.createSlots({_:2},[e.renderList(R.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data})])})),e.renderList(Q.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data})])}))]),1032,["minWidth","columns","isOrder","orderSort","isShowTotal","totalInfo","hoverIndex","isUseScrollX","isShowRadio","isShowCheckbox","isShowCheckboxAll","disabled","checkboxAllValue","isInlineWidth","widthClassPrefix","widthMinClassPrefix"])],512),W.value&&C.leftColumnLength>0?(e.openBlock(),e.createElementBlock("div",Qg,[e.createElementVNode("div",{class:"table-fixed-column-left-container",style:e.normalizeStyle({width:C.leftWidth})},[e.createVNode(Ao,{fixedType:"left",fixedLeftIndex:n.fixedColumnLeftIndex,width:C.totalWidth,columns:n.columns,isOrder:n.isOrder,orderSort:N.value,isShowTotal:Y.value,totalInfo:n.totalData,keyIndex:p,hoverIndex:w.hoverTrIndex,isUseScrollX:se.value,isShowRadio:w.isCheckedRadio,isShowCheckbox:w.isCheckedCheckbox,isShowCheckboxAll:ue.value,disabled:n.disabled,checkboxAllValue:J.value,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix,onOnClickAll:ro,onOnClickOrderBy:co,onOnHoverIn:Ft,onOnHoverOut:Pt},e.createSlots({_:2},[e.renderList(R.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data})])})),e.renderList(Q.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data})])}))]),1032,["fixedLeftIndex","width","columns","isOrder","orderSort","isShowTotal","totalInfo","hoverIndex","isUseScrollX","isShowRadio","isShowCheckbox","isShowCheckboxAll","disabled","checkboxAllValue","isInlineWidth","widthClassPrefix","widthMinClassPrefix"])],4)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),U.value&&C.rightColumnLength>0?(e.openBlock(),e.createElementBlock("div",Zg,[e.createElementVNode("div",{class:"table-fixed-column-right-container",style:e.normalizeStyle({width:C.rightWidth})},[e.createVNode(Ao,{fixedType:"right",fixedRightIndex:n.fixedColumnRightIndex,width:C.totalWidth,columns:n.columns,isOrder:n.isOrder,orderSort:N.value,keyIndex:p,hoverIndex:w.hoverTrIndex,isShowTotal:Y.value,totalInfo:n.totalData,isUseScrollX:se.value,isShowRadio:w.isCheckedRadio,isShowCheckbox:w.isCheckedCheckbox,isShowCheckboxAll:ue.value,disabled:n.disabled,checkboxAllValue:J.value,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix,onOnClickAll:ro,onOnClickOrderBy:co,onOnHoverIn:Ft,onOnHoverOut:Pt},e.createSlots({_:2},[e.renderList(R.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data})])})),e.renderList(Q.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data})])}))]),1032,["fixedRightIndex","width","columns","isOrder","orderSort","hoverIndex","isShowTotal","totalInfo","isUseScrollX","isShowRadio","isShowCheckbox","isShowCheckboxAll","disabled","checkboxAllValue","isInlineWidth","widthClassPrefix","widthMinClassPrefix"])],4)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],2),S.value?(e.openBlock(),e.createElementBlock("div",ey,[fe[0]||(fe[0]=e.createElementVNode("div",null,null,-1)),Y.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"table-scroll-occupy-total",style:e.normalizeStyle({height:w.totalHeight})},null,4)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isScrollX?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass({"table-scroll-occupy-corner":v.isShow})},null,2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isScrollX?e.withDirectives((e.openBlock(),e.createElementBlock("div",ty,[e.createVNode(gn,{isShowLeft:W.value,isShowRight:U.value,leftWidth:C.leftWidth,centerWidth:C.centerWidth,rightWidth:C.rightWidth,isShowCorner:S.value,cornerType:"right-top",onOnScrollX:ba,ref_key:"refElHeadFixedScrollX",ref:E},null,8,["isShowLeft","isShowRight","leftWidth","centerWidth","rightWidth","isShowCorner"])],512)),[[e.vShow,v.isShow]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),$.isShow&&w.isRunLoading?(e.openBlock(),e.createElementBlock("div",ny)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))],6),$.isShow?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle({height:$.height,width:$.width})},null,4)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createElementVNode("div",{class:e.normalizeClass(ee.value),ref_key:"refElBodyWrapper",ref:B},[e.createElementVNode("div",{class:"table-body-container",style:e.normalizeStyle(F.value),ref_key:"refElBodyContainer",ref:T},[e.createElementVNode("div",{class:e.normalizeClass({"table-body-main":!0,"table-body-empty":M.value.length===0}),style:e.normalizeStyle(j.value),ref_key:"refElBodyMain",ref:D},[e.createVNode(Lo,{minWidth:v.minWidth,columns:n.columns,list:M.value,disabled:n.disabled,isOrder:n.isOrder,selectValue:z.value,keyIndex:p,hoverIndex:w.hoverTrIndex,hoverElasticIndex:w.hoverTrElasticIndex,isUseScrollX:se.value,colspanCount:w.colspanCount,isRunLoading:w.isRunLoading,isShowRadio:w.isCheckedRadio,isShowCheckbox:w.isCheckedCheckbox,isElastic:n.isElastic,elasticOpen:H.open,elasticLoading:H.loading,elasticType:n.elasticType,elasticData:n.elasticData,trIntervalNum:n.trIntervalNum,isStriped:n.isStriped,emptyText:n.emptyText,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix,onOnClickTr:uo,onOnHoverIn:Ft,onOnHoverOut:Pt,ref_key:"refElBodyTable",ref:x},e.createSlots({_:2},[e.renderList(P.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data,trIndex:we.trIndex})])})),e.renderList(oe.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data,trIndex:we.trIndex,trElasticInx:we.trElasticInx})])}))]),1032,["minWidth","columns","list","disabled","isOrder","selectValue","hoverIndex","hoverElasticIndex","isUseScrollX","colspanCount","isRunLoading","isShowRadio","isShowCheckbox","isElastic","elasticOpen","elasticLoading","elasticType","elasticData","trIntervalNum","isStriped","emptyText","isInlineWidth","widthClassPrefix","widthMinClassPrefix"])],6),W.value&&C.leftColumnLength>0?(e.openBlock(),e.createElementBlock("div",oy,[e.createElementVNode("div",{class:"table-fixed-column-left-container",style:e.normalizeStyle({width:C.leftWidth})},[e.createVNode(Lo,{width:C.totalWidth,fixedType:"left",fixedLeftIndex:n.fixedColumnLeftIndex,columns:n.columns,list:M.value,disabled:n.disabled,isOrder:n.isOrder,selectValue:z.value,keyIndex:p,hoverIndex:w.hoverTrIndex,hoverElasticIndex:w.hoverTrElasticIndex,isUseScrollX:se.value,colspanCount:w.colspanCount,isRunLoading:w.isRunLoading,isShowRadio:w.isCheckedRadio,isShowCheckbox:w.isCheckedCheckbox,isElastic:n.isElastic,elasticOpen:H.open,elasticLoading:H.loading,elasticType:n.elasticType,elasticData:n.elasticData,trIntervalNum:n.trIntervalNum,isStriped:n.isStriped,emptyText:n.emptyText,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix,onOnClickTr:uo,onOnHoverIn:Ft,onOnHoverOut:Pt},e.createSlots({_:2},[e.renderList(P.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data,trIndex:we.trIndex})])})),e.renderList(oe.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data,trIndex:we.trIndex,trElasticInx:we.trElasticInx})])}))]),1032,["width","fixedLeftIndex","columns","list","disabled","isOrder","selectValue","hoverIndex","hoverElasticIndex","isUseScrollX","colspanCount","isRunLoading","isShowRadio","isShowCheckbox","isElastic","elasticOpen","elasticLoading","elasticType","elasticData","trIntervalNum","isStriped","emptyText","isInlineWidth","widthClassPrefix","widthMinClassPrefix"])],4)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),U.value&&C.rightColumnLength>0?(e.openBlock(),e.createElementBlock("div",ay,[e.createElementVNode("div",{class:"table-fixed-column-right-container",style:e.normalizeStyle({width:C.rightWidth})},[e.createVNode(Lo,{width:C.totalWidth,fixedType:"right",fixedRightIndex:n.fixedColumnRightIndex,columns:n.columns,list:M.value,disabled:n.disabled,isOrder:n.isOrder,selectValue:z.value,keyIndex:p,hoverIndex:w.hoverTrIndex,hoverElasticIndex:w.hoverTrElasticIndex,isUseScrollX:se.value,colspanCount:w.colspanCount,isRunLoading:w.isRunLoading,isShowRadio:w.isCheckedRadio,isShowCheckbox:w.isCheckedCheckbox,isElastic:n.isElastic,elasticOpen:H.open,elasticLoading:H.loading,elasticType:n.elasticType,elasticData:n.elasticData,trIntervalNum:n.trIntervalNum,isStriped:n.isStriped,emptyText:n.emptyText,isInlineWidth:n.isInlineWidth,widthClassPrefix:n.widthClassPrefix,widthMinClassPrefix:n.widthMinClassPrefix,onOnClickTr:uo,onOnHoverIn:Ft,onOnHoverOut:Pt},e.createSlots({_:2},[e.renderList(P.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data,trIndex:we.trIndex})])})),e.renderList(oe.value,ge=>({name:ge,fn:e.withCtx(we=>[e.renderSlot(re.$slots,ge,{data:we.data,trIndex:we.trIndex,trElasticInx:we.trElasticInx})])}))]),1032,["width","fixedRightIndex","columns","list","disabled","isOrder","selectValue","hoverIndex","hoverElasticIndex","isUseScrollX","colspanCount","isRunLoading","isShowRadio","isShowCheckbox","isElastic","elasticOpen","elasticLoading","elasticType","elasticData","trIntervalNum","isStriped","emptyText","isInlineWidth","widthClassPrefix","widthMinClassPrefix"])],4)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],4),n.isScrollX&&M.value.length>0&&v.isShow?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.isScrollXBottom?(e.openBlock(),e.createElementBlock("div",{key:0,class:"table-fixed-column-scrollX",style:e.normalizeStyle({bottom:K.value?"-1px":"1px"})},[e.createVNode(gn,{isShowLeft:W.value,isShowRight:U.value,leftWidth:C.leftWidth,centerWidth:C.centerWidth,rightWidth:C.rightWidth,isShowCorner:S.value,isShowCover:!1,cornerType:"right-bottom",onOnScrollX:ba,ref_key:"refElBodyFixedScrollX",ref:O},null,8,["isShowLeft","isShowRight","leftWidth","centerWidth","rightWidth","isShowCorner"])],4)):(e.openBlock(),e.createElementBlock("div",iy,[e.createElementVNode("div",{style:e.normalizeStyle({height:`${ai}px`})},null,4)]))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],2),n.isPaginate&&M.value.length>0?(e.openBlock(),e.createElementBlock("div",sy,[fe[1]||(fe[1]=e.createElementVNode("div",null,null,-1)),e.createVNode(ma,{currentPage:b.pages,limitValue:b.limit,limitData:n.paginateLimitData,isShowLimit:n.isPaginateLimit,totalCount:Z.value,disabled:n.disabled||w.isRunLoading,onOnChange:Ps},null,8,["currentPage","limitValue","limitData","isShowLimit","totalCount","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))]),w.isRunLoading?(e.openBlock(),e.createElementBlock("div",ly,[e.createElementVNode("div",ry,[e.createElementVNode("div",{class:"table-load-head",style:e.normalizeStyle(le.value)},null,4),e.createElementVNode("div",{class:e.normalizeClass({"table-load-body":!0,"table-load-bg-gray":n.isLoading})},[e.createVNode(Zt,{isLoadIng:n.isLoading,size:"xxl",theme:n.loadTheme,color:n.loadColor||void 0},null,8,["isLoadIng","theme","color"])],2)])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,Xg))}}),my=["id"],py={class:"tableedit-table table-base"},ws=e.defineComponent({name:"ClTableEdit",__name:"Index",props:{id:String,className:String,columns:{type:Array,default:()=>[]},list:{type:Array,default:()=>[]}},setup(n,{expose:a}){const i=n,t=`tableedit-${o.getRandom(5)}`,s=i.id,l=e.useSlots(),d=e.computed(()=>o.isArray(i.list)?i.list:[]),u=e.computed(()=>(o.isArray(i.columns)?i.columns:[]).filter(h=>o.isObject(h)&&o.isNonEmptyString(h.data)&&h.visible!==!1)),r=e.computed(()=>o.getJsonMerge({"panel-table-edit":!0},de.getClassNameJson(i.className))),c=h=>{const g={};return o.isEmpty(h.width)||(g[`width-${h.width}`]=!0),o.getJsonMerge(g,de.getClassNameJson(h.className))},m=h=>!o.isEmpty(h.data)&&!!l[`td_${h.data}`],p=(h,g)=>{const y=h?h[g.data]:void 0;return o.isEmpty(y)||o.getTypeof(y)==="object"?"":y};return a({getData:()=>d.value}),(h,g)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(s),class:e.normalizeClass(r.value)},[e.createElementVNode("table",py,[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(y,V)=>(e.openBlock(),e.createElementBlock("th",{key:`${t}-th-${y.data}-${V}`,class:e.normalizeClass(c(y))},e.toDisplayString(y.title),3))),128))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(y,V)=>(e.openBlock(),e.createElementBlock("tr",{key:`${t}-tr-${V}`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,(E,B)=>(e.openBlock(),e.createElementBlock("td",{key:`${t}-td-${E.data}-${B}`,class:e.normalizeClass(c(E))},[m(E)?e.renderSlot(h.$slots,`td_${E.data}`,{key:0,data:y,col:E,trIndex:V}):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(p(y,E)),1)],64))],2))),128))]))),128))])])],10,my))}}),fy=["id"],hy=["innerHTML"],Es=e.defineComponent({name:"ClTableSimple",__name:"Index",props:{id:String,className:String,columns:{type:Array,default:()=>[]},list:{type:Array,default:()=>[]}},setup(n){const a=n,i=`t-${o.getRandom(5)}`,t=a.id,s=e.computed(()=>o.isArray(a.list)?a.list:[]),l=e.computed(()=>o.isArray(a.columns)?a.columns.filter(p=>o.isObject(p)&&!o.isArray(p)):[]),d=e.computed(()=>o.getJsonMerge({"panel-table-simple":!0,"table-base":!0},de.getClassNameJson(a.className))),u=(p,f)=>p?p[f.data]:void 0,r=p=>{const f={};return o.isEmpty(p.width)||(f[`width-${p.width}`]=!0),o.getJsonMerge(f,de.getClassNameJson(p.className))},c=(p,f)=>{const h=u(p,f);return o.isEmpty(h)||o.getTypeof(h)==="object"?"":h},m=(p,f)=>{const h=u(p,f);return o.isHtmlPair(h)};return(p,f)=>(e.openBlock(),e.createElementBlock("table",{id:e.unref(t),class:e.normalizeClass(d.value)},[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(h,g)=>(e.openBlock(),e.createElementBlock("th",{key:`${i}-th-${g}`,class:e.normalizeClass(r(h))},e.toDisplayString(h.title),3))),128))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s.value,(h,g)=>(e.openBlock(),e.createElementBlock("tr",{key:`${i}-tr-${g}`},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.value,(y,V)=>(e.openBlock(),e.createElementBlock("td",{key:`${i}-td-${V}`,class:e.normalizeClass(r(y))},[m(h,y)?(e.openBlock(),e.createElementBlock("span",{key:0,innerHTML:c(h,y)},null,8,hy)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[e.createTextVNode(e.toDisplayString(c(h,y)),1)],64))],2))),128))]))),128))])],10,fy))}}),gy=["id"],yy={key:0},vy=["id","aria-selected","aria-controls","tabindex","onClick","onKeydown"],ky=["onClick"],Sy=["id","aria-labelledby"],bs=e.defineComponent({name:"ClTabs",__name:"Index",props:{id:String,className:{type:String,default:""},classContent:{type:String,default:""},list:{type:Array,default:()=>[]},theme:{type:String,default:"default",validator:n=>["default","line","card","button"].indexOf(n)!==-1},active:String,disabledData:{type:Array,default:()=>[]},hideData:{type:Array,default:()=>[]},prefixName:String,isShowRemove:{type:Boolean,default:!1},removeReserve:{type:Number,default:1},isShowAdd:{type:Boolean,default:!1},addBtnText:String,tabMinNum:{type:Number,default:1},tabMaxNum:{type:Number,default:0},isHideTabHead:{type:Boolean,default:!1},getAddInfo:Function,checkChangeBefore:Function},emits:{onChange:(n,a)=>!0,onInit:(n,a,i)=>!0,onAdd:n=>!0,onRemove:n=>!0,onErrMsg:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("common");const u=e.useTemplateRef("refElNavUl"),r=e.reactive({keyIndex:`${o.getRandom(8)}`,showId:t.active}),c=e.ref([]),m=e.reactive({left:0,width:0}),p=e.reactive({isShow:!1,width:""}),f={currentTabsAutoIndex:0,isFirstInit:!1},h=e.ref(!1),g=`tabs-${o.getRandom(5)}`,y=t.id,V=e.computed(()=>{const I={"panel-tabs":!0};return I[`tabs-${t.theme}`]=!0,o.getJsonMerge(I,de.getClassNameJson(t.className))}),E=e.computed(()=>{const I={"tabs-content":!0};return o.getJsonMerge(I,de.getClassNameJson(t.classContent))}),B=()=>{const I=[],L=r.showId?r.showId.toString():"";let _={};c.value.forEach(R=>{const P=o.getJsonClone(R);R.tabId===L&&(_=P),I.push(P)}),s("onInit",r.showId||"",_,I)},T=(I,L)=>{e.nextTick(()=>{s("onChange",I,L)})},D=I=>{s("onAdd",I)},x=I=>{s("onRemove",I)},O=I=>{s("onErrMsg",I)},w=I=>{if(t.theme==="line"){const L=document.getElementById(`tab_${r.keyIndex}_${I}`);let _=0,R=0;L&&L.parentElement&&(_=L.parentElement.offsetLeft+10,R=L.parentElement.offsetWidth-20),m.left=_,m.width=R}},M=()=>{if(u.value){const I=u.value.offsetWidth;let L=0;const _=u.value.children,R=_.length;for(let Q=0;Q<R;Q++){const oe=_[Q];oe.classList.contains("tab-indicator")||(Q===0&&(L+=oe.offsetLeft),L+=oe.offsetWidth)}const P=L>I;p.isShow=P,p.width=`${L}px`}},b=(I,L)=>{const _=o.getJsonClone(I),R=o.isNonEmptyString(_.id)?_.id:"-1";if(_.tabId=R==="-1"?o.getRandom(8):R,_.value=R,o.isEmpty(_.name)){const P=o.isNonEmptyString(t.prefixName)?t.prefixName:"";_.name=P+L.toString()}return _},N=I=>{const L=[];return o.isArray(I)&&I.forEach((_,R)=>{o.isObject(_)&&L.push(b(_,R+1))}),L},J=(I,L)=>{let _="";return L&&!o.isEmpty(L)&&I.forEach(R=>{R.tabId===L&&(_=L)}),o.isEmpty(_)&&I.length>0&&(_=I[0].tabId),_},q=()=>{const I=N(t.list);c.value=I,f.currentTabsAutoIndex=I.length,e.nextTick(()=>{r.showId=J(I,t.active||""),M(),!f.isFirstInit&&I.length>0&&(f.isFirstInit=!0,B())})};e.onMounted(()=>{e.nextTick(()=>{q()})}),e.onBeforeUnmount(()=>{}),e.watch([()=>t.active,()=>t.list],()=>{q()}),e.watch(()=>r.showId,(I,L)=>{I!==L&&w(r.showId||"")});const z=()=>c.value.filter(I=>t.disabledData.indexOf(I.tabId)===-1&&t.hideData.indexOf(I.tabId)===-1),H=(I,L)=>{const _=z(),R=_.findIndex(Q=>Q.tabId===r.showId);let P=R;if(I.key==="ArrowLeft")I.preventDefault(),P=R>0?R-1:_.length-1;else if(I.key==="ArrowRight")I.preventDefault(),P=R<_.length-1?R+1:0;else if(I.key==="Home")I.preventDefault(),P=0;else if(I.key==="End")I.preventDefault(),P=_.length-1;else return;P!==R&&_[P]&&v(_[P])},v=async I=>{if(!h.value&&t.disabledData.indexOf(I.tabId)===-1&&I.tabId!==r.showId){let L=!0;if(t.checkChangeBefore){h.value=!0;try{L=await t.checkChangeBefore(I.tabId,r.showId),L=o.isBoolean(L)?L:!0}catch(_){L=!0,O(`标签切换校验异常: ${String(_)}`)}finally{h.value=!1}}L&&(r.showId=I.tabId,T(I.tabId,I))}},S=I=>{if(t.disabledData.indexOf(I.tabId)===-1&&c.value.length>t.tabMinNum){const L=[];c.value.forEach(_=>{_.tabId!==I.tabId&&L.push(_)}),c.value=L,e.nextTick(()=>{M(),r.showId=J(L,r.showId||"")}),x(o.getJsonClone(I))}else O(`${l.value.checkAddMin}${t.tabMinNum}${l.value.count}`)},C=()=>{if(c.value.length<t.tabMaxNum||t.tabMaxNum<=0){let I={};if(t.getAddInfo){try{I=t.getAddInfo()}catch(P){I={},O(`新增标签数据获取异常: ${String(P)}`)}o.isObject(I)||(I={})}const L=o.isEmpty(I.name)?f.currentTabsAutoIndex+1:0,_=b(I,L);o.isEmpty(I.name)&&(f.currentTabsAutoIndex=L);const R=o.getListClone(c.value);R.push(_),c.value=R,e.nextTick(()=>{M(),r.showId=_.tabId,D(_)})}else O(`${l.value.checkAddMax}${t.tabMaxNum}${l.value.count}`)},$=I=>{const L=I.target;u.value&&L&&(u.value.scrollLeft=L.scrollLeft)};return a({getValue:()=>r.showId}),(I,L)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(V.value),id:e.unref(y)},[n.isHideTabHead?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",yy,[e.createElementVNode("ul",{class:"tabs-nav",ref_key:"refElNavUl",ref:u,role:"tablist"},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,_=>e.withDirectives((e.openBlock(),e.createElementBlock("li",{key:`${g}-nav-${_.tabId}`,class:e.normalizeClass({"tab-nav":!0,"tab-active":_.tabId===r.showId,"tab-disabled":n.disabledData.indexOf(_.tabId)>-1||h.value})},[e.createElementVNode("a",{id:`tab_${r.keyIndex}_${_.tabId}`,class:"nav-link",href:"javascript:",role:"tab","aria-selected":_.tabId===r.showId,"aria-controls":`panel_${r.keyIndex}_${_.tabId}`,tabindex:_.tabId===r.showId?0:-1,onClick:R=>v(_),onKeydown:R=>H(R)},[e.renderSlot(I.$slots,`nav_${_.tabId}`,{data:_},()=>[e.createTextVNode(e.toDisplayString(_.name),1)])],40,vy),n.isShowRemove&&c.value.length>n.removeReserve&&c.value.length>n.tabMinNum&&n.disabledData.indexOf(_.tabId)===-1?(e.openBlock(),e.createElementBlock("span",{key:0,class:"tab-remove",onClick:R=>S(_)},[e.createVNode(ve,{name:"close"})],8,ky)):e.createCommentVNode("",!0)],2)),[[e.vShow,n.hideData.indexOf(_.tabId)===-1]])),128)),n.isShowAdd?(e.openBlock(),e.createElementBlock("li",{key:0,class:e.normalizeClass({"tab-add":!0,"tab-disabled":c.value.length>=n.tabMaxNum&&n.tabMaxNum>0})},[e.createElementVNode("a",{class:"nav-link",href:"javascript:",onClick:C},[e.renderSlot(I.$slots,"nav_add",{},()=>[e.createTextVNode(e.toDisplayString(n.addBtnText||e.unref(l).add),1)])])],2)):e.createCommentVNode("",!0),n.theme==="line"?(e.openBlock(),e.createElementBlock("li",{key:1,class:"tab-indicator",style:e.normalizeStyle({left:`${m.left}px`,width:`${m.width}px`})},null,4)):e.createCommentVNode("",!0)],512),p.isShow?(e.openBlock(),e.createBlock(gn,{key:0,isShowLeft:!1,isShowRight:!1,centerWidth:p.width,onOnScrollX:$},null,8,["centerWidth"])):e.createCommentVNode("",!0)])),e.createElementVNode("div",{class:e.normalizeClass(E.value)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,_=>e.withDirectives((e.openBlock(),e.createElementBlock("div",{key:`${g}-content-${_.tabId}`,id:`panel_${r.keyIndex}_${_.tabId}`,class:e.normalizeClass({"tab-content":!0,"tab-active":_.tabId===r.showId}),role:"tabpanel","aria-labelledby":`tab_${r.keyIndex}_${_.tabId}`,tabindex:0},[e.renderSlot(I.$slots,`content_${_.tabId}`,{data:_})],10,Sy)),[[e.vShow,n.hideData.indexOf(_.tabId)===-1]])),128))],2)],10,gy))}}),wy={class:"weekhour-quick"},Ey=e.defineComponent({name:"ClWeekHourQuick",__name:"Quick",props:{disabled:{type:Boolean,default:!1},isOneDay:{type:Boolean,default:!1}},emits:{onClick:n=>!0,onHoverIn:n=>!0,onHoverOut:n=>!0},setup(n,{emit:a}){const i=n,t=a,{optPageLanguage:s,getPageLanguage:l}=Le();l("weekHour");const d=`weekhour-${o.getRandom(5)}`,u=e.ref([]),r=B=>{t("onClick",B)},c=B=>{t("onHoverIn",B)},m=B=>{t("onHoverOut",B)},p=()=>{const B=[{id:"dawn",name:s.value.dawn},{id:"morning",name:s.value.morning},{id:"noon",name:s.value.noon},{id:"afternoon",name:s.value.afternoon},{id:"evening",name:s.value.evening},{id:"night",name:s.value.night}];i.isOneDay||B.push({id:"workday",name:s.value.weekday},{id:"restday",name:s.value.restDay}),u.value=B};(()=>{p()})(),e.watch(()=>[i.isOneDay,s.value],()=>{m(""),p()});const h=B=>{r(B.id)},g=B=>{c(B.id)},y=B=>{m(B.id)},V=()=>{r("all")},E=()=>{r("clean")};return(B,T)=>(e.openBlock(),e.createElementBlock("div",wy,[e.createElementVNode("div",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(u.value,D=>(e.openBlock(),e.createBlock(Vt,{key:`${d}-${D.id}`,disabled:n.disabled,isLight:!0,isHideUnderline:!1,onOnClick:x=>h(D),onOnHoverIn:x=>g(D),onOnHoverOut:x=>y(D)},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(D.name),1)]),_:2},1032,["disabled","onOnClick","onOnHoverIn","onOnHoverOut"]))),128))]),e.createElementVNode("div",null,[e.createVNode(Vt,{disabled:n.disabled,isLight:!0,isHideUnderline:!1,onOnClick:V},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(s).common.checkboxAll),1)]),_:1},8,["disabled"]),e.createVNode(Vt,{disabled:n.disabled,isLight:!0,isHideUnderline:!1,onOnClick:E},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(e.unref(s).common.clearEmpty),1)]),_:1},8,["disabled"])])]))}}),by={class:"weekhour-picker"},Cy={key:0,class:"weekhour-interval"},xy=["onMouseenter","onClick","data-hour"],By=["onMouseenter","onClick","data-week"],Dy={key:0,class:"weekhour-interval"},Iy=["onMouseenter","onClick","data-week","data-hour","aria-selected"],Ty=e.defineComponent({name:"ClWeekHourPicker",__name:"Picker",props:{disabled:{type:Boolean,default:!1},isOneDay:{type:Boolean,default:!1}},emits:{onChange:n=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,{optPageLanguage:l,getPageLanguage:d}=Le();d("weekHour");const u=e.inject("$WeekHourTop");u||Se.warn("ClWeekHourPicker","依赖注入 $WeekHourTop 缺失,使用默认周时配置渲染");const r=u||{week:[1,2,3,4,5,6,7],hour:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],getJsonConvertArr:K=>K},c=e.useTemplateRef("refElTable"),m=`weekhour-${o.getRandom(5)}`,p=e.reactive({hoverHour:[],hoverWeek:[],hoverItem:[],hoverItemAssist:[],selectList:[]}),f=e.ref([]),h=e.ref(["0","1","2","3","4","5","6","7","","8","9","10","11","","12","13","14","","15","16","17","","18","19","","20","21","22","23"]),g={week:[],hour:r.hour,prevValue:[],isMouseMoveStart:!1,isMouseMoveIng:!1,moveStart:{}};let y,V;const E=e.ref(null),B=()=>{y&&(clearTimeout(y),y=void 0),y=setTimeout(()=>{const{selectList:K}=p;o.isEqualArr(g.prevValue,K)||(g.prevValue=o.getArrClone(K),s("onChange",g.prevValue))},500)},T=()=>{const K=t.isOneDay?[{id:"1",name:l.value.daily}]:[{id:"1",name:l.value.monday},{id:"2",name:l.value.tuesday},{id:"3",name:l.value.wednesday},{id:"4",name:l.value.thursday},{id:"5",name:l.value.friday},{id:"6",name:l.value.saturday},{id:"7",name:l.value.sunday}],W=t.isOneDay?K.map(U=>parseInt(U.id)):r.week;g.week=W,f.value=K},D=K=>{let W=[],U=[],ae=[];return o.isEmpty(K)?{week:W,hour:U,item:ae}:(Object.keys(K).forEach(G=>{Array.isArray(K[G])&&(W.push(G.toString()),K[G].forEach(X=>{X!=null&&o.isFinite(X)&&/^(0|[1-9]\d*)$/.test(X.toString())&&(U.push(X.toString()),ae.push(`${G}-${X}`))}))}),W=o.getArrUnique(W),U=o.getArrUnique(U),ae=o.getArrUnique(ae),{week:W,hour:U,item:ae})},x=K=>{const W=D(K);p.hoverWeek=W.week,p.hoverHour=W.hour,p.hoverItem=W.item,p.hoverItemAssist=[]},O=()=>{p.hoverWeek=[],p.hoverHour=[],p.hoverItem=[],p.hoverItemAssist=[]},w=K=>{const W=D(K),U=[];W.week.forEach(ae=>{g.hour.forEach(G=>{U.push(`${ae}-${G}`)})}),W.hour.forEach(ae=>{g.week.forEach(G=>{U.push(`${G}-${ae}`)})}),p.hoverItemAssist=o.getArrUnique(U)},M=(K,W=!0)=>{if(o.isEmpty(K))p.selectList=[];else{const{selectList:U}=p,G=D(K).item,X=[],ee=[];G.forEach(j=>{o.isExistValue(U,j)?ee.push(j):X.push(j)});const F=ee.length===G.length&&ee.length>0;p.selectList=F?o.getArrRemoveById(U,G):U.concat(X)}W&&B()},b=K=>{if(!K)return null;const W={isHour:!1,isWeek:!1,isItem:!1,isValidArea:!1,isValidMove:!1,isGroup:!1,hour:-1,week:-1,x:-1,width:-1};let U;K.target?(U=K.target,W.x=K.pageX):K.parentElement&&(U=K);let ae;if(c.value&&c.value.contains(U)){W.isValidArea=!0;const G=(U.tagName||"").toLocaleLowerCase();ae=G==="th"||G==="td"?U:U.parentElement;const X=ae.className.split(" ");if(W.isHour=X.indexOf("weekhour-hour")>-1,W.isWeek=X.indexOf("weekhour-week")>-1,W.isItem=X.indexOf("weekhour-item")>-1,W.isEmpty=X.indexOf("weekhour-empty")>-1,W.isInterval=X.indexOf("weekhour-interval")>-1,W.isInterval&&(W.width=ae.clientWidth),W.isHour&&(W.type="hour",W.isGroup=!0),W.isWeek&&(W.type="week",W.isGroup=!0),W.isItem&&(W.type="item",W.isGroup=!1),W.isHour||W.isWeek||W.isItem){W.isValidMove=!0;const ee=ae.dataset;let F,j;W.isHour?(F=parseInt(ee.hour),j=-1):W.isWeek?(F=-1,j=parseInt(ee.week)):W.isItem&&(F=parseInt(ee.hour),j=parseInt(ee.week)),W.hour=F,W.week=j}}return W.el=ae,W},N=K=>{const W=b(K);if(W&&W.isInterval){const U=de.getPrev(W.el),ae=de.getNext(W.el);W.prevInfo=b(U),W.nextInfo=b(ae)}return W},J=(K,W)=>{if(K.isEmpty&&W.isEmpty)return null;K.isEmpty&&(K.type=W.type),W.isEmpty&&(W.type=K.type);const U=23,ae=g.week.length,G={x:K.hour,y:K.week},X={x:W.hour,y:W.week};if(K.isGroup||W.isGroup){if(K.type==="week")switch(W.type){case"week":G.x=0,X.x=U;break;case"item":G.x=0;break;case"hour":G.x=0,X.y=1;break}else if(K.type==="hour")switch(W.type){case"hour":G.y=1,X.y=ae;break;case"item":G.y=1;break;case"week":G.y=1,X.x=0;break}else if(K.type==="item")switch(W.type){case"hour":X.y=1;break;case"week":X.x=0;break}}let ee,F,j,le;X.x>=G.x?(ee=G.x,F=X.x):(ee=X.x,F=G.x),X.y>=G.y?(j=G.y,le=X.y):(j=X.y,le=G.y);let me;(ee>-1||F>-1)&&(ee===-1&&(ee=0),me=o.getArrByMinMax(ee,F));let ie;return(j>-1||le>-1)&&(j===-1&&(j=1),ie=o.getArrByMinMax(j,le)),!o.isUndefined(me)&&!o.isUndefined(ie)?{x:me,y:ie}:null},q=K=>{let W={},U={};const ae=g.moveStart.isInterval,G=K.isInterval;if(ae||G){const X=g.moveStart.x,ee=K.x;if(ae&&!G)U=K,X>ee?W=g.moveStart.prevInfo||{}:ee>X&&(W=g.moveStart.nextInfo||{});else if(!ae&&G)W=g.moveStart,X>ee?U=K.nextInfo||{}:ee>X&&(U=K.prevInfo||{});else if(ae&&G){const F=g.moveStart.width;Math.abs(X-ee)>F&&(X>ee?(W=g.moveStart.prevInfo||{},U=K.nextInfo||{}):ee>X&&(W=g.moveStart.nextInfo||{},U=K.prevInfo||{}))}}else W=g.moveStart,U=K;return{startInfo:W,endInfo:U}},z=K=>{if(!g.isMouseMoveStart){g.isMouseMoveStart=!0;const W=N(K);if(W.isValidArea&&(O(),g.moveStart=W,W.isValidMove)){const U=W.week===-1?g.week:[W.week],ae=W.hour===-1?g.hour:[W.hour];x(r.getJsonConvertArr({week:U,hour:ae}))}}},H=K=>{if(g.isMouseMoveStart){g.isMouseMoveIng=!0;const W=N(K);if(W.isValidArea){O();const U=q(W);if(!o.isEmpty(U.startInfo)&&!o.isEmpty(U.endInfo)){const ae=J(U.startInfo,U.endInfo);if(ae){const G=r.getJsonConvertArr({week:ae.y,hour:ae.x});x(G)}}}}},v=K=>{if(g.isMouseMoveIng){O();const W=N(K);if(W.isValidArea){const U=q(W);if(!o.isEmpty(U.startInfo)&&!o.isEmpty(U.endInfo)){const ae=J(U.startInfo,U.endInfo);if(ae&&!t.disabled){const G=r.getJsonConvertArr({week:ae.y,hour:ae.x});M(G)}}}}g.isMouseMoveStart=!1,g.moveStart={},V&&(clearTimeout(V),V=void 0),V=setTimeout(()=>{g.isMouseMoveIng=!1},50)},S=()=>{const K={start(W){let U=!1;return t.disabled||(U=!0,z(W)),U},ing:W=>{H(W)},end:W=>{v(W)}};E.value=new bt(c.value,K)};(()=>{T()})(),e.onMounted(()=>{e.nextTick(()=>{S()})}),e.onBeforeUnmount(()=>{E.value&&(E.value.end(),E.value=null),y&&(clearTimeout(y),y=void 0),V&&(clearTimeout(V),V=void 0)}),e.watch(()=>[t.isOneDay,l.value],([K,W],[U,ae])=>{T(),K!==U&&(p.selectList=[],B())});const $=K=>{if(!g.isMouseMoveStart&&!t.disabled){const W=r.getJsonConvertArr({week:g.week,hour:[K]});x(W)}},k=()=>{g.isMouseMoveStart||O()},I=K=>{if(!g.isMouseMoveStart&&!g.isMouseMoveIng&&!t.disabled){const W=r.getJsonConvertArr({week:g.week,hour:[K]});M(W)}},L=K=>{if(!g.isMouseMoveStart&&!t.disabled){const W={};W[K]=g.hour,x(W)}},_=()=>{g.isMouseMoveStart||O()},R=K=>{if(!g.isMouseMoveStart&&!g.isMouseMoveIng&&!t.disabled){const W={};W[K]=g.hour,M(W)}},P=(K,W)=>{if(!g.isMouseMoveStart&&!t.disabled){const U={};U[K]=[W],x(U),w(U)}},Q=()=>{g.isMouseMoveStart||O()},oe=(K,W)=>{if(!g.isMouseMoveStart&&!g.isMouseMoveIng&&!t.disabled){const U={};U[K]=[W],M(U)}};return a({getWeekArr:()=>o.getArrClone(g.week),setSelected:(K,W=!1)=>{if(!g.isMouseMoveStart){const U=[];D(K).item.forEach(G=>{o.isExistValue(U,G)||U.push(G)}),p.selectList=U,W?B():g.prevValue=o.getArrClone(U)}},setHoverIn:K=>{!g.isMouseMoveStart&&!t.disabled&&x(K)},setHoverOut:()=>{g.isMouseMoveStart||O()}}),(K,W)=>(e.openBlock(),e.createElementBlock("div",by,[e.createElementVNode("table",{ref_key:"refElTable",ref:c,class:"table-base"},[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[W[0]||(W[0]=e.createElementVNode("th",{class:"weekhour-empty"},null,-1)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(U,ae)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${m}-hour-${ae}`},[U===""?(e.openBlock(),e.createElementBlock("th",Cy)):(e.openBlock(),e.createElementBlock("th",{key:1,class:e.normalizeClass({"weekhour-hour":!0,"weekhour-hour-hover":p.hoverHour.indexOf(U)>-1}),onMouseenter:G=>$(U),onMouseleave:k,onClick:G=>I(U),"data-hour":U},e.toDisplayString(U),43,xy))],64))),128))])]),e.createElementVNode("tbody",null,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(U,ae)=>(e.openBlock(),e.createElementBlock("tr",{key:`${m}-week-${U.id}-${ae}`},[e.createElementVNode("td",{class:e.normalizeClass({"weekhour-week":!0,"weekhour-week-hover":p.hoverWeek.indexOf(U.id)>-1}),onMouseenter:G=>L(U.id),onMouseleave:_,onClick:G=>R(U.id),"data-week":U.id},e.toDisplayString(U.name),43,By),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(h.value,(G,X)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${m}-week-${ae}-hour-${X}`},[G===""?(e.openBlock(),e.createElementBlock("td",Dy)):(e.openBlock(),e.createElementBlock("td",{key:1,class:e.normalizeClass({"weekhour-item":!0,"weekhour-item-hover":p.hoverItem.indexOf(`${U.id}-${G}`)>-1,"weekhour-item-assist":p.hoverItemAssist.indexOf(`${U.id}-${G}`)>-1,"weekhour-selected":p.selectList.indexOf(`${U.id}-${G}`)>-1}),onMouseenter:ee=>P(U.id,G),onMouseleave:Q,onClick:ee=>oe(U.id,G),"data-week":U.id,"data-hour":G,"aria-selected":p.selectList.indexOf(`${U.id}-${G}`)>-1},[...W[1]||(W[1]=[e.createElementVNode("i",null,null,-1)])],42,Iy))],64))),128))]))),128))])],512)]))}}),Ny={class:"weekhour-tips"},Vy={class:"weekhour-tips-title"},_y={class:"weekhour-tips-title"},My=e.defineComponent({name:"ClWeekHourTip",__name:"Tips",setup(n){const{optPageLanguage:a,getPageLanguage:i}=Le();return i("weekHour"),(t,s)=>(e.openBlock(),e.createElementBlock("div",Ny,[e.createElementVNode("span",null,[s[0]||(s[0]=e.createElementVNode("span",{class:"weekhour-item weekhour-selected"},[e.createElementVNode("i")],-1)),e.createElementVNode("span",Vy,e.toDisplayString(e.unref(a).selected),1)]),e.createElementVNode("span",null,[s[1]||(s[1]=e.createElementVNode("span",{class:"weekhour-item"},[e.createElementVNode("i")],-1)),e.createElementVNode("span",_y,e.toDisplayString(e.unref(a).selectedNot),1)])]))}}),Oy=["id"],Cs=e.defineComponent({name:"ClWeekHour",__name:"Index",props:{id:String,value:String,className:String,disabled:{type:Boolean,default:!1},isOneDay:{type:Boolean,default:!1},isPlaintext:{type:Boolean,default:!1}},emits:{"update:value":n=>!0,"update:modelValue":n=>!0,onChange:n=>!0,onInit:()=>!0},setup(n,{expose:a,emit:i}){const t=n,s=i,l=t.id,d=e.useTemplateRef("refElPicker"),u=e.reactive({valueOut:""}),r={week:[1,2,3,4,5,6,7],hour:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23],quick:{dawn:{week:[1,2,3,4,5,6,7],hour:[0,1,2,3,4,5,6,7]},morning:{week:[1,2,3,4,5,6,7],hour:[8,9,10,11]},noon:{week:[1,2,3,4,5,6,7],hour:[12,13,14]},afternoon:{week:[1,2,3,4,5,6,7],hour:[15,16,17]},evening:{week:[1,2,3,4,5,6,7],hour:[18,19]},night:{week:[1,2,3,4,5,6,7],hour:[20,21,22,23]},workday:{week:[1,2,3,4,5],hour:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23]},restday:{week:[6,7],hour:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23]},all:{week:[1,2,3,4,5,6,7],hour:[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23]},clean:{week:[],hour:[]}}},c=e.computed(()=>{let N={"panel-week-hour":!0,"weekhour-disabled":t.disabled||t.isPlaintext,"cl-plaintext-static":t.isPlaintext};return N=o.getJsonMerge(N,de.getClassNameJson(t.className)),N}),m=N=>{s("update:value",N),s("update:modelValue",N),s("onChange",N)},p=()=>{e.nextTick(()=>{s("onInit")})},f=N=>{let J={};const q=Object.keys(N);if(!o.isEmpty(q))if(q.length===2&&o.isExistValue(q,"week")&&o.isExistValue(q,"hour")&&o.isArray(N.week)&&o.isArray(N.hour)){const z=V();N.week.forEach(H=>{z.indexOf(H)>-1&&(J[H.toString()]=N.hour)})}else J=o.getJsonClone(N);return J},h=N=>{if(!/^(0|[1-9]\d*)$/.test(N))return[];const J=parseInt(N);if(J>16777215)return[];const q=J.toString(2),z=[];return o.getFillZero(q,24).split("").reverse().forEach((H,v)=>{parseInt(H)===1&&v<24&&z.push(v)}),z},g=N=>{const J={},q=N.split(",");return q.length>7&&(q.length=7),q.forEach((z,H)=>{J[(H+1).toString()]=h(z)}),J},y=N=>{let J={};o.isNonEmptyString(N)&&(J=g(N)),d.value&&d.value.setSelected(J)},V=()=>{let N=r.week;return t.isOneDay&&d.value&&(N=d.value.getWeekArr()),N},E=N=>{const J={};N.forEach(v=>{const S=v.split("-"),C=S[0],$=S[1];o.isExistJsonKey(J,C)||(J[C]=[]);const k=parseInt($);o.isFinite(k)&&J[C].push(k)});const q={};V().forEach(v=>{q[v.toString()]=r.hour.map(()=>0)});for(const[v,S]of Object.entries(J))q[v]&&o.getArrUnique(S).forEach(C=>{q[v][C]=1});const H=[];return Object.keys(q).forEach(v=>{const S=parseInt(o.getArrClone(q[v]).reverse().join(""),2);H.push(S)}),H.join(",")},B=()=>{u.valueOut=o.isNonEmptyString(t.value)?t.value:"",y(t.value),p()};e.onMounted(()=>{e.nextTick(()=>{B()})}),e.watch(()=>t.value,N=>{const J=o.isNonEmptyString(N)?N:"";J!==u.valueOut&&(u.valueOut=J,y(J))}),e.watch(()=>t.disabled,N=>{N&&d.value&&d.value.setHoverOut()});const T=N=>{if(!t.disabled&&o.isExistJsonKey(r.quick,N)){const J=f(r.quick[N]);d.value&&d.value.setSelected(J,!0)}},D=N=>{if(o.isExistJsonKey(r.quick,N)){const J=f(r.quick[N]);d.value&&d.value.setHoverIn(J)}},x=N=>{d.value&&d.value.setHoverOut()},O=N=>{if(!Array.isArray(N))return;const J=E(N);u.valueOut=J,m(J)};return e.provide("$WeekHourTop",{week:r.week,hour:r.hour,getJsonConvertArr:f}),a({getValue:()=>u.valueOut,getValueData:()=>o.isNonEmptyString(u.valueOut)?g(u.valueOut):{},setValue:N=>{const J=o.isNonEmptyString(N)?N:"";u.valueOut=J,y(J)}}),(N,J)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(l),class:e.normalizeClass(c.value)},[e.createVNode(Ey,{disabled:n.disabled||n.isPlaintext,isOneDay:n.isOneDay,onOnClick:T,onOnHoverIn:D,onOnHoverOut:x},null,8,["disabled","isOneDay"]),e.createVNode(Ty,{ref_key:"refElPicker",ref:d,disabled:n.disabled||n.isPlaintext,isOneDay:n.isOneDay,onOnChange:O},null,8,["disabled","isOneDay"]),e.createVNode(My)],10,Oy))}});function Ay(n,a){switch(n){case"select":return o.isBoolean(a)?a:!1;case"radio":return!1;case"checkbox":case"selectTag":return!0;case"inputTag":return o.isBoolean(a)?a:!1;default:return!1}}function si(n,a){if(n!==!0)return"";let i="int";if(o.isNumber(a)){const t=Number.parseInt(String(a),10);if(t>0)switch(t.toString()){case"2":i="float2";break;case"3":i="float3";break;default:i="float"}}return i}const Ly={class:"xeditable-body"},$y={class:"xeditable-form"},Fy={key:1,class:"xeditable-element"},Py=["id"],Ry={key:0,class:"xeditable-errmsg"},xs=e.defineComponent({name:"ClXEditable",__name:"Index",props:{id:String,value:[String,Number],className:{type:String,default:""},classNameLabel:{type:String,default:""},type:{type:String,required:!0,validator:n=>["input","inputNumber","select","selectCascade","textarea","radio","checkbox","selectTag","inputTag","dateTime","slider","customHtml"].indexOf(n)!==-1},label:String,subUnitOptions:{type:Object,default:()=>({})},subUnitList:{type:Array,default:()=>[]},isUseOnSubmitCheck:{type:Boolean,default:!1},appendContainer:{type:String,default:""},isCheckValidate:{type:Boolean,default:!1},validateRules:{type:Array,default:()=>[{r:"required"}]},isUseEllipsis:{type:Boolean,default:!1},classNameEllipsis:{type:String,default:""},isAutoTooltip:{type:Boolean,default:!0},clickEditPoint:{type:String,default:"value",validator:n=>["value","icon"].indexOf(n)!==-1},isShowEditValue:{type:Boolean,default:!0},isShowEditIcon:{type:Boolean,default:!1},editIcon:{type:String,default:"edit"},isSubmitCleanValue:{type:Boolean,default:!1},submitCallback:Function,checkValidateCallback:Function},emits:["onSubmit","onChangeOpen"],setup(n,{expose:a,emit:i}){const t=n,s=i,l=e.useAttrs(),d=e.useSlots(),{optPageLanguage:u,getPageLanguage:r}=Le();r("xEditable");const c=e.useTemplateRef("refElDropdownLayer"),m=e.useTemplateRef("refElForm"),p=e.useTemplateRef("refElFormEdit"),f=e.useTemplateRef("refElSubmit"),h=e.useTemplateRef("refElCustom"),g=e.useTemplateRef("refElContent"),y=e.useTemplateRef("refElErrMsg"),V=t.id,E=e.reactive({keyIndex:`xeditable-${o.getRandom(8)}`,showText:"",subUnitValue:"",subUnitValueType:"",showMsg:"",isShowEmpty:!1,isBtnOperateCenter:!1}),B=e.ref({}),T=e.ref([]),D=e.reactive({status:0,startColor:"#FFFF80",endColor:"var(--cl-transparent, rgba(0, 0, 0, 0))"}),x={lastValue:"",runStep:"",isSubmitting:!1,submitValueDataSnapshot:null,isPendingHlight:!1,pendingValue:null,pendingOpt:null,hlightTimer:null,hlightTimer1:null,hlightTimer2:null,resizeEventCustomHtml:null,resizeEventErrMsg:null,resizeEventContent:null},O=e.computed(()=>{const{type:F}=t;return F==="input"||F==="inputNumber"||F==="select"}),w=e.computed(()=>!o.isUndefined(d.iconLabel)),M=e.computed(()=>{let F={"panel-x-editable":!0};return F=o.getJsonMerge(F,de.getClassNameJson(t.className)),o.getStringByJson(F," ")}),b=e.computed(()=>{const F=["xeditable-value"];return E.isShowEmpty&&F.push("xeditable-empty"),(t.isShowEditIcon||w.value)&&F.push("xeditable-edit-icon"),F.join(" ")}),N=e.computed(()=>{const F=["xeditable-value-label"],{clickEditPoint:j}=t;return j==="value"||E.isShowEmpty?F.push("dropdownLayer-arrow-anchorPoint"):F.push("xeditable-click-invalid"),F.join(" ")}),J=e.computed(()=>{const F=["xeditable-value-editIcon","dropdownLayer-arrow-anchorPoint"];return w.value&&F.push("xeditable-value-editIcon-slot"),F.join(" ")}),q=e.computed(()=>{const F=["xeditable-ellipsis"];return F.push(t.classNameEllipsis),D.status===2&&F.push("xeditable-value-hlight"),F.join(" ")}),z=e.computed(()=>{const F=["xeditable-dropdown"];return F.push(`xeditable-dropdown-${t.type}`),F.join(" ")}),H=e.computed(()=>{const F={};return E.isBtnOperateCenter&&(F["text-align"]="center"),F}),v=e.computed(()=>{const F={};switch(D.status){case 1:F["background-color"]=D.startColor;break;case 2:F["background-color"]=D.endColor;break}return F}),S=F=>{const j=de.getElementData(l);s("onSubmit",F,j)},C=F=>{e.nextTick(()=>{const j=de.getElementData(l);s("onChangeOpen",F,j)})},$=()=>{c.value&&c.value.setOpen(!1),f.value&&f.value.loadStop()},k=F=>{E.showMsg=o.isEmpty(F)?"":F,e.nextTick(()=>{c.value&&c.value.calculationPosition()})},I=()=>Ay(t.type,B.value.multiple),L=()=>{const F=o.getJsonClone(t.subUnitOptions);switch(t.type){case"input":{let j={isClean:!0};j=o.getJsonMerge(j,F);const le=o.isBoolean(j.isNumber)?j.isNumber:!1;E.subUnitValueType=si(le,j.decimal),B.value=j;break}case"inputNumber":{let j={isNumber:!0,isClean:!0};j=o.getJsonMerge(j,F);const le=si(!0,j.decimal)||"int";E.subUnitValueType=le,B.value=j;break}case"select":{let j={multiple:!1,placeholder:u.value.common.pleaseSelect};j=o.getJsonMerge(j,F),B.value=j;break}case"selectCascade":{let j={};j=o.getJsonMerge(j,F),B.value=j,E.isBtnOperateCenter=!0;break}case"textarea":{let j={isClean:!0};j=o.getJsonMerge(j,F),B.value=j,E.isBtnOperateCenter=!0;break}case"radio":{let j={isInline:!0,name:`${E.keyIndex}-radio`};j=o.getJsonMerge(j,F),B.value=j,E.isBtnOperateCenter=j.isInline;break}case"checkbox":{let j={isInline:!1,name:`${E.keyIndex}-checkbox`};j=o.getJsonMerge(j,F),B.value=j,E.isBtnOperateCenter=j.isInline;break}case"selectTag":{let j={type:"radio"};j=o.getJsonMerge(j,F),B.value=j,E.isBtnOperateCenter=!0;break}case"inputTag":{let j={multiple:!0,isAutofill:!0};j=o.getJsonMerge(j,F),B.value=j,E.isBtnOperateCenter=!0;break}case"dateTime":{let j={isDropdown:!1};j=o.getJsonMerge(j,F),B.value=j,E.isBtnOperateCenter=!0;break}case"slider":{let j={};j=o.getJsonMerge(j,F),B.value=j,E.isBtnOperateCenter=!0;break}case"customHtml":{E.isBtnOperateCenter=!0;break}}},_=(F,j)=>{let le=!1,me=!1;j&&(o.isUndefined(j.label)||(le=!0),o.isUndefined(j.list)||(me=!0));let ie="",ne="",A="";switch(o.isString(F)?A=F:o.isNumber(F)&&o.isFinite(F)&&F!==void 0&&(A=F.toString()),t.type){case"input":case"inputNumber":case"textarea":{if(!le&&A&&!o.isEmpty(A))if((t.type==="inputNumber"||t.type==="input"&&o.isBoolean(B.value.isNumber)&&B.value.isNumber)&&o.isNumber(A)){const ce=E.subUnitValueType==="float"?B.value.decimal:"";ie=o.getValueByFormat(A,E.subUnitValueType,{decimalNum:ce})}else ie=A;ne=A;break}case"selectCascade":{if(!le){const te=me?j.list:T.value,ce=o.isNonEmptyString(B.value.parentKey)?B.value.parentKey:"parentId",pe=o.isNonEmptyString(B.value.topParentValue)?B.value.topParentValue:"0";if(A&&!o.isEmpty(A)){const he={};o.isArray(te)&&te.forEach(De=>{!o.isUndefined(De)&&!o.isUndefined(De.id)&&(he[De.id.toString()]=De)});const Ee=[],be={};let xe=A.toString();for(;!o.isEmpty(xe)&&!o.isExistJsonKey(be,xe)&&o.isExistJsonKey(he,xe);){be[xe]=!0;const De=he[xe];o.isEmpty(De.name)?(o.isNumber(De.name)||o.isString(De.name))&&Ee.push(De.name.toString()):Ee.push(De.name),xe=De[ce]!==void 0&&De[ce]!==null?De[ce].toString():"",xe===pe&&(xe="")}Ee.reverse(),ie=Ee.join(" → ")}}ne=A;break}case"select":case"radio":case"checkbox":case"selectTag":case"inputTag":{const te=me?j.list:o.isArray(B.value.list)?B.value.list:T.value;if(!le&&A&&!o.isEmpty(A))if(t.type==="inputTag")ie=A;else{const ce=I(),pe=[],he=ce?A.split(","):[A.toString()],Ee=o.isArray(te)?te.filter(xe=>!o.isUndefined(xe)&&!o.isUndefined(xe.id)):te,be=o.getJsonByList(Ee);he.forEach(xe=>{o.isExistJsonKey(be,xe)&&pe.push(be[xe].name)}),ie=pe.join(",")}ne=A;break}case"dateTime":{le||(ie=A),ne=A;break}case"slider":{le||(ie=A),ne=A;break}}t.isSubmitCleanValue&&(ne="",m.value&&m.value.reset()),E.showText=le?j.label.toString():ie,E.subUnitValue=ne,E.isShowEmpty=o.isEmpty(E.showText),x.lastValue=E.subUnitValue,me&&(T.value=j.list)},R=()=>{x.hlightTimer&&(clearTimeout(x.hlightTimer),x.hlightTimer=null),x.hlightTimer1&&clearTimeout(x.hlightTimer1),x.hlightTimer2&&clearTimeout(x.hlightTimer2),D.status=1,e.nextTick(()=>{x.hlightTimer1=setTimeout(()=>{D.status=2},10),x.hlightTimer2=setTimeout(()=>{D.status=0},1500)})},P=()=>{x.isPendingHlight=!1,x.pendingOpt!==null&&_(x.pendingValue,x.pendingOpt||{}),x.pendingValue=null,x.pendingOpt=null,R()},Q=F=>{if(o.isBoolean(F)?F={success:F}:(o.isUndefined(F)||!o.isObject(F))&&(F={success:!1}),F.success){k(""),m.value&&m.value.reset();let j=null;x.submitValueDataSnapshot?j=x.submitValueDataSnapshot:p.value&&(j=p.value.getValueData()),o.isUndefined(j)&&(j={});let le="";const me={},ie=o.isEmpty(F.data)?{}:F.data,ne=o.isUndefined(ie.label),A=!ne&&(o.isString(ie.label)||o.isNumber(ie.label));switch(me.label=A?ie.label:null,t.type){case"input":case"inputNumber":case"textarea":case"dateTime":case"slider":le=j.value;break;case"selectCascade":{ne&&(me.label=j.show||j.value||""),le=j.value?j.value.toString():"",o.isArray(ie.list)&&(me.list=ie.list);break}case"select":case"radio":case"checkbox":case"selectTag":case"inputTag":{if(I()&&o.isArray(j)){const te=[],ce=[];j.forEach(pe=>{te.push(pe.id),ce.push(pe.name)}),ne&&(me.label=ce.join(",")),le=t.type==="inputTag"?ce.join(","):te.join(",")}else ne&&(me.label=j.name||""),le=t.type==="inputTag"?j.name||"":j.id?j.id.toString():"";o.isArray(ie.list)&&(me.list=ie.list);break}}x.runStep!=="updateProps"?(x.pendingValue=le,x.pendingOpt=me,x.isPendingHlight=!0,$()):(_(le,me),$()),x.hlightTimer&&clearTimeout(x.hlightTimer),x.hlightTimer=setTimeout(()=>{x.hlightTimer=null,x.isPendingHlight&&(x.isPendingHlight=!1,P())},400)}else k(F.msg),e.nextTick(()=>{f.value&&f.value.loadStop()});x.isSubmitting=!1},oe=()=>{L(),_(t.value,{label:t.label,list:t.subUnitList})},ue=async()=>{let F=!1;if(t.isCheckValidate&&m.value){try{F=await m.value.validate()===!0}catch(j){F=!1,Se.warn("ClXEditable","表单校验执行异常",j)}if(t.checkValidateCallback&&o.isFunction(t.checkValidateCallback)){const j=de.getElementData(l),le=Z();let me=!0;try{me=await t.checkValidateCallback(le,j)}catch(ie){me=!1,Se.warn("ClXEditable","checkValidateCallback 执行异常",ie)}me=o.isBoolean(me)?me:!0,me||(F=!1)}}else F=!0;return F},Y=()=>{let F=!1;return t.submitCallback&&o.isFunction(t.submitCallback)&&(F=!0),F},Z=()=>{let F="";return t.type!=="customHtml"&&(F=p.value?p.value.getValue():""),F},se=()=>{if(Y()){const F=Z(),j=de.getElementData(l),le=t.submitCallback?t.submitCallback(F,j):void 0;if(le&&o.isFunction(le.then))le.then(me=>{Q(o.isBoolean(me)?{success:me}:me)}).catch(()=>{Q({success:!1,msg:u.value.submitCallback})});else{let me={};o.isUndefined(le)?me={success:!0}:o.isBoolean(le)?me={success:le}:o.isObject(le)&&o.isBoolean(le.success)?me=le:me={success:!1,msg:u.value.submitCallback},Q(me)}}};e.onMounted(()=>{e.nextTick(()=>{oe()})}),e.onUnmounted(()=>{x.hlightTimer&&clearTimeout(x.hlightTimer),x.hlightTimer1&&clearTimeout(x.hlightTimer1),x.hlightTimer2&&clearTimeout(x.hlightTimer2),x.resizeEventCustomHtml&&(x.resizeEventCustomHtml.destroy(),x.resizeEventCustomHtml=null),x.resizeEventErrMsg&&(x.resizeEventErrMsg.destroy(),x.resizeEventErrMsg=null),x.resizeEventContent&&(x.resizeEventContent.destroy(),x.resizeEventContent=null)}),e.watch([()=>t.value,()=>t.label,()=>t.subUnitList],([F,j,le],[me,ie,ne])=>{(F!==me||j!==ie||le!==ne)&&(F!==me&&(x.runStep="updateProps"),_(F,{label:j,list:le}))}),e.watch(()=>t.subUnitOptions,()=>{L(),_(E.subUnitValue,{label:t.label,list:t.subUnitList})});const K=()=>{x.isSubmitting||(x.isSubmitting=!0,p.value&&(x.submitValueDataSnapshot=p.value.getValueData()),ue().then(F=>{if(F)if(t.type==="customHtml")x.runStep="first",Y()?se():(Se.warn("ClXEditable","customHtml 类型必须配置 submitCallback 才能提交"),x.isSubmitting=!1,$());else{const j=Z(),le=o.isEmpty(j);String(j)!==x.lastValue||le&&E.showText.length>0?(x.runStep="first",Y()?se():(t.isUseOnSubmitCheck||Q({success:!0}),S(j))):(x.isSubmitting=!1,$())}else Q({success:!1})}).catch(()=>{Q({success:!1})}))},W=()=>{$()},U=()=>{c.value&&(c.value.checkIsShowOpen()||c.value.initCompleteOpen())},ae=()=>{x.isPendingHlight&&(x.isPendingHlight=!1,x.hlightTimer&&(clearTimeout(x.hlightTimer),x.hlightTimer=null),x.hlightTimer=setTimeout(()=>{x.hlightTimer=null,P()},150))},G=F=>{F?(x.lastValue=E.subUnitValue,k(""),e.nextTick(()=>{c.value&&c.value.checkIsShowOpen()&&(t.type==="customHtml"?(U(),h.value&&(x.resizeEventCustomHtml&&x.resizeEventCustomHtml.destroy(),x.resizeEventCustomHtml=new ht({element:h.value,callback:()=>{c.value&&c.value.calculationPosition()}}))):(g.value&&(x.resizeEventContent&&x.resizeEventContent.destroy(),x.resizeEventContent=new ht({element:g.value,callback:()=>{c.value&&c.value.calculationPosition()}})),y.value&&(x.resizeEventErrMsg&&x.resizeEventErrMsg.destroy(),x.resizeEventErrMsg=new ht({element:y.value,callback:()=>{c.value&&c.value.calculationPosition()}}))))})):(x.isPendingHlight||(E.subUnitValue=x.lastValue),x.resizeEventCustomHtml&&(x.resizeEventCustomHtml.destroy(),x.resizeEventCustomHtml=null),x.resizeEventErrMsg&&(x.resizeEventErrMsg.destroy(),x.resizeEventErrMsg=null),x.resizeEventContent&&(x.resizeEventContent.destroy(),x.resizeEventContent=null)),C(F)},X=F=>{const j=de.getParent(F.target,".xeditable-click-invalid",F.currentTarget,!1);o.isUndefined(j)||(F.preventDefault(),F.stopPropagation())};return a({setOnSubmitResult:F=>{t.isUseOnSubmitCheck&&o.isUndefined(t.submitCallback)&&x.isSubmitting&&Q(F)}}),(F,j)=>(e.openBlock(),e.createBlock(eo,{ref_key:"refElDropdownLayer",ref:c,id:e.unref(V),classParent:M.value,classText:n.classNameLabel,classDropDown:z.value,dropdownArrowPos:"center",dropDownPos:"up",isUseDropdownArrow:!0,isCloseDestroy:!0,isInitDelayComplete:!0,appendContainer:n.appendContainer,onOnChangeOpen:G,onOnAfterLeave:ae,transitionEnter:"animated fadeIn",transitionLeave:"animated fadeOut"},{label:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(b.value)},[n.isShowEditValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(N.value),onClick:j[0]||(j[0]=le=>X(le))},[n.isUseEllipsis&&E.showText.length>0?(e.openBlock(),e.createBlock(Zo,{key:0,className:q.value,isUseTooltipAuto:n.isAutoTooltip,text:E.showText,style:e.normalizeStyle(v.value)},null,8,["className","isUseTooltipAuto","text","style"])):(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass({"xeditable-value-hlight":D.status===2}),style:e.normalizeStyle(v.value)},e.toDisplayString(E.showText),7))],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.isShowEditIcon||w.value?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(J.value)},[e.renderSlot(F.$slots,"iconLabel",{},()=>[e.createVNode(ve,{name:n.editIcon},null,8,["name"])])],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],2)]),dropdown:e.withCtx(()=>[e.createElementVNode("div",{ref_key:"refElContent",ref:g,class:"xeditable-content"},[e.createElementVNode("div",Ly,[e.createElementVNode("div",$y,[e.createVNode(ea,{ref_key:"refElForm",ref:m,isScrollToErr:!1},{default:e.withCtx(()=>[n.type==="customHtml"?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"refElCustom",ref:h,class:"xeditable-custom"},[e.renderSlot(F.$slots,"customForm")],512)):(e.openBlock(),e.createElementBlock("div",Fy,[e.createVNode(Gn,{isCheck:n.isCheckValidate,checkValue:E.subUnitValue,rules:n.validateRules,msgElementId:O.value?`#${E.keyIndex}_errmsg`:""},{default:e.withCtx(()=>[n.type==="inputNumber"?(e.openBlock(),e.createBlock(_t,e.mergeProps({key:0,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[1]||(j[1]=le=>E.subUnitValue=le)},B.value,{onOnInit:U}),null,16,["value"])):n.type==="input"&&B.value.isNumber?(e.openBlock(),e.createBlock(_t,e.mergeProps({key:1,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[2]||(j[2]=le=>E.subUnitValue=le)},B.value,{onOnInit:U}),null,16,["value"])):n.type==="input"?(e.openBlock(),e.createBlock(Pe,e.mergeProps({key:2,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[3]||(j[3]=le=>E.subUnitValue=le)},B.value,{onOnInit:U}),null,16,["value"])):n.type==="textarea"?(e.openBlock(),e.createBlock(Qn,e.mergeProps({key:3,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[4]||(j[4]=le=>E.subUnitValue=le)},B.value,{onOnInit:U}),null,16,["value"])):n.type==="select"?(e.openBlock(),e.createBlock(En,e.mergeProps({key:4,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[5]||(j[5]=le=>E.subUnitValue=le),list:T.value},B.value,{onOnInit:U}),null,16,["value","list"])):n.type==="selectCascade"?(e.openBlock(),e.createBlock(pa,e.mergeProps({key:5,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[6]||(j[6]=le=>E.subUnitValue=le),list:T.value},B.value,{onOnInit:U}),null,16,["value","list"])):n.type==="radio"?(e.openBlock(),e.createBlock(oa,e.mergeProps({key:6,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[7]||(j[7]=le=>E.subUnitValue=le),list:T.value},B.value,{onOnInit:U}),null,16,["value","list"])):n.type==="checkbox"?(e.openBlock(),e.createBlock(Yo,e.mergeProps({key:7,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[8]||(j[8]=le=>E.subUnitValue=le),list:T.value},B.value,{onOnInit:U}),null,16,["value","list"])):n.type==="selectTag"?(e.openBlock(),e.createBlock(fa,e.mergeProps({key:8,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[9]||(j[9]=le=>E.subUnitValue=le),list:T.value},B.value,{onOnInit:U}),null,16,["value","list"])):n.type==="inputTag"?(e.openBlock(),e.createBlock(da,e.mergeProps({key:9,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[10]||(j[10]=le=>E.subUnitValue=le),list:T.value},B.value,{onOnInit:U}),null,16,["value","list"])):n.type==="dateTime"?(e.openBlock(),e.createBlock(ca,e.mergeProps({key:10,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[11]||(j[11]=le=>E.subUnitValue=le)},B.value,{onOnInit:U}),null,16,["value"])):n.type==="slider"?(e.openBlock(),e.createBlock(ia,e.mergeProps({key:11,ref_key:"refElFormEdit",ref:p,value:E.subUnitValue,"onUpdate:value":j[12]||(j[12]=le=>E.subUnitValue=le)},B.value,{onOnInit:U}),null,16,["value"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:12},[],64))]),_:1},8,["isCheck","checkValue","rules","msgElementId"])]))]),_:3},512)]),e.createElementVNode("div",{class:"xeditable-operate",style:e.normalizeStyle(H.value)},[e.createVNode(Qe,{ref_key:"refElSubmit",ref:f,iconName:"check",isShowLoad:!0,loadPos:"zoom-out",loadTheme:"rotaryLine",onOnClick:K},null,512),e.createVNode(Qe,{iconName:"close",color:"grayLight",onOnClick:W})],4)]),O.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[n.isCheckValidate?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"refElErrMsg",ref:y,id:`${E.keyIndex}_errmsg`,class:"xeditable-errmsg"},null,8,Py)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[E.showMsg.length>0?(e.openBlock(),e.createElementBlock("div",Ry,e.toDisplayString(E.showMsg),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))],64)):e.createCommentVNode("",!0)],512)]),_:3},8,["id","classParent","classText","classDropDown","appendContainer"]))}}),Hy={class:"notify-item"},Uy={class:"notify-icon"},zy={class:"notify-text"},Jy=["innerHTML"],Ky=e.defineComponent({name:"ClNotifyItem",__name:"Notify",props:{isShow:{type:Boolean},itemInfo:{}},emits:["onMouseOver","onMouseOut","onDestroy"],setup(n,{emit:a}){const i=n,t=a,s=e.ref(!1),l=e.computed(()=>({progress:!0,"progress-hide":s.value})),d=e.computed(()=>({"progress-bar":!0,"progress-countdown":!s.value})),u=e.computed(()=>{const p={},f=i.itemInfo?.delay;return o.isFinite(f)&&f>0&&(p["animation-duration"]=`${f}s`),p}),r=()=>{!i.itemInfo||!i.isShow||(s.value=!0,t("onMouseOver",i.itemInfo.key))},c=()=>{!i.itemInfo||!i.isShow||(s.value=!1,t("onMouseOut",i.itemInfo.key))},m=()=>{!i.itemInfo||!i.isShow||t("onDestroy",i.itemInfo.key)};return(p,f)=>(e.openBlock(),e.createBlock(e.Transition,{name:"notify","enter-active-class":n.itemInfo?.clsTransitionEnter,"leave-active-class":n.itemInfo?.clsTransitionLeave},{default:e.withCtx(()=>[n.isShow&&n.itemInfo?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(n.itemInfo.clsContainer),role:"status","aria-live":"polite",onClick:m,onMouseenter:r,onMouseleave:c},[e.createElementVNode("div",Hy,[e.createElementVNode("div",Uy,[e.createVNode(ve,{name:n.itemInfo.iconName},null,8,["name"])]),e.createElementVNode("div",zy,[e.createElementVNode("div",{innerHTML:n.itemInfo.text},null,8,Jy)]),e.createElementVNode("button",{type:"button",class:"notify-close",title:"关闭",onClick:e.withModifiers(m,["stop"])},[e.createVNode(ve,{name:"close"})])]),n.itemInfo.isProgress?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(l.value)},[e.createElementVNode("div",{class:e.normalizeClass(d.value),style:e.normalizeStyle(u.value)},null,6)],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],34)):e.createCommentVNode("",!0)]),_:1},8,["enter-active-class","leave-active-class"]))}}),Wy=["id"],jy=2*1e3,Yy=1e3,qy=2147483,Xy=e.defineComponent({name:"ClNotify",__name:"Notifys",props:{id:String,className:String,position:{type:String,default:"top-right"},isProgress:{type:Boolean,default:!1},delay:{type:Number,default:3}},setup(n,{expose:a}){const i=n,t=`notify-pos-${o.getRandom(5)}`,s=`notify-item-${o.getRandom(5)}`;let l=0;const d=i.id,u={info:"info",success:"check",error:"close-circle-fill",warn:"warn-fill"},r={type:["info","success","error","warn"],position:["top-right","top-center","bottom-right"]},c=e.useTemplateRef("refElTopParent"),m=e.ref([]),p=e.reactive({"top-right":[],"top-center":[],"bottom-right":[]}),f=e.reactive({}),h=e.reactive({});let g,y=!1;const V=e.computed(()=>{let C={"panel-notify":!0};return C=o.getJsonMerge(C,de.getClassNameJson(i.className)),C}),E=()=>document.body,B=()=>{const C=c.value;return!!C&&C.isConnected},T=()=>{if(y){Se.warn("Notify","组件已销毁,无法添加通知");return}if(B())clearTimeout(g),g=void 0;else{const C=E();C&&c.value&&C.appendChild(c.value)}},D=()=>{clearTimeout(g),g=void 0,e.nextTick(()=>{B()&&m.value.length===0&&(g=setTimeout(()=>{const C=c.value;C&&C.isConnected&&C.remove()},jy))})},x=C=>{let $={key:"",text:"",iconName:"",isProgress:!1,delay:i.delay,clsContainer:{},clsTransitionEnter:"",clsTransitionLeave:""},k=-1;if(!o.isNonEmptyString(C))return{info:$,inx:k,pos:""};const I=C.split("_item_")[0].replace("notify_",""),L=p[I];return o.isUndefined(L)||L.forEach((_,R)=>{_.key===C&&($=_,k=R)}),{info:$,inx:k,pos:I}},O=C=>{if(x(C).inx>-1){const k=m.value.indexOf(C);k>-1&&m.value.splice(k,1),h[C]=setTimeout(()=>{delete h[C];const I=x(C);I.inx>-1&&p[I.pos].splice(I.inx,1),!o.isUndefined(p[I.pos])&&p[I.pos].length===0&&m.value.length===0&&D()},Yy)}},w=(C,$)=>{const k=Math.min($,qy);f[C]=setTimeout(()=>{delete f[C],O(C)},k*1e3)},M=C=>{let $="animated fadeInDown",k="animated fadeOutRight";switch(C){case"top-center":$="animated fadeInDown",k="animated fadeOut";break;case"bottom-right":$="animated fadeInUp",k="animated fadeOutRight";break}return{clsTransitionEnter:$,clsTransitionLeave:k}},b=C=>{if(y){Se.warn("Notify","组件已销毁,无法添加通知");return}if(!o.isEmpty(C)&&o.isNonEmptyString(C.msg)){T();const $=o.isExistValue(r.type,C.type||"")&&C.type?C.type:r.type[0];let k=i.position;if(o.isNonEmptyString(C.position)&&(k=C.position),!o.isExistValue(r.position,k)){const Y=o.isString(k)?k:"未知";Se.warn("Notify",`position 无效(${Y}),已回退为 ${r.position[0]}`),k=r.position[0]}const I=C.isProgress;let L=i.isProgress;o.isBoolean(I)&&I!==void 0&&(L=I);const _=C.delay,R=o.isFinite(_)&&_!==void 0&&_>0?Number(_):i.delay;let P={"notify-container":!0,"notify-progress":L};P[`notify-${$}`]=!0,o.isNonEmptyString(C.className)&&(P=o.getJsonMerge(P,de.getClassNameJson(C.className)));const Q=M(k);l+=1;const oe=`notify_${k}_item_${l}`,ue={key:oe,text:o.encodeHTML(C.msg),iconName:u[$],isProgress:L,delay:R,clsContainer:P,clsTransitionEnter:Q.clsTransitionEnter,clsTransitionLeave:Q.clsTransitionLeave};p[k].push(ue),e.nextTick(()=>{x(ue.key).inx>-1&&(m.value.push(ue.key),w(oe,ue.delay))})}else Se.warn("Notify","通知内容为空,已忽略")},N=()=>{Object.keys(f).forEach(C=>{clearTimeout(f[C]),delete f[C]}),Object.keys(h).forEach(C=>{clearTimeout(h[C]),delete h[C]}),clearTimeout(g),g=void 0};e.onBeforeUnmount(()=>{y=!0,N();const C=c.value;C&&C.isConnected&&C.remove()});const J=C=>{f[C]&&(clearTimeout(f[C]),delete f[C])},q=C=>{const $=x(C);$.inx>-1&&w(C,$.info.delay)},z=C=>{f[C]&&(clearTimeout(f[C]),delete f[C]),O(C)};return a({addCustom:C=>{b(C)},clear:()=>{r.position.forEach(C=>{p[C]=[]}),m.value=[],N(),D()},destroy:()=>{y=!0,r.position.forEach(C=>{p[C]=[]}),m.value=[],N(),D()}}),(C,$)=>(e.openBlock(),e.createElementBlock("div",{class:e.normalizeClass(V.value),ref_key:"refElTopParent",ref:c,id:e.unref(d)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(p,(k,I,L)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${t}-${I}-${L}`},[k.length>0?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(`notify-wrapper notify-${I}`)},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(k,_=>(e.openBlock(),e.createBlock(Ky,{key:`${s}-${_.key}`,isShow:m.value.includes(_.key),itemInfo:_,onOnDestroy:z,onOnMouseOver:J,onOnMouseOut:q},null,8,["isShow","itemInfo"]))),128))],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))),128))],10,Wy))}}),Bs=(n={})=>{const a=e.createApp(Xy,n),i=document.createElement("div"),t=a.mount(i),s=t;return{info:(l,d={})=>{const u=o.getJsonMerge(d,{type:"info",msg:l});s.addCustom(u)},success:(l,d={})=>{const u=o.getJsonMerge(d,{type:"success",msg:l});s.addCustom(u)},error:(l,d={})=>{const u=o.getJsonMerge(d,{type:"error",msg:l});s.addCustom(u)},warn:(l,d={})=>{const u=o.getJsonMerge(d,{type:"warn",msg:l});s.addCustom(u)},custom:l=>{s.addCustom(l)},clear:()=>{s.clear()},destroy:()=>{const l=t.$el||null;s.destroy(),a.unmount(),l&&l.parentNode&&l.parentNode.removeChild(l)}}},Gy=["id","aria-label"],Qy={class:"alert-body"},Zy={key:0,class:"alert-icon"},ev={key:2,class:"alert-title"},tv={key:4,class:"alert-text"},nv=["innerHTML"],ov={key:1},av={key:6,class:"alert-operate"},iv=2*1e3,sv=e.defineComponent({name:"ClAlert",__name:"Alert",props:{id:String,width:{type:String,default:"500px"},isBackClick:{type:Boolean,default:!0},submitLabel:{type:String,default:"确定"},submitColor:{type:String,default:"default"},cancelLabel:{type:String,default:"取消"},cancelColor:{type:String,default:"grayLight"},classTransitionEnter:{type:String,default:"animated zoomIn"},classTransitionLeave:String},setup(n,{expose:a}){const i=n,t=i.id||`alert-${o.getRandom(5)}`,s=e.useTemplateRef("refElTopParent"),l=e.useTemplateRef("refElTransition"),d=e.useTemplateRef("refElBtnSubmit"),u=e.reactive({isLoadBackClick:!0}),r=e.reactive({id:t,width:i.width,isBackClick:!1,iconClass:"",iconName:"",iconColor:"",isShowIcon:!1,title:"",isShowTitle:!1,text:"",html:"",isShowTextHtml:!1,isShowText:!1,submitLabel:"",submitIcon:"",submitColor:"default",cancelLabel:"",cancelIcon:"",cancelColor:"grayLight",isShowSubmit:!1,isShowSubmitLoad:!1,isShowCancel:!1,isShowOperate:!1,isShow:!1}),c=e.reactive({submit:null,cancel:null});let m=null,p=!1;const f=e.ref(!1);let h=null;const g={info:{name:"info-circle",color:"var(--cl-primary, #1088f0)"},success:{name:"check-circle",color:"var(--cl-success, #12b76a)"},error:{name:"exclamation-circle",color:"var(--cl-danger, #ee0a24)"},warn:{name:"warn-fill",color:"#fbe300"},doubt:{name:"question-circle",color:"#0ac5c5"}},y=()=>document.querySelector("body"),V=()=>document.getElementById(r.id),E=()=>V()!==null,B=()=>{if(E())(m!==null||p)&&(m!==null&&(clearTimeout(m),m=null),p=!1);else{if(!s.value){Se.warn("ClAlert","refElTopParent 未初始化,无法创建容器");return}y()?.appendChild(s.value)}},T=()=>{p=!0,m!==null&&(clearTimeout(m),m=null),e.nextTick(()=>{p=!1,E()&&!r.isShow&&(m=setTimeout(()=>{const v=V();v&&y()?.removeChild(v),m=null},iv))})},D=v=>{if(!v||typeof v!="object"||Array.isArray(v))return{id:t,width:i.width,isBackClick:i.isBackClick,iconClass:"",iconName:"",iconColor:"",isShowIcon:!1,title:"",isShowTitle:!1,text:"",html:"",isShowTextHtml:!1,isShowText:!1,submitLabel:i.submitLabel,submitIcon:"",submitColor:i.submitColor,isShowSubmit:!1,isShowSubmitLoad:!1,cancelLabel:i.cancelLabel,cancelIcon:"",cancelColor:i.cancelColor,isShowCancel:!1,isShowOperate:!1,isShow:!1};const S=o.isBoolean(v.isBackClick)?v.isBackClick:i.isBackClick,C=o.isNonEmptyString(v.id)?v.id:t,$=o.isNonEmptyString(v.width)?v.width:i.width;let k="",I="",L="";if(!o.isEmpty(v.iconType)){const G=Object.prototype.hasOwnProperty.call(g,v.iconType)?g[v.iconType]:void 0;G&&(I=G.name,L=G.color)}o.isEmpty(I)&&o.isNonEmptyString(v.icon)&&(k=v.icon);const _=!o.isEmpty(I)||!o.isEmpty(k),R=o.isNonEmptyString(v.title),P=o.isNonEmptyString(v.html),Q=o.isNonEmptyString(v.text)||P,oe=o.isEmpty(v.submitLabel)?i.submitLabel:v.submitLabel,ue=o.isEmpty(v.submitColor)?i.submitColor:v.submitColor,Y=o.isEmpty(v.cancelLabel)?i.cancelLabel:v.cancelLabel,Z=o.isEmpty(v.cancelColor)?i.cancelColor:v.cancelColor,se=o.isBoolean(v.isSubmit)?v.isSubmit:!1,K=o.isBoolean(v.isLoad)?v.isLoad:!1,W=o.isBoolean(v.isCancel)?v.isCancel:!1,U=se||W,ae=R||Q;return{id:C,width:$,isBackClick:S,iconClass:k,iconName:I,iconColor:L,isShowIcon:_,title:R?v.title:"",isShowTitle:R,text:o.isNonEmptyString(v.text)?v.text:"",html:P?v.html:"",isShowTextHtml:P,isShowText:Q,submitLabel:oe,submitIcon:o.isNonEmptyString(v.submitIcon)?v.submitIcon:"",submitColor:ue,isShowSubmit:se,isShowSubmitLoad:K,cancelLabel:Y,cancelIcon:o.isNonEmptyString(v.cancelIcon)?v.cancelIcon:"",cancelColor:Z,isShowCancel:W,isShowOperate:U,isShow:ae}},x=v=>{if(r.isShow&&r.isShowSubmitLoad)return;const S=D(v);S.isShow?(B(),f.value=!1,Object.assign(r,S),c.submit=v.submitCallback??null,c.cancel=v.cancelCallback??null,document.addEventListener("keydown",w),h=document.activeElement,s.value?.focus({preventScroll:!0}),l.value?.show()):(c.submit=null,c.cancel=null,l.value?.hide(),r.isShow=!1)},O=()=>{r.isShowSubmitLoad&&d.value?.loadStop(),document.removeEventListener("keydown",w),h&&typeof h.focus=="function"&&(h.focus(),h=null),f.value=!1,l.value?.hide(),u.isLoadBackClick=!0,r.isShowSubmitLoad=!1,r.isShow=!1},w=v=>{v.key==="Escape"&&!r.isShowSubmitLoad?N():v.key==="Enter"&&r.isShowSubmit&&!r.isShowSubmitLoad&&b()},M=async()=>{if(f.value)return;O();const v=c.cancel;if(v&&o.isFunction(v))try{await v()}catch(S){Se.error("ClAlert","cancel 回调执行异常:",S)}};e.onBeforeUnmount(()=>{if(document.removeEventListener("keydown",w),h&&typeof h.focus=="function"&&(h.focus(),h=null),p=!1,m!==null&&(clearTimeout(m),m=null),E()){const v=V();v&&y()?.removeChild(v)}}),e.watch(()=>r.isShow,v=>{v||T()});const b=async()=>{if(f.value)return;const v=c.submit;if(v&&o.isFunction(v)){r.isShowSubmitLoad&&(u.isLoadBackClick=!1),f.value=!0;try{await v()}catch(S){Se.error("ClAlert","submit 回调执行异常:",S),O()}}else O()},N=async()=>{await M()},J=async()=>{await M()};return a({open:v=>{x(v)},hide:()=>{O()},reset:()=>{f.value=!1,r.isShowSubmitLoad&&(d.value?.loadStop(),r.isShowSubmitLoad=!1)}}),(v,S)=>(e.openBlock(),e.createElementBlock("div",{id:r.id,class:"panel-alert",ref_key:"refElTopParent",ref:s,role:"alertdialog","aria-modal":"true",tabindex:"-1","aria-label":r.title||r.text||"提示"},[e.createVNode(Ki,{isBackClick:r.isBackClick&&u.isLoadBackClick&&!f.value,classTransitionEnter:i.classTransitionEnter,classTransitionLeave:i.classTransitionLeave,width:r.width,onOnClickBack:J,ref_key:"refElTransition",ref:l},{default:e.withCtx(()=>[e.createElementVNode("div",Qy,[r.isShowIcon?(e.openBlock(),e.createElementBlock("div",Zy,[e.createVNode(ve,{name:r.iconName,color:r.iconColor,className:r.iconClass},null,8,["name","color","className"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),r.isShowTitle?(e.openBlock(),e.createElementBlock("div",ev,e.toDisplayString(r.title),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),r.isShowText?(e.openBlock(),e.createElementBlock("div",tv,[r.isShowTextHtml?(e.openBlock(),e.createElementBlock("div",{key:0,innerHTML:r.html},null,8,nv)):(e.openBlock(),e.createElementBlock("div",ov,e.toDisplayString(r.text),1))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64)),r.isShowOperate?(e.openBlock(),e.createElementBlock("div",av,[r.isShowSubmit?(e.openBlock(),e.createBlock(Qe,{key:0,ref_key:"refElBtnSubmit",ref:d,className:"alert-submit",isShowLoad:r.isShowSubmitLoad,isShowBackDrop:!0,label:r.submitLabel,icon:r.submitIcon,color:r.submitColor,onOnClick:b},null,8,["isShowLoad","label","icon","color"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),r.isShowCancel?(e.openBlock(),e.createBlock(Qe,{key:2,className:"alert-cancel",disabled:f.value,label:r.cancelLabel,icon:r.cancelIcon,color:r.cancelColor,onOnClick:N},null,8,["disabled","label","icon","color"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:7},[],64))])]),_:1},8,["isBackClick","classTransitionEnter","classTransitionLeave","width"])],8,Gy))}}),Ds=(n={})=>{const a=e.createApp(sv,n),i=document.createElement("div"),t=a.mount(i);return{alert:(s,l={})=>{const d=o.getJsonMerge({isSubmit:!0},l,{title:s,isCancel:!1,cancelCallback:null});t.open(d)},confirm:(s,l={})=>{const d=o.getJsonMerge({isSubmit:!0,isCancel:!0},l,{title:s});t.open(d)},custom:s=>{t.open(s)},close:()=>{t.hide()},reset:()=>{t.reset()},destroy:()=>{t.hide();const s=t.$el||null;a.unmount(),s&&s.parentNode&&s.parentNode.removeChild(s)}}},lv={class:"preview-image"},rv={class:"preview-image-actions-container"},cv={key:0},uv={key:2,class:"image-num"},dv={key:0,class:"preview-image-container"},mv=["src"],pv={key:0,class:"preview-image-loading"},fv=e.defineComponent({name:"ClPreviewImage",__name:"Image",props:{imageInx:{type:Number,default:0},list:{type:Array,default:()=>[]},isLoop:{type:Boolean,default:!1},isShowCopy:{type:Boolean,default:!0}},setup(n,{expose:a}){const i=n,t=e.inject("$PreviewTop");let s=null;const l=e.reactive({isShow:!1,isSwitch:!1,isLoading:!1,src:"",isFading:!1,scale:1,scaleRatio:1.4,rotate:0,rotateAngle:90,showIndex:i.imageInx}),d=e.computed(()=>{const x={},O=[];return O.push(`scale(${l.scale})`),O.push(`rotate(${l.rotate}deg)`),x.transform=O.join(" "),x.opacity=l.isFading?"0":"1",x}),u=()=>{if(!t)return;const{showIndex:x}=l,O=i.list,w=o.isArray(O)?O.length:0,M=w>0&&x>=0&&x<w;if(l.isShow=M,M){s&&clearTimeout(s);const b=l.isFading?200:0;setTimeout(()=>{l.isSwitch=!0,l.src=i.list[x],t.setPrevNextStatus(x,w),s=setTimeout(()=>{l.isLoading=!0},150)},b)}else l.isSwitch=!1},r=()=>{s&&(clearTimeout(s),s=null),l.isFading=!1,l.isLoading=!1},c=()=>{s&&(clearTimeout(s),s=null),l.isFading=!1,l.isLoading=!1},m=()=>{const{scale:x,scaleRatio:O}=l,w=x*O;w<7&&(l.scale=Number(w.toFixed(3)))},p=()=>{const{scale:x,scaleRatio:O}=l,w=x/O;w>.18&&(l.scale=Number(w.toFixed(3)))},f=()=>{const{rotate:x,rotateAngle:O}=l;l.rotate=(x-O)%360},h=()=>{const{rotate:x,rotateAngle:O}=l;l.rotate=(x+O)%360},g=()=>{l.scale=1,l.rotate=0};return a({show:x=>{l.showIndex=x,u()},hide:()=>{l.scale=1,l.rotate=0,l.isFading=!1,l.isShow=!1},prev:()=>{const{showIndex:x}=l;let O=-1;x>0?O=x-1:i.isLoop&&(O=i.list.length-1),O>-1&&(l.isFading=!0,l.showIndex=O,l.scale=1,l.rotate=0,u())},next:()=>{const{showIndex:x}=l;let O=-1;x<i.list.length-1?O=x+1:i.isLoop&&(O=0),O>-1&&(l.isFading=!0,l.showIndex=O,l.scale=1,l.rotate=0,u())},large:()=>{m()},small:()=>{p()}}),(x,O)=>(e.openBlock(),e.createElementBlock("div",lv,[l.isShow?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass({"preview-btn":!0,"preview-image-actions":!0,"preview-image-num":n.list.length>1})},[e.createElementVNode("div",rv,[e.createElementVNode("span",{onClick:e.withModifiers(m,["stop"])},[e.createVNode(ve,{name:"search-plus"})]),e.createElementVNode("span",{onClick:e.withModifiers(p,["stop"])},[e.createVNode(ve,{name:"search-minus"})]),e.createElementVNode("span",{onClick:e.withModifiers(f,["stop"])},[e.createVNode(ve,{name:"rotate-left"})]),e.createElementVNode("span",{onClick:e.withModifiers(h,["stop"])},[e.createVNode(ve,{name:"rotate-right"})]),e.createElementVNode("span",{onClick:e.withModifiers(g,["stop"])},[e.createVNode(ve,{name:"restore"})]),n.isShowCopy?(e.openBlock(),e.createElementBlock("span",cv,[e.createVNode(yn,{textLabel:l.src},null,8,["textLabel"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),n.list.length>1?(e.openBlock(),e.createElementBlock("span",uv,e.toDisplayString(l.showIndex+1)+"/"+e.toDisplayString(n.list.length),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),e.createVNode(e.Transition,{"enter-active-class":"preview-image-enter","leave-active-class":"preview-image-leave"},{default:e.withCtx(()=>[l.isShow?e.withDirectives((e.openBlock(),e.createElementBlock("div",dv,[e.withDirectives(e.createElementVNode("img",{src:l.src,style:e.normalizeStyle(d.value),onLoad:r,onError:c},null,44,mv),[[e.vShow,!l.isLoading]]),l.isLoading?(e.openBlock(),e.createElementBlock("div",pv,[...O[0]||(O[0]=[e.createElementVNode("div",{class:"preview-image-spinner"},null,-1)])])):e.createCommentVNode("",!0)],512)),[[e.vShow,l.isSwitch]]):e.createCommentVNode("",!0)]),_:1})]))}}),hv=["id"],gv=e.defineComponent({name:"ClPreview",__name:"Index",setup(n,{expose:a}){const i=e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./Video-DuP0_H4b.cjs"))),t=e.useTemplateRef("refElTopParent"),s=e.useTemplateRef("refElImage"),l=e.useTemplateRef("refElVideo"),d=e.reactive({elId:`preview-${o.getRandom(5)}`,className:"",type:"",list:[],isLoop:!1,isShowPrevNext:!1,isDisablePrev:!1,isDisableNext:!1,isShowCopy:!0});let u=null;const r=e.computed(()=>{let N={"panel-preview":!0};return N=o.getJsonMerge(N,de.getClassNameJson(d.className)),N}),c=e.computed(()=>d.type==="image"),m=e.computed(()=>d.type==="video"),p=()=>document.querySelector("body"),f=()=>document.querySelector("body>.panel-preview"),h=()=>{const N=f();return!o.isUndefined(N)},g=()=>{h()?(clearTimeout(u),u=null):(document.body.className=de.getAddClass(document.body.className,"preview-open"),p().appendChild(t.value))},y=N=>{let J=N.keyCode;if(!o.isUndefined(J))switch(J=J.toString(),J){case"38":N.preventDefault(),N.stopPropagation();break;case"40":N.preventDefault(),N.stopPropagation();break}},V=N=>{let J=N.keyCode;if(!o.isUndefined(J))switch(J=J.toString(),J){case"27":x();break;case"37":O();break;case"38":N.preventDefault(),N.stopPropagation(),c.value?s.value?.large():m.value&&O();break;case"39":w();break;case"40":N.preventDefault(),N.stopPropagation(),c.value?s.value?.small():m.value&&w();break}},E=()=>{window.removeEventListener("keydown",y),window.removeEventListener("keyup",V)},B=()=>{window.addEventListener("keydown",y),window.addEventListener("keyup",V)},T=(N=!1)=>{h()&&(u=setTimeout(()=>{const J=f();J&&(document.body.className=de.getRemoveClass(document.body.className,"preview-open"),p().removeChild(J)),E()},N?2*1e3:0))},D=N=>{if(!o.isEmpty(N)&&!o.isEmpty(N.src)){g(),o.isNonEmptyString(N.id)&&(d.elId=N.id),d.className=o.isNonEmptyString(N.className)?N.className:"";let J=[];const q=N.src;o.isArray(q)?J=q:o.isString(q)&&(J=[q]),d.type=N.type,d.list=J,d.isLoop=o.isBoolean(N.isLoop)?N.isLoop:!1,d.isShowCopy=o.isBoolean(N.isShowCopy)?N.isShowCopy:!0;const z=o.isEmpty(N.showIndex)?0:N.showIndex;B(),e.nextTick(()=>{c.value?s.value?.show(z):m.value&&l.value?.show(z)})}};e.onBeforeUnmount(()=>{clearTimeout(u),u=null,E();const N=f();N&&(document.body.className=de.getRemoveClass(document.body.className,"preview-open"),p().removeChild(N))});const x=()=>{c.value?s.value?.hide():m.value&&l.value?.hide(),T()},O=()=>{d.isDisablePrev||(c.value?s.value?.prev():m.value&&l.value?.prev())},w=()=>{d.isDisableNext||(c.value?s.value?.next():m.value&&l.value?.next())};return e.provide("$PreviewTop",{setPrevNextStatus:(N,J)=>{const q=J>1;if(d.isShowPrevNext=q,q){const{isLoop:z}=d;d.isDisablePrev=z?!1:N===0,d.isDisableNext=z?!1:N===J-1}}}),a({show:N=>{D(N)},destroy:()=>{T(),d.elId=`preview-${o.getRandom(5)}`,d.className="",d.type="",d.list=[],d.isLoop=!1,d.isShowPrevNext=!1,d.isDisablePrev=!1,d.isDisableNext=!1}}),(N,J)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"refElTopParent",ref:t,id:d.elId,class:e.normalizeClass(r.value)},[e.createVNode(Lt,{teleportTarget:"self",show:!0,background:"var(--cl-overlay, rgba(0, 0, 0, 0.5))",zIndex:0,isLockScroll:!1,duration:0}),e.createElementVNode("div",{class:"preview-btn preview-close",onClick:e.withModifiers(x,["stop"])},[e.createVNode(ve,{name:"close"})]),d.isShowPrevNext?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",{class:e.normalizeClass({"preview-btn":!0,"preview-prev":!0,"preview-btn-disable":d.isDisablePrev}),onClick:e.withModifiers(O,["stop"])},[e.createVNode(ve,{name:"angle-left"})],2),e.createElementVNode("div",{class:e.normalizeClass({"preview-btn":!0,"preview-next":!0,"preview-btn-disable":d.isDisableNext}),onClick:e.withModifiers(w,["stop"])},[e.createVNode(ve,{name:"angle-right"})],2)],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),c.value?(e.openBlock(),e.createBlock(fv,{key:2,ref_key:"refElImage",ref:s,isLoop:d.isLoop,list:d.list,isShowCopy:d.isShowCopy},null,8,["isLoop","list","isShowCopy"])):m.value?(e.openBlock(),e.createBlock(e.unref(i),{key:3,ref_key:"refElVideo",ref:l,isLoop:d.isLoop,list:d.list},null,8,["isLoop","list"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:4},[],64))],10,hv))}}),Is=(n={})=>{const a=e.createApp(gv,n),i=document.createElement("div"),t=a.mount(i);return{image:(s,l={})=>{const d=o.getJsonMerge(l,{type:"image",src:s});t.show(d)},video:(s,l={})=>{const d=o.getJsonMerge(l,{type:"video",src:s});t.show(d)},show:s=>{t.show(s)},destroy:()=>{t.destroy(),a.unmount(),i.parentNode&&i.parentNode.removeChild(i)}}},yv=Object.freeze(Object.defineProperty({__proto__:null,default:Is},Symbol.toStringTag,{value:"Module"}));let Mn=null;const vv=()=>(Mn||(Mn=Promise.resolve().then(()=>require("./index.hljs-BX3KMdv8.cjs")).catch(n=>{throw Mn=null,n})),Mn),kv={bind:(n,a)=>{vv().then(i=>{n.isConnected&&i.highlight(n,a.value)}).catch(()=>{})}},Sv="clCodeHighlight",wv=()=>({deep:!0,beforeMount:kv.bind}),Ts=Object.freeze(Object.defineProperty({__proto__:null,directive:wv,name:Sv},Symbol.toStringTag,{value:"Module"})),Ev="cllazy",bv=n=>{const a=new Pi(n);return{deep:!0,mounted:a.mount.bind(a),updated:a.update.bind(a),unmounted:a.unmount.bind(a)}},Cv=Object.freeze(Object.defineProperty({__proto__:null,directive:bv,name:Ev},Symbol.toStringTag,{value:"Module"}));let On=null;const xv=(n={})=>{if(On)return On;const a=e.createApp(ta,n),i=document.createElement("div"),t=a.mount(i);return On={show:(s,l)=>{t.show(s,l)},hide:(s=1e3)=>{t.hide(s)}},On};function Bv(n){return a=>{n.forEach(i=>{a.component(i.name,i)})}}function Ns(n,a){return(i,t={})=>{Object.keys(n).forEach(l=>{i.directive(n[l].name,n[l].directive(t[l]||{}))});const s={};Object.keys(a).forEach(l=>{s[l]=a[l](t[l]||{})}),o.isObject(t.globalsOption)&&rl(t.globalsOption),i.provide("$ClGlobals",s)}}const Vs={lazyImage:Cv},_s={clipboard:qo,loadScreen:xv,languagePack:Gi,validate:Fi},Dv=[Lt,Pe,ve,lt,zi,Ji,Zt,ta,ji,ia,Qe,ui,jo,hi,yi,fi,Vt,na,vn,oa,aa,Yo,dt,Gt,Wi,vi,_i,Mi,Zo,Oi,ea,jn,Li,$i,Gn,Yn,Hi,_t,hn,Ui,Qt,Qn,Yi,Zn,qi,Xi,yn],Ms={...Vs,codeHighlight:Ts,waves:pi,tooltip:gi};function Iv(n){let a=null,i=null;const t=()=>a?Promise.resolve(a):(i||(i=Promise.resolve().then(()=>yv).then(s=>(a=s.default(n),a))),i);return{show:s=>t().then(l=>l.show(s)),image:s=>t().then(l=>l.image(s)),video:s=>t().then(l=>l.video(s)),destroy:()=>t().then(s=>s.destroy())}}const Os={..._s,notify:Bs,alert:Ds,preview:Iv},Tv=Ns(Ms,Os),Nv=[Qi,Zi,es,os,sa,ls,ca,rs,cs,us,ua,ds,la,ms,da,ps,ra,ma,gn,En,pa,fs,fa,gs,vs,Ss,ws,Es,bs,ha,Cs,xs],Vv=[...Dv,...Nv],_v={...Vs,...Ms},Mv={..._s,...Os},Ov=(n,a={})=>{Bv(Vv)(n),Ns(_v,Mv)(n,a)};exports.Alert=Ds;exports.Clipboard=qo;exports.CodeHighlight=Ts;exports.CommonBase=o;exports.Notify=Bs;exports.Tooltip=gi;exports.Waves=pi;exports._sfc_main=Qi;exports._sfc_main$1=Gt;exports._sfc_main$10=yn;exports._sfc_main$11=es;exports._sfc_main$12=yi;exports._sfc_main$13=os;exports._sfc_main$14=vi;exports._sfc_main$15=sa;exports._sfc_main$16=ls;exports._sfc_main$17=_i;exports._sfc_main$18=ca;exports._sfc_main$19=Mi;exports._sfc_main$2=ui;exports._sfc_main$20=rs;exports._sfc_main$21=cs;exports._sfc_main$22=us;exports._sfc_main$23=ua;exports._sfc_main$24=ds;exports._sfc_main$25=Zo;exports._sfc_main$26=Oi;exports._sfc_main$27=la;exports._sfc_main$28=ea;exports._sfc_main$29=Li;exports._sfc_main$3=Qe;exports._sfc_main$30=jn;exports._sfc_main$31=$i;exports._sfc_main$32=Gn;exports._sfc_main$33=ms;exports._sfc_main$34=ve;exports._sfc_main$35=Yn;exports._sfc_main$36=Pe;exports._sfc_main$37=Hi;exports._sfc_main$38=_t;exports._sfc_main$39=hn;exports._sfc_main$4=Zi;exports._sfc_main$40=Ui;exports._sfc_main$41=Qt;exports._sfc_main$42=da;exports._sfc_main$43=Qn;exports._sfc_main$44=Vt;exports._sfc_main$45=lt;exports._sfc_main$46=zi;exports._sfc_main$47=Zt;exports._sfc_main$48=ta;exports._sfc_main$49=Ji;exports._sfc_main$5=fi;exports._sfc_main$50=na;exports._sfc_main$51=Wi;exports._sfc_main$52=Lt;exports._sfc_main$53=ma;exports._sfc_main$54=ps;exports._sfc_main$55=ra;exports._sfc_main$56=ji;exports._sfc_main$57=oa;exports._sfc_main$58=aa;exports._sfc_main$59=gn;exports._sfc_main$6=jo;exports._sfc_main$60=En;exports._sfc_main$61=pa;exports._sfc_main$62=fs;exports._sfc_main$63=fa;exports._sfc_main$64=gs;exports._sfc_main$65=vs;exports._sfc_main$66=ia;exports._sfc_main$67=Yi;exports._sfc_main$68=Ss;exports._sfc_main$69=ws;exports._sfc_main$7=hi;exports._sfc_main$70=Es;exports._sfc_main$71=bs;exports._sfc_main$72=Zn;exports._sfc_main$73=vn;exports._sfc_main$74=ha;exports._sfc_main$75=qi;exports._sfc_main$76=Xi;exports._sfc_main$77=Cs;exports._sfc_main$78=xs;exports._sfc_main$8=Yo;exports._sfc_main$9=dt;exports.index=Is;exports.installCore=Tv;exports.installs=Ov;exports.languagePack=Gi;