whatmore-react-assets 1.0.963 → 1.0.965
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/{305.0e75e675.chunk.js → 305.c4ca4ee7.chunk.js} +1 -1
- package/static/js/436.0a604fa2.chunk.js +1 -0
- package/static/js/{751.31bafe40.chunk.js → 751.8cbd3625.chunk.js} +1 -1
- package/static/js/{820.fdeedfdf.chunk.js → 820.fe6f7201.chunk.js} +1 -1
- package/static/js/872.b82e5bd7.chunk.js +2 -0
- package/whatmore.js +2 -2
- package/static/js/436.ee1e5ed9.chunk.js +0 -1
- package/static/js/872.4016352d.chunk.js +0 -2
|
@@ -1 +0,0 @@
|
|
|
1
|
-
"use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[436],{1492:function(e,t,o){o.r(t),o.d(t,{default:function(){return _}});var i=o(7313),n=o(6090),r=o(7616),l=o(8811),s=(o(6143),o(7850),o(4444),o(7244),o(123),o(5892),o(1811),o(9302)),a=o(2575),d=o(2210),p=o(8486),c=o(9821),u=o(8866),h=o(2279),m=o.n(h),y=o(7753),v=o(7129),x=o(1855),f=o(9854),g=o(4920),w=o(4522),P=o(778),j=o(7381),C=(o(3439),o(4892)),S=o(6805),I=o(9219),O=o(5945),M=o(7053),b=o(6417);var k=function(e){var t,o,n,r,s,a,d,p,u,h,m,x,g,w,P,j,k,F,E;const[Z,_,W,D,N]=(0,c.Z)();var R=(0,i.useContext)(v.V);const{whatmoreUITheme:T}=(0,i.useContext)(l.I),U=(0,y.MO)("whatmoreShopId"),z=(0,y.MO)("whatmorePrimaryFont"),V=(0,y.MO)("whatmoreSecondaryColor"),H=e.onClick,A=null===(t=e.isOnFocus)||void 0===t||t,$=null!==(o=e.playOnUnfocus)&&void 0!==o&&o,G=null!==(n=e.animateOnFocus&&(0,f.iWI)(U))&&void 0!==n&&n,q="portrait"===N[S.YP],B=(q?1.076*_*(0,f.pEd)(U):_*(0,f.H4g)(U))+"px",L=(q?1.076*_*(0,f.pEd)(U):_*(0,f.H4g)(U))+"px",Y=(q?.965*_*(0,f.pEd)(U):.859*_*(0,f.H4g)(U))+"px",K=(0,f.nzC)(U),{whatmoreIsPreviewMode:X}=(0,i.useContext)(l.I),J=.25*_,Q=J+"px",ee=1.1*J+"px",[te,oe]=(0,i.useState)(e.event),[ie,ne]=(0,i.useState)(),re=Math.round(+(null===(r=te.products)||void 0===r||null===(s=r[0])||void 0===s?void 0:s.price)),le=Math.round(+(null===te||void 0===te||null===(a=te.products[0])||void 0===a?void 0:a.compare_price)),se=le&&0!=le&&le>re?Math.round((le-re)/le*100):NaN,[ae,de]=(0,i.useState)(se);return(0,i.useEffect)((()=>{(0,f.N8M)(U)&&(0,I.p_)(te,(0,f.Ipo)(U),U).then((e=>{var t,o,i,n;oe(e),(null===e||void 0===e||null===(t=e.products)||void 0===t||null===(o=t[0])||void 0===o?void 0:o.discount)&&de(null===e||void 0===e||null===(i=e.products)||void 0===i||null===(n=i[0])||void 0===n?void 0:n.discount)}));(async()=>{var e;const t=await(0,M.p)(null===te||void 0===te||null===(e=te.products)||void 0===e?void 0:e[0],(0,f.Ipo)(U),U);ne(t)})()}),[]),(0,b.jsxs)("div",{ref:e=>{e&&(e.style.setProperty("margin-top",R.tileTopMargin+"px","important"),e.style.setProperty("margin-bottom",R.tileBottomMMargin+"px","important"))},children:[(0,b.jsx)("div",{style:{margin:"0 auto",width:_,height:q&&A?"STR2FOC6KG9"==U||"STRDOIDF6O7"==U?Z:1.1*Z:Z,borderRadius:"round"==T?"5px":"0px",boxShadow:"round"==T?K:null,borderWidth:(0,f.alU)(U),borderColor:(0,f.qPe)(U),overflow:"hidden",cursor:"pointer"},className:G?A?"whatmore-event-tile-scale-out-animation":"whatmore-event-tile-scale-in-animation":"none",onClick:()=>{H(te)},children:(0,b.jsx)(C.Z,{height:"100%",width:"100%",url:te.thumbnail_image,isPlaying:A||$,event:te})}),(0,b.jsxs)("div",{onClick:()=>{H(te)},style:{cursor:"pointer",display:"flex",gap:"6px",padding:"14px 8px"},children:[(X?(0,f.uU$)(U):(0,f.EIj)(U))&&(0,b.jsx)("div",{ref:e=>{e&&e.style.setProperty("height",ee,"important")},style:{maxWidth:Q,minWidth:null!==(d=te.products)&&void 0!==d&&null!==(p=d[0])&&void 0!==p&&p.thumbnail_image?Q:"0",borderRadius:"round"==T?"5px":"0px",overflow:"hidden",backgroundColor:"rgb(220, 220, 220, 1)"},children:(0,b.jsx)("img",{ref:e=>{e&&e.style.setProperty("object-fit",(0,f.yOX)(U),"important")},src:null===(u=te.products)||void 0===u||null===(h=u[0])||void 0===h?void 0:h.thumbnail_image})}),(0,b.jsxs)("div",{style:{display:"flex",flexDirection:"column",gap:"5px"},children:[(0,b.jsx)("p",{ref:e=>{e&&(e.style.setProperty("font-size",B,"important"),e.style.setProperty("line-height","120%","important"),e.style.setProperty("font-family",z,"important"),e.style.setProperty("-webkit-line-clamp",1,"important"),e.style.setProperty("line-clamp",1,"important"),e.style.setProperty("-webkit-box-orient","vertical","important"),e.style.setProperty("display","-webkit-box","important"),e.style.setProperty("overflow","hidden","important"),e.style.setProperty("text-overflow","ellipsis","important"))},children:(0,O.s)(null===(m=te.products[0])||void 0===m?void 0:m.title)}),(0,f.QaY)(U)&&(0,b.jsxs)("div",{style:{display:"flex",gap:"12px",flexDirection:(0,f.$zZ)(U)?"row":"row-reverse",justifyContent:(0,f.$zZ)(U)?"flex-start":"flex-end"},children:[(0,b.jsx)("p",{ref:e=>{e&&(e.style.setProperty("color",(0,f.Uyp)(U),"important"),e.style.setProperty("font-size",L,"important"),e.style.setProperty("font-family",z,"important"),e.style.setProperty("overflow","hidden","important"))},style:{textAlign:"left",fontWeight:"normal"==(0,f.rPP)(U)?"normal":"bold"},children:(0,I.jx)(parseFloat(null!==(x=null===ie||void 0===ie?void 0:ie.price)&&void 0!==x?x:null===te||void 0===te||null===(g=te.products)||void 0===g||null===(w=g[0])||void 0===w?void 0:w.price)," ",U,null===(P=te.products[0])||void 0===P?void 0:P.currency)}),!isNaN(le)&&le>re&&(0,b.jsx)("p",{ref:e=>{e&&(e.style.setProperty("color",(0,f.kPs)(U),"important"),e.style.setProperty("font-size",L,"important"),e.style.setProperty("font-family",z,"important"),e.style.setProperty("overflow","hidden","important"))},style:{textDecoration:"line-through"},children:(0,I.jx)(parseFloat(null!==(j=null===ie||void 0===ie?void 0:ie.compare_at_price)&&void 0!==j?j:null===te||void 0===te||null===(k=te.products)||void 0===k||null===(F=k[0])||void 0===F?void 0:F.compare_price)," ",U,null===(E=te.products[0])||void 0===E?void 0:E.currency)})]}),(0,f.QaY)(U)&&!isNaN(ae)&&0!=ae&&(0,b.jsx)("div",{style:{display:"flex",backgroundColor:"green"==(0,f.ZJm)(U)?"#343434"==V?(0,f.ZJm)(U):V:(0,f.ZJm)(U),alignItems:"center",borderRadius:(0,f.CF_)(U)+"px",width:"fit-content",padding:(0,f.Spx)(U)?"3px 6px":"0px"},children:(0,f.Spx)(U)?(0,b.jsx)("p",{ref:e=>{e&&(e.style.setProperty("color",(0,f.mso)(U),"important"),e.style.setProperty("font-size",Y,"important"),e.style.setProperty("font-family",z,"important"))},children:"".concat(ae,"% Off")}):(0,b.jsx)("p",{ref:e=>{e&&(e.style.setProperty("color",(0,f.aUT)(U),"important"),e.style.setProperty("font-size",Y,"important"),e.style.setProperty("font-family",(0,f.V3Y)(U),"important"))},children:(0,f.sG7)(U)})})]})]})]})};const F=(0,a.Z)({key:"whatmore-css-hv"});function E(e){const[t,o,n]=(0,c.Z)(),r=(0,y.MO)("whatmoreShopId"),s=e.events,a=e.onClick,u=n*(0,f.u6l)(r),h="32365904011"==r,[m,v]=(0,i.useState)(h?s.length:u),{whatmoreWidgetSourceDetails:j}=(0,i.useContext)(l.I);return(0,i.useEffect)((()=>{m<=u&&v((e=>e+u))}),[u]),(0,b.jsx)("div",{className:"whatmore-events-carousel-portrait",style:{display:"flex",justifyContent:"center",alignItems:"center"},children:(0,b.jsx)("div",{style:{width:window.innerWidth,height:"fit-content"},children:(0,b.jsx)(d.tq,{slidesPerView:s.length>1?u:1,initialSlide:s.length>1?1:0,centeredSlides:!0,centeredSlidesBounds:!1,watchSlidesProgress:!0,touchRatio:.5,onSlideChange:e=>{(0,w.y4)({userInteractionType:P.K.HOMEPAGE_CAROUSEL_SWIPED,widgetSourceDetails:j}),e.realIndex>e.previousIndex&&v((e=>e+u))},loop:h,navigation:h,modules:[p.W_],children:s.map(((e,t)=>t<=m&&(0,b.jsx)(d.o5,{children:t=>{let{isActive:o,isPrev:i,isNext:n,isVisible:l}=t;return i||n||o?(0,f.$X$)(r)?(0,b.jsx)(k,{isOnFocus:o&&l,playOnUnfocus:!1,animateOnFocus:!0,event:e,onClick:()=>{a(e)}}):(0,b.jsx)(g.Z,{isOnFocus:o&&l,playOnUnfocus:!1,animateOnFocus:!0,event:e,onClick:()=>{a(e)}}):(0,b.jsx)(x.Z,{})}},"whatmore-event-tile-portrait-"+e.index)))})})})}function Z(e){const[t,o,n,r]=(0,c.Z)(),[s,a]=(0,i.useState)(-1),u=(0,y.MO)("whatmoreShopId"),h=e.onClick,v=e.events,j="32365904011"==u,[C,S]=(0,i.useState)(j?v.length:n),I=Math.min(n,v.length),{whatmoreWidgetSourceDetails:O}=(0,i.useContext)(l.I);return(0,i.useEffect)((()=>{C<=n&&S((e=>e+n))}),[n]),(0,b.jsx)("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",paddingLeft:r+"px",paddingRight:r+"px"},className:"whatmore-events-carousel-landscape",children:(0,b.jsx)("div",{style:{width:o*I*(0,f.Su5)(u)+"px"},children:(0,b.jsx)(d.tq,{slidesPerView:I,watchSlidesProgress:!0,modules:[p.W_],navigation:!0,slidesPerGroup:parseInt(I),onSlideChange:e=>{(0,w.y4)({userInteractionType:P.K.HOMEPAGE_CAROUSEL_SWIPED,widgetSourceDetails:O}),e.realIndex>e.previousIndex&&S((e=>e+n))},spaceBetween:(0,f.WGf)(u),loop:j,children:v.map(((e,t)=>{const o=m()((()=>a(t)),300);return t<=C&&(0,b.jsx)(d.o5,{onMouseEnter:()=>{o()},onMouseLeave:()=>{o.cancel(),a(-1)},children:o=>{let{isActive:i,isPrev:n,isNext:r,isVisible:l}=o;return l?(0,f.$X$)(u)?(0,b.jsx)(k,{isOnFocus:t==s,playOnUnfocus:!(0,f.dHy)(u)||t==parseInt(I/2)&&-1==s,animateOnFocus:!0,event:e,onClick:()=>{h(e)}}):(0,b.jsx)(g.Z,{isOnFocus:t==s,playOnUnfocus:!(0,f.dHy)(u)||t==parseInt(I/2)&&-1==s,animateOnFocus:!0,event:e,onClick:()=>{h(e)}}):(0,b.jsx)(x.Z,{})}},"whatmore-event-tile-landscape-"+e.index)}))})})})}var _=function(e){const[t,o,a]=(0,u.Z)(),[d]=(0,y.j1)("whatmoreShopId"),[p]=(0,y.j1)("whatmorePrimaryColor"),[c]=(0,y.j1)("whatmoreTitleFont"),h="portrait"==t?(0,y.MO)("whatmoreTitleFontSizePortrait"):(0,y.MO)("whatmoreTitleFontSize"),{whatmoreRootId:m}=(0,i.useContext)(l.I),x=((0,y.MO)("isInDesignMode"),(0,y.MO)("whatmoreCollectionHeading")),{whatmoreIsCollectionsTemplate:g}=(0,i.useContext)(l.I),w=e.events,P=e.onClick,C=c;function S(e){P(e)}return(0,i.useEffect)((()=>{(0,j.Oo)("Video shopping powered by Whatmore!")}),[]),(0,i.useEffect)((()=>{l.$.forEach((e=>{var t;const o=null!==(t=e.querySelector('.whatmore-template-type[data-wh="template-a"]'))&&void 0!==t?t:e.querySelector('.whatmore-template-type[data="template-a"]');if(!o)return;o&&e&&(e.style.minHeight="0px")}))}),[]),delete r.ZP.styles.global,(0,b.jsx)(s.C,{value:F,children:(0,b.jsx)("div",{className:"whatmore-carousel-events",children:(0,b.jsx)(n.x,{theme:r.ZP,cssVarsRoot:m,resetCSS:!1,children:(0,b.jsxs)(v.V.Provider,{value:{tileTopMargin:25,tileBottomMMargin:25,tileLeftMargin:4,tileRightMargin:4,showPlayButton:!0},children:[e.heading.trim().length>0||g?(0,b.jsx)("div",{style:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center"},children:(0,b.jsx)("p",{ref:e=>{e&&(e.style.setProperty("font-family",C,"important"),e.style.setProperty("font-size",h+"px","important"))},style:{color:p,backgroundClip:"text",textAlign:"center",fontWeight:(0,f.wOV)(d),lineHeight:(0,f.vY4)(d),letterSpacing:(0,f.X2K)(d)},children:g?"W"!==x?x:"":e.heading})}):(0,b.jsx)(b.Fragment,{}),"landscape"===t?(0,b.jsx)(Z,{events:w,onClick:S}):(0,b.jsx)(E,{events:w,onClick:S})]})})})})}},1855:function(e,t,o){var i=o(7313),n=o(9821),r=o(7129),l=o(6417);t.Z=function(e){var[t,o]=(0,n.Z)();return(0,i.useContext)(r.V),e.event,(0,l.jsx)("div",{style:{margin:"0 auto",width:o,height:t,overflow:"hidden"}})}},5892:function(){},4444:function(){},1811:function(){},7850:function(){}}]);
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
/*! For license information please see 872.4016352d.chunk.js.LICENSE.txt */
|
|
2
|
-
(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[872],{9085:function(t,e,o){"use strict";o.r(e),o.d(e,{default:function(){return I}});var r=o(7313),n=(o(3439),o(6090)),i=o(8811),s=o(7616),a=(o(6143),o(4444),o(7244),o(123),o(5892),o(9302)),l=o(2575),c=o(9821),d=o(8866),p=o(2279),u=o.n(p),h=o(7753),m=o(7129),f=o(1855),x=o(9854),y=o(4522),v=o(778),g=o(4892),C=o(5945),M=o(9219),w=o(6805),P=o(8984),S=o(7053),D=o(5416),j=o(6417);var R=function(t){var e,o,n,s,a,l,d,p,u,f,y,v;const[R,T,b,E,O]=(0,c.Z)(),I=(0,h.MO)("whatmoreShopId"),B="portrait"===O[w.YP],$=(B?1.076*T*(0,x.pEd)(I):T*(0,x.H4g)(I))+"px",N=(B?1.076*T*(0,x.pEd)(I):T*(0,x.H4g)(I))+"px",A=(B?.965*T*(0,x.pEd)(I):.859*T*(0,x.H4g)(I))+"px",[L,U]=(0,r.useState)(t.event),F=(0,h.MO)("whatmoreSecondaryColor");var K=(0,r.useContext)(m.V);const k=null===(e=t.isOnFocus)||void 0===e||e,Y=null!==(o=t.playOnUnfocus)&&void 0!==o&&o,G=t.onClick,{whatmoreUITheme:Z}=(0,r.useContext)(i.I),W=null!==(n=t.animateOnFocus&&(0,x.iWI)(I))&&void 0!==n&&n,[H,V]=(0,r.useState)(!1),z=(0,h.MO)("whatmorePrimaryFont"),X=Math.round(+(null===(s=L.products[0])||void 0===s?void 0:s.price)),_=Math.round(+(null===(a=L.products[0])||void 0===a?void 0:a.compare_price)),J=_&&0!=_&&_>X?Math.round((_-X)/_*100):NaN,[Q,q]=(0,r.useState)(J),[tt,et]=(0,r.useState)();return(0,r.useEffect)((()=>{(0,x.N8M)(I)&&(0,M.p_)(L,(0,x.Ipo)(I),I).then((t=>{var e,o,r;U(t),(null===t||void 0===t||null===(e=t.products)||void 0===e||null===(o=e[0])||void 0===o?void 0:o.discount)&&q(null===t||void 0===t||null===(r=t.products[0])||void 0===r?void 0:r.discount),V(!0)}));(async()=>{var t;const e=await(0,S.p)(null===L||void 0===L||null===(t=L.products)||void 0===t?void 0:t[0],(0,x.Ipo)(I),I);et(e),V(!0)})()}),[]),(0,j.jsxs)("div",{ref:t=>{t&&(t.style.setProperty("margin-top",K.tileTopMargin+"px","important"),t.style.setProperty("margin-bottom",K.tileBottomMMargin+"px","important"))},className:W&&!B?k?"whatmore-event-tile-scale-out-animation":"whatmore-event-tile-scale-in-animation":"none",style:{margin:"0 auto",cursor:"pointer",width:T},onClick:()=>{G(L)},children:[(0,j.jsx)("div",{style:{borderRadius:"round"==Z?"5%":"0px",boxShadow:"round"==Z?"0px 0px 5px 0px #B0B0B0":null,height:R,borderWidth:(0,x.alU)(I),borderColor:(0,x.qPe)(I),overflow:"hidden"},children:(0,j.jsx)(g.Z,{height:"100%",width:"100%",url:L.thumbnail_image,isPlaying:k||Y||(0,P.gE)(),event:L})}),(0,j.jsxs)("div",{style:{display:(0,x.pvY)(I)?"flex":"none",flexDirection:"column",padding:"12px 4px",gap:"5px"},children:[(0,j.jsx)("p",{ref:t=>{t&&(t.style.setProperty("font-size",$,"important"),t.style.setProperty("line-height","120%","important"),t.style.setProperty("font-family",z,"important"),t.style.setProperty("-webkit-line-clamp",1,"important"),t.style.setProperty("line-clamp",1,"important"),t.style.setProperty("-webkit-box-orient","vertical","important"),t.style.setProperty("display","-webkit-box","important"),t.style.setProperty("overflow","hidden","important"),t.style.setProperty("text-overflow","ellipsis","important"))},children:(0,C.s)(null===(l=L.products[0])||void 0===l?void 0:l.title)}),H&&(0,x.QaY)(I)&&(0,j.jsxs)("div",{style:{display:"flex",gap:"12px",flexDirection:(0,x.$zZ)(I)?"row":"row-reverse",justifyContent:(0,x.$zZ)(I)?"flex-start":"flex-end"},children:[(0,j.jsx)("p",{ref:t=>{t&&(t.style.setProperty("color",(0,x.Uyp)(I),"important"),t.style.setProperty("font-size",N,"important"),t.style.setProperty("font-family",z,"important"),t.style.setProperty("overflow","hidden","important"))},style:{textAlign:"left",fontWeight:"normal"==(0,x.rPP)(I)?"normal":"bold"},children:(0,M.jx)(parseFloat((0,D.G)()?null===tt||void 0===tt?void 0:tt.price:null===L||void 0===L||null===(d=L.products)||void 0===d||null===(p=d[0])||void 0===p?void 0:p.price)," ",I,null===(u=L.products[0])||void 0===u?void 0:u.currency)}),!isNaN(_)&&_>X&&(0,j.jsx)("p",{ref:t=>{t&&(t.style.setProperty("color",(0,x.kPs)(I),"important"),t.style.setProperty("font-size",N,"important"),t.style.setProperty("font-family",z,"important"),t.style.setProperty("overflow","hidden","important"))},style:{textDecoration:"line-through"},children:(0,M.jx)(parseFloat((0,D.G)()?null===tt||void 0===tt?void 0:tt.compare_at_price:null===L||void 0===L||null===(f=L.products)||void 0===f||null===(y=f[0])||void 0===y?void 0:y.compare_price)," ",I,null===(v=L.products[0])||void 0===v?void 0:v.currency)})]}),(0,x.QaY)(I)&&!isNaN(Q)&&0!=Q&&H&&(0,j.jsx)("div",{style:{display:(0,x.aKo)(I)?"flex":"none",backgroundColor:"green"==(0,x.ZJm)(I)?"#343434"==F?(0,x.ZJm)(I):F:(0,x.ZJm)(I),alignItems:"center",borderRadius:(0,x.CF_)(I)+"px",width:"fit-content",padding:(0,x.Spx)(I)?"3px 6px":"0px"},children:(0,x.Spx)(I)?(0,j.jsx)("p",{ref:t=>{t&&(t.style.setProperty("color",(0,x.mso)(I),"important"),t.style.setProperty("font-size",A,"important"),t.style.setProperty("font-family",z,"important"))},children:"".concat(Q,"% Off")}):(0,j.jsx)("p",{ref:t=>{t&&(t.style.setProperty("color",(0,x.aUT)(I),"important"),t.style.setProperty("font-size",A,"important"),t.style.setProperty("font-family",(0,x.V3Y)(I),"important"))},children:(0,x.sG7)(I)})})]})]})},T=o(7381);const b=(0,l.Z)({key:"whatmore-css-hv"});function E(t){const[e,o,n]=(0,c.Z)(),s=(0,h.MO)("whatmoreShopId"),a=t.events,l=t.onClick,{whatmoreWidgetSourceDetails:d}=(0,r.useContext)(i.I),p=Math.ceil(n),u=2*p,[m,g]=(0,r.useState)(u),[C,M]=(0,r.useState)(2*p),w=0===(0,x.WGf)(s)?24:(0,x.WGf)(s),[P,S]=(0,r.useState)({touchX:0,touchY:0}),D=()=>(0,j.jsx)("div",{style:{width:"50px",borderRadius:"50%",height:"50px",backgroundColor:"rgba(0, 0, 0, 0.3)"},children:(0,j.jsx)("div",{style:{display:"flex"},className:"whatmore-arrow-right-portrait"})}),T=()=>(0,j.jsx)("div",{style:{width:"50px",borderRadius:"50%",height:"50px",backgroundColor:"rgba(0, 0, 0, 0.3)"},children:(0,j.jsx)("div",{style:{display:"flex"},className:"whatmore-arrow-left-portrait"})}),b=t=>{if("next"===t){const t=2;M((t=>Math.min(t+Math.floor(n),a.length+p+1))),g((e=>Math.min(e+t,a.length+p+1)))}else M((t=>Math.max(t-Math.floor(n),u)));(0,y.y4)({userInteractionType:v.K.HOMEPAGE_CAROUSEL_SWIPED,widgetSourceDetails:d})};return(0,j.jsxs)("div",{className:"whatmore-events-carousel-portrait",style:{display:"flex",justifyContent:"flex-start",paddingLeft:"12px",overflow:"hidden",position:"relative"},onTouchStart:t=>{S({touchX:t.touches[0].clientX,touchY:t.touches[0].clientY})},onTouchEnd:t=>{var e,o,r,n;const i=(null===(e=t.changedTouches)||void 0===e||null===(o=e[0])||void 0===o?void 0:o.clientX)-P.touchX,s=(null===(r=t.changedTouches)||void 0===r||null===(n=r[0])||void 0===n?void 0:n.clientY)-P.touchY;Math.sqrt(i**2+s**2)>10&&Math.abs(i)>Math.abs(s)&&b(i>0?"prev":"next")},children:[(0,x.Yxs)(s)&&(0,j.jsxs)(j.Fragment,{children:[C<=a.length+p&&(0,j.jsx)("div",{onClick:()=>b("next"),style:{position:"absolute",zIndex:1,top:"50%",right:"0",transform:"translateY(-100%)"},children:(0,j.jsx)(D,{})}),C>2*p&&(0,j.jsx)("div",{onClick:()=>b("prev"),style:{position:"absolute",left:"0",zIndex:1,top:"50%",transform:"translateY(-100%)"},children:(0,j.jsx)(T,{})})]}),(0,j.jsx)("div",{style:{display:"flex",gap:w,transform:"translateX(-".concat((C-u)*(o+w),"px)"),transition:"transform 0.4s ease-in-out"},children:a.map(((t,e)=>e<m?(0,j.jsx)("div",{children:(0,j.jsx)(R,{isOnFocus:e<=C-p-1&&e>=Math.max(0,C-u),playOnUnfocus:!1,animateOnFocus:!0,event:t,onClick:()=>l(t)})},"whatmore-carousel-tile-".concat(e)):(0,j.jsx)(f.Z,{})))})]})}function O(t){const[e,o,n,s]=(0,c.Z)(),[a,l]=(0,r.useState)(-1),d=(0,h.MO)("whatmoreShopId"),[p,m]=(0,r.useState)("next"),f=t.onClick,g=t.events,{whatmoreWidgetSourceDetails:C}=(0,r.useContext)(i.I),M=Math.min(Math.ceil(n),g.length),[w,P]=(0,r.useState)(0),S=0===(0,x.WGf)(d)?24:(0,x.WGf)(d),D=()=>(0,j.jsx)("div",{children:(0,j.jsx)("button",{onClick:O,style:{width:"50px",borderRadius:"6px",height:"100px",backgroundColor:"rgba(0, 0, 0, 0.3)"},children:(0,j.jsx)("div",{style:{display:"flex"},className:"whatmore-arrow-right"})})}),T=()=>(0,j.jsx)("div",{children:(0,j.jsx)("button",{onClick:E,style:{width:"50px",borderRadius:"6px",height:"100px",backgroundColor:"rgba(0, 0, 0, 0.3)"},children:(0,j.jsx)("div",{style:{display:"flex"},className:"whatmore-arrow-left"})})});(0,r.useEffect)((()=>{w<=M&&P((t=>t+M))}),[M]);const b=()=>{l(-1)},E=()=>{w!==M&&(m("prev"),P((t=>Math.max(Math.ceil(t-n),M))),(0,y.y4)({userInteractionType:v.K.HOMEPAGE_CAROUSEL_SWIPED,widgetSourceDetails:C}))},O=()=>{w>g.length+n||(m("next"),P((t=>Math.floor(t+n))),(0,y.y4)({userInteractionType:v.K.HOMEPAGE_CAROUSEL_SWIPED,widgetSourceDetails:C}))},I=w>g.length?g.length-M+1:w-M,B=w>=g.length?g.length:I+M,$=g.slice(I,B);return(0,j.jsxs)("div",{className:"whatmore-events-carousel-landscape",style:{position:"relative",display:"flex",justifyContent:"center",alignItems:"center",paddingLeft:"".concat(s,"px"),paddingRight:"".concat(s,"px")},children:[g.length>=n-1&&(0,j.jsx)("div",{style:{position:"absolute",left:"0",zIndex:1,top:"50%",transform:"translateX(50%) translateY(-65%)"},children:w!==M&&(0,j.jsx)(T,{})}),(0,j.jsx)("div",{style:{display:"flex",gap:S+"px",width:"".concat(o*n*(0,x.Su5)(d),"px"),paddingLeft:"8px",justifyContent:g.length<=n-1?"center":"flex-start",overflow:"hidden"},children:$.map(((t,e)=>{const o="whatmore-event-tile-landscape-".concat(t.index).concat(e===M-1?"-last":""),r=e===a;return(0,j.jsx)("div",{className:"whatmore-event-tile-horizontal-swipe-animation-".concat("next"===p?"next":"prev"),onMouseEnter:()=>(t=>{const e=u()((()=>l(t)),300);return e(),e.cancel})(e),onMouseLeave:b,children:(0,j.jsx)(R,{isOnFocus:r,playOnUnfocus:!0,animateOnFocus:!0,event:t,onClick:()=>(t=>{f(t)})(t)})},o)}))}),g.length>=n-1&&(0,j.jsx)("div",{style:{position:"absolute",zIndex:1,top:"50%",right:s+"px",transform:"translateY(-65%)"},children:w<=g.length&&(0,j.jsx)(D,{})})]})}var I=function(t){const[e,o,l]=(0,d.Z)(),[c]=(0,h.j1)("whatmoreShopId"),[p]=(0,h.j1)("whatmorePrimaryColor"),[u]=(0,h.j1)("whatmoreSecondaryColor"),[f]=(0,h.j1)("whatmoreTitleFont"),y="portrait"==e?(0,h.MO)("whatmoreTitleFontSizePortrait"):(0,h.MO)("whatmoreTitleFontSize"),{whatmoreRootId:v}=(0,r.useContext)(i.I),g=((0,h.MO)("isInDesignMode"),(0,h.MO)("whatmoreCollectionHeading")),{whatmoreIsCollectionsTemplate:C}=(0,r.useContext)(i.I),M=t.events,w=t.onClick,P=f;function S(t){w(t)}return(0,r.useEffect)((()=>{(0,T.Oo)("Video shopping powered by Whatmore!")}),[]),(0,r.useEffect)((()=>{i.$.forEach((t=>{var e;const o=null!==(e=t.querySelector('.whatmore-template-type[data-wh="template-f"]'))&&void 0!==e?e:t.querySelector('.whatmore-template-type[data="template-f"]');if(!o)return;o&&t&&(t.style.minHeight="0px")}))}),[]),delete s.ZP.styles.global,(0,j.jsx)(a.C,{value:b,children:(0,j.jsx)("div",{className:"whatmore-carousel-events",children:(0,j.jsx)(n.x,{theme:s.ZP,cssVarsRoot:v,resetCSS:!1,children:(0,j.jsxs)(m.V.Provider,{value:{tileTopMargin:25,tileBottomMMargin:25,tileLeftMargin:4,tileRightMargin:4,showPlayButton:!0},children:[t.heading.trim().length>0||C?(0,j.jsx)("div",{style:{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center"},children:(0,j.jsx)("p",{ref:t=>{t&&(t.style.setProperty("font-family",P,"important"),t.style.setProperty("font-size",y+"px","important"))},style:{color:p,backgroundClip:"text",textAlign:"center",fontWeight:(0,x.wOV)(c),lineHeight:(0,x.vY4)(c),letterSpacing:(0,x.X2K)(c)},children:C?"W"!==g?g:"":t.heading})}):(0,j.jsx)(j.Fragment,{}),"landscape"===e?(0,j.jsx)(O,{events:M,onClick:S}):(0,j.jsx)(E,{events:M,onClick:S})]})})})})}},7129:function(t,e,o){"use strict";o.d(e,{V:function(){return r}});const r=(0,o(7313).createContext)({tileTopMargin:10,tileBottomMMargin:10,tileLeftMargin:10,tileRightMargin:10,showPlayButton:!0})},1855:function(t,e,o){"use strict";var r=o(7313),n=o(9821),i=o(7129),s=o(6417);e.Z=function(t){var[e,o]=(0,n.Z)();return(0,r.useContext)(i.V),t.event,(0,s.jsx)("div",{style:{margin:"0 auto",width:o,height:e,overflow:"hidden"}})}},6805:function(t,e,o){"use strict";o.d(e,{$I:function(){return a},$w:function(){return c},AK:function(){return i},AL:function(){return s},YP:function(){return n},me:function(){return r},rE:function(){return l}});const r="device_type",n="device_mode",i="mobile",s="tablet",a="desktop",l="portrait",c="landscape"},9821:function(t,e,o){"use strict";var r=o(6367),n=o(7753),i=o(8866),s=o(6805);e.Z=function(t){const[e,o,a]=(0,i.Z)(),[l]=(0,n.j1)("whatmoreLandscapePadding"),[c]=(0,n.j1)("whatmoreVideoTileSize"),[d]=(0,n.j1)("whatmoreVideoTileSizePortrait"),p=(0,r.useMediaQuery)({query:"(min-width: 1025px)"}),u=(0,r.useMediaQuery)({query:"(min-width: 481px)"}),h="portrait"==e?d:c,m=!("portrait"!=e||!u),f=h/100*1.3*.5,x=h/100;var y=Math.min(a,o),[v,g,C,M]=[.6*y*(16/9),.6*y,1.4,0];function w(t){return Math.round(10*t)/10}var P={DEVICE_TYPE:s.AK,DEVICE_MODE:s.rE};if(p){const t=g*f,e=v*f;[v,g,C,M]=[e,t,(a-2*l)/(1.1*t),l],P[s.me]=s.$I,P[s.YP]=s.$w}else if(m){var S=.8*g,D=.8*v;"portrait"==e?(S*=x,D*=x,[v,g,C,M]=[D,S,w(a/(1.2*S)),0],P[s.me]=s.AL,P[s.YP]=s.rE):([v,g,C,M]=[D,S,(a-2*l)/(1.1*S),l],P[s.me]=s.AL,P[s.YP]=s.$w)}else{S=g,D=v;"portrait"==e?(S=S*x*.9,D=D*x*.9,[v,g,C,M]=[D,S,w(a/(1.15*S)),0],P[s.me]=s.AK,P[s.YP]=s.rE):(S=.7*g,D=.7*v,[v,g,C,M]=[D,S,(a-2*l)/(1.1*S),l],P[s.me]=s.AK,P[s.YP]=s.$w)}return[v,g,C,M,P]}},6040:function(t,e,o){const r=o(500);t.exports=function(t){if("string"!==typeof t)return;const e=t.toUpperCase();return Object.prototype.hasOwnProperty.call(r,e)?r[e]:void 0},t.exports.currencySymbolMap=r},500:function(t){t.exports={AED:"\u062f.\u0625",AFN:"\u060b",ALL:"L",AMD:"\u058f",ANG:"\u0192",AOA:"Kz",ARS:"$",AUD:"$",AWG:"\u0192",AZN:"\u20bc",BAM:"KM",BBD:"$",BDT:"\u09f3",BGN:"\u043b\u0432",BHD:".\u062f.\u0628",BIF:"FBu",BMD:"$",BND:"$",BOB:"$b",BOV:"BOV",BRL:"R$",BSD:"$",BTC:"\u20bf",BTN:"Nu.",BWP:"P",BYN:"Br",BYR:"Br",BZD:"BZ$",CAD:"$",CDF:"FC",CHE:"CHE",CHF:"CHF",CHW:"CHW",CLF:"CLF",CLP:"$",CNH:"\xa5",CNY:"\xa5",COP:"$",COU:"COU",CRC:"\u20a1",CUC:"$",CUP:"\u20b1",CVE:"$",CZK:"K\u010d",DJF:"Fdj",DKK:"kr",DOP:"RD$",DZD:"\u062f\u062c",EEK:"kr",EGP:"\xa3",ERN:"Nfk",ETB:"Br",ETH:"\u039e",EUR:"\u20ac",FJD:"$",FKP:"\xa3",GBP:"\xa3",GEL:"\u20be",GGP:"\xa3",GHC:"\u20b5",GHS:"GH\u20b5",GIP:"\xa3",GMD:"D",GNF:"FG",GTQ:"Q",GYD:"$",HKD:"$",HNL:"L",HRK:"kn",HTG:"G",HUF:"Ft",IDR:"Rp",ILS:"\u20aa",IMP:"\xa3",INR:"\u20b9",IQD:"\u0639.\u062f",IRR:"\ufdfc",ISK:"kr",JEP:"\xa3",JMD:"J$",JOD:"JD",JPY:"\xa5",KES:"KSh",KGS:"\u043b\u0432",KHR:"\u17db",KMF:"CF",KPW:"\u20a9",KRW:"\u20a9",KWD:"KD",KYD:"$",KZT:"\u20b8",LAK:"\u20ad",LBP:"\xa3",LKR:"\u20a8",LRD:"$",LSL:"M",LTC:"\u0141",LTL:"Lt",LVL:"Ls",LYD:"LD",MAD:"MAD",MDL:"lei",MGA:"Ar",MKD:"\u0434\u0435\u043d",MMK:"K",MNT:"\u20ae",MOP:"MOP$",MRO:"UM",MRU:"UM",MUR:"\u20a8",MVR:"Rf",MWK:"MK",MXN:"$",MXV:"MXV",MYR:"RM",MZN:"MT",NAD:"$",NGN:"\u20a6",NIO:"C$",NOK:"kr",NPR:"\u20a8",NZD:"$",OMR:"\ufdfc",PAB:"B/.",PEN:"S/.",PGK:"K",PHP:"\u20b1",PKR:"\u20a8",PLN:"z\u0142",PYG:"Gs",QAR:"\ufdfc",RMB:"\uffe5",RON:"lei",RSD:"\u0414\u0438\u043d.",RUB:"\u20bd",RWF:"R\u20a3",SAR:"\ufdfc",SBD:"$",SCR:"\u20a8",SDG:"\u062c.\u0633.",SEK:"kr",SGD:"S$",SHP:"\xa3",SLL:"Le",SOS:"S",SRD:"$",SSP:"\xa3",STD:"Db",STN:"Db",SVC:"$",SYP:"\xa3",SZL:"E",THB:"\u0e3f",TJS:"SM",TMT:"T",TND:"\u062f.\u062a",TOP:"T$",TRL:"\u20a4",TRY:"\u20ba",TTD:"TT$",TVD:"$",TWD:"NT$",TZS:"TSh",UAH:"\u20b4",UGX:"USh",USD:"$",UYI:"UYI",UYU:"$U",UYW:"UYW",UZS:"\u043b\u0432",VEF:"Bs",VES:"Bs.S",VND:"\u20ab",VUV:"VT",WST:"WS$",XAF:"FCFA",XBT:"\u0243",XCD:"$",XOF:"CFA",XPF:"\u20a3",XSU:"Sucre",XUA:"XUA",YER:"\ufdfc",ZAR:"R",ZMW:"ZK",ZWD:"Z$",ZWL:"$"}},3439:function(){},7244:function(){},5892:function(){},4444:function(){},8507:function(t,e){"use strict";function o(t){for(var e=1;e<arguments.length;e++){var o=arguments[e];for(var r in o)t[r]=o[r]}return t}var r=function t(e,r){function n(t,n,i){if("undefined"!==typeof document){"number"===typeof(i=o({},r,i)).expires&&(i.expires=new Date(Date.now()+864e5*i.expires)),i.expires&&(i.expires=i.expires.toUTCString()),t=encodeURIComponent(t).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var s="";for(var a in i)i[a]&&(s+="; "+a,!0!==i[a]&&(s+="="+i[a].split(";")[0]));return document.cookie=t+"="+e.write(n,t)+s}}return Object.create({set:n,get:function(t){if("undefined"!==typeof document&&(!arguments.length||t)){for(var o=document.cookie?document.cookie.split("; "):[],r={},n=0;n<o.length;n++){var i=o[n].split("="),s=i.slice(1).join("=");try{var a=decodeURIComponent(i[0]);if(r[a]=e.read(s,a),t===a)break}catch(l){}}return t?r[t]:r}},remove:function(t,e){n(t,"",o({},e,{expires:-1}))},withAttributes:function(e){return t(this.converter,o({},this.attributes,e))},withConverter:function(e){return t(o({},this.converter,e),this.attributes)}},{attributes:{value:Object.freeze(r)},converter:{value:Object.freeze(e)}})}({read:function(t){return'"'===t[0]&&(t=t.slice(1,-1)),t.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(t){return encodeURIComponent(t).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}},{path:"/"});e.Z=r}}]);
|