@cldemo/ui-kit 1.1.3 → 1.1.5

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 (321) hide show
  1. package/buildLibs/all/index.cjs +8 -8
  2. package/buildLibs/all/index.css +1 -1
  3. package/buildLibs/all/index.js +12158 -12048
  4. package/buildLibs/common/globalConfig.cjs +1 -1
  5. package/buildLibs/common/globalConfig.js +29 -15
  6. package/buildLibs/common/i18n/en.cjs +1 -1
  7. package/buildLibs/common/i18n/en.js +3 -1
  8. package/buildLibs/common/i18n/zh_CN.cjs +1 -1
  9. package/buildLibs/common/i18n/zh_CN.js +3 -1
  10. package/buildLibs/common/index.cjs +1 -1
  11. package/buildLibs/common/index.js +26 -24
  12. package/buildLibs/mobile/index.cjs +5 -5
  13. package/buildLibs/mobile/index.css +1 -1
  14. package/buildLibs/mobile/index.js +5903 -5852
  15. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-4TeN_Yn-.js +310 -0
  16. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-DKMVQrVU.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-B-T2hoSW.js} +66 -60
  17. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-BOcOO9-n.js → Index.vue_vue_type_script_setup_true_lang-BBjneEVa.js} +386 -375
  18. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-gwA_FyLx.js → Index.vue_vue_type_script_setup_true_lang-BIH4-mgs.js} +1 -1
  19. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-CgdGs-U2.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-BVGrVxFC.js} +68 -60
  20. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-B2Ste7lk.js → Index.vue_vue_type_script_setup_true_lang-Bi8DPjJz.js} +1 -1
  21. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-RRUPY9bd.js → Index.vue_vue_type_script_setup_true_lang-CMfPrFu4.js} +154 -146
  22. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-CKoVf-v1.js → Index.vue_vue_type_script_setup_true_lang-D4je4ahg.js} +3 -3
  23. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-XiSSYx4X.js → Index.vue_vue_type_script_setup_true_lang-D7YeNBdk.js} +120 -113
  24. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-DC1L_0IK.js +2536 -0
  25. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-CRKrLCa6.js → Index.vue_vue_type_script_setup_true_lang-DFeBj9IN.js} +209 -201
  26. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-D0g1xGPL.js → Index.vue_vue_type_script_setup_true_lang-DM74NqhN.js} +8 -8
  27. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-DPcqZPoO.js +1533 -0
  28. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-Bj1vSCM8.js → Index.vue_vue_type_script_setup_true_lang-DPxMsZuy.js} +2 -2
  29. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-C0DgaU5I.js → Index.vue_vue_type_script_setup_true_lang-D_eRjg8p.js} +54 -48
  30. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-G8UXhRvM.js → Index.vue_vue_type_script_setup_true_lang-Df0iiX1E.js} +1 -1
  31. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-DqZBB8fM.js → Index.vue_vue_type_script_setup_true_lang-DjcrAnYd.js} +2 -2
  32. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-Cyi6TkkK.js → Index.vue_vue_type_script_setup_true_lang-UqloO5cR.js} +1 -1
  33. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-6Rsz2dYw.js → Index.vue_vue_type_script_setup_true_lang-ljMopEep.js} +1 -1
  34. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-CIA-Kc0M.js → Index.vue_vue_type_script_setup_true_lang-vizZ7Mti.js} +6 -5
  35. package/buildLibs/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-Cg_benGj.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-wS3dtCDx.js} +63 -55
  36. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-x7Q4MNNE.js +254 -0
  37. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-BbD4hLPT.js → Index.vue_vue_type_script_setup_true_lang-xpySjof2.js} +2 -2
  38. package/buildLibs/modules/shared/{List.vue_vue_type_script_setup_true_lang-Chy0eAps.js → List.vue_vue_type_script_setup_true_lang-F-n2xPeF.js} +1 -1
  39. package/buildLibs/modules/shared/{One.vue_vue_type_script_setup_true_lang-BR8b8AgK.js → One.vue_vue_type_script_setup_true_lang-BPQ-99F1.js} +1 -1
  40. package/buildLibs/modules/shared/{One.vue_vue_type_script_setup_true_lang-bPEj13DH.js → One.vue_vue_type_script_setup_true_lang-CnkGjequ.js} +1 -1
  41. package/buildLibs/modules/shared/{Validate.vue_vue_type_script_setup_true_lang-3s_3ut9M.js → Validate.vue_vue_type_script_setup_true_lang-D-BFbuqJ.js} +103 -93
  42. package/buildLibs/modules/ui-kit.css +1 -1
  43. package/buildLibs/styles/Common/IconFont-base.css +3 -3
  44. package/buildLibs/styles/Common/Input-base.css +10 -0
  45. package/buildLibs/styles/Element/ClInputTextarea.css +2 -2
  46. package/buildLibs/styles/Web/ClDatetime.css +2 -1
  47. package/buildLibs/styles/Web/ClInputTag.css +4 -3
  48. package/buildLibs/styles/Web/ClPaginate.css +2 -1
  49. package/buildLibs/styles/Web/ClSelect.css +2 -1
  50. package/buildLibs/styles/Web/ClSelectCascade.css +2 -1
  51. package/buildLibs/styles/Web/ClSelectTree.css +2 -1
  52. package/buildLibs/styles/Web/ClSelectmove.css +2 -1
  53. package/buildLibs/styles/Web/ClTable.css +2 -1
  54. package/buildLibs/styles/Web/ClXeditable.css +4 -3
  55. package/buildLibs/types/All/index.d.ts +1 -1
  56. package/buildLibs/types/Common/globalConfig.d.ts +29 -0
  57. package/buildLibs/types/Common/globalTypes.d.ts +11 -0
  58. package/buildLibs/types/Common/i18n/en.d.ts +2 -0
  59. package/buildLibs/types/Common/i18n/zh_CN.d.ts +2 -0
  60. package/buildLibs/types/Common/index.d.ts +1 -1
  61. package/buildLibs/types/Element/CheckBox/Index.vue.d.ts +9 -0
  62. package/buildLibs/types/Element/Input/Index.vue.d.ts +9 -0
  63. package/buildLibs/types/Element/InputNumber/Index.vue.d.ts +9 -0
  64. package/buildLibs/types/Element/InputNumberStepper/Index.vue.d.ts +9 -0
  65. package/buildLibs/types/Element/InputTextarea/Index.vue.d.ts +9 -0
  66. package/buildLibs/types/Element/Radio/Index.vue.d.ts +9 -0
  67. package/buildLibs/types/Web/DateTime/Index.vue.d.ts +9 -0
  68. package/buildLibs/types/Web/FileUpload/Index.vue.d.ts +9 -0
  69. package/buildLibs/types/Web/Select/Index.vue.d.ts +9 -0
  70. package/buildLibs/types/Web/SelectCascade/Index.vue.d.ts +9 -0
  71. package/buildLibs/types/Web/SelectMove/Index.vue.d.ts +9 -0
  72. package/buildLibs/types/Web/SelectTag/Index.vue.d.ts +9 -0
  73. package/buildLibs/types/Web/SelectTree/Index.vue.d.ts +9 -0
  74. package/buildLibs/types/Web/Tree/Index.vue.d.ts +9 -0
  75. package/buildLibs/types/Web/componentsInstalls.d.ts +90 -0
  76. package/buildLibs/utils/Element/ClButton.cjs +1 -1
  77. package/buildLibs/utils/Element/ClButton.js +1 -1
  78. package/buildLibs/utils/Element/ClCheckbox.cjs +1 -1
  79. package/buildLibs/utils/Element/ClCheckbox.js +1 -1
  80. package/buildLibs/utils/Element/ClCheckboxOne.cjs +1 -1
  81. package/buildLibs/utils/Element/ClCheckboxOne.js +1 -1
  82. package/buildLibs/utils/Element/ClClipboard.cjs +1 -1
  83. package/buildLibs/utils/Element/ClClipboard.js +1 -1
  84. package/buildLibs/utils/Element/ClCollapse.cjs +1 -1
  85. package/buildLibs/utils/Element/ClCollapse.js +1 -1
  86. package/buildLibs/utils/Element/ClFormValidate.cjs +1 -1
  87. package/buildLibs/utils/Element/ClFormValidate.js +1 -1
  88. package/buildLibs/utils/Element/ClIconFont.cjs +1 -1
  89. package/buildLibs/utils/Element/ClIconFont.js +1 -1
  90. package/buildLibs/utils/Element/ClInput.cjs +1 -1
  91. package/buildLibs/utils/Element/ClInput.js +1 -1
  92. package/buildLibs/utils/Element/ClInputCaptcha.cjs +1 -1
  93. package/buildLibs/utils/Element/ClInputCaptcha.js +1 -1
  94. package/buildLibs/utils/Element/ClInputNumber.cjs +1 -1
  95. package/buildLibs/utils/Element/ClInputNumber.js +1 -1
  96. package/buildLibs/utils/Element/ClInputNumberStepper.cjs +1 -1
  97. package/buildLibs/utils/Element/ClInputNumberStepper.js +1 -1
  98. package/buildLibs/utils/Element/ClInputPassword.cjs +1 -1
  99. package/buildLibs/utils/Element/ClInputPassword.js +2 -2
  100. package/buildLibs/utils/Element/ClInputSearch.cjs +1 -1
  101. package/buildLibs/utils/Element/ClInputSearch.js +1 -1
  102. package/buildLibs/utils/Element/ClInputTextarea.cjs +1 -1
  103. package/buildLibs/utils/Element/ClInputTextarea.js +1 -1
  104. package/buildLibs/utils/Element/ClModal.cjs +1 -1
  105. package/buildLibs/utils/Element/ClModal.js +1 -1
  106. package/buildLibs/utils/Element/ClRadio.cjs +1 -1
  107. package/buildLibs/utils/Element/ClRadio.js +1 -1
  108. package/buildLibs/utils/Element/ClRadioOne.cjs +1 -1
  109. package/buildLibs/utils/Element/ClRadioOne.js +1 -1
  110. package/buildLibs/utils/Element/ClTags.cjs +1 -1
  111. package/buildLibs/utils/Element/ClTags.js +1 -1
  112. package/buildLibs/utils/Element/__provide__/Validate.cjs +1 -1
  113. package/buildLibs/utils/Element/__provide__/Validate.js +13 -3
  114. package/buildLibs/utils/Mobile/ClActionSheet.cjs +1 -1
  115. package/buildLibs/utils/Mobile/ClActionSheet.js +1 -1
  116. package/buildLibs/utils/Mobile/ClBackTop.cjs +1 -1
  117. package/buildLibs/utils/Mobile/ClBackTop.js +1 -1
  118. package/buildLibs/utils/Mobile/ClBanner.cjs +1 -1
  119. package/buildLibs/utils/Mobile/ClBanner.js +1 -1
  120. package/buildLibs/utils/Mobile/ClCalendarM.cjs +1 -1
  121. package/buildLibs/utils/Mobile/ClCalendarM.js +1 -1
  122. package/buildLibs/utils/Mobile/ClCell.cjs +1 -1
  123. package/buildLibs/utils/Mobile/ClCell.js +1 -1
  124. package/buildLibs/utils/Mobile/ClCodeLegendM.cjs +1 -1
  125. package/buildLibs/utils/Mobile/ClCodeLegendM.js +2 -2
  126. package/buildLibs/utils/Mobile/ClCropperM.cjs +1 -1
  127. package/buildLibs/utils/Mobile/ClCropperM.js +1 -1
  128. package/buildLibs/utils/Mobile/ClDropdownMenuMItem.cjs +1 -1
  129. package/buildLibs/utils/Mobile/ClDropdownMenuMItem.js +1 -1
  130. package/buildLibs/utils/Mobile/ClGrid.cjs +1 -1
  131. package/buildLibs/utils/Mobile/ClGrid.js +1 -1
  132. package/buildLibs/utils/Mobile/ClNavBar.cjs +1 -1
  133. package/buildLibs/utils/Mobile/ClNavBar.js +1 -1
  134. package/buildLibs/utils/Mobile/ClNoticeBar.cjs +1 -1
  135. package/buildLibs/utils/Mobile/ClNoticeBar.js +1 -1
  136. package/buildLibs/utils/Mobile/ClNotifyM.cjs +1 -1
  137. package/buildLibs/utils/Mobile/ClNotifyM.js +1 -1
  138. package/buildLibs/utils/Mobile/ClNumberKeyboard.cjs +1 -1
  139. package/buildLibs/utils/Mobile/ClNumberKeyboard.js +1 -1
  140. package/buildLibs/utils/Mobile/ClPickerCascader.cjs +1 -1
  141. package/buildLibs/utils/Mobile/ClPickerCascader.js +1 -1
  142. package/buildLibs/utils/Mobile/ClPullToRefresh.cjs +1 -1
  143. package/buildLibs/utils/Mobile/ClPullToRefresh.js +1 -1
  144. package/buildLibs/utils/Mobile/ClRate.cjs +1 -1
  145. package/buildLibs/utils/Mobile/ClRate.js +1 -1
  146. package/buildLibs/utils/Mobile/ClScrollCard.cjs +1 -1
  147. package/buildLibs/utils/Mobile/ClScrollCard.js +1 -1
  148. package/buildLibs/utils/Mobile/ClSharePanel.cjs +1 -1
  149. package/buildLibs/utils/Mobile/ClSharePanel.js +1 -1
  150. package/buildLibs/utils/Mobile/ClSidebarSelect.cjs +1 -1
  151. package/buildLibs/utils/Mobile/ClSidebarSelect.js +1 -1
  152. package/buildLibs/utils/Mobile/ClSteps.cjs +1 -1
  153. package/buildLibs/utils/Mobile/ClSteps.js +1 -1
  154. package/buildLibs/utils/Mobile/ClTabbar.cjs +1 -1
  155. package/buildLibs/utils/Mobile/ClTabbar.js +1 -1
  156. package/buildLibs/utils/Mobile/ClToast.cjs +1 -1
  157. package/buildLibs/utils/Mobile/ClToast.js +1 -1
  158. package/buildLibs/utils/Mobile/__provide__/NotifyM.cjs +1 -1
  159. package/buildLibs/utils/Mobile/__provide__/NotifyM.js +1 -1
  160. package/buildLibs/utils/Mobile/__provide__/Toast.cjs +1 -1
  161. package/buildLibs/utils/Mobile/__provide__/Toast.js +1 -1
  162. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-C1OgPpoJ.js → Index.vue_vue_type_script_setup_true_lang-0S6ab-Lp.js} +120 -113
  163. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-neC9NxKi.js → Index.vue_vue_type_script_setup_true_lang-2Fe9SkjL.js} +209 -201
  164. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Dzm58mMQ.js → Index.vue_vue_type_script_setup_true_lang-2zp0QTNm.js} +1 -1
  165. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-4I3wTvhS.js +2536 -0
  166. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-5WPoXMwr.js +1 -0
  167. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-5itnjwU_.js +1 -0
  168. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BIFHYrzc.js → Index.vue_vue_type_script_setup_true_lang-98sOHlWj.js} +1 -1
  169. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-B60Rs_ka.js +1 -0
  170. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-B-Mbqw1Y.js → Index.vue_vue_type_script_setup_true_lang-B6NmuslZ.js} +1 -1
  171. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-D7bJ5UAn.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-B8YAhRda.js} +63 -55
  172. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BGwsPv0S.js +1 -0
  173. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Eczgr-_r.js → Index.vue_vue_type_script_setup_true_lang-BJ_m7Dj5.js} +1 -1
  174. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BM_FJlr9.js +2 -0
  175. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BN9ybiKv.js +1 -0
  176. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-D_YbdXMB.js → Index.vue_vue_type_script_setup_true_lang-BUscvdlk.js} +1 -1
  177. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-UydTJByU.js → Index.vue_vue_type_script_setup_true_lang-BXz7Y87Q.js} +1 -1
  178. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-X8d38eaU.js → Index.vue_vue_type_script_setup_true_lang-BfELTliJ.js} +1 -1
  179. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-C2LGy18j.js → Index.vue_vue_type_script_setup_true_lang-Bt0l5FYh.js} +6 -5
  180. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BQSP8SA4.js → Index.vue_vue_type_script_setup_true_lang-BwwnFiXJ.js} +1 -1
  181. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-C2zOEwJ1.js +1 -0
  182. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-D6kK-vM7.js → Index.vue_vue_type_script_setup_true_lang-C6Ou-vmn.js} +1 -1
  183. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BWeBT0aj.js → Index.vue_vue_type_script_setup_true_lang-C8euOy7Z.js} +2 -2
  184. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-C6Evk0-z.js → Index.vue_vue_type_script_setup_true_lang-CAMYF15G.js} +54 -48
  185. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CSqU5Nz6.js +1 -0
  186. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-ChnRq_PS.js → Index.vue_vue_type_script_setup_true_lang-CWwycVzt.js} +3 -3
  187. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BO4cal3i.js → Index.vue_vue_type_script_setup_true_lang-Cb8fYSc9.js} +386 -375
  188. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Dwkuei2j.js → Index.vue_vue_type_script_setup_true_lang-D3Z2BVYR.js} +2 -2
  189. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-C67qv3YC.js → Index.vue_vue_type_script_setup_true_lang-DB79nPqn.js} +1 -1
  190. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DDMwfmi3.js +1533 -0
  191. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Dirpq4z0.js → Index.vue_vue_type_script_setup_true_lang-DPpZ2_Sb.js} +1 -1
  192. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DUfxwsAA.js +1 -0
  193. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CBjEJN0Y.js → Index.vue_vue_type_script_setup_true_lang-Dc4eYcq-.js} +1 -1
  194. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-O_Nltaue.js → Index.vue_vue_type_script_setup_true_lang-DfAoAIa3.js} +1 -1
  195. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CsUYHAm8.js → Index.vue_vue_type_script_setup_true_lang-Dg5pJiPZ.js} +1 -1
  196. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DxYJbPyJ.js → Index.vue_vue_type_script_setup_true_lang-DulzCj86.js} +8 -8
  197. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DWkYiuK9.js → Index.vue_vue_type_script_setup_true_lang-DvYX7kuB.js} +1 -1
  198. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-CAe8mhTl.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-LeQz80jL.js} +66 -60
  199. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-L4NDsLxm.js → Index.vue_vue_type_script_setup_true_lang-M5y0DMPl.js} +1 -1
  200. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-OfqQJV8-.js +1 -0
  201. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-OiTdNs2W.js +310 -0
  202. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-DdLVG0R0.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-S9t4A2yy.js} +68 -60
  203. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-SW27GX-g.js +254 -0
  204. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-D_XMW7K4.js → Index.vue_vue_type_script_setup_true_lang-VUD3rCg5.js} +154 -146
  205. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-ZNpokp-x.js +1 -0
  206. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CYFgnd30.js → Index.vue_vue_type_script_setup_true_lang-kCemr-ml.js} +1 -1
  207. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-D__hI9ud.js → Index.vue_vue_type_script_setup_true_lang-sGJNOVn3.js} +1 -1
  208. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CizRrQsH.js → Index.vue_vue_type_script_setup_true_lang-vVnnJuup.js} +1 -1
  209. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-xONe0mSK.js +1 -0
  210. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-ctptavhp.js → Index.vue_vue_type_script_setup_true_lang-yXhOl-Ln.js} +2 -2
  211. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-ywDP-ayG.js +1 -0
  212. package/buildLibs/utils/Shared/Index22.css +1 -1
  213. package/buildLibs/utils/Shared/Index8.css +1 -1
  214. package/buildLibs/utils/Shared/Input.css +1 -1
  215. package/buildLibs/utils/Shared/List.css +1 -1
  216. package/buildLibs/utils/Shared/{List.vue_vue_type_script_setup_true_lang-CFCST05R.js → List.vue_vue_type_script_setup_true_lang-B75tAGde.js} +1 -1
  217. package/buildLibs/utils/Shared/{List.vue_vue_type_script_setup_true_lang-CRkZfB8a.js → List.vue_vue_type_script_setup_true_lang-NrDV8bOV.js} +1 -1
  218. package/buildLibs/utils/Shared/{One.vue_vue_type_script_setup_true_lang-cviYcHLZ.js → One.vue_vue_type_script_setup_true_lang-BL5CUHVm.js} +1 -1
  219. package/buildLibs/utils/Shared/{One.vue_vue_type_script_setup_true_lang-HWXEDCZF.js → One.vue_vue_type_script_setup_true_lang-D3hrzxgT.js} +1 -1
  220. package/buildLibs/utils/Shared/{One.vue_vue_type_script_setup_true_lang-CGNfuoKE.js → One.vue_vue_type_script_setup_true_lang-DHPYObdu.js} +1 -1
  221. package/buildLibs/utils/Shared/{One.vue_vue_type_script_setup_true_lang-D9zWNf0s.js → One.vue_vue_type_script_setup_true_lang-DxUlP9yq.js} +1 -1
  222. package/buildLibs/utils/Shared/{Validate.vue_vue_type_script_setup_true_lang-W46p_d7L.js → Validate.vue_vue_type_script_setup_true_lang-BYSnGTWU.js} +1 -1
  223. package/buildLibs/utils/Shared/{Validate.vue_vue_type_script_setup_true_lang-Jyse_5LL.js → Validate.vue_vue_type_script_setup_true_lang-DPwcfCQb.js} +1 -1
  224. package/buildLibs/utils/Shared/{index-DgQu20UC.js → index-BjDIq1u8.js} +1 -1
  225. package/buildLibs/utils/Shared/{index-D-7jSnpf.js → index-CBplKIwJ.js} +2 -2
  226. package/buildLibs/utils/Web/ClAnchorNav.cjs +1 -1
  227. package/buildLibs/utils/Web/ClAnchorNav.js +1 -1
  228. package/buildLibs/utils/Web/ClCalendar.cjs +1 -1
  229. package/buildLibs/utils/Web/ClCalendar.js +1 -1
  230. package/buildLibs/utils/Web/ClCodeLegend.cjs +1 -1
  231. package/buildLibs/utils/Web/ClCodeLegend.js +1 -1
  232. package/buildLibs/utils/Web/ClColorPicker.cjs +1 -1
  233. package/buildLibs/utils/Web/ClColorPicker.js +3 -3
  234. package/buildLibs/utils/Web/ClCropper.cjs +1 -1
  235. package/buildLibs/utils/Web/ClCropper.js +1 -1
  236. package/buildLibs/utils/Web/ClCropperPreview.cjs +1 -1
  237. package/buildLibs/utils/Web/ClCropperPreview.js +4 -4
  238. package/buildLibs/utils/Web/ClDateTime.cjs +1 -1
  239. package/buildLibs/utils/Web/ClDateTime.js +1 -1
  240. package/buildLibs/utils/Web/ClDropdownMenu.cjs +1 -1
  241. package/buildLibs/utils/Web/ClDropdownMenu.js +1 -1
  242. package/buildLibs/utils/Web/ClEchartsLineAxisTag.cjs +1 -1
  243. package/buildLibs/utils/Web/ClEchartsLineAxisTag.js +1 -1
  244. package/buildLibs/utils/Web/ClFileUpload.cjs +1 -1
  245. package/buildLibs/utils/Web/ClFileUpload.js +1 -1
  246. package/buildLibs/utils/Web/ClInputTag.cjs +1 -1
  247. package/buildLibs/utils/Web/ClInputTag.js +1 -1
  248. package/buildLibs/utils/Web/ClPaginate.cjs +1 -1
  249. package/buildLibs/utils/Web/ClPaginate.js +1 -1
  250. package/buildLibs/utils/Web/ClPreviewExample.cjs +1 -1
  251. package/buildLibs/utils/Web/ClPreviewExample.js +1 -1
  252. package/buildLibs/utils/Web/ClSelect.cjs +1 -1
  253. package/buildLibs/utils/Web/ClSelect.js +1 -1
  254. package/buildLibs/utils/Web/ClSelectCascade.cjs +1 -1
  255. package/buildLibs/utils/Web/ClSelectCascade.js +1 -1
  256. package/buildLibs/utils/Web/ClSelectMove.cjs +1 -1
  257. package/buildLibs/utils/Web/ClSelectMove.js +655 -647
  258. package/buildLibs/utils/Web/ClSelectTag.cjs +1 -1
  259. package/buildLibs/utils/Web/ClSelectTag.js +1 -1
  260. package/buildLibs/utils/Web/ClSelectTree.cjs +1 -1
  261. package/buildLibs/utils/Web/ClSelectTree.js +71 -63
  262. package/buildLibs/utils/Web/ClSideMenu.cjs +1 -1
  263. package/buildLibs/utils/Web/ClSideMenu.js +1 -1
  264. package/buildLibs/utils/Web/ClTable.cjs +1 -1
  265. package/buildLibs/utils/Web/ClTable.js +4 -4
  266. package/buildLibs/utils/Web/ClTabs.cjs +1 -1
  267. package/buildLibs/utils/Web/ClTabs.js +1 -1
  268. package/buildLibs/utils/Web/ClTree.cjs +1 -1
  269. package/buildLibs/utils/Web/ClTree.js +1 -1
  270. package/buildLibs/utils/Web/ClXEditable.cjs +1 -1
  271. package/buildLibs/utils/Web/ClXEditable.js +13 -13
  272. package/buildLibs/utils/Web/__provide__/Alert.cjs +1 -1
  273. package/buildLibs/utils/Web/__provide__/Alert.js +2 -2
  274. package/buildLibs/utils/Web/__provide__/Notify.cjs +1 -1
  275. package/buildLibs/utils/Web/__provide__/Notify.js +1 -1
  276. package/buildLibs/utils/Web/__provide__/Preview.cjs +1 -1
  277. package/buildLibs/utils/Web/__provide__/Preview.js +1 -1
  278. package/buildLibs/web/index.cjs +7 -7
  279. package/buildLibs/web/index.css +1 -1
  280. package/buildLibs/web/index.js +10793 -10685
  281. package/docs/components/Element/Checkbox.md +2 -1
  282. package/docs/components/Element/Form.md +15 -0
  283. package/docs/components/Element/Input.md +2 -1
  284. package/docs/components/Element/InputNumber.md +2 -1
  285. package/docs/components/Element/InputNumberStepper.md +2 -1
  286. package/docs/components/Element/InputTextarea.md +2 -1
  287. package/docs/components/Element/Radio.md +2 -1
  288. package/docs/components/Web/DateTime.md +2 -1
  289. package/docs/components/Web/FileUpload.md +2 -1
  290. package/docs/components/Web/Select.md +2 -1
  291. package/docs/components/Web/SelectCascade.md +1 -0
  292. package/docs/components/Web/SelectMove.md +2 -1
  293. package/docs/components/Web/SelectTag.md +1 -0
  294. package/docs/components/Web/SelectTree.md +2 -1
  295. package/docs/components/Web/Tree.md +2 -1
  296. package/fonts/iconfont.css +7 -3
  297. package/fonts/iconfont.ttf +0 -0
  298. package/fonts/iconfont.woff +0 -0
  299. package/fonts/iconfont.woff2 +0 -0
  300. package/package.json +1 -1
  301. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-CiNidFJt.js +0 -246
  302. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-DC6727pS.js +0 -2528
  303. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-EXqjkKwS.js +0 -302
  304. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-Hg16dgRQ.js +0 -1527
  305. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-5aX79Fcf.js +0 -1
  306. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BRvOcf4B.js +0 -1
  307. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Ba8Z8fOP.js +0 -1
  308. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BjNP5odR.js +0 -1
  309. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CFZ5jK-q.js +0 -1
  310. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CQ3RGLek.js +0 -302
  311. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CY5fRV6o.js +0 -1
  312. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CYN4r-Mx.js +0 -1
  313. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-C_7ArHlU.js +0 -1
  314. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CuJjJvft.js +0 -2
  315. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CwjigRBx.js +0 -2528
  316. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-D6cmq0Tf.js +0 -1527
  317. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Dbf-3Nik.js +0 -1
  318. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DgD_gHit.js +0 -1
  319. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-FowII7_3.js +0 -1
  320. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-c7oxeU_j.js +0 -246
  321. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-vLqCsSbV.js +0 -1
