whatmore-react-assets 1.0.1591 → 1.0.1593
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
|
@@ -65,7 +65,7 @@
|
|
|
65
65
|
100% {
|
|
66
66
|
transform: translateY(0%) rotate(0deg);
|
|
67
67
|
}
|
|
68
|
-
`} infinite 1.5s linear`;return(0,f.jsx)(O.J,{unmountOnExit:!0,initialScale:.2,in:d,reverse:!0,delay:g,children:(0,f.jsx)(c.az,{width:"100%",height:"fit-content",paddingTop:100,borderRadius:"3xl",children:(0,f.jsxs)(u.B,{direction:"column",width:"100%",height:"0px",justifyContent:"flex-end",children:[(0,f.jsx)(s.o,{animation:"vertical"===p?b:C,children:"vertical"===p?(0,f.jsx)(D.A,{sx:{color:"white !important",fontSize:w,filter:"drop-shadow(0 0 20px black);"}}):(0,f.jsx)(R.A,{sx:{color:"white !important",fontSize:w,filter:"drop-shadow(0 0 20px black);"}})}),(0,f.jsx)(s.o,{children:(0,f.jsx)(j.E,{textShadow:"dark-lg",fontSize:y+"px",fontWeight:"semibold",sx:{color:"white !important",textShadow:"0px 0px 20px black !important;"},children:"swipe for more"})})]})})})};var Q=function(t){const[e,i]=(0,v.QN)("isFirstIndicatorRenderDone"),[o]=(0,v.QN)("indicatorRenderSeconds"),r=o,l=t.swipeUp;return(0,n.useEffect)((()=>{const t=setTimeout((()=>{i(!0)}),3e3+1e3*r);return()=>{clearTimeout(t)}}),[]),e?null:(0,f.jsx)(W,{showForSeconds:.8*r,delayInSeconds:3,swipeUp:l})},V=i(8781),M=i(5144),H=i(4459);const U="15px";var X=i(1351),Y=i(6157),$=i(4737);var q=function(t){const[e]=(0,v.QN)("isInDesignMode"),[i]=(0,v.QN)("isDemoBrand"),[o]=(0,v.QN)("whatmoreSecondaryColor"),[r]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,h,m,g]=(0,x.A)(),[w,y]=(0,n.useState)(!1),b=t.product,C=t.event,{whatmoreWidgetSourceDetails:S}=(0,n.useContext)($.B),k=.1*m,I=.95*g,_=.05*g;return(0,f.jsx)(u.B,{direction:"row",height:k,justifyContent:"center",alignItems:"center",alignContent:"center",bgGradient:"linear(to-b, transparent, blackAlpha.400, blackAlpha.600)",children:(0,f.jsx)(u.B,{direction:"column",width:"fit-content",height:k,justifyContent:"center",alignItems:"center",alignContent:"center",children:(0,f.jsx)(c.az,{width:I+"px",height:"fit-content",padding:"6px",marginTop:U,backgroundColor:o,borderRadius:"5px",animation:w?M.jd:null,onAnimationEnd:()=>{y(!1)},marginBottom:(0,p.qw1)(a),onClick:()=>{y(!0),function(t,n){e||i||(async()=>{(0,l.Pb)(t,n),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_SHOPNOW_CLICKED,widgetSourceDetails:S,event:t,productList:[n],ctaList:t.cta})})()}(C,b),window.location.href=function(t){return(0,p.BLb)(a)?t.product_link+"?"+(0,p.VCz)(a)+"&"+(0,p.Spk)(a)+"&"+(0,p.$lz)(a):t.product_link}(b)},_hover:{backgroundColor:(0,H.YU)(o,8)},cursor:"pointer",children:(0,f.jsx)(s.o,{children:(0,f.jsx)(j.E,{style:{overflow:"hidden",textOverflow:"ellipsis"},noOfLines:1,fontSize:1.2*_+"px",fontWeight:"medium",lineHeight:"120%",sx:{fontFamily:r+" !important",color:"white !important"},children:(0,p.Qed)(a)})})})})})},K=i(4892),G=i(8538),Z=i(7458),J=i(2159),tt=i(9537),et=i(6710),it=i(173),nt=(i(6125),i(4905));const ot={en:{add_to_cart:"ADD TO CART",buy_now:"BUY NOW",more_info:"MORE INFO",size:"Size",color:"Color",description:"Description",like:"Like",share:"Share",talk_to_us:"Talk to Us",done:"Done",cancel:"Cancel",view_product:"View Product",go_to_cart:"Go to Cart"},ar:{add_to_cart:"\u0623\u0636\u0641 \u0625\u0644\u0649 \u0627\u0644\u0633\u0644\u0629",buy_now:"\u0627\u0634\u062a\u0631\u0650 \u0627\u0644\u0622\u0646",more_info:"\u0645\u0632\u064a\u062f \u0645\u0646 \u0627\u0644\u0645\u0639\u0644\u0648\u0645\u0627\u062a",size:"\u0627\u0644\u062d\u062c\u0645",color:"\u0627\u0644\u0644\u0648\u0646",description:"\u0627\u0644\u0648\u0635\u0641",like:"\u0623\u0639\u062c\u0628\u0646\u064a",share:"\u0645\u0634\u0627\u0631\u0643\u0629",talk_to_us:"\u062a\u062d\u062f\u062b \u0625\u0644\u064a\u0646\u0627",done:"\u062a\u0645",cancel:"\u0625\u0644\u063a\u0627\u0621",view_product:"\u0639\u0631\u0636 \u0627\u0644\u0645\u0646\u062a\u062c",go_to_cart:"\u0627\u0630\u0647\u0628 \u0625\u0644\u0649 \u0627\u0644\u0633\u0644\u0629",watch_and_buy:"\u0634\u0627\u0647\u062f \u0648\u0627\u0634\u062a\u0631\u064a"},da:{add_to_cart:"In den Warenkorb",buy_now:"Jetzt kaufen",more_info:"Mehr Infos",size:"Gr\xf6\xdfe",color:"Farbe",description:"Beschreibung",like:"Gef\xe4llt mir",share:"Teilen",talk_to_us:"Sprechen Sie mit uns",done:"Fertig",cancel:"Abbrechen",view_product:"Produkt ansehen",go_to_cart:"Zum Warenkorb",watch_and_buy:"Ansehen und kaufen"},de:{add_to_cart:"In den Warenkorb",buy_now:"Jetzt kaufen",more_info:"Mehr Infos",size:"Gr\xf6\xdfe",color:"Farbe",description:"Beschreibung",like:"Gef\xe4llt mir",share:"Teilen",talk_to_us:"Sprechen Sie mit uns",done:"Fertig",cancel:"Abbrechen",view_product:"Produkt ansehen",go_to_cart:"Zum Warenkorb",watch_and_buy:"Ansehen und kaufen"},es:{add_to_cart:"A\xf1adir al carrito",buy_now:"Comprar ahora",more_info:"M\xe1s informaci\xf3n",size:"Tama\xf1o",color:"Color",description:"Descripci\xf3n",like:"Me gusta",share:"Compartir",talk_to_us:"Habla con nosotros",done:"Hecho",cancel:"Cancelar",view_product:"Ver producto",go_to_cart:"Ir al carrito",watch_and_buy:"Ver y comprar"},fr:{add_to_cart:"Ajouter au panier",buy_now:"Acheter maintenant",more_info:"Plus d'infos",size:"Taille",color:"Couleur",description:"Description",like:"J'aime",share:"Partager",talk_to_us:"Parlez-nous",done:"Valider",cancel:"Annuler",view_product:"Voir le produit",go_to_cart:"Aller au panier",watch_and_buy:"Regarder et acheter"},ja:{add_to_cart:"\u30ab\u30fc\u30c8\u306b\u8ffd\u52a0",buy_now:"\u4eca\u3059\u3050\u8cfc\u5165",more_info:"\u8a73\u7d30\u60c5\u5831",size:"\u30b5\u30a4\u30ba",color:"\u8272",description:"\u8aac\u660e",like:"\u3044\u3044\u306d",share:"\u5171\u6709",talk_to_us:"\u304a\u554f\u3044\u5408\u308f\u305b",done:"\u5b8c\u4e86",cancel:"\u30ad\u30e3\u30f3\u30bb\u30eb",view_product:"\u5546\u54c1\u3092\u898b\u308b",go_to_cart:"\u30ab\u30fc\u30c8\u306b\u9032\u3080",watch_and_buy:"\u8996\u8074\u3057\u3066\u8cfc\u5165"},nl:{add_to_cart:"Aan winkelwagentje toevoegen",buy_now:"Nu kopen",more_info:"Meer informatie",size:"Maat",color:"Kleur",description:"Beschrijving",like:"Vind ik leuk",share:"Delen",talk_to_us:"Praat met ons",done:"Klaar",cancel:"Annuleren",view_product:"Bekijk product",go_to_cart:"Ga naar winkelwagentje",watch_and_buy:"Kijk en koop"},pt:{add_to_cart:"Adicionar ao carrinho",buy_now:"Comprar agora",more_info:"Mais informa\xe7\xf5es",size:"Tamanho",color:"Cor",description:"Descri\xe7\xe3o",like:"Curtir",share:"Compartilhar",talk_to_us:"Fale conosco",done:"Conclu\xeddo",cancel:"Cancelar",view_product:"Ver produto",go_to_cart:"Ir para o carrinho",watch_and_buy:"Assistir e comprar"},zh:{add_to_cart:"\u52a0\u5165\u8d2d\u7269\u8f66",buy_now:"\u7acb\u5373\u8d2d\u4e70",more_info:"\u66f4\u591a\u4fe1\u606f",size:"\u5c3a\u5bf8",color:"\u989c\u8272",description:"\u63cf\u8ff0",like:"\u559c\u6b22",share:"\u5206\u4eab",talk_to_us:"\u8054\u7cfb\u6211\u4eec",done:"\u5b8c\u6210",cancel:"\u53d6\u6d88",view_product:"\u67e5\u770b\u5546\u54c1",go_to_cart:"\u524d\u5f80\u8d2d\u7269\u8f66",watch_and_buy:"\u89c2\u770b\u5e76\u8d2d\u4e70"}};function rt(t){var e,i,o;const[r]=(0,v.QN)("whatmoreSecondaryColor"),[l]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,s]=(0,n.useState)(!1),h=null!==(e=t.baseFontSize)&&void 0!==e?e:10,x=t.onClick,m=t.width,g=t.height,w=t.title,y=t.showInProgressIcon;return(0,f.jsxs)(c.az,{display:"flex",width:m,height:g,padding:"2x",boxShadow:"lg",animation:d?M.jd:null,onAnimationEnd:()=>{s(!1)},cursor:"pointer",children:["awaitingVariantSelection"==t.cartState&&(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"2px",backgroundColor:"white",onClick:e=>{e.stopPropagation(),t.updateCartState("init"),t.setProductVariantTitle(t.productTitle),s(!0)},children:(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*h+"px !important",fontWeight:"semibold !important",sx:{fontFamily:l+" !important",color:"#343434 !important"},children:["\xa0",null!==(i=null===ot||void 0===ot||null===(o=ot[null===t||void 0===t?void 0:t.websiteLanguage])||void 0===o?void 0:o.cancel)&&void 0!==i?i:"Cancel","\xa0"]})}),(0,f.jsxs)(u.B,{direction:"row",backgroundColor:y?(0,H.YU)(r,8):r,width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"2px",onClick:t=>{t.stopPropagation(),x(),s(!0)},children:[(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*h+"px !important",fontWeight:"semibold !important",sx:{fontFamily:l+" !important",color:(0,p.Hfu)(a)+" !important"},children:["\xa0",w,"\xa0"]}),y?(0,f.jsx)("div",{className:"whatmore-rotate-indefinitely",children:(0,f.jsx)(it.A,{sx:{filter:"drop-shadow(0 0 15px black);",color:"#F5F5F5",fontSize:2.5*h+"px"}})}):(0,f.jsx)(f.Fragment,{})]})]})}function lt(t){var e,i,o;const[r]=(0,v.QN)("whatmoreSecondaryColor"),[l]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,h]=(0,n.useState)(!1),x=null!==(e=t.baseFontSize)&&void 0!==e?e:10,m=t.onClick,g=t.width,w=t.height;return(0,f.jsx)(c.az,{width:g,height:w,padding:"2x",boxShadow:"lg",backgroundColor:"#000000"==(0,p.Wc_)(a)?r:(0,p.Wc_)(a),onClick:t=>{t.stopPropagation(),m(),h(!0)},animation:d?M.jd:null,onAnimationEnd:()=>{h(!1)},cursor:"pointer",children:(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"5px",children:(0,f.jsx)(s.o,{children:(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*x+"px !important",fontWeight:"semibold !important",sx:{fontFamily:l+" !important",color:(0,p.Hfu)(a)+" !important"},children:["\xa0","ADD TO CART"!=(0,p.KPq)(a)?(0,p.KPq)(a):null!==(i=null===ot||void 0===ot||null===(o=ot[null===t||void 0===t?void 0:t.websiteLanguage])||void 0===o?void 0:o.add_to_cart)&&void 0!==i?i:(0,p.KPq)(a),"\xa0"]})})})})}function at(t){var e;const[i]=(0,v.QN)("whatmorePrimaryFont"),n=null!==(e=t.baseFontSize)&&void 0!==e?e:10,o=t.width,r=t.height;return(0,f.jsx)(c.az,{width:o,height:r,padding:"2x",boxShadow:"lg",backgroundColor:"white",borderColor:"gray",borderWidth:"1px",onClick:t=>{t.stopPropagation()},children:(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",paddingX:"4px",paddingY:"5px",justifyContent:"center",children:(0,f.jsxs)(j.E,{color:"gray",lineHeight:"100%",fontSize:1.3*n+"px !important",fontWeight:"semibold !important",sx:{fontFamily:i+" !important",color:"gray !important"},children:["\xa0"," Sold Out ","\xa0"]})})})}function dt(t){var e;const[i]=(0,v.QN)("whatmoreSecondaryColor"),[n]=(0,v.QN)("whatmorePrimaryFont"),[o]=(0,v.QN)("whatmoreShopId"),r=null!==(e=t.baseFontSize)&&void 0!==e?e:10,l=t.onClick,a=t.cartCount,d=t.width,h=t.height,x=t.onCartIconClick;return(0,f.jsx)(c.az,{width:d,height:h,padding:"2x",boxShadow:"lg",backgroundColor:"white",borderColor:i,borderWidth:"1px",onClick:t=>{t.stopPropagation()},cursor:"pointer",children:(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",paddingX:"4px",paddingY:"5px",justifyContent:"center",children:[(0,f.jsx)(s.o,{paddingX:"5px",onClick:()=>{x()},children:(0,p.DiI)(o)?(0,f.jsx)(nt.$,{size:"sm",_hover:{bg:i},sx:{bg:i},children:(0,f.jsx)(j.E,{paddingX:"6px",color:"white",sx:{fontSize:.85*r},children:"GO TO CART"})}):(0,f.jsx)(tt.A,{sx:{color:i,fontSize:1.6*r}})}),(0,f.jsx)(j.E,{color:i,fontSize:1.3*r+"px !important",fontWeight:"semibold !important",sx:{fontFamily:n+" !important"},children:a}),(0,f.jsx)(s.o,{paddingX:"5px",onClick:t=>{t.stopPropagation(),l()},children:(0,f.jsx)(J.A,{sx:{color:i,fontSize:1.6*r}})})]})})}var st=function(t){var e,i,n,o,r,l,a;const[d]=(0,v.QN)("websiteLanguage"),s=null!==(e=t.baseFontSize)&&void 0!==e?e:10,c=null===(i=t.showAddedToCart)||void 0===i||i,u=t.cartState,h=t.cartCount,p=t.onClickAtc,x=t.onCartIconClick;function m(){p()}const g=null!==(n=t.width)&&void 0!==n?n:"100%",w=null!==(o=t.height)&&void 0!==o?o:"100%";return"errored"==u?(0,f.jsx)(et.s,{unmountOnExit:!0,in:!0,initialScale:.5,style:{height:w,width:g},children:(0,f.jsx)(at,{baseFontSize:s,width:g,height:w})}):"init"==u?0==h?(0,f.jsx)(lt,{onClick:m,baseFontSize:s,width:g,height:w,websiteLanguage:d}):c?(0,f.jsx)(et.s,{unmountOnExit:!0,in:!0,initialScale:.5,style:{height:w,width:g},children:(0,f.jsx)(dt,{onClick:m,baseFontSize:s,cartCount:h,width:g,height:w,onCartIconClick:x})}):(0,f.jsx)(lt,{onClick:m,baseFontSize:s,width:g,height:w,websiteLanguage:d}):(0,f.jsx)(rt,{onClick:m,setProductVariantTitle:t.setProductVariantTitle,cartState:u,productTitle:null===(r=t.product)||void 0===r?void 0:r.title,updateCartState:t.updateCartState,baseFontSize:s,width:g,height:w,title:"awaitingVariantSelection"==u?null!==(l=null===ot||void 0===ot||null===(a=ot[d])||void 0===a?void 0:a.done)&&void 0!==l?l:"Done":"",showInProgressIcon:"atcApiCallInProgress"==u||"productVariantDetailsApiCallInProgress"==u,websiteLanguage:d})},ct=i(4533),ut=i(6387),ht=i(1745);const pt=(0,v.Xd)("isInDesignMode"),vt=(0,v.Xd)("isDemoBrand");async function xt(t,e,i,n,o,r,l,a,d){return"shopify"==i?(0,ht.RX)(t,e,n,l,a,d):(pt||vt||(async()=>{(0,ct.Fu)(o,r,l,a,d)})(),(0,ut.It)(null===t||void 0===t?void 0:t[0],e,n))}function mt(t,e){return"shopify"==t?(0,ht.iL)(e):(0,ut.pV)(e)}var gt=i(852);var ft=function(t,e,i){const[o]=(0,v.QN)("whatmoreShopId"),[r]=(0,v.QN)("isInDesignMode"),[a]=(0,v.QN)("isDemoBrand"),[d,s]=(0,n.useState)(null),c=(0,n.useRef)(null),{closeClickComponent:u}=(0,n.useContext)(Ni),{whatmoreUserInfo:h}=(0,n.useContext)($.B),[x,g]=(0,n.useState)({state:"init",cart_count:t});function f(t,e){g({state:t,cart_count:null!==e&&void 0!==e?e:x.cart_count}),"init"!=t&&"errored"!=t?(0,v.t2)("whatmoreAllowAutoSlide",!1):(0,v.t2)("whatmoreAllowAutoSlide",!0)}function w(t){const e=c.current.filter((e=>e.option1==t[0]&&e.option2==t[1]&&e.option3==t[2]));return 0==e.length?null:e[0].id}function j(t){var e=[],i=[],n=[];return t.variants.forEach((o=>{var r,l,a;o.option1&&e.push({option:o.option1,available:null===(r=o.available)||void 0===r||r,type:t.options[0].name}),o.option2&&i.push({option:o.option2,available:null===(l=o.available)||void 0===l||l,type:t.options[1].name}),o.option3&&n.push({option:o.option3,available:null===(a=o.available)||void 0===a||a,type:t.options[2].name})})),e=e.reduce(((t,e,i)=>{var n=t.filter((t=>t.option==e.option));return 0==n.length?[...t,e]:(n[0].available=n[0].available|e.available,t)}),[]),i=i.reduce(((t,e,i)=>{var n=t.filter((t=>t.option==e.option));return 0==n.length?[...t,e]:(n[0].available=n[0].available|e.available,t)}),[]),n=n.reduce(((t,e,i)=>{var n=t.filter((t=>t.option==e.option));return 0==n.length?[...t,e]:(n[0].available=n[0].available|e.available,t)}),[]),[e,i,n]}function y(t){if(0==t.length)return null;const e=t.filter((t=>t.available));return 0==e.length?null:e[0].option}function b(t){return t[0].length<=1&&t[1].length<=1&&t[2].length<=1}function C(){if(c.current&&c.current.length>=1){return c.current.filter((t=>t.available)).length>=1}return!1}function S(t,e,i){r||a||(async()=>{(0,l.tO)(t,e,i)})()}function k(t,n){const r=w(t);if(!r)return void f("init",x.cart_count);f("atcApiCallInProgress",null);xt([r],1,(0,p.NCy)(o),o,i,e,n,null===i||void 0===i?void 0:i.location,null===h||void 0===h?void 0:h.userType).then((t=>{if(!t.ok)throw new Error(t.status);return t.json()})).then((t=>(S(i,e,1),f("init",x.cart_count+1),(0,v.t2)("whatmoreAddedToCart",!0),"72550089015"==o&&(0,v.Xd)("whatmoreAddedToCart")&&(0,gt.H)(o,(()=>{}),100,window.location.hostname),(0,p.MPe)(o)&&setTimeout((()=>function(){const t=window.location.origin+"/cart";window.location.href=t}()),500),t))).catch((t=>{f("errored",null),console.error("Error while adding to cart:",t)}))}return[x,function(t){const n=[];f("productVariantDetailsApiCallInProgress",null),Promise.all(i.products.map((t=>(0,m.M)(t,(0,p.NCy)(o),o).then((e=>{c.current=e.variants;const i=j(e);if(s(i),b(i)&&C()){const e=w([y(i[0]),y(i[1]),y(i[2])]);return e?(n.push(t),e):void f("init",x.cart_count)}}))))).then((r=>{const l=r.filter((t=>void 0!=t));xt(l,1,(0,p.NCy)(o),o,i,e,t,null===i||void 0===i?void 0:i.location,null===h||void 0===h?void 0:h.userType).then((t=>{if(!t.ok)throw new Error(t.status);return t.json()})).then((t=>(n.forEach((t=>{S(i,t,1)})),f("init",x.cart_count+(null===l||void 0===l?void 0:l.length)),(0,v.t2)("whatmoreAddedToCart",!0),t))).catch((t=>{f("errored",null),console.error("Error while adding to cart:",t)}))}))},f,d,function(t){let i=arguments.length>1&&void 0!==arguments[1]&&arguments[1];f("productVariantDetailsApiCallInProgress",null),(0,m.M)(e,(0,p.NCy)(o),o).then((e=>{c.current=e.variants;const n=j(e);s(n),b(n)||i?C()?k([y(n[0]),y(n[1]),y(n[2])],t):f("errored",null):f("awaitingVariantSelection",null)})).catch((t=>{f("errored",null)}))},k,function(t){var e,i,n,r;const l=c.current.filter((e=>e.option1==t[0]&&e.option2==t[1]&&e.option3==t[2]));if(0==l.length)return null;const a=null!==(e=l[0].price)&&void 0!==e?e:0,d=null!==(i=l[0].compare_at_price)&&void 0!==i?i:0;return{price:((0,p.NCy)(o),a),compare_price:((0,p.NCy)(o),d),title:null!==(n=null===(r=l[0])||void 0===r?void 0:r.title)&&void 0!==n?n:""}},function(){"do_nothing"!==(0,p.m4S)(o)&&("go_to_cart_page"!==(0,p.m4S)(o)?"open_cart_slider"!==(0,p.m4S)(o)||null!==u&&u():mt((0,p.NCy)(o),o))}]},wt=i(2720),jt=i(3755),yt=i(7973);var bt=function(t){var e,i,o;const r=t.productVariantOptions,l=null!==(e=t.width)&&void 0!==e?e:"100%",a=(t.height,t.maxHeight),d=null!==(i=t.baseFontSize)&&void 0!==i?i:10,h=t.onOptionSelected,p=null!==(o=t.optionTitleColor)&&void 0!==o?o:"black",x=t.data,[m]=(0,v.QN)("whatmorePrimaryFont"),g=(0,n.useRef)(null),[w,b]=(0,n.useState)(!1),[C,S]=(0,n.useState)(0),[k,I]=(0,n.useState)(0);function _(t){if(0==t.length)return null;const e=t.filter((t=>t.available));return 0==e.length?null:e[0].option}const[z,E]=(0,n.useState)([_(r[0]),_(r[1]),_(r[2])]);return(0,n.useEffect)((()=>{h(z)}),[z]),(0,f.jsx)(u.B,{ref:g,direction:"column",width:l,maxHeight:a,justifyContent:"flex-start",alignItems:"center",spacing:"2px",paddingY:"2px",overflowY:"auto",onTouchStart:t=>{g.current&&(b(!0),S(t.touches[0].clientY),I(g.current.scrollTop))},onTouchMove:t=>{if(!w||!g.current)return;const e=t.touches[0].clientY,i=1.5*(C-e);g.current.scrollTop=k+i,t.preventDefault()},onTouchEnd:()=>{b(!1)},onWheel:t=>{if(!g.current)return;let e=0===t.deltaMode?1:15;g.current.scrollTop+=t.deltaY*e},sx:{"&::-webkit-scrollbar":{width:"4px"},"&::-webkit-scrollbar-track":{width:"6px",background:"#f1f1f1"},"&::-webkit-scrollbar-thumb":{background:"#888",borderRadius:"24px"},"&::-webkit-scrollbar-thumb:hover":{background:"#555"},"overflow-y":"scroll !important","-webkit-overflow-scrolling":"touch"},children:r.map(((e,i)=>{var n;if(0==e.length||"mlveda_country"==(null===e||void 0===e||null===(n=e[0])||void 0===n?void 0:n.type))return;const o=e.every((e=>{var i,n,o,r,l,a;return(null===t||void 0===t||null===(i=t.finalArr)||void 0===i||null===(n=i.finalArr)||void 0===n||null===(o=n.find((t=>(null===t||void 0===t?void 0:t.color)===(null===e||void 0===e?void 0:e.option))))||void 0===o?void 0:o.src)||(null===t||void 0===t||null===(r=t.finalArr)||void 0===r||null===(l=r.finalArrExternal)||void 0===l||null===(a=l.find((t=>(null===t||void 0===t?void 0:t.color)===(null===e||void 0===e?void 0:e.option))))||void 0===a?void 0:a.optionsrc)}));return(0,f.jsxs)(u.B,{width:"100%",direction:"column",alignItems:"center",justifyContent:"flex-start",paddingY:"2px",children:[(0,f.jsx)(s.o,{width:"100%",children:(0,f.jsx)(wt.c,{color:"blackAlpha.500",size:"1px",width:"20%"})}),(0,f.jsxs)(j.E,{as:"b",fontSize:1.2*d+"px",sx:{color:p+" !important",fontFamily:m+" !important"},align:"center",marginY:"2px",children:["\xa0",e[0].type,"\xa0"]}),(0,f.jsx)(jt.s,{gap:"6px",wrap:"wrap",justify:"center",paddingY:"2px",children:e.map(((e,n)=>{var r,l,a,s,u,h,p,v;return(0==i||(null===x||void 0===x||null===(r=x.variants)||void 0===r?void 0:r.find((t=>t[`option${i}`]==(null===z||void 0===z?void 0:z[i-1])&&t[`option${i+1}`]==(null===e||void 0===e?void 0:e.option)))))&&(0,f.jsxs)(c.az,{onClick:t=>{t.stopPropagation(),e.available&&function(t,e){if(2==e)E([z[0],z[1],t]);else if(1==e){var i,n;E([z[0],t,null===x||void 0===x||null===(i=x.variants)||void 0===i||null===(n=i.find((e=>(null===e||void 0===e?void 0:e.option2)==t)))||void 0===n?void 0:n.option3])}else{var o,r,l,a,d,s;const e=null===x||void 0===x||null===(o=x.variants)||void 0===o||null===(r=o.find((e=>(null===e||void 0===e?void 0:e.option1)==t)))||void 0===r?void 0:r.option2;E([t,null===x||void 0===x||null===(l=x.variants)||void 0===l||null===(a=l.find((e=>(null===e||void 0===e?void 0:e.option1)==t)))||void 0===a?void 0:a.option2,null===x||void 0===x||null===(d=x.variants)||void 0===d||null===(s=d.find((t=>(null===t||void 0===t?void 0:t.option2)==e)))||void 0===s?void 0:s.option3])}}(e.option,i)},backgroundColor:e.option===z[i]?"rgba(0, 0, 0, 0.7)":"white",border:e.option===z[i]?"1px solid #ffffff":"1px solid black",cursor:"pointer",display:"flex",alignItems:"center",justifyContent:"center",boxShadow:e.option===z[i]?"0 0 8px rgba(0, 0, 0, 0.8)":"none",marginY:"2px",width:"fit-content",padding:o?"0px":"8px",borderRadius:o?"50%":"0",children:[!o&&(0,f.jsxs)(j.E,{as:e.available?"samp":"s",fontSize:.8*d+"px",sx:{color:e.option===z[i]?"white":(e.available?"black":"gray")+" !important",fontFamily:m+" !important"},align:"center",paddingX:(g=e.option,g.length>=3?"0px":.5*d+"px"),children:["\xa0",e.option,"\xa0"]}),o&&(0,f.jsx)(y._,{width:"58px",height:"58px",style:{cursor:null!==e&&void 0!==e&&e.available?"pointer":"not-allowed",opacity:null!==e&&void 0!==e&&e.available?1:.5,filter:null!==e&&void 0!==e&&e.available?"none":"grayscale(100%)",borderRadius:o?"50%":"100%"},src:(0,yt.b)(null!==(l=null===t||void 0===t||null===(a=t.finalArr)||void 0===a||null===(s=a.finalArr)||void 0===s||null===(u=s.find((t=>(null===t||void 0===t?void 0:t.color)==(null===e||void 0===e?void 0:e.option))))||void 0===u?void 0:u.src)&&void 0!==l?l:null===t||void 0===t||null===(h=t.finalArr)||void 0===h||null===(p=h.finalArrExternal)||void 0===p||null===(v=p.find((t=>(null===t||void 0===t?void 0:t.color)==(null===e||void 0===e?void 0:e.option))))||void 0===v?void 0:v.optionsrc,"?width=400&height=400")})]},n);var g}))},i)]},i)}))})},Ct=i(6594),St=i(4833);var kt=function(t){var e,i,o,r,a,d;const[s]=(0,v.QN)("isInDesignMode"),[h]=(0,v.QN)("isDemoBrand"),[g]=(0,v.QN)("whatmoreSecondaryColor"),w=(0,v.Xd)("whatmoreSecondaryColorShade900"),[b]=(0,v.QN)("whatmorePrimaryFont"),[C]=(0,v.QN)("whatmoreShopId"),[S,k,I,_]=(0,x.A)(),[z,E]=(0,n.useState)(!1),[T,N]=(0,n.useState)(t.product),F=(0,v.Xd)("whatmoreUITheme"),{whatmoreWidgetSourceDetails:A}=(0,n.useContext)($.B),[P,L,B,O,D,R,W,Q]=ft(0,T,t.event),[V,q]=(0,n.useState)(null),[J,tt]=(0,n.useState)(parseFloat(T.price)),[ot,rt]=(0,n.useState)(parseFloat(T.compare_price)),[lt,at]=(0,n.useState)(null===T||void 0===T?void 0:T.title),[dt,ct]=(0,n.useState)(T.currency),[ut,ht]=(0,n.useState)(null),pt=t.event,vt=t.productClickHandler,{whatmoreIsPreviewMode:xt}=(0,n.useContext)($.B),[mt,gt]=(0,n.useState)(null),[wt,jt]=(0,n.useState)(!1),[kt,It]=(0,n.useState)(!1);if((0,n.useEffect)((()=>{(0,p.w4b)(C)?(0,Ct.ck)(T,(0,p.NCy)(C),C).then((t=>{N(t),tt(parseFloat(t.price)),rt(parseFloat(t.compare_price)),ct(t.currency),jt(!0)})).catch((t=>{jt(!0)})):(async()=>{try{var t,e,i,n,o,r;const l=await(0,m.M)(T,(0,p.NCy)(C),C);ht(l),tt((null!==(t=null===l||void 0===l||null===(e=l.variants)||void 0===e||null===(i=e[0])||void 0===i?void 0:i.price)&&void 0!==t?t:null===l||void 0===l?void 0:l.price)/100),rt((null!==(n=null===l||void 0===l||null===(o=l.variants)||void 0===o||null===(r=o[0])||void 0===r?void 0:r.compare_at_price)&&void 0!==n?n:null===l||void 0===l?void 0:l.compare_at_price)/100),jt(!0)}catch(l){jt(!0)}})(),!(0,p.E8r)(C)||!("in_stock"in pt)||null!==pt&&void 0!==pt&&pt.in_stock||B("errored")}),[]),(0,n.useEffect)((()=>{var t,e;const i=null!=ut?null===ut||void 0===ut||null===(t=ut.options)||void 0===t?void 0:t.findIndex((t=>{var e;return"Colour"==(null===t||void 0===t?void 0:t.name)||(null===t||void 0===t||null===(e=t.name)||void 0===e?void 0:e.toLowerCase().includes("color"))})):-1,n=-1!==i?null===ut||void 0===ut||null===(e=ut.variants)||void 0===e?void 0:e.map((t=>{var e,n;const o=null===t||void 0===t?void 0:t[`option${i+1}`];return null!==t&&void 0!==t&&null!==(e=t.featured_image)&&void 0!==e&&e.src?{color:o,src:null===t||void 0===t||null===(n=t.featured_image)||void 0===n?void 0:n.src}:null})):[];let o=[];var r;-1!==i&&(o=null===ut||void 0===ut||null===(r=ut.images)||void 0===r?void 0:r.map((t=>({color:t.color,src:t.src,optionsrc:t.optionsrc}))));gt({position:i,finalArr:n,finalArrExternal:o})}),[ut]),!wt)return(0,f.jsx)(f.Fragment,{});var _t=.68*_,zt=.55*_t,Et=.4*_t,Tt=_t*(.55-.4),Nt=_t+"px",Ft=Et+"px",At=Tt+"px",Pt=.12*Et;const Lt=(0,p.XQu)(C);function Bt(){window.location.href=function(t){return(0,p.BLb)(C)?t.product_link+"?"+(0,p.VCz)(C)+"&"+(0,p.Spk)(C)+"&"+(0,p.$lz)(C):t.product_link}(T)}const Ot=A.landingLocationType,Dt=A.templateType,Rt=(0,St.Wd)(Ot)+(0,St.gf)(Dt)+(null!==pt&&void 0!==pt&&pt.isRelatedEvent?"R":"E")+"_"+(null===pt||void 0===pt?void 0:pt.event_id),Wt=(0,p.HKH)(C)&&t.activeProductsCount>1&&"init"==P.state&&0==P.cart_count;return(0,f.jsxs)(u.B,{direction:"column",justifyContent:"flex-start",alignContent:"center",marginTop:U,marginBottom:(0,p.qw1)(C),width:Nt,height:"fit-content",boxShadow:"round"==F?"dark-lg":null,onClick:()=>{!function(t,e){s||h||(async()=>{(0,l.Pb)(t,e)})(),"72550089015"==C?Bt():vt(e),E(!0)}(pt,T)},backgroundColor:(0,H.YU)("#ffffff",(0,p.p2R)(C)),animation:z?M.jd:M.so,borderRadius:"round"==F?"xl":null,overflow:"hidden",spacing:0,sx:{borderWidth:(0,p.YcK)(C),borderColor:(0,p.Fwt)(C)},children:[(0,f.jsxs)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-start",alignContent:"center",cursor:"pointer",children:[(0,f.jsx)(c.az,{height:Ft,width:Ft,children:(0,f.jsx)(y._,{className:"product-tile-image",width:Ft,height:Ft,src:(0,yt.b)(null!==(e=null!==(i=null===mt||void 0===mt||null===(o=mt.finalArr)||void 0===o||null===(r=o.find((t=>(null===t||void 0===t?void 0:t.color)==(null===V||void 0===V?void 0:V[null===mt||void 0===mt?void 0:mt.position]))))||void 0===r?void 0:r.src)&&void 0!==i?i:null===mt||void 0===mt||null===(a=mt.finalArrExternal)||void 0===a||null===(d=a.find((t=>(null===t||void 0===t?void 0:t.color)==(null===V||void 0===V?void 0:V[null===mt||void 0===mt?void 0:mt.position]))))||void 0===d?void 0:d.src)&&void 0!==e?e:T.thumbnail_image,"&width=400&height=400"),sx:{objectFit:(0,p.KZe)(C)+" !important"}})}),(0,f.jsxs)(c.az,{height:Ft,width:_t-Et+"px",children:[(0,f.jsxs)(u.B,{direction:"column",className:"wht-pr-title",justifyContent:(0,p.UlM)(C)?"flex-end":"center",alignContent:"center",width:"fit-content",height:"100%",paddingX:"4px",paddingY:"10px",children:[(0,f.jsx)("p",{ref:t=>{t&&(t.style.setProperty("color",(0,p.uoB)(C),"important"),t.style.setProperty("font-size",1.1*Pt*(0,p.rh$)(C)+"px","important"),t.style.setProperty("line-height","120%","important"),t.style.setProperty("font-family",b,"important"),t.style.setProperty("-webkit-line-clamp",2,"important"),t.style.setProperty("line-clamp",2,"important"),t.style.setProperty("-webkit-box-orient","vertical","important"),t.style.setProperty("display","-webkit-box","important"),t.style.setProperty("overflow","hidden","important"),t.style.setProperty("text-overflow","ellipsis","important"),t.style.setProperty("padding","0","important"),t.style.setProperty("margin-bottom","4px","important"),t.style.setProperty("font-weight","normal"))},children:(0,G.v)(lt,"prod-tile")}),(0,p.Nzx)(C)?(0,f.jsxs)(u.B,{className:"whatmore-product-atc-price",direction:(0,p.vw2)(C)?"row":"row-reverse",width:"fit-content",height:"fit-content",justifyContent:"flex-start",alignContent:"center",borderRadius:"round"==F?"lg":null,backgroundColor:"white",paddingX:"8px",paddingY:"4px",sx:{margin:"0px !important",marginBottom:"4px !important"},children:[wt&&(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*Pt*(0,p.rh$)(C)+"px !important",fontWeight:"semibold",lineHeight:"100%",textAlign:"center",sx:{fontFamily:b+" !important",color:(0,p.uoB)(C)+" !important",padding:"0px !important",letterSpacing:"normal !important",margin:"0px !important"},children:["\xa0"," "+(0,Ct.Sb)(null!==J&&void 0!==J?J:null===T||void 0===T?void 0:T.price,"",C,dt)," \xa0"]}),(0,Z.P)(J,ot)&&wt?(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*Pt*(0,p.rh$)(C)+"px !important",fontWeight:"medium !important",lineHeight:"100%",textAlign:"center",sx:{fontFamily:b+" !important",color:(0,p.gld)(C)+" !important",margin:"0px !important",letterSpacing:"normal !important",textDecoration:"line-through !important"},children:[" ",(0,Ct.Sb)(null!==ot&&void 0!==ot?ot:null===T||void 0===T?void 0:T.compare_price,"",C,dt)]}):(0,f.jsx)(f.Fragment,{})]}):(0,f.jsx)(f.Fragment,{}),(0,f.jsx)(j.E,{fontSize:.82*Pt*(0,p.rh$)(C)+"px",fontWeight:"medium",lineHeight:"110%",sx:{margin:"0px !important",fontFamily:b+" !important",color:(0,p.Br1)(C)+" !important"},children:xt?(0,p.p6A)(C):(0,p.i2h)(C)})]}),(0,p.UlM)(C)?(0,f.jsx)(u.B,{className:"whatmore-ios-css-relative-fix",style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:"flex-start",height:"100%",width:"100%",children:(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"fit-content",justifyContent:"flex-end",alignItems:"center",marginTop:"5px",backgroundColor:"transparent",children:[(0,f.jsx)(u.B,{direction:"row",width:"fit-content",height:"fit-content",justifyContent:"center",alignItems:"center",backgroundColor:w,sx:{borderRadius:"round"==F?"5px":"0px",padding:"2px"},spacing:"0px",children:(0,p.SK$)(C)?(0,f.jsx)(nt.$,{size:"sm",_hover:{bg:g},sx:{bg:g},children:(0,f.jsx)(j.E,{color:"white",paddingX:"6px",fontSize:.8*Pt+"px",children:"VIEW PRODUCT"})}):(0,f.jsx)(K.A,{sx:{color:g,fontSize:1.3*Pt+"px"}})}),(0,f.jsx)(c.az,{width:"2px"})]})}):(0,f.jsx)(f.Fragment,{})]})]}),(0,f.jsx)(et.s,{unmountOnExit:!0,initialScale:.5,in:"awaitingVariantSelection"==P.state,style:{height:"fit-content",width:"100%"},children:"awaitingVariantSelection"==P.state&&null!=O?(0,f.jsx)(c.az,{width:"100%",height:"fit-content",marginTop:.1*zt+"px",marginBottom:.1*zt+"px",overflowY:"auto",overflowX:"hidden",maxHeight:zt*Lt+"px",overscrollBehavior:"contain",onTouchStart:t=>{t.stopPropagation()},onTouchEnd:t=>{t.stopPropagation()},children:(0,f.jsx)(bt,{maxHeight:zt*Lt*.5+"px",width:Nt,height:"fit-content",event:pt,product:T,finalArr:mt,data:ut,productVariantOptions:O,baseFontSize:1.2*Pt,onOptionSelected:t=>{!function(t){q(t);const e=W(t);e&&(tt(e.price),rt(e.compare_price),e.title.includes(" ")&&at(e.title))}(t)}})}):(0,f.jsx)(f.Fragment,{})}),(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:At,spacing:0,children:[(0,f.jsx)(u.B,{className:"whatmore-add-to-cart",direction:"row",width:"100%",height:At,children:(0,f.jsx)(st,{baseFontSize:Wt?.2*Tt:.3*Tt,setProductVariantTitle:at,product:T,cartState:P.state,cartCount:P.cart_count,updateCartState:B,onClickAtc:t=>{"init"==P.state?(D(Rt),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_ATC_CLICKED,widgetSourceDetails:A,event:pt,productList:[T],ctaList:pt.cta})):"awaitingVariantSelection"==P.state&&(R(V,Rt),at(null===T||void 0===T?void 0:T.title))},onCartIconClick:()=>{Q()}})}),Wt&&(0,f.jsx)(u.B,{width:"100%",className:"wht-all-atc",sx:{fontSize:.28*Tt,flexDirection:"row",height:"100%",justifyContent:"center",alignItems:"center",bg:"white"},children:(0,f.jsx)(nt.$,{disabled:kt,sx:{cursor:"pointer",width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center",fontFamily:`${b} !important`,color:"black"},onClick:async t=>{t.stopPropagation();try{It(!0),L(Rt),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_ALL_ATC_CLICKED,widgetSourceDetails:A,event:pt,productList:pt.products,ctaList:pt.cta}),It(!1)}catch(e){console.error("Failed to add items:",e),It(!1)}},children:kt?(0,f.jsx)("div",{className:"whatmore-rotate-indefinitely",children:(0,f.jsx)(it.A,{sx:{filter:"drop-shadow(0 0 15px black)",color:"#F5F5F5",fontSize:.3*Tt*2.5+"px"}})}):(0,f.jsx)(j.E,{fontFamily:b,children:"ADD ALL ITEMS"})})})]})]})},It=i(2835),_t=i(8397);var zt=function(t){var e,i,n,o,r;const[a]=(0,v.QN)("isInDesignMode"),[d]=(0,v.QN)("isDemoBrand"),[h]=(0,v.QN)("whatmoreSecondaryColor"),[x]=(0,v.QN)("whatmorePrimaryFont"),[m]=(0,v.QN)("whatmoreShopId"),[g]=(0,v.QN)("websiteLanguage"),w=t.event,y=t.product,b=null!==(e=t.baseFontSize)&&void 0!==e?e:10,C=null!==(i=t.width)&&void 0!==i?i:"fit-content",S=null!==(n=t.height)&&void 0!==n?n:"fit-content";return(0,f.jsx)(_t.N,{href:y.product_link,color:h,onClick:()=>{!function(t,e){a||d||(async()=>{(0,l.TJ)(t,e)})()}(w,y)},children:(0,f.jsx)(c.az,{width:C,height:S,padding:"2x",boxShadow:"lg",borderRadius:"md",backgroundColor:"white",children:(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"5px",spacing:"5px",children:[(0,f.jsx)(s.o,{children:(0,f.jsx)(j.E,{lineHeight:"100%",fontSize:1.4*b,fontWeight:"semibold",sx:{fontFamily:x+" !important",color:h+" !important"},children:"MORE INFO"!=(0,p.KnH)(m)?(0,p.KnH)(m):null!==(o=null===ot||void 0===ot||null===(r=ot[g])||void 0===r?void 0:r.more_info)&&void 0!==o?o:(0,p.KnH)(m)})}),(0,f.jsx)(s.o,{children:(0,f.jsx)(K.A,{sx:{color:h,fontSize:1.4*b}})})]})})})},Et=i(9408);function Tt(t){var e;const[i]=(0,v.QN)("whatmoreSecondaryColor"),[o]=(0,v.QN)("whatmorePrimaryFont"),[r]=(0,v.QN)("whatmoreShopId"),[l,a]=(0,n.useState)(!1),d=(t.event,t.product,null!==(e=t.baseFontSize)&&void 0!==e?e:10),s=t.onClick,h=t.width,x=t.height,m=t.title;return(0,f.jsx)(c.az,{width:h,height:x,padding:"2x",boxShadow:"lg",backgroundColor:"#000000"==(0,p.Wc_)(r)?i:(0,p.Wc_)(r),onClick:t=>{t.stopPropagation(),s(),a(!0)},animation:l?M.jd:null,onAnimationEnd:()=>{a(!1)},cursor:"pointer",children:(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"2px",children:(0,f.jsxs)(j.E,{as:"p",ref:t=>{t&&t.style.setProperty("min-height","0","important")},lineHeight:"100%",fontSize:1.4*d+"px",fontWeight:"semibold",sx:{fontFamily:o+" !important",color:(0,p.Hfu)(r)+" !important"},children:["\xa0",m,"\xa0"]})})})}var Nt=function(t){var e,i,n;const[o]=(0,v.QN)("whatmoreShopId"),r=t.event,l=t.product,a=null!==(e=t.baseFontSize)&&void 0!==e?e:10,d=t.onShopNowClick,s=null!==(i=t.width)&&void 0!==i?i:"100%",c=null!==(n=t.height)&&void 0!==n?n:"100%";return(0,f.jsx)(Tt,{onClick:function(){d()},event:r,product:l,baseFontSize:a,width:s,height:c,title:(0,p.Qed)(o)})};var Ft=function(t){var e;const[i]=(0,v.QN)("isInDesignMode"),[o]=(0,v.QN)("isDemoBrand"),[r]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,h,g,w]=(0,x.A)(),[b,C]=(0,n.useState)(!1),[S,k]=(0,n.useState)(t.product),{whatmoreWidgetSourceDetails:I}=(0,n.useContext)($.B),[_,z,E,T,N,F,A,P]=ft(0,S,t.event),[L,B]=(0,n.useState)(null),[O,D]=(0,n.useState)(parseFloat(S.price)),[R,W]=(0,n.useState)(parseFloat(S.compare_price)),[Q,V]=(0,n.useState)(S.currency),[H,q]=(0,n.useState)(!1),K=t.event,J=t.productClickHandler,tt=null!==(e=t.tileWidthFactor)&&void 0!==e?e:1,it=I.landingLocationType,nt=I.templateType,ot=(0,St.Wd)(it)+(0,St.gf)(nt)+(null!==K&&void 0!==K&&K.isRelatedEvent?"R":"E")+"_"+(null===K||void 0===K?void 0:K.event_id);(0,n.useEffect)((()=>{(0,p.w4b)(a)?(0,Ct.ck)(S,(0,p.NCy)(a),a).then((t=>{k(t),D(parseFloat(t.price)),W(parseFloat(t.compare_price)),V(t.currency)})):(async()=>{const t=await(0,m.M)(S,(0,p.NCy)(a),a);D(null===t||void 0===t?void 0:t.price),W(null===t||void 0===t?void 0:t.compare_at_price),q(!0)})()}),[]);var rt=w*tt,lt=.3*rt,at=rt+"px",dt=.7*lt,ct=.9*dt,ut=.12*lt;const ht=(0,p.XQu)(a);function pt(t,e){i||o||(async()=>{(0,l.Pb)(t,e)})(),J(e),C(!0)}return(0,f.jsx)(u.B,{direction:"row",width:at,height:"fit-content",justifyContent:"center",children:(0,f.jsx)(c.az,{marginTop:U,marginBottom:(0,p.qw1)(a),width:at,onClick:t=>{},animation:b?M.jd:null,borderRadius:"lg",onAnimationEnd:()=>{C(!1)},children:(0,f.jsxs)(u.B,{direction:"column",width:"100%",height:"100%",justifyContent:"center",alignItems:"center",spacing:"0px",children:[(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"70%",justifyContent:"space-around",alignItems:"center",borderTopRadius:"lg",overflow:"hidden",onClick:()=>{pt(K,S)},children:[(0,f.jsx)(c.az,{height:dt+"px",width:dt+"px",children:(0,f.jsx)(u.B,{direction:"column",justifyContent:"center",alignItems:"center",height:"100%",width:"100%",children:(0,f.jsx)(c.az,{height:ct+"px",width:ct+"px",borderRadius:"lg",bgColor:"gray.100",overflow:"hidden",children:(0,f.jsx)(y._,{width:ct+"px",height:ct+"px",src:S.thumbnail_image,objectFit:"cover"})})})}),(0,f.jsx)(c.az,{height:dt+"px",width:rt-dt+"px",children:(0,f.jsxs)(u.B,{direction:"column",justifyContent:"space-between",alignContent:"center",width:"fit-content",height:"100%",paddingX:"10px",paddingY:"10px",spacing:"2px",children:[(0,f.jsx)(j.E,{style:{overflow:"hidden",textOverflow:"ellipsis"},noOfLines:1,fontSize:1.2*ut+"px",fontWeight:"medium",lineHeight:"120%",sx:{fontFamily:r+" !important",color:"white !important"},children:(0,G.v)(S.title.toString())}),(0,f.jsxs)(u.B,{direction:"row",width:"fit-content",height:"fit-content",justifyContent:"center",alignItems:"center",marginTop:"5px",children:[(0,p.Nzx)(a)?(0,f.jsxs)(u.B,{direction:"row",width:"fit-content",height:"fit-content",justifyContent:"flex-start",alignItems:"center",borderRadius:"lg",backgroundColor:"blackAlpha.500",paddingX:"10px",paddingY:"5px",children:[H&&(0,f.jsxs)(j.E,{noOfLines:1,fontSize:1*ut+"px",fontWeight:"semibold",lineHeight:"100%",textAlign:"center",sx:{fontFamily:r+" !important",color:"white !important"},children:["\xa0"," "+(0,Ct.Sb)(null!==O&&void 0!==O?O:null===S||void 0===S?void 0:S.price,"",a,Q)," \xa0"]}),(0,f.jsx)(s.o,{children:(0,Z.P)(S.price,S.compare_price)&&H?(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.8*ut+"px",fontWeight:"medium",lineHeight:"100%",textAlign:"center",sx:{fontFamily:r+" !important",color:"#F9F6EE !important",textDecoration:"line-through !important"},children:[" ",(0,Ct.Sb)(null!==R&&void 0!==R?R:null===S||void 0===S?void 0:S.compare_price,"",a,Q)]}):(0,f.jsx)(f.Fragment,{})})]}):(0,f.jsx)(f.Fragment,{}),(0,f.jsx)(s.o,{children:(0,f.jsx)(It.A,{storeId:a,productId:S.client_product_id,productLink:S.product_link,fontSize:1*ut,fontColor:"white"})})]})]})})]}),(0,f.jsx)(et.s,{unmountOnExit:!0,initialScale:.5,in:"awaitingVariantSelection"==_.state,style:{height:"fit-content",width:"100%"},children:"awaitingVariantSelection"==_.state&&null!=T?(0,f.jsx)(c.az,{width:"100%",height:"fit-content",marginTop:.1*lt+"px",marginBottom:.1*lt+"px",overflowY:"auto",overflowX:"hidden",maxHeight:lt*ht+"px",overscrollBehavior:"contain",onTouchStart:t=>{t.stopPropagation()},onTouchEnd:t=>{t.stopPropagation()},children:(0,f.jsx)(bt,{width:at,height:"fit-content",event:K,product:S,productVariantOptions:T,baseFontSize:1*ut,onOptionSelected:t=>{!function(t){B(t);const e=A(t);e&&(D(e.price),W(e.compare_price))}(t)},optionTitleColor:"white"})}):(0,f.jsx)(f.Fragment,{})}),(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"30%",justifyContent:"center",alignItems:"center",paddingBottom:"2px",paddingLeft:"2px",paddingRight:"2px",children:[(0,f.jsx)(c.az,{width:"100%",height:"100%",children:(0,f.jsx)(zt,{baseFontSize:.8*ut,event:K,product:S,width:"100%",height:"100%"})}),(0,f.jsx)(c.az,{width:"100%",height:"100%",borderRadius:"md",overflow:"hidden",children:(0,p.ZzM)(a)?(0,f.jsx)(Nt,{baseFontSize:.8*ut,event:K,product:S,borderRadius:"md",onShopNowClick:t=>{pt(K,S)}}):(0,f.jsx)(f.Fragment,{children:"form"===(0,p.nWM)(a)?(0,f.jsx)(Et.default,{baseFontSize:.8*ut,event:K,product:S,width:"100%",height:"100%",showAddedToCart:!0}):(0,f.jsx)(st,{baseFontSize:.8*ut,event:K,product:S,cartState:_.state,cartCount:_.cart_count,borderRadius:"md",onClickAtc:t=>{"init"==_.state?(N(ot),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_ATC_CLICKED,widgetSourceDetails:I,event:K,productList:[S],ctaList:K.cta})):"awaitingVariantSelection"==_.state&&F(L,ot)},onCartIconClick:()=>{P()}})})})]})]})})})},At=i(7740);var Pt=function(t){const[e]=(0,v.QN)("isInDesignMode"),[i]=(0,v.QN)("isDemoBrand"),[o]=(0,v.QN)("whatmoreSecondaryColor"),r=(0,v.Xd)("whatmoreSecondaryColorShade900"),[a]=(0,v.QN)("whatmorePrimaryFont"),[d]=(0,v.QN)("whatmoreShopId"),[s,h,g,w]=(0,x.A)(),[b,C]=(0,n.useState)(!1),[S,k]=(0,n.useState)(t.product),I=(0,v.Xd)("whatmoreUITheme"),[_,z]=(0,n.useState)(!1),[E,T]=(0,n.useState)(parseFloat(S.price)),[N,F]=(0,n.useState)(parseFloat(S.compare_price)),[A,P]=(0,n.useState)(S.currency),L=t.event,[B,O]=(0,n.useState)();if((0,n.useEffect)((()=>{(0,p.w4b)(d)?(0,Ct.ck)(S,(0,p.NCy)(d),d).then((t=>{k(t),T(parseFloat(t.price)),F(parseFloat(t.compare_price)),P(t.currency),z(!0)})).catch((t=>z(!0))):(async()=>{try{var t,e,i,n,o,r;const l=await(0,m.M)(S,(0,p.NCy)(d),d);O(l),T((null!==(t=null===l||void 0===l||null===(e=l.variants)||void 0===e||null===(i=e[0])||void 0===i?void 0:i.price)&&void 0!==t?t:null===l||void 0===l?void 0:l.price)/100),F((null!==(n=null===l||void 0===l||null===(o=l.variants)||void 0===o||null===(r=o[0])||void 0===r?void 0:r.compare_at_price)&&void 0!==n?n:null===l||void 0===l?void 0:l.compare_at_price)/100),z(!0)}catch(l){z(!0)}})()}),[]),!_)return(0,f.jsx)(f.Fragment,{});var D=.68*w,R=.4*D,W=D+"px",Q=R+"px",V=D*(.55-.4)+"px",q=.12*R;(0,p.XQu)(d);const{whatmoreWidgetSourceDetails:J}=(0,n.useContext)($.B);function tt(t){return(0,p.BLb)(d)?t.product_link+"?"+(0,p.VCz)(d)+"&"+(0,p.Spk)(d)+"&"+(0,p.$lz)(d):t.product_link}function et(t,n){e||i||(async()=>{(0,l.Pb)(t,n),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_SHOPNOW_CLICKED,widgetSourceDetails:J,event:t,productList:[n],ctaList:t.cta})})(),C(!0)}return(0,f.jsxs)(u.B,{direction:"column",justifyContent:"flex-start",alignContent:"center",marginTop:U,marginBottom:(0,p.qw1)(d),width:W,height:"fit-content",boxShadow:"round"==I?"dark-lg":null,onClick:()=>{et(L,S),window.location.href=tt(S)},backgroundColor:(0,H.YU)("#ffffff",(0,p.p2R)(d)),animation:b?M.jd:M.so,borderRadius:"round"==I?"xl":null,overflow:"hidden",spacing:0,sx:{borderWidth:(0,p.YcK)(d),borderColor:(0,p.Fwt)(d)},children:[(0,f.jsxs)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-start",alignContent:"center",cursor:"pointer",children:[(0,f.jsx)(c.az,{height:Q,width:Q,children:(0,f.jsx)(y._,{width:Q,height:Q,src:(0,yt.b)(S.thumbnail_image,"&width=400&height=400"),sx:{objectFit:(0,p.KZe)(d)+" !important"}})}),(0,f.jsxs)(c.az,{height:Q,width:D-R+"px",children:[(0,f.jsxs)(u.B,{direction:"column",justifyContent:(0,p.UlM)(d)?"flex-end":"center",alignContent:"center",width:"fit-content",height:"100%",paddingX:"10px",paddingTop:"10px",paddingBottom:"16px",children:[(0,f.jsx)(j.E,{as:"p",ref:t=>{t&&(t.style.setProperty("min-height","0","important"),t.style.setProperty("-webkit-line-clamp",2,"important"),t.style.setProperty("line-clamp",2,"important"),t.style.setProperty("overflow","hidden","important"),t.style.setProperty("display","-webkit-box","important"),t.style.setProperty("-webkit-box-orient","vertical","important"))},sx:{paddingLeft:"8px",fontFamily:a+" !important",color:"black !important",lineHeight:"120% !important",fontWeight:"medium !important",fontSize:1.1*q+"px !important"},children:(0,G.v)(null==S.title?"":S.title.toString(),"prod-tile")}),(0,p.Nzx)(d)?(0,f.jsxs)(u.B,{className:"whatmore-product-shopnow-price",direction:(0,p.vw2)(d)?"row":"row-reverse",width:"fit-content",height:"fit-content",justifyContent:"flex-start",alignContent:"center",marginTop:"5px",borderRadius:"round"==I?"lg":null,backgroundColor:"white",paddingX:"8px",paddingY:"5px",children:[_&&(0,f.jsxs)(j.E,{as:"p",ref:t=>{t&&t.style.setProperty("min-height","0","important")},noOfLines:1,fontSize:.9*q+"px",fontWeight:"semibold",lineHeight:"100%",textAlign:"center",sx:{fontFamily:a+" !important",color:(0,p.uoB)(d)+" !important",margin:"0px !important"},children:[" "+(0,Ct.Sb)(null!==E&&void 0!==E?E:null===S||void 0===S?void 0:S.price,"",d,A)," \xa0"]}),(0,Z.P)(E,N)&&_?(0,f.jsxs)(j.E,{as:"s",style:{minHeight:0,textDecoration:"line-through"},noOfLines:1,fontSize:.9*q+"px",fontWeight:"medium",lineHeight:"100%",textAlign:"center",sx:{fontFamily:a+" !important",color:(0,p.gld)(d)+" !important",margin:"0px !important"},children:[" ",(0,Ct.Sb)(null!==N&&void 0!==N?N:null===S||void 0===S?void 0:S.compare_price,"",d,A)]}):(0,f.jsx)(f.Fragment,{})]}):(0,f.jsx)(f.Fragment,{}),""!=(0,p.rsz)(d)&&(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*q+"px",lineHeight:"100%",paddingTop:"6px",sx:{fontFamily:(0,p.ogW)(d)+" !important",color:(0,p._zx)(d)+" !important",margin:"0px !important"},children:["\xa0",(0,p.rsz)(d)," \xa0"]})]}),(0,p.UlM)(d)?(0,f.jsx)(u.B,{className:"whatmore-ios-css-relative-fix",style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:"flex-start",height:"100%",width:"100%",children:(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"fit-content",justifyContent:"flex-end",alignItems:"center",marginTop:"5px",backgroundColor:"transparent",children:[(0,f.jsx)(u.B,{direction:"row",width:"fit-content",height:"fit-content",justifyContent:"center",alignItems:"center",backgroundColor:r,sx:{borderRadius:"round"==I?"5px":"0px",padding:"2px"},spacing:"0px",children:(0,f.jsx)(K.A,{sx:{color:o,fontSize:1.3*q+"px"}})}),(0,f.jsx)(c.az,{width:"2px"})]})}):(0,f.jsx)(f.Fragment,{})]})]}),(0,p.Woi)(d)&&(0,f.jsx)(u.B,{direction:"row",width:"100%",height:V,justifyContent:"center",alignItems:"center",children:(0,f.jsx)(Nt,{baseFontSize:.8*q,event:L,product:S,borderRadius:"md",onShopNowClick:t=>{et(L,S),window.location.href=tt(S)}})})]})};function Lt(t){var e;const[i]=(0,v.QN)("whatmoreSecondaryColor"),[o]=(0,v.QN)("whatmorePrimaryFont"),[r]=(0,v.QN)("whatmoreShopId"),[l,a]=(0,n.useState)(!1),d=null!==(e=t.baseFontSize)&&void 0!==e?e:10,s=t.onClick,h=t.width,x=t.height,m=t.title,g=t.showInProgressIcon;return"awaitingVariantSelection"==t.cartState||"productVariantDetailsApiCallInProgress"==t.cartState?(0,f.jsx)(Bt,{onClick:()=>t.onClick(),event:t.event,product:t.product,baseFontSize:d,width:h,height:x}):(0,f.jsxs)(c.az,{display:"flex",width:"fit-content",minWidth:"75%",padding:"2x",boxShadow:"lg",animation:l?M.jd:null,onAnimationEnd:()=>{a(!1)},cursor:"pointer",children:["awaitingVariantSelection"==t.cartState&&(0,f.jsx)(u.B,{direction:"row",alignItems:"center",justifyContent:"center",paddingY:"2px",backgroundColor:"white",onClick:e=>{e.stopPropagation(),t.updateCartState("init"),a(!0)},children:(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*d+"px !important",fontWeight:"semibold !important",sx:{fontFamily:o+" !important",color:"#343434 !important"},children:["\xa0","63064310011"==r?"Annuler":"Cancel","\xa0"]})}),(0,f.jsxs)(u.B,{direction:"row",backgroundColor:g?(0,H.YU)(i,8):i,width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"2px",onClick:t=>{t.stopPropagation(),s(),a(!0)},children:[(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*d+"px !important",fontWeight:"semibold !important",sx:{fontFamily:o+" !important",color:(0,p.Hfu)(r)+" !important"},children:["\xa0",m,"\xa0"]}),g?(0,f.jsx)("div",{className:"whatmore-rotate-indefinitely",children:(0,f.jsx)(it.A,{sx:{filter:"drop-shadow(0 0 15px black);",color:"#F5F5F5",fontSize:2.5*d+"px"}})}):(0,f.jsx)(f.Fragment,{})]})]})}function Bt(t){const[e]=(0,v.QN)("whatmoreSecondaryColor"),[i]=(0,v.QN)("whatmorePrimaryFont"),[o]=(0,v.QN)("whatmoreShopId"),[r,l]=(0,n.useState)(!1),a=t.onClick,d=t.baseFontSize;return(0,f.jsx)(u.B,{direction:"row",paddingBottom:"3%",position:"relative",children:(0,f.jsx)(c.az,{width:"fit-content",minWidth:"75%",boxShadow:"lg",padding:"6px 12px",borderRadius:"6px",backgroundColor:e,onClick:t=>{t.stopPropagation(),a(),l(!0)},animation:r?M.jd:null,onAnimationEnd:()=>{l(!1)},cursor:"pointer",zIndex:"1000",children:(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"5px",children:(0,f.jsx)(s.o,{children:(0,f.jsx)(j.E,{lineHeight:"100%",fontSize:1.3*d+"px",fontWeight:"semibold",sx:{fontFamily:`${i} !important`,color:`${(0,p.Hfu)(o)} !important`},children:(0,p.KPq)(o)})})})})})}function Ot(t){var e;const[i]=(0,v.QN)("whatmorePrimaryFont"),n=null!==(e=t.baseFontSize)&&void 0!==e?e:10;t.width,t.height;return(0,f.jsx)(c.az,{width:"fit-content",height:"fit-content !important",minWidth:"75%",boxShadow:"lg",backgroundColor:"white",borderRadius:"6px",borderColor:"gray",borderWidth:"1px",onClick:t=>{t.stopPropagation()},children:(0,f.jsx)(u.B,{direction:"row",width:"100%",alignItems:"center",paddingX:"4px",paddingY:"3px",justifyContent:"center",children:(0,f.jsxs)(j.E,{color:"gray",lineHeight:"100%",fontSize:1.2*n+"px !important",fontWeight:"semibold !important",sx:{fontFamily:i+" !important",color:"gray !important"},children:["\xa0"," Sold Out ","\xa0"]})})})}function Dt(t){var e;const[i]=(0,v.QN)("whatmoreSecondaryColor"),[n]=(0,v.QN)("whatmorePrimaryFont"),[o]=(0,v.QN)("whatmoreShopId"),r=(t.event,t.product,null!==(e=t.baseFontSize)&&void 0!==e?e:10),l=t.onClick,a=t.cartCount,d=(t.width,t.height,t.onCartIconClick);return(0,f.jsx)(c.az,{width:"fit-content",minWidth:"75%",borderRadius:"6px",padding:"2x",boxShadow:"lg",backgroundColor:"white",borderColor:i,borderWidth:"1px",onClick:t=>{t.stopPropagation()},cursor:"pointer",children:(0,f.jsxs)(u.B,{direction:"row",alignItems:"center",paddingX:"4px",paddingY:"5px",justifyContent:"center",children:[(0,f.jsx)(s.o,{paddingX:"5px",onClick:()=>{d()},children:"1972174947"!=o&&"55194878152"!=o&&"12181504100"!=o?(0,f.jsx)(tt.A,{sx:{color:i,fontSize:1.6*r}}):(0,f.jsx)(nt.$,{size:"sm",_hover:{bg:i},sx:{bg:i},children:(0,f.jsx)(j.E,{paddingX:"6px",color:"white",sx:{fontSize:.85*r},children:"GO TO CART"})})}),(0,f.jsx)(j.E,{color:i,fontSize:1.3*r+"px !important",fontWeight:"semibold !important",sx:{fontFamily:n+" !important"},children:a}),(0,f.jsx)(s.o,{paddingX:"5px",onClick:t=>{t.stopPropagation(),l()},children:(0,f.jsx)(J.A,{sx:{color:i,fontSize:1.6*r}})})]})})}var Rt=function(t){var e,i,n,o;const[r]=(0,v.QN)("whatmoreShopId"),l=t.event,a=t.product,d=null!==(e=t.baseFontSize)&&void 0!==e?e:10,s=null===(i=t.showAddedToCart)||void 0===i||i,c=t.cartState,u=t.cartCount,h=t.onClickAtc,p=t.onCartIconClick;function x(){h()}const m=null!==(n=t.width)&&void 0!==n?n:"100%",g=null!==(o=t.height)&&void 0!==o?o:"100%";return"errored"==c?(0,f.jsx)(et.s,{unmountOnExit:!0,in:!0,initialScale:.5,style:{},children:(0,f.jsx)(Ot,{event:l,product:a,baseFontSize:d,width:m,height:g})}):"init"==c?0==u?(0,f.jsx)(Bt,{onClick:x,event:l,product:a,baseFontSize:d,width:m,height:g}):s?(0,f.jsx)(et.s,{unmountOnExit:!0,in:!0,initialScale:.5,children:(0,f.jsx)(Dt,{onClick:x,event:l,product:a,baseFontSize:d,cartCount:u,width:m,height:g,onCartIconClick:p})}):(0,f.jsx)(Bt,{onClick:x,event:l,product:a,baseFontSize:d,width:m,height:g}):(0,f.jsx)(Lt,{onClick:x,cartState:c,updateCartState:t.updateCartState,event:l,product:a,baseFontSize:d,width:m,height:g,title:"awaitingVariantSelection"==c?"63064310011"==r?"Valider":"Done":"",showInProgressIcon:"atcApiCallInProgress"==c||"productVariantDetailsApiCallInProgress"==c})};var Wt=function(t){var e,i,o,r,a,d;const[s]=(0,v.QN)("isInDesignMode"),[h]=(0,v.QN)("isDemoBrand"),[g]=(0,v.QN)("whatmorePrimaryFont"),[w]=(0,v.QN)("whatmoreShopId"),[b,C,S,k]=(0,x.A)(),[I,_]=(0,n.useState)(!1),[z,E]=(0,n.useState)(t.product),T=(0,v.Xd)("whatmoreUITheme"),{whatmoreWidgetSourceDetails:N}=(0,n.useContext)($.B),[F,A,P,L,B,O,D,R]=ft(0,z,t.event),[W,Q]=(0,n.useState)(null),[V,q]=(0,n.useState)(parseFloat(z.price)),[K,J]=(0,n.useState)(parseFloat(z.compare_price)),[tt,et]=(0,n.useState)(z.currency),[it,nt]=(0,n.useState)(null),ot=t.event,rt=t.productClickHandler,[lt,at]=(0,n.useState)(null),[dt,st]=(0,n.useState)(!1),ct=N.landingLocationType,ut=N.templateType,ht=(0,St.Wd)(ct)+(0,St.gf)(ut)+"_"+(null===ot||void 0===ot?void 0:ot.event_id);(0,n.useEffect)((()=>{(0,p.w4b)(w)?(0,Ct.ck)(z,(0,p.NCy)(w),w).then((t=>{E(t),q(parseFloat(t.price)),J(parseFloat(t.compare_price)),et(t.currency),st(!0)})):(async()=>{var t,e,i,n,o,r;const l=await(0,m.M)(z,(0,p.NCy)(w),w);nt(l),q((null!==(t=null===l||void 0===l||null===(e=l.variants)||void 0===e||null===(i=e[0])||void 0===i?void 0:i.price)&&void 0!==t?t:null===l||void 0===l?void 0:l.price)/100),J((null!==(n=null===l||void 0===l||null===(o=l.variants)||void 0===o||null===(r=o[0])||void 0===r?void 0:r.compare_at_price)&&void 0!==n?n:null===l||void 0===l?void 0:l.compare_at_price)/100),st(!0)})(),!(0,p.E8r)(w)||null!==ot&&void 0!==ot&&ot.in_stock||P("errored")}),[]),(0,n.useEffect)((()=>{var t,e;const i=null!=it?null===it||void 0===it||null===(t=it.options)||void 0===t?void 0:t.findIndex((t=>{var e;return"Colour"==(null===t||void 0===t?void 0:t.name)||(null===t||void 0===t||null===(e=t.name)||void 0===e?void 0:e.toLowerCase().includes("color"))})):-1,n=-1!==i?null===it||void 0===it||null===(e=it.variants)||void 0===e?void 0:e.map((t=>{var e,n;const o=null===t||void 0===t?void 0:t[`option${i+1}`];return null!==t&&void 0!==t&&null!==(e=t.featured_image)&&void 0!==e&&e.src?{color:o,src:null===t||void 0===t||null===(n=t.featured_image)||void 0===n?void 0:n.src}:null})):[];let o=[];var r;-1!==i&&(o=null===it||void 0===it||null===(r=it.images)||void 0===r?void 0:r.map((t=>({color:t.color,src:t.src,optionsrc:t.optionsrc}))));at({position:i,finalArr:n,finalArrExternal:o})}),[it]);var pt=.72*k,vt=.37*pt,xt=pt*(.48-.37),mt=.95*pt+"px",gt=vt+"px",wt=.12*vt;function jt(){window.location.href=function(t){return(0,p.BLb)(w)?t.product_link+"?"+(0,p.VCz)(w)+"&"+(0,p.Spk)(w)+"&"+(0,p.$lz)(w):t.product_link}(z)}return(0,f.jsx)(u.B,{direction:"column",justifyContent:"flex-start",alignContent:"center",marginTop:U,marginBottom:"24px",width:mt,boxShadow:"round"==T?"dark-lg":null,onClick:()=>{!function(t,e){s||h||(async()=>{(0,l.Pb)(t,e)})(),"72550089015"==w?jt():rt(e),_(!0)}(ot,z)},backgroundColor:(0,H.YU)("#ffffff",(0,p.p2R)(w)),animation:I?M.jd:null,borderRadius:"round"==T?"xl":null,overflow:"hidden",onAnimationEnd:()=>{_(!1)},spacing:0,sx:{borderWidth:(0,p.YcK)(w),borderColor:(0,p.Fwt)(w)},children:(0,f.jsxs)(u.B,{display:"flex",direction:"row",width:"full",height:"fit-content",justifyContent:"center",alignContent:"center",cursor:"pointer",alignItems:"center",gap:"8px",children:[(0,f.jsx)(c.az,{height:gt,width:gt,children:(0,f.jsx)(y._,{width:"100%",height:"100%",src:(0,yt.b)(null!==(e=null!==(i=null===lt||void 0===lt||null===(o=lt.finalArr)||void 0===o||null===(r=o.find((t=>(null===t||void 0===t?void 0:t.color)==(null===W||void 0===W?void 0:W[null===lt||void 0===lt?void 0:lt.position]))))||void 0===r?void 0:r.src)&&void 0!==i?i:null===lt||void 0===lt||null===(a=lt.finalArrExternal)||void 0===a||null===(d=a.find((t=>(null===t||void 0===t?void 0:t.color)==(null===W||void 0===W?void 0:W[null===lt||void 0===lt?void 0:lt.position]))))||void 0===d?void 0:d.src)&&void 0!==e?e:z.thumbnail_image,"&width=400&height=400"),sx:{objectFit:(0,p.KZe)(w)+" !important"}})}),(0,f.jsx)(c.az,{height:gt,width:pt-vt+"px",children:(0,f.jsxs)(u.B,{direction:"column",justifyContent:"flex-start",height:"100%",gap:"4px",paddingTop:"12px",width:"100%",children:[(0,f.jsx)("p",{ref:t=>{t&&(t.style.setProperty("color","black","important"),t.style.setProperty("font-size",wt+"px","important"),t.style.setProperty("line-height","120%","important"),t.style.setProperty("font-family",g,"important"),t.style.setProperty("white-space","nowrap","important"),t.style.setProperty("overflow","hidden","important"),t.style.setProperty("text-overflow","ellipsis","important"),t.style.setProperty("padding","0","important"),t.style.setProperty("font-weight","normal","important"))},children:(0,G.v)(null==z.title?"":z.title.toString())}),(0,p.Nzx)(w)?(0,f.jsxs)(u.B,{direction:(0,p.vw2)(w)?"row":"row-reverse",sx:{margin:"0px !important",minHeight:1.1*wt+"px"},children:[dt&&(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*wt*(0,p.rh$)(w)+"px !important",lineHeight:"100%",sx:{fontFamily:g+" !important",color:(0,p.uoB)(w)+" !important",fontWeight:"bold"},children:[" "+(0,Ct.Sb)(null!==V&&void 0!==V?V:null===z||void 0===z?void 0:z.price,"",w,tt)," \xa0"]}),(0,Z.P)(V,K)&&dt?(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*wt*(0,p.rh$)(w)+"px !important",fontWeight:"medium !important",lineHeight:"100%",textAlign:"center",sx:{fontFamily:g+" !important",color:(0,p.gld)(w)+" !important",margin:"0px !important",letterSpacing:"normal !important",textDecoration:"line-through !important"},children:[" ",(0,Ct.Sb)(null!==K&&void 0!==K?K:null===z||void 0===z?void 0:z.compare_price,"",w,tt)]}):(0,f.jsx)(f.Fragment,{})]}):(0,f.jsx)(f.Fragment,{}),(0,f.jsx)(Rt,{baseFontSize:.3*xt,event:ot,product:z,cartState:F.state,cartCount:F.cart_count,updateCartState:P,onClickAtc:t=>{"init"===F.state?(B(ht,!0),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_ATC_CLICKED,widgetSourceDetails:N,event:ot,productList:[z],ctaList:ot.cta})):"awaitingVariantSelection"===F.state&&rt(z)},onCartIconClick:t=>{R()}})]})})]})})};var Qt=function(t){const[e]=(0,v.QN)("whatmoreShopId"),[i]=(0,v.QN)("isWhatmoreWebsite"),n=(0,p.Vpi)(e),o=t.event,r=t.product;return i?(0,f.jsx)(Pt,{product:t.product,event:t.event,productClickHandler:t.productClickHandler}):"broad-tile"==n?(0,f.jsx)(kt,{product:t.product,event:t.event,productClickHandler:t.productClickHandler,activeProductsCount:t.activeProductsCount}):"broad-tile-no-cta"==n?(0,f.jsx)(Pt,{product:t.product,event:t.event,productClickHandler:t.productClickHandler}):"broad-tile-new-atc"==n?(0,f.jsx)(Wt,{product:t.product,event:t.event,productClickHandler:t.productClickHandler}):"link_only"==n?(0,f.jsx)(q,{product:t.product,event:t.event}):"narrow-tile"==n?(0,f.jsx)(Ft,{event:o,product:r,productClickHandler:t.productClickHandler,tileWidthFactor:o.products.length>1?.68:void 0}):(0,f.jsx)(f.Fragment,{})},Vt=i(1079),Mt=i(7802),Ht=i(2979);var Ut=function(t){var e,i,n;const[l,a,d,h]=(0,x.A)(),[m]=(0,v.QN)("whatmoreShopId"),g=(0,v.Xd)("isInDesignMode"),w=(0,v.Xd)("isDemoBrand"),j=t.event,y=t.productClickHandler,b=(0,p.Vpi)(m),C=null!==(e=null===(i=j.products)||void 0===i||null===(n=i.filter((t=>"active"==(null===t||void 0===t?void 0:t.product_status))))||void 0===n?void 0:n.length)&&void 0!==e?e:0;if(!(0,Mt.Z_)(j))return(0,f.jsx)(f.Fragment,{});if(1==j.products.length&&(void 0==j.cta||0==j.cta.length)){const t=j.products[0];return(0,p.uJl)(m)?(0,f.jsx)(u.B,{direction:"horizontal",width:h,height:"fit-content",justifyContent:"center",backgroundImage:"linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.4), rgba(0,0,0,0.6), rgba(0,0,0,0.8))",children:(0,f.jsx)(Ht.S,{userInteractionType:Y.O.PRODUCT_CTA_VIEW,event:j,productList:[t],triggerFlag:!g&&!w,children:(0,f.jsx)(s.o,{children:(0,f.jsx)(Ft,{event:j,product:t,productClickHandler:y},j.event_id+t.product_id)})})}):(0,f.jsx)(u.B,{direction:"horizontal",width:h,height:"fit-content",justifyContent:"center",backgroundImage:"narrow-tile"==b?"linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.4), rgba(0,0,0,0.6), rgba(0,0,0,0.8))":null,children:(0,f.jsx)(s.o,{children:(0,f.jsx)(Ht.S,{userInteractionType:Y.O.PRODUCT_CTA_VIEW,event:j,productList:[t],triggerFlag:!g&&!w,children:(0,f.jsx)(Qt,{activeProductsCount:1,event:j,product:t,productClickHandler:y},j.event_id+t.product_id)})})})}return(0,f.jsx)(s.o,{children:(0,f.jsx)("div",{onTouchStart:t=>{t.stopPropagation()},onTouchEnd:t=>{t.stopPropagation()},children:(0,f.jsx)(c.az,{width:h+"px",backgroundImage:"narrow-tile"==b?"linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.4), rgba(0,0,0,0.6), rgba(0,0,0,0.8))":null,children:(0,f.jsxs)(o.RC,{className:"product-tile swiper-slide",slidesPerView:1==j.products.length?1:1.4,initialSlide:j.products.length<=2||(0,p.TYM)(m)?0:1,centeredSlides:!(0,p.TYM)(m),modules:[r.FJ],mousewheel:{invert:!1,thresholdDelta:20},nested:!0,children:[("STRDOIDF6O7"===m?[j.products[0]]:j.products).map((t=>("oos"!=t.product_status||(0,p.$7F)(m))&&(0,f.jsx)(o.qr,{children:(0,f.jsx)(Ht.S,{userInteractionType:Y.O.PRODUCT_CTA_VIEW,event:j,productList:[t],triggerFlag:!g&&!w,children:(0,f.jsx)(u.B,{direction:"column",height:"100%",width:"100%",justifyContent:"flex-end",alignItems:"center",children:(0,f.jsx)(Qt,{activeProductsCount:C,event:j,product:t,productClickHandler:y},j.event_id+t.product_id)})})},j.event_id+t.product_id))),(0,p.Woi)(m)&&void 0!=j.cta&&j.cta.map((t=>(0,f.jsx)(f.Fragment,{children:""!==t.cta_title.trim()&&(0,f.jsx)(o.qr,{children:(0,f.jsx)(u.B,{direction:"column",height:"100%",width:"100%",justifyContent:"flex-end",paddingBottom:"12px",alignItems:"center",children:(0,f.jsx)(Vt.A,{fontFactor:.75,cta:t},j.event_id+t.cta_id)})},j.event_id+t.cta_id)})))]})})})})};var Xt=function(t){const[e,i]=(0,v.QN)("isProductSwiperCatalogOpen"),o=t.event,r=t.productClickHandler;return(0,n.useContext)(Ni).isIOS&&e?(0,f.jsx)(Ut,{event:o,productClickHandler:r},o.event_id):(0,f.jsx)(O.J,{unmountOnExit:!0,initialScale:.2,in:e,children:(0,f.jsx)(Ut,{event:o,productClickHandler:r},o.event_id)})};function Yt(t){const e=t.event,[i,n,o,r]=(0,x.A)(),[l]=(0,v.QN)("whatmorePrimaryFont");return(0,f.jsx)(c.az,{width:"fit-content",height:"fit-content",padding:"5px",children:(0,f.jsxs)(u.B,{direction:"row",width:"fit-content",height:"fit-content",children:[(0,f.jsx)(s.o,{children:(0,f.jsx)(c.jl,{overflow:"hidden",size:.15*r+"px",children:(0,f.jsx)(y._,{width:"100%",height:"100%",src:e.thumbnail_image})})}),(0,f.jsx)(c.az,{width:"fit-content",height:"fit-content",children:(0,f.jsxs)(u.B,{direction:"column",width:"fit-content",height:"fit-content",children:[(0,f.jsx)(j.E,{color:"white",fontSize:.05*r+"px",fontWeight:"bold",fontFamily:"sans-serif",align:"left",sx:{fontFamily:l+" !important"},children:e.presenter_name.substring(0,15)}),(0,f.jsx)(L.A,{event:e,fontSize:.03*r+"px"})]})})]})})}var $t=function(t){const[e]=(0,v.QN)("isInDesignMode"),[i]=(0,v.QN)("isDemoBrand"),[o,r]=(0,v.QN)("isProductSwiperCatalogOpen"),[l,a]=(0,S.A)(),[d,s]=(0,v.QN)("isFirstIndicatorRenderDone"),h=(0,n.useContext)(Ni),[x]=(0,v.QN)("whatmoreShopId"),m=t.event,g=t.isLast,w=t.onCloseCallback,j=t.focusRef,y=t.productClickHandler;return(0,f.jsx)(c.az,{width:"full",height:"full",borderRadius:"md",children:(0,f.jsxs)(u.B,{direction:"column",width:"full",height:"full",justifyContent:"space-between",children:[(0,f.jsx)(c.az,{width:"full",margin:"2px",bgGradient:"linear(to-t, transparent, whiteAlpha.100, blackAlpha.200, blackAlpha.400, blackAlpha.800)",children:(0,f.jsxs)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"space-between",paddingRight:"10px",paddingLeft:"10px",children:[(0,f.jsx)(Yt,{event:m}),(0,f.jsxs)(u.B,{direction:"row",width:"fit-content",justifyContent:"end",paddingLeft:"10px",children:[(0,f.jsx)(k,{focusRef:j}),(0,f.jsx)(B.A,{event:m,onCloseCallback:w})]})]})}),(0,f.jsx)(c.az,{width:"100%",height:"100%",onClick:()=>{a(!l)}}),(0,f.jsxs)(c.az,{width:"full",height:"fit-content",children:[h.totalEvents>1&&!d&&h.showSwipeIndicator?(0,f.jsx)(c.az,{width:"full",margin:"2px",children:(0,f.jsx)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"center",children:(0,f.jsx)(Q,{swipeUp:!g})})}):null,void 0!=m.products&&m.products.length>0?(0,f.jsxs)(c.az,{width:"full",children:[(0,p.ek9)(x)?(0,f.jsx)(c.az,{w:"100%",children:(0,f.jsx)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,f.jsx)(P,{event:m,onToggle:t=>{r("minimize-button"!==t)}})})}):(0,f.jsx)(f.Fragment,{}),(0,f.jsx)(c.az,{display:"flex",width:"100%",height:"fit-content",children:(0,f.jsx)(Xt,{event:m,productClickHandler:y})})]}):(0,f.jsx)("div",{})]})]})})},qt=i(7642);function Kt(t){const[e,i,o,r]=(0,x.A)(),[l]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,s]=(0,n.useState)(""),h=t.data,m=(t.event,t.product,t.setShowOptionsChart);var g=.4*r*.8*.13;(0,n.useEffect)((()=>{let t="vanyaclothing.myshopify.com";"1972174947"===a?t="vanyaclothing.myshopify.com":"57415434338"===a&&(t="usvanya.myshopify.com");const e=`https://app.kiwisizing.com/api/getSizingChart?shop=${t}&product=${null===h||void 0===h?void 0:h.id}&title=${null===h||void 0===h?void 0:h.title}&tags=&cacheSettingsUpdateAt=2020-08-11T15%3A19%3A49.000Z&settingsVersion=19`;fetch(e).then((t=>{if(!t.ok)throw new Error(`HTTP error! Status: ${t.status}`);return t.json()})).then((t=>{var e,i,n,o,r,l;s(null===t||void 0===t||null===(e=t.sizings)||void 0===e||null===(i=e[0])||void 0===i||null===(n=i.layout)||void 0===n||null===(o=n.data)||void 0===o||null===(r=o[0])||void 0===r||null===(l=r.data)||void 0===l?void 0:l.url)})).catch((t=>{console.error("Error fetching data:",t)}))}),[]);const w=`${z.i7`
|
|
68
|
+
`} infinite 1.5s linear`;return(0,f.jsx)(O.J,{unmountOnExit:!0,initialScale:.2,in:d,reverse:!0,delay:g,children:(0,f.jsx)(c.az,{width:"100%",height:"fit-content",paddingTop:100,borderRadius:"3xl",children:(0,f.jsxs)(u.B,{direction:"column",width:"100%",height:"0px",justifyContent:"flex-end",children:[(0,f.jsx)(s.o,{animation:"vertical"===p?b:C,children:"vertical"===p?(0,f.jsx)(D.A,{sx:{color:"white !important",fontSize:w,filter:"drop-shadow(0 0 20px black);"}}):(0,f.jsx)(R.A,{sx:{color:"white !important",fontSize:w,filter:"drop-shadow(0 0 20px black);"}})}),(0,f.jsx)(s.o,{children:(0,f.jsx)(j.E,{textShadow:"dark-lg",fontSize:y+"px",fontWeight:"semibold",sx:{color:"white !important",textShadow:"0px 0px 20px black !important;"},children:"swipe for more"})})]})})})};var Q=function(t){const[e,i]=(0,v.QN)("isFirstIndicatorRenderDone"),[o]=(0,v.QN)("indicatorRenderSeconds"),r=o,l=t.swipeUp;return(0,n.useEffect)((()=>{const t=setTimeout((()=>{i(!0)}),3e3+1e3*r);return()=>{clearTimeout(t)}}),[]),e?null:(0,f.jsx)(W,{showForSeconds:.8*r,delayInSeconds:3,swipeUp:l})},V=i(8781),M=i(5144),H=i(4459);const U="15px";var X=i(1351),Y=i(6157),$=i(4737);var q=function(t){const[e]=(0,v.QN)("isInDesignMode"),[i]=(0,v.QN)("isDemoBrand"),[o]=(0,v.QN)("whatmoreSecondaryColor"),[r]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,h,m,g]=(0,x.A)(),[w,y]=(0,n.useState)(!1),b=t.product,C=t.event,{whatmoreWidgetSourceDetails:S}=(0,n.useContext)($.B),k=.1*m,I=.95*g,_=.05*g;return(0,f.jsx)(u.B,{direction:"row",height:k,justifyContent:"center",alignItems:"center",alignContent:"center",bgGradient:"linear(to-b, transparent, blackAlpha.400, blackAlpha.600)",children:(0,f.jsx)(u.B,{direction:"column",width:"fit-content",height:k,justifyContent:"center",alignItems:"center",alignContent:"center",children:(0,f.jsx)(c.az,{width:I+"px",height:"fit-content",padding:"6px",marginTop:U,backgroundColor:o,borderRadius:"5px",animation:w?M.jd:null,onAnimationEnd:()=>{y(!1)},marginBottom:(0,p.qw1)(a),onClick:()=>{y(!0),function(t,n){e||i||(async()=>{(0,l.Pb)(t,n),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_SHOPNOW_CLICKED,widgetSourceDetails:S,event:t,productList:[n],ctaList:t.cta})})()}(C,b),window.location.href=function(t){return(0,p.BLb)(a)?t.product_link+"?"+(0,p.VCz)(a)+"&"+(0,p.Spk)(a)+"&"+(0,p.$lz)(a):t.product_link}(b)},_hover:{backgroundColor:(0,H.YU)(o,8)},cursor:"pointer",children:(0,f.jsx)(s.o,{children:(0,f.jsx)(j.E,{style:{overflow:"hidden",textOverflow:"ellipsis"},noOfLines:1,fontSize:1.2*_+"px",fontWeight:"medium",lineHeight:"120%",sx:{fontFamily:r+" !important",color:"white !important"},children:(0,p.Qed)(a)})})})})})},K=i(4892),G=i(8538),Z=i(7458),J=i(2159),tt=i(9537),et=i(6710),it=i(173),nt=(i(6125),i(4905));const ot={en:{add_to_cart:"ADD TO CART",buy_now:"BUY NOW",more_info:"MORE INFO",size:"Size",color:"Color",description:"Description",like:"Like",share:"Share",talk_to_us:"Talk to Us",done:"Done",cancel:"Cancel",view_product:"View Product",go_to_cart:"Go to Cart"},ar:{add_to_cart:"\u0623\u0636\u0641 \u0625\u0644\u0649 \u0627\u0644\u0633\u0644\u0629",buy_now:"\u0627\u0634\u062a\u0631\u0650 \u0627\u0644\u0622\u0646",more_info:"\u0645\u0632\u064a\u062f \u0645\u0646 \u0627\u0644\u0645\u0639\u0644\u0648\u0645\u0627\u062a",size:"\u0627\u0644\u062d\u062c\u0645",color:"\u0627\u0644\u0644\u0648\u0646",description:"\u0627\u0644\u0648\u0635\u0641",like:"\u0623\u0639\u062c\u0628\u0646\u064a",share:"\u0645\u0634\u0627\u0631\u0643\u0629",talk_to_us:"\u062a\u062d\u062f\u062b \u0625\u0644\u064a\u0646\u0627",done:"\u062a\u0645",cancel:"\u0625\u0644\u063a\u0627\u0621",view_product:"\u0639\u0631\u0636 \u0627\u0644\u0645\u0646\u062a\u062c",go_to_cart:"\u0627\u0630\u0647\u0628 \u0625\u0644\u0649 \u0627\u0644\u0633\u0644\u0629",watch_and_buy:"\u0634\u0627\u0647\u062f \u0648\u0627\u0634\u062a\u0631\u064a"},da:{add_to_cart:"In den Warenkorb",buy_now:"Jetzt kaufen",more_info:"Mehr Infos",size:"Gr\xf6\xdfe",color:"Farbe",description:"Beschreibung",like:"Gef\xe4llt mir",share:"Teilen",talk_to_us:"Sprechen Sie mit uns",done:"Fertig",cancel:"Abbrechen",view_product:"Produkt ansehen",go_to_cart:"Zum Warenkorb",watch_and_buy:"Ansehen und kaufen"},de:{add_to_cart:"In den Warenkorb",buy_now:"Jetzt kaufen",more_info:"Mehr Infos",size:"Gr\xf6\xdfe",color:"Farbe",description:"Beschreibung",like:"Gef\xe4llt mir",share:"Teilen",talk_to_us:"Sprechen Sie mit uns",done:"Fertig",cancel:"Abbrechen",view_product:"Produkt ansehen",go_to_cart:"Zum Warenkorb",watch_and_buy:"Ansehen und kaufen"},es:{add_to_cart:"A\xf1adir al carrito",buy_now:"Comprar ahora",more_info:"M\xe1s informaci\xf3n",size:"Tama\xf1o",color:"Color",description:"Descripci\xf3n",like:"Me gusta",share:"Compartir",talk_to_us:"Habla con nosotros",done:"Hecho",cancel:"Cancelar",view_product:"Ver producto",go_to_cart:"Ir al carrito",watch_and_buy:"Ver y comprar"},fr:{add_to_cart:"Ajouter au panier",buy_now:"Acheter maintenant",more_info:"Plus d'infos",size:"Taille",color:"Couleur",description:"Description",like:"J'aime",share:"Partager",talk_to_us:"Parlez-nous",done:"Valider",cancel:"Annuler",view_product:"Voir le produit",go_to_cart:"Aller au panier",watch_and_buy:"Regarder et acheter"},ja:{add_to_cart:"\u30ab\u30fc\u30c8\u306b\u8ffd\u52a0",buy_now:"\u4eca\u3059\u3050\u8cfc\u5165",more_info:"\u8a73\u7d30\u60c5\u5831",size:"\u30b5\u30a4\u30ba",color:"\u8272",description:"\u8aac\u660e",like:"\u3044\u3044\u306d",share:"\u5171\u6709",talk_to_us:"\u304a\u554f\u3044\u5408\u308f\u305b",done:"\u5b8c\u4e86",cancel:"\u30ad\u30e3\u30f3\u30bb\u30eb",view_product:"\u5546\u54c1\u3092\u898b\u308b",go_to_cart:"\u30ab\u30fc\u30c8\u306b\u9032\u3080",watch_and_buy:"\u8996\u8074\u3057\u3066\u8cfc\u5165"},nl:{add_to_cart:"Aan winkelwagentje toevoegen",buy_now:"Nu kopen",more_info:"Meer informatie",size:"Maat",color:"Kleur",description:"Beschrijving",like:"Vind ik leuk",share:"Delen",talk_to_us:"Praat met ons",done:"Klaar",cancel:"Annuleren",view_product:"Bekijk product",go_to_cart:"Ga naar winkelwagentje",watch_and_buy:"Kijk en koop"},pt:{add_to_cart:"Adicionar ao carrinho",buy_now:"Comprar agora",more_info:"Mais informa\xe7\xf5es",size:"Tamanho",color:"Cor",description:"Descri\xe7\xe3o",like:"Curtir",share:"Compartilhar",talk_to_us:"Fale conosco",done:"Conclu\xeddo",cancel:"Cancelar",view_product:"Ver produto",go_to_cart:"Ir para o carrinho",watch_and_buy:"Assistir e comprar"},zh:{add_to_cart:"\u52a0\u5165\u8d2d\u7269\u8f66",buy_now:"\u7acb\u5373\u8d2d\u4e70",more_info:"\u66f4\u591a\u4fe1\u606f",size:"\u5c3a\u5bf8",color:"\u989c\u8272",description:"\u63cf\u8ff0",like:"\u559c\u6b22",share:"\u5206\u4eab",talk_to_us:"\u8054\u7cfb\u6211\u4eec",done:"\u5b8c\u6210",cancel:"\u53d6\u6d88",view_product:"\u67e5\u770b\u5546\u54c1",go_to_cart:"\u524d\u5f80\u8d2d\u7269\u8f66",watch_and_buy:"\u89c2\u770b\u5e76\u8d2d\u4e70"}};function rt(t){var e,i,o;const[r]=(0,v.QN)("whatmoreSecondaryColor"),[l]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,s]=(0,n.useState)(!1),h=null!==(e=t.baseFontSize)&&void 0!==e?e:10,x=t.onClick,m=t.width,g=t.height,w=t.title,y=t.showInProgressIcon;return(0,f.jsxs)(c.az,{display:"flex",width:m,height:g,padding:"2x",boxShadow:"lg",animation:d?M.jd:null,onAnimationEnd:()=>{s(!1)},cursor:"pointer",children:["awaitingVariantSelection"==t.cartState&&(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"2px",backgroundColor:"white",onClick:e=>{e.stopPropagation(),t.updateCartState("init"),t.setProductVariantTitle(t.productTitle),s(!0)},children:(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*h+"px !important",fontWeight:"semibold !important",sx:{fontFamily:l+" !important",color:"#343434 !important"},children:["\xa0",null!==(i=null===ot||void 0===ot||null===(o=ot[null===t||void 0===t?void 0:t.websiteLanguage])||void 0===o?void 0:o.cancel)&&void 0!==i?i:"Cancel","\xa0"]})}),(0,f.jsxs)(u.B,{direction:"row",backgroundColor:y?(0,H.YU)(r,8):r,width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"2px",onClick:t=>{t.stopPropagation(),x(),s(!0)},children:[(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*h+"px !important",fontWeight:"semibold !important",sx:{fontFamily:l+" !important",color:(0,p.Hfu)(a)+" !important"},children:["\xa0",w,"\xa0"]}),y?(0,f.jsx)("div",{className:"whatmore-rotate-indefinitely",children:(0,f.jsx)(it.A,{sx:{filter:"drop-shadow(0 0 15px black);",color:"#F5F5F5",fontSize:2.5*h+"px"}})}):(0,f.jsx)(f.Fragment,{})]})]})}function lt(t){var e,i,o;const[r]=(0,v.QN)("whatmoreSecondaryColor"),[l]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,h]=(0,n.useState)(!1),x=null!==(e=t.baseFontSize)&&void 0!==e?e:10,m=t.onClick,g=t.width,w=t.height;return(0,f.jsx)(c.az,{width:g,height:w,padding:"2x",boxShadow:"lg",backgroundColor:"#000000"==(0,p.Wc_)(a)?r:(0,p.Wc_)(a),onClick:t=>{t.stopPropagation(),m(),h(!0)},animation:d?M.jd:null,onAnimationEnd:()=>{h(!1)},cursor:"pointer",children:(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"5px",children:(0,f.jsx)(s.o,{children:(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*x+"px !important",fontWeight:"semibold !important",sx:{fontFamily:l+" !important",color:(0,p.Hfu)(a)+" !important"},children:["\xa0","ADD TO CART"!=(0,p.KPq)(a)?(0,p.KPq)(a):null!==(i=null===ot||void 0===ot||null===(o=ot[null===t||void 0===t?void 0:t.websiteLanguage])||void 0===o?void 0:o.add_to_cart)&&void 0!==i?i:(0,p.KPq)(a),"\xa0"]})})})})}function at(t){var e;const[i]=(0,v.QN)("whatmorePrimaryFont"),n=null!==(e=t.baseFontSize)&&void 0!==e?e:10,o=t.width,r=t.height;return(0,f.jsx)(c.az,{width:o,height:r,padding:"2x",boxShadow:"lg",backgroundColor:"white",borderColor:"gray",borderWidth:"1px",onClick:t=>{t.stopPropagation()},children:(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",paddingX:"4px",paddingY:"5px",justifyContent:"center",children:(0,f.jsxs)(j.E,{color:"gray",lineHeight:"100%",fontSize:1.3*n+"px !important",fontWeight:"semibold !important",sx:{fontFamily:i+" !important",color:"gray !important"},children:["\xa0"," Sold Out ","\xa0"]})})})}function dt(t){var e;const[i]=(0,v.QN)("whatmoreSecondaryColor"),[n]=(0,v.QN)("whatmorePrimaryFont"),[o]=(0,v.QN)("whatmoreShopId"),r=null!==(e=t.baseFontSize)&&void 0!==e?e:10,l=t.onClick,a=t.cartCount,d=t.width,h=t.height,x=t.onCartIconClick;return(0,f.jsx)(c.az,{width:d,height:h,padding:"2x",boxShadow:"lg",backgroundColor:"white",borderColor:i,borderWidth:"1px",onClick:t=>{t.stopPropagation()},cursor:"pointer",children:(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",paddingX:"4px",paddingY:"5px",justifyContent:"center",children:[(0,f.jsx)(s.o,{paddingX:"5px",onClick:()=>{x()},children:(0,p.DiI)(o)?(0,f.jsx)(nt.$,{size:"sm",_hover:{bg:i},sx:{bg:i},children:(0,f.jsx)(j.E,{paddingX:"6px",color:"white",sx:{fontSize:.85*r},children:"GO TO CART"})}):(0,f.jsx)(tt.A,{sx:{color:i,fontSize:1.6*r}})}),(0,f.jsx)(j.E,{color:i,fontSize:1.3*r+"px !important",fontWeight:"semibold !important",sx:{fontFamily:n+" !important"},children:a}),(0,f.jsx)(s.o,{paddingX:"5px",onClick:t=>{t.stopPropagation(),l()},children:(0,f.jsx)(J.A,{sx:{color:i,fontSize:1.6*r}})})]})})}var st=function(t){var e,i,n,o,r,l,a;const[d]=(0,v.QN)("websiteLanguage"),s=null!==(e=t.baseFontSize)&&void 0!==e?e:10,c=null===(i=t.showAddedToCart)||void 0===i||i,u=t.cartState,h=t.cartCount,p=t.onClickAtc,x=t.onCartIconClick;function m(){p()}const g=null!==(n=t.width)&&void 0!==n?n:"100%",w=null!==(o=t.height)&&void 0!==o?o:"100%";return"errored"==u?(0,f.jsx)(et.s,{unmountOnExit:!0,in:!0,initialScale:.5,style:{height:w,width:g},children:(0,f.jsx)(at,{baseFontSize:s,width:g,height:w})}):"init"==u?0==h?(0,f.jsx)(lt,{onClick:m,baseFontSize:s,width:g,height:w,websiteLanguage:d}):c?(0,f.jsx)(et.s,{unmountOnExit:!0,in:!0,initialScale:.5,style:{height:w,width:g},children:(0,f.jsx)(dt,{onClick:m,baseFontSize:s,cartCount:h,width:g,height:w,onCartIconClick:x})}):(0,f.jsx)(lt,{onClick:m,baseFontSize:s,width:g,height:w,websiteLanguage:d}):(0,f.jsx)(rt,{onClick:m,setProductVariantTitle:t.setProductVariantTitle,cartState:u,productTitle:null===(r=t.product)||void 0===r?void 0:r.title,updateCartState:t.updateCartState,baseFontSize:s,width:g,height:w,title:"awaitingVariantSelection"==u?null!==(l=null===ot||void 0===ot||null===(a=ot[d])||void 0===a?void 0:a.done)&&void 0!==l?l:"Done":"",showInProgressIcon:"atcApiCallInProgress"==u||"productVariantDetailsApiCallInProgress"==u,websiteLanguage:d})},ct=i(4533),ut=i(6387),ht=i(1745);const pt=(0,v.Xd)("isInDesignMode"),vt=(0,v.Xd)("isDemoBrand");async function xt(t,e,i,n,o,r,l,a,d){return"shopify"==i?(0,ht.RX)(t,e,n,l,a,d):(pt||vt||(async()=>{(0,ct.Fu)(o,r,l,a,d)})(),(0,ut.It)(null===t||void 0===t?void 0:t[0],e,n))}function mt(t,e){return"shopify"==t?(0,ht.iL)(e):(0,ut.pV)(e)}var gt=i(852);var ft=function(t,e,i){const[o]=(0,v.QN)("whatmoreShopId"),[r]=(0,v.QN)("isInDesignMode"),[a]=(0,v.QN)("isDemoBrand"),[d,s]=(0,n.useState)(null),c=(0,n.useRef)(null),{closeClickComponent:u}=(0,n.useContext)(Ni),{whatmoreUserInfo:h}=(0,n.useContext)($.B),[x,g]=(0,n.useState)({state:"init",cart_count:t});function f(t,e){g({state:t,cart_count:null!==e&&void 0!==e?e:x.cart_count}),"init"!=t&&"errored"!=t?(0,v.t2)("whatmoreAllowAutoSlide",!1):(0,v.t2)("whatmoreAllowAutoSlide",!0)}function w(t){const e=c.current.filter((e=>e.option1==t[0]&&e.option2==t[1]&&e.option3==t[2]));return 0==e.length?null:e[0].id}function j(t){var e=[],i=[],n=[];return t.variants.forEach((o=>{var r,l,a;o.option1&&e.push({option:o.option1,available:null===(r=o.available)||void 0===r||r,type:t.options[0].name}),o.option2&&i.push({option:o.option2,available:null===(l=o.available)||void 0===l||l,type:t.options[1].name}),o.option3&&n.push({option:o.option3,available:null===(a=o.available)||void 0===a||a,type:t.options[2].name})})),e=e.reduce(((t,e,i)=>{var n=t.filter((t=>t.option==e.option));return 0==n.length?[...t,e]:(n[0].available=n[0].available|e.available,t)}),[]),i=i.reduce(((t,e,i)=>{var n=t.filter((t=>t.option==e.option));return 0==n.length?[...t,e]:(n[0].available=n[0].available|e.available,t)}),[]),n=n.reduce(((t,e,i)=>{var n=t.filter((t=>t.option==e.option));return 0==n.length?[...t,e]:(n[0].available=n[0].available|e.available,t)}),[]),[e,i,n]}function y(t){if(0==t.length)return null;const e=t.filter((t=>t.available));return 0==e.length?null:e[0].option}function b(t){return t[0].length<=1&&t[1].length<=1&&t[2].length<=1}function C(){if(c.current&&c.current.length>=1){return c.current.filter((t=>t.available)).length>=1}return!1}function S(t,e,i){r||a||(async()=>{(0,l.tO)(t,e,i)})()}function k(t,n){const r=w(t);if(!r)return void f("init",x.cart_count);f("atcApiCallInProgress",null);xt([r],1,(0,p.NCy)(o),o,i,e,n,null===i||void 0===i?void 0:i.location,null===h||void 0===h?void 0:h.userType).then((t=>{if(!t.ok)throw new Error(t.status);return t.json()})).then((t=>(S(i,e,1),f("init",x.cart_count+1),(0,v.t2)("whatmoreAddedToCart",!0),"72550089015"==o&&(0,v.Xd)("whatmoreAddedToCart")&&(0,gt.H)(o,(()=>{}),100,window.location.hostname),(0,p.MPe)(o)&&setTimeout((()=>function(){const t=window.location.origin+"/cart";window.location.href=t}()),500),t))).catch((t=>{f("errored",null),console.error("Error while adding to cart:",t)}))}return[x,function(t){const n=[];f("productVariantDetailsApiCallInProgress",null),Promise.all(i.products.map((t=>(0,m.M)(t,(0,p.NCy)(o),o).then((e=>{c.current=e.variants;const i=j(e);if(s(i),b(i)&&C()){const e=w([y(i[0]),y(i[1]),y(i[2])]);return e?(n.push(t),e):void f("init",x.cart_count)}}))))).then((r=>{const l=r.filter((t=>void 0!=t));xt(l,1,(0,p.NCy)(o),o,i,e,t,null===i||void 0===i?void 0:i.location,null===h||void 0===h?void 0:h.userType).then((t=>{if(!t.ok)throw new Error(t.status);return t.json()})).then((t=>(n.forEach((t=>{S(i,t,1)})),f("init",x.cart_count+(null===l||void 0===l?void 0:l.length)),(0,v.t2)("whatmoreAddedToCart",!0),t))).catch((t=>{f("errored",null),console.error("Error while adding to cart:",t)}))}))},f,d,function(t){let i=arguments.length>1&&void 0!==arguments[1]&&arguments[1];f("productVariantDetailsApiCallInProgress",null),(0,m.M)(e,(0,p.NCy)(o),o).then((e=>{c.current=e.variants;const n=j(e);s(n),b(n)||i?C()?k([y(n[0]),y(n[1]),y(n[2])],t):f("errored",null):f("awaitingVariantSelection",null)})).catch((t=>{f("errored",null)}))},k,function(t){var e,i,n,r;const l=c.current.filter((e=>e.option1==t[0]&&e.option2==t[1]&&e.option3==t[2]));if(0==l.length)return null;const a=null!==(e=l[0].price)&&void 0!==e?e:0,d=null!==(i=l[0].compare_at_price)&&void 0!==i?i:0;return{price:((0,p.NCy)(o),a),compare_price:((0,p.NCy)(o),d),title:null!==(n=null===(r=l[0])||void 0===r?void 0:r.title)&&void 0!==n?n:""}},function(){"do_nothing"!==(0,p.m4S)(o)&&("go_to_cart_page"!==(0,p.m4S)(o)?"open_cart_slider"!==(0,p.m4S)(o)||null!==u&&u():mt((0,p.NCy)(o),o))}]},wt=i(2720),jt=i(3755),yt=i(7973);var bt=function(t){var e,i,o;const r=t.productVariantOptions,l=null!==(e=t.width)&&void 0!==e?e:"100%",a=(t.height,t.maxHeight),d=null!==(i=t.baseFontSize)&&void 0!==i?i:10,h=t.onOptionSelected,p=null!==(o=t.optionTitleColor)&&void 0!==o?o:"black",x=t.data,[m]=(0,v.QN)("whatmorePrimaryFont"),g=(0,n.useRef)(null),[w,b]=(0,n.useState)(!1),[C,S]=(0,n.useState)(0),[k,I]=(0,n.useState)(0);function _(t){if(0==t.length)return null;const e=t.filter((t=>t.available));return 0==e.length?null:e[0].option}const[z,E]=(0,n.useState)([_(r[0]),_(r[1]),_(r[2])]);return(0,n.useEffect)((()=>{h(z)}),[z]),(0,f.jsx)(u.B,{ref:g,direction:"column",width:l,maxHeight:a,justifyContent:"flex-start",alignItems:"center",spacing:"2px",paddingY:"2px",overflowY:"auto",onTouchStart:t=>{g.current&&(b(!0),S(t.touches[0].clientY),I(g.current.scrollTop))},onTouchMove:t=>{if(!w||!g.current)return;const e=t.touches[0].clientY,i=1.5*(C-e);g.current.scrollTop=k+i,t.preventDefault()},onTouchEnd:()=>{b(!1)},onWheel:t=>{if(!g.current)return;let e=0===t.deltaMode?1:15;g.current.scrollTop+=t.deltaY*e},sx:{"&::-webkit-scrollbar":{width:"4px"},"&::-webkit-scrollbar-track":{width:"6px",background:"#f1f1f1"},"&::-webkit-scrollbar-thumb":{background:"#888",borderRadius:"24px"},"&::-webkit-scrollbar-thumb:hover":{background:"#555"},"overflow-y":"scroll !important","-webkit-overflow-scrolling":"touch"},children:r.map(((e,i)=>{var n;if(0==e.length||"mlveda_country"==(null===e||void 0===e||null===(n=e[0])||void 0===n?void 0:n.type))return;const o=e.every((e=>{var i,n,o,r,l,a;return(null===t||void 0===t||null===(i=t.finalArr)||void 0===i||null===(n=i.finalArr)||void 0===n||null===(o=n.find((t=>(null===t||void 0===t?void 0:t.color)===(null===e||void 0===e?void 0:e.option))))||void 0===o?void 0:o.src)||(null===t||void 0===t||null===(r=t.finalArr)||void 0===r||null===(l=r.finalArrExternal)||void 0===l||null===(a=l.find((t=>(null===t||void 0===t?void 0:t.color)===(null===e||void 0===e?void 0:e.option))))||void 0===a?void 0:a.optionsrc)}));return(0,f.jsxs)(u.B,{width:"100%",direction:"column",alignItems:"center",justifyContent:"flex-start",paddingY:"2px",children:[(0,f.jsx)(s.o,{width:"100%",children:(0,f.jsx)(wt.c,{color:"blackAlpha.500",size:"1px",width:"20%"})}),(0,f.jsxs)(j.E,{as:"b",fontSize:1.2*d+"px",sx:{color:p+" !important",fontFamily:m+" !important"},align:"center",marginY:"2px",children:["\xa0",e[0].type,"\xa0"]}),(0,f.jsx)(jt.s,{gap:"6px",wrap:"wrap",justify:"center",paddingY:"2px",children:e.map(((e,n)=>{var r,l,a,s,u,h,p,v;return(0==i||(null===x||void 0===x||null===(r=x.variants)||void 0===r?void 0:r.find((t=>t[`option${i}`]==(null===z||void 0===z?void 0:z[i-1])&&t[`option${i+1}`]==(null===e||void 0===e?void 0:e.option)))))&&(0,f.jsxs)(c.az,{onClick:t=>{t.stopPropagation(),e.available&&function(t,e){if(2==e)E([z[0],z[1],t]);else if(1==e){var i,n;E([z[0],t,null===x||void 0===x||null===(i=x.variants)||void 0===i||null===(n=i.find((e=>(null===e||void 0===e?void 0:e.option2)==t)))||void 0===n?void 0:n.option3])}else{var o,r,l,a,d,s;const e=null===x||void 0===x||null===(o=x.variants)||void 0===o||null===(r=o.find((e=>(null===e||void 0===e?void 0:e.option1)==t)))||void 0===r?void 0:r.option2;E([t,null===x||void 0===x||null===(l=x.variants)||void 0===l||null===(a=l.find((e=>(null===e||void 0===e?void 0:e.option1)==t)))||void 0===a?void 0:a.option2,null===x||void 0===x||null===(d=x.variants)||void 0===d||null===(s=d.find((t=>(null===t||void 0===t?void 0:t.option2)==e)))||void 0===s?void 0:s.option3])}}(e.option,i)},backgroundColor:e.option===z[i]?"rgba(0, 0, 0, 0.7)":"white",border:e.option===z[i]?"1px solid #ffffff":"1px solid black",cursor:"pointer",display:"flex",alignItems:"center",justifyContent:"center",boxShadow:e.option===z[i]?"0 0 8px rgba(0, 0, 0, 0.8)":"none",marginY:"2px",width:"fit-content",padding:o?"0px":"8px",borderRadius:o?"50%":"0",children:[!o&&(0,f.jsxs)(j.E,{as:e.available?"samp":"s",fontSize:.8*d+"px",sx:{color:e.option===z[i]?"white":(e.available?"black":"gray")+" !important",fontFamily:m+" !important"},align:"center",paddingX:(g=e.option,g.length>=3?"0px":.5*d+"px"),children:["\xa0",e.option,"\xa0"]}),o&&(0,f.jsx)(y._,{width:"58px",height:"58px",style:{cursor:null!==e&&void 0!==e&&e.available?"pointer":"not-allowed",opacity:null!==e&&void 0!==e&&e.available?1:.5,filter:null!==e&&void 0!==e&&e.available?"none":"grayscale(100%)",borderRadius:o?"50%":"100%"},src:(0,yt.b)(null!==(l=null===t||void 0===t||null===(a=t.finalArr)||void 0===a||null===(s=a.finalArr)||void 0===s||null===(u=s.find((t=>(null===t||void 0===t?void 0:t.color)==(null===e||void 0===e?void 0:e.option))))||void 0===u?void 0:u.src)&&void 0!==l?l:null===t||void 0===t||null===(h=t.finalArr)||void 0===h||null===(p=h.finalArrExternal)||void 0===p||null===(v=p.find((t=>(null===t||void 0===t?void 0:t.color)==(null===e||void 0===e?void 0:e.option))))||void 0===v?void 0:v.optionsrc,"?width=400&height=400")})]},n);var g}))},i)]},i)}))})},Ct=i(6594),St=i(4833);var kt=function(t){var e,i,o,r,a,d;const[s]=(0,v.QN)("isInDesignMode"),[h]=(0,v.QN)("isDemoBrand"),[g]=(0,v.QN)("whatmoreSecondaryColor"),w=(0,v.Xd)("whatmoreSecondaryColorShade900"),[b]=(0,v.QN)("whatmorePrimaryFont"),[C]=(0,v.QN)("whatmoreShopId"),[S,k,I,_]=(0,x.A)(),[z,E]=(0,n.useState)(!1),[T,N]=(0,n.useState)(t.product),F=(0,v.Xd)("whatmoreUITheme"),{whatmoreWidgetSourceDetails:A}=(0,n.useContext)($.B),[P,L,B,O,D,R,W,Q]=ft(0,T,t.event),[V,q]=(0,n.useState)(null),[J,tt]=(0,n.useState)(parseFloat(T.price)),[ot,rt]=(0,n.useState)(parseFloat(T.compare_price)),[lt,at]=(0,n.useState)(null===T||void 0===T?void 0:T.title),[dt,ct]=(0,n.useState)(T.currency),[ut,ht]=(0,n.useState)(null),pt=t.event,vt=t.productClickHandler,{whatmoreIsPreviewMode:xt}=(0,n.useContext)($.B),[mt,gt]=(0,n.useState)(null),[wt,jt]=(0,n.useState)(!1),[kt,It]=(0,n.useState)(!1);if((0,n.useEffect)((()=>{(0,p.w4b)(C)?(0,Ct.ck)(T,(0,p.NCy)(C),C).then((t=>{N(t),tt(parseFloat(t.price)),rt(parseFloat(t.compare_price)),ct(t.currency),jt(!0)})).catch((t=>{jt(!0)})):(async()=>{try{var t,e,i,n,o,r;const l=await(0,m.M)(T,(0,p.NCy)(C),C);ht(l),tt((null!==(t=null===l||void 0===l||null===(e=l.variants)||void 0===e||null===(i=e[0])||void 0===i?void 0:i.price)&&void 0!==t?t:null===l||void 0===l?void 0:l.price)/100),rt((null!==(n=null===l||void 0===l||null===(o=l.variants)||void 0===o||null===(r=o[0])||void 0===r?void 0:r.compare_at_price)&&void 0!==n?n:null===l||void 0===l?void 0:l.compare_at_price)/100),jt(!0)}catch(l){jt(!0)}})(),!(0,p.E8r)(C)||!("in_stock"in pt)||null!==pt&&void 0!==pt&&pt.in_stock||B("errored")}),[]),(0,n.useEffect)((()=>{var t,e;const i=null!=ut?null===ut||void 0===ut||null===(t=ut.options)||void 0===t?void 0:t.findIndex((t=>{var e;return"Colour"==(null===t||void 0===t?void 0:t.name)||(null===t||void 0===t||null===(e=t.name)||void 0===e?void 0:e.toLowerCase().includes("color"))})):-1,n=-1!==i?null===ut||void 0===ut||null===(e=ut.variants)||void 0===e?void 0:e.map((t=>{var e,n;const o=null===t||void 0===t?void 0:t[`option${i+1}`];return null!==t&&void 0!==t&&null!==(e=t.featured_image)&&void 0!==e&&e.src?{color:o,src:null===t||void 0===t||null===(n=t.featured_image)||void 0===n?void 0:n.src}:null})):[];let o=[];var r;-1!==i&&(o=null===ut||void 0===ut||null===(r=ut.images)||void 0===r?void 0:r.map((t=>({color:t.color,src:t.src,optionsrc:t.optionsrc}))));gt({position:i,finalArr:n,finalArrExternal:o})}),[ut]),!wt)return(0,f.jsx)(f.Fragment,{});var _t=.68*_,zt=.55*_t,Et=.4*_t,Tt=_t*(.55-.4),Nt=_t+"px",Ft=Et+"px",At=Tt+"px",Pt=.12*Et;const Lt=(0,p.XQu)(C);function Bt(){window.location.href=function(t){return(0,p.BLb)(C)?t.product_link+"?"+(0,p.VCz)(C)+"&"+(0,p.Spk)(C)+"&"+(0,p.$lz)(C):t.product_link}(T)}const Ot=A.landingLocationType,Dt=A.templateType,Rt=(0,St.Wd)(Ot)+(0,St.gf)(Dt)+(null!==pt&&void 0!==pt&&pt.isRelatedEvent?"R":"E")+"_"+(null===pt||void 0===pt?void 0:pt.event_id),Wt=(0,p.HKH)(C)&&t.activeProductsCount>1&&"init"==P.state&&0==P.cart_count;return(0,f.jsxs)(u.B,{direction:"column",justifyContent:"flex-start",alignContent:"center",marginTop:U,marginBottom:(0,p.qw1)(C),width:Nt,height:"fit-content",boxShadow:"round"==F?"dark-lg":null,onClick:()=>{!function(t,e){s||h||(async()=>{(0,l.Pb)(t,e)})(),"72550089015"==C?Bt():vt(e),E(!0)}(pt,T)},backgroundColor:(0,H.YU)("#ffffff",(0,p.p2R)(C)),animation:z?M.jd:M.so,borderRadius:"round"==F?"xl":null,overflow:"hidden",spacing:0,sx:{borderWidth:(0,p.YcK)(C),borderColor:(0,p.Fwt)(C)},children:[(0,f.jsxs)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-start",alignContent:"center",cursor:"pointer",children:[(0,f.jsx)(c.az,{height:Ft,width:Ft,children:(0,f.jsx)(y._,{className:"product-tile-image",width:Ft,height:Ft,src:(0,yt.b)(null!==(e=null!==(i=null===mt||void 0===mt||null===(o=mt.finalArr)||void 0===o||null===(r=o.find((t=>(null===t||void 0===t?void 0:t.color)==(null===V||void 0===V?void 0:V[null===mt||void 0===mt?void 0:mt.position]))))||void 0===r?void 0:r.src)&&void 0!==i?i:null===mt||void 0===mt||null===(a=mt.finalArrExternal)||void 0===a||null===(d=a.find((t=>(null===t||void 0===t?void 0:t.color)==(null===V||void 0===V?void 0:V[null===mt||void 0===mt?void 0:mt.position]))))||void 0===d?void 0:d.src)&&void 0!==e?e:T.thumbnail_image,"&width=400&height=400"),sx:{objectFit:(0,p.KZe)(C)+" !important"}})}),(0,f.jsxs)(c.az,{height:Ft,width:_t-Et+"px",children:[(0,f.jsxs)(u.B,{direction:"column",className:"wht-pr-title",justifyContent:(0,p.UlM)(C)?"flex-end":"center",alignContent:"center",width:"fit-content",height:"100%",paddingX:"4px",paddingY:"10px",children:[(0,f.jsx)("p",{ref:t=>{t&&(t.style.setProperty("color",(0,p.uoB)(C),"important"),t.style.setProperty("font-size",1.1*Pt*(0,p.rh$)(C)+"px","important"),t.style.setProperty("line-height","120%","important"),t.style.setProperty("font-family",b,"important"),t.style.setProperty("-webkit-line-clamp",2,"important"),t.style.setProperty("line-clamp",2,"important"),t.style.setProperty("-webkit-box-orient","vertical","important"),t.style.setProperty("display","-webkit-box","important"),t.style.setProperty("overflow","hidden","important"),t.style.setProperty("text-overflow","ellipsis","important"),t.style.setProperty("padding","0","important"),t.style.setProperty("margin-bottom","4px","important"),t.style.setProperty("font-weight","normal"))},children:(0,G.v)(lt,"prod-tile")}),(0,p.Nzx)(C)?(0,f.jsxs)(u.B,{className:"whatmore-product-atc-price",direction:(0,p.vw2)(C)?"row":"row-reverse",width:"fit-content",height:"fit-content",justifyContent:"flex-start",alignContent:"center",borderRadius:"round"==F?"lg":null,backgroundColor:"white",paddingX:"8px",paddingY:"4px",sx:{margin:"0px !important",marginBottom:"4px !important"},children:[wt&&(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*Pt*(0,p.rh$)(C)+"px !important",fontWeight:"semibold",lineHeight:"100%",textAlign:"center",sx:{fontFamily:b+" !important",color:(0,p.uoB)(C)+" !important",padding:"0px !important",letterSpacing:"normal !important",margin:"0px !important"},children:["\xa0"," "+(0,Ct.Sb)(null!==J&&void 0!==J?J:null===T||void 0===T?void 0:T.price,"",C,dt)," \xa0"]}),(0,Z.P)(J,ot)&&wt?(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*Pt*(0,p.rh$)(C)+"px !important",fontWeight:"medium !important",lineHeight:"100%",textAlign:"center",sx:{fontFamily:b+" !important",color:(0,p.gld)(C)+" !important",margin:"0px !important",letterSpacing:"normal !important",textDecoration:"line-through !important"},children:[" ",(0,Ct.Sb)(null!==ot&&void 0!==ot?ot:null===T||void 0===T?void 0:T.compare_price,"",C,dt)]}):(0,f.jsx)(f.Fragment,{})]}):(0,f.jsx)(f.Fragment,{}),(0,f.jsx)(j.E,{fontSize:.82*Pt*(0,p.rh$)(C)+"px",fontWeight:"medium",lineHeight:"110%",sx:{margin:"0px !important",fontFamily:b+" !important",color:(0,p.Br1)(C)+" !important"},children:xt?(0,p.p6A)(C):(0,p.i2h)(C)})]}),(0,p.UlM)(C)?(0,f.jsx)(u.B,{className:"whatmore-ios-css-relative-fix",style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:"flex-start",height:"100%",width:"100%",children:(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"fit-content",justifyContent:"flex-end",alignItems:"center",marginTop:"5px",backgroundColor:"transparent",children:[(0,f.jsx)(u.B,{direction:"row",width:"fit-content",height:"fit-content",justifyContent:"center",alignItems:"center",backgroundColor:w,sx:{borderRadius:"round"==F?"5px":"0px",padding:"2px"},spacing:"0px",children:(0,p.SK$)(C)?(0,f.jsx)(nt.$,{size:"sm",_hover:{bg:g},sx:{bg:g},children:(0,f.jsx)(j.E,{color:"white",paddingX:"6px",fontSize:.8*Pt+"px",children:"VIEW PRODUCT"})}):(0,f.jsx)(K.A,{sx:{color:g,fontSize:1.3*Pt+"px"}})}),(0,f.jsx)(c.az,{width:"2px"})]})}):(0,f.jsx)(f.Fragment,{})]})]}),(0,f.jsx)(et.s,{unmountOnExit:!0,initialScale:.5,in:"awaitingVariantSelection"==P.state,style:{height:"fit-content",width:"100%"},children:"awaitingVariantSelection"==P.state&&null!=O?(0,f.jsx)(c.az,{width:"100%",height:"fit-content",marginTop:.1*zt+"px",marginBottom:.1*zt+"px",overflowY:"auto",overflowX:"hidden",maxHeight:zt*Lt+"px",overscrollBehavior:"contain",onTouchStart:t=>{t.stopPropagation()},onTouchEnd:t=>{t.stopPropagation()},children:(0,f.jsx)(bt,{maxHeight:zt*Lt*.5+"px",width:Nt,height:"fit-content",event:pt,product:T,finalArr:mt,data:ut,productVariantOptions:O,baseFontSize:1.2*Pt,onOptionSelected:t=>{!function(t){q(t);const e=W(t);e&&(tt(e.price),rt(e.compare_price),e.title.includes(" ")&&at(e.title))}(t)}})}):(0,f.jsx)(f.Fragment,{})}),(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:At,spacing:0,children:[(0,f.jsx)(u.B,{className:"whatmore-add-to-cart",direction:"row",width:"100%",height:At,children:(0,f.jsx)(st,{baseFontSize:Wt?.2*Tt:.3*Tt,setProductVariantTitle:at,product:T,cartState:P.state,cartCount:P.cart_count,updateCartState:B,onClickAtc:t=>{"init"==P.state?(D(Rt),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_ATC_CLICKED,widgetSourceDetails:A,event:pt,productList:[T],ctaList:pt.cta})):"awaitingVariantSelection"==P.state&&(R(V,Rt),at(null===T||void 0===T?void 0:T.title))},onCartIconClick:()=>{Q()}})}),Wt&&(0,f.jsx)(u.B,{width:"100%",className:"wht-all-atc",sx:{fontSize:.28*Tt,flexDirection:"row",height:"100%",justifyContent:"center",alignItems:"center",bg:"white"},children:(0,f.jsx)(nt.$,{disabled:kt,sx:{cursor:"pointer",width:"100%",height:"100%",display:"flex",justifyContent:"center",alignItems:"center",fontFamily:`${b} !important`,color:"black"},onClick:async t=>{t.stopPropagation();try{It(!0),L(Rt),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_ALL_ATC_CLICKED,widgetSourceDetails:A,event:pt,productList:pt.products,ctaList:pt.cta}),It(!1)}catch(e){console.error("Failed to add items:",e),It(!1)}},children:kt?(0,f.jsx)("div",{className:"whatmore-rotate-indefinitely",children:(0,f.jsx)(it.A,{sx:{filter:"drop-shadow(0 0 15px black)",color:"#F5F5F5",fontSize:.3*Tt*2.5+"px"}})}):(0,f.jsx)(j.E,{fontFamily:b,children:"ADD ALL ITEMS"})})})]})]})},It=i(2835),_t=i(8397);var zt=function(t){var e,i,n,o,r;const[a]=(0,v.QN)("isInDesignMode"),[d]=(0,v.QN)("isDemoBrand"),[h]=(0,v.QN)("whatmoreSecondaryColor"),[x]=(0,v.QN)("whatmorePrimaryFont"),[m]=(0,v.QN)("whatmoreShopId"),[g]=(0,v.QN)("websiteLanguage"),w=t.event,y=t.product,b=null!==(e=t.baseFontSize)&&void 0!==e?e:10,C=null!==(i=t.width)&&void 0!==i?i:"fit-content",S=null!==(n=t.height)&&void 0!==n?n:"fit-content";return(0,f.jsx)(_t.N,{href:y.product_link,color:h,onClick:()=>{!function(t,e){a||d||(async()=>{(0,l.TJ)(t,e)})()}(w,y)},children:(0,f.jsx)(c.az,{width:C,height:S,padding:"2x",boxShadow:"lg",borderRadius:"md",backgroundColor:"white",children:(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"5px",spacing:"5px",children:[(0,f.jsx)(s.o,{children:(0,f.jsx)(j.E,{lineHeight:"100%",fontSize:1.4*b,fontWeight:"semibold",sx:{fontFamily:x+" !important",color:h+" !important"},children:"MORE INFO"!=(0,p.KnH)(m)?(0,p.KnH)(m):null!==(o=null===ot||void 0===ot||null===(r=ot[g])||void 0===r?void 0:r.more_info)&&void 0!==o?o:(0,p.KnH)(m)})}),(0,f.jsx)(s.o,{children:(0,f.jsx)(K.A,{sx:{color:h,fontSize:1.4*b}})})]})})})},Et=i(9408);function Tt(t){var e;const[i]=(0,v.QN)("whatmoreSecondaryColor"),[o]=(0,v.QN)("whatmorePrimaryFont"),[r]=(0,v.QN)("whatmoreShopId"),[l,a]=(0,n.useState)(!1),d=(t.event,t.product,null!==(e=t.baseFontSize)&&void 0!==e?e:10),s=t.onClick,h=t.width,x=t.height,m=t.title;return(0,f.jsx)(c.az,{width:h,height:x,padding:"2x",boxShadow:"lg",backgroundColor:"#000000"==(0,p.Wc_)(r)?i:(0,p.Wc_)(r),onClick:t=>{t.stopPropagation(),s(),a(!0)},animation:l?M.jd:null,onAnimationEnd:()=>{a(!1)},cursor:"pointer",children:(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"2px",children:(0,f.jsxs)(j.E,{as:"p",ref:t=>{t&&t.style.setProperty("min-height","0","important")},lineHeight:"100%",fontSize:1.4*d+"px",fontWeight:"semibold",sx:{fontFamily:o+" !important",color:(0,p.Hfu)(r)+" !important"},children:["\xa0",m,"\xa0"]})})})}var Nt=function(t){var e,i,n;const[o]=(0,v.QN)("whatmoreShopId"),r=t.event,l=t.product,a=null!==(e=t.baseFontSize)&&void 0!==e?e:10,d=t.onShopNowClick,s=null!==(i=t.width)&&void 0!==i?i:"100%",c=null!==(n=t.height)&&void 0!==n?n:"100%";return(0,f.jsx)(Tt,{onClick:function(){d()},event:r,product:l,baseFontSize:a,width:s,height:c,title:(0,p.Qed)(o)})};var Ft=function(t){var e,i,o,r,a;const[d]=(0,v.QN)("isInDesignMode"),[h]=(0,v.QN)("isDemoBrand"),[g]=(0,v.QN)("whatmorePrimaryFont"),[w]=(0,v.QN)("whatmoreShopId"),[b,C,S,k]=(0,x.A)(),[I,_]=(0,n.useState)(!1),[z,E]=(0,n.useState)(t.product),{whatmoreWidgetSourceDetails:T}=(0,n.useContext)($.B),[N,F,A,P,L,B,O,D]=ft(0,z,t.event),[R,W]=(0,n.useState)(null),[Q,V]=(0,n.useState)(parseFloat(z.price)),[H,q]=(0,n.useState)(parseFloat(z.compare_price)),[K,J]=(0,n.useState)(z.currency),[tt,it]=(0,n.useState)(!1),nt=t.event,ot=t.productClickHandler,rt=null!==(e=t.tileWidthFactor)&&void 0!==e?e:1,lt=T.landingLocationType,at=T.templateType,dt=(0,St.Wd)(lt)+(0,St.gf)(at)+(null!==nt&&void 0!==nt&&nt.isRelatedEvent?"R":"E")+"_"+(null===nt||void 0===nt?void 0:nt.event_id);(0,n.useEffect)((()=>{(0,p.w4b)(w)?(0,Ct.ck)(z,(0,p.NCy)(w),w).then((t=>{E(t),V(parseFloat(t.price)),q(parseFloat(t.compare_price)),J(t.currency)})):(async()=>{const t=await(0,m.M)(z,(0,p.NCy)(w),w);V(null===t||void 0===t?void 0:t.price),q(null===t||void 0===t?void 0:t.compare_at_price),it(!0)})()}),[]);var ct=k*rt,ut=.3*ct,ht=ct+"px",pt=.7*ut,vt=.9*pt,xt=.12*ut;const mt=(0,p.XQu)(w);function gt(t,e){d||h||(async()=>{(0,l.Pb)(t,e)})(),ot(e),_(!0)}return(0,f.jsx)(u.B,{direction:"row",width:ht,height:"fit-content",justifyContent:"center",children:(0,f.jsx)(c.az,{marginTop:U,marginBottom:(0,p.qw1)(w),width:ht,onClick:t=>{},animation:I?M.jd:null,borderRadius:"lg",onAnimationEnd:()=>{_(!1)},children:(0,f.jsxs)(u.B,{direction:"column",width:"100%",height:"100%",justifyContent:"center",alignItems:"center",spacing:"0px",children:[(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"70%",justifyContent:"space-around",alignItems:"center",borderTopRadius:"lg",overflow:"hidden",onClick:()=>{gt(nt,z)},children:[(0,f.jsx)(c.az,{height:pt+"px",width:pt+"px",children:(0,f.jsx)(u.B,{direction:"column",justifyContent:"center",alignItems:"center",height:"100%",width:"100%",children:(0,f.jsx)(c.az,{height:vt+"px",width:vt+"px",borderRadius:"lg",bgColor:"gray.100",overflow:"hidden",children:(0,f.jsx)(y._,{width:vt+"px",height:vt+"px",src:z.thumbnail_image,objectFit:"cover"})})})}),(0,f.jsx)(c.az,{height:pt+"px",width:ct-pt+"px",children:(0,f.jsxs)(u.B,{direction:"column",justifyContent:"space-between",alignContent:"center",width:"fit-content",height:"100%",paddingX:"10px",paddingY:"10px",spacing:"2px",children:[(0,f.jsx)(j.E,{style:{overflow:"hidden",textOverflow:"ellipsis"},noOfLines:1,fontSize:1.2*xt+"px",fontWeight:"medium",lineHeight:"120%",sx:{fontFamily:g+" !important",color:"white !important"},children:(0,G.v)(z.title.toString())}),(0,f.jsxs)(u.B,{direction:"row",width:"fit-content",height:"fit-content",justifyContent:"center",alignItems:"center",marginTop:"5px",children:[(0,p.Nzx)(w)?(0,f.jsxs)(u.B,{direction:"row",width:"fit-content",height:"fit-content",justifyContent:"flex-start",alignItems:"center",borderRadius:"lg",backgroundColor:"blackAlpha.500",paddingX:"10px",paddingY:"5px",children:[tt&&(0,f.jsxs)(j.E,{noOfLines:1,fontSize:1*xt+"px",fontWeight:"semibold",lineHeight:"100%",textAlign:"center",sx:{fontFamily:g+" !important",color:"white !important"},children:["\xa0","28849832033"===w?parseFloat(null===nt||void 0===nt||null===(i=nt.products)||void 0===i||null===(o=i[0])||void 0===o?void 0:o.price):(0,Ct.Sb)(null!==Q&&void 0!==Q?Q:null===z||void 0===z?void 0:z.price,"",w,K),"\xa0"]}),(0,f.jsx)(s.o,{children:(0,Z.P)(z.price,z.compare_price)&&tt?(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.8*xt+"px",fontWeight:"medium",lineHeight:"100%",textAlign:"center",sx:{fontFamily:g+" !important",color:"#F9F6EE !important",textDecoration:"line-through !important"},children:[" ","28849832033"===w?parseFloat(null===nt||void 0===nt||null===(r=nt.products)||void 0===r||null===(a=r[0])||void 0===a?void 0:a.compare_price):(0,Ct.Sb)(null!==H&&void 0!==H?H:null===z||void 0===z?void 0:z.compare_price,"",w,K)]}):(0,f.jsx)(f.Fragment,{})})]}):(0,f.jsx)(f.Fragment,{}),(0,f.jsx)(s.o,{children:(0,f.jsx)(It.A,{storeId:w,productId:z.client_product_id,productLink:z.product_link,fontSize:1*xt,fontColor:"white"})})]})]})})]}),(0,f.jsx)(et.s,{unmountOnExit:!0,initialScale:.5,in:"awaitingVariantSelection"==N.state,style:{height:"fit-content",width:"100%"},children:"awaitingVariantSelection"==N.state&&null!=P?(0,f.jsx)(c.az,{width:"100%",height:"fit-content",marginTop:.1*ut+"px",marginBottom:.1*ut+"px",overflowY:"auto",overflowX:"hidden",maxHeight:ut*mt+"px",overscrollBehavior:"contain",onTouchStart:t=>{t.stopPropagation()},onTouchEnd:t=>{t.stopPropagation()},children:(0,f.jsx)(bt,{width:ht,height:"fit-content",event:nt,product:z,productVariantOptions:P,baseFontSize:1*xt,onOptionSelected:t=>{!function(t){W(t);const e=O(t);e&&(V(e.price),q(e.compare_price))}(t)},optionTitleColor:"white"})}):(0,f.jsx)(f.Fragment,{})}),(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"30%",justifyContent:"center",alignItems:"center",paddingBottom:"2px",paddingLeft:"2px",paddingRight:"2px",children:[(0,f.jsx)(c.az,{width:"100%",height:"100%",children:(0,f.jsx)(zt,{baseFontSize:.8*xt,event:nt,product:z,width:"100%",height:"100%"})}),(0,f.jsx)(c.az,{width:"100%",height:"100%",borderRadius:"md",overflow:"hidden",children:(0,p.ZzM)(w)?(0,f.jsx)(Nt,{baseFontSize:.8*xt,event:nt,product:z,borderRadius:"md",onShopNowClick:t=>{gt(nt,z)}}):(0,f.jsx)(f.Fragment,{children:"form"===(0,p.nWM)(w)?(0,f.jsx)(Et.default,{baseFontSize:.8*xt,event:nt,product:z,width:"100%",height:"100%",showAddedToCart:!0}):(0,f.jsx)(st,{baseFontSize:.8*xt,event:nt,product:z,cartState:N.state,cartCount:N.cart_count,borderRadius:"md",onClickAtc:t=>{"init"==N.state?(L(dt),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_ATC_CLICKED,widgetSourceDetails:T,event:nt,productList:[z],ctaList:nt.cta})):"awaitingVariantSelection"==N.state&&B(R,dt)},onCartIconClick:()=>{D()}})})})]})]})})})},At=i(7740);var Pt=function(t){const[e]=(0,v.QN)("isInDesignMode"),[i]=(0,v.QN)("isDemoBrand"),[o]=(0,v.QN)("whatmoreSecondaryColor"),r=(0,v.Xd)("whatmoreSecondaryColorShade900"),[a]=(0,v.QN)("whatmorePrimaryFont"),[d]=(0,v.QN)("whatmoreShopId"),[s,h,g,w]=(0,x.A)(),[b,C]=(0,n.useState)(!1),[S,k]=(0,n.useState)(t.product),I=(0,v.Xd)("whatmoreUITheme"),[_,z]=(0,n.useState)(!1),[E,T]=(0,n.useState)(parseFloat(S.price)),[N,F]=(0,n.useState)(parseFloat(S.compare_price)),[A,P]=(0,n.useState)(S.currency),L=t.event,[B,O]=(0,n.useState)();if((0,n.useEffect)((()=>{(0,p.w4b)(d)?(0,Ct.ck)(S,(0,p.NCy)(d),d).then((t=>{k(t),T(parseFloat(t.price)),F(parseFloat(t.compare_price)),P(t.currency),z(!0)})).catch((t=>z(!0))):(async()=>{try{var t,e,i,n,o,r;const l=await(0,m.M)(S,(0,p.NCy)(d),d);O(l),T((null!==(t=null===l||void 0===l||null===(e=l.variants)||void 0===e||null===(i=e[0])||void 0===i?void 0:i.price)&&void 0!==t?t:null===l||void 0===l?void 0:l.price)/100),F((null!==(n=null===l||void 0===l||null===(o=l.variants)||void 0===o||null===(r=o[0])||void 0===r?void 0:r.compare_at_price)&&void 0!==n?n:null===l||void 0===l?void 0:l.compare_at_price)/100),z(!0)}catch(l){z(!0)}})()}),[]),!_)return(0,f.jsx)(f.Fragment,{});var D=.68*w,R=.4*D,W=D+"px",Q=R+"px",V=D*(.55-.4)+"px",q=.12*R;(0,p.XQu)(d);const{whatmoreWidgetSourceDetails:J}=(0,n.useContext)($.B);function tt(t){return(0,p.BLb)(d)?t.product_link+"?"+(0,p.VCz)(d)+"&"+(0,p.Spk)(d)+"&"+(0,p.$lz)(d):t.product_link}function et(t,n){e||i||(async()=>{(0,l.Pb)(t,n),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_SHOPNOW_CLICKED,widgetSourceDetails:J,event:t,productList:[n],ctaList:t.cta})})(),C(!0)}return(0,f.jsxs)(u.B,{direction:"column",justifyContent:"flex-start",alignContent:"center",marginTop:U,marginBottom:(0,p.qw1)(d),width:W,height:"fit-content",boxShadow:"round"==I?"dark-lg":null,onClick:()=>{et(L,S),window.location.href=tt(S)},backgroundColor:(0,H.YU)("#ffffff",(0,p.p2R)(d)),animation:b?M.jd:M.so,borderRadius:"round"==I?"xl":null,overflow:"hidden",spacing:0,sx:{borderWidth:(0,p.YcK)(d),borderColor:(0,p.Fwt)(d)},children:[(0,f.jsxs)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-start",alignContent:"center",cursor:"pointer",children:[(0,f.jsx)(c.az,{height:Q,width:Q,children:(0,f.jsx)(y._,{width:Q,height:Q,src:(0,yt.b)(S.thumbnail_image,"&width=400&height=400"),sx:{objectFit:(0,p.KZe)(d)+" !important"}})}),(0,f.jsxs)(c.az,{height:Q,width:D-R+"px",children:[(0,f.jsxs)(u.B,{direction:"column",justifyContent:(0,p.UlM)(d)?"flex-end":"center",alignContent:"center",width:"fit-content",height:"100%",paddingX:"10px",paddingTop:"10px",paddingBottom:"16px",children:[(0,f.jsx)(j.E,{as:"p",ref:t=>{t&&(t.style.setProperty("min-height","0","important"),t.style.setProperty("-webkit-line-clamp",2,"important"),t.style.setProperty("line-clamp",2,"important"),t.style.setProperty("overflow","hidden","important"),t.style.setProperty("display","-webkit-box","important"),t.style.setProperty("-webkit-box-orient","vertical","important"))},sx:{paddingLeft:"8px",fontFamily:a+" !important",color:"black !important",lineHeight:"120% !important",fontWeight:"medium !important",fontSize:1.1*q+"px !important"},children:(0,G.v)(null==S.title?"":S.title.toString(),"prod-tile")}),(0,p.Nzx)(d)?(0,f.jsxs)(u.B,{className:"whatmore-product-shopnow-price",direction:(0,p.vw2)(d)?"row":"row-reverse",width:"fit-content",height:"fit-content",justifyContent:"flex-start",alignContent:"center",marginTop:"5px",borderRadius:"round"==I?"lg":null,backgroundColor:"white",paddingX:"8px",paddingY:"5px",children:[_&&(0,f.jsxs)(j.E,{as:"p",ref:t=>{t&&t.style.setProperty("min-height","0","important")},noOfLines:1,fontSize:.9*q+"px",fontWeight:"semibold",lineHeight:"100%",textAlign:"center",sx:{fontFamily:a+" !important",color:(0,p.uoB)(d)+" !important",margin:"0px !important"},children:[" "+(0,Ct.Sb)(null!==E&&void 0!==E?E:null===S||void 0===S?void 0:S.price,"",d,A)," \xa0"]}),(0,Z.P)(E,N)&&_?(0,f.jsxs)(j.E,{as:"s",style:{minHeight:0,textDecoration:"line-through"},noOfLines:1,fontSize:.9*q+"px",fontWeight:"medium",lineHeight:"100%",textAlign:"center",sx:{fontFamily:a+" !important",color:(0,p.gld)(d)+" !important",margin:"0px !important"},children:[" ",(0,Ct.Sb)(null!==N&&void 0!==N?N:null===S||void 0===S?void 0:S.compare_price,"",d,A)]}):(0,f.jsx)(f.Fragment,{})]}):(0,f.jsx)(f.Fragment,{}),""!=(0,p.rsz)(d)&&(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*q+"px",lineHeight:"100%",paddingTop:"6px",sx:{fontFamily:(0,p.ogW)(d)+" !important",color:(0,p._zx)(d)+" !important",margin:"0px !important"},children:["\xa0",(0,p.rsz)(d)," \xa0"]})]}),(0,p.UlM)(d)?(0,f.jsx)(u.B,{className:"whatmore-ios-css-relative-fix",style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:"flex-start",height:"100%",width:"100%",children:(0,f.jsxs)(u.B,{direction:"row",width:"100%",height:"fit-content",justifyContent:"flex-end",alignItems:"center",marginTop:"5px",backgroundColor:"transparent",children:[(0,f.jsx)(u.B,{direction:"row",width:"fit-content",height:"fit-content",justifyContent:"center",alignItems:"center",backgroundColor:r,sx:{borderRadius:"round"==I?"5px":"0px",padding:"2px"},spacing:"0px",children:(0,f.jsx)(K.A,{sx:{color:o,fontSize:1.3*q+"px"}})}),(0,f.jsx)(c.az,{width:"2px"})]})}):(0,f.jsx)(f.Fragment,{})]})]}),(0,p.Woi)(d)&&(0,f.jsx)(u.B,{direction:"row",width:"100%",height:V,justifyContent:"center",alignItems:"center",children:(0,f.jsx)(Nt,{baseFontSize:.8*q,event:L,product:S,borderRadius:"md",onShopNowClick:t=>{et(L,S),window.location.href=tt(S)}})})]})};function Lt(t){var e;const[i]=(0,v.QN)("whatmoreSecondaryColor"),[o]=(0,v.QN)("whatmorePrimaryFont"),[r]=(0,v.QN)("whatmoreShopId"),[l,a]=(0,n.useState)(!1),d=null!==(e=t.baseFontSize)&&void 0!==e?e:10,s=t.onClick,h=t.width,x=t.height,m=t.title,g=t.showInProgressIcon;return"awaitingVariantSelection"==t.cartState||"productVariantDetailsApiCallInProgress"==t.cartState?(0,f.jsx)(Bt,{onClick:()=>t.onClick(),event:t.event,product:t.product,baseFontSize:d,width:h,height:x}):(0,f.jsxs)(c.az,{display:"flex",width:"fit-content",minWidth:"75%",padding:"2x",boxShadow:"lg",animation:l?M.jd:null,onAnimationEnd:()=>{a(!1)},cursor:"pointer",children:["awaitingVariantSelection"==t.cartState&&(0,f.jsx)(u.B,{direction:"row",alignItems:"center",justifyContent:"center",paddingY:"2px",backgroundColor:"white",onClick:e=>{e.stopPropagation(),t.updateCartState("init"),a(!0)},children:(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*d+"px !important",fontWeight:"semibold !important",sx:{fontFamily:o+" !important",color:"#343434 !important"},children:["\xa0","63064310011"==r?"Annuler":"Cancel","\xa0"]})}),(0,f.jsxs)(u.B,{direction:"row",backgroundColor:g?(0,H.YU)(i,8):i,width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"2px",onClick:t=>{t.stopPropagation(),s(),a(!0)},children:[(0,f.jsxs)(j.E,{lineHeight:"100%",fontSize:1.4*d+"px !important",fontWeight:"semibold !important",sx:{fontFamily:o+" !important",color:(0,p.Hfu)(r)+" !important"},children:["\xa0",m,"\xa0"]}),g?(0,f.jsx)("div",{className:"whatmore-rotate-indefinitely",children:(0,f.jsx)(it.A,{sx:{filter:"drop-shadow(0 0 15px black);",color:"#F5F5F5",fontSize:2.5*d+"px"}})}):(0,f.jsx)(f.Fragment,{})]})]})}function Bt(t){const[e]=(0,v.QN)("whatmoreSecondaryColor"),[i]=(0,v.QN)("whatmorePrimaryFont"),[o]=(0,v.QN)("whatmoreShopId"),[r,l]=(0,n.useState)(!1),a=t.onClick,d=t.baseFontSize;return(0,f.jsx)(u.B,{direction:"row",paddingBottom:"3%",position:"relative",children:(0,f.jsx)(c.az,{width:"fit-content",minWidth:"75%",boxShadow:"lg",padding:"6px 12px",borderRadius:"6px",backgroundColor:e,onClick:t=>{t.stopPropagation(),a(),l(!0)},animation:r?M.jd:null,onAnimationEnd:()=>{l(!1)},cursor:"pointer",zIndex:"1000",children:(0,f.jsx)(u.B,{direction:"row",width:"100%",height:"100%",alignItems:"center",justifyContent:"center",paddingY:"5px",children:(0,f.jsx)(s.o,{children:(0,f.jsx)(j.E,{lineHeight:"100%",fontSize:1.3*d+"px",fontWeight:"semibold",sx:{fontFamily:`${i} !important`,color:`${(0,p.Hfu)(o)} !important`},children:(0,p.KPq)(o)})})})})})}function Ot(t){var e;const[i]=(0,v.QN)("whatmorePrimaryFont"),n=null!==(e=t.baseFontSize)&&void 0!==e?e:10;t.width,t.height;return(0,f.jsx)(c.az,{width:"fit-content",height:"fit-content !important",minWidth:"75%",boxShadow:"lg",backgroundColor:"white",borderRadius:"6px",borderColor:"gray",borderWidth:"1px",onClick:t=>{t.stopPropagation()},children:(0,f.jsx)(u.B,{direction:"row",width:"100%",alignItems:"center",paddingX:"4px",paddingY:"3px",justifyContent:"center",children:(0,f.jsxs)(j.E,{color:"gray",lineHeight:"100%",fontSize:1.2*n+"px !important",fontWeight:"semibold !important",sx:{fontFamily:i+" !important",color:"gray !important"},children:["\xa0"," Sold Out ","\xa0"]})})})}function Dt(t){var e;const[i]=(0,v.QN)("whatmoreSecondaryColor"),[n]=(0,v.QN)("whatmorePrimaryFont"),[o]=(0,v.QN)("whatmoreShopId"),r=(t.event,t.product,null!==(e=t.baseFontSize)&&void 0!==e?e:10),l=t.onClick,a=t.cartCount,d=(t.width,t.height,t.onCartIconClick);return(0,f.jsx)(c.az,{width:"fit-content",minWidth:"75%",borderRadius:"6px",padding:"2x",boxShadow:"lg",backgroundColor:"white",borderColor:i,borderWidth:"1px",onClick:t=>{t.stopPropagation()},cursor:"pointer",children:(0,f.jsxs)(u.B,{direction:"row",alignItems:"center",paddingX:"4px",paddingY:"5px",justifyContent:"center",children:[(0,f.jsx)(s.o,{paddingX:"5px",onClick:()=>{d()},children:"1972174947"!=o&&"55194878152"!=o&&"12181504100"!=o?(0,f.jsx)(tt.A,{sx:{color:i,fontSize:1.6*r}}):(0,f.jsx)(nt.$,{size:"sm",_hover:{bg:i},sx:{bg:i},children:(0,f.jsx)(j.E,{paddingX:"6px",color:"white",sx:{fontSize:.85*r},children:"GO TO CART"})})}),(0,f.jsx)(j.E,{color:i,fontSize:1.3*r+"px !important",fontWeight:"semibold !important",sx:{fontFamily:n+" !important"},children:a}),(0,f.jsx)(s.o,{paddingX:"5px",onClick:t=>{t.stopPropagation(),l()},children:(0,f.jsx)(J.A,{sx:{color:i,fontSize:1.6*r}})})]})})}var Rt=function(t){var e,i,n,o;const[r]=(0,v.QN)("whatmoreShopId"),l=t.event,a=t.product,d=null!==(e=t.baseFontSize)&&void 0!==e?e:10,s=null===(i=t.showAddedToCart)||void 0===i||i,c=t.cartState,u=t.cartCount,h=t.onClickAtc,p=t.onCartIconClick;function x(){h()}const m=null!==(n=t.width)&&void 0!==n?n:"100%",g=null!==(o=t.height)&&void 0!==o?o:"100%";return"errored"==c?(0,f.jsx)(et.s,{unmountOnExit:!0,in:!0,initialScale:.5,style:{},children:(0,f.jsx)(Ot,{event:l,product:a,baseFontSize:d,width:m,height:g})}):"init"==c?0==u?(0,f.jsx)(Bt,{onClick:x,event:l,product:a,baseFontSize:d,width:m,height:g}):s?(0,f.jsx)(et.s,{unmountOnExit:!0,in:!0,initialScale:.5,children:(0,f.jsx)(Dt,{onClick:x,event:l,product:a,baseFontSize:d,cartCount:u,width:m,height:g,onCartIconClick:p})}):(0,f.jsx)(Bt,{onClick:x,event:l,product:a,baseFontSize:d,width:m,height:g}):(0,f.jsx)(Lt,{onClick:x,cartState:c,updateCartState:t.updateCartState,event:l,product:a,baseFontSize:d,width:m,height:g,title:"awaitingVariantSelection"==c?"63064310011"==r?"Valider":"Done":"",showInProgressIcon:"atcApiCallInProgress"==c||"productVariantDetailsApiCallInProgress"==c})};var Wt=function(t){var e,i,o,r,a,d;const[s]=(0,v.QN)("isInDesignMode"),[h]=(0,v.QN)("isDemoBrand"),[g]=(0,v.QN)("whatmorePrimaryFont"),[w]=(0,v.QN)("whatmoreShopId"),[b,C,S,k]=(0,x.A)(),[I,_]=(0,n.useState)(!1),[z,E]=(0,n.useState)(t.product),T=(0,v.Xd)("whatmoreUITheme"),{whatmoreWidgetSourceDetails:N}=(0,n.useContext)($.B),[F,A,P,L,B,O,D,R]=ft(0,z,t.event),[W,Q]=(0,n.useState)(null),[V,q]=(0,n.useState)(parseFloat(z.price)),[K,J]=(0,n.useState)(parseFloat(z.compare_price)),[tt,et]=(0,n.useState)(z.currency),[it,nt]=(0,n.useState)(null),ot=t.event,rt=t.productClickHandler,[lt,at]=(0,n.useState)(null),[dt,st]=(0,n.useState)(!1),ct=N.landingLocationType,ut=N.templateType,ht=(0,St.Wd)(ct)+(0,St.gf)(ut)+"_"+(null===ot||void 0===ot?void 0:ot.event_id);(0,n.useEffect)((()=>{(0,p.w4b)(w)?(0,Ct.ck)(z,(0,p.NCy)(w),w).then((t=>{E(t),q(parseFloat(t.price)),J(parseFloat(t.compare_price)),et(t.currency),st(!0)})):(async()=>{var t,e,i,n,o,r;const l=await(0,m.M)(z,(0,p.NCy)(w),w);nt(l),q((null!==(t=null===l||void 0===l||null===(e=l.variants)||void 0===e||null===(i=e[0])||void 0===i?void 0:i.price)&&void 0!==t?t:null===l||void 0===l?void 0:l.price)/100),J((null!==(n=null===l||void 0===l||null===(o=l.variants)||void 0===o||null===(r=o[0])||void 0===r?void 0:r.compare_at_price)&&void 0!==n?n:null===l||void 0===l?void 0:l.compare_at_price)/100),st(!0)})(),!(0,p.E8r)(w)||null!==ot&&void 0!==ot&&ot.in_stock||P("errored")}),[]),(0,n.useEffect)((()=>{var t,e;const i=null!=it?null===it||void 0===it||null===(t=it.options)||void 0===t?void 0:t.findIndex((t=>{var e;return"Colour"==(null===t||void 0===t?void 0:t.name)||(null===t||void 0===t||null===(e=t.name)||void 0===e?void 0:e.toLowerCase().includes("color"))})):-1,n=-1!==i?null===it||void 0===it||null===(e=it.variants)||void 0===e?void 0:e.map((t=>{var e,n;const o=null===t||void 0===t?void 0:t[`option${i+1}`];return null!==t&&void 0!==t&&null!==(e=t.featured_image)&&void 0!==e&&e.src?{color:o,src:null===t||void 0===t||null===(n=t.featured_image)||void 0===n?void 0:n.src}:null})):[];let o=[];var r;-1!==i&&(o=null===it||void 0===it||null===(r=it.images)||void 0===r?void 0:r.map((t=>({color:t.color,src:t.src,optionsrc:t.optionsrc}))));at({position:i,finalArr:n,finalArrExternal:o})}),[it]);var pt=.72*k,vt=.37*pt,xt=pt*(.48-.37),mt=.95*pt+"px",gt=vt+"px",wt=.12*vt;function jt(){window.location.href=function(t){return(0,p.BLb)(w)?t.product_link+"?"+(0,p.VCz)(w)+"&"+(0,p.Spk)(w)+"&"+(0,p.$lz)(w):t.product_link}(z)}return(0,f.jsx)(u.B,{direction:"column",justifyContent:"flex-start",alignContent:"center",marginTop:U,marginBottom:"24px",width:mt,boxShadow:"round"==T?"dark-lg":null,onClick:()=>{!function(t,e){s||h||(async()=>{(0,l.Pb)(t,e)})(),"72550089015"==w?jt():rt(e),_(!0)}(ot,z)},backgroundColor:(0,H.YU)("#ffffff",(0,p.p2R)(w)),animation:I?M.jd:null,borderRadius:"round"==T?"xl":null,overflow:"hidden",onAnimationEnd:()=>{_(!1)},spacing:0,sx:{borderWidth:(0,p.YcK)(w),borderColor:(0,p.Fwt)(w)},children:(0,f.jsxs)(u.B,{display:"flex",direction:"row",width:"full",height:"fit-content",justifyContent:"center",alignContent:"center",cursor:"pointer",alignItems:"center",gap:"8px",children:[(0,f.jsx)(c.az,{height:gt,width:gt,children:(0,f.jsx)(y._,{width:"100%",height:"100%",src:(0,yt.b)(null!==(e=null!==(i=null===lt||void 0===lt||null===(o=lt.finalArr)||void 0===o||null===(r=o.find((t=>(null===t||void 0===t?void 0:t.color)==(null===W||void 0===W?void 0:W[null===lt||void 0===lt?void 0:lt.position]))))||void 0===r?void 0:r.src)&&void 0!==i?i:null===lt||void 0===lt||null===(a=lt.finalArrExternal)||void 0===a||null===(d=a.find((t=>(null===t||void 0===t?void 0:t.color)==(null===W||void 0===W?void 0:W[null===lt||void 0===lt?void 0:lt.position]))))||void 0===d?void 0:d.src)&&void 0!==e?e:z.thumbnail_image,"&width=400&height=400"),sx:{objectFit:(0,p.KZe)(w)+" !important"}})}),(0,f.jsx)(c.az,{height:gt,width:pt-vt+"px",children:(0,f.jsxs)(u.B,{direction:"column",justifyContent:"flex-start",height:"100%",gap:"4px",paddingTop:"12px",width:"100%",children:[(0,f.jsx)("p",{ref:t=>{t&&(t.style.setProperty("color","black","important"),t.style.setProperty("font-size",wt+"px","important"),t.style.setProperty("line-height","120%","important"),t.style.setProperty("font-family",g,"important"),t.style.setProperty("white-space","nowrap","important"),t.style.setProperty("overflow","hidden","important"),t.style.setProperty("text-overflow","ellipsis","important"),t.style.setProperty("padding","0","important"),t.style.setProperty("font-weight","normal","important"))},children:(0,G.v)(null==z.title?"":z.title.toString())}),(0,p.Nzx)(w)?(0,f.jsxs)(u.B,{direction:(0,p.vw2)(w)?"row":"row-reverse",sx:{margin:"0px !important",minHeight:1.1*wt+"px"},children:[dt&&(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*wt*(0,p.rh$)(w)+"px !important",lineHeight:"100%",sx:{fontFamily:g+" !important",color:(0,p.uoB)(w)+" !important",fontWeight:"bold"},children:[" "+(0,Ct.Sb)(null!==V&&void 0!==V?V:null===z||void 0===z?void 0:z.price,"",w,tt)," \xa0"]}),(0,Z.P)(V,K)&&dt?(0,f.jsxs)(j.E,{noOfLines:1,fontSize:.9*wt*(0,p.rh$)(w)+"px !important",fontWeight:"medium !important",lineHeight:"100%",textAlign:"center",sx:{fontFamily:g+" !important",color:(0,p.gld)(w)+" !important",margin:"0px !important",letterSpacing:"normal !important",textDecoration:"line-through !important"},children:[" ",(0,Ct.Sb)(null!==K&&void 0!==K?K:null===z||void 0===z?void 0:z.compare_price,"",w,tt)]}):(0,f.jsx)(f.Fragment,{})]}):(0,f.jsx)(f.Fragment,{}),(0,f.jsx)(Rt,{baseFontSize:.3*xt,event:ot,product:z,cartState:F.state,cartCount:F.cart_count,updateCartState:P,onClickAtc:t=>{"init"===F.state?(B(ht,!0),(0,X.kz)({userInteractionType:Y.O.PRODUCT_TILE_ATC_CLICKED,widgetSourceDetails:N,event:ot,productList:[z],ctaList:ot.cta})):"awaitingVariantSelection"===F.state&&rt(z)},onCartIconClick:t=>{R()}})]})})]})})};var Qt=function(t){const[e]=(0,v.QN)("whatmoreShopId"),[i]=(0,v.QN)("isWhatmoreWebsite"),n=(0,p.Vpi)(e),o=t.event,r=t.product;return i?(0,f.jsx)(Pt,{product:t.product,event:t.event,productClickHandler:t.productClickHandler}):"broad-tile"==n?(0,f.jsx)(kt,{product:t.product,event:t.event,productClickHandler:t.productClickHandler,activeProductsCount:t.activeProductsCount}):"broad-tile-no-cta"==n?(0,f.jsx)(Pt,{product:t.product,event:t.event,productClickHandler:t.productClickHandler}):"broad-tile-new-atc"==n?(0,f.jsx)(Wt,{product:t.product,event:t.event,productClickHandler:t.productClickHandler}):"link_only"==n?(0,f.jsx)(q,{product:t.product,event:t.event}):"narrow-tile"==n?(0,f.jsx)(Ft,{event:o,product:r,productClickHandler:t.productClickHandler,tileWidthFactor:o.products.length>1?.68:void 0}):(0,f.jsx)(f.Fragment,{})},Vt=i(1079),Mt=i(7802),Ht=i(2979);var Ut=function(t){var e,i,n;const[l,a,d,h]=(0,x.A)(),[m]=(0,v.QN)("whatmoreShopId"),g=(0,v.Xd)("isInDesignMode"),w=(0,v.Xd)("isDemoBrand"),j=t.event,y=t.productClickHandler,b=(0,p.Vpi)(m),C=null!==(e=null===(i=j.products)||void 0===i||null===(n=i.filter((t=>"active"==(null===t||void 0===t?void 0:t.product_status))))||void 0===n?void 0:n.length)&&void 0!==e?e:0;if(!(0,Mt.Z_)(j))return(0,f.jsx)(f.Fragment,{});if(1==j.products.length&&(void 0==j.cta||0==j.cta.length)){const t=j.products[0];return(0,p.uJl)(m)?(0,f.jsx)(u.B,{direction:"horizontal",width:h,height:"fit-content",justifyContent:"center",backgroundImage:"linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.4), rgba(0,0,0,0.6), rgba(0,0,0,0.8))",children:(0,f.jsx)(Ht.S,{userInteractionType:Y.O.PRODUCT_CTA_VIEW,event:j,productList:[t],triggerFlag:!g&&!w,children:(0,f.jsx)(s.o,{children:(0,f.jsx)(Ft,{event:j,product:t,productClickHandler:y},j.event_id+t.product_id)})})}):(0,f.jsx)(u.B,{direction:"horizontal",width:h,height:"fit-content",justifyContent:"center",backgroundImage:"narrow-tile"==b?"linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.4), rgba(0,0,0,0.6), rgba(0,0,0,0.8))":null,children:(0,f.jsx)(s.o,{children:(0,f.jsx)(Ht.S,{userInteractionType:Y.O.PRODUCT_CTA_VIEW,event:j,productList:[t],triggerFlag:!g&&!w,children:(0,f.jsx)(Qt,{activeProductsCount:1,event:j,product:t,productClickHandler:y},j.event_id+t.product_id)})})})}return(0,f.jsx)(s.o,{children:(0,f.jsx)("div",{onTouchStart:t=>{t.stopPropagation()},onTouchEnd:t=>{t.stopPropagation()},children:(0,f.jsx)(c.az,{width:h+"px",backgroundImage:"narrow-tile"==b?"linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.4), rgba(0,0,0,0.6), rgba(0,0,0,0.8))":null,children:(0,f.jsxs)(o.RC,{className:"product-tile swiper-slide",slidesPerView:1==j.products.length?1:1.4,initialSlide:j.products.length<=2||(0,p.TYM)(m)?0:1,centeredSlides:!(0,p.TYM)(m),modules:[r.FJ],mousewheel:{invert:!1,thresholdDelta:20},nested:!0,children:[("STRDOIDF6O7"===m?[j.products[0]]:j.products).map((t=>("oos"!=t.product_status||(0,p.$7F)(m))&&(0,f.jsx)(o.qr,{children:(0,f.jsx)(Ht.S,{userInteractionType:Y.O.PRODUCT_CTA_VIEW,event:j,productList:[t],triggerFlag:!g&&!w,children:(0,f.jsx)(u.B,{direction:"column",height:"100%",width:"100%",justifyContent:"flex-end",alignItems:"center",children:(0,f.jsx)(Qt,{activeProductsCount:C,event:j,product:t,productClickHandler:y},j.event_id+t.product_id)})})},j.event_id+t.product_id))),(0,p.Woi)(m)&&void 0!=j.cta&&j.cta.map((t=>(0,f.jsx)(f.Fragment,{children:""!==t.cta_title.trim()&&(0,f.jsx)(o.qr,{children:(0,f.jsx)(u.B,{direction:"column",height:"100%",width:"100%",justifyContent:"flex-end",paddingBottom:"12px",alignItems:"center",children:(0,f.jsx)(Vt.A,{fontFactor:.75,cta:t},j.event_id+t.cta_id)})},j.event_id+t.cta_id)})))]})})})})};var Xt=function(t){const[e,i]=(0,v.QN)("isProductSwiperCatalogOpen"),o=t.event,r=t.productClickHandler;return(0,n.useContext)(Ni).isIOS&&e?(0,f.jsx)(Ut,{event:o,productClickHandler:r},o.event_id):(0,f.jsx)(O.J,{unmountOnExit:!0,initialScale:.2,in:e,children:(0,f.jsx)(Ut,{event:o,productClickHandler:r},o.event_id)})};function Yt(t){const e=t.event,[i,n,o,r]=(0,x.A)(),[l]=(0,v.QN)("whatmorePrimaryFont");return(0,f.jsx)(c.az,{width:"fit-content",height:"fit-content",padding:"5px",children:(0,f.jsxs)(u.B,{direction:"row",width:"fit-content",height:"fit-content",children:[(0,f.jsx)(s.o,{children:(0,f.jsx)(c.jl,{overflow:"hidden",size:.15*r+"px",children:(0,f.jsx)(y._,{width:"100%",height:"100%",src:e.thumbnail_image})})}),(0,f.jsx)(c.az,{width:"fit-content",height:"fit-content",children:(0,f.jsxs)(u.B,{direction:"column",width:"fit-content",height:"fit-content",children:[(0,f.jsx)(j.E,{color:"white",fontSize:.05*r+"px",fontWeight:"bold",fontFamily:"sans-serif",align:"left",sx:{fontFamily:l+" !important"},children:e.presenter_name.substring(0,15)}),(0,f.jsx)(L.A,{event:e,fontSize:.03*r+"px"})]})})]})})}var $t=function(t){const[e]=(0,v.QN)("isInDesignMode"),[i]=(0,v.QN)("isDemoBrand"),[o,r]=(0,v.QN)("isProductSwiperCatalogOpen"),[l,a]=(0,S.A)(),[d,s]=(0,v.QN)("isFirstIndicatorRenderDone"),h=(0,n.useContext)(Ni),[x]=(0,v.QN)("whatmoreShopId"),m=t.event,g=t.isLast,w=t.onCloseCallback,j=t.focusRef,y=t.productClickHandler;return(0,f.jsx)(c.az,{width:"full",height:"full",borderRadius:"md",children:(0,f.jsxs)(u.B,{direction:"column",width:"full",height:"full",justifyContent:"space-between",children:[(0,f.jsx)(c.az,{width:"full",margin:"2px",bgGradient:"linear(to-t, transparent, whiteAlpha.100, blackAlpha.200, blackAlpha.400, blackAlpha.800)",children:(0,f.jsxs)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"space-between",paddingRight:"10px",paddingLeft:"10px",children:[(0,f.jsx)(Yt,{event:m}),(0,f.jsxs)(u.B,{direction:"row",width:"fit-content",justifyContent:"end",paddingLeft:"10px",children:[(0,f.jsx)(k,{focusRef:j}),(0,f.jsx)(B.A,{event:m,onCloseCallback:w})]})]})}),(0,f.jsx)(c.az,{width:"100%",height:"100%",onClick:()=>{a(!l)}}),(0,f.jsxs)(c.az,{width:"full",height:"fit-content",children:[h.totalEvents>1&&!d&&h.showSwipeIndicator?(0,f.jsx)(c.az,{width:"full",margin:"2px",children:(0,f.jsx)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"center",children:(0,f.jsx)(Q,{swipeUp:!g})})}):null,void 0!=m.products&&m.products.length>0?(0,f.jsxs)(c.az,{width:"full",children:[(0,p.ek9)(x)?(0,f.jsx)(c.az,{w:"100%",children:(0,f.jsx)(u.B,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,f.jsx)(P,{event:m,onToggle:t=>{r("minimize-button"!==t)}})})}):(0,f.jsx)(f.Fragment,{}),(0,f.jsx)(c.az,{display:"flex",width:"100%",height:"fit-content",children:(0,f.jsx)(Xt,{event:m,productClickHandler:y})})]}):(0,f.jsx)("div",{})]})]})})},qt=i(7642);function Kt(t){const[e,i,o,r]=(0,x.A)(),[l]=(0,v.QN)("whatmorePrimaryFont"),[a]=(0,v.QN)("whatmoreShopId"),[d,s]=(0,n.useState)(""),h=t.data,m=(t.event,t.product,t.setShowOptionsChart);var g=.4*r*.8*.13;(0,n.useEffect)((()=>{let t="vanyaclothing.myshopify.com";"1972174947"===a?t="vanyaclothing.myshopify.com":"57415434338"===a&&(t="usvanya.myshopify.com");const e=`https://app.kiwisizing.com/api/getSizingChart?shop=${t}&product=${null===h||void 0===h?void 0:h.id}&title=${null===h||void 0===h?void 0:h.title}&tags=&cacheSettingsUpdateAt=2020-08-11T15%3A19%3A49.000Z&settingsVersion=19`;fetch(e).then((t=>{if(!t.ok)throw new Error(`HTTP error! Status: ${t.status}`);return t.json()})).then((t=>{var e,i,n,o,r,l;s(null===t||void 0===t||null===(e=t.sizings)||void 0===e||null===(i=e[0])||void 0===i||null===(n=i.layout)||void 0===n||null===(o=n.data)||void 0===o||null===(r=o[0])||void 0===r||null===(l=r.data)||void 0===l?void 0:l.url)})).catch((t=>{console.error("Error fetching data:",t)}))}),[]);const w=`${z.i7`
|
|
69
69
|
0% {
|
|
70
70
|
transform: translateY(100%);
|
|
71
71
|
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[94],{852:function(e,t,n){n.d(t,{H:function(){return a}});const o=function(){fetch("/cart.json").then((e=>e.json())).then((e=>{fetch("/cart?view=item").then((e=>e.text())).then((t=>{const n=(new DOMParser).parseFromString(t,"text/html"),o=n.getElementById("CartDrawer"),r=document.getElementById("CartDrawer");o&&r&&(r.innerHTML=o.innerHTML);n.querySelector("#CartDrawer .totals__subtotal-value");const a=document.querySelector("cart-drawer");a&&a.classList.remove("is-empty");const i=document.querySelector("cart-drawer-items");i&&i.classList.remove("is-empty");const c=document.getElementById("cart-icon-bubble");if(c.querySelector(".cart-count-bubble")){c.querySelectorAll('.cart-count-bubble span[aria-hidden="true"]').forEach((t=>{t.textContent=e.item_count}))}else{const t=document.createElement("div");t.className="cart-count-bubble",t.innerHTML=`\n <span aria-hidden="true">${e.item_count}</span>\n <span class="visually-hidden">${e.item_count} items</span>\n `,c.appendChild(t)}c.click();document.getElementById("CartDrawer-Overlay").addEventListener("click",(()=>{const e=document.querySelector("cart-drawer");e&&e.classList.remove("active"),document.body.classList.remove("overflow-hidden")}))}))}))},r=e=>{const t=document.querySelector("#halo-cart-sidebar .halo-sidebar-wrapper .previewCart-wrapper"),n="is-loading";t.classList.add(n),t.insertAdjacentHTML("afterbegin",'\n <div class="loading-overlay loading-overlay--custom">\n <div class="loading-overlay__spinner">\n <svg aria-hidden="true" focusable="false" role="presentation" class="spinner" viewBox="0 0 66 66" xmlns="http://www.w3.org/2000/svg">\n <circle class="path" fill="none" stroke-width="6" cx="33" cy="33" r="30"></circle>\n </svg>\n </div>\n </div>\n '),fetch(window.routes.root+"/cart?view=ajax_side_cart",{method:"GET",cache:"no-cache"}).then((e=>e.text())).then((e=>{const o=(new DOMParser).parseFromString(e,"text/html");t.innerHTML=o.body.innerHTML,t.classList.remove(n)})).finally((()=>{document.body.querySelector("[data-cart-count]").textContent=cart.item_count,document.dispatchEvent(new CustomEvent("cart-update",{detail:e}));document.getElementById("cart-icon-bubble").click()}))},a=async function(e,t,n,a){let i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:"cart-icon";if("STRNV8MHJTF"!=e&&"STR6HU283UZ"!=e&&"STR9T3LLEJB"!=e&&"STRWJMIOJNX"!=e&&"STRUDQ36YAC"!=e&&"STR1D5ONOZX"!=e){var c=await fetch("https://"+window.location.hostname+"/cart.js",{cache:"reload"}).then((e=>e.json()));if("57939755089"==e||"27358003275"==e||"63748341981"==e||"68237558034"==e||"63046287536"==e||"9734029408"==e||"83411075365"==e||"36300750986"==e||"16957273"==e||"9483952"==e||"57265094752"==e||"58538459329"==e||"80266658086"==e||"46784020646"==e||"52982579389"==e||"76291703063"==e||"68546691304"==e||"27951333450"==e&&"cart-icon"==i)document.documentElement.dispatchEvent(new CustomEvent("cart:refresh",{bubbles:!0,detail:{cart:c,openMiniCart:!0}}));else if("19506115"==e)window.PXUTheme.jsAjaxCart.showDrawer(),window.PXUTheme.jsAjaxCart.updateView();else if("54465429691"==e||"41096085665"==e)refreshCart(c),window.setTimeout((function(){$.fancybox.close(),$(".cart-button").click()}),500);else if("25427564"==e||"4243849314"==e||"57708314789"==e||"86986621247"==e||"58745159727"==e){(new theme.CartDrawer).open()}else if("62602182872"==e||"57362710572"==e)CartJS.getCart(),$(".block-cart").addClass("active");else if("55820812447"==e||"83096174866"==e||"63791857821"==e||"50529403072"==e||"70963003672"==e||"20157815"==e||"60492578980"==e||"12183765088"==e||"58546946211"==e||"42070737058"==e||"71321583919"==e||"68492624171"==e||"74541891876"==e||"21187677"==e||"74021110038"==e||"58193838255"==e||"25151799349"==e||"72651899165"==e||"52022313149"==e||"64983957725"==e||"69610111257"==e||"61209641060"==e||"87043703105"==e||"69699436842"==e)document.documentElement.dispatchEvent(new CustomEvent("ajaxProduct:added",{bubbles:!0,detail:{}})),document.documentElement.dispatchEvent(new CustomEvent("cart:open",{bubbles:!0,detail:{}}));else if("2665447536"==e||"51364757670"==e||"45740720296"==e||"66229010609"==e)fetch("/?section_id=cart-drawer").then((e=>e.text())).then((e=>{const t=(new DOMParser).parseFromString(e,"text/html").getElementById("cart-drawer").innerHTML;$("#cart-drawer").html(t),$('[aria-controls="cart-drawer"]')[0].click(),$(".header__cart-count .count-bubble ").html(d.item_count).css("opacity",1)}));else if("57824805033"==e||"59504656436"==e||"58112966749"==e||"9989358"==e||"26958037078"==e)o();else if("80856187185"==e||"71256211737"==e)fetch("/cart?section_id=mini-cart").then((e=>e.text())).then((e=>{const t=(new DOMParser).parseFromString(e,"text/html").querySelector(".mini-cart__inner").innerHTML;$(".mini-cart__inner").html(t).addClass("active__drawer")})).catch((e=>{console.error(e)})),o();else if("61094723750"==e||"45034766485"==e)SLIDECART&&(SLIDECART_UPDATE(),SLIDECART_OPEN());else if("10272035"==e){const e=document.querySelector(".cart-drawer"),t=e.parentNode;t.classList.add("menu-opening"),t.setAttribute("open","open"),e.style.visibility="visible",e.style.transform="translate(0)"}else if("1972174947"==e||"55194878152"==e||"49198989466"==e)document.documentElement.dispatchEvent(new CustomEvent("cart:refresh:opend",{bubbles:!0,detail:{}}));else if("64463667449"==e||"63897370681"==e||"81998840121"==e||"70964478228"==e)document.documentElement.dispatchEvent(new CustomEvent("cart:refresh",{bubbles:!0})),document.documentElement.dispatchEvent(new CustomEvent("cart:updated",{bubbles:!0,detail:{cart:c}})),document.getElementById("mini-cart").open=!0;else if("81545986363"==e)document.dispatchEvent(new CustomEvent("theme:cartchanged",{bubbles:!0})),document.dispatchEvent(new CustomEvent("theme:open-cart-drawer",{bubbles:!0}));else if("41346334884"==e||"74448077083"==e||"26562420"==e||"26759856318"==e)document.dispatchEvent(new CustomEvent("dispatch:cart-drawer:refresh")),document.dispatchEvent(new CustomEvent("dispatch:cart-drawer:open"));else if("6873415750"==e)document.dispatchEvent(new CustomEvent("cart:change",{bubbles:!0,detail:{cart:c}})),document.dispatchEvent(new CustomEvent("cart:refresh",{bubbles:!0}));else if("59547517063"==e||"59612954814"==e)(()=>{var e=document.querySelector("cart-notification")||document.querySelector("cart-drawer"),t=window.location.origin?window.location.origin+"/":window.location.protocol+"//"+window.location.host+"/";Shopify.locale.length>0&&(t+=Shopify.locale+"/"),null!==e&&"function"===typeof e.renderContents&&fetch(t+"cart?sections=cart-drawer,cart-icon-bubble",{method:"GET",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"}}).then((function(t){var n=document.querySelector("cart-drawer.drawer.is-empty");null!==n&&n.classList.remove("is-empty");try{return t.clone().json().then((function(t){try{var n={sections:t};e.renderContents(n)}catch(o){console.error(o)}}))}catch(o){console.error(o)}}))})();else if("61086662810"==e)(()=>{try{var e=document.querySelector("mini-cart")||document.querySelector("cart-drawer")||document.querySelector("product-form"),t=window.location.origin?window.location.origin+"/":window.location.protocol+"//"+window.location.host+"/";if(Shopify.locale.length>0&&(t+=Shopify.locale+"/"),null!==e&&"function"===typeof e.renderContents){var n=e.getSectionsToRender().map((e=>e.id));fetch(t+"cart?sections="+n.toString(),{method:"GET",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"}}).then((function(t){try{return t.clone().json().then((function(t){try{var n={sections:t};e.renderContents(n)}catch(o){console.error(o)}}))}catch(n){console.error(n)}}))}}catch(o){console.error(o)}})();else if("5827756145"==e){let e=document.getElementById("cart-config");e=JSON.parse(e.innerHTML||"{}"),"undefined"!==typeof window.Shopify&&"undefined"!==typeof window.Shopify.theme&&"undefined"!==typeof window.Shopify.theme.ajaxCart&&"function"===typeof window.Shopify.theme.ajaxCart.updateView&&(Shopify.theme.ajaxCart.updateView({cart_url:"/cart"},c),Shopify.theme.ajaxCart.showDrawer(e))}else if("73454354741"==e)0!==Object.keys(c).length&&r(c);else if("71830962487"==e)"undefined"!==typeof window.Shopify&&"function"===typeof window.Shopify.onCartUpdate&&-1===Shopify.onCartUpdate.toString().indexOf("There are now")&&window.Shopify.onCartUpdate(c,!0);else if("81516986679"==e||"1293622"==e||"73143124251"==e)document.documentElement.dispatchEvent(new CustomEvent("apps:product-added-to-cart",{bubbles:!0}));else if("78232846646"==e){const e=await fetch("/?section_id=cart-drawer"),t=await e.text(),n=document.createElement("div");n.innerHTML=t;const o=n.querySelector(".cart-drawer").innerHTML;document.querySelector(".cart-drawer").innerHTML=o,document.querySelector(".cart-drawer").classList.add("cart-drawer--active")}else if("50529403072"==e){new theme.Drawers("CartDrawer","cart").open()}else if("66789277933"==e){var d=await fetch("/?section_id=ajax-cart-drawer"),s=await d.text();const e=(new DOMParser).parseFromString(s,"text/html").getElementById("shopify-section-ajax-cart-drawer"),t=e.innerHTML;let n,o=document.querySelector("[data-cart-drwaer-body]"),r=0;e.querySelector("[data-cart-wrapper]")&&(r=parseInt(e.querySelector("[data-cart-wrapper]").getAttribute("data-item-count")),n=e.querySelector("[data-cart-wrapper]").getAttribute("data-item-total")),o.innerHTML=t,r>0&&getQuantityElement(o),cartCountUpdate(r),cartNoteUpdate();let a=document.querySelector("#ajax-cart-drawer[data-side-drawer]");document.querySelector("[data-cart-wrapper]").querySelectorAll("[data-add-to-cart]");getCartItemRemoveElements(a),cartGiftWrapElement(a),cartTermhandlerClick(),cartTermsHandler()}else if("83103121690"==e||"90617479486"==e)document.querySelector(".cart-count").click();else if("19827331"==e){const e=document.getElementById("main-cart-items");if(e){const t=await fetch("/cart"),n=await t.text(),o=(new DOMParser).parseFromString(n,"text/html").getElementById("main-cart-items");o&&(e.innerHTML=o.innerHTML)}$jq(".slider").removeClass("hidden-block").addClass("show-cart-slider")}else if("829620282"==e)try{$.get("/?view=cart",(e=>{const t=document.getElementById("osc-main-wrapper");t.innerHTML=e,updateQty(),removeQty(),$("#osc-icon-span").click(osCloseCart);const n=t.querySelector("#osc-total");calculateProgressBar(n.dataset.totalPrice),osOpenCart()})),document.getElementById("os-pp-error").innerHTML="";const e=parseInt(document.getElementById("osh-cart-bubble").innerHTML)+parseInt(1);$("#osh-cart-bubble").css("display","flex"),$("#osh-cart-bubble").text(e)}catch(u){console.log(u)}else{if("58273038492"==e&&$("#cart-drawer").toggleClass("active"),"62335516854"==e)(new theme.CartDrawer).open();"59993653290"==e&&$("body").toggleClass("show-cart-summary").hasClass("show-cart-summary"),document.documentElement.dispatchEvent(new CustomEvent("product:added",{bubbles:!0,detail:{}})),function(e){var t,n;try{var o=e.item_count;if($("[data-cart-item-count]").html(o),$(".header__cart-count").html(o),$(".site-header__cart-count span[data-cart-count]").html(o),$("#CartCount [data-cart-count]").length>0?$("#CartCount [data-cart-count]").html(o):$("#CartCount").length>0&&$("#CartCount").html($("#CartCount").html().replace(/(\d+)/,e.item_count)),$("#CartCount.hide").length>0&&$("#CartCount.hide").removeClass("hide"),$("#site-cart-handle .count-holder .count").length>0&&$("#site-cart-handle .count-holder .count").html($("#site-cart-handle .count-holder .count").html().replace(/(\d+)/,e.item_count)),$("#minicart .count.cart-target").length>0&&$("#minicart .count.cart-target").html($("#minicart .count.cart-target").html().replace(/(\d+)/,e.item_count)),$("#sidebar #meta .count").length>0&&$("#sidebar #meta .count").html($("#sidebar #meta .count").html().replace(/(\d+)/,e.item_count)),document.querySelectorAll(".js-drawer-open-cart").length>0&&document.querySelectorAll(".js-drawer-open-cart")[0].click(),$(".site-header__cart .site-header__cart-indicator").length>0&&($(".site-header__cart .site-header__cart-indicator").html($(".site-header__cart .site-header__cart-indicator").html().replace(/(\d+)/,e.item_count)),e.item_count>0&&$(".site-header__cart .site-header__cart-indicator").removeClass("hide")),$(".cart-count").length>0&&$(".cart-count").html($(".cart-count").html().replace(/(\d+)/,e.item_count)),$(".cartCount[data-cart-count]").length>0&&$(".cartCount[data-cart-count]").html($(".cartCount[data-cart-count]").html().replace(/(\d+)/,e.item_count)),$("[data-js-cart-count-desktop]").length>0&&($("[data-js-cart-count-desktop]").html(e.item_count),$("[data-js-cart-count-desktop]").attr("data-js-cart-count-desktop",e.item_count)),$(".cart-item-count-header").length>0){var r=$(".cart-item-count-header").first();!0===r.hasClass("cart-item-count-header--total")?r.find(".money").length&&(r=r.find(".money").first()).html(bndlr.formatPrice(e.items_subtotal_price)):r.html(r.html().replace(/(\d+)/,e.item_count))}if($("#CartCost").length>0&&"undefined"!==typeof theme&&"undefined"!==typeof theme.moneyFormat){var a=utils.formatMoney(e.items_subtotal_price,theme.moneyFormat);$("#CartCost").html(a)}if("function"==typeof refreshCart&&refreshCart(e),"undefined"!==typeof slate&&"undefined"!==typeof slate.cart&&"function"==typeof slate.cart.updateCart&&slate.cart.updateCart(),"undefined"!==typeof ajaxCart&&"function"===typeof ajaxCart.load&&ajaxCart.load(),$(".mega-nav-count.nav-main-cart-amount.count-items").length>0&&($(".mega-nav-count.nav-main-cart-amount.count-items").html($(".mega-nav-count.nav-main-cart-amount.count-items").html().replace(/(\d+)/,e.item_count)),$(".mega-nav-count.nav-main-cart-amount.count-items.hidden").removeClass("hidden")),$("#cart-icon-bubble").length>0){var i='#cart-icon-bubble .cart-count-bubble span[aria-hidden="true"]';$(i).length>0?$(i).html($(i).html().replace(/(\d+)/,e.item_count)):$("#cart-icon-bubble").append('<div class="cart-count-bubble"><span aria-hidden="true">'+e.item_count+"</span></div>")}"undefined"!==typeof Shopify&&"undefined"!==typeof Shopify.updateQuickCart&&Shopify.updateQuickCart(e),"undefined"!==typeof bcActionList&&"function"===typeof bcActionList.atcBuildMiniCartSlideTemplate&&(bcActionList.atcBuildMiniCartSlideTemplate(e),"function"===typeof openMiniCart&&openMiniCart()),$(".custom-cart-eye-txt").length>0&&$(".custom-cart-eye-txt").html($(".custom-cart-eye-txt").html().replace(/(\d+)/,e.item_count)),$(".cart_count").length>0&&$(".cart_count").each((function(t,n){$(n).html($(n).html().replace(/(\d+)/,e.item_count))})),document.querySelector(".cart-count")&&(document.querySelector(".cart-count").innerHTML=document.querySelector(".cart-count").innerHTML.replace(/(\d+)/,e.item_count)),$(".cart-count-bubble [data-cart-count]").length>0&&$(".cart-count-bubble [data-cart-count]").html($(".cart-count-bubble [data-cart-count]").html().replace(/(\d+)/,e.item_count)),$(".cart-count-bubble span.visually-hidden").length>0&&$(".cart-count-bubble span.visually-hidden").html($(".cart-count-bubble span.visually-hidden").html().replace(/(\d+)/,e.item_count)),$(".header-cart-count .cart_count_val").length>0&&($(".header-cart-count .cart_count_val").html(e.item_count),$(".header-cart-count").removeClass("empty_cart_count")),"undefined"!==typeof Shopify&&"undefined"!==typeof Shopify.updateCartInfo&&$(".top-cart-holder .cart-target form .cart-info .cart-content").length>0&&Shopify.updateCartInfo(e,".top-cart-holder .cart-target form .cart-info .cart-content");var c=new CustomEvent("wetheme-toggle-right-drawer",{detail:{type:"cart",forceOpen:void 0,params:{cart:e}}});document.documentElement.dispatchEvent(c),"undefined"!==typeof window.vndHlp&&"function"===typeof window.vndHlp.refreshCart&&window.vndHlp.refreshCart(e);try{"function"===typeof window.renderCart&&(window.renderCart(e),e.items.length>0&&$(".mini-cart.is-empty").removeClass("is-empty"))}catch(u){}try{"undefined"!==typeof window.SATCB&&"undefined"!==typeof window.SATCB.Helpers&&"function"===typeof window.SATCB.Helpers.openCartSlider&&window.SATCB.Helpers.openCartSlider()}catch(u){}try{document.dispatchEvent(new CustomEvent("theme:cart:change",{detail:{cart:e,cartCount:e.item_count},bubbles:!0}))}catch(u){}if("undefined"!==typeof window.cartStore&&"function"===typeof window.cartStore.setState&&window.cartStore.setState({justAdded:{},popupActive:!0,item_count:e.item_count,items:e.items,cart:e}),"undefined"!==typeof window.Shopify&&"function"===typeof window.Shopify.onCartUpdate&&-1===Shopify.onCartUpdate.toString().indexOf("There are now")&&window.Shopify.onCartUpdate(e,!0),"undefined"!==typeof theme&&"undefined"!==typeof theme.Cart&&"function"===typeof theme.Cart.setCurrentData&&theme.Cart.setCurrentData(e),"undefined"!==typeof window.halo&&"function"===typeof window.halo.updateSidebarCart){window.halo.updateSidebarCart(e);var d=$("[data-cart-sidebar]");d.length>0&&d[0].click()}if("undefined"!==typeof window.Shopify&&"undefined"!==typeof window.Shopify.theme&&"undefined"!==typeof window.Shopify.theme.ajaxCart&&"function"===typeof window.Shopify.theme.ajaxCart.updateView&&Shopify.theme.ajaxCart.updateView({cart_url:"/cart"},e),"undefined"!==typeof window.theme&&"undefined"!==typeof window.theme.cart&&"function"===typeof window.theme.cart.updateAllHtml)try{window.theme.cart.updateAllHtml(),window.theme.cart.updateTotals(e),document.querySelector(".header--cart-toggle").click()}catch(u){}if("function"===typeof monster_setCartItems)try{monster_setCartItems(e.items)}catch(u){console.error(u)}try{"undefined"!==typeof window.refreshCartContents&&window.refreshCartContents(e)}catch(u){}$(".header-actions [data-header-cart-count]").length>0&&$(".header-actions [data-header-cart-count]").html(e.item_count),window.dispatchEvent(new Event("update_cart")),"undefined"!==typeof clientSpecifics&&"undefined"!==typeof clientSpecifics.update_cart&&clientSpecifics.update_cart.trigger(e)}catch(u){console.log(u)}try{var s=document.querySelector(".minicart__outerbox"),l=window.location.origin?window.location.origin+"/":window.location.protocol+"//"+window.location.host+"/";Shopify.locale.length>0&&(l+=Shopify.locale+"/"),null!==s&&"function"===typeof window.cartContentUpdate&&(sectionsToRender=s.dataset.section,fetch(l+"cart?sections="+sectionsToRender,{method:"GET",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"}}).then((function(t){try{return t.clone().json().then((function(t){e.sections=t,window.cartContentUpdate(e,s,sectionsToRender)}))}catch(u){console.error(u)}})))}catch(u){console.error(u)}if("undefined"!==typeof window.SLIDECART_UPDATE)try{window.SLIDECART_UPDATE()}catch(u){console.log(u)}if("undefined"!==typeof window.SLIDECART_OPEN&&setTimeout((function(){try{window.SLIDECART_OPEN()}catch(u){console.log(u)}}),500),"undefined"!==typeof Shopify&&"undefined"!==typeof Shopify.theme&&"undefined"!==typeof Shopify.theme.jsAjaxCart&&"function"===typeof Shopify.theme.jsAjaxCart.updateView&&Shopify.theme.jsAjaxCart.updateView(),"undefined"!==typeof CartJS&&"function"===typeof CartJS.getCart)try{CartJS.getCart()}catch(u){console.log(u)}try{$(".sp-cart .sp-dropdown-toggle").length&&"undefined"!==typeof Shopify&&"function"===typeof Shopify.getCart&&Shopify.getCart(),$("form.cart-drawer").length>0&&($(".cart-drawer input").first().trigger("blur"),setTimeout((function(){$(".cart-drawer input").first().trigger("input")}),350))}catch(u){console.log(u)}try{var h=document.querySelector("m-cart-drawer");null!==h&&"function"===typeof h.onCartDrawerUpdate&&(h.onCartDrawerUpdate(),"function"===typeof h.open&&h.open())}catch(u){console.log(u)}try{document.dispatchEvent(new CustomEvent("cart:refresh"))}catch(u){}try{document.documentElement.dispatchEvent(new CustomEvent("cart:refresh",{bubbles:!0}))}catch(u){}if("undefined"!==typeof window.HsCartDrawer&&"function"===typeof window.HsCartDrawer.updateSlideCart&&debounce("hscartdrawer",(function(){try{HsCartDrawer.updateSlideCart()}catch(u){console.log(u)}}),100),"function"===typeof window.HS_SLIDE_CART_UPDATE&&debounce("hscartdrawer2",(function(){try{window.HS_SLIDE_CART_UPDATE()}catch(u){console.log(u)}}),100),"undefined"!==typeof window.HS_SLIDE_CART_OPEN&&"function"===typeof window.HS_SLIDE_CART_OPEN&&debounce("hscartdraweropen",(function(){try{window.HS_SLIDE_CART_OPEN()}catch(u){console.log(u)}}),100),"undefined"!==typeof theme&&"undefined"!==typeof theme.Cart&&"function"===typeof theme.Cart.updateCart&&theme.Cart.updateCart(),"undefined"!==typeof window.cart&&"function"===typeof window.cart.getCart&&window.cart.getCart(),"function"===typeof window.updateMiniCartContents)try{window.updateMiniCartContents()}catch(u){}if("function"===typeof window.loadEgCartDrawer)try{window.loadEgCartDrawer()}catch(u){}try{document.dispatchEvent(new CustomEvent("cart:build"))}catch(u){}try{document.dispatchEvent(new CustomEvent("obsidian:upsell:refresh")),document.dispatchEvent(new CustomEvent("obsidian:upsell:open"))}catch(u){}var p=document.getElementById("site-cart");if(null!==p)try{p.show()}catch(u){}if("undefined"!==typeof window.theme&&"function"===typeof window.theme.updateCartSummaries)try{window.theme.updateCartSummaries()}catch(u){}if("undefined"!==typeof window.CD_REFRESHCART)try{window.CD_REFRESHCART()}catch(u){console.log(u)}if("undefined"!==typeof window.CD_OPENCART&&setTimeout((function(){try{window.CD_OPENCART()}catch(u){console.log(u)}}),500),"function"===typeof window.buildCart)try{window.buildCart()}catch(u){console.log(u)}if("undefined"!==typeof window.PXUTheme&&"undefined"!==typeof window.PXUTheme.jsAjaxCart&&"function"===typeof window.PXUTheme.jsAjaxCart.updateView)try{window.PXUTheme.jsAjaxCart.updateView()}catch(u){}if("undefined"!==typeof window.theme&&"function"===typeof window.theme.addedToCartHandler)try{window.theme.addedToCartHandler({})}catch(u){}try{c=new Event("tcustomizer-event-cart-change"),document.dispatchEvent(c)}catch(u){}try{document.dispatchEvent(new CustomEvent("dispatch:cart-drawer:refresh",{bubbles:!0})),setTimeout((function(){document.dispatchEvent(new CustomEvent("dispatch:cart-drawer:open"))}),500)}catch(u){}try{var m=document.querySelector("cart-notification")||document.querySelector("cart-drawer");l=window.location.origin?window.location.origin+"/":window.location.protocol+"//"+window.location.host+"/",Shopify.locale.length>0&&(l+=Shopify.locale+"/"),null!==m&&"function"===typeof m.renderContents&&fetch(l+"cart?sections=cart-drawer,cart-icon-bubble",{method:"GET",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"}}).then((function(e){var t=document.querySelector("cart-drawer.drawer.is-empty");null!==t&&t.classList.remove("is-empty");try{return e.clone().json().then((function(e){try{var t={sections:e};m.renderContents(t)}catch(u){console.error(u)}}))}catch(u){console.error(u)}}))}catch(u){console.error(u)}try{var w=document.querySelector("mini-cart")||document.querySelector("cart-drawer")||document.querySelector("product-form");if(l=window.location.origin?window.location.origin+"/":window.location.protocol+"//"+window.location.host+"/",Shopify.locale.length>0&&(l+=Shopify.locale+"/"),null!==w&&"function"===typeof w.renderContents){var f=w.getSectionsToRender().map((e=>e.id));fetch(l+"cart?sections="+f.toString(),{method:"GET",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"}}).then((function(e){try{return e.clone().json().then((function(e){try{var t={sections:e};w.renderContents(t)}catch(u){console.error(u)}}))}catch(u){console.error(u)}}))}}catch(u){console.error(u)}try{w=document.querySelector("mini-cart")||document.querySelector("cart-drawer")||document.querySelector("product-form"),l=window.location.origin?window.location.origin+"/":window.location.protocol+"//"+window.location.host+"/",null!==w&&"function"===typeof w.renderContents&&(f=w.getSectionsToRender().map((e=>null===e||void 0===e?void 0:e.section)),fetch(l+"cart?sections="+f.toString(),{method:"GET",cache:"no-cache",credentials:"same-origin",headers:{"Content-Type":"application/json"}}).then((function(e){try{return e.clone().json().then((function(e){try{var t={sections:e};w.renderContents(t)}catch(u){console.error(u)}}))}catch(u){console.error(u)}})))}catch(u){console.error(u)}null===(t=document)||void 0===t||null===(n=t.documentElement)||void 0===n||n.dispatchEvent(new CustomEvent("cart:refresh:opend",{bubbles:!0,detail:{}})),console.log("entered")}(c)}setTimeout(t,n)}else{console.log("Executing cart refresh script..");document.getElementById("whatsmorecart").value=Math.random()}}},9821:function(e,t,n){function o(){const e=navigator.userAgent||navigator.vendor||window.opera;if(!/iPhone/.test(e))return!1;const{width:t,height:n}=window.screen;return[{width:320,height:480},{width:320,height:568},{width:375,height:667},{width:414,height:736},{width:375,height:812},{width:414,height:896},{width:360,height:780},{width:390,height:844},{width:428,height:926},{width:393,height:852},{width:430,height:932}].some((e=>e.width===t&&e.height===n||e.width===n&&e.height===t))}n.d(t,{_:function(){return o}})},1085:function(e,t,n){n.d(t,{F5:function(){return r},Pc:function(){return i},Z4:function(){return c},bo:function(){return d},rq:function(){return s}});var o=n(5830);const r=6;function a(){const e=(0,o.Xd)("whatmoreVideoPlayerPool");var t=document.createElement("video");return t.setAttribute("class","whatmore-video-player whatmore-main-video-player-from-pool"),t.setAttribute("width","100%"),t.setAttribute("src","https://whatmore-other-assets.b-cdn.net/whatmore/dummy_for_video_pool_3s_muted_11kb.mp4"),t.muted=!0,t.setAttribute("height","100%"),t.setAttribute("preload","auto"),t.setAttribute("loop",""),t.setAttribute("playsinline",""),t.setAttribute("x-webkit-airplay","allow"),t.controls=!1,e.appendChild(t),t}const i=function(e){for(let t=1;t<=e;t++)a();(0,o.t2)("whatmoreVideoPlayerPoolInitiated",!0)};const c=function(e,t,n,r,a){(0,o.Xd)("whatmoreVideoPlayerPool");const i=function(e,t,n){var r=(a=(0,o.Xd)("whatmoreVideoPlayerPool").children,a.length>0?a[0]:null);var a;if(!r)throw new Error("Whatmore :: not enough blessed videos available in video pool.");return r.setAttribute("src",e),r.muted=t,r.play().then((()=>{!n&&r.pause()})).catch((e=>{})),r}(t,n,r);return e.innerHTML="",e.appendChild(i),i},d=async function(){const e=(0,o.Xd)("whatmoreVideoPlayerPool"),t=(0,o.Xd)("whatmoreVideoPlayerPoolInitiated");t||i(r);var n=[];for(let o of e.children){o.muted=!0;var a=o.play().then((e=>(!t&&o.pause(),e)));n.push(a)}await Promise.all(n).then((e=>{(0,o.t2)("whatmoreVideoPlayerPoolBlessed",!0)})).catch((e=>{console.error("Whatmore :: Error while blessing "+e.message)}))},s=function(e){const t=(0,o.Xd)("whatmoreVideoPlayerPool"),n=e.children[0];n.muted=!0,!n.paused&&n.pause(),t.appendChild(n)}},6613:function(e,t,n){n.d(t,{At:function(){return o},MN:function(){return r}});const o=()=>"undefined"!==typeof navigator&&(/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream),r=()=>o()||"undefined"!==typeof navigator&&/Macintosh/.test(navigator.userAgent)},2039:function(e,t,n){n.d(t,{Il:function(){return r},Th:function(){return a},ij:function(){return o}});const o=function(e){return"video"===e.event_type},r=function(e){return"image"===e.event_type},a=function(e){return"livestream"===e.event_type}},1941:function(e,t,n){n.d(t,{A:function(){return u}});var o=n(5830),r=n(9950);function a(e){if(!e)return{};var t={};return Array.from(e.attributes).forEach((e=>{var n;t[e.name]=(n=e.value,isNaN(+n)?n:+n)})),t}function i(){try{var e;const r=document.getElementById("whatmorePreviewMode");if(!r)return null;for(var t=arguments.length,n=new Array(t),o=0;o<t;o++)n[o]=arguments[o];const i=null===n||void 0===n?void 0:n[0];if(!i)return!0;let c={};return c=i.includes("function")?{}:a(r),null!==(e=c)&&void 0!==e&&e[i]?c[i]:null}catch(r){return null}}var c=function(){var e,t;let{disablePreview:n=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};var o=n?window.innerHeight:null!==(e=i("height-wh"))&&void 0!==e?e:window.innerHeight,a=n?window.innerWidth:null!==(t=i("width-wh"))&&void 0!==t?t:window.innerWidth,[c,d]=[o,a];const[s,u]=(0,r.useState)([c>d?"portrait":"landscape",c,d]);return(0,r.useLayoutEffect)((()=>{function e(){var e,t,o=n?window.innerHeight:null!==(e=i("height-wh"))&&void 0!==e?e:window.innerHeight,r=n?window.innerWidth:null!==(t=i("width-wh"))&&void 0!==t?t:window.innerWidth,[a,c]=[o,r];u(a>c?["portrait",a,c]:["landscape",a,c])}return window.addEventListener("resize",e),window.addEventListener("orientationchange",e),screen.orientation&&screen.orientation.addEventListener("change",e),e(),()=>{window.removeEventListener("resize",e),window.removeEventListener("orientationchange",e),screen.orientation&&screen.orientation.removeEventListener("change",e)}}),[]),s};function d(){return[window.innerHeight,window.innerWidth]}var s=function(){var[e,t]=d();const[n,o]=(0,r.useState)([e>t?"portrait":"landscape",e,t]);return(0,r.useLayoutEffect)((()=>{function e(){var[e,t]=d();o(e>t?["portrait",e,t]:["landscape",e,t])}return window.addEventListener("resize",e),window.addEventListener("orientationchange",e),screen.orientation&&screen.orientation.addEventListener("change",e),e(),()=>{window.removeEventListener("resize",e),window.removeEventListener("orientationchange",e),screen.orientation&&screen.orientation.removeEventListener("change",e)}}),[]),n};var u=function(e){var t;const n=(0,o.Xd)("isWhatmorePreviewMode"),r=s(),a=c({disablePreview:null!==(t=null===e||void 0===e?void 0:e.disablePreview)&&void 0!==t&&t});return n?a:r}},6649:function(e,t,n){var o=n(9950);t.A=function(){let{triggerOnce:e=!1,root:t=null,rootMargin:n="0px",threshold:r=0}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const[a,i]=(0,o.useState)(!1),[c,d]=(0,o.useState)(null),s=(0,o.useRef)(null);return(0,o.useEffect)((()=>{const o=new IntersectionObserver(((t,n)=>{t.forEach((t=>{d(t),t.isIntersecting?(i(!0),e&&n.disconnect()):e||i(!1)}))}),{root:t,rootMargin:n,threshold:r});return s.current&&o.observe(s.current),()=>{o.disconnect()}}),[e,t,n,r]),[s,a,c]}},140:function(e,t,n){n.d(t,{$B:function(){return c},A9:function(){return s},Pb:function(){return u},TG:function(){return p},TJ:function(){return h},Zh:function(){return d},lB:function(){return i},tO:function(){return l}});var o,r=n(964);const a=null!==(o="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==o&&o;function i(e){a&&console.debug("updating user view count for event.");const t={event_id:e.event_id,increase_by:1};fetch(r.$$+"/event/metrics/views",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t)}).then((e=>(a&&console.debug("updating user view count response : HTTP "+e.status),e.json()))).then((e=>{a&&console.debug("updating user view count response : "+JSON.stringify(e))})).catch((e=>{console.error("error updating user view count user for event : ",e)}))}function c(e,t){a&&console.debug("updating like count for event.");const n={event_id:e.event_id,increase_by:t};fetch(r.$$+"/event/metrics/like",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then((e=>(a&&console.debug("updating like count response : HTTP "+e.status),e.json()))).then((e=>{a&&console.debug("updating like count response : "+JSON.stringify(e))})).catch((e=>{console.error("error updating like count user for event : ",e)}))}function d(e){a&&console.debug("updating share count for event.");const t={event_id:e.event_id,increase_by:1};fetch(r.$$+"/event/metrics/share",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t)}).then((e=>(a&&console.debug("updating share count response : HTTP "+e.status),e.json()))).then((e=>{a&&console.debug("updating share count response : "+JSON.stringify(e))})).catch((e=>{console.error("error updating share count user for event : ",e)}))}function s(e,t){a&&console.debug("updating wa click count for event.");const n={event_id:e.event_id,increase_by:t};fetch(r.$$+"/event/metrics/whatsapp",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then((e=>(a&&console.debug("updating whatsapp click count response : HTTP "+e.status),e.json()))).then((e=>{a&&console.debug("updating whatsapp click count response : "+JSON.stringify(e))})).catch((e=>{console.error("error updating whatsapp click count user for event : ",e)}))}function u(e,t){a&&console.debug("updating event-product click count for event {} and product {}.",e.event_id,t.product_id);const n={event_id:e.event_id,product_id:t.product_id,increase_by:1};fetch(r.$$+"/event/metrics/clicks",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then((e=>(a&&console.debug("updating user event-product click count response : HTTP "+e.status),e.json()))).then((e=>{a&&console.debug("updating user event-product click count response : "+JSON.stringify(e))})).catch((t=>{console.error("error updating user event-product click count for event {} : ",e.event_id,t)}))}function l(e,t,n){a&&console.debug("updating event-product add to cart count for event {} and product {}.",e.event_id,t.product_id);const o={event_id:e.event_id,product_id:t.product_id,increase_by:n};fetch(r.$$+"/event/metrics/add_to_cart",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(o)}).then((e=>(a&&console.debug("updating user event-product add to cart count response : HTTP "+e.status),e.json()))).then((e=>{a&&console.debug("updating user event-product add to cart count response : "+JSON.stringify(e))})).catch((t=>{console.error("error updating user event-product add to cart count for event {} : ",e.event_id,t)}))}function h(e,t){a&&console.debug("updating event-product buy now count for event {} and product {}.",e.event_id,t.product_id);const n={event_id:e.event_id,product_id:t.product_id,increase_by:1};fetch(r.$$+"/event/metrics/buy_now",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(n)}).then((e=>(a&&console.debug("updating user event-product buy now count response : HTTP "+e.status),e.json()))).then((e=>{a&&console.debug("updating user event-product buy now count response : "+JSON.stringify(e))})).catch((t=>{console.error("error updating user event-product buy now count for event {} : ",e.event_id,t)}))}function p(e){const t={event_id:e.event.event_id,cta_id:e.cta.cta_id,increase_by:1};fetch(r.$$+"/event/metrics/cta/clicks",{method:"POST",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(t)}).then((e=>(a&&console.debug("updating user cta click count response : HTTP "+e.status),e.json()))).then((e=>{a&&console.debug("updating user cta click count response : "+JSON.stringify(e))})).catch((e=>{console.error("error updating cta click count : ",e)}))}},3330:function(e,t,n){n.d(t,{Si:function(){return p},hr:function(){return h}});var o,r=n(2595),a=n(7732),i=n(1348);const c="Whatmore Video Shopping",d=null!==(o="true"==localStorage.getItem("whatmoreActivateLogs"))&&void 0!==o&&o,s={video_view:"Video View",add_to_cart:"Add to Cart",buy_now:"Buy Now"},u={carousel:"Carousel",stories:"Stories",video_popup:"Video Popup"},l={homepage:"Home Page",product_page:"Product Page"};async function h(e){if((0,i.M$H)(e)&&null!==(0,i.xIo)(e)&&(a.Ay.initialize((0,i.xIo)(e)),d&&console.debug("Whatmore: initialized GA4")),(0,i.B6P)(e)&&null!==(0,i.jWS)(e)){const t=(0,i.Gc6)(e);r.Ay.initialize((0,i.jWS)(e),{useExistingGa:t}),d&&console.debug("Whatmore: initialized GA3")}}async function p(e,t,n){(0,i.B6P)(e)&&null!==(0,i.jWS)(e)&&(r.Ay.event({category:c,action:s.video_view,label:l[t]+":"+u[n]}),d&&console.debug("Whatmore: pushed view event to GA3")),(0,i.M$H)(e)&&null!==(0,i.xIo)(e)&&(a.Ay.event({category:c,action:s.video_view+":"+l[t]+":"+u[n],value:1,nonInteraction:!1}),d&&console.debug("Whatmore: pushed view event to GA4"))}},7145:function(e,t,n){n.d(t,{B:function(){return u}});var o=n(6641),r=n(1348),a=n(5830),i=n(4820);var c=n(6157),d=n(2089),s=n(4533);const u=function(){var e;let{userInteractionType:t="",userInteractionMetadata:n={},widgetSourceDetails:u={},event:l="",productList:h=[],ctaList:p=[]}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{};const m=(0,a.Xd)("isInDesignMode"),w=(0,a.Xd)("isDemoBrand"),f=(0,a.Xd)("whatmoreShopId"),y="72201044272"==f&&"event-view"==t?null!==(e=JSON.parse(localStorage.getItem("_user_wh_lc")))&&void 0!==e?e:{latitude:"",longitude:""}:{};if(n={...n,...y,user_type:null!=localStorage.getItem("w_user_type")?"olduser":"newuser"},!(0,r.rkx)(f)||w||m)return;t!=c.O.HOMEPAGE_CAROUSEL_WIDGET_VIEW&&t!=c.O.STORIES_WIDGET_VIEW&&t!=c.O.COLLECTION_WIDGET_VIEW&&t!=c.O.PDP_POPUP_WIDGET_VIEW||null!=localStorage.getItem("wht_is_impression")||localStorage.setItem("wht_is_impression",!0);const v="_whatmore_bulk_events",g={user_id:(0,s.wm)(),session_id:(0,s.zv)(),user_group:"group-a",user_agent:navigator.userAgent,store_id:(0,a.Xd)("whatmoreShopId"),hostname:window.location.hostname,page_path:window.location.pathname,event_id:(0,d.Ak)(),event_timestamp:Math.round((new Date).getTime()/1e3)},_=(0,c.l)(t,n),C=function(e,t,n,o){var r;return{landing_location_type:t.landingLocationType,template_type:t.templateType,whatmore_event:{id:e.event_id,eventset_id:null!==(r=e.eventset_id)&&void 0!==r?r:null,cta_list:o.map((e=>e.cta_id)),product_list:n.map((e=>e.product_id))}}}(l,u,h,p),b=(0,a.Xd)("whatmoreLoggingActive"),S={...g,interaction_data:_,data:C},E=JSON.parse(localStorage.getItem(v))||[];if(E.push(S),localStorage.setItem(v,JSON.stringify(E)),b&&(0,o.xv)(S),clearTimeout(localStorage.getItem("_whatmore_bulk_timer_id")),E.length>=10)(0,i.u)(E),localStorage.removeItem(v);else if(E.length>0){let e=setTimeout((()=>{(0,i.u)(E),localStorage.removeItem(v)}),14e3);localStorage.setItem("_whatmore_bulk_timer_id",e)}}},6157:function(e,t,n){n.d(t,{O:function(){return o},l:function(){return r}});const o=Object.freeze({EVENT_VIEW:"event-view",PRODUCT_CTA_VIEW:"product-cta-view",SHOPNOW_ATC_CLICKED:"shop-now-atc-clicked",SHOPNOW_BUYNOW_CLICKED:"shop-now-buy-now-clicked",PRODUCT_TILE_ATC_CLICKED:"product-tile-atc-clicked",PRODUCT_TILE_SHOPNOW_CLICKED:"product-tile-shopnow-clicked",VIDEO_LIKED:"video-liked",VIDEO_UNLIKED:"video-unliked",VIDEO_SHARE_CTA_CLICKED:"video-share-cta-clicked",VIDEO_MUTED:"video-muted",HOMEPAGE_CAROUSEL_SWIPED:"homepage-carousel-swiped",HOMEPAGE_VISITED:"homepage-visited",COLLECTION_PAGE_VISITED:"collection-page-visited",PDP_VISITED:"product-page-visited",HOMEPAGE_CAROUSEL_WIDGET_VIEW:"homepage-carousel-widget-view",BANNER_WIDGET_VIEW:"banner-widget-view",STORIES_WIDGET_VIEW:"stories-widget-view",COLLECTION_WIDGET_VIEW:"collection-widget-view",SPOTLIGHT_WIDGET_VIEW:"spotlight-widget-view",PDP_POPUP_WIDGET_VIEW:"pdp-popup-widget-view",PDP_POPUP_CLOSED:"pdp-popup-closed",VIDEO_PLAYBACK:"video-watched",SHOPNOW_CLICKED:"shopnow-clicked",WHATSAPP_ICON_CLICKED:"whatsapp-icon-clicked",BANNER_WIDGET_CLICKED:"banner-widget-clicked",QUESTION_VIEWED:"question-viewed",QUESTION_ANSWERED:"question-answered",QUESTION_CLOSED:"question-closed",PRODUCT_TILE_ALL_ATC_CLICKED:"product-tile-all-atc"}),r=function(e,t){return{name:e,metadata:t}}},2979:function(e,t,n){n.d(t,{S:function(){return d}});var o=n(6649),r=n(4737),a=n(9950),i=n(7145),c=n(4414);const d=function(e){var t;const[n,d,s]=(0,o.A)({triggerOnce:!1,threshold:null!==(t=e.threshold)&&void 0!==t?t:1}),{whatmoreWidgetSourceDetails:u}=(0,a.useContext)(r.B);return(0,a.useEffect)((()=>{var t,n,o,r;d&&null!==(t=e.triggerFlag)&&void 0!==t&&t&&(0,i.B)({userInteractionType:e.userInteractionType,userInteractionMetadata:null!==(n=e.userInteractionMetadata)&&void 0!==n?n:{},widgetSourceDetails:u,event:e.event,productList:null!==(o=e.productList)&&void 0!==o?o:[],ctaList:null!==(r=e.ctaList)&&void 0!==r?r:[]})}),[d]),(0,c.jsx)("div",{style:{height:"100%"},ref:n,children:e.children})}}}]);
|