1import{j as e}from"./CheveronLeft-BLchON5X.js";import"./useCartUpsells-oN76HI6E.js";import{u as d}from"./CartContext-CPmp6VK2.js";import{c as x}from"./tenderCoupon-B4fpH8v8.js";import{f as a}from"./price-3VXvV4Xr.js";import"./index-kA4PVysc.js";import"./ShopifyCart-LdCOHsRZ.js";import"./tenderCoupons-ClMQo-uT.js";import"./events-Dm1k7AS7.js";const N=({product:t})=>{const{addItem:r}=d();if(!t)return null;const{title:l,price:m,featured_image:i,variants:o}=t,n=o?.[0],c=i?.startsWith("//")?`https:${i}`:i,s=x(t);return e.jsxs("div",{className:"flex flex-1 gap-4 bg-white shadow-sm rounded-3xl max-w-[21.25rem] p-4",children:[e.jsx("div",{className:"self-start flex-shrink-0 w-20 h-auto",children:e.jsx("img",{loading:"lazy",src:c,alt:l,className:"object-cover w-full h-full rounded"})}),e.jsxs("div",{className:"flex flex-col items-start justify-start flex-grow gap-3",children:[e.jsxs("div",{className:"flex flex-col items-start justify-between gap-2",children:[e.jsx("h2",{className:"heading-2xs",children:l}),e.jsxs("div",{className:"flex flex-wrap items-baseline gap-x-2 gap-y-1",children:[e.jsx("span",{className:s.eligible?"font-bold text-black body-xs":"text-black body-xs",children:a(s.discountedPrice)}),s.eligible&&e.jsx("span",{className:"text-xs leading-none line-through text-black/55",children:a(s.price)})]}),s.eligible&&e.jsxs("div",{className:"inline-flex max-w-full items-center gap-1.5 rounded-full bg-discount-green px-2 py-1 text-xs font-semibold leading-tight text-discount-green-text ring-1 ring-inset ring-discount-green-text/15","data-tender-coupon-cart-upsell":!0,"data-discount-percentage":s.discountPercentage,children:[e.jsx("svg",{viewBox:"0 0 20 20",fill:"currentColor","aria-hidden":"true",className:"h-3.5 w-3.5 flex-shrink-0 -scale-x-100 text-discount-green-icon",children:e.jsx("path",{fillRule:"evenodd",clipRule:"evenodd",d:"M5.5 3A2.5 2.5 0 003 5.5v2.879a2.5 2.5 0 00.732 1.767l6.5 6.5a2.5 2.5 0 003.536 0l2.878-2.878a2.5 2.5 0 000-3.536l-6.5-6.5A2.5 2.5 0 008.38 3H5.5zM6 7a1 1 0 100-2 1 1 0 000 2z"})}),e.jsxs("span",{className:"min-w-0 break-words",children:[s.badgeText," applied",e.jsx("span",{"aria-hidden":"true",children:" · "}),"Save ",a(s.discountAmount)]})]})]}),n&&e.jsx("button",{className:"button button--xs button-fungi",onClick:()=>r(n.id,1),children:"ADD TO CART"})]})]})};export{N as U};
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.