1 |
- import{d as U,r as l,w as $,o as t,A as x,B as g,c as r,F as m,P as v,a as s,C as w,aE as c,aa as z,D as b,E as d}from"./index-b9299550.js";import{E as A,a as B}from"./el-carousel-item-101ab0da.js";import{E as D}from"./el-image-92ea5aa4.js";import"./el-image-viewer-498779d9.js";const F={class:"flex flex-row flex-wrap"},H=U({name:"MenuSwiper",__name:"index",props:{property:{}},setup(k){const a=k,p=l([]),y=l(0),i=l(0),h=l("");return $(()=>a.property,()=>{h.value=1/a.property.column*100+"%",i.value=32+(a.property.layout==="iconText"?62:42),y.value=a.property.row*i.value;const n=a.property.row*a.property.column;p.value=[];let o=[];for(const u of a.property.list)o.length===n&&(o=[]),o.length===0&&p.value.push(o),o.push(u)},{immediate:!0,deep:!0}),(n,o)=>{const u=D,C=A,E=B;return t(),x(E,{height:`${s(y)}px`,autoplay:!1,arrow:"hover","indicator-position":"outside"},{default:g(()=>[(t(!0),r(m,null,v(s(p),(_,j)=>(t(),x(C,{key:j},{default:g(()=>[w("div",F,[(t(!0),r(m,null,v(_,(e,T)=>{var f;return t(),r("div",{key:T,class:"relative flex flex-col items-center justify-center",style:c({width:s(h),height:`${s(i)}px`})},[w("div",{class:z(["relative","h-42px w-42px"])},[(f=e.badge)!=null&&f.show?(t(),r("span",{key:0,class:"absolute right--10px top--10px z-1 h-20px rounded-10px p-x-6px text-center text-12px leading-20px",style:c({color:e.badge.textColor,backgroundColor:e.badge.bgColor})},b(e.badge.text),5)):d("",!0),e.iconUrl?(t(),x(u,{key:1,src:e.iconUrl,class:"h-full w-full"},null,8,["src"])):d("",!0)],2),n.property.layout==="iconText"?(t(),r("span",{key:0,class:"text-12px",style:c({color:e.titleColor,height:"20px",lineHeight:"20px"})},b(e.title),5)):d("",!0)],4)}),128))])]),_:2},1024))),128))]),_:1},8,["height"])}}});export{H as default};
|