import{_ as e}from"./u-icon.f5369555.js";import{d as t,u as o,r,c as n,an as a,p as i,q as l,h as s,i as d,w as u,M as c,O as p,N as h,F as m,n as g,l as f,x as v,j as b,m as y,D as x,E as w,R as _,t as S,H as D,K as E,a1 as R,aG as C,aH as k,S as T,U as I,aI as N,am as O,aJ as W,aq as A,J as M,X as H,aK as P,aL as B,aM as j}from"./index-15eacd31.js";import{_ as z,a as F}from"./tabbar.e67e4875.js";import{c as X}from"./article.0307362e.js";import{_ as Y}from"./_plugin-vue_export-helper.1b428a4d.js";import{_ as G}from"./app-link.vue_vue_type_script_setup_true_lang.18597de0.js";import{_ as U}from"./u-avatar.ddef1faa.js";const L=Y(t({__name:"index",props:["component","index","pullDownRefresh"],setup(t){const E=t,R=o(),C=r([]),k=n((()=>"decorate"==R.mode?R.value[E.index]:E.component)),T=n((()=>{var e="";return k.value.componentBgColor&&(e+="background-color:"+k.value.componentBgColor+";"),k.value.topRounded&&(e+="border-top-left-radius:"+2*k.value.topRounded+"rpx;"),k.value.topRounded&&(e+="border-top-right-radius:"+2*k.value.topRounded+"rpx;"),k.value.bottomRounded&&(e+="border-bottom-left-radius:"+2*k.value.bottomRounded+"rpx;"),k.value.bottomRounded&&(e+="border-bottom-right-radius:"+2*k.value.bottomRounded+"rpx;"),e})),I=n((()=>{var e="";return k.value.elementBgColor&&(e+="background-color:"+k.value.elementBgColor+";"),k.value.topElementRounded&&(e+="border-top-left-radius:"+2*k.value.topElementRounded+"rpx;"),k.value.topElementRounded&&(e+="border-top-right-radius:"+2*k.value.topElementRounded+"rpx;"),k.value.bottomElementRounded&&(e+="border-bottom-left-radius:"+2*k.value.bottomElementRounded+"rpx;"),k.value.bottomElementRounded&&(e+="border-bottom-right-radius:"+2*k.value.bottomElementRounded+"rpx;"),e}));a((()=>E.pullDownRefresh),((e,t)=>{}));(()=>{if("decorate"==R.mode){let e={image:"",summary:"文章摘要",title:"文章标题",create_time:"2023-03-28 09:00:00"};C.value.push(e),C.value.push(e)}else(()=>{let e={};"diy"==k.value.sources?e.ids=k.value.articleIds:e.limit=k.value.count,X(e).then((e=>{C.value=e.data}))})()})();return(t,o)=>{const r=i(l("u-icon"),e),n=i(l("u--image"),z),a=S,E=D;return s(),d(a,{style:g(f(T))},{default:u((()=>[(s(!0),c(p,null,h(C.value,((e,t)=>(s(),d(a,{key:e.id,class:m(["item flex align-center p-[20rpx]",{"border-solid border-t-0 border-l-0 border-r-0 border-b border-gray-200 mb-[20rpx]":C.value.length-1!==t}]),onClick:t=>{return o=e.id,void _({url:"/pages/article/detail",param:{id:o}});var o},style:g(f(I))},{default:u((()=>[e.image?(s(),d(n,{key:0,width:"260rpx",height:"200rpx",src:f(v)(e.image),model:"aspectFill"},{error:u((()=>[b(r,{name:"photo",color:"#999",size:"50"})])),_:2},1032,["src"])):y("",!0),b(a,{class:"flex-1 flex flex-col justify-between ml-[20rpx]"},{default:u((()=>[b(a,{class:"text-[32rpx] leading-[1.3] multi-hidden mt-[4rpx]"},{default:u((()=>[x(w(e.title),1)])),_:2},1024),b(a,{class:"text-[28rpx] using-hidden mb-[auto] mt-[20rpx] text-gray-500"},{default:u((()=>[x(w(e.summary),1)])),_:2},1024),b(a,{class:"text-[24rpx] text-gray-400 flex justify-between mt-[10rpx]"},{default:u((()=>[b(E,null,{default:u((()=>[x(w(e.create_time),1)])),_:2},1024)])),_:2},1024)])),_:2},1024)])),_:2},1032,["class","onClick","style"])))),128))])),_:1},8,["style"])}}}),[["__scopeId","data-v-e40f9828"]]),q=Y(t({__name:"index",props:["component","index","pullDownRefresh"],setup(t){const _=t,I=o(),N=n((()=>"decorate"==I.mode?I.value[_.index]:_.component)),O=n((()=>{var e="";return N.value.componentBgColor&&(e+="background-color:"+N.value.componentBgColor+";"),N.value.topRounded&&(e+="border-top-left-radius:"+2*N.value.topRounded+"rpx;"),N.value.topRounded&&(e+="border-top-right-radius:"+2*N.value.topRounded+"rpx;"),N.value.bottomRounded&&(e+="border-bottom-left-radius:"+2*N.value.bottomRounded+"rpx;"),N.value.bottomRounded&&(e+="border-bottom-right-radius:"+2*N.value.bottomRounded+"rpx;"),e}));a((()=>_.pullDownRefresh),((e,t)=>{}));const W=r(0),A=e=>{W.value=e.detail.current},M=(e,t)=>{let o=N.value.pageCount*N.value.rowCount,r=!0;return r=e>=[(t-1)*o]&&e<[t*o],r},H=r("");E((()=>{P(),"decorate"==I.mode&&a((()=>N.value),((e,t)=>{e&&"GraphicNav"==e.componentName&&P()}))}));const P=()=>{var e;"decorate"==I.mode&&N.value.list.forEach(((e,t)=>{""==e.imageUrl&&(e.imageUrl="static/resource/images/diy/figure.png")})),e=0,"graphic"==N.value.mode?e=(49+N.value.imageSize)*N.value.pageCount:"img"==N.value.mode?e=(22+N.value.imageSize)*N.value.pageCount:"text"==N.value.mode&&(e=43*N.value.pageCount),H.value=2*e+"rpx"};return(t,o)=>{const r=R,n=D,a=S,_=i(l("u-icon"),e),E=i(l("app-link"),G),I=C,W=k,P=T;return s(),d(a,{style:g(f(O))},{default:u((()=>[f(N).navTitle?(s(),c("div",{key:0,class:"py-[30rpx] px-[32rpx] text-[30rpx]",style:g({fontWeight:f(N).font.weight,color:f(N).font.color})},w(f(N).navTitle),5)):y("",!0),"vertical"==f(N).layout?(s(),d(a,{key:1,class:"graphic-nav"},{default:u((()=>[(s(!0),c(p,null,h(f(N).list,((e,t)=>(s(),d(a,{class:"graphic-nav-item",key:e.id},{default:u((()=>[b(E,{data:e.link,class:m(["flex items-center justify-between py-[30rpx] px-[32rpx]",[0==t?"border-t-0":"border-t"]])},{default:u((()=>["text"!=f(N).mode?(s(),d(a,{key:0,class:"graphic-img relative flex items-center w-10 h-10 mr-[20rpx]",style:g({width:2*f(N).imageSize+"rpx",height:2*f(N).imageSize+"rpx"})},{default:u((()=>[b(r,{src:f(v)(e.imageUrl),mode:"aspectFill",style:g({maxWidth:2*f(N).imageSize+"rpx",maxHeight:2*f(N).imageSize+"rpx",borderRadius:2*f(N).aroundRadius+"rpx"})},null,8,["src","style"]),e.label.control?(s(),d(n,{key:0,class:"tag absolute -top-[10rpx] -right-[24rpx] text-white rounded-[24rpx] rounded-bl-none transform scale-80 py-1 px-2 text-xs",style:g({color:e.label.textColor,backgroundImage:"linear-gradient("+e.label.bgColorStart+","+e.label.bgColorEnd+")"})},{default:u((()=>[x(w(e.label.text),1)])),_:2},1032,["style"])):y("",!0)])),_:2},1032,["style"])):y("",!0),"img"!=f(N).mode?(s(),d(n,{key:1,class:"graphic-text w-full truncate leading-normal",style:g({fontSize:2*f(N).font.size+"rpx",fontWeight:f(N).font.weight,color:f(N).font.color})},{default:u((()=>[x(w(e.title),1)])),_:2},1032,["style"])):y("",!0),b(_,{name:"arrow-right",color:"#CACACA"})])),_:2},1032,["data","class"])])),_:2},1024)))),128))])),_:1})):"horizontal"==f(N).layout&&"pageSlide"==f(N).showStyle?(s(),d(W,{key:2,class:"graphic-nav p-2 box-border relative",circular:"","indicator-dots":!1,style:g({height:H.value}),onChange:A},{default:u((()=>[(s(!0),c(p,null,h(Math.ceil(f(N).list.length/(f(N).pageCount*f(N).rowCount)),((e,t)=>(s(),d(I,{class:"graphic-nav-wrap flex flex-wrap"},{default:u((()=>[(s(!0),c(p,null,h(f(N).list,((t,o)=>(s(),c(p,null,[M(o,e)?(s(),d(a,{class:m(["graphic-nav-item",[f(N).mode]]),key:t.id,style:g({width:100/f(N).rowCount+"%"})},{default:u((()=>[b(E,{data:t.link,class:"flex flex-col items-center box-border py-2"},{default:u((()=>["text"!=f(N).mode?(s(),d(a,{key:0,class:"graphic-img relative flex items-center justify-center w-10 h-10",style:g({width:2*f(N).imageSize+"rpx",height:2*f(N).imageSize+"rpx"})},{default:u((()=>[b(r,{src:f(v)(t.imageUrl),mode:"aspectFill",style:g({maxWidth:2*f(N).imageSize+"rpx",maxHeight:2*f(N).imageSize+"rpx",borderRadius:2*f(N).aroundRadius+"rpx"})},null,8,["src","style"]),t.label.control?(s(),d(n,{key:0,class:"tag absolute -top-[10rpx] -right-[24rpx] text-white rounded-[24rpx] rounded-bl-none transform scale-80 py-1 px-2 text-xs",style:g({color:t.label.textColor,backgroundImage:"linear-gradient("+t.label.bgColorStart+","+t.label.bgColorEnd+")"})},{default:u((()=>[x(w(t.label.text),1)])),_:2},1032,["style"])):y("",!0)])),_:2},1032,["style"])):y("",!0),"img"!=f(N).mode?(s(),d(n,{key:1,class:m(["graphic-text w-full text-center truncate leading-normal",{"pt-1.5":"text"!=f(N).mode}]),style:g({fontSize:2*f(N).font.size+"rpx",fontWeight:f(N).font.weight,color:f(N).font.color})},{default:u((()=>[x(w(t.title),1)])),_:2},1032,["class","style"])):y("",!0)])),_:2},1032,["data"])])),_:2},1032,["class","style"])):y("",!0)],64)))),256))])),_:2},1024)))),256))])),_:1},8,["style"])):(s(),d(P,{key:3,"scroll-x":"singleSlide"==f(N).showStyle,class:m(["graphic-nav","graphic-nav-"+f(N).showStyle])},{default:u((()=>[(s(!0),c(p,null,h(f(N).list,((e,t)=>(s(),d(a,{class:m(["graphic-nav-item",{"flex-shrink-0":"singleSlide"==f(N).showStyle}]),key:e.id,style:g({width:100/f(N).rowCount+"%"})},{default:u((()=>[b(E,{data:e.link,class:"flex flex-col items-center box-border py-2"},{default:u((()=>["text"!=f(N).mode?(s(),d(a,{key:0,class:"graphic-img relative flex items-center justify-center w-10 h-10",style:g({width:2*f(N).imageSize+"rpx",height:2*f(N).imageSize+"rpx"})},{default:u((()=>[b(r,{src:f(v)(e.imageUrl),mode:"aspectFill",style:g({maxWidth:2*f(N).imageSize+"rpx",maxHeight:2*f(N).imageSize+"rpx",borderRadius:2*f(N).aroundRadius+"rpx"})},null,8,["src","style"]),e.label.control?(s(),d(n,{key:0,class:m(["tag absolute -top-[10rpx] -right-[24rpx] text-white rounded-[24rpx] rounded-bl-none transform scale-80 py-1 px-2 text-xs"]),style:g({color:e.label.textColor,backgroundImage:"linear-gradient("+e.label.bgColorStart+","+e.label.bgColorEnd+")"})},{default:u((()=>[x(w(e.label.text),1)])),_:2},1032,["style"])):y("",!0)])),_:2},1032,["style"])):y("",!0),"img"!=f(N).mode?(s(),d(n,{key:1,class:m(["graphic-text w-full text-center truncate leading-normal",{"pt-1.5":"text"!=f(N).mode}]),style:g({fontSize:2*f(N).font.size+"rpx",fontWeight:f(N).font.weight,color:f(N).font.color})},{default:u((()=>[x(w(e.title),1)])),_:2},1032,["class","style"])):y("",!0)])),_:2},1032,["data"])])),_:2},1032,["class","style"])))),128))])),_:1},8,["scroll-x","class"]))])),_:1},8,["style"])}}}),[["__scopeId","data-v-b36514a1"]]),$=t({__name:"index",props:["component","index","pullDownRefresh"],setup(e){const t=e,r=o(),i=n((()=>"decorate"==r.mode?r.value[t.index]:t.component)),l=n((()=>{var e="";return e+="height:"+2*i.value.height+"rpx;",i.value.componentBgColor&&(e+="background-color:"+i.value.componentBgColor+";"),e}));return a((()=>t.pullDownRefresh),((e,t)=>{})),(e,t)=>{const o=S;return s(),d(o,{style:g(f(l))},null,8,["style"])}}}),V=t({__name:"index",props:["component","index","pullDownRefresh"],setup(e){const t=e,m=o(),y=n((()=>"decorate"==m.mode?m.value[t.index]:t.component)),x=n((()=>{var e="";return y.value.componentBgColor&&(e+="background-color:"+y.value.componentBgColor+";"),e})),w=n((()=>{var e="";return y.value.topRounded&&(e+="border-top-left-radius:"+2*y.value.topRounded+"rpx;"),y.value.topRounded&&(e+="border-top-right-radius:"+2*y.value.topRounded+"rpx;"),y.value.bottomRounded&&(e+="border-bottom-left-radius:"+2*y.value.bottomRounded+"rpx;"),y.value.bottomRounded&&(e+="border-bottom-right-radius:"+2*y.value.bottomRounded+"rpx;"),e}));a((()=>t.pullDownRefresh),((e,t)=>{}));const _=n((()=>2*y.value.imageHeight+"rpx")),D=r(0),T=e=>{D.value=e.detail.current};E((()=>{I(),"decorate"==m.mode&&a((()=>y.value),((e,t)=>{e&&"ImageAds"==e.componentName&&I()}))}));const I=()=>{"decorate"==m.mode&&y.value.list.forEach(((e,t)=>{""==e.imageUrl&&(e.imageUrl="static/resource/images/diy/figure.png",e.imgWidth=690,e.imgHeight=330)}))};return(e,t)=>{const o=R,r=i(l("app-link"),G),n=S,a=C,m=k;return s(),d(n,{class:"image-ads",style:g(f(x))},{default:u((()=>[1==f(y).list.length?(s(),d(n,{key:0,class:"leading-0 overflow-hidden",style:g(f(w))},{default:u((()=>[b(r,{data:f(y).list[0].link},{default:u((()=>[b(o,{src:f(v)(f(y).list[0].imageUrl),style:g({height:f(_)}),mode:"heightFix",class:"w-full","show-menu-by-longpress":!0},null,8,["src","style"])])),_:1},8,["data"])])),_:1},8,["style"])):(s(),d(m,{key:1,class:"swiper",style:g({height:f(_)}),autoplay:"true",circular:"true",onChange:T},{default:u((()=>[(s(!0),c(p,null,h(f(y).list,(e=>(s(),d(a,{class:"swiper-item",key:e.id,style:g(f(w))},{default:u((()=>[b(r,{data:e.link},{default:u((()=>[b(n,{class:"item",style:g({height:f(_)})},{default:u((()=>[b(o,{src:f(v)(e.imageUrl),mode:"scaleToFill",class:"w-full h-full","show-menu-by-longpress":!0},null,8,["src"])])),_:2},1032,["style"])])),_:2},1032,["data"])])),_:2},1032,["style"])))),128))])),_:1},8,["style"]))])),_:1},8,["style"])}}}),K=Y(t({__name:"index",props:["component","index","pullDownRefresh"],setup(e){const t=e,c=o(),p=n((()=>"decorate"==c.mode?c.value[t.index]:t.component)),h=n((()=>{var e="";return p.value.componentBgColor&&(e+="background-color:"+p.value.componentBgColor+";"),p.value.bgUrl&&(e+="background-image:url("+v(p.value.bgUrl)+");",e+="background-size: 100%;",e+="background-repeat: no-repeat;"),p.value.topRounded&&(e+="border-top-left-radius:"+2*p.value.topRounded+"rpx;"),p.value.topRounded&&(e+="border-top-right-radius:"+2*p.value.topRounded+"rpx;"),p.value.bottomRounded&&(e+="border-bottom-left-radius:"+2*p.value.bottomRounded+"rpx;"),p.value.bottomRounded&&(e+="border-bottom-right-radius:"+2*p.value.bottomRounded+"rpx;"),e}));a((()=>t.pullDownRefresh),((e,t)=>{}));const m=I(),{query:y}=N(location.href);y.code&&O()&&W({code:y.code}).then((e=>{m.getMemberInfo()}));const E=n((()=>"decorate"==c.mode?{headimg:"",nickname:"昵称",balance:0,point:0,money:0,member_no:"NIU0000021"}:m.info)),R=n((()=>{if(E.value){let e=parseFloat(E.value.balance)+parseFloat(E.value.money);return A(e.toString())}return 0})),C=()=>{H().setLoginBack({url:"/pages/member/index"})};r(!1);const k=()=>{O()?H().getAuthCode("snsapi_userinfo"):_({url:"/pages/member/personal"})};return(e,t)=>{const o=i(l("u-avatar"),U),r=S,n=D,a=i(l("app-link"),G);return s(),d(r,{style:g(f(h))},{default:u((()=>[b(r,{class:"pt-[34rpx] member-info"},{default:u((()=>[f(E)?(s(),d(r,{key:0,class:"flex ml-[32rpx] mr-[52rpx] items-center relative"},{default:u((()=>[b(o,{src:f(v)(f(E).headimg),size:"55",leftIcon:"none",onClick:k},null,8,["src"]),b(r,{class:"ml-[22rpx]"},{default:u((()=>[b(r,{class:"text-[#222222] truncate w-[430rpx] font-bold text-lg",style:g({color:f(p).textColor})},{default:u((()=>[x(w(f(E).nickname),1)])),_:1},8,["style"]),b(r,{class:"text-[#696B70] text-[24rpx] mt-[10rpx]",style:g({color:f(p).textColor})},{default:u((()=>[x(" UID:"+w(f(E).member_no),1)])),_:1},8,["style"])])),_:1}),b(r,{class:"set-icon flex items-center absolute right-0 top-2"},{default:u((()=>[b(a,{url:"/pages/setting/index"},{default:u((()=>[b(n,{class:"iconfont iconshezhi text-[1.6rem] ml-[10rpx]",style:g({color:f(p).textColor})},null,8,["style"])])),_:1})])),_:1})])),_:1})):(s(),d(r,{key:1,class:"flex ml-[32rpx] mr-[52rpx] items-center relative",onClick:C},{default:u((()=>[b(o,{src:"",size:"55"}),b(r,{class:"ml-[22rpx]"},{default:u((()=>[b(r,{class:"text-[#222222] font-bold text-lg",style:g({color:f(p).textColor})},{default:u((()=>[x(w(f(M)("login"))+"/"+w(f(M)("register")),1)])),_:1},8,["style"])])),_:1}),b(r,{class:"set-icon flex items-center absolute right-0 top-2"},{default:u((()=>[b(a,{url:"/pages/setting/index"},{default:u((()=>[b(n,{class:"iconfont iconshezhi text-[1.6rem] ml-[10rpx]",style:g({color:f(p).textColor})},null,8,["style"])])),_:1})])),_:1})])),_:1})),b(r,{class:"flex m-[30rpx] mb-0 py-[30rpx] items-center"},{default:u((()=>[b(r,{class:"flex-1 text-center"},{default:u((()=>[b(r,{class:"font-bold"},{default:u((()=>[b(a,{url:f(E)?"/pages/member/balance":"",style:g({color:f(p).textColor})},{default:u((()=>[x(w(f(R)),1)])),_:1},8,["url","style"])])),_:1}),b(r,{class:"text-sm mt-[10rpx]"},{default:u((()=>[b(a,{url:f(E)?"/pages/member/balance":"",style:g({color:f(p).textColor})},{default:u((()=>[x(w(f(M)("balance")),1)])),_:1},8,["url","style"])])),_:1})])),_:1}),b(r,{class:"border-solid border-white border-l border-b-0 border-t-0 border-r-0 h-[60rpx]"}),b(r,{class:"flex-1 text-center"},{default:u((()=>[b(r,{class:"font-bold"},{default:u((()=>[b(a,{url:f(E)?"/pages/member/point":"",style:g({color:f(p).textColor})},{default:u((()=>{var e;return[x(w(parseInt(null==(e=f(E))?void 0:e.point)||0),1)]})),_:1},8,["url","style"])])),_:1}),b(r,{class:"text-sm mt-[10rpx]"},{default:u((()=>[b(a,{url:f(E)?"/pages/member/point":"",style:g({color:f(p).textColor})},{default:u((()=>[x(w(f(M)("point")),1)])),_:1},8,["url","style"])])),_:1})])),_:1})])),_:1})])),_:1})])),_:1},8,["style"])}}}),[["__scopeId","data-v-1e679529"]]),J=Y(t({__name:"index",props:["component","index","pullDownRefresh"],setup(t){const r=t,c=o(),p=n((()=>"decorate"==c.mode?c.value[r.index]:r.component)),h=n((()=>{var e="";return p.value.componentBgColor&&(e+="background-color:"+p.value.componentBgColor+";"),p.value.topRounded&&(e+="border-top-left-radius:"+2*p.value.topRounded+"rpx;"),p.value.topRounded&&(e+="border-top-right-radius:"+2*p.value.topRounded+"rpx;"),p.value.bottomRounded&&(e+="border-bottom-left-radius:"+2*p.value.bottomRounded+"rpx;"),p.value.bottomRounded&&(e+="border-bottom-right-radius:"+2*p.value.bottomRounded+"rpx;"),e}));return a((()=>r.pullDownRefresh),((e,t)=>{})),(t,o)=>{const r=S,n=i(l("app-link"),G),a=D,c=i(l("u-icon"),e);return s(),d(r,{class:"diy-text",style:g(f(h))},{default:u((()=>["style-1"==f(p).style?(s(),d(r,{key:0,class:"p-[20rpx]"},{default:u((()=>[b(n,{data:f(p).link},{default:u((()=>[b(r,{style:g({fontSize:2*f(p).fontSize+"rpx",color:f(p).textColor,fontWeight:f(p).fontWeight,textAlign:f(p).textAlign})},{default:u((()=>[x(w(f(p).text),1)])),_:1},8,["style"])])),_:1},8,["data"])])),_:1})):y("",!0),"style-2"==f(p).style?(s(),d(r,{key:1,class:"p-[20rpx] flex items-center"},{default:u((()=>[b(n,{data:f(p).link},{default:u((()=>[b(r,{class:"max-w-[200rpx] truncate",style:g({fontSize:2*f(p).fontSize+"rpx",color:f(p).textColor,fontWeight:f(p).fontWeight})},{default:u((()=>[x(w(f(p).text),1)])),_:1},8,["style"])])),_:1},8,["data"]),b(a,{class:"ml-[16rpx] max-w-[300rpx] truncate",style:g({color:f(p).subTitle.color,fontSize:2*f(p).subTitle.fontSize+"rpx"})},{default:u((()=>[x(w(f(p).subTitle.text),1)])),_:1},8,["style"]),f(p).more.isShow?(s(),d(r,{key:0,class:"ml-auto text-right",style:g({color:f(p).more.color})},{default:u((()=>[b(n,{data:f(p).more.link,class:"flex items-center"},{default:u((()=>[b(a,{class:"max-w-[200rpx] truncate text-[24rpx] mr-[8rpx]"},{default:u((()=>[x(w(f(p).more.text),1)])),_:1}),b(c,{name:"arrow-right",size:"12",style:g({color:f(p).more.color})},null,8,["style"])])),_:1},8,["data"])])),_:1},8,["style"])):y("",!0)])),_:1})):y("",!0)])),_:1},8,["style"])}}}),[["__scopeId","data-v-7fc5a7a3"]]),Z=Y(t({__name:"index",props:["component","index","pullDownRefresh"],setup(e){const t=e,r=o(),x=n((()=>"decorate"==r.mode?r.value[t.index]:t.component)),w=n((()=>{var e="";return x.value.componentBgColor&&(e+="background-color:"+x.value.componentBgColor+";"),x.value.topRounded&&(e+="border-top-left-radius:"+2*x.value.topRounded+"rpx;"),x.value.topRounded&&(e+="border-top-right-radius:"+2*x.value.topRounded+"rpx;"),x.value.bottomRounded&&(e+="border-bottom-left-radius:"+2*x.value.bottomRounded+"rpx;"),x.value.bottomRounded&&(e+="border-bottom-right-radius:"+2*x.value.bottomRounded+"rpx;"),e}));a((()=>t.pullDownRefresh),((e,t)=>{})),E((()=>{_(),a((()=>x.value),((e,t)=>{e&&"RubikCube"==e.componentName&&_()}))}));const _=()=>{"decorate"==r.mode&&x.value.list.forEach(((e,t)=>{""==e.imageUrl&&(e.imageUrl="static/resource/images/diy/figure.png",e.imgWidth=690,e.imgHeight=330)})),D()},D=()=>{var e={"row1-of2":{ratio:2,width:"calc((100% - "+P(2*x.value.imageGap)+"px) / 2)"},"row1-of3":{ratio:3,width:"calc((100% - "+P(4*x.value.imageGap)+"px) / 3)"},"row1-of4":{ratio:4,width:"calc((100% - "+P(6*x.value.imageGap)+"px) / 4)"}};x.value.list.forEach(((e,t)=>{e.pageItemStyle=((e,t)=>{var o="";return"right"==x.value.elementAngle||{"row1-lt-of2-rt":[["border-top-right-radius","border-bottom-right-radius"],["border-top-left-radius","border-bottom-left-radius","border-bottom-right-radius"],["border-top-left-radius","border-bottom-left-radius","border-top-right-radius"]],"row1-lt-of1-tp-of2-bm":[["border-top-right-radius","border-bottom-right-radius"],["border-top-left-radius","border-bottom-left-radius","border-bottom-right-radius"],["border-radius"],["border-top-left-radius","border-bottom-left-radius","border-top-right-radius"]],"row1-tp-of2-bm":[["border-bottom-left-radius","border-bottom-right-radius"],["border-top-left-radius","border-bottom-right-radius","border-top-right-radius"],["border-top-left-radius","border-bottom-left-radius","border-top-right-radius"]],"row2-lt-of2-rt":[["border-top-right-radius","border-bottom-left-radius","border-bottom-right-radius"],["border-top-left-radius","border-bottom-right-radius","border-bottom-left-radius"],["border-top-left-radius","border-bottom-right-radius","border-top-right-radius"],["border-top-left-radius","border-bottom-left-radius","border-top-right-radius"]],"row1-of4":[["border-top-right-radius","border-bottom-right-radius"],["border-radius"],["border-radius"],["border-top-left-radius","border-bottom-left-radius"]],"row1-of3":[["border-top-right-radius","border-bottom-right-radius"],["border-radius"],["border-top-left-radius","border-bottom-left-radius"]],"row1-of2":[["border-top-right-radius","border-bottom-right-radius"],["border-top-left-radius","border-bottom-left-radius"]]}[e][t].forEach(((e,t)=>{o+="border-top-left-radius:"+2*x.value.topElementRounded+"rpx;",o+="border-top-right-radius:"+2*x.value.topElementRounded+"rpx;",o+="border-bottom-left-radius:"+2*x.value.bottomElementRounded+"rpx;",o+="border-bottom-right-radius:"+2*x.value.bottomElementRounded+"rpx;"})),o})(x.value.mode,t)})),e[x.value.mode]?C(e[x.value.mode]):"row2-lt-of2-rt"==x.value.mode?k():"row1-lt-of2-rt"==x.value.mode?T():"row1-tp-of2-bm"==x.value.mode?I():"row1-lt-of1-tp-of2-bm"==x.value.mode&&N()},C=e=>{B({success:t=>{let o=0;x.value.list.forEach(((r,n)=>{var a=r.imgHeight/r.imgWidth;let i=t.windowWidth-P(2*x.value.margin.both);x.value.imageGap>0&&(i-=P(e.ratio*x.value.imageGap*2)),r.imgWidth=i/e.ratio,r.imgHeight=r.imgWidth*a,(0==o||o{t.widthStyle=e.width,t.imgHeight=o}))}})},k=()=>{B({success:e=>{let t=0,o=0;x.value.list.forEach(((r,n)=>{var a=r.imgHeight/r.imgWidth;r.imgWidth=e.windowWidth,r.imgWidth-=P(4*x.value.margin.both),x.value.imageGap>0&&(r.imgWidth-=P(2*x.value.imageGap)),r.imgWidth=r.imgWidth/2,r.imgHeight=r.imgWidth*a,n<=1?(0==t||t1&&(0==o||o{e.imgWidth="calc((100% - "+P(2*x.value.imageGap)+"px) / 2)",e.widthStyle=e.imgWidth,r<=1?e.imgHeight=t:r>1&&(e.imgHeight=o)}))}})},T=()=>{let e=0;x.value.list[1].imgWidth,x.value.list[2].imgWidth,B({success:t=>{x.value.list.forEach(((o,r)=>{if(0==r){var n=o.imgHeight/o.imgWidth;o.imgWidth=t.windowWidth-P(4*x.value.margin.both)-P(2*x.value.imageGap),o.imgWidth=o.imgWidth/2,o.imgHeight=o.imgWidth*n,e=(o.imgHeight-P(2*x.value.imageGap))/2,o.imgWidth+="px"}else o.imgWidth=x.value.list[0].imgWidth,o.imgHeight=e}))}})},I=()=>{var e=0;B({success:t=>{x.value.list.forEach(((o,r)=>{var n=o.imgHeight/o.imgWidth;0==r?o.imgWidth=t.windowWidth-P(4*x.value.margin.both):r>0&&(o.imgWidth=t.windowWidth-P(4*x.value.margin.both)-P(2*x.value.imageGap),o.imgWidth=o.imgWidth/2),o.imgHeight=o.imgWidth*n,r>0&&(0==e||e{t.imgWidth+="px",t.widthStyle=t.imgWidth,o>0&&(t.imgHeight=e)}))}})},N=()=>{B({success:e=>{x.value.list.forEach(((t,o)=>{if(0==o){var r=t.imgHeight/t.imgWidth;t.imgWidth=e.windowWidth-P(4*x.value.margin.both)-P(2*x.value.imageGap),t.imgWidth=t.imgWidth/2,t.imgHeight=t.imgWidth*r}else 1==o?(t.imgWidth=x.value.list[0].imgWidth,t.imgHeight=(x.value.list[0].imgHeight-P(2*x.value.imageGap))/2):o>1&&(t.imgWidth=(x.value.list[0].imgWidth-P(2*x.value.imageGap))/2,t.imgHeight=x.value.list[1].imgHeight)})),x.value.list.forEach(((e,t)=>{e.imgWidth+="px",e.imgHeight}))}})};return(e,t)=>{const o=R,n=i(l("app-link"),G),a=S;return s(),d(a,{class:m(["rubik-cube",f(r).mode]),style:g(f(w))},{default:u((()=>["row1-lt-of2-rt"==f(x).mode?(s(),c(p,{key:0},[b(a,{class:"template-left"},{default:u((()=>[b(n,{data:f(x).list[0].link,class:m(["item",f(x).mode]),style:g({marginRight:2*f(x).imageGap+"rpx",width:f(x).list[0].imgWidth,height:f(x).list[0].imgHeight+"px"})},{default:u((()=>[b(o,{src:f(v)(f(x).list[0].imageUrl),mode:"scaleToFill",style:g(f(x).list[0].pageItemStyle),"show-menu-by-longpress":!0},null,8,["src","style"])])),_:1},8,["data","class","style"])])),_:1}),b(a,{class:"template-right"},{default:u((()=>[(s(!0),c(p,null,h(f(x).list,((e,t)=>(s(),c(p,{key:t},[t>0?(s(),d(n,{key:0,data:e.link,class:m(["item",f(x).mode]),style:g({marginBottom:2*f(x).imageGap+"rpx",width:e.imgWidth,height:e.imgHeight+"px"})},{default:u((()=>[b(o,{src:f(v)(e.imageUrl),mode:"scaleToFill",style:g(e.pageItemStyle),"show-menu-by-longpress":!0},null,8,["src","style"])])),_:2},1032,["data","class","style"])):y("",!0)],64)))),128))])),_:1})],64)):"row1-lt-of1-tp-of2-bm"==f(x).mode?(s(),c(p,{key:1},[b(a,{class:"template-left"},{default:u((()=>[b(n,{data:f(x).list[0].link,class:m(["item",f(x).mode]),style:g({marginRight:2*f(x).imageGap+"rpx",width:f(x).list[0].imgWidth,height:f(x).list[0].imgHeight+"px"})},{default:u((()=>[b(o,{src:f(v)(f(x).list[0].imageUrl),mode:"scaleToFill",style:g(f(x).list[0].pageItemStyle),"show-menu-by-longpress":!0},null,8,["src","style"])])),_:1},8,["data","class","style"])])),_:1}),b(a,{class:"template-right"},{default:u((()=>[b(n,{data:f(x).list[1].link,class:m(["item",f(x).mode]),style:g({marginBottom:2*f(x).imageGap+"rpx",width:f(x).list[1].imgWidth,height:f(x).list[1].imgHeight+"px"})},{default:u((()=>[b(o,{src:f(v)(f(x).list[1].imageUrl),mode:"scaleToFill",style:g(f(x).list[1].pageItemStyle),"show-menu-by-longpress":!0},null,8,["src","style"])])),_:1},8,["data","class","style"]),b(a,{class:"template-bottom"},{default:u((()=>[(s(!0),c(p,null,h(f(x).list,((e,t)=>(s(),c(p,{key:t},[t>1?(s(),d(n,{key:0,data:e.link,class:m(["item",f(x).mode]),style:g({marginRight:2*f(x).imageGap+"rpx",width:e.imgWidth,height:e.imgHeight+"px"})},{default:u((()=>[b(o,{src:f(v)(e.imageUrl),mode:"scaleToFill",style:g(e.pageItemStyle),"show-menu-by-longpress":!0},null,8,["src","style"])])),_:2},1032,["data","class","style"])):y("",!0)],64)))),128))])),_:1})])),_:1})],64)):(s(!0),c(p,{key:2},h(f(x).list,((e,t)=>(s(),d(n,{class:m(["item",f(x).mode]),key:t,data:e.link,style:g({marginRight:2*f(x).imageGap+"rpx",marginBottom:2*f(x).imageGap+"rpx",width:e.widthStyle,height:e.imgHeight+"px"})},{default:u((()=>[b(o,{src:f(v)(e.imageUrl),mode:"scaleToFill",style:g(e.pageItemStyle),"show-menu-by-longpress":!0},null,8,["src","style"])])),_:2},1032,["class","data","style"])))),128))])),_:1},8,["class","style"])}}}),[["__scopeId","data-v-5d671723"]]),Q=t({__name:"index",props:["component","index","pullDownRefresh"],setup(e){const t=e,r=o(),m=n((()=>"decorate"==r.mode?r.value[t.index]:t.component)),x=n((()=>{var e="";return m.value.componentBgColor&&(e+="background-color:"+m.value.componentBgColor+";"),m.value.topRounded&&(e+="border-top-left-radius:"+2*m.value.topRounded+"rpx;"),m.value.topRounded&&(e+="border-top-right-radius:"+2*m.value.topRounded+"rpx;"),m.value.bottomRounded&&(e+="border-bottom-left-radius:"+2*m.value.bottomRounded+"rpx;"),m.value.bottomRounded&&(e+="border-bottom-right-radius:"+2*m.value.bottomRounded+"rpx;"),e}));E((()=>{w(),a((()=>m.value),((e,t)=>{e&&"HotArea"==e.componentName&&w()}))}));const w=()=>{"decorate"==r.mode&&""==m.value.imageUrl&&(m.value.imageUrl="static/resource/images/diy/figure.png",m.value.imgWidth=690,m.value.imgHeight=330)};return a((()=>t.pullDownRefresh),((e,t)=>{})),(e,t)=>{const o=R,n=i(l("app-link"),G),a=S;return s(),d(a,{style:g(f(x))},{default:u((()=>[b(a,{class:"simple-graph-wrap overflow-hidden relative leading-0"},{default:u((()=>[b(o,{style:g({height:f(m).imgHeight}),src:f(v)(f(m).imageUrl),mode:"widthFix","show-menu-by-longpress":!0,class:"w-full"},null,8,["style","src"]),"decorate"!=f(r).mode?(s(!0),c(p,{key:0},h(f(m).heatMapData,((e,t)=>(s(),d(n,{data:e.link,class:"absolute",key:t,style:g({width:e.width+"%",height:e.height+"%",left:e.left+"%",top:e.top+"%"})},null,8,["data","style"])))),128)):y("",!0)])),_:1})])),_:1},8,["style"])}}}); /**! * Sortable 1.15.0 * @author RubaXa * @author owenm * @license MIT */ function ee(e,t){var o=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),o.push.apply(o,r)}return o}function te(e){for(var t=1;t=0||(n[o]=e[o]);return n}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r=0||Object.prototype.propertyIsEnumerable.call(e,o)&&(n[o]=e[o])}return n}function ie(e){if("undefined"!=typeof window&&window.navigator)return!!navigator.userAgent.match(e)}var le=ie(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),se=ie(/Edge/i),de=ie(/firefox/i),ue=ie(/safari/i)&&!ie(/chrome/i)&&!ie(/android/i),ce=ie(/iP(ad|od|hone)/i),pe=ie(/chrome/i)&&ie(/android/i),he={capture:!1,passive:!1};function me(e,t,o){e.addEventListener(t,o,!le&&he)}function ge(e,t,o){e.removeEventListener(t,o,!le&&he)}function fe(e,t){if(t){if(">"===t[0]&&(t=t.substring(1)),e)try{if(e.matches)return e.matches(t);if(e.msMatchesSelector)return e.msMatchesSelector(t);if(e.webkitMatchesSelector)return e.webkitMatchesSelector(t)}catch(o){return!1}return!1}}function ve(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function be(e,t,o,r){if(e){o=o||document;do{if(null!=t&&(">"===t[0]?e.parentNode===o&&fe(e,t):fe(e,t))||r&&e===o)return e;if(e===o)break}while(e=ve(e))}return null}var ye,xe=/\s+/g;function we(e,t,o){if(e&&t)if(e.classList)e.classList[o?"add":"remove"](t);else{var r=(" "+e.className+" ").replace(xe," ").replace(" "+t+" "," ");e.className=(r+(o?" "+t:"")).replace(xe," ")}}function _e(e,t,o){var r=e&&e.style;if(r){if(void 0===o)return document.defaultView&&document.defaultView.getComputedStyle?o=document.defaultView.getComputedStyle(e,""):e.currentStyle&&(o=e.currentStyle),void 0===t?o:o[t];t in r||-1!==t.indexOf("webkit")||(t="-webkit-"+t),r[t]=o+("string"==typeof o?"":"px")}}function Se(e,t){var o="";if("string"==typeof e)o=e;else do{var r=_e(e,"transform");r&&"none"!==r&&(o=r+" "+o)}while(!t&&(e=e.parentNode));var n=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return n&&new n(o)}function De(e,t,o){if(e){var r=e.getElementsByTagName(t),n=0,a=r.length;if(o)for(;n=a:n<=a))return r;if(r===Ee())break;r=Oe(r,!1)}return!1}function ke(e,t,o,r){for(var n=0,a=0,i=e.children;a2&&void 0!==arguments[2]?arguments[2]:{},r=o.evt,n=ae(o,Xe);Fe.pluginEvent.bind(Mt)(e,t,te({dragEl:Ue,parentEl:Le,ghostEl:qe,rootEl:$e,nextEl:Ve,lastDownEl:Ke,cloneEl:Je,cloneHidden:Ze,dragStarted:ct,putSortable:nt,activeSortable:Mt.active,originalEvent:r,oldIndex:Qe,oldDraggableIndex:tt,newIndex:et,newDraggableIndex:ot,hideGhostForTarget:Nt,unhideGhostForTarget:Ot,cloneNowHidden:function(){Ze=!0},cloneNowShown:function(){Ze=!1},dispatchSortableEvent:function(e){Ge({sortable:t,name:e,originalEvent:r})}},n))};function Ge(e){!function(e){var t=e.sortable,o=e.rootEl,r=e.name,n=e.targetEl,a=e.cloneEl,i=e.toEl,l=e.fromEl,s=e.oldIndex,d=e.newIndex,u=e.oldDraggableIndex,c=e.newDraggableIndex,p=e.originalEvent,h=e.putSortable,m=e.extraEventProperties;if(t=t||o&&o[Pe]){var g,f=t.options,v="on"+r.charAt(0).toUpperCase()+r.substr(1);!window.CustomEvent||le||se?(g=document.createEvent("Event")).initEvent(r,!0,!0):g=new CustomEvent(r,{bubbles:!0,cancelable:!0}),g.to=i||o,g.from=l||o,g.item=n||o,g.clone=a,g.oldIndex=s,g.newIndex=d,g.oldDraggableIndex=u,g.newDraggableIndex=c,g.originalEvent=p,g.pullMode=h?h.lastPutMode:void 0;var b=te(te({},m),Fe.getEventProperties(r,t));for(var y in b)g[y]=b[y];o&&o.dispatchEvent(g),f[v]&&f[v].call(t,g)}}(te({putSortable:nt,cloneEl:Je,targetEl:Ue,rootEl:$e,oldIndex:Qe,oldDraggableIndex:tt,newIndex:et,newDraggableIndex:ot},e))}var Ue,Le,qe,$e,Ve,Ke,Je,Ze,Qe,et,tt,ot,rt,nt,at,it,lt,st,dt,ut,ct,pt,ht,mt,gt,ft=!1,vt=!1,bt=[],yt=!1,xt=!1,wt=[],_t=!1,St=[],Dt="undefined"!=typeof document,Et=ce,Rt=se||le?"cssFloat":"float",Ct=Dt&&!pe&&!ce&&"draggable"in document.createElement("div"),kt=function(){if(Dt){if(le)return!1;var e=document.createElement("x");return e.style.cssText="pointer-events:auto","auto"===e.style.pointerEvents}}(),Tt=function(e,t){var o=_e(e),r=parseInt(o.width)-parseInt(o.paddingLeft)-parseInt(o.paddingRight)-parseInt(o.borderLeftWidth)-parseInt(o.borderRightWidth),n=ke(e,0,t),a=ke(e,1,t),i=n&&_e(n),l=a&&_e(a),s=i&&parseInt(i.marginLeft)+parseInt(i.marginRight)+Re(n).width,d=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+Re(a).width;if("flex"===o.display)return"column"===o.flexDirection||"column-reverse"===o.flexDirection?"vertical":"horizontal";if("grid"===o.display)return o.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(n&&i.float&&"none"!==i.float){var u="left"===i.float?"left":"right";return!a||"both"!==l.clear&&l.clear!==u?"horizontal":"vertical"}return n&&("block"===i.display||"flex"===i.display||"table"===i.display||"grid"===i.display||s>=r&&"none"===o[Rt]||a&&"none"===o[Rt]&&s+d>r)?"vertical":"horizontal"},It=function(e){function t(e,o){return function(r,n,a,i){var l=r.options.group.name&&n.options.group.name&&r.options.group.name===n.options.group.name;if(null==e&&(o||l))return!0;if(null==e||!1===e)return!1;if(o&&"clone"===e)return e;if("function"==typeof e)return t(e(r,n,a,i),o)(r,n,a,i);var s=(o?r:n).options.group.name;return!0===e||"string"==typeof e&&e===s||e.join&&e.indexOf(s)>-1}}var o={},r=e.group;r&&"object"==oe(r)||(r={name:r}),o.name=r.name,o.checkPull=t(r.pull,!0),o.checkPut=t(r.put),o.revertClone=r.revertClone,e.group=o},Nt=function(){!kt&&qe&&_e(qe,"display","none")},Ot=function(){!kt&&qe&&_e(qe,"display","")};Dt&&!pe&&document.addEventListener("click",(function(e){if(vt)return e.preventDefault(),e.stopPropagation&&e.stopPropagation(),e.stopImmediatePropagation&&e.stopImmediatePropagation(),vt=!1,!1}),!0);var Wt=function(e){if(Ue){e=e.touches?e.touches[0]:e;var t=(n=e.clientX,a=e.clientY,bt.some((function(e){var t=e[Pe].options.emptyInsertThreshold;if(t&&!Te(e)){var o=Re(e),r=n>=o.left-t&&n<=o.right+t,l=a>=o.top-t&&a<=o.bottom+t;return r&&l?i=e:void 0}})),i);if(t){var o={};for(var r in e)e.hasOwnProperty(r)&&(o[r]=e[r]);o.target=o.rootEl=t,o.preventDefault=void 0,o.stopPropagation=void 0,t[Pe]._onDragOver(o)}}var n,a,i},At=function(e){Ue&&Ue.parentNode[Pe]._isOutsideThisEl(e.target)};function Mt(e,t){if(!e||!e.nodeType||1!==e.nodeType)throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));this.el=e,this.options=t=ne({},t),e[Pe]=this;var o={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(e.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return Tt(e,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(e,t){e.setData("Text",t.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:!1!==Mt.supportPointer&&"PointerEvent"in window&&!ue,emptyInsertThreshold:5};for(var r in Fe.initializePlugins(this,e,o),o)!(r in t)&&(t[r]=o[r]);for(var n in It(t),this)"_"===n.charAt(0)&&"function"==typeof this[n]&&(this[n]=this[n].bind(this));this.nativeDraggable=!t.forceFallback&&Ct,this.nativeDraggable&&(this.options.touchStartThreshold=1),t.supportPointer?me(e,"pointerdown",this._onTapStart):(me(e,"mousedown",this._onTapStart),me(e,"touchstart",this._onTapStart)),this.nativeDraggable&&(me(e,"dragover",this),me(e,"dragenter",this)),bt.push(this.el),t.store&&t.store.get&&this.sort(t.store.get(this)||[]),ne(this,Be())}function Ht(e,t,o,r,n,a,i,l){var s,d,u=e[Pe],c=u.options.onMove;return!window.CustomEvent||le||se?(s=document.createEvent("Event")).initEvent("move",!0,!0):s=new CustomEvent("move",{bubbles:!0,cancelable:!0}),s.to=t,s.from=e,s.dragged=o,s.draggedRect=r,s.related=n||t,s.relatedRect=a||Re(t),s.willInsertAfter=l,s.originalEvent=i,e.dispatchEvent(s),c&&(d=c.call(u,s,i)),d}function Pt(e){e.draggable=!1}function Bt(){_t=!1}function jt(e){for(var t=e.tagName+e.className+e.src+e.href+e.textContent,o=t.length,r=0;o--;)r+=t.charCodeAt(o);return r.toString(36)}function zt(e){return setTimeout(e,0)}function Ft(e){return clearTimeout(e)}Mt.prototype={constructor:Mt,_isOutsideThisEl:function(e){this.el.contains(e)||e===this.el||(pt=null)},_getDirection:function(e,t){return"function"==typeof this.options.direction?this.options.direction.call(this,e,t,Ue):this.options.direction},_onTapStart:function(e){if(e.cancelable){var t=this,o=this.el,r=this.options,n=r.preventOnFilter,a=e.type,i=e.touches&&e.touches[0]||e.pointerType&&"touch"===e.pointerType&&e,l=(i||e).target,s=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||l,d=r.filter;if(function(e){St.length=0;var t=e.getElementsByTagName("input"),o=t.length;for(;o--;){var r=t[o];r.checked&&St.push(r)}}(o),!Ue&&!(/mousedown|pointerdown/.test(a)&&0!==e.button||r.disabled)&&!s.isContentEditable&&(this.nativeDraggable||!ue||!l||"SELECT"!==l.tagName.toUpperCase())&&!((l=be(l,r.draggable,o,!1))&&l.animated||Ke===l)){if(Qe=Ie(l),tt=Ie(l,r.draggable),"function"==typeof d){if(d.call(this,e,l,this))return Ge({sortable:t,rootEl:s,name:"filter",targetEl:l,toEl:o,fromEl:o}),Ye("filter",t,{evt:e}),void(n&&e.cancelable&&e.preventDefault())}else if(d&&(d=d.split(",").some((function(r){if(r=be(s,r.trim(),o,!1))return Ge({sortable:t,rootEl:r,name:"filter",targetEl:l,fromEl:o,toEl:o}),Ye("filter",t,{evt:e}),!0}))))return void(n&&e.cancelable&&e.preventDefault());r.handle&&!be(s,r.handle,o,!1)||this._prepareDragStart(e,i,l)}}},_prepareDragStart:function(e,t,o){var r,n=this,a=n.el,i=n.options,l=a.ownerDocument;if(o&&!Ue&&o.parentNode===a){var s=Re(o);if($e=a,Le=(Ue=o).parentNode,Ve=Ue.nextSibling,Ke=o,rt=i.group,Mt.dragged=Ue,at={target:Ue,clientX:(t||e).clientX,clientY:(t||e).clientY},dt=at.clientX-s.left,ut=at.clientY-s.top,this._lastX=(t||e).clientX,this._lastY=(t||e).clientY,Ue.style["will-change"]="all",r=function(){Ye("delayEnded",n,{evt:e}),Mt.eventCanceled?n._onDrop():(n._disableDelayedDragEvents(),!de&&n.nativeDraggable&&(Ue.draggable=!0),n._triggerDragStart(e,t),Ge({sortable:n,name:"choose",originalEvent:e}),we(Ue,i.chosenClass,!0))},i.ignore.split(",").forEach((function(e){De(Ue,e.trim(),Pt)})),me(l,"dragover",Wt),me(l,"mousemove",Wt),me(l,"touchmove",Wt),me(l,"mouseup",n._onDrop),me(l,"touchend",n._onDrop),me(l,"touchcancel",n._onDrop),de&&this.nativeDraggable&&(this.options.touchStartThreshold=4,Ue.draggable=!0),Ye("delayStart",this,{evt:e}),!i.delay||i.delayOnTouchOnly&&!t||this.nativeDraggable&&(se||le))r();else{if(Mt.eventCanceled)return void this._onDrop();me(l,"mouseup",n._disableDelayedDrag),me(l,"touchend",n._disableDelayedDrag),me(l,"touchcancel",n._disableDelayedDrag),me(l,"mousemove",n._delayedDragTouchMoveHandler),me(l,"touchmove",n._delayedDragTouchMoveHandler),i.supportPointer&&me(l,"pointermove",n._delayedDragTouchMoveHandler),n._dragStartTimer=setTimeout(r,i.delay)}}},_delayedDragTouchMoveHandler:function(e){var t=e.touches?e.touches[0]:e;Math.max(Math.abs(t.clientX-this._lastX),Math.abs(t.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){Ue&&Pt(Ue),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var e=this.el.ownerDocument;ge(e,"mouseup",this._disableDelayedDrag),ge(e,"touchend",this._disableDelayedDrag),ge(e,"touchcancel",this._disableDelayedDrag),ge(e,"mousemove",this._delayedDragTouchMoveHandler),ge(e,"touchmove",this._delayedDragTouchMoveHandler),ge(e,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(e,t){t=t||"touch"==e.pointerType&&e,!this.nativeDraggable||t?this.options.supportPointer?me(document,"pointermove",this._onTouchMove):me(document,t?"touchmove":"mousemove",this._onTouchMove):(me(Ue,"dragend",this),me($e,"dragstart",this._onDragStart));try{document.selection?zt((function(){document.selection.empty()})):window.getSelection().removeAllRanges()}catch(o){}},_dragStarted:function(e,t){if(ft=!1,$e&&Ue){Ye("dragStarted",this,{evt:t}),this.nativeDraggable&&me(document,"dragover",At);var o=this.options;!e&&we(Ue,o.dragClass,!1),we(Ue,o.ghostClass,!0),Mt.active=this,e&&this._appendGhost(),Ge({sortable:this,name:"start",originalEvent:t})}else this._nulling()},_emulateDragOver:function(){if(it){this._lastX=it.clientX,this._lastY=it.clientY,Nt();for(var e=document.elementFromPoint(it.clientX,it.clientY),t=e;e&&e.shadowRoot&&(e=e.shadowRoot.elementFromPoint(it.clientX,it.clientY))!==t;)t=e;if(Ue.parentNode[Pe]._isOutsideThisEl(e),t)do{if(t[Pe]){if(t[Pe]._onDragOver({clientX:it.clientX,clientY:it.clientY,target:e,rootEl:t})&&!this.options.dragoverBubble)break}e=t}while(t=t.parentNode);Ot()}},_onTouchMove:function(e){if(at){var t=this.options,o=t.fallbackTolerance,r=t.fallbackOffset,n=e.touches?e.touches[0]:e,a=qe&&Se(qe,!0),i=qe&&a&&a.a,l=qe&&a&&a.d,s=Et&>&&Ne(gt),d=(n.clientX-at.clientX+r.x)/(i||1)+(s?s[0]-wt[0]:0)/(i||1),u=(n.clientY-at.clientY+r.y)/(l||1)+(s?s[1]-wt[1]:0)/(l||1);if(!Mt.active&&!ft){if(o&&Math.max(Math.abs(n.clientX-this._lastX),Math.abs(n.clientY-this._lastY))r.right+n||e.clientX<=r.right&&e.clientY>r.bottom&&e.clientX>=r.left:e.clientX>r.right&&e.clientY>r.top||e.clientX<=r.right&&e.clientY>r.bottom+n}(e,n,this)&&!g.animated){if(g===Ue)return N(!1);if(g&&a===e.target&&(i=g),i&&(o=Re(i)),!1!==Ht($e,a,Ue,t,i,o,e,!!i))return I(),g&&g.nextSibling?a.insertBefore(Ue,g.nextSibling):a.appendChild(Ue),Le=a,O(),N(!0)}else if(g&&function(e,t,o){var r=Re(ke(o.el,0,o.options,!0)),n=10;return t?e.clientXu+d*a/2:sc-mt)return-ht}else if(s>u+d*(1-n)/2&&sc-d*a/2))return s>u+d/2?1:-1;return 0}(e,i,o,n,w?1:l.swapThreshold,null==l.invertedSwapThreshold?l.swapThreshold:l.invertedSwapThreshold,xt,pt===i),0!==v){var E=Ie(Ue);do{E-=v,y=Le.children[E]}while(y&&("none"===_e(y,"display")||y===qe))}if(0===v||y===i)return N(!1);pt=i,ht=v;var R=i.nextElementSibling,C=!1,k=Ht($e,a,Ue,t,i,o,e,C=1===v);if(!1!==k)return 1!==k&&-1!==k||(C=1===k),_t=!0,setTimeout(Bt,30),I(),C&&!R?a.appendChild(Ue):i.parentNode.insertBefore(Ue,C?R:i),S&&Me(S,0,D-S.scrollTop),Le=Ue.parentNode,void 0===b||xt||(mt=Math.abs(b-Re(i)[_])),O(),N(!0)}if(a.contains(Ue))return N(!1)}return!1}function T(l,s){Ye(l,h,te({evt:e,isOwner:u,axis:n?"vertical":"horizontal",revert:r,dragRect:t,targetRect:o,canSort:c,fromSortable:p,target:i,completed:N,onMove:function(o,r){return Ht($e,a,Ue,t,o,Re(o),e,r)},changed:O},s))}function I(){T("dragOverAnimationCapture"),h.captureAnimationState(),h!==p&&p.captureAnimationState()}function N(t){return T("dragOverCompleted",{insertion:t}),t&&(u?d._hideClone():d._showClone(h),h!==p&&(we(Ue,nt?nt.options.ghostClass:d.options.ghostClass,!1),we(Ue,l.ghostClass,!0)),nt!==h&&h!==Mt.active?nt=h:h===Mt.active&&nt&&(nt=null),p===h&&(h._ignoreWhileAnimating=i),h.animateAll((function(){T("dragOverAnimationComplete"),h._ignoreWhileAnimating=null})),h!==p&&(p.animateAll(),p._ignoreWhileAnimating=null)),(i===Ue&&!Ue.animated||i===a&&!i.animated)&&(pt=null),l.dragoverBubble||e.rootEl||i===document||(Ue.parentNode[Pe]._isOutsideThisEl(e.target),!t&&Wt(e)),!l.dragoverBubble&&e.stopPropagation&&e.stopPropagation(),m=!0}function O(){et=Ie(Ue),ot=Ie(Ue,l.draggable),Ge({sortable:h,name:"change",toEl:a,newIndex:et,newDraggableIndex:ot,originalEvent:e})}},_ignoreWhileAnimating:null,_offMoveEvents:function(){ge(document,"mousemove",this._onTouchMove),ge(document,"touchmove",this._onTouchMove),ge(document,"pointermove",this._onTouchMove),ge(document,"dragover",Wt),ge(document,"mousemove",Wt),ge(document,"touchmove",Wt)},_offUpEvents:function(){var e=this.el.ownerDocument;ge(e,"mouseup",this._onDrop),ge(e,"touchend",this._onDrop),ge(e,"pointerup",this._onDrop),ge(e,"touchcancel",this._onDrop),ge(document,"selectstart",this)},_onDrop:function(e){var t=this.el,o=this.options;et=Ie(Ue),ot=Ie(Ue,o.draggable),Ye("drop",this,{evt:e}),Le=Ue&&Ue.parentNode,et=Ie(Ue),ot=Ie(Ue,o.draggable),Mt.eventCanceled||(ft=!1,xt=!1,yt=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),Ft(this.cloneId),Ft(this._dragStartId),this.nativeDraggable&&(ge(document,"drop",this),ge(t,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),ue&&_e(document.body,"user-select",""),_e(Ue,"transform",""),e&&(ct&&(e.cancelable&&e.preventDefault(),!o.dropBubble&&e.stopPropagation()),qe&&qe.parentNode&&qe.parentNode.removeChild(qe),($e===Le||nt&&"clone"!==nt.lastPutMode)&&Je&&Je.parentNode&&Je.parentNode.removeChild(Je),Ue&&(this.nativeDraggable&&ge(Ue,"dragend",this),Pt(Ue),Ue.style["will-change"]="",ct&&!ft&&we(Ue,nt?nt.options.ghostClass:this.options.ghostClass,!1),we(Ue,this.options.chosenClass,!1),Ge({sortable:this,name:"unchoose",toEl:Le,newIndex:null,newDraggableIndex:null,originalEvent:e}),$e!==Le?(et>=0&&(Ge({rootEl:Le,name:"add",toEl:Le,fromEl:$e,originalEvent:e}),Ge({sortable:this,name:"remove",toEl:Le,originalEvent:e}),Ge({rootEl:Le,name:"sort",toEl:Le,fromEl:$e,originalEvent:e}),Ge({sortable:this,name:"sort",toEl:Le,originalEvent:e})),nt&&nt.save()):et!==Qe&&et>=0&&(Ge({sortable:this,name:"update",toEl:Le,originalEvent:e}),Ge({sortable:this,name:"sort",toEl:Le,originalEvent:e})),Mt.active&&(null!=et&&-1!==et||(et=Qe,ot=tt),Ge({sortable:this,name:"end",toEl:Le,originalEvent:e}),this.save())))),this._nulling()},_nulling:function(){Ye("nulling",this),$e=Ue=Le=qe=Ve=Je=Ke=Ze=at=it=ct=et=ot=Qe=tt=pt=ht=nt=rt=Mt.dragged=Mt.ghost=Mt.clone=Mt.active=null,St.forEach((function(e){e.checked=!0})),St.length=lt=st=0},handleEvent:function(e){switch(e.type){case"drop":case"dragend":this._onDrop(e);break;case"dragenter":case"dragover":Ue&&(this._onDragOver(e),function(e){e.dataTransfer&&(e.dataTransfer.dropEffect="move");e.cancelable&&e.preventDefault()}(e));break;case"selectstart":e.preventDefault()}},toArray:function(){for(var e,t=[],o=this.el.children,r=0,n=o.length,a=this.options;r-1&&e%1==0&&e<=9007199254740991}(e.length)&&!function(e){if(!fo(e))return!1;var t=po(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}(e)}function Eo(e,t,o){if(!fo(o))return!1;var r=typeof t;return!!("number"==r?Do(o)&&function(e,t){var o=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==o||"symbol"!=o&&So.test(e))&&e>-1&&e%1==0&&e"decorate"==r.mode?r:t.data));return E((()=>{if("decorate"==r.mode){var e=document.getElementById("componentList");const t=Mt.create(e,{group:"draggable-element",animation:200,onEnd:e=>{let o=r.value[e.oldIndex];r.value.splice(e.oldIndex,1),r.value.splice(e.newIndex,0,o),j((()=>{t.sort(Io(r.value.length).map((e=>e.toString()))),r.postMessage(e.newIndex,r.value[e.newIndex])}))}})}})),(e,o)=>{const n=i(l("diy-article"),L),v=i(l("diy-graphic-nav"),q),x=i(l("diy-horz-blank"),$),w=i(l("diy-image-ads"),V),_=i(l("diy-member-info"),K),D=i(l("diy-text"),J),E=i(l("diy-rubik-cube"),Z),R=i(l("diy-hot-area"),Q),C=S,k=i(l("tabbar"),F);return s(),d(C,{class:"diy-group",id:"componentList"},{default:u((()=>[(s(!0),c(p,null,h(f(a).value,((e,o)=>(s(),d(C,{key:e.id,onClick:t=>f(r).changeCurrentIndex(o,e),class:m(["draggable-element relative cursor-move",{selected:f(r).currentIndex==o,decorate:"decorate"==f(r).mode}]),style:g(e.pageStyle)},{default:u((()=>["Article"==e.componentName?(s(),d(n,{key:0,component:e,index:o,pullDownRefresh:t.pullDownRefresh},null,8,["component","index","pullDownRefresh"])):y("",!0),"GraphicNav"==e.componentName?(s(),d(v,{key:1,component:e,index:o,pullDownRefresh:t.pullDownRefresh},null,8,["component","index","pullDownRefresh"])):y("",!0),"HorzBlank"==e.componentName?(s(),d(x,{key:2,component:e,index:o,pullDownRefresh:t.pullDownRefresh},null,8,["component","index","pullDownRefresh"])):y("",!0),"ImageAds"==e.componentName?(s(),d(w,{key:3,component:e,index:o,pullDownRefresh:t.pullDownRefresh},null,8,["component","index","pullDownRefresh"])):y("",!0),"MemberInfo"==e.componentName?(s(),d(_,{key:4,component:e,index:o,pullDownRefresh:t.pullDownRefresh},null,8,["component","index","pullDownRefresh"])):y("",!0),"Text"==e.componentName?(s(),d(D,{key:5,component:e,index:o,pullDownRefresh:t.pullDownRefresh},null,8,["component","index","pullDownRefresh"])):y("",!0),"RubikCube"==e.componentName?(s(),d(E,{key:6,component:e,index:o,pullDownRefresh:t.pullDownRefresh},null,8,["component","index","pullDownRefresh"])):y("",!0),"HotArea"==e.componentName?(s(),d(R,{key:7,component:e,index:o,pullDownRefresh:t.pullDownRefresh},null,8,["component","index","pullDownRefresh"])):y("",!0)])),_:2},1032,["onClick","class","style"])))),128)),"decorate"!=f(r).mode&&f(a).global.bottomTabBarSwitch?(s(),c(p,{key:0},[b(C,{class:"pt-[20rpx]"}),b(k)],64)):y("",!0)])),_:1})}}}),[["__scopeId","data-v-26c6536e"]]),Oo=t({__name:"index",props:["data","pullDownRefresh"],setup(e){const t=e;return(e,o)=>{const r=i(l("diy-group"),No),n=S;return s(),d(n,null,{default:u((()=>[x(" 固定模板示例,我也可以装修 "),b(r,{data:t.data,pullDownRefresh:t.pullDownRefresh},null,8,["data","pullDownRefresh"])])),_:1})}}}),Wo=Y(t({__name:"index",props:["data","pullDownRefresh"],setup(e){const t=e;return(e,o)=>{const r=i(l("fixed-demo-index"),Oo),n=S;return s(),d(n,{class:"fixed-group"},{default:u((()=>["demo-index"==t.data.global.component?(s(),d(r,{key:0,data:t.data,pullDownRefresh:t.pullDownRefresh},null,8,["data","pullDownRefresh"])):y("",!0)])),_:1})}}}),[["__scopeId","data-v-3b1723ce"]]);export{No as _,Wo as a};