@cldemo/ui-kit 1.1.3 → 1.1.4

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 (165) hide show
  1. package/buildLibs/all/index.cjs +8 -8
  2. package/buildLibs/all/index.js +12157 -12048
  3. package/buildLibs/common/globalConfig.cjs +1 -1
  4. package/buildLibs/common/globalConfig.js +29 -15
  5. package/buildLibs/common/i18n/en.cjs +1 -1
  6. package/buildLibs/common/i18n/en.js +3 -1
  7. package/buildLibs/common/i18n/zh_CN.cjs +1 -1
  8. package/buildLibs/common/i18n/zh_CN.js +3 -1
  9. package/buildLibs/common/index.cjs +1 -1
  10. package/buildLibs/common/index.js +26 -24
  11. package/buildLibs/mobile/index.cjs +5 -5
  12. package/buildLibs/mobile/index.js +5902 -5852
  13. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-CKoVf-v1.js → Index.vue_vue_type_script_setup_true_lang-88gNFuK4.js} +2 -2
  14. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-BQXxDHbe.js +254 -0
  15. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-D0g1xGPL.js → Index.vue_vue_type_script_setup_true_lang-BR0S3Sfl.js} +3 -3
  16. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-RRUPY9bd.js → Index.vue_vue_type_script_setup_true_lang-BrfAVhNV.js} +153 -145
  17. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-DdLVG0R0.js → Index.vue_vue_type_script_setup_true_lang-Bw_jRoEX.js} +67 -59
  18. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-C6Zd584S.js +2536 -0
  19. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-BOcOO9-n.js → Index.vue_vue_type_script_setup_true_lang-CD66oCaI.js} +386 -375
  20. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-CEBiLDTm.js +310 -0
  21. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-C0DgaU5I.js → Index.vue_vue_type_script_setup_true_lang-CRlBvcCg.js} +53 -47
  22. package/buildLibs/modules/shared/{Index.vue_vue_type_script_setup_true_lang-DqZBB8fM.js → Index.vue_vue_type_script_setup_true_lang-CdYh3Pzs.js} +1 -1
  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/{utils/Shared/Index.vue_vue_type_script_setup_true_lang-DKMVQrVU.js → modules/shared/Index.vue_vue_type_script_setup_true_lang-D9sq4n9i.js} +66 -60
  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-D7bJ5UAn.js → Index.vue_vue_type_script_setup_true_lang-DY3tZQZe.js} +63 -55
  27. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-D_73B6av.js +1533 -0
  28. package/buildLibs/modules/shared/{Validate.vue_vue_type_script_setup_true_lang-3s_3ut9M.js → Validate.vue_vue_type_script_setup_true_lang-hn1Tat7L.js} +102 -92
  29. package/buildLibs/types/All/index.d.ts +1 -1
  30. package/buildLibs/types/Common/globalConfig.d.ts +29 -0
  31. package/buildLibs/types/Common/globalTypes.d.ts +11 -0
  32. package/buildLibs/types/Common/i18n/en.d.ts +2 -0
  33. package/buildLibs/types/Common/i18n/zh_CN.d.ts +2 -0
  34. package/buildLibs/types/Common/index.d.ts +1 -1
  35. package/buildLibs/types/Element/CheckBox/Index.vue.d.ts +9 -0
  36. package/buildLibs/types/Element/Input/Index.vue.d.ts +9 -0
  37. package/buildLibs/types/Element/InputNumber/Index.vue.d.ts +9 -0
  38. package/buildLibs/types/Element/InputNumberStepper/Index.vue.d.ts +9 -0
  39. package/buildLibs/types/Element/InputTextarea/Index.vue.d.ts +9 -0
  40. package/buildLibs/types/Element/Radio/Index.vue.d.ts +9 -0
  41. package/buildLibs/types/Web/DateTime/Index.vue.d.ts +9 -0
  42. package/buildLibs/types/Web/FileUpload/Index.vue.d.ts +9 -0
  43. package/buildLibs/types/Web/Select/Index.vue.d.ts +9 -0
  44. package/buildLibs/types/Web/SelectCascade/Index.vue.d.ts +9 -0
  45. package/buildLibs/types/Web/SelectMove/Index.vue.d.ts +9 -0
  46. package/buildLibs/types/Web/SelectTag/Index.vue.d.ts +9 -0
  47. package/buildLibs/types/Web/SelectTree/Index.vue.d.ts +9 -0
  48. package/buildLibs/types/Web/Tree/Index.vue.d.ts +9 -0
  49. package/buildLibs/types/Web/componentsInstalls.d.ts +90 -0
  50. package/buildLibs/utils/Element/ClCheckbox.cjs +1 -1
  51. package/buildLibs/utils/Element/ClCheckbox.js +1 -1
  52. package/buildLibs/utils/Element/ClInput.cjs +1 -1
  53. package/buildLibs/utils/Element/ClInput.js +1 -1
  54. package/buildLibs/utils/Element/ClInputCaptcha.cjs +1 -1
  55. package/buildLibs/utils/Element/ClInputCaptcha.js +1 -1
  56. package/buildLibs/utils/Element/ClInputNumber.cjs +1 -1
  57. package/buildLibs/utils/Element/ClInputNumber.js +1 -1
  58. package/buildLibs/utils/Element/ClInputNumberStepper.cjs +1 -1
  59. package/buildLibs/utils/Element/ClInputNumberStepper.js +1 -1
  60. package/buildLibs/utils/Element/ClInputPassword.cjs +1 -1
  61. package/buildLibs/utils/Element/ClInputPassword.js +1 -1
  62. package/buildLibs/utils/Element/ClInputSearch.cjs +1 -1
  63. package/buildLibs/utils/Element/ClInputSearch.js +1 -1
  64. package/buildLibs/utils/Element/ClInputTextarea.cjs +1 -1
  65. package/buildLibs/utils/Element/ClInputTextarea.js +1 -1
  66. package/buildLibs/utils/Element/ClRadio.cjs +1 -1
  67. package/buildLibs/utils/Element/ClRadio.js +1 -1
  68. package/buildLibs/utils/Element/__provide__/Validate.cjs +1 -1
  69. package/buildLibs/utils/Element/__provide__/Validate.js +13 -3
  70. 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
  71. 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
  72. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-2THK822S.js +254 -0
  73. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BO4cal3i.js → Index.vue_vue_type_script_setup_true_lang-2dwwjiTV.js} +386 -375
  74. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-5itnjwU_.js +1 -0
  75. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-ChnRq_PS.js → Index.vue_vue_type_script_setup_true_lang-B0MJO0JM.js} +2 -2
  76. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BIO6Me43.js +1 -0
  77. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BN9ybiKv.js +1 -0
  78. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BpG7AHvM.js +1 -0
  79. package/buildLibs/{modules/shared/Index.vue_vue_type_script_setup_true_lang-CAe8mhTl.js → utils/Shared/Index.vue_vue_type_script_setup_true_lang-CATwJnes.js} +66 -60
  80. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CW4fM0by.js +1 -0
  81. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-DxYJbPyJ.js → Index.vue_vue_type_script_setup_true_lang-C_exHzjc.js} +3 -3
  82. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CsCn637u.js +2 -0
  83. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-D_XMW7K4.js → Index.vue_vue_type_script_setup_true_lang-D4a5Iaue.js} +153 -145
  84. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DXPZYc0c.js +1 -0
  85. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DY4m6Xyj.js +1 -0
  86. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DZCt32jb.js +1533 -0
  87. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DZF2gj7X.js +2536 -0
  88. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-De1eNjwC.js +1 -0
  89. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-C6Evk0-z.js → Index.vue_vue_type_script_setup_true_lang-DtAy8lm9.js} +53 -47
  90. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DvN-fBNd.js +1 -0
  91. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DwBf338f.js +1 -0
  92. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Cg_benGj.js → Index.vue_vue_type_script_setup_true_lang-F9tBnc_7.js} +63 -55
  93. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-HfnOtuMz.js +310 -0
  94. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Dwkuei2j.js → Index.vue_vue_type_script_setup_true_lang-VjIva6RM.js} +1 -1
  95. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-j7gxlOeM.js +1 -0
  96. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CgdGs-U2.js → Index.vue_vue_type_script_setup_true_lang-lKDQFZtY.js} +67 -59
  97. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-Dzm58mMQ.js → Index.vue_vue_type_script_setup_true_lang-nAMiORzN.js} +1 -1
  98. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-CizRrQsH.js → Index.vue_vue_type_script_setup_true_lang-oovIcT38.js} +1 -1
  99. package/buildLibs/utils/Shared/{Index.vue_vue_type_script_setup_true_lang-BIFHYrzc.js → Index.vue_vue_type_script_setup_true_lang-qqnmaRnk.js} +1 -1
  100. package/buildLibs/utils/Web/ClColorPicker.cjs +1 -1
  101. package/buildLibs/utils/Web/ClColorPicker.js +1 -1
  102. package/buildLibs/utils/Web/ClCropperPreview.cjs +1 -1
  103. package/buildLibs/utils/Web/ClCropperPreview.js +1 -1
  104. package/buildLibs/utils/Web/ClDateTime.cjs +1 -1
  105. package/buildLibs/utils/Web/ClDateTime.js +1 -1
  106. package/buildLibs/utils/Web/ClFileUpload.cjs +1 -1
  107. package/buildLibs/utils/Web/ClFileUpload.js +1 -1
  108. package/buildLibs/utils/Web/ClInputTag.cjs +1 -1
  109. package/buildLibs/utils/Web/ClInputTag.js +1 -1
  110. package/buildLibs/utils/Web/ClPaginate.cjs +1 -1
  111. package/buildLibs/utils/Web/ClPaginate.js +1 -1
  112. package/buildLibs/utils/Web/ClSelect.cjs +1 -1
  113. package/buildLibs/utils/Web/ClSelect.js +1 -1
  114. package/buildLibs/utils/Web/ClSelectCascade.cjs +1 -1
  115. package/buildLibs/utils/Web/ClSelectCascade.js +1 -1
  116. package/buildLibs/utils/Web/ClSelectMove.cjs +1 -1
  117. package/buildLibs/utils/Web/ClSelectMove.js +655 -647
  118. package/buildLibs/utils/Web/ClSelectTag.cjs +1 -1
  119. package/buildLibs/utils/Web/ClSelectTag.js +1 -1
  120. package/buildLibs/utils/Web/ClSelectTree.cjs +1 -1
  121. package/buildLibs/utils/Web/ClSelectTree.js +71 -63
  122. package/buildLibs/utils/Web/ClTable.cjs +1 -1
  123. package/buildLibs/utils/Web/ClTable.js +1 -1
  124. package/buildLibs/utils/Web/ClTree.cjs +1 -1
  125. package/buildLibs/utils/Web/ClTree.js +1 -1
  126. package/buildLibs/utils/Web/ClXEditable.cjs +1 -1
  127. package/buildLibs/utils/Web/ClXEditable.js +10 -10
  128. package/buildLibs/web/index.cjs +7 -7
  129. package/buildLibs/web/index.js +10792 -10685
  130. package/docs/components/Element/Checkbox.md +2 -1
  131. package/docs/components/Element/Form.md +15 -0
  132. package/docs/components/Element/Input.md +2 -1
  133. package/docs/components/Element/InputNumber.md +2 -1
  134. package/docs/components/Element/InputNumberStepper.md +2 -1
  135. package/docs/components/Element/InputTextarea.md +2 -1
  136. package/docs/components/Element/Radio.md +2 -1
  137. package/docs/components/Web/DateTime.md +2 -1
  138. package/docs/components/Web/FileUpload.md +2 -1
  139. package/docs/components/Web/Select.md +2 -1
  140. package/docs/components/Web/SelectCascade.md +1 -0
  141. package/docs/components/Web/SelectMove.md +2 -1
  142. package/docs/components/Web/SelectTag.md +1 -0
  143. package/docs/components/Web/SelectTree.md +2 -1
  144. package/docs/components/Web/Tree.md +2 -1
  145. package/package.json +1 -1
  146. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-CiNidFJt.js +0 -246
  147. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-DC6727pS.js +0 -2528
  148. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-EXqjkKwS.js +0 -302
  149. package/buildLibs/modules/shared/Index.vue_vue_type_script_setup_true_lang-Hg16dgRQ.js +0 -1527
  150. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-5aX79Fcf.js +0 -1
  151. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BRvOcf4B.js +0 -1
  152. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Ba8Z8fOP.js +0 -1
  153. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-BjNP5odR.js +0 -1
  154. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CQ3RGLek.js +0 -302
  155. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CY5fRV6o.js +0 -1
  156. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CYN4r-Mx.js +0 -1
  157. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-C_7ArHlU.js +0 -1
  158. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CuJjJvft.js +0 -2
  159. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-CwjigRBx.js +0 -2528
  160. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-D6cmq0Tf.js +0 -1527
  161. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-Dbf-3Nik.js +0 -1
  162. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-DgD_gHit.js +0 -1
  163. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-FowII7_3.js +0 -1
  164. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-c7oxeU_j.js +0 -246
  165. package/buildLibs/utils/Shared/Index.vue_vue_type_script_setup_true_lang-vLqCsSbV.js +0 -1
