ss-component-new 1.2.331 → 1.2.333
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.
- package/dist/{MTLLoader-wwr1B193.cjs → MTLLoader-C9zwOo5R.cjs} +1 -1
- package/dist/{MTLLoader-Cp2efv7h.js → MTLLoader-DEhuJ8cA.js} +1 -1
- package/dist/{OrbitControls-Dk0u7TVO.cjs → OrbitControls-CrWBKSTk.cjs} +1 -1
- package/dist/{OrbitControls-RSLz2S0b.js → OrbitControls-hKxTuAne.js} +1 -1
- package/dist/{URDFLoader-CkO4RJLO.cjs → URDFLoader-BHqq00po.cjs} +1 -1
- package/dist/{URDFLoader-BpUMfsF6.js → URDFLoader-BU46gp7K.js} +2 -2
- package/dist/{animationData-C7ciTI7m.js → animationData-BbL90xGU.js} +2 -2
- package/dist/{animationData-BoxVqycf.cjs → animationData-BpQQZnbj.cjs} +1 -1
- package/dist/array-CbS69fPx.cjs +1 -0
- package/dist/{array-CVIR-i--.js → array-g-BzIhKE.js} +12 -12
- package/dist/{iconfont-C2QDZzSl.js → iconfont-gpkjnIRx.js} +2 -2
- package/dist/{iconfont-TZ8GIkZM.cjs → iconfont-m2r8ESph.cjs} +1 -1
- package/dist/{index-Bp1PEp0W.js → index-1ax1erqY.js} +5 -5
- package/dist/{index-DfZf-0j4.js → index-4cqyGWUU.js} +2 -2
- package/dist/{index-BFxYIpIU.js → index-95RC0SB0.js} +8 -9
- package/dist/{index-Bog5kQji.js → index-B0lFT37d.js} +1 -1
- package/dist/{index-081NeEuV.cjs → index-B4XQbv4q.cjs} +1 -1
- package/dist/index-BDGC3yIw.cjs +42 -0
- package/dist/index-BGP7aEbi.cjs +1 -0
- package/dist/{index-CiO2uT4E.cjs → index-BHaaYQfC.cjs} +12 -12
- package/dist/{index-CkO99t26.cjs → index-BQTrub6X.cjs} +1 -1
- package/dist/{index-BGmdJ8Zg.js → index-BS0-LNeC.js} +7 -7
- package/dist/{index-Bos1deWK.cjs → index-BV6P_J2D.cjs} +1 -1
- package/dist/{index-DPeOjfU1.cjs → index-BWIBX9Sl.cjs} +1 -1
- package/dist/index-BfeqiijR.cjs +1 -0
- package/dist/{index-CzKMGoa-.js → index-Bh66WJwb.js} +15 -15
- package/dist/{index-DRvE5S23.js → index-BqjG1Y2Y.js} +16 -17
- package/dist/{index-BWBPdata.cjs → index-C6K5EORF.cjs} +1 -1
- package/dist/index-C9a63MeW.cjs +13 -0
- package/dist/index-CEhfRVcG.cjs +1 -0
- package/dist/index-CErvylUA.cjs +1 -0
- package/dist/{index-DkIWU9Bu.js → index-CGefc7Ak.js} +769 -766
- package/dist/{index-uN57qZre.cjs → index-CHxsrbXy.cjs} +1 -1
- package/dist/{index-B2GT4T1e.cjs → index-CIybeMPI.cjs} +1 -1
- package/dist/index-CKgsrRZt.js +10442 -0
- package/dist/{index-i5Ue_JoA.cjs → index-CKwnphQR.cjs} +1 -1
- package/dist/{index-C2_KHquo.js → index-CM-E1W8F.js} +7 -7
- package/dist/{index-DEF6SrBV.js → index-CUNUX64A.js} +4 -4
- package/dist/{index-BGB8AN7S.js → index-CXx07mqc.js} +38 -38
- package/dist/{index-X2bwtZbV.js → index-CbJ39TR9.js} +14 -14
- package/dist/index-Cbp2cz1D.cjs +1 -0
- package/dist/index-CdqgG6z_.cjs +1 -0
- package/dist/{index-B_SWTmBD.cjs → index-Cexe1_nR.cjs} +1 -1
- package/dist/{index-DdBe7pKL.cjs → index-Cgt2DO86.cjs} +1 -1
- package/dist/{index-DHf9fOS7.js → index-Ch1TDVys.js} +18 -18
- package/dist/{index-DkEJVaAX.js → index-ChKY9Q_c.js} +8 -8
- package/dist/index-Cp8dl8Y4.cjs +1 -0
- package/dist/{index-CkUnZ2se.cjs → index-CzrqxMQq.cjs} +1 -1
- package/dist/{index-DSt_Eqwk.js → index-D-v_mH2L.js} +326 -326
- package/dist/{index-D3oj5RSK.js → index-D7Ejivyg.js} +12 -12
- package/dist/{index-DU4iimmS.cjs → index-D7p_01Bm.cjs} +1 -1
- package/dist/{index-u30t7l7e.js → index-DAw-JFPy.js} +4 -4
- package/dist/{index-DVf8au0C.cjs → index-DJMikZ6m.cjs} +1 -1
- package/dist/{index-Dw0CPCgX.js → index-DJv0U7ep.js} +8 -8
- package/dist/index-DL-scY6_.js +8211 -0
- package/dist/index-DRjfXii0.cjs +1 -0
- package/dist/{index-Z8iuWbfd.js → index-DhBrMxH5.js} +2 -2
- package/dist/index-DjOAHJHD.cjs +11 -0
- package/dist/{index-CY36YclZ.js → index-DkGjjjvX.js} +51 -51
- package/dist/{index-TdIk51gx.js → index-Du5EVvZy.js} +1 -1
- package/dist/{index-BqAHAwh3.js → index-FTgRHaEc.js} +2 -2
- package/dist/{index-CF2oTbnv.js → index-HoGtZJB5.js} +2 -2
- package/dist/{index-CRhbl-Xs.cjs → index-L3o91yA1.cjs} +1 -1
- package/dist/{index-H-RrS-FV.js → index-N7UyY0Cn.js} +8 -9
- package/dist/{index-BAnu2IcW.js → index-OmrdMljT.js} +36 -37
- package/dist/{index-DKKKZSMe.cjs → index-V1en5J1m.cjs} +1 -1
- package/dist/index-cGDJIpua.cjs +11 -0
- package/dist/{index-CDseWBxW.js → index-ihdYLrfi.js} +13 -13
- package/dist/{index-Bg3lrziJ.js → index-mhd92owW.js} +1 -1
- package/dist/index-xkAnmSfa.cjs +1 -0
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BDXu7acs.cjs → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BYcd0jgi.cjs} +147 -147
- package/dist/{index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BXs-wWd7.js → index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-CUjt37hI.js} +14 -14
- package/dist/index.vue_vue_type_style_index_1_lang-D3aPbrch.cjs +3 -0
- package/dist/{index.vue_vue_type_style_index_1_lang-BzNe13gn.js → index.vue_vue_type_style_index_1_lang-D4T1pSpg.js} +8 -8
- package/dist/{isString-DDsphIfV.cjs → isString-BM0aTbV9.cjs} +1 -1
- package/dist/{isString-D0BsYbM3.js → isString-DkWdJm3P.js} +1 -1
- package/dist/main-BAe55yT4.cjs +11 -0
- package/dist/{main-BEgGvauC.js → main-DLYiVNbO.js} +9 -10
- package/dist/{menuIndex-BLcswWB-.js → menuIndex-4B2w4mPA.js} +1 -1
- package/dist/{menuIndex-bwSbtzjl.cjs → menuIndex-CJYZx11j.cjs} +1 -1
- package/dist/ss-component.cjs +1 -1
- package/dist/ss-component.css +1 -1
- package/dist/ss-component.js +11 -11
- package/dist/ss-component2.cjs +1 -1
- package/dist/ss-component2.js +12 -12
- package/dist/{threeModel-CsoaXy4U.cjs → threeModel-5zOGJMgA.cjs} +1 -1
- package/dist/{threeModel-o-U3qE_Y.js → threeModel-CGM-saVm.js} +6 -6
- package/dist/{threePreview-B9pRhKDM.js → threePreview-BRK8_lKV.js} +7 -6
- package/dist/threePreview-BkKC0IgX.cjs +1 -0
- package/dist/{threeSceneView-DRPX8OYV.js → threeSceneView-5V5smS73.js} +53 -53
- package/dist/{threeSceneView-DN8Xyzfv.cjs → threeSceneView-BCQKeoTk.cjs} +1 -1
- package/dist/{threeSceneViewForCPMPIP-BCTxqfOq.cjs → threeSceneViewForCPMPIP-DVqwxUS8.cjs} +1 -1
- package/dist/{threeSceneViewForCPMPIP-B_SeEcU9.js → threeSceneViewForCPMPIP-DqG9ZYEL.js} +15 -15
- package/dist/threeTrackPathView-BrBEbTGo.cjs +1 -0
- package/dist/{threeTrackPathView-C-bjSsJM.js → threeTrackPathView-CBKRfkly.js} +8 -7
- package/dist/{threeViewerHost-irhPdb16.js → threeViewerHost-CTAXJC99.js} +10 -11
- package/dist/threeViewerHost-QHAFlASe.cjs +1 -0
- package/dist/{urdfTree-5g-HLyvW.js → urdfTree-DAM1Wv4K.js} +1 -1
- package/dist/{urdfTree-S5yUGyZL.cjs → urdfTree-DNQtn8Y5.cjs} +1 -1
- package/dist/{workpieceTreePanel-BaLWAZDy.js → workpieceTreePanel-B8WM9_Wb.js} +4 -4
- package/dist/{workpieceTreePanel-hlLH8y_h.cjs → workpieceTreePanel-DKMsi2D-.cjs} +1 -1
- package/package.json +1 -1
- package/dist/array-Bi-wunyk.cjs +0 -1
- package/dist/index-BEqVDCR5.cjs +0 -1
- package/dist/index-BVMFNtUY.cjs +0 -11
- package/dist/index-BV_kcZph.js +0 -12765
- package/dist/index-Bc85VROV.cjs +0 -32
- package/dist/index-BhpB-M-v.cjs +0 -13
- package/dist/index-BxQs7JCB.cjs +0 -1
- package/dist/index-CQ5cuVUq.cjs +0 -1
- package/dist/index-CjrO5PEa.cjs +0 -1
- package/dist/index-CoaLtkUJ.cjs +0 -1
- package/dist/index-Df5Gg8qa.cjs +0 -1
- package/dist/index-DmDnw4T-.cjs +0 -1
- package/dist/index-UbLqf_y6.cjs +0 -1
- package/dist/index-cx0rUqLg.js +0 -5929
- package/dist/index-k04UdLA7.cjs +0 -1
- package/dist/index-pSTYzLRc.cjs +0 -21
- package/dist/index.vue_vue_type_style_index_1_lang-OiQttjIF.cjs +0 -3
- package/dist/main-BDV5VAB6.cjs +0 -11
- package/dist/threePreview-CGRM7OHr.cjs +0 -1
- package/dist/threeTrackPathView-Dkc-x5Po.cjs +0 -1
- package/dist/threeViewerHost-e0FA2tJj.cjs +0 -1
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
"use strict";const ba=require("./index-C9a63MeW.cjs"),e=require("vue"),x=require("./index-BDGC3yIw.cjs"),Bt=require("./index-BHaaYQfC.cjs"),lt=require("./index-DjOAHJHD.cjs"),Ie=require("./index.vue_vue_type_style_index_0_scoped_0f027c8c_lang-BYcd0jgi.cjs"),Xt=require("./index-D7p_01Bm.cjs"),Co=require("./threeViewerHost-QHAFlASe.cjs");require("./index.vue_vue_type_style_index_1_lang-D3aPbrch.cjs");const Rt=require("./_plugin-vue_export-helper-BHFhmbuH.cjs"),Do=require("./isString-BM0aTbV9.cjs"),_o=require("./index.vue_vue_type_script_setup_true_lang-BKTJR2th.cjs"),Eo=require("./index-CHxsrbXy.cjs"),ur=require("./index-BVaHwt5f.cjs"),Fl=require("./index-L3o91yA1.cjs"),ua=require("./index-CzrqxMQq.cjs"),Rl=require("./index-BpPyaNFa.cjs"),Pl=require("vue-router"),ya=require("./index-9hspBVrQ.cjs"),Ll=require("./menuIndex-CJYZx11j.cjs");var $l=/\s/;function jl(a){for(var l=a.length;l--&&$l.test(a.charAt(l)););return l}var Ul=/^\s+/;function Kl(a){return a&&a.slice(0,jl(a)+1).replace(Ul,"")}var So=NaN,Wl=/^[-+]0x[0-9a-f]+$/i,Hl=/^0b[01]+$/i,ql=/^0o[0-7]+$/i,Gl=parseInt;function To(a){if(typeof a=="number")return a;if(lt.isSymbol(a))return So;if(lt.isObject(a)){var l=typeof a.valueOf=="function"?a.valueOf():a;a=lt.isObject(l)?l+"":l}if(typeof a!="string")return a===0?a:+a;a=Kl(a);var s=Hl.test(a);return s||ql.test(a)?Gl(a.slice(2),s?2:8):Wl.test(a)?So:+a}var Qa=function(){return lt.root.Date.now()},Xl="Expected a function",Yl=Math.max,Jl=Math.min;function dr(a,l,s){var r,d,c,w,v,f,D=0,C=!1,F=!1,R=!0;if(typeof a!="function")throw new TypeError(Xl);l=To(l)||0,lt.isObject(s)&&(C=!!s.leading,F="maxWait"in s,c=F?Yl(To(s.maxWait)||0,l):c,R="trailing"in s?!!s.trailing:R);function H(B){var h=r,ce=d;return r=d=void 0,D=B,w=a.apply(ce,h),w}function M(B){return D=B,v=setTimeout(O,l),C?H(B):w}function ve(B){var h=B-f,ce=B-D,Ne=l-h;return F?Jl(Ne,c-ce):Ne}function K(B){var h=B-f,ce=B-D;return f===void 0||h>=l||h<0||F&&ce>=c}function O(){var B=Qa();if(K(B))return G(B);v=setTimeout(O,ve(B))}function G(B){return v=void 0,R&&r?H(B):(r=d=void 0,w)}function b(){v!==void 0&&clearTimeout(v),D=0,r=f=d=v=void 0}function E(){return v===void 0?w:G(Qa())}function y(){var B=Qa(),h=K(B);if(r=arguments,d=this,f=B,h){if(v===void 0)return M(f);if(F)return clearTimeout(v),v=setTimeout(O,l),H(f)}return v===void 0&&(v=setTimeout(O,l)),w}return y.cancel=b,y.flush=E,y}var Zl="[object Boolean]";function pr(a){return a===!0||a===!1||lt.isObjectLike(a)&<.baseGetTag(a)==Zl}function Ql(a){return a===void 0}const ei={class:"statistics-cards-container"},ti={class:"statistics-label"},ni={class:"statistics-value"},ai=e.defineComponent({__name:"index",props:{items:{default:()=>[]}},setup(a){return(l,s)=>(e.openBlock(),e.createElementBlock("div",ei,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(l.items,(r,d)=>(e.openBlock(),e.createElementBlock("div",{class:"statistics-card",key:d},[e.createElementVNode("div",ti,e.toDisplayString(r==null?void 0:r.label),1),e.createElementVNode("div",ni,e.toDisplayString((r==null?void 0:r.value)??0),1)]))),128))]))}}),oi=Rt._export_sfc(ai,[["__scopeId","data-v-d399b1f3"]]),ri={class:"form-content"},li={title:"选择标签"},ii={class:"menu-config-wrap",style:{padding:"0 0 0 16px","box-sizing":"border-box","min-height":"200px",width:"400px",overflow:"auto",position:"relative"}},si={class:"col-operate-wrap"},ci={title:"拖拽排序列",style:{cursor:"move",color:"grey",position:"absolute",right:"15px"}},ui={__name:"index",props:{formRules:Object,itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,compName:{type:String,default:""},allMapContents:{type:Object}},emits:["change","contentChange","routeUrl","clickTrigger"],setup(a,{emit:l}){const s=()=>{w.value=!1,v.value=!1,f.value=[]},r=a;e.computed(()=>{var $;const I=($=V.value)==null?void 0:$.split("/");return(I==null?void 0:I.some(W=>(W==null?void 0:W.includes("updateLoading"))||(W==null?void 0:W.includes("loading"))))?!1:P.value==="view"});const d=l,c=e.ref([]),w=e.ref(!1),v=e.ref(!1),f=e.ref([]),{getFileExtension:D}=Co.useThreeSystem(),C=e.ref(),F=e.ref(!1),R=e.ref(!1),H=Ie.useUnit(x.pinia),{chooseTitle:M}=x.storeToRefs(H),ve=e.ref([]),K=e.ref(),O=e.ref(!1),G=e.ref([]),b=ba.useFormToTableComp(x.pinia),E=ba.useFormComp(x.pinia),y=e.ref(!1),B=e.ref(),h=x.useLoginState(x.pinia),{loginUserInfo:ce}=x.storeToRefs(h),Ne=e.ref(),nt=e.ref(!0),xe=x.useModelComp(x.pinia),{tableViewContents:Re,itemData:Pe,isEdit:P,routeToChildPath:re,lockingPage:ne}=x.storeToRefs(xe),pe=e.ref(null),We=e.ref(!1),at=e.ref(!1),X=x.useMenuState(),{activeMenuPath:V}=x.storeToRefs(X),te=Ie.useOriginalState(x.pinia),{originalPath:ye}=x.storeToRefs(te),ue=e.ref([]),Ce=e.ref([{label:"编辑",value:"operable",checked:!1},{label:"禁用",value:"disabled",checked:!1}]),Ze=async I=>{at.value=I,await le("disabled",null,I,!0)},ae=async I=>{await le("operable",null,I,!0)};e.watch(()=>V.value,async()=>{c.value=[],f.value=[]},{deep:!0,immediate:!0});const De=()=>{e.nextTick(()=>{Be()})},N=I=>{var ee;c.value=(ee=c.value)==null?void 0:ee.map($=>({...$,isFormColHidden:!(I!=null&&I.includes($.label))}))};e.onUnmounted(()=>{pe.value=null});const Ge=I=>{d("clickTrigger",I)},Xe=async I=>{var ee,$,W,Ee,ie,q;if(I===""){let Z="";(ee=c.value)==null||ee.forEach(be=>{be!=null&&be.isMain&&(Z=be==null?void 0:be.value)});let de=await Ie.getItemData(re.value,sessionStorage.getItem("systemKey"),"");Z=((q=(ie=(Ee=(W=($=de==null?void 0:de[0])==null?void 0:$.compData)==null?void 0:W.find(be=>(be==null?void 0:be.key)==="mainRouters"))==null?void 0:Ee.contents)==null?void 0:ie[0])==null?void 0:q.routerContent)+ye.value+Z;let we=await Ie.getItemData(Z,sessionStorage.getItem("systemKey"),"");O.value=!0,G.value=we==null?void 0:we.filter(be=>(be==null?void 0:be.comp)!=="methodButton"),d("routeUrl",G.value)}},Be=()=>{var ee;const I=(ee=pe.value)==null?void 0:ee.$el;I&&Ie.Sortable.create(I,{animation:150,handle:".col-drag-icon",ghostClass:"sortable-ghost",onEnd:$=>{const{oldIndex:W,newIndex:Ee}=$;if(W===Ee)return;const ie=c.value.splice(W,1)[0];c.value.splice(Ee,0,ie)}})},le=async(I,ee,$,W=!1)=>{try{xe.setRefreshCurStructure(!1)}catch{lt.ElMessage.error("编辑处理失败")}},Q=async(I,ee)=>{await le()},se=async(I,ee)=>{I&&await le()},_e=async(I,ee,$)=>{await le(ee,$,I,!1)},He=(I,ee)=>{Ne.value===ee?nt.value=!1:nt.value=!0,Ne.value=ee==null?void 0:ee.changeProp},dt=async I=>{var $,W,Ee,ie,q,Z,de,me,we,be,j,Oe,ge,je,ot;let ee=[];if(($=I==null?void 0:I.toString())!=null&&$.includes(".urdf")){if(I.includes(",")){lt.ElMessage.error("当前版本仅允许单个urdf预览!");return}f.value=[{url:I,extension:D(I)}],v.value=!0,w.value=!0;return}if((W=I==null?void 0:I.toString())!=null&&W.includes(".stl")||(Ee=I==null?void 0:I.toString())!=null&&Ee.includes(".STL")||(ie=I==null?void 0:I.toString())!=null&&ie.includes(".obj")||(q=I==null?void 0:I.toString())!=null&&q.includes(".mtl")){const tt=((Z=I==null?void 0:I.toString())==null?void 0:Z.split(",")).map(Te=>({url:Te,extension:D(Te)}));f.value=tt,v.value=!1,w.value=!0;return}if((de=I==null?void 0:I.toString())!=null&&de.includes(".stl")||(me=I==null?void 0:I.toString())!=null&&me.includes(".STL")||(we=I==null?void 0:I.toString())!=null&&we.includes(".obj")||(be=I==null?void 0:I.toString())!=null&&be.includes(".mtl")){let Le,tt=[],Te={};if(Array.isArray(I)?Le=I:Le=I==null?void 0:I.split(","),Le==null||Le.forEach(mt=>{mt.includes(".mtl")?tt.push(mt):Te.blob=Te.blob?Te.blob+","+mt:mt}),(tt==null?void 0:tt.length)>0&&(Te.mtlBlobs=tt),(Oe=(j=Object.values(Te))==null?void 0:j[0])!=null&&Oe.includes("http:"))ee.push(Te);else{const mt=new Blob([Te.blob],{type:"application/octet-stream;charset=UTF-8"});let Qe=URL.createObjectURL(mt),Ve="";(ge=I==null?void 0:I.split("/"))==null||ge.forEach((it,gt)=>{var Ye;gt===((Ye=I==null?void 0:I.split("/"))==null?void 0:Ye.length)-1&&(Ve=it)}),(je=Te.blob)!=null&&je.includes(".stl")&&(Ve=(Ve==null?void 0:Ve.replaceAll(">",""))+".urdf"),K.value=[{name:Ve,blobUrl:Qe}],R.value=!0}}else{const Le=Bt.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"}),tt=await lt.axios.get(I,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{Le.close()}),Te=new Blob([tt.data],{type:"application/octet-stream;charset=UTF-8"});let mt=URL.createObjectURL(Te),Qe="";(ot=I==null?void 0:I.split("/"))==null||ot.forEach((Ve,it)=>{var gt;it===((gt=I==null?void 0:I.split("/"))==null?void 0:gt.length)-1&&(Qe=Ve)}),K.value=[{name:Qe,blobUrl:mt}],R.value=!0}(ee==null?void 0:ee.length)>0&&E.setBlobUrls(ee)},m=()=>{R.value=!1},T=I=>{var ie,q,Z,de;const ee=(q=(ie=x.cloneDeep(r.itemData))==null?void 0:ie.find(me=>(me==null?void 0:me.key)==="formContent"))==null?void 0:q.contents,$=x.cloneDeep(I.content);let W={};$&&((Z=Object.values($))==null?void 0:Z.length)>0&&((de=Object.values($))==null||de.forEach((me,we)=>{W[ee[we].key]=me}));const Ee={content:W,index:r==null?void 0:r.index,buttonName:I==null?void 0:I.buttonName};d("change",Ee)},U=e.computed(()=>"http://222.92.178.198:62001"),J=async I=>{var j,Oe,ge,je,ot,Le,tt,Te,mt,Qe,Ve,it,gt,Ye,$e,It;if(!I)return;(Oe=(j=r==null?void 0:r.itemData)==null?void 0:j.find(Se=>(Se==null?void 0:Se.key)==="parentFormPath"))==null||Oe.contents;let ee=Re.value;(ee==null?void 0:ee.length)>0&&(ee=ee==null?void 0:ee.map(Se=>{var ze,Je,S,fe;let qe=(ze=Se==null?void 0:Se.key)==null?void 0:ze.split("/");return(r==null?void 0:r.compName)===(qe==null?void 0:qe[0])&&(Je=c.value)!=null&&Je.find(Ue=>(Ue==null?void 0:Ue.prop)===(qe==null?void 0:qe[1]))&&(Se.value=(fe=(S=c.value)==null?void 0:S.find(Ue=>(Ue==null?void 0:Ue.prop)===(qe==null?void 0:qe[1])))==null?void 0:fe.value),Se}),xe.setTableViewContents(ee));const $=x.cloneDeep(r.itemData);let W=$==null?void 0:$.map(Se=>{var qe;return(Se==null?void 0:Se.key)==="formContent"&&((qe=Se.contents)==null||qe.map((ze,Je)=>{var S,fe,Ue,he,ut,st,xt,pt,ct,ft,wt,Tt,jt,vt,Mt,Lt,Ut,Wt,Jt;return ze.type=(fe=(S=c.value)==null?void 0:S.find(Pt=>(Pt==null?void 0:Pt.prop)===(ze==null?void 0:ze.prop)))==null?void 0:fe.type,ze.options=ze!=null&&ze.options?ze.options:((ut=(he=(Ue=ze==null?void 0:ze.key)==null?void 0:Ue.split("$"))==null?void 0:he[1])==null?void 0:ut.length)>0?(ct=(pt=ba.formGetOptions((xt=(st=ze==null?void 0:ze.key)==null?void 0:st.split("$"))==null?void 0:xt[1]))==null?void 0:pt.split(","))==null?void 0:ct.map(Pt=>({label:Pt,value:Pt})):[],(ft=ze==null?void 0:ze.key)!=null&&ft.includes("$")&&(ze.key=(Tt=(wt=ze==null?void 0:ze.key)==null?void 0:wt.split("$"))==null?void 0:Tt[0]),ze.signature=(vt=(jt=c.value)==null?void 0:jt.find(Pt=>(Pt==null?void 0:Pt.prop)===(ze==null?void 0:ze.prop)))==null?void 0:vt.signature,ze.isLoginUser=(Lt=(Mt=c.value)==null?void 0:Mt.find(Pt=>(Pt==null?void 0:Pt.prop)===(ze==null?void 0:ze.prop)))==null?void 0:Lt.isLoginUser,ze.value=(Ut=Object.values(I))==null?void 0:Ut[Je],ze.isFormColHidden=(Jt=(Wt=c.value)==null?void 0:Wt.find(Pt=>(Pt==null?void 0:Pt.prop)===(ze==null?void 0:ze.prop)))==null?void 0:Jt.isFormColHidden,ze})),Se}),Ee=c.value,ie=(je=(ge=x.cloneDeep(W))==null?void 0:ge.find(Se=>(Se==null?void 0:Se.key)==="formContent"))==null?void 0:je.contents;if(Ee=Ee==null?void 0:Ee.map(Se=>{var qe;return Se.value=(qe=ie==null?void 0:ie.find((ze,Je)=>((ze==null?void 0:ze.id)??Je)===(Se==null?void 0:Se.id)))==null?void 0:qe.value,Se}),!nt.value){d("contentChange",{contents:W,index:r.index});return}let q="",Z=(tt=(Le=(ot=x.cloneDeep(W))==null?void 0:ot.find(Se=>(Se==null?void 0:Se.key)==="formContent"))==null?void 0:Le.contents)==null?void 0:tt.find((Se,qe)=>{var ze,Je,S;return(Se==null?void 0:Se.label)===Ne.value||qe.toString()===((S=(Je=(ze=Ne.value)==null?void 0:ze.split("t"))==null?void 0:Je[1])==null?void 0:S.toString())}),de=(Te=Z==null?void 0:Z.optionUrl)==null?void 0:Te.menuSelect,me=!0;if((Ve=(Qe=(mt=x.cloneDeep(W))==null?void 0:mt.find(Se=>(Se==null?void 0:Se.key)==="formContent"))==null?void 0:Qe.contents)==null||Ve.forEach(Se=>{var qe,ze,Je,S,fe,Ue;me&&((Je=(ze=(qe=Se==null?void 0:Se.optionUrl)==null?void 0:qe.groupSelect)==null?void 0:ze[1])!=null&&Je.includes("["))&&(q=(fe=(S=Se==null?void 0:Se.optionUrl)==null?void 0:S.groupSelect)==null?void 0:fe[1],JSON.stringify(de)===JSON.stringify((Ue=Se==null?void 0:Se.optionUrl)==null?void 0:Ue.menuSelect)&&(me=!1))}),(it=Z==null?void 0:Z.optionUrl)!=null&&it.menuSelect&&nt.value){let Se=await ba.getSelectRow(Z),qe,ze=(gt=Z==null?void 0:Z.optionUrl)==null?void 0:gt.menuSelect;if(Se==null||Se.forEach(Je=>{var S,fe,Ue,he,ut,st,xt,pt,ct,ft;q===((fe=(S=Z==null?void 0:Z.optionUrl)==null?void 0:S.groupSelect)==null?void 0:fe[1])&&((ut=(he=(Ue=Z==null?void 0:Z.optionUrl)==null?void 0:Ue.groupSelect)==null?void 0:he[1])!=null&&ut.includes("["))&&((ft=x.cloneDeep(Je))==null?void 0:ft[(ct=(pt=(xt=(st=Z==null?void 0:Z.optionUrl)==null?void 0:st.groupSelect)==null?void 0:xt[1])==null?void 0:pt.replaceAll("[",""))==null?void 0:ct.replaceAll("]","")])===(Z==null?void 0:Z.value)&&(qe=Je)}),qe){let Je=x.cloneDeep(Ee);Je=Je==null?void 0:Je.map(fe=>{var Ue,he,ut,st,xt,pt,ct,ft,wt,Tt,jt;return(qe!=null&&qe[fe==null?void 0:fe.label]||qe!=null&&qe[(st=(ut=(he=(Ue=fe==null?void 0:fe.optionUrl)==null?void 0:Ue.groupSelect)==null?void 0:he[1])==null?void 0:ut.replaceAll("[",""))==null?void 0:st.replaceAll("]","")])&&((ct=(pt=(xt=fe==null?void 0:fe.optionUrl)==null?void 0:xt.groupSelect)==null?void 0:pt[1])!=null&&ct.includes("["))&&ze!=null&&ze.every(vt=>{var Mt,Lt;return(Lt=(Mt=fe==null?void 0:fe.optionUrl)==null?void 0:Mt.menuSelect)==null?void 0:Lt.includes(vt)})&&(fe.value=(qe==null?void 0:qe[fe==null?void 0:fe.label])||(qe==null?void 0:qe[(jt=(Tt=(wt=(ft=fe==null?void 0:fe.optionUrl)==null?void 0:ft.groupSelect)==null?void 0:wt[1])==null?void 0:Tt.replaceAll("[",""))==null?void 0:jt.replaceAll("]","")]),Array.isArray(fe.value)&&fe.value.every(vt=>(vt==null?void 0:vt.url)&&(vt==null?void 0:vt.name))&&(fe.type="Upload")),fe}),Je=Je==null?void 0:Je.map(fe=>{var Ue,he,ut;return(Ue=fe==null?void 0:fe.optionUrl)!=null&&Ue.oldMenuSelect&&(fe.optionUrl.menuSelect=(ut=(he=x.cloneDeep(fe))==null?void 0:he.optionUrl)==null?void 0:ut.oldMenuSelect),fe}),c.value=x.cloneDeep(Je);let S=x.cloneDeep(Je);S=S==null?void 0:S.map(fe=>{var Ue,he,ut,st,xt,pt;return(he=(Ue=fe==null?void 0:fe.optionUrl)==null?void 0:Ue.menuSelect)!=null&&he.some(ct=>ct==null?void 0:ct.includes("["))&&(fe.optionUrl.oldMenuSelect=(st=(ut=x.cloneDeep(fe))==null?void 0:ut.optionUrl)==null?void 0:st.menuSelect,fe.optionUrl.menuSelect=(pt=(xt=fe==null?void 0:fe.optionUrl)==null?void 0:xt.menuSelect)==null?void 0:pt.map(ct=>{var ft,wt,Tt,jt;if(ct!=null&&ct.includes("[")){let vt=(wt=(ft=ct==null?void 0:ct.replaceAll("[","").replaceAll("]",""))==null?void 0:ft.split(":"))==null?void 0:wt[1];ct=(jt=(Tt=x.cloneDeep(Je))==null?void 0:Tt.find(Mt=>(Mt==null?void 0:Mt.label)===vt))==null?void 0:jt.value}return ct})),fe}),c.value=S}else c.value=Ee;W=W==null?void 0:W.map(Je=>{var S;return(Je==null?void 0:Je.key)==="formContent"&&(Je.contents=(S=Je.contents)==null?void 0:S.map(fe=>{var Ue,he,ut,st;return fe.value=((he=(Ue=c.value)==null?void 0:Ue.find(xt=>(xt==null?void 0:xt.label)===(fe==null?void 0:fe.key)))==null?void 0:he.value)??(fe==null?void 0:fe.value),fe.type=((st=(ut=c.value)==null?void 0:ut.find(xt=>(xt==null?void 0:xt.prop)===(fe==null?void 0:fe.key)))==null?void 0:st.type)??(fe==null?void 0:fe.type),fe})),Je})}nt.value=!1,d("contentChange",{contents:W,index:r.index});let we=[],be=[];if(($e=x.cloneDeep((Ye=W==null?void 0:W.find(Se=>(Se==null?void 0:Se.key)==="formContent"))==null?void 0:Ye.contents))==null||$e.forEach(Se=>{var qe;Array.isArray(Se==null?void 0:Se.value)&&((qe=Se==null?void 0:Se.value)!=null&&qe.find(ze=>{var Je;return(Je=ze==null?void 0:ze.url)==null?void 0:Je.includes(".obj")}))&&(be=Se==null?void 0:Se.value)}),(be==null?void 0:be.length)>0){const Se=(It=x.cloneDeep(be))==null?void 0:It.filter(qe=>{var ze;return(ze=qe==null?void 0:qe.url)==null?void 0:ze.includes(".obj")});Se==null||Se.forEach(qe=>{var Je,S,fe,Ue;const ze=(Je=be==null?void 0:be.filter(he=>{var ut;return(he==null?void 0:he.name)===(qe==null?void 0:qe.name)&&((ut=he==null?void 0:he.url)==null?void 0:ut.includes(".mtl"))}))==null?void 0:Je.map(he=>he==null?void 0:he.url);we.push({objUrl:qe==null?void 0:qe.url,mtlUrls:((S=be==null?void 0:be.filter(he=>{var ut;return(he==null?void 0:he.name)===(qe==null?void 0:qe.name)&&((ut=he==null?void 0:he.url)==null?void 0:ut.includes(".mtl"))}))==null?void 0:S.length)===1?(Ue=(fe=be==null?void 0:be.filter(he=>{var ut;return(he==null?void 0:he.name)===(qe==null?void 0:qe.name)&&((ut=he==null?void 0:he.url)==null?void 0:ut.includes(".mtl"))}))==null?void 0:fe[0])==null?void 0:Ue.url:ze})}),E.setObjUrl(we)}},_=I=>{if(!I)return;const ee=[];let $="";for(let W of I)(W.includes("[")||$.includes("["))&&($+=W.trim(),x.cloneDeep($).split("【").length-1===x.cloneDeep($).split("】").length-1&&x.cloneDeep($).split("[").length-1===x.cloneDeep($).split("]").length-1&&(ee.push($.replace(/\/\*[\s\S]*?\*\//g,"")),$=""));return ee},oe=(I,ee,$)=>{let W="";const Ee=ee==null?void 0:ee.map(ie=>{var q;return(q=ie==null?void 0:ie.value)==null?void 0:q.pageData});return Ee==null||Ee.forEach(ie=>{var q;(ie==null?void 0:ie.name)===(I==null?void 0:I[0])&&((q=ie==null?void 0:ie.compData)==null||q.forEach(Z=>{var de;(Z==null?void 0:Z.key)==="formContent"&&((de=Z==null?void 0:Z.contents)==null||de.forEach(me=>{var we;(me==null?void 0:me.prop)===(I==null?void 0:I[1])&&(W=(me==null?void 0:me.value)===""?Ie.judgeContents((we=x.cloneDeep(me))==null?void 0:we.optionUrl,$):me==null?void 0:me.value)}))}))}),W},Ae=(I,ee,$,W)=>{var Z,de;let Ee="",ie="";(Z=x.cloneDeep(ee))==null||Z.forEach((me,we)=>{me!=null&&me.includes("[")?ie=ie+ye.value+I[we]:ie=ie===""?ie+me:ie+"/"+me});let q=(de=W[ie])==null?void 0:de.map(me=>{var we;return(we=me==null?void 0:me.value)==null?void 0:we.pageData});return q==null||q.forEach(me=>{var we;(me==null?void 0:me.name)===($==null?void 0:$[0])&&((we=me==null?void 0:me.compData)==null||we.forEach(be=>{var j;(be==null?void 0:be.key)==="formContent"&&((j=be==null?void 0:be.contents)==null||j.forEach(Oe=>{(Oe==null?void 0:Oe.prop)===($==null?void 0:$[1])&&(Ee=Oe==null?void 0:Oe.value)}))}))}),Ee};return e.watch(()=>r.itemData,async()=>{var q,Z,de,me,we,be,j,Oe,ge,je,ot,Le,tt,Te,mt,Qe,Ve,it,gt;const I=(q=r.itemData)==null?void 0:q.find(Ye=>(Ye==null?void 0:Ye.key)==="formContent"),ee=(Z=x.cloneDeep(r.itemData))==null?void 0:Z.find(Ye=>(Ye==null?void 0:Ye.key)==="formButton"),$=(de=x.cloneDeep(r.itemData))==null?void 0:de.find(Ye=>(Ye==null?void 0:Ye.key)==="formFlex"),W=(me=x.cloneDeep(r.itemData))==null?void 0:me.find(Ye=>(Ye==null?void 0:Ye.key)==="formWrap"),Ee=(we=x.cloneDeep(r.itemData))==null?void 0:we.find(Ye=>(Ye==null?void 0:Ye.key)==="enableWrap");if((W==null?void 0:W.contents)==="纵向"?F.value=!1:F.value=!0,y.value=(Ee==null?void 0:Ee.contents)===void 0?!1:Ee==null?void 0:Ee.contents,B.value=typeof($==null?void 0:$.contents)!="boolean"?!(!($!=null&&$.contents)===""||((be=$==null?void 0:$.contents)==null?void 0:be.toUpperCase())==="VERTICAL"):$==null?void 0:$.contents,((j=I==null?void 0:I.contents)==null?void 0:j.length)>0&&Array.isArray(I==null?void 0:I.contents)){let Ye=r.allMapContents;const $e=(ge=(Oe=x.cloneDeep(I))==null?void 0:Oe.contents)==null?void 0:ge.map((S,fe)=>{var vt,Mt,Lt,Ut,Wt,Jt,Pt,En,zn,gn,Fn,yn,Rn,Pn,Ln,$n,jn,Sn,hn,un,bn,vn,nn,pn,Un,Tn,Bn,kn,Kn,Wn,In,Hn,qn;let Ue=(S==null?void 0:S.label)??(S==null?void 0:S.key)??"",he=(S==null?void 0:S.type)??"",ut=(S==null?void 0:S.options)??[];if((vt=S==null?void 0:S.key)!=null&&vt.includes("$")&&(Ue=(Mt=x.cloneDeep(S==null?void 0:S.key).split("$"))==null?void 0:Mt[0],((Ut=(Lt=x.cloneDeep(S==null?void 0:S.key).split("$"))==null?void 0:Lt[1])==null?void 0:Ut.length)>0)){const[_t,Yt]=(Jt=(Wt=x.cloneDeep(S==null?void 0:S.key).split("$"))==null?void 0:Wt[1])==null?void 0:Jt.split(/[()]/);he=((Pt=Ie.FormType.find(yt=>(yt==null?void 0:yt.key)===_t))==null?void 0:Pt.value)??"",((En=Yt==null?void 0:Yt.split(","))==null?void 0:En.length)>0&&(ut=(zn=Yt==null?void 0:Yt.split(","))==null?void 0:zn.map(yt=>({label:yt,value:yt})))}let st=[];S!=null&&S.contents&&!Array.isArray(S==null?void 0:S.contents)&&(st=(Fn=(gn=S==null?void 0:S.contents)==null?void 0:gn.split(","))==null?void 0:Fn.map(_t=>({label:_t,value:_t}))),((yn=S==null?void 0:S.optionUrl)==null?void 0:yn.selectRelateType)==="自定义绑定"&&(st=(Pn=(Rn=S==null?void 0:S.optionUrl)==null?void 0:Rn.defaultSelect)==null?void 0:Pn.map(_t=>({label:_t,value:_t})));let xt=!1,pt=(S==null?void 0:S.isFormColHidden)??!1,ct=Ie.judgeContents((Ln=x.cloneDeep(S))==null?void 0:Ln.optionUrl,Ye),ft=ct!==void 0&&ct!==""?ct:S!=null&&S.originalContent&&(S==null?void 0:S.originalContent)!==""?S.originalContent:S!=null&&S.value?S.value:(ut==null?void 0:ut.length)>0?($n=ut==null?void 0:ut[0])==null?void 0:$n.value:(S==null?void 0:S.value)??"",wt=!1,Tt=ct!==void 0||he===""?"Input":he;if((Array.isArray(ct)&&(ct!=null&&ct.every(_t=>(_t==null?void 0:_t.name)&&(_t==null?void 0:_t.url)))||Array.isArray(ft)&&(ft!=null&&ft.every(_t=>(_t==null?void 0:_t.name)&&(_t==null?void 0:_t.url))))&&(Tt="upload"),typeof ft=="string"&&(ft!=null&&ft.includes("loginUser"))&&!(ft!=null&&ft.includes("loginUserSign"))||S!=null&&S.isLoginUser)xt=!0,ft=((jn=ce.value)==null?void 0:jn.姓名)||((Sn=ce.value)==null?void 0:Sn.account)||((hn=ce.value)==null?void 0:hn.账号)||((un=ce.value)==null?void 0:un.userName);else if(typeof ft=="string"&&(ft!=null&&ft.includes("loginUserSign"))||S!=null&&S.signature||S!=null&&S.isShow)if(wt=!0,(S==null?void 0:S.isShow)==="originalSignature")Tt="image",ft=U.value+"/"+((bn=ce.value)==null?void 0:bn.signature);else{let _t=[...new Set(_(S.isShow))].map(bt=>{var Dt,Ct,zt,Vt;return{key:(Vt=(zt=(Ct=(Dt=bt==null?void 0:bt.split("["))==null?void 0:Dt[1])==null?void 0:Ct.split("]"))==null?void 0:zt[0])==null?void 0:Vt.split(":"),value:""}});(vn=Pe.value)==null||vn.forEach(bt=>{_t==null||_t.forEach((Kt,Dt)=>{var zt;let Ct=Kt==null?void 0:Kt.key;(bt==null?void 0:bt.name)===(Ct==null?void 0:Ct[0].replaceAll("'",""))&&((zt=bt==null?void 0:bt.compData)==null||zt.forEach(Vt=>{var Ft;(Vt==null?void 0:Vt.key)==="formContent"&&((Ft=Vt==null?void 0:Vt.contents)==null||Ft.forEach(Ht=>{(Ht==null?void 0:Ht.prop)===(Ct==null?void 0:Ct[1].replaceAll("'",""))&&(_t[Dt].value=Ht==null?void 0:Ht.value)}))}))})});let Yt=_t==null?void 0:_t.map(bt=>{var Kt;return bt.key="["+((Kt=bt.key)==null?void 0:Kt.join(":"))+"]",bt}),yt=S==null?void 0:S.isShow;Yt==null||Yt.forEach(bt=>{bt!=null&&bt.value?yt=yt.replaceAll(bt==null?void 0:bt.key,"'"+(bt==null?void 0:bt.value)+"'"):yt=yt.replaceAll(bt==null?void 0:bt.key,"undefined")}),yt!=null&&yt.includes("(")||(yt!=null&&yt.includes("==")?yt=((nn=yt==null?void 0:yt.split("==="))==null?void 0:nn[0])+"==='"+((pn=yt==null?void 0:yt.split("==="))==null?void 0:pn[1])+"'":yt=((Un=yt==null?void 0:yt.split("="))==null?void 0:Un[0])+"='"+((Tn=yt==null?void 0:yt.split("="))==null?void 0:Tn[1])+"'"),yt!=null&&yt.includes("=")&&!(yt!=null&&yt.includes("=="))&&!(yt!=null&&yt.includes("==="))&&(yt=yt==null?void 0:yt.replaceAll("=","==")),new Function(`if (${yt}) { return true } else { return false }`)()?(pt=!1,Tt="image",ft=U.value+"/"+((Bn=ce.value)==null?void 0:Bn.signature)):ft=""}return Array.isArray(ft)&&ft.every(_t=>(_t==null?void 0:_t.url)&&(_t==null?void 0:_t.name))&&(S.type="Upload"),S!=null&&S.isMainUrl&&(Tt="Url"),{label:Ue??"",name:"t"+fe,prop:x.cloneDeep(S==null?void 0:S.key),type:Tt,value:S!=null&&S.isSync?((Kn=(kn=M.value)==null?void 0:kn[0])==null?void 0:Kn.value)??((qn=(Wn=V==null?void 0:V.value)==null?void 0:Wn.split("/"))==null?void 0:qn[((Hn=(In=V==null?void 0:V.value)==null?void 0:In.split("/"))==null?void 0:Hn.length)-1]):S!=null&&S.isNewDate&&ft===""?new Date:ft,id:(S==null?void 0:S.id)??fe,contents:(st==null?void 0:st.length)>0?st:ut??[],width:(S==null?void 0:S.width)??1,isLoginUser:xt,config:S==null?void 0:S.config,optionUrl:(S==null?void 0:S.optionUrl)??S,isFormColHidden:pt,signature:wt,isMain:S==null?void 0:S.isMain,isMainUrl:S==null?void 0:S.isMainUrl,operable:(S==null?void 0:S.operable)??!1,disabled:(S==null?void 0:S.disabled)??!1,isSync:S==null?void 0:S.isSync}}),It=$e==null?void 0:$e.map(S=>S==null?void 0:S.value);let Se="";It==null||It.forEach(S=>{S!==""&&S!==void 0&&(Se=Se===""?S:Se+"/"+S)}),b.setSelectArray(It),b.setSelectString(Se);let qe=(je=x.cloneDeep($e))==null?void 0:je.map(S=>(S!=null&&S.value&&Ie.IsJson(S==null?void 0:S.value)&&Array.isArray(JSON.parse(S==null?void 0:S.value))&&(S.value=JSON.parse(S.value)),S));qe=qe==null?void 0:qe.map(S=>{var fe,Ue,he,ut,st,xt,pt,ct;if((Ue=(fe=S==null?void 0:S.optionUrl)==null?void 0:fe.menuSelect)!=null&&Ue.some(ft=>ft==null?void 0:ft.includes("["))){let ft="";S.optionUrl.oldMenuSelect=(ut=(he=x.cloneDeep(S))==null?void 0:he.optionUrl)==null?void 0:ut.menuSelect,S.optionUrl.menuSelect=(xt=(st=S==null?void 0:S.optionUrl)==null?void 0:st.menuSelect)==null?void 0:xt.map(wt=>{var Tt,jt,vt,Mt,Lt,Ut;if(wt!=null&&wt.includes("[")){let Wt=(jt=(Tt=wt==null?void 0:wt.replaceAll("[","").replaceAll("]",""))==null?void 0:Tt.split(":"))==null?void 0:jt[1];ft=oe((vt=wt==null?void 0:wt.replaceAll("[","").replaceAll("]",""))==null?void 0:vt.split(":"),Ye==null?void 0:Ye[V.value],Ye),wt=((Lt=(Mt=x.cloneDeep(qe))==null?void 0:Mt.find(Jt=>(Jt==null?void 0:Jt.label)===Wt))==null?void 0:Lt.value)||oe((Ut=wt==null?void 0:wt.replaceAll("[","").replaceAll("]",""))==null?void 0:Ut.split(":"),Ye==null?void 0:Ye[V.value],Ye)}return wt}),ft!==""&&S.value===""&&(S.value=Ae(S.optionUrl.menuSelect,S.optionUrl.oldMenuSelect,(pt=S==null?void 0:S.optionUrl)==null?void 0:pt.groupSelect,Ye),Array.isArray(S.value)&&((ct=S.value)!=null&&ct.every(wt=>wt==null?void 0:wt.url))&&(S.type="UPLOAD"))}return S}),c.value=qe,at.value=((ot=c.value)==null?void 0:ot.every(S=>S==null?void 0:S.disabled))||ne.value===V.value,We.value=(Le=c.value)==null?void 0:Le.every(S=>S==null?void 0:S.operable),ue.value=(tt=c.value)==null?void 0:tt.map(S=>S==null?void 0:S.label);let ze=[],Je=[];if((Te=x.cloneDeep(c.value))==null||Te.forEach(S=>{var fe;Array.isArray(S==null?void 0:S.value)&&((fe=S==null?void 0:S.value)!=null&&fe.find(Ue=>{var he;return(he=Ue==null?void 0:Ue.url)==null?void 0:he.includes(".obj")}))&&(Je=S==null?void 0:S.value)}),(Je==null?void 0:Je.length)>0){const S=(mt=x.cloneDeep(Je))==null?void 0:mt.filter(fe=>{var Ue;return(Ue=fe==null?void 0:fe.url)==null?void 0:Ue.includes(".obj")});S==null||S.forEach(fe=>{var he,ut,st,xt;const Ue=(he=Je==null?void 0:Je.filter(pt=>{var ct;return(pt==null?void 0:pt.name)===(fe==null?void 0:fe.name)&&((ct=pt==null?void 0:pt.url)==null?void 0:ct.includes(".mtl"))}))==null?void 0:he.map(pt=>pt==null?void 0:pt.url);ze.push({objUrl:fe==null?void 0:fe.url,mtlUrls:((ut=Je==null?void 0:Je.filter(pt=>{var ct;return(pt==null?void 0:pt.name)===(fe==null?void 0:fe.name)&&((ct=pt==null?void 0:pt.url)==null?void 0:ct.includes(".mtl"))}))==null?void 0:ut.length)===1?(xt=(st=Je==null?void 0:Je.filter(pt=>{var ct;return(pt==null?void 0:pt.name)===(fe==null?void 0:fe.name)&&((ct=pt==null?void 0:pt.url)==null?void 0:ct.includes(".mtl"))}))==null?void 0:st[0])==null?void 0:xt.url:Ue})}),E.setObjUrl(ze)}(Qe=x.cloneDeep(c.value))==null||Qe.forEach(S=>{var fe,Ue,he,ut,st,xt,pt,ct,ft,wt,Tt,jt,vt;if((Ue=(fe=S==null?void 0:S.value)==null?void 0:fe.toString())!=null&&Ue.includes(".stl")||(ut=(he=S==null?void 0:S.value)==null?void 0:he.toString())!=null&&ut.includes(".STL")||(xt=(st=S==null?void 0:S.value)==null?void 0:st.toString())!=null&&xt.includes(".obj")||(ct=(pt=S==null?void 0:S.value)==null?void 0:pt.toString())!=null&&ct.includes(".mtl")||(wt=(ft=S==null?void 0:S.value)==null?void 0:ft.toString())!=null&&wt.includes(".urdf")){let Mt={},Lt=[],Ut;Array.isArray(S==null?void 0:S.value)?Ut=S==null?void 0:S.value:Ut=(Tt=S==null?void 0:S.value)==null?void 0:Tt.split(","),Ut==null||Ut.forEach(Wt=>{Wt.includes(".mtl")?Lt.push(Wt):Mt.blob=Mt.blob==="undefined"?Wt:Mt.blob+","+Wt}),(Lt==null?void 0:Lt.length)>0&&(Mt.mtlBlobs=Lt),(vt=(jt=Object.values(Mt))==null?void 0:jt[0])!=null&&vt.includes("http:")}})}else c.value=[];let ie=Re.value;if((ie==null?void 0:ie.length)>0&&(ie=ie==null?void 0:ie.map(Ye=>{var It,Se,qe,ze;let $e=(It=Ye==null?void 0:Ye.key)==null?void 0:It.split("/");return(r==null?void 0:r.compName)===($e==null?void 0:$e[0])&&(Se=c.value)!=null&&Se.find(Je=>(Je==null?void 0:Je.prop)===($e==null?void 0:$e[1]))&&(Ye.value=(ze=(qe=c.value)==null?void 0:qe.find(Je=>(Je==null?void 0:Je.prop)===($e==null?void 0:$e[1])))==null?void 0:ze.value),Ye}),xe.setTableViewContents(ie)),r!=null&&r.formRules)C.value=r==null?void 0:r.formRules;else{let Ye={};(Ve=x.cloneDeep(c).value)==null||Ve.forEach($e=>{($e==null?void 0:$e.isMain)===!0&&(Ye[($e==null?void 0:$e.prop)??($e==null?void 0:$e.name)]=[{required:!0,message:`${($e==null?void 0:$e.prop)||($e==null?void 0:$e.name)}不能为空`}])}),C.value=Ye}if(((it=ee==null?void 0:ee.contents)==null?void 0:it.length)>0){const Ye=[];(gt=ee==null?void 0:ee.contents)==null||gt.forEach(($e,It)=>{($e==null?void 0:$e.label)!==""&&Ye.push({label:($e==null?void 0:$e.label)??"",id:($e==null?void 0:$e.id)??It,type:($e==null?void 0:$e.type)??"",background:$e==null?void 0:$e.background})}),ve.value=Ye}else ve.value=[]},{deep:!0,immediate:!0}),e.watch(()=>ne.value,I=>{at.value=I===V.value},{immediate:!0}),(I,ee)=>{var Z,de;const $=e.resolveComponent("svg-icon"),W=e.resolveComponent("el-switch"),Ee=e.resolveComponent("el-checkbox"),ie=e.resolveComponent("el-popover"),q=e.resolveComponent("el-checkbox-group");return e.openBlock(),e.createElementBlock("div",ri,[y.value===!1?(e.openBlock(),e.createBlock(oi,{key:0,items:(de=(Z=c.value)==null?void 0:Z.filter(me=>!(me!=null&&me.isFormColHidden)))==null?void 0:de.map(me=>({label:me==null?void 0:me.label,value:me==null?void 0:me.value}))},null,8,["items"])):(e.openBlock(),e.createBlock(Bt.ssForm,{key:1,rowContents:c.value,formRules:C.value,buttonValue:ve.value,isRowFlex:!1,isEnableWrap:y.value,onOnButtonClick:T,onChange:J,formDisabled:at.value,formLabelsOperable:We.value,isButtonRow:F.value,onPreview:dt,onBlurChange:He,onHandleColEditChange:Q,onHandleColTypeChange:se,onRouteUrl:Xe,onClickTrigger:Ge},{operateCol:e.withCtx(({renderColumns:me,formDisabled:we,formLabelsOperable:be})=>[e.createVNode(ie,{title:"选择操作的标签",placement:"left-start","popper-class":"menu-operate-popover",trigger:"hover",onShow:De},{reference:e.withCtx(()=>[e.createElementVNode("span",li,[e.createVNode($,{name:"more",style:{cursor:"pointer",width:"15px",height:"15px"}})])]),default:e.withCtx(()=>[e.createElementVNode("div",ii,[ee[1]||(ee[1]=e.createElementVNode("div",{class:"group-title"},"表单操作",-1)),e.createVNode(W,{"model-value":we,"active-text":"禁用","inactive-text":"",onChange:Ze,style:{"margin-right":"8px"}},null,8,["model-value"]),e.createVNode(W,{"model-value":be,"active-text":"编辑所有标签","inactive-text":"",onChange:ae},null,8,["model-value"]),ee[2]||(ee[2]=e.createElementVNode("div",{class:"group-title"},"表单列操作",-1)),e.createVNode(q,{modelValue:ue.value,"onUpdate:modelValue":ee[0]||(ee[0]=j=>ue.value=j),style:{height:"100%"},ref_key:"checkboxGroupRef",ref:pe,onChange:N},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(me,j=>(e.openBlock(),e.createElementBlock("div",{style:{display:"flex","align-items":"center"},key:j.label},[e.createVNode(Ee,{value:j.label,style:{width:"100%",marginRight:0}},{default:e.withCtx(()=>[e.createElementVNode("span",null,e.toDisplayString(j.label),1)]),_:2},1032,["value"]),e.createVNode(ie,{title:"标签操作",placement:"left",teleported:!1,trigger:"hover"},{reference:e.withCtx(()=>[e.createVNode($,{name:"colOperate",style:{width:"15px",height:"15px",cursor:"pointer",color:"grey",position:"absolute",right:"40px"}})]),default:e.withCtx(()=>{var Oe;return[e.createElementVNode("div",si,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((Oe=Object.keys(j))==null?void 0:Oe.filter(ge=>{var je;return(je=Ce.value)==null?void 0:je.find(ot=>(ot==null?void 0:ot.value)===ge)}),ge=>{var je,ot;return e.openBlock(),e.createElementBlock("div",{key:ge},[e.createVNode(Bt._sfc_main$1,{value:j==null?void 0:j[ge],"active-text":(ot=(je=Ce.value)==null?void 0:je.find(Le=>(Le==null?void 0:Le.value)===ge))==null?void 0:ot.label,inactiveText:"",onChange:Le=>_e(Le,ge,j)},null,8,["value","active-text","onChange"])])}),128))])]}),_:2},1024),e.createElementVNode("span",ci,[e.createVNode($,{name:"drag",class:"col-drag-icon",style:{width:"15px",height:"15px"}})])]))),128))]),_:2},1032,["modelValue"])])]),_:2},1024)]),_:1},8,["rowContents","formRules","buttonValue","isEnableWrap","formDisabled","formLabelsOperable","isButtonRow"])),R.value?(e.openBlock(),e.createBlock(Bt.ssFilePreview,{key:2,fileDataList:K.value,onDestroy:m},null,8,["fileDataList"])):e.createCommentVNode("",!0),w.value?(e.openBlock(),e.createBlock(Xt.ssDialog,{key:3,visible:w.value,onBeforeDestroy:s,style:{height:"700px",width:"1000px"}},{default:e.withCtx(()=>[e.createVNode(Co.ThreeViewerHost,{files:f.value,onGetAnimationData:I.onAnimationData},null,8,["files","onGetAnimationData"])]),_:1},8,["visible"])):e.createCommentVNode("",!0)])}}},Bo=Rt._export_sfc(ui,[["__scopeId","data-v-8040f4ad"]]),Pa=e.ref(0),fr=a=>{var l;return!a||(a==null?void 0:a.length)===0?[]:(l=x.cloneDeep(a))==null?void 0:l.map(r=>(Pa.value++,r={label:(r==null?void 0:r.label)??"",prop:(r==null?void 0:r.label)==="操作"?"operate":r==null?void 0:r.prop,width:r!=null&&r.width?parseInt(r.width):"",fixed:(r==null?void 0:r.fixed)??void 0,sortable:(r==null?void 0:r.sortable)??!1,align:(r==null?void 0:r.align)??"left",showOverflowTooltip:(r==null?void 0:r.showOverflowTooltip)??!0,isNotDrag:(r==null?void 0:r.isNotDrag)??!1,isEditCol:(r==null?void 0:r.isEditCol)??!1,isOperate:(r==null?void 0:r.isOperate)??!1,id:(r==null?void 0:r.id)??Pa.value,children:fr(r==null?void 0:r.children)},r))},di=a=>{var s;return(s=x.cloneDeep(a))==null?void 0:s.map(r=>(Pa.value++,r={label:(r==null?void 0:r.label)??"",prop:(r==null?void 0:r.label)==="操作"?"operate":r==null?void 0:r.prop,width:r!=null&&r.width?parseInt(r.width):"",fixed:(r==null?void 0:r.fixed)??void 0,sortable:(r==null?void 0:r.sortable)??!1,align:(r==null?void 0:r.align)??"left",showOverflowTooltip:(r==null?void 0:r.showOverflowTooltip)??!0,isNotDrag:(r==null?void 0:r.isNotDrag)??!1,isEditCol:(r==null?void 0:r.isEditCol)??!1,isOperate:(r==null?void 0:r.isOperate)??!1,id:(r==null?void 0:r.id)??Pa.value,children:fr(r==null?void 0:r.children)},r))},hr=(a,l)=>{var s;return a!=null&&a.find(r=>(r==null?void 0:r.id)===l)?(s=x.cloneDeep(a))==null?void 0:s.filter(d=>(d==null?void 0:d.id)!==l):(a=a==null?void 0:a.map(r=>(r.children=hr(r==null?void 0:r.children,l),r)),a)},vr=(a,l)=>{var s;return a!=null&&a.find(r=>(r==null?void 0:r.id)===(l==null?void 0:l.id))?(s=x.cloneDeep(a))==null?void 0:s.map(d=>((d==null?void 0:d.id)===(l==null?void 0:l.id)&&(d=l),d)):(a=a==null?void 0:a.map(r=>(r.children=vr(r==null?void 0:r.children,l),r)),a)},mr=(a,l)=>{var s;return a!=null&&a.find(r=>{var d;return(r==null?void 0:r.id)===((d=l==null?void 0:l.contents)==null?void 0:d.id)})?(s=x.cloneDeep(a))==null?void 0:s.map(d=>{var c;return(d==null?void 0:d.id)===((c=l==null?void 0:l.contents)==null?void 0:c.id)&&(d=l==null?void 0:l.contents),d}):(a=a==null?void 0:a.map(r=>(r.children=mr(r==null?void 0:r.children,l),r)),a)},gr=(a,l)=>{var s;return a!=null&&a.find(r=>(r==null?void 0:r.id)===(l==null?void 0:l.id))?(s=x.cloneDeep(a))==null?void 0:s.map(d=>((d==null?void 0:d.id)===(l==null?void 0:l.id)&&(d!=null&&d.children||(d.children=[]),d.children.push(l.contents)),d)):(a=a==null?void 0:a.map(r=>(r.children=gr(r==null?void 0:r.children,l),r)),a)},At=[{key:"label",label:"标签名",type:"Input"},{key:"prop",label:"属性名",type:"Input"},{key:"width",label:"宽度",type:"Input"},{key:"sortable",label:"是否支持排序",type:"Switch"},{key:"align",label:"文本所在位置",type:"Radio",options:[{label:"left",value:"左"},{label:"center",value:"中"},{label:"right",value:"右"}]},{key:"fixed",label:"是否固定列",type:"Switch"}],pi=[{label:"查看",value:"view"},{label:"修改",value:"fix"},{label:"删除",value:"delete"},{label:"三维算例",value:"modelExample"}],fi=[{label:"新增",value:"add"}],wn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:fi},{key:"background",label:"按钮背景色",type:"Color"}],Cn=[{key:"label",label:"按钮名",type:"Input"},{key:"type",label:"类型",type:"Select",options:pi},{key:"textColor",label:"按钮颜色",type:"Color"}],hi={class:"table-header-child"},vi={class:"table-header-child-main"},mi={class:"table-header-child-content"},gi={class:"table-header-child-content-item"},yi={class:"fix-button"},bi={key:0},ki={class:"form-content"},xi={__name:"tableNewChild",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const s=a,r=l,d=e.ref(!1),c=e.ref(""),w=Ie.useTableComp(x.pinia),{tableIndex:v}=x.storeToRefs(w);e.ref(0);const f=e.ref(""),D=e.ref([]),C=e.ref([]),F=b=>{var y;d.value=!0;let E=[];At==null||At.forEach(B=>{let h=x.cloneDeep(v.value)+1;w.setTableIndex(h),E.push({label:B==null?void 0:B.label,name:B==null?void 0:B.label,type:B.type,value:b[B.key],id:v.value,contents:B==null?void 0:B.options})}),b!=null&&b.children&&((y=b==null?void 0:b.children)==null?void 0:y.length)>0&&E.push({children:b==null?void 0:b.children,isFormColHidden:!0}),f.value=b==null?void 0:b.id,D.value=E,C.value=E},R=b=>{r("fixChange",x.cloneDeep(b))},H=b=>{r("deleteChange",x.cloneDeep(b))},M=b=>{d.value=!0;let E=[];At==null||At.forEach(y=>{let B=x.cloneDeep(v.value)+1;w.setTableIndex(B),E.push({label:y==null?void 0:y.label,name:y==null?void 0:y.label,type:y.type,value:"",id:v.value,contents:y==null?void 0:y.options})}),c.value=b==null?void 0:b.id,D.value=E,C.value=E},ve=b=>{let E=x.cloneDeep(C.value);E=E==null?void 0:E.map(y=>(y.children||(y.value=b==null?void 0:b[y.name]),y)),C.value=E},K=()=>{var E,y;D.value=C.value;let b={};if(f.value!=="")b.id=f.value,(E=D.value)==null||E.forEach(B=>{const h=At==null?void 0:At.find(ce=>(ce==null?void 0:ce.label)===(B==null?void 0:B.label));h?b[h.key]=B.value:B!=null&&B.children&&B.children.length>0&&(b.children=B.children)}),d.value=!1,r("fixChange",{contents:x.cloneDeep(b),id:c.value,type:"fix"});else{let B=x.cloneDeep(v.value)+1;w.setTableIndex(B),b.id="id"+v.value,(y=D.value)==null||y.forEach(h=>{const ce=At==null?void 0:At.find(Ne=>(Ne==null?void 0:Ne.label)===(h==null?void 0:h.label));ce?b[ce.key]=h.value:h!=null&&h.children&&h.children.length>0&&(b.children=h.children)}),d.value=!1,r("fixChange",{contents:x.cloneDeep(b),id:c.value,type:"add"})}f.value="",D.value=[],C.value=[]},O=()=>{d.value=!1,f.value="",c.value="",D.value=[],C.value=[]},G=b=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{r("deleteChange",b),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(b,E)=>{const y=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",hi,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s==null?void 0:s.tableChildContents,(B,h)=>(e.openBlock(),e.createElementBlock("div",vi,[e.createElementVNode("div",mi,[e.createElementVNode("div",gi,e.toDisplayString(B.label),1),e.createElementVNode("div",yi,[e.createVNode(y,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ce=>M(B)},null,8,["onClick"]),e.createVNode(y,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ce=>F(B)},null,8,["onClick"]),e.createVNode(y,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:ce=>G(B)},null,8,["onClick"])])]),B!=null&&B.children&&B.children.length>0?(e.openBlock(),e.createElementBlock("div",bi,[e.createVNode(yr,{tableChildContents:B==null?void 0:B.children,onDeleteChange:H,onFixChange:R},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode(Xt.ssDialog,{visible:d.value,onBeforeDestroy:O,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",ki,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:D.value,key:D.value,isEnableWrap:!0,onChange:ve},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:O,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:K},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},wi=Rt._export_sfc(xi,[["__scopeId","data-v-e0fef72d"]]),Ci={class:"table-header-child"},Di={class:"table-header-child-main"},_i={class:"table-header-child-content"},Ei={class:"table-header-child-content-item"},Si={class:"fix-button"},Ti={key:0},Bi={class:"form-content"},Ii={class:"dialog-footer"},Ni={__name:"tableChildren",props:{tableChildContents:Array},emits:["fixChange","deleteChange"],setup(a,{emit:l}){const s=a,r=l,d=e.ref(!1),c=e.ref(""),w=Ie.useTableComp(x.pinia),{tableIndex:v}=x.storeToRefs(w),f=e.ref(""),D=e.ref([]),C=e.ref([]),F=b=>{r("fixChange",x.cloneDeep(b))},R=b=>{var y;d.value=!0;let E=[];At==null||At.forEach(B=>{let h=x.cloneDeep(v.value)+1;w.setTableIndex(h),E.push({label:B==null?void 0:B.label,name:B==null?void 0:B.label,type:B.type,value:b[B.key],id:v.value,contents:B==null?void 0:B.options})}),b!=null&&b.children&&((y=b==null?void 0:b.children)==null?void 0:y.length)>0&&E.push({children:b==null?void 0:b.children,isFormColHidden:!0}),f.value=b==null?void 0:b.id,D.value=E,C.value=E},H=b=>{d.value=!0;let E=[];At==null||At.forEach(y=>{let B=x.cloneDeep(v.value)+1;w.setTableIndex(B),E.push({label:y==null?void 0:y.label,name:y==null?void 0:y.label,type:y.type,value:"",id:v.value,contents:y==null?void 0:y.options})}),c.value=b==null?void 0:b.id,D.value=E,C.value=E},M=b=>{let E=x.cloneDeep(C.value);E=E==null?void 0:E.map(y=>(y.children||(y.value=b==null?void 0:b[y.name]),y)),C.value=E},ve=()=>{var E,y;D.value=C.value;let b={};if(f.value!=="")b.id=f.value,(E=D.value)==null||E.forEach(B=>{const h=At==null?void 0:At.find(ce=>(ce==null?void 0:ce.label)===(B==null?void 0:B.label));h?b[h.key]=B.value:B!=null&&B.children&&B.children.length>0&&(b.children=B.children)}),d.value=!1,r("fixChange",{contents:x.cloneDeep(b),id:c.value,type:"fix"});else{let B=x.cloneDeep(v.value)+1;w.setTableIndex(B),b.id="idChild"+v.value,(y=D.value)==null||y.forEach(h=>{const ce=At==null?void 0:At.find(Ne=>(Ne==null?void 0:Ne.label)===(h==null?void 0:h.label));ce?b[ce.key]=h.value:h!=null&&h.children&&h.children.length>0&&(b.children=h.children)}),d.value=!1,r("fixChange",{contents:x.cloneDeep(b),id:c.value,type:"add"})}f.value="",D.value=[],C.value=[]},K=()=>{d.value=!1,f.value="",c.value="",D.value=[],C.value=[]},O=b=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{r("deleteChange",b),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},G=b=>{r("deleteChange",b)};return(b,E)=>{const y=e.resolveComponent("svg-icon"),B=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",Ci,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(s==null?void 0:s.tableChildContents,(h,ce)=>(e.openBlock(),e.createElementBlock("div",Di,[e.createElementVNode("div",_i,[e.createElementVNode("div",Ei,e.toDisplayString(h.label),1),e.createElementVNode("div",Si,[e.createVNode(y,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ne=>H(h)},null,8,["onClick"]),e.createVNode(y,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ne=>R(h)},null,8,["onClick"]),e.createVNode(y,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ne=>O(h)},null,8,["onClick"])])]),h!=null&&h.children&&h.children.length>0?(e.openBlock(),e.createElementBlock("div",Ti,[e.createVNode(wi,{tableChildContents:h==null?void 0:h.children,onDeleteChange:G,onFixChange:F},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),256)),e.createVNode(Xt.ssDialog,{visible:d.value,onBeforeDestroy:K,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Bi,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:D.value,key:D.value,isEnableWrap:!0,onChange:M},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Ii,[e.createVNode(B,{onClick:K,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>E[0]||(E[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(B,{class:"ok-button button",onClick:ve,id:"themeButton"},{default:e.withCtx(()=>E[1]||(E[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},yr=Rt._export_sfc(Ni,[["__scopeId","data-v-ebd68fa1"]]),Ai={class:"table-operate-content"},Vi={class:"table-operate-item"},Oi={class:"operate-title"},Mi={class:"operate-content"},zi={class:"fix-content"},Fi={class:"fix-content-label"},Ri={class:"fix-button"},Pi={key:0},Li={class:"operate-title"},$i={class:"operate-content"},ji={class:"fix-content"},Ui={class:"fix-content-label"},Ki={class:"fix-button"},Wi={class:"operate-title"},Hi={class:"operate-content"},qi={class:"fix-content"},Gi={class:"fix-content-label"},Xi={class:"fix-button"},Yi={class:"operate-title"},Ji={class:"operate-content"},Zi={class:"fix-content"},Qi={class:"fix-content-label"},es={class:"fix-button"},ts={class:"operate-content"},ns={style:{display:"flex","justify-content":"space-between"}},as={class:"form-content"},os={class:"dialog-footer"},rs={class:"form-content"},ls={class:"dialog-footer"},is={class:"form-content"},ss={class:"dialog-footer"},cs={class:"form-content"},us={class:"dialog-footer"},ds={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const s=a,r=l,d=e.ref([]),c=e.ref(!1),w=e.ref(!1),v=e.ref([]),f=e.ref(!1),D=e.ref([]),C=e.ref(!1),F=e.ref([]),R=e.ref(""),H=e.ref(""),M=e.ref([]),ve=e.ref([]),K=e.ref([]),O=e.ref([]),G=e.ref(!1),b=e.ref([]),E=e.ref([]),y=e.ref(0),B=e.ref([]),h=e.ref([]),ce=e.ref([]),Ne=()=>{G.value=!0;let m=[];wn==null||wn.forEach(T=>{y.value++,m.push({label:T==null?void 0:T.label,name:T==null?void 0:T.label,type:T.type,value:(T==null?void 0:T.key)==="background"?"var(--ssComponent-primary-color)":"",id:y.value,contents:T==null?void 0:T.options})}),b.value=m,E.value=m},nt=()=>{var T,U,J;w.value=!0;let m=[];(J=(U=(T=Ie.FormContent)==null?void 0:T.find(_=>(_==null?void 0:_.key)==="Input"))==null?void 0:U.value)==null||J.forEach(_=>{y.value++,m.push({label:_==null?void 0:_.label,name:(_==null?void 0:_.name)||(_==null?void 0:_.label),type:_.type,value:(_==null?void 0:_.label)==="类型"?"Input":"",id:y.value,contents:_==null?void 0:_.options})}),B.value=m,h.value=m},xe=m=>{m||(B.value=h.value)},Re=async m=>{var T,U,J,_,oe,Ae,I,ee,$,W,Ee,ie;if((m==null?void 0:m.类型)!==((U=(T=h.value)==null?void 0:T.find(q=>(q==null?void 0:q.label)==="类型"))==null?void 0:U.value)){let q=[],Z=await((oe=(_=(J=Ie.FormContent)==null?void 0:J.find(de=>(de==null?void 0:de.key)===((m==null?void 0:m.类型)===""?"Input":m==null?void 0:m.类型)))==null?void 0:_.value)==null?void 0:oe.value)?await((W=($=(ee=Ie.FormContent)==null?void 0:ee.find(de=>(de==null?void 0:de.key)===((m==null?void 0:m.类型)===""?"Input":m==null?void 0:m.类型)))==null?void 0:$.value)==null?void 0:W.value):(I=(Ae=Ie.FormContent)==null?void 0:Ae.find(de=>(de==null?void 0:de.key)===((m==null?void 0:m.类型)===""?"Input":m==null?void 0:m.类型)))==null?void 0:I.value;if(Z==null||Z.forEach(de=>{y.value++,q.push({label:de==null?void 0:de.label,name:(de==null?void 0:de.name)||(de==null?void 0:de.label),type:de.type,value:de!=null&&de.属性名?(m==null?void 0:m.prop)||(m==null?void 0:m.name)||(m==null?void 0:m.label):(m==null?void 0:m[de.label])??"",id:y.value,contents:de==null?void 0:de.options,prop:(de==null?void 0:de.prop)||(de==null?void 0:de.name)||(de==null?void 0:de.label)})}),m!=null&&m.菜单选项&&((Ee=m==null?void 0:m.菜单选项)==null?void 0:Ee.length)>0){const de=await Ie.menuToContentType(m==null?void 0:m.菜单选项);q=q==null?void 0:q.map(me=>((me==null?void 0:me.name)==="组信息选项"&&(me.contents=de),me))}h.value=await Ie.selectToBase(x.cloneDeep(q)),B.value=await Ie.selectToBase(x.cloneDeep(q))}else{let q=x.cloneDeep(B.value);if(q=q==null?void 0:q.map(Z=>(Z.value=m==null?void 0:m[Z.name],Z)),m!=null&&m.菜单选项&&((ie=m==null?void 0:m.菜单选项)==null?void 0:ie.length)>0){const Z=await Ie.menuToContentType(m==null?void 0:m.菜单选项);q=q==null?void 0:q.map(de=>((de==null?void 0:de.name)==="组信息选项"&&(de.contents=Z),de))}q=Ie.formToOptionsContents(q),h.value=await Ie.selectToBase(x.cloneDeep(q))}},Pe=async m=>{await Re(m),B.value=h.value},P=(m,T)=>{if((T==null?void 0:T.type)=="Select"&&(m==null?void 0:m.key)==="selectRelateType"){const U=T==null?void 0:T.optionUrl;return(U==null?void 0:U.selectRelateType)||T[m.key]}if((T==null?void 0:T.type)=="Select"&&(m==null?void 0:m.key)==="menuSelect"){const U=T==null?void 0:T.optionUrl;return(U==null?void 0:U.menuSelect)||T[m.key]}if((T==null?void 0:T.type)=="Select"&&(m==null?void 0:m.key)==="groupSelect"){const U=T==null?void 0:T.optionUrl;return(U==null?void 0:U.groupSelect)||T[m.key]}if((T==null?void 0:T.type)=="Select"&&(m==null?void 0:m.key)==="originalContent")return(T==null?void 0:T.value)||T[m.key];if((T==null?void 0:T.type)=="Select"&&(m==null?void 0:m.key)==="multiple"){const U=T[m.key];return pr(U)?U:m.default}return(m==null?void 0:m.label)==="类型"&&T[m.key]===""?"Input":(m==null?void 0:m.key)==="isFormColHidden"&&!T[m.key]?!1:T[m.key]},re=async m=>{var J,_,oe,Ae,I,ee,$,W,Ee;w.value=!0;let T=[];const U=await((oe=(_=(J=Ie.FormContent)==null?void 0:J.find(ie=>(ie==null?void 0:ie.key)===((m==null?void 0:m.type)===""?"Input":m==null?void 0:m.type)))==null?void 0:_.value)==null?void 0:oe.value)?await((W=($=(ee=Ie.FormContent)==null?void 0:ee.find(ie=>(ie==null?void 0:ie.key)===((m==null?void 0:m.type)===""?"Input":m==null?void 0:m.type)))==null?void 0:$.value)==null?void 0:W.value):(I=(Ae=Ie.FormContent)==null?void 0:Ae.find(ie=>(ie==null?void 0:ie.key)===((m==null?void 0:m.type)===""?"Input":m==null?void 0:m.type)))==null?void 0:I.value;if(U==null||U.forEach(ie=>{y.value++,T.push({label:ie==null?void 0:ie.label,name:(ie==null?void 0:ie.name)||(ie==null?void 0:ie.label),type:ie.type,value:(ie==null?void 0:ie.label)==="属性名"?(m==null?void 0:m.prop)||(m==null?void 0:m.name)||(m==null?void 0:m.label):P(ie,m),id:y.value,contents:ie==null?void 0:ie.options})}),m!=null&&m.menuSelect&&((Ee=m==null?void 0:m.menuSelect)==null?void 0:Ee.length)>0){const ie=await Ie.menuToContentType(m==null?void 0:m.menuSelect);T=T==null?void 0:T.map(q=>((q==null?void 0:q.name)==="组信息选项"&&(q.contents=ie),q))}R.value=m==null?void 0:m.id,B.value=await Ie.selectToBase(Ie.formToOptionsContents(T)),h.value=await Ie.selectToBase(Ie.formToOptionsContents(T))},ne=m=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var T,U;ce.value=(T=x.cloneDeep(ce.value))==null?void 0:T.filter(J=>(J==null?void 0:J.id)!==(m==null?void 0:m.id)),r("change",(U=x.cloneDeep(s.originalItemContents))==null?void 0:U.map(J=>((J==null?void 0:J.key)==="tableToForm"&&(J.contents=ce.value),J))),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},pe=()=>{w.value=!1,B.value=[],R.value=""},We=async()=>{var J,_,oe,Ae,I,ee,$,W,Ee,ie;B.value=h.value;let m={};R.value!==""?m.id=R.value:(y.value++,m.id="id"+y.value);let T=await((oe=(_=(J=Ie.FormContent)==null?void 0:J.find(q=>{var Z,de;return(q==null?void 0:q.key)===(((de=(Z=B.value)==null?void 0:Z.find(me=>(me==null?void 0:me.label)==="类型"))==null?void 0:de.value)??"label")}))==null?void 0:_.value)==null?void 0:oe.value)??((I=(Ae=Ie.FormContent)==null?void 0:Ae.find(q=>{var Z,de;return(q==null?void 0:q.key)===(((de=(Z=B.value)==null?void 0:Z.find(me=>(me==null?void 0:me.label)==="类型"))==null?void 0:de.value)??"label")}))==null?void 0:I.value);if((ee=B.value)==null||ee.forEach(q=>{const Z=T==null?void 0:T.find(de=>(de==null?void 0:de.label)===(q==null?void 0:q.label));Z&&(m[Z.key]=q.value)}),m.name=m.label,($=ce.value)!=null&&$.find(q=>q.id===m.id))ce.value=(W=ce.value)==null?void 0:W.map(q=>(q.id===m.id&&(q=m),q));else{let q=x.cloneDeep(ce.value);ce.value||(ce.value=[]),q.push(m),ce.value=q}ce.value=ce.value.map(({id:q,...Z})=>Z),w.value=!1,R.value="";let U=x.cloneDeep(s.originalItemContents);(Ee=x.cloneDeep(s.originalItemContents))!=null&&Ee.find(q=>(q==null?void 0:q.key)==="tableToForm")?U=(ie=x.cloneDeep(s.originalItemContents))==null?void 0:ie.map(q=>((q==null?void 0:q.key)==="tableToForm"&&(q.contents=ce.value),q)):U.push({key:"tableToForm",contents:ce.value}),r("change",U)},at=m=>{G.value=!0;let T=[];wn==null||wn.forEach(U=>{y.value++,T.push({label:U==null?void 0:U.label,name:U==null?void 0:U.label,type:U.type,value:m[U.key],id:y.value,contents:U==null?void 0:U.options})}),R.value=m==null?void 0:m.id,b.value=T,E.value=T};e.watch(()=>C.value,()=>{var T,U;let m=x.cloneDeep(s.originalItemContents);(T=x.cloneDeep(s.originalItemContents))!=null&&T.find(J=>(J==null?void 0:J.key)==="page")?m=(U=x.cloneDeep(s.originalItemContents))==null?void 0:U.map(J=>((J==null?void 0:J.key)==="page"&&(J.contents=C.value),J)):m.push({key:"page",contents:C.value}),r("change",m)},{deep:!0});const X=m=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var T,U;ve.value=(T=x.cloneDeep(ve.value))==null?void 0:T.filter(J=>(J==null?void 0:J.id)!==(m==null?void 0:m.id)),r("change",(U=x.cloneDeep(s.originalItemContents))==null?void 0:U.map(J=>((J==null?void 0:J.key)==="extraButton"&&(J.contents=ve.value),J))),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},V=()=>{var U,J,_,oe,Ae;b.value=E.value;let m={};if(R.value!==""?m.id=R.value:(y.value++,m.id="id"+y.value),(U=b.value)==null||U.forEach(I=>{const ee=wn==null?void 0:wn.find($=>($==null?void 0:$.label)===(I==null?void 0:I.label));ee?m[ee.key]=I.value:I!=null&&I.children&&I.children.length>0&&(m.children=I.children)}),(J=ve.value)!=null&&J.find(I=>I.id===m.id))ve.value=(_=ve.value)==null?void 0:_.map(I=>(I.id===m.id&&(I=m),I));else{let I=x.cloneDeep(ve.value)??[];I.push(m),ve.value=I}G.value=!1,R.value="";let T=x.cloneDeep(s.originalItemContents);(oe=x.cloneDeep(s.originalItemContents))!=null&&oe.find(I=>(I==null?void 0:I.key)==="extraButton")?T=(Ae=x.cloneDeep(s.originalItemContents))==null?void 0:Ae.map(I=>((I==null?void 0:I.key)==="extraButton"&&(I.contents=ve.value),I)):T.push({key:"extraButton",contents:ve.value}),r("change",T)},te=m=>{let T=x.cloneDeep(E.value);T=T==null?void 0:T.map(U=>(U.children||(U.value=m==null?void 0:m[U.name]),U)),E.value=T},ye=()=>{G.value=!1,b.value=[],R.value=""},ue=m=>{f.value=!0;let T=[];Cn==null||Cn.forEach(U=>{y.value++,T.push({label:U==null?void 0:U.label,name:U==null?void 0:U.label,type:U.type,value:m[U.key],id:y.value,contents:U==null?void 0:U.options})}),R.value=m==null?void 0:m.id,K.value=T,O.value=T},Ce=m=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var T,U;M.value=(T=x.cloneDeep(M.value))==null?void 0:T.filter(J=>(J==null?void 0:J.id)!==(m==null?void 0:m.id)),r("change",(U=x.cloneDeep(s.originalItemContents))==null?void 0:U.map(J=>((J==null?void 0:J.key)==="rowButton"&&(J.contents=M.value),J))),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},Ze=()=>{c.value=!0;let m=[];At==null||At.forEach(T=>{y.value++,m.push({label:T==null?void 0:T.label,name:T==null?void 0:T.label,type:T.type,value:"",id:y.value,contents:T==null?void 0:T.options})}),D.value=m,F.value=m},ae=()=>{f.value=!0;let m=[];Cn==null||Cn.forEach(T=>{y.value++,m.push({label:T==null?void 0:T.label,name:T==null?void 0:T.label,type:T.type,value:"",id:y.value,contents:T==null?void 0:T.options})}),K.value=m,O.value=m},De=m=>{let T=x.cloneDeep(O.value);T=T==null?void 0:T.map(U=>(U.children||(U.value=m==null?void 0:m[U.name]),U)),O.value=T},N=()=>{var U,J,_,oe,Ae;K.value=O.value;let m={};if(R.value!==""?m.id=R.value:(y.value++,m.id="id"+y.value),(U=K.value)==null||U.forEach(I=>{const ee=Cn==null?void 0:Cn.find($=>($==null?void 0:$.label)===(I==null?void 0:I.label));ee?m[ee.key]=I.value:I!=null&&I.children&&I.children.length>0&&(m.children=I.children)}),(J=M.value)!=null&&J.find(I=>I.id===m.id))M.value=(_=M.value)==null?void 0:_.map(I=>(I.id===m.id&&(I=m),I));else{let I=x.cloneDeep(M.value);I.push(m),M.value=I}f.value=!1,R.value="";let T=x.cloneDeep(s.originalItemContents);(oe=x.cloneDeep(s.originalItemContents))!=null&&oe.find(I=>(I==null?void 0:I.key)==="rowButton")?T=(Ae=x.cloneDeep(s.originalItemContents))==null?void 0:Ae.map(I=>((I==null?void 0:I.key)==="rowButton"&&(I.contents=M.value),I)):T.push({key:"rowButton",contents:M.value}),r("change",T)},Ge=()=>{f.value=!1,R.value="",O.value=[],K.value=[]},Xe=m=>{c.value=!0;let T=[];At==null||At.forEach(U=>{y.value++,T.push({label:U==null?void 0:U.label,name:U==null?void 0:U.label,type:U.type,value:"",id:y.value,contents:U==null?void 0:U.options})}),D.value=T,H.value=m==null?void 0:m.id,F.value=T},Be=m=>{var T;v.value=hr(x.cloneDeep(v.value),m==null?void 0:m.id),r("change",(T=x.cloneDeep(s.originalItemContents))==null?void 0:T.map(U=>{var J;return(U==null?void 0:U.key)==="header"&&(U.contents=(J=v.value)!=null&&J.some(_=>_==null?void 0:_.children)?[v.value]:v.value),U}))},le=m=>{var U,J,_;m.type==="fix"?m.id!==""?v.value=mr(v.value,m):v.value=vr(v.value,m==null?void 0:m.contents):v.value=gr(v.value,m),v.value=(U=v.value)!=null&&U.some(oe=>oe==null?void 0:oe.children)?[v.value]:v.value,R.value="";let T=x.cloneDeep(s.originalItemContents);(J=x.cloneDeep(s.originalItemContents))!=null&&J.find(oe=>(oe==null?void 0:oe.key)==="header")?T=(_=x.cloneDeep(s.originalItemContents))==null?void 0:_.map(oe=>((oe==null?void 0:oe.key)==="header"&&(oe.contents=v.value),oe)):T.push({key:"header",contents:v.value}),r("change",T)},Q=m=>{var U;c.value=!0;let T=[];At==null||At.forEach(J=>{y.value++,T.push({label:J==null?void 0:J.label,name:J==null?void 0:J.label,type:J.type,value:m[J.key],id:y.value,contents:J==null?void 0:J.options})}),m!=null&&m.children&&((U=m==null?void 0:m.children)==null?void 0:U.length)>0&&T.push({children:m==null?void 0:m.children,isFormColHidden:!0}),R.value=m==null?void 0:m.id,H.value="",D.value=T,F.value=T},se=m=>{let T=x.cloneDeep(F.value);T=T==null?void 0:T.map(U=>(U.children||(U.value=m==null?void 0:m[U.name]),U)),F.value=T},_e=()=>{c.value=!1,R.value="",H.value="",F.value=[]},He=()=>{var U,J,_,oe,Ae,I;D.value=F.value;let m={};if(R.value!==""?m.id=R.value:(y.value++,m.id="id"+y.value),(U=D.value)==null||U.forEach(ee=>{const $=At==null?void 0:At.find(W=>(W==null?void 0:W.label)===(ee==null?void 0:ee.label));$?m[$.key]=ee.value:ee!=null&&ee.children&&ee.children.length>0&&(m.children=ee.children)}),(J=v.value)!=null&&J.find(ee=>ee.id===m.id))v.value=(_=v.value)==null?void 0:_.map(ee=>(ee.id===m.id&&(ee=m),ee));else{let ee=x.cloneDeep(v.value)??[];H.value===""?ee.push(m):ee=ee==null?void 0:ee.map($=>($.id===H.value&&($.children||($.children=[]),$.children.push(m)),$)),v.value=ee}v.value=(oe=v.value)!=null&&oe.some(ee=>ee==null?void 0:ee.children)?[v.value]:v.value,c.value=!1,R.value="",H.value="";let T=x.cloneDeep(s.originalItemContents);(Ae=x.cloneDeep(s.originalItemContents))!=null&&Ae.find(ee=>(ee==null?void 0:ee.key)==="header")?T=(I=x.cloneDeep(s.originalItemContents))==null?void 0:I.map(ee=>((ee==null?void 0:ee.key)==="header"&&(ee.contents=v.value),ee)):T.push({key:"header",contents:v.value}),r("change",T)},dt=m=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var T,U;v.value=(T=x.cloneDeep(v.value))==null?void 0:T.filter(J=>(J==null?void 0:J.id)!==(m==null?void 0:m.id)),r("change",(U=x.cloneDeep(s.originalItemContents))==null?void 0:U.map(J=>{var _;return(J==null?void 0:J.key)==="header"&&(J.contents=(_=v.value)!=null&&_.some(oe=>oe==null?void 0:oe.children)?[v.value]:v.value),J})),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return e.watch(()=>s.originalItemContents,()=>{var m,T,U,J,_,oe,Ae,I,ee,$,W,Ee,ie,q,Z,de,me,we,be;if(!(!s.originalItemContents||s.originalItemContents.length===0))if(d.value=x.cloneDeep(s.originalItemContents),v.value=(T=(m=d.value)==null?void 0:m.find(j=>(j==null?void 0:j.key)==="header"))==null?void 0:T.contents,M.value=(J=(U=d.value)==null?void 0:U.find(j=>(j==null?void 0:j.key)==="rowButton"))==null?void 0:J.contents,ve.value=(oe=(_=d.value)==null?void 0:_.find(j=>(j==null?void 0:j.key)==="extraButton"))==null?void 0:oe.contents,C.value=(I=(Ae=d.value)==null?void 0:Ae.find(j=>(j==null?void 0:j.key)==="page"))!=null&&I.contents?!!(($=(ee=d.value)==null?void 0:ee.find(j=>(j==null?void 0:j.key)==="page"))!=null&&$.contents):!1,ce.value=(Ee=(W=d.value)==null?void 0:W.find(j=>(j==null?void 0:j.key)==="tableToForm"))==null?void 0:Ee.contents,v.value=(ie=v.value)==null?void 0:ie.map((j,Oe)=>(Array.isArray(j)?j=di(j):j={label:(j==null?void 0:j.label)??"",prop:(j==null?void 0:j.label)==="操作"?"operate":j==null?void 0:j.prop,width:j!=null&&j.width?parseInt(j.width):"",fixed:(j==null?void 0:j.fixed)??void 0,sortable:(j==null?void 0:j.sortable)??!1,align:(j==null?void 0:j.align)??"left",showOverflowTooltip:(j==null?void 0:j.showOverflowTooltip)??!0,isNotDrag:(j==null?void 0:j.isNotDrag)??!1,isEditCol:(j==null?void 0:j.isEditCol)??!1,isOperate:(j==null?void 0:j.isOperate)??!1,id:(j==null?void 0:j.id)??Oe,formMenuSelect:(j==null?void 0:j.formMenuSelect)??void 0,groupSelect:(j==null?void 0:j.groupSelect)??void 0},j)),v.value=(q=v.value)!=null&&q.every(j=>Array.isArray(j))?(Z=v.value)==null?void 0:Z[0]:v.value,M.value=(de=M.value)==null?void 0:de.map((j,Oe)=>j={label:(j==null?void 0:j.label)??"",type:(j==null?void 0:j.type)??"",textColor:(j==null?void 0:j.textColor)??"#000000",id:(j==null?void 0:j.id)??Oe}),ve.value=(me=ve.value)==null?void 0:me.map((j,Oe)=>j={label:(j==null?void 0:j.label)??"",type:(j==null?void 0:j.type)??"",background:(j==null?void 0:j.background)??"var(--ssComponent-primary-color)",id:(j==null?void 0:j.id)??Oe}),ce.value)ce.value=(be=ce.value)==null?void 0:be.map(j=>{y.value++;let Oe=j;return Oe.id=y.value,Oe});else{let j=[];const Oe=(we=Ie.getColumnChild(x.cloneDeep(v.value)))==null?void 0:we.filter(ge=>(ge==null?void 0:ge.prop)!=="operate");Oe==null||Oe.forEach(ge=>{var je;y.value++,j.push({label:ge==null?void 0:ge.label,name:(ge==null?void 0:ge.prop)||(ge==null?void 0:ge.label),type:ge!=null&&ge.groupSelect?"Select":"Input",value:"",id:y.value,contents:ge==null?void 0:ge.options,menuSelect:ge==null?void 0:ge.formMenuSelect,groupSelect:(je=ge==null?void 0:ge.groupSelect)==null?void 0:je.split(":"),selectRelateType:"关联绑定列"})}),ce.value=j}},{deep:!0,immediate:!0}),(m,T)=>{const U=e.resolveComponent("svg-icon"),J=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",Ai,[e.createElementVNode("div",Vi,[e.createElementVNode("div",Oi,[T[2]||(T[2]=e.createElementVNode("div",null,e.toDisplayString("表头"),-1)),e.createVNode(J,{class:"icon-content",onClick:Ze,id:"themeButton"},{icon:e.withCtx(()=>[e.createVNode(U,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[T[1]||(T[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",Mi,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(v.value,(_,oe)=>(e.openBlock(),e.createElementBlock("div",{key:oe},[e.createElementVNode("div",zi,[e.createElementVNode("div",Fi,e.toDisplayString(_==null?void 0:_.label),1),e.createElementVNode("div",Ri,[e.createVNode(U,{name:"ChildAdd",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ae=>Xe(_)},null,8,["onClick"]),e.createVNode(U,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ae=>Q(_)},null,8,["onClick"]),e.createVNode(U,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ae=>dt(_)},null,8,["onClick"])])]),_!=null&&_.children&&_.children.length>0?(e.openBlock(),e.createElementBlock("div",Pi,[e.createVNode(yr,{tableChildContents:_==null?void 0:_.children,onDeleteChange:Be,onFixChange:le},null,8,["tableChildContents"])])):e.createCommentVNode("",!0)]))),128))]),e.createElementVNode("div",Li,[T[4]||(T[4]=e.createElementVNode("div",null,e.toDisplayString("行内按钮"),-1)),e.createVNode(J,{class:"icon-content",id:"themeButton",onClick:ae},{icon:e.withCtx(()=>[e.createVNode(U,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[T[3]||(T[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",$i,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(M.value,(_,oe)=>(e.openBlock(),e.createElementBlock("div",{key:oe},[e.createElementVNode("div",ji,[e.createElementVNode("div",Ui,e.toDisplayString(_==null?void 0:_.label),1),e.createElementVNode("div",Ki,[e.createVNode(U,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:Ae=>ue(_)},null,8,["onClick"]),e.createVNode(U,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ae=>Ce(_)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",Wi,[T[6]||(T[6]=e.createElementVNode("div",null,e.toDisplayString("表外按钮"),-1)),e.createVNode(J,{class:"icon-content",id:"themeButton",onClick:Ne},{icon:e.withCtx(()=>[e.createVNode(U,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[T[5]||(T[5]=e.createTextVNode(" 新增 "))]),_:1,__:[5]})]),e.createElementVNode("div",Hi,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ve.value,(_,oe)=>(e.openBlock(),e.createElementBlock("div",{key:oe},[e.createElementVNode("div",qi,[e.createElementVNode("div",Gi,e.toDisplayString(_==null?void 0:_.label),1),e.createElementVNode("div",Xi,[e.createVNode(U,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:Ae=>at(_)},null,8,["onClick"]),e.createVNode(U,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ae=>X(_)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",Yi,[T[8]||(T[8]=e.createElementVNode("div",null,e.toDisplayString("表格弹框字段设置"),-1)),e.createVNode(J,{class:"icon-content",id:"themeButton",onClick:nt},{icon:e.withCtx(()=>[e.createVNode(U,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[T[7]||(T[7]=e.createTextVNode(" 新增 "))]),_:1,__:[7]})]),e.createElementVNode("div",Ji,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(ce.value,(_,oe)=>(e.openBlock(),e.createElementBlock("div",{key:oe},[e.createElementVNode("div",Zi,[e.createElementVNode("div",Qi,e.toDisplayString(_==null?void 0:_.label),1),e.createElementVNode("div",es,[e.createVNode(U,{name:"ChildFix",style:{width:"24px",height:"24px"},class:"svg-icon-content",onClick:Ae=>re(_)},null,8,["onClick"]),e.createVNode(U,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:Ae=>ne(_)},null,8,["onClick"])])])]))),128))]),T[10]||(T[10]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("分页"))],-1)),e.createElementVNode("div",ts,[e.createElementVNode("div",ns,[T[9]||(T[9]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否分页"),-1)),e.createVNode(Bt._sfc_main$1,{modelValue:C.value,"onUpdate:modelValue":T[0]||(T[0]=_=>C.value=_)},null,8,["modelValue"])])])]),e.createVNode(Xt.ssDialog,{visible:c.value,onBeforeDestroy:_e,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",as,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:D.value,key:D.value,isEnableWrap:!0,onChange:se},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",os,[e.createVNode(J,{onClick:_e,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>T[11]||(T[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(J,{class:"ok-button button",onClick:He,id:"themeButton"},{default:e.withCtx(()=>T[12]||(T[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible"]),e.createVNode(Xt.ssDialog,{visible:f.value,onBeforeDestroy:Ge,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",rs,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:K.value,key:K.value,isEnableWrap:!0,onChange:De},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",ls,[e.createVNode(J,{onClick:Ge,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>T[13]||(T[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(J,{class:"ok-button button",onClick:N,id:"themeButton"},{default:e.withCtx(()=>T[14]||(T[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible"]),e.createVNode(Xt.ssDialog,{visible:G.value,onBeforeDestroy:ye,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",is,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:b.value,key:b.value,isEnableWrap:!0,onChange:te},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",ss,[e.createVNode(J,{onClick:ye,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>T[15]||(T[15]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[15]}),e.createVNode(J,{class:"ok-button button",onClick:V,id:"themeButton"},{default:e.withCtx(()=>T[16]||(T[16]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[16]})])]),_:1},8,["visible"]),e.createVNode(Xt.ssDialog,{visible:w.value,onBeforeDestroy:pe,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",cs,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:B.value,key:B.value,isEnableWrap:!0,onChange:Re,onChangeVisible:xe,onBlurChange:Pe},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",us,[e.createVNode(J,{onClick:pe,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>T[17]||(T[17]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[17]}),e.createVNode(J,{class:"ok-button button",onClick:We,id:"themeButton"},{default:e.withCtx(()=>T[18]||(T[18]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[18]})])]),_:1},8,["visible"])])}}},ps=Rt._export_sfc(ds,[["__scopeId","data-v-7a6b87b5"]]),fs=x.useModelComp(x.pinia),{pageMapState:hs}=x.storeToRefs(fs),vs=x.useMenuState(x.pinia),{activeMenuPath:ms}=x.storeToRefs(vs),gs=e.ref(24),ys=e.ref(6),bs=e.ref(70),ks=e.ref(.18),xs=e.ref(45),ws=(a,l,s,r)=>{var d,c,w,v,f,D,C,F,R,H,M,ve,K,O,G,b;return{x:((c=(d=a==null?void 0:a.value)==null?void 0:d.tableData)==null?void 0:c.x)||l%2*12,y:((v=(w=a==null?void 0:a.value)==null?void 0:w.tableData)==null?void 0:v.y)||l,w:((D=(f=a==null?void 0:a.value)==null?void 0:f.tableData)==null?void 0:D.w)||gs.value,h:((F=(C=a==null?void 0:a.value)==null?void 0:C.tableData)==null?void 0:F.h)||s,minW:((H=(R=a==null?void 0:a.value)==null?void 0:R.tableData)==null?void 0:H.minW)||ys.value,minH:((ve=(M=a==null?void 0:a.value)==null?void 0:M.tableData)==null?void 0:ve.minH)||ks.value,maxH:((O=(K=a==null?void 0:a.value)==null?void 0:K.tableData)==null?void 0:O.maxH)||xs.value,i:((b=(G=a==null?void 0:a.value)==null?void 0:G.tableData)==null?void 0:b.i)||l,id:(a==null?void 0:a.id)||l+"",component:r}},Cs=(a,l)=>{var r,d,c,w,v,f,D,C;let s=1;if(a!=null&&a.compData&&Array.isArray(a==null?void 0:a.compData))if(((r=a==null?void 0:a.comp)==null?void 0:r.toUpperCase())==="TABLE"){if(((w=(c=(d=a==null?void 0:a.compData)==null?void 0:d.find(R=>(R==null?void 0:R.key)==="tableContents"))==null?void 0:c.contents)==null?void 0:w.length)===0)return 2}else((v=a==null?void 0:a.comp)==null?void 0:v.toUpperCase())==="FORM"&&(s=((C=(D=(f=a==null?void 0:a.compData)==null?void 0:f.find(R=>(R==null?void 0:R.key)==="formContent"))==null?void 0:D.contents)==null?void 0:C.length)/5);return s*2},br=(a,l,s)=>{var w,v;const r=(v=(w=hs.value)==null?void 0:w[ms.value])==null?void 0:v.filter(f=>{var D;return((D=f==null?void 0:f.key)==null?void 0:D.type)==="gridLayout"}),d=r==null?void 0:r.find(f=>{var D,C,F;return((F=(C=(D=f==null?void 0:f.value)==null?void 0:D.tableData)==null?void 0:C.component)==null?void 0:F.id)===a.id}),c=Cs(a);return a!=null&&a.children&&(a==null?void 0:a.children.length)>0&&(a.children=a.children.map((f,D)=>br(f,D))),{...ws(d,l,c,a)}},Ds=(a,l)=>{if((a==null?void 0:a.length)===0)return[];const s=x.cloneDeep(a);return Array.isArray(a)?s==null?void 0:s.map((r,d)=>br(r,d)):[]},_s=a=>({TABLE:{overall:[{label:"栅格布局",prop:"isGridLayout",type:"switch",value:!1,disabled:!1,activeText:"启用",inactiveText:"默认"},{label:"界面布局",prop:"layout",type:"radio",value:"vertical",options:[{label:"垂直",value:"vertical"},{label:"水平",value:"horizontal"}]},{label:"流程式布局",prop:"isStepLayout",type:"radio",value:!1,options:[{label:"启用",value:!0,disabled:!1},{label:"禁用",value:!1,disabled:!1}]}],alone:[{label:"默认显示序号",prop:"showIndex",type:"radio",value:!1,options:[{label:"是",value:!0},{label:"否",value:!1}]},{label:"浏览视图配置",prop:"viewport",type:"checkbox",value:["read"],options:[{label:"只读视图",value:"read"},{label:"编辑视图",value:"edit"}]},{label:"是否选择迁移",prop:"allowMove",type:"radio",value:!1,options:[{label:"是",value:!0},{label:"否",value:!1}]}]}}),Es=(a,l)=>a==null?void 0:a.map(s=>{for(const r in l)if(r===(s==null?void 0:s.prop))return{...s,value:l[r]};return s}),Ss=e.defineComponent({__name:"index",props:{compType:String,comp:Object,target:{type:String,default:"alone"},optionItems:Array},emits:["change"],setup(a,{emit:l}){const s=a,r=l,d=e.ref([]);e.watch(()=>s.compType,v=>{var C;const f=_s(s==null?void 0:s.optionItems),D=v?(C=f[v==null?void 0:v.toUpperCase()])==null?void 0:C[s==null?void 0:s.target]:[];d.value=D==null?void 0:D.map(F=>{for(const[R,H]of Object.entries((s==null?void 0:s.comp)||{}))if((F==null?void 0:F.prop)===R)return{...F,value:H};return F})},{immediate:!0});const c=v=>Bt.getComponent(v),w=v=>{var f,D;(v==null?void 0:v.prop)==="layout"&&(v==null?void 0:v.value)==="horizontal"?d.value=(f=d.value)==null?void 0:f.map(C=>{var F;return(C==null?void 0:C.prop)==="isStepLayout"?{...C,options:(F=C==null?void 0:C.options)==null?void 0:F.map(R=>({...R,disabled:!0}))}:(C==null?void 0:C.prop)==="isGridLayout"?{...C,disabled:!0}:C}):d.value=(D=d.value)==null?void 0:D.map(C=>{var F;return(C==null?void 0:C.prop)==="isStepLayout"?{...C,options:(F=C==null?void 0:C.options)==null?void 0:F.map(R=>({...R,disabled:!1}))}:(C==null?void 0:C.prop)==="isGridLayout"?{...C,disabled:!1}:C}),r("change",{target:s==null?void 0:s.target,styleConfigs:d.value,prop:v==null?void 0:v.prop})};return(v,f)=>{const D=e.resolveComponent("el-col"),C=e.resolveComponent("el-row");return e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,F=>(e.openBlock(),e.createBlock(C,{class:"style-row",key:F==null?void 0:F.prop},{default:e.withCtx(()=>[e.createVNode(D,{span:6,class:"style-row-title"},{default:e.withCtx(()=>[e.createTextVNode(e.toDisplayString(F==null?void 0:F.label)+":",1)]),_:2},1024),e.createVNode(D,{span:18,style:{display:"flex"}},{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(c(F.type)),{modelValue:F.value,"onUpdate:modelValue":R=>F.value=R,content:F==null?void 0:F.options,optionUrl:F==null?void 0:F.optionUrl,disabled:F==null?void 0:F.disabled,activeText:F==null?void 0:F.activeText,inactiveText:F==null?void 0:F.inactiveText,onChange:R=>w(F)},null,40,["modelValue","onUpdate:modelValue","content","optionUrl","disabled","activeText","inactiveText","onChange"]))]),_:2},1024)]),_:2},1024))),128)}}}),Ts=Rt._export_sfc(Ss,[["__scopeId","data-v-6c233914"]]),Bs=e.defineComponent({__name:"index",props:{compType:String,activeTabName:String,comp:Object,extendItem:{type:Object,default:{}},target:{type:String,default:"alone"},relatedData:Array},emits:["change","onButtonClick"],setup(a,{emit:l}){const s=a,r=l,d=[{required:!0,message:"输入不能为空",trigger:"blur"}],c=e.ref([]),w=O=>O==null?void 0:O.reduce((G,b)=>(G[b==null?void 0:b.prop]=b==null?void 0:b.rule,G),{}),v=e.computed(()=>({formRules:w(c.value),buttonValue:[{label:"取消",background:"#999999",color:"var(--ssbutton-theme-color)"},{label:"保存",background:"var(--ssbutton-theme-bg)",color:"var(--ssbutton-theme-color)"}]})),f=e.ref([]),D=e.ref(""),C=(O,G,b)=>{var B;let E=[];(s==null?void 0:s.activeTabName)==="任务配置"?(E=[{label:"任务名称",prop:"任务名称",key:"任务名称",value:"",width:1,isFormColHidden:!1},{label:"任务关键词",prop:"任务关键词",key:"任务关键词",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"列名称",value:"列名称",children:O},{label:"按钮名称",value:"按钮名称",children:G}]},{label:"执行任务",prop:"执行任务",key:"执行任务",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"进度设置",value:"进度设置",children:[{label:"计时",value:"计时",children:[{label:"倒计时",value:"倒计时"},{label:"进行时",value:"进行时"}]},{label:"进度条",value:"进度条"}]},{label:"统计",value:"统计",children:[{label:"统计规则",value:"统计规则",children:[{label:"求和",value:"求和"},{label:"自定义",value:"自定义"}]}]}]},{label:"执行动作",prop:"执行动作",key:"执行动作",type:"select",value:[],width:1,isFormColHidden:!1,contents:[{label:"点击时",value:"点击时"},{label:"页面加载时",value:"页面加载时"}]},{label:"执行交互",prop:"执行交互",key:"执行交互",type:"cascader",value:[],width:1,isFormColHidden:!1,config:{checkOnClickNode:!0,showPrefix:!1},contents:[{label:"界面显示",value:"界面显示",children:[{label:"主页",value:"主页"},{label:"详情页",value:"详情页"}]},{label:"弹窗提示",value:"弹窗提示"},{label:"后台提交",value:"后台提交"}]},{label:"任务状态",prop:"任务状态",key:"任务状态",type:"radio",value:"启动",width:1,isFormColHidden:!1,contents:[{label:"启动",value:"启动"},{label:"暂停",value:"暂停"}]}],c.value=[{prop:"任务名称",rule:d},{prop:"任务关键词",rule:d},{prop:"执行任务",rule:d},{prop:"执行动作",rule:d},{prop:"执行交互",rule:d}]):(s==null?void 0:s.activeTabName)==="任务关联"&&(E=[{prop:"关联名称",label:"关联名称",key:"关联名称",type:"input",value:"",isTableColHidden:!1,isFormColHidden:!1},{label:"关联形式",prop:"关联形式",key:"关联形式",type:"select",value:"流程式",width:1,isFormColHidden:!1,contents:[{label:"流程式",value:"流程式"}]},{label:"关联任务集合",prop:"关联任务集合",key:"关联任务集合",type:"tag",value:[],width:1,isFormColHidden:!1,contents:(B=s==null?void 0:s.relatedData)==null?void 0:B.map(h=>({label:h==null?void 0:h.任务名称,value:h==null?void 0:h.任务名称}))},{prop:"关联状态",label:"关联状态",key:"关联状态",type:"radio",value:"启动",isTableColHidden:!1,isFormColHidden:!1,contents:[{label:"启动",value:"启动"},{label:"暂停",value:"暂停"}]}],c.value=[{prop:"关联名称",rule:d},{prop:"关联状态",rule:d},{prop:"关联形式",rule:d},{prop:"关联任务集合",rule:d}]);let y;return b&&(b==null?void 0:b.length)>0?y=[...E,...F(O,G,b)]:y=E,y},F=(O,G,b)=>{const E=[{label:"进度关键词",prop:"进度关键词",key:"进度关键词",type:"input",value:"",width:2,isFormColHidden:!1,contents:[]},{label:"统计算法源",prop:"统计算法源",key:"统计算法源",type:"input",value:"",width:2,isFormColHidden:!1,contents:[]},{label:"统计是否获取错误集",prop:"统计是否获取错误集",key:"统计是否获取错误集",type:"radio",value:!1,width:2,isFormColHidden:!1,contents:[{label:"是",value:!0},{label:"否",value:!1}]}];return b?E==null?void 0:E.filter(y=>b==null?void 0:b.includes(y==null?void 0:y.prop)):E},R=(O,G)=>{var h,ce,Ne,nt,xe,Re,Pe,P,re;const b=((xe=(nt=(Ne=(ce=(h=s==null?void 0:s.comp)==null?void 0:h.compData)==null?void 0:ce.find(ne=>(ne==null?void 0:ne.key)==="header"))==null?void 0:Ne.contents)==null?void 0:nt.filter(ne=>(ne==null?void 0:ne.label)!=="操作"))==null?void 0:xe.map(ne=>({value:ne==null?void 0:ne.prop,label:ne.label})))||[],E=/button/i,y=((re=(P=(Pe=(Re=s==null?void 0:s.comp)==null?void 0:Re.compData)==null?void 0:Pe.filter(ne=>E.test(ne==null?void 0:ne.key)))==null?void 0:P.flatMap(ne=>ne==null?void 0:ne.contents))==null?void 0:re.map(ne=>({value:ne==null?void 0:ne.label,label:ne.label})))||[],B=C(b,y,O);f.value=G?Es(B,G):B,O&&(O==null?void 0:O.length)>0&&c.value.push(...O==null?void 0:O.map(ne=>({prop:ne,rule:d})))};e.onMounted(()=>{R(null,s==null?void 0:s.extendItem)});const H=O=>{const G=O==null?void 0:O[D.value];if(D.value==="执行任务"){if(!(G!=null&&G.join("/")))return;const b=G==null?void 0:G.join("/");R(b==="统计/统计规则/自定义"?["统计算法源","统计是否获取错误集"]:b==="进度设置/进度条"?["进度关键词"]:null,O)}},M=O=>{r("change",{target:s==null?void 0:s.target,extendConfigs:O})},ve=(O,G)=>{D.value=G==null?void 0:G.changeProp,H(O)},K=O=>{r("onButtonClick",O)};return(O,G)=>(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:f.value,key:f.value,isStartJustify:!1,isEnableWrap:!1,formRules:v.value.formRules,buttonValue:v.value.buttonValue,onChange:M,onBlurChange:ve,onOnButtonClick:K},null,8,["rowContents","formRules","buttonValue"]))}}),Is=Rt._export_sfc(Bs,[["__scopeId","data-v-7c660c1f"]]),Ns={};function As(a,l){return null}const Vs=Rt._export_sfc(Ns,[["render",As]]),Os={class:"form-operate-content"},Ms={class:"form-operate-item"},zs={class:"operate-title"},Fs={class:"operate-content"},Rs={class:"fix-content"},Ps={class:"fix-button"},Ls={class:"operate-title"},$s={class:"operate-content"},js={class:"fix-content"},Us={class:"fix-button"},Ks={style:{display:"flex","justify-content":"space-between"}},Ws={class:"form-content"},Hs={class:"dialog-footer"},qs={class:"form-content"},Gs={__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const s=a,r=l,d=e.ref(!1),c=e.ref([]),w=e.ref([]),v=e.ref(!1),f=e.ref([]),D=e.ref([]),C=e.ref(""),F=e.ref(!1),R=e.ref(0),H=e.ref([]),M=e.ref([]),ve=(P,re)=>{if((re==null?void 0:re.type)=="Select"&&(P==null?void 0:P.key)==="selectRelateType"){const ne=re==null?void 0:re.optionUrl;return(ne==null?void 0:ne.selectRelateType)||re[P.key]}if((re==null?void 0:re.type)=="Select"&&(P==null?void 0:P.key)==="menuSelect"){const ne=re==null?void 0:re.optionUrl;return(ne==null?void 0:ne.menuSelect)||re[P.key]}if((re==null?void 0:re.type)=="Select"&&(P==null?void 0:P.key)==="groupSelect"){const ne=re==null?void 0:re.optionUrl;return(ne==null?void 0:ne.groupSelect)||re[P.key]}if((re==null?void 0:re.type)=="Select"&&(P==null?void 0:P.key)==="originalContent")return(re==null?void 0:re.value)||re[P.key];if((re==null?void 0:re.type)=="Select"&&(P==null?void 0:P.key)==="multiple"){const ne=re[P.key];return pr(ne)?ne:P.default}return(P==null?void 0:P.label)==="类型"&&re[P.key]===""?"Input":(P==null?void 0:P.key)==="isFormColHidden"&&!re[P.key]?!1:re[P.key]},K=async P=>{var pe,We,at,X,V,te;d.value=!0;let re=[];const ne=await((at=(We=(pe=Ie.FormContent)==null?void 0:pe.find(ye=>(ye==null?void 0:ye.key)===((P==null?void 0:P.type)===""?"Input":P==null?void 0:P.type)))==null?void 0:We.value)==null?void 0:at.value)??((V=(X=Ie.FormContent)==null?void 0:X.find(ye=>(ye==null?void 0:ye.key)===((P==null?void 0:P.type)===""?"Input":P==null?void 0:P.type)))==null?void 0:V.value);if(ne==null||ne.forEach(ye=>{R.value++,re.push({label:ye==null?void 0:ye.label,name:ye==null?void 0:ye.label,type:ye.type,prop:ye==null?void 0:ye.prop,value:ve(ye,P),id:R.value,contents:ye==null?void 0:ye.options,width:(P==null?void 0:P.width)??1})}),P!=null&&P.menuSelect&&((te=P==null?void 0:P.menuSelect)==null?void 0:te.length)>0){const ye=await Ie.menuToContentType(P==null?void 0:P.menuSelect);re=re==null?void 0:re.map(ue=>((ue==null?void 0:ue.name)==="组信息选项"&&(ue.contents=ye),ue))}C.value=P==null?void 0:P.id,c.value=await Ie.selectToBase(Ie.formToOptionsContents(re)),w.value=await Ie.selectToBase(Ie.formToOptionsContents(re))},O=P=>{var ne;v.value=!0;let re=[];(ne=Ie.FormButton)==null||ne.forEach(pe=>{R.value++,re.push({label:pe==null?void 0:pe.label,name:pe==null?void 0:pe.label,type:pe.type,value:(pe==null?void 0:pe.label)==="类型"&&P[pe.key]===""?"normal":P[pe.key],id:R.value,contents:pe==null?void 0:pe.options})}),H.value=re,M.value=re,C.value=P==null?void 0:P.id};e.watch(()=>F.value,()=>{var re,ne;let P=x.cloneDeep(s.originalItemContents);(re=x.cloneDeep(s.originalItemContents))!=null&&re.find(pe=>(pe==null?void 0:pe.key)==="enableWrap")?P=(ne=x.cloneDeep(s.originalItemContents))==null?void 0:ne.map(pe=>((pe==null?void 0:pe.key)==="enableWrap"&&(pe.contents=!F.value),pe)):P.push({key:"enableWrap",contents:!F.value}),r("change",P)},{deep:!0});const G=()=>{var ne,pe,We,at,X;H.value=M.value;let P={};if(C.value!==""?P.id=C.value:(R.value++,P.id="id"+R.value),(ne=H.value)==null||ne.forEach(V=>{var ye;const te=(ye=Ie.FormButton)==null?void 0:ye.find(ue=>(ue==null?void 0:ue.label)===(V==null?void 0:V.label));te&&(P[te.key]=V.value)}),(pe=f.value)!=null&&pe.find(V=>V.id===P.id))f.value=(We=f.value)==null?void 0:We.map(V=>(V.id===P.id&&(V=P),V));else{let V=x.cloneDeep(f.value);f.value||(f.value=[]),V.push(P),f.value=V}v.value=!1,C.value="";let re=x.cloneDeep(s.originalItemContents);(at=x.cloneDeep(s.originalItemContents))!=null&&at.find(V=>(V==null?void 0:V.key)==="formButton")?re=(X=x.cloneDeep(s.originalItemContents))==null?void 0:X.map(V=>((V==null?void 0:V.key)==="formButton"&&(V.contents=f.value),V)):re.push({key:"formButton",contents:f.value}),r("change",re)},b=P=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var re,ne;D.value=(re=x.cloneDeep(D.value))==null?void 0:re.filter(pe=>(pe==null?void 0:pe.id)!==(P==null?void 0:P.id)),r("change",(ne=x.cloneDeep(s.originalItemContents))==null?void 0:ne.map(pe=>((pe==null?void 0:pe.key)==="formContent"&&(pe.contents=D.value),pe))),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},E=P=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{var re,ne;f.value=(re=x.cloneDeep(f.value))==null?void 0:re.filter(pe=>(pe==null?void 0:pe.id)!==(P==null?void 0:P.id)),r("change",(ne=x.cloneDeep(s.originalItemContents))==null?void 0:ne.map(pe=>((pe==null?void 0:pe.key)==="formButton"&&(pe.contents=f.value),pe))),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},y=()=>{var re;v.value=!0;let P=[];(re=Ie.FormButton)==null||re.forEach(ne=>{R.value++,P.push({label:ne==null?void 0:ne.label,name:ne==null?void 0:ne.label,type:ne.type,value:(ne==null?void 0:ne.label)==="类型"?"normal":"",id:R.value,contents:ne==null?void 0:ne.options})}),H.value=P,M.value=P},B=()=>{var re,ne,pe;d.value=!0;let P=[];(pe=(ne=(re=Ie.FormContent)==null?void 0:re.find(We=>(We==null?void 0:We.key)==="Input"))==null?void 0:ne.value)==null||pe.forEach(We=>{R.value++,P.push({label:We==null?void 0:We.label,name:We==null?void 0:We.label,type:We.type,value:(We==null?void 0:We.label)==="类型"?"Input":"",id:R.value,contents:We==null?void 0:We.options})}),c.value=P,w.value=P},h=P=>{let re=x.cloneDeep(M.value);re=re==null?void 0:re.map(ne=>(ne.value=P==null?void 0:P[ne.name],ne)),M.value=re},ce=P=>{const re=P.find(We=>(We==null?void 0:We.name)==="类型");if((re==null?void 0:re.value)!="Select")return;const ne=P.find(We=>(We==null?void 0:We.name)==="多选"),pe=P.find(We=>(We==null?void 0:We.name)==="初始值");ne!=null&&ne.value&&Do.isString(pe.value)&&(pe.value=[pe.value]),!(ne!=null&&ne.value)&&!Do.isString(pe.value)&&(pe.value="")},Ne=async P=>{var re,ne,pe,We,at,X,V,te,ye,ue,Ce,Ze;if((P==null?void 0:P.类型)!==((ne=(re=w.value)==null?void 0:re.find(ae=>(ae==null?void 0:ae.label)==="类型"))==null?void 0:ne.value)){let ae=[];const De=await((at=(We=(pe=Ie.FormContent)==null?void 0:pe.find(N=>(N==null?void 0:N.key)===((P==null?void 0:P.类型)===""?"Input":P==null?void 0:P.类型)))==null?void 0:We.value)==null?void 0:at.value)?await((ue=(ye=(te=Ie.FormContent)==null?void 0:te.find(N=>(N==null?void 0:N.key)===((P==null?void 0:P.类型)===""?"Input":P==null?void 0:P.类型)))==null?void 0:ye.value)==null?void 0:ue.value):(V=(X=Ie.FormContent)==null?void 0:X.find(N=>(N==null?void 0:N.key)===((P==null?void 0:P.类型)===""?"Input":P==null?void 0:P.类型)))==null?void 0:V.value;if(De==null||De.forEach(N=>{var Xe,Be;R.value++;const Ge=Ql(N==null?void 0:N.default)?(P==null?void 0:P[N.label])??N.value??"":N==null?void 0:N.default;ae.push({label:N==null?void 0:N.label,name:N==null?void 0:N.label,type:N.type,value:Ge,prop:N==null?void 0:N.prop,id:R.value,contents:N==null?void 0:N.options,width:((Be=(Xe=w.value)==null?void 0:Xe[0])==null?void 0:Be.width)??1})}),P!=null&&P.菜单选项&&((Ce=P==null?void 0:P.菜单选项)==null?void 0:Ce.length)>0){const N=await Ie.menuToContentType(P==null?void 0:P.菜单选项);ae=ae==null?void 0:ae.map(Ge=>((Ge==null?void 0:Ge.name)==="组信息选项"&&(Ge.contents=N),Ge))}ce(ae),w.value=await Ie.selectToBase(x.cloneDeep(ae)),c.value=await Ie.selectToBase(x.cloneDeep(ae))}else{let ae=x.cloneDeep(w.value);if(ae=ae==null?void 0:ae.map(De=>(De.value=P==null?void 0:P[De.name],De)),P!=null&&P.菜单选项&&((Ze=P==null?void 0:P.菜单选项)==null?void 0:Ze.length)>0){const De=await Ie.menuToContentType(P==null?void 0:P.菜单选项);ae=ae==null?void 0:ae.map(N=>((N==null?void 0:N.name)==="组信息选项"&&(N.contents=De),N))}ae=Ie.formToOptionsContents(ae),ce(ae),w.value=await Ie.selectToBase(x.cloneDeep(ae))}},nt=P=>{P||(c.value=w.value)},xe=async P=>{await Ne(P),c.value=w.value},Re=dr(async()=>{var pe,We,at,X,V,te,ye,ue,Ce,Ze,ae,De;c.value=w.value;let P={};P.width=((We=(pe=c.value)==null?void 0:pe[0])==null?void 0:We.width)??1,C.value!==""?P.id=C.value:(R.value++,P.id="id"+R.value);let re=await((V=(X=(at=Ie.FormContent)==null?void 0:at.find(N=>{var Ge,Xe;return(N==null?void 0:N.key)===(((Xe=(Ge=c.value)==null?void 0:Ge.find(Be=>(Be==null?void 0:Be.label)==="类型"))==null?void 0:Xe.value)??"label")}))==null?void 0:X.value)==null?void 0:V.value)??((ye=(te=Ie.FormContent)==null?void 0:te.find(N=>{var Ge,Xe;return(N==null?void 0:N.key)===(((Xe=(Ge=c.value)==null?void 0:Ge.find(Be=>(Be==null?void 0:Be.label)==="类型"))==null?void 0:Xe.value)??"label")}))==null?void 0:ye.value);if((ue=c.value)==null||ue.forEach(N=>{const Ge=re==null?void 0:re.find(Xe=>(Xe==null?void 0:Xe.label)===(N==null?void 0:N.label));Ge&&(P[Ge.key]=N.value)}),P.width=P.width?P.width:1,P.key=P==null?void 0:P.label,P.isFormColHidden=P==null?void 0:P.isFormColHidden,(Ce=D.value)!=null&&Ce.find(N=>N.id===P.id))D.value=(Ze=D.value)==null?void 0:Ze.map(N=>(N.id===P.id&&(N=P),N));else{let N=x.cloneDeep(D.value);N.push(P),D.value=N}D.value=D.value.map(({id:N,...Ge})=>Ge),d.value=!1,C.value="";let ne=x.cloneDeep(s.originalItemContents);(ae=x.cloneDeep(s.originalItemContents))!=null&&ae.find(N=>(N==null?void 0:N.key)==="formContent")?ne=(De=x.cloneDeep(s.originalItemContents))==null?void 0:De.map(N=>((N==null?void 0:N.key)==="formContent"&&(N.contents=D.value),N)):ne.push({key:"formContent",contents:D.value}),r("change",ne)},300),Pe=()=>{d.value=!1,v.value=!1,C.value="",w.value=[],M.value=[]};return e.watch(()=>s.originalItemContents,()=>{var re,ne,pe,We,at,X;if(!s.originalItemContents||s.originalItemContents.length===0)return;const P=x.cloneDeep(s.originalItemContents);D.value=((re=P==null?void 0:P.find(V=>(V==null?void 0:V.key)==="formContent"))==null?void 0:re.contents)??[],f.value=((ne=P==null?void 0:P.find(V=>(V==null?void 0:V.key)==="formButton"))==null?void 0:ne.contents)??[],F.value=(pe=P==null?void 0:P.find(V=>(V==null?void 0:V.key)==="enableWrap"))!=null&&pe.contents?!((We=P==null?void 0:P.find(V=>(V==null?void 0:V.key)==="enableWrap"))!=null&&We.contents):!0,D.value=(at=x.cloneDeep(D.value))==null?void 0:at.map((V,te)=>{var ue;let ye=V;return ye.id=(V==null?void 0:V.id)??te,V!=null&&V.label||(V.label=(V==null?void 0:V.key)??(V==null?void 0:V.label)??""),V!=null&&V.type||(V.type=(V==null?void 0:V.type)??""),V.contents=((ue=V==null?void 0:V.options)==null?void 0:ue.length)===0?(V==null?void 0:V.contents)??"":V==null?void 0:V.options,ye}),D.value=Ie.formToOptionsContents(D.value),f.value=(X=f.value)==null?void 0:X.map((V,te)=>V={label:(V==null?void 0:V.label)??"",type:(V==null?void 0:V.type)??"",background:(V==null?void 0:V.background)??"var(--ssComponent-primary-color)",id:te})},{deep:!0,immediate:!0}),(P,re)=>{const ne=e.resolveComponent("svg-icon"),pe=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",Os,[e.createElementVNode("div",Ms,[e.createElementVNode("div",zs,[re[2]||(re[2]=e.createElementVNode("div",null,e.toDisplayString("表单内容"),-1)),e.createVNode(pe,{class:"icon-content",id:"themeButton",onClick:B},{icon:e.withCtx(()=>[e.createVNode(ne,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[re[1]||(re[1]=e.createElementVNode("div",null,e.toDisplayString("新增"),-1))]),_:1,__:[1]})]),e.createElementVNode("div",Fs,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(D.value,(We,at)=>(e.openBlock(),e.createElementBlock("div",{key:at},[e.createElementVNode("div",Rs,[e.createElementVNode("div",null,e.toDisplayString(We.label),1),e.createElementVNode("div",Ps,[e.createVNode(ne,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:X=>K(We)},null,8,["onClick"]),e.createVNode(ne,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:X=>b(We)},null,8,["onClick"])])])]))),128))]),e.createElementVNode("div",Ls,[re[4]||(re[4]=e.createElementVNode("div",null,e.toDisplayString("表单按钮"),-1)),e.createVNode(pe,{class:"icon-content",id:"themeButton",onClick:y},{icon:e.withCtx(()=>[e.createVNode(ne,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[re[3]||(re[3]=e.createTextVNode(" 新增 "))]),_:1,__:[3]})]),e.createElementVNode("div",$s,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(f.value,(We,at)=>(e.openBlock(),e.createElementBlock("div",{key:at},[e.createElementVNode("div",js,[e.createElementVNode("div",null,e.toDisplayString(We.label),1),e.createElementVNode("div",Us,[e.createVNode(ne,{name:"ChildFix",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:X=>O(We)},null,8,["onClick"]),e.createVNode(ne,{name:"ChildDelete",class:"svg-icon-content",style:{width:"24px",height:"24px"},onClick:X=>E(We)},null,8,["onClick"])])])]))),128))]),re[6]||(re[6]=e.createElementVNode("div",{class:"operate-title"},[e.createElementVNode("div",null,e.toDisplayString("表单布局"))],-1)),e.createElementVNode("div",Ks,[re[5]||(re[5]=e.createElementVNode("div",{class:"operate-center-content"},e.toDisplayString("是否自动撑宽"),-1)),e.createVNode(Bt._sfc_main$1,{modelValue:F.value,"onUpdate:modelValue":re[0]||(re[0]=We=>F.value=We)},null,8,["modelValue"])])]),e.createVNode(Xt.ssDialog,{visible:d.value,onBeforeDestroy:Pe,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",Ws,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:c.value,key:c.value,isEnableWrap:!0,onChange:Ne,onChangeVisible:nt,onBlurChange:xe},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Hs,[e.createVNode(pe,{onClick:Pe,class:"cancel-button button",id:"themeBorderButton"},{default:e.withCtx(()=>re[7]||(re[7]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[7]}),e.createVNode(pe,{class:"ok-button button",onClick:e.unref(Re),id:"themeButton"},{default:e.withCtx(()=>re[8]||(re[8]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[8]},8,["onClick"])])]),_:1},8,["visible"]),e.createVNode(Xt.ssDialog,{visible:v.value,onBeforeDestroy:Pe,width:840},{default:e.withCtx(()=>[e.createElementVNode("div",qs,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:H.value,key:H.value,isEnableWrap:!0,onChange:h},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",{class:"dialog-footer"},[e.createElementVNode("div",{onClick:Pe,class:"cancel-button button"},e.toDisplayString("取消")),e.createElementVNode("div",{class:"ok-button button",onClick:G},e.toDisplayString("确认"))])]),_:1},8,["visible"])])}}},Io=Rt._export_sfc(Gs,[["__scopeId","data-v-20850524"]]),Xs={class:"step-module content"},Ys={class:"module-data"},Js={class:"step-module layout"},Zs={class:"form-content"},Qs=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const s=a,r=l,d=e.ref([{label:"方向:",prop:"direction",type:"RADIO",contents:[{label:"水平",value:"horizontal"},{label:"垂直",value:"vertical"}],value:"horizontal"},{label:"是否居中:",prop:"alignCenter",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0},{label:"应用简洁风格",prop:"simple",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!1}]),c=e.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"标题",prop:"title",type:"input",value:""},{label:"描述",prop:"description",type:"input",value:""}]),w=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),v=e.reactive({visible:!1,width:"40%",title:"步骤条"}),f=e.ref("create"),D=e.ref({}),C=e.ref([]),F=K=>{var O;D.value=K,r("change",(O=M())==null?void 0:O.compData)},R=(K,O)=>{var G,b;switch(K){case"create":(G=c.value)==null||G.forEach(E=>{E.value=""}),f.value="create",v.visible=!0;break;case"update":(b=c.value)==null||b.forEach(E=>{E.value=O[E==null?void 0:E.prop]}),f.value="update",v.visible=!0;break;case"delete":C.value.splice(O,1),f.value="delete";break}},H=K=>{var O,G,b;if((K==null?void 0:K.buttonName)==="确认"){const E=x.cloneDeep(K==null?void 0:K.content);switch(Object.keys(E).forEach(y=>{E[y]===""&&delete E[y]}),f.value){case"create":C.value.push({...E,index:((O=C.value)==null?void 0:O.length)+1});break;case"update":C.value=(G=C.value)==null?void 0:G.map(y=>y.index===(E==null?void 0:E.index)?{...y,title:E==null?void 0:E.title,description:E==null?void 0:E.description}:y);break}r("change",(b=M())==null?void 0:b.compData),v.visible=!1}else v.visible=!1},M=()=>({comp:"Step",compData:[{key:"stepList",contents:C.value},{key:"stepConfig",contents:D.value}]}),ve=()=>{v.visible=!1};return e.watch(()=>s==null?void 0:s.itemContents,K=>{var O,G;K&&(D.value=((O=K==null?void 0:K.find(b=>b.key==="stepConfig"))==null?void 0:O.contents)??{},C.value=((G=K==null?void 0:K.find(b=>b.key==="stepList"))==null?void 0:G.contents)??[])},{immediate:!0}),(K,O)=>{const G=e.resolveComponent("svg-icon"),b=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",Xs,[O[2]||(O[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(b,{class:"module-icon",id:"themeButton",onClick:O[0]||(O[0]=E=>R("create"))},{icon:e.withCtx(()=>[e.createVNode(G,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[O[1]||(O[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",Ys,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.value,(E,y)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:y},[e.createElementVNode("span",null,e.toDisplayString(E==null?void 0:E.title),1),e.createElementVNode("div",null,[e.createVNode(b,{type:"primary",size:"small",onClick:B=>R("update",{...E,index:y+1})},{default:e.withCtx(()=>O[3]||(O[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(b,{type:"danger",size:"small",onClick:B=>R("delete",y)},{default:e.withCtx(()=>O[4]||(O[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",Js,[O[5]||(O[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(Bt.ssForm,{rowContents:d.value,onChange:F},null,8,["rowContents"])])]),e.createVNode(Xt.ssDialog,{visible:v.visible,title:v.title,onBeforeDestroy:ve,width:v.width},{default:e.withCtx(()=>[e.createElementVNode("div",Zs,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:c.value,key:c.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:w.value,onOnButtonClick:H},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),ec=Rt._export_sfc(Qs,[["__scopeId","data-v-7dbd17f2"]]),tc={class:"step-module content"},nc={class:"module-data"},ac={class:"step-module layout"},oc={class:"form-content"},rc=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const s=a,r=l,d=e.ref("create"),c=e.ref({}),w=e.ref([]),v=e.ref([{label:"方向:",prop:"placement",type:"radio",contents:[{label:"底部",value:"bottom"},{label:"顶部",value:"top"}],value:"bottom"},{label:"节点类型:",prop:"type",type:"select",contents:[{label:"primary",value:"primary"},{label:"success",value:"success"},{label:"warning",value:"warning"},{label:"danger",value:"danger"},{label:"info",value:"info"}],value:"primary"},{label:"颜色:",prop:"color",type:"color",value:""},{label:"尺寸:",prop:"size",type:"radio",contents:[{label:"normal",value:"normal"},{label:"large",value:"large"}],value:"normal"},{label:"是否空心",prop:"isHollow",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0},{label:"是否居中",prop:"isCenter",type:"RADIO",contents:[{label:"是",value:!0},{label:"否",value:!1}],value:!0}]),f=e.ref([{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"内容",prop:"content",type:"input",value:""},{label:"时间戳",prop:"timestamp",type:"datetime",value:""}]),D=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),C=e.reactive({visible:!1,width:"40%",title:"时间线"}),F=K=>{var O;c.value=K,r("change",(O=M())==null?void 0:O.compData)},R=(K,O)=>{var G,b;switch(K){case"create":(G=f.value)==null||G.forEach(E=>{E.value=""}),d.value="create",C.visible=!0;break;case"update":(b=f.value)==null||b.forEach(E=>{E.value=O[E==null?void 0:E.prop]}),d.value="update",C.visible=!0;break;case"delete":w.value.splice(O,1),d.value="delete";break}},H=K=>{var O,G,b,E;if((K==null?void 0:K.buttonName)==="确认"){const y=x.cloneDeep(K==null?void 0:K.content);switch(Object.keys(y).forEach(B=>{y[B]===""&&delete y[B]}),d.value){case"create":(G=w.value)==null||G.push({...y,index:((O=w.value)==null?void 0:O.length)+1});break;case"update":w.value=(b=w.value)==null?void 0:b.map(B=>B.index===(y==null?void 0:y.index)?{...B,content:y==null?void 0:y.content,timestamp:y==null?void 0:y.timestamp}:B);break}r("change",(E=M())==null?void 0:E.compData),C.visible=!1}else C.visible=!1},M=()=>({comp:"TimeLine",compData:[{key:"timeLineList",contents:w.value},{key:"timeLineConfig",contents:c.value}]}),ve=()=>{C.visible=!1};return e.watch(()=>s==null?void 0:s.itemContents,K=>{var O,G;K&&(c.value=((O=K==null?void 0:K.find(b=>b.key==="timeLineConfig"))==null?void 0:O.contents)??{},w.value=((G=K==null?void 0:K.find(b=>b.key==="timeLineList"))==null?void 0:G.contents)??[])},{immediate:!0}),(K,O)=>{const G=e.resolveComponent("svg-icon"),b=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",tc,[O[2]||(O[2]=e.createElementVNode("h4",{class:"module-title"},"内容",-1)),e.createVNode(b,{class:"module-icon",id:"themeButton",onClick:O[0]||(O[0]=E=>R("create"))},{icon:e.withCtx(()=>[e.createVNode(G,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[O[1]||(O[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",nc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(E,y)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:y},[e.createElementVNode("span",null,e.toDisplayString(E==null?void 0:E.content),1),e.createElementVNode("div",null,[e.createVNode(b,{type:"primary",size:"small",onClick:B=>R("update",{...E,index:y+1})},{default:e.withCtx(()=>O[3]||(O[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(b,{type:"danger",size:"small",onClick:B=>R("delete",y)},{default:e.withCtx(()=>O[4]||(O[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",ac,[O[5]||(O[5]=e.createElementVNode("div",{class:"module-title"},"布局",-1)),e.createVNode(Bt.ssForm,{rowContents:v.value,onChange:F},null,8,["rowContents"])])]),e.createVNode(Xt.ssDialog,{visible:C.visible,title:C.title,onBeforeDestroy:ve,width:C.width},{default:e.withCtx(()=>[e.createElementVNode("div",oc,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:f.value,key:f.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:D.value,onOnButtonClick:H},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),lc=Rt._export_sfc(rc,[["__scopeId","data-v-39ffc861"]]),ic={};function sc(a,l){return e.openBlock(),e.createElementBlock("div")}const cc=Rt._export_sfc(ic,[["render",sc]]),uc={class:"extra-content"},dc={key:0},pc={key:1},fc={class:"dialog-footer"},hc={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},emits:["change"],setup(a,{emit:l}){const s=a,r=e.ref(0),d=e.ref(),c=e.ref(),w=l,v=e.ref(!1),f=e.ref({}),D=e.ref({}),C=e.ref();e.watch(()=>[s.itemData],()=>{var E;const b=x.cloneDeep(s.itemData);d.value=(E=x.cloneDeep(b))==null?void 0:E.map(y=>{var B;if(y.key==="extra"){let h=[];(B=y.value)==null||B.forEach(ce=>{var Ne;h.push((Ne=Object.values(ce))==null?void 0:Ne[0])}),y.value=h}return y})},{deep:!0,immediate:!0});const F=(b,E,y,B)=>{var ce;let h={};((ce=b==null?void 0:b[0])==null?void 0:ce.contents)==="详情"&&(v.value=!0,h[E]=b,c.value=b==null?void 0:b.filter(Ne=>(Ne==null?void 0:Ne.key)!=="tableContentName"),f.value=h,D.value=y,C.value=B.id)},R=b=>{var Ne,nt,xe,Re;const E=(nt=(Ne=Object.values(x.cloneDeep(f.value)))==null?void 0:Ne[0])==null?void 0:nt.filter(Pe=>(Pe==null?void 0:Pe.key)==="tableContentName"),y=(Re=(xe=Object.values(x.cloneDeep(f.value)))==null?void 0:xe[0])==null?void 0:Re.filter(Pe=>(Pe==null?void 0:Pe.key)!=="tableContentName"),B=y==null?void 0:y.map((Pe,P)=>{var re;return P===b.index&&(Pe==null?void 0:Pe.comp)==="Table"&&(Pe.compData=(re=Pe.compData)==null?void 0:re.map(ne=>{var pe,We;return(ne==null?void 0:ne.key)==="tableContents"&&(ne.contents=(We=(pe=b.content)==null?void 0:pe.map(at=>{let X={};for(let V in at)V!=="id"&&(X[V]=at[V]);return X}))==null?void 0:We.map(at=>Object.values(at))),ne})),Pe});B.unshift(E==null?void 0:E[0]);let h=x.cloneDeep(f.value),ce={};for(let Pe in h)ce[Pe]=B;f.value=ce},H=()=>{v.value=!1,f.value={},D.value={},C.value=void 0,r.value++},M=b=>{var Ne,nt,xe,Re;const E=(nt=(Ne=Object.values(x.cloneDeep(f.value)))==null?void 0:Ne[0])==null?void 0:nt.filter(Pe=>(Pe==null?void 0:Pe.key)==="tableContentName"),y=(Re=(xe=Object.values(x.cloneDeep(f.value)))==null?void 0:xe[0])==null?void 0:Re.filter(Pe=>(Pe==null?void 0:Pe.key)!=="tableContentName"),B=y==null?void 0:y.map((Pe,P)=>(P===b.index&&(Pe.compData=b.contents),Pe));B.unshift(E==null?void 0:E[0]);let h=x.cloneDeep(f.value),ce={};for(let Pe in h)ce[Pe]=B;f.value=ce},ve=()=>{var E,y;let b={};for(let B in D.value)B===((E=Object.keys(f.value))==null?void 0:E[0])?b[B]=(y=Object.values(f.value))==null?void 0:y[0]:b[B]=D.value[B];w("change",{buttonName:"编辑",index:C.value,singleContent:b},"methodData"),v.value=!1,f.value={},D.value={},C.value=void 0},K=()=>{v.value=!1,f.value={},D.value={},C.value=void 0},O=b=>{w("change",b,"methodData")},G=b=>aa(b);return(b,E)=>{const y=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock("div",uc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(B,h)=>(e.openBlock(),e.createElementBlock("div",{key:r.value},[(B==null?void 0:B.key)==="extra"?(e.openBlock(),e.createElementBlock("div",dc)):(e.openBlock(),e.createElementBlock("div",pc,[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(G(B.comp)),{itemData:B==null?void 0:B.compData,childItemData:B==null?void 0:B.itemChildData,key:h,index:(B==null?void 0:B.id)??h,onContentClick:F,onChange:O},null,40,["itemData","childItemData","index"]))]))]))),128)),e.createVNode(Xt.ssDialog,{visible:v.value,onBeforeDestroy:K},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(c.value,(B,h)=>(e.openBlock(),e.createElementBlock("div",{key:h,class:"extra-dialog"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(G(B.comp)),{itemData:B==null?void 0:B.compData,onChange:R,childItemData:B==null?void 0:B.itemChildData,key:h,onContentChange:M,index:(B==null?void 0:B.id)??h,class:"extra-component"},null,40,["itemData","childItemData","index"]))]))),128))]),footer:e.withCtx(()=>[e.createElementVNode("div",fc,[e.createVNode(y,{class:"cancel-button footer-button",onClick:H,id:"themeBorderButton"},{default:e.withCtx(()=>E[0]||(E[0]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[0]}),e.createVNode(y,{class:"confirm-button footer-button",onClick:ve,id:"themeButton"},{default:e.withCtx(()=>E[1]||(E[1]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[1]})])]),_:1},8,["visible"])])}}},vc=Rt._export_sfc(hc,[["__scopeId","data-v-2d9c5ab2"]]),mc={key:0,class:"method-content"},gc={__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number,changedContent:{type:Object,default:()=>{}}},setup(a){const l=e.ref([]),s=Ie.useOriginalState(x.pinia),{originalPath:r}=x.storeToRefs(s),d=a,c=e.ref(!1),w=e.ref(),v=Ie.useTableComp(x.pinia),{multipleTableConst:f}=x.storeToRefs(v),D=x.useModelComp(x.pinia),C=e.ref(!1),F=x.useMenuState(x.pinia),R=x.useLoginState(x.pinia),{itemData:H,isEdit:M,routeToChildPath:ve,tableViewContents:K,lockingPage:O,payloadTypes:G}=x.storeToRefs(D),{activeMenuPath:b,platform:E,childMenu:y}=x.storeToRefs(F),{loginUserInfo:B}=x.storeToRefs(R),h=e.ref(!1),ce=async()=>{var X,V;(X=l.value)!=null&&X.find(te=>(te==null?void 0:te.buttonName)==="保存")&&await ne((V=l.value)==null?void 0:V.find(te=>(te==null?void 0:te.buttonName)==="保存")),await Ie.onSaveBack()};e.watch(()=>H.value,async()=>{M.value==="view"&&!h.value&&await at(x.cloneDeep(d.itemData)),h.value=!1},{deep:!0});const Ne=()=>{c.value=!1,w.value=void 0},nt=X=>X.map(V=>{const te={};for(const ye in V){const ue=V[ye];if(ye.includes(f.value)){const Ce=ye.split(f.value);let Ze=te;Ce.forEach((ae,De)=>{De===Ce.length-1?Ze[ae]=ue:(Ze[ae]||(Ze[ae]={}),Ze=Ze[ae])})}else te[ye]=ue}return te}),xe=async(X,V,te=[])=>{var ue,Ce,Ze,ae,De,N,Ge,Xe,Be,le,Q,se,_e,He,dt;let ye=(ue=x.cloneDeep(V))==null?void 0:ue.filter(m=>(m==null?void 0:m.comp)!=="methodButton");if(X!=null&&X.includes("[")){let m=(N=(De=(ae=(Ze=(Ce=x.cloneDeep(X))==null?void 0:Ce.split("["))==null?void 0:Ze[1])==null?void 0:ae.split("]"))==null?void 0:De[0])==null?void 0:N.split(":"),T="";if(m!=null&&m[0]){let U=(Ge=ye==null?void 0:ye.find(J=>(J==null?void 0:J.name)===(m==null?void 0:m[0])))==null?void 0:Ge.compData;if(!U){let J=(Xe=X==null?void 0:X.split("["))==null?void 0:Xe[0],_=await Ie.getItemData(J,sessionStorage.getItem("systemKey"),"",!1,"","",te);U=(Be=_==null?void 0:_.find(oe=>(oe==null?void 0:oe.name)===(m==null?void 0:m[0])))==null?void 0:Be.compData}U==null||U.forEach(J=>{var _,oe,Ae,I,ee,$;if((J==null?void 0:J.key)==="formContent")(_=J==null?void 0:J.contents)==null||_.forEach(W=>{var Ee;(W==null?void 0:W.key)===(m==null?void 0:m[1])&&(Array.isArray(W==null?void 0:W.value)?T=W==null?void 0:W.value:T=(Ee=W==null?void 0:W.value)==null?void 0:Ee.toString())});else if((J==null?void 0:J.key)==="tableContents"){let W=[],Ee=(oe=U==null?void 0:U.find(q=>(q==null?void 0:q.key)==="header"))==null?void 0:oe.contents,ie=(m==null?void 0:m[1])??"";if(Ee!=null&&Ee.every(q=>Array.isArray(q))){let q=Ie.getColumnChild((ee=Ee==null?void 0:Ee[0])==null?void 0:ee.filter(Z=>(Z==null?void 0:Z.label)!=="操作"));($=J.contents)==null||$.forEach(Z=>{let de={};Z=Z==null?void 0:Z.filter(me=>!(me!=null&&me.id)),q==null||q.forEach((me,we)=>{let be=Z[we];typeof Z[we]=="number"&&(be=Z[we].toString()),(ie===""||ie===me.prop)&&(de[me.prop]=be)}),W.push(de)}),W=nt(W)}else{let q=(Ae=Ee==null?void 0:Ee.map(Z=>Z==null?void 0:Z.label))==null?void 0:Ae.filter(Z=>Z!=="操作");(I=J.contents)==null||I.forEach(Z=>{let de={};Z=Z==null?void 0:Z.filter(me=>!(me!=null&&me.id)),q==null||q.forEach((me,we)=>{let be=Z[we];typeof Z[we]=="number"&&(be=Z[we].toString()),(ie===""||ie===me)&&(de[me]=be)}),W.push(de)})}T=W}})}return T}else if(X!=null&&X.includes("/")){let m={};return(le=x.cloneDeep(ye))==null||le.forEach((T,U)=>{var J,_,oe,Ae,I,ee,$,W,Ee,ie,q,Z,de,me,we,be,j,Oe,ge;if((T==null?void 0:T.comp)==="Table"){let je=Array.isArray((oe=(_=(J=T==null?void 0:T.compData)==null?void 0:J.find(Te=>(Te==null?void 0:Te.key)==="header"))==null?void 0:_.contents)==null?void 0:oe[0])?($=(ee=(I=(Ae=T==null?void 0:T.compData)==null?void 0:Ae.find(Te=>(Te==null?void 0:Te.key)==="header"))==null?void 0:I.contents)==null?void 0:ee[0])==null?void 0:$.some(Te=>Te==null?void 0:Te.children):[],ot=(ie=(Ee=(W=T==null?void 0:T.compData)==null?void 0:W.find(Te=>(Te==null?void 0:Te.key)==="tableContents"))==null?void 0:Ee.contents)==null?void 0:ie.map(Te=>(Te!=null&&Te.find(mt=>mt==null?void 0:mt.id)&&(Te=Te.slice(1)),Te)),Le=(we=(me=(de=(Z=(q=T==null?void 0:T.compData)==null?void 0:q.find(Te=>(Te==null?void 0:Te.key)==="header"))==null?void 0:Z.contents)==null?void 0:de[0])==null?void 0:me[0])==null?void 0:we.label,tt=(j=(be=T==null?void 0:T.compData)==null?void 0:be.find(Te=>(Te==null?void 0:Te.key)==="header"))==null?void 0:j.contents;if(je)(je==null?void 0:je.length)===0?m[T.name]=m!=null&&m[T.name]?m[T.name]:Ie.tableToForm(ot,tt):m[Le]=Ie.tableToForm(ot,tt);else{const Te=[];tt=tt.slice(1,tt.length-1),tt==null||tt.forEach((mt,Qe)=>{ot==null||ot.forEach(Ve=>{Te.push({key:mt.label+Ve[0],value:Ve[Qe+1]})})}),m["form"+U]=Te}}else{const je=(ge=(Oe=T.compData)==null?void 0:Oe.find(Le=>(Le==null?void 0:Le.key)==="formContent"))==null?void 0:ge.contents;m!=null&&m.form||(m.form=[]);const ot=[];je==null||je.forEach(Le=>{Le.key!==""&&(Le={key:(Le==null?void 0:Le.key)??(Le==null?void 0:Le.label),value:Le==null?void 0:Le.value},ot.push(Le))}),m.form=[...ot,...x.cloneDeep(m==null?void 0:m.form)]}}),m}else{if(X==="createInsofDataApi"){let m=(Q=x.cloneDeep(V))==null?void 0:Q[0];return m={comp:(se=x.cloneDeep(m))==null?void 0:se.comp,compData:(_e=x.cloneDeep(m))==null?void 0:_e.compData,name:(He=x.cloneDeep(m))==null?void 0:He.name,isShow:(dt=x.cloneDeep(m))==null?void 0:dt.isShow},{key:{type:"structure",systemKey:sessionStorage.getItem("systemKey"),parentTable:"",pageKey:b.value},value:{pageData:m}}}return X}},Re=async(X,V,te)=>{var Ce,Ze,ae;let ye=await Ie.getItemData(V,sessionStorage.getItem("systemKey"),""),ue=ye==null?void 0:ye.find(De=>(De==null?void 0:De.name)===(te==null?void 0:te[0]));if(ue){if((ue==null?void 0:ue.comp)==="Table"){let De={};for(let se in x.cloneDeep(X))x.cloneDeep(X)[se]!=="loginUser"?De[se]=x.cloneDeep(X)[se]:De[se]=((Ce=B.value)==null?void 0:Ce.account)||((Ze=B.value)==null?void 0:Ze.账号);let N=[],Ge=De;Array.isArray(X)||(Ge=[De]),Ge==null||Ge.forEach(se=>{N.push({[se[te[1]]]:se})});let Xe=[],Be=N==null?void 0:N.map(se=>{var _e;return(_e=Object.keys(se))==null?void 0:_e[0]});ye==null||ye.forEach(se=>{var _e;(se==null?void 0:se.name)===(te==null?void 0:te[0])&&((_e=se==null?void 0:se.compData)==null||_e.forEach(He=>{var dt;(He==null?void 0:He.key)==="tableContents"&&((dt=He==null?void 0:He.contents)==null||dt.forEach(m=>{m!=null&&m.some(T=>Be.includes(T))&&Xe.push({[m.find(T=>T.id).id]:m.find(T=>Be.includes(T))})}))}))});let le=Xe==null?void 0:Xe.map(se=>{var _e;return(_e=Object.keys(se))==null?void 0:_e[0]}),Q=[];if(le==null||le.forEach(se=>{var dt;let _e=(dt=Xe==null?void 0:Xe.find(m=>{var T;return((T=Object.keys(m))==null?void 0:T[0].toString())===se.toString()}))==null?void 0:dt[se],He=N==null?void 0:N.find(m=>{var T;return((T=Object.keys(m))==null?void 0:T[0])===_e});Q.push({id:parseInt(se),value:{tableData:He[_e]}})}),(Q==null?void 0:Q.length)>0)return Q}else if((ue==null?void 0:ue.comp)==="Form"){let De=x.cloneDeep(ue);De.compData=(ae=De.compData)==null?void 0:ae.map(Xe=>{var Be;return(Xe==null?void 0:Xe.key)==="formContent"&&(Xe.contents=(Be=Xe.contents)==null?void 0:Be.map(le=>((le==null?void 0:le.key)===(te==null?void 0:te[1])&&(le.value=(X==null?void 0:X[le==null?void 0:le.prop])||X),le))),Xe});let N={};for(let Xe in De)Xe!=="id"&&(N[Xe]=De[Xe]);let Ge=[];if(Ge.push({id:ue==null?void 0:ue.id,keyType:te==null?void 0:te[1],value:{pageData:N}}),(Ge==null?void 0:Ge.length)>0)return Ge}}},Pe=async(X,V,te)=>{var Ce,Ze,ae,De,N,Ge,Xe,Be,le,Q;let ye=await Ie.getItemData(V,sessionStorage.getItem("systemKey"),""),ue=ye==null?void 0:ye.find(se=>(se==null?void 0:se.name)===(te==null?void 0:te[0]));if(ue){if((ue==null?void 0:ue.comp)==="Table"){let se={};for(let _e in x.cloneDeep(X))x.cloneDeep(X)[_e]!=="loginUser"?se[_e]=x.cloneDeep(X)[_e]:se[_e]=((Ce=B.value)==null?void 0:Ce.account)||((Ze=B.value)==null?void 0:Ze.账号);await lt.createInsofDataApi({key:{type:"data",pageKey:V,tableId:ue==null?void 0:ue.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:se}})}else if((ue==null?void 0:ue.comp)==="Form"){let se=x.cloneDeep(ue),_e=Object.keys(X),He="";(De=(ae=x.cloneDeep(se))==null?void 0:ae.compData)==null||De.forEach(_=>{var oe,Ae;(_==null?void 0:_.key)==="formContent"&&((Ae=(oe=x.cloneDeep(_))==null?void 0:oe.contents)==null||Ae.forEach(I=>{var ee;_e.includes(I==null?void 0:I.key)&&(I==null?void 0:I.value)===((ee=B.value)==null?void 0:ee.姓名)&&(He=I==null?void 0:I.key)}))});let dt=[];(N=Object.values(X[He]))==null||N.forEach(_=>{_!=null&&_.includes("(")&&dt.push(_)}),dt=[...new Set(dt)];const m=dt==null?void 0:dt.map(async _=>{var $,W,Ee,ie,q,Z,de,me,we,be,j,Oe;let oe="";(Z=(q=(ie=(Ee=(W=($=x.cloneDeep(_))==null?void 0:$.split("("))==null?void 0:W[1])==null?void 0:Ee.split(")"))==null?void 0:ie[0])==null?void 0:q.split(":"))==null||Z.forEach(ge=>{oe=oe===""?oe+ge.replaceAll("'",""):oe+"/"+ge.replaceAll("'","")});let Ae=[];(Oe=(j=(be=(we=(me=(de=x.cloneDeep(_))==null?void 0:de.split("<"))==null?void 0:me[1])==null?void 0:we.split(">"))==null?void 0:be[0])==null?void 0:j.split(":"))==null||Oe.forEach(ge=>{Ae.push(ge.replaceAll("'",""))});const I=await Ie.getItemData(oe,sessionStorage.getItem("systemKey"),"");let ee="";return I==null||I.forEach(ge=>{var je;ge.name===(Ae==null?void 0:Ae[0])&&((je=ge==null?void 0:ge.compData)==null||je.forEach(ot=>{var Le;(ot==null?void 0:ot.key)==="formContent"&&((Le=ot.contents)==null||Le.forEach(tt=>{(tt==null?void 0:tt.key)===(Ae==null?void 0:Ae[1])&&(ee=tt==null?void 0:tt.value)}))}))}),{[_]:ee}}),T=await Promise.all(m);se.compData=(Xe=(Ge=x.cloneDeep(se))==null?void 0:Ge.compData)==null?void 0:Xe.map(_=>{var oe,Ae;return(_==null?void 0:_.key)==="formContent"&&(_.contents=(Ae=(oe=x.cloneDeep(_))==null?void 0:oe.contents)==null?void 0:Ae.map(I=>{var ee,$,W,Ee;return(ee=X[He])!=null&&ee[I==null?void 0:I.key]&&(X[He][I==null?void 0:I.key].includes("(")?I.value=($=T==null?void 0:T.find(ie=>{var q;return((q=Object.keys(ie))==null?void 0:q[0])===X[He][I==null?void 0:I.key]}))==null?void 0:$[X[He][I==null?void 0:I.key]]:I.value=(Ee=(W=x.cloneDeep(X))==null?void 0:W[He])==null?void 0:Ee[I==null?void 0:I.key]),I})),_});const U=await lt.getInsofDataApi({key:{type:"structure",pageKey:V,systemKey:sessionStorage.getItem("systemKey")}});let J="";((Be=U==null?void 0:U.data)==null?void 0:Be.type)==="success"&&((Q=(le=U==null?void 0:U.data)==null?void 0:le.result)==null||Q.forEach(_=>{var oe,Ae;((Ae=(oe=_==null?void 0:_.value)==null?void 0:oe.pageData)==null?void 0:Ae.name)===(te==null?void 0:te[0])&&(J=_.id)}),await lt.updateInsofDataApi({id:J,value:{pageData:se}}))}}},P=(X,V="",te={})=>{for(const[ye,ue]of Object.entries(X)){const Ce=V?`${V}.${ye}`:ye;ue!==null&&typeof ue=="object"&&!Array.isArray(ue)&&Object.prototype.toString.call(ue)!=="[object Date]"?P(ue,Ce,te):te[Ce]=ue}return te},re=async(X,V,te,ye)=>{var Ze,ae,De,N,Ge,Xe,Be,le,Q,se,_e,He,dt,m,T,U,J,_,oe,Ae,I,ee,$,W,Ee;let ue=await Ie.getItemData(V,sessionStorage.getItem("systemKey"),""),Ce=ue==null?void 0:ue.find(ie=>(ie==null?void 0:ie.name)===(te==null?void 0:te[0]));if(Ce){if(!(te!=null&&te[1])&&(Ce==null?void 0:Ce.comp)==="Table"){let ie={},q=[],Z=(ae=(Ze=Ce==null?void 0:Ce.compData)==null?void 0:Ze.find(we=>(we==null?void 0:we.key)==="header"))==null?void 0:ae.contents;Z!=null&&Z.every(we=>Array.isArray(we))?q=(N=Ie.getColumnChild((De=Z==null?void 0:Z[0])==null?void 0:De.filter(we=>(we==null?void 0:we.label)!=="操作")))==null?void 0:N.map(we=>we==null?void 0:we.prop):q=Z==null?void 0:Z.map(we=>we==null?void 0:we.label);for(let we in x.cloneDeep(X))if(x.cloneDeep(X)[we]!=="loginUser"){let be=P(x.cloneDeep(X)[we]),j={};for(let Oe in be)if(q!=null&&q.find(ge=>ge===Oe))j[Oe]=be[Oe];else if(q!=null&&q.find(ge=>(ge==null?void 0:ge.toUpperCase())===(Oe==null?void 0:Oe.toUpperCase()))){let ge=q==null?void 0:q.find(je=>(je==null?void 0:je.toUpperCase())===(Oe==null?void 0:Oe.toUpperCase()));j[ge]=be[Oe]}ie[we]=j}else ie[we]=((Ge=B.value)==null?void 0:Ge.account)||((Xe=B.value)==null?void 0:Xe.账号);let de=await lt.getInsofDataApi({keyLikes:{tableId:Ce==null?void 0:Ce.id}});if(((le=(Be=de==null?void 0:de.data)==null?void 0:Be.result)==null?void 0:le.length)>0){let we=(se=(Q=de==null?void 0:de.data)==null?void 0:Q.result)==null?void 0:se.map(be=>be==null?void 0:be.id);(we==null?void 0:we.length)>0&&await lt.batchDeleteInsofDataApi({ids:we})}let me=[];if((_e=Ce==null?void 0:Ce.compData)!=null&&_e.find(we=>(we==null?void 0:we.key)==="pageColumn")&&((m=(dt=(He=Ce==null?void 0:Ce.compData)==null?void 0:He.find(we=>(we==null?void 0:we.key)==="pageColumn"))==null?void 0:dt.contents)!=null&&m.includes("["))){const we=await lt.getInsofDataApi({id:Ce==null?void 0:Ce.tableId});let be=((_=(J=(U=(T=we==null?void 0:we.data)==null?void 0:T.result)==null?void 0:U[0])==null?void 0:J.key)==null?void 0:_.pageKey)??"";(oe=Object.values(ie))==null||oe.forEach(j=>{me.push({key:{type:"data",pageKey:be,tableId:Ce==null?void 0:Ce.tableId,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:j}})})}else(Ae=Object.values(ie))==null||Ae.forEach(we=>{me.push({key:{type:"data",pageKey:V,tableId:Ce==null?void 0:Ce.id,systemKey:sessionStorage.getItem("systemKey")},value:{tableData:we}})});(me==null?void 0:me.length)>0&&await lt.batchAddInsofDataApi({dataList:me})}else if(!(te!=null&&te[1])&&(Ce==null?void 0:Ce.comp)==="Form"){let ie=x.cloneDeep(Ce);ie.compData=(ee=(I=x.cloneDeep(ie))==null?void 0:I.compData)==null?void 0:ee.map(de=>{var me,we;return(de==null?void 0:de.key)==="formContent"&&(de.contents=(we=(me=x.cloneDeep(de))==null?void 0:me.contents)==null?void 0:we.map(be=>{var j,Oe;return(j=x.cloneDeep(X))!=null&&j[be==null?void 0:be.key]&&(be.value=(Oe=x.cloneDeep(X))==null?void 0:Oe[be==null?void 0:be.key]),be})),de});const q=await lt.getInsofDataApi({key:{type:"structure",pageKey:V,systemKey:sessionStorage.getItem("systemKey")}});let Z="";(($=q==null?void 0:q.data)==null?void 0:$.type)==="success"&&((Ee=(W=q==null?void 0:q.data)==null?void 0:W.result)==null||Ee.forEach(de=>{var me,we;((we=(me=de==null?void 0:de.value)==null?void 0:me.pageData)==null?void 0:we.name)===(te==null?void 0:te[0])&&(Z=de.id)}),await lt.updateInsofDataApi({id:Z,value:{pageData:ie}}))}}},ne=async X=>{var V,te,ye,ue,Ce,Ze,ae,De,N,Ge,Xe,Be,le,Q,se,_e;F.setImportLoading(!0);try{if(X.api){let He=new WeakMap;(te=(V=(await lt.getPageInsofDataApi({systemKey:sessionStorage.getItem("systemKey"),type:G.value})).data.result)==null?void 0:V.filter($=>{var W,Ee;return((W=$==null?void 0:$.key)==null?void 0:W.pageKey)!=="menu"&&((Ee=$==null?void 0:$.key)==null?void 0:Ee.pageKey)!=="secret"}))==null||te.forEach($=>{He[$.key.pageKey]?He[$.key.pageKey]=[...He[$.key.pageKey],$]:He[$.key.pageKey]=[$]});let m=await Ie.getItemData((y==null?void 0:y.value)===""?b.value:y==null?void 0:y.value,sessionStorage.getItem("systemKey"),"",!1,"","",He),T="";if(m=m==null?void 0:m.map($=>{var W,Ee,ie,q,Z,de,me,we,be,j,Oe,ge;if(($==null?void 0:$.comp)==="Form")$.compData=(W=$.compData)==null?void 0:W.map(je=>{var ot;return(je==null?void 0:je.key)==="formContent"&&(je.contents=(ot=je.contents)==null?void 0:ot.map(Le=>{var tt;if((Le==null?void 0:Le.value)===""&&(Le==null?void 0:Le.type)==="Select"){let Te=Ie.judgeContents((tt=x.cloneDeep(Le))==null?void 0:tt.optionUrl,He);Le.value=Le.value||Te}return Le})),je});else if(($==null?void 0:$.comp)==="Table"&&(Ee=$.compData)!=null&&Ee.find(je=>(je==null?void 0:je.key)==="pageColumn")){let je=(q=(ie=$.compData)==null?void 0:ie.find(Te=>(Te==null?void 0:Te.key)==="pageColumn"))==null?void 0:q.contents,ot=((de=(Z=$.compData)==null?void 0:Z.find(Te=>(Te==null?void 0:Te.key)==="pageGroup"))==null?void 0:de.contents)??"",Le=(be=(we=(me=je==null?void 0:je.split("["))==null?void 0:me[1])==null?void 0:we.split("]"))==null?void 0:be[0];T=((j=je==null?void 0:je.split("["))==null?void 0:j[0])+((ge=(Oe=K.value)==null?void 0:Oe.find(Te=>(Te==null?void 0:Te.key)===Le))==null?void 0:ge.value)}return $}),!(T===""||T==="")){const $=await Ie.getItemData(T,sessionStorage.getItem("systemKey"),"",!1,"","",He);m=m==null?void 0:m.map(W=>{var Ee,ie,q,Z,de,me,we,be,j,Oe,ge,je,ot;if((W==null?void 0:W.comp)==="Table"&&(Ee=W.compData)!=null&&Ee.find(Le=>(Le==null?void 0:Le.key)==="pageColumn")){let Le=(q=(ie=W.compData)==null?void 0:ie.find(Ve=>(Ve==null?void 0:Ve.key)==="pageColumn"))==null?void 0:q.contents,tt=((de=(Z=W.compData)==null?void 0:Z.find(Ve=>(Ve==null?void 0:Ve.key)==="pageGroup"))==null?void 0:de.contents)??"",Te=(be=(we=(me=Le==null?void 0:Le.split("["))==null?void 0:me[1])==null?void 0:we.split("]"))==null?void 0:be[0],mt=((j=Le==null?void 0:Le.split("["))==null?void 0:j[0])+((ge=(Oe=K.value)==null?void 0:Oe.find(Ve=>(Ve==null?void 0:Ve.key)===Te))==null?void 0:ge.value),Qe=(je=$==null?void 0:$.find(Ve=>(Ve==null?void 0:Ve.name)===(tt===""?d==null?void 0:d.compName:tt)))==null?void 0:je.compData;W.compData=(ot=W.compData)==null?void 0:ot.map(Ve=>{var it;return(Ve==null?void 0:Ve.key)==="tableContents"&&(Ve.contents=(it=Qe==null?void 0:Qe.find(gt=>(gt==null?void 0:gt.key)==="tableContents"))==null?void 0:it.contents),Ve})}return W})}let U={};if(((ue=(ye=X==null?void 0:X.extraValues)==null?void 0:ye.input)==null?void 0:ue.length)>0){const $=(Ze=(Ce=X==null?void 0:X.extraValues)==null?void 0:Ce.input)==null?void 0:Ze.map(async W=>{var Ee;pe!=null&&pe.find(ie=>ie===W)?U=await xe(W,m):U[Object.keys(W)[0]]=await xe((Ee=Object.values(W))==null?void 0:Ee[0],m,He)});await Promise.all($)}else U=await xe("/",m);let J=!1;(De=(ae=X==null?void 0:X.extraValues)==null?void 0:ae.output)==null||De.forEach($=>{var W,Ee;(Ee=(W=Object.values($))==null?void 0:W[0])!=null&&Ee.includes(".doc")&&(J=!0)});let _;if(J){const $=Bt.ElLoading.service({lock:!0,text:"Loading",background:"rgba(0, 0, 0, 0.7)"});_=await lt.axios.post(X.api,U,{responseType:"blob",headers:{"Content-Type":"application/json"}}).finally(()=>{$.close()})}else _=await lt.axios.post(X.api,U,{headers:{"Content-Type":"application/json"}});let oe=(Be=(Xe=(Ge=(N=x.cloneDeep(X))==null?void 0:N.extraValues)==null?void 0:Ge.output)==null?void 0:Xe.map($=>{var W,Ee,ie,q,Z,de,me,we,be,j,Oe,ge,je,ot,Le,tt;if(!((Ee=(W=Object.values($))==null?void 0:W[0])!=null&&Ee.includes(".doc"))){let Te=(j=(be=(we=(q=x.cloneDeep((ie=Object.values($))==null?void 0:ie[0]))==null?void 0:q.split("["))==null?void 0:we[((me=(de=x.cloneDeep((Z=Object.values($))==null?void 0:Z[0]))==null?void 0:de.split("["))==null?void 0:me.length)-1])==null?void 0:be.split("]"))==null?void 0:j[0],mt=Te==null?void 0:Te.split(":"),Qe=(je=x.cloneDeep((Oe=Object.values($))==null?void 0:Oe[0]))==null?void 0:je.substring(0,x.cloneDeep((ge=Object.values($))==null?void 0:ge[0]).lastIndexOf("["));if(Qe=(Le=x.cloneDeep(Qe))==null?void 0:Le.slice(0,((ot=x.cloneDeep(Qe))==null?void 0:ot.length)-1),Qe!=null&&Qe.includes("[")){let Ve="";if((tt=Ie.contentTransArrayToAll(Qe,"/"))==null||tt.forEach(it=>{var gt,Ye,$e,It,Se,qe,ze;if(!(it!=null&&it.includes("[")))Ve=Ve===""?Ve+it.replaceAll("/",""):Ve+"/"+it.replaceAll("/","");else{let Je=x.cloneDeep(it).slice(1,((gt=x.cloneDeep(it))==null?void 0:gt.length)-1),S=(qe=(Se=(It=($e=(Ye=x.cloneDeep(Je))==null?void 0:Ye.split("["))==null?void 0:$e[1])==null?void 0:It.split("]"))==null?void 0:Se[0])==null?void 0:qe.split(":"),fe="",Ue=(ze=m==null?void 0:m.find(he=>(he==null?void 0:he.name)===(S==null?void 0:S[0])))==null?void 0:ze.compData;Ue==null||Ue.forEach(he=>{var ut;(he==null?void 0:he.key)==="formContent"&&((ut=he==null?void 0:he.contents)==null||ut.forEach(st=>{(st==null?void 0:st.key)===(S==null?void 0:S[1])&&(fe=st==null?void 0:st.value)}))}),Ve=Ve===""?Ve+fe.replaceAll("/",""):Ve+"/"+fe.replaceAll("/","")}}),Qe=Ve,Qe[(Qe==null?void 0:Qe.length)-1]!=="/")return Qe}}}))==null?void 0:Be.filter($=>$);oe=[...new Set(x.cloneDeep(oe))];let Ae=oe==null?void 0:oe.map(async $=>{let W=await Ie.getItemData($,sessionStorage.getItem("systemKey"),"",!1,"","",He);if((W==null?void 0:W.length)===0)return await Ie.getParentContents($)});await Promise.all(Ae);let I=[],ee=(se=(Q=(le=x.cloneDeep(X))==null?void 0:le.extraValues)==null?void 0:Q.output)==null?void 0:se.map(async $=>{var we,be,j,Oe,ge,je,ot,Le,tt,Te,mt,Qe,Ve,it,gt,Ye,$e,It,Se,qe,ze,Je,S,fe,Ue,he,ut,st,xt,pt,ct,ft,wt,Tt,jt,vt,Mt,Lt,Ut,Wt,Jt,Pt,En,zn,gn,Fn,yn,Rn,Pn,Ln,$n,jn,Sn,hn,un,bn,vn,nn,pn,Un,Tn,Bn,kn,Kn,Wn,In,Hn,qn,_t,Yt;if((be=(we=Object.values($))==null?void 0:we[0])!=null&&be.includes(".doc")){var W=new Blob([_.data],{type:"application/octet-stream;charset=UTF-8"}),Ee=_.headers["content-disposition"],ie=new RegExp("filename=([^;]+\\.[^\\.;]+);*"),q=ie.exec(Ee),Z=q==null?void 0:q[1],de=document.createElement("a"),me=window.URL.createObjectURL(W);w.value=[{name:Z,blobUrl:me}],c.value=!0}else{let yt=(Te=(tt=(Le=(Oe=x.cloneDeep((j=Object.values($))==null?void 0:j[0]))==null?void 0:Oe.split("["))==null?void 0:Le[((ot=(je=x.cloneDeep((ge=Object.values($))==null?void 0:ge[0]))==null?void 0:je.split("["))==null?void 0:ot.length)-1])==null?void 0:tt.split("]"))==null?void 0:Te[0],Ot=yt==null?void 0:yt.split(":"),bt=(Ve=x.cloneDeep((mt=Object.values($))==null?void 0:mt[0]))==null?void 0:Ve.substring(0,x.cloneDeep((Qe=Object.values($))==null?void 0:Qe[0]).lastIndexOf("["));if(bt!=null&&bt.includes("[")?bt=(gt=x.cloneDeep(bt))==null?void 0:gt.slice(0,((it=x.cloneDeep(bt))==null?void 0:it.length)-1):bt===""&&(bt=b.value),bt=bt.replaceAll("<","[").replaceAll(">","]"),bt!=null&&bt.includes("[")){let Dt="";(Ye=Ie.contentTransArrayToAll(bt,"/"))==null||Ye.forEach((Ct,zt)=>{var Vt,Ft,Ht,an,Nn,Gn,An,Xn,Ea,oa,ha;if(!(Ct!=null&&Ct.includes("[")))Dt=Dt===""?Dt+Ct.replaceAll("/",""):Dt+"/"+Ct.replaceAll("/","");else{let ra="",dn="";(Vt=x.cloneDeep(Ct))!=null&&Vt.includes("]")?(ra=x.cloneDeep(Ct).slice(1,((Ft=x.cloneDeep(Ct))==null?void 0:Ft.length)-1),dn=(An=(Gn=(Nn=(an=(Ht=x.cloneDeep(ra))==null?void 0:Ht.split("["))==null?void 0:an[1])==null?void 0:Nn.split("]"))==null?void 0:Gn[0])==null?void 0:An.split(":")):(ra=x.cloneDeep(Ct).slice(1,(Xn=x.cloneDeep(Ct))==null?void 0:Xn.length),dn=(Ea=x.cloneDeep(ra))==null?void 0:Ea.split("/"));let Yn="",la=(oa=m==null?void 0:m.find(on=>(on==null?void 0:on.name)===(dn==null?void 0:dn[0])))==null?void 0:oa.compData;la==null||la.forEach(on=>{var Sa;(on==null?void 0:on.key)==="formContent"&&((Sa=on==null?void 0:on.contents)==null||Sa.forEach(Vn=>{(Vn==null?void 0:Vn.key)===(dn==null?void 0:dn[1])&&(Yn=Vn==null?void 0:Vn.value)}))}),((ha=Ie.contentTransArrayToAll(bt,"/"))==null?void 0:ha.length)-1!==zt?Dt=Dt===""?Dt+Yn.replaceAll("/",""):Dt+"/"+Yn.replaceAll("/",""):Dt=Dt+r.value+Yn.replaceAll("/","")}}),($e=b.value)!=null&&$e.includes(Dt)?bt=b.value:bt=Dt}let Kt=x.cloneDeep((It=Object.keys($))==null?void 0:It[0]);if(((Se=_==null?void 0:_.data)==null?void 0:Se.statusCode)===200||((qe=_==null?void 0:_.data)==null?void 0:qe.code)===200){if(((Je=(ze=_==null?void 0:_.data)==null?void 0:ze.data)!=null&&Je[Kt]||(fe=(S=_==null?void 0:_.data)==null?void 0:S.result)!=null&&fe[Kt])&&(Ot==null?void 0:Ot.length)===1)return await re(((he=(Ue=_==null?void 0:_.data)==null?void 0:Ue.data)==null?void 0:he[Kt])||((st=(ut=_==null?void 0:_.data)==null?void 0:ut.result)==null?void 0:st[Kt]),x.cloneDeep(bt),Ot,T);if((pt=(xt=_==null?void 0:_.data)==null?void 0:xt.data)!=null&&pt[Kt]||(ft=(ct=_==null?void 0:_.data)==null?void 0:ct.result)!=null&&ft[Kt]){let Dt=await Re(((Tt=(wt=_==null?void 0:_.data)==null?void 0:wt.data)==null?void 0:Tt[Kt])||((vt=(jt=_==null?void 0:_.data)==null?void 0:jt.result)==null?void 0:vt[Kt]),x.cloneDeep(bt),Ot);return Dt&&(I=[...I,...Dt]),Dt}else{if(!((Mt=_==null?void 0:_.data)!=null&&Mt.data)){let Dt=await Ie.getItemData(b.value,sessionStorage.getItem("systemKey"),"",!1,"","",He);Dt=Dt==null?void 0:Dt.map(zt=>{var Vt;return(zt==null?void 0:zt.name)===(Ot==null?void 0:Ot[0])&&(zt.compData=(Vt=zt.compData)==null?void 0:Vt.map(Ft=>{var Ht;return(Ft==null?void 0:Ft.key)==="formContent"&&(Ft.contents=(Ht=Ft.contents)==null?void 0:Ht.map(an=>{var Nn,Gn;return(an==null?void 0:an.key)===(Ot==null?void 0:Ot[1])&&(an.value=(Gn=(Nn=_==null?void 0:_.data)==null?void 0:Nn.result)==null?void 0:Gn[Kt==null?void 0:Kt.replaceAll(":","")]),an})),Ft})),zt});let Ct=[];(Lt=Dt==null?void 0:Dt.filter(zt=>(zt==null?void 0:zt.comp)==="Form"))==null||Lt.forEach(async zt=>{let Vt={};for(let Ft in zt)Ft!=="id"&&(Vt[Ft]=zt[Ft]);Ct.push({id:zt==null?void 0:zt.id,value:{pageData:Vt}})}),(Ct==null?void 0:Ct.length)>0&&await lt.batchUpdateInsofDataApi({dataList:Ct});return}if((Ot==null?void 0:Ot.length)===1){const Dt=(Jt=(Wt=(Ut=_==null?void 0:_.data)==null?void 0:Ut.data)==null?void 0:Wt.path)==null?void 0:Jt.path;let Ct="";(Fn=(gn=(zn=(En=(Pt=Dt==null?void 0:Dt.split("("))==null?void 0:Pt[1])==null?void 0:En.split(")"))==null?void 0:zn[0])==null?void 0:gn.split(":"))==null||Fn.forEach(Ft=>{var Ht,an;Ct=Ct===""?Ct+((Ht=Ft==null?void 0:Ft.replaceAll("'",""))==null?void 0:Ht.trim()):Ct+"/"+((an=Ft==null?void 0:Ft.replaceAll("'",""))==null?void 0:an.trim())});let zt=[($n=(Ln=(Pn=(Rn=(yn=Dt==null?void 0:Dt.split("<"))==null?void 0:yn[1])==null?void 0:Rn.split(">"))==null?void 0:Pn[0])==null?void 0:Ln.replaceAll("'",""))==null?void 0:$n.trim()],Vt;return(hn=(Sn=(jn=_==null?void 0:_.data)==null?void 0:jn.data)==null?void 0:Sn.data)!=null&&hn[Ot==null?void 0:Ot[0]]?Vt=await re((vn=(bn=(un=_==null?void 0:_.data)==null?void 0:un.data)==null?void 0:bn.data)==null?void 0:vn[Ot==null?void 0:Ot[0]],Ct,Ot,T):Vt=await Pe((pn=(nn=_==null?void 0:_.data)==null?void 0:nn.data)==null?void 0:pn.data,Ct,zt,He),Vt}else{const Dt=(Bn=(Tn=(Un=_==null?void 0:_.data)==null?void 0:Un.data)==null?void 0:Tn.path)==null?void 0:Bn.path;let Ct="";return(Hn=(In=(Wn=(Kn=(kn=Dt==null?void 0:Dt.split("("))==null?void 0:kn[1])==null?void 0:Kn.split(")"))==null?void 0:Wn[0])==null?void 0:In.split(":"))==null||Hn.forEach(Vt=>{var Ft,Ht;Ct=Ct===""?Ct+((Ft=Vt==null?void 0:Vt.replaceAll("'",""))==null?void 0:Ft.trim()):Ct+"/"+((Ht=Vt==null?void 0:Vt.replaceAll("'",""))==null?void 0:Ht.trim())}),await Re((Yt=(_t=(qn=_==null?void 0:_.data)==null?void 0:qn.data)==null?void 0:_t.data)==null?void 0:Yt[Ot==null?void 0:Ot[0]],Ct,Ot)}}}}});if(await Promise.all(ee),(I==null?void 0:I.length)>0){let $=[];I==null||I.forEach(ie=>{$!=null&&$.find(q=>{var Z,de,me,we;return((de=(Z=q==null?void 0:q.value)==null?void 0:Z.pageData)==null?void 0:de.name)===((we=(me=ie==null?void 0:ie.value)==null?void 0:me.pageData)==null?void 0:we.name)})||$.push(ie)});let W=[];$==null||$.forEach(ie=>{var de,me,we,be;let q=x.cloneDeep(ie);q.value.pageData.compData=(de=q.value.pageData.compData)==null?void 0:de.map(j=>{var Oe;return(j==null?void 0:j.key)==="formContent"&&(j.contents=(Oe=j.contents)==null?void 0:Oe.map(ge=>{var ot,Le,tt,Te;let je=(ot=x.cloneDeep(I))==null?void 0:ot.find(mt=>(mt==null?void 0:mt.keyType)===(ge==null?void 0:ge.key));if(je){let mt=(Te=(tt=(Le=je.value.pageData.compData)==null?void 0:Le.find(Qe=>(Qe==null?void 0:Qe.key)==="formContent"))==null?void 0:tt.contents)==null?void 0:Te.find(Qe=>(Qe==null?void 0:Qe.key)===(ge==null?void 0:ge.key));ge.value=mt==null?void 0:mt.value}return ge})),j}),W.push({id:q==null?void 0:q.id,value:q==null?void 0:q.value});let Z=[];(be=(we=(me=q==null?void 0:q.value)==null?void 0:me.pageData)==null?void 0:we.compData)==null||be.forEach(j=>{var Oe;(j==null?void 0:j.key)==="formContent"&&((Oe=j==null?void 0:j.contents)==null||Oe.forEach(ge=>{var je,ot,Le,tt,Te,mt;if((ot=(je=ge==null?void 0:ge.optionUrl)==null?void 0:je.menuSelect)!=null&&ot.find(Qe=>Qe==null?void 0:Qe.includes("[")))if(Z!=null&&Z.find(Qe=>{var Ve,it,gt;return((Ve=Qe==null?void 0:Qe.key)==null?void 0:Ve.join(","))===((gt=(it=ge==null?void 0:ge.optionUrl)==null?void 0:it.menuSelect)==null?void 0:gt.join(","))})){let Qe=(Le=Z==null?void 0:Z.find(Ve=>{var it,gt,Ye;return((it=Ve==null?void 0:Ve.key)==null?void 0:it.join(","))===((Ye=(gt=ge==null?void 0:ge.optionUrl)==null?void 0:gt.menuSelect)==null?void 0:Ye.join(","))}))==null?void 0:Le.value;Qe.push({key:ge==null?void 0:ge.prop,groups:(tt=ge==null?void 0:ge.optionUrl)==null?void 0:tt.groupSelect,value:ge==null?void 0:ge.value}),Z=Z==null?void 0:Z.map(Ve=>{var it,gt,Ye;return((it=Ve==null?void 0:Ve.key)==null?void 0:it.join(","))===((Ye=(gt=ge==null?void 0:ge.optionUrl)==null?void 0:gt.menuSelect)==null?void 0:Ye.join(","))&&(Ve.value=Qe),Ve})}else Z.push({key:(Te=ge==null?void 0:ge.optionUrl)==null?void 0:Te.menuSelect,value:[{key:ge==null?void 0:ge.prop,groups:(mt=ge==null?void 0:ge.optionUrl)==null?void 0:mt.groupSelect,value:ge==null?void 0:ge.value}]})}))}),(Z==null?void 0:Z.length)>0&&(Z=Z==null?void 0:Z.map(j=>{var ge;let Oe="";return(ge=j==null?void 0:j.key)==null||ge.forEach(je=>{var ot;if(!(je!=null&&je.includes("[")))Oe=Oe===""?Oe+je:Oe+"/"+je;else{let Le="",tt=(ot=je==null?void 0:je.replaceAll("[","").replaceAll("]",""))==null?void 0:ot.split(":");m==null||m.forEach(Te=>{var mt;(Te==null?void 0:Te.name)===(tt==null?void 0:tt[0])&&((mt=Te==null?void 0:Te.compData)==null||mt.forEach(Qe=>{var Ve;(Qe==null?void 0:Qe.key)==="formContent"&&((Ve=Qe==null?void 0:Qe.contents)==null||Ve.forEach(it=>{(it==null?void 0:it.prop)===(tt==null?void 0:tt[1])&&(Le=it==null?void 0:it.value)}))}))}),Oe=Oe+r.value+Le}}),j.key=Oe,j})),Z==null||Z.forEach(j=>{var ot,Le,tt;let Oe=(ot=He[j.key])==null?void 0:ot.find(Te=>{var mt,Qe,Ve,it,gt,Ye,$e;return((Qe=(mt=Te==null?void 0:Te.value)==null?void 0:mt.pageData)==null?void 0:Qe.name)===((gt=(it=(Ve=j==null?void 0:j.value)==null?void 0:Ve[0])==null?void 0:it.groups)==null?void 0:gt[0])&&(($e=(Ye=Te==null?void 0:Te.value)==null?void 0:Ye.pageData)==null?void 0:$e.name)!==void 0}),ge=Oe==null?void 0:Oe.id,je=(Le=Oe==null?void 0:Oe.value)==null?void 0:Le.pageData;je.compData=(tt=je.compData)==null?void 0:tt.map(Te=>{var mt;return(Te==null?void 0:Te.key)==="formContent"&&(Te.contents=(mt=Te.contents)==null?void 0:mt.map(Qe=>{var it;let Ve=(it=j.value)==null?void 0:it.find(gt=>(gt==null?void 0:gt.key)===(Qe==null?void 0:Qe.prop));return Ve&&(Qe.value=Ve.value),Qe})),Te}),W.push({id:ge,value:{pageData:je}})})});let Ee=(_e=x.cloneDeep(I))==null?void 0:_e[0];(W==null?void 0:W.length)>0&&await lt.batchUpdateInsofDataApi({dataList:W})}D.setFreshContent(!0)}F.setImportLoading(!1)}catch{lt.ElMessage.error("方法执行错误,请查看方法!"),F.setImportLoading(!1)}h.value=!0},pe=["createInsofDataApi"],We=dr(async X=>{ne(X)},100),at=async X=>{var ae,De,N,Ge,Xe;const V=x.cloneDeep(X);let te,ye=new WeakMap,ue=await lt.getPageInsofDataApi({systemKey:sessionStorage.getItem("systemKey"),type:G.value});(De=(ae=ue.data.result)==null?void 0:ae.filter(Be=>{var le,Q;return((le=Be==null?void 0:Be.key)==null?void 0:le.pageKey)!=="menu"&&((Q=Be==null?void 0:Be.key)==null?void 0:Q.pageKey)!=="secret"}))==null||De.forEach(Be=>{ye[Be.key.pageKey]?ye[Be.key.pageKey]=[...ye[Be.key.pageKey],Be]:ye[Be.key.pageKey]=[Be]}),X!=null&&X[0].path&&(te=await(V==null?void 0:V.map(async(Be,le)=>{var U,J,_,oe,Ae,I,ee,$,W,Ee,ie,q,Z,de,me,we;const se=(U=ye[Be==null?void 0:Be.path])==null?void 0:U.filter(be=>{var j;return((j=be==null?void 0:be.key)==null?void 0:j.type)==="data"});let _e="";const He=await Ie.getItemData(b.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,ye);se==null||se.forEach(be=>{var j,Oe,ge,je,ot;((Oe=(j=be==null?void 0:be.value)==null?void 0:j.tableData)==null?void 0:Oe.算法名称)===((ge=V==null?void 0:V[le])==null?void 0:ge.method)&&(_e=(ot=(je=be==null?void 0:be.value)==null?void 0:je.tableData)==null?void 0:ot.算法体)});const dt=await Ie.getItemData(Be==null?void 0:Be.path,sessionStorage.getItem("systemKey"),"",!1,[],!1,ye);let m="",T=(Ae=(oe=(_=(J=dt==null?void 0:dt[0])==null?void 0:J.compData)==null?void 0:_.find(be=>(be==null?void 0:be.key)==="header"))==null?void 0:oe.contents)==null?void 0:Ae.findIndex(be=>(be==null?void 0:be.prop)==="算法体");return(ee=(I=dt==null?void 0:dt[0])==null?void 0:I.compData)==null||ee.forEach(be=>{var j;(be==null?void 0:be.key)==="tableContents"&&((j=be==null?void 0:be.contents)==null||j.forEach(Oe=>{Oe!=null&&Oe.find(ge=>ge===(Be==null?void 0:Be.method))&&(m=Oe[T])}))}),{buttonName:(($=V==null?void 0:V[le])==null?void 0:$.method)||((ie=(Ee=(W=se==null?void 0:se[0])==null?void 0:W.value)==null?void 0:Ee.tableData)==null?void 0:ie.算法名称),api:(_e===""?(de=(Z=(q=se==null?void 0:se[0])==null?void 0:q.value)==null?void 0:Z.tableData)==null?void 0:de.算法体:_e)||m,content:He==null?void 0:He.filter(be=>be.comp!=="methodButton"),extraContent:(me=x.cloneDeep(Be.value))==null?void 0:me.slice(1),methodName:(Be==null?void 0:Be.path)??"",extraValues:(we=V==null?void 0:V[le])==null?void 0:we.data}})));const Ce=V==null?void 0:V.map(async Be=>{var dt,m,T,U,J,_;const le=(dt=ue.data.result)==null?void 0:dt.filter(oe=>{var Ae,I,ee;return((Ae=oe==null?void 0:oe.key)==null?void 0:Ae.parentTable)===""&&((I=oe==null?void 0:oe.key)==null?void 0:I.type)==="method"&&((ee=oe==null?void 0:oe.key)==null?void 0:ee.methodName)===oe.method}),Q=le==null?void 0:le[0],se=(m=ue.data.result)==null?void 0:m.filter(oe=>{var Ae,I;return((Ae=oe==null?void 0:oe.key)==null?void 0:Ae.type)==="methodData"&&((I=oe==null?void 0:oe.key)==null?void 0:I.tableId)===(Q==null?void 0:Q.id)}),_e=await Ie.getItemData(b.value,sessionStorage.getItem("systemKey"),"",!1,[],!1,ye),He=se==null?void 0:se[0];return{buttonName:(T=Q==null?void 0:Q.key)==null?void 0:T.methodKey,api:(J=(U=He==null?void 0:He.value)==null?void 0:U.tableData)==null?void 0:J[0],content:_e==null?void 0:_e.filter(oe=>oe.comp!=="methodButton"),extraContent:(_=x.cloneDeep(Be.value))==null?void 0:_.slice(1),methodName:(Be==null?void 0:Be.method)??""}}),Ze=(N=X==null?void 0:X[0])!=null&&N.path&&((Ge=X==null?void 0:X[0])==null?void 0:Ge.path)!==""?await Promise.all(te):await Promise.all(Ce);l.value=Ze==null?void 0:Ze.filter(Be=>Be==null?void 0:Be.extraContent),(Xe=l.value)==null||Xe.forEach(Be=>{var le;Be.api===""&&((le=Be.content)==null||le.forEach(Q=>{var se;Q.comp=="Table"&&D.setExtraContents(Ie.methodTableToContent(Q.compData,(se=Be.extraContent)==null?void 0:se[0]))}))})};return e.watch(()=>d.itemData,async()=>{M.value=="view"&&!h.value&&await at(x.cloneDeep(d.itemData)),h.value=!1},{immediate:!0,deep:!0}),(X,V)=>{var te,ye,ue;return e.unref(M)!=="edit"?(e.openBlock(),e.createElementBlock("div",mc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList((te=l.value)==null?void 0:te.filter(Ce=>(Ce==null?void 0:Ce.buttonName)!=="保存"),Ce=>{var Ze;return e.openBlock(),e.createElementBlock("div",null,[Ce.api!==""?(e.openBlock(),e.createBlock(e.unref(_o._sfc_main),{key:0,disabled:e.unref(O)===e.unref(b)&&!((Ze=Ce==null?void 0:Ce.buttonName)!=null&&Ze.includes("预览")),class:"calculator-content",modelValue:Ce.buttonName,onClickTrigger:ae=>e.unref(We)(Ce),loading:C.value},null,8,["disabled","modelValue","onClickTrigger","loading"])):e.createCommentVNode("",!0)])}),256)),e.createElementVNode("div",null,[e.unref(ve)!==""&&((ue=e.unref(b))==null?void 0:ue[((ye=e.unref(b))==null?void 0:ye.length)-1])!==e.unref(r)?(e.openBlock(),e.createBlock(e.unref(_o._sfc_main),{key:0,class:"calculator-content",onClickTrigger:ce,modelValue:"保存"})):e.createCommentVNode("",!0)]),c.value?(e.openBlock(),e.createBlock(Bt.ssFilePreview,{key:0,fileDataList:w.value,onDestroy:Ne},null,8,["fileDataList"])):e.createCommentVNode("",!0)])):e.createCommentVNode("",!0)}}},yc=Rt._export_sfc(gc,[["__scopeId","data-v-11fca7e0"]]),bc={};function kc(a,l){return" 567 "}const xc=Rt._export_sfc(bc,[["render",kc]]),wc={class:"module content"},Cc={class:"module data"},Dc={class:"module layout"},_c={class:"form-content"},Ec=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const s=a,r=l,d=e.reactive({visible:!1,width:"40%",title:"签名配置"}),c=e.ref("create"),w=e.ref([{label:"取消",background:"#c0c4cc"},{label:"确认",background:"#436aaf"}]),v=e.ref([{label:"宽度(%):",prop:"signPadWidth",type:"number",value:"30"},{label:"弹窗名称:",prop:"dialogTitle",type:"input",value:""},{label:"弹窗宽度(%):",prop:"dialogWidth",type:"number",value:"30"},{label:"弹窗显示:",prop:"dialogShow",type:"radio",contents:[{label:"显示",value:!0},{label:"隐藏",value:!1}],value:!1,isFormColHidden:!0},{label:"路径:",prop:"url",type:"input",value:"",isFormColHidden:!0}]),f=e.computed(()=>[{label:"",prop:"index",type:"input",value:"",isFormColHidden:!0},{label:"类型:",prop:"label",type:"select",contents:[{label:"电子签名",value:"电子签名"},{label:"签字版",value:"签字版"},{label:"上传签名",value:"上传签名"}],value:""},{label:"图标",prop:"icon",type:"inputPopover",value:""}]),D=e.ref({}),C=e.ref([]),F=()=>({comp:"Signature",compData:[{key:"signTypeList",contents:C.value},{key:"signConfig",contents:D.value}]}),R=K=>{var O;D.value=x.cloneDeep(K),r("change",(O=F())==null?void 0:O.compData)},H=K=>{var O,G;if((K==null?void 0:K.buttonName)==="确认"){const b=x.cloneDeep(K==null?void 0:K.content);switch(c.value){case"create":C.value.push({...b,index:((O=C.value)==null?void 0:O.length)+1});break}r("change",(G=F())==null?void 0:G.compData),d.visible=!1}else d.visible=!1},M=(K,O)=>{var G,b;switch(K){case"create":(G=f.value)==null||G.forEach(E=>{E.value=""}),c.value="create",d.visible=!0;break;case"update":(b=f.value)==null||b.forEach(E=>{E.value=O[E==null?void 0:E.prop]}),c.value="update",d.visible=!0;break;case"delete":C.value.splice(O,1),c.value="delete";break}},ve=()=>{d.visible=!1};return e.watch(()=>s==null?void 0:s.itemContents,K=>{var O,G;K&&(D.value=((O=K==null?void 0:K.find(b=>b.key==="signConfig"))==null?void 0:O.contents)??{},C.value=((G=K==null?void 0:K.find(b=>b.key==="signTypeList"))==null?void 0:G.contents)??[])},{immediate:!0}),(K,O)=>{const G=e.resolveComponent("svg-icon"),b=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",wc,[O[2]||(O[2]=e.createElementVNode("h4",{class:"module-title"},"签名类型",-1)),e.createVNode(b,{class:"module-icon",id:"themeButton",onClick:O[0]||(O[0]=E=>M("create"))},{icon:e.withCtx(()=>[e.createVNode(G,{name:"Plus",class:"icon-size"})]),default:e.withCtx(()=>[O[1]||(O[1]=e.createTextVNode(" 新增 "))]),_:1,__:[1]})]),e.createElementVNode("div",Cc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(C.value,(E,y)=>(e.openBlock(),e.createElementBlock("div",{class:"module-data-item",key:y},[e.createElementVNode("span",null,e.toDisplayString(E==null?void 0:E.label),1),e.createElementVNode("div",null,[e.createVNode(b,{type:"primary",size:"small",onClick:B=>M("update",{...E,index:y+1})},{default:e.withCtx(()=>O[3]||(O[3]=[e.createTextVNode("修改")])),_:2,__:[3]},1032,["onClick"]),e.createVNode(b,{type:"danger",size:"small",onClick:B=>M("delete",y)},{default:e.withCtx(()=>O[4]||(O[4]=[e.createTextVNode("删除")])),_:2,__:[4]},1032,["onClick"])])]))),128))]),e.createElementVNode("div",Dc,[e.createVNode(Bt.ssForm,{rowContents:v.value,onChange:R},null,8,["rowContents"])])]),e.createVNode(Xt.ssDialog,{visible:d.visible,title:d.title,onBeforeDestroy:ve,width:d.width},{default:e.withCtx(()=>[e.createElementVNode("div",_c,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:f.value,key:f.value,isEnableWrap:!1,isButtonRow:!1,isStartJustify:!1,buttonValue:w.value,onOnButtonClick:H},null,8,["rowContents","buttonValue"]))])]),_:1},8,["visible","title","width"])],64)}}}),Sc=Rt._export_sfc(Ec,[["__scopeId","data-v-487e0536"]]),Tc=e.defineComponent({__name:"index",props:{stepConfig:{type:Object,default:{}},stepList:{type:Array,default:()=>[]}},emits:["clickStep","clickTrigger","changeTrigger"],setup(a,{emit:l}){const s=a,r=l,d=e.ref(1),c=e.computed(()=>{var F,R;return(F=s==null?void 0:s.stepConfig)!=null&&F.allowTrigger?d.value:(R=s==null?void 0:s.stepConfig)==null?void 0:R.active}),w=(F,R)=>{d.value=R,r("clickStep",F,R)},v=F=>Bt.getComponent(F),f=()=>{var R;const F=(R=s==null?void 0:s.stepList)==null?void 0:R.find((H,M)=>M+1===c.value);return console.log("findStep",F),F?F==null?void 0:F.children:[]},D=F=>{r("clickTrigger",F)},C=F=>{r("changeTrigger",F)};return(F,R)=>{var ve,K,O,G,b;const H=e.resolveComponent("el-step"),M=e.resolveComponent("el-steps");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createVNode(M,{direction:(ve=a.stepConfig)==null?void 0:ve.direction,active:c.value,"finish-status":"success",simple:(K=a.stepConfig)==null?void 0:K.simple,"align-center":((O=a.stepConfig)==null?void 0:O.alignCenter)??!0},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.stepList,(E,y)=>(e.openBlock(),e.createBlock(H,{key:y,class:"step-item",onClick:B=>w(E,y+1)},{title:e.withCtx(()=>[e.renderSlot(F.$slots,"title",{title:E==null?void 0:E.title},void 0,!0)]),description:e.withCtx(()=>[e.renderSlot(F.$slots,"description",{description:E==null?void 0:E.description},void 0,!0)]),_:2},1032,["onClick"]))),128))]),_:3},8,["direction","active","simple","align-center"]),(G=a.stepConfig)!=null&&G.allowTrigger&&((b=a.stepConfig)!=null&&b.active)?(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:0},e.renderList(f(),(E,y)=>(e.openBlock(),e.createElementBlock("div",{key:y,class:"step-cont-wrap"},[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(v(E==null?void 0:E.type)),{modelValue:E.value,"onUpdate:modelValue":B=>E.value=B,onClickTrigger:D,onChangeTrigger:C,content:E==null?void 0:E.content},e.createSlots({_:2},[e.renderList(F.$slots,(B,h)=>({name:h,fn:e.withCtx(ce=>[e.renderSlot(F.$slots,h,e.mergeProps({ref_for:!0},ce||{}),void 0,!0)])}))]),1064,["modelValue","onUpdate:modelValue","content"]))]))),128)):e.createCommentVNode("",!0)],64)}}}),Bc=Rt._export_sfc(Tc,[["__scopeId","data-v-d7c99969"]]),Ic=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]}},emits:["clickStep"],setup(a,{emit:l}){const s=a,r=l,d=e.ref({}),c=e.ref([]),w=(v,f)=>{r("clickStep",v,f)};return e.watch(()=>s==null?void 0:s.itemData,v=>{var f,D;c.value=(f=v==null?void 0:v.find(C=>(C==null?void 0:C.key)==="stepList"))==null?void 0:f.contents,d.value=(D=v==null?void 0:v.find(C=>(C==null?void 0:C.key)==="stepConfig"))==null?void 0:D.contents},{immediate:!0,deep:!0}),(v,f)=>{const D=e.resolveComponent("svg-icon");return e.openBlock(),e.createBlock(Bc,{stepConfig:d.value,stepList:c.value,onClickStep:w},{icon:e.withCtx(()=>[e.createVNode(D,{name:"import"})]),title:e.withCtx(({title:C})=>[e.createTextVNode(e.toDisplayString(C),1)]),description:e.withCtx(({description:C})=>[e.createTextVNode(e.toDisplayString(C),1)]),_:1},8,["stepConfig","stepList"])}}}),Nc=e.defineComponent({__name:"index",props:{activities:{type:Array,default:()=>[]},timeLineConfig:{type:Object,default:()=>{}}},setup(a){return(l,s)=>{const r=e.resolveComponent("el-timeline-item"),d=e.resolveComponent("el-timeline");return e.openBlock(),e.createBlock(d,null,{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(a.activities,(c,w)=>(e.openBlock(),e.createBlock(r,{key:w,timestamp:c.timestamp,placement:a.timeLineConfig.placement,center:a.timeLineConfig.isCenter,"hide-timestamp":!0,type:a.timeLineConfig.type,color:a.timeLineConfig.color,size:a.timeLineConfig.size,icon:a.timeLineConfig.icon,hollow:a.timeLineConfig.isHollow},{default:e.withCtx(()=>[e.renderSlot(l.$slots,"content",{content:c==null?void 0:c.content,timestamp:c==null?void 0:c.timestamp},void 0,!0)]),_:2},1032,["timestamp","placement","center","type","color","size","icon","hollow"]))),128))]),_:3})}}}),Ac=Rt._export_sfc(Nc,[["__scopeId","data-v-4172a886"]]),Vc={class:"line-content"},Oc={class:"line-time"},Mc=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]}},setup(a){const l=a,s=e.ref({}),r=e.ref([]);return e.watch(()=>l==null?void 0:l.itemData,d=>{var c,w;r.value=(c=d==null?void 0:d.find(v=>(v==null?void 0:v.key)==="timeLineList"))==null?void 0:c.contents,s.value=(w=d==null?void 0:d.find(v=>(v==null?void 0:v.key)==="timeLineConfig"))==null?void 0:w.contents},{immediate:!0}),(d,c)=>(e.openBlock(),e.createBlock(Ac,{activities:r.value,timeLineConfig:s.value},{content:e.withCtx(({content:w,timestamp:v})=>[e.createElementVNode("span",Vc,e.toDisplayString(w),1),e.createElementVNode("span",Oc,e.toDisplayString(v),1)]),_:1},8,["activities","timeLineConfig"]))}}),zc=Rt._export_sfc(Mc,[["__scopeId","data-v-b4d9deed"]]),Fc={class:"tabs-content"},Rc={__name:"index",props:{itemData:{type:Array,default:()=>[]},tabsData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},index:Number},setup(a){const l=a,s=e.ref([]);return e.watch(()=>l==null?void 0:l.itemData,r=>{const d=r.find(c=>(c==null?void 0:c.key)=="stepList");d?s.value=d.contents.map(c=>({value:c.value||c.title,label:c.label||c.title,children:c.children||[]})):s.value=l==null?void 0:l.tabsData},{immediate:!0,deep:!0}),(r,d)=>(e.openBlock(),e.createElementBlock("div",Fc,[e.createVNode(Bt.ssTab,{tabsContents:s.value},null,8,["tabsContents"])]))}},Pc=Rt._export_sfc(Rc,[["__scopeId","data-v-40865f68"]]),Ga=x.defineStore("tabComp",{state:()=>({itemData:[],originalData:[],extraContents:[],nodeDev:"",isEdit:"view",isRefreshCurStructure:!1,isSubmitCurStructure:!1,curStructureCompIds:[]}),actions:{setItemData(a){this.itemData=a},setCurStructureCompIds(a){this.curStructureCompIds=a},setRefreshCurStructure(a){this.isRefreshCurStructure=a},setOriginalData(a){this.originalData=a},setExtraContents(a){this.extraContents=a},setNodeDev(a){this.nodeDev=a},setIsEdit(a){this.isEdit=a}}}),Lc={class:"type-select"},$c=["onClick"],jc={class:"list-icon"},Uc={__name:"modelSelect",setup(a){const l=Ga(x.pinia),{itemData:s}=x.storeToRefs(l),r=d=>{const c=x.cloneDeep(s.value);c.push({comp:d.comp,name:d.name,compData:[]}),l.setItemData(c)};return(d,c)=>{const w=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",Lc,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(e.unref(ol),(v,f)=>(e.openBlock(),e.createElementBlock("div",{class:"type-list",key:f},[e.createElementVNode("div",{class:"list-content",onClick:D=>r(v)},[e.createElementVNode("div",jc,[e.createVNode(w,{name:v.icon},null,8,["name"])]),e.createElementVNode("div",null,e.toDisplayString(v.name),1)],8,$c)]))),128))])}}},Kc=Rt._export_sfc(Uc,[["__scopeId","data-v-91799bf8"]]),Wc={class:"fill-content"},Hc={class:"operate-content"},qc={class:"collapse-title-content"},Gc={class:"collapse-title-item"},Xc={key:1},Yc=["onClick"],Jc={class:"icon-content"},Zc={key:0,class:"edit-content"},Qc=["onClick"],eu={class:"comp-child"},tu={__name:"modelFill",setup(a){const l=Ga(x.pinia),{itemData:s,originalData:r}=x.storeToRefs(l),d=e.ref([]);e.ref([]);const c=e.ref([]),w=e.ref([]),v=H=>{var ve;let M=(ve=x.cloneDeep(w.value))==null?void 0:ve.map((K,O)=>(H===O&&(K.content=!0),K));w.value=M},f=H=>{var ve;let M=(ve=x.cloneDeep(w.value))==null?void 0:ve.map((K,O)=>(H===O&&(K.content=!1),K));w.value=M,d.value=x.cloneDeep(s.value)},D=(H,M)=>{var G;let ve=(G=x.cloneDeep(w.value))==null?void 0:G.map((b,E)=>(H===E&&(b.content=!1),b));w.value=ve;const K=x.cloneDeep(s.value),O=K==null?void 0:K.filter((b,E)=>(E===H&&(b.name=M),b));l.setOriginalData(O),l.setItemData(O)};e.watch(()=>s.value,()=>{var H,M,ve;!s.value||((H=s.value)==null?void 0:H.length)===0?d.value=[]:d.value=(M=x.cloneDeep(s.value))==null?void 0:M.filter(K=>(K==null?void 0:K.comp)!=="methodButton"),c.value=d.value,w.value=(ve=x.cloneDeep(c.value))==null?void 0:ve.map((K,O)=>({id:O,content:!1}))},{deep:!0,immediate:!0});const C=H=>aa(H),F=(H,M,ve)=>{var O,G;if(!H)return;let K=x.cloneDeep(s.value);K=(O=K==null?void 0:K.map((b,E)=>(E===ve&&(b.compData=H),b)))==null?void 0:O.filter(b=>(b==null?void 0:b.comp)!=="methodButton"),w.value=(G=x.cloneDeep(K))==null?void 0:G.map((b,E)=>({id:E,content:!1})),l.setOriginalData(K),l.setItemData(K)},R=H=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{const M=x.cloneDeep(s.value),ve=M==null?void 0:M.filter((K,O)=>O!==H);l.setOriginalData(ve),l.setItemData(ve),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})};return(H,M)=>{const ve=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",Wc,[M[1]||(M[1]=e.createElementVNode("div",{class:"fill-operate"},e.toDisplayString("操作栏"),-1)),e.createElementVNode("div",Hc,[e.createVNode(ur.default,{class:"collapse-content",collapseContents:d.value},{title:e.withCtx(({item:K,index:O})=>{var G,b,E,y,B,h,ce,Ne,nt,xe;return[e.createElementVNode("div",qc,[e.createElementVNode("div",Gc,[(b=(G=w.value)==null?void 0:G.find(Re=>Re.id===O))!=null&&b.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:0,class:"collapse-title",style:e.normalizeStyle({marginRight:K.name&&K.name!==""?"8px":"0px"})},e.toDisplayString(K.name),5)),(y=(E=w.value)==null?void 0:E.find(Re=>Re.id===O))!=null&&y.content?(e.openBlock(),e.createElementBlock("div",Xc,[e.createVNode(Bt._sfc_main$2,{modelValue:K.name,"onUpdate:modelValue":Re=>K.name=Re,onClick:M[0]||(M[0]=e.withModifiers(()=>{},["stop"]))},null,8,["modelValue","onUpdate:modelValue"])])):e.createCommentVNode("",!0),(h=(B=w.value)==null?void 0:B.find(Re=>Re.id===O))!=null&&h.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:2,onClick:e.withModifiers(Re=>v(O),["stop"]),class:"icon-content"},[e.createVNode(ve,{name:"Edit",style:{width:"16px",height:"16px"}})],8,Yc))]),e.createElementVNode("div",Jc,[(Ne=(ce=w.value)==null?void 0:ce.find(Re=>Re.id===O))!=null&&Ne.content?(e.openBlock(),e.createElementBlock("div",Zc,[e.createVNode(ve,{name:"Cancel",style:{width:"16px",height:"16px"},class:"icon-content",onClick:e.withModifiers(Re=>f(O),["stop"])},null,8,["onClick"]),e.createVNode(ve,{name:"Save",onClick:e.withModifiers(Re=>D(O,K.name),["stop"]),style:{width:"16px",height:"16px",fill:"var(--ssComponent-primary-color)"},class:"icon-content"},null,8,["onClick"])])):e.createCommentVNode("",!0),(xe=(nt=w.value)==null?void 0:nt.find(Re=>Re.id===O))!=null&&xe.content?e.createCommentVNode("",!0):(e.openBlock(),e.createElementBlock("div",{key:1,onClick:e.withModifiers(Re=>R(O),["stop"]),class:"icon-content"},[e.createVNode(ve,{name:"Delete",style:{width:"16px",height:"16px"}})],8,Qc))])])]}),content:e.withCtx(({item:K,index:O})=>{var G,b;return[e.createElementVNode("div",eu,[e.createTextVNode(e.toDisplayString(C(K.comp+"Operate"))+" ",1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(C(K.comp+"Operate")),{itemContents:K==null?void 0:K.compData,originalItemContents:(b=(G=c.value)==null?void 0:G.find((E,y)=>y===O))==null?void 0:b.compData,onChange:E=>F(E,K,O)},null,40,["itemContents","originalItemContents","onChange"]))])]}),_:1},8,["collapseContents"])])])}}},nu=Rt._export_sfc(tu,[["__scopeId","data-v-a46a44b9"]]),au={key:0,class:"show-content"},ou={style:{display:"flex"}},ru={__name:"modelShow",setup(a){const l=Ga(x.pinia),{itemData:s}=x.storeToRefs(l),r=e.ref([]);e.watch(()=>s.value,()=>{var c;!s.value||((c=s.value)==null?void 0:c.length)===0?r.value=[]:r.value=x.cloneDeep(s.value)},{deep:!0,immediate:!0});const d=c=>aa(c);return(c,w)=>{var v;return((v=r.value)==null?void 0:v.length)>0?(e.openBlock(),e.createElementBlock("div",au,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(r.value,(f,D)=>(e.openBlock(),e.createElementBlock("div",{class:"item-content",key:D},[e.createElementVNode("div",ou,e.toDisplayString(f.name),1),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(d(f.comp)),{itemData:f==null?void 0:f.compData,childItemData:f==null?void 0:f.itemChildData,key:D},null,8,["itemData","childItemData"]))]))),128))])):e.createCommentVNode("",!0)}}},lu=Rt._export_sfc(ru,[["__scopeId","data-v-3f3e863e"]]),iu={class:"tabs-header"},su={class:"tabs-list"},cu={class:"tab-name"},uu={class:"tab-actions"},du=["onClick"],pu=["onClick"],fu=["onClick"],hu={class:"model-operate"},vu={class:"model-select",style:{display:"unset"}},mu={class:"existing-components"},gu={class:"component-list"},yu=["onClick"],bu={class:"component-info"},ku={class:"component-type"},xu={class:"component-name"},wu={class:"model-fill"},Cu={__name:"operate",props:{itemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const s=a,r=l,d=e.ref([]),c=e.ref(!1),w=e.ref(""),v=e.ref({title:""}),f=e.ref(-1),D=e.ref(!1),C=e.ref(-1),F=e.ref(new WeakMap),R=e.ref(null),H=Ga(x.pinia),{itemData:M}=x.storeToRefs(H),ve=()=>{w.value="新增标签页",v.value.title="",f.value=-1,c.value=!0},K=X=>{w.value="修改标签页",v.value.title=d.value[X].title,f.value=X,c.value=!0},O=X=>{const V=E(X);F.value.delete(V),d.value.splice(X,1),at()},G=()=>{if(v.value.title.trim()){if(f.value===-1){const X={title:v.value.title,value:v.value.title,label:v.value.title,children:[],id:b()};d.value.push(X)}else d.value[f.value].title=v.value.title,d.value[f.value].value=v.value.title,d.value[f.value].label=v.value.title;c.value=!1,at()}},b=()=>`tab_${Date.now()}_${Math.random().toString(36).substr(2,9)}`,E=X=>{const V=d.value[X];return V.id||(V.id=b()),V.id},y=X=>{var ye;C.value=X;const V=E(X);R.value=x.cloneDeep(M.value);let te=F.value.get(V);!te&&((ye=d.value[X].children)==null?void 0:ye.length)>0&&(te=Ne(d.value[X].children)),te?H.setItemData(x.cloneDeep(te)):H.setItemData([]),D.value=!0},B=e.computed(()=>{const X=x.useModelComp(x.pinia),V=x.storeToRefs(X).itemData.value;return console.log("可用组件数据",V),!V||!Array.isArray(V)?[]:V.filter(te=>{var ye;if(te.comp==="Tabs"&&C.value>=0){const ue=E(C.value);if((ye=te.compData)==null?void 0:ye.some(Ze=>{var ae;return Ze.key==="stepList"&&((ae=Ze.contents)==null?void 0:ae.some(De=>De.id===ue))}))return!1}return!0})}),h=X=>({Table:"表格",Form:"表单",Tabs:"标签页",Chart:"图表",Card:"卡片"})[X]||X,ce=X=>{var V;try{const te=x.cloneDeep(X);te.id=Date.now()+Math.random(),te.comp==="Tabs"&&((V=te.compData)==null||V.forEach(ue=>{ue.key==="stepList"&&ue.contents&&ue.contents.forEach(Ce=>{Ce.id=b()})}));const ye=x.cloneDeep(M.value);ye.push(te),H.setItemData(ye)}catch(te){console.error("添加组件失败:",te)}},Ne=X=>X.map(V=>{var te;switch(V.type){case"form":return{comp:"Form",name:V.value||"表单",compData:nt(V.content)};case"table":return{comp:"Table",name:V.value||"表格",compData:xe(V.content)};default:return{comp:"Unknown",name:V.value||"",compData:((te=V.content)==null?void 0:te.originalData)||[]}}}),nt=X=>{if(!X)return[];const V=[];return X.rowContents&&V.push({key:"formContent",contents:X.rowContents}),X.buttonValue&&V.push({key:"formButton",contents:X.buttonValue}),typeof X.isEnableWrap<"u"&&V.push({key:"enableWrap",contents:X.isEnableWrap}),V},xe=X=>[],Re=()=>{if(C.value>=0&&C.value<d.value.length){const X=E(C.value);F.value.set(X,x.cloneDeep(M.value)),d.value[C.value].children=re(M.value),console.log("保存后的数据",re(M.value))}D.value=!1,C.value=-1,R.value=null,at()},Pe=()=>{R.value&&H.setItemData(x.cloneDeep(R.value)),D.value=!1,C.value=-1,R.value=null},P=()=>{D.value&&Pe()},re=X=>{if(!Array.isArray(X))throw new Error("sourceData must be an array");return X.map((V,te)=>{if(!V||typeof V!="object")return V;const{comp:ye,name:ue,compData:Ce}=V;switch(ye){case"Form":return{type:"form",content:ne(Ce||[]),value:"表单"};case"Table":return{type:"table",content:pe(Ce||[]),value:"表格"};default:return{type:"xxx",content:We(Ce||[]),value:""}}})},ne=X=>{const V={formRules:{},rowContents:[],buttonValue:[],rowValues:[],isEnableWrap:!0,isRowFlex:!0,isButtonRow:!0,isEdit:!0,isStartJustify:!0},te={formContent:"rowContents",enableWrap:"isEnableWrap",formButton:"buttonValue"};return X.forEach((ye,ue)=>{if(!ye||typeof ye!="object"){console.warn(`Invalid config at index ${ue}:`,ye);return}const{key:Ce,contents:Ze}=ye,ae=te[Ce];if(!ae){console.warn(`Unknown Form config key: ${Ce}`);return}Ce==="enableWrap"?V[ae]=!!Ze:V[ae]=Array.isArray(Ze)?Ze:[]}),V},pe=X=>{const V={columns:[],tableData:[],extraButton:[],rowButton:[],currentPage:0,total:0,pageSize:0,isShowPagination:!0,isShowEdit:!0,isMoveColumn:!0,isShowDelete:!0},te={header:"columns",tableContents:"tableData"};return X.forEach((ye,ue)=>{if(!ye||typeof ye!="object"){console.warn(`Invalid config at index ${ue}:`,ye);return}const{key:Ce,contents:Ze}=ye,ae=te[Ce];if(!ae){console.warn(`Unknown Table config key: ${Ce}`);return}V[ae]=Array.isArray(Ze)?Ze:[]}),V},We=X=>(console.log("Default conversion logic - to be implemented"),{originalData:X,processed:!1,componentType:"unknown"}),at=()=>{const X=[{key:"stepList",contents:d.value}];r("change",X)};return e.watch(()=>s.itemContents,X=>{if(X&&X.length>0){const V=X.find(te=>te.key==="stepList");V&&V.contents&&(d.value=V.contents.map(te=>({title:te.title||"",value:te.value||te.title||"",label:te.label||te.title||"",children:te.children||[],id:te.id||b()})))}},{immediate:!0,deep:!0}),(X,V)=>{const te=e.resolveComponent("svg-icon"),ye=e.resolveComponent("el-input"),ue=e.resolveComponent("el-form-item"),Ce=e.resolveComponent("el-form");return e.openBlock(),e.createElementBlock("div",null,[e.createElementVNode("div",iu,[V[6]||(V[6]=e.createElementVNode("h4",null,"标签页管理",-1)),e.createElementVNode("button",{onClick:ve},[e.createVNode(te,{name:"Plus",style:{width:"14px",height:"14px","margin-right":"4px"}}),V[5]||(V[5]=e.createTextVNode(" 新增标签页 "))])]),e.createElementVNode("div",su,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(d.value,(Ze,ae)=>(e.openBlock(),e.createElementBlock("div",{class:"tab-item",key:ae},[e.createElementVNode("span",cu,e.toDisplayString(Ze.title),1),e.createElementVNode("div",uu,[e.createElementVNode("button",{onClick:De=>K(ae)},"修改标题",8,du),e.createElementVNode("button",{onClick:De=>y(ae)},"布局调整",8,pu),e.createElementVNode("button",{onClick:De=>O(ae)},"删除",8,fu)])]))),128))]),e.createVNode(Xt.ssDialog,{modelValue:c.value,"onUpdate:modelValue":V[2]||(V[2]=Ze=>c.value=Ze),title:w.value,onBeforeDestroy:V[3]||(V[3]=Ze=>c.value=!1)},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:V[1]||(V[1]=Ze=>c.value=!1)},"取消"),e.createElementVNode("button",{type:"primary",onClick:G},"确定")]),default:e.withCtx(()=>[e.createVNode(Ce,{model:v.value,"label-width":"80px"},{default:e.withCtx(()=>[e.createVNode(ue,{label:"标签名称",required:""},{default:e.withCtx(()=>[e.createVNode(ye,{modelValue:v.value.title,"onUpdate:modelValue":V[0]||(V[0]=Ze=>v.value.title=Ze),placeholder:"请输入标签页名称"},null,8,["modelValue"])]),_:1})]),_:1},8,["model"])]),_:1},8,["modelValue","title"]),e.createVNode(Xt.ssDialog,{modelValue:D.value,"onUpdate:modelValue":V[4]||(V[4]=Ze=>D.value=Ze),title:"布局调整",fullScreen:"",onBeforeDestroy:P},{footer:e.withCtx(()=>[e.createElementVNode("button",{onClick:Pe},"取消"),e.createElementVNode("button",{onClick:Re},"确定")]),default:e.withCtx(()=>[e.createElementVNode("div",hu,[e.createElementVNode("div",vu,[e.createVNode(Kc),e.createElementVNode("div",mu,[V[8]||(V[8]=e.createElementVNode("h5",null,"添加已有组件",-1)),e.createElementVNode("div",gu,[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(B.value,Ze=>(e.openBlock(),e.createElementBlock("div",{key:Ze.id,class:"component-item",onClick:ae=>ce(Ze)},[e.createElementVNode("div",bu,[e.createElementVNode("span",ku,e.toDisplayString(h(Ze.comp)),1),e.createElementVNode("span",xu,e.toDisplayString(Ze.name),1)]),V[7]||(V[7]=e.createElementVNode("button",{class:"add-btn"},"添加",-1))],8,yu))),128))])])]),(e.openBlock(),e.createElementBlock("div",{class:"model-show",key:X.innerWidth},[e.createVNode(lu)])),e.createElementVNode("div",wu,[e.createVNode(nu)])])]),_:1},8,["modelValue"])])}}},Du=Rt._export_sfc(Cu,[["__scopeId","data-v-9096ed0d"]]);function _u(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis"},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",axisLabel:{interval:0},data:[]},yAxis:{type:"value"},series:[]}}function Eu(a){return{type:"line",...a}}function Su(){return{title:{text:"",left:"center",top:10,textStyle:{color:"#333",fontSize:18,fontWeight:"bold"}},tooltip:{trigger:"axis",axisPointer:{type:"shadow"}},grid:{left:"3%",right:"4%",bottom:"3%",containLabel:!0},xAxis:{type:"category",data:["Mon","Tue","Wed","Thu","Fri","Sat","Sun"]},yAxis:[{type:"value"}],series:[]}}function Tu(a){return{type:"bar",barWidth:"60%",...a}}function Bu(){return{title:{text:"",left:"center"},tooltip:{trigger:"item"},series:[]}}function Iu(a){return{type:"pie",radius:"50%",emphasis:{itemStyle:{shadowBlur:10,shadowOffsetX:0,shadowColor:"rgba(0, 0, 0, 0.5)"}},...a}}const _n={line:{initBaseoptions:_u,initSeries:Eu},bar:{initBaseoptions:Su,initSeries:Tu},pie:{initBaseoptions:Bu,initSeries:Iu}},No=x.useMenuState(x.pinia),kr=(a,l)=>{var C;const s=[],r=[],{group:d,nameCol:c,valueCol:w}=l||{},v=a==null?void 0:a.find(F=>{const{name:R}=F;return R===d});if(!v)return{names:s,values:r};const f=(C=v==null?void 0:v.compData)==null?void 0:C.find(F=>{const{key:R}=F;return R==="tableContents"});return((f==null?void 0:f.contents)||[]).forEach(F=>{const R=F==null?void 0:F[0];let H=!1;lt.isObject(R)&&(R!=null&&R.id)&&(H=!0);let M=c,ve=w;H&&(M=M+1,ve=ve+1);const K=F==null?void 0:F[M],O=F==null?void 0:F[ve];s.push(K),r.push(O)}),{names:s,values:r}},Nu=async a=>{const{menu:l,mainKey:s,detailGroup:r,detailNameCol:d,detailValueCol:c,isSelfDetail:w}=a||{};let v=null;const f=sessionStorage.getItem("systemKey");if(w&&No.activeMenuPath&&(v=await Ie.getItemData(`${No.activeMenuPath}`,f,"")),!w){const D=l==null?void 0:l.join("/");v=await Ie.getItemData(`${D}^${s}`,f,"")}return kr(v,{group:r,nameCol:d,valueCol:c})},Au=async a=>{const{menu:l,group:s,nameCol:r,valueCol:d}=a||{},c=l==null?void 0:l.join("/"),w=sessionStorage.getItem("systemKey"),v=await Ie.getItemData(c,w,"");return kr(v,{group:s,nameCol:r,valueCol:d})},po=async(a,l)=>{const s={names:[],values:[]},{menu:r,group:d,nameCol:c,valueCol:w}=a||{};if(!r.length||!d)return s;const{mainKey:v,group:f,nameCol:D,valueCol:C,isSelfDetail:F}=l||{};return v&&f&&Bt.isNumber(D)&&Bt.isNumber(C)?await Nu({menu:r,mainKey:v,detailGroup:f,detailNameCol:D,detailValueCol:C,isSelfDetail:F}):Bt.isNumber(c)&&Bt.isNumber(w)?await Au({menu:r,group:d,nameCol:c,valueCol:w}):s},Vu=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:s})=>{const{type:r,title:d}=a||{},c=_n==null?void 0:_n[r];if(!c)return;const{initBaseoptions:w,initSeries:v}=c,f=w();f.title.text=d??"";const{names:D,values:C}=await po(l,s);if(!D||!C)return f;f.xAxis.data=D;const F=v({data:C});return f.series.push(F),f},Ou=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:s})=>{const{type:r,title:d}=a||{},c=_n==null?void 0:_n[r];if(!c)return;const{initBaseoptions:w,initSeries:v}=c,f=w();f.title.text=d??"";const{names:D,values:C}=await po(l,s);if(!D||!C)return f;f.xAxis.data=D;const F=v({data:C});return f.series.push(F),f},Mu=async({chartBaseConfig:a,chartDataConfig:l,chartDetailConfig:s})=>{const{type:r,title:d}=a||{},c=_n==null?void 0:_n[r];if(!c)return;const{initBaseoptions:w,initSeries:v}=c,f=w();f.title.text=d??"";const{names:D,values:C}=await po(l,s);if(!D||!C)return f;const F=[];for(let H=0;H<D.length;H++){const M=D[H],ve=C[H];F.push({name:M,value:ve})}const R=v({data:F});return f.series.push(R),f},zu=async(a=[])=>{var w,v,f;const l=((w=a==null?void 0:a.find(D=>D.key==="chartBaseConfig"))==null?void 0:w.contents)??{},s=((v=a==null?void 0:a.find(D=>D.key==="chartDataConfig"))==null?void 0:v.contents)??{},r=((f=a==null?void 0:a.find(D=>D.key==="chartDetailConfig"))==null?void 0:f.contents)??{},{type:d}=l;let c={};return d==="line"&&(c=await Vu({chartBaseConfig:l,chartDataConfig:s,chartDetailConfig:r})),d==="bar"&&(c=await Ou({chartBaseConfig:l,chartDataConfig:s,chartDetailConfig:r})),d==="pie"&&(c=await Mu({chartBaseConfig:l,chartDataConfig:s,chartDetailConfig:r})),c},Fu=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}},height:{type:String,default:"300px"}},setup(a){const l=a,s=e.ref({});e.onMounted(async()=>{const d=l==null?void 0:l.itemData;s.value=await zu(d)});const r=e.computed(()=>(l==null?void 0:l.height)||"300px");return(d,c)=>(e.openBlock(),e.createElementBlock("div",{class:"eCharts",style:e.normalizeStyle({height:r.value})},[e.createVNode(Fl.ssChart,{optionContents:s.value},null,8,["optionContents"])],4))}}),Ru=Rt._export_sfc(Fu,[["__scopeId","data-v-d4c081e8"]]),Pu={class:"chart-module layout"},Lu={class:"chart-module content"},$u={class:"chart-module content"},ju={class:"form-content"},Uu={class:"dialog-footer"},Ku={class:"form-content"},Wu={class:"dialog-footer"},Hu={class:"form-content"},qu={class:"dialog-footer"},Gu=e.defineComponent({__name:"operate",props:{itemContents:{type:Array,default:()=>[]},originalItemContents:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const s=a,r=l,d=e.reactive({visible:!1,width:"840",title:"基础配置"}),c=e.ref([]),w=()=>[{label:"类型",prop:"type",type:"select",contents:[{label:"柱状图",value:"bar"},{label:"饼图",value:"pie"},{label:"折线图",value:"line"}],value:""},{label:"标题",prop:"title",type:"input",value:""}],v=e.ref({}),f=()=>{var le;c.value=w(),(le=c.value)==null||le.forEach(Q=>{var _e;const se=Q==null?void 0:Q.prop;Q.value=(_e=v==null?void 0:v.value)==null?void 0:_e[se]}),d.visible=!0},D=le=>{v.value=le},C=()=>{var le;d.visible=!1,r("change",(le=Xe())==null?void 0:le.compData)},F=e.reactive({visible:!1,width:"840",title:"数据配置"}),R=e.ref([]),H=()=>[{label:"菜单选项",prop:"menu",type:"cascader",contents:[]},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],M=e.ref({}),ve=()=>{const le=R.value,Q=x.cloneDeep(le);return Q==null||Q.forEach(se=>{var He;const _e=se==null?void 0:se.prop;se.value=(He=M.value)==null?void 0:He[_e]}),Q},K=le=>{var se;M.value=le;const Q=ve();R.value=Q,r("change",(se=Xe())==null?void 0:se.compData)},O=async()=>{const le=await Ie.getMenusContent(),Q=ve();Q==null||Q.forEach(se=>{(se==null?void 0:se.prop)==="menu"&&(se.contents=le)}),R.value=Q,F.visible=!0,await Ze(M.value.menu),await N(M.value.group)},G=e.reactive({visible:!1,width:"840",title:"详情页配置"}),b=e.ref([]),E=()=>[{label:"详情页主键",prop:"mainKey",type:"select",contents:[]},{label:"使用当前详情页内容",prop:"isSelfDetail",type:"switch"},{label:"组信息选项",prop:"group",type:"select",contents:[]},{label:"名称列",prop:"nameCol",type:"select",contents:[]},{label:"取值列",prop:"valueCol",type:"select",contents:[]}],y=e.ref({}),B=()=>{const le=b.value,Q=x.cloneDeep(le);return Q==null||Q.forEach(se=>{var He;const _e=se==null?void 0:se.prop;se.value=(He=y.value)==null?void 0:He[_e]}),Q},h=le=>{var se;y.value=le;const Q=B();b.value=Q,r("change",(se=Xe())==null?void 0:se.compData)},ce=async()=>{await P();const le=x.cloneDeep(Ne.value),Q=B();Q==null||Q.forEach(se=>{var He;const _e=se==null?void 0:se.prop;se.value=(He=y==null?void 0:y.value)==null?void 0:He[_e],_e==="mainKey"&&(se.contents=le)}),b.value=Q,G.visible=!0},Ne=e.ref([]),nt=e.ref([]),xe=e.ref({}),Re=e.ref({}),Pe=()=>{const{compData:le}=ye.value||{},Q=le==null?void 0:le.find(U=>{const{key:J}=U;return J==="header"}),se=(Q==null?void 0:Q.contents)||[],_e=se==null?void 0:se.filter((U,J)=>{const{label:_}=U;return _!=="操作"}),He=_e==null?void 0:_e.findIndex((U,J)=>{const{isMainKey:_}=U;return _});if(He<0)return[];const dt=le==null?void 0:le.find(U=>{const{key:J}=U;return J==="tableContents"}),m=(dt==null?void 0:dt.contents)||[];return m==null?void 0:m.map(U=>{const J=U==null?void 0:U[0];let _=He;lt.isObject(J)&&(J!=null&&J.id)&&(_=_+1);const oe=U==null?void 0:U[_];return{label:oe,value:oe}})},P=async()=>{const le=await Pe();Ne.value=le},re=async le=>{const Q=sessionStorage.getItem("systemKey");return await Ie.getItemData(le,Q,"")},ne=async le=>{const Q=le;nt.value=Q==null?void 0:Q.map(se=>{const{name:_e}=se;return xe.value[_e]=se,{label:_e,value:_e}})},pe=le=>{const{comp:Q,compData:se}=Re.value||{};if(Q==="Table"){let _e=B();_e=_e.filter(He=>{const{prop:dt}=He;return dt!=="formItems"}),ae(_e,se),b.value=_e}},We=async()=>{var se,_e;const le=(se=y==null?void 0:y.value)==null?void 0:se.mainKey,Q=(_e=M==null?void 0:M.value)==null?void 0:_e.menu;if(le){const dt=`${Q==null?void 0:Q.join("/")}^${le}`,m=await re(dt);await ne(m);const T=B();T==null||T.forEach(U=>{(U==null?void 0:U.prop)==="group"&&(U.contents=nt.value)}),b.value=T}};e.watch(()=>{var le;return(le=y==null?void 0:y.value)==null?void 0:le.mainKey},async(le,Q)=>{le!=Q&&le&&await We()});const at=async le=>{const Q=xe.value[le];Re.value=Q,await pe()};e.watch(()=>{var le;return(le=y==null?void 0:y.value)==null?void 0:le.group},async(le,Q)=>{le!=Q&&le&&at(le)});const X=async()=>{var Q;await We();const le=(Q=y.value)==null?void 0:Q.group;await at(le)},V=e.ref([]),te=e.ref({}),ye=e.ref({}),ue=async le=>{const Q=le==null?void 0:le.join("/"),se=sessionStorage.getItem("systemKey");return await Ie.getItemData(Q,se,"")},Ce=async le=>{const Q=await ue(le);V.value=Q==null?void 0:Q.map(se=>{const{name:_e}=se;return te.value[_e]=se,{label:_e,value:_e}})},Ze=async(le,Q)=>{await Ce(le);const se=ve();se==null||se.forEach(_e=>{(_e==null?void 0:_e.prop)==="group"&&(_e.contents=V.value)}),R.value=se};e.watch(()=>{var le;return(le=M==null?void 0:M.value)==null?void 0:le.menu},async(le,Q)=>{const se=le==null?void 0:le.join("/"),_e=Q==null?void 0:Q.join("/");se!=_e&&await Ze(le)});const ae=(le,Q)=>{const se=Q==null?void 0:Q.find(m=>{const{key:T}=m;return T==="header"}),_e=(se==null?void 0:se.contents)||[],He=_e==null?void 0:_e.filter((m,T)=>{const{label:U}=m;return U!=="操作"}),dt=He==null?void 0:He.map((m,T)=>{const{label:U}=m;return{label:U,value:T}});le==null||le.forEach(m=>{const T=m==null?void 0:m.prop;(T==="nameCol"||T==="valueCol")&&(m.contents=dt)})},De=le=>{const{comp:Q,compData:se}=ye.value||{};if(Q==="Table"){M.value.formItems=[];let _e=ve();_e=_e.filter(He=>{const{prop:dt}=He;return dt!=="formItems"}),ae(_e,se),R.value=_e}},N=async le=>{const Q=te.value[le];ye.value=Q,await De()};e.watch(()=>{var le;return(le=M==null?void 0:M.value)==null?void 0:le.group},async(le,Q)=>{le!=Q&&N(le)});const Ge=async()=>{var se,_e;const le=(se=M.value)==null?void 0:se.menu;await Ze(le);const Q=(_e=M.value)==null?void 0:_e.group;await N(Q)},Xe=()=>({comp:"chart",compData:[{key:"chartBaseConfig",contents:v.value},{key:"chartDataConfig",contents:M.value},{key:"chartDetailConfig",contents:y.value}]}),Be=()=>{d.visible=!1,F.visible=!1,G.visible=!1};return e.onMounted(async()=>{var Q,se,_e;R.value=H(),b.value=E();const le=s==null?void 0:s.itemContents;v.value=((Q=le==null?void 0:le.find(He=>He.key==="chartBaseConfig"))==null?void 0:Q.contents)??{},M.value=((se=le==null?void 0:le.find(He=>He.key==="chartDataConfig"))==null?void 0:se.contents)??{},await Ge(),y.value=((_e=le==null?void 0:le.find(He=>He.key==="chartDetailConfig"))==null?void 0:_e.contents)??{},await X()}),(le,Q)=>{const se=e.resolveComponent("el-button");return e.openBlock(),e.createElementBlock(e.Fragment,null,[e.createElementVNode("div",null,[e.createElementVNode("div",Pu,[Q[4]||(Q[4]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createVNode(se,{id:"themeButton",onClick:Q[0]||(Q[0]=_e=>f())},{default:e.withCtx(()=>Q[3]||(Q[3]=[e.createTextVNode(" 修改 ")])),_:1,__:[3]})]),e.createElementVNode("div",Lu,[Q[6]||(Q[6]=e.createElementVNode("h4",{class:"module-title"},"数据配置",-1)),e.createVNode(se,{id:"themeButton",onClick:Q[1]||(Q[1]=_e=>O())},{default:e.withCtx(()=>Q[5]||(Q[5]=[e.createTextVNode(" 修改 ")])),_:1,__:[5]})]),e.createElementVNode("div",$u,[Q[8]||(Q[8]=e.createElementVNode("h4",{class:"module-title"},"详情数据配置",-1)),e.createVNode(se,{id:"themeButton",onClick:Q[2]||(Q[2]=_e=>ce())},{default:e.withCtx(()=>Q[7]||(Q[7]=[e.createTextVNode(" 修改 ")])),_:1,__:[7]})])]),e.createVNode(Xt.ssDialog,{visible:d.visible,title:d.title,onBeforeDestroy:Be,width:d.width},{default:e.withCtx(()=>[e.createElementVNode("div",ju,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:c.value,key:c.value,isEnableWrap:!0,onChange:D},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Uu,[e.createVNode(se,{class:"cancel-button button",onClick:Be,id:"themeBorderButton"},{default:e.withCtx(()=>Q[9]||(Q[9]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[9]}),e.createVNode(se,{class:"ok-button button",onClick:C,id:"themeButton"},{default:e.withCtx(()=>Q[10]||(Q[10]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[10]})])]),_:1},8,["visible","title","width"]),e.createVNode(Xt.ssDialog,{visible:F.visible,title:F.title,onBeforeDestroy:Be,width:F.width},{default:e.withCtx(()=>[e.createElementVNode("div",Ku,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:R.value,key:R.value,isEnableWrap:!0,onChange:K},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",Wu,[e.createVNode(se,{class:"cancel-button button",onClick:Be,id:"themeBorderButton"},{default:e.withCtx(()=>Q[11]||(Q[11]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[11]}),e.createVNode(se,{class:"ok-button button",onClick:Be,id:"themeButton"},{default:e.withCtx(()=>Q[12]||(Q[12]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[12]})])]),_:1},8,["visible","title","width"]),e.createVNode(Xt.ssDialog,{visible:G.visible,title:G.title,onBeforeDestroy:Be,width:G.width},{default:e.withCtx(()=>[e.createElementVNode("div",Hu,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:b.value,key:b.value,isEnableWrap:!0,onChange:h},null,8,["rowContents"]))])]),footer:e.withCtx(()=>[e.createElementVNode("div",qu,[e.createVNode(se,{class:"cancel-button button",onClick:Be,id:"themeBorderButton"},{default:e.withCtx(()=>Q[13]||(Q[13]=[e.createTextVNode(e.toDisplayString("取消"))])),_:1,__:[13]}),e.createVNode(se,{class:"ok-button button",onClick:Be,id:"themeButton"},{default:e.withCtx(()=>Q[14]||(Q[14]=[e.createTextVNode(e.toDisplayString("确认"))])),_:1,__:[14]})])]),_:1},8,["visible","title","width"])],64)}}}),Xu=Rt._export_sfc(Gu,[["__scopeId","data-v-fe119645"]]),Yu=(a,l)=>{let s;a.replaceAll(" ",`\r
|
|
2
|
+
`).replaceAll(`
|
|
3
|
+
`,`\r
|
|
4
|
+
`).includes(`\r
|
|
5
|
+
`)?s=a.replaceAll(`
|
|
6
|
+
`,`\r
|
|
7
|
+
`).replaceAll(" ",`\r
|
|
8
|
+
`).split(`\r
|
|
9
|
+
`).filter(c=>c.trim()!==""):s=a.replaceAll(" ",`\r
|
|
10
|
+
`).split(`
|
|
11
|
+
`).filter(c=>c.trim()!==""),s=s==null?void 0:s.map(c=>(c=c==null?void 0:c.replaceAll("\r",""),c));const r=[];let d="";for(const c of s)c.includes("{")||d.includes("{")||c.includes("[")||d.includes("[")||c.includes("【")||d.includes("【")||c.includes("(")||d.includes("(")||c.includes("(")||d.includes("(")||c.includes("/*")||d.includes("/*")?(d+=c.trim(),d.split("{").length-1===d.split("}").length-1&&d.split("【").length-1===d.split("】").length-1&&d.split("[").length-1===d.split("]").length-1&&d.split("(").length-1===d.split(")").length-1&&d.split("(").length-1===d.split(")").length-1&&d.split("/*").length-1===d.split("*/").length-1&&!(l!=null&&l.find(w=>w===d[d.length-1]))?(r.push(d.replace(/\/\*[\s\S]*?\*\//g,"")),d=""):d!=null&&d.includes("*/")&&(d=d.replace(/\/\*[\s\S]*?\*\//g,""))):l!=null&&l.find(w=>w===c[c.length-1])?d+=c.trim():r.push(c.trim().replace(/\/\*[\s\S]*?\*\//g,""));return r},fo=(a,l)=>{let s=a;const r=[];let d="",c=0;for(const w of s)c++,w.includes("{")||d.includes("{")||w.includes("[")||d.includes("[")||w.includes("【")||d.includes("【")||w.includes("(")||d.includes("(")||w.includes("(")||d.includes("(")||w.includes("/*")||d.includes("/*")?(d+=w.trim(),d.split("{").length-1===d.split("}").length-1&&d.split("【").length-1===d.split("】").length-1&&d.split("[").length-1===d.split("]").length-1&&d.split("(").length-1===d.split(")").length-1&&d.split("(").length-1===d.split(")").length-1&&d.split("/*").length-1===d.split("*/").length-1&&d[d.length-1]===l?(r.push(d.replace(/\/\*[\s\S]*?\*\//g,"")),d=""):c===(a==null?void 0:a.length)&&(r.push(d.replace(/\/\*[\s\S]*?\*\//g,"")),d="")):(d+=w.trim(),(d==null?void 0:d[(d==null?void 0:d.length)-1])===l&&(r.push(d.replace(/\/\*[\s\S]*?\*\//g,"")),d=""));return(d==null?void 0:d.length)!==0&&r.push(d.replace(/\/\*[\s\S]*?\*\//g,"")),r},Ju=(a,l)=>a===l||a.length===l.length&&a.every((s,r)=>s===l[r]),Zu=a=>a.reduce((l,s)=>{var d;const r=(((d=l.at(-1))==null?void 0:d.total)??0)+s;return l.push({key:s,total:r}),l},[]),Qu=a=>{for(let l=a.length-1;l>0;l--){const s=Math.floor(Math.random()*(l+1));[a[l],a[s]]=[a[s],a[l]]}return a};let qt="$R";const ed=Ie.useUnit(x.pinia),{chooseTitle:ia}=x.storeToRefs(ed),da=[{key:"@MaxRow",value:"onNumSlice",order:1},{key:"@Type",value:"onRandomContents",order:2},{key:"@Filter",value:"onConditionContents",order:4},{key:"@FatherSync",value:"onFatherPaceContents",order:1},{key:"@SonSync",value:"onPaceContents",order:1},{key:"@MultiLead",value:"onMainTagContents",order:3},{key:"@ProButton",value:"onButtonContents",order:1},{key:"@PamButton",value:"onPamButtonContents",order:1},{key:"@RowButton",value:"onRowButtonContents",order:1},{key:"@Related",value:"onRelated",order:1}],td=a=>{var s;return(a==null?void 0:a.filter.toUpperCase())==="ALL"||(a==null?void 0:a.filter.toUpperCase())==="NONE"?a==null?void 0:a.contents:(s=a==null?void 0:a.contents)==null?void 0:s.map(r=>{var d;return(r==null?void 0:r.key)==="tableContents"&&(r.contents=(d=r.contents)==null?void 0:d.slice(0,parseInt(a==null?void 0:a.filter))),r})},nd=a=>{var l;return(a==null?void 0:a.filter)==="Random"?(l=a==null?void 0:a.contents)==null?void 0:l.map(r=>((r==null?void 0:r.key)==="tableContents"&&(r.contents=Qu(r.contents)),r)):a==null?void 0:a.contents},ad=a=>{var r,d,c,w,v;let l=(c=(d=(r=a==null?void 0:a.filter)==null?void 0:r.replace("*",""))==null?void 0:d.replaceAll("{",""))==null?void 0:c.replaceAll("}","");if((l==null?void 0:l[0])!=="("&&(l="("+l+")"),l.slice(1,(l==null?void 0:l.length)-1)==="undefined")return a==null?void 0:a.contents;let s=Ie.calculatorAndToOr(l);if((s==null?void 0:s.length)>0){let f=[];return s==null||s.forEach(C=>{let F={};for(let R in C){let H=R;H!=null&&H.includes("[")||(F[H]=C[R])}f.push(F)}),(v=(w=x.cloneDeep(a))==null?void 0:w.contents)==null?void 0:v.map(C=>{var R,H,M,ve;let F=(M=(H=(R=x.cloneDeep(a))==null?void 0:R.contents)==null?void 0:H.find(K=>(K==null?void 0:K.key)==="header"))==null?void 0:M.contents;if(F=(ve=Ie.getEqualChild(F))==null?void 0:ve.filter(K=>(K==null?void 0:K.label)!=="操作"),(C==null?void 0:C.key)==="tableContents"){let O=Ie.tableToForm(C==null?void 0:C.contents,F);f==null||f.forEach(G=>{var b,E;for(let y in G)!((b=O==null?void 0:O[0])!=null&&b.find(B=>{var h;return(B==null?void 0:B.key)===y||((h=B==null?void 0:B.key)==null?void 0:h.includes(y))}))&&!(O!=null&&O.find(B=>{var h;return(B==null?void 0:B.key)===y||((h=B==null?void 0:B.key)==null?void 0:h.includes(y))}))||(((E=G[y])==null?void 0:E[0])!=="!"?O=O==null?void 0:O.filter(B=>{var h,ce;return((h=B==null?void 0:B.find(Ne=>{var nt;return(Ne==null?void 0:Ne.key)===y||((nt=Ne==null?void 0:Ne.key)==null?void 0:nt.includes(y))}))==null?void 0:h.value)===G[y]&&!Array.isArray(G==null?void 0:G[y])||Array.isArray(G==null?void 0:G[y])&&((ce=G==null?void 0:G[y])==null?void 0:ce.find(Ne=>{var nt;return((nt=B==null?void 0:B.find(xe=>{var Re;return(xe==null?void 0:xe.key)===y||((Re=xe==null?void 0:xe.key)==null?void 0:Re.includes(y))}))==null?void 0:nt.value)===Ne}))}):O=O==null?void 0:O.filter(B=>{var h;return((h=B==null?void 0:B.find(ce=>{var Ne;return(ce==null?void 0:ce.key)===y||((Ne=ce==null?void 0:ce.key)==null?void 0:Ne.includes(y))}))==null?void 0:h.value)!==G[y]}))}),(O==null?void 0:O.length)===0?C.contents=[]:C.contents=O==null?void 0:O.map(G=>{let b={};return G==null||G.forEach(E=>{b[E==null?void 0:E.key]=E==null?void 0:E.value}),b})}return C})}return a==null?void 0:a.contents},od=a=>a==null?void 0:a.contents,rd=a=>a==null?void 0:a.contents,ld=a=>a==null?void 0:a.contents,id=a=>a==null?void 0:a.contents,sd=a=>a==null?void 0:a.contents,cd=a=>a==null?void 0:a.contents,ud=async a=>{var l,s,r,d,c,w,v,f,D,C,F;if((a==null?void 0:a.filter)==="true"){let R=await Xa((s=(l=ia==null?void 0:ia.value)==null?void 0:l[0])==null?void 0:s.parentContent,!1),H=(d=(r=ia==null?void 0:ia.value)==null?void 0:r[0])==null?void 0:d.value;R=(c=R==null?void 0:R[0])==null?void 0:c.compData;let M=(w=R==null?void 0:R.find(O=>(O==null?void 0:O.key)==="header"))==null?void 0:w.contents;M=((v=M==null?void 0:M.find(O=>O==null?void 0:O.isMainKey))==null?void 0:v.prop)??((f=M==null?void 0:M[0])==null?void 0:f.prop);let ve=(C=(D=R==null?void 0:R.find(O=>(O==null?void 0:O.key)==="tableContents"))==null?void 0:D.contents)==null?void 0:C.find(O=>(O==null?void 0:O[M])===H);return(F=a==null?void 0:a.contents)==null?void 0:F.map(O=>{var G;return(O==null?void 0:O.key)==="formContent"&&(O.contents=(G=O.contents)==null?void 0:G.map(b=>(b.value=ve==null?void 0:ve[b==null?void 0:b.prop],b))),O})}return a==null?void 0:a.contents},xr={onNumSlice:td,onRandomContents:nd,onConditionContents:ad,onFatherPaceContents:od,onPaceContents:rd,onMainTagContents:ld,onButtonContents:id,onPamButtonContents:sd,onRowButtonContents:cd,onRelated:ud},dd=async a=>{var d,c,w,v,f,D,C,F,R,H,M,ve,K,O,G,b,E,y,B;let l="";if(((d=a==null?void 0:a.find(h=>(h==null?void 0:h.key)==="filter"))==null?void 0:d.contents)!==""&&(l=(c=a==null?void 0:a.find(h=>(h==null?void 0:h.key)==="filter"))==null?void 0:c.contents),l===""||!l)return a;(l==null?void 0:l[0])==="("?l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1):(l=(v=(w=l==null?void 0:l.replace("(",qt))==null?void 0:w.split(qt))==null?void 0:v[1],l=l==null?void 0:l.slice(0,(l==null?void 0:l.length)-1));let s=(f=fo(l,","))==null?void 0:f.map(h=>((h==null?void 0:h[(h==null?void 0:h.length)-1])===","&&(h=h==null?void 0:h.slice(0,(h==null?void 0:h.length)-1)),h!=null&&h.includes("(")||(h=h==null?void 0:h.replaceAll(":","=")),h)),r=a;for(let h in s){let ce,Ne="";(D=s==null?void 0:s[h])!=null&&D.includes("(")?(ce=(R=(F=(C=s==null?void 0:s[h])==null?void 0:C.replace("(",qt))==null?void 0:F.split(qt))==null?void 0:R[0],Ne="("+((ve=(M=(H=s==null?void 0:s[h])==null?void 0:H.replace("(",qt))==null?void 0:M.split(qt))==null?void 0:ve[1])):(ce=(G=(O=(K=s==null?void 0:s[h])==null?void 0:K.replace("=",qt))==null?void 0:O.split(qt))==null?void 0:G[0],Ne=(y=(E=(b=s==null?void 0:s[h])==null?void 0:b.replace("=",qt))==null?void 0:E.split(qt))==null?void 0:y[1]);let nt=(B=da==null?void 0:da.find(xe=>(xe==null?void 0:xe.key)===ce))==null?void 0:B.value;if(nt){const xe=xr[nt];await new Function("return ")(),r=xe({contents:r,filter:Ne})}}return r},pd=async a=>{var d,c,w,v,f,D,C,F,R,H,M,ve,K,O,G,b,E,y,B;let l="";if(((d=a==null?void 0:a.find(h=>(h==null?void 0:h.key)==="filter"))==null?void 0:d.contents)!==""&&(l=(c=a==null?void 0:a.find(h=>(h==null?void 0:h.key)==="filter"))==null?void 0:c.contents),l==="")return a;(l==null?void 0:l[0])==="("?l=l==null?void 0:l.slice(1,(l==null?void 0:l.length)-1):(l=(v=(w=l==null?void 0:l.replace("(",qt))==null?void 0:w.split(qt))==null?void 0:v[1],l=l==null?void 0:l.slice(0,(l==null?void 0:l.length)-1));let s=(f=fo(l,","))==null?void 0:f.map(h=>((h==null?void 0:h[(h==null?void 0:h.length)-1])===","&&(h=h==null?void 0:h.slice(0,(h==null?void 0:h.length)-1)),h!=null&&h.includes("(")||(h=h==null?void 0:h.replaceAll(":","=")),h)),r=a;for(let h in s){let ce,Ne="";(D=s==null?void 0:s[h])!=null&&D.includes("(")?(ce=(R=(F=(C=s==null?void 0:s[h])==null?void 0:C.replace("(",qt))==null?void 0:F.split(qt))==null?void 0:R[0],Ne="("+((ve=(M=(H=s==null?void 0:s[h])==null?void 0:H.replace("(",qt))==null?void 0:M.split(qt))==null?void 0:ve[1])):(ce=(G=(O=(K=s==null?void 0:s[h])==null?void 0:K.replace("=",qt))==null?void 0:O.split(qt))==null?void 0:G[0],Ne=(y=(E=(b=s==null?void 0:s[h])==null?void 0:b.replace("=",qt))==null?void 0:E.split(qt))==null?void 0:y[1]);let nt=(B=da==null?void 0:da.find(xe=>(xe==null?void 0:xe.key)===ce))==null?void 0:B.value;if(nt){const xe=xr[nt];await new Function("return ")(),r=xe({contents:r,filter:Ne})}}return r},fd=x.useLoginState(x.pinia),{loginUserInfo:Dn}=x.storeToRefs(fd),hd=x.useMenuState(x.pinia),{activeMenuPath:Ao}=x.storeToRefs(hd),ro=Ie.useUnit(x.pinia),{selectTitle:eo}=x.storeToRefs(ro),vd=async(a,l)=>{var w,v,f,D,C,F,R,H,M,ve,K,O,G;let s=Ao.value,r="",d=((w=eo==null?void 0:eo.value)==null?void 0:w.find(b=>(b==null?void 0:b.condition)==="child"))??void 0;ro.setSelectTitle([]),(a==null?void 0:a.length)===0||(s=l?s:(v=a==null?void 0:a[0])==null?void 0:v.object_name,r=(f=a==null?void 0:a[0])==null?void 0:f.father_name);let c=[];if(r!==""){let b=r;(b==null?void 0:b[(b==null?void 0:b.length)-1])==="/"&&(b=b==null?void 0:b.slice(0,(b==null?void 0:b.length)-1));let E=await Xa(b,!1);E=(D=E==null?void 0:E[0])==null?void 0:D.compData;let y=(C=E==null?void 0:E.find(h=>(h==null?void 0:h.key)==="header"))==null?void 0:C.contents;y=((F=y==null?void 0:y.find(h=>h==null?void 0:h.isMainKey))==null?void 0:F.prop)??((R=y==null?void 0:y[0])==null?void 0:R.prop);let B=(M=(H=E==null?void 0:E.find(h=>(h==null?void 0:h.key)==="tableContents"))==null?void 0:H.contents)==null?void 0:M.map(h=>({label:h==null?void 0:h[y],value:h==null?void 0:h[y]}));c=(ve=r==null?void 0:r.split("/"))==null?void 0:ve.map(h=>(h===""?d?(d.isShow=!0,h=d):h={value:h,condition:"child",options:B,parentContent:(r==null?void 0:r[(r==null?void 0:r.length)-1])==="/"?r==null?void 0:r.slice(0,(r==null?void 0:r.length)-1):r,isShow:!0}:h={condition:"parent",value:h.trim(),isShow:!0},h))}if(s!==""){let b=(K=s==null?void 0:s.split("/"))==null?void 0:K.map(E=>(E={condition:"normal",value:E.trim(),isShow:!0},E));((O=b==null?void 0:b[0])==null?void 0:O.value)===((G=c==null?void 0:c[0])==null?void 0:G.value)&&(b=b==null?void 0:b.filter((E,y)=>y!==0)),c=[...c,...b]}r===""&&d&&((d==null?void 0:d.parentContent)!==Ao.value&&(d.isShow=!1),(d==null?void 0:d.value)!==""&&c.push(d)),ro.setSelectTitle(c)},Vo=async a=>{let l=[],s=a==null?void 0:a.map(async r=>{var v,f,D,C,F,R,H,M,ve,K,O,G,b,E,y,B,h,ce,Ne,nt,xe,Re,Pe,P,re,ne,pe,We,at,X;let d=(C=(D=(f=(v=r==null?void 0:r.contents)==null?void 0:v.find(V=>{var te;return(te=V==null?void 0:V.key)==null?void 0:te.includes("struct")}))==null?void 0:f.value)==null?void 0:D[0])==null?void 0:C.类型,c=Object.values(r==null?void 0:r.name);c=c==null?void 0:c.reverse();let w={comp:d,isShow:!0,name:c==null?void 0:c[0],id:r==null?void 0:r.object_id};for(let V in c)parseInt(V)>=1&&(w[`name${parseInt(V)-1}`]=c[V]);if(d==="Table"){let V=(F=r==null?void 0:r.contents)==null?void 0:F.find(ue=>{var Ce;return(Ce=ue==null?void 0:ue.key)==null?void 0:Ce.includes("content")}),te=[];V.value=(R=V==null?void 0:V.value)==null?void 0:R.sort((ue,Ce)=>parseInt(ue)-parseInt(Ce)),te.push({key:"tableContents",contents:V==null?void 0:V.value});let ye=(O=(K=(ve=(M=(H=r==null?void 0:r.contents)==null?void 0:H.find(ue=>{var Ce;return(Ce=ue==null?void 0:ue.key)==null?void 0:Ce.includes("struct")}))==null?void 0:M.value)==null?void 0:ve[0])==null?void 0:K.结构)==null?void 0:O.contents;te.push({key:"header",contents:ye}),te.push({key:"filter",contents:(B=(y=(E=(b=(G=r==null?void 0:r.contents)==null?void 0:G.find(ue=>{var Ce;return(Ce=ue==null?void 0:ue.key)==null?void 0:Ce.includes("struct")}))==null?void 0:b.value)==null?void 0:E[0])==null?void 0:y.引用)==null?void 0:B.contents}),w.compData=await pd(te)}else if(d==="Form"){let V=[],te=(Ne=(ce=(h=r==null?void 0:r.contents)==null?void 0:h.find(ue=>{var Ce;return(Ce=ue==null?void 0:ue.key)==null?void 0:Ce.includes("content")}))==null?void 0:ce.value)==null?void 0:Ne[0],ye=(re=(P=(Pe=(Re=(xe=(nt=r==null?void 0:r.contents)==null?void 0:nt.find(ue=>{var Ce;return(Ce=ue==null?void 0:ue.key)==null?void 0:Ce.includes("struct")}))==null?void 0:xe.value)==null?void 0:Re[0])==null?void 0:Pe.结构)==null?void 0:P.contents)==null?void 0:re.map(ue=>(ue.value=te==null?void 0:te[ue==null?void 0:ue.prop],ue));V.push({key:"filter",contents:(X=(at=(We=(pe=(ne=r==null?void 0:r.contents)==null?void 0:ne.find(ue=>{var Ce;return(Ce=ue==null?void 0:ue.key)==null?void 0:Ce.includes("struct")}))==null?void 0:pe.value)==null?void 0:We[0])==null?void 0:at.引用)==null?void 0:X.contents}),V.push({key:"formContent",contents:ye}),w.compData=await dd(V)}return w});return l=await Promise.all(s),l},Xa=async(a,l,s={})=>{var w,v,f,D,C,F,R,H,M,ve,K;let r=await ua.getPageDataApi({platId:parseInt((w=Dn==null?void 0:Dn.value)==null?void 0:w.plat_id),pageName:a}),d=(v=r==null?void 0:r.data)==null?void 0:v.result;if((d==null?void 0:d.length)===0&&(s!=null&&s.originPath)&&(s==null?void 0:s.originPath)!==a){let O=await ua.getPageDataApi({platId:parseInt((f=Dn==null?void 0:Dn.value)==null?void 0:f.plat_id),pageName:s==null?void 0:s.originPath});if(((C=(D=O==null?void 0:O.data)==null?void 0:D.result)==null?void 0:C.length)>0){let G=await Vo((F=O==null?void 0:O.data)==null?void 0:F.result);G=G==null?void 0:G.map(E=>{var h,ce,Ne,nt,xe,Re,Pe,P,re,ne,pe,We,at,X,V;let y=[],B=(h=Object.keys(E))==null?void 0:h.filter(te=>te==null?void 0:te.includes("name"));for(let te in E)B!=null&&B.find(ye=>ye===te)&&y.push(E==null?void 0:E[te]);if(y=y.reverse(),(E==null?void 0:E.comp)==="Table")E={filter:(Ne=(ce=E==null?void 0:E.compData)==null?void 0:ce.find(te=>(te==null?void 0:te.key)==="filter"))==null?void 0:Ne.contents,key:E==null?void 0:E.comp,name:y,tableColumns:(xe=(nt=E==null?void 0:E.compData)==null?void 0:nt.find(te=>(te==null?void 0:te.key)==="header"))==null?void 0:xe.contents,tableContents:(Pe=(Re=E==null?void 0:E.compData)==null?void 0:Re.find(te=>(te==null?void 0:te.key)==="tableContents"))==null?void 0:Pe.contents};else{let te=(ne=(re=(P=E==null?void 0:E.compData)==null?void 0:P.find(ue=>(ue==null?void 0:ue.key)==="formContent"))==null?void 0:re.contents)==null?void 0:ne.map(ue=>(ue==null?void 0:ue.value)??"");te=[te];let ye=(at=(We=(pe=E==null?void 0:E.compData)==null?void 0:pe.find(ue=>(ue==null?void 0:ue.key)==="formContent"))==null?void 0:We.contents)==null?void 0:at.map(ue=>(ue.value="",ue));E={contents:te,filter:(V=(X=E==null?void 0:E.compData)==null?void 0:X.find(ue=>(ue==null?void 0:ue.key)==="filter"))==null?void 0:V.contents,key:E==null?void 0:E.comp,name:y,value:ye}}return E});let b=[{key:"menuPath",contents:[{path:a,fatherPath:(M=(H=(R=O==null?void 0:O.data)==null?void 0:R.result)==null?void 0:H[0])==null?void 0:M.father_name,isShow:!1}]},{key:a,contents:G}];await ua.createPlatFormDataApi({platId:parseInt((ve=Dn==null?void 0:Dn.value)==null?void 0:ve.plat_id),changeData:b}),d=(K=O==null?void 0:O.data)==null?void 0:K.result}}return l&&await vd(d,!!(s!=null&&s.originPath)),await Vo(d)};var za={exports:{}},md=za.exports,Oo;function gd(){return Oo||(Oo=1,function(a,l){(function(s,r){r()})(md,function(){function s(D,C){return typeof C>"u"?C={autoBom:!1}:typeof C!="object"&&(console.warn("Deprecated: Expected third argument to be a object"),C={autoBom:!C}),C.autoBom&&/^\s*(?:text\/\S*|application\/xml|\S*\/\S*\+xml)\s*;.*charset\s*=\s*utf-8/i.test(D.type)?new Blob(["\uFEFF",D],{type:D.type}):D}function r(D,C,F){var R=new XMLHttpRequest;R.open("GET",D),R.responseType="blob",R.onload=function(){f(R.response,C,F)},R.onerror=function(){console.error("could not download file")},R.send()}function d(D){var C=new XMLHttpRequest;C.open("HEAD",D,!1);try{C.send()}catch{}return 200<=C.status&&299>=C.status}function c(D){try{D.dispatchEvent(new MouseEvent("click"))}catch{var C=document.createEvent("MouseEvents");C.initMouseEvent("click",!0,!0,window,0,0,0,80,20,!1,!1,!1,!1,0,null),D.dispatchEvent(C)}}var w=typeof window=="object"&&window.window===window?window:typeof self=="object"&&self.self===self?self:typeof Ie.commonjsGlobal=="object"&&Ie.commonjsGlobal.global===Ie.commonjsGlobal?Ie.commonjsGlobal:void 0,v=w.navigator&&/Macintosh/.test(navigator.userAgent)&&/AppleWebKit/.test(navigator.userAgent)&&!/Safari/.test(navigator.userAgent),f=w.saveAs||(typeof window!="object"||window!==w?function(){}:"download"in HTMLAnchorElement.prototype&&!v?function(D,C,F){var R=w.URL||w.webkitURL,H=document.createElement("a");C=C||D.name||"download",H.download=C,H.rel="noopener",typeof D=="string"?(H.href=D,H.origin===location.origin?c(H):d(H.href)?r(D,C,F):c(H,H.target="_blank")):(H.href=R.createObjectURL(D),setTimeout(function(){R.revokeObjectURL(H.href)},4e4),setTimeout(function(){c(H)},0))}:"msSaveOrOpenBlob"in navigator?function(D,C,F){if(C=C||D.name||"download",typeof D!="string")navigator.msSaveOrOpenBlob(s(D,F),C);else if(d(D))r(D,C,F);else{var R=document.createElement("a");R.href=D,R.target="_blank",setTimeout(function(){c(R)})}}:function(D,C,F,R){if(R=R||open("","_blank"),R&&(R.document.title=R.document.body.innerText="downloading..."),typeof D=="string")return r(D,C,F);var H=D.type==="application/octet-stream",M=/constructor/i.test(w.HTMLElement)||w.safari,ve=/CriOS\/[\d]+/.test(navigator.userAgent);if((ve||H&&M||v)&&typeof FileReader<"u"){var K=new FileReader;K.onloadend=function(){var b=K.result;b=ve?b:b.replace(/^data:[^;]*;/,"data:attachment/file;"),R?R.location.href=b:location=b,R=null},K.readAsDataURL(D)}else{var O=w.URL||w.webkitURL,G=O.createObjectURL(D);R?R.location=G:location.href=G,R=null,setTimeout(function(){O.revokeObjectURL(G)},4e4)}});w.saveAs=f.saveAs=f,a.exports=f})}(za)),za.exports}gd();const La=e.defineAsyncComponent(()=>Promise.resolve().then(()=>require("./index-BHaaYQfC.cjs")).then(a=>a.index));La.install=a=>{a.component("ssMenu",La)};const wr={__name:"index",props:{name:String},setup(a){const l=a,s=e.computed(()=>lt.ElIcons[l.name]);return e.onMounted(()=>{}),(r,d)=>{const c=e.resolveComponent("el-icon");return e.openBlock(),e.createBlock(c,null,{default:e.withCtx(()=>[(e.openBlock(),e.createBlock(e.resolveDynamicComponent(s.value)))]),_:1})}}},Cr=(a,l,s=0)=>{let r=a;return r!=null&&r.every(d=>Array.isArray(d))&&(r!=null&&r.every(d=>Array.isArray(d)&&d.length===1)?r=r==null?void 0:r.filter(d=>(d==null?void 0:d[0])!==(l==null?void 0:l[s])):r=r==null?void 0:r.map(d=>{if(d!=null&&d.find(c=>c===(l==null?void 0:l[s]))&&(l==null?void 0:l.length)!==1){let c=x.cloneDeep(l),w=d==null?void 0:d.filter(C=>C!==(c==null?void 0:c[s])),v=s+1,f=Cr(w,c,v),D=[];D.push(d==null?void 0:d[0]),f==null||f.forEach(C=>{D.push(C)}),d=D}return d})),r},Dr=(a,l,s,r=0)=>{let d=a;return d!=null&&d.every(c=>Array.isArray(c))&&(d!=null&&d.every(c=>Array.isArray(c)&&c.length===1)?d.push([s]):d=d==null?void 0:d.map(c=>{if(c!=null&&c.find(w=>w===(l==null?void 0:l[r]))&&(l==null?void 0:l.length)!==1){let w=x.cloneDeep(l),v=c==null?void 0:c.filter(F=>F!==(w==null?void 0:w[r])),f=r+1,D=Dr(v,w,s,f),C=[];C.push(c==null?void 0:c[0]),D==null||D.forEach(F=>{C.push(F)}),c=C}return c})),d},_r=(a,l,s,r,d=0)=>{let c=a;return c!=null&&c.every(w=>Array.isArray(w))&&(c!=null&&c.every(w=>Array.isArray(w)&&w.length===1)?c=c==null?void 0:c.map(w=>((w==null?void 0:w[0])===s&&(w=[r]),w)):c=c==null?void 0:c.map(w=>{if(w!=null&&w.find(v=>v===(l==null?void 0:l[d]))&&(l==null?void 0:l.length)!==1){let v=x.cloneDeep(l),f=w==null?void 0:w.filter(R=>R!==(v==null?void 0:v[d])),D=d+1,C=_r(f,v,s,r,D),F=[];F.push(w==null?void 0:w[0]),C==null||C.forEach(R=>{F.push(R)}),w=F}return w})),c};function Er(a="menu"){return{name:a,components:{SvgIcon:Rl.SvgIcon,ssMenu:La,DynamicIcon:wr,ssDialog:Xt.ssDialog,ssInput:Bt._sfc_main$2},setup(l,{emit:s}){const r=e.defineProps({mode:{type:String,default:"vertical"}}),d=e.ref([{allowInherit:!1,operateType:"复制新增",operateIcon:"CopyAddMenu"},{allowInherit:!1,operateType:"删除",operateIcon:"DeleteMenu"},{allowInherit:!1,operateType:"修改菜单名",operateIcon:"FixedMenu"}]),c=x.useMenuState(),w=x.useModelComp(x.pinia),v=x.useLoginState(x.pinia),{loginUserInfo:f}=x.storeToRefs(v),D=e.ref(0),C=Pl.useRouter(),F=e.ref(),{asideMenus:R,menuTriggerType:H,platform:M}=x.storeToRefs(c),{fixMenuStatus:ve}=x.storeToRefs(w),K=e.computed(()=>r==null?void 0:r.mode),O=ae=>ae==null?void 0:ae.map(N=>{var Ge,Xe;return!(N!=null&&N.children)||((Ge=N==null?void 0:N.children)==null?void 0:Ge.length)===0?N.config=d.value:N!=null&&N.children&&((Xe=N==null?void 0:N.children)==null?void 0:Xe.length)>0&&(N.children=O(N.children)),N}),G=e.computed(()=>{let ae=[...R.value];if((ae==null?void 0:ae.length)===0)return C.push("/"),[];const De=ce(ae,h.value);return De.isFlag||(ae=De==null?void 0:De.data),ae=ae==null?void 0:ae.map(N=>{var Ge,Xe;return!(N!=null&&N.children)||((Ge=N==null?void 0:N.children)==null?void 0:Ge.length)===0?N.config=d.value:N!=null&&N.children&&((Xe=N==null?void 0:N.children)==null?void 0:Xe.length)>0&&(N.children=O(N.children)),N}),ae}),b=async(ae,De)=>{w.setRouteToChildPath(""),c.setMenuTriggerType("click"),c.setActiveMenuPath(ae==null?void 0:ae.path),c.setActiveAsideMenu(ae),ae.isRouter?C.push(ae.path):C.push("/"),s("node-click",ae,De)},E=async ae=>{const De=Ll.findNodeByPropInTree(G.value,"path",ae);c.setActiveAsideMenu(De),w.setRouteToChildPath(""),ve.value?w.setFixMenuStatus(!1):(Ce.value&&(H.value="open"),H.value==="click"?D.value===1?c.setActiveMenuPath(sessionStorage.getItem("pageKey")):c.setActiveMenuPath(ae):Ce.value||(c.setMenuTriggerType("click"),c.setActiveMenuPath(ae))),ae!=null&&ae.startsWith("/")?C.push(ae):C.push("/"),D.value++},y=ae=>{Ce.value||c.setActiveMenuPath(ae)},B=ae=>{const De=document.documentElement;ae==null||ae.forEach(N=>{De.style.setProperty(N.name,N.value)})};e.onMounted(()=>{D.value=1});const h=e.computed(()=>{const ae=sessionStorage.getItem("authority");return ae?JSON.parse(ae):[]});e.watch(()=>M.value,ae=>{ae==="browser"?B(ya.browserVerticalMenuClasses):ae==="client"?(B(ya.clientHorizontalMenuClasses),B(ya.clientVerticalMenuClasses)):ae==="three"&&(B(ya.threeHorizontalMenuClasses),B(ya.threeVerticalMenuClasses))},{immediate:!0});const ce=(ae,De)=>({isFlag:!0}),Ne=e.reactive({show:!1,title:"菜单配置",width:"30%",type:"create"}),nt=ae=>aa(ae),xe=e.ref({}),Re=e.ref([]),Pe=e.ref({}),P=e.ref({}),re=ae=>{switch(ae){case"复制新增":return"create";case"修改菜单名":return"update";case"删除":return"delete"}},ne=e.ref({}),pe=ae=>{c.setCacheInputMenu({type:Ne.type,data:ae}),c.setIsRefreshMenus(!0)},We=async(ae,De,N)=>{var Ge,Xe,Be,le,Q,se,_e,He,dt,m,T,U,J,_,oe,Ae,I,ee,$,W,Ee,ie,q,Z,de,me,we,be,j,Oe,ge,je,ot,Le,tt,Te,mt,Qe,Ve,it,gt,Ye;if(De==="create"){let $e=(N==null?void 0:N.title)+"(1)",It=await lt.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:"menu"}}),Se=(Xe=(Ge=It==null?void 0:It.data)==null?void 0:Ge.result)==null?void 0:Xe[0],qe=(Be=Se==null?void 0:Se.value)==null?void 0:Be.pageData;qe.compData=(le=qe.compData)==null?void 0:le.map(S=>{var fe;return(S==null?void 0:S.key)==="menuContents"&&(S.contents=Dr(S.contents,(fe=N==null?void 0:N.path)==null?void 0:fe.split("/"),$e)),S}),await lt.updateInsofDataApi({id:Se==null?void 0:Se.id,value:{pageData:qe}});let ze=(se=(Q=N==null?void 0:N.path)==null?void 0:Q.split("/"))==null?void 0:se.filter((S,fe)=>{var Ue,he;return fe!==((he=(Ue=N==null?void 0:N.path)==null?void 0:Ue.split("/"))==null?void 0:he.length)-1}),Je=await Ie.getItemData((dt=(He=(_e=N==null?void 0:N.path)==null?void 0:_e.split("/"))==null?void 0:He.filter((S,fe)=>{var Ue,he;return fe!==((he=(Ue=N==null?void 0:N.path)==null?void 0:Ue.split("/"))==null?void 0:he.length)-1}))==null?void 0:dt.join("/"),sessionStorage.getItem("systemKey"),"");if(ze.push($e),ze=ze==null?void 0:ze.join("/"),(Je==null?void 0:Je.length)>0){let S=Je==null?void 0:Je[0],fe=(T=(m=S==null?void 0:S.compData)==null?void 0:m.find(Ue=>(Ue==null?void 0:Ue.key)==="header"))==null?void 0:T.contents;if(((U=fe==null?void 0:fe[0])==null?void 0:U.directiveLabel)==="#isMain"){let Ue=(J=fe==null?void 0:fe[0])==null?void 0:J.prop,he=(oe=(_=S==null?void 0:S.compData)==null?void 0:_.find(st=>(st==null?void 0:st.key)==="tableContents"))==null?void 0:oe.contents,ut;he==null||he.forEach(st=>{var xt,pt;if(st.length===1)((xt=st==null?void 0:st[0])==null?void 0:xt[Ue])===(N==null?void 0:N.title)&&(ut=st==null?void 0:st[0],ut[Ue]=$e);else{let ct=(pt=fe==null?void 0:fe.filter(Tt=>Tt!=="操作"))==null?void 0:pt.map(Tt=>Tt==null?void 0:Tt.prop),ft=st==null?void 0:st.filter(Tt=>!(Tt!=null&&Tt.id)),wt=Ie.getValueToObjectValue(ft,ct);wt[Ue]=$e,ut=wt}}),await lt.createInsofDataApi({key:{type:"data",pageKey:(ee=(I=(Ae=N==null?void 0:N.path)==null?void 0:Ae.split("/"))==null?void 0:I.filter((st,xt)=>{var pt,ct;return xt!==((ct=(pt=N==null?void 0:N.path)==null?void 0:pt.split("/"))==null?void 0:ct.length)-1}))==null?void 0:ee.join("/"),tableId:S==null?void 0:S.id,systemKey:sessionStorage.getItem("systemKey"),createUserId:($=f.value)==null?void 0:$.id,createUserLayer:((W=f.value)==null?void 0:W.dept)||((Ee=f.value)==null?void 0:Ee.部门名称)},value:{tableData:ut}})}}await Ie.newLoadingConstruct(N==null?void 0:N.path,ze),c.setUpdateMenuStatus(!1),await ua.verifyStructureDataToStore(),c.setActiveMenuPath((Z=(q=(ie=N==null?void 0:N.path)==null?void 0:ie.split("/"))==null?void 0:q.filter((S,fe)=>{var Ue,he;return fe!==((he=(Ue=N==null?void 0:N.path)==null?void 0:Ue.split("/"))==null?void 0:he.length)-1}))==null?void 0:Z.join("/")),c.setActiveTopMenuPath((me=(de=N==null?void 0:N.path)==null?void 0:de.split("/"))==null?void 0:me[0]),c.setIsRefreshMenus(!1),c.setIsRefreshMenus(!0)}else if(De==="update")F.value=N;else if(De==="delete"){let $e=await lt.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:N==null?void 0:N.path}}),It=await lt.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:"menu"}}),Se=(be=(we=It==null?void 0:It.data)==null?void 0:we.result)==null?void 0:be[0],qe=(j=Se==null?void 0:Se.value)==null?void 0:j.pageData;if(qe.compData=(Oe=qe.compData)==null?void 0:Oe.map(S=>{var fe;return(S==null?void 0:S.key)==="menuContents"&&(S.contents=Cr(S.contents,(fe=N==null?void 0:N.path)==null?void 0:fe.split("/"))),S}),await lt.updateInsofDataApi({id:Se==null?void 0:Se.id,value:{pageData:qe}}),((je=(ge=$e==null?void 0:$e.data)==null?void 0:ge.result)==null?void 0:je.length)>0){let S=(Le=(ot=$e==null?void 0:$e.data)==null?void 0:ot.result)==null?void 0:Le.map(fe=>fe==null?void 0:fe.id);(S==null?void 0:S.length)>0&&await lt.batchDeleteInsofDataApi({ids:S})}let ze=await Ie.getItemData((mt=(Te=(tt=N==null?void 0:N.path)==null?void 0:tt.split("/"))==null?void 0:Te.filter((S,fe)=>{var Ue,he;return fe!==((he=(Ue=N==null?void 0:N.path)==null?void 0:Ue.split("/"))==null?void 0:he.length)-1}))==null?void 0:mt.join("/"),sessionStorage.getItem("systemKey"),""),Je=[];(ze==null?void 0:ze.length)>0&&(ze==null||ze.forEach(S=>{var Ue,he,ut,st,xt,pt,ct,ft,wt,Tt,jt;let fe=(st=(ut=(he=(Ue=S==null?void 0:S.compData)==null?void 0:Ue.find(vt=>(vt==null?void 0:vt.key)==="header"))==null?void 0:he.contents)==null?void 0:ut[0])==null?void 0:st.prop;((ft=(ct=(pt=(xt=S==null?void 0:S.compData)==null?void 0:xt.find(vt=>(vt==null?void 0:vt.key)==="header"))==null?void 0:pt.contents)==null?void 0:ct[0])==null?void 0:ft.directiveLabel)==="#isMain"&&((jt=(Tt=(wt=S==null?void 0:S.compData)==null?void 0:wt.find(vt=>(vt==null?void 0:vt.key)==="tableContents"))==null?void 0:Tt.contents)==null||jt.forEach(vt=>{var Mt,Lt,Ut;(vt==null?void 0:vt.length)>1?(vt==null?void 0:vt[1])===(N==null?void 0:N.title)&&Je.push((Mt=vt==null?void 0:vt[0])==null?void 0:Mt.id):((Lt=vt==null?void 0:vt[0])==null?void 0:Lt[fe])===(N==null?void 0:N.title)&&Je.push((Ut=vt==null?void 0:vt[0])==null?void 0:Ut.id)}))})),(Je==null?void 0:Je.length)>0&&await lt.batchDeleteInsofDataApi({ids:Je}),c.setUpdateMenuStatus(!1),await ua.verifyStructureDataToStore(),c.setActiveMenuPath((it=(Ve=(Qe=N==null?void 0:N.path)==null?void 0:Qe.split("/"))==null?void 0:Ve.filter((S,fe)=>{var Ue,he;return fe!==((he=(Ue=N==null?void 0:N.path)==null?void 0:Ue.split("/"))==null?void 0:he.length)-1}))==null?void 0:it.join("/")),c.setActiveTopMenuPath((Ye=(gt=N==null?void 0:N.path)==null?void 0:gt.split("/"))==null?void 0:Ye[0]),c.setIsRefreshMenus(!1),c.setIsRefreshMenus(!0)}},at=async(ae,De)=>{var He,dt,m,T,U,J,_,oe,Ae,I,ee,$,W,Ee,ie,q,Z,de,me,we,be,j,Oe,ge,je,ot,Le,tt,Te,mt,Qe;let N=await lt.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:"menu"}}),Ge=(dt=(He=N==null?void 0:N.data)==null?void 0:He.result)==null?void 0:dt[0],Xe=(m=Ge==null?void 0:Ge.value)==null?void 0:m.pageData;Xe.compData=(T=Xe.compData)==null?void 0:T.map(Ve=>{var it,gt;return(Ve==null?void 0:Ve.key)==="menuContents"&&(Ve.contents=_r(Ve.contents,(it=De==null?void 0:De.path)==null?void 0:it.split("/"),De==null?void 0:De.title,(gt=ae==null?void 0:ae.target)==null?void 0:gt.value)),Ve}),Ge!=null&&Ge.id&&await lt.updateInsofDataApi({id:Ge==null?void 0:Ge.id,value:{pageData:Xe}});let Be=(J=(U=De==null?void 0:De.path)==null?void 0:U.split("/"))==null?void 0:J.filter((Ve,it)=>{var gt,Ye;return it!==((Ye=(gt=De==null?void 0:De.path)==null?void 0:gt.split("/"))==null?void 0:Ye.length)-1}),le=Be==null?void 0:Be.join("/");Be.push((_=ae==null?void 0:ae.target)==null?void 0:_.value),Be=Be==null?void 0:Be.join("/");let Q=await Ie.getItemData(le,sessionStorage.getItem("systemKey"),"");if((($=(ee=(I=(Ae=(oe=Q==null?void 0:Q[0])==null?void 0:oe.compData)==null?void 0:Ae.find(Ve=>(Ve==null?void 0:Ve.key)==="header"))==null?void 0:I.contents)==null?void 0:ee[0])==null?void 0:$.directiveLabel)==="#isMain"){let Ve=(Z=(q=(ie=(Ee=(W=Q==null?void 0:Q[0])==null?void 0:W.compData)==null?void 0:Ee.find($e=>($e==null?void 0:$e.key)==="header"))==null?void 0:ie.contents)==null?void 0:q[0])==null?void 0:Z.prop,it=(we=(me=(de=Q==null?void 0:Q[0])==null?void 0:de.compData)==null?void 0:me.find($e=>($e==null?void 0:$e.key)==="tableContents"))==null?void 0:we.contents,gt=(ge=(Oe=(j=(be=Q==null?void 0:Q[0])==null?void 0:be.compData)==null?void 0:j.find($e=>($e==null?void 0:$e.key)==="header"))==null?void 0:Oe.contents)==null?void 0:ge.map($e=>$e==null?void 0:$e.prop),Ye;if(it==null||it.forEach($e=>{var Se;let It=Ie.getValueToObjectValue($e,gt);(It==null?void 0:It[Ve])===De.title&&(Ye=It,Ye[Ve]=(Se=ae==null?void 0:ae.target)==null?void 0:Se.value)}),Ye){let $e={};for(let Se in Ye)Se!=="id"&&($e[Se]=Ye==null?void 0:Ye[Se]);let It=[{id:Ye==null?void 0:Ye.id,value:{tableData:$e}}];await lt.batchUpdateInsofDataApi({dataList:It})}}let se=await lt.getInsofDataApi({key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:De==null?void 0:De.path}}),_e=(ot=(je=se==null?void 0:se.data)==null?void 0:je.result)==null?void 0:ot.map(Ve=>({id:Ve==null?void 0:Ve.id,key:Ve==null?void 0:Ve.key}));_e=_e==null?void 0:_e.map(Ve=>(Ve.key.pageKey=Be,Ve)),(_e==null?void 0:_e.length)>0&&await lt.batchUpdateInsofDataApi({dataList:_e}),c.setUpdateMenuStatus(!1),await ua.verifyStructureDataToStore(),c.setActiveMenuPath((Te=(tt=(Le=De==null?void 0:De.path)==null?void 0:Le.split("/"))==null?void 0:tt.filter((Ve,it)=>{var gt,Ye;return it!==((Ye=(gt=De==null?void 0:De.path)==null?void 0:gt.split("/"))==null?void 0:Ye.length)-1}))==null?void 0:Te.join("/")),c.setActiveTopMenuPath((Qe=(mt=De==null?void 0:De.path)==null?void 0:mt.split("/"))==null?void 0:Qe[0]),c.setIsRefreshMenus(!1),c.setIsRefreshMenus(!0),F.value=void 0},X=async(ae,De)=>{Ne.type=re(De==null?void 0:De.operateType),await We(De,Ne.type,ae),P.value=ae,ne.value=De},V=()=>{Ne.show=!1},te=ae=>ae==null?void 0:ae.filter(De=>De.allowInherit),ye=()=>{var N,Ge,Xe,Be,le;let ae;Ne.type==="create"&&(ae=((N=P.value)==null?void 0:N.path)+"/"+Pe.value[(Ge=Pe.value)==null?void 0:Ge.prop]),Ne.type==="update"&&(ae=(Xe=P.value)==null?void 0:Xe.path);const De={...P.value,config:te((Be=P.value)==null?void 0:Be.config),children:[],childMenus:[],title:Pe.value[(le=Pe.value)==null?void 0:le.prop],path:ae};console.log("clickSubmitForm",ne.value,P.value,De),pe(De),Ne.show=!1},ue=ae=>{var N,Ge;const De=(N=ae==null?void 0:ae.contents)==null?void 0:N.find(Xe=>Xe.key==="formContent");De&&(Pe.value=(Ge=De==null?void 0:De.contents)==null?void 0:Ge.reduce((Xe,Be)=>(Xe[Be.key]=Be.value,Xe.prop=Be.key,Xe),{}))},Ce=e.ref(!1);return{isCollapse:Ce,handleMenuCollapse:()=>{Ce.value=!Ce.value},handleCompChange:ue,dialogForm:xe,dialogRenderComps:Re,getComponents:nt,clickSubmitForm:ye,dialogInfo:Ne,beforeDialogDestroy:V,clickMenuIcon:X,mode:K,renderMenuList:G,clickMenu:b,openMenu:E,closeMenu:y,changeMenuStyle:B,fixElement:F,onBlur:at}}}}e.defineComponent(Er());const yd=x.useLoginState(),{loginUserInfo:df}=x.storeToRefs(yd),rn=x.useModelComp(x.pinia),Sr=e.ref(!1),{itemData:bd,itemGridData:Zn,curStructureCompIds:Mo,isSubmitCurStructure:kd,isRefreshCurStructure:xd,freshContent:pf,routeToChildPath:wd,payloadTypes:ff,pageMapState:lo,itemExtendData:Aa}=x.storeToRefs(rn),tn=x.useMenuState(x.pinia),{activeTopMenuPath:Cd,activeMenuPath:ln,platform:hf,activeAsideMenu:vf,buttonTriggerType:Dd,menus:mf}=x.storeToRefs(tn),ta=Ie.useUnit(x.pinia),{selectTitle:Tr,chooseTitle:zo}=x.storeToRefs(ta),_d=Ie.useOriginalState(x.pinia),{originalPath:Ed}=x.storeToRefs(_d);e.ref();x.useAuthorityState(x.pinia);const $a=e.ref(!0),fa=e.ref(0),io=e.ref([]);e.ref(!1);e.computed(async()=>{var l,s;const a=(l=ln.value)!=null&&l.startsWith("/")?(s=ln.value)==null?void 0:s.substring(1):ln.value;return(a==null?void 0:a.includes(Ed.value))||await Od(a)});const Sd=()=>{rn.setItemGridData([]),rn.setIsEdit("edit"),rn.setSubmitCurStructure(ln.value!=="/平台管理/菜单管理")},Td=()=>{rn.setIsEdit("view"),rn.setRefreshCurStructure(!0)},Bd=async a=>{const l=sessionStorage.getItem("systemKey"),s=await Ie.getItemData(a,l,"");return s&&s.length>0},Id=async a=>{var v,f,D;let l=Tr.value,s=l==null?void 0:l.findIndex(C=>(C==null?void 0:C.value)===(a==null?void 0:a.value)),r=(v=l==null?void 0:l.filter(C=>(C==null?void 0:C.condition)==="parent"))==null?void 0:v.map(C=>C==null?void 0:C.value),d=r==null?void 0:r[0],c=(D=(f=l==null?void 0:l.filter((C,F)=>!(C!=null&&C.condition)&&F<=s))==null?void 0:f.map(C=>C.value))==null?void 0:D.join("/");d?(c==null?void 0:c.length)>0?d=d+"/"+c:d=r==null?void 0:r.join("/"):(c==null?void 0:c.length)>0&&(d=c,l=l==null?void 0:l.filter(C=>(C==null?void 0:C.condition)!=="child"),ta.setSelectTitle(l),ta.setChooseTitle([])),await Bd(d)&&tn.setActiveMenuPath(d)},to=async(a,l,s,r="contentConfig")=>{var d;try{if(!Array.isArray(a))return;let c,w;l==="create"?(c={dataList:a==null?void 0:a.map(f=>{var D;return{key:{systemKey:sessionStorage.getItem("systemKey"),pageKey:s!=null&&s.startsWith("/")?s==null?void 0:s.substring(1):s,type:"structure",structureBelong:r,parentTable:"",version:1},value:{pageData:{...f,compData:(D=f==null?void 0:f.compData)==null?void 0:D.filter(C=>(C==null?void 0:C.key)!=="tableContents")}}}})},w=lt.batchAddInsofDataApi):l==="update"?(c={dataList:a==null?void 0:a.map(f=>{var D;return{id:f==null?void 0:f.id,value:{pageData:{...f,compData:(D=f==null?void 0:f.compData)==null?void 0:D.filter(C=>(C==null?void 0:C.key)!=="tableContents")}}}})},w=lt.batchUpdateInsofDataApi):l==="delete"&&(c={ids:a},w=lt.batchDeleteInsofDataApi);const v=await w(c);if(((d=v==null?void 0:v.data)==null?void 0:d.code)===200)return v.data.result;throw lt.ElMessage.error("保存响应失败"),new Error("保存响应失败")}catch{lt.ElMessage.error("保存响应失败")}},Fo=async(a,l,s,r)=>{var d,c,w,v,f,D,C,F,R,H,M;try{const ve=(c=(d=a==null?void 0:a.results)==null?void 0:d.filter(y=>!(y!=null&&y.id)||typeof(y==null?void 0:y.id)=="string"))==null?void 0:c.map(y=>({key:{pageKey:a==null?void 0:a.pageKey,systemKey:sessionStorage.getItem("systemKey"),type:l,relatedInfo:s},value:{tableData:y}})),K=(v=(w=a==null?void 0:a.results)==null?void 0:w.filter(y=>(y==null?void 0:y.id)&&typeof(y==null?void 0:y.id)=="number"))==null?void 0:v.map(y=>({id:y==null?void 0:y.id,value:{tableData:y}})),O=JSON.parse(x.cloneDeep(JSON.stringify(a))),G=(f=O==null?void 0:O.results)==null?void 0:f.map(y=>y.id);let b;s?b=(F=(C=(D=lo.value)==null?void 0:D[ln.value])==null?void 0:C.filter(y=>{var B,h,ce;return((B=y==null?void 0:y.key)==null?void 0:B.type)===l&&((ce=(h=y==null?void 0:y.key)==null?void 0:h.relatedInfo)==null?void 0:ce.target)===r}))==null?void 0:F.map(y=>y==null?void 0:y.id):b=(M=(H=(R=lo.value)==null?void 0:R[ln.value])==null?void 0:H.filter(y=>{var B;return((B=y==null?void 0:y.key)==null?void 0:B.type)===l}))==null?void 0:M.map(y=>y==null?void 0:y.id);const E=b==null?void 0:b.filter(y=>!(G!=null&&G.includes(y))&&typeof y=="number");(ve==null?void 0:ve.length)>0&&await lt.batchAddInsofDataApi({dataList:ve}),(K==null?void 0:K.length)>0&&await lt.batchUpdateInsofDataApi({dataList:K}),(E==null?void 0:E.length)>0&&await lt.batchDeleteInsofDataApi({ids:E})}catch(ve){throw new Error(ve)}},Nd=async a=>{var D,C,F,R,H,M,ve,K,O,G;tn.setContentLoading(!0);const l=JSON.parse(x.cloneDeep(JSON.stringify(bd.value)));if(!kd.value)return tn.setCacheStructures({key:Dd.value,data:l}),lt.ElMessage.success("已暂存");const s=l==null?void 0:l.map(b=>b.id),r=s.filter(b=>{var E;return!((E=Mo.value)!=null&&E.includes(b))}),d=(D=Mo.value)==null?void 0:D.filter(b=>!s.includes(b)),c=[...r,...d].filter(b=>typeof b!==null&&typeof b<"u"),w=l==null?void 0:l.filter(b=>!b.id),v=l==null?void 0:l.filter(b=>b.id);let f=[];if(c&&(c==null?void 0:c.length)>0&&f.push(to(c,"delete",a)),w&&(w==null?void 0:w.length)>0&&f.push(to(w,"create",a)),v&&(v==null?void 0:v.length)>0&&f.push(to(v,"update",a)),Zn.value&&((C=Zn.value)!=null&&C.isDelete&&((R=(F=Zn.value)==null?void 0:F.results)==null?void 0:R.length)>0&&((M=(H=Zn.value)==null?void 0:H.results)!=null&&M.every(b=>typeof b=="number"))?await lt.batchDeleteInsofDataApi({ids:(ve=Zn.value)==null?void 0:ve.results}):(console.log("itemGridData.value",Zn.value),f.push(await Fo(Zn.value,"gridLayout")))),Aa.value)for(const b in Aa.value)f.push(await Fo((K=Aa.value)==null?void 0:K[b],"extend",{target:b,compId:(G=(O=Aa.value)==null?void 0:O[b])==null?void 0:G.compId},b));await Promise.all(f).then(()=>{lt.ElMessage.success("保存成功"),rn.setRefreshCurStructure(!0)}).catch(b=>{lt.ElMessage.success(b)}),tn.setContentLoading(!1)},ja=a=>aa(a),Gt=e.ref([]),Ad=e.computed(()=>{var a;return(a=Gt.value)==null?void 0:a.filter(l=>(l==null?void 0:l.affix)&&(l==null?void 0:l.affix)!=="default")}),Br=e.computed(()=>{var a;return(a=Gt.value)==null?void 0:a.filter(l=>!(l!=null&&l.affix)||(l==null?void 0:l.affix)==="default")}),Ir=e.ref(0),Nr=e.ref(null),Ua=async(a,l="data",s)=>{},Vd=async a=>{var s,r,d;const l=await lt.getInsofDataApi({id:a});return(d=(r=(s=l==null?void 0:l.data)==null?void 0:s.result)==null?void 0:r[0])==null?void 0:d.value},Ka=async(a,l)=>{var d,c,w;if(Sr.value||typeof(a==null?void 0:a.index)=="string")return;const s=await Vd(a==null?void 0:a.index),r=(d=s==null?void 0:s.pageData)==null?void 0:d.name;await Ie.fixFormContents(a==null?void 0:a.index,{comp:"Form",compData:(c=x.cloneDeep(a==null?void 0:a.contents))==null?void 0:c.filter(v=>v.contents),name:r,isShow:(w=s==null?void 0:s.pageData)==null?void 0:w.isShow}),l&&(tn.setActiveMenuPath(null),tn.setActiveMenuPath(l))},Wa=async a=>{Gt.value=await Ie.getDeepDiffItems(a),rn.setItemData(Gt.value),rn.setOriginalData(Gt.value)},Od=async a=>{var l,s;return(l=a==null?void 0:a.split("/"))==null||l.forEach((r,d)=>{var c;((c=a==null?void 0:a.split("/"))==null?void 0:c.length)-2>d}),(s=a==null?void 0:a.split("/"))==null||s.forEach((r,d)=>{var c;((c=a==null?void 0:a.split("/"))==null?void 0:c.length)-1>d}),!1};e.ref();const ka=e.ref(null),Md=()=>{var a,l;console.log("倒计时结束时"),x.ElMessageBox.alert(`超时未提交,【${(l=(a=ln.value)==null?void 0:a.split("/"))==null?void 0:l[0]}】失败`,"告警",{confirmButtonText:"确认",type:"error"})},Ar=e.ref([]),zd=e.computed(()=>{var a,l;return(l=(a=lo.value)==null?void 0:a[ln.value])==null?void 0:l.filter(s=>{var r;return((r=s==null?void 0:s.key)==null?void 0:r.type)==="gridLayout"})});e.watch(()=>[Cd.value],()=>{ta.setSelectTitle([]),ta.setChooseTitle([])},{deep:!0});e.watch(()=>[zo.value],async()=>{var l,s;let a=(l=zo.value)==null?void 0:l.filter(r=>(r==null?void 0:r.condition)==="child"&&(r==null?void 0:r.value)!==""&&(r==null?void 0:r.parentContent)!==ln.value);if((a==null?void 0:a.length)>0){tn.setContentLoading(!0);let r=ln.value+"/"+((s=a==null?void 0:a[0])==null?void 0:s.value),d=await Xa(r,!0,{originPath:ln.value});Gt.value=await Ie.getDeepDiffItems(d),tn.setContentLoading(!1)}});e.watch(()=>[ln.value,xd.value],async a=>{var w,v,f;if(!ln.value)return;rn.setLockingPage(""),Gt.value=[];let l=e.getCurrentInstance();(w=l==null?void 0:l.scope)==null||w.stop(),l=null,$a.value=!1,tn.setContentLoading(!0),Sr.value=!0;let s=a==null?void 0:a[0],r=s,d=(v=Tr.value)==null?void 0:v.filter(D=>(D==null?void 0:D.condition)==="child"&&(D==null?void 0:D.value)!==""&&(D==null?void 0:D.parentContent)!==ln.value);(d==null?void 0:d.length)>0&&(s=s+"/"+((f=d==null?void 0:d[0])==null?void 0:f.value));let c=await Xa(s,!0,{originPath:r});Gt.value=await Ie.getDeepDiffItems(c),tn.setContentLoading(!1),rn.setExtraContents([]),ta.setSelectIndex(""),ta.setSelectMenu(""),rn.setItemData(Gt.value),rn.setOriginalData(Gt.value),e.nextTick(()=>{fa.value=fa.value++,$a.value=!0})},{immediate:!0});const Fd=async()=>{tn.setLinkMenuInfo(null),tn.setActiveMenuPath(wd.value),Gt.value=null,rn.setRouteToChildPath(""),tn.setChildMenu("")},Rd=a=>new RegExp("button","i").test(a),Pd=a=>/^[\u4e00-\u9fa5]+\/[\u4e00-\u9fa5]+\^(.+)$/.test(a),Vr=a=>{if(Pd(a)){const l=a==null?void 0:a.split("^");(l==null?void 0:l.length)>0&&(l!=null&&l[0])&&tn.setLinkMenuInfo({path:l==null?void 0:l[0],data:l==null?void 0:l[1]})}},Or=a=>{var l;ka.value&&(ka.value={...ka.value,mainKeyPropValue:a==null?void 0:a[(l=ka.value)==null?void 0:l.mainKeyProp]})},Ld=a=>{Ir.value=a},ca=e.reactive({index:0,comp:null}),$d=e.computed(()=>{var a;return(a=Gt.value)==null?void 0:a.map((l,s)=>({id:l.id,name:l.name,status:jd(l,s)}))}),Mr=(a,l)=>{var f,D,C,F,R;const s=l?a:a-2,r=(f=Gt.value)==null?void 0:f[s],d=(C=(D=r==null?void 0:r.compData)==null?void 0:D.find(H=>(H==null?void 0:H.key)==="header"))==null?void 0:C.contents,c=d==null?void 0:d.findIndex(H=>(H==null?void 0:H.isMainKey)&&(H==null?void 0:H.label)!=="操作"),w=c===-1?0:c,v=(R=(F=r==null?void 0:r.compData)==null?void 0:F.find(H=>(H==null?void 0:H.key)==="tableContents"))==null?void 0:R.contents;return{valid:v==null?void 0:v.every(H=>H==null?void 0:H[w+1]),length:(v==null?void 0:v.length)||0}},jd=(a,l)=>{var r;let s="process";if(((r=a==null?void 0:a.comp)==null?void 0:r.toUpperCase())==="TABLE"){const{valid:d,length:c}=Mr(l,!0);ca.index===l?s="process":c===0?s="wait":s=d?"success":"error"}return s},zr=a=>{var s,r,d,c,w;const l=a+1;if(l>1&&((d=(r=(s=Gt.value)==null?void 0:s[a])==null?void 0:r.comp)==null?void 0:d.toUpperCase())==="TABLE"){const{valid:v}=Mr(l);v?(ca.index=l,ca.comp=(c=Gt.value)==null?void 0:c[a]):lt.ElMessage({showClose:!0,type:"warning",message:"当前流程有输入未完成"})}else ca.index=l,ca.comp=(w=Gt.value)==null?void 0:w[a]},Fr=e.computed(()=>{var a,l;return(l=(a=Br.value)==null?void 0:a[0])==null?void 0:l.isStepLayout});e.watch(()=>Fr.value,a=>{a&&zr(0)},{immediate:!0});const Ud={class:"layout"},Kd=e.defineComponent({__name:"index",props:{itemData:{type:Array,default:()=>[]},childItemData:{type:Array,default:()=>[]},userInfo:{type:Object,default:{}}},emits:["rowClick"],setup(a,{emit:l}){const s=l,r=a;e.onMounted(async()=>{});const d=e.computed(()=>x.cloneDeep(r==null?void 0:r.itemData)||[]),c=e.computed(()=>{var C;const D=(C=d==null?void 0:d.value)==null?void 0:C.find(F=>{const{key:R}=F;return R==="baseConfig"});return D==null?void 0:D.contents}),w=e.computed(()=>{var C;const D=(C=d==null?void 0:d.value)==null?void 0:C.find(F=>{const{key:R}=F;return R==="children"});return D==null?void 0:D.contents}),v=e.computed(()=>{let D=x.cloneDeep(w.value)||[];const C=D.length;let F=0;const R=[];if(D=D.map(H=>{const M=H.span;return M?(H.span=Number(M),F=F+H.span):R.push(H),H}),F<24){const H=Math.floor((24-F)/C);R.forEach(M=>{M.span=H})}return D}),f=D=>{s("rowClick",D)};return(D,C)=>{var H;const F=e.resolveComponent("el-col"),R=e.resolveComponent("el-row");return e.openBlock(),e.createElementBlock("div",Ud,[e.createVNode(R,{style:e.normalizeStyle({height:(H=c.value)==null?void 0:H.height})},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(v.value,(M,ve)=>(e.openBlock(),e.createBlock(F,{span:M==null?void 0:M.span},{default:e.withCtx(()=>{var K;return[e.unref($a)?(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(ja)(M.comp)),{key:e.unref(fa),compName:M.name,index:(M==null?void 0:M.id)??ve,height:(K=c.value)==null?void 0:K.height,itemData:M==null?void 0:M.compData,childItemData:M==null?void 0:M.itemChildData,onChange:e.unref(Ua),onContentChange:e.unref(Ka),onPageChange:e.unref(Wa),onRowClick:f},null,40,["compName","index","height","itemData","childItemData","onChange","onContentChange","onPageChange"])):e.createCommentVNode("",!0)]}),_:2},1032,["span"]))),256))]),_:1},8,["style"])])}}}),Wd=Rt._export_sfc(Kd,[["__scopeId","data-v-ab9a36ed"]]),Hd={class:"layout-operate"},qd={class:"layout-module"},Gd={class:"collapse-title-item"},Xd={class:"collapse-title"},Yd={class:"icon-content"},Jd=["onClick"],Zd={class:"comp-child"},Qd=e.defineComponent({__name:"operate",props:{itemContents:{type:Object,default:()=>{}},originalItemContents:{type:Array,default:()=>[]},itemChildData:{type:Array,default:()=>[]}},emits:["change"],setup(a,{emit:l}){const s=a,r=l;e.onMounted(()=>{ve()});const d=e.ref({}),c=e.ref({}),w=e.ref([]),v=y=>[{label:"高度",prop:"height",type:"input",value:y==null?void 0:y.height}],f=y=>{c.value=y,r("change",E(),!0)},D=e.ref([]),C=e.ref([]),F=y=>[{label:"占比",prop:"span",type:"input",value:y==null?void 0:y.span}],R=e.computed(()=>{const y=s==null?void 0:s.itemContents;return x.cloneDeep(y)}),H=e.computed(()=>{const y=R==null?void 0:R.value,B=y==null?void 0:y.find(h=>{const{key:ce}=h;return ce==="baseConfig"});return B==null?void 0:B.contents}),M=e.computed(()=>{const y=R==null?void 0:R.value,B=y==null?void 0:y.find(h=>{const{key:ce}=h;return ce==="children"});return B==null?void 0:B.contents}),ve=()=>{var y;d.value=R.value||{},D.value=(M==null?void 0:M.value)||[],w.value=v(),w.value=(y=w.value)==null?void 0:y.map(B=>{var ce;const{prop:h}=B;return B.value=(ce=H.value)==null?void 0:ce[h],B})};e.watch(()=>{var y;return(y=M==null?void 0:M.value)==null?void 0:y.length},()=>{var y;D.value=(M==null?void 0:M.value)||[],C.value=(y=M.value)==null?void 0:y.map(B=>F(B))},{immediate:!0});const K=(y,B)=>{const h=x.cloneDeep(M==null?void 0:M.value);h[B].span=y.span,D.value=h,r("change",E(),!0)},O=y=>aa(y),G=(y,B,h)=>{if(!y)return;const ce=x.cloneDeep(M==null?void 0:M.value);ce[h]&&(ce[h].compData=y,D.value=ce,r("change",E(),!0))},b=y=>{x.ElMessageBox.confirm("是否确认要删除","",{confirmButtonText:"确认",cancelButtonText:"取消",type:"warning"}).then(()=>{let B=x.cloneDeep(M==null?void 0:M.value);B=B==null?void 0:B.filter((h,ce)=>y!==ce),D.value=B,r("change",E(),!0),lt.ElMessage({type:"success",message:"删除成功"})}).catch(()=>{})},E=()=>({compData:[{key:"baseConfig",contents:c.value},{key:"children",contents:D==null?void 0:D.value}]});return(y,B)=>{const h=e.resolveComponent("svg-icon");return e.openBlock(),e.createElementBlock("div",Hd,[e.createElementVNode("div",qd,[B[1]||(B[1]=e.createElementVNode("div",{class:"module-title"},"基础配置",-1)),e.createElementVNode("div",null,[e.createVNode(Bt.ssForm,{rowContents:w.value,isEnableWrap:!0,onChange:B[0]||(B[0]=ce=>f(ce))},null,8,["rowContents"])])]),e.createVNode(ur.default,{class:"collapse-content",collapseContents:M.value},{title:e.withCtx(({item:ce,index:Ne})=>[e.createElementVNode("div",Gd,[e.createElementVNode("div",Xd,e.toDisplayString(ce.name),1),e.createElementVNode("div",Yd,[e.createElementVNode("div",{onClick:e.withModifiers(nt=>b(Ne),["stop"]),class:"icon-content"},[e.createVNode(h,{name:"Delete",style:{width:"16px",height:"16px"}})],8,Jd)])])]),content:e.withCtx(({item:ce,index:Ne})=>[e.createElementVNode("div",Zd,[e.createElementVNode("div",null,[(e.openBlock(),e.createBlock(Bt.ssForm,{rowContents:C.value[Ne],key:Ne,isEnableWrap:!0,onChange:nt=>K(nt,Ne)},null,8,["rowContents","onChange"]))]),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(O(ce.comp+"Operate")),{itemContents:ce==null?void 0:ce.compData,originalItemContents:ce.compData,onChange:nt=>G(nt,ce,Ne)},null,40,["itemContents","originalItemContents","onChange"]))])]),_:1},8,["collapseContents"])])}}}),ep=Rt._export_sfc(Qd,[["__scopeId","data-v-ba05456e"]]),tp=typeof window<"u";var Ro;tp&&((Ro=window==null?void 0:window.navigator)!=null&&Ro.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function cn(a){return a==null}function Rr(){}const np=Object.freeze({aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"});Object.freeze(new Set(Object.keys(np)));function ap(){const a=new Map;return{on(l,s){const r=a.get(l);r!=null&&r.add(s)||a.set(l,new Set([s]))},off(l,s){const r=a.get(l);r&&r.delete(s)},clear(l){const s=a.get(l);s&&s.clear()},clearAll(){a.clear()},emit(l,...s){const r=a.get(l);r&&r.forEach(d=>{d(...s)})}}}function Po(a,l=16){if(typeof a!="function")return Rr;const s=(...c)=>{a(...c)};if(l<=0)return Pr(s);let r=0,d;return function(...c){const w=Date.now(),v=w-r;clearTimeout(d),v>=l?(r=w,s(...c)):d=setTimeout(()=>{r=Date.now(),s(...c)},Math.max(0,l-v))}}function op(a,l=100){if(typeof a!="function")return Rr;const s=(...d)=>{a(...d)};if(l<=0)return Pr(s);let r;return function(...d){clearTimeout(r),r=setTimeout(()=>{s(...d)},l)}}function Pr(a){if(typeof a!="function")return a;let l=!1,s,r;return function(...d){return s=d,l||(l=!0,r=Promise.resolve().then(()=>(l=!1,r=void 0,a(...s)))),r}}const wa=new Set,Lr=new WeakMap;function rp(){wa.forEach(a=>{a(...Lr.get(a))}),wa.clear()}function en(a,...l){if(typeof a!="function")return a;Lr.set(a,l),!wa.has(a)&&(wa.add(a),wa.size===1&&Promise.resolve().then(rp))}const $r=Symbol("LAYOUT_KEY"),jr=Symbol("EMITTER_KEY");function lp(a){let l=0,s;for(let r=0,d=a.length;r<d;r++)s=a[r].y+a[r].h,s>l&&(l=s);return l}function so(a){const l=Array(a.length);for(let s=0,r=a.length;s<r;s++)l[s]=ip(a[s]);return l}function ip(a){return{...a}}function Ur(a,l){return!(a===l||a.x+a.w<=l.x||a.x>=l.x+l.w||a.y+a.h<=l.y||a.y>=l.y+l.h)}function sa(a,l,s){const r=Wr(a),d=Hr(a),c=Array(a.length);for(let w=0,v=d.length;w<v;w++){let f=d[w];f.static||(f=sp(r,f,l,s),r.push(f)),c[a.findIndex(D=>D.i===f.i)]=f,f.moved=!1}return c}function sp(a,l,s,r){if(s)for(;l.y>0&&!Ca(a,l);)l.y--;else if(r){const c=r[l.i].y;for(;l.y>c&&!Ca(a,l);)l.y--}let d;for(;d=Ca(a,l);)l.y=d.y+d.h;return l}function cp(a,l){const s=Wr(a);for(let r=0,d=a.length;r<d;r++){const c=a[r];if(c.x+c.w>l.cols&&(c.x=l.cols-c.w),c.x<0&&(c.x=0,c.w=l.cols),!c.static)s.push(c);else for(;Ca(s,c);)c.y++}return a}function Lo(a,l){for(let s=0,r=a.length;s<r;s++)if(a[s].i===l)return a[s]}function Ca(a,l){for(let s=0,r=a.length;s<r;s++)if(Ur(a[s],l))return a[s]}function Kr(a,l){return a.filter(s=>Ur(s,l))}function Wr(a){return a.filter(l=>l.static)}function co(a,l,s,r,d=!1,c=!1){if(l.static)return a;const w=l.x,v=l.y,f=r&&l.y>r;typeof s=="number"&&(l.x=s),typeof r=="number"&&(l.y=r),l.moved=!0;let D=Hr(a);f&&(D=D.reverse());const C=Kr(D,l);if(c&&C.length)return l.x=w,l.y=v,l.moved=!1,a;for(let F=0,R=C.length;F<R;F++){const H=C[F];H.moved||l.y>H.y&&l.y-H.y>H.h/4||(H.static?a=$o(a,H,l,d):a=$o(a,l,H,d))}return a}function $o(a,l,s,r){if(r){const d={x:s.x,y:s.y,w:s.w,h:s.h};if(d.y=Math.max(l.y-s.h,0),!Ca(a,d))return co(a,s,void 0,d.y,!1)}return co(a,s,void 0,s.y+1,!1)}function up(a,l,s,r){const d="translate3d("+l+"px,"+a+"px, 0)";return{transform:d,WebkitTransform:d,MozTransform:d,msTransform:d,OTransform:d,width:s+"px",height:r+"px",position:"absolute"}}function dp(a,l,s,r){const d="translate3d("+l*-1+"px,"+a+"px, 0)";return{transform:d,WebkitTransform:d,MozTransform:d,msTransform:d,OTransform:d,width:s+"px",height:r+"px",position:"absolute"}}function pp(a,l,s,r){return{top:a+"px",left:l+"px",width:s+"px",height:r+"px",position:"absolute"}}function fp(a,l,s,r){return{top:a+"px",right:l+"px",width:s+"px",height:r+"px",position:"absolute"}}function Hr(a){return Array.from(a).sort(function(l,s){return l.y===s.y&&l.x===s.x?0:l.y>s.y||l.y===s.y&&l.x>s.x?1:-1})}function hp(a,l){l=l||"Layout";const s=["x","y","w","h"],r=[];if(!Array.isArray(a))throw new Error(l+" must be an array!");for(let d=0,c=a.length;d<c;d++){const w=a[d];for(let v=0;v<s.length;v++)if(typeof w[s[v]]!="number")throw new Error("VueGridLayout: "+l+"["+d+"]."+s[v]+" must be a number!");if(w.i===void 0||w.i===null)throw new Error("VueGridLayout: "+l+"["+d+"].i cannot be null!");if(typeof w.i!="number"&&typeof w.i!="string")throw new Error("VueGridLayout: "+l+"["+d+"].i must be a string or number!");if(r.indexOf(w.i)>=0)throw new Error("VueGridLayout: "+l+"["+d+"].i must be unique!");if(r.push(w.i),w.static!==void 0&&typeof w.static!="boolean")throw new Error("VueGridLayout: "+l+"["+d+"].static must be a boolean!")}}function vp(a,l="vgl"){const s=()=>`${l}-${a}`;return{b:s,be:r=>`${s()}__${r}`,bm:r=>`${s()}--${r}`,bem:(r,d)=>`${s()}__${r}--${d}`}}function jo(a){return mp(a)}function mp(a){var l;const s=((l=a.target)==null?void 0:l.offsetParent)||document.body,r=a.offsetParent===document.body?{left:0,top:0}:s.getBoundingClientRect(),d=a.clientX+s.scrollLeft-r.left,c=a.clientY+s.scrollTop-r.top;return{x:d,y:c}}function Uo(a,l,s,r){return gp(a)?{deltaX:s-a,deltaY:r-l,lastX:a,lastY:l,x:s,y:r}:{deltaX:0,deltaY:0,lastX:s,lastY:r,x:s,y:r}}function gp(a){return typeof a=="number"&&!Number.isNaN(a)}function yp(a,l){const s=Gr(a);let r=s[0];for(let d=1,c=s.length;d<c;d++){const w=s[d];l>a[w]&&(r=w)}return r}function qr(a,l){if(!l[a])throw new Error("ResponsiveGridLayout: `cols` entry for breakpoint "+a+" is missing!");return l[a]}function bp(a,l,s,r,d,c,w){if(l[r])return so(l[r]);let v=a;const f=Gr(s),D=f.slice(f.indexOf(r));for(let C=0,F=D.length;C<F;C++){const R=D[C];if(l[R]){v=l[R];break}}return v=so(v||[]),sa(cp(v,{cols:c}),w)}function Gr(a){return Object.keys(a).sort((l,s)=>a[l]-a[s])}let kp="auto";function xp(){return typeof document<"u"}function Ko(){return xp()?typeof document.dir<"u"?document.dir:document.getElementsByTagName("html")[0].getAttribute("dir"):kp}var xa={exports:{}},wp=xa.exports,Wo;function Cp(){return Wo||(Wo=1,function(a,l){(function(s,r){a.exports=r()})(wp,function(){function s(n,t){var o=Object.keys(n);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(n);t&&(i=i.filter(function(u){return Object.getOwnPropertyDescriptor(n,u).enumerable})),o.push.apply(o,i)}return o}function r(n){for(var t=1;t<arguments.length;t++){var o=arguments[t]!=null?arguments[t]:{};t%2?s(Object(o),!0).forEach(function(i){f(n,i,o[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(o)):s(Object(o)).forEach(function(i){Object.defineProperty(n,i,Object.getOwnPropertyDescriptor(o,i))})}return n}function d(n){return d=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},d(n)}function c(n,t){if(!(n instanceof t))throw new TypeError("Cannot call a class as a function")}function w(n,t){for(var o=0;o<t.length;o++){var i=t[o];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(n,ve(i.key),i)}}function v(n,t,o){return t&&w(n.prototype,t),Object.defineProperty(n,"prototype",{writable:!1}),n}function f(n,t,o){return(t=ve(t))in n?Object.defineProperty(n,t,{value:o,enumerable:!0,configurable:!0,writable:!0}):n[t]=o,n}function D(n,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");n.prototype=Object.create(t&&t.prototype,{constructor:{value:n,writable:!0,configurable:!0}}),Object.defineProperty(n,"prototype",{writable:!1}),t&&F(n,t)}function C(n){return C=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},C(n)}function F(n,t){return F=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(o,i){return o.__proto__=i,o},F(n,t)}function R(n){if(n===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return n}function H(n){var t=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}();return function(){var o,i=C(n);if(t){var u=C(this).constructor;o=Reflect.construct(i,arguments,u)}else o=i.apply(this,arguments);return function(p,g){if(g&&(typeof g=="object"||typeof g=="function"))return g;if(g!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return R(p)}(this,o)}}function M(){return M=typeof Reflect<"u"&&Reflect.get?Reflect.get.bind():function(n,t,o){var i=function(p,g){for(;!Object.prototype.hasOwnProperty.call(p,g)&&(p=C(p))!==null;);return p}(n,t);if(i){var u=Object.getOwnPropertyDescriptor(i,t);return u.get?u.get.call(arguments.length<3?n:o):u.value}},M.apply(this,arguments)}function ve(n){var t=function(o,i){if(typeof o!="object"||o===null)return o;var u=o[Symbol.toPrimitive];if(u!==void 0){var p=u.call(o,i);if(typeof p!="object")return p;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(o)}(n,"string");return typeof t=="symbol"?t:t+""}var K=function(n){return!(!n||!n.Window)&&n instanceof n.Window},O=void 0,G=void 0;function b(n){O=n;var t=n.document.createTextNode("");t.ownerDocument!==n.document&&typeof n.wrap=="function"&&n.wrap(t)===t&&(n=n.wrap(n)),G=n}function E(n){return K(n)?n:(n.ownerDocument||n).defaultView||G.window}typeof window<"u"&&window&&b(window);var y=function(n){return!!n&&d(n)==="object"},B=function(n){return typeof n=="function"},h={window:function(n){return n===G||K(n)},docFrag:function(n){return y(n)&&n.nodeType===11},object:y,func:B,number:function(n){return typeof n=="number"},bool:function(n){return typeof n=="boolean"},string:function(n){return typeof n=="string"},element:function(n){if(!n||d(n)!=="object")return!1;var t=E(n)||G;return/object|function/.test(typeof Element>"u"?"undefined":d(Element))?n instanceof Element||n instanceof t.Element:n.nodeType===1&&typeof n.nodeName=="string"},plainObject:function(n){return y(n)&&!!n.constructor&&/function Object\b/.test(n.constructor.toString())},array:function(n){return y(n)&&n.length!==void 0&&B(n.splice)}};function ce(n){var t=n.interaction;if(t.prepared.name==="drag"){var o=t.prepared.axis;o==="x"?(t.coords.cur.page.y=t.coords.start.page.y,t.coords.cur.client.y=t.coords.start.client.y,t.coords.velocity.client.y=0,t.coords.velocity.page.y=0):o==="y"&&(t.coords.cur.page.x=t.coords.start.page.x,t.coords.cur.client.x=t.coords.start.client.x,t.coords.velocity.client.x=0,t.coords.velocity.page.x=0)}}function Ne(n){var t=n.iEvent,o=n.interaction;if(o.prepared.name==="drag"){var i=o.prepared.axis;if(i==="x"||i==="y"){var u=i==="x"?"y":"x";t.page[u]=o.coords.start.page[u],t.client[u]=o.coords.start.client[u],t.delta[u]=0}}}var nt={id:"actions/drag",install:function(n){var t=n.actions,o=n.Interactable,i=n.defaults;o.prototype.draggable=nt.draggable,t.map.drag=nt,t.methodDict.drag="draggable",i.actions.drag=nt.defaults},listeners:{"interactions:before-action-move":ce,"interactions:action-resume":ce,"interactions:action-move":Ne,"auto-start:check":function(n){var t=n.interaction,o=n.interactable,i=n.buttons,u=o.options.drag;if(u&&u.enabled&&(!t.pointerIsDown||!/mouse|pointer/.test(t.pointerType)||(i&o.options.drag.mouseButtons)!=0))return n.action={name:"drag",axis:u.lockAxis==="start"?u.startAxis:u.lockAxis},!1}},draggable:function(n){return h.object(n)?(this.options.drag.enabled=n.enabled!==!1,this.setPerAction("drag",n),this.setOnEvents("drag",n),/^(xy|x|y|start)$/.test(n.lockAxis)&&(this.options.drag.lockAxis=n.lockAxis),/^(xy|x|y)$/.test(n.startAxis)&&(this.options.drag.startAxis=n.startAxis),this):h.bool(n)?(this.options.drag.enabled=n,this):this.options.drag},beforeMove:ce,move:Ne,defaults:{startAxis:"xy",lockAxis:"xy"},getCursor:function(){return"move"},filterEventType:function(n){return n.search("drag")===0}},xe=nt,Re={init:function(n){var t=n;Re.document=t.document,Re.DocumentFragment=t.DocumentFragment||Pe,Re.SVGElement=t.SVGElement||Pe,Re.SVGSVGElement=t.SVGSVGElement||Pe,Re.SVGElementInstance=t.SVGElementInstance||Pe,Re.Element=t.Element||Pe,Re.HTMLElement=t.HTMLElement||Re.Element,Re.Event=t.Event,Re.Touch=t.Touch||Pe,Re.PointerEvent=t.PointerEvent||t.MSPointerEvent},document:null,DocumentFragment:null,SVGElement:null,SVGSVGElement:null,SVGElementInstance:null,Element:null,HTMLElement:null,Event:null,Touch:null,PointerEvent:null};function Pe(){}var P=Re,re={init:function(n){var t=P.Element,o=n.navigator||{};re.supportsTouch="ontouchstart"in n||h.func(n.DocumentTouch)&&P.document instanceof n.DocumentTouch,re.supportsPointerEvent=o.pointerEnabled!==!1&&!!P.PointerEvent,re.isIOS=/iP(hone|od|ad)/.test(o.platform),re.isIOS7=/iP(hone|od|ad)/.test(o.platform)&&/OS 7[^\d]/.test(o.appVersion),re.isIe9=/MSIE 9/.test(o.userAgent),re.isOperaMobile=o.appName==="Opera"&&re.supportsTouch&&/Presto/.test(o.userAgent),re.prefixedMatchesSelector="matches"in t.prototype?"matches":"webkitMatchesSelector"in t.prototype?"webkitMatchesSelector":"mozMatchesSelector"in t.prototype?"mozMatchesSelector":"oMatchesSelector"in t.prototype?"oMatchesSelector":"msMatchesSelector",re.pEventTypes=re.supportsPointerEvent?P.PointerEvent===n.MSPointerEvent?{up:"MSPointerUp",down:"MSPointerDown",over:"mouseover",out:"mouseout",move:"MSPointerMove",cancel:"MSPointerCancel"}:{up:"pointerup",down:"pointerdown",over:"pointerover",out:"pointerout",move:"pointermove",cancel:"pointercancel"}:null,re.wheelEvent=P.document&&"onmousewheel"in P.document?"mousewheel":"wheel"},supportsTouch:null,supportsPointerEvent:null,isIOS7:null,isIOS:null,isIe9:null,isOperaMobile:null,prefixedMatchesSelector:null,pEventTypes:null,wheelEvent:null},ne=re;function pe(n,t){if(n.contains)return n.contains(t);for(;t;){if(t===n)return!0;t=t.parentNode}return!1}function We(n,t){for(;h.element(n);){if(X(n,t))return n;n=at(n)}return null}function at(n){var t=n.parentNode;if(h.docFrag(t)){for(;(t=t.host)&&h.docFrag(t););return t}return t}function X(n,t){return G!==O&&(t=t.replace(/\/deep\//g," ")),n[ne.prefixedMatchesSelector](t)}var V=function(n){return n.parentNode||n.host};function te(n,t){for(var o,i=[],u=n;(o=V(u))&&u!==t&&o!==u.ownerDocument;)i.unshift(u),u=o;return i}function ye(n,t,o){for(;h.element(n);){if(X(n,t))return!0;if((n=at(n))===o)return X(n,t)}return!1}function ue(n){return n.correspondingUseElement||n}function Ce(n){var t=n instanceof P.SVGElement?n.getBoundingClientRect():n.getClientRects()[0];return t&&{left:t.left,right:t.right,top:t.top,bottom:t.bottom,width:t.width||t.right-t.left,height:t.height||t.bottom-t.top}}function Ze(n){var t,o=Ce(n);if(!ne.isIOS7&&o){var i={x:(t=(t=E(n))||G).scrollX||t.document.documentElement.scrollLeft,y:t.scrollY||t.document.documentElement.scrollTop};o.left+=i.x,o.right+=i.x,o.top+=i.y,o.bottom+=i.y}return o}function ae(n){for(var t=[];n;)t.push(n),n=at(n);return t}function De(n){return!!h.string(n)&&(P.document.querySelector(n),!0)}function N(n,t){for(var o in t)n[o]=t[o];return n}function Ge(n,t,o){return n==="parent"?at(o):n==="self"?t.getRect(o):We(o,n)}function Xe(n,t,o,i){var u=n;return h.string(u)?u=Ge(u,t,o):h.func(u)&&(u=u.apply(void 0,i)),h.element(u)&&(u=Ze(u)),u}function Be(n){return n&&{x:"x"in n?n.x:n.left,y:"y"in n?n.y:n.top}}function le(n){return!n||"x"in n&&"y"in n||((n=N({},n)).x=n.left||0,n.y=n.top||0,n.width=n.width||(n.right||0)-n.x,n.height=n.height||(n.bottom||0)-n.y),n}function Q(n,t,o){n.left&&(t.left+=o.x),n.right&&(t.right+=o.x),n.top&&(t.top+=o.y),n.bottom&&(t.bottom+=o.y),t.width=t.right-t.left,t.height=t.bottom-t.top}function se(n,t,o){var i=o&&n.options[o];return Be(Xe(i&&i.origin||n.options.origin,n,t,[n&&t]))||{x:0,y:0}}function _e(n,t){var o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:function(A){return!0},i=arguments.length>3?arguments[3]:void 0;if(i=i||{},h.string(n)&&n.search(" ")!==-1&&(n=He(n)),h.array(n))return n.forEach(function(A){return _e(A,t,o,i)}),i;if(h.object(n)&&(t=n,n=""),h.func(t)&&o(n))i[n]=i[n]||[],i[n].push(t);else if(h.array(t))for(var u=0,p=t;u<p.length;u++){var g=p[u];_e(n,g,o,i)}else if(h.object(t))for(var k in t)_e(He(k).map(function(A){return"".concat(n).concat(A)}),t[k],o,i);return i}function He(n){return n.trim().split(/ +/)}var dt=function(n,t){return Math.sqrt(n*n+t*t)},m=["webkit","moz"];function T(n,t){n.__set||(n.__set={});var o=function(u){if(m.some(function(p){return u.indexOf(p)===0}))return 1;typeof n[u]!="function"&&u!=="__set"&&Object.defineProperty(n,u,{get:function(){return u in n.__set?n.__set[u]:n.__set[u]=t[u]},set:function(p){n.__set[u]=p},configurable:!0})};for(var i in t)o(i);return n}function U(n,t){n.page=n.page||{},n.page.x=t.page.x,n.page.y=t.page.y,n.client=n.client||{},n.client.x=t.client.x,n.client.y=t.client.y,n.timeStamp=t.timeStamp}function J(n){n.page.x=0,n.page.y=0,n.client.x=0,n.client.y=0}function _(n){return n instanceof P.Event||n instanceof P.Touch}function oe(n,t,o){return n=n||"page",(o=o||{}).x=t[n+"X"],o.y=t[n+"Y"],o}function Ae(n,t){return t=t||{x:0,y:0},ne.isOperaMobile&&_(n)?(oe("screen",n,t),t.x+=window.scrollX,t.y+=window.scrollY):oe("page",n,t),t}function I(n){return h.number(n.pointerId)?n.pointerId:n.identifier}function ee(n,t,o){var i=t.length>1?W(t):t[0];Ae(i,n.page),function(u,p){p=p||{},ne.isOperaMobile&&_(u)?oe("screen",u,p):oe("client",u,p)}(i,n.client),n.timeStamp=o}function $(n){var t=[];return h.array(n)?(t[0]=n[0],t[1]=n[1]):n.type==="touchend"?n.touches.length===1?(t[0]=n.touches[0],t[1]=n.changedTouches[0]):n.touches.length===0&&(t[0]=n.changedTouches[0],t[1]=n.changedTouches[1]):(t[0]=n.touches[0],t[1]=n.touches[1]),t}function W(n){for(var t={pageX:0,pageY:0,clientX:0,clientY:0,screenX:0,screenY:0},o=0;o<n.length;o++){var i=n[o];for(var u in t)t[u]+=i[u]}for(var p in t)t[p]/=n.length;return t}function Ee(n){if(!n.length)return null;var t=$(n),o=Math.min(t[0].pageX,t[1].pageX),i=Math.min(t[0].pageY,t[1].pageY),u=Math.max(t[0].pageX,t[1].pageX),p=Math.max(t[0].pageY,t[1].pageY);return{x:o,y:i,left:o,top:i,right:u,bottom:p,width:u-o,height:p-i}}function ie(n,t){var o=t+"X",i=t+"Y",u=$(n),p=u[0][o]-u[1][o],g=u[0][i]-u[1][i];return dt(p,g)}function q(n,t){var o=t+"X",i=t+"Y",u=$(n),p=u[1][o]-u[0][o],g=u[1][i]-u[0][i];return 180*Math.atan2(g,p)/Math.PI}function Z(n){return h.string(n.pointerType)?n.pointerType:h.number(n.pointerType)?[void 0,void 0,"touch","pen","mouse"][n.pointerType]:/touch/.test(n.type||"")||n instanceof P.Touch?"touch":"mouse"}function de(n){var t=h.func(n.composedPath)?n.composedPath():n.path;return[ue(t?t[0]:n.target),ue(n.currentTarget)]}var me=function(){function n(t){c(this,n),this.immediatePropagationStopped=!1,this.propagationStopped=!1,this._interaction=t}return v(n,[{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),n}();Object.defineProperty(me.prototype,"interaction",{get:function(){return this._interaction._proxy},set:function(){}});var we=function(n,t){for(var o=0;o<t.length;o++){var i=t[o];n.push(i)}return n},be=function(n){return we([],n)},j=function(n,t){for(var o=0;o<n.length;o++)if(t(n[o],o,n))return o;return-1},Oe=function(n,t){return n[j(n,t)]},ge=function(n){D(o,n);var t=H(o);function o(i,u,p){var g;c(this,o),(g=t.call(this,u._interaction)).dropzone=void 0,g.dragEvent=void 0,g.relatedTarget=void 0,g.draggable=void 0,g.propagationStopped=!1,g.immediatePropagationStopped=!1;var k=p==="dragleave"?i.prev:i.cur,A=k.element,L=k.dropzone;return g.type=p,g.target=A,g.currentTarget=A,g.dropzone=L,g.dragEvent=u,g.relatedTarget=u.target,g.draggable=u.interactable,g.timeStamp=u.timeStamp,g}return v(o,[{key:"reject",value:function(){var i=this,u=this._interaction.dropState;if(this.type==="dropactivate"||this.dropzone&&u.cur.dropzone===this.dropzone&&u.cur.element===this.target)if(u.prev.dropzone=this.dropzone,u.prev.element=this.target,u.rejected=!0,u.events.enter=null,this.stopImmediatePropagation(),this.type==="dropactivate"){var p=u.activeDrops,g=j(p,function(A){var L=A.dropzone,z=A.element;return L===i.dropzone&&z===i.target});u.activeDrops.splice(g,1);var k=new o(u,this.dragEvent,"dropdeactivate");k.dropzone=this.dropzone,k.target=this.target,this.dropzone.fire(k)}else this.dropzone.fire(new o(u,this.dragEvent,"dragleave"))}},{key:"preventDefault",value:function(){}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}}]),o}(me);function je(n,t){for(var o=0,i=n.slice();o<i.length;o++){var u=i[o],p=u.dropzone,g=u.element;t.dropzone=p,t.target=g,p.fire(t),t.propagationStopped=t.immediatePropagationStopped=!1}}function ot(n,t){for(var o=function(p,g){for(var k=[],A=0,L=p.interactables.list;A<L.length;A++){var z=L[A];if(z.options.drop.enabled){var Y=z.options.drop.accept;if(!(h.element(Y)&&Y!==g||h.string(Y)&&!X(g,Y)||h.func(Y)&&!Y({dropzone:z,draggableElement:g})))for(var ke=0,Fe=z.getAllElements();ke<Fe.length;ke++){var Me=Fe[ke];Me!==g&&k.push({dropzone:z,element:Me,rect:z.getRect(Me)})}}}return k}(n,t),i=0;i<o.length;i++){var u=o[i];u.rect=u.dropzone.getRect(u.element)}return o}function Le(n,t,o){for(var i=n.dropState,u=n.interactable,p=n.element,g=[],k=0,A=i.activeDrops;k<A.length;k++){var L=A[k],z=L.dropzone,Y=L.element,ke=L.rect,Fe=z.dropCheck(t,o,u,p,Y,ke);g.push(Fe?Y:null)}var Me=function(Ke){for(var rt,et,ht,Et=[],Nt=0;Nt<Ke.length;Nt++){var kt=Ke[Nt],St=Ke[rt];if(kt&&Nt!==rt)if(St){var Qt=V(kt),$t=V(St);if(Qt!==kt.ownerDocument)if($t!==kt.ownerDocument)if(Qt!==$t){Et=Et.length?Et:te(St);var sn=void 0;if(St instanceof P.HTMLElement&&kt instanceof P.SVGElement&&!(kt instanceof P.SVGSVGElement)){if(kt===$t)continue;sn=kt.ownerSVGElement}else sn=kt;for(var fn=te(sn,St.ownerDocument),xn=0;fn[xn]&&fn[xn]===Et[xn];)xn++;var Na=[fn[xn-1],fn[xn],Et[xn]];if(Na[0])for(var ga=Na[0].lastChild;ga;){if(ga===Na[1]){rt=Nt,Et=fn;break}if(ga===Na[2])break;ga=ga.previousSibling}}else ht=St,(parseInt(E(et=kt).getComputedStyle(et).zIndex,10)||0)>=(parseInt(E(ht).getComputedStyle(ht).zIndex,10)||0)&&(rt=Nt);else rt=Nt}else rt=Nt}return rt}(g);return i.activeDrops[Me]||null}function tt(n,t,o){var i=n.dropState,u={enter:null,leave:null,activate:null,deactivate:null,move:null,drop:null};return o.type==="dragstart"&&(u.activate=new ge(i,o,"dropactivate"),u.activate.target=null,u.activate.dropzone=null),o.type==="dragend"&&(u.deactivate=new ge(i,o,"dropdeactivate"),u.deactivate.target=null,u.deactivate.dropzone=null),i.rejected||(i.cur.element!==i.prev.element&&(i.prev.dropzone&&(u.leave=new ge(i,o,"dragleave"),o.dragLeave=u.leave.target=i.prev.element,o.prevDropzone=u.leave.dropzone=i.prev.dropzone),i.cur.dropzone&&(u.enter=new ge(i,o,"dragenter"),o.dragEnter=i.cur.element,o.dropzone=i.cur.dropzone)),o.type==="dragend"&&i.cur.dropzone&&(u.drop=new ge(i,o,"drop"),o.dropzone=i.cur.dropzone,o.relatedTarget=i.cur.element),o.type==="dragmove"&&i.cur.dropzone&&(u.move=new ge(i,o,"dropmove"),o.dropzone=i.cur.dropzone)),u}function Te(n,t){var o=n.dropState,i=o.activeDrops,u=o.cur,p=o.prev;t.leave&&p.dropzone.fire(t.leave),t.enter&&u.dropzone.fire(t.enter),t.move&&u.dropzone.fire(t.move),t.drop&&u.dropzone.fire(t.drop),t.deactivate&&je(i,t.deactivate),o.prev.dropzone=u.dropzone,o.prev.element=u.element}function mt(n,t){var o=n.interaction,i=n.iEvent,u=n.event;if(i.type==="dragmove"||i.type==="dragend"){var p=o.dropState;t.dynamicDrop&&(p.activeDrops=ot(t,o.element));var g=i,k=Le(o,g,u);p.rejected=p.rejected&&!!k&&k.dropzone===p.cur.dropzone&&k.element===p.cur.element,p.cur.dropzone=k&&k.dropzone,p.cur.element=k&&k.element,p.events=tt(o,0,g)}}var Qe={id:"actions/drop",install:function(n){var t=n.actions,o=n.interactStatic,i=n.Interactable,u=n.defaults;n.usePlugin(xe),i.prototype.dropzone=function(p){return function(g,k){if(h.object(k)){if(g.options.drop.enabled=k.enabled!==!1,k.listeners){var A=_e(k.listeners),L=Object.keys(A).reduce(function(Y,ke){return Y[/^(enter|leave)/.test(ke)?"drag".concat(ke):/^(activate|deactivate|move)/.test(ke)?"drop".concat(ke):ke]=A[ke],Y},{}),z=g.options.drop.listeners;z&&g.off(z),g.on(L),g.options.drop.listeners=L}return h.func(k.ondrop)&&g.on("drop",k.ondrop),h.func(k.ondropactivate)&&g.on("dropactivate",k.ondropactivate),h.func(k.ondropdeactivate)&&g.on("dropdeactivate",k.ondropdeactivate),h.func(k.ondragenter)&&g.on("dragenter",k.ondragenter),h.func(k.ondragleave)&&g.on("dragleave",k.ondragleave),h.func(k.ondropmove)&&g.on("dropmove",k.ondropmove),/^(pointer|center)$/.test(k.overlap)?g.options.drop.overlap=k.overlap:h.number(k.overlap)&&(g.options.drop.overlap=Math.max(Math.min(1,k.overlap),0)),"accept"in k&&(g.options.drop.accept=k.accept),"checker"in k&&(g.options.drop.checker=k.checker),g}return h.bool(k)?(g.options.drop.enabled=k,g):g.options.drop}(this,p)},i.prototype.dropCheck=function(p,g,k,A,L,z){return function(Y,ke,Fe,Me,Ke,rt,et){var ht=!1;if(!(et=et||Y.getRect(rt)))return!!Y.options.drop.checker&&Y.options.drop.checker(ke,Fe,ht,Y,rt,Me,Ke);var Et=Y.options.drop.overlap;if(Et==="pointer"){var Nt=se(Me,Ke,"drag"),kt=Ae(ke);kt.x+=Nt.x,kt.y+=Nt.y;var St=kt.x>et.left&&kt.x<et.right,Qt=kt.y>et.top&&kt.y<et.bottom;ht=St&&Qt}var $t=Me.getRect(Ke);if($t&&Et==="center"){var sn=$t.left+$t.width/2,fn=$t.top+$t.height/2;ht=sn>=et.left&&sn<=et.right&&fn>=et.top&&fn<=et.bottom}return $t&&h.number(Et)&&(ht=Math.max(0,Math.min(et.right,$t.right)-Math.max(et.left,$t.left))*Math.max(0,Math.min(et.bottom,$t.bottom)-Math.max(et.top,$t.top))/($t.width*$t.height)>=Et),Y.options.drop.checker&&(ht=Y.options.drop.checker(ke,Fe,ht,Y,rt,Me,Ke)),ht}(this,p,g,k,A,L,z)},o.dynamicDrop=function(p){return h.bool(p)?(n.dynamicDrop=p,o):n.dynamicDrop},N(t.phaselessTypes,{dragenter:!0,dragleave:!0,dropactivate:!0,dropdeactivate:!0,dropmove:!0,drop:!0}),t.methodDict.drop="dropzone",n.dynamicDrop=!1,u.actions.drop=Qe.defaults},listeners:{"interactions:before-action-start":function(n){var t=n.interaction;t.prepared.name==="drag"&&(t.dropState={cur:{dropzone:null,element:null},prev:{dropzone:null,element:null},rejected:null,events:null,activeDrops:[]})},"interactions:after-action-start":function(n,t){var o=n.interaction,i=(n.event,n.iEvent);if(o.prepared.name==="drag"){var u=o.dropState;u.activeDrops=[],u.events={},u.activeDrops=ot(t,o.element),u.events=tt(o,0,i),u.events.activate&&(je(u.activeDrops,u.events.activate),t.fire("actions/drop:start",{interaction:o,dragEvent:i}))}},"interactions:action-move":mt,"interactions:after-action-move":function(n,t){var o=n.interaction,i=n.iEvent;if(o.prepared.name==="drag"){var u=o.dropState;Te(o,u.events),t.fire("actions/drop:move",{interaction:o,dragEvent:i}),u.events={}}},"interactions:action-end":function(n,t){if(n.interaction.prepared.name==="drag"){var o=n.interaction,i=n.iEvent;mt(n,t),Te(o,o.dropState.events),t.fire("actions/drop:end",{interaction:o,dragEvent:i})}},"interactions:stop":function(n){var t=n.interaction;if(t.prepared.name==="drag"){var o=t.dropState;o&&(o.activeDrops=null,o.events=null,o.cur.dropzone=null,o.cur.element=null,o.prev.dropzone=null,o.prev.element=null,o.rejected=!1)}}},getActiveDrops:ot,getDrop:Le,getDropEvents:tt,fireDropEvents:Te,filterEventType:function(n){return n.search("drag")===0||n.search("drop")===0},defaults:{enabled:!1,accept:null,overlap:"pointer"}},Ve=Qe;function it(n){var t=n.interaction,o=n.iEvent,i=n.phase;if(t.prepared.name==="gesture"){var u=t.pointers.map(function(L){return L.pointer}),p=i==="start",g=i==="end",k=t.interactable.options.deltaSource;if(o.touches=[u[0],u[1]],p)o.distance=ie(u,k),o.box=Ee(u),o.scale=1,o.ds=0,o.angle=q(u,k),o.da=0,t.gesture.startDistance=o.distance,t.gesture.startAngle=o.angle;else if(g||t.pointers.length<2){var A=t.prevEvent;o.distance=A.distance,o.box=A.box,o.scale=A.scale,o.ds=0,o.angle=A.angle,o.da=0}else o.distance=ie(u,k),o.box=Ee(u),o.scale=o.distance/t.gesture.startDistance,o.angle=q(u,k),o.ds=o.scale-t.gesture.scale,o.da=o.angle-t.gesture.angle;t.gesture.distance=o.distance,t.gesture.angle=o.angle,h.number(o.scale)&&o.scale!==1/0&&!isNaN(o.scale)&&(t.gesture.scale=o.scale)}}var gt={id:"actions/gesture",before:["actions/drag","actions/resize"],install:function(n){var t=n.actions,o=n.Interactable,i=n.defaults;o.prototype.gesturable=function(u){return h.object(u)?(this.options.gesture.enabled=u.enabled!==!1,this.setPerAction("gesture",u),this.setOnEvents("gesture",u),this):h.bool(u)?(this.options.gesture.enabled=u,this):this.options.gesture},t.map.gesture=gt,t.methodDict.gesture="gesturable",i.actions.gesture=gt.defaults},listeners:{"interactions:action-start":it,"interactions:action-move":it,"interactions:action-end":it,"interactions:new":function(n){n.interaction.gesture={angle:0,distance:0,scale:1,startAngle:0,startDistance:0}},"auto-start:check":function(n){if(!(n.interaction.pointers.length<2)){var t=n.interactable.options.gesture;if(t&&t.enabled)return n.action={name:"gesture"},!1}}},defaults:{},getCursor:function(){return""},filterEventType:function(n){return n.search("gesture")===0}},Ye=gt;function $e(n,t,o,i,u,p,g){if(!t)return!1;if(t===!0){var k=h.number(p.width)?p.width:p.right-p.left,A=h.number(p.height)?p.height:p.bottom-p.top;if(g=Math.min(g,Math.abs((n==="left"||n==="right"?k:A)/2)),k<0&&(n==="left"?n="right":n==="right"&&(n="left")),A<0&&(n==="top"?n="bottom":n==="bottom"&&(n="top")),n==="left"){var L=k>=0?p.left:p.right;return o.x<L+g}if(n==="top"){var z=A>=0?p.top:p.bottom;return o.y<z+g}if(n==="right")return o.x>(k>=0?p.right:p.left)-g;if(n==="bottom")return o.y>(A>=0?p.bottom:p.top)-g}return!!h.element(i)&&(h.element(t)?t===i:ye(i,t,u))}function It(n){var t=n.iEvent,o=n.interaction;if(o.prepared.name==="resize"&&o.resizeAxes){var i=t;o.interactable.options.resize.square?(o.resizeAxes==="y"?i.delta.x=i.delta.y:i.delta.y=i.delta.x,i.axes="xy"):(i.axes=o.resizeAxes,o.resizeAxes==="x"?i.delta.y=0:o.resizeAxes==="y"&&(i.delta.x=0))}}var Se,qe,ze={id:"actions/resize",before:["actions/drag"],install:function(n){var t=n.actions,o=n.browser,i=n.Interactable,u=n.defaults;ze.cursors=function(p){return p.isIe9?{x:"e-resize",y:"s-resize",xy:"se-resize",top:"n-resize",left:"w-resize",bottom:"s-resize",right:"e-resize",topleft:"se-resize",bottomright:"se-resize",topright:"ne-resize",bottomleft:"ne-resize"}:{x:"ew-resize",y:"ns-resize",xy:"nwse-resize",top:"ns-resize",left:"ew-resize",bottom:"ns-resize",right:"ew-resize",topleft:"nwse-resize",bottomright:"nwse-resize",topright:"nesw-resize",bottomleft:"nesw-resize"}}(o),ze.defaultMargin=o.supportsTouch||o.supportsPointerEvent?20:10,i.prototype.resizable=function(p){return function(g,k,A){return h.object(k)?(g.options.resize.enabled=k.enabled!==!1,g.setPerAction("resize",k),g.setOnEvents("resize",k),h.string(k.axis)&&/^x$|^y$|^xy$/.test(k.axis)?g.options.resize.axis=k.axis:k.axis===null&&(g.options.resize.axis=A.defaults.actions.resize.axis),h.bool(k.preserveAspectRatio)?g.options.resize.preserveAspectRatio=k.preserveAspectRatio:h.bool(k.square)&&(g.options.resize.square=k.square),g):h.bool(k)?(g.options.resize.enabled=k,g):g.options.resize}(this,p,n)},t.map.resize=ze,t.methodDict.resize="resizable",u.actions.resize=ze.defaults},listeners:{"interactions:new":function(n){n.interaction.resizeAxes="xy"},"interactions:action-start":function(n){(function(t){var o=t.iEvent,i=t.interaction;if(i.prepared.name==="resize"&&i.prepared.edges){var u=o,p=i.rect;i._rects={start:N({},p),corrected:N({},p),previous:N({},p),delta:{left:0,right:0,width:0,top:0,bottom:0,height:0}},u.edges=i.prepared.edges,u.rect=i._rects.corrected,u.deltaRect=i._rects.delta}})(n),It(n)},"interactions:action-move":function(n){(function(t){var o=t.iEvent,i=t.interaction;if(i.prepared.name==="resize"&&i.prepared.edges){var u=o,p=i.interactable.options.resize.invert,g=p==="reposition"||p==="negate",k=i.rect,A=i._rects,L=A.start,z=A.corrected,Y=A.delta,ke=A.previous;if(N(ke,z),g){if(N(z,k),p==="reposition"){if(z.top>z.bottom){var Fe=z.top;z.top=z.bottom,z.bottom=Fe}if(z.left>z.right){var Me=z.left;z.left=z.right,z.right=Me}}}else z.top=Math.min(k.top,L.bottom),z.bottom=Math.max(k.bottom,L.top),z.left=Math.min(k.left,L.right),z.right=Math.max(k.right,L.left);for(var Ke in z.width=z.right-z.left,z.height=z.bottom-z.top,z)Y[Ke]=z[Ke]-ke[Ke];u.edges=i.prepared.edges,u.rect=z,u.deltaRect=Y}})(n),It(n)},"interactions:action-end":function(n){var t=n.iEvent,o=n.interaction;if(o.prepared.name==="resize"&&o.prepared.edges){var i=t;i.edges=o.prepared.edges,i.rect=o._rects.corrected,i.deltaRect=o._rects.delta}},"auto-start:check":function(n){var t=n.interaction,o=n.interactable,i=n.element,u=n.rect,p=n.buttons;if(u){var g=N({},t.coords.cur.page),k=o.options.resize;if(k&&k.enabled&&(!t.pointerIsDown||!/mouse|pointer/.test(t.pointerType)||(p&k.mouseButtons)!=0)){if(h.object(k.edges)){var A={left:!1,right:!1,top:!1,bottom:!1};for(var L in A)A[L]=$e(L,k.edges[L],g,t._latestPointer.eventTarget,i,u,k.margin||ze.defaultMargin);A.left=A.left&&!A.right,A.top=A.top&&!A.bottom,(A.left||A.right||A.top||A.bottom)&&(n.action={name:"resize",edges:A})}else{var z=k.axis!=="y"&&g.x>u.right-ze.defaultMargin,Y=k.axis!=="x"&&g.y>u.bottom-ze.defaultMargin;(z||Y)&&(n.action={name:"resize",axes:(z?"x":"")+(Y?"y":"")})}return!n.action&&void 0}}}},defaults:{square:!1,preserveAspectRatio:!1,axis:"xy",margin:NaN,edges:null,invert:"none"},cursors:null,getCursor:function(n){var t=n.edges,o=n.axis,i=n.name,u=ze.cursors,p=null;if(o)p=u[i+o];else if(t){for(var g="",k=0,A=["top","bottom","left","right"];k<A.length;k++){var L=A[k];t[L]&&(g+=L)}p=u[g]}return p},filterEventType:function(n){return n.search("resize")===0},defaultMargin:null},Je=ze,S={id:"actions",install:function(n){n.usePlugin(Ye),n.usePlugin(Je),n.usePlugin(xe),n.usePlugin(Ve)}},fe=0,Ue={request:function(n){return Se(n)},cancel:function(n){return qe(n)},init:function(n){if(Se=n.requestAnimationFrame,qe=n.cancelAnimationFrame,!Se)for(var t=["ms","moz","webkit","o"],o=0;o<t.length;o++){var i=t[o];Se=n["".concat(i,"RequestAnimationFrame")],qe=n["".concat(i,"CancelAnimationFrame")]||n["".concat(i,"CancelRequestAnimationFrame")]}Se=Se&&Se.bind(n),qe=qe&&qe.bind(n),Se||(Se=function(u){var p=Date.now(),g=Math.max(0,16-(p-fe)),k=n.setTimeout(function(){u(p+g)},g);return fe=p+g,k},qe=function(u){return clearTimeout(u)})}},he={defaults:{enabled:!1,margin:60,container:null,speed:300},now:Date.now,interaction:null,i:0,x:0,y:0,isScrolling:!1,prevTime:0,margin:0,speed:0,start:function(n){he.isScrolling=!0,Ue.cancel(he.i),n.autoScroll=he,he.interaction=n,he.prevTime=he.now(),he.i=Ue.request(he.scroll)},stop:function(){he.isScrolling=!1,he.interaction&&(he.interaction.autoScroll=null),Ue.cancel(he.i)},scroll:function(){var n=he.interaction,t=n.interactable,o=n.element,i=n.prepared.name,u=t.options[i].autoScroll,p=ut(u.container,t,o),g=he.now(),k=(g-he.prevTime)/1e3,A=u.speed*k;if(A>=1){var L={x:he.x*A,y:he.y*A};if(L.x||L.y){var z=st(p);h.window(p)?p.scrollBy(L.x,L.y):p&&(p.scrollLeft+=L.x,p.scrollTop+=L.y);var Y=st(p),ke={x:Y.x-z.x,y:Y.y-z.y};(ke.x||ke.y)&&t.fire({type:"autoscroll",target:o,interactable:t,delta:ke,interaction:n,container:p})}he.prevTime=g}he.isScrolling&&(Ue.cancel(he.i),he.i=Ue.request(he.scroll))},check:function(n,t){var o;return(o=n.options[t].autoScroll)==null?void 0:o.enabled},onInteractionMove:function(n){var t=n.interaction,o=n.pointer;if(t.interacting()&&he.check(t.interactable,t.prepared.name))if(t.simulation)he.x=he.y=0;else{var i,u,p,g,k=t.interactable,A=t.element,L=t.prepared.name,z=k.options[L].autoScroll,Y=ut(z.container,k,A);if(h.window(Y))g=o.clientX<he.margin,i=o.clientY<he.margin,u=o.clientX>Y.innerWidth-he.margin,p=o.clientY>Y.innerHeight-he.margin;else{var ke=Ce(Y);g=o.clientX<ke.left+he.margin,i=o.clientY<ke.top+he.margin,u=o.clientX>ke.right-he.margin,p=o.clientY>ke.bottom-he.margin}he.x=u?1:g?-1:0,he.y=p?1:i?-1:0,he.isScrolling||(he.margin=z.margin,he.speed=z.speed,he.start(t))}}};function ut(n,t,o){return(h.string(n)?Ge(n,t,o):n)||E(o)}function st(n){return h.window(n)&&(n=window.document.body),{x:n.scrollLeft,y:n.scrollTop}}var xt={id:"auto-scroll",install:function(n){var t=n.defaults,o=n.actions;n.autoScroll=he,he.now=function(){return n.now()},o.phaselessTypes.autoscroll=!0,t.perAction.autoScroll=he.defaults},listeners:{"interactions:new":function(n){n.interaction.autoScroll=null},"interactions:destroy":function(n){n.interaction.autoScroll=null,he.stop(),he.interaction&&(he.interaction=null)},"interactions:stop":he.stop,"interactions:action-move":function(n){return he.onInteractionMove(n)}}},pt=xt;function ct(n,t){var o=!1;return function(){return o||(G.console.warn(t),o=!0),n.apply(this,arguments)}}function ft(n,t){return n.name=t.name,n.axis=t.axis,n.edges=t.edges,n}function wt(n){return h.bool(n)?(this.options.styleCursor=n,this):n===null?(delete this.options.styleCursor,this):this.options.styleCursor}function Tt(n){return h.func(n)?(this.options.actionChecker=n,this):n===null?(delete this.options.actionChecker,this):this.options.actionChecker}var jt={id:"auto-start/interactableMethods",install:function(n){var t=n.Interactable;t.prototype.getAction=function(o,i,u,p){var g=function(k,A,L,z,Y){var ke=k.getRect(z),Fe=A.buttons||{0:1,1:4,3:8,4:16}[A.button],Me={action:null,interactable:k,interaction:L,element:z,rect:ke,buttons:Fe};return Y.fire("auto-start:check",Me),Me.action}(this,i,u,p,n);return this.options.actionChecker?this.options.actionChecker(o,i,g,this,p,u):g},t.prototype.ignoreFrom=ct(function(o){return this._backCompatOption("ignoreFrom",o)},"Interactable.ignoreFrom() has been deprecated. Use Interactble.draggable({ignoreFrom: newValue})."),t.prototype.allowFrom=ct(function(o){return this._backCompatOption("allowFrom",o)},"Interactable.allowFrom() has been deprecated. Use Interactble.draggable({allowFrom: newValue})."),t.prototype.actionChecker=Tt,t.prototype.styleCursor=wt}};function vt(n,t,o,i,u){return t.testIgnoreAllow(t.options[n.name],o,i)&&t.options[n.name].enabled&&Wt(t,o,n,u)?n:null}function Mt(n,t,o,i,u,p,g){for(var k=0,A=i.length;k<A;k++){var L=i[k],z=u[k],Y=L.getAction(t,o,n,z);if(Y){var ke=vt(Y,L,z,p,g);if(ke)return{action:ke,interactable:L,element:z}}}return{action:null,interactable:null,element:null}}function Lt(n,t,o,i,u){var p=[],g=[],k=i;function A(z){p.push(z),g.push(k)}for(;h.element(k);){p=[],g=[],u.interactables.forEachMatch(k,A);var L=Mt(n,t,o,p,g,i,u);if(L.action&&!L.interactable.options[L.action.name].manualStart)return L;k=at(k)}return{action:null,interactable:null,element:null}}function Ut(n,t,o){var i=t.action,u=t.interactable,p=t.element;i=i||{name:null},n.interactable=u,n.element=p,ft(n.prepared,i),n.rect=u&&i.name?u.getRect(p):null,En(n,o),o.fire("autoStart:prepared",{interaction:n})}function Wt(n,t,o,i){var u=n.options,p=u[o.name].max,g=u[o.name].maxPerElement,k=i.autoStart.maxInteractions,A=0,L=0,z=0;if(!(p&&g&&k))return!1;for(var Y=0,ke=i.interactions.list;Y<ke.length;Y++){var Fe=ke[Y],Me=Fe.prepared.name;if(Fe.interacting()&&(++A>=k||Fe.interactable===n&&((L+=Me===o.name?1:0)>=p||Fe.element===t&&(z++,Me===o.name&&z>=g))))return!1}return k>0}function Jt(n,t){return h.number(n)?(t.autoStart.maxInteractions=n,this):t.autoStart.maxInteractions}function Pt(n,t,o){var i=o.autoStart.cursorElement;i&&i!==n&&(i.style.cursor=""),n.ownerDocument.documentElement.style.cursor=t,n.style.cursor=t,o.autoStart.cursorElement=t?n:null}function En(n,t){var o=n.interactable,i=n.element,u=n.prepared;if(n.pointerType==="mouse"&&o&&o.options.styleCursor){var p="";if(u.name){var g=o.options[u.name].cursorChecker;p=h.func(g)?g(u,o,i,n._interacting):t.actions.map[u.name].getCursor(u)}Pt(n.element,p||"",t)}else t.autoStart.cursorElement&&Pt(t.autoStart.cursorElement,"",t)}var zn={id:"auto-start/base",before:["actions"],install:function(n){var t=n.interactStatic,o=n.defaults;n.usePlugin(jt),o.base.actionChecker=null,o.base.styleCursor=!0,N(o.perAction,{manualStart:!1,max:1/0,maxPerElement:1,allowFrom:null,ignoreFrom:null,mouseButtons:1}),t.maxInteractions=function(i){return Jt(i,n)},n.autoStart={maxInteractions:1/0,withinInteractionLimit:Wt,cursorElement:null}},listeners:{"interactions:down":function(n,t){var o=n.interaction,i=n.pointer,u=n.event,p=n.eventTarget;o.interacting()||Ut(o,Lt(o,i,u,p,t),t)},"interactions:move":function(n,t){(function(o,i){var u=o.interaction,p=o.pointer,g=o.event,k=o.eventTarget;u.pointerType!=="mouse"||u.pointerIsDown||u.interacting()||Ut(u,Lt(u,p,g,k,i),i)})(n,t),function(o,i){var u=o.interaction;if(u.pointerIsDown&&!u.interacting()&&u.pointerWasMoved&&u.prepared.name){i.fire("autoStart:before-start",o);var p=u.interactable,g=u.prepared.name;g&&p&&(p.options[g].manualStart||!Wt(p,u.element,u.prepared,i)?u.stop():(u.start(u.prepared,p,u.element),En(u,i)))}}(n,t)},"interactions:stop":function(n,t){var o=n.interaction,i=o.interactable;i&&i.options.styleCursor&&Pt(o.element,"",t)}},maxInteractions:Jt,withinInteractionLimit:Wt,validateAction:vt},gn=zn,Fn={id:"auto-start/dragAxis",listeners:{"autoStart:before-start":function(n,t){var o=n.interaction,i=n.eventTarget,u=n.dx,p=n.dy;if(o.prepared.name==="drag"){var g=Math.abs(u),k=Math.abs(p),A=o.interactable.options.drag,L=A.startAxis,z=g>k?"x":g<k?"y":"xy";if(o.prepared.axis=A.lockAxis==="start"?z[0]:A.lockAxis,z!=="xy"&&L!=="xy"&&L!==z){o.prepared.name=null;for(var Y=i,ke=function(Me){if(Me!==o.interactable){var Ke=o.interactable.options.drag;if(!Ke.manualStart&&Me.testIgnoreAllow(Ke,Y,i)){var rt=Me.getAction(o.downPointer,o.downEvent,o,Y);if(rt&&rt.name==="drag"&&function(et,ht){if(!ht)return!1;var Et=ht.options.drag.startAxis;return et==="xy"||Et==="xy"||Et===et}(z,Me)&&gn.validateAction(rt,Me,Y,i,t))return Me}}};h.element(Y);){var Fe=t.interactables.forEachMatch(Y,ke);if(Fe){o.prepared.name="drag",o.interactable=Fe,o.element=Y;break}Y=at(Y)}}}}}};function yn(n){var t=n.prepared&&n.prepared.name;if(!t)return null;var o=n.interactable.options;return o[t].hold||o[t].delay}var Rn={id:"auto-start/hold",install:function(n){var t=n.defaults;n.usePlugin(gn),t.perAction.hold=0,t.perAction.delay=0},listeners:{"interactions:new":function(n){n.interaction.autoStartHoldTimer=null},"autoStart:prepared":function(n){var t=n.interaction,o=yn(t);o>0&&(t.autoStartHoldTimer=setTimeout(function(){t.start(t.prepared,t.interactable,t.element)},o))},"interactions:move":function(n){var t=n.interaction,o=n.duplicate;t.autoStartHoldTimer&&t.pointerWasMoved&&!o&&(clearTimeout(t.autoStartHoldTimer),t.autoStartHoldTimer=null)},"autoStart:before-start":function(n){var t=n.interaction;yn(t)>0&&(t.prepared.name=null)}},getHoldDuration:yn},Pn=Rn,Ln={id:"auto-start",install:function(n){n.usePlugin(gn),n.usePlugin(Pn),n.usePlugin(Fn)}},$n=function(n){return/^(always|never|auto)$/.test(n)?(this.options.preventDefault=n,this):h.bool(n)?(this.options.preventDefault=n?"always":"never",this):this.options.preventDefault};function jn(n){var t=n.interaction,o=n.event;t.interactable&&t.interactable.checkAndPreventDefault(o)}var Sn={id:"core/interactablePreventDefault",install:function(n){var t=n.Interactable;t.prototype.preventDefault=$n,t.prototype.checkAndPreventDefault=function(o){return function(i,u,p){var g=i.options.preventDefault;if(g!=="never")if(g!=="always"){if(u.events.supportsPassive&&/^touch(start|move)$/.test(p.type)){var k=E(p.target).document,A=u.getDocOptions(k);if(!A||!A.events||A.events.passive!==!1)return}/^(mouse|pointer|touch)*(down|start)/i.test(p.type)||h.element(p.target)&&X(p.target,"input,select,textarea,[contenteditable=true],[contenteditable=true] *")||p.preventDefault()}else p.preventDefault()}(this,n,o)},n.interactions.docEvents.push({type:"dragstart",listener:function(o){for(var i=0,u=n.interactions.list;i<u.length;i++){var p=u[i];if(p.element&&(p.element===o.target||pe(p.element,o.target)))return void p.interactable.checkAndPreventDefault(o)}}})},listeners:["down","move","up","cancel"].reduce(function(n,t){return n["interactions:".concat(t)]=jn,n},{})};function hn(n,t){if(t.phaselessTypes[n])return!0;for(var o in t.map)if(n.indexOf(o)===0&&n.substr(o.length)in t.phases)return!0;return!1}function un(n){var t={};for(var o in n){var i=n[o];h.plainObject(i)?t[o]=un(i):h.array(i)?t[o]=be(i):t[o]=i}return t}var bn=function(){function n(t){c(this,n),this.states=[],this.startOffset={left:0,right:0,top:0,bottom:0},this.startDelta=void 0,this.result=void 0,this.endResult=void 0,this.startEdges=void 0,this.edges=void 0,this.interaction=void 0,this.interaction=t,this.result=vn(),this.edges={left:!1,right:!1,top:!1,bottom:!1}}return v(n,[{key:"start",value:function(t,o){var i,u,p=t.phase,g=this.interaction,k=function(L){var z=L.interactable.options[L.prepared.name],Y=z.modifiers;return Y&&Y.length?Y:["snap","snapSize","snapEdges","restrict","restrictEdges","restrictSize"].map(function(ke){var Fe=z[ke];return Fe&&Fe.enabled&&{options:Fe,methods:Fe._methods}}).filter(function(ke){return!!ke})}(g);this.prepareStates(k),this.startEdges=N({},g.edges),this.edges=N({},this.startEdges),this.startOffset=(i=g.rect,u=o,i?{left:u.x-i.left,top:u.y-i.top,right:i.right-u.x,bottom:i.bottom-u.y}:{left:0,top:0,right:0,bottom:0}),this.startDelta={x:0,y:0};var A=this.fillArg({phase:p,pageCoords:o,preEnd:!1});return this.result=vn(),this.startAll(A),this.result=this.setAll(A)}},{key:"fillArg",value:function(t){var o=this.interaction;return t.interaction=o,t.interactable=o.interactable,t.element=o.element,t.rect||(t.rect=o.rect),t.edges||(t.edges=this.startEdges),t.startOffset=this.startOffset,t}},{key:"startAll",value:function(t){for(var o=0,i=this.states;o<i.length;o++){var u=i[o];u.methods.start&&(t.state=u,u.methods.start(t))}}},{key:"setAll",value:function(t){var o=t.phase,i=t.preEnd,u=t.skipModifiers,p=t.rect,g=t.edges;t.coords=N({},t.pageCoords),t.rect=N({},p),t.edges=N({},g);for(var k=u?this.states.slice(u):this.states,A=vn(t.coords,t.rect),L=0;L<k.length;L++){var z,Y=k[L],ke=Y.options,Fe=N({},t.coords),Me=null;(z=Y.methods)!=null&&z.set&&this.shouldDo(ke,i,o)&&(t.state=Y,Me=Y.methods.set(t),Q(t.edges,t.rect,{x:t.coords.x-Fe.x,y:t.coords.y-Fe.y})),A.eventProps.push(Me)}N(this.edges,t.edges),A.delta.x=t.coords.x-t.pageCoords.x,A.delta.y=t.coords.y-t.pageCoords.y,A.rectDelta.left=t.rect.left-p.left,A.rectDelta.right=t.rect.right-p.right,A.rectDelta.top=t.rect.top-p.top,A.rectDelta.bottom=t.rect.bottom-p.bottom;var Ke=this.result.coords,rt=this.result.rect;if(Ke&&rt){var et=A.rect.left!==rt.left||A.rect.right!==rt.right||A.rect.top!==rt.top||A.rect.bottom!==rt.bottom;A.changed=et||Ke.x!==A.coords.x||Ke.y!==A.coords.y}return A}},{key:"applyToInteraction",value:function(t){var o=this.interaction,i=t.phase,u=o.coords.cur,p=o.coords.start,g=this.result,k=this.startDelta,A=g.delta;i==="start"&&N(this.startDelta,g.delta);for(var L=0,z=[[p,k],[u,A]];L<z.length;L++){var Y=z[L],ke=Y[0],Fe=Y[1];ke.page.x+=Fe.x,ke.page.y+=Fe.y,ke.client.x+=Fe.x,ke.client.y+=Fe.y}var Me=this.result.rectDelta,Ke=t.rect||o.rect;Ke.left+=Me.left,Ke.right+=Me.right,Ke.top+=Me.top,Ke.bottom+=Me.bottom,Ke.width=Ke.right-Ke.left,Ke.height=Ke.bottom-Ke.top}},{key:"setAndApply",value:function(t){var o=this.interaction,i=t.phase,u=t.preEnd,p=t.skipModifiers,g=this.setAll(this.fillArg({preEnd:u,phase:i,pageCoords:t.modifiedCoords||o.coords.cur.page}));if(this.result=g,!g.changed&&(!p||p<this.states.length)&&o.interacting())return!1;if(t.modifiedCoords){var k=o.coords.cur.page,A={x:t.modifiedCoords.x-k.x,y:t.modifiedCoords.y-k.y};g.coords.x+=A.x,g.coords.y+=A.y,g.delta.x+=A.x,g.delta.y+=A.y}this.applyToInteraction(t)}},{key:"beforeEnd",value:function(t){var o=t.interaction,i=t.event,u=this.states;if(u&&u.length){for(var p=!1,g=0;g<u.length;g++){var k=u[g];t.state=k;var A=k.options,L=k.methods,z=L.beforeEnd&&L.beforeEnd(t);if(z)return this.endResult=z,!1;p=p||!p&&this.shouldDo(A,!0,t.phase,!0)}p&&o.move({event:i,preEnd:!0})}}},{key:"stop",value:function(t){var o=t.interaction;if(this.states&&this.states.length){var i=N({states:this.states,interactable:o.interactable,element:o.element,rect:null},t);this.fillArg(i);for(var u=0,p=this.states;u<p.length;u++){var g=p[u];i.state=g,g.methods.stop&&g.methods.stop(i)}this.states=null,this.endResult=null}}},{key:"prepareStates",value:function(t){this.states=[];for(var o=0;o<t.length;o++){var i=t[o],u=i.options,p=i.methods,g=i.name;this.states.push({options:u,methods:p,index:o,name:g})}return this.states}},{key:"restoreInteractionCoords",value:function(t){var o=t.interaction,i=o.coords,u=o.rect,p=o.modification;if(p.result){for(var g=p.startDelta,k=p.result,A=k.delta,L=k.rectDelta,z=0,Y=[[i.start,g],[i.cur,A]];z<Y.length;z++){var ke=Y[z],Fe=ke[0],Me=ke[1];Fe.page.x-=Me.x,Fe.page.y-=Me.y,Fe.client.x-=Me.x,Fe.client.y-=Me.y}u.left-=L.left,u.right-=L.right,u.top-=L.top,u.bottom-=L.bottom}}},{key:"shouldDo",value:function(t,o,i,u){return!(!t||t.enabled===!1||u&&!t.endOnly||t.endOnly&&!o||i==="start"&&!t.setStart)}},{key:"copyFrom",value:function(t){this.startOffset=t.startOffset,this.startDelta=t.startDelta,this.startEdges=t.startEdges,this.edges=t.edges,this.states=t.states.map(function(o){return un(o)}),this.result=vn(N({},t.result.coords),N({},t.result.rect))}},{key:"destroy",value:function(){for(var t in this)this[t]=null}}]),n}();function vn(n,t){return{rect:t,coords:n,delta:{x:0,y:0},rectDelta:{left:0,right:0,top:0,bottom:0},eventProps:[],changed:!0}}function nn(n,t){var o=n.defaults,i={start:n.start,set:n.set,beforeEnd:n.beforeEnd,stop:n.stop},u=function(p){var g=p||{};for(var k in g.enabled=g.enabled!==!1,o)k in g||(g[k]=o[k]);var A={options:g,methods:i,name:t,enable:function(){return g.enabled=!0,A},disable:function(){return g.enabled=!1,A}};return A};return t&&typeof t=="string"&&(u._defaults=o,u._methods=i),u}function pn(n){var t=n.iEvent,o=n.interaction.modification.result;o&&(t.modifiers=o.eventProps)}var Un={id:"modifiers/base",before:["actions"],install:function(n){n.defaults.perAction.modifiers=[]},listeners:{"interactions:new":function(n){var t=n.interaction;t.modification=new bn(t)},"interactions:before-action-start":function(n){var t=n.interaction,o=n.interaction.modification;o.start(n,t.coords.start.page),t.edges=o.edges,o.applyToInteraction(n)},"interactions:before-action-move":function(n){var t=n.interaction,o=t.modification,i=o.setAndApply(n);return t.edges=o.edges,i},"interactions:before-action-end":function(n){var t=n.interaction,o=t.modification,i=o.beforeEnd(n);return t.edges=o.startEdges,i},"interactions:action-start":pn,"interactions:action-move":pn,"interactions:action-end":pn,"interactions:after-action-start":function(n){return n.interaction.modification.restoreInteractionCoords(n)},"interactions:after-action-move":function(n){return n.interaction.modification.restoreInteractionCoords(n)},"interactions:stop":function(n){return n.interaction.modification.stop(n)}}},Tn=Un,Bn={base:{preventDefault:"auto",deltaSource:"page"},perAction:{enabled:!1,origin:{x:0,y:0}},actions:{}},kn=function(n){D(o,n);var t=H(o);function o(i,u,p,g,k,A,L){var z;c(this,o),(z=t.call(this,i)).relatedTarget=null,z.screenX=void 0,z.screenY=void 0,z.button=void 0,z.buttons=void 0,z.ctrlKey=void 0,z.shiftKey=void 0,z.altKey=void 0,z.metaKey=void 0,z.page=void 0,z.client=void 0,z.delta=void 0,z.rect=void 0,z.x0=void 0,z.y0=void 0,z.t0=void 0,z.dt=void 0,z.duration=void 0,z.clientX0=void 0,z.clientY0=void 0,z.velocity=void 0,z.speed=void 0,z.swipe=void 0,z.axes=void 0,z.preEnd=void 0,k=k||i.element;var Y=i.interactable,ke=(Y&&Y.options||Bn).deltaSource,Fe=se(Y,k,p),Me=g==="start",Ke=g==="end",rt=Me?R(z):i.prevEvent,et=Me?i.coords.start:Ke?{page:rt.page,client:rt.client,timeStamp:i.coords.cur.timeStamp}:i.coords.cur;return z.page=N({},et.page),z.client=N({},et.client),z.rect=N({},i.rect),z.timeStamp=et.timeStamp,Ke||(z.page.x-=Fe.x,z.page.y-=Fe.y,z.client.x-=Fe.x,z.client.y-=Fe.y),z.ctrlKey=u.ctrlKey,z.altKey=u.altKey,z.shiftKey=u.shiftKey,z.metaKey=u.metaKey,z.button=u.button,z.buttons=u.buttons,z.target=k,z.currentTarget=k,z.preEnd=A,z.type=L||p+(g||""),z.interactable=Y,z.t0=Me?i.pointers[i.pointers.length-1].downTime:rt.t0,z.x0=i.coords.start.page.x-Fe.x,z.y0=i.coords.start.page.y-Fe.y,z.clientX0=i.coords.start.client.x-Fe.x,z.clientY0=i.coords.start.client.y-Fe.y,z.delta=Me||Ke?{x:0,y:0}:{x:z[ke].x-rt[ke].x,y:z[ke].y-rt[ke].y},z.dt=i.coords.delta.timeStamp,z.duration=z.timeStamp-z.t0,z.velocity=N({},i.coords.velocity[ke]),z.speed=dt(z.velocity.x,z.velocity.y),z.swipe=Ke||g==="inertiastart"?z.getSwipe():null,z}return v(o,[{key:"getSwipe",value:function(){var i=this._interaction;if(i.prevEvent.speed<600||this.timeStamp-i.prevEvent.timeStamp>150)return null;var u=180*Math.atan2(i.prevEvent.velocityY,i.prevEvent.velocityX)/Math.PI;u<0&&(u+=360);var p=112.5<=u&&u<247.5,g=202.5<=u&&u<337.5;return{up:g,down:!g&&22.5<=u&&u<157.5,left:p,right:!p&&(292.5<=u||u<67.5),angle:u,speed:i.prevEvent.speed,velocity:{x:i.prevEvent.velocityX,y:i.prevEvent.velocityY}}}},{key:"preventDefault",value:function(){}},{key:"stopImmediatePropagation",value:function(){this.immediatePropagationStopped=this.propagationStopped=!0}},{key:"stopPropagation",value:function(){this.propagationStopped=!0}}]),o}(me);Object.defineProperties(kn.prototype,{pageX:{get:function(){return this.page.x},set:function(n){this.page.x=n}},pageY:{get:function(){return this.page.y},set:function(n){this.page.y=n}},clientX:{get:function(){return this.client.x},set:function(n){this.client.x=n}},clientY:{get:function(){return this.client.y},set:function(n){this.client.y=n}},dx:{get:function(){return this.delta.x},set:function(n){this.delta.x=n}},dy:{get:function(){return this.delta.y},set:function(n){this.delta.y=n}},velocityX:{get:function(){return this.velocity.x},set:function(n){this.velocity.x=n}},velocityY:{get:function(){return this.velocity.y},set:function(n){this.velocity.y=n}}});var Kn=v(function n(t,o,i,u,p){c(this,n),this.id=void 0,this.pointer=void 0,this.event=void 0,this.downTime=void 0,this.downTarget=void 0,this.id=t,this.pointer=o,this.event=i,this.downTime=u,this.downTarget=p}),Wn=function(n){return n.interactable="",n.element="",n.prepared="",n.pointerIsDown="",n.pointerWasMoved="",n._proxy="",n}({}),In=function(n){return n.start="",n.move="",n.end="",n.stop="",n.interacting="",n}({}),Hn=0,qn=function(){function n(t){var o=this,i=t.pointerType,u=t.scopeFire;c(this,n),this.interactable=null,this.element=null,this.rect=null,this._rects=void 0,this.edges=null,this._scopeFire=void 0,this.prepared={name:null,axis:null,edges:null},this.pointerType=void 0,this.pointers=[],this.downEvent=null,this.downPointer={},this._latestPointer={pointer:null,event:null,eventTarget:null},this.prevEvent=null,this.pointerIsDown=!1,this.pointerWasMoved=!1,this._interacting=!1,this._ending=!1,this._stopped=!0,this._proxy=void 0,this.simulation=null,this.doMove=ct(function(z){this.move(z)},"The interaction.doMove() method has been renamed to interaction.move()"),this.coords={start:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},prev:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},cur:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},delta:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0},velocity:{page:{x:0,y:0},client:{x:0,y:0},timeStamp:0}},this._id=Hn++,this._scopeFire=u,this.pointerType=i;var p=this;this._proxy={};var g=function(z){Object.defineProperty(o._proxy,z,{get:function(){return p[z]}})};for(var k in Wn)g(k);var A=function(z){Object.defineProperty(o._proxy,z,{value:function(){return p[z].apply(p,arguments)}})};for(var L in In)A(L);this._scopeFire("interactions:new",{interaction:this})}return v(n,[{key:"pointerMoveTolerance",get:function(){return 1}},{key:"pointerDown",value:function(t,o,i){var u=this.updatePointer(t,o,i,!0),p=this.pointers[u];this._scopeFire("interactions:down",{pointer:t,event:o,eventTarget:i,pointerIndex:u,pointerInfo:p,type:"down",interaction:this})}},{key:"start",value:function(t,o,i){return!(this.interacting()||!this.pointerIsDown||this.pointers.length<(t.name==="gesture"?2:1)||!o.options[t.name].enabled)&&(ft(this.prepared,t),this.interactable=o,this.element=i,this.rect=o.getRect(i),this.edges=this.prepared.edges?N({},this.prepared.edges):{left:!0,right:!0,top:!0,bottom:!0},this._stopped=!1,this._interacting=this._doPhase({interaction:this,event:this.downEvent,phase:"start"})&&!this._stopped,this._interacting)}},{key:"pointerMove",value:function(t,o,i){this.simulation||this.modification&&this.modification.endResult||this.updatePointer(t,o,i,!1);var u,p,g=this.coords.cur.page.x===this.coords.prev.page.x&&this.coords.cur.page.y===this.coords.prev.page.y&&this.coords.cur.client.x===this.coords.prev.client.x&&this.coords.cur.client.y===this.coords.prev.client.y;this.pointerIsDown&&!this.pointerWasMoved&&(u=this.coords.cur.client.x-this.coords.start.client.x,p=this.coords.cur.client.y-this.coords.start.client.y,this.pointerWasMoved=dt(u,p)>this.pointerMoveTolerance);var k,A,L,z=this.getPointerIndex(t),Y={pointer:t,pointerIndex:z,pointerInfo:this.pointers[z],event:o,type:"move",eventTarget:i,dx:u,dy:p,duplicate:g,interaction:this};g||(k=this.coords.velocity,A=this.coords.delta,L=Math.max(A.timeStamp/1e3,.001),k.page.x=A.page.x/L,k.page.y=A.page.y/L,k.client.x=A.client.x/L,k.client.y=A.client.y/L,k.timeStamp=L),this._scopeFire("interactions:move",Y),g||this.simulation||(this.interacting()&&(Y.type=null,this.move(Y)),this.pointerWasMoved&&U(this.coords.prev,this.coords.cur))}},{key:"move",value:function(t){t&&t.event||J(this.coords.delta),(t=N({pointer:this._latestPointer.pointer,event:this._latestPointer.event,eventTarget:this._latestPointer.eventTarget,interaction:this},t||{})).phase="move",this._doPhase(t)}},{key:"pointerUp",value:function(t,o,i,u){var p=this.getPointerIndex(t);p===-1&&(p=this.updatePointer(t,o,i,!1));var g=/cancel$/i.test(o.type)?"cancel":"up";this._scopeFire("interactions:".concat(g),{pointer:t,pointerIndex:p,pointerInfo:this.pointers[p],event:o,eventTarget:i,type:g,curEventTarget:u,interaction:this}),this.simulation||this.end(o),this.removePointer(t,o)}},{key:"documentBlur",value:function(t){this.end(t),this._scopeFire("interactions:blur",{event:t,type:"blur",interaction:this})}},{key:"end",value:function(t){var o;this._ending=!0,t=t||this._latestPointer.event,this.interacting()&&(o=this._doPhase({event:t,interaction:this,phase:"end"})),this._ending=!1,o===!0&&this.stop()}},{key:"currentAction",value:function(){return this._interacting?this.prepared.name:null}},{key:"interacting",value:function(){return this._interacting}},{key:"stop",value:function(){this._scopeFire("interactions:stop",{interaction:this}),this.interactable=this.element=null,this._interacting=!1,this._stopped=!0,this.prepared.name=this.prevEvent=null}},{key:"getPointerIndex",value:function(t){var o=I(t);return this.pointerType==="mouse"||this.pointerType==="pen"?this.pointers.length-1:j(this.pointers,function(i){return i.id===o})}},{key:"getPointerInfo",value:function(t){return this.pointers[this.getPointerIndex(t)]}},{key:"updatePointer",value:function(t,o,i,u){var p,g,k,A=I(t),L=this.getPointerIndex(t),z=this.pointers[L];return u=u!==!1&&(u||/(down|start)$/i.test(o.type)),z?z.pointer=t:(z=new Kn(A,t,o,null,null),L=this.pointers.length,this.pointers.push(z)),ee(this.coords.cur,this.pointers.map(function(Y){return Y.pointer}),this._now()),p=this.coords.delta,g=this.coords.prev,k=this.coords.cur,p.page.x=k.page.x-g.page.x,p.page.y=k.page.y-g.page.y,p.client.x=k.client.x-g.client.x,p.client.y=k.client.y-g.client.y,p.timeStamp=k.timeStamp-g.timeStamp,u&&(this.pointerIsDown=!0,z.downTime=this.coords.cur.timeStamp,z.downTarget=i,T(this.downPointer,t),this.interacting()||(U(this.coords.start,this.coords.cur),U(this.coords.prev,this.coords.cur),this.downEvent=o,this.pointerWasMoved=!1)),this._updateLatestPointer(t,o,i),this._scopeFire("interactions:update-pointer",{pointer:t,event:o,eventTarget:i,down:u,pointerInfo:z,pointerIndex:L,interaction:this}),L}},{key:"removePointer",value:function(t,o){var i=this.getPointerIndex(t);if(i!==-1){var u=this.pointers[i];this._scopeFire("interactions:remove-pointer",{pointer:t,event:o,eventTarget:null,pointerIndex:i,pointerInfo:u,interaction:this}),this.pointers.splice(i,1),this.pointerIsDown=!1}}},{key:"_updateLatestPointer",value:function(t,o,i){this._latestPointer.pointer=t,this._latestPointer.event=o,this._latestPointer.eventTarget=i}},{key:"destroy",value:function(){this._latestPointer.pointer=null,this._latestPointer.event=null,this._latestPointer.eventTarget=null}},{key:"_createPreparedEvent",value:function(t,o,i,u){return new kn(this,t,this.prepared.name,o,this.element,i,u)}},{key:"_fireEvent",value:function(t){var o;(o=this.interactable)==null||o.fire(t),(!this.prevEvent||t.timeStamp>=this.prevEvent.timeStamp)&&(this.prevEvent=t)}},{key:"_doPhase",value:function(t){var o=t.event,i=t.phase,u=t.preEnd,p=t.type,g=this.rect;if(g&&i==="move"&&(Q(this.edges,g,this.coords.delta[this.interactable.options.deltaSource]),g.width=g.right-g.left,g.height=g.bottom-g.top),this._scopeFire("interactions:before-action-".concat(i),t)===!1)return!1;var k=t.iEvent=this._createPreparedEvent(o,i,u,p);return this._scopeFire("interactions:action-".concat(i),t),i==="start"&&(this.prevEvent=k),this._fireEvent(k),this._scopeFire("interactions:after-action-".concat(i),t),!0}},{key:"_now",value:function(){return Date.now()}}]),n}();function _t(n){Yt(n.interaction)}function Yt(n){if(!function(o){return!(!o.offset.pending.x&&!o.offset.pending.y)}(n))return!1;var t=n.offset.pending;return Ot(n.coords.cur,t),Ot(n.coords.delta,t),Q(n.edges,n.rect,t),t.x=0,t.y=0,!0}function yt(n){var t=n.x,o=n.y;this.offset.pending.x+=t,this.offset.pending.y+=o,this.offset.total.x+=t,this.offset.total.y+=o}function Ot(n,t){var o=n.page,i=n.client,u=t.x,p=t.y;o.x+=u,o.y+=p,i.x+=u,i.y+=p}In.offsetBy="";var bt={id:"offset",before:["modifiers","pointer-events","actions","inertia"],install:function(n){n.Interaction.prototype.offsetBy=yt},listeners:{"interactions:new":function(n){n.interaction.offset={total:{x:0,y:0},pending:{x:0,y:0}}},"interactions:update-pointer":function(n){return function(t){t.pointerIsDown&&(Ot(t.coords.cur,t.offset.total),t.offset.pending.x=0,t.offset.pending.y=0)}(n.interaction)},"interactions:before-action-start":_t,"interactions:before-action-move":_t,"interactions:before-action-end":function(n){var t=n.interaction;if(Yt(t))return t.move({offset:!0}),t.end(),!1},"interactions:stop":function(n){var t=n.interaction;t.offset.total.x=0,t.offset.total.y=0,t.offset.pending.x=0,t.offset.pending.y=0}}},Kt=bt,Dt=function(){function n(t){c(this,n),this.active=!1,this.isModified=!1,this.smoothEnd=!1,this.allowResume=!1,this.modification=void 0,this.modifierCount=0,this.modifierArg=void 0,this.startCoords=void 0,this.t0=0,this.v0=0,this.te=0,this.targetOffset=void 0,this.modifiedOffset=void 0,this.currentOffset=void 0,this.lambda_v0=0,this.one_ve_v0=0,this.timeout=void 0,this.interaction=void 0,this.interaction=t}return v(n,[{key:"start",value:function(t){var o=this.interaction,i=Ct(o);if(!i||!i.enabled)return!1;var u=o.coords.velocity.client,p=dt(u.x,u.y),g=this.modification||(this.modification=new bn(o));if(g.copyFrom(o.modification),this.t0=o._now(),this.allowResume=i.allowResume,this.v0=p,this.currentOffset={x:0,y:0},this.startCoords=o.coords.cur.page,this.modifierArg=g.fillArg({pageCoords:this.startCoords,preEnd:!0,phase:"inertiastart"}),this.t0-o.coords.cur.timeStamp<50&&p>i.minSpeed&&p>i.endSpeed)this.startInertia();else{if(g.result=g.setAll(this.modifierArg),!g.result.changed)return!1;this.startSmoothEnd()}return o.modification.result.rect=null,o.offsetBy(this.targetOffset),o._doPhase({interaction:o,event:t,phase:"inertiastart"}),o.offsetBy({x:-this.targetOffset.x,y:-this.targetOffset.y}),o.modification.result.rect=null,this.active=!0,o.simulation=this,!0}},{key:"startInertia",value:function(){var t=this,o=this.interaction.coords.velocity.client,i=Ct(this.interaction),u=i.resistance,p=-Math.log(i.endSpeed/this.v0)/u;this.targetOffset={x:(o.x-p)/u,y:(o.y-p)/u},this.te=p,this.lambda_v0=u/this.v0,this.one_ve_v0=1-i.endSpeed/this.v0;var g=this.modification,k=this.modifierArg;k.pageCoords={x:this.startCoords.x+this.targetOffset.x,y:this.startCoords.y+this.targetOffset.y},g.result=g.setAll(k),g.result.changed&&(this.isModified=!0,this.modifiedOffset={x:this.targetOffset.x+g.result.delta.x,y:this.targetOffset.y+g.result.delta.y}),this.onNextFrame(function(){return t.inertiaTick()})}},{key:"startSmoothEnd",value:function(){var t=this;this.smoothEnd=!0,this.isModified=!0,this.targetOffset={x:this.modification.result.delta.x,y:this.modification.result.delta.y},this.onNextFrame(function(){return t.smoothEndTick()})}},{key:"onNextFrame",value:function(t){var o=this;this.timeout=Ue.request(function(){o.active&&t()})}},{key:"inertiaTick",value:function(){var t,o,i,u,p,g,k,A=this,L=this.interaction,z=Ct(L).resistance,Y=(L._now()-this.t0)/1e3;if(Y<this.te){var ke,Fe=1-(Math.exp(-z*Y)-this.lambda_v0)/this.one_ve_v0;this.isModified?(t=0,o=0,i=this.targetOffset.x,u=this.targetOffset.y,p=this.modifiedOffset.x,g=this.modifiedOffset.y,ke={x:Vt(k=Fe,t,i,p),y:Vt(k,o,u,g)}):ke={x:this.targetOffset.x*Fe,y:this.targetOffset.y*Fe};var Me={x:ke.x-this.currentOffset.x,y:ke.y-this.currentOffset.y};this.currentOffset.x+=Me.x,this.currentOffset.y+=Me.y,L.offsetBy(Me),L.move(),this.onNextFrame(function(){return A.inertiaTick()})}else L.offsetBy({x:this.modifiedOffset.x-this.currentOffset.x,y:this.modifiedOffset.y-this.currentOffset.y}),this.end()}},{key:"smoothEndTick",value:function(){var t=this,o=this.interaction,i=o._now()-this.t0,u=Ct(o).smoothEndDuration;if(i<u){var p={x:Ft(i,0,this.targetOffset.x,u),y:Ft(i,0,this.targetOffset.y,u)},g={x:p.x-this.currentOffset.x,y:p.y-this.currentOffset.y};this.currentOffset.x+=g.x,this.currentOffset.y+=g.y,o.offsetBy(g),o.move({skipModifiers:this.modifierCount}),this.onNextFrame(function(){return t.smoothEndTick()})}else o.offsetBy({x:this.targetOffset.x-this.currentOffset.x,y:this.targetOffset.y-this.currentOffset.y}),this.end()}},{key:"resume",value:function(t){var o=t.pointer,i=t.event,u=t.eventTarget,p=this.interaction;p.offsetBy({x:-this.currentOffset.x,y:-this.currentOffset.y}),p.updatePointer(o,i,u,!0),p._doPhase({interaction:p,event:i,phase:"resume"}),U(p.coords.prev,p.coords.cur),this.stop()}},{key:"end",value:function(){this.interaction.move(),this.interaction.end(),this.stop()}},{key:"stop",value:function(){this.active=this.smoothEnd=!1,this.interaction.simulation=null,Ue.cancel(this.timeout)}}]),n}();function Ct(n){var t=n.interactable,o=n.prepared;return t&&t.options&&o.name&&t.options[o.name].inertia}var zt={id:"inertia",before:["modifiers","actions"],install:function(n){var t=n.defaults;n.usePlugin(Kt),n.usePlugin(Tn),n.actions.phases.inertiastart=!0,n.actions.phases.resume=!0,t.perAction.inertia={enabled:!1,resistance:10,minSpeed:100,endSpeed:10,allowResume:!0,smoothEndDuration:300}},listeners:{"interactions:new":function(n){var t=n.interaction;t.inertia=new Dt(t)},"interactions:before-action-end":function(n){var t=n.interaction,o=n.event;return(!t._interacting||t.simulation||!t.inertia.start(o))&&null},"interactions:down":function(n){var t=n.interaction,o=n.eventTarget,i=t.inertia;if(i.active)for(var u=o;h.element(u);){if(u===t.element){i.resume(n);break}u=at(u)}},"interactions:stop":function(n){var t=n.interaction.inertia;t.active&&t.stop()},"interactions:before-action-resume":function(n){var t=n.interaction.modification;t.stop(n),t.start(n,n.interaction.coords.cur.page),t.applyToInteraction(n)},"interactions:before-action-inertiastart":function(n){return n.interaction.modification.setAndApply(n)},"interactions:action-resume":pn,"interactions:action-inertiastart":pn,"interactions:after-action-inertiastart":function(n){return n.interaction.modification.restoreInteractionCoords(n)},"interactions:after-action-resume":function(n){return n.interaction.modification.restoreInteractionCoords(n)}}};function Vt(n,t,o,i){var u=1-n;return u*u*t+2*u*n*o+n*n*i}function Ft(n,t,o,i){return-o*(n/=i)*(n-2)+t}var Ht=zt;function an(n,t){for(var o=0;o<t.length;o++){var i=t[o];if(n.immediatePropagationStopped)break;i(n)}}var Nn=function(){function n(t){c(this,n),this.options=void 0,this.types={},this.propagationStopped=!1,this.immediatePropagationStopped=!1,this.global=void 0,this.options=N({},t||{})}return v(n,[{key:"fire",value:function(t){var o,i=this.global;(o=this.types[t.type])&&an(t,o),!t.propagationStopped&&i&&(o=i[t.type])&&an(t,o)}},{key:"on",value:function(t,o){var i=_e(t,o);for(t in i)this.types[t]=we(this.types[t]||[],i[t])}},{key:"off",value:function(t,o){var i=_e(t,o);for(t in i){var u=this.types[t];if(u&&u.length)for(var p=0,g=i[t];p<g.length;p++){var k=g[p],A=u.indexOf(k);A!==-1&&u.splice(A,1)}}}},{key:"getRect",value:function(t){return null}}]),n}(),Gn=function(){function n(t){c(this,n),this.currentTarget=void 0,this.originalEvent=void 0,this.type=void 0,this.originalEvent=t,T(this,t)}return v(n,[{key:"preventOriginalDefault",value:function(){this.originalEvent.preventDefault()}},{key:"stopPropagation",value:function(){this.originalEvent.stopPropagation()}},{key:"stopImmediatePropagation",value:function(){this.originalEvent.stopImmediatePropagation()}}]),n}();function An(n){return h.object(n)?{capture:!!n.capture,passive:!!n.passive}:{capture:!!n,passive:!1}}function Xn(n,t){return n===t||(typeof n=="boolean"?!!t.capture===n&&!t.passive:!!n.capture==!!t.capture&&!!n.passive==!!t.passive)}var Ea={id:"events",install:function(n){var t,o=[],i={},u=[],p={add:g,remove:k,addDelegate:function(z,Y,ke,Fe,Me){var Ke=An(Me);if(!i[ke]){i[ke]=[];for(var rt=0;rt<u.length;rt++){var et=u[rt];g(et,ke,A),g(et,ke,L,!0)}}var ht=i[ke],Et=Oe(ht,function(Nt){return Nt.selector===z&&Nt.context===Y});Et||(Et={selector:z,context:Y,listeners:[]},ht.push(Et)),Et.listeners.push({func:Fe,options:Ke})},removeDelegate:function(z,Y,ke,Fe,Me){var Ke,rt=An(Me),et=i[ke],ht=!1;if(et)for(Ke=et.length-1;Ke>=0;Ke--){var Et=et[Ke];if(Et.selector===z&&Et.context===Y){for(var Nt=Et.listeners,kt=Nt.length-1;kt>=0;kt--){var St=Nt[kt];if(St.func===Fe&&Xn(St.options,rt)){Nt.splice(kt,1),Nt.length||(et.splice(Ke,1),k(Y,ke,A),k(Y,ke,L,!0)),ht=!0;break}}if(ht)break}}},delegateListener:A,delegateUseCapture:L,delegatedEvents:i,documents:u,targets:o,supportsOptions:!1,supportsPassive:!1};function g(z,Y,ke,Fe){if(z.addEventListener){var Me=An(Fe),Ke=Oe(o,function(rt){return rt.eventTarget===z});Ke||(Ke={eventTarget:z,events:{}},o.push(Ke)),Ke.events[Y]||(Ke.events[Y]=[]),Oe(Ke.events[Y],function(rt){return rt.func===ke&&Xn(rt.options,Me)})||(z.addEventListener(Y,ke,p.supportsOptions?Me:Me.capture),Ke.events[Y].push({func:ke,options:Me}))}}function k(z,Y,ke,Fe){if(z.addEventListener&&z.removeEventListener){var Me=j(o,function(Qt){return Qt.eventTarget===z}),Ke=o[Me];if(Ke&&Ke.events)if(Y!=="all"){var rt=!1,et=Ke.events[Y];if(et){if(ke==="all"){for(var ht=et.length-1;ht>=0;ht--){var Et=et[ht];k(z,Y,Et.func,Et.options)}return}for(var Nt=An(Fe),kt=0;kt<et.length;kt++){var St=et[kt];if(St.func===ke&&Xn(St.options,Nt)){z.removeEventListener(Y,ke,p.supportsOptions?Nt:Nt.capture),et.splice(kt,1),et.length===0&&(delete Ke.events[Y],rt=!0);break}}}rt&&!Object.keys(Ke.events).length&&o.splice(Me,1)}else for(Y in Ke.events)Ke.events.hasOwnProperty(Y)&&k(z,Y,"all")}}function A(z,Y){for(var ke=An(Y),Fe=new Gn(z),Me=i[z.type],Ke=de(z)[0],rt=Ke;h.element(rt);){for(var et=0;et<Me.length;et++){var ht=Me[et],Et=ht.selector,Nt=ht.context;if(X(rt,Et)&&pe(Nt,Ke)&&pe(Nt,rt)){var kt=ht.listeners;Fe.currentTarget=rt;for(var St=0;St<kt.length;St++){var Qt=kt[St];Xn(Qt.options,ke)&&Qt.func(Fe)}}}rt=at(rt)}}function L(z){return A(z,!0)}return(t=n.document)==null||t.createElement("div").addEventListener("test",null,{get capture(){return p.supportsOptions=!0},get passive(){return p.supportsPassive=!0}}),n.events=p,p}},oa={methodOrder:["simulationResume","mouseOrPen","hasPointer","idle"],search:function(n){for(var t=0,o=oa.methodOrder;t<o.length;t++){var i=o[t],u=oa[i](n);if(u)return u}return null},simulationResume:function(n){var t=n.pointerType,o=n.eventType,i=n.eventTarget,u=n.scope;if(!/down|start/i.test(o))return null;for(var p=0,g=u.interactions.list;p<g.length;p++){var k=g[p],A=i;if(k.simulation&&k.simulation.allowResume&&k.pointerType===t)for(;A;){if(A===k.element)return k;A=at(A)}}return null},mouseOrPen:function(n){var t,o=n.pointerId,i=n.pointerType,u=n.eventType,p=n.scope;if(i!=="mouse"&&i!=="pen")return null;for(var g=0,k=p.interactions.list;g<k.length;g++){var A=k[g];if(A.pointerType===i){if(A.simulation&&!ha(A,o))continue;if(A.interacting())return A;t||(t=A)}}if(t)return t;for(var L=0,z=p.interactions.list;L<z.length;L++){var Y=z[L];if(!(Y.pointerType!==i||/down/i.test(u)&&Y.simulation))return Y}return null},hasPointer:function(n){for(var t=n.pointerId,o=0,i=n.scope.interactions.list;o<i.length;o++){var u=i[o];if(ha(u,t))return u}return null},idle:function(n){for(var t=n.pointerType,o=0,i=n.scope.interactions.list;o<i.length;o++){var u=i[o];if(u.pointers.length===1){var p=u.interactable;if(p&&(!p.options.gesture||!p.options.gesture.enabled))continue}else if(u.pointers.length>=2)continue;if(!u.interacting()&&t===u.pointerType)return u}return null}};function ha(n,t){return n.pointers.some(function(o){return o.id===t})}var ra=oa,dn=["pointerDown","pointerMove","pointerUp","updatePointer","removePointer","windowBlur"];function Yn(n,t){return function(o){var i=t.interactions.list,u=Z(o),p=de(o),g=p[0],k=p[1],A=[];if(/^touch/.test(o.type)){t.prevTouchTime=t.now();for(var L=0,z=o.changedTouches;L<z.length;L++){var Y=z[L],ke={pointer:Y,pointerId:I(Y),pointerType:u,eventType:o.type,eventTarget:g,curEventTarget:k,scope:t},Fe=la(ke);A.push([ke.pointer,ke.eventTarget,ke.curEventTarget,Fe])}}else{var Me=!1;if(!ne.supportsPointerEvent&&/mouse/.test(o.type)){for(var Ke=0;Ke<i.length&&!Me;Ke++)Me=i[Ke].pointerType!=="mouse"&&i[Ke].pointerIsDown;Me=Me||t.now()-t.prevTouchTime<500||o.timeStamp===0}if(!Me){var rt={pointer:o,pointerId:I(o),pointerType:u,eventType:o.type,curEventTarget:k,eventTarget:g,scope:t},et=la(rt);A.push([rt.pointer,rt.eventTarget,rt.curEventTarget,et])}}for(var ht=0;ht<A.length;ht++){var Et=A[ht],Nt=Et[0],kt=Et[1],St=Et[2];Et[3][n](Nt,o,kt,St)}}}function la(n){var t=n.pointerType,o=n.scope,i={interaction:ra.search(n),searchDetails:n};return o.fire("interactions:find",i),i.interaction||o.interactions.new({pointerType:t})}function on(n,t){var o=n.doc,i=n.scope,u=n.options,p=i.interactions.docEvents,g=i.events,k=g[t];for(var A in i.browser.isIOS&&!u.events&&(u.events={passive:!1}),g.delegatedEvents)k(o,A,g.delegateListener),k(o,A,g.delegateUseCapture,!0);for(var L=u&&u.events,z=0;z<p.length;z++){var Y=p[z];k(o,Y.type,Y.listener,L)}}var Sa={id:"core/interactions",install:function(n){for(var t={},o=0;o<dn.length;o++){var i=dn[o];t[i]=Yn(i,n)}var u,p=ne.pEventTypes;function g(){for(var k=0,A=n.interactions.list;k<A.length;k++){var L=A[k];if(L.pointerIsDown&&L.pointerType==="touch"&&!L._interacting)for(var z=function(){var Fe=ke[Y];n.documents.some(function(Me){return pe(Me.doc,Fe.downTarget)})||L.removePointer(Fe.pointer,Fe.event)},Y=0,ke=L.pointers;Y<ke.length;Y++)z()}}(u=P.PointerEvent?[{type:p.down,listener:g},{type:p.down,listener:t.pointerDown},{type:p.move,listener:t.pointerMove},{type:p.up,listener:t.pointerUp},{type:p.cancel,listener:t.pointerUp}]:[{type:"mousedown",listener:t.pointerDown},{type:"mousemove",listener:t.pointerMove},{type:"mouseup",listener:t.pointerUp},{type:"touchstart",listener:g},{type:"touchstart",listener:t.pointerDown},{type:"touchmove",listener:t.pointerMove},{type:"touchend",listener:t.pointerUp},{type:"touchcancel",listener:t.pointerUp}]).push({type:"blur",listener:function(k){for(var A=0,L=n.interactions.list;A<L.length;A++)L[A].documentBlur(k)}}),n.prevTouchTime=0,n.Interaction=function(k){D(L,k);var A=H(L);function L(){return c(this,L),A.apply(this,arguments)}return v(L,[{key:"pointerMoveTolerance",get:function(){return n.interactions.pointerMoveTolerance},set:function(z){n.interactions.pointerMoveTolerance=z}},{key:"_now",value:function(){return n.now()}}]),L}(qn),n.interactions={list:[],new:function(k){k.scopeFire=function(L,z){return n.fire(L,z)};var A=new n.Interaction(k);return n.interactions.list.push(A),A},listeners:t,docEvents:u,pointerMoveTolerance:1},n.usePlugin(Sn)},listeners:{"scope:add-document":function(n){return on(n,"add")},"scope:remove-document":function(n){return on(n,"remove")},"interactable:unset":function(n,t){for(var o=n.interactable,i=t.interactions.list.length-1;i>=0;i--){var u=t.interactions.list[i];u.interactable===o&&(u.stop(),t.fire("interactions:destroy",{interaction:u}),u.destroy(),t.interactions.list.length>2&&t.interactions.list.splice(i,1))}}},onDocSignal:on,doOnInteractions:Yn,methodNames:dn},Vn=Sa,On=function(n){return n[n.On=0]="On",n[n.Off=1]="Off",n}(On||{}),rl=function(){function n(t,o,i,u){c(this,n),this.target=void 0,this.options=void 0,this._actions=void 0,this.events=new Nn,this._context=void 0,this._win=void 0,this._doc=void 0,this._scopeEvents=void 0,this._actions=o.actions,this.target=t,this._context=o.context||i,this._win=E(De(t)?this._context:t),this._doc=this._win.document,this._scopeEvents=u,this.set(o)}return v(n,[{key:"_defaults",get:function(){return{base:{},perAction:{},actions:{}}}},{key:"setOnEvents",value:function(t,o){return h.func(o.onstart)&&this.on("".concat(t,"start"),o.onstart),h.func(o.onmove)&&this.on("".concat(t,"move"),o.onmove),h.func(o.onend)&&this.on("".concat(t,"end"),o.onend),h.func(o.oninertiastart)&&this.on("".concat(t,"inertiastart"),o.oninertiastart),this}},{key:"updatePerActionListeners",value:function(t,o,i){var u,p=this,g=(u=this._actions.map[t])==null?void 0:u.filterEventType,k=function(A){return(g==null||g(A))&&hn(A,p._actions)};(h.array(o)||h.object(o))&&this._onOff(On.Off,t,o,void 0,k),(h.array(i)||h.object(i))&&this._onOff(On.On,t,i,void 0,k)}},{key:"setPerAction",value:function(t,o){var i=this._defaults;for(var u in o){var p=u,g=this.options[t],k=o[p];p==="listeners"&&this.updatePerActionListeners(t,g.listeners,k),h.array(k)?g[p]=be(k):h.plainObject(k)?(g[p]=N(g[p]||{},un(k)),h.object(i.perAction[p])&&"enabled"in i.perAction[p]&&(g[p].enabled=k.enabled!==!1)):h.bool(k)&&h.object(i.perAction[p])?g[p].enabled=k:g[p]=k}}},{key:"getRect",value:function(t){return t=t||(h.element(this.target)?this.target:null),h.string(this.target)&&(t=t||this._context.querySelector(this.target)),Ze(t)}},{key:"rectChecker",value:function(t){var o=this;return h.func(t)?(this.getRect=function(i){var u=N({},t.apply(o,i));return"width"in u||(u.width=u.right-u.left,u.height=u.bottom-u.top),u},this):t===null?(delete this.getRect,this):this.getRect}},{key:"_backCompatOption",value:function(t,o){if(De(o)||h.object(o)){for(var i in this.options[t]=o,this._actions.map)this.options[i][t]=o;return this}return this.options[t]}},{key:"origin",value:function(t){return this._backCompatOption("origin",t)}},{key:"deltaSource",value:function(t){return t==="page"||t==="client"?(this.options.deltaSource=t,this):this.options.deltaSource}},{key:"getAllElements",value:function(){var t=this.target;return h.string(t)?Array.from(this._context.querySelectorAll(t)):h.func(t)&&t.getAllElements?t.getAllElements():h.element(t)?[t]:[]}},{key:"context",value:function(){return this._context}},{key:"inContext",value:function(t){return this._context===t.ownerDocument||pe(this._context,t)}},{key:"testIgnoreAllow",value:function(t,o,i){return!this.testIgnore(t.ignoreFrom,o,i)&&this.testAllow(t.allowFrom,o,i)}},{key:"testAllow",value:function(t,o,i){return!t||!!h.element(i)&&(h.string(t)?ye(i,t,o):!!h.element(t)&&pe(t,i))}},{key:"testIgnore",value:function(t,o,i){return!(!t||!h.element(i))&&(h.string(t)?ye(i,t,o):!!h.element(t)&&pe(t,i))}},{key:"fire",value:function(t){return this.events.fire(t),this}},{key:"_onOff",value:function(t,o,i,u,p){h.object(o)&&!h.array(o)&&(u=i,i=null);var g=_e(o,i,p);for(var k in g){k==="wheel"&&(k=ne.wheelEvent);for(var A=0,L=g[k];A<L.length;A++){var z=L[A];hn(k,this._actions)?this.events[t===On.On?"on":"off"](k,z):h.string(this.target)?this._scopeEvents[t===On.On?"addDelegate":"removeDelegate"](this.target,this._context,k,z,u):this._scopeEvents[t===On.On?"add":"remove"](this.target,k,z,u)}}return this}},{key:"on",value:function(t,o,i){return this._onOff(On.On,t,o,i)}},{key:"off",value:function(t,o,i){return this._onOff(On.Off,t,o,i)}},{key:"set",value:function(t){var o=this._defaults;for(var i in h.object(t)||(t={}),this.options=un(o.base),this._actions.methodDict){var u=i,p=this._actions.methodDict[u];this.options[u]={},this.setPerAction(u,N(N({},o.perAction),o.actions[u])),this[p](t[u])}for(var g in t)g!=="getRect"?h.func(this[g])&&this[g](t[g]):this.rectChecker(t.getRect);return this}},{key:"unset",value:function(){if(h.string(this.target))for(var t in this._scopeEvents.delegatedEvents)for(var o=this._scopeEvents.delegatedEvents[t],i=o.length-1;i>=0;i--){var u=o[i],p=u.selector,g=u.context,k=u.listeners;p===this.target&&g===this._context&&o.splice(i,1);for(var A=k.length-1;A>=0;A--)this._scopeEvents.removeDelegate(this.target,this._context,t,k[A][0],k[A][1])}else this._scopeEvents.remove(this.target,"all")}}]),n}(),ll=function(){function n(t){var o=this;c(this,n),this.list=[],this.selectorMap={},this.scope=void 0,this.scope=t,t.addListeners({"interactable:unset":function(i){var u=i.interactable,p=u.target,g=h.string(p)?o.selectorMap[p]:p[o.scope.id],k=j(g,function(A){return A===u});g.splice(k,1)}})}return v(n,[{key:"new",value:function(t,o){o=N(o||{},{actions:this.scope.actions});var i=new this.scope.Interactable(t,o,this.scope.document,this.scope.events);return this.scope.addDocument(i._doc),this.list.push(i),h.string(t)?(this.selectorMap[t]||(this.selectorMap[t]=[]),this.selectorMap[t].push(i)):(i.target[this.scope.id]||Object.defineProperty(t,this.scope.id,{value:[],configurable:!0}),t[this.scope.id].push(i)),this.scope.fire("interactable:new",{target:t,options:o,interactable:i,win:this.scope._win}),i}},{key:"getExisting",value:function(t,o){var i=o&&o.context||this.scope.document,u=h.string(t),p=u?this.selectorMap[t]:t[this.scope.id];if(p)return Oe(p,function(g){return g._context===i&&(u||g.inContext(t))})}},{key:"forEachMatch",value:function(t,o){for(var i=0,u=this.list;i<u.length;i++){var p=u[i],g=void 0;if((h.string(p.target)?h.element(t)&&X(t,p.target):t===p.target)&&p.inContext(t)&&(g=o(p)),g!==void 0)return g}}}]),n}(),il=function(){function n(){var t=this;c(this,n),this.id="__interact_scope_".concat(Math.floor(100*Math.random())),this.isInitialized=!1,this.listenerMaps=[],this.browser=ne,this.defaults=un(Bn),this.Eventable=Nn,this.actions={map:{},phases:{start:!0,move:!0,end:!0},methodDict:{},phaselessTypes:{}},this.interactStatic=function(i){var u=function p(g,k){var A=i.interactables.getExisting(g,k);return A||((A=i.interactables.new(g,k)).events.global=p.globalEvents),A};return u.getPointerAverage=W,u.getTouchBBox=Ee,u.getTouchDistance=ie,u.getTouchAngle=q,u.getElementRect=Ze,u.getElementClientRect=Ce,u.matchesSelector=X,u.closest=We,u.globalEvents={},u.version="1.10.27",u.scope=i,u.use=function(p,g){return this.scope.usePlugin(p,g),this},u.isSet=function(p,g){return!!this.scope.interactables.get(p,g&&g.context)},u.on=ct(function(p,g,k){if(h.string(p)&&p.search(" ")!==-1&&(p=p.trim().split(/ +/)),h.array(p)){for(var A=0,L=p;A<L.length;A++){var z=L[A];this.on(z,g,k)}return this}if(h.object(p)){for(var Y in p)this.on(Y,p[Y],g);return this}return hn(p,this.scope.actions)?this.globalEvents[p]?this.globalEvents[p].push(g):this.globalEvents[p]=[g]:this.scope.events.add(this.scope.document,p,g,{options:k}),this},"The interact.on() method is being deprecated"),u.off=ct(function(p,g,k){if(h.string(p)&&p.search(" ")!==-1&&(p=p.trim().split(/ +/)),h.array(p)){for(var A=0,L=p;A<L.length;A++){var z=L[A];this.off(z,g,k)}return this}if(h.object(p)){for(var Y in p)this.off(Y,p[Y],g);return this}var ke;return hn(p,this.scope.actions)?p in this.globalEvents&&(ke=this.globalEvents[p].indexOf(g))!==-1&&this.globalEvents[p].splice(ke,1):this.scope.events.remove(this.scope.document,p,g,k),this},"The interact.off() method is being deprecated"),u.debug=function(){return this.scope},u.supportsTouch=function(){return ne.supportsTouch},u.supportsPointerEvent=function(){return ne.supportsPointerEvent},u.stop=function(){for(var p=0,g=this.scope.interactions.list;p<g.length;p++)g[p].stop();return this},u.pointerMoveTolerance=function(p){return h.number(p)?(this.scope.interactions.pointerMoveTolerance=p,this):this.scope.interactions.pointerMoveTolerance},u.addDocument=function(p,g){this.scope.addDocument(p,g)},u.removeDocument=function(p){this.scope.removeDocument(p)},u}(this),this.InteractEvent=kn,this.Interactable=void 0,this.interactables=new ll(this),this._win=void 0,this.document=void 0,this.window=void 0,this.documents=[],this._plugins={list:[],map:{}},this.onWindowUnload=function(i){return t.removeDocument(i.target)};var o=this;this.Interactable=function(i){D(p,i);var u=H(p);function p(){return c(this,p),u.apply(this,arguments)}return v(p,[{key:"_defaults",get:function(){return o.defaults}},{key:"set",value:function(g){return M(C(p.prototype),"set",this).call(this,g),o.fire("interactable:set",{options:g,interactable:this}),this}},{key:"unset",value:function(){M(C(p.prototype),"unset",this).call(this);var g=o.interactables.list.indexOf(this);g<0||(o.interactables.list.splice(g,1),o.fire("interactable:unset",{interactable:this}))}}]),p}(rl)}return v(n,[{key:"addListeners",value:function(t,o){this.listenerMaps.push({id:o,map:t})}},{key:"fire",value:function(t,o){for(var i=0,u=this.listenerMaps;i<u.length;i++){var p=u[i].map[t];if(p&&p(o,this,t)===!1)return!1}}},{key:"init",value:function(t){return this.isInitialized?this:function(o,i){return o.isInitialized=!0,h.window(i)&&b(i),P.init(i),ne.init(i),Ue.init(i),o.window=i,o.document=i.document,o.usePlugin(Vn),o.usePlugin(Ea),o}(this,t)}},{key:"pluginIsInstalled",value:function(t){var o=t.id;return o?!!this._plugins.map[o]:this._plugins.list.indexOf(t)!==-1}},{key:"usePlugin",value:function(t,o){if(!this.isInitialized)return this;if(this.pluginIsInstalled(t))return this;if(t.id&&(this._plugins.map[t.id]=t),this._plugins.list.push(t),t.install&&t.install(this,o),t.listeners&&t.before){for(var i=0,u=this.listenerMaps.length,p=t.before.reduce(function(k,A){return k[A]=!0,k[vo(A)]=!0,k},{});i<u;i++){var g=this.listenerMaps[i].id;if(g&&(p[g]||p[vo(g)]))break}this.listenerMaps.splice(i,0,{id:t.id,map:t.listeners})}else t.listeners&&this.listenerMaps.push({id:t.id,map:t.listeners});return this}},{key:"addDocument",value:function(t,o){if(this.getDocIndex(t)!==-1)return!1;var i=E(t);o=o?N({},o):{},this.documents.push({doc:t,options:o}),this.events.documents.push(t),t!==this.document&&this.events.add(i,"unload",this.onWindowUnload),this.fire("scope:add-document",{doc:t,window:i,scope:this,options:o})}},{key:"removeDocument",value:function(t){var o=this.getDocIndex(t),i=E(t),u=this.documents[o].options;this.events.remove(i,"unload",this.onWindowUnload),this.documents.splice(o,1),this.events.documents.splice(o,1),this.fire("scope:remove-document",{doc:t,window:i,scope:this,options:u})}},{key:"getDocIndex",value:function(t){for(var o=0;o<this.documents.length;o++)if(this.documents[o].doc===t)return o;return-1}},{key:"getDocOptions",value:function(t){var o=this.getDocIndex(t);return o===-1?null:this.documents[o].options}},{key:"now",value:function(){return(this.window.Date||Date).now()}}]),n}();function vo(n){return n&&n.replace(/\/.*$/,"")}var mo=new il,Zt=mo.interactStatic,sl=typeof globalThis<"u"?globalThis:window;mo.init(sl);var cl=Object.freeze({__proto__:null,edgeTarget:function(){},elements:function(){},grid:function(n){var t=[["x","y"],["left","top"],["right","bottom"],["width","height"]].filter(function(i){var u=i[0],p=i[1];return u in n||p in n}),o=function(i,u){for(var p=n.range,g=n.limits,k=g===void 0?{left:-1/0,right:1/0,top:-1/0,bottom:1/0}:g,A=n.offset,L=A===void 0?{x:0,y:0}:A,z={range:p,grid:n,x:null,y:null},Y=0;Y<t.length;Y++){var ke=t[Y],Fe=ke[0],Me=ke[1],Ke=Math.round((i-L.x)/n[Fe]),rt=Math.round((u-L.y)/n[Me]);z[Fe]=Math.max(k.left,Math.min(k.right,Ke*n[Fe]+L.x)),z[Me]=Math.max(k.top,Math.min(k.bottom,rt*n[Me]+L.y))}return z};return o.grid=n,o.coordFields=t,o}}),ul={id:"snappers",install:function(n){var t=n.interactStatic;t.snappers=N(t.snappers||{},cl),t.createSnapGrid=t.snappers.grid}},dl=ul,pl={start:function(n){var t=n.state,o=n.rect,i=n.edges,u=n.pageCoords,p=t.options,g=p.ratio,k=p.enabled,A=t.options,L=A.equalDelta,z=A.modifiers;g==="preserve"&&(g=o.width/o.height),t.startCoords=N({},u),t.startRect=N({},o),t.ratio=g,t.equalDelta=L;var Y=t.linkedEdges={top:i.top||i.left&&!i.bottom,left:i.left||i.top&&!i.right,bottom:i.bottom||i.right&&!i.top,right:i.right||i.bottom&&!i.left};if(t.xIsPrimaryAxis=!(!i.left&&!i.right),t.equalDelta){var ke=(Y.left?1:-1)*(Y.top?1:-1);t.edgeSign={x:ke,y:ke}}else t.edgeSign={x:Y.left?-1:1,y:Y.top?-1:1};if(k!==!1&&N(i,Y),z!=null&&z.length){var Fe=new bn(n.interaction);Fe.copyFrom(n.interaction.modification),Fe.prepareStates(z),t.subModification=Fe,Fe.startAll(r({},n))}},set:function(n){var t=n.state,o=n.rect,i=n.coords,u=t.linkedEdges,p=N({},i),g=t.equalDelta?fl:hl;if(N(n.edges,u),g(t,t.xIsPrimaryAxis,i,o),!t.subModification)return null;var k=N({},o);Q(u,k,{x:i.x-p.x,y:i.y-p.y});var A=t.subModification.setAll(r(r({},n),{},{rect:k,edges:u,pageCoords:i,prevCoords:i,prevRect:k})),L=A.delta;return A.changed&&(g(t,Math.abs(L.x)>Math.abs(L.y),A.coords,A.rect),N(i,A.coords)),A.eventProps},defaults:{ratio:"preserve",equalDelta:!1,modifiers:[],enabled:!1}};function fl(n,t,o){var i=n.startCoords,u=n.edgeSign;t?o.y=i.y+(o.x-i.x)*u.y:o.x=i.x+(o.y-i.y)*u.x}function hl(n,t,o,i){var u=n.startRect,p=n.startCoords,g=n.ratio,k=n.edgeSign;if(t){var A=i.width/g;o.y=p.y+(A-u.height)*k.y}else{var L=i.height*g;o.x=p.x+(L-u.width)*k.x}}var vl=nn(pl,"aspectRatio"),go=function(){};go._defaults={};var Ta=go;function Jn(n,t,o){return h.func(n)?Xe(n,t.interactable,t.element,[o.x,o.y,t]):Xe(n,t.interactable,t.element)}var Ba={start:function(n){var t=n.rect,o=n.startOffset,i=n.state,u=n.interaction,p=n.pageCoords,g=i.options,k=g.elementRect,A=N({left:0,top:0,right:0,bottom:0},g.offset||{});if(t&&k){var L=Jn(g.restriction,u,p);if(L){var z=L.right-L.left-t.width,Y=L.bottom-L.top-t.height;z<0&&(A.left+=z,A.right+=z),Y<0&&(A.top+=Y,A.bottom+=Y)}A.left+=o.left-t.width*k.left,A.top+=o.top-t.height*k.top,A.right+=o.right-t.width*(1-k.right),A.bottom+=o.bottom-t.height*(1-k.bottom)}i.offset=A},set:function(n){var t=n.coords,o=n.interaction,i=n.state,u=i.options,p=i.offset,g=Jn(u.restriction,o,t);if(g){var k=function(A){return!A||"left"in A&&"top"in A||((A=N({},A)).left=A.x||0,A.top=A.y||0,A.right=A.right||A.left+A.width,A.bottom=A.bottom||A.top+A.height),A}(g);t.x=Math.max(Math.min(k.right-p.right,t.x),k.left+p.left),t.y=Math.max(Math.min(k.bottom-p.bottom,t.y),k.top+p.top)}},defaults:{restriction:null,elementRect:null,offset:null,endOnly:!1,enabled:!1}},ml=nn(Ba,"restrict"),yo={top:1/0,left:1/0,bottom:-1/0,right:-1/0},bo={top:-1/0,left:-1/0,bottom:1/0,right:1/0};function ko(n,t){for(var o=0,i=["top","left","bottom","right"];o<i.length;o++){var u=i[o];u in n||(n[u]=t[u])}return n}var va={noInner:yo,noOuter:bo,start:function(n){var t,o=n.interaction,i=n.startOffset,u=n.state,p=u.options;p&&(t=Be(Jn(p.offset,o,o.coords.start.page))),t=t||{x:0,y:0},u.offset={top:t.y+i.top,left:t.x+i.left,bottom:t.y-i.bottom,right:t.x-i.right}},set:function(n){var t=n.coords,o=n.edges,i=n.interaction,u=n.state,p=u.offset,g=u.options;if(o){var k=N({},t),A=Jn(g.inner,i,k)||{},L=Jn(g.outer,i,k)||{};ko(A,yo),ko(L,bo),o.top?t.y=Math.min(Math.max(L.top+p.top,k.y),A.top+p.top):o.bottom&&(t.y=Math.max(Math.min(L.bottom+p.bottom,k.y),A.bottom+p.bottom)),o.left?t.x=Math.min(Math.max(L.left+p.left,k.x),A.left+p.left):o.right&&(t.x=Math.max(Math.min(L.right+p.right,k.x),A.right+p.right))}},defaults:{inner:null,outer:null,offset:null,endOnly:!1,enabled:!1}},gl=nn(va,"restrictEdges"),yl=N({get elementRect(){return{top:0,left:0,bottom:1,right:1}},set elementRect(n){}},Ba.defaults),bl=nn({start:Ba.start,set:Ba.set,defaults:yl},"restrictRect"),kl={width:-1/0,height:-1/0},xl={width:1/0,height:1/0},wl=nn({start:function(n){return va.start(n)},set:function(n){var t=n.interaction,o=n.state,i=n.rect,u=n.edges,p=o.options;if(u){var g=le(Jn(p.min,t,n.coords))||kl,k=le(Jn(p.max,t,n.coords))||xl;o.options={endOnly:p.endOnly,inner:N({},va.noInner),outer:N({},va.noOuter)},u.top?(o.options.inner.top=i.bottom-g.height,o.options.outer.top=i.bottom-k.height):u.bottom&&(o.options.inner.bottom=i.top+g.height,o.options.outer.bottom=i.top+k.height),u.left?(o.options.inner.left=i.right-g.width,o.options.outer.left=i.right-k.width):u.right&&(o.options.inner.right=i.left+g.width,o.options.outer.right=i.left+k.width),va.set(n),o.options=p}},defaults:{min:null,max:null,endOnly:!1,enabled:!1}},"restrictSize"),Ya={start:function(n){var t,o=n.interaction,i=n.interactable,u=n.element,p=n.rect,g=n.state,k=n.startOffset,A=g.options,L=A.offsetWithOrigin?function(ke){var Fe=ke.interaction.element,Me=Be(Xe(ke.state.options.origin,null,null,[Fe])),Ke=Me||se(ke.interactable,Fe,ke.interaction.prepared.name);return Ke}(n):{x:0,y:0};if(A.offset==="startCoords")t={x:o.coords.start.page.x,y:o.coords.start.page.y};else{var z=Xe(A.offset,i,u,[o]);(t=Be(z)||{x:0,y:0}).x+=L.x,t.y+=L.y}var Y=A.relativePoints;g.offsets=p&&Y&&Y.length?Y.map(function(ke,Fe){return{index:Fe,relativePoint:ke,x:k.left-p.width*ke.x+t.x,y:k.top-p.height*ke.y+t.y}}):[{index:0,relativePoint:null,x:t.x,y:t.y}]},set:function(n){var t=n.interaction,o=n.coords,i=n.state,u=i.options,p=i.offsets,g=se(t.interactable,t.element,t.prepared.name),k=N({},o),A=[];u.offsetWithOrigin||(k.x-=g.x,k.y-=g.y);for(var L=0,z=p;L<z.length;L++)for(var Y=z[L],ke=k.x-Y.x,Fe=k.y-Y.y,Me=0,Ke=u.targets.length;Me<Ke;Me++){var rt=u.targets[Me],et=void 0;(et=h.func(rt)?rt(ke,Fe,t._proxy,Y,Me):rt)&&A.push({x:(h.number(et.x)?et.x:ke)+Y.x,y:(h.number(et.y)?et.y:Fe)+Y.y,range:h.number(et.range)?et.range:u.range,source:rt,index:Me,offset:Y})}for(var ht={target:null,inRange:!1,distance:0,range:0,delta:{x:0,y:0}},Et=0;Et<A.length;Et++){var Nt=A[Et],kt=Nt.range,St=Nt.x-k.x,Qt=Nt.y-k.y,$t=dt(St,Qt),sn=$t<=kt;kt===1/0&&ht.inRange&&ht.range!==1/0&&(sn=!1),ht.target&&!(sn?ht.inRange&&kt!==1/0?$t/kt<ht.distance/ht.range:kt===1/0&&ht.range!==1/0||$t<ht.distance:!ht.inRange&&$t<ht.distance)||(ht.target=Nt,ht.distance=$t,ht.range=kt,ht.inRange=sn,ht.delta.x=St,ht.delta.y=Qt)}return ht.inRange&&(o.x=ht.target.x,o.y=ht.target.y),i.closest=ht,ht},defaults:{range:1/0,targets:null,offset:null,offsetWithOrigin:!0,origin:null,relativePoints:null,endOnly:!1,enabled:!1}},Cl=nn(Ya,"snap"),Ia={start:function(n){var t=n.state,o=n.edges,i=t.options;if(!o)return null;n.state={options:{targets:null,relativePoints:[{x:o.left?0:1,y:o.top?0:1}],offset:i.offset||"self",origin:{x:0,y:0},range:i.range}},t.targetFields=t.targetFields||[["width","height"],["x","y"]],Ya.start(n),t.offsets=n.state.offsets,n.state=t},set:function(n){var t=n.interaction,o=n.state,i=n.coords,u=o.options,p=o.offsets,g={x:i.x-p[0].x,y:i.y-p[0].y};o.options=N({},u),o.options.targets=[];for(var k=0,A=u.targets||[];k<A.length;k++){var L=A[k],z=void 0;if(z=h.func(L)?L(g.x,g.y,t):L){for(var Y=0,ke=o.targetFields;Y<ke.length;Y++){var Fe=ke[Y],Me=Fe[0],Ke=Fe[1];if(Me in z||Ke in z){z.x=z[Me],z.y=z[Ke];break}}o.options.targets.push(z)}}var rt=Ya.set(n);return o.options=u,rt},defaults:{range:1/0,targets:null,offset:null,endOnly:!1,enabled:!1}},Dl=nn(Ia,"snapSize"),Ja={aspectRatio:vl,restrictEdges:gl,restrict:ml,restrictRect:bl,restrictSize:wl,snapEdges:nn({start:function(n){var t=n.edges;return t?(n.state.targetFields=n.state.targetFields||[[t.left?"left":"right",t.top?"top":"bottom"]],Ia.start(n)):null},set:Ia.set,defaults:N(un(Ia.defaults),{targets:void 0,range:void 0,offset:{x:0,y:0}})},"snapEdges"),snap:Cl,snapSize:Dl,spring:Ta,avoid:Ta,transform:Ta,rubberband:Ta},_l={id:"modifiers",install:function(n){var t=n.interactStatic;for(var o in n.usePlugin(Tn),n.usePlugin(dl),t.modifiers=Ja,Ja){var i=Ja[o],u=i._defaults,p=i._methods;u._methods=p,n.defaults.perAction[o]=u}}},El=_l,xo=function(n){D(o,n);var t=H(o);function o(i,u,p,g,k,A){var L;if(c(this,o),T(R(L=t.call(this,k)),p),p!==u&&T(R(L),u),L.timeStamp=A,L.originalEvent=p,L.type=i,L.pointerId=I(u),L.pointerType=Z(u),L.target=g,L.currentTarget=null,i==="tap"){var z=k.getPointerIndex(u);L.dt=L.timeStamp-k.pointers[z].downTime;var Y=L.timeStamp-k.tapTime;L.double=!!k.prevTap&&k.prevTap.type!=="doubletap"&&k.prevTap.target===L.target&&Y<500}else i==="doubletap"&&(L.dt=u.timeStamp-k.tapTime,L.double=!0);return L}return v(o,[{key:"_subtractOrigin",value:function(i){var u=i.x,p=i.y;return this.pageX-=u,this.pageY-=p,this.clientX-=u,this.clientY-=p,this}},{key:"_addOrigin",value:function(i){var u=i.x,p=i.y;return this.pageX+=u,this.pageY+=p,this.clientX+=u,this.clientY+=p,this}},{key:"preventDefault",value:function(){this.originalEvent.preventDefault()}}]),o}(me),ma={id:"pointer-events/base",before:["inertia","modifiers","auto-start","actions"],install:function(n){n.pointerEvents=ma,n.defaults.actions.pointerEvents=ma.defaults,N(n.actions.phaselessTypes,ma.types)},listeners:{"interactions:new":function(n){var t=n.interaction;t.prevTap=null,t.tapTime=0},"interactions:update-pointer":function(n){var t=n.down,o=n.pointerInfo;!t&&o.hold||(o.hold={duration:1/0,timeout:null})},"interactions:move":function(n,t){var o=n.interaction,i=n.pointer,u=n.event,p=n.eventTarget;n.duplicate||o.pointerIsDown&&!o.pointerWasMoved||(o.pointerIsDown&&Za(n),Mn({interaction:o,pointer:i,event:u,eventTarget:p,type:"move"},t))},"interactions:down":function(n,t){(function(o,i){for(var u=o.interaction,p=o.pointer,g=o.event,k=o.eventTarget,A=o.pointerIndex,L=u.pointers[A].hold,z=ae(k),Y={interaction:u,pointer:p,event:g,eventTarget:k,type:"hold",targets:[],path:z,node:null},ke=0;ke<z.length;ke++){var Fe=z[ke];Y.node=Fe,i.fire("pointerEvents:collect-targets",Y)}if(Y.targets.length){for(var Me=1/0,Ke=0,rt=Y.targets;Ke<rt.length;Ke++){var et=rt[Ke].eventable.options.holdDuration;et<Me&&(Me=et)}L.duration=Me,L.timeout=setTimeout(function(){Mn({interaction:u,eventTarget:k,pointer:p,event:g,type:"hold"},i)},Me)}})(n,t),Mn(n,t)},"interactions:up":function(n,t){Za(n),Mn(n,t),function(o,i){var u=o.interaction,p=o.pointer,g=o.event,k=o.eventTarget;u.pointerWasMoved||Mn({interaction:u,eventTarget:k,pointer:p,event:g,type:"tap"},i)}(n,t)},"interactions:cancel":function(n,t){Za(n),Mn(n,t)}},PointerEvent:xo,fire:Mn,collectEventTargets:wo,defaults:{holdDuration:600,ignoreFrom:null,allowFrom:null,origin:{x:0,y:0}},types:{down:!0,move:!0,up:!0,cancel:!0,tap:!0,doubletap:!0,hold:!0}};function Mn(n,t){var o=n.interaction,i=n.pointer,u=n.event,p=n.eventTarget,g=n.type,k=n.targets,A=k===void 0?wo(n,t):k,L=new xo(g,i,u,p,o,t.now());t.fire("pointerEvents:new",{pointerEvent:L});for(var z={interaction:o,pointer:i,event:u,eventTarget:p,targets:A,type:g,pointerEvent:L},Y=0;Y<A.length;Y++){var ke=A[Y];for(var Fe in ke.props||{})L[Fe]=ke.props[Fe];var Me=se(ke.eventable,ke.node);if(L._subtractOrigin(Me),L.eventable=ke.eventable,L.currentTarget=ke.node,ke.eventable.fire(L),L._addOrigin(Me),L.immediatePropagationStopped||L.propagationStopped&&Y+1<A.length&&A[Y+1].node!==L.currentTarget)break}if(t.fire("pointerEvents:fired",z),g==="tap"){var Ke=L.double?Mn({interaction:o,pointer:i,event:u,eventTarget:p,type:"doubletap"},t):L;o.prevTap=Ke,o.tapTime=Ke.timeStamp}return L}function wo(n,t){var o=n.interaction,i=n.pointer,u=n.event,p=n.eventTarget,g=n.type,k=o.getPointerIndex(i),A=o.pointers[k];if(g==="tap"&&(o.pointerWasMoved||!A||A.downTarget!==p))return[];for(var L=ae(p),z={interaction:o,pointer:i,event:u,eventTarget:p,type:g,path:L,targets:[],node:null},Y=0;Y<L.length;Y++){var ke=L[Y];z.node=ke,t.fire("pointerEvents:collect-targets",z)}return g==="hold"&&(z.targets=z.targets.filter(function(Fe){var Me,Ke;return Fe.eventable.options.holdDuration===((Me=o.pointers[k])==null||(Ke=Me.hold)==null?void 0:Ke.duration)})),z.targets}function Za(n){var t=n.interaction,o=n.pointerIndex,i=t.pointers[o].hold;i&&i.timeout&&(clearTimeout(i.timeout),i.timeout=null)}var Sl=Object.freeze({__proto__:null,default:ma});function Tl(n){var t=n.interaction;t.holdIntervalHandle&&(clearInterval(t.holdIntervalHandle),t.holdIntervalHandle=null)}var Bl={id:"pointer-events/holdRepeat",install:function(n){n.usePlugin(ma);var t=n.pointerEvents;t.defaults.holdRepeatInterval=0,t.types.holdrepeat=n.actions.phaselessTypes.holdrepeat=!0},listeners:["move","up","cancel","endall"].reduce(function(n,t){return n["pointerEvents:".concat(t)]=Tl,n},{"pointerEvents:new":function(n){var t=n.pointerEvent;t.type==="hold"&&(t.count=(t.count||0)+1)},"pointerEvents:fired":function(n,t){var o=n.interaction,i=n.pointerEvent,u=n.eventTarget,p=n.targets;if(i.type==="hold"&&p.length){var g=p[0].eventable.options.holdRepeatInterval;g<=0||(o.holdIntervalHandle=setTimeout(function(){t.pointerEvents.fire({interaction:o,eventTarget:u,type:"hold",pointer:i,event:i},t)},g))}}})},Il=Bl,Nl={id:"pointer-events/interactableTargets",install:function(n){var t=n.Interactable;t.prototype.pointerEvents=function(i){return N(this.events.options,i),this};var o=t.prototype._backCompatOption;t.prototype._backCompatOption=function(i,u){var p=o.call(this,i,u);return p===this&&(this.events.options[i]=u),p}},listeners:{"pointerEvents:collect-targets":function(n,t){var o=n.targets,i=n.node,u=n.type,p=n.eventTarget;t.interactables.forEachMatch(i,function(g){var k=g.events,A=k.options;k.types[u]&&k.types[u].length&&g.testIgnoreAllow(A,i,p)&&o.push({node:i,eventable:k,props:{interactable:g}})})},"interactable:new":function(n){var t=n.interactable;t.events.getRect=function(o){return t.getRect(o)}},"interactable:set":function(n,t){var o=n.interactable,i=n.options;N(o.events.options,t.pointerEvents.defaults),N(o.events.options,i.pointerEvents||{})}}},Al=Nl,Vl={id:"pointer-events",install:function(n){n.usePlugin(Sl),n.usePlugin(Il),n.usePlugin(Al)}},Ol=Vl,Ml={id:"reflow",install:function(n){var t=n.Interactable;n.actions.phases.reflow=!0,t.prototype.reflow=function(o){return function(i,u,p){for(var g=i.getAllElements(),k=p.window.Promise,A=k?[]:null,L=function(){var Y=g[z],ke=i.getRect(Y);if(!ke)return 1;var Fe,Me=Oe(p.interactions.list,function(et){return et.interacting()&&et.interactable===i&&et.element===Y&&et.prepared.name===u.name});if(Me)Me.move(),A&&(Fe=Me._reflowPromise||new k(function(et){Me._reflowResolve=et}));else{var Ke=le(ke),rt=function(et){return{coords:et,get page(){return this.coords.page},get client(){return this.coords.client},get timeStamp(){return this.coords.timeStamp},get pageX(){return this.coords.page.x},get pageY(){return this.coords.page.y},get clientX(){return this.coords.client.x},get clientY(){return this.coords.client.y},get pointerId(){return this.coords.pointerId},get target(){return this.coords.target},get type(){return this.coords.type},get pointerType(){return this.coords.pointerType},get buttons(){return this.coords.buttons},preventDefault:function(){}}}({page:{x:Ke.x,y:Ke.y},client:{x:Ke.x,y:Ke.y},timeStamp:p.now()});Fe=function(et,ht,Et,Nt,kt){var St=et.interactions.new({pointerType:"reflow"}),Qt={interaction:St,event:kt,pointer:kt,eventTarget:Et,phase:"reflow"};St.interactable=ht,St.element=Et,St.prevEvent=kt,St.updatePointer(kt,kt,Et,!0),J(St.coords.delta),ft(St.prepared,Nt),St._doPhase(Qt);var $t=et.window,sn=$t.Promise,fn=sn?new sn(function(xn){St._reflowResolve=xn}):void 0;return St._reflowPromise=fn,St.start(Nt,ht,Et),St._interacting?(St.move(Qt),St.end(kt)):(St.stop(),St._reflowResolve()),St.removePointer(kt,kt),fn}(p,i,Y,u,rt)}A&&A.push(Fe)},z=0;z<g.length&&!L();z++);return A&&k.all(A).then(function(){return i})}(this,o,n)}},listeners:{"interactions:stop":function(n,t){var o=n.interaction;o.pointerType==="reflow"&&(o._reflowResolve&&o._reflowResolve(),function(i,u){i.splice(i.indexOf(u),1)}(t.interactions.list,o))}}},zl=Ml;if(Zt.use(Sn),Zt.use(Kt),Zt.use(Ol),Zt.use(Ht),Zt.use(El),Zt.use(Ln),Zt.use(S),Zt.use(pt),Zt.use(zl),Zt.default=Zt,d(a)==="object"&&a)try{a.exports=Zt}catch{}return Zt.default=Zt,Zt})}(xa,xa.exports)),xa.exports}var Dp=Cp();const Ho=Ie.getDefaultExportFromCjs(Dp),Ha=e.defineComponent({__name:"grid-item",props:{isDraggable:{type:Boolean,default:void 0},isResizable:{type:Boolean,default:void 0},isBounded:{type:Boolean,default:void 0},static:{type:Boolean,default:!1},minH:{default:1},minW:{default:1},maxH:{default:1/0},maxW:{default:1/0},x:{},y:{},w:{},h:{},i:{},dragIgnoreFrom:{default:"a, button"},dragAllowFrom:{default:void 0},resizeIgnoreFrom:{default:"a, button"},preserveAspectRatio:{type:Boolean,default:!1},dragOption:{default:()=>({})},resizeOption:{default:()=>({})}},emits:["container-resized","resize","resized","move","moved"],setup(a,{expose:l,emit:s}){const r=a,d=s,c=e.inject($r),w=e.inject(jr);if(!c)throw new Error("[grid-layout-plus]: missing layout store, GridItem must under a GridLayout.");const v=e.shallowRef(null),f=e.reactive({cols:1,containerWidth:100,rowHeight:30,margin:[10,10],maxRows:1/0,draggable:void 0,resizable:void 0,bounded:void 0,transformScale:1,useCssTransforms:!0,useStyleCursor:!0,isDragging:!1,dragging:{top:-1,left:-1},isResizing:!1,resizing:{width:-1,height:-1},style:{},rtl:!1});let D=!1,C=!1,F=NaN,R=NaN,H=NaN,M=NaN,ve=-1,K=-1,O=-1,G=-1,b=r.x,E=r.y,y=r.w,B=r.h;const h=e.ref(),ce=e.reactive({i:e.toRef(r,"i"),state:f,wrapper:h,calcXY:Xe});function Ne(_){_e(_)}function nt(){He()}function xe(_){cn(r.isDraggable)&&(f.draggable=_)}function Re(_){cn(r.isResizable)&&(f.resizable=_)}function Pe(_){cn(r.isBounded)&&(f.bounded=_)}function P(_){f.transformScale=_}function re(_){f.rowHeight=_}function ne(_){f.maxRows=_}function pe(){f.rtl=Ko()==="rtl",He()}function We(_){f.cols=Math.floor(_)}c.increaseItem(ce),e.onBeforeMount(()=>{f.rtl=Ko()==="rtl"}),e.onMounted(()=>{c.responsive&&c.lastBreakpoint?f.cols=qr(c.lastBreakpoint,c.cols):f.cols=c.colNum,f.rowHeight=c.rowHeight,f.containerWidth=c.width!==null?c.width:100,f.margin=c.margin!==void 0?c.margin.map(Number):[10,10],f.maxRows=c.maxRows,cn(r.isDraggable)?f.draggable=c.isDraggable:f.draggable=r.isDraggable,cn(r.isResizable)?f.resizable=c.isResizable:f.resizable=r.isResizable,cn(r.isBounded)?f.bounded=c.isBounded:f.bounded=r.isBounded,f.transformScale=c.transformScale,f.useCssTransforms=c.useCssTransforms,f.useStyleCursor=c.useStyleCursor,e.watchEffect(()=>{b=r.x,E=r.y,B=r.h,y=r.w,en(Ze)}),w.on("updateWidth",Ne),w.on("compact",nt),w.on("setDraggable",xe),w.on("setResizable",Re),w.on("setBounded",Pe),w.on("setTransformScale",P),w.on("setRowHeight",re),w.on("setMaxRows",ne),w.on("directionchange",pe),w.on("setColNum",We)}),e.onBeforeUnmount(()=>{w.off("updateWidth",Ne),w.off("compact",nt),w.off("setDraggable",xe),w.off("setResizable",Re),w.off("setBounded",Pe),w.off("setTransformScale",P),w.off("setRowHeight",re),w.off("setMaxRows",ne),w.off("directionchange",pe),w.off("setColNum",We),v.value&&(v.value.unset(),v.value=null),c.decreaseItem(ce)}),l({state:f,wrapper:h});const at=typeof navigator<"u"?navigator.userAgent.toLowerCase().includes("android"):!1,X=e.computed(()=>f.resizable&&!r.static),V=e.computed(()=>c.isMirrored?!f.rtl:f.rtl),te=e.computed(()=>(f.draggable||f.resizable)&&!r.static),ye=vp("item"),ue=e.computed(()=>({[ye.b()]:!0,[ye.bm("resizable")]:X.value,[ye.bm("static")]:r.static,[ye.bm("resizing")]:f.isResizing,[ye.bm("dragging")]:f.isDragging,[ye.bm("transform")]:f.useCssTransforms,[ye.bm("rtl")]:V.value,[ye.bm("no-touch")]:at&&te.value})),Ce=e.computed(()=>[ye.be("resizer"),V.value&&ye.bem("resizer","rtl")].filter(Boolean));e.watch(()=>r.isDraggable,_=>{f.draggable=_}),e.watch(()=>r.static,()=>{en(T),en(J)}),e.watch(()=>f.draggable,()=>{en(T)}),e.watch(()=>r.isResizable,_=>{f.resizable=_}),e.watch(()=>r.isBounded,_=>{f.bounded=_}),e.watch(()=>f.resizable,()=>{en(J)}),e.watch(()=>f.rowHeight,()=>{en(Ze),en(ae)}),e.watch([()=>f.cols,()=>f.containerWidth],()=>{en(J),en(Ze),en(ae)}),e.watch([()=>r.minH,()=>r.maxH,()=>r.minW,()=>r.maxW],()=>{en(J)}),e.watch(V,()=>{en(J),en(Ze)}),e.watch([()=>c.margin,()=>c.margin[0],()=>c.margin[1]],()=>{const _=c.margin;!_||_[0]===f.margin[0]&&_[1]===f.margin[1]||(f.margin=_.map(Number),en(Ze),en(ae))});function Ze(){r.x+r.w>f.cols?(b=0,y=r.w>f.cols?f.cols:r.w):(b=r.x,y=r.w);const _=Ge(b,E,y,B);f.isDragging&&(_.top=f.dragging.top,V.value?_.right=f.dragging.left:_.left=f.dragging.left),f.isResizing&&(_.width=f.resizing.width,_.height=f.resizing.height);let oe;f.useCssTransforms?V.value?oe=dp(_.top,_.right,_.width,_.height):oe=up(_.top,_.left,_.width,_.height):V.value?oe=fp(_.top,_.right,_.width,_.height):oe=pp(_.top,_.left,_.width,_.height),f.style=oe}function ae(){const _={};for(const oe of["width","height"]){const Ae=f.style[oe].match(/^(\d+)px$/);if(!Ae)return;_[oe]=Ae[1]}d("container-resized",r.i,r.h,r.w,_.height,_.width)}function De(_){if(r.static)return;const oe=_.type;if(oe==="resizestart"&&f.isResizing||oe!=="resizestart"&&!f.isResizing)return;const Ae=jo(_);if(cn(Ae))return;const{x:I,y:ee}=Ae,$={width:0,height:0};let W;switch(oe){case"resizestart":{J(),ve=y,K=B,W=Ge(b,E,y,B),$.width=W.width,$.height=W.height,f.resizing=$,f.isResizing=!0;break}case"resizemove":{!_.edges.right&&!_.edges.left&&(H=I),!_.edges.top&&!_.edges.bottom&&(M=ee);const Ee=Uo(H,M,I,ee);V.value?$.width=f.resizing.width-Ee.deltaX/f.transformScale:$.width=f.resizing.width+Ee.deltaX/f.transformScale,$.height=f.resizing.height+Ee.deltaY/f.transformScale,f.resizing=$;break}case"resizeend":{W=Ge(b,E,y,B),$.width=W.width,$.height=W.height,f.resizing={width:-1,height:-1},f.isResizing=!1;break}}W=se($.height,$.width),W.w<r.minW&&(W.w=r.minW),W.w>r.maxW&&(W.w=r.maxW),W.h<r.minH&&(W.h=r.minH),W.h>r.maxH&&(W.h=r.maxH),W.h<1&&(W.h=1),W.w<1&&(W.w=1),H=I,M=ee,(y!==W.w||B!==W.h)&&d("resize",r.i,W.h,W.w,$.height,$.width),_.type==="resizeend"&&(ve!==y||K!==B)&&d("resized",r.i,W.h,W.w,$.height,$.width),w.emit("resizeEvent",_.type,r.i,b,E,W.h,W.w)}function N(_){if(r.static||f.isResizing)return;const oe=_.type;if(oe==="dragstart"&&f.isDragging||oe!=="dragstart"&&!f.isDragging)return;const Ae=jo(_);if(cn(Ae))return;const{x:I,y:ee}=Ae,$=_.target;if(!$.offsetParent)return;const W={top:0,left:0};switch(oe){case"dragstart":{O=b,G=E;const ie=$.offsetParent.getBoundingClientRect(),q=$.getBoundingClientRect(),Z=q.left/f.transformScale,de=ie.left/f.transformScale,me=q.right/f.transformScale,we=ie.right/f.transformScale,be=q.top/f.transformScale,j=ie.top/f.transformScale;V.value?W.left=(me-we)*-1:W.left=Z-de,W.top=be-j,f.dragging=W,f.isDragging=!0;break}case"dragmove":{const ie=Uo(F,R,I,ee);if(V.value?W.left=f.dragging.left-ie.deltaX/f.transformScale:W.left=f.dragging.left+ie.deltaX/f.transformScale,W.top=f.dragging.top+ie.deltaY/f.transformScale,f.bounded){const q=$.offsetParent.clientHeight-le(r.h,f.rowHeight,f.margin[1]);W.top=Q(W.top,0,q);const Z=Be(),de=f.containerWidth-le(r.w,Z,f.margin[0]);W.left=Q(W.left,0,de)}f.dragging=W;break}case"dragend":{const ie=$.offsetParent.getBoundingClientRect(),q=$.getBoundingClientRect(),Z=q.left/f.transformScale,de=ie.left/f.transformScale,me=q.right/f.transformScale,we=ie.right/f.transformScale,be=q.top/f.transformScale,j=ie.top/f.transformScale;V.value?W.left=(me-we)*-1:W.left=Z-de,W.top=be-j,f.dragging={top:-1,left:-1},f.isDragging=!1;break}}let Ee;V.value,Ee=Xe(W.top,W.left),F=I,R=ee,(b!==Ee.x||E!==Ee.y)&&d("move",r.i,Ee.x,Ee.y),_.type==="dragend"&&(O!==b||G!==E)&&d("moved",r.i,Ee.x,Ee.y),w.emit("dragEvent",_.type,r.i,Ee.x,Ee.y,B,y)}function Ge(_,oe,Ae,I){const ee=Be();let $;return V.value?$={right:Math.round(ee*_+(_+1)*f.margin[0]),top:Math.round(f.rowHeight*oe+(oe+1)*f.margin[1]),width:Ae===1/0?Ae:Math.round(ee*Ae+Math.max(0,Ae-1)*f.margin[0]),height:I===1/0?I:Math.round(f.rowHeight*I+Math.max(0,I-1)*f.margin[1])}:$={left:Math.round(ee*_+(_+1)*f.margin[0]),top:Math.round(f.rowHeight*oe+(oe+1)*f.margin[1]),width:Ae===1/0?Ae:Math.round(ee*Ae+Math.max(0,Ae-1)*f.margin[0]),height:I===1/0?I:Math.round(f.rowHeight*I+Math.max(0,I-1)*f.margin[1])},$}function Xe(_,oe){const Ae=Be();let I=Math.round((oe-f.margin[0])/(Ae+f.margin[0])),ee=Math.round((_-f.margin[1])/(f.rowHeight+f.margin[1]));return I=Math.max(Math.min(I,f.cols-y),0),ee=Math.max(Math.min(ee,f.maxRows-B),0),{x:I,y:ee}}function Be(){return(f.containerWidth-f.margin[0]*(f.cols+1))/f.cols}function le(_,oe,Ae){return Number.isFinite(_)?Math.round(oe*_+Math.max(0,_-1)*Ae):_}function Q(_,oe,Ae){return Math.max(Math.min(_,Ae),oe)}function se(_,oe,Ae=!1){const I=Be();let ee=Math.round((oe+f.margin[0])/(I+f.margin[0])),$=0;return Ae?$=Math.ceil((_+f.margin[1])/(f.rowHeight+f.margin[1])):$=Math.round((_+f.margin[1])/(f.rowHeight+f.margin[1])),ee=Math.max(Math.min(ee,f.cols-b),0),$=Math.max(Math.min($,f.maxRows-E),0),{w:ee,h:$}}function _e(_,oe){f.containerWidth=_}function He(){Ze()}function dt(){!v.value&&h.value&&(v.value=Ho(h.value),f.useStyleCursor||v.value.styleCursor(!1))}const m=Po(N);function T(){if(dt(),!!v.value)if(f.draggable&&!r.static){const _={ignoreFrom:r.dragIgnoreFrom,allowFrom:r.dragAllowFrom,...r.dragOption};v.value.draggable(_),D||(D=!0,v.value.on("dragstart dragmove dragend",oe=>{oe.type==="dragmove"?m(oe):N(oe)}))}else v.value.draggable({enabled:!1})}const U=Po(De);function J(){if(dt(),!!v.value)if(f.resizable&&!r.static){const _=Ge(0,0,r.maxW,r.maxH),oe=Ge(0,0,r.minW,r.minH),Ae={edges:{left:V.value?`.${Ce.value[0]}`:!1,right:V.value?!1:`.${Ce.value[0]}`,bottom:`.${Ce.value[0]}`,top:!1},ignoreFrom:r.resizeIgnoreFrom,restrictSize:{min:{height:oe.height*f.transformScale,width:oe.width*f.transformScale},max:{height:_.height*f.transformScale,width:_.width*f.transformScale}},...r.resizeOption};r.preserveAspectRatio&&(Ae.modifiers=[Ho.modifiers.aspectRatio({ratio:"preserve"})]),v.value.resizable(Ae),C||(C=!0,v.value.on("resizestart resizemove resizeend",I=>{I.type==="resizemove"?U(I):De(I)}))}else v.value.resizable({enabled:!1})}return(_,oe)=>(e.openBlock(),e.createElementBlock("section",{ref_key:"wrapper",ref:h,class:e.normalizeClass(ue.value),style:e.normalizeStyle(f.style)},[e.renderSlot(_.$slots,"default"),X.value?(e.openBlock(),e.createElementBlock("span",{key:0,class:e.normalizeClass(Ce.value)},null,2)):e.createCommentVNode("",!0)],6))}}),na=typeof window<"u";var qo;na&&(qo=window==null?void 0:window.navigator)!=null&&qo.userAgent&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function Go(a){return a!=null}function Xo(){}const _p=Object.freeze({aliceblue:"f0f8ff",antiquewhite:"faebd7",aqua:"0ff",aquamarine:"7fffd4",azure:"f0ffff",beige:"f5f5dc",bisque:"ffe4c4",black:"000",blanchedalmond:"ffebcd",blue:"00f",blueviolet:"8a2be2",brown:"a52a2a",burlywood:"deb887",burntsienna:"ea7e5d",cadetblue:"5f9ea0",chartreuse:"7fff00",chocolate:"d2691e",coral:"ff7f50",cornflowerblue:"6495ed",cornsilk:"fff8dc",crimson:"dc143c",cyan:"0ff",darkblue:"00008b",darkcyan:"008b8b",darkgoldenrod:"b8860b",darkgray:"a9a9a9",darkgreen:"006400",darkgrey:"a9a9a9",darkkhaki:"bdb76b",darkmagenta:"8b008b",darkolivegreen:"556b2f",darkorange:"ff8c00",darkorchid:"9932cc",darkred:"8b0000",darksalmon:"e9967a",darkseagreen:"8fbc8f",darkslateblue:"483d8b",darkslategray:"2f4f4f",darkslategrey:"2f4f4f",darkturquoise:"00ced1",darkviolet:"9400d3",deeppink:"ff1493",deepskyblue:"00bfff",dimgray:"696969",dimgrey:"696969",dodgerblue:"1e90ff",firebrick:"b22222",floralwhite:"fffaf0",forestgreen:"228b22",fuchsia:"f0f",gainsboro:"dcdcdc",ghostwhite:"f8f8ff",gold:"ffd700",goldenrod:"daa520",gray:"808080",green:"008000",greenyellow:"adff2f",grey:"808080",honeydew:"f0fff0",hotpink:"ff69b4",indianred:"cd5c5c",indigo:"4b0082",ivory:"fffff0",khaki:"f0e68c",lavender:"e6e6fa",lavenderblush:"fff0f5",lawngreen:"7cfc00",lemonchiffon:"fffacd",lightblue:"add8e6",lightcoral:"f08080",lightcyan:"e0ffff",lightgoldenrodyellow:"fafad2",lightgray:"d3d3d3",lightgreen:"90ee90",lightgrey:"d3d3d3",lightpink:"ffb6c1",lightsalmon:"ffa07a",lightseagreen:"20b2aa",lightskyblue:"87cefa",lightslategray:"789",lightslategrey:"789",lightsteelblue:"b0c4de",lightyellow:"ffffe0",lime:"0f0",limegreen:"32cd32",linen:"faf0e6",magenta:"f0f",maroon:"800000",mediumaquamarine:"66cdaa",mediumblue:"0000cd",mediumorchid:"ba55d3",mediumpurple:"9370db",mediumseagreen:"3cb371",mediumslateblue:"7b68ee",mediumspringgreen:"00fa9a",mediumturquoise:"48d1cc",mediumvioletred:"c71585",midnightblue:"191970",mintcream:"f5fffa",mistyrose:"ffe4e1",moccasin:"ffe4b5",navajowhite:"ffdead",navy:"000080",oldlace:"fdf5e6",olive:"808000",olivedrab:"6b8e23",orange:"ffa500",orangered:"ff4500",orchid:"da70d6",palegoldenrod:"eee8aa",palegreen:"98fb98",paleturquoise:"afeeee",palevioletred:"db7093",papayawhip:"ffefd5",peachpuff:"ffdab9",peru:"cd853f",pink:"ffc0cb",plum:"dda0dd",powderblue:"b0e0e6",purple:"800080",rebeccapurple:"663399",red:"f00",rosybrown:"bc8f8f",royalblue:"4169e1",saddlebrown:"8b4513",salmon:"fa8072",sandybrown:"f4a460",seagreen:"2e8b57",seashell:"fff5ee",sienna:"a0522d",silver:"c0c0c0",skyblue:"87ceeb",slateblue:"6a5acd",slategray:"708090",slategrey:"708090",snow:"fffafa",springgreen:"00ff7f",steelblue:"4682b4",tan:"d2b48c",teal:"008080",thistle:"d8bfd8",tomato:"ff6347",turquoise:"40e0d0",violet:"ee82ee",wheat:"f5deb3",white:"fff",whitesmoke:"f5f5f5",yellow:"ff0",yellowgreen:"9acd32"});Object.freeze(new Set(Object.keys(_p)));const Ep=na&&("ontouchstart"in window||Tp()>0),Sp=Ep?"pointerdown":"click";function Tp(){return typeof navigator<"u"&&(navigator.maxTouchPoints||navigator.msMaxTouchPoints)||0}function Bp(a,l,s=window.Event){const{type:r,bubbles:d=!1,cancelable:c=!1,...w}=l;if(!Go(r)||r==="")return!1;let v;return Go(s)?v=new s(r,{bubbles:d,cancelable:c}):(v=document.createEvent("HTMLEvents"),v.initEvent(r,d,c)),Object.assign(v,w),a.dispatchEvent(v)}const Ip="clickoutside",Np=new Set;na&&document.addEventListener(Sp,a=>{const l=a.target,s=a.composedPath&&a.composedPath();Np.forEach(r=>{r!==l&&(s?!s.includes(r):!r.contains(l))&&(!r.__transferElement||r.__transferElement!==l&&!r.__transferElement.contains(l))&&Bp(r,{type:Ip})})},!0);const Ap=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]];let Fa;if(na){for(const a of Ap)if(a[1]in document){Fa=a;break}}e.computed(()=>!1);const Vp=new Set,Op=new WeakMap;if(na&&Fa){const a=Fa[2],l=Fa[4];document.addEventListener(l,()=>{if(Vp.forEach(s=>{s.value=!1}),document[a]){const s=Op.get(document[a]);s&&(s.value=!0)}},!1)}const Xr=new Map;Xr.set("x",0);Xr.set("y",0);var Qn=[],Mp=function(){return Qn.some(function(a){return a.activeTargets.length>0})},zp=function(){return Qn.some(function(a){return a.skippedTargets.length>0})},Yo="ResizeObserver loop completed with undelivered notifications.",Fp=function(){var a;typeof ErrorEvent=="function"?a=new ErrorEvent("error",{message:Yo}):(a=document.createEvent("Event"),a.initEvent("error",!1,!1),a.message=Yo),window.dispatchEvent(a)},_a;(function(a){a.BORDER_BOX="border-box",a.CONTENT_BOX="content-box",a.DEVICE_PIXEL_CONTENT_BOX="device-pixel-content-box"})(_a||(_a={}));var ea=function(a){return Object.freeze(a)},Rp=function(){function a(l,s){this.inlineSize=l,this.blockSize=s,ea(this)}return a}(),Yr=function(){function a(l,s,r,d){return this.x=l,this.y=s,this.width=r,this.height=d,this.top=this.y,this.left=this.x,this.bottom=this.top+this.height,this.right=this.left+this.width,ea(this)}return a.prototype.toJSON=function(){var l=this,s=l.x,r=l.y,d=l.top,c=l.right,w=l.bottom,v=l.left,f=l.width,D=l.height;return{x:s,y:r,top:d,right:c,bottom:w,left:v,width:f,height:D}},a.fromRect=function(l){return new a(l.x,l.y,l.width,l.height)},a}(),ho=function(a){return a instanceof SVGElement&&"getBBox"in a},Jr=function(a){if(ho(a)){var l=a.getBBox(),s=l.width,r=l.height;return!s&&!r}var d=a,c=d.offsetWidth,w=d.offsetHeight;return!(c||w||a.getClientRects().length)},Jo=function(a){var l;if(a instanceof Element)return!0;var s=(l=a==null?void 0:a.ownerDocument)===null||l===void 0?void 0:l.defaultView;return!!(s&&a instanceof s.Element)},Pp=function(a){switch(a.tagName){case"INPUT":if(a.type!=="image")break;case"VIDEO":case"AUDIO":case"EMBED":case"OBJECT":case"CANVAS":case"IFRAME":case"IMG":return!0}return!1},Da=typeof window<"u"?window:{},Va=new WeakMap,Zo=/auto|scroll/,Lp=/^tb|vertical/,$p=/msie|trident/i.test(Da.navigator&&Da.navigator.userAgent),mn=function(a){return parseFloat(a||"0")},pa=function(a,l,s){return a===void 0&&(a=0),l===void 0&&(l=0),s===void 0&&(s=!1),new Rp((s?l:a)||0,(s?a:l)||0)},Qo=ea({devicePixelContentBoxSize:pa(),borderBoxSize:pa(),contentBoxSize:pa(),contentRect:new Yr(0,0,0,0)}),Zr=function(a,l){if(l===void 0&&(l=!1),Va.has(a)&&!l)return Va.get(a);if(Jr(a))return Va.set(a,Qo),Qo;var s=getComputedStyle(a),r=ho(a)&&a.ownerSVGElement&&a.getBBox(),d=!$p&&s.boxSizing==="border-box",c=Lp.test(s.writingMode||""),w=!r&&Zo.test(s.overflowY||""),v=!r&&Zo.test(s.overflowX||""),f=r?0:mn(s.paddingTop),D=r?0:mn(s.paddingRight),C=r?0:mn(s.paddingBottom),F=r?0:mn(s.paddingLeft),R=r?0:mn(s.borderTopWidth),H=r?0:mn(s.borderRightWidth),M=r?0:mn(s.borderBottomWidth),ve=r?0:mn(s.borderLeftWidth),K=F+D,O=f+C,G=ve+H,b=R+M,E=v?a.offsetHeight-b-a.clientHeight:0,y=w?a.offsetWidth-G-a.clientWidth:0,B=d?K+G:0,h=d?O+b:0,ce=r?r.width:mn(s.width)-B-y,Ne=r?r.height:mn(s.height)-h-E,nt=ce+K+y+G,xe=Ne+O+E+b,Re=ea({devicePixelContentBoxSize:pa(Math.round(ce*devicePixelRatio),Math.round(Ne*devicePixelRatio),c),borderBoxSize:pa(nt,xe,c),contentBoxSize:pa(ce,Ne,c),contentRect:new Yr(F,f,ce,Ne)});return Va.set(a,Re),Re},Qr=function(a,l,s){var r=Zr(a,s),d=r.borderBoxSize,c=r.contentBoxSize,w=r.devicePixelContentBoxSize;switch(l){case _a.DEVICE_PIXEL_CONTENT_BOX:return w;case _a.BORDER_BOX:return d;default:return c}},jp=function(){function a(l){var s=Zr(l);this.target=l,this.contentRect=s.contentRect,this.borderBoxSize=ea([s.borderBoxSize]),this.contentBoxSize=ea([s.contentBoxSize]),this.devicePixelContentBoxSize=ea([s.devicePixelContentBoxSize])}return a}(),el=function(a){if(Jr(a))return 1/0;for(var l=0,s=a.parentNode;s;)l+=1,s=s.parentNode;return l},Up=function(){var a=1/0,l=[];Qn.forEach(function(c){if(c.activeTargets.length!==0){var w=[];c.activeTargets.forEach(function(v){var f=new jp(v.target),D=el(v.target);w.push(f),v.lastReportedSize=Qr(v.target,v.observedBox),D<a&&(a=D)}),l.push(function(){c.callback.call(c.observer,w,c.observer)}),c.activeTargets.splice(0,c.activeTargets.length)}});for(var s=0,r=l;s<r.length;s++){var d=r[s];d()}return a},er=function(a){Qn.forEach(function(l){l.activeTargets.splice(0,l.activeTargets.length),l.skippedTargets.splice(0,l.skippedTargets.length),l.observationTargets.forEach(function(s){s.isActive()&&(el(s.target)>a?l.activeTargets.push(s):l.skippedTargets.push(s))})})},Kp=function(){var a=0;for(er(a);Mp();)a=Up(),er(a);return zp()&&Fp(),a>0},no,tl=[],Wp=function(){return tl.splice(0).forEach(function(a){return a()})},Hp=function(a){if(!no){var l=0,s=document.createTextNode(""),r={characterData:!0};new MutationObserver(function(){return Wp()}).observe(s,r),no=function(){s.textContent="".concat(l?l--:l++)}}tl.push(a),no()},qp=function(a){Hp(function(){requestAnimationFrame(a)})},Ra=0,Gp=function(){return!!Ra},Xp=250,Yp={attributes:!0,characterData:!0,childList:!0,subtree:!0},tr=["resize","load","transitionend","animationend","animationstart","animationiteration","keyup","keydown","mouseup","mousedown","mouseover","mouseout","blur","focus"],nr=function(a){return a===void 0&&(a=0),Date.now()+a},ao=!1,Jp=function(){function a(){var l=this;this.stopped=!0,this.listener=function(){return l.schedule()}}return a.prototype.run=function(l){var s=this;if(l===void 0&&(l=Xp),!ao){ao=!0;var r=nr(l);qp(function(){var d=!1;try{d=Kp()}finally{if(ao=!1,l=r-nr(),!Gp())return;d?s.run(1e3):l>0?s.run(l):s.start()}})}},a.prototype.schedule=function(){this.stop(),this.run()},a.prototype.observe=function(){var l=this,s=function(){return l.observer&&l.observer.observe(document.body,Yp)};document.body?s():Da.addEventListener("DOMContentLoaded",s)},a.prototype.start=function(){var l=this;this.stopped&&(this.stopped=!1,this.observer=new MutationObserver(this.listener),this.observe(),tr.forEach(function(s){return Da.addEventListener(s,l.listener,!0)}))},a.prototype.stop=function(){var l=this;this.stopped||(this.observer&&this.observer.disconnect(),tr.forEach(function(s){return Da.removeEventListener(s,l.listener,!0)}),this.stopped=!0)},a}(),uo=new Jp,ar=function(a){!Ra&&a>0&&uo.start(),Ra+=a,!Ra&&uo.stop()},Zp=function(a){return!ho(a)&&!Pp(a)&&getComputedStyle(a).display==="inline"},Qp=function(){function a(l,s){this.target=l,this.observedBox=s||_a.CONTENT_BOX,this.lastReportedSize={inlineSize:0,blockSize:0}}return a.prototype.isActive=function(){var l=Qr(this.target,this.observedBox,!0);return Zp(this.target)&&(this.lastReportedSize=l),this.lastReportedSize.inlineSize!==l.inlineSize||this.lastReportedSize.blockSize!==l.blockSize},a}(),ef=function(){function a(l,s){this.activeTargets=[],this.skippedTargets=[],this.observationTargets=[],this.observer=l,this.callback=s}return a}(),Oa=new WeakMap,or=function(a,l){for(var s=0;s<a.length;s+=1)if(a[s].target===l)return s;return-1},Ma=function(){function a(){}return a.connect=function(l,s){var r=new ef(l,s);Oa.set(l,r)},a.observe=function(l,s,r){var d=Oa.get(l),c=d.observationTargets.length===0;or(d.observationTargets,s)<0&&(c&&Qn.push(d),d.observationTargets.push(new Qp(s,r&&r.box)),ar(1),uo.schedule())},a.unobserve=function(l,s){var r=Oa.get(l),d=or(r.observationTargets,s),c=r.observationTargets.length===1;d>=0&&(c&&Qn.splice(Qn.indexOf(r),1),r.observationTargets.splice(d,1),ar(-1))},a.disconnect=function(l){var s=this,r=Oa.get(l);r.observationTargets.slice().forEach(function(d){return s.unobserve(l,d.target)}),r.activeTargets.splice(0,r.activeTargets.length)},a}(),tf=function(){function a(l){if(arguments.length===0)throw new TypeError("Failed to construct 'ResizeObserver': 1 argument required, but only 0 present.");if(typeof l!="function")throw new TypeError("Failed to construct 'ResizeObserver': The callback provided as parameter 1 is not a function.");Ma.connect(this,l)}return a.prototype.observe=function(l,s){if(arguments.length===0)throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Jo(l))throw new TypeError("Failed to execute 'observe' on 'ResizeObserver': parameter 1 is not of type 'Element");Ma.observe(this,l,s)},a.prototype.unobserve=function(l){if(arguments.length===0)throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': 1 argument required, but only 0 present.");if(!Jo(l))throw new TypeError("Failed to execute 'unobserve' on 'ResizeObserver': parameter 1 is not of type 'Element");Ma.unobserve(this,l)},a.prototype.disconnect=function(){Ma.disconnect(this)},a.toString=function(){return"function ResizeObserver () { [polyfill code] }"},a}();const qa=new WeakMap;function nf(a){var l;for(let s=0,r=a.length;s<r;++s){const d=a[s],c=qa.get(d.target);if(typeof c=="function"){const{inlineSize:w,blockSize:v}=((l=d.borderBoxSize)==null?void 0:l[0])??{},{offsetWidth:f,offsetHeight:D}=d.target;c(Object.assign(d,{offsetWidth:f,offsetHeight:D,width:w??f,height:v??D}))}}}const nl=new(na&&window.ResizeObserver||tf)(nf);function rr(a,l){qa.set(a,l),nl.observe(a)}function lr(a){qa.has(a)&&(nl.unobserve(a),qa.delete(a))}function af(a={}){let l=Xo;const s=e.watch(()=>e.unref(a.target),d=>{l(),!(!d||typeof a.onResize!="function")&&(rr(d,a.onResize),l=()=>{lr(d),l=Xo})},{immediate:!0}),r=()=>{s(),l()};return e.getCurrentScope()&&e.onScopeDispose(r),{observeResize:rr,unobserveResize:lr,unobserve:r}}const of=e.ref(!1);e.computed(()=>of.value);const ir="__theme_style__",oo="__theme_observer__",sr=e.reactive(new Map),cr=new Map;e.watch(sr,()=>{if(!na)return;cr.clear();const a=document.head.querySelector(`#${ir}`);a&&document.head.removeChild(a);const l=document.createElement("style");let s=`.${oo} { width: 1px }`,r=1;for(const[d,[c,w]]of sr.entries())s+=` html.${c} .${oo}, .${w} .${oo} { width: ${++r}px }`,cr.set(r,d);l.textContent=s,l.id=ir,document.head.appendChild(l)});const al=e.defineComponent({__name:"grid-layout",props:{autoSize:{type:Boolean,default:!0},colNum:{default:12},rowHeight:{default:150},maxRows:{default:1/0},margin:{default:()=>[10,10]},isDraggable:{type:Boolean,default:!0},isResizable:{type:Boolean,default:!0},isMirrored:{type:Boolean,default:!1},isBounded:{type:Boolean,default:!1},useCssTransforms:{type:Boolean,default:!0},verticalCompact:{type:Boolean,default:!0},restoreOnDrag:{type:Boolean,default:!1},layout:{},responsive:{type:Boolean,default:!1},responsiveLayouts:{default:()=>({})},transformScale:{default:1},breakpoints:{default:()=>({lg:1200,md:996,sm:768,xs:480,xxs:0})},cols:{default:()=>({lg:12,md:10,sm:6,xs:4,xxs:2})},preventCollision:{type:Boolean,default:!1},useStyleCursor:{type:Boolean,default:!0}},emits:["layout-before-mount","layout-mounted","layout-updated","breakpoint-changed","update:layout","layout-ready"],setup(a,{expose:l,emit:s}){const r=a,d=s,c=e.reactive({width:-1,mergedStyle:{},lastLayoutLength:0,isDragging:!1,placeholder:{x:0,y:0,w:0,h:0,i:""},layouts:{},lastBreakpoint:null,originalLayout:null}),w=new Map,v=e.ref(r.layout),f=e.ref(),{observeResize:D,unobserveResize:C}=af(),F=ap();F.on("resizeEvent",R),F.on("dragEvent",H),e.onBeforeMount(()=>{d("layout-before-mount",v.value)}),e.onMounted(()=>{d("layout-mounted",v.value),e.nextTick(()=>{hp(v.value),c.originalLayout=v.value,e.nextTick(()=>{Ne(),f.value&&D(f.value,op(b,16)),sa(v.value,r.verticalCompact),d("layout-updated",v.value),G(),b()})})}),e.onBeforeUnmount(()=>{F.clearAll(),f.value&&C(f.value)});function R(xe,Re,Pe,P,re,ne){h(xe,Re,Pe,P,re,ne)}function H(xe,Re,Pe,P,re,ne){B(xe,Re,Pe,P,re,ne)}e.watch(()=>c.width,(xe,Re)=>{e.nextTick(()=>{F.emit("updateWidth",xe),Re===-1&&e.nextTick(()=>{d("layout-ready",v.value)}),G()})}),e.watch(()=>[r.layout,r.layout.length],()=>{v.value=r.layout,O()}),e.watch(()=>r.colNum,xe=>{F.emit("setColNum",xe)}),e.watch(()=>r.rowHeight,xe=>{F.emit("setRowHeight",xe)}),e.watch(()=>r.isDraggable,xe=>{F.emit("setDraggable",xe)}),e.watch(()=>r.isResizable,xe=>{F.emit("setResizable",xe)}),e.watch(()=>r.isBounded,xe=>{F.emit("setBounded",xe)}),e.watch(()=>r.transformScale,xe=>{F.emit("setTransformScale",xe)}),e.watch(()=>r.responsive,xe=>{xe||(d("update:layout",c.originalLayout),F.emit("setColNum",r.colNum)),b()}),e.watch(()=>r.maxRows,xe=>{F.emit("setMaxRows",xe)}),e.watch([()=>r.margin,()=>r.margin[1]],G),e.provide($r,e.reactive({...e.toRefs(r),...e.toRefs(c),increaseItem:M,decreaseItem:ve})),e.provide(jr,F),l({state:c,getItem:K,resizeEvent:h,dragEvent:B,layoutUpdate:O});function M(xe){w.set(xe.i,xe)}function ve(xe){w.delete(xe.i)}function K(xe){return w.get(xe)}function O(){if(!cn(v.value)&&!cn(c.originalLayout)){if(v.value.length!==c.originalLayout.length){const xe=nt(v.value,c.originalLayout);if(xe.length>0)if(v.value.length>c.originalLayout.length)c.originalLayout=c.originalLayout.concat(xe);else{const Re=new Set(xe.map(Pe=>Pe.i));c.originalLayout=c.originalLayout.filter(Pe=>!Re.has(Pe.i))}c.lastLayoutLength=v.value.length,Ne()}sa(v.value,r.verticalCompact),F.emit("updateWidth",c.width),G(),d("layout-updated",v.value)}}function G(){c.mergedStyle={height:E()}}function b(){f.value&&(c.width=f.value.offsetWidth),F.emit("resizeEvent")}function E(){if(!r.autoSize)return;const xe=parseFloat(r.margin[1]);return lp(v.value)*(r.rowHeight+xe)+xe+"px"}let y;function B(xe,Re,Pe,P,re,ne){let pe=Lo(v.value,Re);cn(pe)&&(pe={h:0,w:0,x:0,y:0,i:""}),xe==="dragstart"&&!r.verticalCompact&&(y=v.value.reduce((We,{i:at,x:X,y:V})=>({...We,[at]:{x:X,y:V}}),{})),xe==="dragmove"||xe==="dragstart"?(c.placeholder.i=Re,c.placeholder.x=pe.x,c.placeholder.y=pe.y,c.placeholder.w=ne,c.placeholder.h=re,e.nextTick(()=>{c.isDragging=!0}),F.emit("updateWidth",c.width)):e.nextTick(()=>{c.isDragging=!1}),v.value=co(v.value,pe,Pe,P,!0,r.preventCollision),r.restoreOnDrag?(pe.static=!0,sa(v.value,r.verticalCompact,y),pe.static=!1):sa(v.value,r.verticalCompact),F.emit("compact"),G(),xe==="dragend"&&(y=void 0,d("layout-updated",v.value))}function h(xe,Re,Pe,P,re,ne){let pe=Lo(v.value,Re);cn(pe)&&(pe={h:0,w:0,x:0,y:0,i:""});let We;if(r.preventCollision){const at=Kr(v.value,{...pe,w:ne,h:re}).filter(X=>X.i!==pe.i);if(We=at.length>0,We){let X=1/0,V=1/0;at.forEach(te=>{te.x>pe.x&&(X=Math.min(X,te.x)),te.y>pe.y&&(V=Math.min(V,te.y))}),Number.isFinite(X)&&(pe.w=X-pe.x),Number.isFinite(V)&&(pe.h=V-pe.y)}}We||(pe.w=ne,pe.h=re),xe==="resizestart"||xe==="resizemove"?(c.placeholder.i=Re,c.placeholder.x=Pe,c.placeholder.y=P,c.placeholder.w=pe.w,c.placeholder.h=pe.h,e.nextTick(()=>{c.isDragging=!0}),F.emit("updateWidth",c.width)):xe&&e.nextTick(()=>{c.isDragging=!1}),r.responsive&&ce(),sa(v.value,r.verticalCompact),F.emit("compact"),G(),xe==="resizeend"&&d("layout-updated",v.value)}function ce(){const xe=yp(r.breakpoints,c.width);if(xe===c.lastBreakpoint)return;const Re=qr(xe,r.cols);!cn(c.lastBreakpoint)&&!c.layouts[c.lastBreakpoint]&&(c.layouts[c.lastBreakpoint]=so(v.value));const Pe=bp(c.originalLayout,c.layouts,r.breakpoints,xe,c.lastBreakpoint,Re,r.verticalCompact);c.layouts[xe]=Pe,c.lastBreakpoint!==xe&&d("breakpoint-changed",xe,Pe),v.value=Pe,d("update:layout",Pe),c.lastBreakpoint=xe,F.emit("setColNum",Re)}function Ne(){c.layouts=Object.assign({},r.responsiveLayouts)}function nt(xe,Re){const Pe=new Set(Re.map(pe=>pe.i)),P=new Set(xe.map(pe=>pe.i)),re=xe.filter(pe=>!Pe.has(pe.i)),ne=Re.filter(pe=>!P.has(pe.i));return re.concat(ne)}return(xe,Re)=>(e.openBlock(),e.createElementBlock("div",{ref_key:"wrapper",ref:f,class:"vgl-layout",style:e.normalizeStyle(c.mergedStyle)},[xe.$slots.default?e.renderSlot(xe.$slots,"default",{key:0}):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(v.value,Pe=>(e.openBlock(),e.createBlock(Ha,e.mergeProps({key:Pe.i,ref_for:!0},Pe),{default:e.withCtx(()=>[e.renderSlot(xe.$slots,"item",{item:Pe})]),_:2},1040))),128)),e.withDirectives(e.createVNode(Ha,{class:"vgl-item--placeholder",x:c.placeholder.x,y:c.placeholder.y,w:c.placeholder.w,h:c.placeholder.h,i:c.placeholder.i},null,8,["x","y","w","h","i"]),[[e.vShow,c.isDragging]])],4))}});(function(){try{if(typeof document<"u"){var a=document.createElement("style");a.appendChild(document.createTextNode('.vgl-layout{--vgl-placeholder-bg: red;--vgl-placeholder-opacity: 20%;--vgl-placeholder-z-index: 2;--vgl-item-resizing-z-index: 3;--vgl-item-resizing-opacity: 60%;--vgl-item-dragging-z-index: 3;--vgl-item-dragging-opacity: 100%;--vgl-resizer-size: 10px;--vgl-resizer-border-color: #444;--vgl-resizer-border-width: 2px;position:relative;box-sizing:border-box;transition:height .2s ease}.vgl-item{position:absolute;box-sizing:border-box;transition:.2s ease;transition-property:left,top,right}.vgl-item--placeholder{z-index:var(--vgl-placeholder-z-index, 2);-webkit-user-select:none;-moz-user-select:none;user-select:none;background-color:var(--vgl-placeholder-bg, red);opacity:var(--vgl-placeholder-opacity, 20%);transition-duration:.1s}.vgl-item--no-touch{touch-action:none}.vgl-item--transform{right:auto;left:0;transition-property:transform}.vgl-item--transform.vgl-item--rtl{right:0;left:auto}.vgl-item--resizing{z-index:var(--vgl-item-resizing-z-index, 3);-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--vgl-item-resizing-opacity, 60%)}.vgl-item--dragging{z-index:var(--vgl-item-dragging-z-index, 3);-webkit-user-select:none;-moz-user-select:none;user-select:none;opacity:var(--vgl-item-dragging-opacity, 100%);transition:none}.vgl-item__resizer{position:absolute;right:0;bottom:0;box-sizing:border-box;width:var(--vgl-resizer-size);height:var(--vgl-resizer-size);cursor:se-resize}.vgl-item__resizer:before{position:absolute;top:0;right:3px;bottom:3px;left:0;content:"";border:0 solid var(--vgl-resizer-border-color);border-right-width:var(--vgl-resizer-border-width);border-bottom-width:var(--vgl-resizer-border-width)}.vgl-item__resizer--rtl{right:auto;left:0;cursor:sw-resize}.vgl-item__resizer--rtl:before{top:0;right:0;bottom:3px;left:3px;border-right-width:0;border-bottom-width:var(--vgl-resizer-border-width);border-left-width:var(--vgl-resizer-border-width)}')),document.head.appendChild(a)}}catch(l){console.error("vite-plugin-css-injected-by-js",l)}})();const rf={key:0,class:"item-view-group"},lf={key:0,class:"item-view-group"},sf=e.defineComponent({__name:"index",props:{children:{type:Object,default:()=>{}},level:{type:Number,default:1}},emits:["rowClick","routeUrl"],setup(a,{emit:l}){const s=x.useModelComp(x.pinia),{isEdit:r}=x.storeToRefs(s),d=l,c=a,w=e.computed(()=>c==null?void 0:c.children),v=e.computed(()=>{var R,H,M,ve;return((R=c==null?void 0:c.children)==null?void 0:R.length)>0&&((H=c==null?void 0:c.children)!=null&&H.every(K=>K==null?void 0:K.layout))?(ve=(M=c==null?void 0:c.children)==null?void 0:M[0])==null?void 0:ve.layout:"vertical"}),f=e.computed(()=>{var R,H;return((H=(R=c==null?void 0:c.children)==null?void 0:R[0])==null?void 0:H.isGridLayout)||!1}),D=e.ref((c==null?void 0:c.level)+1),C=R=>{d("rowClick",R)},F=(R,H)=>{d("routeUrl",R,H)};return(R,H)=>f.value?(e.openBlock(),e.createBlock(e.unref(al),{key:0,layout:w.value,"onUpdate:layout":H[0]||(H[0]=M=>w.value=M),"is-draggable":e.unref(r)==="edit","is-resizable":e.unref(r)==="edit","col-num":24,margin:[8,16]},{default:e.withCtx(()=>[(e.openBlock(!0),e.createElementBlock(e.Fragment,null,e.renderList(w.value,(M,ve)=>(e.openBlock(),e.createBlock(e.unref(Ha),{key:M.i,x:M.x,y:M.y,"min-h":M.minH,"max-h":M.maxH,"min-w":M.minW,w:M.w,h:M.h,i:M.i},{default:e.withCtx(()=>{var K,O,G,b,E,y,B,h,ce,Ne,nt,xe,Re;return[e.createElementVNode("div",{style:e.normalizeStyle({gap:"16px",display:"flex",flexDirection:"column",paddingBottom:ve===((K=c==null?void 0:c.children)==null?void 0:K.length)-1?"0px":"24px"})},[((G=(O=M==null?void 0:M.component)==null?void 0:O.comp)==null?void 0:G.toUpperCase())!=="TABLE"&&((b=M==null?void 0:M.component)!=null&&b.name)?(e.openBlock(),e.createElementBlock("div",rf,[e.createElementVNode("div",{class:"group-name-wrap",style:e.normalizeStyle({paddingLeft:(parseInt(D.value.toString())-1)*12+"px",fontWeight:600-(D.value-1)*100>=400?600-(D.value-1)*100:400,fontSize:17-D.value>=14?17-D.value+"px":"14px"})},e.toDisplayString((E=M==null?void 0:M.component)==null?void 0:E.name),5)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(ja)((y=M==null?void 0:M.component)==null?void 0:y.comp)),{pageLayout:v.value,config:{showIndex:(B=e.unref(Gt)[ve])==null?void 0:B.showIndex,allowMove:(h=e.unref(Gt)[ve])==null?void 0:h.allowMove,viewport:(ce=e.unref(Gt)[ve])==null?void 0:ce.viewport},compName:M==null?void 0:M.component.name,compNames:e.unref(Ar),itemData:(Ne=M==null?void 0:M.component)==null?void 0:Ne.compData,childItemData:(nt=M==null?void 0:M.component)==null?void 0:nt.itemChildData,key:e.unref(fa),cacheNewData:e.unref(Nr),onChange:e.unref(Ua),index:(M==null?void 0:M.id)??ve,onContentChange:e.unref(Ka),onPageChange:e.unref(Wa),parentTableId:(xe=M==null?void 0:M.component)==null?void 0:xe.tableId,allMapContents:e.unref(io),children:(Re=M==null?void 0:M.component)==null?void 0:Re.children,level:D.value,onRowClick:C,onRouteUrl:F,onClickTrigger:e.unref(Vr),onClickMainKey:e.unref(Or)},null,40,["pageLayout","config","compName","compNames","itemData","childItemData","cacheNewData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level","onClickTrigger","onClickMainKey"]))],4)]}),_:2},1032,["x","y","min-h","max-h","min-w","w","h","i"]))),128))]),_:1},8,["layout","is-draggable","is-resizable"])):(e.openBlock(!0),e.createElementBlock(e.Fragment,{key:1},e.renderList(c==null?void 0:c.children,(M,ve)=>{var K,O;return e.openBlock(),e.createElementBlock("div",{style:e.normalizeStyle({gap:"16px",display:(M==null?void 0:M.isShow)===!1?"none":"flex",flexDirection:"column",paddingBottom:parseInt(ve)===((K=c==null?void 0:c.children)==null?void 0:K.length)-1?"0px":"24px"})},[((O=M==null?void 0:M.comp)==null?void 0:O.toUpperCase())!=="TABLE"&&M.name?(e.openBlock(),e.createElementBlock("div",lf,[e.createElementVNode("div",{class:"group-name-wrap",style:e.normalizeStyle({paddingLeft:parseInt(D.value.toString())>1?"12px":"0px",fontWeight:600-(D.value-1)*100>=400?600-(D.value-1)*100:400,fontSize:17-D.value>=14?17-D.value+"px":"14px"})},e.toDisplayString(M.name),5)])):e.createCommentVNode("",!0),(e.openBlock(),e.createBlock(e.resolveDynamicComponent(e.unref(ja)(M.comp)),{compName:M.name,itemData:M==null?void 0:M.compData,childItemData:M==null?void 0:M.itemChildData,key:e.unref(fa),onChange:e.unref(Ua),index:(M==null?void 0:M.id)??ve,onContentChange:e.unref(Ka),onPageChange:e.unref(Wa),parentTableId:M==null?void 0:M.tableId,allMapContents:e.unref(io),children:M==null?void 0:M.children,level:D.value,onRowClick:C,onRouteUrl:F},null,40,["compName","itemData","childItemData","onChange","index","onContentChange","onPageChange","parentTableId","allMapContents","children","level"]))],4)}),256))}}),cf=Rt._export_sfc(sf,[["__scopeId","data-v-e672653d"]]),ol=e.ref([{name:"表格",type:"table",comp:"Table",icon:"Table"},{name:"表单",type:"form",comp:"Form",icon:"Form"},{name:"折叠",type:"fold",comp:"Fold",icon:"Fold"},{name:"头像",type:"avatar",comp:"AvatarUpload",icon:"Avatar"},{name:"签名",type:"signature",comp:"Signature",icon:"Signature"},{name:"步骤条",type:"step",comp:"Step",icon:"Step"},{name:"时间线",type:"timeLine",comp:"TimeLine",icon:"TimeLine"},{name:"标签页",type:"tabs",comp:"Tabs",icon:"Tabs"},{name:"图表",type:"chart",comp:"Chart",icon:"chart-new"},{name:"行内布局",type:"layout",comp:"Layout",icon:"ai13"}]),uf={TABLE:ba.ssTable,FORM:Bo,TABLEOPERATE:ps,TABLESTYLE:Ts,TABLEEXTEND:Is,TABLEINTERACTION:Vs,FORMOPERATE:Io,FOLD:cc,CALCULATOR:vc,METHODBUTTON:yc,AVATARUPLOAD:Eo.ssAvatar,SIGNATURE:Eo.ssSignature,FORMTOP:Bo,STEP:Ic,STEPOPERATE:ec,TIMELINE:zc,TIMELINEOPERATE:lc,FORMTOPOPERATE:Io,SIGNATUREOPERATE:Sc,AVATARUPLOADOPERATE:xc,TABS:Pc,TABSOPERATE:Du,CHART:Ru,CHARTOPERATE:Xu,LAYOUT:Wd,LAYOUTOPERATE:ep,PARENTITEM:cf};function aa(a){return uf[a==null?void 0:a.toUpperCase()]||null}exports.De=al;exports._sfc_main=wr;exports.activeStepInfo=ca;exports.affixItems=Ad;exports.allMapContents=io;exports.analyzeSplitToContent=fo;exports.analyzerStringToArray=Yu;exports.cacheNewData=Nr;exports.clickMainKey=Or;exports.clickSavePage=Nd;exports.clickStep=zr;exports.clickTrigger=Vr;exports.compId=fa;exports.compNames=Ar;exports.compShow=$a;exports.existLayouts=zd;exports.generateLayouts=Ds;exports.getComponent=aa;exports.getComponents=ja;exports.getSliceContLength=Ld;exports.gridRowHeight=bs;exports.isStepLayout=Fr;exports.onBack=Td;exports.onChange=Ua;exports.onClick=Id;exports.onContentChange=Ka;exports.onExtendTaskEnd=Md;exports.onPageBack=Fd;exports.onPageChange=Wa;exports.onSelectFixContent=Sd;exports.prefixSum=Zu;exports.renderShowItems=Br;exports.same=Ju;exports.setComponent=Er;exports.showItems=Gt;exports.sliceTableLength=Ir;exports.slotContent=ol;exports.ssMenu=La;exports.st=Ha;exports.stepItems=$d;exports.toolBar=ka;exports.verifyButton=Rd;
|