import{G as p,r as s,k as g,j as e,d as x,e as h,E as u,F as d,f,l as j,m as y,b as E}from"./index-BTeXlNCi.js";import{I as S,a as w}from"./ImageListItem-BIQLLH7Z.js";const i=[];for(let t=1;t<31;t++)i.push({img:`/memories/${t}.webp`});const I=t=>{const a=t.split("/");return a[a.length-1].split(".")[0]};function v(){const{screen:t}=p,[a,n]=s.useState({col:0,height:{}});return s.useEffect(()=>{n(r=>({...r,col:t>1200?4:t>900?3:(t>600,2)}))},[t]),s.useLayoutEffect(()=>{n(r=>({...r,height:g(30,400,500)}))},[]),e.jsxs(e.Fragment,{children:[e.jsx(x,{}),e.jsxs(h,{mask:!0,children:[e.jsx(u,{p:"clamp(3rem, 3vw + 1rem, 3rem) clamp(3rem, 3vw + 1rem, 3rem)",children:e.jsx(d,{text:"Gallery"})}),e.jsx(f,{sx:{width:"100%",height:"100%"},children:e.jsx(S,{variant:"masonry",cols:a.col,gap:8,style:{padding:"8px"},children:i.map((r,l)=>e.jsx(w,{sx:{img:{transition:"all 200ms",borderRadius:"8px","&:hover":{cursor:"pointer",boxShadow:"0 0 10px #999"}}},children:e.jsx("img",{src:j(r.img),style:{height:`${a.height[l]}px`},alt:"",loading:"lazy",onClick:o=>{window.setChildren(e.jsx(y,{initialSlide:I(o.currentTarget.currentSrc)-1,loop:!0,navigation:!0,effect:"fade",data:i.map((m,c)=>({id:c,el:e.jsx(E,{path:m.img,fit:"cover",style:{aspectRatio:16/9}})}))}))}})},r.img))})})]})]})}v.propTypes={};export{v as default};