whatmore-react-assets 1.0.906 → 1.0.908
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 +1 -1
- package/static/js/143.794de861.chunk.js +1 -0
- package/static/js/{196.6b1b7e32.chunk.js → 196.9d786fee.chunk.js} +1 -1
- package/static/js/{218.bd668d19.chunk.js → 218.b0b06873.chunk.js} +1 -1
- package/static/js/380.ee6adb33.chunk.js +1 -0
- package/static/js/{411.0615a4a8.chunk.js → 411.7fcdc7c3.chunk.js} +2 -2
- package/static/js/582.94664f83.chunk.js +1 -0
- package/static/js/{691.a3cc8e1e.chunk.js → 691.cbca937c.chunk.js} +1 -1
- package/static/js/{853.151247ed.chunk.js → 853.ed158c33.chunk.js} +1 -1
- package/whatmore.js +2 -2
- package/static/js/143.232e6d3c.chunk.js +0 -1
- package/static/js/380.057a2a1e.chunk.js +0 -1
- package/static/js/582.68a5ba1e.chunk.js +0 -1
package/package.json
CHANGED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[143],{8181:function(e,t,n){var i=n(7313),o=n(8866),r=n(7753),a=n(6417);const s=i.memo((()=>{if(!(0,r.MO)("isLandingSharedLink"))return(0,a.jsx)(a.Fragment,{});const[e]=(0,o.Z)();return(0,a.jsxs)("div",{className:`shimmer-container ${e}`,children:["portrait"===e?(0,a.jsx)("div",{className:"shimmer-item portrait-full",children:(0,a.jsx)("div",{className:"shimmer-effect"})}):Array(3).fill().map(((e,t)=>(0,a.jsx)("div",{className:"shimmer-item landscape-item "+(1===t?"center-item":""),children:(0,a.jsx)("div",{className:"shimmer-effect"})},t))),(0,a.jsx)("style",{children:"\n .shimmer-container {\n display: flex;\n position: fixed;\n top: 0;\n left: 0;\n width: 100vw;\n height: 100vh;\n overflow-x: scroll;\n scroll-snap-type: x mandatory;\n scroll-behavior: smooth;\n z-index: 1000;\n }\n\n .portrait {\n justify-content: center;\n align-items: center;\n background: rgba(0, 0, 0, 0.3);\n }\n\n .landscape {\n justify-content: center;\n align-items: center;\n background: rgba(0, 0, 0, 0.8);\n }\n\n .shimmer-item {\n scroll-snap-align: start;\n display: flex;\n justify-content: center;\n align-items: center;\n position: relative;\n transition: transform 0.3s ease;\n }\n\n .portrait-full {\n width: 100vw;\n height: 100vh;\n margin: 0; \n }\n\n .landscape-item {\n width: 250px;\n height: 450px;\n background: #D3D3D3;\n border-radius: 8px;\n margin-left: -50px; \n }\n\n .center-item {\n width: 360px;\n height: 620px;\n box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.5); \n z-index: 10; \n }\n\n .shimmer-effect {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background: linear-gradient(90deg, rgba(0, 0, 0, 0.3) 25%, rgba(0, 0, 0, 0.5) 50%, rgba(0, 0, 0, 0.3) 75%);\n animation: shimmer 2s infinite;\n background-size: 200% 100%;\n }\n\n @keyframes shimmer {\n 0% {\n background-position: -200% 0;\n }\n 100% {\n background-position: 200% 0;\n }\n }\n "})]})}));t.Z=s},4284:function(e,t,n){n.r(t);var i=n(7313),o=n(9854),r=n(2860),a=n(7753),s=n(5160),c=n(6967),d=n(5380),u=n(58),l=n(8984),p=n(4669),h=n(513),v=n(9302),m=n(2575),f=n(7300),g=n(6524),w=n(8811),_=n(4522),E=n(778),I=n(7643),y=n(7008),L=n(7381),x=n(8181),S=n(6095),b=n(6417);const T=(0,m.Z)({key:"whatmore-css-ppv"}),D=i.lazy((()=>Promise.all([n.e(819),n.e(577),n.e(351),n.e(955),n.e(926),n.e(303),n.e(218),n.e(903)]).then(n.bind(n,3218))));function j(e){return e.split(/[?#]/)[0]}t.default=function(e){const[t,n]=(0,i.useState)(),[m,C]=(0,i.useState)(),[k]=(0,a.j1)("isInDesignMode"),[K]=(0,a.j1)("isDemoBrand"),[O]=(0,a.j1)("whatmoreEmbedAppUseVariant"),[P,V]=(0,i.useState)(-2),[M]=(0,a.j1)("whatmoreVariantId"),[A]=(0,a.j1)("whatmoreShopId");var[N]=(0,a.j1)("whatmoreProductId");const W=(0,a.MO)("isLandingSharedLink"),U=(0,a.MO)("whatmoreShareTemplateId"),B=(0,a.MO)("whatmoreShareEventId"),z=W&&"template-embed"===(0,g.zv)(U),[H,Z]=(0,i.useState)(z);N=(0,o.iXA)(A)?j(window.location.href):N;const[F,G]=(0,i.useState)((()=>"true"===O?M:N));var R=r.Gc+"/v2/brand/"+A+"/product-events";const{whatmoreWidgetSourceDetails:q}=(0,i.useContext)(w.I);(0,i.useEffect)((()=>{(0,L.Oo)("Video shopping powered by Whatmore!"),(0,c.hb)();const e=()=>{const e="_whatmore_bulk_events",t=JSON.parse(localStorage.getItem(e))||[];t&&t.length>0&&((0,y.K)(t),localStorage.removeItem(e))};return window.addEventListener("beforeunload",e),()=>{window.removeEventListener("beforeunload",e)}}),[]),(0,i.useEffect)((()=>{(0,p.ll)(A)}),[]),(0,i.useEffect)((()=>{null==t||0==t.length||m||!(0,l.KE)()||(0,a.MO)("whatmoreVideoPlayerPoolInitiated")||(0,u.b5)(u.UD)}),[t]),(0,i.useEffect)((()=>{V(-1),fetch(R.toString()+"?client_product_id="+F.toString()+"&status="+"upcoming".toString()+"&event_type=video").then((e=>e.json())).then((e=>e.events)).then((e=>(null!=e&&0!=e.length&&(0,o.Htz)(A)&&(0,o.d0x)(e),n(e),e))).then((e=>((0,o.yoE)(A)&&function(e,t){setTimeout((async()=>{const n=e.reduce(((e,t)=>[...e,...t.products]),[]).filter((e=>e.client_product_id==t))[0];if(!n||n.product_link==j(window.location.href))return;const i={product_id:n.product_id,product_link:j(window.location.href)};fetch(r.Gc+"/product",{method:"PUT",headers:{Accept:"application/json","Content-Type":"application/json"},body:JSON.stringify(i)})}),500)}(e,F),e))).catch((e=>{C(e.message)}))}),[F]),(0,i.useEffect)((()=>{var e,n;V(-2),(t&&t.length>0||(0,o.uO6)(A))&&(0,_.PB)({userInteractionType:E.K.PDP_VISITED,widgetSourceDetails:q,event:null===t||void 0===t?void 0:t[0],productList:null===t||void 0===t||null===(e=t[0])||void 0===e?void 0:e.products,ctaList:null===t||void 0===t||null===(n=t[0])||void 0===n?void 0:n.cta})}),[t]),(0,i.useEffect)((()=>{let e=history.pushState;history.pushState=function(){let t=e.apply(this,arguments);return window.dispatchEvent(new Event("pushstate")),window.dispatchEvent(new Event("locationchange")),t};let t=history.replaceState;history.replaceState=function(){let e=t.apply(this,arguments);return window.dispatchEvent(new Event("replacestate")),window.dispatchEvent(new Event("locationchange")),e},window.addEventListener("popstate",(()=>{window.dispatchEvent(new Event("locationchange"))})),window.addEventListener("locationchange",(function(){if("true"===O){const e=function(e){for(var t=window.location.search.substring(1).split("&"),n=0;n<t.length;n++){var i=t[n].split("=");if(i[0]==e)return i[1]}return!1}("variant");e&&""!==e&&G(e)}}))}),[]),(0,i.useEffect)((()=>{if(null!=t&&0!==t.length&&!m&&z&&((0,S.A)("whatmore-video-player",(()=>{Z(!1)})),null!=B)){const e=t.find((e=>B==e.event_id));if(e)return void Q(e,!0,t.indexOf(e))}}),[t]);const J=q.landingLocationType,Y=q.templateType,Q=function(e){let t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;if((0,l.KE)()&&!t&&(0,u.QV)(),(0,f.B6)(e)||(0,f.WJ)(e))return k||K||(async()=>{const t=(0,g.NY)(J)+(0,g.dS)(Y)+"_"+(null===e||void 0===e?void 0:e.event_id);(0,s.wh)(e),(0,p.Tc)(A,r.h7,r.dU),(0,c.H4)(e.event_id,e.products,"product_page","video_popup",t)})(),void V(n)};function X(){return(0,b.jsx)(b.Fragment,{})}return null==t||0==t.length||m?(0,b.jsx)("div",{}):(0,b.jsxs)(v.C,{value:T,children:[H&&(0,b.jsx)(x.Z,{}),"no-product"===F||-1===P||0===t.length?(0,b.jsx)(X,{}):-2===P&&t.length>0?(0,b.jsx)("div",{children:(0,b.jsx)(I.u,{userInteractionType:E.K.PDP_POPUP_WIDGET_VIEW,event:t[0],productList:t[0].products,cta:t[0].cta,triggerFlag:!k&&!K,children:(0,b.jsx)(d.Z,{event:t[0],inVideoClick:Q,closeClick:e=>{e.stopPropagation(),V(-1)}})})}):(0,b.jsx)("div",{children:(0,b.jsx)(i.Suspense,{children:(0,b.jsx)(I.u,{userInteractionType:E.K.EVENT_VIEW,event:t[0],productList:t[0].products,cta:t[0].cta,triggerFlag:!k&&!K,children:(0,b.jsx)(D,{events:t,index:P,onBack:function(e){(0,o.n2L)(A)&&(0,a.MO)("whatmoreAddedToCart")&&(0,h.D)(A,(()=>{}),100,window.location.hostname,e),V(-2),Z(!1)},template:"template-product-page"})})})})]})}},6095:function(e,t,n){function i(e,t){let n=0;let i=new MutationObserver((function(){document.querySelector("."+e)?(t(),i.disconnect()):0==n&&(n=1,setTimeout((()=>{t(),i.disconnect()}),8e3))}));i.observe(document.body,{childList:!0,subtree:!0})}n.d(t,{A:function(){return i}})},4522:function(e,t,n){n.d(t,{gW:function(){return s},GF:function(){return c},y4:function(){return u},PB:function(){return l},Z2:function(){return d}});var i=n(9854),o=n(7753),r=n(778);var a=n(733);const s={[r.K.EVENT_VIEW]:"whatmore_video_click_event",[r.K.VIDEO_LIKED]:"whatmore_video_like_event",[r.K.VIDEO_SHARE_CTA_CLICKED]:"whatmore_video_share_event",[r.K.PRODUCT_TILE_ATC_CLICKED]:"whatmore_video_atc_event",[r.K.SHOPNOW_ATC_CLICKED]:"whatmore_video_atc_event"};function c(e){var t;let{userInteractionType:n,userInteractionMetadata:c,widgetSourceDetails:d,event:u,productList:l,ctaList:p}=e;(0,a.s)({userInteractionType:n,userInteractionMetadata:c,widgetSourceDetails:d,event:u,productList:l,ctaList:p}),n in s&&function(e,t){const n=(0,o.MO)("whatmoreShopId");(e!=r.K.EVENT_VIEW||(0,i.UAB)(n))&&(e!=r.K.SHOPNOW_ATC_CLICKED&&e!=r.K.PRODUCT_TILE_ATC_CLICKED||(0,i.Tn_)(n))&&(e!=r.K.VIDEO_LIKED||(0,i.sKB)(n))&&(e!=r.K.VIDEO_SHARE_CTA_CLICKED||(0,i.YOU)(n))&&"function"==typeof fbq&&(async()=>{console.log("hello"),fbq("trackCustom",s[e],{id:null===t||void 0===t?void 0:t.client_product_id,product_url:null===t||void 0===t?void 0:t.product_link})})()}(n,null!==(t=null===l||void 0===l?void 0:l[1])&&void 0!==t?t:null===l||void 0===l?void 0:l[0])}function d(e){let{userInteractionType:t,userInteractionMetadata:n,widgetSourceDetails:i,event:o,productList:r,ctaList:s}=e;(0,a.s)({userInteractionType:t,userInteractionMetadata:n,widgetSourceDetails:i,event:o,productList:r,ctaList:s})}function u(e){let{userInteractionType:t,userInteractionMetadata:n,widgetSourceDetails:i,event:o,productList:r,ctaList:s}=e;(0,a.s)({userInteractionType:t,userInteractionMetadata:n,widgetSourceDetails:i,event:o,productList:r,ctaList:s})}function l(e){let{userInteractionType:t,userInteractionMetadata:n,widgetSourceDetails:i,event:o,productList:r,ctaList:s}=e;(0,a.s)({userInteractionType:t,userInteractionMetadata:n,widgetSourceDetails:i,event:o,productList:r,ctaList:s})}}}]);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[196,691,12],{1332:function(e,t,n){var r=n(7313),i=(n(8743),n(7753)),o=n(5254),a=n(6417);t.Z=function(e){return(0,r.useEffect)((()=>{const e=(0,o.oo)((0,i.MO)("whatmoreSecondaryColor"));!function(e,t,n,r){const i=`rgba(${e},${t},${n},${r})`,o=`\n @keyframes whatmore-loading-indicator-keyframe {\n 0%,\n 100% {\n box-shadow: 0em -2.6em 0em 0em ${i}, 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7);\n }\n 12.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.7), 1.8em -1.8em 0 0em ${i}, 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5);\n }\n 25% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.5), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 2.5em 0em 0 0em ${i}, 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 37.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 1.75em 1.75em 0 0em ${i}, 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 50% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 0em 2.5em 0 0em ${i}, -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 62.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -1.8em 1.8em 0 0em ${i}, -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 75% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -2.6em 0em 0 0em ${i}, -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 87.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -1.8em -1.8em 0 0em ${i};\n }\n }\n `,a=document.createElement("style");a.type="text/css",a.innerHTML=o,document.head.appendChild(a)}(e[0],e[1],e[2],.2)}),[]),(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("span",{className:"whatmore-loading-indicator"})})}},4658:function(e,t,n){n.r(t),n.d(t,{default:function(){return R}});var r=n(7313),i=n(6090),o=n(7616),a=(n(6143),n(7850),n(4444),n(7244),n(123),n(5892),n(1811),n(9302)),s=n(2575),l=n(7129),d=n(8811),m=(n(3439),n(7753)),c=n(7931),h=n(9018),u=n(9854),p=n(3933),g=n(8866),f=n(868),v=n(342),x=n(3437),$=n(3455),b=n(6417);var y=function(e){var t;const n=e.isMuted,r=null!==(t=e.iconSize)&&void 0!==t?t:30;function i(){e.onToggle()}return(0,b.jsx)("div",{style:{cursor:"pointer"},children:n?(0,b.jsx)($.Z,{sx:{color:"white",fontSize:r,filter:"drop-shadow(0 0 5px black);"},onClick:()=>{i()}}):(0,b.jsx)(x.Z,{sx:{color:"white",fontSize:r,filter:"drop-shadow(0 0 5px black);"},onClick:()=>{i()}})})},w=n(1896),j=n(8984),C=n(58),I=n(6119),P=n(4522),k=n(778),S=n(3433);function z(e){const[t,n]=(0,r.useState)(e.initialMuteState),i=e.events,o=e.activeEventIndex,a=e.setActiveEventIndex,s=(0,m.MO)("whatmoreShopId"),l="portrait"===e.mode;function d(){(0,u.hr)(s)&&e.isCTAPresent||(n(!t),(0,j.KE)()&&(0,C.QV)(),e.onMuteToggle())}const p=e.event;return(0,b.jsx)("div",{style:{position:(0,u.SJ)(s)?"absolute":"relative",top:(0,u.SJ)(s)?0:"",zIndex:1,bottom:(0,u.SJ)(s)?"":"100%",width:"100%",height:"100%",overflow:"hidden",backgroundColor:"transparent"},className:"whatmore-ios-css-relative-fix",children:(0,b.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",width:"100%",height:"100%",justifyContent:"space-between",alignItems:"center"},children:[(0,b.jsxs)("div",{className:"banner-event-overlay",style:{display:"flex",flexFlow:"row nowrap",justifyContent:"space-between",alignItems:"center",width:"100%",paddingRight:"1%",paddingLeft:"1%",paddingTop:"1%",backgroundImage:"linear-gradient(to top, rgba(0,0,0,0), rgba(0,0,0,0.1), rgba(0,0,0,0.3))"},children:[!(e.isCTAPresent&&(0,u.hr)(s)||"video"!==p.event_type)&&(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("div",{style:{width:"100%",height:"100%"},onClick:()=>d()}),(0,b.jsx)(y,{isMuted:t,onToggle:()=>{d()}})]}),i.length>1&&(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("div",{classname:"banner-navigation-overlay",style:{position:"absolute",left:"10px",top:"50%",transform:"translateY(-50%)",backgroundColor:"transparent",borderRadius:"50%",zIndex:2,border:"2px solid white",padding:"2px",cursor:"pointer"},onClick:e=>{e.stopPropagation(),a(0===o?i.length-1:o-1)},children:(0,b.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:"6px"},children:(0,b.jsx)("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",width:"20px",color:"#252525",height:"20px"},children:(0,b.jsx)(c.Z,{})})})}),(0,b.jsx)("div",{style:{position:"absolute",right:"10px",top:"50%",transform:"translateY(-50%)",backgroundColor:"transparent",borderRadius:"50%",zIndex:2,border:"2px solid white",padding:"2px",cursor:"pointer"},onClick:e=>{e.stopPropagation(),a(o===i.length-1?0:o+1)},children:(0,b.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:"6px"},children:(0,b.jsx)("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",width:"20px",color:"#252525",height:"20px",textAlign:"center"},children:(0,b.jsx)(h.Z,{})})})}),(0,u.cRS)(s)&&(0,b.jsx)("div",{style:{display:"flex",position:"absolute",bottom:"7%",left:"50%",transform:"translateX(-50%)",gap:"24px",zIndex:1},children:i.map(((e,t)=>{const n=t===o;return(0,b.jsx)("button",{onClick:e=>{e.stopPropagation(),a(t)},style:{width:n?"25px":l?"12px":"14px",height:l?"12px":"14px",borderRadius:n?"10px":"50%",backgroundColor:n?(0,u.YFz)(s):"#f8eeec",boxShadow:"0px 0px 8px rgba(0, 0, 0, 0.3)"}},t)}))})]})]}),(0,b.jsx)("div",{style:{width:"100%",height:"100%"},onClick:()=>d()})]})})}var M=function(e){var t,n,i;const[o,a,s]=(0,g.Z)(),[l,c]=(0,r.useState)(!0),{whatmoreUITheme:h}=(0,r.useContext)(d.I),x=(0,m.MO)("whatmoreVideoTileSize"),{ref:$,inView:y,entry:j}=(0,p.YD)({triggerOnce:!1}),{whatmoreWidgetSourceDetails:C}=(0,r.useContext)(d.I),M=(0,m.MO)("whatmoreShopId"),Z=e.events,R=e.activeEventIndex,E=e.setActiveEventIndex,N=Z[R],F=((0,u.nzC)(M),(0,v.uv)(N)),L=(0,v.WN)(N);if("portrait"===o&&!F)return(0,b.jsx)(b.Fragment,{});if("landscape"===o&&!L)return(0,b.jsx)(b.Fragment,{});const T=(0,f.V)("portrait"===o?F:L),A=x/100*(0,u.b4p)(M),O=x/100*(0,u.GmU)(M),D="portrait"===o?(0,u.oOc)(M):(0,u.snl)(M),V="portrait"===o?s*A:s*O,W=V*D,_=null!=(null===(t=N.cta)||void 0===t||null===(n=t[1])||void 0===n?void 0:n.cta_link);return(0,r.useEffect)((()=>{d.$.forEach((e=>{var t;if(!(null!==(t=e.querySelector('.whatmore-template-type[data-wh="template-banner-a"]'))&&void 0!==t?t:e.querySelector('.whatmore-template-type[data="template-banner-a"]')))return;const n=e.querySelector(".whatmore-base");n&&(n.style.minHeight="0px")}))}),[]),(0,b.jsxs)("div",{ref:$,onClick:()=>{var e,t;(0,P.GF)({userInteractionType:k.K.BANNER_WIDGET_CLICKED,widgetSourceDetails:C,event:Z[R]}),(0,u.hr)(M)&&_&&!(0,u.j1_)(M)&&window.open(null===(e=N.cta)||void 0===e||null===(t=e[1])||void 0===t?void 0:t.cta_link,"_self")},style:{position:"relative",margin:"0 auto",width:(0,u.SJ)(M)?"100%":V,minHeight:(0,u.SJ)(M)?s*D:"",height:(0,u.SJ)(M)?"auto":W,borderWidth:(0,u.alU)(M),borderColor:(0,u.qPe)(M),overflow:"hidden",cursor:"pointer"},children:[(0,b.jsx)(w.Z,{height:"100%",width:"100%",url:T,isPlaying:y,event:N,isVideoMuted:l,setDuration:e.setDuration,source:S.j.BANNER}),(0,b.jsx)(z,{isCTAPresent:_,events:Z,activeEventIndex:R,setActiveEventIndex:E,event:N,mode:o,onMuteToggle:()=>c(!l),initialMuteState:l}),(0,u.j1_)(M)&&(0,b.jsx)("div",{style:{position:"relative",zIndex:1,bottom:"portrait"===o?"12%":"20%"},className:"whatmore-ios-css-relative-fix",children:(0,b.jsx)("div",{children:(0,b.jsx)(I.Z,{event:N,cta:null===N||void 0===N||null===(i=N.cta)||void 0===i?void 0:i[1],fontFactor:.6})})})]})};const Z=(0,s.Z)({key:"whatmore-css-bv"});var R=function(e){const{whatmoreRootId:t}=(0,r.useContext)(d.I),[n,s]=(0,r.useState)(0),m=e.events,[c,h]=(0,r.useState)(-1);let u;return(0,r.useEffect)((()=>{u&&clearInterval(u);const e="video"===m[n].event_type,t=e?1e3*c:6e3;return e?-1!=c&&(u=setInterval((()=>{s((e=>e===m.length-1?0:e+1))}),t)):u=setInterval((()=>{s((e=>e===m.length-1?0:e+1))}),t),()=>{clearInterval(u)}}),[c,n]),delete o.ZP.styles.global,(0,b.jsx)(a.C,{value:Z,children:(0,b.jsx)("div",{className:"whatmore-banner-events",children:(0,b.jsx)(i.x,{theme:o.ZP,cssVarsRoot:t,resetCSS:!1,children:(0,b.jsx)(l.V.Provider,{value:{tileTopMargin:0,tileBottomMMargin:0,tileLeftMargin:0,tileRightMargin:0,showPlayButton:!1},children:(0,b.jsx)(M,{activeEventIndex:n,events:m,setActiveEventIndex:s,setDuration:h})})})})})}},3867:function(e,t,n){var r=n(8816),i=n(417),o=n(4885),a=n(7753),s=n(8811),l=n(7313),d=n(6417);t.Z=function(e){var t;const{whatmoreUITheme:n}=(0,l.useContext)(s.I),[m]=(0,a.j1)("whatmoreSecondaryColor"),[c,h]=(0,a.j1)("productRatings"),u=(0,a.MO)("whatmorePrimaryFont"),p=(e.storeId,e.productId),g=(e.productLink,e.fontSize),f=null!==(t=e.fontColor)&&void 0!==t?t:"gray";if(null===c||"undefined"==typeof c||!(p in c)||c[p].avgRating>5)return(0,d.jsx)(d.Fragment,{});const v=c[p].avgRating,x=c[p].totalRatings;return(0,d.jsx)("div",{style:{display:"flex",flexFlow:"column nowrap",width:"100%",height:"fit-content",justifyContent:"flex-start",alignItems:"center"},children:(0,d.jsxs)("div",{style:{display:"flex",flexFlow:"row nowrap",width:"100%",height:"fit-content",justifyContent:"flex-start",alignItems:"center",gap:"0px"},children:[[...Array(Math.floor(v))].map(((e,t)=>(0,d.jsx)(r.Z,{sx:{color:m,fontSize:g+"px"}},"star-icon"+t))),v-Math.floor(v)>.2?(0,d.jsx)(i.Z,{sx:{color:m,fontSize:g+"px"}},"star-half-icon"):v-Math.floor(v)==0?(0,d.jsx)(d.Fragment,{}):(0,d.jsx)(o.Z,{sx:{color:m,fontSize:g+"px"}},"star-outline-icon"),[...Array(Math.floor(5-v))].map(((e,t)=>(0,d.jsx)(o.Z,{sx:{color:m,fontSize:g+"px"}},"star-outline-icon-"+t))),(0,d.jsx)("div",{children:(0,d.jsx)("div",{width:"2px"})}),(0,d.jsx)("div",{children:(0,d.jsx)("div",{style:{backgroundColor:m,borderRadius:"round"==n?"2px":"0px",padding:"1px",overflow:"hidden"},children:(0,d.jsxs)("p",{ref:e=>{e&&(e.style.setProperty("color","white","important"),e.style.setProperty("font-size",.8*g+"px","important"),e.style.setProperty("font-family",u,"important"),e.style.setProperty("-webkit-line-clamp",2,"important"),e.style.setProperty("line-clamp",2,"important"),e.style.setProperty("-webkit-box-orient","vertical","important"),e.style.setProperty("display","-webkit-box","important"),e.style.setProperty("overflow","hidden","important"),e.style.setProperty("text-overflow","ellipsis","important"))},style:{textAlign:"left",fontWeight:"medium"},children:["\xa0",v,"\xa0"]})})}),(0,d.jsx)("div",{children:(0,d.jsxs)("p",{ref:e=>{e&&(e.style.setProperty("color",f,"important"),e.style.setProperty("font-size",.8*g+"px","important"),e.style.setProperty("font-family",u,"important"),e.style.setProperty("-webkit-line-clamp",2,"important"),e.style.setProperty("line-clamp",2,"important"),e.style.setProperty("-webkit-box-orient","vertical","important"),e.style.setProperty("display","-webkit-box","important"),e.style.setProperty("overflow","hidden","important"),e.style.setProperty("text-overflow","ellipsis","important"))},style:{textAlign:"left",fontWeight:"medium"},children:["\xa0","("+x+")"]})})]})})}},7129:function(e,t,n){n.d(t,{V:function(){return r}});const r=(0,n(7313).createContext)({tileTopMargin:10,tileBottomMMargin:10,tileLeftMargin:10,tileRightMargin:10,showPlayButton:!0})},3175:function(e,t,n){var r=n(1332),i=n(5180),o=n(6417);t.Z=function(e){var t,n;const a=null!==(t=e.height)&&void 0!==t?t:"100%",s=null!==(n=e.width)&&void 0!==n?n:"100%";return(0,o.jsxs)("div",{style:{width:s,height:a,overflow:"hidden",minHeight:a,minWidth:s},children:[(0,o.jsx)(i.Z,{height:a,width:s}),(0,o.jsx)("div",{style:{display:"flex",flexFlow:"column nowrap",justifyContent:"center",alignContent:"center",width:"100%",height:"100%",position:"relative",zIndex:1,bottom:"100%",className:"whatmore-ios-css-relative-fix"},children:(0,o.jsx)("div",{style:{display:"flex",flexFlow:"row nowrap",justifyContent:"center",width:"100%",height:"fit-content"},children:(0,o.jsx)(r.Z,{})})})]})}},5180:function(e,t,n){var r=n(6417);t.Z=function(e){var t,n,i;const o=null!==(t=e.height)&&void 0!==t?t:"100%",a=null!==(n=e.width)&&void 0!==n?n:"100%",s=null!==(i=e.borderRadius)&&void 0!==i?i:"10px";return(0,r.jsx)("div",{style:{height:o,width:o,borderRadius:s,overflow:"hidden",minHeight:o,minWidth:a,maxHeight:o,maxWidth:a},children:(0,r.jsx)("div",{style:{minHeight:o,minWidth:a},height:"100%",width:"100%",className:"whatmore-shimmer"})})}},2887:function(e,t,n){var r=n(7313),i=n(3175),o=n(6417);t.Z=function(e){var t,n,a;const[s,l]=(0,r.useState)(!1),d=r.useRef(0),m=(0,r.useRef)(null),c=null!==(t=e.timeUpdateCallback)&&void 0!==t?t:()=>{},h=null!==(n=e.height)&&void 0!==n?n:"100%",u=null!==(a=e.width)&&void 0!==a?a:"100%";return(0,r.useEffect)((()=>{d.current=0;const e=setInterval((()=>{d.current=d.current+.03,m.current&&c(d.current,5),d.current>=5&&(d.current=0)}),30);return()=>{clearInterval(e)}}),[e.isPlaying]),(0,o.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",width:u,height:h,overflow:"hidden"},children:[(0,o.jsx)("div",{style:{width:s?"100%":"0px",height:s?"100%":"0px"},children:(0,o.jsx)("img",{ref:m,src:e.url,style:{objectFit:"cover",height:h,width:u,backgroundColor:"white"},alt:"image player",onLoad:()=>{l(!0)}})}),s?(0,o.jsx)(o.Fragment,{}):(0,o.jsx)(i.Z,{width:u,height:h})]})}},4892:function(e,t,n){n.d(t,{Z:function(){return u}});var r=n(7313),i=n(3933),o=n(868),a=n(8984),s=n(7300),l=n(2887),d=n(4862),m=n(7753),c=n(6417);var h=function(e){var t,n;const o=(0,r.useRef)(null),[s,l,h]=(0,i.YD)({triggerOnce:!0}),u=(0,m.MO)("whatmoreShopId"),p=null!==(t=e.height)&&void 0!==t?t:"100%",g=null!==(n=e.width)&&void 0!==n?n:"100%";return(0,r.useEffect)((()=>{o.current&&(e.isPlaying?o.current.play():((d.G6||(0,a.gE)())&&o.current.play(),o.current.pause()))}),[e.isPlaying,l]),(0,c.jsx)("div",{ref:s,style:{width:p,height:g,overflow:"hidden"},children:l?(0,c.jsx)("video",{ref:o,className:"whatmore-video-player",width:g,height:p,preload:"metadata",loop:!0,playsInline:!0,poster:e.isPlaying&&"STRTFEDEDAP"!==u&&"STRY2V4XO5L"!==u?e.url:e.poster,muted:!0,src:e.url,style:{backgroundColor:"white"}}):(0,c.jsx)("div",{width:g,height:p,ref:e=>{e&&e.style.setProperty("display","block","important")}})})};var u=function(e){var t,n,d,m;const[u,p,g]=(0,i.YD)({triggerOnce:!0});if((0,s.WJ)(e.event))return(0,c.jsx)(l.Z,{height:e.height,width:e.width,url:e.url,isPlaying:e.isPlaying,timeUpdateCallback:e.timeUpdateCallback});const f=null!==(t=e.pauseFromPlayTimeInMs)&&void 0!==t?t:200;var v;if((0,a.KE)())return(0,c.jsx)(h,{height:"100%",width:"100%",poster:null===e||void 0===e||null===(v=e.event)||void 0===v?void 0:v.poster_image,url:(0,o.V)(e.url),isPlaying:e.isPlaying,pauseFromPlayTimeInMs:f});const x=(0,r.useRef)(null),$=null!==(n=e.height)&&void 0!==n?n:"100%",b=null!==(d=e.width)&&void 0!==d?d:"100%";return(0,r.useEffect)((()=>{x.current&&(e.isPlaying?x.current.play():x.current.pause())}),[e.isPlaying,p]),(0,c.jsx)("div",{ref:u,style:{width:$,height:b,overflow:"hidden"},children:p?(0,c.jsx)("video",{ref:x,className:"whatmore-video-player",width:b,height:$,preload:"metadata",loop:!0,playsInline:!0,muted:!0,src:(0,o.V)(e.url),poster:null===e||void 0===e||null===(m=e.event)||void 0===m?void 0:m.poster_image,style:{backgroundColor:"white"}}):(0,c.jsx)("div",{width:b,height:$,ref:e=>{e&&e.style.setProperty("display","block","important")}})})}},868:function(e,t,n){n.d(t,{V:function(){return s}});var r=n(9854),i=n(7753);const o={"https://d3syezql093hs1.cloudfront.net":"https://whatmore-brand-video-assets.azureedge.net","https://d2r0bijhs9mx1s.cloudfront.net":"https://whatmore-brand-thumbnail-video-assets.azureedge.net","https://d2oouab8j9eigo.cloudfront.net":"https://whatmore-brand-story-assets.azureedge.net","https://d28nus7q7qajdn.cloudfront.net":"https://whatmore-video-assets.azureedge.net","https://d1zl4k1t5o4s75.cloudfront.net":"https://whatmore-brand-video-assets-720p.azureedge.net"},a={"https://d3syezql093hs1.cloudfront.net":"https://whatmore-brand-video-assets.b-cdn.net","https://d2r0bijhs9mx1s.cloudfront.net":"https://whatmore-brand-thumbnail-video-assets.b-cdn.net","https://d2oouab8j9eigo.cloudfront.net":"https://whatmore-brand-story-assets.b-cdn.net","https://d28nus7q7qajdn.cloudfront.net":"https://whatmore-video-assets-old.b-cdn.net","https://d1zl4k1t5o4s75.cloudfront.net":"https://whatmore-brand-video-assets-720p.b-cdn.net"},s=function(e){const t=(0,i.MO)("whatmoreShopId");if(!e)return e;if(e.startsWith("https://cdn.shopify.com"))return e;if("AWSCDN"==(0,r.zpr)(t))return e;if("AZURECDN"==(0,r.zpr)(t)){if(e.includes(".azureedge.net"))return e;if(e.includes(".cloudfront.net")){for(const t of Object.keys(o))if(e.includes(t))return e.replace(t,o[t]);return e}}if("BUNNYCDN"==(0,r.zpr)(t)){if(e.includes(".b-cdn.net"))return e;if(e.includes(".cloudfront.net")){for(const t of Object.keys(a))if(e.includes(t))return e.replace(t,a[t]);return e}}return e}},9363:function(e,t,n){n.d(t,{$:function(){return a},s:function(){return o}});var r=n(9854),i=n(7753);function o(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const n=(0,i.MO)("whatmoreShopId");return"shopify"!=(0,r.Ipo)(n)?"STRNV8MHJTF"==n?e+"?format=webp":e:e+t}function a(e){var t;if(null!==e&&void 0!==e&&e.includes("https://w-media.b-cdn.net/process-media"))return"image";const n=null===e||void 0===e||null===(t=e.trim())||void 0===t?void 0:t.split("?")[0],r=/\.(jpeg|jpg|gif|png|svg|webp)$/i,i=/\.(mp4|mov|wmv|avi|flv|mkv)$/i;return null!==r&&void 0!==r&&r.test(n)?"image":null!==i&&void 0!==i&&i.test(n)?"video":void 0}},5456:function(e,t,n){n.d(t,{B:function(){return r}});const r=function(e,t){return!(isNaN(t)||!t||("string"===typeof t||t instanceof String)&&!t.trim().length)&&!(parseInt(t)<=parseInt(e))}},7931:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"M15.41 7.41 14 6l-6 6 6 6 1.41-1.41L10.83 12z"}),"NavigateBefore");t.Z=a},9018:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"NavigateNext");t.Z=a},9723:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"M8 6.82v10.36c0 .79.87 1.27 1.54.84l8.14-5.18c.62-.39.62-1.29 0-1.69L9.54 5.98C8.87 5.55 8 6.03 8 6.82z"}),"PlayArrowRounded");t.Z=a},8816:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"M12 17.27 18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"}),"Star");t.Z=a},417:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"m22 9.24-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4V6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z"}),"StarHalf");t.Z=a},4885:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"m22 9.24-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4l-3.76 2.27 1-4.28-3.32-2.88 4.38-.38L12 6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z"}),"StarOutline");t.Z=a},8743:function(){},3439:function(){},123:function(){},7244:function(){},5892:function(){},4444:function(){},1811:function(){},7850:function(){}}]);
|
|
1
|
+
"use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[196,691,12],{1332:function(e,t,n){var r=n(7313),i=(n(8743),n(7753)),o=n(5254),a=n(6417);t.Z=function(e){return(0,r.useEffect)((()=>{const e=(0,o.oo)((0,i.MO)("whatmoreSecondaryColor"));!function(e,t,n,r){const i=`rgba(${e},${t},${n},${r})`,o=`\n @keyframes whatmore-loading-indicator-keyframe {\n 0%,\n 100% {\n box-shadow: 0em -2.6em 0em 0em ${i}, 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7);\n }\n 12.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.7), 1.8em -1.8em 0 0em ${i}, 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5);\n }\n 25% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.5), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 2.5em 0em 0 0em ${i}, 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 37.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 1.75em 1.75em 0 0em ${i}, 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 50% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 0em 2.5em 0 0em ${i}, -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 62.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -1.8em 1.8em 0 0em ${i}, -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 75% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -2.6em 0em 0 0em ${i}, -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 87.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -1.8em -1.8em 0 0em ${i};\n }\n }\n `,a=document.createElement("style");a.type="text/css",a.innerHTML=o,document.head.appendChild(a)}(e[0],e[1],e[2],.2)}),[]),(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("span",{className:"whatmore-loading-indicator"})})}},4658:function(e,t,n){n.r(t),n.d(t,{default:function(){return R}});var r=n(7313),i=n(6090),o=n(7616),a=(n(6143),n(7850),n(4444),n(7244),n(123),n(5892),n(1811),n(9302)),s=n(2575),l=n(7129),d=n(8811),m=(n(3439),n(7753)),c=n(7931),h=n(9018),u=n(9854),p=n(3933),g=n(8866),f=n(868),v=n(342),x=n(3437),$=n(3455),b=n(6417);var y=function(e){var t;const n=e.isMuted,r=null!==(t=e.iconSize)&&void 0!==t?t:30;function i(){e.onToggle()}return(0,b.jsx)("div",{style:{cursor:"pointer"},children:n?(0,b.jsx)($.Z,{sx:{color:"white",fontSize:r,filter:"drop-shadow(0 0 5px black);"},onClick:()=>{i()}}):(0,b.jsx)(x.Z,{sx:{color:"white",fontSize:r,filter:"drop-shadow(0 0 5px black);"},onClick:()=>{i()}})})},w=n(1896),j=n(8984),C=n(58),I=n(6119),P=n(4522),k=n(778),S=n(3433);function z(e){const[t,n]=(0,r.useState)(e.initialMuteState),i=e.events,o=e.activeEventIndex,a=e.setActiveEventIndex,s=(0,m.MO)("whatmoreShopId"),l="portrait"===e.mode;function d(){(0,u.hr)(s)&&e.isCTAPresent||(n(!t),(0,j.KE)()&&(0,C.QV)(),e.onMuteToggle())}const p=e.event;return(0,b.jsx)("div",{style:{position:(0,u.SJ)(s)?"absolute":"relative",top:(0,u.SJ)(s)?0:"",zIndex:1,bottom:(0,u.SJ)(s)?"":"100%",width:"100%",height:"100%",overflow:"hidden",backgroundColor:"transparent"},className:"whatmore-ios-css-relative-fix",children:(0,b.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",width:"100%",height:"100%",justifyContent:"space-between",alignItems:"center"},children:[(0,b.jsxs)("div",{className:"banner-event-overlay",style:{display:"flex",flexFlow:"row nowrap",justifyContent:"space-between",alignItems:"center",width:"100%",paddingRight:"1%",paddingLeft:"1%",paddingTop:"1%",backgroundImage:"linear-gradient(to top, rgba(0,0,0,0), rgba(0,0,0,0.1), rgba(0,0,0,0.3))"},children:[!(e.isCTAPresent&&(0,u.hr)(s)||"video"!==p.event_type)&&(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("div",{style:{width:"100%",height:"100%"},onClick:()=>d()}),(0,b.jsx)(y,{isMuted:t,onToggle:()=>{d()}})]}),i.length>1&&(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)("div",{classname:"banner-navigation-overlay",style:{position:"absolute",left:"10px",top:"50%",transform:"translateY(-50%)",backgroundColor:"transparent",borderRadius:"50%",zIndex:2,border:"2px solid white",padding:"2px",cursor:"pointer"},onClick:e=>{e.stopPropagation(),a(0===o?i.length-1:o-1)},children:(0,b.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:"6px"},children:(0,b.jsx)("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",width:"20px",color:"#252525",height:"20px"},children:(0,b.jsx)(c.Z,{})})})}),(0,b.jsx)("div",{style:{position:"absolute",right:"10px",top:"50%",transform:"translateY(-50%)",backgroundColor:"transparent",borderRadius:"50%",zIndex:2,border:"2px solid white",padding:"2px",cursor:"pointer"},onClick:e=>{e.stopPropagation(),a(o===i.length-1?0:o+1)},children:(0,b.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:"6px"},children:(0,b.jsx)("div",{style:{display:"flex",alignItems:"center",justifyContent:"center",width:"20px",color:"#252525",height:"20px",textAlign:"center"},children:(0,b.jsx)(h.Z,{})})})}),(0,u.cRS)(s)&&(0,b.jsx)("div",{style:{display:"flex",position:"absolute",bottom:"7%",left:"50%",transform:"translateX(-50%)",gap:"24px",zIndex:1},children:i.map(((e,t)=>{const n=t===o;return(0,b.jsx)("button",{onClick:e=>{e.stopPropagation(),a(t)},style:{width:n?"25px":l?"12px":"14px",height:l?"12px":"14px",borderRadius:n?"10px":"50%",backgroundColor:n?(0,u.YFz)(s):"#f8eeec",boxShadow:"0px 0px 8px rgba(0, 0, 0, 0.3)"}},t)}))})]})]}),(0,b.jsx)("div",{style:{width:"100%",height:"100%"},onClick:()=>d()})]})})}var M=function(e){var t,n,i;const[o,a,s]=(0,g.Z)(),[l,c]=(0,r.useState)(!0),{whatmoreUITheme:h}=(0,r.useContext)(d.I),x=(0,m.MO)("whatmoreVideoTileSize"),{ref:$,inView:y,entry:j}=(0,p.YD)({triggerOnce:!1}),{whatmoreWidgetSourceDetails:C}=(0,r.useContext)(d.I),M=(0,m.MO)("whatmoreShopId"),Z=e.events,R=e.activeEventIndex,E=e.setActiveEventIndex,N=Z[R],F=((0,u.nzC)(M),(0,v.uv)(N)),L=(0,v.WN)(N);if("portrait"===o&&!F)return(0,b.jsx)(b.Fragment,{});if("landscape"===o&&!L)return(0,b.jsx)(b.Fragment,{});const T=(0,f.V)("portrait"===o?F:L),A=x/100*(0,u.b4p)(M),O=x/100*(0,u.GmU)(M),D="portrait"===o?(0,u.oOc)(M):(0,u.snl)(M),V="portrait"===o?s*A:s*O,W=V*D,_=null!=(null===(t=N.cta)||void 0===t||null===(n=t[1])||void 0===n?void 0:n.cta_link);return(0,r.useEffect)((()=>{d.$.forEach((e=>{var t;if(!(null!==(t=e.querySelector('.whatmore-template-type[data-wh="template-banner-a"]'))&&void 0!==t?t:e.querySelector('.whatmore-template-type[data="template-banner-a"]')))return;const n=e.querySelector(".whatmore-base");n&&(n.style.minHeight="0px")}))}),[]),(0,b.jsxs)("div",{ref:$,onClick:()=>{var e,t;(0,P.GF)({userInteractionType:k.K.BANNER_WIDGET_CLICKED,widgetSourceDetails:C,event:Z[R]}),(0,u.hr)(M)&&_&&!(0,u.j1_)(M)&&window.open(null===(e=N.cta)||void 0===e||null===(t=e[1])||void 0===t?void 0:t.cta_link,"_self")},style:{position:"relative",margin:"0 auto",width:(0,u.SJ)(M)?"100%":V,minHeight:(0,u.SJ)(M)?s*D:"",height:(0,u.SJ)(M)?"auto":W,borderWidth:(0,u.alU)(M),borderColor:(0,u.qPe)(M),overflow:"hidden",cursor:"pointer"},children:[(0,b.jsx)(w.Z,{height:"100%",width:"100%",url:T,isPlaying:y,event:N,isVideoMuted:l,setDuration:e.setDuration,source:S.j.BANNER}),(0,b.jsx)(z,{isCTAPresent:_,events:Z,activeEventIndex:R,setActiveEventIndex:E,event:N,mode:o,onMuteToggle:()=>c(!l),initialMuteState:l}),(0,u.j1_)(M)&&(0,b.jsx)("div",{style:{position:"relative",zIndex:1,bottom:"portrait"===o?"12%":"20%"},className:"whatmore-ios-css-relative-fix",children:(0,b.jsx)("div",{children:(0,b.jsx)(I.Z,{event:N,cta:null===N||void 0===N||null===(i=N.cta)||void 0===i?void 0:i[1],fontFactor:.6})})})]})};const Z=(0,s.Z)({key:"whatmore-css-bv"});var R=function(e){const{whatmoreRootId:t}=(0,r.useContext)(d.I),[n,s]=(0,r.useState)(0),m=e.events,[c,h]=(0,r.useState)(-1);let u;return(0,r.useEffect)((()=>{u&&clearInterval(u);const e="video"===m[n].event_type,t=e?1e3*c:6e3;return e?-1!=c&&(u=setInterval((()=>{s((e=>e===m.length-1?0:e+1))}),t)):u=setInterval((()=>{s((e=>e===m.length-1?0:e+1))}),t),()=>{clearInterval(u)}}),[c,n]),delete o.ZP.styles.global,(0,b.jsx)(a.C,{value:Z,children:(0,b.jsx)("div",{className:"whatmore-banner-events",children:(0,b.jsx)(i.x,{theme:o.ZP,cssVarsRoot:t,resetCSS:!1,children:(0,b.jsx)(l.V.Provider,{value:{tileTopMargin:0,tileBottomMMargin:0,tileLeftMargin:0,tileRightMargin:0,showPlayButton:!1},children:(0,b.jsx)(M,{activeEventIndex:n,events:m,setActiveEventIndex:s,setDuration:h})})})})})}},3867:function(e,t,n){var r=n(8816),i=n(417),o=n(4885),a=n(7753),s=n(8811),l=n(7313),d=n(6417);t.Z=function(e){var t;const{whatmoreUITheme:n}=(0,l.useContext)(s.I),[m]=(0,a.j1)("whatmoreSecondaryColor"),[c,h]=(0,a.j1)("productRatings"),u=(0,a.MO)("whatmorePrimaryFont"),p=(e.storeId,e.productId),g=(e.productLink,e.fontSize),f=null!==(t=e.fontColor)&&void 0!==t?t:"gray";if(null===c||"undefined"==typeof c||!(p in c)||c[p].avgRating>5)return(0,d.jsx)(d.Fragment,{});const v=c[p].avgRating,x=c[p].totalRatings;return(0,d.jsx)("div",{style:{display:"flex",flexFlow:"column nowrap",width:"100%",height:"fit-content",justifyContent:"flex-start",alignItems:"center"},children:(0,d.jsxs)("div",{style:{display:"flex",flexFlow:"row nowrap",width:"100%",height:"fit-content",justifyContent:"flex-start",alignItems:"center",gap:"0px"},children:[[...Array(Math.floor(v))].map(((e,t)=>(0,d.jsx)(r.Z,{sx:{color:m,fontSize:g+"px"}},"star-icon"+t))),v-Math.floor(v)>.2?(0,d.jsx)(i.Z,{sx:{color:m,fontSize:g+"px"}},"star-half-icon"):v-Math.floor(v)==0?(0,d.jsx)(d.Fragment,{}):(0,d.jsx)(o.Z,{sx:{color:m,fontSize:g+"px"}},"star-outline-icon"),[...Array(Math.floor(5-v))].map(((e,t)=>(0,d.jsx)(o.Z,{sx:{color:m,fontSize:g+"px"}},"star-outline-icon-"+t))),(0,d.jsx)("div",{children:(0,d.jsx)("div",{width:"2px"})}),(0,d.jsx)("div",{children:(0,d.jsx)("div",{style:{backgroundColor:m,borderRadius:"round"==n?"2px":"0px",padding:"1px",overflow:"hidden"},children:(0,d.jsxs)("p",{ref:e=>{e&&(e.style.setProperty("color","white","important"),e.style.setProperty("font-size",.8*g+"px","important"),e.style.setProperty("font-family",u,"important"),e.style.setProperty("-webkit-line-clamp",2,"important"),e.style.setProperty("line-clamp",2,"important"),e.style.setProperty("-webkit-box-orient","vertical","important"),e.style.setProperty("display","-webkit-box","important"),e.style.setProperty("overflow","hidden","important"),e.style.setProperty("text-overflow","ellipsis","important"))},style:{textAlign:"left",fontWeight:"medium"},children:["\xa0",v,"\xa0"]})})}),(0,d.jsx)("div",{children:(0,d.jsxs)("p",{ref:e=>{e&&(e.style.setProperty("color",f,"important"),e.style.setProperty("font-size",.8*g+"px","important"),e.style.setProperty("font-family",u,"important"),e.style.setProperty("-webkit-line-clamp",2,"important"),e.style.setProperty("line-clamp",2,"important"),e.style.setProperty("-webkit-box-orient","vertical","important"),e.style.setProperty("display","-webkit-box","important"),e.style.setProperty("overflow","hidden","important"),e.style.setProperty("text-overflow","ellipsis","important"))},style:{textAlign:"left",fontWeight:"medium"},children:["\xa0","("+x+")"]})})]})})}},7129:function(e,t,n){n.d(t,{V:function(){return r}});const r=(0,n(7313).createContext)({tileTopMargin:10,tileBottomMMargin:10,tileLeftMargin:10,tileRightMargin:10,showPlayButton:!0})},3175:function(e,t,n){var r=n(1332),i=n(5180),o=n(6417);t.Z=function(e){var t,n;const a=null!==(t=e.height)&&void 0!==t?t:"100%",s=null!==(n=e.width)&&void 0!==n?n:"100%";return(0,o.jsxs)("div",{style:{width:s,height:a,overflow:"hidden",minHeight:a,minWidth:s},children:[(0,o.jsx)(i.Z,{height:a,width:s}),(0,o.jsx)("div",{style:{display:"flex",flexFlow:"column nowrap",justifyContent:"center",alignContent:"center",width:"100%",height:"100%",position:"relative",zIndex:1,bottom:"100%",className:"whatmore-ios-css-relative-fix"},children:(0,o.jsx)("div",{style:{display:"flex",flexFlow:"row nowrap",justifyContent:"center",width:"100%",height:"fit-content"},children:(0,o.jsx)(r.Z,{})})})]})}},5180:function(e,t,n){var r=n(6417);t.Z=function(e){var t,n,i;const o=null!==(t=e.height)&&void 0!==t?t:"100%",a=null!==(n=e.width)&&void 0!==n?n:"100%",s=null!==(i=e.borderRadius)&&void 0!==i?i:"10px";return(0,r.jsx)("div",{style:{height:o,width:o,borderRadius:s,overflow:"hidden",minHeight:o,minWidth:a,maxHeight:o,maxWidth:a},children:(0,r.jsx)("div",{style:{minHeight:o,minWidth:a},height:"100%",width:"100%",className:"whatmore-shimmer"})})}},2887:function(e,t,n){var r=n(7313),i=n(3175),o=n(6417);t.Z=function(e){var t,n,a;const[s,l]=(0,r.useState)(!1),d=r.useRef(0),m=(0,r.useRef)(null),c=null!==(t=e.timeUpdateCallback)&&void 0!==t?t:()=>{},h=null!==(n=e.height)&&void 0!==n?n:"100%",u=null!==(a=e.width)&&void 0!==a?a:"100%";return(0,r.useEffect)((()=>{d.current=0;const e=setInterval((()=>{d.current=d.current+.03,m.current&&c(d.current,5),d.current>=5&&(d.current=0)}),30);return()=>{clearInterval(e)}}),[e.isPlaying]),(0,o.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",width:u,height:h,overflow:"hidden"},children:[(0,o.jsx)("div",{style:{width:s?"100%":"0px",height:s?"100%":"0px"},children:(0,o.jsx)("img",{ref:m,src:e.url,style:{objectFit:"cover",height:h,width:u,backgroundColor:"white"},alt:"image player",onLoad:()=>{l(!0)}})}),s?(0,o.jsx)(o.Fragment,{}):(0,o.jsx)(i.Z,{width:u,height:h})]})}},4892:function(e,t,n){n.d(t,{Z:function(){return u}});var r=n(7313),i=n(3933),o=n(868),a=n(8984),s=n(7300),l=n(2887),d=n(4862),m=n(7753),c=n(6417);var h=function(e){var t,n;const o=(0,r.useRef)(null),[s,l,h]=(0,i.YD)({triggerOnce:!0}),u=(0,m.MO)("whatmoreShopId"),p=null!==(t=e.height)&&void 0!==t?t:"100%",g=null!==(n=e.width)&&void 0!==n?n:"100%";return(0,r.useEffect)((()=>{o.current&&(e.isPlaying?o.current.play():((d.G6||(0,a.gE)())&&o.current.play(),o.current.pause()))}),[e.isPlaying,l]),(0,c.jsx)("div",{ref:s,style:{width:p,height:g,overflow:"hidden"},children:l?(0,c.jsx)("video",{ref:o,className:"whatmore-video-player-muted",width:g,height:p,preload:"metadata",loop:!0,playsInline:!0,poster:e.isPlaying&&"STRTFEDEDAP"!==u&&"STRY2V4XO5L"!==u?e.url:e.poster,muted:!0,src:e.url,style:{backgroundColor:"white"}}):(0,c.jsx)("div",{width:g,height:p,ref:e=>{e&&e.style.setProperty("display","block","important")}})})};var u=function(e){var t,n,d,m;const[u,p,g]=(0,i.YD)({triggerOnce:!0});if((0,s.WJ)(e.event))return(0,c.jsx)(l.Z,{height:e.height,width:e.width,url:e.url,isPlaying:e.isPlaying,timeUpdateCallback:e.timeUpdateCallback});const f=null!==(t=e.pauseFromPlayTimeInMs)&&void 0!==t?t:200;var v;if((0,a.KE)())return(0,c.jsx)(h,{height:"100%",width:"100%",poster:null===e||void 0===e||null===(v=e.event)||void 0===v?void 0:v.poster_image,url:(0,o.V)(e.url),isPlaying:e.isPlaying,pauseFromPlayTimeInMs:f});const x=(0,r.useRef)(null),$=null!==(n=e.height)&&void 0!==n?n:"100%",b=null!==(d=e.width)&&void 0!==d?d:"100%";return(0,r.useEffect)((()=>{x.current&&(e.isPlaying?x.current.play():x.current.pause())}),[e.isPlaying,p]),(0,c.jsx)("div",{ref:u,style:{width:$,height:b,overflow:"hidden"},children:p?(0,c.jsx)("video",{ref:x,className:"whatmore-video-player-muted",width:b,height:$,preload:"metadata",loop:!0,playsInline:!0,muted:!0,src:(0,o.V)(e.url),poster:null===e||void 0===e||null===(m=e.event)||void 0===m?void 0:m.poster_image,style:{backgroundColor:"white"}}):(0,c.jsx)("div",{width:b,height:$,ref:e=>{e&&e.style.setProperty("display","block","important")}})})}},868:function(e,t,n){n.d(t,{V:function(){return s}});var r=n(9854),i=n(7753);const o={"https://d3syezql093hs1.cloudfront.net":"https://whatmore-brand-video-assets.azureedge.net","https://d2r0bijhs9mx1s.cloudfront.net":"https://whatmore-brand-thumbnail-video-assets.azureedge.net","https://d2oouab8j9eigo.cloudfront.net":"https://whatmore-brand-story-assets.azureedge.net","https://d28nus7q7qajdn.cloudfront.net":"https://whatmore-video-assets.azureedge.net","https://d1zl4k1t5o4s75.cloudfront.net":"https://whatmore-brand-video-assets-720p.azureedge.net"},a={"https://d3syezql093hs1.cloudfront.net":"https://whatmore-brand-video-assets.b-cdn.net","https://d2r0bijhs9mx1s.cloudfront.net":"https://whatmore-brand-thumbnail-video-assets.b-cdn.net","https://d2oouab8j9eigo.cloudfront.net":"https://whatmore-brand-story-assets.b-cdn.net","https://d28nus7q7qajdn.cloudfront.net":"https://whatmore-video-assets-old.b-cdn.net","https://d1zl4k1t5o4s75.cloudfront.net":"https://whatmore-brand-video-assets-720p.b-cdn.net"},s=function(e){const t=(0,i.MO)("whatmoreShopId");if(!e)return e;if(e.startsWith("https://cdn.shopify.com"))return e;if("AWSCDN"==(0,r.zpr)(t))return e;if("AZURECDN"==(0,r.zpr)(t)){if(e.includes(".azureedge.net"))return e;if(e.includes(".cloudfront.net")){for(const t of Object.keys(o))if(e.includes(t))return e.replace(t,o[t]);return e}}if("BUNNYCDN"==(0,r.zpr)(t)){if(e.includes(".b-cdn.net"))return e;if(e.includes(".cloudfront.net")){for(const t of Object.keys(a))if(e.includes(t))return e.replace(t,a[t]);return e}}return e}},9363:function(e,t,n){n.d(t,{$:function(){return a},s:function(){return o}});var r=n(9854),i=n(7753);function o(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";const n=(0,i.MO)("whatmoreShopId");return"shopify"!=(0,r.Ipo)(n)?"STRNV8MHJTF"==n?e+"?format=webp":e:e+t}function a(e){var t;if(null!==e&&void 0!==e&&e.includes("https://w-media.b-cdn.net/process-media"))return"image";const n=null===e||void 0===e||null===(t=e.trim())||void 0===t?void 0:t.split("?")[0],r=/\.(jpeg|jpg|gif|png|svg|webp)$/i,i=/\.(mp4|mov|wmv|avi|flv|mkv)$/i;return null!==r&&void 0!==r&&r.test(n)?"image":null!==i&&void 0!==i&&i.test(n)?"video":void 0}},5456:function(e,t,n){n.d(t,{B:function(){return r}});const r=function(e,t){return!(isNaN(t)||!t||("string"===typeof t||t instanceof String)&&!t.trim().length)&&!(parseInt(t)<=parseInt(e))}},7931:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"M15.41 7.41 14 6l-6 6 6 6 1.41-1.41L10.83 12z"}),"NavigateBefore");t.Z=a},9018:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"M10 6 8.59 7.41 13.17 12l-4.58 4.59L10 18l6-6z"}),"NavigateNext");t.Z=a},9723:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"M8 6.82v10.36c0 .79.87 1.27 1.54.84l8.14-5.18c.62-.39.62-1.29 0-1.69L9.54 5.98C8.87 5.55 8 6.03 8 6.82z"}),"PlayArrowRounded");t.Z=a},8816:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"M12 17.27 18.18 21l-1.64-7.03L22 9.24l-7.19-.61L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21z"}),"Star");t.Z=a},417:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"m22 9.24-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4V6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z"}),"StarHalf");t.Z=a},4885:function(e,t,n){var r=n(5318);t.Z=void 0;var i=r(n(5045)),o=n(6417),a=(0,i.default)((0,o.jsx)("path",{d:"m22 9.24-7.19-.62L12 2 9.19 8.63 2 9.24l5.46 4.73L5.82 21 12 17.27 18.18 21l-1.63-7.03L22 9.24zM12 15.4l-3.76 2.27 1-4.28-3.32-2.88 4.38-.38L12 6.1l1.71 4.04 4.38.38-3.32 2.88 1 4.28L12 15.4z"}),"StarOutline");t.Z=a},8743:function(){},3439:function(){},123:function(){},7244:function(){},5892:function(){},4444:function(){},1811:function(){},7850:function(){}}]);
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
0% {
|
|
74
74
|
transform: translateY(100%);
|
|
75
75
|
}
|
|
76
|
-
`} 0.5s`,bt=null===q||void 0===q||null===(e=q.options)||void 0===e?void 0:e.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"))})),[It,kt]=(0,r.useState)(-1!==bt?null===(n=q.options)||void 0===n||null===(i=n[bt])||void 0===i||null===(o=i.values)||void 0===o?void 0:o[0]:""),[_t,Ft]=(0,r.useState)({});(0,r.useEffect)((()=>{-1!==bt&&"whatmore"!==(0,c.Ipo)(wt)&&async function(){const t=await(0,lt.m3)(Z);Ft(t)}()}),[]);let Tt=-1,Et=-1!==bt&&null!==_t&&void 0!==_t&&_t.product&&(null===_t||void 0===_t||null===(l=_t.product)||void 0===l||null===(a=l.images)||void 0===a?void 0:a.length)>=(null===_t||void 0===_t||null===(d=_t.product)||void 0===d||null===(p=d.options)||void 0===p||null===(v=p[bt])||void 0===v||null===(m=v.values)||void 0===m?void 0:m.length)?null===_t||void 0===_t||null===(f=_t.product)||void 0===f||null===(w=f.images)||void 0===w?void 0:w.map((t=>{var e,n,i,o,r,l,a,d,s,c,u,h,p,v;const x=null===_t||void 0===_t||null===(e=_t.product)||void 0===e||null===(n=e.options)||void 0===n?void 0:n.findIndex((t=>"Color"==(null===t||void 0===t?void 0:t.name)||"Colour"==(null===t||void 0===t?void 0:t.name)||"COLOR"==(null===t||void 0===t?void 0:t.name)));return{color:(null===t||void 0===t?void 0:t.variant_ids.length)>0?null===_t||void 0===_t||null===(i=_t.product)||void 0===i||null===(o=i.options)||void 0===o||null===(r=o[x])||void 0===r||null===(l=r.values)||void 0===l?void 0:l[Math.min(++Tt,(null===_t||void 0===_t||null===(a=_t.product)||void 0===a||null===(d=a.options)||void 0===d||null===(s=d[bt])||void 0===s||null===(c=s.values)||void 0===c?void 0:c.length)-1)]:null===_t||void 0===_t||null===(u=_t.product)||void 0===u||null===(h=u.options)||void 0===h||null===(p=h[x])||void 0===p||null===(v=p.values)||void 0===v?void 0:v[Math.max(0,Tt)],src:null===t||void 0===t?void 0:t.src}})):[],Pt=[];if("whatmore"==(0,c.Ipo)(wt)&&(null===q||void 0===q||null===(j=q.images)||void 0===j?void 0:j.length)>0){var Ot;var Lt;if(-1!==(null===q||void 0===q||null===(Ot=q.options)||void 0===Ot?void 0:Ot.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"))}))))Pt=null===q||void 0===q||null===(Lt=q.images)||void 0===Lt?void 0:Lt.map((t=>({color:t.color,src:t.src,optionsrc:t.optionsrc})))}return Tt+1<(null===_t||void 0===_t||null===(y=_t.product)||void 0===y||null===(C=y.options)||void 0===C||null===(b=C[bt])||void 0===b||null===(I=b.values)||void 0===I?void 0:I.length)&&(Et=[]),(0,x.jsxs)(s.kC,{sx:{"&::-webkit-scrollbar":{width:"0px"}},id:"whatmore-shopnow-view",position:"relative",maxHeight:"75vh",overflowY:"scroll",direction:"column",bg:"#FFF",height:"fit-content",opacity:"100%",borderTopRadius:"round"==(null===ft||void 0===ft?void 0:ft.whatmoreUITheme)?"xl":null,animation:St,children:[(0,x.jsx)(At,{setOpenShopNow:U,setLockSwiper:B,FONT_SIZE:A}),(0,x.jsx)(s.M5,{marginBottom:"10px",px:"20px",py:"5px",children:(0,x.jsx)(s.kC,{bg:"whiteAlpha.900",width:"fit-content",height:"fit-content",borderRadius:"round"==(null===ft||void 0===ft?void 0:ft.whatmoreUITheme)?"lg":null,overflow:"hidden",sx:{borderWidth:(0,c.alU)(wt),borderColor:(0,c.qPe)(wt)},children:(0,x.jsx)(s.kC,{width:"100%",children:(0,x.jsx)(Zt.P,{renderElement:t=>(0,x.jsx)(x.Fragment,{children:(0,x.jsx)(s.xu,{width:M+"px",height:D+"px",children:(0,x.jsx)(g.Ee,{width:M+"px",height:D+"px",borderRadius:"round"==(null===ft||void 0===ft?void 0:ft.whatmoreUITheme)?"lg":null,src:(0,pt.s)(t.eventData.src,"&width=400&height=400"),alt:Z.handle,sx:{objectFit:(0,c.yOX)(wt)+" !important"},fallback:(0,x.jsx)(K.Z,{width:M+"px",height:D+"px",borderRadius:"round"==(null===ft||void 0===ft?void 0:ft.whatmoreUITheme)?"10px":"0px"})})})}),dataList:Et.length>0&&!Et.includes(null)?null===(k=Et)||void 0===k?void 0:k.filter((t=>(null===t||void 0===t?void 0:t.color)==It)):Pt.length>0?[null===(_=Pt)||void 0===_?void 0:_.find((t=>(null===t||void 0===t?void 0:t.color)==It))]:null===q||void 0===q||null===(F=q.images)||void 0===F?void 0:F.map((t=>({src:t.includes("https")?t:"https:"+t}))),spacing:10,defaultHeight:M+"px",defaultWidth:D+"px",retainAlreadyRenderedElements:!0,isScroll:!0})})})}),(0,x.jsx)(Ht,{data:q,product:Z,PRODUCT_TILE_HEIGHT:R,PRODUCT_TILE_WIDTH:z,FONT_SIZE:A,getVariantPrice:Yt,selectedVariantId:et,itemPrice:at,itemQuantity:it,setItemQuantity:ot,thumbnailImage:mt}),(null===q||void 0===q||null===(T=q.variants)||void 0===T?void 0:T.length)>0&&(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(s.M5,{paddingTop:"4px",width:"100%",children:(0,x.jsx)(s.iz,{color:(0,c.W8U)(wt),size:"xs",width:"90%"})}),(0,x.jsx)(Vt,{data:q,dividerColor:(0,c.W8U)(wt),setSelectedColor:kt,finalArr:Et,finalArrExternal:Pt,product:Z,PRODUCT_TILE_HEIGHT:R,PRODUCT_TILE_WIDTH:z,FONT_SIZE:A,selectOptionFirstHandler:jt,selectOptionSecondHandler:yt,selectOptionThirdHandler:Ct,getVariantPrice:Yt,selectedOptionFirst:X,selectedOptionSecond:$,selectedOptionThird:Q,selectedVariantId:et})]}),c.$2G&&((null===q||void 0===q?void 0:q.description)||(null===q||void 0===q?void 0:q.body_html))&&(0,x.jsx)(Wt,{PRODUCT_TILE_HEIGHT:R,FONT_SIZE:A,data:q,handleToggle:()=>N(!W),show:W}),(0,x.jsx)(s.xu,{sx:{pointerEvents:"none"},paddingTop:"20px",opacity:0,children:(0,x.jsx)(Kt,{position:"relative",data:q,FONT_SIZE:A,product:Z})}),(0,x.jsx)(Kt,{position:"fixed",selectedVariantId:et,data:q,FONT_SIZE:A,PRODUCT_TILE_WIDTH:z,product:Z,itemQuantity:it,cartItemCount:st,addToCartFlag:ut,setAddToCartFlag:ht,soldOutFlag:vt,setSoldOutFlag:xt,event:H})]})}const Bt=(t,e,n,i)=>{var o,r,l,a,d,s,c,u,h,p;if(void 0===e&&void 0===n&&void 0===i)return null===t||void 0===t||null===(o=t.variants)||void 0===o||null===(r=o[0])||void 0===r?void 0:r.id;if(void 0===i&&void 0===n)return null===(l=t.variants.find((t=>t.option1===e)))||void 0===l?void 0:l.id;if(void 0===i&&void 0===e)return null===(a=t.variants.find((t=>t.option2===n)))||void 0===a?void 0:a.id;if(void 0===n&&void 0===e)return null===(d=t.variants.find((t=>t.option3===i)))||void 0===d?void 0:d.id;if(void 0===n)return null===(s=t.variants.find((t=>t.option1===e&&t.option3===i)))||void 0===s?void 0:s.id;if(void 0===i)return null===(c=t.variants.find((t=>t.option1===e&&t.option2===n)))||void 0===c?void 0:c.id;if(void 0===e)return null===(u=t.variants.find((t=>t.option2===n&&t.option3===i)))||void 0===u?void 0:u.id;const v=null===t||void 0===t?void 0:t.variants.find((t=>t.option1===e&&t.option2===n&&t.option3===i));return void 0===v?null===t||void 0===t||null===(h=t.variants)||void 0===h||null===(p=h[0])||void 0===p?void 0:p.id:v.id},Yt=(t,e)=>{var n,i;return null===t||void 0===t||null===(n=t.variants)||void 0===n||null===(i=n.find((t=>t.id===e)))||void 0===i?void 0:i.price},Xt=(t,e)=>{var n,i;return null===t||void 0===t||null===(n=t.variants)||void 0===n||null===(i=n.find((t=>t.id.toString()===e)))||void 0===i?void 0:i.option1},Gt=(t,e)=>{var n,i;return null===t||void 0===t||null===(n=t.variants)||void 0===n||null===(i=n.find((t=>t.id.toString()===e)))||void 0===i?void 0:i.option2},$t=(t,e)=>{var n,i;return null===t||void 0===t||null===(n=t.variants)||void 0===n||null===(i=n.find((t=>t.id.toString()===e)))||void 0===i?void 0:i.option3},Jt=(t,e)=>{var n;const i=null===t||void 0===t||null===(n=t.variants)||void 0===n?void 0:n.find((t=>t.id==e));return void 0===i?null:null===i||void 0===i||null===(o=i.featured_image)||void 0===o?void 0:o.src;var o},Qt=(0,r.createContext)({setShowOptionsChart:null});var te=function(t){const e=t.event,n=t.data,i=t.currentProduct,o=t.setOpenShopNow,l=t.setLockSwiper,[a,d]=(0,r.useState)(!1);return(0,x.jsx)(Qt.Provider,{value:{setShowOptionsChart:d},children:(0,x.jsxs)(s.xu,{width:"full",height:"full",borderRadius:"md",children:[(0,x.jsx)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"flex-end",children:(0,x.jsx)(s.xu,{width:"full",height:"fit-content",children:(0,x.jsx)(Ut,{data:n,event:e,product:i,setOpenShopNow:o,setLockSwiper:l})})}),a?(0,x.jsx)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"flex-end",style:{position:"relative",zIndex:1,bottom:"100%"},className:"whatmore-ios-css-relative-fix",id:"whatmore-size-chart",children:(0,x.jsx)(s.xu,{width:"full",height:"fit-content",children:(0,x.jsx)(Lt,{data:n,event:e,product:i,setShowOptionsChart:()=>{d(!1)}})})}):(0,x.jsx)(x.Fragment,{})]})})};var ee=function(t){var e,[n,i,o,l]=(0,h.Z)();const[a,d]=(0,r.useState)(!1),[v,g]=(0,r.useState)(),[f,w]=(0,r.useState)(),j=(0,u.MO)("whatmoreShopId"),y=t.event,C=t.onBack,S=r.useRef(),b=t.isPlaying,I=t.isLast,k=t.setLockSwiper,_=t.selectedVariantId,F=null===(e=t.showOverlay)||void 0===e||e,T="center";return(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:l,height:o,sx:{overflow:"hidden"},children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:T,height:"full",width:"full",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,x.jsx)(s.oM,{width:"full",ratio:l/o,children:(0,x.jsx)(m,{height:"100%",width:"100%",url:y.event_hls_url,isPlaying:b,event:y})})})}),F?(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:T,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,x.jsx)(Ot,{focusRef:S,event:t.event,isLast:I,onCloseCallback:C,productClickHandler:async t=>{const e=await(0,p.p)(t,(0,c.Ipo)(j),j);w(t),g(e),d(!0),k(!0)}})})}):(0,x.jsx)(x.Fragment,{}),!0===a?(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"200%"},direction:"column",justifyContent:T,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,x.jsx)(te,{focusRef:S,event:t.event,isLast:I,onCloseCallback:()=>C(),setLockSwiper:k,data:v,currentProduct:f,setOpenShopNow:d,selectedVariantId:_})})}):(0,x.jsx)("div",{})]})})};const ne=function(t,e){return isNaN(t)||isNaN(e)||e<=0||t>e?0:Math.ceil(t/e*100)};function ie(t){var e,n,[i,o,r,l]=(0,h.Z)();const[a]=(0,u.j1)("whatmoreSecondaryColor"),[d]=(0,u.j1)("whatmoreSecondaryColorShade900"),c=t.progress,p=null!==(e=t.totalSiblings)&&void 0!==e?e:1,v=null!==(n=t.indexAmongSiblings)&&void 0!==n?n:0;return(0,x.jsx)(s.Kq,{width:"96%",height:"fit-content",direction:"row",justifyContent:"center",alignItems:"center",spacing:"1px",children:[...Array(p).keys()].map((t=>(0,x.jsx)(s.Kq,{width:"100%",height:.004*r+"px",backgroundColor:t<v?a:d+"99",borderRightRadius:"lg",borderLeftRadius:"lg",direction:"row",justifyContent:"flex-start",alignItems:"center",overflow:"hidden",sx:{display:"block !important"},children:t==v?(0,x.jsx)(s.xu,{height:"100%",width:c+"%",bgColor:a,borderRightRadius:"lg",borderLeftRadius:"lg",sx:{display:"block !important"}}):(0,x.jsx)(x.Fragment,{})},"event-progress-bar-slab-"+t)))})}var oe=n(868),re=n(2630);const le=t=>t>=1e3?(t/1e3).toFixed(1)+"k":t;var ae=n(4862);var de=function(t){var e,n,i,o=t.whatmoreShareTemplateId;const l=t.whatmoreShareStoryId,a=t.whatmoreShareEventId,p=t.event,v=null===(e=t.showShareText)||void 0===e||e,m=null!==(n=t.shareButtonBottomMargin)&&void 0!==n?n:0,g=(0,u.MO)("whatmoreShopId"),f=(0,u.MO)("isInDesignMode"),w=(0,u.MO)("isDemoBrand"),j=(0,u.MO)("whatmorePrimaryFont"),{whatmoreWidgetSourceDetails:y}=(0,r.useContext)(V.I),[C,S,b,I]=(0,h.Z)(),k=null!==(i=t.iconSize)&&void 0!==i?i:.1*I;function _(){const e=(0,u.MO)("whatmoreLandingLocationType");var n;!function(t){f||w||(async()=>{(0,d.x0)(t)})()}(p),(e.startsWith("product")||"embed"===e)&&(o="te"),n="event_product_link"===(0,c.EEC)(g)?p.products[0].product_link||"":window.location.pathname,n=("event_product_link"===(0,c.EEC)(g)?"":window.location.hostname)+n+"?wtt="+o+"&wsid="+l+"&weid="+a,(0,c.lj5)(g)&&(n=n+"&"+(0,c.awP)(g)+"&utm_campaign=video-share&utm_medium="+e);const i={title:(0,c.JNF)(g),text:`${(0,c.Qa8)(g)} \n ${n} ${(0,c.AWG)(g)?"\n \n -via Whatmore":""}`};navigator.share&&!ae.nI?navigator.share(i):(t.setIsModalOpen(!0),t.setShareText([i,n]))}return(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.Cd,{cursor:"pointer",style:{marginBottom:m+"px"},children:(0,x.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"fit-content",width:"fit-content",children:[(0,x.jsx)(re.Z,{sx:{boxShadow:3,transform:"scaleX(-1)",color:"white",fontSize:k,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),_(),(0,q.GF)({userInteractionType:H.K.VIDEO_SHARE_CTA_CLICKED,widgetSourceDetails:y,event:p,productList:p.products,ctaList:p.cta})}}),v&&(0,c.u8S)(g)?(0,x.jsxs)(s.xv,{fontSize:.3*k+"px !important",fontWeight:"semibold !important",align:"center",sx:{fontFamily:j+" !important",color:"white !important",paddingRight:"10%"},children:["\xa0",p.total_share>(0,c.LWl)(g)?le(p.total_share):"Share","\xa0"]}):(0,x.jsx)(x.Fragment,{})]})})})},se=n(7933),ce=n(2785);var ue=function(t){var e;const n=(0,u.MO)("whatmoreShopId"),i=(0,u.MO)("whatmorePrimaryFont"),o=(0,u.MO)("whatmoreLikedEvents"),l=((0,u.MO)("whatmoreSecondaryColor"),(0,u.MO)("isInDesignMode")),a=(0,u.MO)("isDemoBrand"),{whatmoreWidgetSourceDetails:p}=(0,r.useContext)(V.I),v=t.event,[m,g]=(0,r.useState)(null!==(e=o[v.event_id])&&void 0!==e&&e),[f,w,j,y]=(0,h.Z)(),C=.1*y;function S(t,e){l||a||(async()=>{(0,d.Z6)(t,e)})()}function b(){(0,u.bU)("whatmoreLikedEvents",{...o,[v.event_id]:!m}),m?(S(v,-1),(0,q.GF)({userInteractionType:H.K.VIDEO_UNLIKED,widgetSourceDetails:p,event:v,productList:v.products,ctaList:v.cta})):(S(v,1),(0,q.GF)({userInteractionType:H.K.VIDEO_LIKED,widgetSourceDetails:p,event:v,productList:v.products,ctaList:v.cta})),g(!m)}const I=v.total_like+(m?1:0);return(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.Cd,{cursor:"pointer",children:(0,x.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"fit-content",width:"fit-content",children:[m?(0,x.jsx)(ce.Z,{sx:{boxShadow:3,color:(0,c.dmX)(n),fontSize:C,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),b()}}):(0,x.jsx)(se.Z,{sx:{boxShadow:3,color:"white",fontSize:C,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),b()}}),(0,x.jsx)(x.Fragment,{children:(0,c.CEM)(n)?(0,x.jsxs)(s.xv,{fontSize:.3*C+"px !important",fontWeight:"semibold !important",align:"center",sx:{fontFamily:i+" !important",color:"white !important",position:"relative",bottom:"5px"},children:["\xa0",I>=(0,c.zKg)(n)?le(I):"Like","\xa0"]}):(0,x.jsx)(x.Fragment,{})})]})})})};const he=t=>{let{iconSize:e}=t;return(0,x.jsx)("div",{style:{backgroundColor:"#25D366",borderRadius:"50%",padding:.3*e},children:(0,x.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:e,height:e,fill:"white",class:"bi bi-whatsapp",viewBox:"0 0 16 16",children:(0,x.jsx)("path",{d:"M13.601 2.326A7.854 7.854 0 0 0 7.994 0C3.627 0 .068 3.558.064 7.926c0 1.399.366 2.76 1.057 3.965L0 16l4.204-1.102a7.933 7.933 0 0 0 3.79.965h.004c4.368 0 7.926-3.558 7.93-7.93A7.898 7.898 0 0 0 13.6 2.326zM7.994 14.521a6.573 6.573 0 0 1-3.356-.92l-.24-.144-2.494.654.666-2.433-.156-.251a6.56 6.56 0 0 1-1.007-3.505c0-3.626 2.957-6.584 6.591-6.584a6.56 6.56 0 0 1 4.66 1.931 6.557 6.557 0 0 1 1.928 4.66c-.004 3.639-2.961 6.592-6.592 6.592zm3.615-4.934c-.197-.099-1.17-.578-1.353-.646-.182-.065-.315-.099-.445.099-.133.197-.513.646-.627.775-.114.133-.232.148-.43.05-.197-.1-.836-.308-1.592-.985-.59-.525-.985-1.175-1.103-1.372-.114-.198-.011-.304.088-.403.087-.088.197-.232.296-.346.1-.114.133-.198.198-.33.065-.134.034-.248-.015-.347-.05-.099-.445-1.076-.612-1.47-.16-.389-.323-.335-.445-.34-.114-.007-.247-.007-.38-.007a.729.729 0 0 0-.529.247c-.182.198-.691.677-.691 1.654 0 .977.71 1.916.81 2.049.098.133 1.394 2.132 3.383 2.992.47.205.84.326 1.129.418.475.152.904.129 1.246.08.38-.058 1.171-.48 1.338-.943.164-.464.164-.86.114-.943-.049-.084-.182-.133-.38-.232z"})})})};var pe=n(8866);const ve=t=>{let{iconSize:e}=t;return(0,x.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:.3*e},children:(0,x.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:e,height:e,fill:"currentColor",class:"bi bi-twitter-x",viewBox:"0 0 16 16",children:(0,x.jsx)("path",{d:"M12.6.75h2.454l-5.36 6.142L16 15.25h-4.937l-3.867-5.07-4.425 5.07H.316l5.733-6.57L0 .75h5.063l3.495 4.633L12.601.75Zm-.86 13.028h1.36L4.323 2.145H2.865z"})})})},xe=t=>{let{iconSize:e}=t;return(0,x.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:.3*e},children:(0,x.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:e,height:e,fill:"currentColor",class:"bi bi-copy",viewBox:"0 0 16 16",children:(0,x.jsx)("path",{"fill-rule":"evenodd",d:"M4 2a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2zm2-1a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1zM2 5a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1v-1h1v1a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h1v1z"})})})};var me=t=>{const e=t.shareText,[n,i]=(0,r.useState)("Copy link"),[o,l]=(0,r.useState)("");return(0,x.jsx)(x.Fragment,{children:t.isModalOpen&&(0,x.jsxs)("div",{className:"modal-overlay",style:{backgroundColor:"white",borderRadius:"10px",padding:"12px 12px 20px 12px"},children:[(0,x.jsxs)("div",{style:{cursor:"pointer",display:"flex",justifyContent:"space-between",paddingBottom:"6px"},children:[(0,x.jsx)("img",{onClick:()=>{window.location.href="https://whatmore.ai"},src:"https://whatmore-other-assets.b-cdn.net/whatmore/new_whatmore_logo.png",style:{objectFit:"contain",backgroundColor:"transparent",borderRadius:"0px",width:Math.min(t.iconSize,28)+"px"}}),(0,x.jsx)(P.Z,{onClick:e=>{e.stopPropagation(),t.setIsModalOpen(!1)}})]}),(0,x.jsx)("div",{}),(0,x.jsx)(s.iz,{color:"blackAlpha.500",size:"1px",width:"100%"}),(0,x.jsxs)("div",{className:"social-icons",style:{display:"flex",gap:"20px",justifyContent:"center",paddingTop:"12px"},children:[(0,x.jsxs)("div",{onClick:t=>{var n;t.stopPropagation();const i=encodeURIComponent(null===(n=e[0])||void 0===n?void 0:n.text);window.open(`https://wa.me/?text=${i}`,"_blank")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,x.jsx)(he,{iconSize:Math.min(t.iconSize,30)}),(0,x.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14)},children:"Whatsapp"})]}),(0,x.jsxs)("div",{onClick:t=>{var n;t.stopPropagation();const i=encodeURIComponent(null===(n=e[0])||void 0===n?void 0:n.text);window.open(`https://twitter.com/intent/tweet?text=${i}`,"_blank")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,x.jsx)(ve,{iconSize:Math.min(t.iconSize,30),style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,x.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14)},children:"X"})]}),(0,x.jsxs)("div",{onClick:t=>{t.stopPropagation(),navigator.clipboard.writeText(e[1]),i("Link copied"),l("green")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,x.jsx)(xe,{iconSize:Math.min(t.iconSize,30),style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,x.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14),color:o},children:n})]})]})]})})};var ge=function(t){var e;const n=(0,u.MO)("whatmorePrimaryFont"),i=(0,u.MO)("whatmoreShopId"),o=null!==(e=t.fontSize)&&void 0!==e?e:"8";return(0,x.jsx)(s.rU,{href:"https://www.whatmore.ai/shoppable-videos",isExternal:!0,children:(0,c.XFt)(i)&&(0,x.jsxs)(s.Kq,{direction:"row",justifyContent:"flex-start",alignItems:"center",width:"fit-content",spacing:"2px",paddingLeft:"2px",paddingRight:"2px",children:[(0,x.jsx)("p",{style:{textAlign:"center",color:"white",fontFamily:n,fontWeight:"normal",fontSize:1.1*o+"px"},children:"powered by Whatmore"}),(0,x.jsx)(s.xu,{width:"10px"}),(0,x.jsx)("img",{src:"https://whatmore-other-assets.b-cdn.net/whatmore/new_whatmore_logo.png",style:{objectFit:"contain",width:1.7*o,backgroundColor:"transparent",borderRadius:"0px"}})]})})};function fe(t){var e;const n=t.event,[i,o,l,a]=(0,h.Z)(),[d]=(0,u.j1)("whatmorePrimaryFont"),{whatmoreIsStoriesTemplate:p}=(0,r.useContext)(V.I),[v]=(0,u.j1)("whatmoreSecondaryColor"),[m]=(0,u.j1)("whatmoreShopId"),g=(0,c.f63)(m),f=null!==(e=(0,c.u2W)(m))&&void 0!==e?e:[v,g,v,g,v],w=(0,r.useRef)(null);return(0,r.useEffect)((()=>{w.current&&w.current.play()}),[]),(0,x.jsx)(x.Fragment,{children:p?(0,x.jsx)(s.xu,{width:"100%",height:"fit-content",padding:"5px",children:(0,x.jsxs)(s.Kq,{direction:"row",width:"100%",height:"fit-content",justifyContent:"flex-start",children:[(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.Cd,{overflow:"hidden",size:.14*a+"px",sx:{boxShadow:"0px 2px 1px 0px "+f[0]+"50, 0px -2px 1px 0px "+f[1]+"50, 2px 0px 1px 0px "+f[2]+"50, -2px 0px 1px 0px "+f[3]+"80, 2px -2px 1px 0px "+f[4]+"80, -2px 2px 1px 0px "+f[0]+"DA, 2px 2px 1px 0px "+f[1]+"DA, -2px -2px 1px 0px "+f[2]+"DA"},children:"video"==(0,pt.$)((0,oe.V)(n.storyset_thumbnail_image))?(0,x.jsx)("video",{className:"whatmore-story-thumbnail",ref:w,preload:"metadata",loop:!0,playsInline:!0,src:(0,oe.V)(n.storyset_thumbnail_image),muted:!0,alt:"story image"}):(0,x.jsx)("img",{src:(0,oe.V)(n.storyset_thumbnail_image),style:{objectFit:"cover",height:"100%",width:"100%",backgroundColor:"white"}})})}),(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.xv,{style:{overflow:"hidden",textOverflow:"ellipsis"},noOfLines:1,fontSize:.05*a+"px",fontWeight:"medium",lineHeight:"100%",sx:{fontFamily:d+" !important",color:"white !important",textShadow:"0px 0px 4px black !important;"},children:n.storyset_name})})]})}):(0,x.jsx)(x.Fragment,{})})}var we=function(t){const[e,n,i]=(0,pe.Z)(),[o]=(0,u.j1)("isInDesignMode"),[l]=(0,u.j1)("isDemoBrand"),[a,p]=(0,u.j1)("isProductSwiperCatalogOpen"),[v,m]=(0,u.j1)("isFirstIndicatorRenderDone"),[g]=(0,u.j1)("whatmoreShopId"),f=(0,r.useContext)(ln),{whatmoreEventsBrowsingTemplate:w}=(0,r.useContext)(V.I),[j,C,S,b]=(0,h.Z)(),I=(0,u.MO)("whatmorePrimaryFont"),k=t.event,_=t.storySetId,F=t.isLast,E=t.onCloseCallback,P=t.focusRef,L=t.productClickHandler,z=t.videoPlayingData,R=t.totalSiblingEvents,M=t.indexAmongSiblings,K=t.leftOpenSpaceClickHandler,A=t.midOpenSpaceClickHandler,W=t.rightOpenSpaceClickHandler,{whatmoreWidgetSourceDetails:N}=(0,r.useContext)(V.I),Z=.1*b,[U,B]=(0,r.useState)(!1),[Y,X]=(0,r.useState)([]),G=t=>{$.current&&!$.current.contains(t.target)&&B(!1)},$=(0,r.useRef)(null);(0,r.useEffect)((()=>(U?document.addEventListener("click",G):document.removeEventListener("click",G),()=>{document.removeEventListener("click",G)})),[U]);const J="Free"==(0,c.Svj)(g)&&"portrait"==e;return(0,x.jsxs)(s.xu,{width:"full",height:"full",borderRadius:"md",children:[U&&(0,x.jsx)("div",{ref:$,className:"whatmore-share-modal",style:{zIndex:100,position:"absolute",boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.6)",width:"75%",top:"45%",left:"50%",transform:"translateX(-50%) translateY(-50%)"},children:(0,x.jsx)(me,{shareText:Y,setShareText:X,iconSize:Z,isModalOpen:U,setIsModalOpen:B})}),(0,x.jsxs)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"space-between",children:[(0,x.jsxs)(s.Kq,{width:"full",height:"fit-content",direction:"column",justifyContent:"flex-start",alignItems:"center",bgGradient:"linear(to-t, transparent, whiteAlpha.100, blackAlpha.200, blackAlpha.400, blackAlpha.800)",children:[f.showVideoPlayingData?(0,x.jsx)(s.Kq,{direction:"row",width:"100%",height:"fit-content",marginTop:"5px",justifyContent:"center",children:(0,x.jsx)(ie,{progress:ne(z.current_time,z.video_duration),totalSiblings:R,indexAmongSiblings:M})}):(0,x.jsx)(x.Fragment,{}),(0,x.jsx)(s.xu,{width:"full",margin:"2px",marginTop:"5px",children:(0,x.jsxs)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",paddingRight:"10px",paddingLeft:"10px",children:[(0,x.jsx)(fe,{event:k}),(0,x.jsxs)(s.Kq,{direction:"row",width:"fit-content",justifyContent:"end",paddingLeft:"10px",children:[(0,mt.ZK)(w)?(0,x.jsx)(de,{whatmoreShareTemplateId:(0,mt.QN)(w),whatmoreShareStoryId:_,whatmoreShareEventId:k.event_id,event:k,showShareText:!1,iconSize:.07*b,shareButtonBottomMargin:6,setIsModalOpen:B,setShareText:X}):(0,x.jsx)(x.Fragment,{}),(0,x.jsx)(y,{focusRef:P}),("landscape"!==e||t.showCloseOverlay)&&(0,x.jsx)(O,{event:k,onCloseCallback:E})]})]})})]}),(0,x.jsxs)(s.Kq,{width:"100%",height:"100%",direction:"row",justifyContent:"center",children:[(0,x.jsx)(s.xu,{width:"33%",height:"100%",onClick:()=>{K()},sx:{display:"block !important"}}),(0,x.jsx)(s.xu,{width:"34%",height:"100%",onClick:()=>{A()},sx:{display:"block !important"}}),(0,x.jsx)(s.xu,{width:"33%",height:"100%",onClick:()=>{W()},sx:{display:"block !important"}})]}),(0,x.jsxs)(s.xu,{width:"full",height:"fit-content",children:[f.totalEvents>1&&!v&&f.showSwipeIndicator?(0,x.jsx)(s.xu,{width:"full",margin:"2px",children:(0,x.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"center",children:(0,x.jsx)(D,{swipeUp:!F})})}):null,(0,x.jsxs)(s.xu,{width:"fit-content",height:"fit-content",position:"absolute",right:0,bottom:"25%",children:[(0,c.slY)(g)&&!(0,mt.ZK)(w)?(0,x.jsx)(s.xu,{ml:"auto",width:"fit-content",paddingY:"12px",paddingX:"8px",children:(0,x.jsxs)(s.Kq,{gap:"4px",direction:"column",alignItems:"center",cursor:"pointer",onClick:function(){var t;o||l||(async()=>{(0,d.lY)(k,1)})(),(0,q.GF)({userInteractionType:H.K.WHATSAPP_ICON_CLICKED,widgetSourceDetails:N,event:k,productList:null===k||void 0===k?void 0:k.products,ctaList:null===k||void 0===k?void 0:k.cta});const e=k.products.map((t=>`${t.product_link} \n`)),n=(0,c.gtK)(g),i=`Hey, I am interested in ${k.products.length>1?"these products":"this product"} I saw on ${null===(t=k.products[0])||void 0===t?void 0:t.brand} store: \n${e}. Could you please help me with some queries?`;window.open(n+`&text=${i}&type=phone_number`,"_blank")},children:[(0,x.jsx)(he,{iconSize:.7*Z,style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,x.jsx)(s.xv,{fontSize:Z*(0,c.Xod)(g)+"px",fontWeight:"bold",align:"center",style:{marginTop:0},sx:{fontFamily:I+" !important",color:"white !important"},children:(0,c.UiZ)(g)})]})}):(0,x.jsx)(x.Fragment,{}),(0,c.jY3)(g)?(0,x.jsx)(s.xu,{width:"full",height:"fit-content",paddingX:"12px",children:(0,x.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,x.jsx)(ue,{event:k})})}):(0,x.jsx)(x.Fragment,{}),(0,c.ROU)(g)&&!(0,mt.ZK)(w)?(0,x.jsx)(s.xu,{width:"full",height:"fit-content",paddingX:"12px",children:(0,x.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,x.jsx)(de,{whatmoreShareTemplateId:(0,mt.QN)(w),whatmoreShareStoryId:_,whatmoreShareEventId:k.event_id,event:k,setIsModalOpen:B,setShareText:X})})}):(0,x.jsx)(x.Fragment,{})]}),(0,_t.kT)(k)?(0,x.jsxs)(s.xu,{width:"full",children:[(0,c.Jm1)(g)?(0,x.jsx)(s.xu,{w:"100%",children:(0,x.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,x.jsx)(T,{event:k,onToggle:t=>{p("minimize-button"!==t)}})})}):(0,x.jsx)(x.Fragment,{}),(0,x.jsx)(s.xu,{display:"flex",width:"100%",height:"fit-content",children:(0,x.jsx)(Et,{event:k,productClickHandler:L})})]}):(0,x.jsx)(x.Fragment,{})]}),J&&(0,x.jsx)(s.Kq,{direction:"row",width:"100%",height:"fit-content",bg:"gray",py:"3px",justifyContent:"center",children:(0,x.jsx)(ge,{fontSize:.033*b})})]})]})},je=n(2279),ye=n.n(je),Ce=n(342);var Se=function(t){var e,n,i,o,l,a,[d,m,g,f]=(0,h.Z)();const[w,j]=(0,r.useState)(!1),[y,C]=(0,r.useState)(),[S,b]=(0,r.useState)(),[I,k]=(0,r.useState)({current_time:0,video_duration:0,is_video_ended:!1}),_=(0,u.MO)("whatmoreShopId"),F=t.event,T=t.storyId,E=t.onBack,P=r.useRef(),O=t.isPlaying,L=t.isLast,z=t.setLockSwiper,R=t.onVideoEndedCallback,M=t.progressUpdateCallback,D=null!==(e=t.totalSiblingEvents)&&void 0!==e?e:0,K=null!==(n=t.indexAmongSiblings)&&void 0!==n?n:0,A=null===(i=t.showOverlay)||void 0===i||i,W=null!==(o=t.leftOpenSpaceClickHandler)&&void 0!==o?o:()=>{},N=null!==(l=t.midOpenSpaceClickHandler)&&void 0!==l?l:()=>{},Z=null!==(a=t.rightOpenSpaceClickHandler)&&void 0!==a?a:()=>{},{whatmoreWidgetSourceDetails:U}=(0,r.useContext)(V.I),B="center";let Y;try{Y=ye()((()=>{R()}),1e3,{leading:!0,trailing:!1})}catch(X){console.log(X)}return(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:f,height:g,sx:{overflow:"hidden"},children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:B,height:"full",width:"full",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,x.jsx)(s.oM,{width:"full",ratio:f/g,children:(0,x.jsx)(v.Z,{height:"100%",width:"100%",url:(0,oe.V)((0,Ce.uv)(F)),isPlaying:O,timeUpdateCallback:function(t,e){const n=ne(t,e);M(n);const i=I.is_video_ended;n>=99&&O&&!i?(Y(),k({current_time:t,video_duration:e,is_video_ended:!0})):k({current_time:t,video_duration:e,is_video_ended:i})},event:F,source:t.source})})})}),A?(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:B,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,x.jsx)(we,{focusRef:P,event:t.event,isLast:L,onCloseCallback:t=>{E(t),(0,q.Z2)({userInteractionType:H.K.VIDEO_PLAYBACK,userInteractionMetadata:{watch_time:I.current_time},widgetSourceDetails:U,event:F,productList:F.products,ctaList:F.cta})},productClickHandler:async t=>{const e=await(0,p.p)(t,(0,c.Ipo)(_),_);b(t),C(e),j(!0),z(!0),(0,q.GF)({userInteractionType:H.K.SHOPNOW_CLICKED,widgetSourceDetails:U,event:F,productList:F.products,ctaList:F.cta}),(0,u.bU)("whatmoreAllowAutoSlide",!1)},videoPlayingData:I,totalSiblingEvents:D,indexAmongSiblings:K,leftOpenSpaceClickHandler:W,midOpenSpaceClickHandler:N,rightOpenSpaceClickHandler:Z,storySetId:T,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay})})}):(0,x.jsx)(x.Fragment,{}),!0===w?(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"200%"},direction:"column",justifyContent:B,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,x.jsx)(te,{focusRef:P,event:t.event,isLast:L,onCloseCallback:()=>E(),setLockSwiper:z,data:y,currentProduct:S,setOpenShopNow:t=>{j(t),(0,u.bU)("whatmoreAllowAutoSlide",!t)}})})}):(0,x.jsx)("div",{})]})})},be=n(7300),Ie=n(8984),ke=n(58),_e=n(9723);var Fe=function(t){var[e,n,i,o]=(0,h.Z)();const r=(0,u.MO)("whatmoreShopId"),l=t.event,a=t.isPlaying,d="center";return(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:o,height:i,sx:{overflow:"hidden"},children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:d,height:"full",width:"full",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,x.jsx)(s.oM,{width:"full",ratio:o/i,children:(0,x.jsx)(v.Z,{height:"100%",width:"100%",url:(0,oe.V)((0,Ce.uv)(l)),isPlaying:a,timeUpdateCallback:function(t,e){},event:l,source:t.source})})})}),(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:d,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",backdropFilter:"auto",backdropBlur:"10px",onClick:t=>{(0,ke.QV)()},children:(0,x.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"full",width:"full",children:[(0,x.jsx)(_e.Z,{sx:{boxShadow:3,color:(0,c.Ya_)(r),fontSize:.4*o,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{(0,ke.QV)()}}),(0,x.jsx)(s.xv,{color:"white",fontSize:.05*o+"px",fontWeight:"bold",align:"left",children:"Please click to play video.."})]})})})]})})},Te=n(3433);var Ee=function(t){var e,n;const r=t.event,l=null===(e=t.isPlaying)||void 0===e||e,a=t.onBack,d=t.isLast,s=t.setLockSwiper,c=(t.heightFactor,t.widthFactor,t.onVideoEndedCallback),h=t.progressUpdateCallback,[p,v]=(0,j.Z)(),[m]=(0,u.j1)("whatmoreVideoPlayerPoolBlessed"),g=null===(n=t.showOverlay)||void 0===n||n;function f(){v(!p)}if((0,Ie.KE)()&&0==m)return(0,x.jsx)(Fe,{event:r,onBack:a,isPlaying:l,isLast:d,setLockSwiper:s,onVideoEndedCallback:c,progressUpdateCallback:h,totalSiblingEvents:1,indexAmongSiblings:0,leftOpenSpaceClickHandler:()=>{f()},midOpenSpaceClickHandler:()=>{f()},rightOpenSpaceClickHandler:()=>{f()},showOverlay:g,source:Te.j.CAROUSEL_EVENT_OPENED},"shopping-video-view"+r.event_id);if((0,be.B6)(r)||(0,be.WJ)(r))return(0,x.jsx)(Se,{event:r,onBack:a,isPlaying:l,isLast:d,setLockSwiper:s,onVideoEndedCallback:c,progressUpdateCallback:h,totalSiblingEvents:1,indexAmongSiblings:0,leftOpenSpaceClickHandler:()=>{f()},midOpenSpaceClickHandler:()=>{f()},rightOpenSpaceClickHandler:()=>{f()},showOverlay:g,source:Te.j.CAROUSEL_EVENT_OPENED,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay},"shopping-video-view"+r.event_id);if((0,be.yC)(r)){var{status:w,bannerText:y,timeToStartInMins:C}=i.Z.getEventStatus(r);if(w.name===o.Z.LIVE.name)return(0,x.jsx)(ee,{event:r,onBack:a,isPlaying:l,isLast:d,showOverlay:g},"shopping-live-view"+r.event_id)}return console.error("Can't render event which is neither video or a currently-live-event"),(0,x.jsx)("div",{})},Pe=n(9284),Oe=n.n(Pe),Le=n(7463),ze=n(2154);function Re(t){var e;const[n,i]=(0,r.useState)(!1),o=t.onClick,l=null!==(e=t.fontSize)&&void 0!==e?e:50;return(0,x.jsx)("div",{style:{height:"fit-content",width:"fit-content",backgroundColor:"black",opacity:.4,borderRadius:"50%"},className:[n?"whatmore-scale-on-tap":""].join(" "),children:"left"===t.type?(0,x.jsx)(ze.Z,{sx:{color:"white",fontSize:l+"px",filter:"drop-shadow(0 0 5px black);"},onClick:t=>{i(!0),setTimeout((()=>{i(!1)}),500),o(t,"up")}}):(0,x.jsx)(Le.Z,{sx:{color:"white",fontSize:l+"px",filter:"drop-shadow(0 0 5px black);"},onClick:t=>{i(!0),setTimeout((()=>{i(!1)}),500),o(t,"down")}})})}var Me=function(t){var e,n,i;const o=null!==(e=t.relativeBottomPercentage)&&void 0!==e?e:"30%",r=null!==(n=t.width)&&void 0!==n?n:"100%",l=null!==(i=t.fontSize)&&void 0!==i?i:50,a=t.handleClick;return(0,x.jsx)("div",{style:{position:"relative",zIndex:1,bottom:o,width:"100%",height:"fit-content",display:"flex",flexFlow:"row nowrap",justifyContent:"center"},id:"here",children:(0,x.jsxs)("div",{style:{display:"flex",flexFlow:"row nowrap",width:r,height:"fit-content",paddingRight:"5px",paddingLeft:"5px",paddingTop:"5px",paddingBottom:"5px",justifyContent:"space-between",alignContent:"center"},children:[(0,x.jsx)(Re,{type:"left",onClick:a,fontSize:l}),(0,x.jsx)(Re,{type:"right",onClick:a,fontSize:l})]})})},De=n(2860),Ke=n(4669);var Ae=function(t,e){function n(t,e){return 1==e?0:t<0?e+t:t>=e?t-e:t}const i=(0,r.useRef)({prevIndex:n(t-1,e),activeIndex:t,nextIndex:n(t+1,e)});return[function(){return i.current},function(t){i.current="right"==t?{prevIndex:n(i.current.activeIndex,e),activeIndex:n(i.current.activeIndex+1,e),nextIndex:n(i.current.activeIndex+2,e)}:{prevIndex:n(i.current.activeIndex-2,e),activeIndex:n(i.current.activeIndex-1,e),nextIndex:n(i.current.activeIndex,e)}},function(t){return n(i.current.activeIndex+t)}]};var We=function(t,e){const n=(0,r.useRef)({clientX:0,clientY:0});return[function(t){n.current.clientX=t.changedTouches[0].clientX,n.current.clientY=t.changedTouches[0].clientY},function(i){const o=n.current.clientX,r=n.current.clientY;var l=o-i.changedTouches[0].clientX,a=r-i.changedTouches[0].clientY;return"vertical"==t&&Math.abs(a)>e||"horizontal"==t&&Math.abs(l)>e?"vertical"==t?a>0?"right":"left":l>0?"right":"left":null}]};var Ne=function(t,e){const n=(0,r.useRef)(ye()(((t,e)=>{t(e)}),300,{leading:!0,trailing:!1}));return[function(i,o){var r=0;if(r="vertical"==t?i.deltaY:i.deltaX,Math.abs(r)<=e)return;const l=r>0?"right":"left";n.current(o,l)}]},qe=n(5173);var He=function(t){const e=t.events,n=t.eventIndex,i=t.onBack;var[o,p,v,m]=(0,h.Z)();const[g]=(0,u.j1)("isInDesignMode"),[f]=(0,u.j1)("isDemoBrand"),[w,j]=(0,r.useState)(!0),[y,C]=(0,u.j1)("isFirstIndicatorRenderDone"),[S,b]=(0,r.useState)(!1),{setCloseClickComponent:I}=(0,r.useContext)(ln),{slideDirection:k}=(0,r.useContext)(ln),[_]=(0,u.j1)("whatmoreShopId"),[F]=(0,u.j1)("whatmoreLandingLocationType"),[T,E]=Ae(n,e.length),[P,O]=We(k,50),[L]=Ne("vertical",30),[z,R]=(0,r.useState)(!1),[M,D]=(0,r.useState)(null),{whatmoreWidgetSourceDetails:K,whatmoreUserInfo:A}=(0,r.useContext)(V.I);function N(){R(!1)}function Z(t){N(),setTimeout((()=>{i(t)}),500)}(0,r.useEffect)((()=>(R(!0),()=>{})),[]);const U=K.landingLocationType,B=K.templateType;function Y(){(0,u.MO)("whatmoreAllowAutoSlide")&&(E("right"),M.slideNext())}function X(t,e){E(e),function(t,e){M&&("left"===e?M.slidePrev():M.slideNext())}(0,e)}I(Z);const G=Math.round(.05*v);return(0,x.jsx)(Oe(),{isOpen:z,onAfterOpen:function(){},onRequestClose:N,overlayClassName:"whatmore-modal",className:"whatmore-modal-content",ariaHideApp:!1,children:(0,x.jsx)(qe.Z,{children:(0,x.jsxs)("div",{style:{height:window.innerHeight,width:window.innerWidth,backgroundColor:(0,W.lA)("#000000",13)},onTouchStart:t=>{P(t)},onTouchEnd:t=>{if(S)return;const e=O(t);e&&X(0,e)},onWheel:t=>{S||L(t,(t=>{X(0,t)}))},children:[(0,x.jsx)(l.tq,{speed:400,threshold:G,slidesPerView:1,direction:k,modules:[a.tl,a.Gk],initialSlide:n,loop:1!=e.length,height:window.innerHeight,width:window.innerWidth,watchSlidesProgress:!0,allowSlideNext:!S,allowSlidePrev:!S,allowTouchMove:!1,onSwiper:t=>{D(t),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:K,event:e[T().activeIndex],productList:e[T().activeIndex].products})},onSlideChange:t=>{var n;w?j(!1):(y||C(!0),n=e[T().activeIndex],g||f||(async()=>{const t=(0,mt.NY)(U)+(0,mt.dS)(B)+"_"+(null===n||void 0===n?void 0:n.event_id);(0,d.wh)(n),"index"===F?((0,Ke.Tc)(_,De.Xh,De.pR),(0,ot.H4)(n.event_id,n.products,De.Xh,De.pR,t,null===n||void 0===n?void 0:n.location,null===A||void 0===A?void 0:A.userType)):F.startsWith("product")||"embed"===F?((0,Ke.Tc)(_,De.h7,De.dU),(0,ot.H4)(n.event_id,n.products,De.h7,De.dU,t)):F.startsWith("collection")?((0,Ke.Tc)(_,De.U$,De.Pk),(0,ot.H4)(n.event_id,n.products,De.U$,De.Pk,t)):((0,Ke.Tc)(_,De.Xh,De.pR),(0,ot.H4)(n.event_id,n.products,De.Xh,De.pR,t))})(),(0,q.y4)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:K,event:e[T().activeIndex],productList:e[T().activeIndex].products}))},children:[...Array(Math.min(e.length,3)).keys()].map((n=>(0,x.jsx)(l.o5,{children:n=>{let{isActive:i,isPrev:o,isNext:r,isVisible:l,isDuplicate:a}=n;const d=i?"activeIndex":o?"prevIndex":"nextIndex";return(0,x.jsx)(s.Kq,{direction:"column",height:window.innerHeight,justifyContent:"center",children:(0,x.jsx)(Ee,{event:e[T()[d]],onBack:Z,isPlaying:1==e.length||i&&l,isLast:!1,setLockSwiper:b,onVideoEndedCallback:Y,progressUpdateCallback:t=>{},showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay})})}},"event-vertical-scroll-slide-"+n)))}),e.length>1&&!S&&(0,c.h6H)(_)&&"horizontal"===(0,c.e8z)(_)&&"horizontal"===k?(0,x.jsx)(Me,{relativeBottomPercentage:"50%",width:m,handleClick:(t,e)=>{X(0,"down"==e?"right":"left")},fontSize:parseInt(.12*m)}):(0,x.jsx)(x.Fragment,{})]})})})},Ve=n(1168);n(6143),n(7850),n(4444),n(7244),n(123),n(5892),n(1811);const Ze=t=>{let{children:e,customClass:n,show:i,closeCallback:o}=t;return Ve.createPortal((0,x.jsxs)("div",{className:`whatmore-landscape-modal whatmore-root ${n}`,style:{display:i?"block":"none"},children:[(0,x.jsx)("div",{className:"whatmore-landscape-modal-overlay",onClick:o}),(0,x.jsx)("div",{className:"whatmore-landscape-modal-content",children:e})]}),document.body)};Ze.defaultProps={children:(0,x.jsx)("div",{children:"Empty Modal"}),customClass:"",show:!1,closeCallback:()=>!1};var Ue=Ze;var Be=function(t){var[e,n,i,o]=(0,h.Z)();const[p]=(0,u.j1)("isInDesignMode"),[v]=(0,u.j1)("isDemoBrand"),[m,g]=(0,u.j1)("isFirstIndicatorRenderDone"),[f,w]=(0,r.useState)(0!=t.eventIndex),{setCloseClickComponent:j}=(0,r.useContext)(ln),[y,C]=(0,r.useState)(!1),[S]=(0,u.j1)("whatmoreShopId"),[b]=(0,u.j1)("whatmoreLandingLocationType"),{whatmoreUITheme:I}=(0,r.useContext)(V.I),{whatmoreWidgetSourceDetails:k,whatmoreUserInfo:_}=(0,r.useContext)(V.I),[F,T]=(0,r.useState)(!1),[E,P]=(0,r.useState)(null);function L(){T(!1)}const z=t.events,R=t.eventIndex,M=t.onBack,D=z.concat(z),K=z.length,A=(0,r.useRef)(0);function N(t){L(),setTimeout((()=>{M(t)}),500)}function Z(){E&&!E.isEnd&&(0,u.MO)("whatmoreAllowAutoSlide")&&E.slideNext()}(0,r.useEffect)((()=>(T(!0),()=>{})),[]),j(N);const U=k.landingLocationType,B=k.templateType,Y=parseInt(Math.min(5,z.length));return(0,x.jsx)(Ue,{show:F,closeCallback:L,customClass:"whatmore-landscape-modal-swipe-view",children:(0,x.jsxs)(s.Kq,{direction:"column",width:window.innerWidth,height:window.innerHeight,justifyContent:"center",aligntItems:"center",backgroundColor:(0,W.lA)("#000000",13),children:[(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.xu,{height:"fit-content",width:o*Y,children:(0,x.jsxs)(l.tq,{onInit:t=>{P(t),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:k,event:z[t.activeIndex],productList:z[t.activeIndex].products,ctaList:z[t.activeIndex].cta})},slidesPerView:Y,centeredSlides:!0,allowTouchMove:!1,initialSlide:R,modules:[a.lI,a.W_,a.Gk,a.pt,a.tl],navigation:Y>=5,effect:"coverflow",coverflowEffect:{rotate:-8,stretch:Math.floor(.22*i),depth:100,scale:.7,modifier:1,slideShadows:!1},height:"fit-content",width:o*Y,watchSlidesProgress:!0,onSlideChange:t=>{var e;f?w(!1):(m||g(!0),e=z[t.activeIndex],p||v||(async()=>{const t=(0,mt.NY)(U)+(0,mt.dS)(B)+"_"+(null===e||void 0===e?void 0:e.event_id);(0,d.wh)(e),"index"===b?((0,Ke.Tc)(S,De.Xh,De.pR),(0,ot.H4)(e.event_id,e.products,De.Xh,De.pR,t,null===e||void 0===e?void 0:e.location,null===_||void 0===_?void 0:_.userType)):b.startsWith("product")||"embed"===b?((0,Ke.Tc)(S,De.h7,De.dU),(0,ot.H4)(e.event_id,e.products,De.h7,De.dU,t)):b.startsWith("collection")?((0,Ke.Tc)(S,De.U$,De.Pk),(0,ot.H4)(e.event_id,e.products,De.U$,De.Pk,t)):((0,Ke.Tc)(S,De.Xh,De.pR),(0,ot.H4)(e.event_id,e.products,De.Xh,De.pR,t))})(),(0,q.y4)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:k,event:z[t.activeIndex],productList:z[t.activeIndex].products,ctaList:z[t.activeIndex].cta}))},mousewheel:{invert:!1,thresholdDelta:20},children:[z.length>2&&(0,x.jsx)("div",{className:"whatmore-shopping-close-button",children:(0,x.jsx)(O,{onCloseCallback:M})}),D.slice(R,z.length+R).map(((t,e)=>(0,x.jsx)(l.o5,{children:t=>{let{isActive:n,isPrev:r,isNext:l,isVisible:a,isDuplicate:d}=t;if(n)return(0,x.jsx)(s.Kq,{direction:"column",height:i,width:1*o,justifyContent:"center",marginLeft:"auto",marginRight:"auto",children:(0,x.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==I?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,x.jsx)(Ee,{event:z[e%K],onBack:N,isPlaying:!0,isLast:e%K===z.length-1,setLockSwiper:C,widthFactor:1,heightFactor:1,onVideoEndedCallback:Z,progressUpdateCallback:t=>{},showCloseOverlay:(null===z||void 0===z?void 0:z.length)<=2})})});if(l)return(0,x.jsx)(s.Kq,{direction:"column",height:i,width:o,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{E.slideTo(e%K,300)},children:(0,x.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==I?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,x.jsx)(Ee,{event:z[e%K],onBack:N,isPlaying:!1,isLast:e%K===z.length-1,setLockSwiper:C,widthFactor:1,heightFactor:1,onVideoEndedCallback:Z,progressUpdateCallback:t=>{},showOverlay:!1})})});if(r&&1===A.current)return(0,x.jsx)(s.Kq,{direction:"column",height:i,width:o,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{E.slideTo(e%K,300)},children:(0,x.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==I?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,x.jsx)(Ee,{event:z[e%K],onBack:N,isPlaying:!1,isLast:e%K===z.length-1,setLockSwiper:C,widthFactor:1,heightFactor:1,onVideoEndedCallback:Z,progressUpdateCallback:t=>{},showOverlay:!1})})});try{R+e>=K-1&&(A.current=1)}catch(u){console.log(u)}return(0,x.jsx)(x.Fragment,{})}},"event-horizontal-scroll-slide"+t.event_id)))]})})}),(0,x.jsx)(s.M5,{children:(0,x.jsx)(ge,{height:.04*i,width:.1*o,fontSize:.02*i})})]})})},Ye=n(6090),Xe=n(7616),Ge=n(9302),$e=n(2575);var Je=function(t){const[e,n,i,o]=(0,h.Z)(),[r]=(0,u.j1)("whatmorePrimaryColor"),[l]=(0,u.j1)("whatmoreSecondaryColor"),a="flex-end";return(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:o,height:i,backgroundColor:"whiteAlpha.200",backdropBlur:"10px",children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:a,height:"full",width:"full",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",children:(0,x.jsx)(s.oM,{width:"full",ratio:o/i,children:(0,x.jsx)(s.xu,{w:"100%",h:"100%",bgGradient:"linear(to-br, "+r+", gray, "+l+")"})})})}),(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:a,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{padding:"2px",margin:"5px",borderRadius:"md",backgroundColor:"transparent",children:(0,x.jsx)(s.oM,{width:"full",ratio:9/16,children:(0,x.jsx)(s.xu,{width:"full",height:"full",borderRadius:"md",backdropFilter:"auto",backdropBlur:"5px"})})})})]})})};var Qe=function(t){var e;const n=t.stories,i=t.onBack,o=t.onStoryCompleteCallback,a=t.isActive,c=null!==(e=t.initialEventIndex)&&void 0!==e?e:0,p=n.events;var[v,m,g,f]=(0,h.Z)();const[w,y]=(0,j.Z)(),[C]=(0,u.j1)("isInDesignMode"),[S]=(0,u.j1)("isDemoBrand"),[b]=(0,u.j1)("whatmoreShopId"),[I,k]=(0,r.useState)(!0),[_,F]=(0,u.j1)("isFirstIndicatorRenderDone"),[T,E]=(0,r.useState)(null),[P,O]=(0,r.useState)(!1),{whatmoreWidgetSourceDetails:L,whatmoreUserInfo:z}=(0,r.useContext)(V.I),[R,M]=Ae(c,p.length);function D(t){i(t)}const K=L.landingLocationType,A=L.templateType;function W(){if(!(0,u.MO)("whatmoreAllowAutoSlide"))return;R().activeIndex+1>=p.length?o("right"):(M("right"),T&&T.slideNext())}function N(t){const e=R().activeIndex;"right"==t&&e+1>=p.length||"left"==t&&e-1<0?o(t):(M(t),T&&("left"==t?T.slidePrev():T.slideNext()))}return p[R().activeIndex],(0,x.jsx)("div",{children:(0,x.jsx)(l.tq,{speed:1,slidesPerView:1,direction:"horizontal",initialSlide:0,loop:!0,height:g,width:f,watchSlidesProgress:!0,allowTouchMove:!1,onSwiper:t=>{E(t)},onSlideChange:t=>{I?k(!1):(_||F(!0),function(t){const e=(0,mt.NY)(K)+(0,mt.dS)(A)+"_"+(null===t||void 0===t?void 0:t.event_id);C||S||(async()=>{(0,d.wh)(t),(0,Ke.Tc)(b,De.Xh,De.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===z||void 0===z?void 0:z.userType)})()}(p[R().activeIndex]),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:L,event:p[R().activeIndex],productList:p[R().activeIndex].products,ctaList:p[R().activeIndex].cta}))},children:[...Array(Math.min(p.length,3)).keys()].map((e=>(0,x.jsx)(l.o5,{children:e=>{let{isActive:i,isPrev:o,isNext:r,isVisible:l,isDuplicate:d}=e;if(a){const e=i?"activeIndex":o?"prevIndex":"nextIndex",r=p[R()[e]];return(0,x.jsx)(s.Kq,{direction:"column",height:g,justifyContent:"center",children:(0,be.B6)(r)||(0,be.WJ)(r)?(0,x.jsx)(Se,{event:r,totalSiblingEvents:p.length,indexAmongSiblings:R()[e],onBack:D,isPlaying:a&&i&&l,isLast:!1,setLockSwiper:O,onVideoEndedCallback:W,progressUpdateCallback:t=>{},leftOpenSpaceClickHandler:()=>{N("left")},midOpenSpaceClickHandler:()=>{y(!w)},rightOpenSpaceClickHandler:()=>{N("right")},storyId:n.id,source:Te.j.STORY_EVENT_OPENED,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay},"shopping-video-view"+r.event_id):(0,x.jsx)(x.Fragment,{})})}return(0,x.jsx)(s.Kq,{direction:"column",height:v,justifyContent:"center",children:(0,x.jsx)(Je,{})})}},"event-story-view-slide-"+e)))})})};var tn=function(t){const e=t.onBack,n=t.eventsStories,i=t.initialStoryIndex;var[o,c,p,v]=(0,h.Z)();const[m]=(0,u.j1)("isInDesignMode"),[g]=(0,u.j1)("isDemoBrand"),[f,w]=(0,r.useState)(!0),[j,y]=(0,u.j1)("isFirstIndicatorRenderDone"),[C,S]=(0,r.useState)(!1),{setCloseClickComponent:b}=(0,r.useContext)(ln),{slideDirection:I}=(0,r.useContext)(ln),[k]=(0,u.j1)("whatmoreShopId"),[_,F]=Ae(i,n.length),[T,E]=We("horizontal",50),[P]=Ne("vertical",30),O=t.eventIndex,[L,z]=(0,r.useState)(!1),[R,M]=(0,r.useState)(null),{whatmoreWidgetSourceDetails:D,whatmoreUserInfo:K}=(0,r.useContext)(V.I);function A(){z(!1)}function W(t){A(),setTimeout((()=>{e(t)}),500)}(0,r.useEffect)((()=>(z(!0),()=>{})),[]),b(W);const N=D.landingLocationType,Z=D.templateType;function U(t){R&&(0,u.MO)("whatmoreAllowAutoSlide")&&(F(t),"right"==t?R.slideNext():R.slidePrev())}function B(t,e){U(e)}return(0,x.jsx)(Oe(),{isOpen:L,onAfterOpen:function(){},onRequestClose:A,overlayClassName:"whatmore-modal",className:"whatmore-modal-content",ariaHideApp:!1,children:(0,x.jsx)("div",{style:{height:window.innerHeight,width:window.innerWidth,backgroundColor:"#00000088"},onTouchStart:t=>{T(t)},onTouchEnd:t=>{const e=E(t);e&&B(0,e)},onWheel:t=>{P(t,(t=>{B(0,t)}))},children:(0,x.jsx)(l.tq,{speed:1,slidesPerView:1,direction:"horizontal",modules:[a.SH,a.Gk],initialSlide:i,loop:n.length>1,height:window.innerHeight,width:window.innerWidth,watchSlidesProgress:!0,onSwiper:t=>{var e,i;M(t),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:D,event:n[_().activeIndex].events[0],productList:null===(e=n[_().activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(i=n[_().activeIndex].events[0])||void 0===i?void 0:i.cta})},onSlideChange:t=>{var e,i;f?w(!1):(!function(t){const e=(0,mt.NY)(N)+(0,mt.dS)(Z)+"_"+(null===t||void 0===t?void 0:t.event_id);m||g||(async()=>{(0,d.wh)(t),(0,Ke.Tc)(k,De.Xh,De.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===K||void 0===K?void 0:K.userType)})()}(n[_().activeIndex].events[0]),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:D,event:n[_().activeIndex].events[0],productList:null===(e=n[_().activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(i=n[_().activeIndex].events[0])||void 0===i?void 0:i.cta}))},allowTouchMove:!1,cubeEffect:{shadow:!0,slideShadows:!0,shadowOffset:20,shadowScale:.94},children:[...Array(Math.min(n.length,3)).keys()].map((t=>(0,x.jsx)(l.o5,{children:t=>{let{isActive:e,isPrev:r,isNext:l,isVisible:a,isDuplicate:d}=t;const c=e?"activeIndex":r?"prevIndex":"nextIndex";return(0,x.jsx)(s.Kq,{direction:"column",height:o,justifyContent:"center",children:(0,x.jsx)(Qe,{stories:n[_()[c]],onBack:W,isActive:e&&a,isNext:l,isPrev:r,onStoryCompleteCallback:U,nextStories:n[_().nextIndex],prevStories:n[_().prevIndex],initialEventIndex:i==_()[c]?O:0},"event-story-view-"+n[_()[c]].id)})}},"event-vertical-scroll-slide-"+t)))})})})},en=n(4892);var nn=function(t){var e,n,i,[o,l,a,d]=(0,h.Z)();const[c]=(0,u.j1)("whatmorePrimaryColor"),[p]=(0,u.j1)("whatmoreSecondaryColor"),v=t.event,m=(t.onBack,r.useRef(),null!==(e=t.showPausedVideo)&&void 0!==e&&e),f=null!==(n=t.heightFactor)&&void 0!==n?n:1,w="flex-end";return d*=null!==(i=t.widthFactor)&&void 0!==i?i:1,a*=f,(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:d,height:a,children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:w,height:"full",width:"full",children:(0,x.jsx)(s.xu,{children:(0,x.jsx)(s.oM,{width:"full",ratio:9/16,children:m?(0,be.B6)(v)||(0,be.WJ)(v)?(0,x.jsx)(en.Z,{height:"100%",width:"100%",url:v.thumbnail_image,isPlaying:!1,pauseFromPlayTimeInMs:1e3,event:v}):(0,x.jsx)(g.Ee,{width:"full",height:"full",src:v.thumbnail_image,objectFit:"cover",borderRadius:"lg"}):(0,x.jsx)(s.xu,{w:"100%",h:"100%",bgGradient:"linear(to-br, "+c+", gray, "+p+")"})})})}),(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:w,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{children:(0,x.jsx)(s.oM,{width:"full",ratio:9/16,children:(0,x.jsx)(s.xu,{width:"full",height:"full",backgroundColor:"blackAlpha.400"})})})})]})})};var on=function(t){var[e,n,i,o]=(0,h.Z)();const[c]=(0,u.j1)("isInDesignMode"),[p]=(0,u.j1)("isDemoBrand"),[v,m]=(0,u.j1)("isFirstIndicatorRenderDone"),[g,f]=(0,r.useState)(0!=t.eventIndex),{setCloseClickComponent:w}=(0,r.useContext)(ln),[j,y]=(0,r.useState)(!1),[C]=(0,u.j1)("whatmoreShopId"),{whatmoreWidgetSourceDetails:S,whatmoreUserInfo:b}=(0,r.useContext)(V.I),[I,k]=(0,r.useState)(!1),[_,F]=(0,r.useState)(null);function T(){k(!1)}t.events;const E=t.eventIndex,P=t.onBack,L=t.eventsStories,z=t.initialStoryIndex;function R(t){T(),setTimeout((()=>{P(t)}),500)}(0,r.useEffect)((()=>(k(!0),()=>{})),[]),w(R);const M=S.landingLocationType,D=S.templateType;function K(t){_&&!_.isEnd&&("right"==t?_.slideNext():_.slidePrev())}const A=parseInt(Math.min(5,L.length));return(0,x.jsx)(Ue,{show:I,closeCallback:T,customClass:"whatmore-landscape-modal-stories-view",children:(0,x.jsxs)(s.Kq,{direction:"column",width:window.innerWidth,height:window.innerHeight,justifyContent:"center",aligntItems:"center",backgroundColor:"blackAlpha.800",children:[(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.xu,{height:"fit-content",width:o*A,children:(0,x.jsxs)(l.tq,{onInit:t=>{var e,n;F(t),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:S,event:L[t.activeIndex].events[0],productList:null===(e=L[t.activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(n=L[t.activeIndex].events[0])||void 0===n?void 0:n.cta})},slidesPerView:A,centeredSlides:!0,allowTouchMove:!1,initialSlide:z,modules:[a.lI,a.W_,a.Gk],navigation:A>=5,effect:"coverflow",coverflowEffect:{rotate:-8,stretch:Math.floor(.22*i),depth:100,scale:.7,modifier:1,slideShadows:!1},height:"fit-content",width:o*A,watchSlidesProgress:!0,onSlideChange:t=>{var e,n;g?f(!1):(v||m(!0),function(t){const e=(0,mt.NY)(M)+(0,mt.dS)(D)+"_"+(null===t||void 0===t?void 0:t.event_id);c||p||(async()=>{(0,d.wh)(t),(0,Ke.Tc)(C,De.Xh,De.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===b||void 0===b?void 0:b.userType)})()}(L[t.activeIndex].events[0]),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:S,event:L[t.activeIndex].events[0],productList:null===(e=L[t.activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(n=L[t.activeIndex].events[0])||void 0===n?void 0:n.cta}))},mousewheel:{invert:!1,thresholdDelta:20},children:[L.length>2&&(0,x.jsx)("div",{className:"whatmore-shopping-close-button",children:(0,x.jsx)(O,{onCloseCallback:P})}),L.map(((t,e)=>(0,x.jsx)(l.o5,{children:n=>{let{isActive:r,isPrev:l,isNext:a,isVisible:d,isDuplicate:c}=n;if(r){const n=1;return(0,x.jsx)(s.Kq,{direction:"column",height:i,width:o*n,justifyContent:"center",marginLeft:"auto",marginRight:"auto",children:(0,x.jsx)(s.xu,{borderRadius:"xl",overflow:"hidden",backgroundColor:"transparent",boxShadow:"dark-lg",children:(0,x.jsx)(Qe,{stories:t,onBack:R,isActive:r&&d,isNext:!1,isPrev:!1,onStoryCompleteCallback:K,initialEventIndex:z==e?E:0,showCloseOverlay:(null===L||void 0===L?void 0:L.length)<=2},"event-story-view-"+t.id)})})}return l||a?(0,x.jsx)(s.Kq,{direction:"column",height:i,width:o,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{_.slideTo(e,300)},children:(0,x.jsx)(s.xu,{borderRadius:"xl",overflow:"hidden",backgroundColor:"transparent",boxShadow:"dark-lg",children:(0,x.jsx)(nn,{showPausedVideo:!0,event:L[e].events[0],onBack:R,isPlaying:!1,setLockSwiper:y})})}):(0,x.jsx)(x.Fragment,{})}},"event-horizontal-scroll-slide-"+e)))]})})}),(0,x.jsx)(s.M5,{children:(0,x.jsx)(ge,{height:.04*i,width:.1*o,fontSize:.02*i})})]})})};const rn=(0,$e.Z)({key:"whatmore-css-sv"}),ln=(0,r.createContext)({isIOS:!1,totalEvents:0,closeClickComponent:null,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:"vertical",showSwipeIndicator:!0});var an=function(t){var e,n;const[i,o,l]=(0,pe.Z)(),[a]=(0,u.j1)("whatmoreShopId"),{whatmoreRootId:d}=(0,r.useContext)(V.I),{whatmoreIsStoriesTemplate:s}=(0,r.useContext)(V.I);var h=t.events,p=t.index,v=t.onBack,m=t.eventsStories,g=t.initialStoryIndex,f=(0,c.cX2)(a),w=(h[p],"portrait"===i?null!==(e=t.slideDirection)&&void 0!==e?e:"vertical":null!==(n=t.slideDirection)&&void 0!==n?n:h.length>1?"horizontal":"vertical"),j="portrait"===i?!(0,c.h6H)(a)&&!s:(0,c.n89)(a);return h[p],(0,r.useLayoutEffect)((()=>{(0,c.TLG)(a)&&(window.location.href.includes(f)?history.replaceState(null,"","#"+f):history.pushState(null,"","#"+f),window.addEventListener("popstate",(()=>{window.location.href.includes(f)||v()})))}),[]),delete Xe.ZP.styles.global,s?(0,x.jsx)(Ge.C,{value:rn,children:(0,x.jsx)(Ye.x,{theme:Xe.ZP,cssVarsRoot:d,resetCSS:!1,children:(0,x.jsx)(ln.Provider,{value:{isIOS:(0,Ie.KE)(),totalEvents:h.length,closeClickComponent:v,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:w,showSwipeIndicator:j},children:"portrait"===i?(0,x.jsx)(tn,{eventsStories:m,initialStoryIndex:g,onBack:v,eventIndex:p}):(0,c.Bbr)(a)?(0,x.jsx)(on,{eventsStories:m,initialStoryIndex:g,onBack:v,eventIndex:p}):(0,x.jsx)(tn,{eventsStories:m,initialStoryIndex:g,onBack:v,eventIndex:p})})})}):(0,x.jsx)(Ge.C,{value:rn,children:(0,x.jsx)(Ye.x,{theme:Xe.ZP,cssVarsRoot:d,resetCSS:!1,children:(0,x.jsx)(ln.Provider,{value:{isIOS:(0,Ie.KE)(),totalEvents:h.length,closeClickComponent:v,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:w,showSwipeIndicator:j},children:"portrait"===i?(0,x.jsx)(He,{events:h,eventIndex:p,onBack:v}):(0,x.jsx)(Be,{events:h,eventIndex:p,onBack:v})})})})}},9316:function(t,e,n){n.d(e,{mT:function(){return o}});var i=n(686);const o=`\n ${i.F4`
|
|
76
|
+
`} 0.5s`,bt=null===q||void 0===q||null===(e=q.options)||void 0===e?void 0:e.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"))})),[It,kt]=(0,r.useState)(-1!==bt?null===(n=q.options)||void 0===n||null===(i=n[bt])||void 0===i||null===(o=i.values)||void 0===o?void 0:o[0]:""),[_t,Ft]=(0,r.useState)({});(0,r.useEffect)((()=>{-1!==bt&&"whatmore"!==(0,c.Ipo)(wt)&&async function(){const t=await(0,lt.m3)(Z);Ft(t)}()}),[]);let Tt=-1,Et=-1!==bt&&null!==_t&&void 0!==_t&&_t.product&&(null===_t||void 0===_t||null===(l=_t.product)||void 0===l||null===(a=l.images)||void 0===a?void 0:a.length)>=(null===_t||void 0===_t||null===(d=_t.product)||void 0===d||null===(p=d.options)||void 0===p||null===(v=p[bt])||void 0===v||null===(m=v.values)||void 0===m?void 0:m.length)?null===_t||void 0===_t||null===(f=_t.product)||void 0===f||null===(w=f.images)||void 0===w?void 0:w.map((t=>{var e,n,i,o,r,l,a,d,s,c,u,h,p,v;const x=null===_t||void 0===_t||null===(e=_t.product)||void 0===e||null===(n=e.options)||void 0===n?void 0:n.findIndex((t=>"Color"==(null===t||void 0===t?void 0:t.name)||"Colour"==(null===t||void 0===t?void 0:t.name)||"COLOR"==(null===t||void 0===t?void 0:t.name)));return{color:(null===t||void 0===t?void 0:t.variant_ids.length)>0?null===_t||void 0===_t||null===(i=_t.product)||void 0===i||null===(o=i.options)||void 0===o||null===(r=o[x])||void 0===r||null===(l=r.values)||void 0===l?void 0:l[Math.min(++Tt,(null===_t||void 0===_t||null===(a=_t.product)||void 0===a||null===(d=a.options)||void 0===d||null===(s=d[bt])||void 0===s||null===(c=s.values)||void 0===c?void 0:c.length)-1)]:null===_t||void 0===_t||null===(u=_t.product)||void 0===u||null===(h=u.options)||void 0===h||null===(p=h[x])||void 0===p||null===(v=p.values)||void 0===v?void 0:v[Math.max(0,Tt)],src:null===t||void 0===t?void 0:t.src}})):[],Pt=[];if("whatmore"==(0,c.Ipo)(wt)&&(null===q||void 0===q||null===(j=q.images)||void 0===j?void 0:j.length)>0){var Ot;var Lt;if(-1!==(null===q||void 0===q||null===(Ot=q.options)||void 0===Ot?void 0:Ot.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"))}))))Pt=null===q||void 0===q||null===(Lt=q.images)||void 0===Lt?void 0:Lt.map((t=>({color:t.color,src:t.src,optionsrc:t.optionsrc})))}return Tt+1<(null===_t||void 0===_t||null===(y=_t.product)||void 0===y||null===(C=y.options)||void 0===C||null===(b=C[bt])||void 0===b||null===(I=b.values)||void 0===I?void 0:I.length)&&(Et=[]),(0,x.jsxs)(s.kC,{sx:{"&::-webkit-scrollbar":{width:"0px"}},id:"whatmore-shopnow-view",position:"relative",maxHeight:"75vh",overflowY:"scroll",direction:"column",bg:"#FFF",height:"fit-content",opacity:"100%",borderTopRadius:"round"==(null===ft||void 0===ft?void 0:ft.whatmoreUITheme)?"xl":null,animation:St,children:[(0,x.jsx)(At,{setOpenShopNow:U,setLockSwiper:B,FONT_SIZE:A}),(0,x.jsx)(s.M5,{marginBottom:"10px",px:"20px",py:"5px",children:(0,x.jsx)(s.kC,{bg:"whiteAlpha.900",width:"fit-content",height:"fit-content",borderRadius:"round"==(null===ft||void 0===ft?void 0:ft.whatmoreUITheme)?"lg":null,overflow:"hidden",sx:{borderWidth:(0,c.alU)(wt),borderColor:(0,c.qPe)(wt)},children:(0,x.jsx)(s.kC,{width:"100%",children:(0,x.jsx)(Zt.P,{renderElement:t=>(0,x.jsx)(x.Fragment,{children:(0,x.jsx)(s.xu,{width:M+"px",height:D+"px",children:(0,x.jsx)(g.Ee,{width:M+"px",height:D+"px",borderRadius:"round"==(null===ft||void 0===ft?void 0:ft.whatmoreUITheme)?"lg":null,src:(0,pt.s)(t.eventData.src,"&width=400&height=400"),alt:Z.handle,sx:{objectFit:(0,c.yOX)(wt)+" !important"},fallback:(0,x.jsx)(K.Z,{width:M+"px",height:D+"px",borderRadius:"round"==(null===ft||void 0===ft?void 0:ft.whatmoreUITheme)?"10px":"0px"})})})}),dataList:Et.length>0&&!Et.includes(null)?null===(k=Et)||void 0===k?void 0:k.filter((t=>(null===t||void 0===t?void 0:t.color)==It)):Pt.length>0?[null===(_=Pt)||void 0===_?void 0:_.find((t=>(null===t||void 0===t?void 0:t.color)==It))]:null===q||void 0===q||null===(F=q.images)||void 0===F?void 0:F.map((t=>({src:t.includes("https")?t:"https:"+t}))),spacing:10,defaultHeight:M+"px",defaultWidth:D+"px",retainAlreadyRenderedElements:!0,isScroll:!0})})})}),(0,x.jsx)(Ht,{data:q,product:Z,PRODUCT_TILE_HEIGHT:R,PRODUCT_TILE_WIDTH:z,FONT_SIZE:A,getVariantPrice:Yt,selectedVariantId:et,itemPrice:at,itemQuantity:it,setItemQuantity:ot,thumbnailImage:mt}),(null===q||void 0===q||null===(T=q.variants)||void 0===T?void 0:T.length)>0&&(0,x.jsxs)(x.Fragment,{children:[(0,x.jsx)(s.M5,{paddingTop:"4px",width:"100%",children:(0,x.jsx)(s.iz,{color:(0,c.W8U)(wt),size:"xs",width:"90%"})}),(0,x.jsx)(Vt,{data:q,dividerColor:(0,c.W8U)(wt),setSelectedColor:kt,finalArr:Et,finalArrExternal:Pt,product:Z,PRODUCT_TILE_HEIGHT:R,PRODUCT_TILE_WIDTH:z,FONT_SIZE:A,selectOptionFirstHandler:jt,selectOptionSecondHandler:yt,selectOptionThirdHandler:Ct,getVariantPrice:Yt,selectedOptionFirst:X,selectedOptionSecond:$,selectedOptionThird:Q,selectedVariantId:et})]}),c.$2G&&((null===q||void 0===q?void 0:q.description)||(null===q||void 0===q?void 0:q.body_html))&&(0,x.jsx)(Wt,{PRODUCT_TILE_HEIGHT:R,FONT_SIZE:A,data:q,handleToggle:()=>N(!W),show:W}),(0,x.jsx)(s.xu,{sx:{pointerEvents:"none"},paddingTop:"20px",opacity:0,children:(0,x.jsx)(Kt,{position:"relative",data:q,FONT_SIZE:A,product:Z})}),(0,x.jsx)(Kt,{position:"fixed",selectedVariantId:et,data:q,FONT_SIZE:A,PRODUCT_TILE_WIDTH:z,product:Z,itemQuantity:it,cartItemCount:st,addToCartFlag:ut,setAddToCartFlag:ht,soldOutFlag:vt,setSoldOutFlag:xt,event:H})]})}const Bt=(t,e,n,i)=>{var o,r,l,a,d,s,c,u,h,p;if(void 0===e&&void 0===n&&void 0===i)return null===t||void 0===t||null===(o=t.variants)||void 0===o||null===(r=o[0])||void 0===r?void 0:r.id;if(void 0===i&&void 0===n)return null===(l=t.variants.find((t=>t.option1===e)))||void 0===l?void 0:l.id;if(void 0===i&&void 0===e)return null===(a=t.variants.find((t=>t.option2===n)))||void 0===a?void 0:a.id;if(void 0===n&&void 0===e)return null===(d=t.variants.find((t=>t.option3===i)))||void 0===d?void 0:d.id;if(void 0===n)return null===(s=t.variants.find((t=>t.option1===e&&t.option3===i)))||void 0===s?void 0:s.id;if(void 0===i)return null===(c=t.variants.find((t=>t.option1===e&&t.option2===n)))||void 0===c?void 0:c.id;if(void 0===e)return null===(u=t.variants.find((t=>t.option2===n&&t.option3===i)))||void 0===u?void 0:u.id;const v=null===t||void 0===t?void 0:t.variants.find((t=>t.option1===e&&t.option2===n&&t.option3===i));return void 0===v?null===t||void 0===t||null===(h=t.variants)||void 0===h||null===(p=h[0])||void 0===p?void 0:p.id:v.id},Yt=(t,e)=>{var n,i;return null===t||void 0===t||null===(n=t.variants)||void 0===n||null===(i=n.find((t=>t.id===e)))||void 0===i?void 0:i.price},Xt=(t,e)=>{var n,i;return null===t||void 0===t||null===(n=t.variants)||void 0===n||null===(i=n.find((t=>t.id.toString()===e)))||void 0===i?void 0:i.option1},Gt=(t,e)=>{var n,i;return null===t||void 0===t||null===(n=t.variants)||void 0===n||null===(i=n.find((t=>t.id.toString()===e)))||void 0===i?void 0:i.option2},$t=(t,e)=>{var n,i;return null===t||void 0===t||null===(n=t.variants)||void 0===n||null===(i=n.find((t=>t.id.toString()===e)))||void 0===i?void 0:i.option3},Jt=(t,e)=>{var n;const i=null===t||void 0===t||null===(n=t.variants)||void 0===n?void 0:n.find((t=>t.id==e));return void 0===i?null:null===i||void 0===i||null===(o=i.featured_image)||void 0===o?void 0:o.src;var o},Qt=(0,r.createContext)({setShowOptionsChart:null});var te=function(t){const e=t.event,n=t.data,i=t.currentProduct,o=t.setOpenShopNow,l=t.setLockSwiper,[a,d]=(0,r.useState)(!1);return(0,x.jsx)(Qt.Provider,{value:{setShowOptionsChart:d},children:(0,x.jsxs)(s.xu,{width:"full",height:"full",borderRadius:"md",children:[(0,x.jsx)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"flex-end",children:(0,x.jsx)(s.xu,{width:"full",height:"fit-content",children:(0,x.jsx)(Ut,{data:n,event:e,product:i,setOpenShopNow:o,setLockSwiper:l})})}),a?(0,x.jsx)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"flex-end",style:{position:"relative",zIndex:1,bottom:"100%"},className:"whatmore-ios-css-relative-fix",id:"whatmore-size-chart",children:(0,x.jsx)(s.xu,{width:"full",height:"fit-content",children:(0,x.jsx)(Lt,{data:n,event:e,product:i,setShowOptionsChart:()=>{d(!1)}})})}):(0,x.jsx)(x.Fragment,{})]})})};var ee=function(t){var e,[n,i,o,l]=(0,h.Z)();const[a,d]=(0,r.useState)(!1),[v,g]=(0,r.useState)(),[f,w]=(0,r.useState)(),j=(0,u.MO)("whatmoreShopId"),y=t.event,C=t.onBack,S=r.useRef(),b=t.isPlaying,I=t.isLast,k=t.setLockSwiper,_=t.selectedVariantId,F=null===(e=t.showOverlay)||void 0===e||e,T="center";return(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:l,height:o,sx:{overflow:"hidden"},children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:T,height:"full",width:"full",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,x.jsx)(s.oM,{width:"full",ratio:l/o,children:(0,x.jsx)(m,{height:"100%",width:"100%",url:y.event_hls_url,isPlaying:b,event:y})})})}),F?(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:T,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,x.jsx)(Ot,{focusRef:S,event:t.event,isLast:I,onCloseCallback:C,productClickHandler:async t=>{const e=await(0,p.p)(t,(0,c.Ipo)(j),j);w(t),g(e),d(!0),k(!0)}})})}):(0,x.jsx)(x.Fragment,{}),!0===a?(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"200%"},direction:"column",justifyContent:T,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,x.jsx)(te,{focusRef:S,event:t.event,isLast:I,onCloseCallback:()=>C(),setLockSwiper:k,data:v,currentProduct:f,setOpenShopNow:d,selectedVariantId:_})})}):(0,x.jsx)("div",{})]})})};const ne=function(t,e){return isNaN(t)||isNaN(e)||e<=0||t>e?0:Math.ceil(t/e*100)};function ie(t){var e,n,[i,o,r,l]=(0,h.Z)();const[a]=(0,u.j1)("whatmoreSecondaryColor"),[d]=(0,u.j1)("whatmoreSecondaryColorShade900"),c=t.progress,p=null!==(e=t.totalSiblings)&&void 0!==e?e:1,v=null!==(n=t.indexAmongSiblings)&&void 0!==n?n:0;return(0,x.jsx)(s.Kq,{width:"96%",height:"fit-content",direction:"row",justifyContent:"center",alignItems:"center",spacing:"1px",children:[...Array(p).keys()].map((t=>(0,x.jsx)(s.Kq,{width:"100%",height:.004*r+"px",backgroundColor:t<v?a:d+"99",borderRightRadius:"lg",borderLeftRadius:"lg",direction:"row",justifyContent:"flex-start",alignItems:"center",overflow:"hidden",sx:{display:"block !important"},children:t==v?(0,x.jsx)(s.xu,{height:"100%",width:c+"%",bgColor:a,borderRightRadius:"lg",borderLeftRadius:"lg",sx:{display:"block !important"}}):(0,x.jsx)(x.Fragment,{})},"event-progress-bar-slab-"+t)))})}var oe=n(868),re=n(2630);const le=t=>t>=1e3?(t/1e3).toFixed(1)+"k":t;var ae=n(4862);var de=function(t){var e,n,i,o=t.whatmoreShareTemplateId;const l=t.whatmoreShareStoryId,a=t.whatmoreShareEventId,p=t.event,v=null===(e=t.showShareText)||void 0===e||e,m=null!==(n=t.shareButtonBottomMargin)&&void 0!==n?n:0,g=(0,u.MO)("whatmoreShopId"),f=(0,u.MO)("isInDesignMode"),w=(0,u.MO)("isDemoBrand"),j=(0,u.MO)("whatmorePrimaryFont"),{whatmoreWidgetSourceDetails:y}=(0,r.useContext)(V.I),[C,S,b,I]=(0,h.Z)(),k=null!==(i=t.iconSize)&&void 0!==i?i:.1*I;function _(){const e=(0,u.MO)("whatmoreLandingLocationType");var n;!function(t){f||w||(async()=>{(0,d.x0)(t)})()}(p),(e.startsWith("product")||"embed"===e)&&(o="te"),n="event_product_link"===(0,c.EEC)(g)?p.products[0].product_link||"":window.location.pathname,n=("event_product_link"===(0,c.EEC)(g)?"":window.location.hostname)+n+"?wtt="+o+"&wsid="+l+"&weid="+a,(0,c.lj5)(g)&&(n=n+"&"+(0,c.awP)(g)+"&utm_campaign=video-share&utm_medium="+e);const i={title:(0,c.JNF)(g),text:`${(0,c.Qa8)(g)} \n ${n} ${(0,c.AWG)(g)?"\n \n -via Whatmore":""}`};navigator.share&&!ae.nI?navigator.share(i):(t.setIsModalOpen(!0),t.setShareText([i,n]))}return(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.Cd,{cursor:"pointer",style:{marginBottom:m+"px"},children:(0,x.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"fit-content",width:"fit-content",children:[(0,x.jsx)(re.Z,{sx:{boxShadow:3,transform:"scaleX(-1)",color:"white",fontSize:k,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),_(),(0,q.GF)({userInteractionType:H.K.VIDEO_SHARE_CTA_CLICKED,widgetSourceDetails:y,event:p,productList:p.products,ctaList:p.cta})}}),v&&(0,c.u8S)(g)?(0,x.jsxs)(s.xv,{fontSize:.3*k+"px !important",fontWeight:"semibold !important",align:"center",sx:{fontFamily:j+" !important",color:"white !important",paddingRight:"10%"},children:["\xa0",p.total_share>(0,c.LWl)(g)?le(p.total_share):"Share","\xa0"]}):(0,x.jsx)(x.Fragment,{})]})})})},se=n(7933),ce=n(2785);var ue=function(t){var e;const n=(0,u.MO)("whatmoreShopId"),i=(0,u.MO)("whatmorePrimaryFont"),o=(0,u.MO)("whatmoreLikedEvents"),l=((0,u.MO)("whatmoreSecondaryColor"),(0,u.MO)("isInDesignMode")),a=(0,u.MO)("isDemoBrand"),{whatmoreWidgetSourceDetails:p}=(0,r.useContext)(V.I),v=t.event,[m,g]=(0,r.useState)(null!==(e=o[v.event_id])&&void 0!==e&&e),[f,w,j,y]=(0,h.Z)(),C=.1*y;function S(t,e){l||a||(async()=>{(0,d.Z6)(t,e)})()}function b(){(0,u.bU)("whatmoreLikedEvents",{...o,[v.event_id]:!m}),m?(S(v,-1),(0,q.GF)({userInteractionType:H.K.VIDEO_UNLIKED,widgetSourceDetails:p,event:v,productList:v.products,ctaList:v.cta})):(S(v,1),(0,q.GF)({userInteractionType:H.K.VIDEO_LIKED,widgetSourceDetails:p,event:v,productList:v.products,ctaList:v.cta})),g(!m)}const I=v.total_like+(m?1:0);return(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.Cd,{cursor:"pointer",children:(0,x.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"fit-content",width:"fit-content",children:[m?(0,x.jsx)(ce.Z,{sx:{boxShadow:3,color:(0,c.dmX)(n),fontSize:C,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),b()}}):(0,x.jsx)(se.Z,{sx:{boxShadow:3,color:"white",fontSize:C,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),b()}}),(0,x.jsx)(x.Fragment,{children:(0,c.CEM)(n)?(0,x.jsxs)(s.xv,{fontSize:.3*C+"px !important",fontWeight:"semibold !important",align:"center",sx:{fontFamily:i+" !important",color:"white !important",position:"relative",bottom:"5px"},children:["\xa0",I>=(0,c.zKg)(n)?le(I):"Like","\xa0"]}):(0,x.jsx)(x.Fragment,{})})]})})})};const he=t=>{let{iconSize:e}=t;return(0,x.jsx)("div",{style:{backgroundColor:"#25D366",borderRadius:"50%",padding:.3*e},children:(0,x.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:e,height:e,fill:"white",class:"bi bi-whatsapp",viewBox:"0 0 16 16",children:(0,x.jsx)("path",{d:"M13.601 2.326A7.854 7.854 0 0 0 7.994 0C3.627 0 .068 3.558.064 7.926c0 1.399.366 2.76 1.057 3.965L0 16l4.204-1.102a7.933 7.933 0 0 0 3.79.965h.004c4.368 0 7.926-3.558 7.93-7.93A7.898 7.898 0 0 0 13.6 2.326zM7.994 14.521a6.573 6.573 0 0 1-3.356-.92l-.24-.144-2.494.654.666-2.433-.156-.251a6.56 6.56 0 0 1-1.007-3.505c0-3.626 2.957-6.584 6.591-6.584a6.56 6.56 0 0 1 4.66 1.931 6.557 6.557 0 0 1 1.928 4.66c-.004 3.639-2.961 6.592-6.592 6.592zm3.615-4.934c-.197-.099-1.17-.578-1.353-.646-.182-.065-.315-.099-.445.099-.133.197-.513.646-.627.775-.114.133-.232.148-.43.05-.197-.1-.836-.308-1.592-.985-.59-.525-.985-1.175-1.103-1.372-.114-.198-.011-.304.088-.403.087-.088.197-.232.296-.346.1-.114.133-.198.198-.33.065-.134.034-.248-.015-.347-.05-.099-.445-1.076-.612-1.47-.16-.389-.323-.335-.445-.34-.114-.007-.247-.007-.38-.007a.729.729 0 0 0-.529.247c-.182.198-.691.677-.691 1.654 0 .977.71 1.916.81 2.049.098.133 1.394 2.132 3.383 2.992.47.205.84.326 1.129.418.475.152.904.129 1.246.08.38-.058 1.171-.48 1.338-.943.164-.464.164-.86.114-.943-.049-.084-.182-.133-.38-.232z"})})})};var pe=n(8866);const ve=t=>{let{iconSize:e}=t;return(0,x.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:.3*e},children:(0,x.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:e,height:e,fill:"currentColor",class:"bi bi-twitter-x",viewBox:"0 0 16 16",children:(0,x.jsx)("path",{d:"M12.6.75h2.454l-5.36 6.142L16 15.25h-4.937l-3.867-5.07-4.425 5.07H.316l5.733-6.57L0 .75h5.063l3.495 4.633L12.601.75Zm-.86 13.028h1.36L4.323 2.145H2.865z"})})})},xe=t=>{let{iconSize:e}=t;return(0,x.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:.3*e},children:(0,x.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",width:e,height:e,fill:"currentColor",class:"bi bi-copy",viewBox:"0 0 16 16",children:(0,x.jsx)("path",{"fill-rule":"evenodd",d:"M4 2a2 2 0 0 1 2-2h8a2 2 0 0 1 2 2v8a2 2 0 0 1-2 2H6a2 2 0 0 1-2-2zm2-1a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1V2a1 1 0 0 0-1-1zM2 5a1 1 0 0 0-1 1v8a1 1 0 0 0 1 1h8a1 1 0 0 0 1-1v-1h1v1a2 2 0 0 1-2 2H2a2 2 0 0 1-2-2V6a2 2 0 0 1 2-2h1v1z"})})})};var me=t=>{const e=t.shareText,[n,i]=(0,r.useState)("Copy link"),[o,l]=(0,r.useState)("");return(0,x.jsx)(x.Fragment,{children:t.isModalOpen&&(0,x.jsxs)("div",{className:"modal-overlay",style:{backgroundColor:"white",borderRadius:"10px",padding:"12px 12px 20px 12px"},children:[(0,x.jsxs)("div",{style:{cursor:"pointer",display:"flex",justifyContent:"space-between",paddingBottom:"6px"},children:[(0,x.jsx)("img",{onClick:()=>{window.location.href="https://whatmore.ai"},src:"https://whatmore-other-assets.b-cdn.net/whatmore/new_whatmore_logo.png",style:{objectFit:"contain",backgroundColor:"transparent",borderRadius:"0px",width:Math.min(t.iconSize,28)+"px"}}),(0,x.jsx)(P.Z,{onClick:e=>{e.stopPropagation(),t.setIsModalOpen(!1)}})]}),(0,x.jsx)("div",{}),(0,x.jsx)(s.iz,{color:"blackAlpha.500",size:"1px",width:"100%"}),(0,x.jsxs)("div",{className:"social-icons",style:{display:"flex",gap:"20px",justifyContent:"center",paddingTop:"12px"},children:[(0,x.jsxs)("div",{onClick:t=>{var n;t.stopPropagation();const i=encodeURIComponent(null===(n=e[0])||void 0===n?void 0:n.text);window.open(`https://wa.me/?text=${i}`,"_blank")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,x.jsx)(he,{iconSize:Math.min(t.iconSize,30)}),(0,x.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14)},children:"Whatsapp"})]}),(0,x.jsxs)("div",{onClick:t=>{var n;t.stopPropagation();const i=encodeURIComponent(null===(n=e[0])||void 0===n?void 0:n.text);window.open(`https://twitter.com/intent/tweet?text=${i}`,"_blank")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,x.jsx)(ve,{iconSize:Math.min(t.iconSize,30),style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,x.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14)},children:"X"})]}),(0,x.jsxs)("div",{onClick:t=>{t.stopPropagation(),navigator.clipboard.writeText(e[1]),i("Link copied"),l("green")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,x.jsx)(xe,{iconSize:Math.min(t.iconSize,30),style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,x.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14),color:o},children:n})]})]})]})})};var ge=function(t){var e,n;const i=null===(e=t.brandName)||void 0===e?void 0:e.replace(/\s+/g,"_"),o=(0,u.MO)("whatmorePrimaryFont"),r=(0,u.MO)("whatmoreShopId"),l=null!==(n=t.fontSize)&&void 0!==n?n:"8",[a]=(0,pe.Z)(),d=`https://www.whatmore.ai/shoppable-videos?utm_source=${i}&utm_medium=referral&utm_campaign=${"landscape"===a?"customer_referral_desktop":"customer_referral_mobile"}`;return(0,x.jsx)(s.rU,{href:d,isExternal:!0,children:(0,c.XFt)(r)&&(0,x.jsxs)(s.Kq,{direction:"row",justifyContent:"flex-start",alignItems:"center",width:"fit-content",spacing:"2px",paddingLeft:"2px",paddingRight:"2px",children:[(0,x.jsx)("p",{style:{textAlign:"center",color:"white",fontFamily:o,fontWeight:"normal",fontSize:1.1*l+"px"},children:"powered by Whatmore"}),(0,x.jsx)(s.xu,{width:"10px"}),(0,x.jsx)("img",{src:"https://whatmore-other-assets.b-cdn.net/whatmore/new_whatmore_logo.png",style:{objectFit:"contain",width:1.7*l,backgroundColor:"transparent",borderRadius:"0px"}})]})})};function fe(t){var e;const n=t.event,[i,o,l,a]=(0,h.Z)(),[d]=(0,u.j1)("whatmorePrimaryFont"),{whatmoreIsStoriesTemplate:p}=(0,r.useContext)(V.I),[v]=(0,u.j1)("whatmoreSecondaryColor"),[m]=(0,u.j1)("whatmoreShopId"),g=(0,c.f63)(m),f=null!==(e=(0,c.u2W)(m))&&void 0!==e?e:[v,g,v,g,v],w=(0,r.useRef)(null);return(0,r.useEffect)((()=>{w.current&&w.current.play()}),[]),(0,x.jsx)(x.Fragment,{children:p?(0,x.jsx)(s.xu,{width:"100%",height:"fit-content",padding:"5px",children:(0,x.jsxs)(s.Kq,{direction:"row",width:"100%",height:"fit-content",justifyContent:"flex-start",children:[(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.Cd,{overflow:"hidden",size:.14*a+"px",sx:{boxShadow:"0px 2px 1px 0px "+f[0]+"50, 0px -2px 1px 0px "+f[1]+"50, 2px 0px 1px 0px "+f[2]+"50, -2px 0px 1px 0px "+f[3]+"80, 2px -2px 1px 0px "+f[4]+"80, -2px 2px 1px 0px "+f[0]+"DA, 2px 2px 1px 0px "+f[1]+"DA, -2px -2px 1px 0px "+f[2]+"DA"},children:"video"==(0,pt.$)((0,oe.V)(n.storyset_thumbnail_image))?(0,x.jsx)("video",{className:"whatmore-story-thumbnail",ref:w,preload:"metadata",loop:!0,playsInline:!0,src:(0,oe.V)(n.storyset_thumbnail_image),muted:!0,alt:"story image"}):(0,x.jsx)("img",{src:(0,oe.V)(n.storyset_thumbnail_image),style:{objectFit:"cover",height:"100%",width:"100%",backgroundColor:"white"}})})}),(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.xv,{style:{overflow:"hidden",textOverflow:"ellipsis"},noOfLines:1,fontSize:.05*a+"px",fontWeight:"medium",lineHeight:"100%",sx:{fontFamily:d+" !important",color:"white !important",textShadow:"0px 0px 4px black !important;"},children:n.storyset_name})})]})}):(0,x.jsx)(x.Fragment,{})})}var we=function(t){const[e,n,i]=(0,pe.Z)(),[o]=(0,u.j1)("isInDesignMode"),[l]=(0,u.j1)("isDemoBrand"),[a,p]=(0,u.j1)("isProductSwiperCatalogOpen"),[v,m]=(0,u.j1)("isFirstIndicatorRenderDone"),[g]=(0,u.j1)("whatmoreShopId"),f=(0,r.useContext)(ln),{whatmoreEventsBrowsingTemplate:w}=(0,r.useContext)(V.I),[j,C,S,b]=(0,h.Z)(),I=(0,u.MO)("whatmorePrimaryFont"),k=t.event,_=t.storySetId,F=t.isLast,E=t.onCloseCallback,P=t.focusRef,L=t.productClickHandler,z=t.videoPlayingData,R=t.totalSiblingEvents,M=t.indexAmongSiblings,K=t.leftOpenSpaceClickHandler,A=t.midOpenSpaceClickHandler,W=t.rightOpenSpaceClickHandler,{whatmoreWidgetSourceDetails:N}=(0,r.useContext)(V.I),Z=.1*b,[U,B]=(0,r.useState)(!1),[Y,X]=(0,r.useState)([]),G=t=>{$.current&&!$.current.contains(t.target)&&B(!1)},$=(0,r.useRef)(null);(0,r.useEffect)((()=>(U?document.addEventListener("click",G):document.removeEventListener("click",G),()=>{document.removeEventListener("click",G)})),[U]);const J="Free"==(0,c.Svj)(g)&&"portrait"==e;return(0,x.jsxs)(s.xu,{width:"full",height:"full",borderRadius:"md",children:[U&&(0,x.jsx)("div",{ref:$,className:"whatmore-share-modal",style:{zIndex:100,position:"absolute",boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.6)",width:"75%",top:"45%",left:"50%",transform:"translateX(-50%) translateY(-50%)"},children:(0,x.jsx)(me,{shareText:Y,setShareText:X,iconSize:Z,isModalOpen:U,setIsModalOpen:B})}),(0,x.jsxs)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"space-between",children:[(0,x.jsxs)(s.Kq,{width:"full",height:"fit-content",direction:"column",justifyContent:"flex-start",alignItems:"center",bgGradient:"linear(to-t, transparent, whiteAlpha.100, blackAlpha.200, blackAlpha.400, blackAlpha.800)",children:[f.showVideoPlayingData?(0,x.jsx)(s.Kq,{direction:"row",width:"100%",height:"fit-content",marginTop:"5px",justifyContent:"center",children:(0,x.jsx)(ie,{progress:ne(z.current_time,z.video_duration),totalSiblings:R,indexAmongSiblings:M})}):(0,x.jsx)(x.Fragment,{}),(0,x.jsx)(s.xu,{width:"full",margin:"2px",marginTop:"5px",children:(0,x.jsxs)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",paddingRight:"10px",paddingLeft:"10px",children:[(0,x.jsx)(fe,{event:k}),(0,x.jsxs)(s.Kq,{direction:"row",width:"fit-content",justifyContent:"end",paddingLeft:"10px",children:[(0,mt.ZK)(w)?(0,x.jsx)(de,{whatmoreShareTemplateId:(0,mt.QN)(w),whatmoreShareStoryId:_,whatmoreShareEventId:k.event_id,event:k,showShareText:!1,iconSize:.07*b,shareButtonBottomMargin:6,setIsModalOpen:B,setShareText:X}):(0,x.jsx)(x.Fragment,{}),(0,x.jsx)(y,{focusRef:P}),("landscape"!==e||t.showCloseOverlay)&&(0,x.jsx)(O,{event:k,onCloseCallback:E})]})]})})]}),(0,x.jsxs)(s.Kq,{width:"100%",height:"100%",direction:"row",justifyContent:"center",children:[(0,x.jsx)(s.xu,{width:"33%",height:"100%",onClick:()=>{K()},sx:{display:"block !important"}}),(0,x.jsx)(s.xu,{width:"34%",height:"100%",onClick:()=>{A()},sx:{display:"block !important"}}),(0,x.jsx)(s.xu,{width:"33%",height:"100%",onClick:()=>{W()},sx:{display:"block !important"}})]}),(0,x.jsxs)(s.xu,{width:"full",height:"fit-content",children:[f.totalEvents>1&&!v&&f.showSwipeIndicator?(0,x.jsx)(s.xu,{width:"full",margin:"2px",children:(0,x.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"center",children:(0,x.jsx)(D,{swipeUp:!F})})}):null,(0,x.jsxs)(s.xu,{width:"fit-content",height:"fit-content",position:"absolute",right:0,bottom:"25%",children:[(0,c.slY)(g)&&!(0,mt.ZK)(w)?(0,x.jsx)(s.xu,{ml:"auto",width:"fit-content",paddingY:"12px",paddingX:"8px",children:(0,x.jsxs)(s.Kq,{gap:"4px",direction:"column",alignItems:"center",cursor:"pointer",onClick:function(){var t;o||l||(async()=>{(0,d.lY)(k,1)})(),(0,q.GF)({userInteractionType:H.K.WHATSAPP_ICON_CLICKED,widgetSourceDetails:N,event:k,productList:null===k||void 0===k?void 0:k.products,ctaList:null===k||void 0===k?void 0:k.cta});const e=k.products.map((t=>`${t.product_link} \n`)),n=(0,c.gtK)(g),i=`Hey, I am interested in ${k.products.length>1?"these products":"this product"} I saw on ${null===(t=k.products[0])||void 0===t?void 0:t.brand} store: \n${e}. Could you please help me with some queries?`;window.open(n+`&text=${i}&type=phone_number`,"_blank")},children:[(0,x.jsx)(he,{iconSize:.7*Z,style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,x.jsx)(s.xv,{fontSize:Z*(0,c.Xod)(g)+"px",fontWeight:"bold",align:"center",style:{marginTop:0},sx:{fontFamily:I+" !important",color:"white !important"},children:(0,c.UiZ)(g)})]})}):(0,x.jsx)(x.Fragment,{}),(0,c.jY3)(g)?(0,x.jsx)(s.xu,{width:"full",height:"fit-content",paddingX:"12px",children:(0,x.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,x.jsx)(ue,{event:k})})}):(0,x.jsx)(x.Fragment,{}),(0,c.ROU)(g)&&!(0,mt.ZK)(w)?(0,x.jsx)(s.xu,{width:"full",height:"fit-content",paddingX:"12px",children:(0,x.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,x.jsx)(de,{whatmoreShareTemplateId:(0,mt.QN)(w),whatmoreShareStoryId:_,whatmoreShareEventId:k.event_id,event:k,setIsModalOpen:B,setShareText:X})})}):(0,x.jsx)(x.Fragment,{})]}),(0,_t.kT)(k)?(0,x.jsxs)(s.xu,{width:"full",children:[(0,c.Jm1)(g)?(0,x.jsx)(s.xu,{w:"100%",children:(0,x.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,x.jsx)(T,{event:k,onToggle:t=>{p("minimize-button"!==t)}})})}):(0,x.jsx)(x.Fragment,{}),(0,x.jsx)(s.xu,{display:"flex",width:"100%",height:"fit-content",children:(0,x.jsx)(Et,{event:k,productClickHandler:L})})]}):(0,x.jsx)(x.Fragment,{})]}),J&&(0,x.jsx)(s.Kq,{direction:"row",width:"100%",height:"fit-content",bg:"gray",py:"3px",justifyContent:"center",children:(0,x.jsx)(ge,{brandName:null===k||void 0===k?void 0:k.brand,fontSize:.033*b})})]})]})},je=n(2279),ye=n.n(je),Ce=n(342);var Se=function(t){var e,n,i,o,l,a,[d,m,g,f]=(0,h.Z)();const[w,j]=(0,r.useState)(!1),[y,C]=(0,r.useState)(),[S,b]=(0,r.useState)(),[I,k]=(0,r.useState)({current_time:0,video_duration:0,is_video_ended:!1}),_=(0,u.MO)("whatmoreShopId"),F=t.event,T=t.storyId,E=t.onBack,P=r.useRef(),O=t.isPlaying,L=t.isLast,z=t.setLockSwiper,R=t.onVideoEndedCallback,M=t.progressUpdateCallback,D=null!==(e=t.totalSiblingEvents)&&void 0!==e?e:0,K=null!==(n=t.indexAmongSiblings)&&void 0!==n?n:0,A=null===(i=t.showOverlay)||void 0===i||i,W=null!==(o=t.leftOpenSpaceClickHandler)&&void 0!==o?o:()=>{},N=null!==(l=t.midOpenSpaceClickHandler)&&void 0!==l?l:()=>{},Z=null!==(a=t.rightOpenSpaceClickHandler)&&void 0!==a?a:()=>{},{whatmoreWidgetSourceDetails:U}=(0,r.useContext)(V.I),B="center";let Y;try{Y=ye()((()=>{R()}),1e3,{leading:!0,trailing:!1})}catch(X){console.log(X)}return(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:f,height:g,sx:{overflow:"hidden"},children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:B,height:"full",width:"full",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,x.jsx)(s.oM,{width:"full",ratio:f/g,children:(0,x.jsx)(v.Z,{height:"100%",width:"100%",url:(0,oe.V)((0,Ce.uv)(F)),isPlaying:O,timeUpdateCallback:function(t,e){const n=ne(t,e);M(n);const i=I.is_video_ended;n>=99&&O&&!i?(Y(),k({current_time:t,video_duration:e,is_video_ended:!0})):k({current_time:t,video_duration:e,is_video_ended:i})},event:F,source:t.source})})})}),A?(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:B,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,x.jsx)(we,{focusRef:P,event:t.event,isLast:L,onCloseCallback:t=>{E(t),(0,q.Z2)({userInteractionType:H.K.VIDEO_PLAYBACK,userInteractionMetadata:{watch_time:I.current_time},widgetSourceDetails:U,event:F,productList:F.products,ctaList:F.cta})},productClickHandler:async t=>{const e=await(0,p.p)(t,(0,c.Ipo)(_),_);b(t),C(e),j(!0),z(!0),(0,q.GF)({userInteractionType:H.K.SHOPNOW_CLICKED,widgetSourceDetails:U,event:F,productList:F.products,ctaList:F.cta}),(0,u.bU)("whatmoreAllowAutoSlide",!1)},videoPlayingData:I,totalSiblingEvents:D,indexAmongSiblings:K,leftOpenSpaceClickHandler:W,midOpenSpaceClickHandler:N,rightOpenSpaceClickHandler:Z,storySetId:T,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay})})}):(0,x.jsx)(x.Fragment,{}),!0===w?(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"200%"},direction:"column",justifyContent:B,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,x.jsx)(te,{focusRef:P,event:t.event,isLast:L,onCloseCallback:()=>E(),setLockSwiper:z,data:y,currentProduct:S,setOpenShopNow:t=>{j(t),(0,u.bU)("whatmoreAllowAutoSlide",!t)}})})}):(0,x.jsx)("div",{})]})})},be=n(7300),Ie=n(8984),ke=n(58),_e=n(9723);var Fe=function(t){var[e,n,i,o]=(0,h.Z)();const r=(0,u.MO)("whatmoreShopId"),l=t.event,a=t.isPlaying,d="center";return(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:o,height:i,sx:{overflow:"hidden"},children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:d,height:"full",width:"full",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,x.jsx)(s.oM,{width:"full",ratio:o/i,children:(0,x.jsx)(v.Z,{height:"100%",width:"100%",url:(0,oe.V)((0,Ce.uv)(l)),isPlaying:a,timeUpdateCallback:function(t,e){},event:l,source:t.source})})})}),(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:d,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",backdropFilter:"auto",backdropBlur:"10px",onClick:t=>{(0,ke.QV)()},children:(0,x.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"full",width:"full",children:[(0,x.jsx)(_e.Z,{sx:{boxShadow:3,color:(0,c.Ya_)(r),fontSize:.4*o,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{(0,ke.QV)()}}),(0,x.jsx)(s.xv,{color:"white",fontSize:.05*o+"px",fontWeight:"bold",align:"left",children:"Please click to play video.."})]})})})]})})},Te=n(3433);var Ee=function(t){var e,n;const r=t.event,l=null===(e=t.isPlaying)||void 0===e||e,a=t.onBack,d=t.isLast,s=t.setLockSwiper,c=(t.heightFactor,t.widthFactor,t.onVideoEndedCallback),h=t.progressUpdateCallback,[p,v]=(0,j.Z)(),[m]=(0,u.j1)("whatmoreVideoPlayerPoolBlessed"),g=null===(n=t.showOverlay)||void 0===n||n;function f(){v(!p)}if((0,Ie.KE)()&&0==m)return(0,x.jsx)(Fe,{event:r,onBack:a,isPlaying:l,isLast:d,setLockSwiper:s,onVideoEndedCallback:c,progressUpdateCallback:h,totalSiblingEvents:1,indexAmongSiblings:0,leftOpenSpaceClickHandler:()=>{f()},midOpenSpaceClickHandler:()=>{f()},rightOpenSpaceClickHandler:()=>{f()},showOverlay:g,source:Te.j.CAROUSEL_EVENT_OPENED},"shopping-video-view"+r.event_id);if((0,be.B6)(r)||(0,be.WJ)(r))return(0,x.jsx)(Se,{event:r,onBack:a,isPlaying:l,isLast:d,setLockSwiper:s,onVideoEndedCallback:c,progressUpdateCallback:h,totalSiblingEvents:1,indexAmongSiblings:0,leftOpenSpaceClickHandler:()=>{f()},midOpenSpaceClickHandler:()=>{f()},rightOpenSpaceClickHandler:()=>{f()},showOverlay:g,source:Te.j.CAROUSEL_EVENT_OPENED,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay},"shopping-video-view"+r.event_id);if((0,be.yC)(r)){var{status:w,bannerText:y,timeToStartInMins:C}=i.Z.getEventStatus(r);if(w.name===o.Z.LIVE.name)return(0,x.jsx)(ee,{event:r,onBack:a,isPlaying:l,isLast:d,showOverlay:g},"shopping-live-view"+r.event_id)}return console.error("Can't render event which is neither video or a currently-live-event"),(0,x.jsx)("div",{})},Pe=n(9284),Oe=n.n(Pe),Le=n(7463),ze=n(2154);function Re(t){var e;const[n,i]=(0,r.useState)(!1),o=t.onClick,l=null!==(e=t.fontSize)&&void 0!==e?e:50;return(0,x.jsx)("div",{style:{height:"fit-content",width:"fit-content",backgroundColor:"black",opacity:.4,borderRadius:"50%"},className:[n?"whatmore-scale-on-tap":""].join(" "),children:"left"===t.type?(0,x.jsx)(ze.Z,{sx:{color:"white",fontSize:l+"px",filter:"drop-shadow(0 0 5px black);"},onClick:t=>{i(!0),setTimeout((()=>{i(!1)}),500),o(t,"up")}}):(0,x.jsx)(Le.Z,{sx:{color:"white",fontSize:l+"px",filter:"drop-shadow(0 0 5px black);"},onClick:t=>{i(!0),setTimeout((()=>{i(!1)}),500),o(t,"down")}})})}var Me=function(t){var e,n,i;const o=null!==(e=t.relativeBottomPercentage)&&void 0!==e?e:"30%",r=null!==(n=t.width)&&void 0!==n?n:"100%",l=null!==(i=t.fontSize)&&void 0!==i?i:50,a=t.handleClick;return(0,x.jsx)("div",{style:{position:"relative",zIndex:1,bottom:o,width:"100%",height:"fit-content",display:"flex",flexFlow:"row nowrap",justifyContent:"center"},id:"here",children:(0,x.jsxs)("div",{style:{display:"flex",flexFlow:"row nowrap",width:r,height:"fit-content",paddingRight:"5px",paddingLeft:"5px",paddingTop:"5px",paddingBottom:"5px",justifyContent:"space-between",alignContent:"center"},children:[(0,x.jsx)(Re,{type:"left",onClick:a,fontSize:l}),(0,x.jsx)(Re,{type:"right",onClick:a,fontSize:l})]})})},De=n(2860),Ke=n(4669);var Ae=function(t,e){function n(t,e){return 1==e?0:t<0?e+t:t>=e?t-e:t}const i=(0,r.useRef)({prevIndex:n(t-1,e),activeIndex:t,nextIndex:n(t+1,e)});return[function(){return i.current},function(t){i.current="right"==t?{prevIndex:n(i.current.activeIndex,e),activeIndex:n(i.current.activeIndex+1,e),nextIndex:n(i.current.activeIndex+2,e)}:{prevIndex:n(i.current.activeIndex-2,e),activeIndex:n(i.current.activeIndex-1,e),nextIndex:n(i.current.activeIndex,e)}},function(t){return n(i.current.activeIndex+t)}]};var We=function(t,e){const n=(0,r.useRef)({clientX:0,clientY:0});return[function(t){n.current.clientX=t.changedTouches[0].clientX,n.current.clientY=t.changedTouches[0].clientY},function(i){const o=n.current.clientX,r=n.current.clientY;var l=o-i.changedTouches[0].clientX,a=r-i.changedTouches[0].clientY;return"vertical"==t&&Math.abs(a)>e||"horizontal"==t&&Math.abs(l)>e?"vertical"==t?a>0?"right":"left":l>0?"right":"left":null}]};var Ne=function(t,e){const n=(0,r.useRef)(ye()(((t,e)=>{t(e)}),300,{leading:!0,trailing:!1}));return[function(i,o){var r=0;if(r="vertical"==t?i.deltaY:i.deltaX,Math.abs(r)<=e)return;const l=r>0?"right":"left";n.current(o,l)}]},qe=n(5173);var He=function(t){const e=t.events,n=t.eventIndex,i=t.onBack;var[o,p,v,m]=(0,h.Z)();const[g]=(0,u.j1)("isInDesignMode"),[f]=(0,u.j1)("isDemoBrand"),[w,j]=(0,r.useState)(!0),[y,C]=(0,u.j1)("isFirstIndicatorRenderDone"),[S,b]=(0,r.useState)(!1),{setCloseClickComponent:I}=(0,r.useContext)(ln),{slideDirection:k}=(0,r.useContext)(ln),[_]=(0,u.j1)("whatmoreShopId"),[F]=(0,u.j1)("whatmoreLandingLocationType"),[T,E]=Ae(n,e.length),[P,O]=We(k,50),[L]=Ne("vertical",30),[z,R]=(0,r.useState)(!1),[M,D]=(0,r.useState)(null),{whatmoreWidgetSourceDetails:K,whatmoreUserInfo:A}=(0,r.useContext)(V.I);function N(){R(!1)}function Z(t){N(),setTimeout((()=>{i(t)}),500)}(0,r.useEffect)((()=>(R(!0),()=>{})),[]);const U=K.landingLocationType,B=K.templateType;function Y(){(0,u.MO)("whatmoreAllowAutoSlide")&&(E("right"),M.slideNext())}function X(t,e){E(e),function(t,e){M&&("left"===e?M.slidePrev():M.slideNext())}(0,e)}I(Z);const G=Math.round(.05*v);return(0,x.jsx)(Oe(),{isOpen:z,onAfterOpen:function(){},onRequestClose:N,overlayClassName:"whatmore-modal",className:"whatmore-modal-content",ariaHideApp:!1,children:(0,x.jsx)(qe.Z,{children:(0,x.jsxs)("div",{style:{height:window.innerHeight,width:window.innerWidth,backgroundColor:(0,W.lA)("#000000",13)},onTouchStart:t=>{P(t)},onTouchEnd:t=>{if(S)return;const e=O(t);e&&X(0,e)},onWheel:t=>{S||L(t,(t=>{X(0,t)}))},children:[(0,x.jsx)(l.tq,{speed:400,threshold:G,slidesPerView:1,direction:k,modules:[a.tl,a.Gk],initialSlide:n,loop:1!=e.length,height:window.innerHeight,width:window.innerWidth,watchSlidesProgress:!0,allowSlideNext:!S,allowSlidePrev:!S,allowTouchMove:!1,onSwiper:t=>{D(t),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:K,event:e[T().activeIndex],productList:e[T().activeIndex].products})},onSlideChange:t=>{var n;w?j(!1):(y||C(!0),n=e[T().activeIndex],g||f||(async()=>{const t=(0,mt.NY)(U)+(0,mt.dS)(B)+"_"+(null===n||void 0===n?void 0:n.event_id);(0,d.wh)(n),"index"===F?((0,Ke.Tc)(_,De.Xh,De.pR),(0,ot.H4)(n.event_id,n.products,De.Xh,De.pR,t,null===n||void 0===n?void 0:n.location,null===A||void 0===A?void 0:A.userType)):F.startsWith("product")||"embed"===F?((0,Ke.Tc)(_,De.h7,De.dU),(0,ot.H4)(n.event_id,n.products,De.h7,De.dU,t)):F.startsWith("collection")?((0,Ke.Tc)(_,De.U$,De.Pk),(0,ot.H4)(n.event_id,n.products,De.U$,De.Pk,t)):((0,Ke.Tc)(_,De.Xh,De.pR),(0,ot.H4)(n.event_id,n.products,De.Xh,De.pR,t))})(),(0,q.y4)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:K,event:e[T().activeIndex],productList:e[T().activeIndex].products}))},children:[...Array(Math.min(e.length,3)).keys()].map((n=>(0,x.jsx)(l.o5,{children:n=>{let{isActive:i,isPrev:o,isNext:r,isVisible:l,isDuplicate:a}=n;const d=i?"activeIndex":o?"prevIndex":"nextIndex";return(0,x.jsx)(s.Kq,{direction:"column",height:window.innerHeight,justifyContent:"center",children:(0,x.jsx)(Ee,{event:e[T()[d]],onBack:Z,isPlaying:1==e.length||i&&l,isLast:!1,setLockSwiper:b,onVideoEndedCallback:Y,progressUpdateCallback:t=>{},showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay})})}},"event-vertical-scroll-slide-"+n)))}),e.length>1&&!S&&(0,c.h6H)(_)&&"horizontal"===(0,c.e8z)(_)&&"horizontal"===k?(0,x.jsx)(Me,{relativeBottomPercentage:"50%",width:m,handleClick:(t,e)=>{X(0,"down"==e?"right":"left")},fontSize:parseInt(.12*m)}):(0,x.jsx)(x.Fragment,{})]})})})},Ve=n(1168);n(6143),n(7850),n(4444),n(7244),n(123),n(5892),n(1811);const Ze=t=>{let{children:e,customClass:n,show:i,closeCallback:o}=t;return Ve.createPortal((0,x.jsxs)("div",{className:`whatmore-landscape-modal whatmore-root ${n}`,style:{display:i?"block":"none"},children:[(0,x.jsx)("div",{className:"whatmore-landscape-modal-overlay",onClick:o}),(0,x.jsx)("div",{className:"whatmore-landscape-modal-content",children:e})]}),document.body)};Ze.defaultProps={children:(0,x.jsx)("div",{children:"Empty Modal"}),customClass:"",show:!1,closeCallback:()=>!1};var Ue=Ze;var Be=function(t){var e,[n,i,o,p]=(0,h.Z)();const[v]=(0,u.j1)("isInDesignMode"),[m]=(0,u.j1)("isDemoBrand"),[g,f]=(0,u.j1)("isFirstIndicatorRenderDone"),[w,j]=(0,r.useState)(0!=t.eventIndex),{setCloseClickComponent:y}=(0,r.useContext)(ln),[C,S]=(0,r.useState)(!1),[b]=(0,u.j1)("whatmoreShopId"),[I]=(0,u.j1)("whatmoreLandingLocationType"),{whatmoreUITheme:k}=(0,r.useContext)(V.I),{whatmoreWidgetSourceDetails:_,whatmoreUserInfo:F}=(0,r.useContext)(V.I),[T,E]=(0,r.useState)(!1),[P,L]=(0,r.useState)(null);function z(){E(!1)}const R=t.events,M=t.eventIndex,D=t.onBack,K=R.concat(R),A=R.length,N=null===R||void 0===R||null===(e=R[0])||void 0===e?void 0:e.brand,Z=(0,r.useRef)(0);function U(t){z(),setTimeout((()=>{D(t)}),500)}function B(){P&&!P.isEnd&&(0,u.MO)("whatmoreAllowAutoSlide")&&P.slideNext()}(0,r.useEffect)((()=>(E(!0),()=>{})),[]),y(U);const Y=_.landingLocationType,X=_.templateType,G=parseInt(Math.min(5,R.length));return(0,x.jsx)(Ue,{show:T,closeCallback:z,customClass:"whatmore-landscape-modal-swipe-view",children:(0,x.jsxs)(s.Kq,{direction:"column",width:window.innerWidth,height:window.innerHeight,justifyContent:"center",aligntItems:"center",backgroundColor:(0,W.lA)("#000000",13),children:[(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.xu,{height:"fit-content",width:p*G,children:(0,x.jsxs)(l.tq,{onInit:t=>{L(t),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:_,event:R[t.activeIndex],productList:R[t.activeIndex].products,ctaList:R[t.activeIndex].cta})},slidesPerView:G,centeredSlides:!0,allowTouchMove:!1,initialSlide:M,modules:[a.lI,a.W_,a.Gk,a.pt,a.tl],navigation:G>=5,effect:"coverflow",coverflowEffect:{rotate:-8,stretch:Math.floor(.22*o),depth:100,scale:.7,modifier:1,slideShadows:!1},height:"fit-content",width:p*G,watchSlidesProgress:!0,onSlideChange:t=>{var e;w?j(!1):(g||f(!0),e=R[t.activeIndex],v||m||(async()=>{const t=(0,mt.NY)(Y)+(0,mt.dS)(X)+"_"+(null===e||void 0===e?void 0:e.event_id);(0,d.wh)(e),"index"===I?((0,Ke.Tc)(b,De.Xh,De.pR),(0,ot.H4)(e.event_id,e.products,De.Xh,De.pR,t,null===e||void 0===e?void 0:e.location,null===F||void 0===F?void 0:F.userType)):I.startsWith("product")||"embed"===I?((0,Ke.Tc)(b,De.h7,De.dU),(0,ot.H4)(e.event_id,e.products,De.h7,De.dU,t)):I.startsWith("collection")?((0,Ke.Tc)(b,De.U$,De.Pk),(0,ot.H4)(e.event_id,e.products,De.U$,De.Pk,t)):((0,Ke.Tc)(b,De.Xh,De.pR),(0,ot.H4)(e.event_id,e.products,De.Xh,De.pR,t))})(),(0,q.y4)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:_,event:R[t.activeIndex],productList:R[t.activeIndex].products,ctaList:R[t.activeIndex].cta}))},mousewheel:{invert:!1,thresholdDelta:20},children:[R.length>2&&(0,x.jsx)("div",{className:"whatmore-shopping-close-button",children:(0,x.jsx)(O,{onCloseCallback:D})}),K.slice(M,R.length+M).map(((t,e)=>(0,x.jsx)(l.o5,{children:t=>{let{isActive:n,isPrev:i,isNext:r,isVisible:l,isDuplicate:a}=t;if(n)return(0,x.jsx)(s.Kq,{direction:"column",height:o,width:1*p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",children:(0,x.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(b),borderColor:(0,c.qPe)(b)},children:(0,x.jsx)(Ee,{event:R[e%A],onBack:U,isPlaying:!0,isLast:e%A===R.length-1,setLockSwiper:S,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{},showCloseOverlay:(null===R||void 0===R?void 0:R.length)<=2})})});if(r)return(0,x.jsx)(s.Kq,{direction:"column",height:o,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{P.slideTo(e%A,300)},children:(0,x.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(b),borderColor:(0,c.qPe)(b)},children:(0,x.jsx)(Ee,{event:R[e%A],onBack:U,isPlaying:!1,isLast:e%A===R.length-1,setLockSwiper:S,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{},showOverlay:!1})})});if(i&&1===Z.current)return(0,x.jsx)(s.Kq,{direction:"column",height:o,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{P.slideTo(e%A,300)},children:(0,x.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(b),borderColor:(0,c.qPe)(b)},children:(0,x.jsx)(Ee,{event:R[e%A],onBack:U,isPlaying:!1,isLast:e%A===R.length-1,setLockSwiper:S,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{},showOverlay:!1})})});try{M+e>=A-1&&(Z.current=1)}catch(d){console.log(d)}return(0,x.jsx)(x.Fragment,{})}},"event-horizontal-scroll-slide"+t.event_id)))]})})}),(0,x.jsx)(s.M5,{children:(0,x.jsx)(ge,{brandName:N,height:.04*o,width:.1*p,fontSize:.02*o})})]})})},Ye=n(6090),Xe=n(7616),Ge=n(9302),$e=n(2575);var Je=function(t){const[e,n,i,o]=(0,h.Z)(),[r]=(0,u.j1)("whatmorePrimaryColor"),[l]=(0,u.j1)("whatmoreSecondaryColor"),a="flex-end";return(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:o,height:i,backgroundColor:"whiteAlpha.200",backdropBlur:"10px",children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:a,height:"full",width:"full",children:(0,x.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",children:(0,x.jsx)(s.oM,{width:"full",ratio:o/i,children:(0,x.jsx)(s.xu,{w:"100%",h:"100%",bgGradient:"linear(to-br, "+r+", gray, "+l+")"})})})}),(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:a,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{padding:"2px",margin:"5px",borderRadius:"md",backgroundColor:"transparent",children:(0,x.jsx)(s.oM,{width:"full",ratio:9/16,children:(0,x.jsx)(s.xu,{width:"full",height:"full",borderRadius:"md",backdropFilter:"auto",backdropBlur:"5px"})})})})]})})};var Qe=function(t){var e;const n=t.stories,i=t.onBack,o=t.onStoryCompleteCallback,a=t.isActive,c=null!==(e=t.initialEventIndex)&&void 0!==e?e:0,p=n.events;var[v,m,g,f]=(0,h.Z)();const[w,y]=(0,j.Z)(),[C]=(0,u.j1)("isInDesignMode"),[S]=(0,u.j1)("isDemoBrand"),[b]=(0,u.j1)("whatmoreShopId"),[I,k]=(0,r.useState)(!0),[_,F]=(0,u.j1)("isFirstIndicatorRenderDone"),[T,E]=(0,r.useState)(null),[P,O]=(0,r.useState)(!1),{whatmoreWidgetSourceDetails:L,whatmoreUserInfo:z}=(0,r.useContext)(V.I),[R,M]=Ae(c,p.length);function D(t){i(t)}const K=L.landingLocationType,A=L.templateType;function W(){if(!(0,u.MO)("whatmoreAllowAutoSlide"))return;R().activeIndex+1>=p.length?o("right"):(M("right"),T&&T.slideNext())}function N(t){const e=R().activeIndex;"right"==t&&e+1>=p.length||"left"==t&&e-1<0?o(t):(M(t),T&&("left"==t?T.slidePrev():T.slideNext()))}return p[R().activeIndex],(0,x.jsx)("div",{children:(0,x.jsx)(l.tq,{speed:1,slidesPerView:1,direction:"horizontal",initialSlide:0,loop:!0,height:g,width:f,watchSlidesProgress:!0,allowTouchMove:!1,onSwiper:t=>{E(t)},onSlideChange:t=>{I?k(!1):(_||F(!0),function(t){const e=(0,mt.NY)(K)+(0,mt.dS)(A)+"_"+(null===t||void 0===t?void 0:t.event_id);C||S||(async()=>{(0,d.wh)(t),(0,Ke.Tc)(b,De.Xh,De.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===z||void 0===z?void 0:z.userType)})()}(p[R().activeIndex]),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:L,event:p[R().activeIndex],productList:p[R().activeIndex].products,ctaList:p[R().activeIndex].cta}))},children:[...Array(Math.min(p.length,3)).keys()].map((e=>(0,x.jsx)(l.o5,{children:e=>{let{isActive:i,isPrev:o,isNext:r,isVisible:l,isDuplicate:d}=e;if(a){const e=i?"activeIndex":o?"prevIndex":"nextIndex",r=p[R()[e]];return(0,x.jsx)(s.Kq,{direction:"column",height:g,justifyContent:"center",children:(0,be.B6)(r)||(0,be.WJ)(r)?(0,x.jsx)(Se,{event:r,totalSiblingEvents:p.length,indexAmongSiblings:R()[e],onBack:D,isPlaying:a&&i&&l,isLast:!1,setLockSwiper:O,onVideoEndedCallback:W,progressUpdateCallback:t=>{},leftOpenSpaceClickHandler:()=>{N("left")},midOpenSpaceClickHandler:()=>{y(!w)},rightOpenSpaceClickHandler:()=>{N("right")},storyId:n.id,source:Te.j.STORY_EVENT_OPENED,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay},"shopping-video-view"+r.event_id):(0,x.jsx)(x.Fragment,{})})}return(0,x.jsx)(s.Kq,{direction:"column",height:v,justifyContent:"center",children:(0,x.jsx)(Je,{})})}},"event-story-view-slide-"+e)))})})};var tn=function(t){const e=t.onBack,n=t.eventsStories,i=t.initialStoryIndex;var[o,c,p,v]=(0,h.Z)();const[m]=(0,u.j1)("isInDesignMode"),[g]=(0,u.j1)("isDemoBrand"),[f,w]=(0,r.useState)(!0),[j,y]=(0,u.j1)("isFirstIndicatorRenderDone"),[C,S]=(0,r.useState)(!1),{setCloseClickComponent:b}=(0,r.useContext)(ln),{slideDirection:I}=(0,r.useContext)(ln),[k]=(0,u.j1)("whatmoreShopId"),[_,F]=Ae(i,n.length),[T,E]=We("horizontal",50),[P]=Ne("vertical",30),O=t.eventIndex,[L,z]=(0,r.useState)(!1),[R,M]=(0,r.useState)(null),{whatmoreWidgetSourceDetails:D,whatmoreUserInfo:K}=(0,r.useContext)(V.I);function A(){z(!1)}function W(t){A(),setTimeout((()=>{e(t)}),500)}(0,r.useEffect)((()=>(z(!0),()=>{})),[]),b(W);const N=D.landingLocationType,Z=D.templateType;function U(t){R&&(0,u.MO)("whatmoreAllowAutoSlide")&&(F(t),"right"==t?R.slideNext():R.slidePrev())}function B(t,e){U(e)}return(0,x.jsx)(Oe(),{isOpen:L,onAfterOpen:function(){},onRequestClose:A,overlayClassName:"whatmore-modal",className:"whatmore-modal-content",ariaHideApp:!1,children:(0,x.jsx)("div",{style:{height:window.innerHeight,width:window.innerWidth,backgroundColor:"#00000088"},onTouchStart:t=>{T(t)},onTouchEnd:t=>{const e=E(t);e&&B(0,e)},onWheel:t=>{P(t,(t=>{B(0,t)}))},children:(0,x.jsx)(l.tq,{speed:1,slidesPerView:1,direction:"horizontal",modules:[a.SH,a.Gk],initialSlide:i,loop:n.length>1,height:window.innerHeight,width:window.innerWidth,watchSlidesProgress:!0,onSwiper:t=>{var e,i;M(t),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:D,event:n[_().activeIndex].events[0],productList:null===(e=n[_().activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(i=n[_().activeIndex].events[0])||void 0===i?void 0:i.cta})},onSlideChange:t=>{var e,i;f?w(!1):(!function(t){const e=(0,mt.NY)(N)+(0,mt.dS)(Z)+"_"+(null===t||void 0===t?void 0:t.event_id);m||g||(async()=>{(0,d.wh)(t),(0,Ke.Tc)(k,De.Xh,De.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===K||void 0===K?void 0:K.userType)})()}(n[_().activeIndex].events[0]),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:D,event:n[_().activeIndex].events[0],productList:null===(e=n[_().activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(i=n[_().activeIndex].events[0])||void 0===i?void 0:i.cta}))},allowTouchMove:!1,cubeEffect:{shadow:!0,slideShadows:!0,shadowOffset:20,shadowScale:.94},children:[...Array(Math.min(n.length,3)).keys()].map((t=>(0,x.jsx)(l.o5,{children:t=>{let{isActive:e,isPrev:r,isNext:l,isVisible:a,isDuplicate:d}=t;const c=e?"activeIndex":r?"prevIndex":"nextIndex";return(0,x.jsx)(s.Kq,{direction:"column",height:o,justifyContent:"center",children:(0,x.jsx)(Qe,{stories:n[_()[c]],onBack:W,isActive:e&&a,isNext:l,isPrev:r,onStoryCompleteCallback:U,nextStories:n[_().nextIndex],prevStories:n[_().prevIndex],initialEventIndex:i==_()[c]?O:0},"event-story-view-"+n[_()[c]].id)})}},"event-vertical-scroll-slide-"+t)))})})})},en=n(4892);var nn=function(t){var e,n,i,[o,l,a,d]=(0,h.Z)();const[c]=(0,u.j1)("whatmorePrimaryColor"),[p]=(0,u.j1)("whatmoreSecondaryColor"),v=t.event,m=(t.onBack,r.useRef(),null!==(e=t.showPausedVideo)&&void 0!==e&&e),f=null!==(n=t.heightFactor)&&void 0!==n?n:1,w="flex-end";return d*=null!==(i=t.widthFactor)&&void 0!==i?i:1,a*=f,(0,x.jsx)(s.M5,{children:(0,x.jsxs)(s.xu,{width:d,height:a,children:[(0,x.jsx)(s.Kq,{direction:"column",justifyContent:w,height:"full",width:"full",children:(0,x.jsx)(s.xu,{children:(0,x.jsx)(s.oM,{width:"full",ratio:9/16,children:m?(0,be.B6)(v)||(0,be.WJ)(v)?(0,x.jsx)(en.Z,{height:"100%",width:"100%",url:v.thumbnail_image,isPlaying:!1,pauseFromPlayTimeInMs:1e3,event:v}):(0,x.jsx)(g.Ee,{width:"full",height:"full",src:v.thumbnail_image,objectFit:"cover",borderRadius:"lg"}):(0,x.jsx)(s.xu,{w:"100%",h:"100%",bgGradient:"linear(to-br, "+c+", gray, "+p+")"})})})}),(0,x.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:w,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,x.jsx)(s.xu,{children:(0,x.jsx)(s.oM,{width:"full",ratio:9/16,children:(0,x.jsx)(s.xu,{width:"full",height:"full",backgroundColor:"blackAlpha.400"})})})})]})})};var on=function(t){var e,n,[i,o,c,p]=(0,h.Z)();const[v]=(0,u.j1)("isInDesignMode"),[m]=(0,u.j1)("isDemoBrand"),[g,f]=(0,u.j1)("isFirstIndicatorRenderDone"),[w,j]=(0,r.useState)(0!=t.eventIndex),{setCloseClickComponent:y}=(0,r.useContext)(ln),[C,S]=(0,r.useState)(!1),[b]=(0,u.j1)("whatmoreShopId"),{whatmoreWidgetSourceDetails:I,whatmoreUserInfo:k}=(0,r.useContext)(V.I),[_,F]=(0,r.useState)(!1),[T,E]=(0,r.useState)(null);function P(){F(!1)}t.events;const L=t.eventIndex,z=t.onBack,R=t.eventsStories,M=t.initialStoryIndex,D=null===(e=R[0])||void 0===e||null===(n=e.events[0])||void 0===n?void 0:n.brand;function K(t){P(),setTimeout((()=>{z(t)}),500)}(0,r.useEffect)((()=>(F(!0),()=>{})),[]),y(K);const A=I.landingLocationType,W=I.templateType;function N(t){T&&!T.isEnd&&("right"==t?T.slideNext():T.slidePrev())}const Z=parseInt(Math.min(5,R.length));return(0,x.jsx)(Ue,{show:_,closeCallback:P,customClass:"whatmore-landscape-modal-stories-view",children:(0,x.jsxs)(s.Kq,{direction:"column",width:window.innerWidth,height:window.innerHeight,justifyContent:"center",aligntItems:"center",backgroundColor:"blackAlpha.800",children:[(0,x.jsx)(s.M5,{children:(0,x.jsx)(s.xu,{height:"fit-content",width:p*Z,children:(0,x.jsxs)(l.tq,{onInit:t=>{var e,n;E(t),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:I,event:R[t.activeIndex].events[0],productList:null===(e=R[t.activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(n=R[t.activeIndex].events[0])||void 0===n?void 0:n.cta})},slidesPerView:Z,centeredSlides:!0,allowTouchMove:!1,initialSlide:M,modules:[a.lI,a.W_,a.Gk],navigation:Z>=5,effect:"coverflow",coverflowEffect:{rotate:-8,stretch:Math.floor(.22*c),depth:100,scale:.7,modifier:1,slideShadows:!1},height:"fit-content",width:p*Z,watchSlidesProgress:!0,onSlideChange:t=>{var e,n;w?j(!1):(g||f(!0),function(t){const e=(0,mt.NY)(A)+(0,mt.dS)(W)+"_"+(null===t||void 0===t?void 0:t.event_id);v||m||(async()=>{(0,d.wh)(t),(0,Ke.Tc)(b,De.Xh,De.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===k||void 0===k?void 0:k.userType)})()}(R[t.activeIndex].events[0]),(0,q.GF)({userInteractionType:H.K.EVENT_VIEW,widgetSourceDetails:I,event:R[t.activeIndex].events[0],productList:null===(e=R[t.activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(n=R[t.activeIndex].events[0])||void 0===n?void 0:n.cta}))},mousewheel:{invert:!1,thresholdDelta:20},children:[R.length>2&&(0,x.jsx)("div",{className:"whatmore-shopping-close-button",children:(0,x.jsx)(O,{onCloseCallback:z})}),R.map(((t,e)=>(0,x.jsx)(l.o5,{children:n=>{let{isActive:i,isPrev:o,isNext:r,isVisible:l,isDuplicate:a}=n;if(i){const n=1;return(0,x.jsx)(s.Kq,{direction:"column",height:c,width:p*n,justifyContent:"center",marginLeft:"auto",marginRight:"auto",children:(0,x.jsx)(s.xu,{borderRadius:"xl",overflow:"hidden",backgroundColor:"transparent",boxShadow:"dark-lg",children:(0,x.jsx)(Qe,{stories:t,onBack:K,isActive:i&&l,isNext:!1,isPrev:!1,onStoryCompleteCallback:N,initialEventIndex:M==e?L:0,showCloseOverlay:(null===R||void 0===R?void 0:R.length)<=2},"event-story-view-"+t.id)})})}return o||r?(0,x.jsx)(s.Kq,{direction:"column",height:c,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{T.slideTo(e,300)},children:(0,x.jsx)(s.xu,{borderRadius:"xl",overflow:"hidden",backgroundColor:"transparent",boxShadow:"dark-lg",children:(0,x.jsx)(nn,{showPausedVideo:!0,event:R[e].events[0],onBack:K,isPlaying:!1,setLockSwiper:S})})}):(0,x.jsx)(x.Fragment,{})}},"event-horizontal-scroll-slide-"+e)))]})})}),(0,x.jsx)(s.M5,{children:(0,x.jsx)(ge,{brandName:D,height:.04*c,width:.1*p,fontSize:.02*c})})]})})};const rn=(0,$e.Z)({key:"whatmore-css-sv"}),ln=(0,r.createContext)({isIOS:!1,totalEvents:0,closeClickComponent:null,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:"vertical",showSwipeIndicator:!0});var an=function(t){var e,n;const[i,o,l]=(0,pe.Z)(),[a]=(0,u.j1)("whatmoreShopId"),{whatmoreRootId:d}=(0,r.useContext)(V.I),{whatmoreIsStoriesTemplate:s}=(0,r.useContext)(V.I);var h=t.events,p=t.index,v=t.onBack,m=t.eventsStories,g=t.initialStoryIndex,f=(0,c.cX2)(a),w=(h[p],"portrait"===i?null!==(e=t.slideDirection)&&void 0!==e?e:"vertical":null!==(n=t.slideDirection)&&void 0!==n?n:h.length>1?"horizontal":"vertical"),j="portrait"===i?!(0,c.h6H)(a)&&!s:(0,c.n89)(a);return h[p],(0,r.useLayoutEffect)((()=>{(0,c.TLG)(a)&&(window.location.href.includes(f)?history.replaceState(null,"","#"+f):history.pushState(null,"","#"+f),window.addEventListener("popstate",(()=>{window.location.href.includes(f)||v()})))}),[]),delete Xe.ZP.styles.global,s?(0,x.jsx)(Ge.C,{value:rn,children:(0,x.jsx)(Ye.x,{theme:Xe.ZP,cssVarsRoot:d,resetCSS:!1,children:(0,x.jsx)(ln.Provider,{value:{isIOS:(0,Ie.KE)(),totalEvents:h.length,closeClickComponent:v,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:w,showSwipeIndicator:j},children:"portrait"===i?(0,x.jsx)(tn,{eventsStories:m,initialStoryIndex:g,onBack:v,eventIndex:p}):(0,c.Bbr)(a)?(0,x.jsx)(on,{eventsStories:m,initialStoryIndex:g,onBack:v,eventIndex:p}):(0,x.jsx)(tn,{eventsStories:m,initialStoryIndex:g,onBack:v,eventIndex:p})})})}):(0,x.jsx)(Ge.C,{value:rn,children:(0,x.jsx)(Ye.x,{theme:Xe.ZP,cssVarsRoot:d,resetCSS:!1,children:(0,x.jsx)(ln.Provider,{value:{isIOS:(0,Ie.KE)(),totalEvents:h.length,closeClickComponent:v,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:w,showSwipeIndicator:j},children:"portrait"===i?(0,x.jsx)(He,{events:h,eventIndex:p,onBack:v}):(0,x.jsx)(Be,{events:h,eventIndex:p,onBack:v})})})})}},9316:function(t,e,n){n.d(e,{mT:function(){return o}});var i=n(686);const o=`\n ${i.F4`
|
|
77
77
|
0% { transform: scale(1); }
|
|
78
78
|
50%, { transform: scale(0.95); }
|
|
79
79
|
100% { transform: scale(1); }
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[380],{1332:function(e,t,n){var i=n(7313),r=(n(8743),n(7753)),o=n(5254),a=n(6417);t.Z=function(e){return(0,i.useEffect)((()=>{const e=(0,o.oo)((0,r.MO)("whatmoreSecondaryColor"));!function(e,t,n,i){const r=`rgba(${e},${t},${n},${i})`,o=`\n @keyframes whatmore-loading-indicator-keyframe {\n 0%,\n 100% {\n box-shadow: 0em -2.6em 0em 0em ${r}, 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7);\n }\n 12.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.7), 1.8em -1.8em 0 0em ${r}, 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5);\n }\n 25% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.5), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 2.5em 0em 0 0em ${r}, 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 37.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 1.75em 1.75em 0 0em ${r}, 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 50% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.7), 0em 2.5em 0 0em ${r}, -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 62.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.5), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -1.8em 1.8em 0 0em ${r}, -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 75% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -2.6em 0em 0 0em ${r}, -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2);\n }\n 87.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${n}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${n}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${n}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${n}, 0.5), -2.6em 0em 0 0em rgba(${e}, ${t}, ${n}, 0.7), -1.8em -1.8em 0 0em ${r};\n }\n }\n `,a=document.createElement("style");a.type="text/css",a.innerHTML=o,document.head.appendChild(a)}(e[0],e[1],e[2],.2)}),[]),(0,a.jsx)(a.Fragment,{children:(0,a.jsx)("span",{className:"whatmore-loading-indicator"})})}},3175:function(e,t,n){var i=n(1332),r=n(5180),o=n(6417);t.Z=function(e){var t,n;const a=null!==(t=e.height)&&void 0!==t?t:"100%",s=null!==(n=e.width)&&void 0!==n?n:"100%";return(0,o.jsxs)("div",{style:{width:s,height:a,overflow:"hidden",minHeight:a,minWidth:s},children:[(0,o.jsx)(r.Z,{height:a,width:s}),(0,o.jsx)("div",{style:{display:"flex",flexFlow:"column nowrap",justifyContent:"center",alignContent:"center",width:"100%",height:"100%",position:"relative",zIndex:1,bottom:"100%",className:"whatmore-ios-css-relative-fix"},children:(0,o.jsx)("div",{style:{display:"flex",flexFlow:"row nowrap",justifyContent:"center",width:"100%",height:"fit-content"},children:(0,o.jsx)(i.Z,{})})})]})}},5180:function(e,t,n){var i=n(6417);t.Z=function(e){var t,n,r;const o=null!==(t=e.height)&&void 0!==t?t:"100%",a=null!==(n=e.width)&&void 0!==n?n:"100%",s=null!==(r=e.borderRadius)&&void 0!==r?r:"10px";return(0,i.jsx)("div",{style:{height:o,width:o,borderRadius:s,overflow:"hidden",minHeight:o,minWidth:a,maxHeight:o,maxWidth:a},children:(0,i.jsx)("div",{style:{minHeight:o,minWidth:a},height:"100%",width:"100%",className:"whatmore-shimmer"})})}},2887:function(e,t,n){var i=n(7313),r=n(3175),o=n(6417);t.Z=function(e){var t,n,a;const[s,d]=(0,i.useState)(!1),m=i.useRef(0),l=(0,i.useRef)(null),h=null!==(t=e.timeUpdateCallback)&&void 0!==t?t:()=>{},c=null!==(n=e.height)&&void 0!==n?n:"100%",u=null!==(a=e.width)&&void 0!==a?a:"100%";return(0,i.useEffect)((()=>{m.current=0;const e=setInterval((()=>{m.current=m.current+.03,l.current&&h(m.current,5),m.current>=5&&(m.current=0)}),30);return()=>{clearInterval(e)}}),[e.isPlaying]),(0,o.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",width:u,height:c,overflow:"hidden"},children:[(0,o.jsx)("div",{style:{width:s?"100%":"0px",height:s?"100%":"0px"},children:(0,o.jsx)("img",{ref:l,src:e.url,style:{objectFit:"cover",height:c,width:u,backgroundColor:"white"},alt:"image player",onLoad:()=>{d(!0)}})}),s?(0,o.jsx)(o.Fragment,{}):(0,o.jsx)(r.Z,{width:u,height:c})]})}},4892:function(e,t,n){n.d(t,{Z:function(){return u}});var i=n(7313),r=n(3933),o=n(868),a=n(8984),s=n(7300),d=n(2887),m=n(4862),l=n(7753),h=n(6417);var c=function(e){var t,n;const o=(0,i.useRef)(null),[s,d,c]=(0,r.YD)({triggerOnce:!0}),u=(0,l.MO)("whatmoreShopId"),p=null!==(t=e.height)&&void 0!==t?t:"100%",$=null!==(n=e.width)&&void 0!==n?n:"100%";return(0,i.useEffect)((()=>{o.current&&(e.isPlaying?o.current.play():((m.G6||(0,a.gE)())&&o.current.play(),o.current.pause()))}),[e.isPlaying,d]),(0,h.jsx)("div",{ref:s,style:{width:p,height:$,overflow:"hidden"},children:d?(0,h.jsx)("video",{ref:o,className:"whatmore-video-player-muted",width:$,height:p,preload:"metadata",loop:!0,playsInline:!0,poster:e.isPlaying&&"STRTFEDEDAP"!==u&&"STRY2V4XO5L"!==u?e.url:e.poster,muted:!0,src:e.url,style:{backgroundColor:"white"}}):(0,h.jsx)("div",{width:$,height:p,ref:e=>{e&&e.style.setProperty("display","block","important")}})})};var u=function(e){var t,n,m,l;const[u,p,$]=(0,r.YD)({triggerOnce:!0});if((0,s.WJ)(e.event))return(0,h.jsx)(d.Z,{height:e.height,width:e.width,url:e.url,isPlaying:e.isPlaying,timeUpdateCallback:e.timeUpdateCallback});const g=null!==(t=e.pauseFromPlayTimeInMs)&&void 0!==t?t:200;var f;if((0,a.KE)())return(0,h.jsx)(c,{height:"100%",width:"100%",poster:null===e||void 0===e||null===(f=e.event)||void 0===f?void 0:f.poster_image,url:(0,o.V)(e.url),isPlaying:e.isPlaying,pauseFromPlayTimeInMs:g});const x=(0,i.useRef)(null),b=null!==(n=e.height)&&void 0!==n?n:"100%",w=null!==(m=e.width)&&void 0!==m?m:"100%";return(0,i.useEffect)((()=>{x.current&&(e.isPlaying?x.current.play():x.current.pause())}),[e.isPlaying,p]),(0,h.jsx)("div",{ref:u,style:{width:b,height:w,overflow:"hidden"},children:p?(0,h.jsx)("video",{ref:x,className:"whatmore-video-player-muted",width:w,height:b,preload:"metadata",loop:!0,playsInline:!0,muted:!0,src:(0,o.V)(e.url),poster:null===e||void 0===e||null===(l=e.event)||void 0===l?void 0:l.poster_image,style:{backgroundColor:"white"}}):(0,h.jsx)("div",{width:w,height:b,ref:e=>{e&&e.style.setProperty("display","block","important")}})})}},5380:function(e,t,n){n.d(t,{Z:function(){return x}});var i=n(4959),r=n(7313),o=n(4892),a=n(6805),s=n(7753),d=n(9821);var m=function(e){const[t,n,i,r,o]=(0,d.Z)(),[m]=(0,s.j1)("whatmoreEmbedAppVideoPlayerSizePortrait"),[l]=(0,s.j1)("whatmoreEmbedAppVideoPlayerSizeLandscape"),h=o[a.YP]===a.$w?l/100:m/100*1.2;return[t*h,n*h,o]},l=n(9723),h=n(9461),c=n.n(h),u=n(1195),p=n(7108),$=(n(7244),n(123),n(9854)),g=n(8811),f=n(6417);var x=function(e){var t;const n=r.useRef(null);var[d,h,x]=m();const{whatmoreUITheme:b}=(0,r.useContext)(g.I),[w]=(0,s.j1)("whatmoreEmbedAppVideoTitle"),[v]=(0,s.j1)("whatmoreEmbedAppPositionPortrait"),[y]=(0,s.j1)("whatmoreEmbedAppHorizontalPaddingPortrait"),[j]=(0,s.j1)("whatmoreEmbedAppVerticalPaddingPortrait"),[z]=(0,s.j1)("whatmoreEmbedAppPositionLandscape"),[P]=(0,s.j1)("whatmoreEmbedAppHorizontalPaddingLandscape"),[E]=(0,s.j1)("whatmoreEmbedAppVerticalPaddingLandscape"),C=(0,s.MO)("whatmoreShopId");var I=v,k=y,S=j;x[a.YP]===a.$w&&(I=z,k=P,S=E);const[A,Z]=(0,r.useState)(["initial",window.pageYOffset]),[R,Y]=(0,r.useState)(!1),F=null!==(t=e.isSpotlight)&&void 0!==t&&t,N=x[a.YP]===a.$w?.7*(0,$.zGA)(C):(0,$.zGA)(C),L=F?N:1;d*=L,h*=L;const M=F?(0,$.G0o)(C):I,O=F?(0,$.X8j)(C):(0,$.lVn)(C),[V,D]=(0,r.useState)(!F&&(0,$.eXi)(C));function T(e,t){Z(e),e[1]<=100?Y(!1):t!=R&&(Y(t),D(!1))}(0,r.useEffect)((()=>{let e=window.pageYOffset,t=!1;const n=()=>{const n=window.pageYOffset;Math.abs(n-e)<100||(T([n>e?"scrolled-down":"scrolled-up",n],!0),e=n>0?n:0),t=!1},i=()=>{t||(window.requestAnimationFrame(n),t=!0)};return window.addEventListener("scroll",i),()=>window.removeEventListener("scroll",i)}),[A]),(0,i.O3)({ref:n,handler:()=>{T(["scrolled-up",A[1]],!0)}});const _=e.event,q=e.inVideoClick,B=e.closeClick,H=.3*h,W=.6*h,U=.1*h,K=.1*(.5*h),G="round"==b?"10px":"0px",X=(0,$.Z$A)(C);var Q=!1,J=0,ee=0;function te(e){Q=e}return(0,f.jsx)("div",{children:V&&!O?(0,f.jsx)(f.Fragment,{}):R&&O?(0,f.jsx)("div",{style:"left"===M?{left:"1px",bottom:F?(0,$.vnu)(C)+"px":S+"px",position:"fixed",zIndex:X}:{right:"5px",bottom:F?(0,$.vnu)(C)+"px":S+"px",position:"fixed",zIndex:X},children:(0,f.jsxs)("div",{onClick:()=>{T(["initial",A[1]],!1)},style:{margin:"1px",width:h+"px",height:d+"px"},className:"left"===M?"whatmore-ultraminimized-video-view-left":"whatmore-ultraminimized-video-view-right",children:[(0,f.jsx)("div",{style:{boxShadow:"0px 0px 10px 3px #B0B0B0",borderRadius:G,overflow:"hidden"},children:(0,f.jsx)("div",{style:{width:"100%",height:"100%",aspectRatio:9/16},children:(0,f.jsx)(o.Z,{url:_.thumbnail_image,isPlaying:!1,event:_})})}),(0,f.jsx)("div",{style:{position:"relative",zIndex:1,bottom:"100%",width:"100%",height:"100%"},children:(0,f.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",height:"100%"},children:[(0,f.jsx)("div",{style:{display:"flex",flexFlow:"row nowrap",justifyContent:"flex-end",width:"100%",height:"fit-content"},children:(0,f.jsx)("div",{className:"whatmore-ultraminimized-content-scale-out",children:(0,f.jsx)(u.Z,{sx:{filter:"drop-shadow(0 0 15px black);",color:"white",fontSize:H+"px"},style:{position:"relative",zIndex:1,left:K+"px",bottom:K+"px"},onClick:B})})}),(0,f.jsx)("div",{style:{height:"100%",display:"flex",flexFlow:"column nowrap",alignItems:"center",justifyContent:"center"},children:(0,f.jsx)(p.Z,{sx:{color:"white",fontSize:2*H+"px",filter:"drop-shadow(0 0 15px black);"}})})]})})]})}):(0,f.jsx)(c(),{nodeRef:n,cancel:".activate-button,.close-btn",defaultClassName:"whatmore-react-draggable",defaultClassNameDragging:"whatmore-react-draggable-dragging",defaultClassNameDragged:"whatmore-react-draggable-dragged",bounds:"html",onStart:(e,t)=>{var n,i;n=t.x,i=t.y,J=n,ee=i},onDrag:(e,t)=>{te(!0)},onStop:(e,t)=>{Q&&(Math.abs(t.x-J)>5||Math.abs(t.y-ee)>5)?te(!1):q(_)},children:(0,f.jsx)("div",{ref:n,style:"left"===M?{left:F?(0,$.$II)(C)+"px":k+"px",bottom:F?(0,$.vnu)(C)+"px":S+"px",position:"fixed",zIndex:X}:{right:F?(0,$.$II)(C)+"px":k+"px",bottom:F?(0,$.vnu)(C)+"px":S+"px",position:"fixed",zIndex:X},children:(0,f.jsxs)("div",{style:Object.assign({},{boxSizing:"border-box",margin:"1px",width:h+"px",height:d+"px"}),className:"left"===M?"whatmore-minimized-video-view-left":"whatmore-minimized-video-view-right",children:[(0,f.jsx)("div",{style:{boxShadow:"0px 0px 10px 3px #B0B0B0",borderRadius:G,overflow:"hidden",position:"relative"},children:(0,f.jsx)("div",{style:{width:"100%",height:"100%",aspectRatio:9/16},children:(0,f.jsx)(o.Z,{url:_.thumbnail_image,isMuted:!0,isPlaying:!0,event:_})})}),(0,f.jsx)("div",{style:{position:"relative",zIndex:1,bottom:"100%",width:"100%",height:"100%"},children:(0,f.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",justifyContent:"space-between",height:"100%"},children:[(0,f.jsx)("div",{style:{display:"flex",flexFlow:"row nowrap",justifyContent:"flex-end",width:"100%",height:"fit-content"},children:(0,f.jsx)(u.Z,{className:"close-btn",sx:{filter:"drop-shadow(0 0 15px black);",color:"white",fontSize:H+"px"},onClick:B,style:{position:"relative",zIndex:1,left:U+"px",bottom:U+"px"}})}),(0,f.jsx)("div",{style:{marginLeft:"auto",marginRight:"auto"},children:(0,f.jsx)(l.Z,{sx:{color:(0,$.Ya_)(C),fontSize:W+"px",filter:"drop-shadow(0 0 15px black);"}})}),(0,f.jsx)("div",{style:{paddingLeft:"2px",paddingRight:"2px",borderBottomLeftRadius:G,borderBottomRightRadius:G,backgroundImage:w?"linear-gradient(to bottom, rgba(0,0,0,0), rgba(0,0,0,0.2), rgba(0,0,0,0.6))":""},children:(0,f.jsxs)("p",{style:{textAlign:"center",color:"white",fontFamily:"Sans-serif",fontWeight:"semi-bold",fontSize:.4*H+"px",margin:0,padding:0,lineHeight:"110%"},children:["\xa0",w]})})]})})]})})})})}},868:function(e,t,n){n.d(t,{V:function(){return s}});var i=n(9854),r=n(7753);const o={"https://d3syezql093hs1.cloudfront.net":"https://whatmore-brand-video-assets.azureedge.net","https://d2r0bijhs9mx1s.cloudfront.net":"https://whatmore-brand-thumbnail-video-assets.azureedge.net","https://d2oouab8j9eigo.cloudfront.net":"https://whatmore-brand-story-assets.azureedge.net","https://d28nus7q7qajdn.cloudfront.net":"https://whatmore-video-assets.azureedge.net","https://d1zl4k1t5o4s75.cloudfront.net":"https://whatmore-brand-video-assets-720p.azureedge.net"},a={"https://d3syezql093hs1.cloudfront.net":"https://whatmore-brand-video-assets.b-cdn.net","https://d2r0bijhs9mx1s.cloudfront.net":"https://whatmore-brand-thumbnail-video-assets.b-cdn.net","https://d2oouab8j9eigo.cloudfront.net":"https://whatmore-brand-story-assets.b-cdn.net","https://d28nus7q7qajdn.cloudfront.net":"https://whatmore-video-assets-old.b-cdn.net","https://d1zl4k1t5o4s75.cloudfront.net":"https://whatmore-brand-video-assets-720p.b-cdn.net"},s=function(e){const t=(0,r.MO)("whatmoreShopId");if(!e)return e;if(e.startsWith("https://cdn.shopify.com"))return e;if("AWSCDN"==(0,i.zpr)(t))return e;if("AZURECDN"==(0,i.zpr)(t)){if(e.includes(".azureedge.net"))return e;if(e.includes(".cloudfront.net")){for(const t of Object.keys(o))if(e.includes(t))return e.replace(t,o[t]);return e}}if("BUNNYCDN"==(0,i.zpr)(t)){if(e.includes(".b-cdn.net"))return e;if(e.includes(".cloudfront.net")){for(const t of Object.keys(a))if(e.includes(t))return e.replace(t,a[t]);return e}}return e}},6805:function(e,t,n){n.d(t,{$I:function(){return s},$w:function(){return m},AK:function(){return o},AL:function(){return a},YP:function(){return r},me:function(){return i},rE:function(){return d}});const i="device_type",r="device_mode",o="mobile",a="tablet",s="desktop",d="portrait",m="landscape"},9821:function(e,t,n){var i=n(6367),r=n(7753),o=n(8866),a=n(6805);t.Z=function(e){const[t,n,s]=(0,o.Z)(),[d]=(0,r.j1)("whatmoreLandscapePadding"),[m]=(0,r.j1)("whatmoreVideoTileSize"),[l]=(0,r.j1)("whatmoreVideoTileSizePortrait"),h=(0,i.useMediaQuery)({query:"(min-width: 1025px)"}),c=(0,i.useMediaQuery)({query:"(min-width: 481px)"}),u="portrait"==t?l:m,p=!("portrait"!=t||!c),$=u/100*1.3*.5,g=u/100;var f=Math.min(s,n),[x,b,w,v]=[.6*f*(16/9),.6*f,1.4,0];function y(e){return Math.round(10*e)/10}var j={DEVICE_TYPE:a.AK,DEVICE_MODE:a.rE};if(h){const e=b*$,t=x*$;[x,b,w,v]=[t,e,(s-2*d)/(1.1*e),d],j[a.me]=a.$I,j[a.YP]=a.$w}else if(p){var z=.8*b,P=.8*x;"portrait"==t?(z*=g,P*=g,[x,b,w,v]=[P,z,y(s/(1.2*z)),0],j[a.me]=a.AL,j[a.YP]=a.rE):([x,b,w,v]=[P,z,(s-2*d)/(1.1*z),d],j[a.me]=a.AL,j[a.YP]=a.$w)}else{z=b,P=x;"portrait"==t?(z=z*g*.9,P=P*g*.9,[x,b,w,v]=[P,z,y(s/(1.15*z)),0],j[a.me]=a.AK,j[a.YP]=a.rE):(z=.7*b,P=.7*x,[x,b,w,v]=[P,z,(s-2*d)/(1.1*z),d],j[a.me]=a.AK,j[a.YP]=a.$w)}return[x,b,w,v,j]}},8743:function(){},123:function(){},7244:function(){}}]);
|