PageSourceSearch

https://sock-shop-spark.lovable.app/assets/_app.show-ByD2Wv4U.js

js sock-shop-spark.lovable.app collected 2026-10-03 03:45:43 UTC 2,912 bytes, 1 lines download raw bytes

1import{r as t,a as i,j as e,L as l,y as d}from"./index-Bratghjx.js";import{B as o}from"./button-W8DTlMrk.js";import{P as c}from"./ProductImage-Dbe2g-Xk.js";import{A as m}from"./arrow-left-1kdsW6vx.js";import{L as x}from"./loader-circle-BlACLt8x.js";import"./utils-BQHNewu7.js";const u=a=>Math.round(Number(a??0)).toLocaleString("sv-SE");function w(){const[a,n]=t.useState(null);return t.useEffect(()=>{let s=!0;return(async()=>{const r=await i.catalog().catch(()=>null);s&&n(r?.products??[])})(),()=>{s=!1}},[]),e.jsxs("div",{className:"fixed inset-0 z-50 flex flex-col bg-background animate-[fade-in_0.3s_ease-out]",children:[e.jsx("header",{className:"border-b border-border/60 bg-primary px-4 py-4 text-primary-foreground sm:px-6",children:e.jsxs("div",{className:"mx-auto flex max-w-2xl items-center justify-between gap-3",children:[e.jsx(l,{to:"/new-order",children:e.jsxs(o,{variant:"ghost",size:"sm",className:"rounded-full text-primary-foreground hover:bg-white/15 hover:text-primary-foreground",children:[e.jsx(m,{className:"mr-1.5 h-4 w-4"}),"Klar"]})}),e.jsxs("div",{className:"text-center",children:[e.jsx("p",{className:"text-sm font-black uppercase tracking-wider sm:text-base",children:"📱 Visa mobilen för kunden"}),e.jsx("p",{className:"text-xs text-primary-foreground/85",children:"Låt kunden bläddra och välja"})]}),e.jsx("div",{className:"w-[68px]","aria-hidden":!0})]})}),e.jsx("main",{className:"flex-1 overflow-y-auto px-4 py-5 sm:px-6",children:e.jsxs("div",{className:"mx-auto max-w-2xl space-y-5",children:[a?a.map(s=>e.jsxs("article",{className:"rounded-3xl bg-card p-5 shadow-[var(--shadow-card)] sm:p-6",children:[e.jsx(c,{src:s.image,alt:s.name,className:"mx-auto aspect-square w-full max-w-xs"}),e.jsxs("div",{className:"mt-4 text-center",children:[e.jsx("h2",{className:"text-xl font-black text-foreground sm:text-2xl",children:s.name}),e.jsxs("p",{className:"mt-3 text-3xl font-black text-primary",children:[u(s.rows?.[0]?.price)," kr"]})]}),(s.rows?.length??0)>1&&e.jsxs("div",{className:"mt-5 border-t border-border/60 pt-4",children:[e.jsx("p",{className:"mb-2 text-[10px] font-bold uppercase tracking-wider text-muted-foreground",children:"Storlek"}),e.jsx("div",{className:"flex flex-wrap gap-2",children:s.rows.map(r=>e.jsx("span",{className:`inline-flex items-center rounded-full px-3 py-1.5 text-sm font-semibold ${r.in_stock?"bg-muted text-foreground":"bg-muted/50 text-muted-foreground line-through"}`,children:r.label||"Standard"},r.id))})]})]},s.id)):e.jsx("div",{className:"flex justify-center py-16",children:e.jsx(x,{className:"h-6 w-6 animate-spin text-primary"})}),e.jsx("div",{className:"pt-2 pb-6 text-center",children:e.jsx(l,{to:"/new-order",children:e.jsxs(o,{size:"lg",className:"rounded-full px-8 shadow-[var(--shadow-glow)]",children:[e.jsx(d,{className:"mr-2 h-5 w-5"}),"Klar – tillbaka till beställning"]})})})]})})]})}export{w 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.