1"use strict";(globalThis.webpackChunk_swo_frontend=globalThis.webpackChunk_swo_frontend||[]).push([[8492],{38492:(e,a,t)=>{t.r(a),t.d(a,{CartComponent:()=>he});var l=t(21126),n=t(35103),i=t(36820),r=t(25089),s=t(41797),c=t(44167),o=t(19963),d=t(94751),u=t(81500),h=t(73701),m=t(98309),p=t(56225),g=t(65438),b=t(33818),f=t(22494),v=t(38004),x=t(18127);const Y=({children:e})=>(0,x.Y)("div",{children:(0,x.Y)("h1",{className:"uppercase md:mb-smd text-heading-2 text-black font-futura-500 mt-0",children:e})}),C=({left:e,right:a,...t})=>(0,x.FD)(x.FK,{children:[(0,x.FD)("div",{className:"grid lg:grid-cols-2 min-h-[50vh] max-lg:gap-6",children:[(0,x.FD)("div",{"data-testid":"cart-page-grid-left",className:"lg:pr-md",children:[(0,x.Y)(Y,{children:(0,x.Y)(n.T,{children:t.translations.cart})}),e]}),(0,x.Y)("div",{"data-testid":"cart-page-grid-right",className:"lg:mr-[10%]",children:a})]}),(0,x.Y)(v.o,{contactData:t.contactData,headline:void 0,chatbotEnabled:t.locale.chatbotEnabled})]});var y=t(59809),k=t(35539),N=t(26645),T=t(74931),D=t(85400),P=t(80449),F=t(7970),w=t(25394);const I=({bundleElements:e})=>{const a=(0,F.P)()("noImage");return(0,x.Y)("ul",{className:"bg-white",children:e.map((e,t)=>(0,x.FD)("li",{className:"flex items-stretch pl-[92px] md:pl-[112px]",children:[(0,x.Y)("div",{"aria-hidden":"true",className:"w-[2px] shrink-0 self-stretch bg-green"}),(0,x.Y)(w.E,{As:"span",to:e.extendedInfo.link,className:"size-[48px] shrink-0 flex items-center justify-center bg-green-white [&_img]:size-full [&_img]:object-contain",children:e.extendedInfo.image?(0,x.Y)(D.i,{contentfulUrl:e.extendedInfo.image.url,assetId:e.extendedInfo.image.id,cropping:void 0,sizes:"48px"}):(0,x.Y)("span",{className:"text-gray-dark-2024 [&_svg]:size-6",children:(0,x.Y)(T.Pi,{strokeWidth:3,"aria-label":a.value})})}),(0,x.FD)("div",{className:"min-w-0 flex items-center justify-center gap-4 px-4 py-2",children:[(0,x.Y)(w.E,{As:"span",to:e.extendedInfo.link,className:"no-underline hover:underline u-color-inherit",children:(0,x.Y)("span",{className:"font-futura-300 text-black text-body-small",children:e.name})}),e.variant.uniqueAttributes.length>0&&(0,x.Y)(P.V,{attributes:e.variant.uniqueAttributes.map(e=>({label:e.value.label,type:"color"===e.value.type?"color":"plain",customValue:e.value.customValue})),size:"small",noMargin:!0,direction:"row"})]})]},`${e.name}-${t}`))})};var A=t(53446),V=t.n(A),L=t(1561),M=t(65675);const S=({quantity:e,onIncrease:a,onDecrease:t,onRemove:n,controlsDisabled:i=!1,removable:r=!0,itemName:s})=>{const[c,o]=(0,l.useTransition)(),[d,u]=(0,l.useState)(null),h=(e,a)=>()=>{a&&(u(e),o(async()=>{try{await a()}finally{u(null)}}))},m=c,g="inline-flex items-center justify-center size-[24px] p-0 border-none bg-transparent cursor-pointer text-green-dark enabled:hover:opacity-70 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-green-dark disabled:text-grey-5 disabled:cursor-not-allowed",b="increase"===d||"decrease"===d;return(0,x.FD)("div",{className:"flex items-center gap-[12px]",children:[(0,x.FD)("div",{role:"group","aria-label":`Quantity for ${s}`,className:V()("flex items-center gap-[8px] h-[48px] w-[132px] p-[12px] bg-gray-light-2024",i&&"hidden"),children:[(0,x.Y)("button",{type:"button","aria-label":`Decrease quantity of ${s}`,className:g,disabled:!t||m,onClick:h("decrease",t),children:(0,x.Y)(L.h,{"aria-hidden":"true",className:"size-[24px]"})}),(0,x.FD)("span",{className:"relative flex-1 text-center font-futura-500 text-[21px] leading-[16px] tracking-[1.05px] text-black",children:[(0,x.Y)("span",{"aria-live":"polite","aria-label":`Quantity: ${e}`,className:V()(b&&"invisible"),children:e}),b&&(0,x.Y)("span",{className:"absolute inset-0 flex items-center justify-center",children:(0,x.Y)(p.NG,{size:"1x",color:"green",noMargin:!0})})]}),(0,x.Y)("button",{type:"button","aria-label":`Increase quantity of ${s}`,className:g,disabled:!a||m,onClick:h("increase",a),children:(0,x.Y)(M.h,{"aria-hidden":"true",className:"size-[24px]"})})]}),(0,x.Y)("button",{type:"button","aria-label":`Remove ${s} from cart`,"aria-busy":"remove"===d,className:V()("inline-flex items-center justify-center size-[46px] rounded-full p-0 border-none bg-transparent cursor-pointer text-black","enabled:hover:opacity-70 focus-visible:outline focus-visible:outline-2 focus-visible:outline-offset-2 focus-visible:outline-green-dark","disabled:text-grey-5 disabled:cursor-not-allowed","mr-4"),disabled:!r||m,onClick:h("remove",n),children:"remove"===d?(0,x.Y)(p.NG,{size:"1x",color:"green",noMargin:!0}):(0,x.Y)(T.NQ,{"aria-hidden":"true",className:"size-[20px]"})})]})};var z=t(45181);const _=({translations:e})=>{const{checkout:{dispatch:a},cart:t}
1=(0,y.V)(),l=(e,l)=>a({tag:"change-line-item-amount",cart:t,lineItem:e,change:l});return(0,x.Y)(x.FK,{children:(0,x.Y)("ul",{className:"flex flex-col gap-3 mt-4","data-testid":"cart-line-items-table",children:(0,N.IU)(t).map(n=>{const{line:i}=n,r=(0,z.J)(i.data.availability),s=i.quantity<99&&"number"===typeof r&&r>i.quantity;return(0,x.Y)(k.$,{product:i,extracted:n.extracted,shopT:e,background:"white",BottomElement:"bundle"===i.data.tag?(0,x.Y)(I,{bundleElements:i.data.bundleElements}):void 0,children:(0,x.Y)(S,{quantity:i.quantity,itemName:i.name,controlsDisabled:i.cannotBeRemoved,removable:!i.cannotBeRemoved,onDecrease:i.quantity<=1?void 0:()=>l(i,"-1"),onIncrease:s?()=>l(i,"+1"):void 0,onRemove:()=>(e=>a({tag:"remove-line-item-from-cart",cart:t,lineItems:[e]}))(i)})},i.id)})})})};var q=t(50088),j=t(43456),K=t(72314);const E=e=>(0,x.Y)("svg",{viewBox:"0 0 129 152",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e,children:(0,x.Y)("path",{d:"M27.3 14.7C27.3 8.92499 22.575 4.19999 16.8 4.19999C10.7625 4.19999 6.3 8.92499 6.3 14.7C6.3 20.475 10.7625 25.2 16.8 25.2C22.575 25.2 27.3 20.475 27.3 14.7ZM2.1 14.7C2.1 6.56249 8.6625 -8.58307e-06 16.8 -8.58307e-06C24.675 -8.58307e-06 31.5 6.56249 31.5 14.7C31.5 22.8375 24.675 29.4 16.8 29.4C8.6625 29.4 2.1 22.8375 2.1 14.7ZM-4.55976e-06 53.2875C-4.55976e-06 44.8875 6.825 37.8 15.4875 37.8C21.525 37.8 27.3 40.6875 30.975 45.675L43.575 63.7875C45.15 65.8875 47.775 67.2 50.4 67.2H58.8C60.1125 67.2 61.6875 67.725 63 68.25V50.4C63 49.35 63.7875 48.3 65.1 48.3C66.15 48.3 67.2 49.35 67.2 50.4V130.2C72.1875 130.2 76.3875 133.875 77.4375 138.6H126C127.05 138.6 128.1 139.65 128.1 140.7C128.1 141.75 127.05 142.8 126 142.8H77.4375C76.3875 147.525 72.1875 151.2 67.2 151.2C61.1625 151.2 56.7 146.475 56.7 140.7C56.7 136.5 59.0625 132.825 63 130.988V82.95C61.687
15 83.475 60.1125 84 58.8 84H50.4C42.2625 84 34.65 80.0625 29.925 73.5L29.4 72.45V95.2875L37.275 102.112C42.7875 106.837 46.2 113.925 46.2 121.275V142.8C46.2 147.525 42.2625 151.2 37.8 151.2C33.075 151.2 29.4 147.525 29.4 142.8V121.275C29.4 118.65 28.0875 116.287 26.25 114.712L8.6625 99.75C3.15 94.7625 -4.55976e-06 87.9375 -4.55976e-06 80.5875V53.2875ZM63 75.6C62.7375 73.2375 60.9 71.4 58.8 71.4H50.4C46.4625 71.4 42.525 69.5625 40.1625 66.15L27.5625 48.3C24.675 44.3625 20.2125 42 15.4875 42C9.1875 42 4.2 46.9875 4.2 53.2875V80.5875C4.2 86.625 6.825 92.4 11.2875 96.3375L29.1375 111.562C31.7625 113.925 33.6 117.337 33.6 121.012V142.8C33.6 145.163 35.4375 147 37.8 147C39.9 147 42 145.163 42 142.8V121.012C42 114.975 39.1125 109.2 34.65 105.262L25.725 97.65C25.4625 97.3875 25.2 96.8625 25.2 96.075V65.8875C25.2 64.8375 25.725 64.05 26.5125 63.7875C27.5625 63.525 28.35 63.7875 28.875 64.575L33.3375 71.1375C37.275 76.65 43.8375 79.8 50.6625 79.8H58.8C60.9 79.8 63 77.9625 63 75.6ZM-4.55976e-06 105.787C0.524995 106.312 1.05 107.1 1.8375 107.625L4.2 109.462V142.8C4.2 145.163 6.0375 147 8.4 147C10.5 147 12.6 145.163 12.6 142.8V116.812L16.8 120.225V142.8C16.8 147.525 12.8625 151.2 8.4 151.2C3.675 151.2 -4.55976e-06 147.525 -4.55976e-06 142.8V105.787ZM73.5 140.7C73.5 137.288 70.6125 134.4 67.2 134.4C63.525 134.4 60.9 137.288 60.9 140.7C60.9 144.113 63.525 147 67.2 147C70.6125 147 73.5 144.113 73.5 140.7Z",fill:"currentColor"})});var B=t(59445);const R=e=>(0,x.FD)("div",{className:V()("flex justify-center flex-col max-md:mt-md","expand"),children:[e.Icon?(0,x.Y)("div",{className:"flex justify-center items-center mt-6",children:e.Icon}):null,(0,x.Y)("div",{className:"mt-8 [&_>_*:first-child]:mt-0",children:e.richText}),e.link&&(0,x.Y)("div",{className:"flex mt-10 md:mt-md justify-center",children:(0,x.Y)(B.i,{variant:"outline",as:"a",isInternal:!0,link:e.link.href,children:e.link.label})})]}),H=({t:e,links:a})=>(0,x.Y)(x.FK,{children:(0,x.Y)(R,{Icon:(0,x.Y)(E,{className:"size-32 lg:size-40"}),richText:(0,x.Y)(x.FK,{children:(0,x.Y)("p",{className:V()("font-futura-300 text-body-subheading","mt-4"),children:(0,x.Y)(n.T,{children:e("yourCartIsEmpty")})})}),link:a.allProducts})});var $=t(50114),Z=t(92236),W=t(59970);const Q=({informationSetDeliveryData:e,variant:a})=>(0,x.Y)("div",{"data-testid":"cart-information-set-delivery-data",className:V()("no-border"===a?"":"border-t border-solid border-t-grey-5","no-border"===a?"":"border-b border-solid border-b-grey-5","pt-md pb-md "),children:(0,x.Y)("div",{className:V()("grid",e.length>=4?"gap-4 xl:gap-6 grid-cols-2 sm:grid-cols-4":"gap-4 xl:gap-6 grid-cols-3 sm:grid-cols-3","w-full lg:max-w-[36em]","mx-auto"),children:e.map(({IconComponent:e,label:a})=>(0,x.Y)(W._,{IconComponent:e,label:a},a.key))})});var X=t(45924);const O=({canCheckout:e,linkToCheckout:a,t:t})=>{const l="w-full h-full flex! grow justify-center items-center";return(0,x.FD)("div",{className:"flex max-md:flex-wrap",children:[false,(0,x.Y)("span",{className:"w-full",children:e?(0,x.Y)(B.i,{variant:"green",as:"a",link:a,isInternal:!0,scrollToTop:!0,className:V()(X.mF.checkout.pageLink,l),children:(0,x.Y)(n.T,{children:t("checkout.goToCheckout")})}):(0,x.Y)(B.i,{variant:"green",as:"button",disabled:!0,className:l,children:(0,x.Y)(n.T,{children:t("checkout.goToCheckout")})})})]})},U=({before:e,after:a,linkToCheckout:t,t:l,canCheckout:n})=>(0,x.Y)("div",{children:(0,x.Y)("div",{className:"mt-5 w-full lg:mb-0",children:(0,x.FD)("div",{className:"mb-5 js-cart-summary--shipping",children:[e,(0,x.Y)(O,{linkToCheckout:t,t:l,canCheckout:n}),a]})})});var G=t(46404),J=t(68622),ee=t(86794);const ae=({totalPrice:e,t:a,cartDiscount:t})=>(0,x.FD)("div",{className:"flex flex-col gap-3 items-end",children:[(null===t||void 0===t?void 0:t.hasBundleDiscount)&&(0,x.Y)(ee.Y,{translations:a,theme:"cool-mint"}),(0,x.Y)("span",{className:"font-futura-500 text-green-dark text-heading-3 uppercase",children:(0,x.Y)(G.A,{preDiscountPrice:e.value.preDiscountPrice,currentPrice:e.value.currentPrice})})]}),te=({locale:e,translations:a,cart:t})=>{const{cart:l,checkout:{computed:i}}=(0,y.V)(),r=i.cartCosts,{shippingCostProps:s,cartTotalPriceWithEstimatedShippingCost:c,isPriceIncludingTaxes:o,cartTaxPortions:d}=r,u="excludingTaxes"===o,h=(0,J.WJ)(e,a)[u?"priceExcluding":"priceIncluding"],m=a("vat"===(0,J.q8)(e)?"summary.vatHeadline":"summary.taxesHeadline");return(0,x.FD)("div",{className:"flex flex-col gap-2 pt-2 pb-4",children:[(0,x.Y)("div",{className:"flex items-center h-12",children:(0,x.FD)("span",{className:"font-futura-500 text-black text-body-small",children:[(0,x.Y)(n.T,{children:c.label}),(0,x.FD)("span",{className:"font-futura-300 text-[0.875em]",children:[" ","(",(0,x.Y)(n.T,{children:h}),")"]})]})}),(0,x.FD)("div",{className:"flex flex-col gap-1.5 font-futura-300 text-body-small text-black",children:[(0,x.Y)(le,{label:(0,x.Y)(n.T,{children:a("summary.cartSubtotalPrice")}),children:(0,X.l7)(e)(l.totalPrice)}),s&&(0,x.Y)(le,{classNameValue:"uppercase",label:(0,x.Y)(n.T,{children:s.shippingMethod}),children:(0,x.Y)(G.y,{discounted:s.priceLabel.discountedPrice,regular:s.priceLabel.regularPrice})}),u?(0,x.Y)(le,{label:(0,x.Y)(le,{label:(0,x.Y)(n.T,{children:m}),children:(0,x.Y)(n.T,{children:a("summary.willBeCalculatedInNextStep")})})}):d.map(e=>(0,x.Y)(le,{label:e.label,children:e.valueLabel},e.label))]}),(0,x.Y)("hr",{className:"h-px w-full bg-green"}),(0,x.Y)(ae,{totalPrice:c,t:a,cartDiscount:t.cartDiscount})]})},le=({label:e,children:a,classNameValue:t})=>(0,x.FD)("div",{className:"flex items-center justify-between gap-4 break-words",children:[(0,x.Y)("span",{className:"min-w-0 flex-1",children:e}),null!=a&&(0,x.Y)("span",{className:V()("text-right whitespace-nowrap",t),children:a})]});var ne=t(38330);const ie=({translations:e,linkToCheckout:a,cart:t,locale:l})=>{var n;const i=null!==(n=null===t||void 0===t?void 0:t.areAllCartLineItemsCheckoutable)&&void 0!==n&&n;return(0,x.Y)(U,{linkToCheckout:a,t:e,canCheckout:i,before:t?(0,x.Y)(te,{c
1art:t,locale:l,translations:e}):null,after:(0,x.Y)("div",{className:"pt-6",children:(0,x.Y)(ne.K,{paymentMethodIcons:t?t.cartPaymentMethods.map(e=>({key:e.tag})):l.availablePaymentMethods,locale:l})})})},re=({loadedCart:e,locale:a,t:t,linkToCheckout:l,informationSetDeliveryData:i,relatedProducts:r,relatedProductsLoading:s,addingSku:c,onAddAccessory:o})=>(0,x.FD)("div",{className:"lg:shadow-[0_0_16px_0_rgba(0,_0,_0,_0.25)] border-none max-lg:bg-white max-lg:rounded-md",children:[r.length>0&&(0,x.FD)("div",{className:V()("relative","transition-opacity",s&&"opacity-40"),"aria-busy":s,children:[s&&(0,x.Y)("div",{className:"absolute right-10 top-11 z-10 size-4 animate-spin rounded-full border-2 border-current border-t-transparent"}),(0,x.Y)(Z.P,{products:r,cart:e,addingSku:c,onClickAction:{tag:"action",handler:o},title:(0,x.Y)(n.T,{children:t("pane.crossSellingTitle")}),PriceLabel:$.M,theme:"gray",limit:3,noMargin:!0,noPadding:!0,Wrapper:se})]}),(0,x.FD)("div",{className:V()(oe,"pt-1"),children:[(0,x.Y)(ie,{paymentMethods:a.availablePaymentMethods,translations:t,linkToCheckout:l,locale:a,cart:e?{areAllCartLineItemsCheckoutable:e.computed.areAllCartLineItemsCheckoutable,cartDiscount:e.computed.cartDiscount,cartPaymentMethods:e.payment.availablePaymentMethods}:null}),(0,x.Y)(Q,{informationSetDeliveryData:i,variant:"no-border"})]})]}),se=({children:e})=>(0,x.Y)("div",{className:"py-6 lg:py-10 bg-cool-mint px-6 lg:px-10",children:e}),ce=({cart:e,...a})=>{var t,i;const{auth:r}=(0,g.P)().state,{pdpPostAddCartPane:s}=(0,g.P)().state.config.features,v=(0,h.Sz)(),{links:Y}=v,{locale:y,segment:k,translations:N,checkoutTranslations:T,generalTranslations:D,deliveryDaysRange:P}=a,F=e.cart;(0,m.Su)(()=>(d.E.checkoutSteps(F?F.lineItems:[],y,"view-cart",k).push(),!0),[null===F||void 0===F?void 0:F.id]);const w=(0,f._)(N,T,D),I=(0,u.t2)(w),A=(0,l.useId)(),V=F?(0,K.U$)(F):[],L=(0,c.I)({queryKey:(0,K.QK)(v.pageBase.locale.code,v.pageBase.segment.key,A+"@"+(null===F||void 0===F?void 0:F.lineItems.map(e=>e.name).join(","))),queryFn:({signal:e})=>(0,K.fu)({localeCode:v.pageBase.locale.code,segmentKey:v.pageBase.segment.key},V,e),enabled:s&&V.length>0,staleTime:3e5,placeholderData:o.rX}),M=(null!==(t=null===(i=L.data)||void 0===i?void 0:i.products)&&void 0!==t?t:[]).map(K.wY),{addingSku:S,onAddAccessory:z}=(0,j.W)({handleAddToCartError:e=>{console.error(e)}}),E=(0,u.c)(a.deliveryOptions),B=(0,q.X)(E);if(!r)return null;if(!F||0===F.lineItems.length)return(0,x.Y)(C,{...a,left:(0,x.Y)(H,{t:I,links:{...Y,allProducts:{href:a.linkToAllProducts.href,label:(0,x.Y)(n.T,{children:a.linkToAllProducts.label})}}}),right:(0,x.Y)(re,{loadedCart:null,locale:y,t:I,linkToCheckout:a.linkToCheckout,informationSetDeliveryData:B,relatedProducts:M,relatedProductsLoading:L.isFetching,addingSku:S,onAddAccessory:z})});const{versionKey:R,updateFetchedCart:$,requestCartRefetch:Z}=e;return(0,x.FD)(b.x,{auth:r,soClientCart:F,versionKey:R,updateFetchedCart:$,requestCartRefetch:Z,translations:I,deliveryDaysRange:P,children:[(e.isFetching||e.updatingKey)&&(0,x.Y)(p.XO,{}),(0,x.Y)(C,{...a,left:(0,x.Y)(_,{translations:I}),right:(0,x.Y)(re,{loadedCart:F,locale:y,t:I,linkToCheckout:a.linkToCheckout,informationSetDeliveryData:B,relatedProducts:M,relatedProductsLoading:L.isFetching,addingSku:S,onAddAccessory:z})})]})},oe="px-6 lg:px-10";var de=t(86176);const ue=({error:e,translations:a,links:t})=>{const l=(0,u.c)(a);return(0,x.FD)(x.FK,{children:["loading-cart"===e&&(0,x.Y)(p.XO,{}),("shopping-currently-not-possible"===e||"shopping-not-possible"===e)&&(0,x.FD)(x.FK,{children:[(0,x.Y)(R,{richText:(0,x.FD)(x.FK,{children:[(0,x.Y)("h2",{className:V()("font-futura-300 text-heading-2 uppercase text-center"),children:(0,x.Y)(n.T,{children:l("shoppingCurrentlyNotPossible.headline")})}),(0,x.Y)("p",{className:V()("font-futura-300 text-body-subheading text-center","mt-4"),children:(0,x.Y)(n.T,{children:l("shoppingCurrentlyNotPossible.description")})})]}),link:{label:(0,x.Y)(n.T,{children:l("link.homepage")}),href:t.homepage}}),(0,x.Y)(de.h,{size:"lg"})]})]})},he=e=>{const{cart:a}=(0,s.B)();return(0,r.pipe)(a,i.fold(a=>(0,x.Y)("div",{className:"flex justify-center",children:(0,x.Y)(ue,{error:a,translations:e.translations,links:{myServiceRegister:e.linkToMyServiceRegister,homepage:e.linkToHomepage,allProducts:{href:e.linkToAllProducts.href,label:(0,x.Y)(n.T,{children:e.linkToAllProducts.label})}}})}),a=>(0,x.Y)(ce,{...e,cart:a})))}}}]); 2//# sourceMappingURL=8492.6e6b03a1.chunk.js.map
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.