@@ -1 +1 @@
1
- "use strict";const e=require("vue"),Fe=require("@cldemo/ui-kit/common/log"),i=require("@cldemo/ui-kit/common/base"),V=require("@cldemo/ui-kit/common/Element"),it=require("@cldemo/ui-kit/common/Element/Event"),rt=require("../Shared/One.vue_vue_type_script_setup_true_lang-D9zWNf0s.js"),ct=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CFZ5jK-q.js"),dt=require("../Shared/index-q2CbfC2a.js"),Wt=require("../Shared/One.vue_vue_type_script_setup_true_lang-CGNfuoKE.js"),nt=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CZNVHUR1.js"),Pt=require("../Shared/language-BJ4aVgHI.js"),$t=require("../Shared/Ing.vue_vue_type_script_setup_true_lang-DaWKYdkt.js"),Mt=require("../Shared/Index.vue_vue_type_script_setup_true_lang-Dzm58mMQ.js"),at=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DBrrIpHb.js");;/* empty css */const ut=l=>{if(i.isNonEmptyString(l)){if(l.indexOf("clIcon-")===0){const m=l.substring(7);return i.isNonEmptyString(m)&&/^[a-zA-Z0-9-]+$/.test(m)?{name:m,className:""}:{name:"question-circle",className:""}}return/^clicon/i.test(l)?{name:"question-circle",className:""}:/^[a-zA-Z0-9-]+$/.test(l)?{name:l,className:""}:{name:"",className:l}}return{name:"question-circle",className:""}},At=["aria-sort"],Ht=e.defineComponent({name:"ClTableTh",directives:{cltooltip:dt.tooltipDirectives},__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:(l,m,x)=>!0},setup(l,{emit:m}){const x=l,n=m,I=e.computed(()=>ut(x.thInfo?.tipIcon)),w=e.computed(()=>i.isObject(x.thInfo)&&!i.isEmpty(x.thInfo)?x.thInfo:{}),A=e.computed(()=>!x.isOrder||i.isEmpty(w.value)?!1:i.isEmpty(w.value.sort)?!0:w.value.sort===!0),E=e.computed(()=>A.value&&!x.disabled),S=e.computed(()=>{const g=x.thInfo?.tipMsg;if(!i.isNonEmptyString(g))return;const k=i.removeHTMLTags(g);return i.isNonEmptyString(k)?k:void 0}),s=e.computed(()=>{if(!A.value)return"";const g=i.isEmpty(x.orderSort)?[]:x.orderSort;return g.length>0&&g[0]===x.thIndex?g.length===2?g[1]==="asc"||g[1]==="desc"?g[1]:"none":g.length===1?"desc":"none":"none"}),B=e.computed(()=>{if(s.value==="asc")return"ascending";if(s.value==="desc")return"descending";if(s.value==="none")return"none"}),X=e.computed(()=>{const g={},k=w.value;if(!i.isEmpty(k.width)&&z(k.width)&&(g[`${x.widthClassPrefix}${k.width}`]=!0),!i.isEmpty(k.widthMin)&&z(k.widthMin)&&x.isUseScrollX&&(g[`${x.widthMinClassPrefix}${k.widthMin}`]=!0),(x.fixedLeftIndex>-1||x.fixedRightIndex>-1)&&(g["th-hidden"]=x.fixedLeftIndex>-1&&x.thIndex>x.fixedLeftIndex||x.fixedRightIndex>-1&&x.thIndex<x.fixedRightIndex),A.value){g["th-sort"]=!0,g["sort-none"]=!0,g["th-sort-near"]=k.sortNear===!0;const j=s.value;(j==="asc"||j==="desc")&&(g[`sort-${j}`]=!0,g["sort-none"]=!1)}i.isNonEmptyString(k.tipMsg)&&(g["th-tip"]=!0,g["th-tip-sideAlign"]=k.tipSideAlign===!0),x.disabled&&(g["th-disabled"]=!0),i.isNonEmptyString(k.textAlign)&&i.isExistValue(["left","center","right"],k.textAlign)&&(g[`text-${k.textAlign}`]=!0);let W=g;return W=i.getJsonMerge(W,V.getClassNameJson(k.className)),W=i.getJsonMerge(W,V.getClassNameJson(k.classTh)),W}),Z=e.computed(()=>{const g={};if(!x.isInlineWidth)return g;const k=w.value;return!i.isEmpty(k.width)&&z(k.width)&&(g.width=i.isFinite(Number(k.width))?`${Number(k.width)}px`:`${k.width}`),!i.isEmpty(k.widthMin)&&z(k.widthMin)&&x.isUseScrollX&&(g.minWidth=i.isFinite(Number(k.widthMin))?`${Number(k.widthMin)}px`:`${k.widthMin}`),g}),Y=(g,k)=>{n("onClickOrderBy",g,x.thIndex,k)},z=g=>i.isString(g)||i.getTypeof(g)==="number"&&i.isFinite(g),$=()=>{if(E.value){const g=s.value==="desc"?"asc":"desc";Y(w.value,g)}};return(g,k)=>{const W=e.resolveDirective("cltooltip");return!e.unref(i).isBoolean(l.thInfo?.visible)||l.thInfo.visible?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass(X.value),style:e.normalizeStyle(Z.value),scope:"col","aria-sort":B.value},[e.createElementVNode("span",{class:"th-title",onClick:$},[e.renderSlot(g.$slots,"default")]),e.unref(i).isNonEmptyString(l.thInfo?.tipMsg)?e.withDirectives((e.openBlock(),e.createBlock(ct._sfc_main,{key:0,name:I.value.name,className:I.value.className,class:"th-tip-icon",role:"img","aria-label":S.value},null,8,["name","className","aria-label"])),[[W,{html:l.thInfo.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),s.value!==""?(e.openBlock(),e.createElementBlock("i",{key:2,class:"tr-sort-icon","aria-hidden":"true",onClick:$})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],14,At)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}}),Ue=e.defineComponent({name:"ClTableTd",directives:{cltooltip:dt.tooltipDirectives},__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:l=>["td","total"].indexOf(l)>-1}},setup(l){const m=l,x=e.computed(()=>ut(m.tdInfo?.tipIcon)),n=e.computed(()=>i.isEmpty(m.tdInfo)?{}:m.tdInfo),I=e.computed(()=>{const S=m.tdInfo?.tipMsg;if(!i.isNonEmptyString(S))return;const s=i.removeHTMLTags(S);return i.isNonEmptyString(s)?s:void 0}),w=e.computed(()=>{const S={},s=n.value;!i.isEmpty(s.width)&&E(s.width)&&(S[`${m.widthClassPrefix}${s.width}`]=!0),!i.isEmpty(s.widthMin)&&E(s.widthMin)&&m.isUseScrollX&&(S[`${m.widthMinClassPrefix}${s.widthMin}`]=!0),(m.fixedLeftIndex>-1||m.fixedRightIndex>-1)&&(S["td-hidden"]=m.fixedLeftIndex>-1&&m.tdIndex>m.fixedLeftIndex||m.fixedRightIndex>-1&&m.tdIndex<m.fixedRightIndex),m.isOrder&&(i.isEmpty(s.sort)||s.sort===!0)&&(S["td-sort"]=!0,S["td-sort-near"]=s.sortNear===!0),i.isNonEmptyString(s.tipMsg)&&(S["td-tip"]=!0,S["td-tip-sideAlign"]=s.tipSideAlign===!0),i.isNonEmptyString(s.textAlign)&&i.isExistValue(["left","center","right"],s.textAlign)&&(S[`text-${s.textAlign}`]=!0);let B=S;return B=i.getJsonMerge(B,V.getClassNameJson(s.className)),m.useType==="td"?B=i.getJsonMerge(B,V.getClassNameJson(s.classTd)):m.useType==="total"&&(B=i.getJsonMerge(B,V.getClassNameJson(s.classTotal))),B}),A=e.computed(()=>{const S={};if(!m.isInlineWidth)return S;const s=n.value;return!i.isEmpty(s.width)&&E(s.width)&&(S.width=i.isFinite(Number(s.width))?`${Number(s.width)}px`:`${s.width}`),!i.isEmpty(s.widthMin)&&E(s.widthMin)&&m.isUseScrollX&&(S.minWidth=i.isFinite(Number(s.widthMin))?`${Number(s.widthMin)}px`:`${s.widthMin}`),S}),E=S=>i.isString(S)||i.getTypeof(S)==="number"&&i.isFinite(S);return(S,s)=>{const B=e.resolveDirective("cltooltip");return!e.unref(i).isBoolean(l.tdInfo?.visible)||l.tdInfo.visible?(e.openBlock(),e.createElementBlock("td",{key:0,class:e.normalizeClass(w.value),style:e.normalizeStyle(A.value)},[e.renderSlot(S.$slots,"default"),e.unref(i).isNonEmptyString(l.tdInfo?.tipMsg)?e.withDirectives((e.openBlock(),e.createBlock(ct._sfc_main,{key:0,name:x.value.name,className:x.value.className,class:"td-tip-icon",role:"img","aria-label":I.value},null,8,["name","className","aria-label"])),[[B,{html:l.tdInfo.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}}),Ft=["aria-hidden"],Dt={key:0},Vt={key:0},De=99999999,Ve=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:l=>["","left","right"].indexOf(l)>-1},fixedLeftIndex:{type:Number,default:-1,validator:l=>l>=-1},fixedRightIndex:{type:Number,default:-1,validator:l=>l>=-1},isInlineWidth:{type:Boolean,default:!1},widthClassPrefix:{type:String,default:"width-"},widthMinClassPrefix:{type:String,default:"width-min-"}},emits:{onClickAll:()=>!0,onClickOrderBy:(l,m,x)=>!0,onHoverIn:l=>!0,onHoverOut:()=>!0},setup(l,{expose:m,emit:x}){const n=l,I=x,w=e.useTemplateRef("refElTable"),A=e.computed(()=>({"table-default":!0,"table-base":!0})),E=e.computed(()=>{const h={};return i.isEmpty(n.fixedType)?n.isUseScrollX&&i.isNonEmptyString(n.minWidth)&&n.minWidth!=="none"&&(h.minWidth=n.minWidth):i.isNonEmptyString(n.width)&&n.width!=="none"&&(h.width=n.width),h}),S=h=>h?i.isUndefined(h.title)?i.isUndefined(h.data)?"":h.data:h.title:"",s=(h,v)=>i.isUndefined(h)||!v?"":i.isEmpty(v.format)?h:i.getValueByFormat(h,v.format??"",v.formatExt),B=(h,v)=>!h||!v?"":s(h[v.data],v);e.watch(()=>n.isShowTotal,h=>{!h&&n.hoverIndex===De&&I("onHoverOut")});const X=()=>{I("onClickAll")},Z=(h,v,O)=>{I("onClickOrderBy",h,v,O)},Y=()=>{I("onHoverIn",De)},z=()=>{I("onHoverOut")};return m({getOffsetHeight:()=>w.value?w.value.offsetHeight:0,getRcWidth:()=>{let h=0;if((n.isShowRadio||n.isShowCheckbox)&&w.value){const v=w.value.querySelector(".th-rc");v&&(h=v.clientWidth)}return h},getPaddingLr:()=>{let h=0;if(!w.value)return h;const v=w.value.querySelectorAll("th:not(.th-rc)");for(let O=0;O<v.length;O++){const d=V.getStyle(v[O]),T=parseFloat(d.paddingLeft),q=parseFloat(d.paddingRight),_=i.isFinite(T)?T:0,K=i.isFinite(q)?q:0;h+=_+K}return h},getElTh:()=>w.value?w.value.querySelectorAll("th"):[],getTotalHeight:()=>{let h=0;if(n.isShowTotal&&w.value){const v=w.value.querySelector(".tr-total");v&&(h=v.clientHeight)}return h}}),(h,v)=>(e.openBlock(),e.createElementBlock("table",{class:e.normalizeClass(A.value),style:e.normalizeStyle(E.value),"aria-hidden":!e.unref(i).isEmpty(l.fixedType),ref_key:"refElTable",ref:w},[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[l.isShowRadio||l.isShowCheckbox?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass({"th-rc":!0,"th-hidden":l.fixedRightIndex>-1}),scope:"col"},[l.isShowCheckbox&&l.isShowCheckboxAll?(e.openBlock(),e.createBlock(rt._sfc_main,{key:0,forId:e.unref(i).isNonEmptyString(l.keyIndex)?`${l.keyIndex}_${l.fixedType}_cb_all`:void 0,value:l.checkboxAllValue,disabled:l.disabled,onOnChange:X},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(l.columns,(O,d)=>(e.openBlock(),e.createBlock(Ht,{key:`${l.keyIndex}_${l.fixedType}_head_th_${d}`,thInfo:O,thIndex:d,isOrder:l.isOrder,disabled:l.disabled,orderSort:l.orderSort,isUseScrollX:l.isUseScrollX,fixedLeftIndex:l.fixedLeftIndex,fixedRightIndex:l.fixedRightIndex,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickOrderBy:Z},{default:e.withCtx(()=>[e.renderSlot(h.$slots,`th_${O?.data??""}`,{data:O},()=>[e.createElementVNode("span",null,e.toDisplayString(S(O)),1)])]),_:2},1032,["thInfo","thIndex","isOrder","disabled","orderSort","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))])]),l.isShowTotal?(e.openBlock(),e.createElementBlock("tbody",Dt,[e.createElementVNode("tr",{class:e.normalizeClass({"tr-total":!0,"tr-hover":l.hoverIndex===De}),onMouseenter:Y,onMouseleave:z},[l.isShowRadio||l.isShowCheckbox?(e.openBlock(),e.createElementBlock("td",Vt)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.columns,(O,d)=>(e.openBlock(),e.createBlock(Ue,{key:`${l.keyIndex}_${l.fixedType}_body_total_td_${d}`,isOrder:l.isOrder,tdIndex:d,tdInfo:O,isUseScrollX:l.isUseScrollX,fixedLeftIndex:l.fixedLeftIndex,fixedRightIndex:l.fixedRightIndex,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,useType:"total"},{default:e.withCtx(()=>[e.renderSlot(h.$slots,`total_${O?.data??""}`,{data:l.totalInfo},()=>[e.createTextVNode(e.toDisplayString(B(l.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,Ft))}}),Xt=["id"],Ut=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(l){const m=l,x=m.id,n=e.computed(()=>S("cb")),I=e.computed(()=>S("rd")),w=e.computed(()=>m.value===!0),A=e.computed(()=>m.disabled===!0||i.isBoolean(m.info?.isDisabled)&&m.info.isDisabled),E=e.computed(()=>{const s={"th-rc":!0};return i.getJsonMerge(s,V.getClassNameJson(m.className))}),S=s=>i.isNonEmptyString(m.keyIndex)?`${m.keyIndex}_${s}`:void 0;return(s,B)=>l.isShowRadio||l.isShowCheckbox?(e.openBlock(),e.createElementBlock("td",{key:0,id:e.unref(x),class:e.normalizeClass(E.value)},[l.isShowCheckbox?(e.openBlock(),e.createBlock(rt._sfc_main,{key:0,forId:n.value,value:w.value,disabled:A.value},null,8,["forId","value","disabled"])):l.isShowRadio?(e.openBlock(),e.createBlock(Wt._sfc_main,{key:1,forId:I.value,name:I.value,value:w.value,disabled:A.value},null,8,["forId","name","value","disabled"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))],10,Xt)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}),zt=["onClick","onMouseenter"],qt=["onMouseenter"],Jt=["colspan"],Yt={key:0,class:"panel-elastic-load",role:"status","aria-live":"polite"},jt={class:"elastic-load-container"},Kt=["data-elastic-id"],Gt=["onMouseenter"],Zt=["colspan"],Qt={class:"panel-elastic-load",role:"status","aria-live":"polite"},_t={class:"elastic-load-container"},el=["onMouseenter"],tl={key:2},ll=["colspan"],il={class:"panel-table-empty",role:"status"},Xe=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:l=>["default","sameDataStructure"].indexOf(l)>-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:(l,m,x)=>!0,onHoverIn:(l,m)=>!0,onHoverOut:()=>!0},setup(l,{expose:m,emit:x}){const n=l,I=x,{optPageLanguage:w,getPageLanguage:A}=Pt.useLanguage();A("common");const E=e.useTemplateRef("refElTable"),S=e.ref(new Set),s=e.computed(()=>new Set((Array.isArray(n.selectValue)?n.selectValue:[]).filter(c=>!i.isUndefined(c)).map(c=>String(c)))),B=e.computed(()=>new Set((Array.isArray(n.elasticLoading)?n.elasticLoading:[]).filter(c=>!i.isUndefined(c)).map(c=>String(c)))),X=e.computed(()=>new Set((Array.isArray(n.elasticOpen)?n.elasticOpen:[]).filter(c=>!i.isUndefined(c)).map(c=>String(c)))),Z=e.computed(()=>{const c=Number(n.colspanCount);return i.isFinite(c)&&c>=1?Math.floor(c):1}),Y=e.computed(()=>({"table-default":!0,"table-base":!0,"table-empty":i.isEmpty(n.list)})),z=e.computed(()=>{const c={};return i.isNonEmptyString(n.fixedType)?i.isNonEmptyString(n.width)&&n.width!=="none"&&(c.width=n.width):n.isUseScrollX&&i.isNonEmptyString(n.minWidth)&&n.minWidth!=="none"&&(c.minWidth=n.minWidth),c}),$=(c,C,y)=>{I("onClickTr",c,C,y)},g=(c,C=-1)=>{I("onHoverIn",c,C)},k=()=>{I("onHoverOut")},W=(c,C)=>i.isEmpty(c)||!C?"":i.isEmpty(C.format)?c:i.getValueByFormat(c,C.format??"",C.formatExt),j=c=>{const C=n.elasticData||{};return Object.prototype.hasOwnProperty.call(C,c)?C[c]:[]},h=c=>!i.isEmpty(c)&&!i.isEmpty(c.id)&&s.value.has(c.id.toString()),v=c=>!i.isEmpty(c)&&!i.isEmpty(c.id)&&B.value.has(c.id.toString());return m({getWidth:()=>E.value?E.value.clientWidth:0,getHeight:()=>E.value?E.value.clientHeight:0,setElasticWidth:()=>{if(!E.value)return;const c=E.value.parentNode;if(!c)return;const C=E.value.querySelectorAll(".panel-elastic-load"),y=c.clientWidth;for(let p=0;p<C.length;p++)C[p].style.width=`${y}px`},setElasticHeight:c=>{if(!E.value)return;const C=E.value.querySelector(`[data-elastic-id="${CSS.escape(c)}"]`);if(C){const y=C.parentNode;if(y){C.style.height="",y.style.height="";const L=`${C.clientHeight}px`;C.style.height=L,y.style.height=L}const p=S.value;p.has(c)||(S.value=new Set(p).add(c))}},removeElasticAbsolute:c=>{if(S.value.has(c)){const C=new Set(S.value);C.delete(c),S.value=C}},clearElasticAbsolute:()=>{S.value.size>0&&(S.value=new Set)},setElasticLoadLeft:c=>{if(!E.value)return;const C=E.value.querySelectorAll(".panel-elastic-load"),y=i.isFinite(c)?Math.max(0,c):0;for(let p=0;p<C.length;p++)C[p].style.left=`${y}px`},setEmptyWidth:()=>{if(!E.value)return;const c=E.value.querySelector(".panel-table-empty");if(c){const C=E.value.parentNode;if(C){const y=C.clientWidth;c.style.width=`${y}px`}}},setEmptyLeft:c=>{const C=E.value?E.value.querySelector(".panel-table-empty"):null;if(C){const y=i.isFinite(c)?Math.max(0,c):0;C.style.left=`${y}px`}}}),(c,C)=>(e.openBlock(),e.createElementBlock("table",{class:e.normalizeClass(Y.value),style:e.normalizeStyle(z.value),ref_key:"refElTable",ref:E},[e.createElementVNode("tbody",null,[e.unref(i).isEmpty(l.list)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(l.list,(y,p)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${l.keyIndex}_${l.fixedType}_body_tr_${p}`},[e.createElementVNode("tr",{class:e.normalizeClass({odd:l.isStriped&&p%2===0,"tr-customInterval-odd":l.isStriped&&l.trIntervalNum>0&&Math.floor(p/l.trIntervalNum)%2===0,"tr-customInterval-even":l.isStriped&&l.trIntervalNum>0&&Math.floor(p/l.trIntervalNum)%2===1,"tr-disabled":e.unref(i).isBoolean(y?.isDisabled)&&y.isDisabled,"tr-selected":h(y),"tr-hover":l.hoverIndex===p}),onClick:L=>$(L,y,p),onMouseenter:L=>g(p),onMouseleave:k},[l.isShowRadio||l.isShowCheckbox?(e.openBlock(),e.createBlock(Ut,{key:0,keyIndex:`${l.keyIndex}_${l.fixedType}_body_tr_${p}`,isShowRadio:l.isShowRadio,isShowCheckbox:l.isShowCheckbox,value:h(y),info:y,disabled:l.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(l.columns,(L,R)=>(e.openBlock(),e.createBlock(Ue,{key:`${l.keyIndex}_${l.fixedType}_body_tr_${p}_td_${R}`,isOrder:l.isOrder,tdIndex:R,tdInfo:L,isUseScrollX:l.isUseScrollX,fixedLeftIndex:l.fixedLeftIndex,fixedRightIndex:l.fixedRightIndex,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix},{default:e.withCtx(()=>[e.renderSlot(c.$slots,`td_${L?.data??""}`,{data:y,trIndex:p},()=>[e.createTextVNode(e.toDisplayString(W(y&&L?y[L.data]:void 0,L)),1)])]),_:2},1032,["isOrder","tdIndex","tdInfo","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))],42,zt),l.isElastic&&!e.unref(i).isEmpty(y?.id)&&X.value.has(y.id.toString())?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[l.elasticType==="default"?(e.openBlock(),e.createElementBlock("tr",{key:0,class:e.normalizeClass({"tr-elastic":!0,"tr-hover":l.hoverIndex===p}),onMouseenter:L=>g(p),onMouseleave:k},[e.createElementVNode("td",{colspan:Z.value,class:e.normalizeClass({"td-elastic-load":v(y)})},[v(y)?(e.openBlock(),e.createElementBlock("div",Yt,[e.createElementVNode("div",jt,[e.createVNode(nt._sfc_main,{theme:"circleBubble",size:"large"})])])):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["elastic-container",{"elastic-container-absolute":S.value.has(y.id.toString())}]),"data-elastic-id":y.id},[e.renderSlot(c.$slots,"tr_elastic_children",{data:y,trIndex:p})],10,Kt))],10,Jt)],42,qt)):l.elasticType==="sameDataStructure"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[v(y)?(e.openBlock(),e.createElementBlock("tr",{key:0,class:e.normalizeClass({"tr-elastic":!0,"tr-hover":l.hoverIndex===p}),onMouseenter:L=>g(p),onMouseleave:k},[e.createElementVNode("td",{colspan:Z.value,class:"td-elastic-load"},[e.createElementVNode("div",Qt,[e.createElementVNode("div",_t,[e.createVNode(nt._sfc_main,{theme:"circleBubble",size:"large"})])])],8,Zt)],42,Gt)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(j(y.id.toString()),(L,R)=>(e.openBlock(),e.createElementBlock("tr",{key:`${l.keyIndex}_${l.fixedType}_body_tr_${p}_elastic_${R}`,class:e.normalizeClass({"tr-elastic-sameDataStructure":!0,odd:l.isStriped&&R%2===0,"tr-disabled":e.unref(i).isBoolean(L?.isDisabled)&&L.isDisabled,"tr-hover":l.hoverElasticIndex===R&&l.hoverIndex===p}),onMouseenter:H=>g(p,R),onMouseleave:k},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.columns,(H,ae)=>(e.openBlock(),e.createBlock(Ue,{key:`${l.keyIndex}_${l.fixedType}_body_tr_${p}_elastic_${R}_td_${ae}`,isOrder:l.isOrder,tdIndex:ae,tdInfo:H,isUseScrollX:l.isUseScrollX,fixedLeftIndex:l.fixedLeftIndex,fixedRightIndex:l.fixedRightIndex,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix},{default:e.withCtx(()=>[e.renderSlot(c.$slots,`td_elastic_${H?.data??""}`,{data:L,trIndex:p,trElasticInx:R},()=>[e.createTextVNode(e.toDisplayString(W(L&&H?L[H.data]:void 0,H)),1)])]),_:2},1032,["isOrder","tdIndex","tdInfo","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))],42,el))),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(i).isEmpty(l.list)&&!l.isRunLoading&&!e.unref(i).isNonEmptyString(l.fixedType)?(e.openBlock(),e.createElementBlock("tr",tl,[e.createElementVNode("td",{colspan:Z.value,class:"td-empty"},[e.createElementVNode("div",il,e.toDisplayString(e.unref(i).isNonEmptyString(l.emptyText)?l.emptyText:e.unref(w).noResultsText),1)],8,ll)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])],6))}});function nl(l){if(!Array.isArray(l))return[];const m=[];return l.forEach(x=>{if(i.isEmpty(x))return;const n=x;!(i.isBoolean(n.isDisabled)?n.isDisabled:!1)&&!i.isEmpty(n.id)&&m.push(String(n.id))}),m}function al(l,m,x=!1){if(!Array.isArray(l)||l.length===0)return[];const n=[];return l.forEach(I=>{const w=String(I);m.includes(w)&&n.push(w)}),x&&n.length>1?[n[0]]:n}function ol(l,m){return m.length>0&&m.length===l.length}function sl(l,m){return l.filter(x=>!m.includes(x))}const rl=["id"],cl={class:"table-wrapper"},dl={key:0,class:"table-fixed-column-left"},ul={key:2,class:"table-fixed-column-right"},fl={key:0,class:"table-scroll-occupy-container"},hl={key:2,class:"table-fixed-column-scrollX"},ml={key:4,class:"table-fixed-head-load"},gl={key:0,class:"table-fixed-column-left"},yl={key:2,class:"table-fixed-column-right"},vl={key:1,class:"table-fixed-column-scrollX"},xl={key:2,class:"table-footer-wrapper"},Sl={key:0,class:"table-load",role:"status","aria-live":"polite"},kl={class:"table-load-wrapper"},ot=15,pl=30,Cl=180,wl=50,st=300,El=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:l=>["none","radio","checkbox"].indexOf(l)>-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:l=>["default","sameDataStructure"].indexOf(l)>-1},elasticData:{type:Object,default:()=>({})},trIntervalNum:{type:Number,default:-1},isStriped:{type:Boolean,default:!1},emptyText:String,isHead:{type:Boolean,default:!0}},emits:{onGetData:l=>!0,onClickRow:(l,m,x)=>!0,onClickElastic:(l,m,x,n,I)=>!0,onChangeChecked:(l,m,x)=>!0,onChangeParams:l=>!0},setup(l,{expose:m,emit:x}){const n=l,I=x,w=e.useSlots(),A=t=>{let a=[];if(n.isOrder){const o=i.isEmpty(t)?[]:t;let r=[0,"desc"];const u=i.isEmpty(n.columns)?[]:n.columns;for(let f=0;f<u.length;f+=1){const b=u[f];if(i.isEmpty(b))continue;const M=b.sort===void 0||b.sort===null?!0:b.sort===!0,N=i.isBoolean(b.visible)?b.visible:!0;if(M&&N){r=[f,"desc"];break}}if(o.length===0)a=r;else{const f=u[o[0]];if(i.isEmpty(f))a=r;else{const b=f.sort===void 0||f.sort===null?!0:f.sort===!0,M=i.isBoolean(f.visible)?f.visible:!0,N=Array.isArray(o)?o[0]:void 0,te=Array.isArray(o)&&(o[1]==="asc"||o[1]==="desc")?o[1]:void 0;a=b&&M&&!i.isUndefined(N)?[N,te??"desc"]:r}}}return a},E=()=>{let t=1;return n.paginateLimit>0&&n.pageOffset>=0&&(t=Math.floor(n.pageOffset/n.paginateLimit)+1),t},S=A(n.orderSort),s={dataJson:i.getJsonByList(n.list),changeNewPaginate:{pages:E(),limit:n.paginateLimit},changeNewSort:{orderIndex:S[0],orderBy:S[1]},sortLocalData:[],scrollBody:{left:0},scrollHead:{left:0},resizeEvent:null,timerBody:null,pendingCanceled:!1},B={observerBodyScrollY:null},X=`table-${i.getRandom(5)}`,Z=n.id,Y=e.useTemplateRef("refElHeadWrapper"),z=e.useTemplateRef("refElHeadContainer"),$=e.useTemplateRef("refElHeadMain"),g=e.useTemplateRef("refElHeadTable"),k=e.useTemplateRef("refElHeadFixedScrollX"),W=e.useTemplateRef("refElBodyWrapper"),j=e.useTemplateRef("refElBodyContainer"),h=e.useTemplateRef("refElBodyMain"),v=e.useTemplateRef("refElBodyTable"),O=e.useTemplateRef("refElBodyFixedScrollX"),d=e.reactive({isRunLoading:!1,isCheckedRadio:n.checkedRowType==="radio",isCheckedCheckbox:n.checkedRowType==="checkbox",colspanCount:0,hoverTrIndex:-1,hoverTrElasticIndex:-1,totalHeight:"0"}),T=e.ref([]),q=e.reactive({pages:s.changeNewPaginate.pages,limit:s.changeNewPaginate.limit}),_=e.ref(S),K=e.ref(!1),ce=()=>{const t=n.selectValue;return i.isNonEmptyString(t)?i.split(t):i.isNumber(t)?i.split(t.toString()):[]},U=e.ref(ce()),P=e.reactive({open:[],loading:[]}),c=e.reactive({isShow:!1,minWidth:"auto",posType:"left"}),C=e.ref(!1),y=e.reactive({totalWidth:"0",centerWidth:"0",leftColumnLength:0,leftWidth:"0",rightColumnLength:0,rightWidth:"0"}),p=e.reactive({isShow:!1,width:"auto",height:"auto"}),L=e.reactive({headHeight:0});let R=null,H=null,ae=0;const ve=e.computed(()=>Object.keys(w).filter(t=>t.indexOf("th_")===0)),xe=e.computed(()=>{const t=Object.keys(w).filter(a=>a.indexOf("td_")===0&&a.indexOf("td_elastic_")!==0);return n.isElastic&&t.push("tr_elastic_children"),t}),Se=e.computed(()=>Object.keys(w).filter(t=>t.indexOf("total_")===0)),ke=e.computed(()=>Object.keys(w).filter(t=>t.indexOf("td_elastic_")===0)),pe=e.computed(()=>n.isShowCheckboxAll&&T.value.length>0),oe=e.computed(()=>!i.isEmpty(n.totalData)&&T.value.length>0),ft=e.computed(()=>n.isServer?i.isFinite(n.totalLength)?n.totalLength:0:i.isFinite(n.totalLength)?n.totalLength:n.list?.length||0),J=e.computed(()=>n.isScrollX||n.isScrollXBottom),le=e.computed(()=>n.scrollY>0),F=e.computed(()=>n.isHead&&n.fixedColumnLeftIndex>-1&&J.value),D=e.computed(()=>n.isHead&&n.fixedColumnRightIndex>-1&&J.value&&n.fixedColumnRightIndex>n.fixedColumnLeftIndex+1),ht=e.computed(()=>{const t={"panel-table":!0,"table-disabled":n.disabled};return d.isRunLoading&&(t["table-loading"]=!0),i.osType().isMobile&&(t["table-mob"]=!0),i.getJsonMerge(t,V.getClassNameJson(n.className))}),mt=e.computed(()=>{const t={"table-head-wrapper":!0,"table-scrollY":le.value,"table-scroll-occupy-y":C.value};return p.isShow&&(t["table-fixed-head"]=!0),t}),gt=e.computed(()=>{const t={"table-head-container":!0};return n.isScrollX&&(t["table-scrollX"]=!0),(F.value||D.value)&&(t["table-fixed-column"]=!0,c.isShow?t[`table-scrollX-${c.posType}`]=!0:t["table-scrollX-none"]=!0),t}),yt=e.computed(()=>{const t={"table-body-wrapper":!0,"table-scrollY":le.value,"table-scrollX":n.isScrollX,"table-scrollX-bottom":c.isShow};return t["table-scroll-borderT0"]=c.isShow&&n.isScrollX,(F.value||D.value)&&(t["table-fixed-column"]=!0,c.isShow?t[`table-scrollX-${c.posType}`]=!0:t["table-scrollX-none"]=!0),t}),vt=e.computed(()=>{const t={};if((F.value||D.value)&&le.value){const a=c.isShow?Math.max(0,n.scrollY-ot):n.scrollY;t.maxHeight=`${a}px`}return t}),xt=e.computed(()=>{const t={};return F.value||D.value||le.value&&(t.maxHeight=`${n.scrollY}px`),t}),St=e.computed(()=>{const t={};return d.isRunLoading&&(t.height=`${L.headHeight}px`),t}),kt=t=>{I("onGetData",t)},pt=(t,a,o,r,u)=>{I("onClickElastic",t,a,o,r,u)},Ct=(t,a,o=!1)=>{I("onClickRow",t,a,o)},wt=(t,a,o)=>{I("onChangeChecked",t,a,o)},de=()=>{const t=me();I("onChangeParams",t)},Ce=()=>{e.nextTick(()=>{if($.value){const t=$.value.querySelector("thead");t&&(L.headHeight=t.offsetHeight)}}),d.isRunLoading=!0},ze=()=>{d.isRunLoading=!1},we=()=>{let t=0,a=0;(d.isCheckedRadio||d.isCheckedCheckbox)&&(t=1,g.value&&(a=g.value.getRcWidth())),(i.isEmpty(n.columns)?[]:n.columns).forEach(u=>{(i.isBoolean(u?.visible)?u.visible:!0)&&(t+=1,!i.isEmpty(u)&&!i.isEmpty(u.width)?a+=Number(u.width)||0:!i.isEmpty(u)&&!i.isEmpty(u.widthMin)&&(a+=Number(u.widthMin)||0))});const r=g.value?g.value.getPaddingLr():0;a+=r,d.colspanCount=t,J.value&&(c.minWidth=a>0?`${a}px`:"auto")},Ee=()=>new Promise((t,a)=>{e.nextTick(()=>{try{if(!v.value){t();return}const o=v.value.getWidth();y.totalWidth=`${o}px`;let r=o;if(F.value||D.value){const u=[],f=[];(i.isEmpty(n.columns)?[]:n.columns).forEach((G,re)=>{(i.isBoolean(G?.visible)?G.visible:!0)&&(F.value&&re<=n.fixedColumnLeftIndex&&u.push(G),D.value&&re>=n.fixedColumnRightIndex&&f.push(G))});const M=d.isCheckedRadio||d.isCheckedCheckbox,N=g.value?g.value.getElTh():[],te=N.length;let Q=u.length;const se=f.length;let lt=Q-1;const Rt=te-se;M&&(Q+=1,lt+=1);let Me=0,Ae=0;for(let G=0;G<te;G++){const re=N[G];if(!re)continue;const He=re.clientWidth;G<=lt&&(Me+=He),G>=Rt&&(Ae+=He)}F.value&&(y.leftColumnLength=u.length,y.leftWidth=`${Me}px`,r-=Me),D.value&&(y.rightColumnLength=f.length,y.rightWidth=`${Ae}px`,r-=Ae)}r=Math.max(0,r),y.centerWidth=`${r}px`,e.nextTick(()=>{t()})}catch(o){a(o)}})}),qe=()=>{e.nextTick(()=>{v.value&&v.value.setElasticWidth()})},Et=t=>{(F.value||D.value)&&v.value&&v.value.setElasticHeight(t)},Je=t=>{if(n.isElasticLoad){const a=i.getArrClone(P.loading);a.indexOf(t)===-1&&(a.push(t),P.loading=a)}},Ye=t=>{if(n.isElasticLoad){const a=i.getArrClone(P.loading),o=a.indexOf(t);o>-1&&(a.splice(o,1),P.loading=a,e.nextTick(()=>{Et(t)}))}},be=(t,a,o,r)=>{if(i.isEmpty(t)||i.isEmpty(t.id))return;const u=t.id.toString(),f=i.getArrClone(P.open),b=f.indexOf(u),M=b===-1;M?(f.push(u),Je(u)):(f.splice(b,1),Ye(u),(F.value||D.value)&&v.value&&v.value.removeElasticAbsolute(u)),It(o,M);const N=i.isBoolean(r)?r:!0;P.open=f,N&&pt(u,t,a,M,o),qe()},bt=()=>{const t=[],a=i.isEmpty(n.elasticIconCls)?[]:n.elasticIconCls;if(a.length===2){const o=T.value,r=P.open;o.forEach(u=>{if(!u){t.push(u);return}const f=i.getJsonClone(u);if(!i.isEmpty(f.id)){const b=f.id.toString();f._elasticIconCls=r.indexOf(b)>-1?a[1]:a[0]}t.push(f)})}t.length>0&&(T.value=t)},It=(t,a=!1)=>{if(t){const o=[],r=["elastic-expand","elastic-retract"];a?o.push("elastic-expand"):o.push("elastic-retract");const u=i.isEmpty(n.elasticIconCls)?[]:n.elasticIconCls;u.length===2&&(r.push(u[0]),r.push(u[1]),a?o.push(u[1]):o.push(u[0]));let f=V.getRemoveClass(t.className,r.join(" "));f=V.getAddClass(f,o),t.className=f}},ue=()=>nl(T.value),fe=(t=null)=>{const a=i.isUndefined(t)||t===null?U.value:t;return al(a,ue(),d.isCheckedRadio)},Ie=()=>{if(d.isCheckedCheckbox){const t=ue(),a=fe();K.value=ol(t,a)}},je=()=>{const t=[],a=fe(),o=ue(),r=sl(o,a);if(d.isCheckedCheckbox)a.forEach(u=>{const f=s.dataJson[u.toString()];i.isUndefined(f)||t.push(f)});else if(d.isCheckedRadio&&a.length>0){const u=s.dataJson[a[0]];i.isUndefined(u)||t.push(u)}return{checkedIds:a,unCheckedIds:r,checkedData:t}},Be=()=>{const t=je();wt(t.checkedIds.join(","),t.checkedData,{checkedIds:t.checkedIds,unCheckedIds:t.unCheckedIds})},Ke=t=>{if(i.isEmpty(t)||i.isEmpty(t.id))return;const a=t.id.toString(),o=U.value;let r=[];if(d.isCheckedCheckbox){const u=i.isExistValue(o,a);o.forEach(f=>{f!==a&&r.push(f)}),u||r.push(a),U.value=r,Ie(),Be()}else o.length>0&&o[0]===a||(r=[a],U.value=r,Be())},Te=()=>{if(J.value&&h.value&&v.value){const t=h.value.clientWidth,a=v.value.getWidth();c.isShow=a>t}},Le=()=>{if(le.value&&v.value){const t=v.value.getHeight();let a=t>n.scrollY;if(a||(F.value||D.value?j.value&&(a=t>j.value.clientHeight):h.value&&h.value.offsetHeight>=n.scrollY&&(a=t>h.value.clientHeight)),a&&oe.value&&g.value){const o=g.value.getTotalHeight()-(i.osType().isMobile?2:0);d.totalHeight=`${o}px`}C.value=a}},he=()=>{if((F.value||D.value)&&h.value&&v.value){let t=h.value.scrollLeft;const a=h.value.clientWidth,o=v.value.getWidth();let r="left";t>0&&(a+t>=o?r="right":r="center"),c.posType=r}},Ge=()=>{if(!W.value||!v.value)return;let t=$.value?$.value.scrollLeft:0;const a=W.value.clientWidth,o=v.value.getWidth();a+t>o&&(t=0),P.loading.length>0&&v.value.setElasticLoadLeft(t),T.value.length===0&&v.value.setEmptyLeft(t)},Ne=t=>{ae=t.target.scrollLeft,R===null&&(R=requestAnimationFrame(()=>{R=null;const a=ae;$.value&&($.value.scrollLeft=a),h.value&&(h.value.scrollLeft=a),k.value&&k.value.setScrollLeft(a),O.value&&O.value.setScrollLeft(a),he(),Ge()}))},Ze=t=>{const a=t.target,o=a.scrollLeft;a.scrollWidth-a.clientWidth-o<1&&h.value&&h.value.scrollLeft>o||(o!==s.scrollHead.left&&Ne(t),s.scrollHead.left=o)},Qe=t=>{const a=t.target.scrollLeft;a!==s.scrollBody.left&&Ne(t),s.scrollBody.left=a},Oe=()=>{if(n.isFixedHead&&Y.value&&!d.isRunLoading){let t=!1,a="auto",o="auto";const r=Y.value&&Y.value.parentNode?V.getPositionView(Y.value.parentNode):null;if(r&&r.top<0&&W.value&&z.value&&g.value){const u=W.value.clientHeight;if(r.top>(u-pl)*-1){t=!0;const f=W.value.offsetWidth,b=c.isShow&&n.isScrollX?z.value.offsetHeight:g.value.getOffsetHeight();a=`${f}px`,o=`${b}px`}}p.isShow=t,p.width=a,p.height=o}},Re=()=>{T.value.length===0&&e.nextTick(()=>{v.value&&v.value.setEmptyWidth()})},me=()=>{const t={};if(n.isPaginate){const{pages:a,limit:o}=s.changeNewPaginate;t.pages=a,t.limit=o,t.offset=(t.pages-1)*t.limit}if(n.isOrder){const{orderIndex:a,orderBy:o}=s.changeNewSort;t.orderIndex=a,t.orderBy=o;const r=n.columns[a];i.isUndefined(r)||(t.orderColumns=r.data)}return t},Bt=()=>{n.scrollY>0&&e.nextTick(()=>{if(!h.value)return;const t=h.value.querySelectorAll(".tr-selected");h.value.scrollTop=t&&t.length>0&&t[0].offsetTop>Cl?t[0].offsetTop-wl:0})},_e=(t={})=>{if(d.isCheckedRadio||d.isCheckedCheckbox){const a=ce();U.value=fe(a),Ie(),Bt()}n.isElastic&&((!i.isBoolean(t.isElasticCloseAll)||t.isElasticCloseAll)&&(P.open=[],(F.value||D.value)&&v.value&&v.value.clearElasticAbsolute()),P.loading=[],bt()),d.hoverTrIndex=-1,d.hoverTrElasticIndex=-1,e.nextTick(()=>{n.isPaginate&&(q.pages=s.changeNewPaginate.pages,q.limit=s.changeNewPaginate.limit),n.isOrder&&(_.value=A([s.changeNewSort.orderIndex,s.changeNewSort.orderBy])),ze(),we(),e.nextTick(()=>{Le(),Te(),Ee().then(()=>{he()}).catch(a=>{Fe.warn("ClTable","表格固定列分析失败",a)}),Re(),Oe()})})},et=(t,a)=>{const o=i.isEmpty(n.list)?[]:n.list;let r=[];if(a){if(n.isOrder){const u={},f=[];let b="string";if(!i.isUndefined(t.orderIndex)){const M=t.orderColumns,N=n.columns[t.orderIndex];if(!i.isUndefined(N))if(i.isEmpty(N.sortType))switch(N.format){case"int":case"float2":case"float3":b="number";break;case"date":case"dateTime":case"time":b="date";break;default:b="string"}else b=N.sortType;o.forEach(te=>{if(!te)return;let Q=te[M];Q=i.isUndefined(Q)||Q===null?"":Q;const se=Q.toString();i.isExistJsonKey(u,se)||(u[se]=[],f.push(Q)),u[se].push(i.getJsonClone(te))})}f.length>0&&(t.orderBy==="desc"?i.getArrDesc(f,b):i.getArrAsc(f,b)).forEach(N=>{r.push(...u[N.toString()])})}else r=i.getListClone(n.list);s.sortLocalData=r}else r=s.sortLocalData;if(n.isPaginate){const u=[],f=r.length,b=t.offset;let M=t.offset+t.limit;if(M=f<M?f:M,f&&f>=b&&f>0)for(let N=b;N<M;N+=1)u.push(i.getJsonClone(r[N]));return u}else return r},ee=(t={})=>{const a=me();U.value=[],K.value=!1,Ce(),n.isServer?(s.timerBody&&clearTimeout(s.timerBody),s.timerBody=setTimeout(()=>{s.timerBody=null,kt(a)},st)):(s.timerBody&&clearTimeout(s.timerBody),s.timerBody=setTimeout(()=>{s.timerBody=null;const o=i.isBoolean(t.isChangePage)?!t.isChangePage:!0;T.value=et(a,o),_e()},st))},Tt=()=>{J.value&&($.value&&$.value.addEventListener("scroll",Ze),h.value&&h.value.addEventListener("scroll",Qe))},Lt=()=>{if(le.value){const t=window,a=t.MutationObserver||t.WebKitMutationObserver||t.MozMutationObserver;if(!a)return;B.observerBodyScrollY=new a(()=>{Le()});const o=B.observerBodyScrollY;v.value&&v.value.$el&&o&&o.observe(v.value.$el,{childList:!0,subtree:!0})}},ge=()=>{Te(),Ee().then(()=>{he()}).catch(t=>{Fe.warn("ClTable","表格固定列分析失败",t)}),qe(),Re(),Ge(),e.nextTick(()=>{Oe()})},ye=()=>{H===null&&(H=requestAnimationFrame(()=>{H=null,Oe()}))},Nt=()=>{we(),e.nextTick(()=>{n.isServer?ee():i.isEmpty(n.list)?n.isShowInitLoadIng?Ce():e.nextTick(()=>{Re()}):(ee(),n.isShowInitLoadIng||(d.isRunLoading=!1))})};e.onMounted(()=>{e.nextTick(()=>{Nt(),Tt(),Lt(),s.resizeEvent=new it.Resize({isDelay:!0,callback:()=>{ge()}}),n.isFixedHead&&window.addEventListener("scroll",ye)})}),e.onActivated(()=>{n.isFixedHead&&window.addEventListener("scroll",ye),s.resizeEvent||(s.resizeEvent=new it.Resize({isDelay:!0,callback:()=>{ge()}})),ge(),s.pendingCanceled&&(s.pendingCanceled=!1,ee())}),e.onDeactivated(()=>{window.removeEventListener("scroll",ye),s.timerBody&&(clearTimeout(s.timerBody),s.timerBody=null,d.isRunLoading=!1,s.pendingCanceled=!0),s.resizeEvent&&(s.resizeEvent.destroy(),s.resizeEvent=null),R!==null&&(cancelAnimationFrame(R),R=null),H!==null&&(cancelAnimationFrame(H),H=null)}),e.onBeforeUnmount(()=>{s.timerBody&&(clearTimeout(s.timerBody),s.timerBody=null),B.observerBodyScrollY&&(B.observerBodyScrollY.disconnect(),B.observerBodyScrollY.takeRecords(),B.observerBodyScrollY=null),J.value&&($.value&&$.value.removeEventListener("scroll",Ze),h.value&&h.value.removeEventListener("scroll",Qe)),s.resizeEvent&&s.resizeEvent.destroy(),R!==null&&(cancelAnimationFrame(R),R=null),H!==null&&(cancelAnimationFrame(H),H=null),window.removeEventListener("scroll",ye)}),e.watch(()=>n.list,(t,a)=>{const o=i.isEmpty(t)?[]:t;if(s.timerBody&&(clearTimeout(s.timerBody),s.timerBody=null),s.dataJson=i.getJsonByList(o),n.isServer)T.value=i.getListClone(o);else if(n.isParamTriggerServer)T.value=i.getListClone(o,!0);else{s.changeNewPaginate.pages=1;const u=me();T.value=et(u,!0)}const r={};if(n.isElastic){let u=!1;if(a)if(o.length===a.length){const f=new Set(a.map(b=>b?.id));u=o.some(b=>b&&!f.has(b.id))}else u=!0;u||(r.isElasticCloseAll=!1)}_e(r)},{deep:!0}),e.watch(()=>n.columns,()=>{e.nextTick(()=>{we(),e.nextTick(()=>{Le(),Te(),Ee().then(()=>{he()}).catch(t=>{Fe.warn("ClTable","表格固定列分析失败",t)})})})},{deep:!0}),e.watch(()=>n.selectValue,()=>{const t=ce();U.value=fe(t),Ie()}),e.watch(()=>n.orderSort,(t,a)=>{if(t&&t.length>=2&&!(t[0]===s.changeNewSort.orderIndex&&t[1]===s.changeNewSort.orderBy)){const o=A(n.orderSort);s.changeNewPaginate.pages=1,q.pages=1,s.changeNewSort={orderIndex:o[0],orderBy:o[1]},_.value=o,!n.isServer&&n.isParamTriggerServer?de():ee({isChangePage:!1})}},{deep:!0}),e.watch([()=>n.pageOffset,()=>n.paginateLimit],([t,a],[o,r])=>{const u=E();s.changeNewPaginate.pages=u,s.changeNewPaginate.limit=a,q.pages=u,q.limit=a,!n.isServer&&n.isParamTriggerServer?de():ee({isChangePage:!0})});const We=()=>{if(n.disabled)return;const t=!K.value;let a=[];if(t){const o=ue(),r=U.value,u=[];o.forEach(f=>{i.isExistValue(r,f)||u.push(f)}),a=r.concat(u)}K.value=t,U.value=a,Be()},Pe=(t,a,o)=>{n.disabled||d.isRunLoading||(s.changeNewPaginate.pages=1,q.pages=1,s.changeNewSort.orderIndex=a,s.changeNewSort.orderBy=o,!n.isServer&&n.isParamTriggerServer?de():ee({isChangePage:!1}))},$e=(t,a,o)=>{if(!a||i.isEmpty(a)||i.isBoolean(a.isDisabled)&&a.isDisabled||n.disabled)return;const r=i.isNonEmptyString(n.rowClickKeyInvalid)?V.getParent(t.target,n.rowClickKeyInvalid,t.currentTarget,!1):void 0;if(i.isUndefined(r)){if(n.isElastic){const f=i.isNonEmptyString(n.rowClickKeyElastic)?V.getParent(t.target,n.rowClickKeyElastic,t.currentTarget,!1):void 0;if(i.isUndefined(f))n.isClickRowLinkage&&be(a,o);else{be(a,o,f);return}}let u=!1;if(d.isCheckedRadio||d.isCheckedCheckbox){let f=V.getParent(t.target,".th-rc",t.currentTarget,!1);f===t.currentTarget&&(f=null),i.isUndefined(f)?n.isClickRowLinkage&&Ke(a):(u=!0,Ke(a))}Ct(a,o,u)}},ie=(t,a=-1)=>{d.hoverTrIndex=t,d.hoverTrElasticIndex=a},ne=()=>{d.hoverTrIndex=-1,d.hoverTrElasticIndex=-1},Ot=(t,a)=>{n.disabled||d.isRunLoading||n.isPaginate&&(s.changeNewPaginate.pages=t,s.changeNewPaginate.limit=a,!n.isServer&&n.isParamTriggerServer?de():ee({isChangePage:!0}))},tt=t=>{Ne(t)};return m({getParamInfo:()=>me(),refresh:(t=!0)=>{d.isRunLoading||(t&&(s.changeNewPaginate.pages=1),ee())},getData:()=>{const t=e.toRaw(T.value);return i.getListClone(t)},getDataAll:()=>{if(n.isServer){const t=e.toRaw(T.value);return i.getListClone(t)}return i.getListClone(s.sortLocalData)},getSelectData:()=>{const t=je();return{ids:(t?.checkedIds||[]).join(","),list:t?.checkedData||[]}},loadStart:()=>{Ce()},loadStop:()=>{ze()},loadElasticStart:t=>{i.isUndefined(t)||t===null||Je(t.toString())},loadElasticStop:t=>{i.isUndefined(t)||t===null||Ye(t.toString())},closeElastic:(t,a,o)=>{if(i.isEmpty(t)||i.isEmpty(t.id))return;const r=t.id.toString();if(P.open.indexOf(r)===-1)return;const u=o||(h.value?h.value.querySelector(`[data-elastic-id="${CSS.escape(r)}"]`):null);be(t,a,u,!1)},refreshResize:()=>{ge()}}),(t,a)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(Z),class:e.normalizeClass(ht.value)},[e.createElementVNode("div",cl,[l.isHead?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",{class:e.normalizeClass(mt.value),style:e.normalizeStyle({width:p.width}),ref_key:"refElHeadWrapper",ref:Y},[e.createElementVNode("div",{class:e.normalizeClass(gt.value),ref_key:"refElHeadContainer",ref:z},[e.createElementVNode("div",{class:"table-head-main",ref_key:"refElHeadMain",ref:$},[e.createVNode(Ve,{minWidth:c.minWidth,columns:l.columns,isOrder:l.isOrder,orderSort:_.value,isShowTotal:oe.value,totalInfo:l.totalData,keyIndex:X,hoverIndex:d.hoverTrIndex,isUseScrollX:J.value,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isShowCheckboxAll:pe.value,disabled:l.disabled,checkboxAllValue:K.value,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickAll:We,onOnClickOrderBy:Pe,onOnHoverIn:ie,onOnHoverOut:ne,ref_key:"refElHeadTable",ref:g},e.createSlots({_:2},[e.renderList(ve.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data})])})),e.renderList(Se.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data})])}))]),1032,["minWidth","columns","isOrder","orderSort","isShowTotal","totalInfo","hoverIndex","isUseScrollX","isShowRadio","isShowCheckbox","isShowCheckboxAll","disabled","checkboxAllValue","isInlineWidth","widthClassPrefix","widthMinClassPrefix"])],512),F.value&&y.leftColumnLength>0?(e.openBlock(),e.createElementBlock("div",dl,[e.createElementVNode("div",{class:"table-fixed-column-left-container",style:e.normalizeStyle({width:y.leftWidth})},[e.createVNode(Ve,{fixedType:"left",fixedLeftIndex:l.fixedColumnLeftIndex,width:y.totalWidth,columns:l.columns,isOrder:l.isOrder,orderSort:_.value,isShowTotal:oe.value,totalInfo:l.totalData,keyIndex:X,hoverIndex:d.hoverTrIndex,isUseScrollX:J.value,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isShowCheckboxAll:pe.value,disabled:l.disabled,checkboxAllValue:K.value,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickAll:We,onOnClickOrderBy:Pe,onOnHoverIn:ie,onOnHoverOut:ne},e.createSlots({_:2},[e.renderList(ve.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data})])})),e.renderList(Se.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.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)),D.value&&y.rightColumnLength>0?(e.openBlock(),e.createElementBlock("div",ul,[e.createElementVNode("div",{class:"table-fixed-column-right-container",style:e.normalizeStyle({width:y.rightWidth})},[e.createVNode(Ve,{fixedType:"right",fixedRightIndex:l.fixedColumnRightIndex,width:y.totalWidth,columns:l.columns,isOrder:l.isOrder,orderSort:_.value,keyIndex:X,hoverIndex:d.hoverTrIndex,isShowTotal:oe.value,totalInfo:l.totalData,isUseScrollX:J.value,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isShowCheckboxAll:pe.value,disabled:l.disabled,checkboxAllValue:K.value,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickAll:We,onOnClickOrderBy:Pe,onOnHoverIn:ie,onOnHoverOut:ne},e.createSlots({_:2},[e.renderList(ve.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data})])})),e.renderList(Se.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.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),C.value?(e.openBlock(),e.createElementBlock("div",fl,[a[0]||(a[0]=e.createElementVNode("div",null,null,-1)),oe.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"table-scroll-occupy-total",style:e.normalizeStyle({height:d.totalHeight})},null,4)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),l.isScrollX?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass({"table-scroll-occupy-corner":c.isShow})},null,2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),l.isScrollX?e.withDirectives((e.openBlock(),e.createElementBlock("div",hl,[e.createVNode(at._sfc_main,{isShowLeft:F.value,isShowRight:D.value,leftWidth:y.leftWidth,centerWidth:y.centerWidth,rightWidth:y.rightWidth,isShowCorner:C.value,cornerType:"right-top",onOnScrollX:tt,ref_key:"refElHeadFixedScrollX",ref:k},null,8,["isShowLeft","isShowRight","leftWidth","centerWidth","rightWidth","isShowCorner"])],512)),[[e.vShow,c.isShow]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),p.isShow&&d.isRunLoading?(e.openBlock(),e.createElementBlock("div",ml)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))],6),p.isShow?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle({height:p.height,width:p.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(yt.value),ref_key:"refElBodyWrapper",ref:W},[e.createElementVNode("div",{class:"table-body-container",style:e.normalizeStyle(vt.value),ref_key:"refElBodyContainer",ref:j},[e.createElementVNode("div",{class:e.normalizeClass({"table-body-main":!0,"table-body-empty":T.value.length===0}),style:e.normalizeStyle(xt.value),ref_key:"refElBodyMain",ref:h},[e.createVNode(Xe,{minWidth:c.minWidth,columns:l.columns,list:T.value,disabled:l.disabled,isOrder:l.isOrder,selectValue:U.value,keyIndex:X,hoverIndex:d.hoverTrIndex,hoverElasticIndex:d.hoverTrElasticIndex,isUseScrollX:J.value,colspanCount:d.colspanCount,isRunLoading:d.isRunLoading,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isElastic:l.isElastic,elasticOpen:P.open,elasticLoading:P.loading,elasticType:l.elasticType,elasticData:l.elasticData,trIntervalNum:l.trIntervalNum,isStriped:l.isStriped,emptyText:l.emptyText,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickTr:$e,onOnHoverIn:ie,onOnHoverOut:ne,ref_key:"refElBodyTable",ref:v},e.createSlots({_:2},[e.renderList(xe.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex})])})),e.renderList(ke.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex,trElasticInx:r.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),F.value&&y.leftColumnLength>0?(e.openBlock(),e.createElementBlock("div",gl,[e.createElementVNode("div",{class:"table-fixed-column-left-container",style:e.normalizeStyle({width:y.leftWidth})},[e.createVNode(Xe,{width:y.totalWidth,fixedType:"left",fixedLeftIndex:l.fixedColumnLeftIndex,columns:l.columns,list:T.value,disabled:l.disabled,isOrder:l.isOrder,selectValue:U.value,keyIndex:X,hoverIndex:d.hoverTrIndex,hoverElasticIndex:d.hoverTrElasticIndex,isUseScrollX:J.value,colspanCount:d.colspanCount,isRunLoading:d.isRunLoading,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isElastic:l.isElastic,elasticOpen:P.open,elasticLoading:P.loading,elasticType:l.elasticType,elasticData:l.elasticData,trIntervalNum:l.trIntervalNum,isStriped:l.isStriped,emptyText:l.emptyText,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickTr:$e,onOnHoverIn:ie,onOnHoverOut:ne},e.createSlots({_:2},[e.renderList(xe.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex})])})),e.renderList(ke.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex,trElasticInx:r.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)),D.value&&y.rightColumnLength>0?(e.openBlock(),e.createElementBlock("div",yl,[e.createElementVNode("div",{class:"table-fixed-column-right-container",style:e.normalizeStyle({width:y.rightWidth})},[e.createVNode(Xe,{width:y.totalWidth,fixedType:"right",fixedRightIndex:l.fixedColumnRightIndex,columns:l.columns,list:T.value,disabled:l.disabled,isOrder:l.isOrder,selectValue:U.value,keyIndex:X,hoverIndex:d.hoverTrIndex,hoverElasticIndex:d.hoverTrElasticIndex,isUseScrollX:J.value,colspanCount:d.colspanCount,isRunLoading:d.isRunLoading,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isElastic:l.isElastic,elasticOpen:P.open,elasticLoading:P.loading,elasticType:l.elasticType,elasticData:l.elasticData,trIntervalNum:l.trIntervalNum,isStriped:l.isStriped,emptyText:l.emptyText,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickTr:$e,onOnHoverIn:ie,onOnHoverOut:ne},e.createSlots({_:2},[e.renderList(xe.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex})])})),e.renderList(ke.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex,trElasticInx:r.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),l.isScrollX&&T.value.length>0&&c.isShow?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[l.isScrollXBottom?(e.openBlock(),e.createElementBlock("div",{key:0,class:"table-fixed-column-scrollX",style:e.normalizeStyle({bottom:le.value?"-1px":"1px"})},[e.createVNode(at._sfc_main,{isShowLeft:F.value,isShowRight:D.value,leftWidth:y.leftWidth,centerWidth:y.centerWidth,rightWidth:y.rightWidth,isShowCorner:C.value,isShowCover:!1,cornerType:"right-bottom",onOnScrollX:tt,ref_key:"refElBodyFixedScrollX",ref:O},null,8,["isShowLeft","isShowRight","leftWidth","centerWidth","rightWidth","isShowCorner"])],4)):(e.openBlock(),e.createElementBlock("div",vl,[e.createElementVNode("div",{style:e.normalizeStyle({height:`${ot}px`})},null,4)]))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],2),l.isPaginate&&T.value.length>0?(e.openBlock(),e.createElementBlock("div",xl,[a[1]||(a[1]=e.createElementVNode("div",null,null,-1)),e.createVNode(Mt._sfc_main,{currentPage:q.pages,limitValue:q.limit,limitData:l.paginateLimitData,isShowLimit:l.isPaginateLimit,totalCount:ft.value,disabled:l.disabled||d.isRunLoading,onOnChange:Ot},null,8,["currentPage","limitValue","limitData","isShowLimit","totalCount","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))]),d.isRunLoading?(e.openBlock(),e.createElementBlock("div",Sl,[e.createElementVNode("div",kl,[e.createElementVNode("div",{class:"table-load-head",style:e.normalizeStyle(St.value)},null,4),e.createElementVNode("div",{class:e.normalizeClass({"table-load-body":!0,"table-load-bg-gray":l.isLoading})},[e.createVNode($t._sfc_main,{isLoadIng:l.isLoading,size:"xxl",theme:l.loadTheme,color:l.loadColor||void 0},null,8,["isLoadIng","theme","color"])],2)])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,rl))}});module.exports=El;
1
+ "use strict";const e=require("vue"),Fe=require("@cldemo/ui-kit/common/log"),i=require("@cldemo/ui-kit/common/base"),V=require("@cldemo/ui-kit/common/Element"),it=require("@cldemo/ui-kit/common/Element/Event"),rt=require("../Shared/One.vue_vue_type_script_setup_true_lang-D9zWNf0s.js"),ct=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CFZ5jK-q.js"),dt=require("../Shared/index-q2CbfC2a.js"),Wt=require("../Shared/One.vue_vue_type_script_setup_true_lang-CGNfuoKE.js"),nt=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CZNVHUR1.js"),Pt=require("../Shared/language-BJ4aVgHI.js"),$t=require("../Shared/Ing.vue_vue_type_script_setup_true_lang-DaWKYdkt.js"),Mt=require("../Shared/Index.vue_vue_type_script_setup_true_lang-nAMiORzN.js"),at=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DBrrIpHb.js");;/* empty css */const ut=l=>{if(i.isNonEmptyString(l)){if(l.indexOf("clIcon-")===0){const m=l.substring(7);return i.isNonEmptyString(m)&&/^[a-zA-Z0-9-]+$/.test(m)?{name:m,className:""}:{name:"question-circle",className:""}}return/^clicon/i.test(l)?{name:"question-circle",className:""}:/^[a-zA-Z0-9-]+$/.test(l)?{name:l,className:""}:{name:"",className:l}}return{name:"question-circle",className:""}},At=["aria-sort"],Ht=e.defineComponent({name:"ClTableTh",directives:{cltooltip:dt.tooltipDirectives},__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:(l,m,x)=>!0},setup(l,{emit:m}){const x=l,n=m,I=e.computed(()=>ut(x.thInfo?.tipIcon)),w=e.computed(()=>i.isObject(x.thInfo)&&!i.isEmpty(x.thInfo)?x.thInfo:{}),A=e.computed(()=>!x.isOrder||i.isEmpty(w.value)?!1:i.isEmpty(w.value.sort)?!0:w.value.sort===!0),E=e.computed(()=>A.value&&!x.disabled),S=e.computed(()=>{const g=x.thInfo?.tipMsg;if(!i.isNonEmptyString(g))return;const k=i.removeHTMLTags(g);return i.isNonEmptyString(k)?k:void 0}),s=e.computed(()=>{if(!A.value)return"";const g=i.isEmpty(x.orderSort)?[]:x.orderSort;return g.length>0&&g[0]===x.thIndex?g.length===2?g[1]==="asc"||g[1]==="desc"?g[1]:"none":g.length===1?"desc":"none":"none"}),B=e.computed(()=>{if(s.value==="asc")return"ascending";if(s.value==="desc")return"descending";if(s.value==="none")return"none"}),X=e.computed(()=>{const g={},k=w.value;if(!i.isEmpty(k.width)&&z(k.width)&&(g[`${x.widthClassPrefix}${k.width}`]=!0),!i.isEmpty(k.widthMin)&&z(k.widthMin)&&x.isUseScrollX&&(g[`${x.widthMinClassPrefix}${k.widthMin}`]=!0),(x.fixedLeftIndex>-1||x.fixedRightIndex>-1)&&(g["th-hidden"]=x.fixedLeftIndex>-1&&x.thIndex>x.fixedLeftIndex||x.fixedRightIndex>-1&&x.thIndex<x.fixedRightIndex),A.value){g["th-sort"]=!0,g["sort-none"]=!0,g["th-sort-near"]=k.sortNear===!0;const j=s.value;(j==="asc"||j==="desc")&&(g[`sort-${j}`]=!0,g["sort-none"]=!1)}i.isNonEmptyString(k.tipMsg)&&(g["th-tip"]=!0,g["th-tip-sideAlign"]=k.tipSideAlign===!0),x.disabled&&(g["th-disabled"]=!0),i.isNonEmptyString(k.textAlign)&&i.isExistValue(["left","center","right"],k.textAlign)&&(g[`text-${k.textAlign}`]=!0);let W=g;return W=i.getJsonMerge(W,V.getClassNameJson(k.className)),W=i.getJsonMerge(W,V.getClassNameJson(k.classTh)),W}),Z=e.computed(()=>{const g={};if(!x.isInlineWidth)return g;const k=w.value;return!i.isEmpty(k.width)&&z(k.width)&&(g.width=i.isFinite(Number(k.width))?`${Number(k.width)}px`:`${k.width}`),!i.isEmpty(k.widthMin)&&z(k.widthMin)&&x.isUseScrollX&&(g.minWidth=i.isFinite(Number(k.widthMin))?`${Number(k.widthMin)}px`:`${k.widthMin}`),g}),Y=(g,k)=>{n("onClickOrderBy",g,x.thIndex,k)},z=g=>i.isString(g)||i.getTypeof(g)==="number"&&i.isFinite(g),$=()=>{if(E.value){const g=s.value==="desc"?"asc":"desc";Y(w.value,g)}};return(g,k)=>{const W=e.resolveDirective("cltooltip");return!e.unref(i).isBoolean(l.thInfo?.visible)||l.thInfo.visible?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass(X.value),style:e.normalizeStyle(Z.value),scope:"col","aria-sort":B.value},[e.createElementVNode("span",{class:"th-title",onClick:$},[e.renderSlot(g.$slots,"default")]),e.unref(i).isNonEmptyString(l.thInfo?.tipMsg)?e.withDirectives((e.openBlock(),e.createBlock(ct._sfc_main,{key:0,name:I.value.name,className:I.value.className,class:"th-tip-icon",role:"img","aria-label":S.value},null,8,["name","className","aria-label"])),[[W,{html:l.thInfo.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),s.value!==""?(e.openBlock(),e.createElementBlock("i",{key:2,class:"tr-sort-icon","aria-hidden":"true",onClick:$})):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))],14,At)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}}),Ue=e.defineComponent({name:"ClTableTd",directives:{cltooltip:dt.tooltipDirectives},__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:l=>["td","total"].indexOf(l)>-1}},setup(l){const m=l,x=e.computed(()=>ut(m.tdInfo?.tipIcon)),n=e.computed(()=>i.isEmpty(m.tdInfo)?{}:m.tdInfo),I=e.computed(()=>{const S=m.tdInfo?.tipMsg;if(!i.isNonEmptyString(S))return;const s=i.removeHTMLTags(S);return i.isNonEmptyString(s)?s:void 0}),w=e.computed(()=>{const S={},s=n.value;!i.isEmpty(s.width)&&E(s.width)&&(S[`${m.widthClassPrefix}${s.width}`]=!0),!i.isEmpty(s.widthMin)&&E(s.widthMin)&&m.isUseScrollX&&(S[`${m.widthMinClassPrefix}${s.widthMin}`]=!0),(m.fixedLeftIndex>-1||m.fixedRightIndex>-1)&&(S["td-hidden"]=m.fixedLeftIndex>-1&&m.tdIndex>m.fixedLeftIndex||m.fixedRightIndex>-1&&m.tdIndex<m.fixedRightIndex),m.isOrder&&(i.isEmpty(s.sort)||s.sort===!0)&&(S["td-sort"]=!0,S["td-sort-near"]=s.sortNear===!0),i.isNonEmptyString(s.tipMsg)&&(S["td-tip"]=!0,S["td-tip-sideAlign"]=s.tipSideAlign===!0),i.isNonEmptyString(s.textAlign)&&i.isExistValue(["left","center","right"],s.textAlign)&&(S[`text-${s.textAlign}`]=!0);let B=S;return B=i.getJsonMerge(B,V.getClassNameJson(s.className)),m.useType==="td"?B=i.getJsonMerge(B,V.getClassNameJson(s.classTd)):m.useType==="total"&&(B=i.getJsonMerge(B,V.getClassNameJson(s.classTotal))),B}),A=e.computed(()=>{const S={};if(!m.isInlineWidth)return S;const s=n.value;return!i.isEmpty(s.width)&&E(s.width)&&(S.width=i.isFinite(Number(s.width))?`${Number(s.width)}px`:`${s.width}`),!i.isEmpty(s.widthMin)&&E(s.widthMin)&&m.isUseScrollX&&(S.minWidth=i.isFinite(Number(s.widthMin))?`${Number(s.widthMin)}px`:`${s.widthMin}`),S}),E=S=>i.isString(S)||i.getTypeof(S)==="number"&&i.isFinite(S);return(S,s)=>{const B=e.resolveDirective("cltooltip");return!e.unref(i).isBoolean(l.tdInfo?.visible)||l.tdInfo.visible?(e.openBlock(),e.createElementBlock("td",{key:0,class:e.normalizeClass(w.value),style:e.normalizeStyle(A.value)},[e.renderSlot(S.$slots,"default"),e.unref(i).isNonEmptyString(l.tdInfo?.tipMsg)?e.withDirectives((e.openBlock(),e.createBlock(ct._sfc_main,{key:0,name:x.value.name,className:x.value.className,class:"td-tip-icon",role:"img","aria-label":I.value},null,8,["name","className","aria-label"])),[[B,{html:l.tdInfo.tipMsg,className:"tooltip-modal"}]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],6)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}}),Ft=["aria-hidden"],Dt={key:0},Vt={key:0},De=99999999,Ve=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:l=>["","left","right"].indexOf(l)>-1},fixedLeftIndex:{type:Number,default:-1,validator:l=>l>=-1},fixedRightIndex:{type:Number,default:-1,validator:l=>l>=-1},isInlineWidth:{type:Boolean,default:!1},widthClassPrefix:{type:String,default:"width-"},widthMinClassPrefix:{type:String,default:"width-min-"}},emits:{onClickAll:()=>!0,onClickOrderBy:(l,m,x)=>!0,onHoverIn:l=>!0,onHoverOut:()=>!0},setup(l,{expose:m,emit:x}){const n=l,I=x,w=e.useTemplateRef("refElTable"),A=e.computed(()=>({"table-default":!0,"table-base":!0})),E=e.computed(()=>{const h={};return i.isEmpty(n.fixedType)?n.isUseScrollX&&i.isNonEmptyString(n.minWidth)&&n.minWidth!=="none"&&(h.minWidth=n.minWidth):i.isNonEmptyString(n.width)&&n.width!=="none"&&(h.width=n.width),h}),S=h=>h?i.isUndefined(h.title)?i.isUndefined(h.data)?"":h.data:h.title:"",s=(h,v)=>i.isUndefined(h)||!v?"":i.isEmpty(v.format)?h:i.getValueByFormat(h,v.format??"",v.formatExt),B=(h,v)=>!h||!v?"":s(h[v.data],v);e.watch(()=>n.isShowTotal,h=>{!h&&n.hoverIndex===De&&I("onHoverOut")});const X=()=>{I("onClickAll")},Z=(h,v,O)=>{I("onClickOrderBy",h,v,O)},Y=()=>{I("onHoverIn",De)},z=()=>{I("onHoverOut")};return m({getOffsetHeight:()=>w.value?w.value.offsetHeight:0,getRcWidth:()=>{let h=0;if((n.isShowRadio||n.isShowCheckbox)&&w.value){const v=w.value.querySelector(".th-rc");v&&(h=v.clientWidth)}return h},getPaddingLr:()=>{let h=0;if(!w.value)return h;const v=w.value.querySelectorAll("th:not(.th-rc)");for(let O=0;O<v.length;O++){const d=V.getStyle(v[O]),T=parseFloat(d.paddingLeft),q=parseFloat(d.paddingRight),_=i.isFinite(T)?T:0,K=i.isFinite(q)?q:0;h+=_+K}return h},getElTh:()=>w.value?w.value.querySelectorAll("th"):[],getTotalHeight:()=>{let h=0;if(n.isShowTotal&&w.value){const v=w.value.querySelector(".tr-total");v&&(h=v.clientHeight)}return h}}),(h,v)=>(e.openBlock(),e.createElementBlock("table",{class:e.normalizeClass(A.value),style:e.normalizeStyle(E.value),"aria-hidden":!e.unref(i).isEmpty(l.fixedType),ref_key:"refElTable",ref:w},[e.createElementVNode("thead",null,[e.createElementVNode("tr",null,[l.isShowRadio||l.isShowCheckbox?(e.openBlock(),e.createElementBlock("th",{key:0,class:e.normalizeClass({"th-rc":!0,"th-hidden":l.fixedRightIndex>-1}),scope:"col"},[l.isShowCheckbox&&l.isShowCheckboxAll?(e.openBlock(),e.createBlock(rt._sfc_main,{key:0,forId:e.unref(i).isNonEmptyString(l.keyIndex)?`${l.keyIndex}_${l.fixedType}_cb_all`:void 0,value:l.checkboxAllValue,disabled:l.disabled,onOnChange:X},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(l.columns,(O,d)=>(e.openBlock(),e.createBlock(Ht,{key:`${l.keyIndex}_${l.fixedType}_head_th_${d}`,thInfo:O,thIndex:d,isOrder:l.isOrder,disabled:l.disabled,orderSort:l.orderSort,isUseScrollX:l.isUseScrollX,fixedLeftIndex:l.fixedLeftIndex,fixedRightIndex:l.fixedRightIndex,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickOrderBy:Z},{default:e.withCtx(()=>[e.renderSlot(h.$slots,`th_${O?.data??""}`,{data:O},()=>[e.createElementVNode("span",null,e.toDisplayString(S(O)),1)])]),_:2},1032,["thInfo","thIndex","isOrder","disabled","orderSort","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))])]),l.isShowTotal?(e.openBlock(),e.createElementBlock("tbody",Dt,[e.createElementVNode("tr",{class:e.normalizeClass({"tr-total":!0,"tr-hover":l.hoverIndex===De}),onMouseenter:Y,onMouseleave:z},[l.isShowRadio||l.isShowCheckbox?(e.openBlock(),e.createElementBlock("td",Vt)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.columns,(O,d)=>(e.openBlock(),e.createBlock(Ue,{key:`${l.keyIndex}_${l.fixedType}_body_total_td_${d}`,isOrder:l.isOrder,tdIndex:d,tdInfo:O,isUseScrollX:l.isUseScrollX,fixedLeftIndex:l.fixedLeftIndex,fixedRightIndex:l.fixedRightIndex,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,useType:"total"},{default:e.withCtx(()=>[e.renderSlot(h.$slots,`total_${O?.data??""}`,{data:l.totalInfo},()=>[e.createTextVNode(e.toDisplayString(B(l.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,Ft))}}),Xt=["id"],Ut=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(l){const m=l,x=m.id,n=e.computed(()=>S("cb")),I=e.computed(()=>S("rd")),w=e.computed(()=>m.value===!0),A=e.computed(()=>m.disabled===!0||i.isBoolean(m.info?.isDisabled)&&m.info.isDisabled),E=e.computed(()=>{const s={"th-rc":!0};return i.getJsonMerge(s,V.getClassNameJson(m.className))}),S=s=>i.isNonEmptyString(m.keyIndex)?`${m.keyIndex}_${s}`:void 0;return(s,B)=>l.isShowRadio||l.isShowCheckbox?(e.openBlock(),e.createElementBlock("td",{key:0,id:e.unref(x),class:e.normalizeClass(E.value)},[l.isShowCheckbox?(e.openBlock(),e.createBlock(rt._sfc_main,{key:0,forId:n.value,value:w.value,disabled:A.value},null,8,["forId","value","disabled"])):l.isShowRadio?(e.openBlock(),e.createBlock(Wt._sfc_main,{key:1,forId:I.value,name:I.value,value:w.value,disabled:A.value},null,8,["forId","name","value","disabled"])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:2},[],64))],10,Xt)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))}}),zt=["onClick","onMouseenter"],qt=["onMouseenter"],Jt=["colspan"],Yt={key:0,class:"panel-elastic-load",role:"status","aria-live":"polite"},jt={class:"elastic-load-container"},Kt=["data-elastic-id"],Gt=["onMouseenter"],Zt=["colspan"],Qt={class:"panel-elastic-load",role:"status","aria-live":"polite"},_t={class:"elastic-load-container"},el=["onMouseenter"],tl={key:2},ll=["colspan"],il={class:"panel-table-empty",role:"status"},Xe=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:l=>["default","sameDataStructure"].indexOf(l)>-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:(l,m,x)=>!0,onHoverIn:(l,m)=>!0,onHoverOut:()=>!0},setup(l,{expose:m,emit:x}){const n=l,I=x,{optPageLanguage:w,getPageLanguage:A}=Pt.useLanguage();A("common");const E=e.useTemplateRef("refElTable"),S=e.ref(new Set),s=e.computed(()=>new Set((Array.isArray(n.selectValue)?n.selectValue:[]).filter(c=>!i.isUndefined(c)).map(c=>String(c)))),B=e.computed(()=>new Set((Array.isArray(n.elasticLoading)?n.elasticLoading:[]).filter(c=>!i.isUndefined(c)).map(c=>String(c)))),X=e.computed(()=>new Set((Array.isArray(n.elasticOpen)?n.elasticOpen:[]).filter(c=>!i.isUndefined(c)).map(c=>String(c)))),Z=e.computed(()=>{const c=Number(n.colspanCount);return i.isFinite(c)&&c>=1?Math.floor(c):1}),Y=e.computed(()=>({"table-default":!0,"table-base":!0,"table-empty":i.isEmpty(n.list)})),z=e.computed(()=>{const c={};return i.isNonEmptyString(n.fixedType)?i.isNonEmptyString(n.width)&&n.width!=="none"&&(c.width=n.width):n.isUseScrollX&&i.isNonEmptyString(n.minWidth)&&n.minWidth!=="none"&&(c.minWidth=n.minWidth),c}),$=(c,C,y)=>{I("onClickTr",c,C,y)},g=(c,C=-1)=>{I("onHoverIn",c,C)},k=()=>{I("onHoverOut")},W=(c,C)=>i.isEmpty(c)||!C?"":i.isEmpty(C.format)?c:i.getValueByFormat(c,C.format??"",C.formatExt),j=c=>{const C=n.elasticData||{};return Object.prototype.hasOwnProperty.call(C,c)?C[c]:[]},h=c=>!i.isEmpty(c)&&!i.isEmpty(c.id)&&s.value.has(c.id.toString()),v=c=>!i.isEmpty(c)&&!i.isEmpty(c.id)&&B.value.has(c.id.toString());return m({getWidth:()=>E.value?E.value.clientWidth:0,getHeight:()=>E.value?E.value.clientHeight:0,setElasticWidth:()=>{if(!E.value)return;const c=E.value.parentNode;if(!c)return;const C=E.value.querySelectorAll(".panel-elastic-load"),y=c.clientWidth;for(let p=0;p<C.length;p++)C[p].style.width=`${y}px`},setElasticHeight:c=>{if(!E.value)return;const C=E.value.querySelector(`[data-elastic-id="${CSS.escape(c)}"]`);if(C){const y=C.parentNode;if(y){C.style.height="",y.style.height="";const L=`${C.clientHeight}px`;C.style.height=L,y.style.height=L}const p=S.value;p.has(c)||(S.value=new Set(p).add(c))}},removeElasticAbsolute:c=>{if(S.value.has(c)){const C=new Set(S.value);C.delete(c),S.value=C}},clearElasticAbsolute:()=>{S.value.size>0&&(S.value=new Set)},setElasticLoadLeft:c=>{if(!E.value)return;const C=E.value.querySelectorAll(".panel-elastic-load"),y=i.isFinite(c)?Math.max(0,c):0;for(let p=0;p<C.length;p++)C[p].style.left=`${y}px`},setEmptyWidth:()=>{if(!E.value)return;const c=E.value.querySelector(".panel-table-empty");if(c){const C=E.value.parentNode;if(C){const y=C.clientWidth;c.style.width=`${y}px`}}},setEmptyLeft:c=>{const C=E.value?E.value.querySelector(".panel-table-empty"):null;if(C){const y=i.isFinite(c)?Math.max(0,c):0;C.style.left=`${y}px`}}}),(c,C)=>(e.openBlock(),e.createElementBlock("table",{class:e.normalizeClass(Y.value),style:e.normalizeStyle(z.value),ref_key:"refElTable",ref:E},[e.createElementVNode("tbody",null,[e.unref(i).isEmpty(l.list)?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(l.list,(y,p)=>(e.openBlock(),e.createElementBlock(e.Fragment,{key:`${l.keyIndex}_${l.fixedType}_body_tr_${p}`},[e.createElementVNode("tr",{class:e.normalizeClass({odd:l.isStriped&&p%2===0,"tr-customInterval-odd":l.isStriped&&l.trIntervalNum>0&&Math.floor(p/l.trIntervalNum)%2===0,"tr-customInterval-even":l.isStriped&&l.trIntervalNum>0&&Math.floor(p/l.trIntervalNum)%2===1,"tr-disabled":e.unref(i).isBoolean(y?.isDisabled)&&y.isDisabled,"tr-selected":h(y),"tr-hover":l.hoverIndex===p}),onClick:L=>$(L,y,p),onMouseenter:L=>g(p),onMouseleave:k},[l.isShowRadio||l.isShowCheckbox?(e.openBlock(),e.createBlock(Ut,{key:0,keyIndex:`${l.keyIndex}_${l.fixedType}_body_tr_${p}`,isShowRadio:l.isShowRadio,isShowCheckbox:l.isShowCheckbox,value:h(y),info:y,disabled:l.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(l.columns,(L,R)=>(e.openBlock(),e.createBlock(Ue,{key:`${l.keyIndex}_${l.fixedType}_body_tr_${p}_td_${R}`,isOrder:l.isOrder,tdIndex:R,tdInfo:L,isUseScrollX:l.isUseScrollX,fixedLeftIndex:l.fixedLeftIndex,fixedRightIndex:l.fixedRightIndex,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix},{default:e.withCtx(()=>[e.renderSlot(c.$slots,`td_${L?.data??""}`,{data:y,trIndex:p},()=>[e.createTextVNode(e.toDisplayString(W(y&&L?y[L.data]:void 0,L)),1)])]),_:2},1032,["isOrder","tdIndex","tdInfo","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))],42,zt),l.isElastic&&!e.unref(i).isEmpty(y?.id)&&X.value.has(y.id.toString())?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[l.elasticType==="default"?(e.openBlock(),e.createElementBlock("tr",{key:0,class:e.normalizeClass({"tr-elastic":!0,"tr-hover":l.hoverIndex===p}),onMouseenter:L=>g(p),onMouseleave:k},[e.createElementVNode("td",{colspan:Z.value,class:e.normalizeClass({"td-elastic-load":v(y)})},[v(y)?(e.openBlock(),e.createElementBlock("div",Yt,[e.createElementVNode("div",jt,[e.createVNode(nt._sfc_main,{theme:"circleBubble",size:"large"})])])):(e.openBlock(),e.createElementBlock("div",{key:1,class:e.normalizeClass(["elastic-container",{"elastic-container-absolute":S.value.has(y.id.toString())}]),"data-elastic-id":y.id},[e.renderSlot(c.$slots,"tr_elastic_children",{data:y,trIndex:p})],10,Kt))],10,Jt)],42,qt)):l.elasticType==="sameDataStructure"?(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[v(y)?(e.openBlock(),e.createElementBlock("tr",{key:0,class:e.normalizeClass({"tr-elastic":!0,"tr-hover":l.hoverIndex===p}),onMouseenter:L=>g(p),onMouseleave:k},[e.createElementVNode("td",{colspan:Z.value,class:"td-elastic-load"},[e.createElementVNode("div",Qt,[e.createElementVNode("div",_t,[e.createVNode(nt._sfc_main,{theme:"circleBubble",size:"large"})])])],8,Zt)],42,Gt)):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(j(y.id.toString()),(L,R)=>(e.openBlock(),e.createElementBlock("tr",{key:`${l.keyIndex}_${l.fixedType}_body_tr_${p}_elastic_${R}`,class:e.normalizeClass({"tr-elastic-sameDataStructure":!0,odd:l.isStriped&&R%2===0,"tr-disabled":e.unref(i).isBoolean(L?.isDisabled)&&L.isDisabled,"tr-hover":l.hoverElasticIndex===R&&l.hoverIndex===p}),onMouseenter:H=>g(p,R),onMouseleave:k},[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.columns,(H,ae)=>(e.openBlock(),e.createBlock(Ue,{key:`${l.keyIndex}_${l.fixedType}_body_tr_${p}_elastic_${R}_td_${ae}`,isOrder:l.isOrder,tdIndex:ae,tdInfo:H,isUseScrollX:l.isUseScrollX,fixedLeftIndex:l.fixedLeftIndex,fixedRightIndex:l.fixedRightIndex,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix},{default:e.withCtx(()=>[e.renderSlot(c.$slots,`td_elastic_${H?.data??""}`,{data:L,trIndex:p,trElasticInx:R},()=>[e.createTextVNode(e.toDisplayString(W(L&&H?L[H.data]:void 0,H)),1)])]),_:2},1032,["isOrder","tdIndex","tdInfo","isUseScrollX","fixedLeftIndex","fixedRightIndex","isInlineWidth","widthClassPrefix","widthMinClassPrefix"]))),128))],42,el))),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(i).isEmpty(l.list)&&!l.isRunLoading&&!e.unref(i).isNonEmptyString(l.fixedType)?(e.openBlock(),e.createElementBlock("tr",tl,[e.createElementVNode("td",{colspan:Z.value,class:"td-empty"},[e.createElementVNode("div",il,e.toDisplayString(e.unref(i).isNonEmptyString(l.emptyText)?l.emptyText:e.unref(w).noResultsText),1)],8,ll)])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])],6))}});function nl(l){if(!Array.isArray(l))return[];const m=[];return l.forEach(x=>{if(i.isEmpty(x))return;const n=x;!(i.isBoolean(n.isDisabled)?n.isDisabled:!1)&&!i.isEmpty(n.id)&&m.push(String(n.id))}),m}function al(l,m,x=!1){if(!Array.isArray(l)||l.length===0)return[];const n=[];return l.forEach(I=>{const w=String(I);m.includes(w)&&n.push(w)}),x&&n.length>1?[n[0]]:n}function ol(l,m){return m.length>0&&m.length===l.length}function sl(l,m){return l.filter(x=>!m.includes(x))}const rl=["id"],cl={class:"table-wrapper"},dl={key:0,class:"table-fixed-column-left"},ul={key:2,class:"table-fixed-column-right"},fl={key:0,class:"table-scroll-occupy-container"},hl={key:2,class:"table-fixed-column-scrollX"},ml={key:4,class:"table-fixed-head-load"},gl={key:0,class:"table-fixed-column-left"},yl={key:2,class:"table-fixed-column-right"},vl={key:1,class:"table-fixed-column-scrollX"},xl={key:2,class:"table-footer-wrapper"},Sl={key:0,class:"table-load",role:"status","aria-live":"polite"},kl={class:"table-load-wrapper"},ot=15,pl=30,Cl=180,wl=50,st=300,El=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:l=>["none","radio","checkbox"].indexOf(l)>-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:l=>["default","sameDataStructure"].indexOf(l)>-1},elasticData:{type:Object,default:()=>({})},trIntervalNum:{type:Number,default:-1},isStriped:{type:Boolean,default:!1},emptyText:String,isHead:{type:Boolean,default:!0}},emits:{onGetData:l=>!0,onClickRow:(l,m,x)=>!0,onClickElastic:(l,m,x,n,I)=>!0,onChangeChecked:(l,m,x)=>!0,onChangeParams:l=>!0},setup(l,{expose:m,emit:x}){const n=l,I=x,w=e.useSlots(),A=t=>{let a=[];if(n.isOrder){const o=i.isEmpty(t)?[]:t;let r=[0,"desc"];const u=i.isEmpty(n.columns)?[]:n.columns;for(let f=0;f<u.length;f+=1){const b=u[f];if(i.isEmpty(b))continue;const M=b.sort===void 0||b.sort===null?!0:b.sort===!0,N=i.isBoolean(b.visible)?b.visible:!0;if(M&&N){r=[f,"desc"];break}}if(o.length===0)a=r;else{const f=u[o[0]];if(i.isEmpty(f))a=r;else{const b=f.sort===void 0||f.sort===null?!0:f.sort===!0,M=i.isBoolean(f.visible)?f.visible:!0,N=Array.isArray(o)?o[0]:void 0,te=Array.isArray(o)&&(o[1]==="asc"||o[1]==="desc")?o[1]:void 0;a=b&&M&&!i.isUndefined(N)?[N,te??"desc"]:r}}}return a},E=()=>{let t=1;return n.paginateLimit>0&&n.pageOffset>=0&&(t=Math.floor(n.pageOffset/n.paginateLimit)+1),t},S=A(n.orderSort),s={dataJson:i.getJsonByList(n.list),changeNewPaginate:{pages:E(),limit:n.paginateLimit},changeNewSort:{orderIndex:S[0],orderBy:S[1]},sortLocalData:[],scrollBody:{left:0},scrollHead:{left:0},resizeEvent:null,timerBody:null,pendingCanceled:!1},B={observerBodyScrollY:null},X=`table-${i.getRandom(5)}`,Z=n.id,Y=e.useTemplateRef("refElHeadWrapper"),z=e.useTemplateRef("refElHeadContainer"),$=e.useTemplateRef("refElHeadMain"),g=e.useTemplateRef("refElHeadTable"),k=e.useTemplateRef("refElHeadFixedScrollX"),W=e.useTemplateRef("refElBodyWrapper"),j=e.useTemplateRef("refElBodyContainer"),h=e.useTemplateRef("refElBodyMain"),v=e.useTemplateRef("refElBodyTable"),O=e.useTemplateRef("refElBodyFixedScrollX"),d=e.reactive({isRunLoading:!1,isCheckedRadio:n.checkedRowType==="radio",isCheckedCheckbox:n.checkedRowType==="checkbox",colspanCount:0,hoverTrIndex:-1,hoverTrElasticIndex:-1,totalHeight:"0"}),T=e.ref([]),q=e.reactive({pages:s.changeNewPaginate.pages,limit:s.changeNewPaginate.limit}),_=e.ref(S),K=e.ref(!1),ce=()=>{const t=n.selectValue;return i.isNonEmptyString(t)?i.split(t):i.isNumber(t)?i.split(t.toString()):[]},U=e.ref(ce()),P=e.reactive({open:[],loading:[]}),c=e.reactive({isShow:!1,minWidth:"auto",posType:"left"}),C=e.ref(!1),y=e.reactive({totalWidth:"0",centerWidth:"0",leftColumnLength:0,leftWidth:"0",rightColumnLength:0,rightWidth:"0"}),p=e.reactive({isShow:!1,width:"auto",height:"auto"}),L=e.reactive({headHeight:0});let R=null,H=null,ae=0;const ve=e.computed(()=>Object.keys(w).filter(t=>t.indexOf("th_")===0)),xe=e.computed(()=>{const t=Object.keys(w).filter(a=>a.indexOf("td_")===0&&a.indexOf("td_elastic_")!==0);return n.isElastic&&t.push("tr_elastic_children"),t}),Se=e.computed(()=>Object.keys(w).filter(t=>t.indexOf("total_")===0)),ke=e.computed(()=>Object.keys(w).filter(t=>t.indexOf("td_elastic_")===0)),pe=e.computed(()=>n.isShowCheckboxAll&&T.value.length>0),oe=e.computed(()=>!i.isEmpty(n.totalData)&&T.value.length>0),ft=e.computed(()=>n.isServer?i.isFinite(n.totalLength)?n.totalLength:0:i.isFinite(n.totalLength)?n.totalLength:n.list?.length||0),J=e.computed(()=>n.isScrollX||n.isScrollXBottom),le=e.computed(()=>n.scrollY>0),F=e.computed(()=>n.isHead&&n.fixedColumnLeftIndex>-1&&J.value),D=e.computed(()=>n.isHead&&n.fixedColumnRightIndex>-1&&J.value&&n.fixedColumnRightIndex>n.fixedColumnLeftIndex+1),ht=e.computed(()=>{const t={"panel-table":!0,"table-disabled":n.disabled};return d.isRunLoading&&(t["table-loading"]=!0),i.osType().isMobile&&(t["table-mob"]=!0),i.getJsonMerge(t,V.getClassNameJson(n.className))}),mt=e.computed(()=>{const t={"table-head-wrapper":!0,"table-scrollY":le.value,"table-scroll-occupy-y":C.value};return p.isShow&&(t["table-fixed-head"]=!0),t}),gt=e.computed(()=>{const t={"table-head-container":!0};return n.isScrollX&&(t["table-scrollX"]=!0),(F.value||D.value)&&(t["table-fixed-column"]=!0,c.isShow?t[`table-scrollX-${c.posType}`]=!0:t["table-scrollX-none"]=!0),t}),yt=e.computed(()=>{const t={"table-body-wrapper":!0,"table-scrollY":le.value,"table-scrollX":n.isScrollX,"table-scrollX-bottom":c.isShow};return t["table-scroll-borderT0"]=c.isShow&&n.isScrollX,(F.value||D.value)&&(t["table-fixed-column"]=!0,c.isShow?t[`table-scrollX-${c.posType}`]=!0:t["table-scrollX-none"]=!0),t}),vt=e.computed(()=>{const t={};if((F.value||D.value)&&le.value){const a=c.isShow?Math.max(0,n.scrollY-ot):n.scrollY;t.maxHeight=`${a}px`}return t}),xt=e.computed(()=>{const t={};return F.value||D.value||le.value&&(t.maxHeight=`${n.scrollY}px`),t}),St=e.computed(()=>{const t={};return d.isRunLoading&&(t.height=`${L.headHeight}px`),t}),kt=t=>{I("onGetData",t)},pt=(t,a,o,r,u)=>{I("onClickElastic",t,a,o,r,u)},Ct=(t,a,o=!1)=>{I("onClickRow",t,a,o)},wt=(t,a,o)=>{I("onChangeChecked",t,a,o)},de=()=>{const t=me();I("onChangeParams",t)},Ce=()=>{e.nextTick(()=>{if($.value){const t=$.value.querySelector("thead");t&&(L.headHeight=t.offsetHeight)}}),d.isRunLoading=!0},ze=()=>{d.isRunLoading=!1},we=()=>{let t=0,a=0;(d.isCheckedRadio||d.isCheckedCheckbox)&&(t=1,g.value&&(a=g.value.getRcWidth())),(i.isEmpty(n.columns)?[]:n.columns).forEach(u=>{(i.isBoolean(u?.visible)?u.visible:!0)&&(t+=1,!i.isEmpty(u)&&!i.isEmpty(u.width)?a+=Number(u.width)||0:!i.isEmpty(u)&&!i.isEmpty(u.widthMin)&&(a+=Number(u.widthMin)||0))});const r=g.value?g.value.getPaddingLr():0;a+=r,d.colspanCount=t,J.value&&(c.minWidth=a>0?`${a}px`:"auto")},Ee=()=>new Promise((t,a)=>{e.nextTick(()=>{try{if(!v.value){t();return}const o=v.value.getWidth();y.totalWidth=`${o}px`;let r=o;if(F.value||D.value){const u=[],f=[];(i.isEmpty(n.columns)?[]:n.columns).forEach((G,re)=>{(i.isBoolean(G?.visible)?G.visible:!0)&&(F.value&&re<=n.fixedColumnLeftIndex&&u.push(G),D.value&&re>=n.fixedColumnRightIndex&&f.push(G))});const M=d.isCheckedRadio||d.isCheckedCheckbox,N=g.value?g.value.getElTh():[],te=N.length;let Q=u.length;const se=f.length;let lt=Q-1;const Rt=te-se;M&&(Q+=1,lt+=1);let Me=0,Ae=0;for(let G=0;G<te;G++){const re=N[G];if(!re)continue;const He=re.clientWidth;G<=lt&&(Me+=He),G>=Rt&&(Ae+=He)}F.value&&(y.leftColumnLength=u.length,y.leftWidth=`${Me}px`,r-=Me),D.value&&(y.rightColumnLength=f.length,y.rightWidth=`${Ae}px`,r-=Ae)}r=Math.max(0,r),y.centerWidth=`${r}px`,e.nextTick(()=>{t()})}catch(o){a(o)}})}),qe=()=>{e.nextTick(()=>{v.value&&v.value.setElasticWidth()})},Et=t=>{(F.value||D.value)&&v.value&&v.value.setElasticHeight(t)},Je=t=>{if(n.isElasticLoad){const a=i.getArrClone(P.loading);a.indexOf(t)===-1&&(a.push(t),P.loading=a)}},Ye=t=>{if(n.isElasticLoad){const a=i.getArrClone(P.loading),o=a.indexOf(t);o>-1&&(a.splice(o,1),P.loading=a,e.nextTick(()=>{Et(t)}))}},be=(t,a,o,r)=>{if(i.isEmpty(t)||i.isEmpty(t.id))return;const u=t.id.toString(),f=i.getArrClone(P.open),b=f.indexOf(u),M=b===-1;M?(f.push(u),Je(u)):(f.splice(b,1),Ye(u),(F.value||D.value)&&v.value&&v.value.removeElasticAbsolute(u)),It(o,M);const N=i.isBoolean(r)?r:!0;P.open=f,N&&pt(u,t,a,M,o),qe()},bt=()=>{const t=[],a=i.isEmpty(n.elasticIconCls)?[]:n.elasticIconCls;if(a.length===2){const o=T.value,r=P.open;o.forEach(u=>{if(!u){t.push(u);return}const f=i.getJsonClone(u);if(!i.isEmpty(f.id)){const b=f.id.toString();f._elasticIconCls=r.indexOf(b)>-1?a[1]:a[0]}t.push(f)})}t.length>0&&(T.value=t)},It=(t,a=!1)=>{if(t){const o=[],r=["elastic-expand","elastic-retract"];a?o.push("elastic-expand"):o.push("elastic-retract");const u=i.isEmpty(n.elasticIconCls)?[]:n.elasticIconCls;u.length===2&&(r.push(u[0]),r.push(u[1]),a?o.push(u[1]):o.push(u[0]));let f=V.getRemoveClass(t.className,r.join(" "));f=V.getAddClass(f,o),t.className=f}},ue=()=>nl(T.value),fe=(t=null)=>{const a=i.isUndefined(t)||t===null?U.value:t;return al(a,ue(),d.isCheckedRadio)},Ie=()=>{if(d.isCheckedCheckbox){const t=ue(),a=fe();K.value=ol(t,a)}},je=()=>{const t=[],a=fe(),o=ue(),r=sl(o,a);if(d.isCheckedCheckbox)a.forEach(u=>{const f=s.dataJson[u.toString()];i.isUndefined(f)||t.push(f)});else if(d.isCheckedRadio&&a.length>0){const u=s.dataJson[a[0]];i.isUndefined(u)||t.push(u)}return{checkedIds:a,unCheckedIds:r,checkedData:t}},Be=()=>{const t=je();wt(t.checkedIds.join(","),t.checkedData,{checkedIds:t.checkedIds,unCheckedIds:t.unCheckedIds})},Ke=t=>{if(i.isEmpty(t)||i.isEmpty(t.id))return;const a=t.id.toString(),o=U.value;let r=[];if(d.isCheckedCheckbox){const u=i.isExistValue(o,a);o.forEach(f=>{f!==a&&r.push(f)}),u||r.push(a),U.value=r,Ie(),Be()}else o.length>0&&o[0]===a||(r=[a],U.value=r,Be())},Te=()=>{if(J.value&&h.value&&v.value){const t=h.value.clientWidth,a=v.value.getWidth();c.isShow=a>t}},Le=()=>{if(le.value&&v.value){const t=v.value.getHeight();let a=t>n.scrollY;if(a||(F.value||D.value?j.value&&(a=t>j.value.clientHeight):h.value&&h.value.offsetHeight>=n.scrollY&&(a=t>h.value.clientHeight)),a&&oe.value&&g.value){const o=g.value.getTotalHeight()-(i.osType().isMobile?2:0);d.totalHeight=`${o}px`}C.value=a}},he=()=>{if((F.value||D.value)&&h.value&&v.value){let t=h.value.scrollLeft;const a=h.value.clientWidth,o=v.value.getWidth();let r="left";t>0&&(a+t>=o?r="right":r="center"),c.posType=r}},Ge=()=>{if(!W.value||!v.value)return;let t=$.value?$.value.scrollLeft:0;const a=W.value.clientWidth,o=v.value.getWidth();a+t>o&&(t=0),P.loading.length>0&&v.value.setElasticLoadLeft(t),T.value.length===0&&v.value.setEmptyLeft(t)},Ne=t=>{ae=t.target.scrollLeft,R===null&&(R=requestAnimationFrame(()=>{R=null;const a=ae;$.value&&($.value.scrollLeft=a),h.value&&(h.value.scrollLeft=a),k.value&&k.value.setScrollLeft(a),O.value&&O.value.setScrollLeft(a),he(),Ge()}))},Ze=t=>{const a=t.target,o=a.scrollLeft;a.scrollWidth-a.clientWidth-o<1&&h.value&&h.value.scrollLeft>o||(o!==s.scrollHead.left&&Ne(t),s.scrollHead.left=o)},Qe=t=>{const a=t.target.scrollLeft;a!==s.scrollBody.left&&Ne(t),s.scrollBody.left=a},Oe=()=>{if(n.isFixedHead&&Y.value&&!d.isRunLoading){let t=!1,a="auto",o="auto";const r=Y.value&&Y.value.parentNode?V.getPositionView(Y.value.parentNode):null;if(r&&r.top<0&&W.value&&z.value&&g.value){const u=W.value.clientHeight;if(r.top>(u-pl)*-1){t=!0;const f=W.value.offsetWidth,b=c.isShow&&n.isScrollX?z.value.offsetHeight:g.value.getOffsetHeight();a=`${f}px`,o=`${b}px`}}p.isShow=t,p.width=a,p.height=o}},Re=()=>{T.value.length===0&&e.nextTick(()=>{v.value&&v.value.setEmptyWidth()})},me=()=>{const t={};if(n.isPaginate){const{pages:a,limit:o}=s.changeNewPaginate;t.pages=a,t.limit=o,t.offset=(t.pages-1)*t.limit}if(n.isOrder){const{orderIndex:a,orderBy:o}=s.changeNewSort;t.orderIndex=a,t.orderBy=o;const r=n.columns[a];i.isUndefined(r)||(t.orderColumns=r.data)}return t},Bt=()=>{n.scrollY>0&&e.nextTick(()=>{if(!h.value)return;const t=h.value.querySelectorAll(".tr-selected");h.value.scrollTop=t&&t.length>0&&t[0].offsetTop>Cl?t[0].offsetTop-wl:0})},_e=(t={})=>{if(d.isCheckedRadio||d.isCheckedCheckbox){const a=ce();U.value=fe(a),Ie(),Bt()}n.isElastic&&((!i.isBoolean(t.isElasticCloseAll)||t.isElasticCloseAll)&&(P.open=[],(F.value||D.value)&&v.value&&v.value.clearElasticAbsolute()),P.loading=[],bt()),d.hoverTrIndex=-1,d.hoverTrElasticIndex=-1,e.nextTick(()=>{n.isPaginate&&(q.pages=s.changeNewPaginate.pages,q.limit=s.changeNewPaginate.limit),n.isOrder&&(_.value=A([s.changeNewSort.orderIndex,s.changeNewSort.orderBy])),ze(),we(),e.nextTick(()=>{Le(),Te(),Ee().then(()=>{he()}).catch(a=>{Fe.warn("ClTable","表格固定列分析失败",a)}),Re(),Oe()})})},et=(t,a)=>{const o=i.isEmpty(n.list)?[]:n.list;let r=[];if(a){if(n.isOrder){const u={},f=[];let b="string";if(!i.isUndefined(t.orderIndex)){const M=t.orderColumns,N=n.columns[t.orderIndex];if(!i.isUndefined(N))if(i.isEmpty(N.sortType))switch(N.format){case"int":case"float2":case"float3":b="number";break;case"date":case"dateTime":case"time":b="date";break;default:b="string"}else b=N.sortType;o.forEach(te=>{if(!te)return;let Q=te[M];Q=i.isUndefined(Q)||Q===null?"":Q;const se=Q.toString();i.isExistJsonKey(u,se)||(u[se]=[],f.push(Q)),u[se].push(i.getJsonClone(te))})}f.length>0&&(t.orderBy==="desc"?i.getArrDesc(f,b):i.getArrAsc(f,b)).forEach(N=>{r.push(...u[N.toString()])})}else r=i.getListClone(n.list);s.sortLocalData=r}else r=s.sortLocalData;if(n.isPaginate){const u=[],f=r.length,b=t.offset;let M=t.offset+t.limit;if(M=f<M?f:M,f&&f>=b&&f>0)for(let N=b;N<M;N+=1)u.push(i.getJsonClone(r[N]));return u}else return r},ee=(t={})=>{const a=me();U.value=[],K.value=!1,Ce(),n.isServer?(s.timerBody&&clearTimeout(s.timerBody),s.timerBody=setTimeout(()=>{s.timerBody=null,kt(a)},st)):(s.timerBody&&clearTimeout(s.timerBody),s.timerBody=setTimeout(()=>{s.timerBody=null;const o=i.isBoolean(t.isChangePage)?!t.isChangePage:!0;T.value=et(a,o),_e()},st))},Tt=()=>{J.value&&($.value&&$.value.addEventListener("scroll",Ze),h.value&&h.value.addEventListener("scroll",Qe))},Lt=()=>{if(le.value){const t=window,a=t.MutationObserver||t.WebKitMutationObserver||t.MozMutationObserver;if(!a)return;B.observerBodyScrollY=new a(()=>{Le()});const o=B.observerBodyScrollY;v.value&&v.value.$el&&o&&o.observe(v.value.$el,{childList:!0,subtree:!0})}},ge=()=>{Te(),Ee().then(()=>{he()}).catch(t=>{Fe.warn("ClTable","表格固定列分析失败",t)}),qe(),Re(),Ge(),e.nextTick(()=>{Oe()})},ye=()=>{H===null&&(H=requestAnimationFrame(()=>{H=null,Oe()}))},Nt=()=>{we(),e.nextTick(()=>{n.isServer?ee():i.isEmpty(n.list)?n.isShowInitLoadIng?Ce():e.nextTick(()=>{Re()}):(ee(),n.isShowInitLoadIng||(d.isRunLoading=!1))})};e.onMounted(()=>{e.nextTick(()=>{Nt(),Tt(),Lt(),s.resizeEvent=new it.Resize({isDelay:!0,callback:()=>{ge()}}),n.isFixedHead&&window.addEventListener("scroll",ye)})}),e.onActivated(()=>{n.isFixedHead&&window.addEventListener("scroll",ye),s.resizeEvent||(s.resizeEvent=new it.Resize({isDelay:!0,callback:()=>{ge()}})),ge(),s.pendingCanceled&&(s.pendingCanceled=!1,ee())}),e.onDeactivated(()=>{window.removeEventListener("scroll",ye),s.timerBody&&(clearTimeout(s.timerBody),s.timerBody=null,d.isRunLoading=!1,s.pendingCanceled=!0),s.resizeEvent&&(s.resizeEvent.destroy(),s.resizeEvent=null),R!==null&&(cancelAnimationFrame(R),R=null),H!==null&&(cancelAnimationFrame(H),H=null)}),e.onBeforeUnmount(()=>{s.timerBody&&(clearTimeout(s.timerBody),s.timerBody=null),B.observerBodyScrollY&&(B.observerBodyScrollY.disconnect(),B.observerBodyScrollY.takeRecords(),B.observerBodyScrollY=null),J.value&&($.value&&$.value.removeEventListener("scroll",Ze),h.value&&h.value.removeEventListener("scroll",Qe)),s.resizeEvent&&s.resizeEvent.destroy(),R!==null&&(cancelAnimationFrame(R),R=null),H!==null&&(cancelAnimationFrame(H),H=null),window.removeEventListener("scroll",ye)}),e.watch(()=>n.list,(t,a)=>{const o=i.isEmpty(t)?[]:t;if(s.timerBody&&(clearTimeout(s.timerBody),s.timerBody=null),s.dataJson=i.getJsonByList(o),n.isServer)T.value=i.getListClone(o);else if(n.isParamTriggerServer)T.value=i.getListClone(o,!0);else{s.changeNewPaginate.pages=1;const u=me();T.value=et(u,!0)}const r={};if(n.isElastic){let u=!1;if(a)if(o.length===a.length){const f=new Set(a.map(b=>b?.id));u=o.some(b=>b&&!f.has(b.id))}else u=!0;u||(r.isElasticCloseAll=!1)}_e(r)},{deep:!0}),e.watch(()=>n.columns,()=>{e.nextTick(()=>{we(),e.nextTick(()=>{Le(),Te(),Ee().then(()=>{he()}).catch(t=>{Fe.warn("ClTable","表格固定列分析失败",t)})})})},{deep:!0}),e.watch(()=>n.selectValue,()=>{const t=ce();U.value=fe(t),Ie()}),e.watch(()=>n.orderSort,(t,a)=>{if(t&&t.length>=2&&!(t[0]===s.changeNewSort.orderIndex&&t[1]===s.changeNewSort.orderBy)){const o=A(n.orderSort);s.changeNewPaginate.pages=1,q.pages=1,s.changeNewSort={orderIndex:o[0],orderBy:o[1]},_.value=o,!n.isServer&&n.isParamTriggerServer?de():ee({isChangePage:!1})}},{deep:!0}),e.watch([()=>n.pageOffset,()=>n.paginateLimit],([t,a],[o,r])=>{const u=E();s.changeNewPaginate.pages=u,s.changeNewPaginate.limit=a,q.pages=u,q.limit=a,!n.isServer&&n.isParamTriggerServer?de():ee({isChangePage:!0})});const We=()=>{if(n.disabled)return;const t=!K.value;let a=[];if(t){const o=ue(),r=U.value,u=[];o.forEach(f=>{i.isExistValue(r,f)||u.push(f)}),a=r.concat(u)}K.value=t,U.value=a,Be()},Pe=(t,a,o)=>{n.disabled||d.isRunLoading||(s.changeNewPaginate.pages=1,q.pages=1,s.changeNewSort.orderIndex=a,s.changeNewSort.orderBy=o,!n.isServer&&n.isParamTriggerServer?de():ee({isChangePage:!1}))},$e=(t,a,o)=>{if(!a||i.isEmpty(a)||i.isBoolean(a.isDisabled)&&a.isDisabled||n.disabled)return;const r=i.isNonEmptyString(n.rowClickKeyInvalid)?V.getParent(t.target,n.rowClickKeyInvalid,t.currentTarget,!1):void 0;if(i.isUndefined(r)){if(n.isElastic){const f=i.isNonEmptyString(n.rowClickKeyElastic)?V.getParent(t.target,n.rowClickKeyElastic,t.currentTarget,!1):void 0;if(i.isUndefined(f))n.isClickRowLinkage&&be(a,o);else{be(a,o,f);return}}let u=!1;if(d.isCheckedRadio||d.isCheckedCheckbox){let f=V.getParent(t.target,".th-rc",t.currentTarget,!1);f===t.currentTarget&&(f=null),i.isUndefined(f)?n.isClickRowLinkage&&Ke(a):(u=!0,Ke(a))}Ct(a,o,u)}},ie=(t,a=-1)=>{d.hoverTrIndex=t,d.hoverTrElasticIndex=a},ne=()=>{d.hoverTrIndex=-1,d.hoverTrElasticIndex=-1},Ot=(t,a)=>{n.disabled||d.isRunLoading||n.isPaginate&&(s.changeNewPaginate.pages=t,s.changeNewPaginate.limit=a,!n.isServer&&n.isParamTriggerServer?de():ee({isChangePage:!0}))},tt=t=>{Ne(t)};return m({getParamInfo:()=>me(),refresh:(t=!0)=>{d.isRunLoading||(t&&(s.changeNewPaginate.pages=1),ee())},getData:()=>{const t=e.toRaw(T.value);return i.getListClone(t)},getDataAll:()=>{if(n.isServer){const t=e.toRaw(T.value);return i.getListClone(t)}return i.getListClone(s.sortLocalData)},getSelectData:()=>{const t=je();return{ids:(t?.checkedIds||[]).join(","),list:t?.checkedData||[]}},loadStart:()=>{Ce()},loadStop:()=>{ze()},loadElasticStart:t=>{i.isUndefined(t)||t===null||Je(t.toString())},loadElasticStop:t=>{i.isUndefined(t)||t===null||Ye(t.toString())},closeElastic:(t,a,o)=>{if(i.isEmpty(t)||i.isEmpty(t.id))return;const r=t.id.toString();if(P.open.indexOf(r)===-1)return;const u=o||(h.value?h.value.querySelector(`[data-elastic-id="${CSS.escape(r)}"]`):null);be(t,a,u,!1)},refreshResize:()=>{ge()}}),(t,a)=>(e.openBlock(),e.createElementBlock("div",{id:e.unref(Z),class:e.normalizeClass(ht.value)},[e.createElementVNode("div",cl,[l.isHead?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[e.createElementVNode("div",{class:e.normalizeClass(mt.value),style:e.normalizeStyle({width:p.width}),ref_key:"refElHeadWrapper",ref:Y},[e.createElementVNode("div",{class:e.normalizeClass(gt.value),ref_key:"refElHeadContainer",ref:z},[e.createElementVNode("div",{class:"table-head-main",ref_key:"refElHeadMain",ref:$},[e.createVNode(Ve,{minWidth:c.minWidth,columns:l.columns,isOrder:l.isOrder,orderSort:_.value,isShowTotal:oe.value,totalInfo:l.totalData,keyIndex:X,hoverIndex:d.hoverTrIndex,isUseScrollX:J.value,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isShowCheckboxAll:pe.value,disabled:l.disabled,checkboxAllValue:K.value,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickAll:We,onOnClickOrderBy:Pe,onOnHoverIn:ie,onOnHoverOut:ne,ref_key:"refElHeadTable",ref:g},e.createSlots({_:2},[e.renderList(ve.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data})])})),e.renderList(Se.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data})])}))]),1032,["minWidth","columns","isOrder","orderSort","isShowTotal","totalInfo","hoverIndex","isUseScrollX","isShowRadio","isShowCheckbox","isShowCheckboxAll","disabled","checkboxAllValue","isInlineWidth","widthClassPrefix","widthMinClassPrefix"])],512),F.value&&y.leftColumnLength>0?(e.openBlock(),e.createElementBlock("div",dl,[e.createElementVNode("div",{class:"table-fixed-column-left-container",style:e.normalizeStyle({width:y.leftWidth})},[e.createVNode(Ve,{fixedType:"left",fixedLeftIndex:l.fixedColumnLeftIndex,width:y.totalWidth,columns:l.columns,isOrder:l.isOrder,orderSort:_.value,isShowTotal:oe.value,totalInfo:l.totalData,keyIndex:X,hoverIndex:d.hoverTrIndex,isUseScrollX:J.value,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isShowCheckboxAll:pe.value,disabled:l.disabled,checkboxAllValue:K.value,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickAll:We,onOnClickOrderBy:Pe,onOnHoverIn:ie,onOnHoverOut:ne},e.createSlots({_:2},[e.renderList(ve.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data})])})),e.renderList(Se.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.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)),D.value&&y.rightColumnLength>0?(e.openBlock(),e.createElementBlock("div",ul,[e.createElementVNode("div",{class:"table-fixed-column-right-container",style:e.normalizeStyle({width:y.rightWidth})},[e.createVNode(Ve,{fixedType:"right",fixedRightIndex:l.fixedColumnRightIndex,width:y.totalWidth,columns:l.columns,isOrder:l.isOrder,orderSort:_.value,keyIndex:X,hoverIndex:d.hoverTrIndex,isShowTotal:oe.value,totalInfo:l.totalData,isUseScrollX:J.value,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isShowCheckboxAll:pe.value,disabled:l.disabled,checkboxAllValue:K.value,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickAll:We,onOnClickOrderBy:Pe,onOnHoverIn:ie,onOnHoverOut:ne},e.createSlots({_:2},[e.renderList(ve.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data})])})),e.renderList(Se.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.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),C.value?(e.openBlock(),e.createElementBlock("div",fl,[a[0]||(a[0]=e.createElementVNode("div",null,null,-1)),oe.value?(e.openBlock(),e.createElementBlock("div",{key:0,class:"table-scroll-occupy-total",style:e.normalizeStyle({height:d.totalHeight})},null,4)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),l.isScrollX?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass({"table-scroll-occupy-corner":c.isShow})},null,2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),l.isScrollX?e.withDirectives((e.openBlock(),e.createElementBlock("div",hl,[e.createVNode(at._sfc_main,{isShowLeft:F.value,isShowRight:D.value,leftWidth:y.leftWidth,centerWidth:y.centerWidth,rightWidth:y.rightWidth,isShowCorner:C.value,cornerType:"right-top",onOnScrollX:tt,ref_key:"refElHeadFixedScrollX",ref:k},null,8,["isShowLeft","isShowRight","leftWidth","centerWidth","rightWidth","isShowCorner"])],512)),[[e.vShow,c.isShow]]):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64)),p.isShow&&d.isRunLoading?(e.openBlock(),e.createElementBlock("div",ml)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:5},[],64))],6),p.isShow?(e.openBlock(),e.createElementBlock("div",{key:0,style:e.normalizeStyle({height:p.height,width:p.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(yt.value),ref_key:"refElBodyWrapper",ref:W},[e.createElementVNode("div",{class:"table-body-container",style:e.normalizeStyle(vt.value),ref_key:"refElBodyContainer",ref:j},[e.createElementVNode("div",{class:e.normalizeClass({"table-body-main":!0,"table-body-empty":T.value.length===0}),style:e.normalizeStyle(xt.value),ref_key:"refElBodyMain",ref:h},[e.createVNode(Xe,{minWidth:c.minWidth,columns:l.columns,list:T.value,disabled:l.disabled,isOrder:l.isOrder,selectValue:U.value,keyIndex:X,hoverIndex:d.hoverTrIndex,hoverElasticIndex:d.hoverTrElasticIndex,isUseScrollX:J.value,colspanCount:d.colspanCount,isRunLoading:d.isRunLoading,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isElastic:l.isElastic,elasticOpen:P.open,elasticLoading:P.loading,elasticType:l.elasticType,elasticData:l.elasticData,trIntervalNum:l.trIntervalNum,isStriped:l.isStriped,emptyText:l.emptyText,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickTr:$e,onOnHoverIn:ie,onOnHoverOut:ne,ref_key:"refElBodyTable",ref:v},e.createSlots({_:2},[e.renderList(xe.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex})])})),e.renderList(ke.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex,trElasticInx:r.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),F.value&&y.leftColumnLength>0?(e.openBlock(),e.createElementBlock("div",gl,[e.createElementVNode("div",{class:"table-fixed-column-left-container",style:e.normalizeStyle({width:y.leftWidth})},[e.createVNode(Xe,{width:y.totalWidth,fixedType:"left",fixedLeftIndex:l.fixedColumnLeftIndex,columns:l.columns,list:T.value,disabled:l.disabled,isOrder:l.isOrder,selectValue:U.value,keyIndex:X,hoverIndex:d.hoverTrIndex,hoverElasticIndex:d.hoverTrElasticIndex,isUseScrollX:J.value,colspanCount:d.colspanCount,isRunLoading:d.isRunLoading,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isElastic:l.isElastic,elasticOpen:P.open,elasticLoading:P.loading,elasticType:l.elasticType,elasticData:l.elasticData,trIntervalNum:l.trIntervalNum,isStriped:l.isStriped,emptyText:l.emptyText,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickTr:$e,onOnHoverIn:ie,onOnHoverOut:ne},e.createSlots({_:2},[e.renderList(xe.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex})])})),e.renderList(ke.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex,trElasticInx:r.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)),D.value&&y.rightColumnLength>0?(e.openBlock(),e.createElementBlock("div",yl,[e.createElementVNode("div",{class:"table-fixed-column-right-container",style:e.normalizeStyle({width:y.rightWidth})},[e.createVNode(Xe,{width:y.totalWidth,fixedType:"right",fixedRightIndex:l.fixedColumnRightIndex,columns:l.columns,list:T.value,disabled:l.disabled,isOrder:l.isOrder,selectValue:U.value,keyIndex:X,hoverIndex:d.hoverTrIndex,hoverElasticIndex:d.hoverTrElasticIndex,isUseScrollX:J.value,colspanCount:d.colspanCount,isRunLoading:d.isRunLoading,isShowRadio:d.isCheckedRadio,isShowCheckbox:d.isCheckedCheckbox,isElastic:l.isElastic,elasticOpen:P.open,elasticLoading:P.loading,elasticType:l.elasticType,elasticData:l.elasticData,trIntervalNum:l.trIntervalNum,isStriped:l.isStriped,emptyText:l.emptyText,isInlineWidth:l.isInlineWidth,widthClassPrefix:l.widthClassPrefix,widthMinClassPrefix:l.widthMinClassPrefix,onOnClickTr:$e,onOnHoverIn:ie,onOnHoverOut:ne},e.createSlots({_:2},[e.renderList(xe.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex})])})),e.renderList(ke.value,o=>({name:o,fn:e.withCtx(r=>[e.renderSlot(t.$slots,o,{data:r.data,trIndex:r.trIndex,trElasticInx:r.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),l.isScrollX&&T.value.length>0&&c.isShow?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[l.isScrollXBottom?(e.openBlock(),e.createElementBlock("div",{key:0,class:"table-fixed-column-scrollX",style:e.normalizeStyle({bottom:le.value?"-1px":"1px"})},[e.createVNode(at._sfc_main,{isShowLeft:F.value,isShowRight:D.value,leftWidth:y.leftWidth,centerWidth:y.centerWidth,rightWidth:y.rightWidth,isShowCorner:C.value,isShowCover:!1,cornerType:"right-bottom",onOnScrollX:tt,ref_key:"refElBodyFixedScrollX",ref:O},null,8,["isShowLeft","isShowRight","leftWidth","centerWidth","rightWidth","isShowCorner"])],4)):(e.openBlock(),e.createElementBlock("div",vl,[e.createElementVNode("div",{style:e.normalizeStyle({height:`${ot}px`})},null,4)]))],64)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],2),l.isPaginate&&T.value.length>0?(e.openBlock(),e.createElementBlock("div",xl,[a[1]||(a[1]=e.createElementVNode("div",null,null,-1)),e.createVNode(Mt._sfc_main,{currentPage:q.pages,limitValue:q.limit,limitData:l.paginateLimitData,isShowLimit:l.isPaginateLimit,totalCount:ft.value,disabled:l.disabled||d.isRunLoading,onOnChange:Ot},null,8,["currentPage","limitValue","limitData","isShowLimit","totalCount","disabled"])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:3},[],64))]),d.isRunLoading?(e.openBlock(),e.createElementBlock("div",Sl,[e.createElementVNode("div",kl,[e.createElementVNode("div",{class:"table-load-head",style:e.normalizeStyle(St.value)},null,4),e.createElementVNode("div",{class:e.normalizeClass({"table-load-body":!0,"table-load-bg-gray":l.isLoading})},[e.createVNode($t._sfc_main,{isLoadIng:l.isLoading,size:"xxl",theme:l.loadTheme,color:l.loadColor||void 0},null,8,["isLoadIng","theme","color"])],2)])])):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],10,rl))}});module.exports=El;
@@ -17,7 +17,7 @@ import { _ as di } from "../Shared/One.vue_vue_type_script_setup_true_lang-HWXED
17
17
  import { _ as Tt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-DROYOL5-.js";
18
18
  import { a as ci } from "../Shared/language-CZZEj4e3.js";
19
19
  import { _ as ui } from "../Shared/Ing.vue_vue_type_script_setup_true_lang-DLgw8gwh.js";
20
- import { _ as fi } from "../Shared/Index.vue_vue_type_script_setup_true_lang-ChnRq_PS.js";
20
+ import { _ as fi } from "../Shared/Index.vue_vue_type_script_setup_true_lang-B0MJO0JM.js";
21
21
  import { _ as Lt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-sanF-ATY.js";
22
22
  /* empty css */
23
23
  const Pt = (t) => {
@@ -1 +1 @@
1
- "use strict";const e=require("../Shared/Index.vue_vue_type_script_setup_true_lang-BjNP5odR.js");module.exports=e._sfc_main;
1
+ "use strict";const e=require("../Shared/Index.vue_vue_type_script_setup_true_lang-BN9ybiKv.js");module.exports=e._sfc_main;
@@ -1,7 +1,7 @@
1
1
  import '../../styles/Common/Token.css';
2
2
  import '../../styles/Common/Input-base.css';
3
3
  import '../../styles/Web/ClTree.css';
4
- import { _ as f } from "../Shared/Index.vue_vue_type_script_setup_true_lang-neC9NxKi.js";
4
+ import { _ as f } from "../Shared/Index.vue_vue_type_script_setup_true_lang-2Fe9SkjL.js";
5
5
  export {
6
6
  f as default
7
7
  };
@@ -1 +1 @@
1
- "use strict";const e=require("vue"),A=require("@cldemo/ui-kit/common/log"),i=require("@cldemo/ui-kit/common/base"),U=require("@cldemo/ui-kit/common/Element"),R=require("@cldemo/ui-kit/common/Element/Event"),_e=require("../Shared/language-BJ4aVgHI.js"),Z=require("../Shared/Index.vue_vue_type_script_setup_true_lang-D_YbdXMB.js"),Ce=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CYN4r-Mx.js"),Te=require("../Shared/Index.vue_vue_type_script_setup_true_lang-FowII7_3.js"),xe=require("../Shared/Popup.vue_vue_type_script_setup_true_lang-2PS2RvJ7.js"),Se=require("../Shared/Index.vue_vue_type_script_setup_true_lang-2j33Xlwf.js"),Be=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DA4gQfK2.js"),Ve=require("../Shared/Validate.vue_vue_type_script_setup_true_lang-W46p_d7L.js"),Ue=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CFZ5jK-q.js"),we=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CY5fRV6o.js"),ee=require("../Shared/Index.vue_vue_type_script_setup_true_lang-vLqCsSbV.js"),Ie=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CizRrQsH.js"),Oe=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CuJjJvft.js"),Ne=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DgD_gHit.js"),Pe=require("../Shared/Index.vue_vue_type_script_setup_true_lang-Dbf-3Nik.js"),ze=require("../Shared/Index.vue_vue_type_script_setup_true_lang-Ba8Z8fOP.js"),De=require("../Shared/Index.vue_vue_type_script_setup_true_lang-C_7ArHlU.js"),Fe=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CspSZ5L3.js");function Le(c,h){switch(c){case"select":return i.isBoolean(h)?h:!1;case"radio":return!1;case"checkbox":case"selectTag":return!0;case"inputTag":return i.isBoolean(h)?h:!1;default:return!1}}function te(c,h){if(c!==!0)return"";let B="int";if(i.isNumber(h)){const r=Number.parseInt(String(h),10);if(r>0)switch(r.toString()){case"2":B="float2";break;case"3":B="float3";break;default:B="float"}}return B}const Me={class:"xeditable-body"},He={class:"xeditable-form"},qe={key:1,class:"xeditable-element"},$e=["id"],Je={key:0,class:"xeditable-errmsg"},Ae=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:c=>["input","inputNumber","select","selectCascade","textarea","radio","checkbox","selectTag","inputTag","dateTime","slider","customHtml"].indexOf(c)!==-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:c=>["value","icon"].indexOf(c)!==-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(c,{expose:h,emit:B}){const r=c,j=B,z=e.useAttrs(),le=e.useSlots(),{optPageLanguage:D,getPageLanguage:se}=_e.useLanguage();se("xEditable");const f=e.useTemplateRef("refElDropdownLayer"),T=e.useTemplateRef("refElForm"),d=e.useTemplateRef("refElFormEdit"),w=e.useTemplateRef("refElSubmit"),F=e.useTemplateRef("refElCustom"),L=e.useTemplateRef("refElContent"),M=e.useTemplateRef("refElErrMsg"),ie=r.id,n=e.reactive({keyIndex:`xeditable-${i.getRandom(8)}`,showText:"",subUnitValue:"",subUnitValueType:"",showMsg:"",isShowEmpty:!1,isBtnOperateCenter:!1}),u=e.ref({}),_=e.ref([]),C=e.reactive({status:0,startColor:"#FFFF80",endColor:"var(--cl-transparent, rgba(0, 0, 0, 0))"}),s={lastValue:"",runStep:"",isSubmitting:!1,submitValueDataSnapshot:null,isPendingHlight:!1,pendingValue:null,pendingOpt:null,hlightTimer:null,hlightTimer1:null,hlightTimer2:null,resizeEventCustomHtml:null,resizeEventErrMsg:null,resizeEventContent:null},K=e.computed(()=>{const{type:l}=r;return l==="input"||l==="inputNumber"||l==="select"}),H=e.computed(()=>!i.isUndefined(le.iconLabel)),ae=e.computed(()=>{let l={"panel-x-editable":!0};return l=i.getJsonMerge(l,U.getClassNameJson(r.className)),i.getStringByJson(l," ")}),ne=e.computed(()=>{const l=["xeditable-value"];return n.isShowEmpty&&l.push("xeditable-empty"),(r.isShowEditIcon||H.value)&&l.push("xeditable-edit-icon"),l.join(" ")}),re=e.computed(()=>{const l=["xeditable-value-label"],{clickEditPoint:t}=r;return t==="value"||n.isShowEmpty?l.push("dropdownLayer-arrow-anchorPoint"):l.push("xeditable-click-invalid"),l.join(" ")}),ue=e.computed(()=>{const l=["xeditable-value-editIcon","dropdownLayer-arrow-anchorPoint"];return H.value&&l.push("xeditable-value-editIcon-slot"),l.join(" ")}),oe=e.computed(()=>{const l=["xeditable-ellipsis"];return l.push(r.classNameEllipsis),C.status===2&&l.push("xeditable-value-hlight"),l.join(" ")}),ce=e.computed(()=>{const l=["xeditable-dropdown"];return l.push(`xeditable-dropdown-${r.type}`),l.join(" ")}),me=e.computed(()=>{const l={};return n.isBtnOperateCenter&&(l["text-align"]="center"),l}),X=e.computed(()=>{const l={};switch(C.status){case 1:l["background-color"]=C.startColor;break;case 2:l["background-color"]=C.endColor;break}return l}),pe=l=>{const t=U.getElementData(z);j("onSubmit",l,t)},de=l=>{e.nextTick(()=>{const t=U.getElementData(z);j("onChangeOpen",l,t)})},I=()=>{f.value&&f.value.setOpen(!1),w.value&&w.value.loadStop()},q=l=>{n.showMsg=i.isEmpty(l)?"":l,e.nextTick(()=>{f.value&&f.value.calculationPosition()})},G=()=>Le(r.type,u.value.multiple),Q=()=>{const l=i.getJsonClone(r.subUnitOptions);switch(r.type){case"input":{let t={isClean:!0};t=i.getJsonMerge(t,l);const a=i.isBoolean(t.isNumber)?t.isNumber:!1;n.subUnitValueType=te(a,t.decimal),u.value=t;break}case"inputNumber":{let t={isNumber:!0,isClean:!0};t=i.getJsonMerge(t,l);const a=te(!0,t.decimal)||"int";n.subUnitValueType=a,u.value=t;break}case"select":{let t={multiple:!1,placeholder:D.value.common.pleaseSelect};t=i.getJsonMerge(t,l),u.value=t;break}case"selectCascade":{let t={};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"textarea":{let t={isClean:!0};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"radio":{let t={isInline:!0,name:`${n.keyIndex}-radio`};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=t.isInline;break}case"checkbox":{let t={isInline:!1,name:`${n.keyIndex}-checkbox`};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=t.isInline;break}case"selectTag":{let t={type:"radio"};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"inputTag":{let t={multiple:!0,isAutofill:!0};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"dateTime":{let t={isDropdown:!1};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"slider":{let t={};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"customHtml":{n.isBtnOperateCenter=!0;break}}},O=(l,t)=>{let a=!1,o=!1;t&&(i.isUndefined(t.label)||(a=!0),i.isUndefined(t.list)||(o=!0));let p="",v="",m="";switch(i.isString(l)?m=l:i.isNumber(l)&&i.isFinite(l)&&l!==void 0&&(m=l.toString()),r.type){case"input":case"inputNumber":case"textarea":{if(!a&&m&&!i.isEmpty(m))if((r.type==="inputNumber"||r.type==="input"&&i.isBoolean(u.value.isNumber)&&u.value.isNumber)&&i.isNumber(m)){const k=n.subUnitValueType==="float"?u.value.decimal:"";p=i.getValueByFormat(m,n.subUnitValueType,{decimalNum:k})}else p=m;v=m;break}case"selectCascade":{if(!a){const E=o?t.list:_.value,k=i.isNonEmptyString(u.value.parentKey)?u.value.parentKey:"parentId",S=i.isNonEmptyString(u.value.topParentValue)?u.value.topParentValue:"0";if(m&&!i.isEmpty(m)){const N={};i.isArray(E)&&E.forEach(y=>{!i.isUndefined(y)&&!i.isUndefined(y.id)&&(N[y.id.toString()]=y)});const V=[],P={};let g=m.toString();for(;!i.isEmpty(g)&&!i.isExistJsonKey(P,g)&&i.isExistJsonKey(N,g);){P[g]=!0;const y=N[g];i.isEmpty(y.name)?(i.isNumber(y.name)||i.isString(y.name))&&V.push(y.name.toString()):V.push(y.name),g=y[k]!==void 0&&y[k]!==null?y[k].toString():"",g===S&&(g="")}V.reverse(),p=V.join(" → ")}}v=m;break}case"select":case"radio":case"checkbox":case"selectTag":case"inputTag":{const E=o?t.list:i.isArray(u.value.list)?u.value.list:_.value;if(!a&&m&&!i.isEmpty(m))if(r.type==="inputTag")p=m;else{const k=G(),S=[],N=k?m.split(","):[m.toString()],V=i.isArray(E)?E.filter(g=>!i.isUndefined(g)&&!i.isUndefined(g.id)):E,P=i.getJsonByList(V);N.forEach(g=>{i.isExistJsonKey(P,g)&&S.push(P[g].name)}),p=S.join(",")}v=m;break}case"dateTime":{a||(p=m),v=m;break}case"slider":{a||(p=m),v=m;break}}r.isSubmitCleanValue&&(v="",T.value&&T.value.reset()),n.showText=a?t.label.toString():p,n.subUnitValue=v,n.isShowEmpty=i.isEmpty(n.showText),s.lastValue=n.subUnitValue,o&&(_.value=t.list)},fe=()=>{s.hlightTimer&&(clearTimeout(s.hlightTimer),s.hlightTimer=null),s.hlightTimer1&&clearTimeout(s.hlightTimer1),s.hlightTimer2&&clearTimeout(s.hlightTimer2),C.status=1,e.nextTick(()=>{s.hlightTimer1=setTimeout(()=>{C.status=2},10),s.hlightTimer2=setTimeout(()=>{C.status=0},1500)})},W=()=>{s.isPendingHlight=!1,s.pendingOpt!==null&&O(s.pendingValue,s.pendingOpt||{}),s.pendingValue=null,s.pendingOpt=null,fe()},x=l=>{if(i.isBoolean(l)?l={success:l}:(i.isUndefined(l)||!i.isObject(l))&&(l={success:!1}),l.success){q(""),T.value&&T.value.reset();let t=null;s.submitValueDataSnapshot?t=s.submitValueDataSnapshot:d.value&&(t=d.value.getValueData()),i.isUndefined(t)&&(t={});let a="";const o={},p=i.isEmpty(l.data)?{}:l.data,v=i.isUndefined(p.label),m=!v&&(i.isString(p.label)||i.isNumber(p.label));switch(o.label=m?p.label:null,r.type){case"input":case"inputNumber":case"textarea":case"dateTime":case"slider":a=t.value;break;case"selectCascade":{v&&(o.label=t.show||t.value||""),a=t.value?t.value.toString():"",i.isArray(p.list)&&(o.list=p.list);break}case"select":case"radio":case"checkbox":case"selectTag":case"inputTag":{if(G()&&i.isArray(t)){const E=[],k=[];t.forEach(S=>{E.push(S.id),k.push(S.name)}),v&&(o.label=k.join(",")),a=r.type==="inputTag"?k.join(","):E.join(",")}else v&&(o.label=t.name||""),a=r.type==="inputTag"?t.name||"":t.id?t.id.toString():"";i.isArray(p.list)&&(o.list=p.list);break}}s.runStep!=="updateProps"?(s.pendingValue=a,s.pendingOpt=o,s.isPendingHlight=!0,I()):(O(a,o),I()),s.hlightTimer&&clearTimeout(s.hlightTimer),s.hlightTimer=setTimeout(()=>{s.hlightTimer=null,s.isPendingHlight&&(s.isPendingHlight=!1,W())},400)}else q(l.msg),e.nextTick(()=>{w.value&&w.value.loadStop()});s.isSubmitting=!1},ve=()=>{Q(),O(r.value,{label:r.label,list:r.subUnitList})},ge=async()=>{let l=!1;if(r.isCheckValidate&&T.value){try{l=await T.value.validate()===!0}catch(t){l=!1,A.warn("ClXEditable","表单校验执行异常",t)}if(r.checkValidateCallback&&i.isFunction(r.checkValidateCallback)){const t=U.getElementData(z),a=J();let o=!0;try{o=await r.checkValidateCallback(a,t)}catch(p){o=!1,A.warn("ClXEditable","checkValidateCallback 执行异常",p)}o=i.isBoolean(o)?o:!0,o||(l=!1)}}else l=!0;return l},$=()=>{let l=!1;return r.submitCallback&&i.isFunction(r.submitCallback)&&(l=!0),l},J=()=>{let l="";return r.type!=="customHtml"&&(l=d.value?d.value.getValue():""),l},Y=()=>{if($()){const l=J(),t=U.getElementData(z),a=r.submitCallback?r.submitCallback(l,t):void 0;if(a&&i.isFunction(a.then))a.then(o=>{x(i.isBoolean(o)?{success:o}:o)}).catch(()=>{x({success:!1,msg:D.value.submitCallback})});else{let o={};i.isUndefined(a)?o={success:!0}:i.isBoolean(a)?o={success:a}:i.isObject(a)&&i.isBoolean(a.success)?o=a:o={success:!1,msg:D.value.submitCallback},x(o)}}};e.onMounted(()=>{e.nextTick(()=>{ve()})}),e.onUnmounted(()=>{s.hlightTimer&&clearTimeout(s.hlightTimer),s.hlightTimer1&&clearTimeout(s.hlightTimer1),s.hlightTimer2&&clearTimeout(s.hlightTimer2),s.resizeEventCustomHtml&&(s.resizeEventCustomHtml.destroy(),s.resizeEventCustomHtml=null),s.resizeEventErrMsg&&(s.resizeEventErrMsg.destroy(),s.resizeEventErrMsg=null),s.resizeEventContent&&(s.resizeEventContent.destroy(),s.resizeEventContent=null)}),e.watch([()=>r.value,()=>r.label,()=>r.subUnitList],([l,t,a],[o,p,v])=>{(l!==o||t!==p||a!==v)&&(l!==o&&(s.runStep="updateProps"),O(l,{label:t,list:a}))}),e.watch(()=>r.subUnitOptions,()=>{Q(),O(n.subUnitValue,{label:r.label,list:r.subUnitList})});const be=()=>{s.isSubmitting||(s.isSubmitting=!0,d.value&&(s.submitValueDataSnapshot=d.value.getValueData()),ge().then(l=>{if(l)if(r.type==="customHtml")s.runStep="first",$()?Y():(A.warn("ClXEditable","customHtml 类型必须配置 submitCallback 才能提交"),s.isSubmitting=!1,I());else{const t=J(),a=i.isEmpty(t);String(t)!==s.lastValue||a&&n.showText.length>0?(s.runStep="first",$()?Y():(r.isUseOnSubmitCheck||x({success:!0}),pe(t))):(s.isSubmitting=!1,I())}else x({success:!1})}).catch(()=>{x({success:!1})}))},ye=()=>{I()},b=()=>{f.value&&(f.value.checkIsShowOpen()||f.value.initCompleteOpen())},ke=()=>{s.isPendingHlight&&(s.isPendingHlight=!1,s.hlightTimer&&(clearTimeout(s.hlightTimer),s.hlightTimer=null),s.hlightTimer=setTimeout(()=>{s.hlightTimer=null,W()},150))},Ee=l=>{l?(s.lastValue=n.subUnitValue,q(""),e.nextTick(()=>{f.value&&f.value.checkIsShowOpen()&&(r.type==="customHtml"?(b(),F.value&&(s.resizeEventCustomHtml&&s.resizeEventCustomHtml.destroy(),s.resizeEventCustomHtml=new R.Resize({element:F.value,callback:()=>{f.value&&f.value.calculationPosition()}}))):(L.value&&(s.resizeEventContent&&s.resizeEventContent.destroy(),s.resizeEventContent=new R.Resize({element:L.value,callback:()=>{f.value&&f.value.calculationPosition()}})),M.value&&(s.resizeEventErrMsg&&s.resizeEventErrMsg.destroy(),s.resizeEventErrMsg=new R.Resize({element:M.value,callback:()=>{f.value&&f.value.calculationPosition()}}))))})):(s.isPendingHlight||(n.subUnitValue=s.lastValue),s.resizeEventCustomHtml&&(s.resizeEventCustomHtml.destroy(),s.resizeEventCustomHtml=null),s.resizeEventErrMsg&&(s.resizeEventErrMsg.destroy(),s.resizeEventErrMsg=null),s.resizeEventContent&&(s.resizeEventContent.destroy(),s.resizeEventContent=null)),de(l)},he=l=>{const t=U.getParent(l.target,".xeditable-click-invalid",l.currentTarget,!1);i.isUndefined(t)||(l.preventDefault(),l.stopPropagation())};return h({setOnSubmitResult:l=>{r.isUseOnSubmitCheck&&i.isUndefined(r.submitCallback)&&s.isSubmitting&&x(l)}}),(l,t)=>(e.openBlock(),e.createBlock(xe._sfc_main,{ref_key:"refElDropdownLayer",ref:f,id:e.unref(ie),classParent:ae.value,classText:c.classNameLabel,classDropDown:ce.value,dropdownArrowPos:"center",dropDownPos:"up",isUseDropdownArrow:!0,isCloseDestroy:!0,isInitDelayComplete:!0,appendContainer:c.appendContainer,onOnChangeOpen:Ee,onOnAfterLeave:ke,transitionEnter:"animated fadeIn",transitionLeave:"animated fadeOut"},{label:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(ne.value)},[c.isShowEditValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(re.value),onClick:t[0]||(t[0]=a=>he(a))},[c.isUseEllipsis&&n.showText.length>0?(e.openBlock(),e.createBlock(Se._sfc_main,{key:0,className:oe.value,isUseTooltipAuto:c.isAutoTooltip,text:n.showText,style:e.normalizeStyle(X.value)},null,8,["className","isUseTooltipAuto","text","style"])):(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass({"xeditable-value-hlight":C.status===2}),style:e.normalizeStyle(X.value)},e.toDisplayString(n.showText),7))],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),c.isShowEditIcon||H.value?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(ue.value)},[e.renderSlot(l.$slots,"iconLabel",{},()=>[e.createVNode(Ue._sfc_main,{name:c.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:L,class:"xeditable-content"},[e.createElementVNode("div",Me,[e.createElementVNode("div",He,[e.createVNode(Be._sfc_main,{ref_key:"refElForm",ref:T,isScrollToErr:!1},{default:e.withCtx(()=>[c.type==="customHtml"?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"refElCustom",ref:F,class:"xeditable-custom"},[e.renderSlot(l.$slots,"customForm")],512)):(e.openBlock(),e.createElementBlock("div",qe,[e.createVNode(Ve._sfc_main,{isCheck:c.isCheckValidate,checkValue:n.subUnitValue,rules:c.validateRules,msgElementId:K.value?`#${n.keyIndex}_errmsg`:""},{default:e.withCtx(()=>[c.type==="inputNumber"?(e.openBlock(),e.createBlock(ee._sfc_main,e.mergeProps({key:0,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[1]||(t[1]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="input"&&u.value.isNumber?(e.openBlock(),e.createBlock(ee._sfc_main,e.mergeProps({key:1,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[2]||(t[2]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="input"?(e.openBlock(),e.createBlock(we._sfc_main,e.mergeProps({key:2,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[3]||(t[3]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="textarea"?(e.openBlock(),e.createBlock(Oe._sfc_main,e.mergeProps({key:3,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[4]||(t[4]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="select"?(e.openBlock(),e.createBlock(Pe._sfc_main,e.mergeProps({key:4,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[5]||(t[5]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="selectCascade"?(e.openBlock(),e.createBlock(ze._sfc_main,e.mergeProps({key:5,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[6]||(t[6]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="radio"?(e.openBlock(),e.createBlock(Ne._sfc_main,e.mergeProps({key:6,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[7]||(t[7]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="checkbox"?(e.openBlock(),e.createBlock(Ce._sfc_main,e.mergeProps({key:7,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[8]||(t[8]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="selectTag"?(e.openBlock(),e.createBlock(De._sfc_main,e.mergeProps({key:8,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[9]||(t[9]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="inputTag"?(e.openBlock(),e.createBlock(Ie._sfc_main,e.mergeProps({key:9,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[10]||(t[10]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="dateTime"?(e.openBlock(),e.createBlock(Te._sfc_main,e.mergeProps({key:10,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[11]||(t[11]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="slider"?(e.openBlock(),e.createBlock(Fe._sfc_main,e.mergeProps({key:11,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[12]||(t[12]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),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(me.value)},[e.createVNode(Z._sfc_main,{ref_key:"refElSubmit",ref:w,iconName:"check",isShowLoad:!0,loadPos:"zoom-out",loadTheme:"rotaryLine",onOnClick:be},null,512),e.createVNode(Z._sfc_main,{iconName:"close",color:"grayLight",onOnClick:ye})],4)]),K.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c.isCheckValidate?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"refElErrMsg",ref:M,id:`${n.keyIndex}_errmsg`,class:"xeditable-errmsg"},null,8,$e)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n.showMsg.length>0?(e.openBlock(),e.createElementBlock("div",Je,e.toDisplayString(n.showMsg),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))],64)):e.createCommentVNode("",!0)],512)]),_:3},8,["id","classParent","classText","classDropDown","appendContainer"]))}});module.exports=Ae;
1
+ "use strict";const e=require("vue"),A=require("@cldemo/ui-kit/common/log"),i=require("@cldemo/ui-kit/common/base"),U=require("@cldemo/ui-kit/common/Element"),R=require("@cldemo/ui-kit/common/Element/Event"),_e=require("../Shared/language-BJ4aVgHI.js"),Z=require("../Shared/Index.vue_vue_type_script_setup_true_lang-D_YbdXMB.js"),Ce=require("../Shared/Index.vue_vue_type_script_setup_true_lang-BpG7AHvM.js"),Te=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DY4m6Xyj.js"),xe=require("../Shared/Popup.vue_vue_type_script_setup_true_lang-2PS2RvJ7.js"),Se=require("../Shared/Index.vue_vue_type_script_setup_true_lang-2j33Xlwf.js"),Be=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DA4gQfK2.js"),Ve=require("../Shared/Validate.vue_vue_type_script_setup_true_lang-W46p_d7L.js"),Ue=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CFZ5jK-q.js"),we=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DXPZYc0c.js"),ee=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CW4fM0by.js"),Ie=require("../Shared/Index.vue_vue_type_script_setup_true_lang-oovIcT38.js"),Oe=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CsCn637u.js"),Ne=require("../Shared/Index.vue_vue_type_script_setup_true_lang-De1eNjwC.js"),Pe=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DvN-fBNd.js"),ze=require("../Shared/Index.vue_vue_type_script_setup_true_lang-DwBf338f.js"),De=require("../Shared/Index.vue_vue_type_script_setup_true_lang-5itnjwU_.js"),Fe=require("../Shared/Index.vue_vue_type_script_setup_true_lang-CspSZ5L3.js");function Le(c,h){switch(c){case"select":return i.isBoolean(h)?h:!1;case"radio":return!1;case"checkbox":case"selectTag":return!0;case"inputTag":return i.isBoolean(h)?h:!1;default:return!1}}function te(c,h){if(c!==!0)return"";let B="int";if(i.isNumber(h)){const r=Number.parseInt(String(h),10);if(r>0)switch(r.toString()){case"2":B="float2";break;case"3":B="float3";break;default:B="float"}}return B}const Me={class:"xeditable-body"},He={class:"xeditable-form"},qe={key:1,class:"xeditable-element"},$e=["id"],Je={key:0,class:"xeditable-errmsg"},Ae=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:c=>["input","inputNumber","select","selectCascade","textarea","radio","checkbox","selectTag","inputTag","dateTime","slider","customHtml"].indexOf(c)!==-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:c=>["value","icon"].indexOf(c)!==-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(c,{expose:h,emit:B}){const r=c,j=B,z=e.useAttrs(),le=e.useSlots(),{optPageLanguage:D,getPageLanguage:se}=_e.useLanguage();se("xEditable");const f=e.useTemplateRef("refElDropdownLayer"),T=e.useTemplateRef("refElForm"),d=e.useTemplateRef("refElFormEdit"),w=e.useTemplateRef("refElSubmit"),F=e.useTemplateRef("refElCustom"),L=e.useTemplateRef("refElContent"),M=e.useTemplateRef("refElErrMsg"),ie=r.id,n=e.reactive({keyIndex:`xeditable-${i.getRandom(8)}`,showText:"",subUnitValue:"",subUnitValueType:"",showMsg:"",isShowEmpty:!1,isBtnOperateCenter:!1}),u=e.ref({}),_=e.ref([]),C=e.reactive({status:0,startColor:"#FFFF80",endColor:"var(--cl-transparent, rgba(0, 0, 0, 0))"}),s={lastValue:"",runStep:"",isSubmitting:!1,submitValueDataSnapshot:null,isPendingHlight:!1,pendingValue:null,pendingOpt:null,hlightTimer:null,hlightTimer1:null,hlightTimer2:null,resizeEventCustomHtml:null,resizeEventErrMsg:null,resizeEventContent:null},K=e.computed(()=>{const{type:l}=r;return l==="input"||l==="inputNumber"||l==="select"}),H=e.computed(()=>!i.isUndefined(le.iconLabel)),ae=e.computed(()=>{let l={"panel-x-editable":!0};return l=i.getJsonMerge(l,U.getClassNameJson(r.className)),i.getStringByJson(l," ")}),ne=e.computed(()=>{const l=["xeditable-value"];return n.isShowEmpty&&l.push("xeditable-empty"),(r.isShowEditIcon||H.value)&&l.push("xeditable-edit-icon"),l.join(" ")}),re=e.computed(()=>{const l=["xeditable-value-label"],{clickEditPoint:t}=r;return t==="value"||n.isShowEmpty?l.push("dropdownLayer-arrow-anchorPoint"):l.push("xeditable-click-invalid"),l.join(" ")}),ue=e.computed(()=>{const l=["xeditable-value-editIcon","dropdownLayer-arrow-anchorPoint"];return H.value&&l.push("xeditable-value-editIcon-slot"),l.join(" ")}),oe=e.computed(()=>{const l=["xeditable-ellipsis"];return l.push(r.classNameEllipsis),C.status===2&&l.push("xeditable-value-hlight"),l.join(" ")}),ce=e.computed(()=>{const l=["xeditable-dropdown"];return l.push(`xeditable-dropdown-${r.type}`),l.join(" ")}),me=e.computed(()=>{const l={};return n.isBtnOperateCenter&&(l["text-align"]="center"),l}),X=e.computed(()=>{const l={};switch(C.status){case 1:l["background-color"]=C.startColor;break;case 2:l["background-color"]=C.endColor;break}return l}),pe=l=>{const t=U.getElementData(z);j("onSubmit",l,t)},de=l=>{e.nextTick(()=>{const t=U.getElementData(z);j("onChangeOpen",l,t)})},I=()=>{f.value&&f.value.setOpen(!1),w.value&&w.value.loadStop()},q=l=>{n.showMsg=i.isEmpty(l)?"":l,e.nextTick(()=>{f.value&&f.value.calculationPosition()})},G=()=>Le(r.type,u.value.multiple),Q=()=>{const l=i.getJsonClone(r.subUnitOptions);switch(r.type){case"input":{let t={isClean:!0};t=i.getJsonMerge(t,l);const a=i.isBoolean(t.isNumber)?t.isNumber:!1;n.subUnitValueType=te(a,t.decimal),u.value=t;break}case"inputNumber":{let t={isNumber:!0,isClean:!0};t=i.getJsonMerge(t,l);const a=te(!0,t.decimal)||"int";n.subUnitValueType=a,u.value=t;break}case"select":{let t={multiple:!1,placeholder:D.value.common.pleaseSelect};t=i.getJsonMerge(t,l),u.value=t;break}case"selectCascade":{let t={};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"textarea":{let t={isClean:!0};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"radio":{let t={isInline:!0,name:`${n.keyIndex}-radio`};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=t.isInline;break}case"checkbox":{let t={isInline:!1,name:`${n.keyIndex}-checkbox`};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=t.isInline;break}case"selectTag":{let t={type:"radio"};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"inputTag":{let t={multiple:!0,isAutofill:!0};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"dateTime":{let t={isDropdown:!1};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"slider":{let t={};t=i.getJsonMerge(t,l),u.value=t,n.isBtnOperateCenter=!0;break}case"customHtml":{n.isBtnOperateCenter=!0;break}}},O=(l,t)=>{let a=!1,o=!1;t&&(i.isUndefined(t.label)||(a=!0),i.isUndefined(t.list)||(o=!0));let p="",v="",m="";switch(i.isString(l)?m=l:i.isNumber(l)&&i.isFinite(l)&&l!==void 0&&(m=l.toString()),r.type){case"input":case"inputNumber":case"textarea":{if(!a&&m&&!i.isEmpty(m))if((r.type==="inputNumber"||r.type==="input"&&i.isBoolean(u.value.isNumber)&&u.value.isNumber)&&i.isNumber(m)){const k=n.subUnitValueType==="float"?u.value.decimal:"";p=i.getValueByFormat(m,n.subUnitValueType,{decimalNum:k})}else p=m;v=m;break}case"selectCascade":{if(!a){const E=o?t.list:_.value,k=i.isNonEmptyString(u.value.parentKey)?u.value.parentKey:"parentId",S=i.isNonEmptyString(u.value.topParentValue)?u.value.topParentValue:"0";if(m&&!i.isEmpty(m)){const N={};i.isArray(E)&&E.forEach(y=>{!i.isUndefined(y)&&!i.isUndefined(y.id)&&(N[y.id.toString()]=y)});const V=[],P={};let g=m.toString();for(;!i.isEmpty(g)&&!i.isExistJsonKey(P,g)&&i.isExistJsonKey(N,g);){P[g]=!0;const y=N[g];i.isEmpty(y.name)?(i.isNumber(y.name)||i.isString(y.name))&&V.push(y.name.toString()):V.push(y.name),g=y[k]!==void 0&&y[k]!==null?y[k].toString():"",g===S&&(g="")}V.reverse(),p=V.join(" → ")}}v=m;break}case"select":case"radio":case"checkbox":case"selectTag":case"inputTag":{const E=o?t.list:i.isArray(u.value.list)?u.value.list:_.value;if(!a&&m&&!i.isEmpty(m))if(r.type==="inputTag")p=m;else{const k=G(),S=[],N=k?m.split(","):[m.toString()],V=i.isArray(E)?E.filter(g=>!i.isUndefined(g)&&!i.isUndefined(g.id)):E,P=i.getJsonByList(V);N.forEach(g=>{i.isExistJsonKey(P,g)&&S.push(P[g].name)}),p=S.join(",")}v=m;break}case"dateTime":{a||(p=m),v=m;break}case"slider":{a||(p=m),v=m;break}}r.isSubmitCleanValue&&(v="",T.value&&T.value.reset()),n.showText=a?t.label.toString():p,n.subUnitValue=v,n.isShowEmpty=i.isEmpty(n.showText),s.lastValue=n.subUnitValue,o&&(_.value=t.list)},fe=()=>{s.hlightTimer&&(clearTimeout(s.hlightTimer),s.hlightTimer=null),s.hlightTimer1&&clearTimeout(s.hlightTimer1),s.hlightTimer2&&clearTimeout(s.hlightTimer2),C.status=1,e.nextTick(()=>{s.hlightTimer1=setTimeout(()=>{C.status=2},10),s.hlightTimer2=setTimeout(()=>{C.status=0},1500)})},W=()=>{s.isPendingHlight=!1,s.pendingOpt!==null&&O(s.pendingValue,s.pendingOpt||{}),s.pendingValue=null,s.pendingOpt=null,fe()},x=l=>{if(i.isBoolean(l)?l={success:l}:(i.isUndefined(l)||!i.isObject(l))&&(l={success:!1}),l.success){q(""),T.value&&T.value.reset();let t=null;s.submitValueDataSnapshot?t=s.submitValueDataSnapshot:d.value&&(t=d.value.getValueData()),i.isUndefined(t)&&(t={});let a="";const o={},p=i.isEmpty(l.data)?{}:l.data,v=i.isUndefined(p.label),m=!v&&(i.isString(p.label)||i.isNumber(p.label));switch(o.label=m?p.label:null,r.type){case"input":case"inputNumber":case"textarea":case"dateTime":case"slider":a=t.value;break;case"selectCascade":{v&&(o.label=t.show||t.value||""),a=t.value?t.value.toString():"",i.isArray(p.list)&&(o.list=p.list);break}case"select":case"radio":case"checkbox":case"selectTag":case"inputTag":{if(G()&&i.isArray(t)){const E=[],k=[];t.forEach(S=>{E.push(S.id),k.push(S.name)}),v&&(o.label=k.join(",")),a=r.type==="inputTag"?k.join(","):E.join(",")}else v&&(o.label=t.name||""),a=r.type==="inputTag"?t.name||"":t.id?t.id.toString():"";i.isArray(p.list)&&(o.list=p.list);break}}s.runStep!=="updateProps"?(s.pendingValue=a,s.pendingOpt=o,s.isPendingHlight=!0,I()):(O(a,o),I()),s.hlightTimer&&clearTimeout(s.hlightTimer),s.hlightTimer=setTimeout(()=>{s.hlightTimer=null,s.isPendingHlight&&(s.isPendingHlight=!1,W())},400)}else q(l.msg),e.nextTick(()=>{w.value&&w.value.loadStop()});s.isSubmitting=!1},ve=()=>{Q(),O(r.value,{label:r.label,list:r.subUnitList})},ge=async()=>{let l=!1;if(r.isCheckValidate&&T.value){try{l=await T.value.validate()===!0}catch(t){l=!1,A.warn("ClXEditable","表单校验执行异常",t)}if(r.checkValidateCallback&&i.isFunction(r.checkValidateCallback)){const t=U.getElementData(z),a=J();let o=!0;try{o=await r.checkValidateCallback(a,t)}catch(p){o=!1,A.warn("ClXEditable","checkValidateCallback 执行异常",p)}o=i.isBoolean(o)?o:!0,o||(l=!1)}}else l=!0;return l},$=()=>{let l=!1;return r.submitCallback&&i.isFunction(r.submitCallback)&&(l=!0),l},J=()=>{let l="";return r.type!=="customHtml"&&(l=d.value?d.value.getValue():""),l},Y=()=>{if($()){const l=J(),t=U.getElementData(z),a=r.submitCallback?r.submitCallback(l,t):void 0;if(a&&i.isFunction(a.then))a.then(o=>{x(i.isBoolean(o)?{success:o}:o)}).catch(()=>{x({success:!1,msg:D.value.submitCallback})});else{let o={};i.isUndefined(a)?o={success:!0}:i.isBoolean(a)?o={success:a}:i.isObject(a)&&i.isBoolean(a.success)?o=a:o={success:!1,msg:D.value.submitCallback},x(o)}}};e.onMounted(()=>{e.nextTick(()=>{ve()})}),e.onUnmounted(()=>{s.hlightTimer&&clearTimeout(s.hlightTimer),s.hlightTimer1&&clearTimeout(s.hlightTimer1),s.hlightTimer2&&clearTimeout(s.hlightTimer2),s.resizeEventCustomHtml&&(s.resizeEventCustomHtml.destroy(),s.resizeEventCustomHtml=null),s.resizeEventErrMsg&&(s.resizeEventErrMsg.destroy(),s.resizeEventErrMsg=null),s.resizeEventContent&&(s.resizeEventContent.destroy(),s.resizeEventContent=null)}),e.watch([()=>r.value,()=>r.label,()=>r.subUnitList],([l,t,a],[o,p,v])=>{(l!==o||t!==p||a!==v)&&(l!==o&&(s.runStep="updateProps"),O(l,{label:t,list:a}))}),e.watch(()=>r.subUnitOptions,()=>{Q(),O(n.subUnitValue,{label:r.label,list:r.subUnitList})});const be=()=>{s.isSubmitting||(s.isSubmitting=!0,d.value&&(s.submitValueDataSnapshot=d.value.getValueData()),ge().then(l=>{if(l)if(r.type==="customHtml")s.runStep="first",$()?Y():(A.warn("ClXEditable","customHtml 类型必须配置 submitCallback 才能提交"),s.isSubmitting=!1,I());else{const t=J(),a=i.isEmpty(t);String(t)!==s.lastValue||a&&n.showText.length>0?(s.runStep="first",$()?Y():(r.isUseOnSubmitCheck||x({success:!0}),pe(t))):(s.isSubmitting=!1,I())}else x({success:!1})}).catch(()=>{x({success:!1})}))},ye=()=>{I()},b=()=>{f.value&&(f.value.checkIsShowOpen()||f.value.initCompleteOpen())},ke=()=>{s.isPendingHlight&&(s.isPendingHlight=!1,s.hlightTimer&&(clearTimeout(s.hlightTimer),s.hlightTimer=null),s.hlightTimer=setTimeout(()=>{s.hlightTimer=null,W()},150))},Ee=l=>{l?(s.lastValue=n.subUnitValue,q(""),e.nextTick(()=>{f.value&&f.value.checkIsShowOpen()&&(r.type==="customHtml"?(b(),F.value&&(s.resizeEventCustomHtml&&s.resizeEventCustomHtml.destroy(),s.resizeEventCustomHtml=new R.Resize({element:F.value,callback:()=>{f.value&&f.value.calculationPosition()}}))):(L.value&&(s.resizeEventContent&&s.resizeEventContent.destroy(),s.resizeEventContent=new R.Resize({element:L.value,callback:()=>{f.value&&f.value.calculationPosition()}})),M.value&&(s.resizeEventErrMsg&&s.resizeEventErrMsg.destroy(),s.resizeEventErrMsg=new R.Resize({element:M.value,callback:()=>{f.value&&f.value.calculationPosition()}}))))})):(s.isPendingHlight||(n.subUnitValue=s.lastValue),s.resizeEventCustomHtml&&(s.resizeEventCustomHtml.destroy(),s.resizeEventCustomHtml=null),s.resizeEventErrMsg&&(s.resizeEventErrMsg.destroy(),s.resizeEventErrMsg=null),s.resizeEventContent&&(s.resizeEventContent.destroy(),s.resizeEventContent=null)),de(l)},he=l=>{const t=U.getParent(l.target,".xeditable-click-invalid",l.currentTarget,!1);i.isUndefined(t)||(l.preventDefault(),l.stopPropagation())};return h({setOnSubmitResult:l=>{r.isUseOnSubmitCheck&&i.isUndefined(r.submitCallback)&&s.isSubmitting&&x(l)}}),(l,t)=>(e.openBlock(),e.createBlock(xe._sfc_main,{ref_key:"refElDropdownLayer",ref:f,id:e.unref(ie),classParent:ae.value,classText:c.classNameLabel,classDropDown:ce.value,dropdownArrowPos:"center",dropDownPos:"up",isUseDropdownArrow:!0,isCloseDestroy:!0,isInitDelayComplete:!0,appendContainer:c.appendContainer,onOnChangeOpen:Ee,onOnAfterLeave:ke,transitionEnter:"animated fadeIn",transitionLeave:"animated fadeOut"},{label:e.withCtx(()=>[e.createElementVNode("div",{class:e.normalizeClass(ne.value)},[c.isShowEditValue?(e.openBlock(),e.createElementBlock("div",{key:0,class:e.normalizeClass(re.value),onClick:t[0]||(t[0]=a=>he(a))},[c.isUseEllipsis&&n.showText.length>0?(e.openBlock(),e.createBlock(Se._sfc_main,{key:0,className:oe.value,isUseTooltipAuto:c.isAutoTooltip,text:n.showText,style:e.normalizeStyle(X.value)},null,8,["className","isUseTooltipAuto","text","style"])):(e.openBlock(),e.createElementBlock("span",{key:1,class:e.normalizeClass({"xeditable-value-hlight":C.status===2}),style:e.normalizeStyle(X.value)},e.toDisplayString(n.showText),7))],2)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64)),c.isShowEditIcon||H.value?(e.openBlock(),e.createElementBlock("div",{key:2,class:e.normalizeClass(ue.value)},[e.renderSlot(l.$slots,"iconLabel",{},()=>[e.createVNode(Ue._sfc_main,{name:c.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:L,class:"xeditable-content"},[e.createElementVNode("div",Me,[e.createElementVNode("div",He,[e.createVNode(Be._sfc_main,{ref_key:"refElForm",ref:T,isScrollToErr:!1},{default:e.withCtx(()=>[c.type==="customHtml"?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"refElCustom",ref:F,class:"xeditable-custom"},[e.renderSlot(l.$slots,"customForm")],512)):(e.openBlock(),e.createElementBlock("div",qe,[e.createVNode(Ve._sfc_main,{isCheck:c.isCheckValidate,checkValue:n.subUnitValue,rules:c.validateRules,msgElementId:K.value?`#${n.keyIndex}_errmsg`:""},{default:e.withCtx(()=>[c.type==="inputNumber"?(e.openBlock(),e.createBlock(ee._sfc_main,e.mergeProps({key:0,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[1]||(t[1]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="input"&&u.value.isNumber?(e.openBlock(),e.createBlock(ee._sfc_main,e.mergeProps({key:1,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[2]||(t[2]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="input"?(e.openBlock(),e.createBlock(we._sfc_main,e.mergeProps({key:2,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[3]||(t[3]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="textarea"?(e.openBlock(),e.createBlock(Oe._sfc_main,e.mergeProps({key:3,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[4]||(t[4]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="select"?(e.openBlock(),e.createBlock(Pe._sfc_main,e.mergeProps({key:4,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[5]||(t[5]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="selectCascade"?(e.openBlock(),e.createBlock(ze._sfc_main,e.mergeProps({key:5,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[6]||(t[6]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="radio"?(e.openBlock(),e.createBlock(Ne._sfc_main,e.mergeProps({key:6,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[7]||(t[7]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="checkbox"?(e.openBlock(),e.createBlock(Ce._sfc_main,e.mergeProps({key:7,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[8]||(t[8]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="selectTag"?(e.openBlock(),e.createBlock(De._sfc_main,e.mergeProps({key:8,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[9]||(t[9]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="inputTag"?(e.openBlock(),e.createBlock(Ie._sfc_main,e.mergeProps({key:9,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[10]||(t[10]=a=>n.subUnitValue=a),list:_.value},u.value,{onOnInit:b}),null,16,["value","list"])):c.type==="dateTime"?(e.openBlock(),e.createBlock(Te._sfc_main,e.mergeProps({key:10,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[11]||(t[11]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),null,16,["value"])):c.type==="slider"?(e.openBlock(),e.createBlock(Fe._sfc_main,e.mergeProps({key:11,ref_key:"refElFormEdit",ref:d,value:n.subUnitValue,"onUpdate:value":t[12]||(t[12]=a=>n.subUnitValue=a)},u.value,{onOnInit:b}),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(me.value)},[e.createVNode(Z._sfc_main,{ref_key:"refElSubmit",ref:w,iconName:"check",isShowLoad:!0,loadPos:"zoom-out",loadTheme:"rotaryLine",onOnClick:be},null,512),e.createVNode(Z._sfc_main,{iconName:"close",color:"grayLight",onOnClick:ye})],4)]),K.value?(e.openBlock(),e.createElementBlock(e.Fragment,{key:0},[c.isCheckValidate?(e.openBlock(),e.createElementBlock("div",{key:0,ref_key:"refElErrMsg",ref:M,id:`${n.keyIndex}_errmsg`,class:"xeditable-errmsg"},null,8,$e)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[n.showMsg.length>0?(e.openBlock(),e.createElementBlock("div",Je,e.toDisplayString(n.showMsg),1)):(e.openBlock(),e.createElementBlock(e.Fragment,{key:1},[],64))],64))],64)):e.createCommentVNode("",!0)],512)]),_:3},8,["id","classParent","classText","classDropDown","appendContainer"]))}});module.exports=Ae;
@@ -14,21 +14,21 @@ import z from "@cldemo/ui-kit/common/Element";
14
14
  import { Resize as le } from "@cldemo/ui-kit/common/Element/Event";
15
15
  import { a as Ke } from "../Shared/language-CZZEj4e3.js";
16
16
  import { _ as ge } from "../Shared/Index.vue_vue_type_script_setup_true_lang-D__hI9ud.js";
17
- import { _ as Xe } from "../Shared/Index.vue_vue_type_script_setup_true_lang-CgdGs-U2.js";
18
- import { _ as qe } from "../Shared/Index.vue_vue_type_script_setup_true_lang-CwjigRBx.js";
17
+ import { _ as Xe } from "../Shared/Index.vue_vue_type_script_setup_true_lang-lKDQFZtY.js";
18
+ import { _ as qe } from "../Shared/Index.vue_vue_type_script_setup_true_lang-DZF2gj7X.js";
19
19
  import { _ as Ge } from "../Shared/Popup.vue_vue_type_script_setup_true_lang-DKmJL9a2.js";
20
20
  import { _ as Qe } from "../Shared/Index.vue_vue_type_script_setup_true_lang-B5nzKNsJ.js";
21
21
  import { _ as We } from "../Shared/Index.vue_vue_type_script_setup_true_lang-ClJgAoET.js";
22
22
  import { _ as Ye } from "../Shared/Validate.vue_vue_type_script_setup_true_lang-Jyse_5LL.js";
23
23
  import { _ as Ze } from "../Shared/Index.vue_vue_type_script_setup_true_lang-C2LGy18j.js";
24
- import { _ as et } from "../Shared/Index.vue_vue_type_script_setup_true_lang-D_XMW7K4.js";
25
- import { _ as ve } from "../Shared/Index.vue_vue_type_script_setup_true_lang-DKMVQrVU.js";
26
- import { _ as tt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-DxYJbPyJ.js";
27
- import { _ as it } from "../Shared/Index.vue_vue_type_script_setup_true_lang-Cg_benGj.js";
28
- import { _ as lt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-c7oxeU_j.js";
29
- import { _ as st } from "../Shared/Index.vue_vue_type_script_setup_true_lang-BO4cal3i.js";
30
- import { _ as at } from "../Shared/Index.vue_vue_type_script_setup_true_lang-CQ3RGLek.js";
31
- import { _ as nt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-C1OgPpoJ.js";
24
+ import { _ as et } from "../Shared/Index.vue_vue_type_script_setup_true_lang-D4a5Iaue.js";
25
+ import { _ as ve } from "../Shared/Index.vue_vue_type_script_setup_true_lang-CATwJnes.js";
26
+ import { _ as tt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-C_exHzjc.js";
27
+ import { _ as it } from "../Shared/Index.vue_vue_type_script_setup_true_lang-F9tBnc_7.js";
28
+ import { _ as lt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-2THK822S.js";
29
+ import { _ as st } from "../Shared/Index.vue_vue_type_script_setup_true_lang-2dwwjiTV.js";
30
+ import { _ as at } from "../Shared/Index.vue_vue_type_script_setup_true_lang-HfnOtuMz.js";
31
+ import { _ as nt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-0S6ab-Lp.js";
32
32
  import { _ as rt } from "../Shared/Index.vue_vue_type_script_setup_true_lang-BfwJynUJ.js";
33
33
  function ut(o, U) {
34
34
  switch (o) {