1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[102],{9102:(e,t,l)=>{l.d(t,{L:()=>z});var r=l(82536),n=l(93629),i=l(17459),s=l(66352),o=l(77394),a=l(36420),c=l(51106),u=l(74032),d=l(46001),v=l.n(d),h=l(89016),f=l(28200),m=l(95132);let x=e=>{let{className:t}=e;return(0,s.jsx)("svg",{width:"762",height:"418",viewBox:"0 0 762 418",className:t,fill:"none",xmlns:"http://www.w3.org/2000/svg",children:(0,s.jsx)("path",{d:"M760.048 417.907L760.089 220.236L381.034 1.43534L1.95112 220.299L1.91062 417.971",stroke:"currentColor",strokeWidth:"2"})})};var p=l(89102),g=l(40926),w=l(64099),b=l(97224),j=l(43943),y=l(90046);function k(){return(k=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var l=arguments[t];for(var r in l)Object.prototype.hasOwnProperty.call(l,r)&&(e[r]=l[r])}return e}).apply(this,arguments)}var N=function(e){var t=(0,m.useRef)(e);return t.current=e,t},C=function(e){var t=void 0===e?{}:e,l=t.root,r=t.rootMargin,n=t.threshold,i=void 0===n?0:n,s=t.trackVisibility,o=t.delay,a=t.unobserveOnEnter,c=t.onChange,u=t.onEnter,d=t.onLeave,v=(0,m.useState)({inView:!1,scrollDirection:{}}),h=v[0],f=v[1],x=(0,m.useRef)(!1),p=(0,m.useRef)({}),g=(0,m.useRef)(),w=(0,m.useRef)(!1),b=N(c),j=N(u),y=N(d),C=(0,m.useRef)(),F=(0,m.useCallback)(function(){g.current&&(g.current.disconnect(),p.current={})},[]),T=(0,m.useCallback)(function(e){e&&e!==C.current&&(F(),C.current=e),g.current&&C.current&&g.current.observe(C.current)},[F]),L=(0,m.useCallback)(function(){if(C.current){var e=C.current.getBoundingClientRect();p.current={x:e.x,y:e.y}}},[C]);return(0,m.useEffect)(function(){if(!("IntersectionObserver"in window)||!("IntersectionObserverEntry"in window))return console.error("\uD83D\uDCA1 react-cool-inview: the browser doesn't support Intersection Observer, please install polyfill: https://github.com/wellyshen/react-cool-inview#intersection-observer-polyfill"),function(){return null};var e=!0;return g.current=new IntersectionObserver(function(t){var l=t[0],r=l.intersectionRatio,n=l.isIntersecting,o=l.boundingClientRect,c=o.x,u=o.y,d=l.isVisible,v={},h=Array.isArray(i)?Math.min.apply(Math,i):i,m=void 0!==n?n:r>0;m=h>0?r>=h:m,c<p.current.x&&(v.horizontal="left"),c>p.current.x&&(v.horizontal="right"),p.current.x=c,u<p.current.y&&(v.vertical="up"),u>p.current.y&&(v.vertical="down"),p.current.y=u;var g={entry:l,scrollDirection:v,observe:T,unobserve:F};s&&(void 0!==d||w.current||(console.warn("\uD83D\uDCA1 react-cool-inview: the browser doesn't support Intersection Observer v2, fallback to v1 behavior"),w.current=!0),void 0!==d&&(m=d)),m&&!x.current&&(a&&F(),j.current&&j.current(g)),!m&&x.current&&y.current&&y.current(g),b.current&&b.current(k({},g,{inView:m})),e&&f({inView:m,scrollDirection:v,entry:l}),x.current=m},{root:l,rootMargin:r,threshold:i,trackVisibility:s,delay:o}),T(),function(){e=!1,F()}},[a,l,r,JSON.stringify(i),s,o,T,F]),k({},h,{observe:T,unobserve:F,updatePosition:L})},F=l(26496),T=l(64868);let L=e=>{let{id:t="productrowskeleton",count:l=5}=e;return(0,s.jsx)("ul",{className:"flex justify-center",children:[...Array(l)].map((e,l)=>(0,s.jsx)("li",{className:"overflow-hidden group first-of-type:rounded-l-large last-of-type:rounded-r-large max-w-[18rem] min-w-[18rem] b3:max-w-[28.6rem] b3:min-w-[28.6rem] !h-auto",children:(0,s.jsx)("div",{className:"relative flex items-center object-center w-full h-full overflow-hidden",children:(0,s.jsx)(p.Y,{className:"h-full",fetching:!0,isDescriptionVisible:!1})})},"".concat(t,"_").concat(l)))})},I=e=>{var{title:t,description:l,items:o,fetching:a,locale:c,onQuantityChange:u,sendProductImpressions:d,onFavouriteClick:k,isBackgroundHexagon:N=!0,className:I}=e,S=(0,i._)(e,["title","description","items","fetching","locale","onQuantityChange","sendProductImpressions","onFavouriteClick","isBackgroundHexagon","className"]);let{t:A}=(0,b.B)(),[O,R]=(0,m.useState)(null),{swiperSlider:_,swiperState:E}=(0,j.v)(O),{observe:V}=C({threshold:0,unobserveOnEnter:!0,onEnter:()=>{d&&d()}});return a||o&&0!==o.length?(0,s.jsxs)("section",(0,n._)((0,r._)({className:v()(I,"flex flex-col w-full px-0 overflow-hidden gap-lg"),ref:V,"data-product-row":!0}
1,S),{children:[N&&(0,s.jsx)(s.Fragment,{children:(0,s.jsx)("div",{className:v()("-mb-[60rem] -mt-[11rem] absolute left-1/2 -translate-x-1/2 hidden b4:block pointer-events-none -z-10"),children:(0,s.jsx)(x,{className:"text-color01"})})}),(t||l)&&(0,s.jsx)(f.T,{title:t,subtitle:l,className:v()({"mb-0 b4:mt-[6rem]":!0===N})}),(0,s.jsx)("div",{className:v()("w-full b4:mx-0",{"pt-lg+":!(t||l)}),children:(0,s.jsx)("div",{className:"flex justify-center px-0",children:(0,s.jsx)("div",{className:"relative w-full overflow-visible b3:mt-lg b4:mt-0",children:a?(0,s.jsx)("div",{className:"container",children:(0,s.jsx)(L,{})}):o&&o.length>0&&(0,s.jsxs)(s.Fragment,{children:[_&&(0,s.jsx)("div",{className:"hidden b3:block",children:(0,s.jsx)(g.v,{slider:_,swiperState:E})}),(0,s.jsx)(T.RC,{onSwiper:e=>R(e),speed:500,modules:[F.Vx],slidesPerView:"auto",centerInsufficientSlides:!0,className:"w-full",direction:"horizontal",wrapperClass:"flex bg-brown-100 rounded-large",spaceBetween:1,children:o.map((e,t)=>(0,s.jsx)(T.qr,{className:"overflow-hidden group first-of-type:rounded-l-large last-of-type:rounded-r-large max-w-[18rem] min-w-[18rem] b3:max-w-[28.6rem] b3:min-w-[28.6rem] !h-auto",children:(0,s.jsx)("div",{className:"relative flex items-center object-center w-full h-full overflow-hidden",children:(0,s.jsx)(h.t,{retry:!0,children:(0,s.jsx)(p.Y,{className:"h-full",product:e,locale:c,onQuantityChange:t=>{u&&u(t,e)},onFavouriteClick:k,view:p.M.Tile,imageView:y.H.Featured,fetching:a,isDescriptionVisible:!1})})})},t))})]})})})})]})):(0,s.jsx)("div",{className:"h-full p-lg flex-center-x bg-color01",children:A[w.o.lister.empty]})};var S=l(76525),A=l(4938),O=l(47956),R=l(200),_=l(89267),E=l(348),V=l(96907),B=l.n(V),P=l(12845),M=l(53741),D=l(90559),Q=l(6560);let q=B()(e=>e(),1e3),z=e=>{var t,{fetching:l,items:d,className:v,title:h,description:f,locale:x}=e,p=(0,i._)(e,["fetching","items","className","title","description","locale"]);let g=(0,R.t)(),{loggedInStatus:w}=(0,m.useContext)(P.C),[b,j]=(0,m.useState)({open:!1,sku:void 0}),[y,k]=(0,m.useState)(!1),{data:N}=(0,D.he)(void 0,"cache-and-network"),[C]=(0,o.n)(M.B5),{data:F}=(0,a.IT)(Q.in,{variables:{skus:null==d?void 0:d.map(e=>e.sku)},fetchPolicy:"cache-and-network",ssr:!1,skip:w!==E.fM.isAuth||!d||(null==d?void 0:d.length)===0}),T=(0,m.useRef)(N),[L]=(0,M.od)(void 0,!1),V=async(e,t)=>{var l,r,n,i,s,o;let a=e.sku,c=null==T||null==(n=T.current)||null==(r=n.customCart)||null==(l=r.items)?void 0:l.find(e=>e.sku===a),u=null!=(i=null==c?void 0:c.qty)?i:0,d={products:[{itemId:null==c?void 0:c.itemId,sku:a,qty:null!=t?t:0}]},v=0;if(u>0?await C({variables:{input:d}}).then(async e=>{var t,l;let{data:r}=e;await q(g);let n=null!=(l=null==r||null==(t=r.updateCartItem)?void 0:t.qty)?l:0;n&&(v=n)}):L({variables:{input:d}}).then(async e=>{var t,l,r,n;let{data:i}=e;await q(g);let s=null!=(n=null==i||null==(r=i.addProductsToCart)||null==(l=r.items)||null==(t=l.find(e=>e.sku===a))?void 0:t.qty)?n:0;s&&(v=s)}),v>=0){let t=v-u,l=t>0?_.Je.AddToCart:_.Je.RemoveFromCart;(t>0||t<0)&&(0,A.C)({type:l,orderlistId:(0,S.u)(null==T||null==(o=T.current)||null==(s=o.customCart)?void 0:s.customAttributes,"OrderList_ID"),product:e,qty:t>0?t:-t,location:_.td.Featured})}},B=async e=>{w!==E.fM.isAuth?k(!0):j({open:!0,sku:e})};return(0,m.useEffect)(()=>{T.current=N},[N]),(0,s.jsxs)(s.Fragment,{children:[y&&(0,s.jsx)(u.K,{onClose:()=>k(!1)}),b.open&&(0,s.jsx)(c.e,{showFlyout:b.open,setShowFlyout:e=>j({open:e,sku:void 0}),skus:(null==b?void 0:b.sku)?[null==b?void 0:b.sku]:[],origin:_.td.Category}),(0,s.jsx)(I,(0,n._)((0,r._)({},p),{fetching:l,title:h,description:f,locale:x,className:v,items:(0,O.ec)(d,null==N||null==(t=N.customCart)?void 0:t.items,null==F?void 0:F.onFavouriteLists),onQuantityChange:(e,t)=>
1{V(t,e)},onFavouriteClick:e=>{let{sku:t}=e;B(t)}}))]})}},51106:(e,t,l)=>{l.d(t,{e:()=>I});var r=l(66352),n=l(36420),i=l(77394),s=l(18171),o=l(82254),a=l(66589),c=l(47128),u=l(55777),d=l(22317),v=l(33895),h=l(17824),f=l(82610),m=l(33063),x=l(48019),p=l(64099),g=l(97224),w=l(89267),b=l(348),j=l(30985),y=l(21688),k=l(12845),N=l(29171),C=l(6560),F=l(95132),T=l(34345),L=l(15959);let I=e=>{var t,l,I,S,A;let{className:O,showFlyout:R,setShowFlyout:_,skus:E,origin:V}=e,[B,P]=(0,F.useState)([]),[M,D]=(0,F.useState)(!1),[Q,q]=(0,F.useState)(!1),{loggedInStatus:z}=(0,F.useContext)(k.C),{t:J}=(0,g.B)(),$=j.n.PERSONAL_FAVOURITE_LIST,{loading:H,data:K,refetch:Y}=(0,n.IT)(C.Pj,{ssr:!1,skip:!R}),U=null==K||null==(l=K.getFavouriteLists)||null==(t=l.find(e=>(null==e?void 0:e.type)===j.n.PERSONAL_FAVOURITE_LIST))?void 0:t.lists;(0,F.useEffect)(()=>{R&&Y()},[R]);let{data:G}=(0,n.IT)(C.in,{variables:{skus:null==E?void 0:E.map(e=>e)},fetchPolicy:"cache-and-network",ssr:!1,skip:!R||z!==b.fM.isAuth||(null==E?void 0:E.length)>1}),W=null==G?void 0:G.onFavouriteLists,X=null==W?void 0:W.flatMap(e=>e.favouriteLists),[Z,{data:ee,loading:et,reset:el}]=(0,i.n)(N.Bu,{awaitRefetchQueries:!0,refetchQueries:(null==E?void 0:E.length)===1?["OnFavouriteLists"]:[],onCompleted:()=>{setTimeout(()=>_(!1),2e3),P([]),y.y.setTag({analyticsInput:{event:w.Je.AddToFavouriteList,data:{skus:E,origin:V}}})}}),er=async e=>{Z({variables:{input:e.map(e=>({favouriteListId:e,items:E.map(e=>({sku:e,qty:1}))}))}})};return(0,F.useEffect)(()=>()=>el(),[R]),(0,r.jsxs)(r.Fragment,{children:[R&&(0,r.jsx)(s.e,{showFlyout:M,setShowParentFlyout:_,setShowFlyout:D,origin:V}),(0,r.jsxs)(x.m,{location:"right",toggle:R&&!M,setToggle:_,renderHeader:()=>{var e,t,l;return(0,r.jsxs)("div",{className:"w-full flex wrap flex-col gap-sm",children:[(0,r.jsx)("h3",{className:"w-full text-lg b4:text-3xl",children:null!=(e=J[p.o.product.addToFavourites.flyout.title])?e:"Favorietenlijsten"}),(0,r.jsx)(m.k,{href:o.v.AccountFavouriteLists(),children:(0,r.jsx)(L.Q,{className:"block w-full mb-sm",icon:(0,r.jsx)(h.C,{}),"data-show-all-favourite-list-link":!0,children:(0,r.jsx)("span",{children:null!=(t=J[p.o.product.addToFavourites.flyout.showAllLists])?t:"Bekijk alle favorietenlijsten"})})}),(0,r.jsx)(L.Q,{className:"block w-full mb-sm",href:"#",onClick:e=>{e.preventDefault(),D(e=>!e)},icon:(0,r.jsx)(f.G,{}),"data-create-favourite-list-toggle":!0,children:(0,r.jsx)("span",{children:null!=(l=J[p.o.product.addToFavourites.flyout.newList])?l:"Nieuwe favorietenlijst aanmaken"})})]})},className:O,renderFooter:()=>{var e;return(0,r.jsxs)("div",{className:"grid b4:grid-cols-2 gap",children:[(0,r.jsx)(a.$,{className:"w-full",loading:et,success:!!ee,onClick:()=>{er(B.map(e=>e.id))},disabled:0===B.length,"data-add-to-favourite-lists":!0,children:null!=(e=J[p.o.product.addToFavourites.flyout.add])?e:"Voeg toe aan lijst"}),(0,r.jsx)(a.$,{color:c.n.brown100,className:"w-full b4:flex-1",onClick:()=>_(!1),"data-flyout-back-button":!0,children:J[p.o.common.forms.back]})]})},children:[(0,r.jsx)(d.C,{children:null!=(I=J[p.o.product.addToFavourites.flyout.intro])?I:"Kies de favorietenlijst(en) waar je dit product aan wilt toevoegen."}),H?[void 0,void 0,void 0,void 0].map((e,t)=>(0,r.jsx)(u.r,{className:"grid b3:!px-lg+ b3:!-mx-lg+",children:(0,r.jsx)(T.A,{width:220})},t)):(0,r.jsx)(r.Fragment,{children:(0,r.jsxs)("div",{className:"mb-lg","data-favourite-type":$,children:[U&&U.length>0?U.slice(0,!Q&&U.length>5?5:U.length).map(e=>{let{id:t,name:l}=e,n=null==X?void 0:X.some(e=>(null==e?void 0:e.id)===t);return(0,r.jsx)(u.r,{className:"grid b3:!px-lg+ b3:!-mx-lg+","data-favourite-list-id":t,"data-favourite-list-success":B.includes(e),children:(0,r.jsx)(v.S,{className:"items-center",onClick:()=>{B.filter(e=>e.id===t).length>0?P(B.filter(e=>e.id!==t)):P([...B,e])},checked:(null==B?void 0:B.some(e=>e.id===t))||n,"data-check-favourite-list":!0,disabled:n,label:l})},t)}):(0,r.jsx)("span",{children:null!=(S=J[p.o.product.addToFavourites.flyout.none])?S:"Je hebt nog geen favorietenlijsten"}),U&&U.length>5&&!Q&&(0,r.jsx)("div",{className:"flex-center-y bg-color01 px-lg py -mx-lg",children:(0,r.jsx)(L.Q,{className:"block",href:"#",onClick:e=>{e.preventDefault(),q(!Q)},children:(0,r.jsx)("span",{children:null!=(A=J[p.o.product.addToFavourites.flyout.showAll])?A:"Bekijk alles"})})})]})})]})]})}},74032:(e,t,l)=>{l.d(t,{K:()=>u});var r=l(66352),n=l(24457),i=l(66589),s=l(47128),o=l(99526),a=l(64099),c=l(97224);let u=e=>{let{onClose:t}=e,{t:l}=(0,c.B)();return(0,r.jsxs)(o.zD,{title:l[a.o.product.addToFavourites.favouritesLogin.title],onClose:t,active:!0,children:[(0,r.jsx)(o.g0,{children:l[a.o.product.addToFavourites.favouritesLogin.text]}),(0,r.jsxs)(o.IY,{children:[(0,r.jsx)(i.$,{className:"w-full b3:w-auto",onClick:()=>{var e;return n.g.navigateToLogin("?redirect=".concat(null==(e=window)?void 0:e.location.pathname))},children:l[a.o.product.addToFavourites.favouritesLogin.button]}),(0,r.jsx)(i.$,{className:"w-full b3:w-auto",color:s.n.background,onClick:t,children:l[a.o.common.forms.cancel]})]})]})}}}]);
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.