"use strict";exports.id=5633,exports.ids=[5633],exports.modules={45633:(e,t,a)=>{a.a(e,async(e,r)=>{try{a.d(t,{Z:()=>CartItemList});var s=a(20997),l=a(59003),d=a.n(l),i=a(86201),c=a(51449),n=a(5114),o=a(40393),x=a(11377),m=e([i,c,o]);function CartItemList({className:e}){let{t}=(0,x.useTranslation)("common"),{items:a,clearItemFromCart:r,verifiedResponse:l}=(0,c.jD)();return s.jsx("ul",{role:"list",className:d()("-my-6 w-full",e),children:a.map(e=>{let a=l?.unavailable_products?.find(t=>t===e.id);return(0,s.jsxs)("li",{className:"relative ml-4 flex border-b border-light-300 last-of-type:border-b-0 dark:border-dark-500 xs:ml-6",children:[s.jsx("button",{type:"button",className:"absolute -left-8 top-1/2 -mt-3.5 flex-shrink-0 p-2 font-medium text-dark-900 hover:text-dark dark:text-dark-800 dark:hover:text-light-900 xs:-left-10",onClick:()=>{var a;return a=e.id,void(r(a),i.default.success(s.jsx("b",{children:t("text-remove-item-from-cart-message")})))},children:s.jsx(n.T,{className:"h-3.5 w-3.5"})}),s.jsx(o.Z,{item:e,notAvailable:!!a})]},e.id)})})}[i,c,o]=m.then?(await m)():m,r()}catch(e){r(e)}})},40393:(e,t,a)=>{a.a(e,async(e,r)=>{try{a.d(t,{Z:()=>CartItem});var s=a(20997),l=a(79541),d=a(29620),i=a(77107),c=a(97514),n=a(18537),o=e([l]);function CartItem({item:e,notAvailable:t}){let{name:a,image:r,slug:o,price:x,shop:m,quantity:h}=e,{price:b}=(0,l.ZP)({amount:x});return(0,s.jsxs)("div",{className:"flex w-full items-start gap-4 py-3",children:[s.jsx("div",{className:"relative aspect-[5/3.4] w-28 flex-shrink-0 border border-light-300 bg-light-300 dark:border-0 dark:bg-dark-500 xs:w-32",children:s.jsx(d.Z,{alt:a,fill:!0,src:r??n.Z,className:"object-cover"})}),(0,s.jsxs)("div",{className:"w-[calc(100%-125px)] text-13px font-medium xs:w-[calc(100%-145px)] sm:w-[calc(100%-150px)]",children:[t&&s.jsx("span",{className:"mb-1 inline-block rounded-2xl text-xs font-semibold text-red-500",children:"Not Available"}),s.jsx("h3",{className:"truncate text-dark dark:text-light",children:s.jsx(i.Z,{href:c.Z.productUrl(o),className:"transition-colors hover:text-brand-dark",children:a})}),s.jsx("p",{className:"mt-1 mb-2.5",children:s.jsx(i.Z,{href:c.Z.shopUrl(m.slug),className:"text-light-base transition-colors hover:text-brand-dark dark:text-dark-base",children:m.name})}),(0,s.jsxs)("p",{className:"flex items-center gap-1",children:[s.jsx("span",{className:"rounded-2xl bg-light-300 p-1.5 font-semibold uppercase leading-none text-brand-dark dark:bg-dark-500",children:b}),(0,s.jsxs)("span",{className:"text-light-base dark:text-dark-base",children:["X ",h]})]})]})]})}l=(o.then?(await o)():o)[0],r()}catch(e){r(e)}})}};