@@ -1,13 +1,14 @@
1
- import { defineComponent as Y, useTemplateRef as Z, computed as d, openBlock as s, createElementBlock as r, normalizeClass as O, unref as _, createElementVNode as P, mergeProps as ie, toDisplayString as ee, createCommentVNode as re, createBlock as ne, withKeys as Q, withModifiers as R, Fragment as k, renderSlot as I, ref as B, onMounted as ce, onBeforeUnmount as de, watch as pe, normalizeStyle as fe, createVNode as me, createSlots as W, withCtx as V, nextTick as ye } from "vue";
1
+ import { defineComponent as Y, useTemplateRef as Z, computed as p, openBlock as i, createElementBlock as r, normalizeClass as O, unref as _, createElementVNode as P, mergeProps as re, toDisplayString as ee, createCommentVNode as ce, createBlock as te, withKeys as Q, withModifiers as R, Fragment as k, renderSlot as I, ref as w, onMounted as pe, onBeforeUnmount as de, watch as fe, normalizeStyle as me, createVNode as ye, createSlots as W, withCtx as B, nextTick as ve } from "vue";
2
2
  /* empty css */
3
3
  /* empty css */
4
4
  import u from "@cldemo/ui-kit/common/base";
5
5
  import ge from "@cldemo/ui-kit/common/Element";
