1const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/storefront-images-_RL5xK_z.js","assets/locations-BCxxQUzH.js"])))=>i.map(i=>d[i]); 2import{j as t,r,_ as w,L as n}from"./index-CCiyeWVF.js";import{A as b,R as y,u as v}from"./auth-nwr103q_.js";import{l as P,g as c}from"./storefront-client-C41UqI-v.js";import{S as N}from"./SiteRenderer-2fDJJT-Z.js";import{L as A}from"./loader-circle-B85m_KdK.js";import{A as _}from"./arrow-left-C8wNoRQl.js";import"./storefront-modules-BZHrw8Pm.js";import"./locations-BCxxQUzH.js";import"./index-B2LDWpgW.js";import"./index-BkiJF8sS.js";import"./index-BlwC_Pwl.js";import"./shopping-bag-DokMpSta.js";import"./createLucideIcon-DZ4pSLkU.js";import"./x-gDeTq97A.js";import"./check-Ds7kP9gv.js";import"./minus-Bac_7dp6.js";import"./plus-Cp8mjSv6.js";import"./trash-2-BhOpXc4F.js";import"./send-L5IdykCM.js";import"./map-pin-Ok0jmNp5.js";import"./arrow-right-C2VW-Oux.js";function L(){const{user:s}=v(),[m,l]=r.useState(!0),[o,d]=r.useState(""),[p,u]=r.useState({}),[x,f]=r.useState({});return r.useEffect(()=>{s&&(async()=>{try{const a=(await P(s.id))?.data??{};u(a);const i={},{collectImagePaths:h}=await w(async()=>{const{collectImagePaths:e}=await import("./storefront-images-_RL5xK_z.js");return{collectImagePaths:e}},__vite__mapDeps([0,1])),{fieldKeys:j,productPaths:g}=h(a);await Promise.all([...j.map(async e=>{i[e]=await c(a[e])}),...g.map(async e=>{i[e]=await c(e)})]),f(i)}catch{d("We couldn't load your saved preview. Return to the studio and try again.")}finally{l(!1)}})()},[s]),o?t.jsxs("main",{className:"sb-loading",children:[t.jsx("p",{role:"alert",children:o}),t.jsx(n,{to:"/storefront-builder",className:"sb-button",children:"Back to studio"})]}):m?t.jsx("main",{className:"flex min-h-screen items-center justify-center bg-cream",children:t.jsx(A,{className:"h-6 w-6 animate-spin text-crust"})}):t.jsxs(t.Fragment,{children:[t.jsx("div",{className:"sticky top-0 z-50 border-b border-wheat bg-cream/95 px-4 py-2 text-sm",children:t.jsxs("div",{className:"mx-auto flex max-w-4xl items-center justify-between",children:[t.jsxs(n,{to:"/storefront-builder",className:"inline-flex items-center gap-1 font-semibold text-crust hover:underline",children:[t.jsx(_,{className:"h-4 w-4"})," Back to builder"]}),t.jsx("span",{className:"text-charcoal/70",children:"Private draft preview"})]})}),t.jsx(N,{data:p,imageUrls:x})]})}const X=()=>t.jsx(b,{children:t.jsx(y,{children:t.jsx(L,{})})});export{X as component};
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.