whatmore-react-assets 1.0.1060 → 1.0.1061
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/{950.2283a32d.chunk.js → 145.fe264c73.chunk.js} +1 -1
- package/static/js/{818.7b89f2b0.chunk.js → 818.c8731ea4.chunk.js} +1 -1
- package/static/js/{688.055f2e97.chunk.js → 824.adba009d.chunk.js} +1 -1
- package/static/js/app-main.bb5be476.chunk.js +1 -0
- package/static/js/{465.073e7e2b.chunk.js → atc-with-form.c6e794f2.chunk.js} +1 -1
- package/static/js/{150.355628ac.chunk.js → banner-template-a.0352962b.chunk.js} +1 -1
- package/static/js/{436.695d073c.chunk.js → carousel-template-a.593e5436.chunk.js} +1 -1
- package/static/js/{891.fd24e3dd.chunk.js → carousel-template-b.1a388616.chunk.js} +1 -1
- package/static/js/{678.b0bdb0cf.chunk.js → carousel-template-f.0377ce09.chunk.js} +2 -2
- package/static/js/{299.b5556032.chunk.js → carousel-template-feed.2a46447b.chunk.js} +2 -2
- package/static/js/{530.344f90c9.chunk.js → carousel-template-view-more.6fee8817.chunk.js} +1 -1
- package/static/js/{622.58ace99c.chunk.js → collections-template-a.a32aa9b7.chunk.js} +1 -1
- package/static/js/collections-template-b.fe4cdbbf.chunk.js +1 -0
- package/static/js/{708.7c0863ae.chunk.js → collections-template-c.660b920a.chunk.js} +1 -1
- package/static/js/collections-template-stories.407b3524.chunk.js +1 -0
- package/static/js/{582.74949624.chunk.js → event-click-main.bf24531c.chunk.js} +1 -1
- package/static/js/{836.ce78bb59.chunk.js → event-click-product.60b5a8fa.chunk.js} +1 -1
- package/static/js/event-click-spotlight.929fb915.chunk.js +1 -0
- package/static/js/{236.edc261dc.chunk.js → homepage-carousel-view.ab3a8fe0.chunk.js} +1 -1
- package/static/js/product-page-view.e35c4c9d.chunk.js +1 -0
- package/static/js/{824.52974fed.chunk.js → recommended-carousel.9a69fdec.chunk.js} +2 -2
- package/static/js/{692.e97ba156.chunk.js → spotlight-view.03d41d9a.chunk.js} +1 -1
- package/static/js/{580.68a1a16f.chunk.js → stories-template-a.ff47c763.chunk.js} +1 -1
- package/whatmore.js +2 -2
- package/static/js/440.fbb6b522.chunk.js +0 -1
- package/static/js/74.733f2e9a.chunk.js +0 -1
- package/static/js/77.8f57a05d.chunk.js +0 -1
- package/static/js/84.8847b6ff.chunk.js +0 -1
- package/static/js/965.ea0fd29e.chunk.js +0 -1
- /package/static/css/{465.1c72edff.chunk.css → atc-with-form.1c72edff.chunk.css} +0 -0
- /package/static/css/{150.4e431eee.chunk.css → banner-template-a.4e431eee.chunk.css} +0 -0
- /package/static/css/{436.59976cb2.chunk.css → carousel-template-a.59976cb2.chunk.css} +0 -0
- /package/static/css/{891.1672d707.chunk.css → carousel-template-b.1672d707.chunk.css} +0 -0
- /package/static/css/{678.599c1ca5.chunk.css → carousel-template-f.599c1ca5.chunk.css} +0 -0
- /package/static/css/{299.e2240c87.chunk.css → carousel-template-feed.e2240c87.chunk.css} +0 -0
- /package/static/css/{530.e2240c87.chunk.css → carousel-template-view-more.e2240c87.chunk.css} +0 -0
- /package/static/css/{622.dc868ab3.chunk.css → collections-template-a.dc868ab3.chunk.css} +0 -0
- /package/static/css/{708.dc868ab3.chunk.css → collections-template-b.dc868ab3.chunk.css} +0 -0
- /package/static/css/{84.dc868ab3.chunk.css → collections-template-c.dc868ab3.chunk.css} +0 -0
- /package/static/css/{965.dc868ab3.chunk.css → collections-template-stories.dc868ab3.chunk.css} +0 -0
- /package/static/css/{582.3373f4ca.chunk.css → event-click-main.3373f4ca.chunk.css} +0 -0
- /package/static/css/{77.1c72edff.chunk.css → event-click-product.1c72edff.chunk.css} +0 -0
- /package/static/css/{836.1c72edff.chunk.css → event-click-spotlight.1c72edff.chunk.css} +0 -0
- /package/static/css/{692.87a3bb51.chunk.css → product-page-view.87a3bb51.chunk.css} +0 -0
- /package/static/css/{74.87a3bb51.chunk.css → spotlight-view.87a3bb51.chunk.css} +0 -0
- /package/static/css/{580.ff6f5f73.chunk.css → stories-template-a.ff6f5f73.chunk.css} +0 -0
package/package.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[950],{1332:function(e,t,r){var n=r(7313),i=(r(8743),r(7753)),m=r(5254),a=r(6417);t.Z=function(e){return(0,n.useEffect)((()=>{const e=(0,m.oo)((0,i.MO)("whatmoreSecondaryColor"));!function(e,t,r,n){const i=`rgba(${e},${t},${r},${n})`,m=`\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}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.5), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.7);\n }\n 12.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.7), 1.8em -1.8em 0 0em ${i}, 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.5);\n }\n 25% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.5), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.7), 2.5em 0em 0 0em ${i}, 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 37.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.5), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.7), 1.75em 1.75em 0 0em ${i}, 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 50% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.5), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.7), 0em 2.5em 0 0em ${i}, -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 62.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.5), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.7), -1.8em 1.8em 0 0em ${i}, -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 75% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.5), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.7), -2.6em 0em 0 0em ${i}, -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 87.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.5), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.7), -1.8em -1.8em 0 0em ${i};\n }\n }\n `,a=document.createElement("style");a.type="text/css",a.innerHTML=m,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,r){var n=r(1332),i=r(5180),m=r(6417);t.Z=function(e){var t,r;const a=null!==(t=e.height)&&void 0!==t?t:"100%",o=null!==(r=e.width)&&void 0!==r?r:"100%";return(0,m.jsxs)("div",{style:{width:o,height:a,overflow:"hidden",minHeight:a,minWidth:o},children:[(0,m.jsx)(i.Z,{height:a,width:o}),(0,m.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,m.jsx)("div",{style:{display:"flex",flexFlow:"row nowrap",justifyContent:"center",width:"100%",height:"fit-content"},children:(0,m.jsx)(n.Z,{})})})]})}},5180:function(e,t,r){var n=r(6417);t.Z=function(e){var t,r,i;const m=null!==(t=e.height)&&void 0!==t?t:"100%",a=null!==(r=e.width)&&void 0!==r?r:"100%",o=null!==(i=e.borderRadius)&&void 0!==i?i:"10px";return(0,n.jsx)("div",{style:{height:m,width:m,borderRadius:o,overflow:"hidden",minHeight:m,minWidth:a,maxHeight:m,maxWidth:a},children:(0,n.jsx)("div",{style:{minHeight:m,minWidth:a},height:"100%",width:"100%",className:"whatmore-shimmer"})})}},2887:function(e,t,r){var n=r(7313),i=r(3175),m=r(6417);t.Z=function(e){var t,r,a;const[o,s]=(0,n.useState)(!1),d=n.useRef(0),l=(0,n.useRef)(null),u=null!==(t=e.timeUpdateCallback)&&void 0!==t?t:()=>{},c=null!==(r=e.height)&&void 0!==r?r:"100%",h=null!==(a=e.width)&&void 0!==a?a:"100%";return(0,n.useEffect)((()=>{d.current=0;const e=setInterval((()=>{d.current=d.current+.03,l.current&&u(d.current,5),d.current>=5&&(d.current=0)}),30);return()=>{clearInterval(e)}}),[e.isPlaying]),(0,m.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",width:h,height:c,overflow:"hidden"},children:[(0,m.jsx)("div",{style:{width:o?"100%":"0px",height:o?"100%":"0px"},children:(0,m.jsx)("img",{ref:l,src:e.url,style:{objectFit:"cover",height:c,width:h,backgroundColor:"white"},alt:"image player",onLoad:()=>{s(!0)}})}),o?(0,m.jsx)(m.Fragment,{}):(0,m.jsx)(i.Z,{width:h,height:c})]})}},4892:function(e,t,r){r.d(t,{Z:function(){return $}});var n=r(7313),i=r(3933),m=r(868),a=r(8984),o=r(7300),s=r(2887),d=r(4862),l=r(7753),u=r(342),c=(r(9854),r(6417));var h=function(e){var t,r;const m=(0,n.useRef)(null),[o,s,h]=(0,i.YD)({triggerOnce:!0}),$=(0,l.MO)("whatmoreShopId"),p=null!==(t=e.height)&&void 0!==t?t:"100%",g=null!==(r=e.width)&&void 0!==r?r:"100%";return(0,n.useEffect)((()=>{m.current&&(e.isPlaying?m.current.play():((d.G6||(0,a.gE)())&&m.current.play(),"57939755089"==$?setTimeout((()=>{m.current.pause()}),300):m.current.pause()))}),[e.isPlaying,s]),(0,c.jsx)("div",{ref:o,style:{width:p,height:g,overflow:"hidden",display:"flex",alignItems:"center"},children:s?(0,c.jsxs)("video",{ref:m,className:"whatmore-video-player-muted",width:g,height:p,preload:"metadata",loop:!0,src:e.url,playsInline:!0,poster:e.isPlaying&&"STRTFEDEDAP"!==$&&"STRY2V4XO5L"!==$?e.url:e.poster,muted:!0,style:{backgroundColor:"white",borderRadius:e.borderRadius},children:[(0,c.jsx)("source",{src:e.url,type:"video/mp4"}),(0,c.jsx)("source",{src:(0,u.vW)(e.url),type:"video/mp4"})]}):(0,c.jsx)("div",{width:g,height:p,ref:e=>{e&&e.style.setProperty("display","block","important")}})})};var $=function(e){var t,r,d,$;const[p,g,f]=(0,i.YD)({triggerOnce:!0}),b=(0,l.MO)("whatmoreShopId");if((0,o.WJ)(e.event))return(0,c.jsx)(s.Z,{height:e.height,width:e.width,url:e.url,isPlaying:e.isPlaying,timeUpdateCallback:e.timeUpdateCallback});const v=null!==(t=e.pauseFromPlayTimeInMs)&&void 0!==t?t:200;var w;if((0,a.KE)())return(0,c.jsx)(h,{borderRadius:e.borderRadius,height:"100%",width:"100%",poster:null===e||void 0===e||null===(w=e.event)||void 0===w?void 0:w.poster_image,url:(0,m.V)(e.url),isPlaying:e.isPlaying,pauseFromPlayTimeInMs:v});const y=(0,n.useRef)(null),_=null!==(r=e.height)&&void 0!==r?r:"100%",x=null!==(d=e.width)&&void 0!==d?d:"100%";return(0,n.useEffect)((()=>{y.current&&(e.isPlaying?y.current.play():y.current.pause())}),[e.isPlaying,g]),(0,c.jsx)("div",{ref:p,style:{width:_,height:x,overflow:"hidden",display:"flex",alignItems:"center"},children:g?(0,c.jsxs)("video",{ref:y,className:"whatmore-video-player-muted",width:x,height:_,preload:"metadata",loop:!0,playsInline:!0,muted:!0,poster:"57939755089"==b?"":null===e||void 0===e||null===($=e.event)||void 0===$?void 0:$.poster_image,style:{backgroundColor:"white"},children:[(0,c.jsx)("source",{src:(0,m.V)(e.url),type:"video/mp4"}),(0,c.jsx)("source",{src:(0,u.vW)(e.url),type:"video/mp4"})]}):(0,c.jsx)("div",{width:x,height:_,ref:e=>{e&&e.style.setProperty("display","block","important")}})})}},868:function(e,t,r){r.d(t,{V:function(){return o}});var n=r(9854),i=r(7753);const m={"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"},o=function(e){const t=(0,i.MO)("whatmoreShopId");if(!e)return e;if(e.startsWith("https://cdn.shopify.com"))return e;if("AWSCDN"==(0,n.zpr)(t))return e;if("AZURECDN"==(0,n.zpr)(t)){if(e.includes(".azureedge.net"))return e;if(e.includes(".cloudfront.net")){for(const t of Object.keys(m))if(e.includes(t))return e.replace(t,m[t]);return e}}if("BUNNYCDN"==(0,n.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}},342:function(e,t,r){r.d(t,{$W:function(){return o},WN:function(){return a},uv:function(){return m},vW:function(){return s}});var n=r(9854);const i=(0,r(7753).MO)("whatmoreShopId"),m=function(e){var t;return"event_media_urls"in e?"image"===e.event_type?e.event_media_urls.primary.portrait.content_image_original:"secondary"in e.event_media_urls&&e.event_media_urls.secondary.portrait.content_video_1080p?e.event_media_urls.secondary.portrait.content_video_1080p:null!==(t=e.event_media_urls.primary.portrait.content_video_1080p)&&void 0!==t?t:null:e.event_hls_url},a=function(e){return"event_media_urls"in e?"image"===e.event_type?e.event_media_urls.primary.landscape.content_image_original:"secondary"in e.event_media_urls&&e.event_media_urls.secondary.landscape.content_video_1080p?e.event_media_urls.secondary.landscape.content_video_1080p:e.event_media_urls.primary.landscape.content_video_1080p:e.event_hls_url},o=function(e){if(e.startsWith("https://cdn.shopify.com")&&e.includes("whatmore_")){const t=(0,n.QFt)(i);if(!t)return e;return`https://whatmore-brand-video-assets-720p.b-cdn.net/${t}/${e.split("whatmore_")[1].split("?")[0]}`}return e},s=function(e){if(e.startsWith("https://cdn.shopify.com")&&e.includes("whatmore_")){const t=(0,n.QFt)(i);if(!t)return e;return`https://whatmore-brand-thumbnail-video-assets.b-cdn.net/${t}/${e.split("whatmore_")[1].split("?")[0]}`}return e}},6805:function(e,t,r){r.d(t,{$I:function(){return o},$w:function(){return d},AK:function(){return m},AL:function(){return a},YP:function(){return i},me:function(){return n},rE:function(){return s}});const n="device_type",i="device_mode",m="mobile",a="tablet",o="desktop",s="portrait",d="landscape"},9821:function(e,t,r){var n=r(6367),i=r(7753),m=r(8866),a=r(6805);t.Z=function(e){const[t,r,o]=(0,m.Z)(),[s]=(0,i.j1)("whatmoreLandscapePadding"),[d]=(0,i.j1)("whatmoreVideoTileSize"),[l]=(0,i.j1)("whatmoreVideoTileSizePortrait"),u=(0,n.useMediaQuery)({query:"(min-width: 1025px)"}),c=(0,n.useMediaQuery)({query:"(min-width: 481px)"}),h="portrait"==t?l:d,$=!("portrait"!=t||!c),p=h/100*1.3*.5,g=h/100;var f=Math.min(o,r),[b,v,w,y]=[.6*f*(16/9),.6*f,1.4,0];function _(e){return Math.round(10*e)/10}var x={DEVICE_TYPE:a.AK,DEVICE_MODE:a.rE};if(u){const e=v*p,t=b*p;[b,v,w,y]=[t,e,(o-2*s)/(1.1*e),s],x[a.me]=a.$I,x[a.YP]=a.$w}else if($){var j=.8*v,P=.8*b;"portrait"==t?(j*=g,P*=g,[b,v,w,y]=[P,j,_(o/(1.2*j)),0],x[a.me]=a.AL,x[a.YP]=a.rE):([b,v,w,y]=[P,j,(o-2*s)/(1.1*j),s],x[a.me]=a.AL,x[a.YP]=a.$w)}else{j=v,P=b;"portrait"==t?(j=j*g*.9,P=P*g*.9,[b,v,w,y]=[P,j,_(o/(1.15*j)),0],x[a.me]=a.AK,x[a.YP]=a.rE):(j=.7*v,P=.7*b,[b,v,w,y]=[P,j,(o-2*s)/(1.1*j),s],x[a.me]=a.AK,x[a.YP]=a.$w)}return[b,v,w,y,x]}},8743:function(){},123:function(){},7244:function(){}}]);
|
|
1
|
+
"use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[145],{1332:function(e,t,r){var n=r(7313),i=(r(8743),r(7753)),m=r(5254),a=r(6417);t.Z=function(e){return(0,n.useEffect)((()=>{const e=(0,m.oo)((0,i.MO)("whatmoreSecondaryColor"));!function(e,t,r,n){const i=`rgba(${e},${t},${r},${n})`,m=`\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}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.5), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.7);\n }\n 12.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.7), 1.8em -1.8em 0 0em ${i}, 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.5);\n }\n 25% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.5), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.7), 2.5em 0em 0 0em ${i}, 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 37.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.5), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.7), 1.75em 1.75em 0 0em ${i}, 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 50% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.5), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.7), 0em 2.5em 0 0em ${i}, -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 62.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.5), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.7), -1.8em 1.8em 0 0em ${i}, -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 75% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.5), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.7), -2.6em 0em 0 0em ${i}, -1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2);\n }\n 87.5% {\n box-shadow: 0em -2.6em 0em 0em rgba(${e}, ${t}, ${r}, 0.2), 1.8em -1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 2.5em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 1.75em 1.75em 0 0em rgba(${e}, ${t}, ${r}, 0.2), 0em 2.5em 0 0em rgba(${e}, ${t}, ${r}, 0.2), -1.8em 1.8em 0 0em rgba(${e}, ${t}, ${r}, 0.5), -2.6em 0em 0 0em rgba(${e}, ${t}, ${r}, 0.7), -1.8em -1.8em 0 0em ${i};\n }\n }\n `,a=document.createElement("style");a.type="text/css",a.innerHTML=m,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,r){var n=r(1332),i=r(5180),m=r(6417);t.Z=function(e){var t,r;const a=null!==(t=e.height)&&void 0!==t?t:"100%",o=null!==(r=e.width)&&void 0!==r?r:"100%";return(0,m.jsxs)("div",{style:{width:o,height:a,overflow:"hidden",minHeight:a,minWidth:o},children:[(0,m.jsx)(i.Z,{height:a,width:o}),(0,m.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,m.jsx)("div",{style:{display:"flex",flexFlow:"row nowrap",justifyContent:"center",width:"100%",height:"fit-content"},children:(0,m.jsx)(n.Z,{})})})]})}},5180:function(e,t,r){var n=r(6417);t.Z=function(e){var t,r,i;const m=null!==(t=e.height)&&void 0!==t?t:"100%",a=null!==(r=e.width)&&void 0!==r?r:"100%",o=null!==(i=e.borderRadius)&&void 0!==i?i:"10px";return(0,n.jsx)("div",{style:{height:m,width:m,borderRadius:o,overflow:"hidden",minHeight:m,minWidth:a,maxHeight:m,maxWidth:a},children:(0,n.jsx)("div",{style:{minHeight:m,minWidth:a},height:"100%",width:"100%",className:"whatmore-shimmer"})})}},2887:function(e,t,r){var n=r(7313),i=r(3175),m=r(6417);t.Z=function(e){var t,r,a;const[o,s]=(0,n.useState)(!1),d=n.useRef(0),l=(0,n.useRef)(null),u=null!==(t=e.timeUpdateCallback)&&void 0!==t?t:()=>{},c=null!==(r=e.height)&&void 0!==r?r:"100%",h=null!==(a=e.width)&&void 0!==a?a:"100%";return(0,n.useEffect)((()=>{d.current=0;const e=setInterval((()=>{d.current=d.current+.03,l.current&&u(d.current,5),d.current>=5&&(d.current=0)}),30);return()=>{clearInterval(e)}}),[e.isPlaying]),(0,m.jsxs)("div",{style:{display:"flex",flexFlow:"column nowrap",width:h,height:c,overflow:"hidden"},children:[(0,m.jsx)("div",{style:{width:o?"100%":"0px",height:o?"100%":"0px"},children:(0,m.jsx)("img",{ref:l,src:e.url,style:{objectFit:"cover",height:c,width:h,backgroundColor:"white"},alt:"image player",onLoad:()=>{s(!0)}})}),o?(0,m.jsx)(m.Fragment,{}):(0,m.jsx)(i.Z,{width:h,height:c})]})}},4892:function(e,t,r){r.d(t,{Z:function(){return $}});var n=r(7313),i=r(3933),m=r(868),a=r(8984),o=r(7300),s=r(2887),d=r(4862),l=r(7753),u=r(342),c=(r(9854),r(6417));var h=function(e){var t,r;const m=(0,n.useRef)(null),[o,s,h]=(0,i.YD)({triggerOnce:!0}),$=(0,l.MO)("whatmoreShopId"),p=null!==(t=e.height)&&void 0!==t?t:"100%",g=null!==(r=e.width)&&void 0!==r?r:"100%";return(0,n.useEffect)((()=>{m.current&&(e.isPlaying?m.current.play():((d.G6||(0,a.gE)())&&m.current.play(),"57939755089"==$?setTimeout((()=>{m.current.pause()}),300):m.current.pause()))}),[e.isPlaying,s]),(0,c.jsx)("div",{ref:o,style:{width:p,height:g,overflow:"hidden",display:"flex",alignItems:"center"},children:s?(0,c.jsxs)("video",{ref:m,className:"whatmore-video-player-muted",width:g,height:p,preload:"metadata",loop:!0,src:e.url,playsInline:!0,poster:e.isPlaying&&"STRTFEDEDAP"!==$&&"STRY2V4XO5L"!==$?e.url:e.poster,muted:!0,style:{backgroundColor:"white",borderRadius:e.borderRadius},children:[(0,c.jsx)("source",{src:e.url,type:"video/mp4"}),(0,c.jsx)("source",{src:(0,u.vW)(e.url),type:"video/mp4"})]}):(0,c.jsx)("div",{width:g,height:p,ref:e=>{e&&e.style.setProperty("display","block","important")}})})};var $=function(e){var t,r,d,$;const[p,g,f]=(0,i.YD)({triggerOnce:!0}),b=(0,l.MO)("whatmoreShopId");if((0,o.WJ)(e.event))return(0,c.jsx)(s.Z,{height:e.height,width:e.width,url:e.url,isPlaying:e.isPlaying,timeUpdateCallback:e.timeUpdateCallback});const v=null!==(t=e.pauseFromPlayTimeInMs)&&void 0!==t?t:200;var w;if((0,a.KE)())return(0,c.jsx)(h,{borderRadius:e.borderRadius,height:"100%",width:"100%",poster:null===e||void 0===e||null===(w=e.event)||void 0===w?void 0:w.poster_image,url:(0,m.V)(e.url),isPlaying:e.isPlaying,pauseFromPlayTimeInMs:v});const y=(0,n.useRef)(null),_=null!==(r=e.height)&&void 0!==r?r:"100%",x=null!==(d=e.width)&&void 0!==d?d:"100%";return(0,n.useEffect)((()=>{y.current&&(e.isPlaying?y.current.play():y.current.pause())}),[e.isPlaying,g]),(0,c.jsx)("div",{ref:p,style:{width:_,height:x,overflow:"hidden",display:"flex",alignItems:"center"},children:g?(0,c.jsxs)("video",{ref:y,className:"whatmore-video-player-muted",width:x,height:_,preload:"metadata",loop:!0,playsInline:!0,muted:!0,poster:"57939755089"==b?"":null===e||void 0===e||null===($=e.event)||void 0===$?void 0:$.poster_image,style:{backgroundColor:"white"},children:[(0,c.jsx)("source",{src:(0,m.V)(e.url),type:"video/mp4"}),(0,c.jsx)("source",{src:(0,u.vW)(e.url),type:"video/mp4"})]}):(0,c.jsx)("div",{width:x,height:_,ref:e=>{e&&e.style.setProperty("display","block","important")}})})}},868:function(e,t,r){r.d(t,{V:function(){return o}});var n=r(9854),i=r(7753);const m={"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"},o=function(e){const t=(0,i.MO)("whatmoreShopId");if(!e)return e;if(e.startsWith("https://cdn.shopify.com"))return e;if("AWSCDN"==(0,n.zpr)(t))return e;if("AZURECDN"==(0,n.zpr)(t)){if(e.includes(".azureedge.net"))return e;if(e.includes(".cloudfront.net")){for(const t of Object.keys(m))if(e.includes(t))return e.replace(t,m[t]);return e}}if("BUNNYCDN"==(0,n.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}},342:function(e,t,r){r.d(t,{$W:function(){return o},WN:function(){return a},uv:function(){return m},vW:function(){return s}});var n=r(9854);const i=(0,r(7753).MO)("whatmoreShopId"),m=function(e){var t;return"event_media_urls"in e?"image"===e.event_type?e.event_media_urls.primary.portrait.content_image_original:"secondary"in e.event_media_urls&&e.event_media_urls.secondary.portrait.content_video_1080p?e.event_media_urls.secondary.portrait.content_video_1080p:null!==(t=e.event_media_urls.primary.portrait.content_video_1080p)&&void 0!==t?t:null:e.event_hls_url},a=function(e){return"event_media_urls"in e?"image"===e.event_type?e.event_media_urls.primary.landscape.content_image_original:"secondary"in e.event_media_urls&&e.event_media_urls.secondary.landscape.content_video_1080p?e.event_media_urls.secondary.landscape.content_video_1080p:e.event_media_urls.primary.landscape.content_video_1080p:e.event_hls_url},o=function(e){if(e.startsWith("https://cdn.shopify.com")&&e.includes("whatmore_")){const t=(0,n.QFt)(i);if(!t)return e;return`https://whatmore-brand-video-assets-720p.b-cdn.net/${t}/${e.split("whatmore_")[1].split("?")[0]}`}return e},s=function(e){if(e.startsWith("https://cdn.shopify.com")&&e.includes("whatmore_")){const t=(0,n.QFt)(i);if(!t)return e;return`https://whatmore-brand-thumbnail-video-assets.b-cdn.net/${t}/${e.split("whatmore_")[1].split("?")[0]}`}return e}},6805:function(e,t,r){r.d(t,{$I:function(){return o},$w:function(){return d},AK:function(){return m},AL:function(){return a},YP:function(){return i},me:function(){return n},rE:function(){return s}});const n="device_type",i="device_mode",m="mobile",a="tablet",o="desktop",s="portrait",d="landscape"},9821:function(e,t,r){var n=r(6367),i=r(7753),m=r(8866),a=r(6805);t.Z=function(e){const[t,r,o]=(0,m.Z)(),[s]=(0,i.j1)("whatmoreLandscapePadding"),[d]=(0,i.j1)("whatmoreVideoTileSize"),[l]=(0,i.j1)("whatmoreVideoTileSizePortrait"),u=(0,n.useMediaQuery)({query:"(min-width: 1025px)"}),c=(0,n.useMediaQuery)({query:"(min-width: 481px)"}),h="portrait"==t?l:d,$=!("portrait"!=t||!c),p=h/100*1.3*.5,g=h/100;var f=Math.min(o,r),[b,v,w,y]=[.6*f*(16/9),.6*f,1.4,0];function _(e){return Math.round(10*e)/10}var x={DEVICE_TYPE:a.AK,DEVICE_MODE:a.rE};if(u){const e=v*p,t=b*p;[b,v,w,y]=[t,e,(o-2*s)/(1.1*e),s],x[a.me]=a.$I,x[a.YP]=a.$w}else if($){var j=.8*v,P=.8*b;"portrait"==t?(j*=g,P*=g,[b,v,w,y]=[P,j,_(o/(1.2*j)),0],x[a.me]=a.AL,x[a.YP]=a.rE):([b,v,w,y]=[P,j,(o-2*s)/(1.1*j),s],x[a.me]=a.AL,x[a.YP]=a.$w)}else{j=v,P=b;"portrait"==t?(j=j*g*.9,P=P*g*.9,[b,v,w,y]=[P,j,_(o/(1.15*j)),0],x[a.me]=a.AK,x[a.YP]=a.rE):(j=.7*v,P=.7*b,[b,v,w,y]=[P,j,(o-2*s)/(1.1*j),s],x[a.me]=a.AK,x[a.YP]=a.$w)}return[b,v,w,y,x]}},8743:function(){},123:function(){},7244:function(){}}]);
|
|
@@ -73,7 +73,7 @@
|
|
|
73
73
|
0% {
|
|
74
74
|
transform: translateY(100%);
|
|
75
75
|
}
|
|
76
|
-
`} 0.5s`,bt=null===N||void 0===N||null===(e=N.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"))})),[St,It]=(0,n.useState)(-1!==bt?null===(i=N.options)||void 0===i||null===(o=i[bt])||void 0===o||null===(r=o.values)||void 0===r?void 0:r[0]:""),[kt,_t]=(0,n.useState)({});(0,n.useEffect)((()=>{-1!==bt&&"whatmore"!==(0,c.Ipo)(ft)&&async function(){const t=await(0,lt.m3)(Z);_t(t)}()}),[]);let Tt=-1,Ft=-1!==bt&&null!==kt&&void 0!==kt&&kt.product&&(null===kt||void 0===kt||null===(l=kt.product)||void 0===l||null===(a=l.images)||void 0===a?void 0:a.length)>=(null===kt||void 0===kt||null===(d=kt.product)||void 0===d||null===(p=d.options)||void 0===p||null===(x=p[bt])||void 0===x||null===(m=x.values)||void 0===m?void 0:m.length)?null===kt||void 0===kt||null===(f=kt.product)||void 0===f||null===(w=f.images)||void 0===w?void 0:w.map((t=>{var e,i,n,o,r,l,a,d,s,c,u,h,p,x;const v=null===kt||void 0===kt||null===(e=kt.product)||void 0===e||null===(i=e.options)||void 0===i?void 0:i.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===kt||void 0===kt||null===(n=kt.product)||void 0===n||null===(o=n.options)||void 0===o||null===(r=o[v])||void 0===r||null===(l=r.values)||void 0===l?void 0:l[Math.min(++Tt,(null===kt||void 0===kt||null===(a=kt.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===kt||void 0===kt||null===(u=kt.product)||void 0===u||null===(h=u.options)||void 0===h||null===(p=h[v])||void 0===p||null===(x=p.values)||void 0===x?void 0:x[Math.max(0,Tt)],src:null===t||void 0===t?void 0:t.src}})):[],Et=[];if("whatmore"==(0,c.Ipo)(ft)&&(null===N||void 0===N||null===(j=N.images)||void 0===j?void 0:j.length)>0){var Pt;var Ot;if(-1!==(null===N||void 0===N||null===(Pt=N.options)||void 0===Pt?void 0:Pt.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"))}))))Et=null===N||void 0===N||null===(Ot=N.images)||void 0===Ot?void 0:Ot.map((t=>({color:t.color,src:t.src,optionsrc:t.optionsrc})))}return Tt+1<(null===kt||void 0===kt||null===(y=kt.product)||void 0===y||null===(C=y.options)||void 0===C||null===(S=C[bt])||void 0===S||null===(I=S.values)||void 0===I?void 0:I.length)&&(Ft=[]),(0,v.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===gt||void 0===gt?void 0:gt.whatmoreUITheme)?"xl":null,animation:Ct,children:[(0,v.jsx)(Ut,{setOpenShopNow:H,setLockSwiper:U,FONT_SIZE:K}),(0,v.jsx)(s.M5,{marginBottom:"10px",px:"20px",py:"5px",children:(0,v.jsx)(s.kC,{bg:"whiteAlpha.900",width:"fit-content",height:"fit-content",borderRadius:"round"==(null===gt||void 0===gt?void 0:gt.whatmoreUITheme)?"lg":null,overflow:"hidden",sx:{borderWidth:(0,c.alU)(ft),borderColor:(0,c.qPe)(ft)},children:(0,v.jsx)(s.kC,{width:"100%",children:(0,v.jsx)($t.P,{renderElement:t=>(0,v.jsx)(v.Fragment,{children:(0,v.jsx)(s.xu,{width:D+"px",height:A+"px",children:(0,v.jsx)(g.Ee,{width:D+"px",height:A+"px",borderRadius:"round"==(null===gt||void 0===gt?void 0:gt.whatmoreUITheme)?"lg":null,src:(0,pt.s)(t.eventData.src,"&width=400&height=400"),alt:Z.handle,sx:{objectFit:(0,c.yOX)(ft)+" !important"},fallback:(0,v.jsx)(R.Z,{width:D+"px",height:A+"px",borderRadius:"round"==(null===gt||void 0===gt?void 0:gt.whatmoreUITheme)?"10px":"0px"})})})}),dataList:Ft.length>0&&!Ft.includes(null)?null===(k=Ft)||void 0===k?void 0:k.filter((t=>(null===t||void 0===t?void 0:t.color)==St)):Et.length>0?[null===(_=Et)||void 0===_?void 0:_.find((t=>(null===t||void 0===t?void 0:t.color)==St))]:null===N||void 0===N||null===(T=N.images)||void 0===T?void 0:T.map((t=>({src:t.includes("https")?t:"https:"+t}))),spacing:10,defaultHeight:D+"px",defaultWidth:A+"px",retainAlreadyRenderedElements:!0,isScroll:!0})})})}),(0,v.jsx)(Xt,{data:N,product:Z,PRODUCT_TILE_HEIGHT:M,PRODUCT_TILE_WIDTH:L,FONT_SIZE:K,getVariantPrice:te,selectedVariantId:tt,itemPrice:ot,itemQuantity:it,setItemQuantity:nt,thumbnailImage:vt}),(null===N||void 0===N||null===(F=N.variants)||void 0===F?void 0:F.length)>0&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)(s.M5,{paddingTop:"4px",width:"100%",children:(0,v.jsx)(s.iz,{color:(0,c.W8U)(ft),size:"xs",width:"90%"})}),(0,v.jsx)(Gt,{data:N,dividerColor:(0,c.W8U)(ft),setSelectedColor:It,finalArr:Ft,finalArrExternal:Et,product:Z,PRODUCT_TILE_HEIGHT:M,PRODUCT_TILE_WIDTH:L,FONT_SIZE:K,selectOptionFirstHandler:wt,selectOptionSecondHandler:jt,selectOptionThirdHandler:yt,getVariantPrice:te,selectedOptionFirst:Y,selectedOptionSecond:G,selectedOptionThird:Q,selectedVariantId:tt})]}),c.$2G&&((null===N||void 0===N?void 0:N.description)||(null===N||void 0===N?void 0:N.body_html))&&(0,v.jsx)(Bt,{PRODUCT_TILE_HEIGHT:M,FONT_SIZE:K,data:N,handleToggle:()=>q(!W),show:W}),(0,v.jsx)(s.xu,{sx:{pointerEvents:"none"},paddingTop:"20px",opacity:0,children:(0,v.jsx)(Ht,{position:"relative",data:N,FONT_SIZE:K,product:Z})}),(0,v.jsx)(Ht,{position:"fixed",selectedVariantId:tt,data:N,FONT_SIZE:K,PRODUCT_TILE_WIDTH:L,product:Z,itemQuantity:it,cartItemCount:dt,addToCartFlag:ct,setAddToCartFlag:ut,soldOutFlag:ht,setSoldOutFlag:xt,event:V})]})}const Jt=(t,e,i,n)=>{var o;if(!e&&!i&&!n)return;const r=null===t||void 0===t||null===(o=t.variants)||void 0===o?void 0:o.find((t=>(!e||t.option1===e)&&(!i||t.option2===i)&&(!n||t.option3===n)));return r?r.id:void 0},te=(t,e)=>{var i,n;return null===t||void 0===t||null===(i=t.variants)||void 0===i||null===(n=i.find((t=>t.id===e)))||void 0===n?void 0:n.price},ee=(t,e)=>{var i,n;return null===t||void 0===t||null===(i=t.variants)||void 0===i||null===(n=i.find((t=>t.id.toString()===e)))||void 0===n?void 0:n.option1},ie=(t,e)=>{var i,n;return null===t||void 0===t||null===(i=t.variants)||void 0===i||null===(n=i.find((t=>t.id.toString()===e)))||void 0===n?void 0:n.option2},ne=(t,e)=>{var i,n;return null===t||void 0===t||null===(i=t.variants)||void 0===i||null===(n=i.find((t=>t.id.toString()===e)))||void 0===n?void 0:n.option3},oe=(t,e)=>{var i;const n=null===t||void 0===t||null===(i=t.variants)||void 0===i?void 0:i.find((t=>t.id==e));return void 0===n?null:null===n||void 0===n||null===(o=n.featured_image)||void 0===o?void 0:o.src;var o},re=(0,n.createContext)({setShowOptionsChart:null});var le=function(t){const e=t.event,i=t.data,o=t.currentProduct,r=t.setOpenShopNow,l=t.setLockSwiper,[a,d]=(0,n.useState)(!1);return(0,v.jsx)(re.Provider,{value:{setShowOptionsChart:d},children:(0,v.jsxs)(s.xu,{width:"full",height:"full",borderRadius:"md",children:[(0,v.jsx)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"flex-end",children:(0,v.jsx)(s.xu,{width:"full",height:"fit-content",children:(0,v.jsx)(Qt,{data:i,event:e,product:o,setOpenShopNow:r,setLockSwiper:l})})}),a?(0,v.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,v.jsx)(s.xu,{width:"full",height:"fit-content",children:(0,v.jsx)(Wt,{data:i,event:e,product:o,setShowOptionsChart:()=>{d(!1)}})})}):(0,v.jsx)(v.Fragment,{})]})})};var ae=function(t){var e,[i,o,r,l]=(0,h.Z)();const[a,d]=(0,n.useState)(!1),[x,g]=(0,n.useState)(),[f,w]=(0,n.useState)(),j=(0,u.MO)("whatmoreShopId"),y=t.event,C=t.onBack,b=n.useRef(),S=t.isPlaying,I=t.isLast,k=t.setLockSwiper,_=t.selectedVariantId,T=null===(e=t.showOverlay)||void 0===e||e,F="center";return(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:l,height:r,sx:{overflow:"hidden"},children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:F,height:"full",width:"full",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,v.jsx)(s.oM,{width:"full",ratio:l/r,children:(0,v.jsx)(m,{height:"100%",width:"100%",url:y.event_hls_url,isPlaying:S,event:y})})})}),T?(0,v.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:F,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,v.jsx)(At,{focusRef:b,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,v.jsx)(v.Fragment,{}),!0===a?(0,v.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"200%"},direction:"column",justifyContent:F,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,v.jsx)(le,{focusRef:b,event:t.event,isLast:I,onCloseCallback:()=>C(),setLockSwiper:k,data:x,currentProduct:f,setOpenShopNow:d,selectedVariantId:_})})}):(0,v.jsx)("div",{})]})})};const de=function(t,e){return isNaN(t)||isNaN(e)||e<=0||t>e?0:Math.ceil(t/e*100)};function se(t){var e,i,[n,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,x=null!==(i=t.indexAmongSiblings)&&void 0!==i?i:0;return(0,v.jsx)(s.Kq,{width:"96%",height:"fit-content",direction:"row",justifyContent:"center",alignItems:"center",spacing:"1px",children:[...Array(p).keys()].map((t=>(0,v.jsx)(s.Kq,{width:"100%",height:.004*r+"px",backgroundColor:t<x?a:d+"99",borderRightRadius:"lg",borderLeftRadius:"lg",direction:"row",justifyContent:"flex-start",alignItems:"center",overflow:"hidden",sx:{display:"block !important"},children:t==x?(0,v.jsx)(s.xu,{height:"100%",width:c+"%",bgColor:a,borderRightRadius:"lg",borderLeftRadius:"lg",sx:{display:"block !important"}}):(0,v.jsx)(v.Fragment,{})},"event-progress-bar-slab-"+t)))})}var ce=i(868),ue=i(2630);const he=t=>t>=1e3?(t/1e3).toFixed(1)+"k":t;var pe=i(4862);var xe=function(t){var e,i,o,r,a,d=t.whatmoreShareTemplateId;const p=t.whatmoreShareStoryId,x=t.whatmoreShareEventId,m=t.event,g=null===(e=t.showShareText)||void 0===e||e,f=null!==(i=t.shareButtonBottomMargin)&&void 0!==i?i:0,w=(0,u.MO)("whatmoreShopId"),j=(0,u.MO)("isInDesignMode"),y=(0,u.MO)("isDemoBrand"),C=(0,u.MO)("whatmorePrimaryFont"),b=(0,u.MO)("websiteLanguage"),{whatmoreWidgetSourceDetails:S}=(0,n.useContext)(V.I),[I,k,_,T]=(0,h.Z)(),F=null!==(o=t.iconSize)&&void 0!==o?o:.1*T*(0,c.r5f)(w);function E(){const e=(0,u.MO)("whatmoreLandingLocationType");var i;!function(t){j||y||(async()=>{(0,l.x0)(t)})()}(m),(e.startsWith("product")||"embed"===e)&&(d="te"),i="event_product_link"===(0,c.EEC)(w)?m.products[0].product_link||"":window.location.pathname,i=("event_product_link"===(0,c.EEC)(w)?"":window.location.hostname)+i+"?wtt="+d+"&wsid="+p+"&weid="+x,(0,c.lj5)(w)&&(i=i+"&"+(0,c.awP)(w)+"&utm_campaign=video-share&utm_medium="+e);const n={title:(0,c.JNF)(w),text:`${(0,c.Qa8)(w)} \n ${i} ${(0,c.AWG)(w)?"\n \n -via Whatmore":""}`};navigator.share&&!pe.nI?navigator.share(n):(t.setIsModalOpen(!0),t.setShareText([n,i]))}return(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.Cd,{cursor:"pointer",style:{marginBottom:f+"px"},children:(0,v.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"fit-content",width:"fit-content",children:[(0,v.jsx)(ue.Z,{sx:{boxShadow:3,transform:"scaleX(-1)",color:"white",fontSize:F,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),E(),(0,q.GF)({userInteractionType:N.K.VIDEO_SHARE_CTA_CLICKED,widgetSourceDetails:S,event:m,productList:m.products,ctaList:m.cta})}}),g&&(0,c.u8S)(w)?(0,v.jsxs)(s.xv,{fontSize:.3*F+"px !important",fontWeight:"semibold !important",align:"center",sx:{fontFamily:C+" !important",color:"white !important",paddingRight:"10%"},children:["\xa0",m.total_share>(0,c.LWl)(w)?he(m.total_share):null!==(r=null===Q||void 0===Q||null===(a=Q[b])||void 0===a?void 0:a.share)&&void 0!==r?r:"Share","\xa0"]}):(0,v.jsx)(v.Fragment,{})]})})})},ve=i(7933),me=i(2785);var ge=function(t){var e,i,o;const r=(0,u.MO)("whatmoreShopId"),a=(0,u.MO)("whatmorePrimaryFont"),d=(0,u.MO)("whatmoreLikedEvents"),p=(0,u.MO)("isInDesignMode"),x=(0,u.MO)("isDemoBrand"),m=(0,u.MO)("websiteLanguage"),{whatmoreWidgetSourceDetails:g}=(0,n.useContext)(V.I),f=t.event,[w,j]=(0,n.useState)(null!==(e=d[f.event_id])&&void 0!==e&&e),[y,C,b,S]=(0,h.Z)(),I=.1*S*(0,c.r5f)(r);function k(t,e){p||x||(async()=>{(0,l.Z6)(t,e)})()}function _(){(0,u.bU)("whatmoreLikedEvents",{...d,[f.event_id]:!w}),w?(k(f,-1),(0,q.GF)({userInteractionType:N.K.VIDEO_UNLIKED,widgetSourceDetails:g,event:f,productList:f.products,ctaList:f.cta})):(k(f,1),(0,q.GF)({userInteractionType:N.K.VIDEO_LIKED,widgetSourceDetails:g,event:f,productList:f.products,ctaList:f.cta})),j(!w)}const T=f.total_like+(w?1:0);return(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.Cd,{cursor:"pointer",children:(0,v.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"fit-content",width:"fit-content",children:[w?(0,v.jsx)(me.Z,{sx:{boxShadow:3,color:(0,c.dmX)(r),fontSize:I,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),_()}}):(0,v.jsx)(ve.Z,{sx:{boxShadow:3,color:"white",fontSize:I,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),_()}}),(0,v.jsx)(v.Fragment,{children:(0,c.CEM)(r)?(0,v.jsxs)(s.xv,{fontSize:.3*I+"px !important",fontWeight:"semibold !important",align:"center",sx:{fontFamily:a+" !important",color:"white !important",position:"relative",bottom:"5px"},children:["\xa0",T>=(0,c.zKg)(r)?he(T):null!==(i=null===Q||void 0===Q||null===(o=Q[m])||void 0===o?void 0:o.like)&&void 0!==i?i:"Like","\xa0"]}):(0,v.jsx)(v.Fragment,{})})]})})})};const fe=t=>{let{iconSize:e}=t;return(0,v.jsx)("div",{style:{backgroundColor:"#25D366",borderRadius:"50%",padding:.3*e},children:(0,v.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,v.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 we=i(8866);const je=t=>{let{iconSize:e}=t;return(0,v.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:.3*e},children:(0,v.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,v.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"})})})},ye=t=>{let{iconSize:e}=t;return(0,v.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:.3*e},children:(0,v.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,v.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 Ce=t=>{const e=t.shareText,[i,o]=(0,n.useState)("Copy link"),[r,l]=(0,n.useState)("");return(0,v.jsx)(v.Fragment,{children:t.isModalOpen&&(0,v.jsxs)("div",{className:"modal-overlay",style:{backgroundColor:"white",borderRadius:"10px",padding:"12px 12px 20px 12px"},children:[(0,v.jsxs)("div",{style:{cursor:"pointer",display:"flex",justifyContent:"space-between",paddingBottom:"6px"},children:[(0,v.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,v.jsx)(Kt.Z,{onClick:e=>{e.stopPropagation(),t.setIsModalOpen(!1)}})]}),(0,v.jsx)("div",{}),(0,v.jsx)(s.iz,{color:"blackAlpha.500",size:"1px",width:"100%"}),(0,v.jsxs)("div",{className:"social-icons",style:{display:"flex",gap:"20px",justifyContent:"center",paddingTop:"12px"},children:[(0,v.jsxs)("div",{onClick:t=>{var i;t.stopPropagation();const n=encodeURIComponent(null===(i=e[0])||void 0===i?void 0:i.text);window.open(`https://wa.me/?text=${n}`,"_blank")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,v.jsx)(fe,{iconSize:Math.min(t.iconSize,30)}),(0,v.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14)},children:"Whatsapp"})]}),(0,v.jsxs)("div",{onClick:t=>{var i;t.stopPropagation();const n=encodeURIComponent(null===(i=e[0])||void 0===i?void 0:i.text);window.open(`https://twitter.com/intent/tweet?text=${n}`,"_blank")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,v.jsx)(je,{iconSize:Math.min(t.iconSize,30),style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,v.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14)},children:"X"})]}),(0,v.jsxs)("div",{onClick:t=>{t.stopPropagation(),navigator.clipboard.writeText(e[1]),o("Link copied"),l("green")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,v.jsx)(ye,{iconSize:Math.min(t.iconSize,30),style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,v.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14),color:r},children:i})]})]})]})})};var be=function(t){var e,i;const n=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!==(i=t.fontSize)&&void 0!==i?i:"8",[a]=(0,we.Z)(),d=`https://www.whatmore.ai/shoppable-videos?utm_source=${n}&utm_medium=referral&utm_campaign=${"landscape"===a?"customer_referral_desktop":"customer_referral_mobile"}`;return(0,v.jsx)(s.rU,{href:d,isExternal:!0,children:(0,c.XFt)(r)&&(0,v.jsxs)(s.Kq,{direction:"row",justifyContent:"flex-start",alignItems:"center",width:"fit-content",spacing:"2px",paddingLeft:"2px",paddingRight:"2px",children:[(0,v.jsx)("p",{style:{textAlign:"center",color:"white",fontFamily:o,fontWeight:"normal",fontSize:1.1*l+"px"},children:"powered by Whatmore"}),(0,v.jsx)(s.xu,{width:"10px"}),(0,v.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"}})]})})},Se=i(4892),Ie=i(1195);var ke=()=>(0,v.jsxs)(s.xu,{as:"svg",width:"46px",height:"46px",viewBox:"0 0 24 24",fill:"none",className:"tick-animation",marginBottom:"20px",children:[(0,v.jsx)("circle",{cx:"12",cy:"12",r:"11",stroke:"gray",strokeWidth:"2",fill:"none"}),(0,v.jsx)("path",{d:"M7 12l3 3 7-7",stroke:"gray",strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round"})]});var _e=t=>{var e;const i={text:null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.title,options:(null===t||void 0===t?void 0:t.options)||[]},[o,r]=(0,n.useState)(!1),[l,a]=(0,n.useState)(null),[d,c]=(0,n.useState)(null),u=(0,n.useRef)(null),h=(0,n.useContext)(V.I);return(0,n.useEffect)((()=>{if(o){const e=setTimeout((()=>{t.setIsQuestionVisible(!1)}),1e3);return()=>clearTimeout(e)}}),[o]),(0,n.useEffect)((()=>{!o&&u.current&&c(u.current.offsetHeight)}),[o]),(0,v.jsxs)(s.xu,{position:"fixed",top:"50%",left:"50%",transform:"translate(-50%, -50%)",minWidth:"320px",width:"fit-content",bg:"white",borderRadius:"lg",boxShadow:"md",display:"flex",flexDirection:"column",maxWidth:"90%",maxHeight:"90%",overflowY:"visible",ref:u,height:d?`${d}px`:"auto",children:[(0,v.jsx)(s.xu,{position:"absolute",top:"-10px",right:"-10px",bg:"rgba(255, 255, 255, 0.8)",borderRadius:"full",padding:1,display:"flex",alignItems:"center",justifyContent:"center",cursor:"pointer",zIndex:"10",onClick:()=>{var e;t.setIsQuestionVisible(!1),(0,q.GF)({userInteractionType:N.K.QUESTION_CLOSED,userInteractionMetadata:{questionId:null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.id},widgetSourceDetails:h})},children:(0,v.jsx)(Ie.Z,{})}),(0,v.jsx)(s.xu,{bg:"gray.700",borderTopRadius:"lg",py:3,px:6,display:"flex",flexDirection:"column",justifyContent:"center",width:"100%",children:(0,v.jsx)(s.X6,{py:6,as:"h2",textAlign:"center",style:{fontWeight:"bold",fontSize:"18px",color:"white"},children:null===i||void 0===i?void 0:i.text})}),(0,v.jsx)(s.xu,{flex:"1",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",py:5,px:6,width:"100%",children:o?(0,v.jsxs)(s.xu,{flex:"1",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",width:"100%",children:[(0,v.jsx)(ke,{}),(0,v.jsx)(s.X6,{as:"h3",size:"md",color:"gray.700",fontWeight:"medium",textAlign:"center",mt:4,fontSize:"lg",children:"Thank you for your response!"})]}):(0,v.jsx)(s.Kq,{spacing:5,width:"100%",align:"center",children:i.options.map(((e,i)=>(0,v.jsx)(s.xu,{px:4,borderWidth:2,borderRadius:"md",cursor:"pointer",bg:l===e?"gray.200":"white",borderColor:l===e?"gray.400":"gray.200",_hover:{bg:"gray.200"},onClick:()=>(e=>{var i;a(e),r(!0),(0,q.GF)({userInteractionType:N.K.QUESTION_ANSWERED,userInteractionMetadata:{questionId:null===t||void 0===t||null===(i=t.question)||void 0===i?void 0:i.id,response:e},widgetSourceDetails:h})})(e),transition:"background-color 0.2s, border-color 0.2s",display:"flex",alignItems:"center",width:"100%",children:(0,v.jsx)(s.xv,{py:5,color:"gray.800",children:e})},i)))})})]})},Te=i(2586);var Fe=t=>{var e,i;const[o,r]=(0,n.useState)(""),[l,a]=(0,n.useState)(""),[d,h]=(0,n.useState)(!1),[p,x]=(0,n.useState)(!1),m=(0,u.MO)("whatmoreShopId"),g=(0,u.MO)("whatmoreSecondaryColor"),f=null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.title,w=(0,n.useContext)(V.I),j=()=>{var e,i;(()=>{const{type:e}=(null===t||void 0===t?void 0:t.question)||{};return"number"===e?/^\d{10}$/.test(o):/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(o)})()?(h(!0),(0,q.GF)({userInteractionType:N.K.QUESTION_ANSWERED,userInteractionMetadata:{questionId:null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.id,response:o,type:"number"===(null===t||void 0===t||null===(i=t.question)||void 0===i?void 0:i.type)?"leadgen:number":"leadgen:email"},widgetSourceDetails:w})):a("Please enter valid contact info.")},y=()=>{var e;t.setIsQuestionVisible(!1),(0,q.GF)({userInteractionType:N.K.QUESTION_CLOSED,userInteractionMetadata:{questionId:null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.id},widgetSourceDetails:w})};return(0,v.jsx)(s.kC,{bg:"rgba(0, 0, 0, 0.8)",p:"6%",borderRadius:"md",boxShadow:"md",width:"90vw",mx:"auto",minH:"40vh",maxH:"80vh",position:"fixed",top:"30%",left:"50%",transform:"translateX(-50%)",direction:"column",align:"center",justify:"center",zIndex:100,overflow:"hidden",children:d?(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)(s.xu,{textAlign:"center",color:"white",children:[(0,v.jsx)(s.xu,{fontSize:"2xl",fontWeight:"bold",children:"CONGRATULATIONS!"}),(0,v.jsx)(s.xu,{my:"4%",fontSize:"xl",children:"Claim Now"})]}),(0,v.jsx)(s.xu,{position:"absolute",top:"2%",right:"2%",zIndex:20,children:(0,v.jsx)(P.Z,{onCloseCallback:y})}),(0,v.jsxs)(s.xu,{position:"relative",width:"70%",onClick:()=>{const t=(0,c.dKN)(m);navigator.clipboard.writeText(t).then((()=>{x(!0),setTimeout((()=>{y()}),1e3),setTimeout((()=>x(!1)),2e3)}),(()=>{console.error("Failed to copy the coupon code")}))},cursor:"pointer",children:[(0,v.jsxs)(s.xu,{bg:"white",border:"2px dashed black",borderRadius:"md",p:"2%",display:"flex",alignItems:"center",justifyContent:"space-between",mt:"4%",children:[(0,v.jsx)(s.xu,{as:"span",fontWeight:"bold",color:"black",children:(0,c.dKN)(m)}),(0,v.jsx)(Te.Z,{sx:{color:p?{whatmoreSecondaryColor:g}:"gray",cursor:"pointer",marginLeft:"2%"}})]}),p&&(0,v.jsx)(s.xu,{padding:"4%",position:"absolute",left:"50%",transform:"translateX(-50%)",bg:g,color:"white",fontSize:"12px",borderRadius:"md",px:"2%",py:"0.5%",textAlign:"center",children:"Copied!"})]})]}):(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)(s.xu,{textAlign:"center",color:"white",children:[(0,v.jsx)(s.xu,{children:(0,v.jsx)(s.xv,{fontSize:"22px",fontWeight:"bold",children:f})}),(0,v.jsx)(s.xu,{marginBottom:"10%",fontSize:"md",children:(0,c.ewB)(m)})]}),(0,v.jsx)(s.xu,{position:"fixed",top:"2%",right:"2%",zIndex:20,children:(0,v.jsx)(P.Z,{onCloseCallback:y})}),(0,v.jsxs)(s.kC,{mt:"4%",align:"center",direction:"column",width:"80%",children:[(0,v.jsx)(s.xu,{sx:{bg:"white",border:"2px solid #4A4A4A",borderRadius:"8px",paddingLeft:"2%",display:"flex",alignItems:"center",marginBottom:"6%",width:"100%",height:"auto",minH:"48px"},children:(0,v.jsx)("input",{type:"number"===(null===(i=t.question)||void 0===i?void 0:i.type)?"tel":"email",placeholder:t.placeholder,value:o,onChange:t=>{r(t.target.value),l&&a("")},onKeyDown:t=>{"Enter"===t.key&&j()},style:{fontSize:"1em",border:"none",outline:"none",width:"100%"}})}),l&&(0,v.jsx)(s.xv,{color:"red.500",mb:"4% !important",fontSize:"md",textAlign:"center",width:"100%",children:l}),(0,v.jsx)(s.xu,{as:"button",bg:"#343434"!=g?g:"green",color:"#343434",borderRadius:"md",fontWeight:"bold",height:"35px",display:"flex",alignItems:"center",justifyContent:"center",onClick:j,width:"50%",children:(0,v.jsx)(s.xv,{fontSize:"0.8em",padding:"2%",color:"white",children:"SUBMIT"})})]})]})})};var Ee=t=>{const[e,i]=(0,n.useState)(null);return(0,v.jsx)(s.xu,{children:!e&&(0,v.jsx)(Fe,{question:t.question,onEmailSubmit:t=>{i(t)},setIsQuestionVisible:t.setIsQuestionVisible,placeholder:t.placeholder})})};var Pe=t=>{var e;const[i,o]=(0,n.useState)(null),r=t.questionIndex,l=t.questionList;if((0,n.useEffect)((()=>{if(!(r>=l.length))return()=>(0,ot.xw)()}),[]),r>=l.length)return;const a=null===l||void 0===l?void 0:l[r];return"string"===(null===a||void 0===a?void 0:a.type)||"number"===(null===a||void 0===a?void 0:a.type)?(0,v.jsx)(s.xu,{children:(0,v.jsx)(Ee,{setIsQuestionVisible:t.setIsQuestionVisible,question:a,placeholder:"number"===(null===a||void 0===a?void 0:a.type)?"Enter your phone number":"Enter your email"})}):(0,v.jsx)(s.xu,{children:(0,v.jsx)(_e,{question:a,options:null===a||void 0===a||null===(e=a.answers)||void 0===e?void 0:e.values.map((t=>null===t||void 0===t?void 0:t.value)),onAnswerSelect:t=>{o(t)},selectedAnswer:i,onClose:()=>{t.setIsQuestionVisible(!1)},setIsQuestionVisible:t.setIsQuestionVisible})})};function Oe(t){var e;const i=t.event,[o,r,l,a]=(0,h.Z)(),[d]=(0,u.j1)("whatmorePrimaryFont"),{whatmoreIsStoriesTemplate:p}=(0,n.useContext)(V.I),[x]=(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:[x,g,x,g,x],w=(0,n.useRef)(null);(0,n.useEffect)((()=>{w.current&&w.current.play()}),[]);const j=(0,ce.V)(null===i||void 0===i?void 0:i.storyset_thumbnail_image);return(0,v.jsx)(v.Fragment,{children:p?(0,v.jsx)(s.xu,{width:"100%",height:"fit-content",padding:"5px",children:(0,v.jsxs)(s.Kq,{direction:"row",width:"100%",height:"fit-content",justifyContent:"flex-start",children:[(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.Cd,{overflow:"hidden",size:.14*t.width+"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.$)(j)?(0,v.jsx)(Se.Z,{height:"100%",width:"100%",poster:null===i||void 0===i?void 0:i.thumbnail_image,url:j,isPlaying:!0,event:{event_type:"video"},borderRadius:"50%"}):(0,v.jsx)("img",{src:j,style:{objectFit:"cover",height:"100%",width:"100%",backgroundColor:"white"}})})}),(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.xv,{style:{overflow:"hidden",textOverflow:"ellipsis"},noOfLines:1,fontSize:.05*t.width+"px",fontWeight:"medium",lineHeight:"100%",sx:{fontFamily:d+" !important",color:"white !important",textShadow:"0px 0px 4px black !important;"},children:i.storyset_name})})]})}):(0,v.jsx)(v.Fragment,{})})}var ze=function(t){var e,i,o;const[r,a,d]=(0,we.Z)(),[p]=(0,u.j1)("isInDesignMode"),[x]=(0,u.j1)("isDemoBrand"),[m,g]=(0,u.j1)("isProductSwiperCatalogOpen"),[f,w]=(0,u.j1)("isFirstIndicatorRenderDone"),[j]=(0,u.j1)("whatmoreShopId"),C=(0,n.useContext)(wi),{whatmoreEventsBrowsingTemplate:b}=(0,n.useContext)(V.I),[S,I,k,_]=(0,h.Z)(),T=(0,u.MO)("whatmorePrimaryFont"),E=t.event,O=t.storySetId,z=t.isLast,L=t.onCloseCallback,M=t.focusRef,R=t.productClickHandler,A=t.videoPlayingData,K=t.totalSiblingEvents,W=t.indexAmongSiblings,Z=t.leftOpenSpaceClickHandler,H=t.midOpenSpaceClickHandler,U=t.rightOpenSpaceClickHandler,{whatmoreWidgetSourceDetails:B}=(0,n.useContext)(V.I),Y=.1*_,[X,G]=(0,n.useState)(!1),[$,Q]=(0,n.useState)([]),J=t=>{tt.current&&!tt.current.contains(t.target)&&G(!1)},tt=(0,n.useRef)(null);(0,n.useEffect)((()=>(X?document.addEventListener("click",J):document.removeEventListener("click",J),()=>{document.removeEventListener("click",J)})),[X]);const et="Free"==(0,c.Svj)(j)&&"portrait"==r;return(0,v.jsxs)(s.xu,{width:"full",height:"full",borderRadius:"md",children:[t.isQuestionVisible&&(0,v.jsx)(Lt.u,{userInteractionType:N.K.QUESTION_VIEWED,userInteractionMetadata:{questionId:null===(e=t.questionList)||void 0===e||null===(i=e[t.qIndex])||void 0===i?void 0:i.id},triggerFlag:!p&&!x,children:(0,v.jsx)(Pe,{questionList:t.questionList,questionIndex:t.qIndex,setIsQuestionVisible:t.setIsQuestionVisible})}),X&&(0,v.jsx)("div",{ref:tt,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,v.jsx)(Ce,{shareText:$,setShareText:Q,iconSize:Y,isModalOpen:X,setIsModalOpen:G})}),(!t.isQuestionVisible||t.qIndex>=(null===t||void 0===t||null===(o=t.questionList)||void 0===o?void 0:o.length))&&(0,v.jsxs)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"space-between",children:[(0,v.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:[C.showVideoPlayingData?(0,v.jsx)(s.Kq,{direction:"row",width:"100%",height:"fit-content",marginTop:"5px",justifyContent:"center",children:(0,v.jsx)(se,{progress:de(A.current_time,A.video_duration),totalSiblings:K,indexAmongSiblings:W})}):(0,v.jsx)(v.Fragment,{}),(0,v.jsx)(s.xu,{width:"full",margin:"2px",marginTop:"5px",children:(0,v.jsxs)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",paddingRight:"10px",paddingLeft:"10px",children:[(0,v.jsx)(Oe,{event:E,width:_}),(0,v.jsxs)(s.Kq,{direction:"row",width:"fit-content",justifyContent:"end",paddingLeft:"10px",children:[(0,mt.ZK)(b)?(0,v.jsx)(xe,{whatmoreShareTemplateId:(0,mt.QN)(b),whatmoreShareStoryId:O,whatmoreShareEventId:E.event_id,event:E,showShareText:!1,iconSize:.07*_,shareButtonBottomMargin:6,setIsModalOpen:G,setShareText:Q}):(0,v.jsx)(v.Fragment,{}),(0,v.jsx)(y,{focusRef:M}),("landscape"!==r||t.showCloseOverlay)&&(0,v.jsx)(P.Z,{event:E,onCloseCallback:L})]})]})})]}),(0,v.jsxs)(s.Kq,{width:"100%",height:"100%",direction:"row",justifyContent:"center",children:[(0,v.jsx)(s.xu,{width:"33%",height:"100%",onClick:()=>{Z()},sx:{display:"block !important"}}),(0,v.jsx)(s.xu,{width:"34%",height:"100%",onClick:()=>{H()},sx:{display:"block !important"}}),(0,v.jsx)(s.xu,{width:"33%",height:"100%",onClick:()=>{U()},sx:{display:"block !important"}})]}),(0,v.jsxs)(s.xu,{width:"full",height:"fit-content",children:[C.totalEvents>1&&!f&&C.showSwipeIndicator?(0,v.jsx)(s.xu,{width:"full",margin:"2px",children:(0,v.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"center",children:(0,v.jsx)(D,{swipeUp:!z})})}):null,(0,v.jsxs)(s.xu,{width:"fit-content",height:"fit-content",position:"absolute",right:0,bottom:"25%",children:[(0,c.slY)(j)&&!(0,mt.ZK)(b)?(0,v.jsx)(s.xu,{ml:"auto",width:"fit-content",paddingY:"12px",paddingX:"8px",position:"relative",top:"-30px",children:(0,v.jsxs)(s.Kq,{gap:"4px",direction:"column",alignItems:"center",cursor:"pointer",onClick:function(){var t;p||x||(async()=>{(0,l.lY)(E,1)})(),(0,q.GF)({userInteractionType:N.K.WHATSAPP_ICON_CLICKED,widgetSourceDetails:B,event:E,productList:null===E||void 0===E?void 0:E.products,ctaList:null===E||void 0===E?void 0:E.cta});const e=E.products.map((t=>`${t.product_link} \n`)),i=(0,c.gtK)(j),n=`Hey, I am interested in ${E.products.length>1?"these products":"this product"} I saw on ${null===(t=E.products[0])||void 0===t?void 0:t.brand} store: \n${e}. Could you please help me with some queries?`;window.open(i+`&text=${n}&type=phone_number`,"_blank")},children:[(0,v.jsx)(fe,{iconSize:.7*Y,style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,v.jsx)(s.xv,{fontSize:Y*(0,c.Xod)(j)+"px",fontWeight:"bold",align:"center",style:{marginTop:0},sx:{fontFamily:T+" !important",color:"white !important"},children:(0,c.UiZ)(j)})]})}):(0,v.jsx)(v.Fragment,{}),(0,c.jY3)(j)?(0,v.jsx)(s.xu,{width:"full",height:"fit-content",paddingX:"12px",position:"relative",top:"-30px",children:(0,v.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,v.jsx)(ge,{event:E})})}):(0,v.jsx)(v.Fragment,{}),(0,c.ROU)(j)&&!(0,mt.ZK)(b)?(0,v.jsx)(s.xu,{width:"full",height:"fit-content",paddingX:"12px",position:"relative",top:"-30px",children:(0,v.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,v.jsx)(xe,{whatmoreShareTemplateId:(0,mt.QN)(b),whatmoreShareStoryId:O,whatmoreShareEventId:E.event_id,event:E,setIsModalOpen:G,setShareText:Q})})}):(0,v.jsx)(v.Fragment,{})]}),(0,zt.kT)(E)?(0,v.jsxs)(s.xu,{width:"full",children:[(0,c.Jm1)(j)?(0,v.jsx)(s.xu,{w:"100%",children:(0,v.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,v.jsx)(F,{event:E,onToggle:t=>{g("minimize-button"!==t)}})})}):(0,v.jsx)(v.Fragment,{}),(0,v.jsx)(s.xu,{display:"flex",width:"100%",height:"fit-content",children:(0,v.jsx)(Dt,{event:E,productClickHandler:R})})]}):(0,v.jsx)(v.Fragment,{})]}),et&&(0,v.jsx)(s.Kq,{direction:"row",width:"100%",height:"fit-content",bg:"rgba(52, 52, 52, 0.9)",py:"3px",justifyContent:"center",children:(0,v.jsx)(be,{brandName:null===E||void 0===E?void 0:E.brand,fontSize:.033*_})})]})]})},Le=i(2279),Me=i.n(Le),De=i(342);var Re=function(t){var e,i,o,r,l,a,[d,m,g,f]=(0,h.Z)();const[w,j]=(0,n.useState)(!1),[y,C]=(0,n.useState)(),[b,S]=(0,n.useState)(),[I,k]=(0,n.useState)({current_time:0,video_duration:0,is_video_ended:!1}),_=(0,u.MO)("whatmoreShopId"),T=t.event,F=t.storyId,E=t.onBack,P=n.useRef(),O=t.isPlaying,z=t.isLast,L=t.setLockSwiper,M=t.onVideoEndedCallback,D=t.progressUpdateCallback,R=null!==(e=t.totalSiblingEvents)&&void 0!==e?e:0,A=null!==(i=t.indexAmongSiblings)&&void 0!==i?i:0,K=null===(o=t.showOverlay)||void 0===o||o,W=null!==(r=t.leftOpenSpaceClickHandler)&&void 0!==r?r:()=>{},Z=null!==(l=t.midOpenSpaceClickHandler)&&void 0!==l?l:()=>{},H=null!==(a=t.rightOpenSpaceClickHandler)&&void 0!==a?a:()=>{},{whatmoreWidgetSourceDetails:U}=(0,n.useContext)(V.I),{questionList:B}=(0,n.useContext)(wi),Y=(null===B||void 0===B?void 0:B.length)>0?parseInt(localStorage.getItem("_whatmore_qview_index")):1e4,[X,G]=(0,n.useState)();(0,n.useEffect)((()=>{G(t.showQuestion)}),[t.showQuestion]);const $="center";let Q;try{Q=Me()((()=>{M()}),1e3,{leading:!0,trailing:!1})}catch(J){console.log(J)}return(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:f,height:g,sx:{overflow:"hidden"},children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:$,height:"full",width:"full",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,v.jsx)(s.oM,{width:"full",ratio:f/g,children:(0,v.jsx)(x.Z,{height:"100%",width:"100%",url:(0,ce.V)((0,De.uv)(T)),isPlaying:O&&(!X||Y>=B.length),timeUpdateCallback:function(t,e){const i=de(t,e);D({watch_time:t,video_duration:e});const n=I.is_video_ended;i>=99&&O&&!n?(Q(),k({current_time:t,video_duration:e,is_video_ended:!0})):k({current_time:t,video_duration:e,is_video_ended:n})},event:T,question:X&&Y<(null===B||void 0===B?void 0:B.length),source:t.source})})})}),K?(0,v.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:$,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,v.jsx)(ze,{focusRef:P,event:t.event,isLast:z,onCloseCallback:t=>{E(t),(0,q.Z2)({userInteractionType:N.K.VIDEO_PLAYBACK,userInteractionMetadata:{watch_time:I.current_time,video_duration:I.video_duration},widgetSourceDetails:U,event:T,productList:T.products,ctaList:T.cta})},productClickHandler:async t=>{const e=await(0,p.p)(t,(0,c.Ipo)(_),_);S(t),C(e),j(!0),L(!0),(0,q.GF)({userInteractionType:N.K.SHOPNOW_CLICKED,widgetSourceDetails:U,event:T,productList:T.products,ctaList:T.cta}),(0,u.bU)("whatmoreAllowAutoSlide",!1)},videoPlayingData:I,totalSiblingEvents:R,indexAmongSiblings:A,questionList:B,isQuestionVisible:X&&Y<(null===B||void 0===B?void 0:B.length),qIndex:Y,setIsQuestionVisible:G,leftOpenSpaceClickHandler:W,midOpenSpaceClickHandler:Z,rightOpenSpaceClickHandler:H,storySetId:F,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay})})}):(0,v.jsx)(v.Fragment,{}),!0===w?(0,v.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"200%"},direction:"column",justifyContent:$,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,v.jsx)(le,{focusRef:P,event:t.event,isLast:z,onCloseCallback:()=>E(),setLockSwiper:L,data:y,currentProduct:b,setOpenShopNow:t=>{j(t),(0,u.bU)("whatmoreAllowAutoSlide",!t)}})})}):(0,v.jsx)("div",{})]})})},Ae=i(7300),Ke=i(8984),We=i(58),qe=i(9723);var Ne=function(t){var[e,i,n,o]=(0,h.Z)();const r=(0,u.MO)("whatmoreShopId"),l=t.event,a=t.isPlaying,d="center";return(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:o,height:n,sx:{overflow:"hidden"},children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:d,height:"full",width:"full",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,v.jsx)(s.oM,{width:"full",ratio:o/n,children:(0,v.jsx)(x.Z,{height:"100%",width:"100%",url:(0,ce.V)((0,De.uv)(l)),isPlaying:a,timeUpdateCallback:function(t,e){},event:l,source:t.source})})})}),(0,v.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,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",backdropFilter:"auto",backdropBlur:"10px",onClick:t=>{(0,We.QV)()},children:(0,v.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"full",width:"full",children:[(0,v.jsx)(qe.Z,{sx:{boxShadow:3,color:(0,c.Ya_)(r),fontSize:.4*o,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{(0,We.QV)()}}),(0,v.jsx)(s.xv,{color:"white",fontSize:.05*o+"px",fontWeight:"bold",align:"left",children:"Please click to play video.."})]})})})]})})},Ve=i(3433);const Ze=n.lazy((()=>i.e(824).then(i.bind(i,5824))));var He=function(t){var e,i;const n=t.event,o=null===(e=t.isPlaying)||void 0===e||e,r=t.onBack,l=t.isLast,s=t.setLockSwiper,c=(t.heightFactor,t.widthFactor,t.onVideoEndedCallback),h=t.progressUpdateCallback,[p,x]=(0,j.Z)(),[m]=(0,u.j1)("whatmoreVideoPlayerPoolBlessed"),g=null===(i=t.showOverlay)||void 0===i||i;function f(){x(!p)}if((0,Ke.KE)()&&0==m&&"recommended_images"!=(null===n||void 0===n?void 0:n.event_type))return(0,v.jsx)(Ne,{event:n,onBack:r,isPlaying:o,isLast:l,setLockSwiper:s,onVideoEndedCallback:c,progressUpdateCallback:h,totalSiblingEvents:1,indexAmongSiblings:0,leftOpenSpaceClickHandler:()=>{f()},midOpenSpaceClickHandler:()=>{f()},rightOpenSpaceClickHandler:()=>{f()},showOverlay:g,source:Ve.j.CAROUSEL_EVENT_OPENED},"shopping-video-view"+n.event_id);if((0,Ae.B6)(n)||(0,Ae.WJ)(n))return(0,v.jsx)(Re,{event:n,onBack:r,isPlaying:o,isLast:l,setLockSwiper:s,onVideoEndedCallback:c,progressUpdateCallback:h,showQuestion:t.showQuestion,totalSiblingEvents:1,indexAmongSiblings:0,leftOpenSpaceClickHandler:()=>{f()},midOpenSpaceClickHandler:()=>{f()},rightOpenSpaceClickHandler:()=>{f()},showOverlay:g,source:Ve.j.CAROUSEL_EVENT_OPENED,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay},"shopping-video-view"+n.event_id);if("recommended_images"==(null===n||void 0===n?void 0:n.event_type))return(0,v.jsx)(Ze,{onBack:r,mode:t.mode,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay,imageUrls:null===n||void 0===n?void 0:n.product_list});if((0,Ae.yC)(n)){var{status:w,bannerText:y,timeToStartInMins:C}=d.Z.getEventStatus(n);if(w.name===a.Z.LIVE.name)return(0,v.jsx)(ae,{event:n,onBack:r,isPlaying:o,isLast:l,showOverlay:g},"shopping-live-view"+n.event_id)}return console.error("Can't render event which is neither video or a currently-live-event"),(0,v.jsx)("div",{})},Ue=i(9284),Be=i.n(Ue),Ye=i(7463),Xe=i(2154);function Ge(t){var e;const[i,o]=(0,n.useState)(!1),r=t.onClick,l=null!==(e=t.fontSize)&&void 0!==e?e:50;return(0,v.jsx)("div",{style:{height:"fit-content",width:"fit-content",backgroundColor:"black",opacity:.4,borderRadius:"50%"},className:[i?"whatmore-scale-on-tap":""].join(" "),children:"left"===t.type?(0,v.jsx)(Xe.Z,{sx:{color:"white",fontSize:l+"px",filter:"drop-shadow(0 0 5px black);"},onClick:t=>{o(!0),setTimeout((()=>{o(!1)}),500),r(t,"up")}}):(0,v.jsx)(Ye.Z,{sx:{color:"white",fontSize:l+"px",filter:"drop-shadow(0 0 5px black);"},onClick:t=>{o(!0),setTimeout((()=>{o(!1)}),500),r(t,"down")}})})}var $e=function(t){var e,i,n;const o=null!==(e=t.relativeBottomPercentage)&&void 0!==e?e:"30%",r=null!==(i=t.width)&&void 0!==i?i:"100%",l=null!==(n=t.fontSize)&&void 0!==n?n:50,a=t.handleClick;return(0,v.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,v.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,v.jsx)(Ge,{type:"left",onClick:a,fontSize:l}),(0,v.jsx)(Ge,{type:"right",onClick:a,fontSize:l})]})})},Qe=i(2860),Je=i(4669);var ti=function(t,e){function i(t,e){return 1==e?0:t<0?e+t:t>=e?t-e:t}const o=(0,n.useRef)({prevIndex:i(t-1,e),activeIndex:t,nextIndex:i(t+1,e)});return[function(){return o.current},function(t){o.current="right"==t?{prevIndex:i(o.current.activeIndex,e),activeIndex:i(o.current.activeIndex+1,e),nextIndex:i(o.current.activeIndex+2,e)}:{prevIndex:i(o.current.activeIndex-2,e),activeIndex:i(o.current.activeIndex-1,e),nextIndex:i(o.current.activeIndex,e)}},function(t){return i(o.current.activeIndex+t)}]};var ei=function(t,e){const i=(0,n.useRef)({clientX:0,clientY:0});return[function(t){i.current.clientX=t.changedTouches[0].clientX,i.current.clientY=t.changedTouches[0].clientY},function(n){const o=i.current.clientX,r=i.current.clientY;var l=o-n.changedTouches[0].clientX,a=r-n.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 ii=function(t,e){const i=(0,n.useRef)(Me()(((t,e)=>{t(e)}),300,{leading:!0,trailing:!1}));return[function(n,o){var r=0;if(r="vertical"==t?n.deltaY:n.deltaX,Math.abs(r)<=e)return;const l=r>0?"right":"left";i.current(o,l)}]},ni=i(5173);var oi=function(t){const e=t.events,i=t.eventIndex,a=t.onBack;var[d,p,x,m]=(0,h.Z)();const[g]=(0,u.j1)("isInDesignMode"),[f]=(0,u.j1)("isDemoBrand"),[w,j]=(0,n.useState)(!0),[y,C]=(0,u.j1)("isFirstIndicatorRenderDone"),[b,S]=(0,n.useState)(!1),[I,k]=(0,n.useState)({}),{setCloseClickComponent:_}=(0,n.useContext)(wi),{slideDirection:T}=(0,n.useContext)(wi),[F]=(0,u.j1)("whatmoreShopId"),[E]=(0,u.j1)("whatmoreLandingLocationType"),[P,O]=ti(i,e.length),[z,L]=ei(T,50),[M]=ii("vertical",30),[D,R]=(0,n.useState)(!1),[A,W]=(0,n.useState)(null),{whatmoreWidgetSourceDetails:Z,whatmoreUserInfo:H}=(0,n.useContext)(V.I);function U(){R(!1)}function B(t){U(),setTimeout((()=>{a(t)}),500)}(0,n.useEffect)((()=>(R(!0),()=>{})),[]);const Y=Z.landingLocationType,X=Z.templateType;_(B);let G=i;const{questionList:$}=(0,n.useContext)(wi);function Q(){(0,u.MO)("whatmoreAllowAutoSlide")&&(O("right"),A.slideNext())}function J(t,e){O(e),function(t,e){A&&("left"===e?A.slidePrev():A.slideNext())}(0,e)}const tt=Math.round(.05*x);return(0,v.jsx)(Be(),{isOpen:D,onAfterOpen:function(){},onRequestClose:U,overlayClassName:"whatmore-modal",className:"whatmore-modal-content",ariaHideApp:!1,children:(0,v.jsx)(ni.Z,{children:(0,v.jsxs)("div",{style:{height:window.innerHeight,width:window.innerWidth,backgroundColor:(0,K.lA)("#000000",13)},onTouchStart:t=>{z(t)},onTouchEnd:t=>{if(b)return;const e=L(t);e&&J(0,e)},onWheel:t=>{b||M(t,(t=>{J(0,t)}))},children:[(0,v.jsx)(o.tq,{speed:400,threshold:tt,slidesPerView:1,direction:T,modules:[r.tl,r.Gk],initialSlide:i,loop:1!=e.length,height:window.innerHeight,width:window.innerWidth,watchSlidesProgress:!0,allowSlideNext:!b,allowSlidePrev:!b,allowTouchMove:!1,onSwiper:t=>{W(t),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:Z,event:e[P().activeIndex],productList:e[P().activeIndex].products})},onSlideChange:t=>{var i;w?j(!1):(y||C(!0),(0,q.Z2)({userInteractionType:N.K.VIDEO_PLAYBACK,userInteractionMetadata:I,widgetSourceDetails:Z,event:e[P().activeIndex],productList:e[P().activeIndex].products}),i=e[P().activeIndex],g||f||null===i||void 0===i||!i.event_id||(async()=>{const t=(0,mt.NY)(Y)+(0,mt.dS)(X)+"_"+(null===i||void 0===i?void 0:i.event_id);(0,l.wh)(i),"index"===E?((0,Je.Tc)(F,Qe.Xh,Qe.pR),(0,ot.H4)(i.event_id,i.products,Qe.Xh,Qe.pR,t,null===i||void 0===i?void 0:i.location,null===H||void 0===H?void 0:H.userType)):E.startsWith("product")||"embed"===E?((0,Je.Tc)(F,Qe.h7,Qe.dU),(0,ot.H4)(i.event_id,i.products,Qe.h7,Qe.dU,t)):E.startsWith("collection")?((0,Je.Tc)(F,Qe.U$,Qe.Pk),(0,ot.H4)(i.event_id,i.products,Qe.U$,Qe.Pk,t)):((0,Je.Tc)(F,Qe.Xh,Qe.pR),(0,ot.H4)(i.event_id,i.products,Qe.Xh,Qe.pR,t))})(),(0,q.y4)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:Z,event:e[P().activeIndex],productList:e[P().activeIndex].products}))},children:[...Array(Math.min(e.length,3)).keys()].map((n=>(0,v.jsx)(o.o5,{children:n=>{let{isActive:o,isPrev:r,isNext:l,isVisible:a,isDuplicate:d}=n;const u=o?"activeIndex":r?"prevIndex":"nextIndex",h=P()[u];"activeIndex"==u&&(G=Math.max(G,h),0==h&&(G=0));const p=(null===$||void 0===$?void 0:$.length)>0&&o&&a&&(h>i||G<i&&h>0)&&h>=G&&h%(0,c.rFm)(F)==i%(0,c.rFm)(F);return(0,v.jsx)(s.Kq,{direction:"column",height:window.innerHeight,justifyContent:"center",children:(0,v.jsx)(He,{event:e[h],showQuestion:p,onBack:B,isPlaying:1==e.length||o&&a,isLast:!1,setLockSwiper:S,onVideoEndedCallback:Q,progressUpdateCallback:t=>{k(t)},showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay,mode:"portrait"})})}},"event-vertical-scroll-slide-"+n)))}),e.length>1&&!b&&(0,c.h6H)(F)&&"horizontal"===(0,c.e8z)(F)&&"horizontal"===T?(0,v.jsx)($e,{relativeBottomPercentage:"50%",width:m,handleClick:(t,e)=>{J(0,"down"==e?"right":"left")},fontSize:parseInt(.12*m)}):(0,v.jsx)(v.Fragment,{})]})})})},ri=i(1168);i(6143),i(7850),i(4444),i(7244),i(123),i(5892),i(1811);const li=t=>{let{children:e,customClass:i,show:n,closeCallback:o}=t;return ri.createPortal((0,v.jsxs)("div",{className:`whatmore-landscape-modal whatmore-root ${i}`,style:{display:n?"block":"none"},children:[(0,v.jsx)("div",{className:"whatmore-landscape-modal-overlay",onClick:o}),(0,v.jsx)("div",{className:"whatmore-landscape-modal-content",children:e})]}),document.body)};li.defaultProps={children:(0,v.jsx)("div",{children:"Empty Modal"}),customClass:"",show:!1,closeCallback:()=>!1};var ai=li;var di=function(t){var e,[i,a,d,p]=(0,h.Z)();const[x]=(0,u.j1)("isInDesignMode"),[m]=(0,u.j1)("isDemoBrand"),[g,f]=(0,u.j1)("isFirstIndicatorRenderDone"),[w,j]=(0,n.useState)(0!=t.eventIndex),{setCloseClickComponent:y}=(0,n.useContext)(wi),[C,b]=(0,n.useState)(!1),[S]=(0,u.j1)("whatmoreShopId"),[I]=(0,u.j1)("whatmoreLandingLocationType"),k=(0,u.MO)("whatmoreUITheme"),{whatmoreWidgetSourceDetails:_,whatmoreUserInfo:T}=(0,n.useContext)(V.I),[F,E]=(0,n.useState)(!1),[O,z]=(0,n.useState)(null);function L(){E(!1)}const M=t.events,D=t.eventIndex,R=t.onBack,A=M.concat(M),W=M.length,Z=null===M||void 0===M||null===(e=M[0])||void 0===e?void 0:e.brand,H=(0,n.useRef)(0);function U(t){L(),setTimeout((()=>{R(t)}),500)}function B(){O&&!O.isEnd&&(0,u.MO)("whatmoreAllowAutoSlide")&&O.slideNext()}(0,n.useEffect)((()=>(E(!0),()=>{})),[]),y(U);const Y=_.landingLocationType,X=_.templateType,[G,$]=(0,n.useState)({}),Q=parseInt(Math.min(5,M.length));return(0,v.jsx)(ai,{show:F,closeCallback:L,customClass:"whatmore-landscape-modal-swipe-view",children:(0,v.jsxs)(s.Kq,{direction:"column",width:window.innerWidth,height:window.innerHeight,justifyContent:"center",aligntItems:"center",backgroundColor:(0,K.lA)("#000000",13),children:[(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.xu,{height:"fit-content",width:p*Q,children:(0,v.jsxs)(o.tq,{onInit:t=>{z(t),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:_,event:M[t.activeIndex],productList:M[t.activeIndex].products,ctaList:M[t.activeIndex].cta})},slidesPerView:Q,centeredSlides:!0,allowTouchMove:!1,initialSlide:D,modules:[r.lI,r.W_,r.Gk,r.pt,r.tl],navigation:Q>=5,effect:"coverflow",coverflowEffect:{rotate:-8,stretch:Math.floor(.22*d),depth:100,scale:.7,modifier:1,slideShadows:!1},height:"fit-content",width:p*Q,watchSlidesProgress:!0,onSlideChange:t=>{var e;w?j(!1):(g||f(!0),e=M[t.activeIndex],x||m||null===e||void 0===e||!e.event_id||(async()=>{const t=(0,mt.NY)(Y)+(0,mt.dS)(X)+"_"+(null===e||void 0===e?void 0:e.event_id);(0,l.wh)(e),"index"===I?((0,Je.Tc)(S,Qe.Xh,Qe.pR),(0,ot.H4)(e.event_id,e.products,Qe.Xh,Qe.pR,t,null===e||void 0===e?void 0:e.location,null===T||void 0===T?void 0:T.userType)):I.startsWith("product")||"embed"===I?((0,Je.Tc)(S,Qe.h7,Qe.dU),(0,ot.H4)(e.event_id,e.products,Qe.h7,Qe.dU,t)):I.startsWith("collection")?((0,Je.Tc)(S,Qe.U$,Qe.Pk),(0,ot.H4)(e.event_id,e.products,Qe.U$,Qe.Pk,t)):((0,Je.Tc)(S,Qe.Xh,Qe.pR),(0,ot.H4)(e.event_id,e.products,Qe.Xh,Qe.pR,t))})(),(0,q.Z2)({userInteractionType:N.K.VIDEO_PLAYBACK,userInteractionMetadata:G,widgetSourceDetails:_,event:M[t.activeIndex],productList:M[t.activeIndex].products,ctaList:M[t.activeIndex].cta}),(0,q.y4)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:_,event:M[t.activeIndex],productList:M[t.activeIndex].products,ctaList:M[t.activeIndex].cta}))},mousewheel:{invert:!1,thresholdDelta:20},children:[M.length>2&&(0,v.jsx)("div",{className:"whatmore-shopping-close-button",children:(0,v.jsx)(P.Z,{onCloseCallback:R})}),A.slice(D,M.length+D).map(((t,e)=>(0,v.jsx)(o.o5,{children:t=>{let{isActive:i,isPrev:n,isNext:o,isVisible:r,isDuplicate:l}=t;if(i)return(0,v.jsx)(s.Kq,{direction:"column",height:d,width:1*p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",children:(0,v.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,v.jsx)(He,{event:M[e%W],onBack:U,isPlaying:!0,isLast:e%W===M.length-1,setLockSwiper:b,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{$(t)},showCloseOverlay:(null===M||void 0===M?void 0:M.length)<=2,mode:"landscape"})})});if(o)return(0,v.jsx)(s.Kq,{direction:"column",height:d,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{O.slideTo(e%W,300)},children:(0,v.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,v.jsx)(He,{event:M[e%W],onBack:U,isPlaying:!1,isLast:e%W===M.length-1,setLockSwiper:b,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{$(t)},showOverlay:!1,mode:"landscape"})})});if(n&&1===H.current)return(0,v.jsx)(s.Kq,{direction:"column",height:d,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{O.slideTo(e%W,300)},children:(0,v.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,v.jsx)(He,{event:M[e%W],onBack:U,isPlaying:!1,isLast:e%W===M.length-1,setLockSwiper:b,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{$(t)},showOverlay:!1,mode:"landscape"})})});try{D+e>=W-1&&(H.current=1)}catch(a){console.log(a)}return(0,v.jsx)(v.Fragment,{})}},"event-horizontal-scroll-slide"+t.event_id)))]})})}),(0,v.jsx)(s.M5,{children:(0,v.jsx)(be,{brandName:Z,height:.04*d,width:.1*p,fontSize:.02*d})})]})})},si=i(6090),ci=i(7616),ui=i(9302),hi=i(2575);var pi=function(t){const[e,i,n,o]=(0,h.Z)(),[r]=(0,u.j1)("whatmorePrimaryColor"),[l]=(0,u.j1)("whatmoreSecondaryColor"),a="flex-end";return(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:o,height:n,backgroundColor:"whiteAlpha.200",backdropBlur:"10px",children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:a,height:"full",width:"full",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",children:(0,v.jsx)(s.oM,{width:"full",ratio:o/n,children:(0,v.jsx)(s.xu,{w:"100%",h:"100%",bgGradient:"linear(to-br, "+r+", gray, "+l+")"})})})}),(0,v.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,v.jsx)(s.xu,{padding:"2px",margin:"5px",borderRadius:"md",backgroundColor:"transparent",children:(0,v.jsx)(s.oM,{width:"full",ratio:9/16,children:(0,v.jsx)(s.xu,{width:"full",height:"full",borderRadius:"md",backdropFilter:"auto",backdropBlur:"5px"})})})})]})})};var xi=function(t){var e;const i=t.stories,r=t.onBack,a=t.onStoryCompleteCallback,d=t.isActive,c=null!==(e=t.initialEventIndex)&&void 0!==e?e:0,p=i.events;var[x,m,g,f]=(0,h.Z)();const[w,y]=(0,j.Z)(),[C]=(0,u.j1)("isInDesignMode"),[b]=(0,u.j1)("isDemoBrand"),[S]=(0,u.j1)("whatmoreShopId"),[I,k]=(0,n.useState)(!0),[_,T]=(0,u.j1)("isFirstIndicatorRenderDone"),[F,E]=(0,n.useState)(null),[P,O]=(0,n.useState)(!1),{whatmoreWidgetSourceDetails:z,whatmoreUserInfo:L}=(0,n.useContext)(V.I),[M,D]=ti(c,p.length);function R(t){r(t)}const A=z.landingLocationType,K=z.templateType;function W(){if(!(0,u.MO)("whatmoreAllowAutoSlide"))return;M().activeIndex+1>=p.length?a("right"):(D("right"),F&&F.slideNext())}function Z(t){const e=M().activeIndex;"right"==t&&e+1>=p.length||"left"==t&&e-1<0?a(t):(D(t),F&&("left"==t?F.slidePrev():F.slideNext()))}const[H,U]=(0,n.useState)({});return p[M().activeIndex],(0,v.jsx)("div",{children:(0,v.jsx)(o.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):(_||T(!0),(0,q.Z2)({userInteractionType:N.K.VIDEO_PLAYBACK,userInteractionMetadata:H,widgetSourceDetails:z,event:p[M().activeIndex],productList:p[M().activeIndex].products,ctaList:p[M().activeIndex].cta}),function(t){const e=(0,mt.NY)(A)+(0,mt.dS)(K)+"_"+(null===t||void 0===t?void 0:t.event_id);C||b||(async()=>{(0,l.wh)(t),(0,Je.Tc)(S,Qe.Xh,Qe.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===L||void 0===L?void 0:L.userType)})()}(p[M().activeIndex]),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:z,event:p[M().activeIndex],productList:p[M().activeIndex].products,ctaList:p[M().activeIndex].cta}))},children:[...Array(Math.min(p.length,3)).keys()].map((e=>(0,v.jsx)(o.o5,{children:e=>{let{isActive:n,isPrev:o,isNext:r,isVisible:l,isDuplicate:a}=e;if(d){const e=n?"activeIndex":o?"prevIndex":"nextIndex",r=p[M()[e]];return(0,v.jsx)(s.Kq,{direction:"column",height:g,justifyContent:"center",children:(0,Ae.B6)(r)||(0,Ae.WJ)(r)?(0,v.jsx)(Re,{event:r,totalSiblingEvents:p.length,indexAmongSiblings:M()[e],onBack:R,isPlaying:d&&n&&l,isLast:!1,setLockSwiper:O,onVideoEndedCallback:W,progressUpdateCallback:t=>{U(t)},leftOpenSpaceClickHandler:()=>{Z("left")},midOpenSpaceClickHandler:()=>{y(!w)},rightOpenSpaceClickHandler:()=>{Z("right")},storyId:i.id,source:Ve.j.STORY_EVENT_OPENED,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay},"shopping-video-view"+r.event_id):(0,v.jsx)(v.Fragment,{})})}return(0,v.jsx)(s.Kq,{direction:"column",height:x,justifyContent:"center",children:(0,v.jsx)(pi,{})})}},"event-story-view-slide-"+e)))})})};var vi=function(t){const e=t.onBack,i=t.eventsStories,a=t.initialStoryIndex;var[d,c,p,x]=(0,h.Z)();const[m]=(0,u.j1)("isInDesignMode"),[g]=(0,u.j1)("isDemoBrand"),[f,w]=(0,n.useState)(!0),[j,y]=(0,u.j1)("isFirstIndicatorRenderDone"),[C,b]=(0,n.useState)(!1),{setCloseClickComponent:S}=(0,n.useContext)(wi),{slideDirection:I}=(0,n.useContext)(wi),[k]=(0,u.j1)("whatmoreShopId"),[_,T]=ti(a,i.length),[F,E]=ei("horizontal",50),[P]=ii("vertical",30),O=t.eventIndex,[z,L]=(0,n.useState)(!1),[M,D]=(0,n.useState)(null),{whatmoreWidgetSourceDetails:R,whatmoreUserInfo:A}=(0,n.useContext)(V.I);function K(){L(!1)}function W(t){K(),setTimeout((()=>{e(t)}),500)}(0,n.useEffect)((()=>(L(!0),()=>{})),[]),S(W);const Z=R.landingLocationType,H=R.templateType;function U(t){M&&(0,u.MO)("whatmoreAllowAutoSlide")&&(T(t),"right"==t?M.slideNext():M.slidePrev())}function B(t,e){U(e)}return(0,v.jsx)(Be(),{isOpen:z,onAfterOpen:function(){},onRequestClose:K,overlayClassName:"whatmore-modal",className:"whatmore-modal-content",ariaHideApp:!1,children:(0,v.jsx)("div",{style:{height:window.innerHeight,width:window.innerWidth,backgroundColor:"#00000088"},onTouchStart:t=>{F(t)},onTouchEnd:t=>{const e=E(t);e&&B(0,e)},onWheel:t=>{P(t,(t=>{B(0,t)}))},children:(0,v.jsx)(o.tq,{speed:1,slidesPerView:1,direction:"horizontal",modules:[r.SH,r.Gk],initialSlide:a,loop:i.length>1,height:window.innerHeight,width:window.innerWidth,watchSlidesProgress:!0,onSwiper:t=>{var e,n;D(t),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:R,event:i[_().activeIndex].events[0],productList:null===(e=i[_().activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(n=i[_().activeIndex].events[0])||void 0===n?void 0:n.cta})},onSlideChange:t=>{var e,n;f?w(!1):(!function(t){const e=(0,mt.NY)(Z)+(0,mt.dS)(H)+"_"+(null===t||void 0===t?void 0:t.event_id);m||g||(async()=>{(0,l.wh)(t),(0,Je.Tc)(k,Qe.Xh,Qe.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===A||void 0===A?void 0:A.userType)})()}(i[_().activeIndex].events[0]),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:R,event:i[_().activeIndex].events[0],productList:null===(e=i[_().activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(n=i[_().activeIndex].events[0])||void 0===n?void 0:n.cta}))},allowTouchMove:!1,cubeEffect:{shadow:!0,slideShadows:!0,shadowOffset:20,shadowScale:.94},children:[...Array(Math.min(i.length,3)).keys()].map((t=>(0,v.jsx)(o.o5,{children:t=>{let{isActive:e,isPrev:n,isNext:o,isVisible:r,isDuplicate:l}=t;const c=e?"activeIndex":n?"prevIndex":"nextIndex";return(0,v.jsx)(s.Kq,{direction:"column",height:d,justifyContent:"center",children:(0,v.jsx)(xi,{stories:i[_()[c]],onBack:W,isActive:e&&r,isNext:o,isPrev:n,onStoryCompleteCallback:U,nextStories:i[_().nextIndex],prevStories:i[_().prevIndex],initialEventIndex:a==_()[c]?O:0},"event-story-view-"+i[_()[c]].id)})}},"event-vertical-scroll-slide-"+t)))})})})};var mi=function(t){var e,i,o,[r,l,a,d]=(0,h.Z)();const[c]=(0,u.j1)("whatmorePrimaryColor"),[p]=(0,u.j1)("whatmoreSecondaryColor"),x=t.event,m=(t.onBack,n.useRef(),null!==(e=t.showPausedVideo)&&void 0!==e&&e),f=null!==(i=t.heightFactor)&&void 0!==i?i:1,w="flex-end";return d*=null!==(o=t.widthFactor)&&void 0!==o?o:1,a*=f,(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:d,height:a,children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:w,height:"full",width:"full",children:(0,v.jsx)(s.xu,{children:(0,v.jsx)(s.oM,{width:"full",ratio:9/16,children:m?(0,Ae.B6)(x)||(0,Ae.WJ)(x)?(0,v.jsx)(Se.Z,{height:"100%",width:"100%",url:x.thumbnail_image,isPlaying:!1,pauseFromPlayTimeInMs:1e3,event:x}):(0,v.jsx)(g.Ee,{width:"full",height:"full",src:x.thumbnail_image,objectFit:"cover",borderRadius:"lg"}):(0,v.jsx)(s.xu,{w:"100%",h:"100%",bgGradient:"linear(to-br, "+c+", gray, "+p+")"})})})}),(0,v.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,v.jsx)(s.xu,{children:(0,v.jsx)(s.oM,{width:"full",ratio:9/16,children:(0,v.jsx)(s.xu,{width:"full",height:"full",backgroundColor:"blackAlpha.400"})})})})]})})};var gi=function(t){var e,i,[a,d,c,p]=(0,h.Z)();const[x]=(0,u.j1)("isInDesignMode"),[m]=(0,u.j1)("isDemoBrand"),[g,f]=(0,u.j1)("isFirstIndicatorRenderDone"),[w,j]=(0,n.useState)(0!=t.eventIndex),{setCloseClickComponent:y}=(0,n.useContext)(wi),[C,b]=(0,n.useState)(!1),[S]=(0,u.j1)("whatmoreShopId"),{whatmoreWidgetSourceDetails:I,whatmoreUserInfo:k}=(0,n.useContext)(V.I),[_,T]=(0,n.useState)(!1),[F,E]=(0,n.useState)(null);function O(){T(!1)}t.events;const z=t.eventIndex,L=t.onBack,M=t.eventsStories,D=t.initialStoryIndex,R=null===(e=M[0])||void 0===e||null===(i=e.events[0])||void 0===i?void 0:i.brand;function A(t){O(),setTimeout((()=>{L(t)}),500)}(0,n.useEffect)((()=>(T(!0),()=>{})),[]),y(A);const K=I.landingLocationType,W=I.templateType;function Z(t){F&&!F.isEnd&&("right"==t?F.slideNext():F.slidePrev())}const H=parseInt(Math.min(5,M.length));return(0,v.jsx)(ai,{show:_,closeCallback:O,customClass:"whatmore-landscape-modal-stories-view",children:(0,v.jsxs)(s.Kq,{direction:"column",width:window.innerWidth,height:window.innerHeight,justifyContent:"center",aligntItems:"center",backgroundColor:"blackAlpha.800",children:[(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.xu,{height:"fit-content",width:p*H,children:(0,v.jsxs)(o.tq,{onInit:t=>{var e,i;E(t),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:I,event:M[t.activeIndex].events[0],productList:null===(e=M[t.activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(i=M[t.activeIndex].events[0])||void 0===i?void 0:i.cta})},slidesPerView:H,centeredSlides:!0,allowTouchMove:!1,initialSlide:D,modules:[r.lI,r.W_,r.Gk],navigation:H>=5,effect:"coverflow",coverflowEffect:{rotate:-8,stretch:Math.floor(.22*c),depth:100,scale:.7,modifier:1,slideShadows:!1},height:"fit-content",width:p*H,watchSlidesProgress:!0,onSlideChange:t=>{var e,i;w?j(!1):(g||f(!0),function(t){const e=(0,mt.NY)(K)+(0,mt.dS)(W)+"_"+(null===t||void 0===t?void 0:t.event_id);x||m||(async()=>{(0,l.wh)(t),(0,Je.Tc)(S,Qe.Xh,Qe.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)})()}(M[t.activeIndex].events[0]),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:I,event:M[t.activeIndex].events[0],productList:null===(e=M[t.activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(i=M[t.activeIndex].events[0])||void 0===i?void 0:i.cta}))},mousewheel:{invert:!1,thresholdDelta:20},children:[M.length>2&&(0,v.jsx)("div",{className:"whatmore-shopping-close-button",children:(0,v.jsx)(P.Z,{onCloseCallback:L})}),M.map(((t,e)=>(0,v.jsx)(o.o5,{children:i=>{let{isActive:n,isPrev:o,isNext:r,isVisible:l,isDuplicate:a}=i;if(n){const i=1;return(0,v.jsx)(s.Kq,{direction:"column",height:c,width:p*i,justifyContent:"center",marginLeft:"auto",marginRight:"auto",children:(0,v.jsx)(s.xu,{borderRadius:"xl",overflow:"hidden",backgroundColor:"transparent",boxShadow:"dark-lg",children:(0,v.jsx)(xi,{stories:t,onBack:A,isActive:n&&l,isNext:!1,isPrev:!1,onStoryCompleteCallback:Z,initialEventIndex:D==e?z:0,showCloseOverlay:(null===M||void 0===M?void 0:M.length)<=2},"event-story-view-"+t.id)})})}return o||r?(0,v.jsx)(s.Kq,{direction:"column",height:c,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{F.slideTo(e,300)},children:(0,v.jsx)(s.xu,{borderRadius:"xl",overflow:"hidden",backgroundColor:"transparent",boxShadow:"dark-lg",children:(0,v.jsx)(mi,{showPausedVideo:!0,event:M[e].events[0],onBack:A,isPlaying:!1,setLockSwiper:b})})}):(0,v.jsx)(v.Fragment,{})}},"event-horizontal-scroll-slide-"+e)))]})})}),(0,v.jsx)(s.M5,{children:(0,v.jsx)(be,{brandName:R,height:.04*c,width:.1*p,fontSize:.02*c})})]})})};const fi=(0,hi.Z)({key:"whatmore-css-sv"}),wi=(0,n.createContext)({isIOS:!1,totalEvents:0,closeClickComponent:null,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:"vertical",showSwipeIndicator:!0,questionList:[]});var ji=function(t){var e,i,o;const[r,l,a]=(0,we.Z)(),[d]=(0,u.j1)("whatmoreShopId"),{whatmoreRootId:s}=(0,n.useContext)(V.I),{whatmoreIsStoriesTemplate:h}=(0,n.useContext)(V.I);var p=t.events,x=t.index,m=t.onBack,g=t.eventsStories,f=t.initialStoryIndex,w=(0,c.cX2)(d),j="portrait"===r?null!==(e=t.slideDirection)&&void 0!==e?e:"vertical":null!==(i=t.slideDirection)&&void 0!==i?i:p.length>1?"horizontal":"vertical",y="portrait"===r?!(0,c.h6H)(d)&&!h:(0,c.n89)(d);return(0,n.useLayoutEffect)((()=>{(0,c.TLG)(d)&&(window.location.href.includes(w)?history.replaceState(null,"","#"+w):history.pushState(null,"","#"+w),window.addEventListener("popstate",(()=>{window.location.href.includes(w)||m()})))}),[]),delete ci.ZP.styles.global,h?(0,v.jsx)(ui.C,{value:fi,children:(0,v.jsx)(si.x,{theme:ci.ZP,cssVarsRoot:s,resetCSS:!1,children:(0,v.jsx)(wi.Provider,{value:{isIOS:(0,Ke.KE)(),totalEvents:p.length,closeClickComponent:m,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:j,showSwipeIndicator:y},children:"portrait"===r?(0,v.jsx)(vi,{eventsStories:g,initialStoryIndex:f,onBack:m,eventIndex:x}):(0,c.Bbr)(d)?(0,v.jsx)(gi,{eventsStories:g,initialStoryIndex:f,onBack:m,eventIndex:x}):(0,v.jsx)(vi,{eventsStories:g,initialStoryIndex:f,onBack:m,eventIndex:x})})})}):(0,v.jsx)(ui.C,{value:fi,children:(0,v.jsx)(si.x,{theme:ci.ZP,cssVarsRoot:s,resetCSS:!1,children:(0,v.jsx)(wi.Provider,{value:{isIOS:(0,Ke.KE)(),totalEvents:p.length,closeClickComponent:m,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:j,showSwipeIndicator:y,questionList:(0,c.YGB)(d)?null===(o=JSON.parse(localStorage.getItem("_whatmore_brand_questions")))||void 0===o?void 0:o.questionList:[]},children:"portrait"===r?(0,v.jsx)(oi,{events:p,eventIndex:x,onBack:m}):(0,v.jsx)(di,{events:p,eventIndex:x,onBack:m})})})})}},9316:function(t,e,i){i.d(e,{mT:function(){return o}});var n=i(686);const o=`\n ${n.F4`
|
|
76
|
+
`} 0.5s`,bt=null===N||void 0===N||null===(e=N.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"))})),[St,It]=(0,n.useState)(-1!==bt?null===(i=N.options)||void 0===i||null===(o=i[bt])||void 0===o||null===(r=o.values)||void 0===r?void 0:r[0]:""),[kt,_t]=(0,n.useState)({});(0,n.useEffect)((()=>{-1!==bt&&"whatmore"!==(0,c.Ipo)(ft)&&async function(){const t=await(0,lt.m3)(Z);_t(t)}()}),[]);let Tt=-1,Ft=-1!==bt&&null!==kt&&void 0!==kt&&kt.product&&(null===kt||void 0===kt||null===(l=kt.product)||void 0===l||null===(a=l.images)||void 0===a?void 0:a.length)>=(null===kt||void 0===kt||null===(d=kt.product)||void 0===d||null===(p=d.options)||void 0===p||null===(x=p[bt])||void 0===x||null===(m=x.values)||void 0===m?void 0:m.length)?null===kt||void 0===kt||null===(f=kt.product)||void 0===f||null===(w=f.images)||void 0===w?void 0:w.map((t=>{var e,i,n,o,r,l,a,d,s,c,u,h,p,x;const v=null===kt||void 0===kt||null===(e=kt.product)||void 0===e||null===(i=e.options)||void 0===i?void 0:i.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===kt||void 0===kt||null===(n=kt.product)||void 0===n||null===(o=n.options)||void 0===o||null===(r=o[v])||void 0===r||null===(l=r.values)||void 0===l?void 0:l[Math.min(++Tt,(null===kt||void 0===kt||null===(a=kt.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===kt||void 0===kt||null===(u=kt.product)||void 0===u||null===(h=u.options)||void 0===h||null===(p=h[v])||void 0===p||null===(x=p.values)||void 0===x?void 0:x[Math.max(0,Tt)],src:null===t||void 0===t?void 0:t.src}})):[],Et=[];if("whatmore"==(0,c.Ipo)(ft)&&(null===N||void 0===N||null===(j=N.images)||void 0===j?void 0:j.length)>0){var Pt;var Ot;if(-1!==(null===N||void 0===N||null===(Pt=N.options)||void 0===Pt?void 0:Pt.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"))}))))Et=null===N||void 0===N||null===(Ot=N.images)||void 0===Ot?void 0:Ot.map((t=>({color:t.color,src:t.src,optionsrc:t.optionsrc})))}return Tt+1<(null===kt||void 0===kt||null===(y=kt.product)||void 0===y||null===(C=y.options)||void 0===C||null===(S=C[bt])||void 0===S||null===(I=S.values)||void 0===I?void 0:I.length)&&(Ft=[]),(0,v.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===gt||void 0===gt?void 0:gt.whatmoreUITheme)?"xl":null,animation:Ct,children:[(0,v.jsx)(Ut,{setOpenShopNow:H,setLockSwiper:U,FONT_SIZE:K}),(0,v.jsx)(s.M5,{marginBottom:"10px",px:"20px",py:"5px",children:(0,v.jsx)(s.kC,{bg:"whiteAlpha.900",width:"fit-content",height:"fit-content",borderRadius:"round"==(null===gt||void 0===gt?void 0:gt.whatmoreUITheme)?"lg":null,overflow:"hidden",sx:{borderWidth:(0,c.alU)(ft),borderColor:(0,c.qPe)(ft)},children:(0,v.jsx)(s.kC,{width:"100%",children:(0,v.jsx)($t.P,{renderElement:t=>(0,v.jsx)(v.Fragment,{children:(0,v.jsx)(s.xu,{width:D+"px",height:A+"px",children:(0,v.jsx)(g.Ee,{width:D+"px",height:A+"px",borderRadius:"round"==(null===gt||void 0===gt?void 0:gt.whatmoreUITheme)?"lg":null,src:(0,pt.s)(t.eventData.src,"&width=400&height=400"),alt:Z.handle,sx:{objectFit:(0,c.yOX)(ft)+" !important"},fallback:(0,v.jsx)(R.Z,{width:D+"px",height:A+"px",borderRadius:"round"==(null===gt||void 0===gt?void 0:gt.whatmoreUITheme)?"10px":"0px"})})})}),dataList:Ft.length>0&&!Ft.includes(null)?null===(k=Ft)||void 0===k?void 0:k.filter((t=>(null===t||void 0===t?void 0:t.color)==St)):Et.length>0?[null===(_=Et)||void 0===_?void 0:_.find((t=>(null===t||void 0===t?void 0:t.color)==St))]:null===N||void 0===N||null===(T=N.images)||void 0===T?void 0:T.map((t=>({src:t.includes("https")?t:"https:"+t}))),spacing:10,defaultHeight:D+"px",defaultWidth:A+"px",retainAlreadyRenderedElements:!0,isScroll:!0})})})}),(0,v.jsx)(Xt,{data:N,product:Z,PRODUCT_TILE_HEIGHT:M,PRODUCT_TILE_WIDTH:L,FONT_SIZE:K,getVariantPrice:te,selectedVariantId:tt,itemPrice:ot,itemQuantity:it,setItemQuantity:nt,thumbnailImage:vt}),(null===N||void 0===N||null===(F=N.variants)||void 0===F?void 0:F.length)>0&&(0,v.jsxs)(v.Fragment,{children:[(0,v.jsx)(s.M5,{paddingTop:"4px",width:"100%",children:(0,v.jsx)(s.iz,{color:(0,c.W8U)(ft),size:"xs",width:"90%"})}),(0,v.jsx)(Gt,{data:N,dividerColor:(0,c.W8U)(ft),setSelectedColor:It,finalArr:Ft,finalArrExternal:Et,product:Z,PRODUCT_TILE_HEIGHT:M,PRODUCT_TILE_WIDTH:L,FONT_SIZE:K,selectOptionFirstHandler:wt,selectOptionSecondHandler:jt,selectOptionThirdHandler:yt,getVariantPrice:te,selectedOptionFirst:Y,selectedOptionSecond:G,selectedOptionThird:Q,selectedVariantId:tt})]}),c.$2G&&((null===N||void 0===N?void 0:N.description)||(null===N||void 0===N?void 0:N.body_html))&&(0,v.jsx)(Bt,{PRODUCT_TILE_HEIGHT:M,FONT_SIZE:K,data:N,handleToggle:()=>q(!W),show:W}),(0,v.jsx)(s.xu,{sx:{pointerEvents:"none"},paddingTop:"20px",opacity:0,children:(0,v.jsx)(Ht,{position:"relative",data:N,FONT_SIZE:K,product:Z})}),(0,v.jsx)(Ht,{position:"fixed",selectedVariantId:tt,data:N,FONT_SIZE:K,PRODUCT_TILE_WIDTH:L,product:Z,itemQuantity:it,cartItemCount:dt,addToCartFlag:ct,setAddToCartFlag:ut,soldOutFlag:ht,setSoldOutFlag:xt,event:V})]})}const Jt=(t,e,i,n)=>{var o;if(!e&&!i&&!n)return;const r=null===t||void 0===t||null===(o=t.variants)||void 0===o?void 0:o.find((t=>(!e||t.option1===e)&&(!i||t.option2===i)&&(!n||t.option3===n)));return r?r.id:void 0},te=(t,e)=>{var i,n;return null===t||void 0===t||null===(i=t.variants)||void 0===i||null===(n=i.find((t=>t.id===e)))||void 0===n?void 0:n.price},ee=(t,e)=>{var i,n;return null===t||void 0===t||null===(i=t.variants)||void 0===i||null===(n=i.find((t=>t.id.toString()===e)))||void 0===n?void 0:n.option1},ie=(t,e)=>{var i,n;return null===t||void 0===t||null===(i=t.variants)||void 0===i||null===(n=i.find((t=>t.id.toString()===e)))||void 0===n?void 0:n.option2},ne=(t,e)=>{var i,n;return null===t||void 0===t||null===(i=t.variants)||void 0===i||null===(n=i.find((t=>t.id.toString()===e)))||void 0===n?void 0:n.option3},oe=(t,e)=>{var i;const n=null===t||void 0===t||null===(i=t.variants)||void 0===i?void 0:i.find((t=>t.id==e));return void 0===n?null:null===n||void 0===n||null===(o=n.featured_image)||void 0===o?void 0:o.src;var o},re=(0,n.createContext)({setShowOptionsChart:null});var le=function(t){const e=t.event,i=t.data,o=t.currentProduct,r=t.setOpenShopNow,l=t.setLockSwiper,[a,d]=(0,n.useState)(!1);return(0,v.jsx)(re.Provider,{value:{setShowOptionsChart:d},children:(0,v.jsxs)(s.xu,{width:"full",height:"full",borderRadius:"md",children:[(0,v.jsx)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"flex-end",children:(0,v.jsx)(s.xu,{width:"full",height:"fit-content",children:(0,v.jsx)(Qt,{data:i,event:e,product:o,setOpenShopNow:r,setLockSwiper:l})})}),a?(0,v.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,v.jsx)(s.xu,{width:"full",height:"fit-content",children:(0,v.jsx)(Wt,{data:i,event:e,product:o,setShowOptionsChart:()=>{d(!1)}})})}):(0,v.jsx)(v.Fragment,{})]})})};var ae=function(t){var e,[i,o,r,l]=(0,h.Z)();const[a,d]=(0,n.useState)(!1),[x,g]=(0,n.useState)(),[f,w]=(0,n.useState)(),j=(0,u.MO)("whatmoreShopId"),y=t.event,C=t.onBack,b=n.useRef(),S=t.isPlaying,I=t.isLast,k=t.setLockSwiper,_=t.selectedVariantId,T=null===(e=t.showOverlay)||void 0===e||e,F="center";return(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:l,height:r,sx:{overflow:"hidden"},children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:F,height:"full",width:"full",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,v.jsx)(s.oM,{width:"full",ratio:l/r,children:(0,v.jsx)(m,{height:"100%",width:"100%",url:y.event_hls_url,isPlaying:S,event:y})})})}),T?(0,v.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:F,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,v.jsx)(At,{focusRef:b,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,v.jsx)(v.Fragment,{}),!0===a?(0,v.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"200%"},direction:"column",justifyContent:F,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,v.jsx)(le,{focusRef:b,event:t.event,isLast:I,onCloseCallback:()=>C(),setLockSwiper:k,data:x,currentProduct:f,setOpenShopNow:d,selectedVariantId:_})})}):(0,v.jsx)("div",{})]})})};const de=function(t,e){return isNaN(t)||isNaN(e)||e<=0||t>e?0:Math.ceil(t/e*100)};function se(t){var e,i,[n,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,x=null!==(i=t.indexAmongSiblings)&&void 0!==i?i:0;return(0,v.jsx)(s.Kq,{width:"96%",height:"fit-content",direction:"row",justifyContent:"center",alignItems:"center",spacing:"1px",children:[...Array(p).keys()].map((t=>(0,v.jsx)(s.Kq,{width:"100%",height:.004*r+"px",backgroundColor:t<x?a:d+"99",borderRightRadius:"lg",borderLeftRadius:"lg",direction:"row",justifyContent:"flex-start",alignItems:"center",overflow:"hidden",sx:{display:"block !important"},children:t==x?(0,v.jsx)(s.xu,{height:"100%",width:c+"%",bgColor:a,borderRightRadius:"lg",borderLeftRadius:"lg",sx:{display:"block !important"}}):(0,v.jsx)(v.Fragment,{})},"event-progress-bar-slab-"+t)))})}var ce=i(868),ue=i(2630);const he=t=>t>=1e3?(t/1e3).toFixed(1)+"k":t;var pe=i(4862);var xe=function(t){var e,i,o,r,a,d=t.whatmoreShareTemplateId;const p=t.whatmoreShareStoryId,x=t.whatmoreShareEventId,m=t.event,g=null===(e=t.showShareText)||void 0===e||e,f=null!==(i=t.shareButtonBottomMargin)&&void 0!==i?i:0,w=(0,u.MO)("whatmoreShopId"),j=(0,u.MO)("isInDesignMode"),y=(0,u.MO)("isDemoBrand"),C=(0,u.MO)("whatmorePrimaryFont"),b=(0,u.MO)("websiteLanguage"),{whatmoreWidgetSourceDetails:S}=(0,n.useContext)(V.I),[I,k,_,T]=(0,h.Z)(),F=null!==(o=t.iconSize)&&void 0!==o?o:.1*T*(0,c.r5f)(w);function E(){const e=(0,u.MO)("whatmoreLandingLocationType");var i;!function(t){j||y||(async()=>{(0,l.x0)(t)})()}(m),(e.startsWith("product")||"embed"===e)&&(d="te"),i="event_product_link"===(0,c.EEC)(w)?m.products[0].product_link||"":window.location.pathname,i=("event_product_link"===(0,c.EEC)(w)?"":window.location.hostname)+i+"?wtt="+d+"&wsid="+p+"&weid="+x,(0,c.lj5)(w)&&(i=i+"&"+(0,c.awP)(w)+"&utm_campaign=video-share&utm_medium="+e);const n={title:(0,c.JNF)(w),text:`${(0,c.Qa8)(w)} \n ${i} ${(0,c.AWG)(w)?"\n \n -via Whatmore":""}`};navigator.share&&!pe.nI?navigator.share(n):(t.setIsModalOpen(!0),t.setShareText([n,i]))}return(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.Cd,{cursor:"pointer",style:{marginBottom:f+"px"},children:(0,v.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"fit-content",width:"fit-content",children:[(0,v.jsx)(ue.Z,{sx:{boxShadow:3,transform:"scaleX(-1)",color:"white",fontSize:F,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),E(),(0,q.GF)({userInteractionType:N.K.VIDEO_SHARE_CTA_CLICKED,widgetSourceDetails:S,event:m,productList:m.products,ctaList:m.cta})}}),g&&(0,c.u8S)(w)?(0,v.jsxs)(s.xv,{fontSize:.3*F+"px !important",fontWeight:"semibold !important",align:"center",sx:{fontFamily:C+" !important",color:"white !important",paddingRight:"10%"},children:["\xa0",m.total_share>(0,c.LWl)(w)?he(m.total_share):null!==(r=null===Q||void 0===Q||null===(a=Q[b])||void 0===a?void 0:a.share)&&void 0!==r?r:"Share","\xa0"]}):(0,v.jsx)(v.Fragment,{})]})})})},ve=i(7933),me=i(2785);var ge=function(t){var e,i,o;const r=(0,u.MO)("whatmoreShopId"),a=(0,u.MO)("whatmorePrimaryFont"),d=(0,u.MO)("whatmoreLikedEvents"),p=(0,u.MO)("isInDesignMode"),x=(0,u.MO)("isDemoBrand"),m=(0,u.MO)("websiteLanguage"),{whatmoreWidgetSourceDetails:g}=(0,n.useContext)(V.I),f=t.event,[w,j]=(0,n.useState)(null!==(e=d[f.event_id])&&void 0!==e&&e),[y,C,b,S]=(0,h.Z)(),I=.1*S*(0,c.r5f)(r);function k(t,e){p||x||(async()=>{(0,l.Z6)(t,e)})()}function _(){(0,u.bU)("whatmoreLikedEvents",{...d,[f.event_id]:!w}),w?(k(f,-1),(0,q.GF)({userInteractionType:N.K.VIDEO_UNLIKED,widgetSourceDetails:g,event:f,productList:f.products,ctaList:f.cta})):(k(f,1),(0,q.GF)({userInteractionType:N.K.VIDEO_LIKED,widgetSourceDetails:g,event:f,productList:f.products,ctaList:f.cta})),j(!w)}const T=f.total_like+(w?1:0);return(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.Cd,{cursor:"pointer",children:(0,v.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"fit-content",width:"fit-content",children:[w?(0,v.jsx)(me.Z,{sx:{boxShadow:3,color:(0,c.dmX)(r),fontSize:I,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),_()}}):(0,v.jsx)(ve.Z,{sx:{boxShadow:3,color:"white",fontSize:I,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{t.stopPropagation(),_()}}),(0,v.jsx)(v.Fragment,{children:(0,c.CEM)(r)?(0,v.jsxs)(s.xv,{fontSize:.3*I+"px !important",fontWeight:"semibold !important",align:"center",sx:{fontFamily:a+" !important",color:"white !important",position:"relative",bottom:"5px"},children:["\xa0",T>=(0,c.zKg)(r)?he(T):null!==(i=null===Q||void 0===Q||null===(o=Q[m])||void 0===o?void 0:o.like)&&void 0!==i?i:"Like","\xa0"]}):(0,v.jsx)(v.Fragment,{})})]})})})};const fe=t=>{let{iconSize:e}=t;return(0,v.jsx)("div",{style:{backgroundColor:"#25D366",borderRadius:"50%",padding:.3*e},children:(0,v.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,v.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 we=i(8866);const je=t=>{let{iconSize:e}=t;return(0,v.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:.3*e},children:(0,v.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,v.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"})})})},ye=t=>{let{iconSize:e}=t;return(0,v.jsx)("div",{style:{backgroundColor:"#fff",borderRadius:"50%",padding:.3*e},children:(0,v.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,v.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 Ce=t=>{const e=t.shareText,[i,o]=(0,n.useState)("Copy link"),[r,l]=(0,n.useState)("");return(0,v.jsx)(v.Fragment,{children:t.isModalOpen&&(0,v.jsxs)("div",{className:"modal-overlay",style:{backgroundColor:"white",borderRadius:"10px",padding:"12px 12px 20px 12px"},children:[(0,v.jsxs)("div",{style:{cursor:"pointer",display:"flex",justifyContent:"space-between",paddingBottom:"6px"},children:[(0,v.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,v.jsx)(Kt.Z,{onClick:e=>{e.stopPropagation(),t.setIsModalOpen(!1)}})]}),(0,v.jsx)("div",{}),(0,v.jsx)(s.iz,{color:"blackAlpha.500",size:"1px",width:"100%"}),(0,v.jsxs)("div",{className:"social-icons",style:{display:"flex",gap:"20px",justifyContent:"center",paddingTop:"12px"},children:[(0,v.jsxs)("div",{onClick:t=>{var i;t.stopPropagation();const n=encodeURIComponent(null===(i=e[0])||void 0===i?void 0:i.text);window.open(`https://wa.me/?text=${n}`,"_blank")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,v.jsx)(fe,{iconSize:Math.min(t.iconSize,30)}),(0,v.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14)},children:"Whatsapp"})]}),(0,v.jsxs)("div",{onClick:t=>{var i;t.stopPropagation();const n=encodeURIComponent(null===(i=e[0])||void 0===i?void 0:i.text);window.open(`https://twitter.com/intent/tweet?text=${n}`,"_blank")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,v.jsx)(je,{iconSize:Math.min(t.iconSize,30),style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,v.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14)},children:"X"})]}),(0,v.jsxs)("div",{onClick:t=>{t.stopPropagation(),navigator.clipboard.writeText(e[1]),o("Link copied"),l("green")},style:{cursor:"pointer",display:"flex",flexDirection:"column",gap:"4px",alignItems:"center"},children:[(0,v.jsx)(ye,{iconSize:Math.min(t.iconSize,30),style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,v.jsx)("p",{style:{fontSize:Math.min(t.iconSize,14),color:r},children:i})]})]})]})})};var be=function(t){var e,i;const n=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!==(i=t.fontSize)&&void 0!==i?i:"8",[a]=(0,we.Z)(),d=`https://www.whatmore.ai/shoppable-videos?utm_source=${n}&utm_medium=referral&utm_campaign=${"landscape"===a?"customer_referral_desktop":"customer_referral_mobile"}`;return(0,v.jsx)(s.rU,{href:d,isExternal:!0,children:(0,c.XFt)(r)&&(0,v.jsxs)(s.Kq,{direction:"row",justifyContent:"flex-start",alignItems:"center",width:"fit-content",spacing:"2px",paddingLeft:"2px",paddingRight:"2px",children:[(0,v.jsx)("p",{style:{textAlign:"center",color:"white",fontFamily:o,fontWeight:"normal",fontSize:1.1*l+"px"},children:"powered by Whatmore"}),(0,v.jsx)(s.xu,{width:"10px"}),(0,v.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"}})]})})},Se=i(4892),Ie=i(1195);var ke=()=>(0,v.jsxs)(s.xu,{as:"svg",width:"46px",height:"46px",viewBox:"0 0 24 24",fill:"none",className:"tick-animation",marginBottom:"20px",children:[(0,v.jsx)("circle",{cx:"12",cy:"12",r:"11",stroke:"gray",strokeWidth:"2",fill:"none"}),(0,v.jsx)("path",{d:"M7 12l3 3 7-7",stroke:"gray",strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round"})]});var _e=t=>{var e;const i={text:null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.title,options:(null===t||void 0===t?void 0:t.options)||[]},[o,r]=(0,n.useState)(!1),[l,a]=(0,n.useState)(null),[d,c]=(0,n.useState)(null),u=(0,n.useRef)(null),h=(0,n.useContext)(V.I);return(0,n.useEffect)((()=>{if(o){const e=setTimeout((()=>{t.setIsQuestionVisible(!1)}),1e3);return()=>clearTimeout(e)}}),[o]),(0,n.useEffect)((()=>{!o&&u.current&&c(u.current.offsetHeight)}),[o]),(0,v.jsxs)(s.xu,{position:"fixed",top:"50%",left:"50%",transform:"translate(-50%, -50%)",minWidth:"320px",width:"fit-content",bg:"white",borderRadius:"lg",boxShadow:"md",display:"flex",flexDirection:"column",maxWidth:"90%",maxHeight:"90%",overflowY:"visible",ref:u,height:d?`${d}px`:"auto",children:[(0,v.jsx)(s.xu,{position:"absolute",top:"-10px",right:"-10px",bg:"rgba(255, 255, 255, 0.8)",borderRadius:"full",padding:1,display:"flex",alignItems:"center",justifyContent:"center",cursor:"pointer",zIndex:"10",onClick:()=>{var e;t.setIsQuestionVisible(!1),(0,q.GF)({userInteractionType:N.K.QUESTION_CLOSED,userInteractionMetadata:{questionId:null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.id},widgetSourceDetails:h})},children:(0,v.jsx)(Ie.Z,{})}),(0,v.jsx)(s.xu,{bg:"gray.700",borderTopRadius:"lg",py:3,px:6,display:"flex",flexDirection:"column",justifyContent:"center",width:"100%",children:(0,v.jsx)(s.X6,{py:6,as:"h2",textAlign:"center",style:{fontWeight:"bold",fontSize:"18px",color:"white"},children:null===i||void 0===i?void 0:i.text})}),(0,v.jsx)(s.xu,{flex:"1",display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",py:5,px:6,width:"100%",children:o?(0,v.jsxs)(s.xu,{flex:"1",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",width:"100%",children:[(0,v.jsx)(ke,{}),(0,v.jsx)(s.X6,{as:"h3",size:"md",color:"gray.700",fontWeight:"medium",textAlign:"center",mt:4,fontSize:"lg",children:"Thank you for your response!"})]}):(0,v.jsx)(s.Kq,{spacing:5,width:"100%",align:"center",children:i.options.map(((e,i)=>(0,v.jsx)(s.xu,{px:4,borderWidth:2,borderRadius:"md",cursor:"pointer",bg:l===e?"gray.200":"white",borderColor:l===e?"gray.400":"gray.200",_hover:{bg:"gray.200"},onClick:()=>(e=>{var i;a(e),r(!0),(0,q.GF)({userInteractionType:N.K.QUESTION_ANSWERED,userInteractionMetadata:{questionId:null===t||void 0===t||null===(i=t.question)||void 0===i?void 0:i.id,response:e},widgetSourceDetails:h})})(e),transition:"background-color 0.2s, border-color 0.2s",display:"flex",alignItems:"center",width:"100%",children:(0,v.jsx)(s.xv,{py:5,color:"gray.800",children:e})},i)))})})]})},Te=i(2586);var Fe=t=>{var e,i;const[o,r]=(0,n.useState)(""),[l,a]=(0,n.useState)(""),[d,h]=(0,n.useState)(!1),[p,x]=(0,n.useState)(!1),m=(0,u.MO)("whatmoreShopId"),g=(0,u.MO)("whatmoreSecondaryColor"),f=null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.title,w=(0,n.useContext)(V.I),j=()=>{var e,i;(()=>{const{type:e}=(null===t||void 0===t?void 0:t.question)||{};return"number"===e?/^\d{10}$/.test(o):/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(o)})()?(h(!0),(0,q.GF)({userInteractionType:N.K.QUESTION_ANSWERED,userInteractionMetadata:{questionId:null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.id,response:o,type:"number"===(null===t||void 0===t||null===(i=t.question)||void 0===i?void 0:i.type)?"leadgen:number":"leadgen:email"},widgetSourceDetails:w})):a("Please enter valid contact info.")},y=()=>{var e;t.setIsQuestionVisible(!1),(0,q.GF)({userInteractionType:N.K.QUESTION_CLOSED,userInteractionMetadata:{questionId:null===t||void 0===t||null===(e=t.question)||void 0===e?void 0:e.id},widgetSourceDetails:w})};return(0,v.jsx)(s.kC,{bg:"rgba(0, 0, 0, 0.8)",p:"6%",borderRadius:"md",boxShadow:"md",width:"90vw",mx:"auto",minH:"40vh",maxH:"80vh",position:"fixed",top:"30%",left:"50%",transform:"translateX(-50%)",direction:"column",align:"center",justify:"center",zIndex:100,overflow:"hidden",children:d?(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)(s.xu,{textAlign:"center",color:"white",children:[(0,v.jsx)(s.xu,{fontSize:"2xl",fontWeight:"bold",children:"CONGRATULATIONS!"}),(0,v.jsx)(s.xu,{my:"4%",fontSize:"xl",children:"Claim Now"})]}),(0,v.jsx)(s.xu,{position:"absolute",top:"2%",right:"2%",zIndex:20,children:(0,v.jsx)(P.Z,{onCloseCallback:y})}),(0,v.jsxs)(s.xu,{position:"relative",width:"70%",onClick:()=>{const t=(0,c.dKN)(m);navigator.clipboard.writeText(t).then((()=>{x(!0),setTimeout((()=>{y()}),1e3),setTimeout((()=>x(!1)),2e3)}),(()=>{console.error("Failed to copy the coupon code")}))},cursor:"pointer",children:[(0,v.jsxs)(s.xu,{bg:"white",border:"2px dashed black",borderRadius:"md",p:"2%",display:"flex",alignItems:"center",justifyContent:"space-between",mt:"4%",children:[(0,v.jsx)(s.xu,{as:"span",fontWeight:"bold",color:"black",children:(0,c.dKN)(m)}),(0,v.jsx)(Te.Z,{sx:{color:p?{whatmoreSecondaryColor:g}:"gray",cursor:"pointer",marginLeft:"2%"}})]}),p&&(0,v.jsx)(s.xu,{padding:"4%",position:"absolute",left:"50%",transform:"translateX(-50%)",bg:g,color:"white",fontSize:"12px",borderRadius:"md",px:"2%",py:"0.5%",textAlign:"center",children:"Copied!"})]})]}):(0,v.jsxs)(v.Fragment,{children:[(0,v.jsxs)(s.xu,{textAlign:"center",color:"white",children:[(0,v.jsx)(s.xu,{children:(0,v.jsx)(s.xv,{fontSize:"22px",fontWeight:"bold",children:f})}),(0,v.jsx)(s.xu,{marginBottom:"10%",fontSize:"md",children:(0,c.ewB)(m)})]}),(0,v.jsx)(s.xu,{position:"fixed",top:"2%",right:"2%",zIndex:20,children:(0,v.jsx)(P.Z,{onCloseCallback:y})}),(0,v.jsxs)(s.kC,{mt:"4%",align:"center",direction:"column",width:"80%",children:[(0,v.jsx)(s.xu,{sx:{bg:"white",border:"2px solid #4A4A4A",borderRadius:"8px",paddingLeft:"2%",display:"flex",alignItems:"center",marginBottom:"6%",width:"100%",height:"auto",minH:"48px"},children:(0,v.jsx)("input",{type:"number"===(null===(i=t.question)||void 0===i?void 0:i.type)?"tel":"email",placeholder:t.placeholder,value:o,onChange:t=>{r(t.target.value),l&&a("")},onKeyDown:t=>{"Enter"===t.key&&j()},style:{fontSize:"1em",border:"none",outline:"none",width:"100%"}})}),l&&(0,v.jsx)(s.xv,{color:"red.500",mb:"4% !important",fontSize:"md",textAlign:"center",width:"100%",children:l}),(0,v.jsx)(s.xu,{as:"button",bg:"#343434"!=g?g:"green",color:"#343434",borderRadius:"md",fontWeight:"bold",height:"35px",display:"flex",alignItems:"center",justifyContent:"center",onClick:j,width:"50%",children:(0,v.jsx)(s.xv,{fontSize:"0.8em",padding:"2%",color:"white",children:"SUBMIT"})})]})]})})};var Ee=t=>{const[e,i]=(0,n.useState)(null);return(0,v.jsx)(s.xu,{children:!e&&(0,v.jsx)(Fe,{question:t.question,onEmailSubmit:t=>{i(t)},setIsQuestionVisible:t.setIsQuestionVisible,placeholder:t.placeholder})})};var Pe=t=>{var e;const[i,o]=(0,n.useState)(null),r=t.questionIndex,l=t.questionList;if((0,n.useEffect)((()=>{if(!(r>=l.length))return()=>(0,ot.xw)()}),[]),r>=l.length)return;const a=null===l||void 0===l?void 0:l[r];return"string"===(null===a||void 0===a?void 0:a.type)||"number"===(null===a||void 0===a?void 0:a.type)?(0,v.jsx)(s.xu,{children:(0,v.jsx)(Ee,{setIsQuestionVisible:t.setIsQuestionVisible,question:a,placeholder:"number"===(null===a||void 0===a?void 0:a.type)?"Enter your phone number":"Enter your email"})}):(0,v.jsx)(s.xu,{children:(0,v.jsx)(_e,{question:a,options:null===a||void 0===a||null===(e=a.answers)||void 0===e?void 0:e.values.map((t=>null===t||void 0===t?void 0:t.value)),onAnswerSelect:t=>{o(t)},selectedAnswer:i,onClose:()=>{t.setIsQuestionVisible(!1)},setIsQuestionVisible:t.setIsQuestionVisible})})};function Oe(t){var e;const i=t.event,[o,r,l,a]=(0,h.Z)(),[d]=(0,u.j1)("whatmorePrimaryFont"),{whatmoreIsStoriesTemplate:p}=(0,n.useContext)(V.I),[x]=(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:[x,g,x,g,x],w=(0,n.useRef)(null);(0,n.useEffect)((()=>{w.current&&w.current.play()}),[]);const j=(0,ce.V)(null===i||void 0===i?void 0:i.storyset_thumbnail_image);return(0,v.jsx)(v.Fragment,{children:p?(0,v.jsx)(s.xu,{width:"100%",height:"fit-content",padding:"5px",children:(0,v.jsxs)(s.Kq,{direction:"row",width:"100%",height:"fit-content",justifyContent:"flex-start",children:[(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.Cd,{overflow:"hidden",size:.14*t.width+"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.$)(j)?(0,v.jsx)(Se.Z,{height:"100%",width:"100%",poster:null===i||void 0===i?void 0:i.thumbnail_image,url:j,isPlaying:!0,event:{event_type:"video"},borderRadius:"50%"}):(0,v.jsx)("img",{src:j,style:{objectFit:"cover",height:"100%",width:"100%",backgroundColor:"white"}})})}),(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.xv,{style:{overflow:"hidden",textOverflow:"ellipsis"},noOfLines:1,fontSize:.05*t.width+"px",fontWeight:"medium",lineHeight:"100%",sx:{fontFamily:d+" !important",color:"white !important",textShadow:"0px 0px 4px black !important;"},children:i.storyset_name})})]})}):(0,v.jsx)(v.Fragment,{})})}var ze=function(t){var e,i,o;const[r,a,d]=(0,we.Z)(),[p]=(0,u.j1)("isInDesignMode"),[x]=(0,u.j1)("isDemoBrand"),[m,g]=(0,u.j1)("isProductSwiperCatalogOpen"),[f,w]=(0,u.j1)("isFirstIndicatorRenderDone"),[j]=(0,u.j1)("whatmoreShopId"),C=(0,n.useContext)(wi),{whatmoreEventsBrowsingTemplate:b}=(0,n.useContext)(V.I),[S,I,k,_]=(0,h.Z)(),T=(0,u.MO)("whatmorePrimaryFont"),E=t.event,O=t.storySetId,z=t.isLast,L=t.onCloseCallback,M=t.focusRef,R=t.productClickHandler,A=t.videoPlayingData,K=t.totalSiblingEvents,W=t.indexAmongSiblings,Z=t.leftOpenSpaceClickHandler,H=t.midOpenSpaceClickHandler,U=t.rightOpenSpaceClickHandler,{whatmoreWidgetSourceDetails:B}=(0,n.useContext)(V.I),Y=.1*_,[X,G]=(0,n.useState)(!1),[$,Q]=(0,n.useState)([]),J=t=>{tt.current&&!tt.current.contains(t.target)&&G(!1)},tt=(0,n.useRef)(null);(0,n.useEffect)((()=>(X?document.addEventListener("click",J):document.removeEventListener("click",J),()=>{document.removeEventListener("click",J)})),[X]);const et="Free"==(0,c.Svj)(j)&&"portrait"==r;return(0,v.jsxs)(s.xu,{width:"full",height:"full",borderRadius:"md",children:[t.isQuestionVisible&&(0,v.jsx)(Lt.u,{userInteractionType:N.K.QUESTION_VIEWED,userInteractionMetadata:{questionId:null===(e=t.questionList)||void 0===e||null===(i=e[t.qIndex])||void 0===i?void 0:i.id},triggerFlag:!p&&!x,children:(0,v.jsx)(Pe,{questionList:t.questionList,questionIndex:t.qIndex,setIsQuestionVisible:t.setIsQuestionVisible})}),X&&(0,v.jsx)("div",{ref:tt,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,v.jsx)(Ce,{shareText:$,setShareText:Q,iconSize:Y,isModalOpen:X,setIsModalOpen:G})}),(!t.isQuestionVisible||t.qIndex>=(null===t||void 0===t||null===(o=t.questionList)||void 0===o?void 0:o.length))&&(0,v.jsxs)(s.Kq,{direction:"column",width:"full",height:"full",justifyContent:"space-between",children:[(0,v.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:[C.showVideoPlayingData?(0,v.jsx)(s.Kq,{direction:"row",width:"100%",height:"fit-content",marginTop:"5px",justifyContent:"center",children:(0,v.jsx)(se,{progress:de(A.current_time,A.video_duration),totalSiblings:K,indexAmongSiblings:W})}):(0,v.jsx)(v.Fragment,{}),(0,v.jsx)(s.xu,{width:"full",margin:"2px",marginTop:"5px",children:(0,v.jsxs)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",paddingRight:"10px",paddingLeft:"10px",children:[(0,v.jsx)(Oe,{event:E,width:_}),(0,v.jsxs)(s.Kq,{direction:"row",width:"fit-content",justifyContent:"end",paddingLeft:"10px",children:[(0,mt.ZK)(b)?(0,v.jsx)(xe,{whatmoreShareTemplateId:(0,mt.QN)(b),whatmoreShareStoryId:O,whatmoreShareEventId:E.event_id,event:E,showShareText:!1,iconSize:.07*_,shareButtonBottomMargin:6,setIsModalOpen:G,setShareText:Q}):(0,v.jsx)(v.Fragment,{}),(0,v.jsx)(y,{focusRef:M}),("landscape"!==r||t.showCloseOverlay)&&(0,v.jsx)(P.Z,{event:E,onCloseCallback:L})]})]})})]}),(0,v.jsxs)(s.Kq,{width:"100%",height:"100%",direction:"row",justifyContent:"center",children:[(0,v.jsx)(s.xu,{width:"33%",height:"100%",onClick:()=>{Z()},sx:{display:"block !important"}}),(0,v.jsx)(s.xu,{width:"34%",height:"100%",onClick:()=>{H()},sx:{display:"block !important"}}),(0,v.jsx)(s.xu,{width:"33%",height:"100%",onClick:()=>{U()},sx:{display:"block !important"}})]}),(0,v.jsxs)(s.xu,{width:"full",height:"fit-content",children:[C.totalEvents>1&&!f&&C.showSwipeIndicator?(0,v.jsx)(s.xu,{width:"full",margin:"2px",children:(0,v.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"center",children:(0,v.jsx)(D,{swipeUp:!z})})}):null,(0,v.jsxs)(s.xu,{width:"fit-content",height:"fit-content",position:"absolute",right:0,bottom:"25%",children:[(0,c.slY)(j)&&!(0,mt.ZK)(b)?(0,v.jsx)(s.xu,{ml:"auto",width:"fit-content",paddingY:"12px",paddingX:"8px",position:"relative",top:"-30px",children:(0,v.jsxs)(s.Kq,{gap:"4px",direction:"column",alignItems:"center",cursor:"pointer",onClick:function(){var t;p||x||(async()=>{(0,l.lY)(E,1)})(),(0,q.GF)({userInteractionType:N.K.WHATSAPP_ICON_CLICKED,widgetSourceDetails:B,event:E,productList:null===E||void 0===E?void 0:E.products,ctaList:null===E||void 0===E?void 0:E.cta});const e=E.products.map((t=>`${t.product_link} \n`)),i=(0,c.gtK)(j),n=`Hey, I am interested in ${E.products.length>1?"these products":"this product"} I saw on ${null===(t=E.products[0])||void 0===t?void 0:t.brand} store: \n${e}. Could you please help me with some queries?`;window.open(i+`&text=${n}&type=phone_number`,"_blank")},children:[(0,v.jsx)(fe,{iconSize:.7*Y,style:{boxShadow:"8px 0px 8px rgba(0, 0, 0, 0.4)"}}),(0,v.jsx)(s.xv,{fontSize:Y*(0,c.Xod)(j)+"px",fontWeight:"bold",align:"center",style:{marginTop:0},sx:{fontFamily:T+" !important",color:"white !important"},children:(0,c.UiZ)(j)})]})}):(0,v.jsx)(v.Fragment,{}),(0,c.jY3)(j)?(0,v.jsx)(s.xu,{width:"full",height:"fit-content",paddingX:"12px",position:"relative",top:"-30px",children:(0,v.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,v.jsx)(ge,{event:E})})}):(0,v.jsx)(v.Fragment,{}),(0,c.ROU)(j)&&!(0,mt.ZK)(b)?(0,v.jsx)(s.xu,{width:"full",height:"fit-content",paddingX:"12px",position:"relative",top:"-30px",children:(0,v.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,v.jsx)(xe,{whatmoreShareTemplateId:(0,mt.QN)(b),whatmoreShareStoryId:O,whatmoreShareEventId:E.event_id,event:E,setIsModalOpen:G,setShareText:Q})})}):(0,v.jsx)(v.Fragment,{})]}),(0,zt.kT)(E)?(0,v.jsxs)(s.xu,{width:"full",children:[(0,c.Jm1)(j)?(0,v.jsx)(s.xu,{w:"100%",children:(0,v.jsx)(s.Kq,{direction:"row",width:"full",height:"fit-content",justifyContent:"flex-end",children:(0,v.jsx)(F,{event:E,onToggle:t=>{g("minimize-button"!==t)}})})}):(0,v.jsx)(v.Fragment,{}),(0,v.jsx)(s.xu,{display:"flex",width:"100%",height:"fit-content",children:(0,v.jsx)(Dt,{event:E,productClickHandler:R})})]}):(0,v.jsx)(v.Fragment,{})]}),et&&(0,v.jsx)(s.Kq,{direction:"row",width:"100%",height:"fit-content",bg:"rgba(52, 52, 52, 0.9)",py:"3px",justifyContent:"center",children:(0,v.jsx)(be,{brandName:null===E||void 0===E?void 0:E.brand,fontSize:.033*_})})]})]})},Le=i(2279),Me=i.n(Le),De=i(342);var Re=function(t){var e,i,o,r,l,a,[d,m,g,f]=(0,h.Z)();const[w,j]=(0,n.useState)(!1),[y,C]=(0,n.useState)(),[b,S]=(0,n.useState)(),[I,k]=(0,n.useState)({current_time:0,video_duration:0,is_video_ended:!1}),_=(0,u.MO)("whatmoreShopId"),T=t.event,F=t.storyId,E=t.onBack,P=n.useRef(),O=t.isPlaying,z=t.isLast,L=t.setLockSwiper,M=t.onVideoEndedCallback,D=t.progressUpdateCallback,R=null!==(e=t.totalSiblingEvents)&&void 0!==e?e:0,A=null!==(i=t.indexAmongSiblings)&&void 0!==i?i:0,K=null===(o=t.showOverlay)||void 0===o||o,W=null!==(r=t.leftOpenSpaceClickHandler)&&void 0!==r?r:()=>{},Z=null!==(l=t.midOpenSpaceClickHandler)&&void 0!==l?l:()=>{},H=null!==(a=t.rightOpenSpaceClickHandler)&&void 0!==a?a:()=>{},{whatmoreWidgetSourceDetails:U}=(0,n.useContext)(V.I),{questionList:B}=(0,n.useContext)(wi),Y=(null===B||void 0===B?void 0:B.length)>0?parseInt(localStorage.getItem("_whatmore_qview_index")):1e4,[X,G]=(0,n.useState)();(0,n.useEffect)((()=>{G(t.showQuestion)}),[t.showQuestion]);const $="center";let Q;try{Q=Me()((()=>{M()}),1e3,{leading:!0,trailing:!1})}catch(J){console.log(J)}return(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:f,height:g,sx:{overflow:"hidden"},children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:$,height:"full",width:"full",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,v.jsx)(s.oM,{width:"full",ratio:f/g,children:(0,v.jsx)(x.Z,{height:"100%",width:"100%",url:(0,ce.V)((0,De.uv)(T)),isPlaying:O&&(!X||Y>=B.length),timeUpdateCallback:function(t,e){const i=de(t,e);D({watch_time:t,video_duration:e});const n=I.is_video_ended;i>=99&&O&&!n?(Q(),k({current_time:t,video_duration:e,is_video_ended:!0})):k({current_time:t,video_duration:e,is_video_ended:n})},event:T,question:X&&Y<(null===B||void 0===B?void 0:B.length),source:t.source})})})}),K?(0,v.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"100%"},direction:"column",justifyContent:$,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,v.jsx)(ze,{focusRef:P,event:t.event,isLast:z,onCloseCallback:t=>{E(t),(0,q.Z2)({userInteractionType:N.K.VIDEO_PLAYBACK,userInteractionMetadata:{watch_time:I.current_time,video_duration:I.video_duration},widgetSourceDetails:U,event:T,productList:T.products,ctaList:T.cta})},productClickHandler:async t=>{const e=await(0,p.p)(t,(0,c.Ipo)(_),_);S(t),C(e),j(!0),L(!0),(0,q.GF)({userInteractionType:N.K.SHOPNOW_CLICKED,widgetSourceDetails:U,event:T,productList:T.products,ctaList:T.cta}),(0,u.bU)("whatmoreAllowAutoSlide",!1)},videoPlayingData:I,totalSiblingEvents:R,indexAmongSiblings:A,questionList:B,isQuestionVisible:X&&Y<(null===B||void 0===B?void 0:B.length),qIndex:Y,setIsQuestionVisible:G,leftOpenSpaceClickHandler:W,midOpenSpaceClickHandler:Z,rightOpenSpaceClickHandler:H,storySetId:F,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay})})}):(0,v.jsx)(v.Fragment,{}),!0===w?(0,v.jsx)(s.Kq,{style:{position:"relative",zIndex:1,bottom:"200%"},direction:"column",justifyContent:$,height:"full",width:"full",className:"whatmore-ios-css-relative-fix",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",children:(0,v.jsx)(le,{focusRef:P,event:t.event,isLast:z,onCloseCallback:()=>E(),setLockSwiper:L,data:y,currentProduct:b,setOpenShopNow:t=>{j(t),(0,u.bU)("whatmoreAllowAutoSlide",!t)}})})}):(0,v.jsx)("div",{})]})})},Ae=i(7300),Ke=i(8984),We=i(58),qe=i(9723);var Ne=function(t){var[e,i,n,o]=(0,h.Z)();const r=(0,u.MO)("whatmoreShopId"),l=t.event,a=t.isPlaying,d="center";return(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:o,height:n,sx:{overflow:"hidden"},children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:d,height:"full",width:"full",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"white",children:(0,v.jsx)(s.oM,{width:"full",ratio:o/n,children:(0,v.jsx)(x.Z,{height:"100%",width:"100%",url:(0,ce.V)((0,De.uv)(l)),isPlaying:a,timeUpdateCallback:function(t,e){},event:l,source:t.source})})})}),(0,v.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,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",width:"100%",height:"100%",backdropFilter:"auto",backdropBlur:"10px",onClick:t=>{(0,We.QV)()},children:(0,v.jsxs)(s.Kq,{direction:"column",justifyContent:"center",alignItems:"center",height:"full",width:"full",children:[(0,v.jsx)(qe.Z,{sx:{boxShadow:3,color:(0,c.Ya_)(r),fontSize:.4*o,filter:"drop-shadow(0 0 5px black);"},onClick:t=>{(0,We.QV)()}}),(0,v.jsx)(s.xv,{color:"white",fontSize:.05*o+"px",fontWeight:"bold",align:"left",children:"Please click to play video.."})]})})})]})})},Ve=i(3433);const Ze=n.lazy((()=>i.e(258).then(i.bind(i,5824))));var He=function(t){var e,i;const n=t.event,o=null===(e=t.isPlaying)||void 0===e||e,r=t.onBack,l=t.isLast,s=t.setLockSwiper,c=(t.heightFactor,t.widthFactor,t.onVideoEndedCallback),h=t.progressUpdateCallback,[p,x]=(0,j.Z)(),[m]=(0,u.j1)("whatmoreVideoPlayerPoolBlessed"),g=null===(i=t.showOverlay)||void 0===i||i;function f(){x(!p)}if((0,Ke.KE)()&&0==m&&"recommended_images"!=(null===n||void 0===n?void 0:n.event_type))return(0,v.jsx)(Ne,{event:n,onBack:r,isPlaying:o,isLast:l,setLockSwiper:s,onVideoEndedCallback:c,progressUpdateCallback:h,totalSiblingEvents:1,indexAmongSiblings:0,leftOpenSpaceClickHandler:()=>{f()},midOpenSpaceClickHandler:()=>{f()},rightOpenSpaceClickHandler:()=>{f()},showOverlay:g,source:Ve.j.CAROUSEL_EVENT_OPENED},"shopping-video-view"+n.event_id);if((0,Ae.B6)(n)||(0,Ae.WJ)(n))return(0,v.jsx)(Re,{event:n,onBack:r,isPlaying:o,isLast:l,setLockSwiper:s,onVideoEndedCallback:c,progressUpdateCallback:h,showQuestion:t.showQuestion,totalSiblingEvents:1,indexAmongSiblings:0,leftOpenSpaceClickHandler:()=>{f()},midOpenSpaceClickHandler:()=>{f()},rightOpenSpaceClickHandler:()=>{f()},showOverlay:g,source:Ve.j.CAROUSEL_EVENT_OPENED,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay},"shopping-video-view"+n.event_id);if("recommended_images"==(null===n||void 0===n?void 0:n.event_type))return(0,v.jsx)(Ze,{onBack:r,mode:t.mode,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay,imageUrls:null===n||void 0===n?void 0:n.product_list});if((0,Ae.yC)(n)){var{status:w,bannerText:y,timeToStartInMins:C}=d.Z.getEventStatus(n);if(w.name===a.Z.LIVE.name)return(0,v.jsx)(ae,{event:n,onBack:r,isPlaying:o,isLast:l,showOverlay:g},"shopping-live-view"+n.event_id)}return console.error("Can't render event which is neither video or a currently-live-event"),(0,v.jsx)("div",{})},Ue=i(9284),Be=i.n(Ue),Ye=i(7463),Xe=i(2154);function Ge(t){var e;const[i,o]=(0,n.useState)(!1),r=t.onClick,l=null!==(e=t.fontSize)&&void 0!==e?e:50;return(0,v.jsx)("div",{style:{height:"fit-content",width:"fit-content",backgroundColor:"black",opacity:.4,borderRadius:"50%"},className:[i?"whatmore-scale-on-tap":""].join(" "),children:"left"===t.type?(0,v.jsx)(Xe.Z,{sx:{color:"white",fontSize:l+"px",filter:"drop-shadow(0 0 5px black);"},onClick:t=>{o(!0),setTimeout((()=>{o(!1)}),500),r(t,"up")}}):(0,v.jsx)(Ye.Z,{sx:{color:"white",fontSize:l+"px",filter:"drop-shadow(0 0 5px black);"},onClick:t=>{o(!0),setTimeout((()=>{o(!1)}),500),r(t,"down")}})})}var $e=function(t){var e,i,n;const o=null!==(e=t.relativeBottomPercentage)&&void 0!==e?e:"30%",r=null!==(i=t.width)&&void 0!==i?i:"100%",l=null!==(n=t.fontSize)&&void 0!==n?n:50,a=t.handleClick;return(0,v.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,v.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,v.jsx)(Ge,{type:"left",onClick:a,fontSize:l}),(0,v.jsx)(Ge,{type:"right",onClick:a,fontSize:l})]})})},Qe=i(2860),Je=i(4669);var ti=function(t,e){function i(t,e){return 1==e?0:t<0?e+t:t>=e?t-e:t}const o=(0,n.useRef)({prevIndex:i(t-1,e),activeIndex:t,nextIndex:i(t+1,e)});return[function(){return o.current},function(t){o.current="right"==t?{prevIndex:i(o.current.activeIndex,e),activeIndex:i(o.current.activeIndex+1,e),nextIndex:i(o.current.activeIndex+2,e)}:{prevIndex:i(o.current.activeIndex-2,e),activeIndex:i(o.current.activeIndex-1,e),nextIndex:i(o.current.activeIndex,e)}},function(t){return i(o.current.activeIndex+t)}]};var ei=function(t,e){const i=(0,n.useRef)({clientX:0,clientY:0});return[function(t){i.current.clientX=t.changedTouches[0].clientX,i.current.clientY=t.changedTouches[0].clientY},function(n){const o=i.current.clientX,r=i.current.clientY;var l=o-n.changedTouches[0].clientX,a=r-n.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 ii=function(t,e){const i=(0,n.useRef)(Me()(((t,e)=>{t(e)}),300,{leading:!0,trailing:!1}));return[function(n,o){var r=0;if(r="vertical"==t?n.deltaY:n.deltaX,Math.abs(r)<=e)return;const l=r>0?"right":"left";i.current(o,l)}]},ni=i(5173);var oi=function(t){const e=t.events,i=t.eventIndex,a=t.onBack;var[d,p,x,m]=(0,h.Z)();const[g]=(0,u.j1)("isInDesignMode"),[f]=(0,u.j1)("isDemoBrand"),[w,j]=(0,n.useState)(!0),[y,C]=(0,u.j1)("isFirstIndicatorRenderDone"),[b,S]=(0,n.useState)(!1),[I,k]=(0,n.useState)({}),{setCloseClickComponent:_}=(0,n.useContext)(wi),{slideDirection:T}=(0,n.useContext)(wi),[F]=(0,u.j1)("whatmoreShopId"),[E]=(0,u.j1)("whatmoreLandingLocationType"),[P,O]=ti(i,e.length),[z,L]=ei(T,50),[M]=ii("vertical",30),[D,R]=(0,n.useState)(!1),[A,W]=(0,n.useState)(null),{whatmoreWidgetSourceDetails:Z,whatmoreUserInfo:H}=(0,n.useContext)(V.I);function U(){R(!1)}function B(t){U(),setTimeout((()=>{a(t)}),500)}(0,n.useEffect)((()=>(R(!0),()=>{})),[]);const Y=Z.landingLocationType,X=Z.templateType;_(B);let G=i;const{questionList:$}=(0,n.useContext)(wi);function Q(){(0,u.MO)("whatmoreAllowAutoSlide")&&(O("right"),A.slideNext())}function J(t,e){O(e),function(t,e){A&&("left"===e?A.slidePrev():A.slideNext())}(0,e)}const tt=Math.round(.05*x);return(0,v.jsx)(Be(),{isOpen:D,onAfterOpen:function(){},onRequestClose:U,overlayClassName:"whatmore-modal",className:"whatmore-modal-content",ariaHideApp:!1,children:(0,v.jsx)(ni.Z,{children:(0,v.jsxs)("div",{style:{height:window.innerHeight,width:window.innerWidth,backgroundColor:(0,K.lA)("#000000",13)},onTouchStart:t=>{z(t)},onTouchEnd:t=>{if(b)return;const e=L(t);e&&J(0,e)},onWheel:t=>{b||M(t,(t=>{J(0,t)}))},children:[(0,v.jsx)(o.tq,{speed:400,threshold:tt,slidesPerView:1,direction:T,modules:[r.tl,r.Gk],initialSlide:i,loop:1!=e.length,height:window.innerHeight,width:window.innerWidth,watchSlidesProgress:!0,allowSlideNext:!b,allowSlidePrev:!b,allowTouchMove:!1,onSwiper:t=>{W(t),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:Z,event:e[P().activeIndex],productList:e[P().activeIndex].products})},onSlideChange:t=>{var i;w?j(!1):(y||C(!0),(0,q.Z2)({userInteractionType:N.K.VIDEO_PLAYBACK,userInteractionMetadata:I,widgetSourceDetails:Z,event:e[P().activeIndex],productList:e[P().activeIndex].products}),i=e[P().activeIndex],g||f||null===i||void 0===i||!i.event_id||(async()=>{const t=(0,mt.NY)(Y)+(0,mt.dS)(X)+"_"+(null===i||void 0===i?void 0:i.event_id);(0,l.wh)(i),"index"===E?((0,Je.Tc)(F,Qe.Xh,Qe.pR),(0,ot.H4)(i.event_id,i.products,Qe.Xh,Qe.pR,t,null===i||void 0===i?void 0:i.location,null===H||void 0===H?void 0:H.userType)):E.startsWith("product")||"embed"===E?((0,Je.Tc)(F,Qe.h7,Qe.dU),(0,ot.H4)(i.event_id,i.products,Qe.h7,Qe.dU,t)):E.startsWith("collection")?((0,Je.Tc)(F,Qe.U$,Qe.Pk),(0,ot.H4)(i.event_id,i.products,Qe.U$,Qe.Pk,t)):((0,Je.Tc)(F,Qe.Xh,Qe.pR),(0,ot.H4)(i.event_id,i.products,Qe.Xh,Qe.pR,t))})(),(0,q.y4)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:Z,event:e[P().activeIndex],productList:e[P().activeIndex].products}))},children:[...Array(Math.min(e.length,3)).keys()].map((n=>(0,v.jsx)(o.o5,{children:n=>{let{isActive:o,isPrev:r,isNext:l,isVisible:a,isDuplicate:d}=n;const u=o?"activeIndex":r?"prevIndex":"nextIndex",h=P()[u];"activeIndex"==u&&(G=Math.max(G,h),0==h&&(G=0));const p=(null===$||void 0===$?void 0:$.length)>0&&o&&a&&(h>i||G<i&&h>0)&&h>=G&&h%(0,c.rFm)(F)==i%(0,c.rFm)(F);return(0,v.jsx)(s.Kq,{direction:"column",height:window.innerHeight,justifyContent:"center",children:(0,v.jsx)(He,{event:e[h],showQuestion:p,onBack:B,isPlaying:1==e.length||o&&a,isLast:!1,setLockSwiper:S,onVideoEndedCallback:Q,progressUpdateCallback:t=>{k(t)},showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay,mode:"portrait"})})}},"event-vertical-scroll-slide-"+n)))}),e.length>1&&!b&&(0,c.h6H)(F)&&"horizontal"===(0,c.e8z)(F)&&"horizontal"===T?(0,v.jsx)($e,{relativeBottomPercentage:"50%",width:m,handleClick:(t,e)=>{J(0,"down"==e?"right":"left")},fontSize:parseInt(.12*m)}):(0,v.jsx)(v.Fragment,{})]})})})},ri=i(1168);i(6143),i(7850),i(4444),i(7244),i(123),i(5892),i(1811);const li=t=>{let{children:e,customClass:i,show:n,closeCallback:o}=t;return ri.createPortal((0,v.jsxs)("div",{className:`whatmore-landscape-modal whatmore-root ${i}`,style:{display:n?"block":"none"},children:[(0,v.jsx)("div",{className:"whatmore-landscape-modal-overlay",onClick:o}),(0,v.jsx)("div",{className:"whatmore-landscape-modal-content",children:e})]}),document.body)};li.defaultProps={children:(0,v.jsx)("div",{children:"Empty Modal"}),customClass:"",show:!1,closeCallback:()=>!1};var ai=li;var di=function(t){var e,[i,a,d,p]=(0,h.Z)();const[x]=(0,u.j1)("isInDesignMode"),[m]=(0,u.j1)("isDemoBrand"),[g,f]=(0,u.j1)("isFirstIndicatorRenderDone"),[w,j]=(0,n.useState)(0!=t.eventIndex),{setCloseClickComponent:y}=(0,n.useContext)(wi),[C,b]=(0,n.useState)(!1),[S]=(0,u.j1)("whatmoreShopId"),[I]=(0,u.j1)("whatmoreLandingLocationType"),k=(0,u.MO)("whatmoreUITheme"),{whatmoreWidgetSourceDetails:_,whatmoreUserInfo:T}=(0,n.useContext)(V.I),[F,E]=(0,n.useState)(!1),[O,z]=(0,n.useState)(null);function L(){E(!1)}const M=t.events,D=t.eventIndex,R=t.onBack,A=M.concat(M),W=M.length,Z=null===M||void 0===M||null===(e=M[0])||void 0===e?void 0:e.brand,H=(0,n.useRef)(0);function U(t){L(),setTimeout((()=>{R(t)}),500)}function B(){O&&!O.isEnd&&(0,u.MO)("whatmoreAllowAutoSlide")&&O.slideNext()}(0,n.useEffect)((()=>(E(!0),()=>{})),[]),y(U);const Y=_.landingLocationType,X=_.templateType,[G,$]=(0,n.useState)({}),Q=parseInt(Math.min(5,M.length));return(0,v.jsx)(ai,{show:F,closeCallback:L,customClass:"whatmore-landscape-modal-swipe-view",children:(0,v.jsxs)(s.Kq,{direction:"column",width:window.innerWidth,height:window.innerHeight,justifyContent:"center",aligntItems:"center",backgroundColor:(0,K.lA)("#000000",13),children:[(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.xu,{height:"fit-content",width:p*Q,children:(0,v.jsxs)(o.tq,{onInit:t=>{z(t),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:_,event:M[t.activeIndex],productList:M[t.activeIndex].products,ctaList:M[t.activeIndex].cta})},slidesPerView:Q,centeredSlides:!0,allowTouchMove:!1,initialSlide:D,modules:[r.lI,r.W_,r.Gk,r.pt,r.tl],navigation:Q>=5,effect:"coverflow",coverflowEffect:{rotate:-8,stretch:Math.floor(.22*d),depth:100,scale:.7,modifier:1,slideShadows:!1},height:"fit-content",width:p*Q,watchSlidesProgress:!0,onSlideChange:t=>{var e;w?j(!1):(g||f(!0),e=M[t.activeIndex],x||m||null===e||void 0===e||!e.event_id||(async()=>{const t=(0,mt.NY)(Y)+(0,mt.dS)(X)+"_"+(null===e||void 0===e?void 0:e.event_id);(0,l.wh)(e),"index"===I?((0,Je.Tc)(S,Qe.Xh,Qe.pR),(0,ot.H4)(e.event_id,e.products,Qe.Xh,Qe.pR,t,null===e||void 0===e?void 0:e.location,null===T||void 0===T?void 0:T.userType)):I.startsWith("product")||"embed"===I?((0,Je.Tc)(S,Qe.h7,Qe.dU),(0,ot.H4)(e.event_id,e.products,Qe.h7,Qe.dU,t)):I.startsWith("collection")?((0,Je.Tc)(S,Qe.U$,Qe.Pk),(0,ot.H4)(e.event_id,e.products,Qe.U$,Qe.Pk,t)):((0,Je.Tc)(S,Qe.Xh,Qe.pR),(0,ot.H4)(e.event_id,e.products,Qe.Xh,Qe.pR,t))})(),(0,q.Z2)({userInteractionType:N.K.VIDEO_PLAYBACK,userInteractionMetadata:G,widgetSourceDetails:_,event:M[t.activeIndex],productList:M[t.activeIndex].products,ctaList:M[t.activeIndex].cta}),(0,q.y4)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:_,event:M[t.activeIndex],productList:M[t.activeIndex].products,ctaList:M[t.activeIndex].cta}))},mousewheel:{invert:!1,thresholdDelta:20},children:[M.length>2&&(0,v.jsx)("div",{className:"whatmore-shopping-close-button",children:(0,v.jsx)(P.Z,{onCloseCallback:R})}),A.slice(D,M.length+D).map(((t,e)=>(0,v.jsx)(o.o5,{children:t=>{let{isActive:i,isPrev:n,isNext:o,isVisible:r,isDuplicate:l}=t;if(i)return(0,v.jsx)(s.Kq,{direction:"column",height:d,width:1*p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",children:(0,v.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,v.jsx)(He,{event:M[e%W],onBack:U,isPlaying:!0,isLast:e%W===M.length-1,setLockSwiper:b,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{$(t)},showCloseOverlay:(null===M||void 0===M?void 0:M.length)<=2,mode:"landscape"})})});if(o)return(0,v.jsx)(s.Kq,{direction:"column",height:d,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{O.slideTo(e%W,300)},children:(0,v.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,v.jsx)(He,{event:M[e%W],onBack:U,isPlaying:!1,isLast:e%W===M.length-1,setLockSwiper:b,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{$(t)},showOverlay:!1,mode:"landscape"})})});if(n&&1===H.current)return(0,v.jsx)(s.Kq,{direction:"column",height:d,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{O.slideTo(e%W,300)},children:(0,v.jsx)(s.xu,{overflow:"hidden",sx:{borderRadius:"round"==k?"10px":"0px",borderWidth:(0,c.alU)(S),borderColor:(0,c.qPe)(S)},children:(0,v.jsx)(He,{event:M[e%W],onBack:U,isPlaying:!1,isLast:e%W===M.length-1,setLockSwiper:b,widthFactor:1,heightFactor:1,onVideoEndedCallback:B,progressUpdateCallback:t=>{$(t)},showOverlay:!1,mode:"landscape"})})});try{D+e>=W-1&&(H.current=1)}catch(a){console.log(a)}return(0,v.jsx)(v.Fragment,{})}},"event-horizontal-scroll-slide"+t.event_id)))]})})}),(0,v.jsx)(s.M5,{children:(0,v.jsx)(be,{brandName:Z,height:.04*d,width:.1*p,fontSize:.02*d})})]})})},si=i(6090),ci=i(7616),ui=i(9302),hi=i(2575);var pi=function(t){const[e,i,n,o]=(0,h.Z)(),[r]=(0,u.j1)("whatmorePrimaryColor"),[l]=(0,u.j1)("whatmoreSecondaryColor"),a="flex-end";return(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:o,height:n,backgroundColor:"whiteAlpha.200",backdropBlur:"10px",children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:a,height:"full",width:"full",children:(0,v.jsx)(s.xu,{borderRadius:"md",backgroundColor:"transparent",children:(0,v.jsx)(s.oM,{width:"full",ratio:o/n,children:(0,v.jsx)(s.xu,{w:"100%",h:"100%",bgGradient:"linear(to-br, "+r+", gray, "+l+")"})})})}),(0,v.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,v.jsx)(s.xu,{padding:"2px",margin:"5px",borderRadius:"md",backgroundColor:"transparent",children:(0,v.jsx)(s.oM,{width:"full",ratio:9/16,children:(0,v.jsx)(s.xu,{width:"full",height:"full",borderRadius:"md",backdropFilter:"auto",backdropBlur:"5px"})})})})]})})};var xi=function(t){var e;const i=t.stories,r=t.onBack,a=t.onStoryCompleteCallback,d=t.isActive,c=null!==(e=t.initialEventIndex)&&void 0!==e?e:0,p=i.events;var[x,m,g,f]=(0,h.Z)();const[w,y]=(0,j.Z)(),[C]=(0,u.j1)("isInDesignMode"),[b]=(0,u.j1)("isDemoBrand"),[S]=(0,u.j1)("whatmoreShopId"),[I,k]=(0,n.useState)(!0),[_,T]=(0,u.j1)("isFirstIndicatorRenderDone"),[F,E]=(0,n.useState)(null),[P,O]=(0,n.useState)(!1),{whatmoreWidgetSourceDetails:z,whatmoreUserInfo:L}=(0,n.useContext)(V.I),[M,D]=ti(c,p.length);function R(t){r(t)}const A=z.landingLocationType,K=z.templateType;function W(){if(!(0,u.MO)("whatmoreAllowAutoSlide"))return;M().activeIndex+1>=p.length?a("right"):(D("right"),F&&F.slideNext())}function Z(t){const e=M().activeIndex;"right"==t&&e+1>=p.length||"left"==t&&e-1<0?a(t):(D(t),F&&("left"==t?F.slidePrev():F.slideNext()))}const[H,U]=(0,n.useState)({});return p[M().activeIndex],(0,v.jsx)("div",{children:(0,v.jsx)(o.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):(_||T(!0),(0,q.Z2)({userInteractionType:N.K.VIDEO_PLAYBACK,userInteractionMetadata:H,widgetSourceDetails:z,event:p[M().activeIndex],productList:p[M().activeIndex].products,ctaList:p[M().activeIndex].cta}),function(t){const e=(0,mt.NY)(A)+(0,mt.dS)(K)+"_"+(null===t||void 0===t?void 0:t.event_id);C||b||(async()=>{(0,l.wh)(t),(0,Je.Tc)(S,Qe.Xh,Qe.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===L||void 0===L?void 0:L.userType)})()}(p[M().activeIndex]),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:z,event:p[M().activeIndex],productList:p[M().activeIndex].products,ctaList:p[M().activeIndex].cta}))},children:[...Array(Math.min(p.length,3)).keys()].map((e=>(0,v.jsx)(o.o5,{children:e=>{let{isActive:n,isPrev:o,isNext:r,isVisible:l,isDuplicate:a}=e;if(d){const e=n?"activeIndex":o?"prevIndex":"nextIndex",r=p[M()[e]];return(0,v.jsx)(s.Kq,{direction:"column",height:g,justifyContent:"center",children:(0,Ae.B6)(r)||(0,Ae.WJ)(r)?(0,v.jsx)(Re,{event:r,totalSiblingEvents:p.length,indexAmongSiblings:M()[e],onBack:R,isPlaying:d&&n&&l,isLast:!1,setLockSwiper:O,onVideoEndedCallback:W,progressUpdateCallback:t=>{U(t)},leftOpenSpaceClickHandler:()=>{Z("left")},midOpenSpaceClickHandler:()=>{y(!w)},rightOpenSpaceClickHandler:()=>{Z("right")},storyId:i.id,source:Ve.j.STORY_EVENT_OPENED,showCloseOverlay:null===t||void 0===t?void 0:t.showCloseOverlay},"shopping-video-view"+r.event_id):(0,v.jsx)(v.Fragment,{})})}return(0,v.jsx)(s.Kq,{direction:"column",height:x,justifyContent:"center",children:(0,v.jsx)(pi,{})})}},"event-story-view-slide-"+e)))})})};var vi=function(t){const e=t.onBack,i=t.eventsStories,a=t.initialStoryIndex;var[d,c,p,x]=(0,h.Z)();const[m]=(0,u.j1)("isInDesignMode"),[g]=(0,u.j1)("isDemoBrand"),[f,w]=(0,n.useState)(!0),[j,y]=(0,u.j1)("isFirstIndicatorRenderDone"),[C,b]=(0,n.useState)(!1),{setCloseClickComponent:S}=(0,n.useContext)(wi),{slideDirection:I}=(0,n.useContext)(wi),[k]=(0,u.j1)("whatmoreShopId"),[_,T]=ti(a,i.length),[F,E]=ei("horizontal",50),[P]=ii("vertical",30),O=t.eventIndex,[z,L]=(0,n.useState)(!1),[M,D]=(0,n.useState)(null),{whatmoreWidgetSourceDetails:R,whatmoreUserInfo:A}=(0,n.useContext)(V.I);function K(){L(!1)}function W(t){K(),setTimeout((()=>{e(t)}),500)}(0,n.useEffect)((()=>(L(!0),()=>{})),[]),S(W);const Z=R.landingLocationType,H=R.templateType;function U(t){M&&(0,u.MO)("whatmoreAllowAutoSlide")&&(T(t),"right"==t?M.slideNext():M.slidePrev())}function B(t,e){U(e)}return(0,v.jsx)(Be(),{isOpen:z,onAfterOpen:function(){},onRequestClose:K,overlayClassName:"whatmore-modal",className:"whatmore-modal-content",ariaHideApp:!1,children:(0,v.jsx)("div",{style:{height:window.innerHeight,width:window.innerWidth,backgroundColor:"#00000088"},onTouchStart:t=>{F(t)},onTouchEnd:t=>{const e=E(t);e&&B(0,e)},onWheel:t=>{P(t,(t=>{B(0,t)}))},children:(0,v.jsx)(o.tq,{speed:1,slidesPerView:1,direction:"horizontal",modules:[r.SH,r.Gk],initialSlide:a,loop:i.length>1,height:window.innerHeight,width:window.innerWidth,watchSlidesProgress:!0,onSwiper:t=>{var e,n;D(t),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:R,event:i[_().activeIndex].events[0],productList:null===(e=i[_().activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(n=i[_().activeIndex].events[0])||void 0===n?void 0:n.cta})},onSlideChange:t=>{var e,n;f?w(!1):(!function(t){const e=(0,mt.NY)(Z)+(0,mt.dS)(H)+"_"+(null===t||void 0===t?void 0:t.event_id);m||g||(async()=>{(0,l.wh)(t),(0,Je.Tc)(k,Qe.Xh,Qe.OW),(0,ot.H4)(t.event_id,t.products,"homepage","stories",e,null===t||void 0===t?void 0:t.location,null===A||void 0===A?void 0:A.userType)})()}(i[_().activeIndex].events[0]),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:R,event:i[_().activeIndex].events[0],productList:null===(e=i[_().activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(n=i[_().activeIndex].events[0])||void 0===n?void 0:n.cta}))},allowTouchMove:!1,cubeEffect:{shadow:!0,slideShadows:!0,shadowOffset:20,shadowScale:.94},children:[...Array(Math.min(i.length,3)).keys()].map((t=>(0,v.jsx)(o.o5,{children:t=>{let{isActive:e,isPrev:n,isNext:o,isVisible:r,isDuplicate:l}=t;const c=e?"activeIndex":n?"prevIndex":"nextIndex";return(0,v.jsx)(s.Kq,{direction:"column",height:d,justifyContent:"center",children:(0,v.jsx)(xi,{stories:i[_()[c]],onBack:W,isActive:e&&r,isNext:o,isPrev:n,onStoryCompleteCallback:U,nextStories:i[_().nextIndex],prevStories:i[_().prevIndex],initialEventIndex:a==_()[c]?O:0},"event-story-view-"+i[_()[c]].id)})}},"event-vertical-scroll-slide-"+t)))})})})};var mi=function(t){var e,i,o,[r,l,a,d]=(0,h.Z)();const[c]=(0,u.j1)("whatmorePrimaryColor"),[p]=(0,u.j1)("whatmoreSecondaryColor"),x=t.event,m=(t.onBack,n.useRef(),null!==(e=t.showPausedVideo)&&void 0!==e&&e),f=null!==(i=t.heightFactor)&&void 0!==i?i:1,w="flex-end";return d*=null!==(o=t.widthFactor)&&void 0!==o?o:1,a*=f,(0,v.jsx)(s.M5,{children:(0,v.jsxs)(s.xu,{width:d,height:a,children:[(0,v.jsx)(s.Kq,{direction:"column",justifyContent:w,height:"full",width:"full",children:(0,v.jsx)(s.xu,{children:(0,v.jsx)(s.oM,{width:"full",ratio:9/16,children:m?(0,Ae.B6)(x)||(0,Ae.WJ)(x)?(0,v.jsx)(Se.Z,{height:"100%",width:"100%",url:x.thumbnail_image,isPlaying:!1,pauseFromPlayTimeInMs:1e3,event:x}):(0,v.jsx)(g.Ee,{width:"full",height:"full",src:x.thumbnail_image,objectFit:"cover",borderRadius:"lg"}):(0,v.jsx)(s.xu,{w:"100%",h:"100%",bgGradient:"linear(to-br, "+c+", gray, "+p+")"})})})}),(0,v.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,v.jsx)(s.xu,{children:(0,v.jsx)(s.oM,{width:"full",ratio:9/16,children:(0,v.jsx)(s.xu,{width:"full",height:"full",backgroundColor:"blackAlpha.400"})})})})]})})};var gi=function(t){var e,i,[a,d,c,p]=(0,h.Z)();const[x]=(0,u.j1)("isInDesignMode"),[m]=(0,u.j1)("isDemoBrand"),[g,f]=(0,u.j1)("isFirstIndicatorRenderDone"),[w,j]=(0,n.useState)(0!=t.eventIndex),{setCloseClickComponent:y}=(0,n.useContext)(wi),[C,b]=(0,n.useState)(!1),[S]=(0,u.j1)("whatmoreShopId"),{whatmoreWidgetSourceDetails:I,whatmoreUserInfo:k}=(0,n.useContext)(V.I),[_,T]=(0,n.useState)(!1),[F,E]=(0,n.useState)(null);function O(){T(!1)}t.events;const z=t.eventIndex,L=t.onBack,M=t.eventsStories,D=t.initialStoryIndex,R=null===(e=M[0])||void 0===e||null===(i=e.events[0])||void 0===i?void 0:i.brand;function A(t){O(),setTimeout((()=>{L(t)}),500)}(0,n.useEffect)((()=>(T(!0),()=>{})),[]),y(A);const K=I.landingLocationType,W=I.templateType;function Z(t){F&&!F.isEnd&&("right"==t?F.slideNext():F.slidePrev())}const H=parseInt(Math.min(5,M.length));return(0,v.jsx)(ai,{show:_,closeCallback:O,customClass:"whatmore-landscape-modal-stories-view",children:(0,v.jsxs)(s.Kq,{direction:"column",width:window.innerWidth,height:window.innerHeight,justifyContent:"center",aligntItems:"center",backgroundColor:"blackAlpha.800",children:[(0,v.jsx)(s.M5,{children:(0,v.jsx)(s.xu,{height:"fit-content",width:p*H,children:(0,v.jsxs)(o.tq,{onInit:t=>{var e,i;E(t),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:I,event:M[t.activeIndex].events[0],productList:null===(e=M[t.activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(i=M[t.activeIndex].events[0])||void 0===i?void 0:i.cta})},slidesPerView:H,centeredSlides:!0,allowTouchMove:!1,initialSlide:D,modules:[r.lI,r.W_,r.Gk],navigation:H>=5,effect:"coverflow",coverflowEffect:{rotate:-8,stretch:Math.floor(.22*c),depth:100,scale:.7,modifier:1,slideShadows:!1},height:"fit-content",width:p*H,watchSlidesProgress:!0,onSlideChange:t=>{var e,i;w?j(!1):(g||f(!0),function(t){const e=(0,mt.NY)(K)+(0,mt.dS)(W)+"_"+(null===t||void 0===t?void 0:t.event_id);x||m||(async()=>{(0,l.wh)(t),(0,Je.Tc)(S,Qe.Xh,Qe.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)})()}(M[t.activeIndex].events[0]),(0,q.GF)({userInteractionType:N.K.EVENT_VIEW,widgetSourceDetails:I,event:M[t.activeIndex].events[0],productList:null===(e=M[t.activeIndex].events[0])||void 0===e?void 0:e.products,ctaList:null===(i=M[t.activeIndex].events[0])||void 0===i?void 0:i.cta}))},mousewheel:{invert:!1,thresholdDelta:20},children:[M.length>2&&(0,v.jsx)("div",{className:"whatmore-shopping-close-button",children:(0,v.jsx)(P.Z,{onCloseCallback:L})}),M.map(((t,e)=>(0,v.jsx)(o.o5,{children:i=>{let{isActive:n,isPrev:o,isNext:r,isVisible:l,isDuplicate:a}=i;if(n){const i=1;return(0,v.jsx)(s.Kq,{direction:"column",height:c,width:p*i,justifyContent:"center",marginLeft:"auto",marginRight:"auto",children:(0,v.jsx)(s.xu,{borderRadius:"xl",overflow:"hidden",backgroundColor:"transparent",boxShadow:"dark-lg",children:(0,v.jsx)(xi,{stories:t,onBack:A,isActive:n&&l,isNext:!1,isPrev:!1,onStoryCompleteCallback:Z,initialEventIndex:D==e?z:0,showCloseOverlay:(null===M||void 0===M?void 0:M.length)<=2},"event-story-view-"+t.id)})})}return o||r?(0,v.jsx)(s.Kq,{direction:"column",height:c,width:p,justifyContent:"center",marginLeft:"auto",marginRight:"auto",onClick:t=>{F.slideTo(e,300)},children:(0,v.jsx)(s.xu,{borderRadius:"xl",overflow:"hidden",backgroundColor:"transparent",boxShadow:"dark-lg",children:(0,v.jsx)(mi,{showPausedVideo:!0,event:M[e].events[0],onBack:A,isPlaying:!1,setLockSwiper:b})})}):(0,v.jsx)(v.Fragment,{})}},"event-horizontal-scroll-slide-"+e)))]})})}),(0,v.jsx)(s.M5,{children:(0,v.jsx)(be,{brandName:R,height:.04*c,width:.1*p,fontSize:.02*c})})]})})};const fi=(0,hi.Z)({key:"whatmore-css-sv"}),wi=(0,n.createContext)({isIOS:!1,totalEvents:0,closeClickComponent:null,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:"vertical",showSwipeIndicator:!0,questionList:[]});var ji=function(t){var e,i,o;const[r,l,a]=(0,we.Z)(),[d]=(0,u.j1)("whatmoreShopId"),{whatmoreRootId:s}=(0,n.useContext)(V.I),{whatmoreIsStoriesTemplate:h}=(0,n.useContext)(V.I);var p=t.events,x=t.index,m=t.onBack,g=t.eventsStories,f=t.initialStoryIndex,w=(0,c.cX2)(d),j="portrait"===r?null!==(e=t.slideDirection)&&void 0!==e?e:"vertical":null!==(i=t.slideDirection)&&void 0!==i?i:p.length>1?"horizontal":"vertical",y="portrait"===r?!(0,c.h6H)(d)&&!h:(0,c.n89)(d);return(0,n.useLayoutEffect)((()=>{(0,c.TLG)(d)&&(window.location.href.includes(w)?history.replaceState(null,"","#"+w):history.pushState(null,"","#"+w),window.addEventListener("popstate",(()=>{window.location.href.includes(w)||m()})))}),[]),delete ci.ZP.styles.global,h?(0,v.jsx)(ui.C,{value:fi,children:(0,v.jsx)(si.x,{theme:ci.ZP,cssVarsRoot:s,resetCSS:!1,children:(0,v.jsx)(wi.Provider,{value:{isIOS:(0,Ke.KE)(),totalEvents:p.length,closeClickComponent:m,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:j,showSwipeIndicator:y},children:"portrait"===r?(0,v.jsx)(vi,{eventsStories:g,initialStoryIndex:f,onBack:m,eventIndex:x}):(0,c.Bbr)(d)?(0,v.jsx)(gi,{eventsStories:g,initialStoryIndex:f,onBack:m,eventIndex:x}):(0,v.jsx)(vi,{eventsStories:g,initialStoryIndex:f,onBack:m,eventIndex:x})})})}):(0,v.jsx)(ui.C,{value:fi,children:(0,v.jsx)(si.x,{theme:ci.ZP,cssVarsRoot:s,resetCSS:!1,children:(0,v.jsx)(wi.Provider,{value:{isIOS:(0,Ke.KE)(),totalEvents:p.length,closeClickComponent:m,setCloseClickComponent:t=>{},showVideoPlayingData:!0,slideDirection:j,showSwipeIndicator:y,questionList:(0,c.YGB)(d)?null===(o=JSON.parse(localStorage.getItem("_whatmore_brand_questions")))||void 0===o?void 0:o.questionList:[]},children:"portrait"===r?(0,v.jsx)(oi,{events:p,eventIndex:x,onBack:m}):(0,v.jsx)(di,{events:p,eventIndex:x,onBack:m})})})})}},9316:function(t,e,i){i.d(e,{mT:function(){return o}});var n=i(686);const o=`\n ${n.F4`
|
|
77
77
|
0% { transform: scale(1); }
|
|
78
78
|
50%, { transform: scale(0.95); }
|
|
79
79
|
100% { transform: scale(1); }
|