6
- import { _ as X } from "./Index.vue_vue_type_script_setup_true_lang-C2LGy18j.js";
7
- const ve = ["id"], he = ["type", "inputmode", "name", "value", "placeholder", "disabled", "readonly"], Ce = {
6
+ import { getPlaintextOutText as he } from "@cldemo/ui-kit/common/globalConfig";
7
+ import { _ as X } from "./Index.vue_vue_type_script_setup_true_lang-Bt0l5FYh.js";
8
+ const Ce = ["id"], Se = ["type", "inputmode", "name", "value", "placeholder", "disabled", "readonly"], xe = {
8
9
  key: 0,
9
10
  class: "input-floating-label"
10
- }, Se = {
11
+ }, be = {
11
12
  key: 3,
12
13
  class: "input-suffix"
13
14
  }, N = /* @__PURE__ */ Y({
@@ -69,90 +70,90 @@ const ve = ["id"], he = ["type", "inputmode", "name", "value", "placeholder", "d
69
70
  }
70
71
  },
71
72
  emits: ["onInputText", "onKeydown", "onKeyup", "onFocus", "onBlur", "onClear"],
72
- setup(t, { expose: E, emit: F }) {
73
- const n = t, o = F, T = n.id, p = Z("refElInput"), C = d(() => {
74
- let l = n.name;
73
+ setup(n, { expose: E, emit: T }) {
74
+ const t = n, o = T, V = t.id, d = Z("refElInput"), x = p(() => {
75
+ let l = t.name;
75
76
  return u.isEmpty(l) && (l = `input_${u.getRandom(8)}`), l;
76
- }), v = d(() => u.isEmpty(n.inputmode) ? void 0 : n.inputmode), a = d(() => {
77
+ }), g = p(() => u.isEmpty(t.inputmode) ? void 0 : t.inputmode), a = p(() => {
77
78
  const l = {};
78
- return u.isNonEmptyString(n.autocomplete) && (l.autocomplete = n.autocomplete), l;
79
- }), f = d(() => n.isClean && !n.disabled && !n.isReadonly), S = d(() => f.value && !u.isEmpty(n.value)), c = d(() => n.isFloating ? n.label || n.placeholder : ""), y = d(() => ({
79
+ return u.isNonEmptyString(t.autocomplete) && (l.autocomplete = t.autocomplete), l;
80
+ }), F = p(() => t.isClean && !t.disabled && !t.isReadonly), f = p(() => F.value && !u.isEmpty(t.value)), h = p(() => t.isFloating ? t.label || t.placeholder : ""), c = p(() => ({
80
81
  "input-container": !0,
81
82
  // input-clean 与 disabled 解耦:类只决定清除按钮占位 padding(恒定 24px),
82
83
  // disabled 时按钮显示由 optIsShowClean 单独控制 → 文字/数字位置不随禁用态跳动
83
- "input-clean": n.isClean,
84
- "input-suffix": n.isShowSuffix,
85
- "input-floating": n.isFloating
86
- })), K = (l) => {
87
- const x = l.target;
88
- x && o("onInputText", x.value);
89
- }, D = (l) => {
84
+ "input-clean": t.isClean,
85
+ "input-suffix": t.isShowSuffix,
86
+ "input-floating": t.isFloating
87
+ })), y = (l) => {
88
+ const b = l.target;
89
+ b && o("onInputText", b.value);
90
+ }, K = (l) => {
90
91
  o("onKeydown", l);
91
- }, $ = (l) => {
92
+ }, D = (l) => {
92
93
  o("onKeyup", l);
93
- }, h = () => {
94
+ }, $ = () => {
94
95
  o("onFocus");
95
- }, w = () => {
96
+ }, C = () => {
96
97
  o("onBlur");
97
- }, b = () => {
98
+ }, S = () => {
98
99
  o("onClear");
99
100
  };
100
101
  return E({
101
- getInputElement: () => p.value,
102
+ getInputElement: () => d.value,
102
103
  focus: () => {
103
- p.value?.focus();
104
+ d.value?.focus();
104
105
  }
105
- }), (l, x) => (s(), r("div", {
106
- id: _(T),
107
- class: O(y.value)
106
+ }), (l, b) => (i(), r("div", {
107
+ id: _(V),
108
+ class: O(c.value)
108
109
  }, [
109
- P("input", ie({
110
+ P("input", re({
110
111
  ref_key: "refElInput",
111
- ref: p,
112
- type: t.inputType,
113
- inputmode: v.value,
114
- name: C.value
112
+ ref: d,
113
+ type: n.inputType,
114
+ inputmode: g.value,
115
+ name: x.value
115
116
  }, a.value, {
116
117
  class: "form-control",
117
- value: t.value,
118
- placeholder: t.placeholder,
119
- disabled: t.disabled,
120
- readonly: t.isReadonly,
121
- onInput: K,
122
- onKeydown: D,
123
- onKeyup: $,
124
- onFocus: h,
125
- onBlur: w
126
- }), null, 16, he),
127
- c.value ? (s(), r("label", Ce, ee(c.value), 1)) : re("", !0),
128
- S.value ? (s(), ne(X, {
118
+ value: n.value,
119
+ placeholder: n.placeholder,
120
+ disabled: n.disabled,
121
+ readonly: n.isReadonly,
122
+ onInput: y,
123
+ onKeydown: K,
124
+ onKeyup: D,
125
+ onFocus: $,
126
+ onBlur: C
127
+ }), null, 16, Se),
128
+ h.value ? (i(), r("label", xe, ee(h.value), 1)) : ce("", !0),
129
+ f.value ? (i(), te(X, {
129
130
  key: 1,
130
131
  name: "close-circle-fill",
131
132
  class: "input-clear-icon",
132
133
  "aria-label": "清除输入内容",
133
134
  role: "button",
134
135
  tabindex: "-1",
135
- onClick: R(b, ["stop"]),
136
+ onClick: R(S, ["stop"]),
136
137
  onKeydown: [
137
- Q(R(b, ["stop"]), ["enter"]),
138
- Q(R(b, ["stop", "prevent"]), ["space"])
138
+ Q(R(S, ["stop"]), ["enter"]),
139
+ Q(R(S, ["stop", "prevent"]), ["space"])
139
140
  ]
140
- }, null, 8, ["onKeydown"])) : (s(), r(k, { key: 2 }, [], 64)),
141
- t.isShowSuffix ? (s(), r("div", Se, [
141
+ }, null, 8, ["onKeydown"])) : (i(), r(k, { key: 2 }, [], 64)),
142
+ n.isShowSuffix ? (i(), r("div", be, [
142
143
  I(l.$slots, "suffix")
143
- ])) : (s(), r(k, { key: 4 }, [], 64))
144
- ], 10, ve));
144
+ ])) : (i(), r(k, { key: 4 }, [], 64))
145
+ ], 10, Ce));
145
146
  }
146
- }), be = ["id"], xe = {
147
+ }), Ie = ["id"], ke = {
147
148
  key: 0,
148
149
  class: "cl-plaintext-value"
149
- }, Ie = {
150
+ }, we = {
150
151
  key: 0,
151
152
  class: "input-group-prepend"
152
- }, ke = { class: "input-group-text" }, we = {
153
+ }, Be = { class: "input-group-text" }, Ee = {
153
154
  key: 2,
154
155
  class: "input-group-append"
155
- }, Be = { class: "input-group-text" }, Oe = /* @__PURE__ */ Y({
156
+ }, Te = { class: "input-group-text" }, ze = /* @__PURE__ */ Y({
156
157
  name: "ClInput",
157
158
  components: {
158
159
  ClInputContainer: N
@@ -215,6 +216,11 @@ const ve = ["id"], he = ["type", "inputmode", "name", "value", "placeholder", "d
215
216
  default: !1
216
217
  // desc: 是否纯文本只读模式,只渲染文本不挂载输入控件(不渲染 prepend/append/suffix 插槽)
217
218
  },
219
+ plaintextEmptyText: {
220
+ type: String,
221
+ default: void 0
222
+ // desc: 纯文本只读模式下值为空时的显示文本(默认 "-",显式传空串则显示空白;未显式传时依次读取组件配置段与 plaintextGlobal 段)
223
+ },
218
224
  changeDelayTime: {
219
225
  type: Number,
220
226
  default: 200
@@ -222,131 +228,133 @@ const ve = ["id"], he = ["type", "inputmode", "name", "value", "placeholder", "d
222
228
  }
223
229
  },
224
230
  emits: ["update:value", "update:modelValue", "onChange", "onFocus", "onBlur", "onChangeBlur", "onKeyupEnter", "onClear", "onInit", "onKeydown", "onKeyup", "onChangeDelay"],
225
- setup(t, { expose: E, emit: F }) {
226
- const n = t, o = F, T = n.id, p = Z("refElContainer"), C = B(!1), v = u.isString(n.value) ? n.value : n.value !== void 0 && u.isNumber(n.value) && u.isFinite(n.value) ? n.value.toString() : "", a = B(v), f = B(v), S = B(v), c = {
227
- prevDelayValue: v,
231
+ setup(n, { expose: E, emit: T }) {
232
+ const t = n, o = T, V = t.id, d = Z("refElContainer"), x = w(!1), g = u.isString(t.value) ? t.value : t.value !== void 0 && u.isNumber(t.value) && u.isFinite(t.value) ? t.value.toString() : "", a = w(g), F = p(
233
+ () => he("input", t.plaintextEmptyText, a.value, t.value)
234
+ ), f = w(g), h = w(g), c = {
235
+ prevDelayValue: g,
228
236
  valueDelayRun: !1
229
237
  };
230
238
  let y = null;
231
- const K = d(() => {
239
+ const K = p(() => {
232
240
  let e = {
233
241
  "panel-input": !0,
234
- "input-disabled": n.disabled,
235
- "input-readonly": n.isReadonly
242
+ "input-disabled": t.disabled,
243
+ "input-readonly": t.isReadonly
236
244
  };
237
- return e = u.getJsonMerge(e, ge.getClassNameJson(n.className)), u.isEmpty(n.theme, "default") || (e[`input-${n.theme}`] = !0), e;
238
- }), D = d(() => {
245
+ return e = u.getJsonMerge(e, ge.getClassNameJson(t.className)), u.isEmpty(t.theme, "default") || (e[`input-${t.theme}`] = !0), e;
246
+ }), D = p(() => {
239
247
  const e = {};
240
- return u.isNonEmptyString(n.width) && (e.width = n.width), e;
248
+ return u.isNonEmptyString(t.width) && (e.width = t.width), e;
241
249
  }), $ = (e) => {
242
- h(), c.valueDelayRun = !0, y = setTimeout(() => {
250
+ C(), c.valueDelayRun = !0, y = setTimeout(() => {
243
251
  y = null, f.value === e && (c.valueDelayRun = !1, c.prevDelayValue !== e && (c.prevDelayValue = e, o("onChangeDelay", e)));
244
- }, n.changeDelayTime);
245
- }, h = () => {
252
+ }, t.changeDelayTime);
253
+ }, C = () => {
246
254
  y && (clearTimeout(y), y = null), c.valueDelayRun = !1;
247
- }, w = (e) => {
255
+ }, S = (e) => {
248
256
  if (e !== f.value) {
249
257
  f.value = e;
250
- const i = m(e);
251
- o("update:value", i), o("update:modelValue", i), o("onChange", i), $(i);
258
+ const s = m(e);
259
+ o("update:value", s), o("update:modelValue", s), o("onChange", s), $(s);
252
260
  }
253
- }, b = (e) => {
254
- C.value = !0, S.value = e, o("onFocus", e);
255
261
  }, M = (e) => {
256
- C.value = !1, o("onBlur", e), e !== S.value && (S.value = e, o("onChangeBlur", e));
262
+ x.value = !0, h.value = e, o("onFocus", e);
257
263
  }, z = (e) => {
258
- o("onKeyupEnter", e);
264
+ x.value = !1, o("onBlur", e), e !== h.value && (h.value = e, o("onChangeBlur", e));
259
265
  }, l = (e) => {
266
+ o("onKeyupEnter", e);
267
+ }, b = (e) => {
260
268
  o("onKeydown", e);
261
- }, x = (e) => {
269
+ }, ne = (e) => {
262
270
  o("onKeyup", e);
263
- }, te = () => {
264
- o("onClear");
265
271
  }, oe = () => {
266
- ye(() => {
272
+ o("onClear");
273
+ }, le = () => {
274
+ ve(() => {
267
275
  o("onInit");
268
276
  });
269
277
  }, m = (e) => u.isString(e) || u.isNumber(e) && u.isFinite(e) ? e.toString() : "", J = () => {
270
- p.value?.focus();
271
- }, le = () => {
272
- const e = m(n.value);
273
- u.isEmpty(e) || (a.value = e, f.value = e), oe();
278
+ d.value?.focus();
279
+ }, ae = () => {
280
+ const e = m(t.value);
281
+ u.isEmpty(e) || (a.value = e, f.value = e), le();
274
282
  };
275
- ce(() => {
276
- le();
283
+ pe(() => {
284
+ ae();
277
285
  }), de(() => {
278
- h();
279
- }), pe(
280
- () => n.value,
286
+ C();
287
+ }), fe(
288
+ () => t.value,
281
289
  (e) => {
282
- const i = m(e);
283
- i !== a.value && (a.value = i, f.value = i, c.prevDelayValue = i, c.valueDelayRun && h());
290
+ const s = m(e);
291
+ s !== a.value && (a.value = s, f.value = s, c.prevDelayValue = s, c.valueDelayRun && C());
284
292
  }
285
293
  );
286
294
  const L = (e) => {
287
- a.value = e, w(e);
295
+ a.value = e, S(e);
288
296
  }, U = (e) => {
289
- l(e);
297
+ b(e);
290
298
  }, A = (e) => {
291
- const i = e.key, g = e.keyCode;
292
- if (i === "Enter" || g === 13) {
293
- const ue = e.target, se = m(ue.value);
294
- z(se);
299
+ const s = e.key, v = e.keyCode;
300
+ if (s === "Enter" || v === 13) {
301
+ const ie = e.target, se = m(ie.value);
302
+ l(se);
295
303
  } else
296
- x(e);
304
+ ne(e);
297
305
  }, j = () => {
298
306
  const e = m(a.value);
299
- b(e);
307
+ M(e);
300
308
  }, q = () => {
301
309
  const e = m(a.value);
302
- M(e);
310
+ z(e);
303
311
  }, G = () => {
304
- a.value = "", w(""), te(), J();
305
- }, ae = () => {
306
- const e = p.value;
312
+ a.value = "", S(""), oe(), J();
313
+ }, ue = () => {
314
+ const e = d.value;
307
315
  return e ? e.getInputElement() : null;
308
316
  }, H = () => m(a.value);
309
317
  return E({
310
318
  getValue: H,
311
319
  getValueData: () => ({ value: H(), show: a.value }),
312
- setValue: (e, i) => {
313
- const g = m(e);
314
- a.value = g, f.value = g, c.prevDelayValue = g, c.valueDelayRun && h(), i && (o("update:value", g), o("update:modelValue", g));
320
+ setValue: (e, s) => {
321
+ const v = m(e);
322
+ a.value = v, f.value = v, c.prevDelayValue = v, c.valueDelayRun && C(), s && (o("update:value", v), o("update:modelValue", v));
315
323
  },
316
324
  focus: () => {
317
325
  J();
318
326
  },
319
- getInputElement: ae
320
- }), (e, i) => (s(), r("div", {
321
- id: _(T),
327
+ getInputElement: ue
328
+ }), (e, s) => (i(), r("div", {
329
+ id: _(V),
322
330
  class: O(K.value),
323
- style: fe(D.value)
331
+ style: me(D.value)
324
332
  }, [
325
- t.isPlaintext ? (s(), r("div", xe, ee(a.value), 1)) : (s(), r(k, { key: 1 }, [
326
- e.$slots.prepend || e.$slots.append ? (s(), r("div", {
333
+ n.isPlaintext ? (i(), r("div", ke, ee(F.value), 1)) : (i(), r(k, { key: 1 }, [
334
+ e.$slots.prepend || e.$slots.append ? (i(), r("div", {
327
335
  key: 0,
328
- class: O({ "input-group": !0, "input-group-focus": C.value })
336
+ class: O({ "input-group": !0, "input-group-focus": x.value })
329
337
  }, [
330
- e.$slots.prepend ? (s(), r("div", Ie, [
331
- P("span", ke, [
338
+ e.$slots.prepend ? (i(), r("div", we, [
339
+ P("span", Be, [
332
340
  I(e.$slots, "prepend")
333
341
  ])
334
- ])) : (s(), r(k, { key: 1 }, [], 64)),
335
- me(N, {
342
+ ])) : (i(), r(k, { key: 1 }, [], 64)),
343
+ ye(N, {
336
344
  ref_key: "refElContainer",
337
- ref: p,
345
+ ref: d,
338
346
  value: a.value,
339
- inputType: t.inputType,
340
- inputmode: t.inputmode,
341
- autocomplete: t.autocomplete,
342
- name: t.name,
343
- placeholder: t.placeholder,
344
- disabled: t.disabled,
345
- isReadonly: t.isReadonly,
346
- isClean: t.isClean,
347
+ inputType: n.inputType,
348
+ inputmode: n.inputmode,
349
+ autocomplete: n.autocomplete,
350
+ name: n.name,
351
+ placeholder: n.placeholder,
352
+ disabled: n.disabled,
353
+ isReadonly: n.isReadonly,
354
+ isClean: n.isClean,
347
355
  isShowSuffix: !!e.$slots.suffix,
348
- label: t.label,
349
- isFloating: t.isFloating,
356
+ label: n.label,
357
+ isFloating: n.isFloating,
350
358
  onOnInputText: L,
351
359
  onOnKeydown: U,
352
360
  onOnKeyup: A,
@@ -356,37 +364,37 @@ const ve = ["id"], he = ["type", "inputmode", "name", "value", "placeholder", "d
356
364
  }, W({ _: 2 }, [
357
365
  e.$slots.suffix ? {
358
366
  name: "suffix",
359
- fn: V(() => [
367
+ fn: B(() => [
360
368
  I(e.$slots, "suffix")
361
369
  ]),
362
370
  key: "0"
363
371
  } : {
364
372
  name: "suffix",
365
- fn: V(() => []),
373
+ fn: B(() => []),
366
374
  key: "1"
367
375
  }
368
376
  ]), 1032, ["value", "inputType", "inputmode", "autocomplete", "name", "placeholder", "disabled", "isReadonly", "isClean", "isShowSuffix", "label", "isFloating"]),
369
- e.$slots.append ? (s(), r("div", we, [
370
- P("span", Be, [
377
+ e.$slots.append ? (i(), r("div", Ee, [
378
+ P("span", Te, [
371
379
  I(e.$slots, "append")
372
380
  ])
373
- ])) : (s(), r(k, { key: 3 }, [], 64))
374
- ], 2)) : (s(), ne(N, {
381
+ ])) : (i(), r(k, { key: 3 }, [], 64))
382
+ ], 2)) : (i(), te(N, {
375
383
  key: 1,
376
384
  ref_key: "refElContainer",
377
- ref: p,
385
+ ref: d,
378
386
  value: a.value,
379
- inputType: t.inputType,
380
- inputmode: t.inputmode,
381
- autocomplete: t.autocomplete,
382
- name: t.name,
383
- placeholder: t.placeholder,
384
- disabled: t.disabled,
385
- isReadonly: t.isReadonly,
386
- isClean: t.isClean,
387
+ inputType: n.inputType,
388
+ inputmode: n.inputmode,
389
+ autocomplete: n.autocomplete,
390
+ name: n.name,
391
+ placeholder: n.placeholder,
392
+ disabled: n.disabled,
393
+ isReadonly: n.isReadonly,
394
+ isClean: n.isClean,
387
395
  isShowSuffix: !!e.$slots.suffix,
388
- label: t.label,
389
- isFloating: t.isFloating,
396
+ label: n.label,
397
+ isFloating: n.isFloating,
390
398
  onOnInputText: L,
391
399
  onOnKeydown: U,
392
400
  onOnKeyup: A,
@@ -396,20 +404,20 @@ const ve = ["id"], he = ["type", "inputmode", "name", "value", "placeholder", "d
396
404
  }, W({ _: 2 }, [
397
405
  e.$slots.suffix ? {
398
406
  name: "suffix",
399
- fn: V(() => [
407
+ fn: B(() => [
400
408
  I(e.$slots, "suffix")
401
409
  ]),
402
410
  key: "0"
403
411
  } : {
404
412
  name: "suffix",
405
- fn: V(() => []),
413
+ fn: B(() => []),
406
414
  key: "1"
407
415
  }
408
416
  ]), 1032, ["value", "inputType", "inputmode", "autocomplete", "name", "placeholder", "disabled", "isReadonly", "isClean", "isShowSuffix", "label", "isFloating"]))
409
417
  ], 64))
410
- ], 14, be));
418
+ ], 14, Ie));
411
419
  }
412
420
  });
413
421
  export {
414
- Oe as _
422
+ ze as _
415
423
  };
@@ -0,0 +1 @@
1
+ "use strict";var Ie=Object.create;var we=Object.defineProperty;var xe=Object.getOwnPropertyDescriptor;var ke=Object.getOwnPropertyNames;var _e=Object.getPrototypeOf,Te=Object.prototype.hasOwnProperty;var Be=(c,O,L,r)=>{if(O&&typeof O=="object"||typeof O=="function")for(let o of ke(O))!Te.call(c,o)&&o!==L&&we(c,o,{get:()=>O[o],enumerable:!(r=xe(O,o))||r.enumerable});return c};var Ce=(c,O,L)=>(L=c!=null?Ie(_e(c)):{},Be(O||!c||!c.__esModule?we(L,"default",{value:c,enumerable:!0}):L,c));const e=require("vue"),G=require("@cldemo/ui-kit/common/log"),n=require("@cldemo/ui-kit/common/base"),N=require("@cldemo/ui-kit/common/Element"),Ve=require("@cldemo/ui-kit/common/globalConfig"),Me=require("./Index.vue_vue_type_script_setup_true_lang-BPTL5eCB.js"),Le=require("./List.vue_vue_type_script_setup_true_lang-B75tAGde.js"),Oe=require("./Index.vue_vue_type_script_setup_true_lang-98sOHlWj.js"),De=require("./One.vue_vue_type_script_setup_true_lang-DxUlP9yq.js"),be=require("./language-BJ4aVgHI.js"),Pe=require("./Index.vue_vue_type_script_setup_true_lang-xONe0mSK.js"),Fe=require("./Index.vue_vue_type_script_setup_true_lang-kCemr-ml.js");;/* empty css */const Ae=["id"],Ke={key:0,class:"select-inDropdown-search",role:"search","aria-label":"搜索选项"},Ne={key:2,class:"select-inDropdown-checkboxAll"},Re=["aria-selected","aria-disabled","onClick"],$e={class:"select-inDropdown-item-inner"},qe={key:0,class:"select-inDropdown-checkbox"},He=["innerHTML"],Je={key:5,class:"select-inDropdown-body"},je={class:"select-inDropdown-empty"},Se=35,We=210,ze=20,Ue=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:c=>!0,onInitComplete:()=>!0,onError:c=>!0},setup(c,{expose:O,emit:L}){const r=e.defineAsyncComponent(()=>import("vue-virtual-scroller").then(l=>(Promise.resolve().then(()=>require("./vue-virtual-scroller-C_hlZMj5.js")),l.RecycleScroller))),o=c,_=L,{optPageLanguage:X,getPageLanguage:Y}=be.useLanguage();Y("common");const T=e.inject("$SelectTop",{}),M=typeof T.getSelectData=="function",E=e.useTemplateRef("refElSearch"),P=e.useTemplateRef("refElScroller"),I=e.useTemplateRef("refElRoot");let S=!0;const w={isScrollLoading:!1,hasMoreData:!0};let f=[],F=0,B=0;const Z=o.id,ee=`select-inList-${o.keyIndex||""}`;let R=!1;const J=e.ref(""),k=e.ref([]),te=e.ref([]);let ne={};const re=l=>{const s=l.id.toString();if(o.isMultiple&&o.isCascade&&l._hasChildren&&M){const p=T.getAllChildIds(s).filter(g=>!T.getSelectValueInfo(g)?.isDisabled);if(p.length===0)return 0;const m=p.filter(g=>n.isExistValue(o.selectId,g)).length;return m===0?0:m===p.length?2:1}return n.isExistValue(o.selectId,s)?2:0},oe=l=>re(l)===2,pe=l=>re(l)===1,he=e.computed(()=>{let l=!1;return te.value.length>0&&o.selectId.length>=te.value.length&&(l=n.isContainArr(o.selectId,te.value)),l}),ge=l=>{if(!l||typeof l!="object")return"";let s=n.isNonEmptyString(o.showDropDownTextFormat)?o.showDropDownTextFormat:"";l._level>=1&&n.isNonEmptyString(o.showDropDownTextFormatSub)&&(s=o.showDropDownTextFormatSub);let a=n.isEmpty(s)?l.name:n.convertStringFormat(s,l);return n.isHtml(a)?n.isEmpty(s)&&n.isHtml(l.name)?a=n.encodeHTML(l.name):a=n.convertStringFormatEncodeHTML(s,l):typeof a=="string"&&a.indexOf("<")>-1&&(a=n.encodeHTML(a)),a},j=l=>{const s=ne[l]||{};if(n.isBoolean(s._isTypeRadio))return s._isTypeRadio;if(M){const a=T.getSelectValueInfo(l);if(n.isBoolean(a?._isTypeRadio))return a._isTypeRadio}return!1},W=()=>{const l=[];ne=n.getJsonByList(k.value),k.value.forEach(s=>{if(!n.isObject(s))return;const a=typeof s.id;if(s.id==null||a!=="string"&&(a!=="number"||!n.isFinite(s.id)))return;const p=s.id.toString();if(!(o.isCascade&&s._hasChildren)&&!j(p)){if(n.isExistValue(l,p))return;s.isDisabled?n.isExistValue(o.selectId,p)&&l.push(p):l.push(p)}}),te.value=l},z=l=>{const s=o.parentKey,a=o.topParentValue,p={};l.forEach(y=>{if(!n.isObject(y)||y.id==null||typeof y.id!="string"&&(typeof y.id!="number"||!n.isFinite(y.id)))return;const x=y[s],V=x!=null&&(typeof x=="string"||typeof x=="number")?x.toString():"";V!==""&&V!==String(a)&&(p[V]||(p[V]=[]),p[V].push(y))});const m=[],g=(y,x,V,C)=>{y.forEach(K=>{const ae=K.id.toString();if(C.has(ae))return;C.add(ae);const $=p[ae]||[];m.push({...K,_level:x,_parentName:V,_hasChildren:$.length>0}),$.length>0&&g($,x+1,K.name,C)})},D=l.filter(y=>{if(!n.isObject(y)||y.id==null||typeof y.id!="string"&&(typeof y.id!="number"||!n.isFinite(y.id)))return!1;const x=y[s],V=x!=null&&(typeof x=="string"||typeof x=="number")?x.toString():"";return n.isEmpty(V)||V===String(a)});return g(D,0,"",new Set),m},ie=(l,s)=>{if(!M)return l;const a=l.filter(C=>C!=null&&C.id!=null&&(typeof C.id=="string"||typeof C.id=="number"&&n.isFinite(C.id))),p=s.filter(C=>C!=null&&C.id!=null&&(typeof C.id=="string"||typeof C.id=="number"&&n.isFinite(C.id))),m=o.parentKey,g=o.topParentValue,D=new Set,y=new Set(a.map(C=>C.id.toString()));a.forEach(C=>{const K=C.id.toString();D.add(K);const ae=new Set;let $=C[m];for(;$!=null&&(typeof $=="string"||typeof $=="number")&&$.toString()!==String(g);){const i=$.toString();if(ae.has(i))break;ae.add(i),y.has(i)||D.add(i),$=T.getSelectValueInfo(i)?.[m]}T.getAllChildIds(K).forEach(i=>{D.add(i)})});const x=p.filter(C=>D.has(C.id.toString())),V=new Set(x.map(C=>C.id.toString()));return D.forEach(C=>{if(!V.has(C)){const K=T.getSelectValueInfo(C);K&&Object.keys(K).length>0&&x.push(K)}}),x},ce=()=>{S&&(S=!1,w.hasMoreData=!0,o.isCascade?(f=[...o.originalData||[]],k.value=z(f)):k.value=n.getListClone(o.originalData).filter(l=>l!=null&&l.id!=null&&(typeof l.id=="string"||typeof l.id=="number"&&n.isFinite(l.id))),W(),ye(),J.value="",e.nextTick(()=>{E.value&&E.value.setValue("")}))},ye=()=>{e.nextTick(()=>{if(P.value&&o.selectId.length>0){const l=k.value.findIndex(s=>s.id!=null&&n.isExistValue(o.selectId,s.id.toString()));l>-1&&P.value.scrollToItem(l)}})},se=l=>{const s=[],a=ne[l]||{},p=o.isCascade&&a._hasChildren;if(o.isMultiple)if(j(l))n.isExistValue(o.selectId,l)?o.selectId.forEach(m=>{m!==l&&s.push(m)}):(o.selectId.forEach(m=>{j(m)||s.push(m)}),s.push(l));else if(p&&M){const m=T.getAllChildIds(l),g=m.filter(y=>!T.getSelectValueInfo(y)?.isDisabled),D=g.length>0&&g.every(y=>n.isExistValue(o.selectId,y));o.selectId.forEach(y=>{m.includes(y)?m.includes(y)&&T.getSelectValueInfo(y)?.isDisabled&&s.push(y):s.push(y)}),D||g.forEach(y=>{n.isExistValue(s,y)||s.push(y)})}else o.selectId.forEach(m=>{m!==l&&s.push(m)}),n.isExistValue(o.selectId,l)||s.push(l);else{if(p&&!o.parentSelectable)return[...o.selectId];s.push(l)}return s},le=l=>{const s=k.value;if(s.length===0)return;let a=-1;const p=J.value;p.length>0?(s.forEach((m,g)=>{m.id.toString()===p&&(a=g)}),a+=l,a<0?a=0:a>=s.length&&(a=s.length-1)):a=0,J.value=s[a].id.toString(),P.value&&P.value.scrollToItem(a)},q=l=>{let s=l.keyCode;if(!n.isUndefined(s))switch(s=s.toString(),s){case"13":{const a=I.value&&l.target instanceof Node&&I.value.contains(l.target);(l.target===document.body||a)&&(l.preventDefault(),l.stopPropagation());break}case"38":l.preventDefault(),l.stopPropagation(),le(-1);break;case"40":l.preventDefault(),l.stopPropagation(),le(1);break}},H=l=>{let s=l.keyCode;if(!n.isUndefined(s))switch(s=s.toString(),s){case"27":M&&T.closeDropdown?.();break;case"13":{const a=J.value;if(!a||o.disabled||!o.isOpen)break;const p=I.value&&l.target instanceof Node&&I.value.contains(l.target);if(l.target!==document.body&&!p||!k.value.some(D=>D.id.toString()===a)||ne[a]?.isDisabled)break;const g=se(a);_("onChange",g);break}}},U=l=>l.map(s=>{const{_level:a,_parentName:p,_hasChildren:m,...g}=s;return g}),ue=async()=>{if(o.serverCallback&&!(w.isScrollLoading||!w.hasMoreData)&&(w.isScrollLoading=!0,o.serverCallback)){const l=++B,s=k.value;try{const a={offset:s.length};if(o.isSearch&&E.value){const D=E.value.getValue();n.isEmpty(D)||(a.search=D)}const p=await o.serverCallback(a);if(l!==B||s!==k.value)return;if(!Array.isArray(p)){G.error("ClSelect","_loadMore 服务端返回数据格式异常(非数组):",typeof p),_("onError","服务端加载失败:返回数据格式异常");return}if(p.length===0){w.hasMoreData=!1;return}const m=new Set(s.map(D=>D?.id?.toString()).filter(Boolean)),g=p.filter(D=>{if(D?.id==null)return!1;const y=typeof D.id;return y!=="string"&&(y!=="number"||!n.isFinite(D.id))?!1:!m.has(D.id.toString())});if(g.length===0){w.hasMoreData=!1;return}o.isCascade?a.search?k.value=z([...k.value,...g]):(f.length===0&&(f=U(k.value)),f.length===0&&(f=[...o.originalData]),f.push(...g),k.value=z(f)):k.value.push(...g),W(),M&&(T.convertListToJson(g),T.refreshDisplayLabels?.())}catch(a){G.error("ClSelect","_loadMore 服务端加载失败:",a),_("onError","服务端加载失败,请稍后重试")}finally{w.isScrollLoading=!1}}},de=()=>{ce(),_("onInitComplete")};e.onMounted(()=>{de()}),e.onBeforeUnmount(()=>{N.offListener(window,"keydown",q),N.offListener(window,"keyup",H),R=!1}),e.onDeactivated(()=>{N.offListener(window,"keydown",q),N.offListener(window,"keyup",H),R=!1}),e.onActivated(()=>{o.isOpen&&!R&&(N.onListener(window,"keydown",q),N.onListener(window,"keyup",H),R=!0)}),e.watch(()=>o.isOpen,l=>{l?(S=!0,ce()):w.isScrollLoading=!1}),e.watch(()=>o.originalData,l=>{S=!0,o.isCascade?(f=[...l||[]],k.value=z(f)):k.value=n.getListClone(l).filter(s=>s!=null&&s.id!=null&&(typeof s.id=="string"||typeof s.id=="number"&&n.isFinite(s.id))),W(),w.hasMoreData=!0,J.value="",e.nextTick(()=>{E.value&&E.value.setValue("")})});const me=async l=>{const s=++F;B=Math.max(B,s+1);let a=[];if(o.isCascade&&(f=[]),w.hasMoreData=!0,o.serverCallback){try{if(a=await o.serverCallback({search:l,offset:0}),Array.isArray(a)||(G.error("ClSelect","onSearch 服务端返回数据格式异常(非数组):",typeof a),_("onError","服务端搜索失败:返回数据格式异常"),a=[]),s!==F)return;M&&T.convertListToJson(a)}catch(p){G.error("ClSelect","onSearch 服务端搜索失败:",p),_("onError","服务端搜索失败,请稍后重试"),a=[]}if(s!==F)return;o.isCascade&&(a=ie(a,o.originalData),a=z(a))}else{const p=o.originalData.filter(m=>m!=null&&m.id!=null&&(typeof m.id=="string"||typeof m.id=="number"&&n.isFinite(m.id)));if(n.isEmpty(l))a=p;else{o.searchKeyType!=="||"&&o.searchKeyType!=="&&"&&G.warn("ClSelect","onSearch searchKeyType 未知值,已降级为 OR 匹配:",o.searchKeyType);const m=l.toLowerCase(),g=n.isArray(o.searchKey)?o.searchKey:["name"],D=g.length;p.forEach(y=>{const x=[];for(let V=0;V<D;V++){const C=y[g[V]];if(C==null)continue;String(C).toLowerCase().indexOf(m)>-1&&x.push(!0)}if(x.length>0)switch(o.searchKeyType){case"||":a.push(y);break;case"&&":x.length===D&&a.push(y);break;default:a.push(y)}})}o.isCascade&&(n.isEmpty(l)||(a=ie(a,o.originalData)),a=z(a))}k.value=a.filter(p=>p!=null&&p.id!=null&&(typeof p.id=="string"||typeof p.id=="number"&&n.isFinite(p.id))),W(),J.value="",M&&T.calculationDropdownPosition()},fe=l=>{if(!o.disabled&&o.isMultiple){const s=[],a=[];te.value.forEach(g=>{l.value?n.isExistValue(o.selectId,g)||s.push(g):n.isExistValue(o.selectId,g)&&(ne[g]?.isDisabled||a.push(g))});const p=n.getArrClone(o.selectId);a.length>0&&a.forEach(g=>{const D=p.indexOf(g);D>-1&&p.splice(D,1)}),s.length>0&&s.forEach(g=>{n.isExistValue(p,g)||p.push(g)});const m=[];p.forEach(g=>{(!j(g)||n.isExistValue(o.selectId,g))&&m.push(g)}),_("onChange",m)}},Q=l=>{if(l.id==null||typeof l.id!="string"&&(typeof l.id!="number"||!n.isFinite(l.id))||l.isDisabled||o.disabled)return;const s=l.id.toString(),a=se(s);_("onChange",a)};return O({initOpenShow:l=>{l?R||(N.onListener(window,"keydown",q),N.onListener(window,"keyup",H),R=!0):R&&(N.offListener(window,"keydown",q),N.offListener(window,"keyup",H),R=!1)}}),(l,s)=>(e.openBlock(),e.createElementBlock("div",{class:"select-inDropdown-container",id:e.unref(Z),ref_key:"refElRoot",ref:I},[c.isSearch?(e.openBlock(),e.createElementBlock("div",Ke,[e.createVNode(Oe._sfc_main,{ref_key:"refElSearch",ref:E,placeholder:c.searchPlaceholder,disabled:c.disabled,onOnChange:me},null,8,["placeholder","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),c.isMultiple&&c.isCheckBoxAll&&k.value.length>0?(e.openBlock(),e.createElementBlock("div",Ne,[e.createVNode(De._sfc_main,{forId:`${ee}-cb-all`,label:e.unref(X).checkboxAll,value:he.value,disabled:c.disabled,onOnChange:fe},null,8,["forId","label","value","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),k.value.length>0?(e.openBlock(),e.createBlock(e.unref(r),{key:4,class:"select-inDropdown-body select-inDropdown-scroller",role:"listbox",style:e.normalizeStyle({height:Math.min(k.value.length*Se,We)+"px"}),items:k.value,"item-size":Se,"key-field":"id",ref_key:"refElScroller",ref:P,onScrollEnd:ue},{default:e.withCtx(({item:a})=>[e.createElementVNode("div",{role:"option","aria-selected":oe(a),"aria-disabled":a.isDisabled||!1,class:e.normalizeClass({"option-selected":oe(a),"option-disabled":a.isDisabled,"option-hoverKeydown":J.value===a.id.toString(),"select-inDropdown-item-child":a._level>=1}),style:e.normalizeStyle({height:Se+"px",paddingLeft:a._level?a._level*ze+"px":void 0}),onClick:p=>Q(a)},[e.createElementVNode("div",$e,[c.isMultiple?(e.openBlock(),e.createElementBlock("div",qe,[e.createVNode(De._sfc_main,{name:`${ee}-cb`,forId:`${ee}-cb-${a.id}`,value:oe(a),indeterminate:pe(a),disabled:a.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:ge(a)},null,8,He)])],14,Re)]),_:1},8,["style","items"])):(e.openBlock(),e.createElementBlock("div",Je,[e.createElementVNode("div",je,e.toDisplayString(e.unref(X).noResultsText),1)]))],8,Ae))}}),Ge=["id"],Xe={class:"select-inTag-title"},Qe={class:"select-inTag-operate"},Ye={class:"select-inTag-body"},Ze=e.defineComponent({name:"ClSelectInTags",__name:"Tags",props:{id:String,showTextFormat:String,selectId:{type:Array,default:()=>[]}},emits:{onRemove:c=>!0},setup(c,{emit:O}){const L=c,r=O,o=L.id,{optPageLanguage:_,getPageLanguage:X}=be.useLanguage();X("common");const Y=e.inject("$SelectTop",{}),T=typeof Y.getSelectData=="function",M=e.computed(()=>T?n.isArray(L.selectId)?Y.getSelectData(L.selectId):[]:[]),E=e.computed(()=>T?M.value.length:0),P=e.computed(()=>n.isArray(M.value)?M.value.some(w=>n.isObject(w)?!(n.isBoolean(w.isDisabled)&&w.isDisabled):!1):!1),I=()=>{const w=M.value;if(!n.isArray(w))return;const f=[];let F=!1;w.forEach(B=>{if(!n.isObject(B))return;(n.isBoolean(B.isDisabled)?!!B.isDisabled:!1)?(typeof B.id=="string"&&!n.isEmpty(B.id)||typeof B.id=="number"&&n.isFinite(B.id))&&f.push(B.id.toString()):F=!0}),F&&r("onRemove",f)},S=w=>{if(!n.isArray(L.selectId)||n.isEmpty(w))return;const f=String(w),F=L.selectId.findIndex(Z=>String(Z)===f);if(F===-1)return;const B=n.getArrClone(L.selectId);B.splice(F,1),r("onRemove",B)};return(w,f)=>(e.openBlock(),e.createElementBlock("div",{class:"select-inTag-container",id:e.unref(o)},[e.createElementVNode("div",Xe,[e.createElementVNode("span",null,e.toDisplayString(e.unref(_).selected)+" "+e.toDisplayString(E.value)+" "+e.toDisplayString(e.unref(_).count),1),e.createElementVNode("span",Qe,[P.value?(e.openBlock(),e.createBlock(Pe._sfc_main,{key:0,class:"select-inTag-deleteAll",name:"remove",title:e.unref(_).deleteAll,"aria-label":e.unref(_).deleteAll,onClick:I},null,8,["title","aria-label"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))])]),e.createElementVNode("div",Ye,[e.createVNode(Fe._sfc_main,{showTextFormat:c.showTextFormat,list:M.value,onOnRemove:S},null,8,["showTextFormat","list"])])],8,Ge))}}),et=["id"],tt={key:0,class:"select-inText-num"},nt=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:c=>["default","noBorder"].includes(c)},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:c=>["left","right"].includes(c)},transitionLeave:{type:String,default:"zoomOutTop"},searchPlaceholder:String,searchKey:{type:Array,default:()=>["name"]},searchKeyType:{type:String,default:"||",validator:c=>["||","&&"].includes(c)},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},plaintextEmptyText:{type:String,default:void 0},plaintextSeparator:{type:String,default:","},plaintextLevelSeparator:{type:String,default:" > "},onOpenBefore:Function,serverCallback:Function,appendContainer:{type:String,default:""}},emits:{"update:value":c=>!0,"update:modelValue":c=>!0,onChange:(c,O)=>!0,onInit:()=>!0,onOpen:c=>!0,onError:c=>!0},setup(c,{expose:O,emit:L}){const r=c,o=L,_=e.useTemplateRef("refElDropdownLayer"),X=e.useTemplateRef("refElList"),Y=e.useTemplateRef("refElTags"),T=`select-${n.getRandom(8)}`,M=r.id,E=e.reactive({isOpen:!1,dropDownPos:"down",tagHeight:"",tagLeft:"",tagDirection:"right"});let P=[],I={};const S={childrenMap:{},parentMap:{},lastChildMap:{},allChildMap:{}},w=e.ref(!1),f=e.ref([]),F=e.ref([]),B=e.ref([]);let Z=!1;const ee=e.computed(()=>n.isNonEmptyString(r.showTextFormat)?r.showTextFormat:r.isCascade?"${name}(${parentName})":""),R=e.computed(()=>{let t={"panel-select":!0};return r.theme==="noBorder"&&(t["select-theme-noBorder"]=!0),t=n.getJsonMerge(t,N.getClassNameJson(r.className)),n.getStringByJson(t," ")}),J=e.computed(()=>`${R.value} cl-plaintext-value`),k=e.computed(()=>{const t=n.isString(r.plaintextSeparator)?r.plaintextSeparator:",";return B.value.join(t)}),te=e.computed(()=>Ve.getPlaintextOutText("select",r.plaintextEmptyText,k.value,r.value)),ne=e.computed(()=>{let t={"select-inDropdown":!0};return r.theme==="noBorder"&&(t["select-inDropdown-noBorder"]=!0),E.isOpen&&r.multiple&&r.isShowTag&&(t["select-inTag-ext"]=!0,t[`select-inTag-${E.tagDirection}`]=!0),t=n.getJsonMerge(t,N.getClassNameJson(r.classDropDown)),n.getStringByJson(t," ")}),re=e.computed(()=>{const t={"select-inTag":!0,"select-inTag-open":E.isOpen};return t[`select-inTag-${E.dropDownPos}`]=!0,t[`select-inTag-${E.tagDirection}`]=!0,t}),oe=t=>{o("update:value",t),o("update:modelValue",t)},pe=(t,i)=>{oe(t),o("onChange",t,i)},he=()=>{Z||(Z=!0,e.nextTick(()=>{o("onInit")}))},ge=t=>{e.nextTick(()=>{o("onOpen",t)})},j=()=>{const t=[];return f.value.forEach(i=>{n.isExistJsonKey(I,i)&&t.push(i)}),t},W=t=>{if(n.isEmpty(t)||!n.isArray(t))return;const i={},u=r.parentKey,h=r.topParentValue;if(t.forEach(d=>{if(!n.isObject(d)){G.warn("ClSelect","_convertListToJson 跳过非对象数据项:",d);return}if(!(typeof d.id=="string"||typeof d.id=="number"&&n.isFinite(d.id))){G.warn("ClSelect","_convertListToJson 跳过无 id 或 id 类型异常的数据项:",d);return}const b=d.id.toString();i[b]=n.getJsonClone(d)}),I=n.getJsonMerge(I,i),r.serverCallback&&!w.value&&!n.isEmpty(i)&&(w.value=!0,r.value!=null&&r.value!==""&&(H(r.value),q())),r.isCascade&&Object.keys(I).forEach(d=>{const v=I[d][u],b=v!=null&&(typeof v=="string"||typeof v=="number")?v.toString():"";if(b!==""&&b!==String(h)){const A=I[b];A?.name&&(I[d].parentName=A.name)}}),r.isCascade&&(z(),r.isOutMerge&&r.multiple&&f.value.length>0)){const d=se(f.value);n.isEqualArr(f.value,d)||(f.value=d,P=d)}if(r.multiple&&f.value.length>1){const d=f.value.filter(v=>{const b=I[v];return n.isBoolean(b?._isTypeRadio)&&b._isTypeRadio});if(d.length>1){const v=d[d.length-1],b=f.value.filter(A=>A===v||!d.includes(A));n.isEqualArr(f.value,b)||(f.value=b,Q())}}f.value.length>0&&(f.value=[...f.value])},z=()=>{const t=r.parentKey,i=r.topParentValue;S.childrenMap={},S.parentMap={},S.lastChildMap={},S.allChildMap={},Object.keys(I).forEach(h=>{const v=I[h][t],b=v!=null&&(typeof v=="string"||typeof v=="number")?v.toString():"";b!==""&&b!==String(i)&&(S.parentMap[h]=b,S.childrenMap[b]||(S.childrenMap[b]=[]),S.childrenMap[b].push(h))})},ie=t=>{const i=(u,h)=>{if(S.lastChildMap[u])return S.lastChildMap[u];if(h.has(u))return[];h.add(u);const d=S.childrenMap[u];if(!d||d.length===0)return S.lastChildMap[u]=[u],[u];const v=[];return d.forEach(b=>{v.push(...i(b,new Set(h)))}),S.lastChildMap[u]=v,v};return i(t,new Set)},ce=t=>{const i=(u,h)=>{if(S.allChildMap[u])return S.allChildMap[u];if(h.has(u))return[];h.add(u);const d=S.childrenMap[u];if(!d||d.length===0)return S.allChildMap[u]=[],[];const v=[];d.forEach(A=>{v.push(A),v.push(...i(A,new Set(h)))});const b=Array.from(new Set(v));return S.allChildMap[u]=b,b};return i(t,new Set)},ye=t=>{if(t.length===0)return[];const i=new Set(t),u=new Set,h=new Set;for(const d of i){const v=S.parentMap[d];v&&!h.has(v)&&u.add(v)}for(;u.size>0;){const d=u.values().next().value;if(u.delete(d),h.has(d))continue;h.add(d);const v=S.childrenMap[d];if(!v||v.length===0)continue;let b=!0;for(const A of v)if(!i.has(A)){b=!1;break}if(b){for(const Ee of v)i.delete(Ee);i.add(d);const A=S.parentMap[d];A&&!h.has(A)&&u.add(A)}}return[...i]},se=t=>{if(t.length===0)return[];const i=[];return t.forEach(u=>{i.push(...ie(u))}),n.getArrUnique(i)},le=t=>!r.isCascade||!r.multiple?t:r.isOutMerge?ye(t):se(t),q=()=>{if(w.value&&!n.isEmpty(f.value)){if(n.isEmpty(I)||r.serverCallback)return;const t=j();if(!n.isEqualArr(f.value,t)){const i=f.value.filter(h=>!t.includes(h));i.length>0&&G.warn("ClSelect","以下 id 在数据列表中不存在,已自动清除:",i),f.value=t,P=t;const u=le(t);oe(u.join(","))}}},H=t=>{if(t!=null&&typeof t!="string"&&(typeof t!="number"||!n.isFinite(t))){G.warn("ClSelect","setValue 收到非预期类型值:",typeof t,t);return}let i=t==null||t===""?[]:t.toString().split(",").filter(h=>h!=="");i=n.getArrUnique(i),r.isCascade&&r.isOutMerge&&i.length>0&&r.multiple&&(i=se(i));let u=n.isEqualArr(f.value,i);u&&(u=i.join(",")===f.value.join(",")),u||(P=i,f.value=i)},U=t=>n.isExistJsonKey(I,t)?n.getJsonClone(I[t]):{},ue=t=>{const i=n.isArray(t)?t:f.value,u=[];return i.forEach(h=>{const d=U(h);n.isEmpty(d)||u.push(d)}),u},de=t=>{const u=r.isCascade&&!r.multiple&&(S.childrenMap[t.id?.toString()]?.length>0||!S.parentMap[t.id?.toString()])&&n.isEmpty(r.showTextFormat)?"":ee.value;let h=n.isEmpty(u)?t.name??"":n.convertStringFormat(u,t);return n.isHtml(h)?h=n.isEmpty(u)?n.encodeHTML(t.name):n.convertStringFormatEncodeHTML(u,t):typeof h=="string"&&h.indexOf("<")>-1&&(h=n.encodeHTML(h)),h},me=t=>{if(n.isNonEmptyString(r.showTextFormat))return n.removeHTMLTags(de(t));const i=n.isString(r.plaintextLevelSeparator)?r.plaintextLevelSeparator:" > ",u=n.isString(t?.name)?t.name:"",h=n.isString(t?.parentName)?t.parentName:"",d=r.isCascade&&n.isNonEmptyString(h)?`${h}${i}${u}`:u;return n.removeHTMLTags(d)},fe=()=>{const t=ue();F.value=t.map(i=>de(i)),B.value=f.value.map(i=>{const u=U(i);return n.isEmpty(u)?i:me(u)})},Q=()=>{const t=j();P=t,f.value=t;const i=le(t),u=i.join(",");let h;if(r.multiple){const d=[];i.forEach(v=>{const b=U(v);n.isEmpty(b)||d.push(b)}),h=d}else h=U(u),n.isEmpty(h)&&(h=null);pe(u,h)},ve=()=>{E.isOpen||!n.isEqualArr(f.value,P)&&Q()},l=()=>{w.value||(w.value=!0,W(r.list),H(r.value),q())},s=()=>{!w.value&&r.list&&r.list.length>0&&l()},a=()=>{import("vue-virtual-scroller").then(()=>{Promise.resolve().then(()=>require("./vue-virtual-scroller-C_hlZMj5.js"))})};e.onMounted(()=>{r.isPlaintext||a(),e.nextTick(()=>{s()})}),e.watch(w,t=>{t&&he()}),e.watch(()=>r.list,(t,i)=>{w.value||(t&&t.length>0||i===void 0)&&(w.value=!0)}),e.watch([()=>r.value,()=>r.list],([t,i],[u,h])=>{const d=i||[];!w.value&&d.length>0&&(w.value=!0),i!==h&&(I={},S.childrenMap={},S.parentMap={},S.lastChildMap={},S.allChildMap={}),W(d),t!==void 0&&H(t),q()}),e.watch([f,()=>r.list],([t,i])=>{i&&i.length>0&&n.isEmpty(I)&&W(i),fe()}),e.watch(()=>r.isOutMerge,()=>{r.isCascade&&r.multiple&&f.value.length>0&&le(j()).join(",")!==String(r.value??"")&&Q()}),e.watch([()=>r.parentKey,()=>r.topParentValue],()=>{r.isCascade&&!n.isEmpty(I)&&z()});const p=t=>{t&&r.disabled||(E.isOpen=t,t?P=f.value:ve(),e.nextTick(()=>{X.value&&X.value.initOpenShow(t)}),ge(t))},m=()=>{r.disabled||(f.value=[],r.multiple&&r.multipleRealTimeChange?Q():ve())},g=t=>{if(E.dropDownPos=t.use.dropDownPos,r.multiple&&r.isShowTag){const i=Y.value?.$el?.offsetWidth||0;E.tagHeight=r.theme==="default"?`${t.original.dropDownHeight+1}px`:`${t.original.dropDownHeight}px`;const u=t.original.winWidth-(t.original.controlOffset.left+t.original.dropDownWidth)>=i?"right":"left";E.tagDirection=u,u==="right"?E.tagLeft=`${t.original.dropDownWidth-1}px`:E.tagLeft=`${(t.original.dropDownWidth-t.original.textWidth+i+1)*-1}px`}},D=t=>{f.value=t,r.multiple?r.multipleRealTimeChange&&Q():_.value?.setOpen(!1)},y=t=>{r.disabled||(f.value=t,Q())},x=t=>{o("onError",t)},V=()=>{_.value&&(_.value.checkIsShowOpen()||_.value.initCompleteOpen())};e.provide("$SelectTop",{getSelectData:ue,getSelectValueInfo:U,getAllChildIds:ce,calculationDropdownPosition:()=>{_.value?.calculationPosition()},convertListToJson:W,closeDropdown:()=>{_.value?.setOpen(!1)},refreshDisplayLabels:()=>{fe()}});const C=()=>{const t=j();return le(t).join(",")};return O({getValue:C,getValueData:()=>{const t=C();if(r.multiple){const u=t?t.split(","):[],h=[];return u.forEach(d=>{const v=U(d);n.isEmpty(v)||h.push(v)}),h}if(!t)return null;const i=U(t);return n.isEmpty(i)?null:i},setValue:t=>{H(t),q()},runInitComplete:()=>{l()}}),(t,i)=>c.isPlaintext?(e.openBlock(),e.createElementBlock("div",{key:0,id:e.unref(M),class:e.normalizeClass(J.value)},e.toDisplayString(te.value),11,et)):(e.openBlock(),e.createBlock(Le._sfc_main,{key:1,id:e.unref(M),ref_key:"refElDropdownLayer",ref:_,classParent:R.value,classText:"select-inText",classDropDown:ne.value,placeholder:c.placeholder,isDisabled:c.disabled,isClear:c.isClear,textLabel:F.value.join(","),textArrowDirection:c.arrowDirection,transitionLeave:c.transitionLeave,appendContainer:c.appendContainer,appendFollowWidth:c.theme!=="noBorder",onOpenBeforeCallback:c.onOpenBefore,onOnChangeOpen:p,onOnClear:m,onOnChangePosition:g},{textExtend:e.withCtx(()=>[c.multiple?(e.openBlock(),e.createElementBlock("span",tt,[F.value.length>1?(e.openBlock(),e.createBlock(Me._sfc_main,{key:0,num:F.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(Ue,{ref_key:"refElList",ref:X,isSearch:c.isSearch,searchPlaceholder:c.searchPlaceholder,searchKey:c.searchKey,searchKeyType:c.searchKeyType,isMultiple:c.multiple,isCheckBoxAll:c.isCheckBoxAll,showDropDownTextFormat:c.showDropDownTextFormat,showDropDownTextFormatSub:c.showDropDownTextFormatSub,isCascade:c.isCascade,parentSelectable:c.parentSelectable,parentKey:c.parentKey,topParentValue:c.topParentValue,originalData:c.list,keyIndex:T,selectId:f.value,disabled:c.disabled,isOpen:E.isOpen,serverCallback:c.serverCallback,onOnChange:D,onOnInitComplete:V,onOnError:x},null,8,["isSearch","searchPlaceholder","searchKey","searchKeyType","isMultiple","isCheckBoxAll","showDropDownTextFormat","showDropDownTextFormatSub","isCascade","parentSelectable","parentKey","topParentValue","originalData","selectId","disabled","isOpen","serverCallback"])]),dropdownExtend:e.withCtx(()=>[c.multiple&&c.isShowTag?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(re.value),style:e.normalizeStyle({height:E.tagHeight,left:E.tagLeft}),ref_key:"refElTags",ref:Y},[e.createVNode(Ze,{showTextFormat:ee.value,selectId:f.value,onOnRemove:y},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"]))}});exports._sfc_main=nt;
@@ -1 +1 @@
1
- "use strict";const t=require("vue"),n=require("@cldemo/ui-kit/common/base"),V=require("@cldemo/ui-kit/common/Element"),E=require("./Index.vue_vue_type_script_setup_true_lang-CFZ5jK-q.js"),z=["id"],$=["onClick"],J=["innerHTML"],q={key:1},O=t.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},color:{type:String,default:""},isSolid:{type:Boolean,default:!0},isRound:{type:Boolean,default:!1},size:{type:String,default:"m",validator:c=>["s","m","l"].indexOf(c)!==-1},isFormatHtml:{type:Boolean,default:!1}},emits:["onRemove","onClickTag"],setup(c,{expose:B,emit:C}){const l=c,m=C,T=`tags-${n.getRandom(5)}`,w=l.id,y=t.ref(l.disabled),r=t.ref([]),D=["primary","success","warning","danger","secondary"],i=t.reactive({status:0,startColor:"#FFFF80",endColor:"var(--cl-transparent, rgba(0, 0, 0, 0))",hID:""}),I=t.computed(()=>{let e={"panel-tags":!0};l.size!=="m"&&(e[`tags-size-${l.size}`]=!0),l.isRemoveAll&&r.value.length>0&&(e["tags-region"]=!0);const s=V.getClassNameJson(l.className);return e=n.getJsonMerge(e,s),e}),h=e=>n.isEmpty(e)?"":n.isEmpty(l.showTextFormat)?n.isNonEmptyString(e.name)?e.name:"":n.convertStringFormatEncodeHTML(l.showTextFormat,e),v=e=>n.isNonEmptyString(e.color)?e.color.trim():n.isNonEmptyString(l.color)?l.color.trim():"",k=e=>n.isBoolean(e.isSolid)?!!e.isSolid:l.isSolid,R=e=>n.isBoolean(e.isRound)?!!e.isRound:l.isRound,f=e=>n.isNonEmptyString(e)&&n.isExistValue(D,e),L=e=>{if(n.isEmpty(e))return{};const s=v(e),o=k(e),a={};return a.tag=!0,a["tag-disabled"]=!!e.isShowDisabled,a["tag-remove"]=l.isRemove&&!e.isShowDisabled,(n.isNonEmptyString(e.id)||typeof e.id=="number")&&(a["tag-hlight"]=e.id.toString()===i.hID&&i.status===2),n.isNonEmptyString(s)&&(a[o?"tag-solid":"tag-plain"]=!0,R(e)&&(a["tag-round"]=!0)),f(s)&&(a[`tag-color-${s}`]=!0),a},N=e=>{const s={};if(n.isEmpty(e))return s;const o=v(e);if(n.isNonEmptyString(o)&&!f(o)&&(k(e)?(s["background-color"]=o,s["border-color"]=o):(s.color=o,s["border-color"]=o)),n.isEmpty(e.id))return s;if(e.id.toString()===i.hID)switch(i.status){case 1:s["background-color"]=i.startColor;break;case 2:s["background-color"]=i.endColor;break}return s},S=e=>{if(n.isEmpty(e))return;const s=y.value;let o=!1;s?o=!0:o=n.isBoolean(e.isDisabled)?!!e.isDisabled:!1,e.isShowDisabled=o},g=e=>{const s=[];return!n.isArray(e)||n.isEmpty(e)||e.forEach(o=>{if(n.isEmpty(o))return;const a=n.getJsonClone(o);S(a),s.push(a)}),s},_=e=>{y.value=e;const s=g(r.value);r.value=s};let u=null,d=null;const b=()=>{u!==null&&(clearTimeout(u),u=null),d!==null&&(clearTimeout(d),d=null)},F=e=>{n.isEmpty(e)||(b(),i.hID=e.toString(),i.status=1,t.nextTick(()=>{u=setTimeout(()=>{i.status=2},10),d=setTimeout(()=>{i.status=0,i.hID=""},1500)}))},x=()=>{const e=g(l.list);r.value=e};t.onMounted(()=>{t.nextTick(()=>{x()})}),t.onBeforeUnmount(()=>{b()}),t.watch(()=>l.disabled,e=>{_(e)}),t.watch(()=>l.list,e=>{const s=g(e);r.value=s},{deep:!0});const H=(e,s)=>{m("onClickTag",s)},A=(e,s,o)=>{if(e.preventDefault(),e.stopPropagation(),l.isRemove&&!s.isShowDisabled&&o>=0&&o<r.value.length){r.value.splice(o,1);const a=n.isNonEmptyString(s.id)||typeof s.id=="number"?s.id.toString():"";m("onRemove",a)}},M=()=>{r.value=[],m("onRemove","")};return B({setDisabled:(e=!0)=>{_(e)},addInfo:e=>{if(n.isEmpty(e))return;const s=n.getListExistValue(r.value,e.name||"","name");if(n.isEmpty(s)){const o=n.getJsonClone(e);S(o),r.value.push(o)}else s.info&&!n.isEmpty(s.info.id)&&F(s.info.id)},getData:()=>n.getListClone(r.value)}),(e,s)=>(t.openBlock(),t.createElementBlock("div",{id:t.unref(w),class:t.normalizeClass(I.value)},[r.value.length>0?t.renderSlot(e.$slots,"head",{key:0}):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[],64)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.value,(o,a)=>(t.openBlock(),t.createElementBlock("span",{key:`${T}-list-${a}-${o.id}`,class:t.normalizeClass(L(o)),style:t.normalizeStyle(N(o)),onClick:t.withModifiers(p=>H(p,o),["stop"])},[o.isHtml||c.isFormatHtml?(t.openBlock(),t.createElementBlock("span",{key:0,innerHTML:h(o)},null,8,J)):(t.openBlock(),t.createElementBlock("span",q,t.toDisplayString(h(o)),1)),c.isRemove&&!o.isShowDisabled?(t.openBlock(),t.createBlock(E._sfc_main,{key:2,class:"tag-close",name:"close","aria-label":"移除",onClick:p=>A(p,o,a)},null,8,["onClick"])):t.createCommentVNode("",!0)],14,$))),128)),c.isRemoveAll&&r.value.length>0&&!c.disabled?(t.openBlock(),t.createBlock(E._sfc_main,{key:2,class:"tag-closeAll",name:"close","aria-label":"清除全部",onClick:M})):t.createCommentVNode("",!0)],10,z))}});exports._sfc_main=O;
1
+ "use strict";const t=require("vue"),n=require("@cldemo/ui-kit/common/base"),V=require("@cldemo/ui-kit/common/Element"),E=require("./Index.vue_vue_type_script_setup_true_lang-xONe0mSK.js"),z=["id"],$=["onClick"],J=["innerHTML"],q={key:1},O=t.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},color:{type:String,default:""},isSolid:{type:Boolean,default:!0},isRound:{type:Boolean,default:!1},size:{type:String,default:"m",validator:c=>["s","m","l"].indexOf(c)!==-1},isFormatHtml:{type:Boolean,default:!1}},emits:["onRemove","onClickTag"],setup(c,{expose:B,emit:C}){const l=c,m=C,T=`tags-${n.getRandom(5)}`,w=l.id,y=t.ref(l.disabled),r=t.ref([]),D=["primary","success","warning","danger","secondary"],i=t.reactive({status:0,startColor:"#FFFF80",endColor:"var(--cl-transparent, rgba(0, 0, 0, 0))",hID:""}),I=t.computed(()=>{let e={"panel-tags":!0};l.size!=="m"&&(e[`tags-size-${l.size}`]=!0),l.isRemoveAll&&r.value.length>0&&(e["tags-region"]=!0);const s=V.getClassNameJson(l.className);return e=n.getJsonMerge(e,s),e}),h=e=>n.isEmpty(e)?"":n.isEmpty(l.showTextFormat)?n.isNonEmptyString(e.name)?e.name:"":n.convertStringFormatEncodeHTML(l.showTextFormat,e),v=e=>n.isNonEmptyString(e.color)?e.color.trim():n.isNonEmptyString(l.color)?l.color.trim():"",k=e=>n.isBoolean(e.isSolid)?!!e.isSolid:l.isSolid,R=e=>n.isBoolean(e.isRound)?!!e.isRound:l.isRound,f=e=>n.isNonEmptyString(e)&&n.isExistValue(D,e),L=e=>{if(n.isEmpty(e))return{};const s=v(e),o=k(e),a={};return a.tag=!0,a["tag-disabled"]=!!e.isShowDisabled,a["tag-remove"]=l.isRemove&&!e.isShowDisabled,(n.isNonEmptyString(e.id)||typeof e.id=="number")&&(a["tag-hlight"]=e.id.toString()===i.hID&&i.status===2),n.isNonEmptyString(s)&&(a[o?"tag-solid":"tag-plain"]=!0,R(e)&&(a["tag-round"]=!0)),f(s)&&(a[`tag-color-${s}`]=!0),a},N=e=>{const s={};if(n.isEmpty(e))return s;const o=v(e);if(n.isNonEmptyString(o)&&!f(o)&&(k(e)?(s["background-color"]=o,s["border-color"]=o):(s.color=o,s["border-color"]=o)),n.isEmpty(e.id))return s;if(e.id.toString()===i.hID)switch(i.status){case 1:s["background-color"]=i.startColor;break;case 2:s["background-color"]=i.endColor;break}return s},S=e=>{if(n.isEmpty(e))return;const s=y.value;let o=!1;s?o=!0:o=n.isBoolean(e.isDisabled)?!!e.isDisabled:!1,e.isShowDisabled=o},g=e=>{const s=[];return!n.isArray(e)||n.isEmpty(e)||e.forEach(o=>{if(n.isEmpty(o))return;const a=n.getJsonClone(o);S(a),s.push(a)}),s},_=e=>{y.value=e;const s=g(r.value);r.value=s};let u=null,d=null;const b=()=>{u!==null&&(clearTimeout(u),u=null),d!==null&&(clearTimeout(d),d=null)},F=e=>{n.isEmpty(e)||(b(),i.hID=e.toString(),i.status=1,t.nextTick(()=>{u=setTimeout(()=>{i.status=2},10),d=setTimeout(()=>{i.status=0,i.hID=""},1500)}))},x=()=>{const e=g(l.list);r.value=e};t.onMounted(()=>{t.nextTick(()=>{x()})}),t.onBeforeUnmount(()=>{b()}),t.watch(()=>l.disabled,e=>{_(e)}),t.watch(()=>l.list,e=>{const s=g(e);r.value=s},{deep:!0});const H=(e,s)=>{m("onClickTag",s)},A=(e,s,o)=>{if(e.preventDefault(),e.stopPropagation(),l.isRemove&&!s.isShowDisabled&&o>=0&&o<r.value.length){r.value.splice(o,1);const a=n.isNonEmptyString(s.id)||typeof s.id=="number"?s.id.toString():"";m("onRemove",a)}},M=()=>{r.value=[],m("onRemove","")};return B({setDisabled:(e=!0)=>{_(e)},addInfo:e=>{if(n.isEmpty(e))return;const s=n.getListExistValue(r.value,e.name||"","name");if(n.isEmpty(s)){const o=n.getJsonClone(e);S(o),r.value.push(o)}else s.info&&!n.isEmpty(s.info.id)&&F(s.info.id)},getData:()=>n.getListClone(r.value)}),(e,s)=>(t.openBlock(),t.createElementBlock("div",{id:t.unref(w),class:t.normalizeClass(I.value)},[r.value.length>0?t.renderSlot(e.$slots,"head",{key:0}):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[],64)),(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(r.value,(o,a)=>(t.openBlock(),t.createElementBlock("span",{key:`${T}-list-${a}-${o.id}`,class:t.normalizeClass(L(o)),style:t.normalizeStyle(N(o)),onClick:t.withModifiers(p=>H(p,o),["stop"])},[o.isHtml||c.isFormatHtml?(t.openBlock(),t.createElementBlock("span",{key:0,innerHTML:h(o)},null,8,J)):(t.openBlock(),t.createElementBlock("span",q,t.toDisplayString(h(o)),1)),c.isRemove&&!o.isShowDisabled?(t.openBlock(),t.createBlock(E._sfc_main,{key:2,class:"tag-close",name:"close","aria-label":"移除",onClick:p=>A(p,o,a)},null,8,["onClick"])):t.createCommentVNode("",!0)],14,$))),128)),c.isRemoveAll&&r.value.length>0&&!c.disabled?(t.openBlock(),t.createBlock(E._sfc_main,{key:2,class:"tag-closeAll",name:"close","aria-label":"清除全部",onClick:M})):t.createCommentVNode("",!0)],10,z))}});exports._sfc_main=O;
@@ -4,7 +4,7 @@ import o from "@cldemo/ui-kit/common/base";
4
4
  import J from "@cldemo/ui-kit/common/Element";
5
5
  import { _ as M } from "./Index.vue_vue_type_script_setup_true_lang-DROYOL5-.js";
6
6
  import { _ as Ce } from "./Index.vue_vue_type_script_setup_true_lang-CVmFF9j1.js";
7
- import { _ as _e } from "./Index.vue_vue_type_script_setup_true_lang-C2LGy18j.js";
7
+ import { _ as _e } from "./Index.vue_vue_type_script_setup_true_lang-Bt0l5FYh.js";
8
8
  import { w as Ee } from "./index-CU97F682.js";
9
9
  /* empty css */
10
10
  const ze = ["id"], xe = ["disabled", "aria-label"], Le = {