PageSourceSearch

https://turn3creative.com/assets/product-EXnWcgpS.js

js turn3creative.com collected 2026-10-04 18:40:47 UTC 5,129 bytes, 6 lines download raw bytes

1import{r as i,j as e}from"./query-D0rYzImR.js";import{d as N,e as v,f as y,u as k,L as w,H as z,m as C,S}from"./index-CRrNbhgK.js";import{p as P}from"./shop-data-ifKljOdI.js";import{C as A}from"./check-pT59aTOz.js";import"./react-vendor-B9OdkcLT.js";import"./radix-ui-D0FPhtpi.js";/**
2 * @license lucide-react v0.454.0 - ISC
3 *
4 * This source code is licensed under the ISC license.
5 * See the LICENSE file in the root directory of this source tree.
6 */const $=N("ArrowLeft",[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]]);function T(){var l;const{id:x}=v(),p=y(),s=P.find(r=>r.id===x),[t,g]=i.useState(""),[n,u]=i.useState(0),[c,o]=i.useState(!1),[h,d]=i.useState(!1),{addItem:f,openCart:j}=k();if(!s)return e.jsx("main",{className:"bg-background text-foreground min-h-screen flex items-center justify-center",children:e.jsxs("div",{className:"text-center",children:[e.jsx("p",{className:"text-muted-foreground mb-4",children:"Product not found."}),e.jsx(w,{to:"/shop",className:"text-xs tracking-widest uppercase text-primary hover:underline",children:"Back to Shop"})]})});const b=()=>{var m;if(s.sizes.length>1&&!t){d(!0);return}const r=s.sizes.length===1?s.sizes[0]:t,a=(r?(m=s.sizePricing)==null?void 0:m[r]:void 0)??s.price;f({id:s.id,name:s.name,price:a,size:r,image:s.image}),o(!0),setTimeout(()=>o(!1),2e3),j()};return e.jsxs(e.Fragment,{children:[e.jsxs(z,{children:[e.jsxs("title",{children:[s.name," — turn3 Creative"]}),e.jsx("meta",{name:"description",content:s.description})]}),e.jsxs("main",{className:"bg-background text-foreground min-h-screen",children:[e.jsx("div",{className:"border-b border-border",children:e.jsx("div",{className:"container mx-auto px-6 lg:px-8 py-4",children:e.jsxs("button",{onClick:()=>p(-1),className:"flex items-center gap-2 text-xs font-medium tracking-widest uppercase text-muted-foreground hover:text-foreground transition-colors",children:[e.jsx($,{size:12})," Back"]})})}),e.jsx("div",{className:"container mx-auto px-6 lg:px-8 py-12 lg:py-20",children:e.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 gap-12 lg:gap-20",children:[e.jsxs("div",{className:"space-y-3",children:[e.jsx(C.div,{initial:{opacity:0}
6,animate:{opacity:1},transition:{duration:.3},className:"aspect-square bg-card overflow-hidden",style:{clipPath:"polygon(0 0, 100% 0, 100% 96%, 97% 100%, 0 100%)"},children:e.jsx("img",{src:s.images[n],alt:s.name,className:"w-full h-full object-cover"})},n),s.images.length>1&&e.jsx("div",{className:"flex gap-3",children:s.images.map((r,a)=>e.jsx("button",{onClick:()=>u(a),className:`w-16 h-16 overflow-hidden border-2 transition-colors ${n===a?"border-primary":"border-border hover:border-foreground/30"}`,children:e.jsx("img",{src:r,alt:"",className:"w-full h-full object-cover"})},a))})]}),e.jsxs("div",{className:"flex flex-col",children:[e.jsx("div",{className:"w-8 h-0.5 bg-primary mb-6"}),e.jsx("p",{className:"text-xs tracking-[0.3em] uppercase text-muted-foreground/60 mb-2",children:s.category}),e.jsx("h1",{className:"font-heading text-[clamp(2.5rem,5vw,4rem)] leading-none tracking-tight mb-4",style:{fontFamily:"var(--font-heading)"},children:s.name.toUpperCase()}),e.jsxs("p",{className:"text-2xl text-primary font-medium mb-6",children:[t&&((l=s.sizePricing)!=null&&l[t])?`$${s.sizePricing[t]}`:`$${s.price}`,s.sizePricing&&!t&&e.jsx("span",{className:"text-sm text-muted-foreground font-normal ml-2",children:"/ prices vary by size"})]}),e.jsx("p",{className:"text-muted-foreground leading-relaxed mb-8",children:s.description}),s.sizes.length>1&&e.jsxs("div",{className:"mb-6",children:[e.jsxs("div",{className:"flex justify-between items-center mb-3",children:[e.jsxs("p",{className:"text-xs font-medium tracking-widest uppercase",children:["Size ",t&&e.jsxs("span",{className:"text-primary",children:["— ",t]})]}),h&&e.jsx("p",{className:"text-xs text-primary",children:"Please select a size"})]}),e.jsx("div",{className:"flex flex-wrap gap-2",children:s.sizes.map(r=>e.jsx("button",{onClick:()=>{g(r),d(!1)},className:`px-4 py-2 text-xs font-medium tracking-widest uppercase border transition-colors ${t===r?"border-primary text-foreground bg-primary/10":"border-border text-muted-foreground hover:border-foreground
6/40 hover:text-foreground"}`,children:r},r))})]}),e.jsx("button",{onClick:b,className:`flex items-center justify-center gap-2 w-full py-4 text-xs font-medium tracking-widest uppercase transition-colors mb-4 ${c?"bg-green-700 text-white":"bg-primary text-primary-foreground hover:bg-primary/90"}`,children:c?e.jsxs(e.Fragment,{children:[e.jsx(A,{size:14})," Added to Cart"]}):e.jsxs(e.Fragment,{children:[e.jsx(S,{size:14})," Add to Cart"]})}),e.jsxs("div",{className:"mt-8 pt-8 border-t border-border",children:[e.jsx("p",{className:"text-xs font-medium tracking-widest uppercase mb-4",children:"Product Details"}),e.jsx("ul",{className:"space-y-2",children:s.details.map((r,a)=>e.jsxs("li",{className:"flex items-start gap-3 text-sm text-muted-foreground",children:[e.jsx("span",{className:"text-primary mt-1 shrink-0",children:"—"}),r]},a))})]})]})]})})]})]})}export{T 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.