1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["./C9EukanA.js","./1-qlIMh8.js","./yOJj5uNE.js"])))=>i.map(i=>d[i]); 2import{f as k,o as a,k as x,w as L,b as g,a as o,t as y,q as B,g as R,c,F as w,l as D,n as b,d as M,j as l,A as O,W as P,r as f,h as V,S as j,aq as q,C as F,_ as H}from"./yOJj5uNE.js";import{_ as I}from"./1AYDHkAm.js";import{_ as U}from"./SNJcfoqu.js";import{_ as W}from"./CYwy5q5M.js";import{_ as Y}from"./D6Y0ded2.js";import"./BZUBiNE_.js";import"./DlAUqK2U.js";const G={class:"w-full h-full absolute top-0 left-0 bg-cstm-dark-24 flex justify-end items-end hover:bg-cstm-dark-64 transition z-[2]"},J={class:"w-full text-white p-6 space-y-2"},K={class:"text-2xl"},Q={class:"text-md"},X=k({__name:"StoreItem",props:{item:{}},setup(v){return(e,s)=>{const i=U,r=W;return a(),x(r,{to:`/stores/${e.item.slug}`,class:"w-full h-[614px] relative overflow-hidden block"},{default:L(()=>{var n;return[g(i,{src:((n=e.item.image)==null?void 0:n.url)??"/placeholder.png",alt:e.item.name,sizes:"100vw sm:50vw lg:33vw",densities:"x1 x2",format:"webp",quality:"95",loading:"lazy",decoding:"async",class:"w-full h-full object-cover absolute top-0 left-0 z-[1]",style:{"object-position":"center"}},null,8,["src","alt"]),o("div",G,[o("div",J,[o("p",K,y(e.item.name),1),o("p",Q,y(e.item.subDescription),1)])])]}),_:1},8,["to"])}}}),Z={class:"py-8"},tt={class:"text-center text-h1 font-semibold"},et={class:"flex flex-col items-center"},st={class:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-3 lg:gap-4 w-full"},at={key:0,class:"col-span-full text-center text-gray-500"},ot=o("p",null,"No stores available.",-1),nt=[ot],rt={key:2,class:"col-span-full text-center text-red-500"},lt={class:"mt-8 pb-8"},ct=k({__name:"Store",props:{status:{},stores:{},data:{}},setup(v){B();const e=R();return(s,i)=>{var u;const r=I,n=X,p=Y;return a(),c("section",null,[o("div",Z,[o("h1",tt,y(s.data.content.section1_title),1)]),o("div",et,[o("div",st,[s.status==="pending"||s.status==="idle"?(a(),c(w,{key:0},D(4,t=>g(r,{key:t})),64)):s.status==="success"?(a(),c(w,{key:1},[((u=s.stores)==null?void 0:u.length)===0?(a(),c("div",at,nt)):(a(!0),c(w,{key:1},D(s.stores,t=>(a(),x(n,{key:t.id,item:t},null,8,["item"]))),128))],64)):s.status==="error"?(a(),c("div",rt," Error loading stores. Please try again later. ")):b("",!0)]),o("div",lt,[g(p,{onClick:i[0]||(i[0]=t=>l(e).push("/inquiries")),class:"py-4 px-8"},{default:L(()=>[M(" CONTACT STORE ")]),_:1})])])])}}}),it=F(()=>H(()=>import("./C9EukanA.js"),__vite__mapDeps([0,1,2]),import.meta.url).then(v=>v.default||v)),ut={key:0,class:"border-b border-black w-fit m-auto cursor-pointer"},gt=k({__name:"index",async setup(v){let e,s;const{$api:i}=B(),{data:r}=([e,s]=O(()=>i.cms.getStorePage()),e=await e,s(),e);P({title:r.value.data.title,description:r.value.data.description,image:r.value.data.og_image_path});const n=f(1),p=f([]),u=f(null),t=f(!1),N=f(null),$=f(""),S=async()=>{const{data:_,execute:d,status:m}=q(async()=>await i.branch.getBranches({page:n.value}),{immediate:!1},"$3okRRdiexw");return await d(),{branches:_,branchStatus:m}},C=async()=>{var d;if(t.value)return;if(t.value=!0,n.value++,n.value>u.value){t.value=!1;return}const{branches:_}=await S();p.value=[...p.value,...((d=_.value)==null?void 0:d.data)||[]],t.value=!1},T=async()=>{var m,h,E;const{branches:_,branchStatus:d}=await S();p.value=((m=_.value)==null?void 0:m.data)||[],u.value=(E=(h=_.value)==null?void 0:h.meta)==null?void 0:E.last_page,$.value=d.value},A=()=>{z()&&!t.value&&n.value<u.value&&C()},z=()=>window.innerHeight+window.scrollY>=document.documentElement.scrollHeight-100;return V(async()=>{T(),window.addEventListener("scroll",A)}),j(()=>{window.removeEventListener("scroll",A)}),(_,d)=>{const m=ct,h=it;return a(),c("section",null,[g(m,{stores:l(p),status:l($),data:l(r).data},null,8,["stores","status","data"]),o("div",{onClick:C,ref_key:"loadMoreTrigger",ref:N,class:"py-16"}
2,[l(n)<l(u)?(a(),c("p",ut,y(l(t)?"Loading...":"LOAD MORE"),1)):b("",!0)],512),l(t)?(a(),x(h,{key:0})):b("",!0)])}}});export{gt as default};
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.