whatmore-react-assets 1.0.1806 → 1.0.1808

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.
@@ -0,0 +1,2 @@
1
+ /*! For license information please see carousel-template-ai.9827361f.chunk.js.LICENSE.txt */
2
+ (self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[151],{22:function(e,t,r){"use strict";r.d(t,{$S:function(){return s},_:function(){return o},b4:function(){return n},dl:function(){return i},nN:function(){return c},tn:function(){return l},vF:function(){return a}});const o="device_type",i="device_mode",n="mobile",a="tablet",s="desktop",l="portrait",c="landscape"},932:function(e,t,r){"use strict";var o=r(5830),i=r(1941),n=r(22),a=r(1348);t.A=function(e){const[t,r,s]=(0,i.A)(),[l]=(0,o.QN)("whatmoreLandscapePadding"),[c]=(0,o.QN)("whatmoreShopId"),[u]=(0,o.QN)("whatmoreVideoTileSize"),[d]=(0,o.QN)("whatmoreVideoTileSizePortrait"),p=s>r,m="portrait"==t?d:u,h=!("portrait"!=t||!(s>=481)),v=m/100*1.3*.5,f=m/100;var w=Math.min(s,r),[S,g,y,C]=[.6*w*(16/9),.6*w,1.4,0];function x(e){return Math.round(10*e)/10}var N={DEVICE_TYPE:n.b4,DEVICE_MODE:n.tn};if(p){const e=g*v,t=S*v;[S,g,y,C]=[t,e,(s-2*l-2*(0,a.$du)(c))/(1.1*e),l],N[n._]=n.$S,N[n.dl]=n.nN}else if(h){var D=.8*g,M=.8*S;"portrait"==t?(D*=f,M*=f,[S,g,y,C]=[M,D,x(s/(1.2*D)),0],N[n._]=n.vF,N[n.dl]=n.tn):([S,g,y,C]=[M,D,(s-2*l)/(1.1*D),l],N[n._]=n.vF,N[n.dl]=n.nN)}else{D=g,M=S;"portrait"==t?(D=D*f*.9,M=M*f*.9,[S,g,y,C]=[M,D,x(s/(1.15*D)),0],N[n._]=n.b4,N[n.dl]=n.tn):(D=.7*g,M=.7*S,[S,g,y,C]=[M,D,(s-2*l)/(1.1*D),l],N[n._]=n.b4,N[n.dl]=n.nN)}return[S,g,y,C,N]}},2173:function(e,t,r){const o=r(8558);e.exports=function(e){if("string"!==typeof e)return;const t=e.toUpperCase();return Object.prototype.hasOwnProperty.call(o,t)?o[t]:void 0},e.exports.currencySymbolMap=o},7136:function(e,t,r){"use strict";var o=r(9950),i=r(932),n=r(7509),a=r(5830),s=r(4414);t.A=function(e){var[t,r]=(0,i.A)();(0,o.useContext)(n.h);const l=(0,a.Xd)("whatmoreShopId");return e.event,(0,s.jsx)("div",{style:{margin:"0 auto",width:"8968077397"==l?void 0:r,aspectRatio:"8968077397"==l?9/16:void 0,height:"8968077397"==l?"100%":t,overflow:"hidden"}})}},7509:function(e,t,r){"use strict";r.d(t,{h:function(){return o}});const o=(0,r(9950).createContext)({tileTopMargin:10,tileBottomMMargin:10,tileLeftMargin:10,tileRightMargin:10,showPlayButton:!0})},8558:function(e){e.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:"$"}},9112:function(e,t,r){"use strict";r.r(t),r.d(t,{default:function(){return b}});var o=r(9950),i=r(340),n=r(5089),a=r(5873),s=r(572),l=r(8603),c=r(9946),u=r(9094),d=(r(9130),r(932)),p=r(1941),m=r(5491),h=r.n(m),v=r(5830),f=r(7509),w=r(7136),S=r(1348),g=r(5551),y=r(1351),C=r(6157),x=(r(6641),r(9879)),N=r(22),D=r(6594),M=r(8149),R=r(7740),_=r(4414);var P=function(e){var t,r,i,n,a,s,l,c,u,p,m,h,f,w,g;const y=(0,o.useRef)(null),[C,P,A,T,B]=(0,d.A)(),b=1*P,F=1*C,U=((0,v.Xd)("whatmoreUITheme"),(0,v.Xd)("whatmoreShopId")),$="portrait"===B[N.dl],j=$?(0,S.HWj)(U):(0,S.N_4)(U),E=(0,v.Xd)("whatmorePrimaryFont"),I=(0,v.Xd)("whatmoreSecondaryColor"),L=e.onClick,O=null===(t=e.isOnFocus)||void 0===t||t,K=null!==(r=e.playOnUnfocus)&&void 0!==r&&r,[k,G]=(0,o.useState)(e.event),[V,H]=(0,o.useState)(),[W,X]=(0,o.useState)(!1),Y=null!==(i=null===(n=k.products)||void 0===n?void 0:n.find(e=>"active"==e.product_status))&&void 0!==i?i:null===(a=k.products)||void 0===a?void 0:a[0],Z=Math.round(+(null===Y||void 0===Y?void 0:Y.price)),z=Math.round(+(null===Y||void 0===Y?void 0:Y.compare_price)),Q=z&&0!=z&&z>Z?Math.round((z-Z)/z*100):NaN,[J,q]=(0,o.useState)(Q),[ee,te]=(0,o.useState)(!1);return(0,o.useEffect)(()=>{(0,S.w4b)(U)?(0,D.fu)(k,(0,S.NCy)(U),U).then(e=>{var t,r,o;G(e);const i=Math.round(null===(t=e.products)||void 0===t||null===(r=t[0])||void 0===r?void 0:r.price),n=Math.round(null===e||void 0===e||null===(o=e.products[0])||void 0===o?void 0:o.compare_price),a=n&&0!=n&&n>i?Math.round((n-i)/n*100):NaN;q(a),te(!0)}).catch(e=>{console.warn("Whatmore AI Template: Failed to enrich event with price data, using fallback",e),te(!0)}):(async()=>{try{const e=await(0,M.M)(Y,(0,S.NCy)(U),U);H(e),te(!0)}catch(e){console.warn("Whatmore AI Template: Failed to fetch product details, using fallback data",e),te(!0)}})()},[]),(0,o.useEffect)(()=>{if(y.current){const e=y.current,t=$?"portrait":"landscape",r=getComputedStyle(e),o=parseFloat(r.getPropertyValue(`--wtmr-name-font-scale-${t}`))||($?1.25:1.38),i=parseFloat(r.getPropertyValue(`--wtmr-price-font-scale-${t}`))||($?1.4:1.56),n=parseFloat(r.getPropertyValue(`--wtmr-category-font-scale-${t}`))||($?1:1.08),a=parseFloat(r.getPropertyValue(`--wtmr-discount-font-scale-${t}`))||($?1.1:1.2);e.style.setProperty("--wtmr-font-family",E),e.style.setProperty("--wtmr-discount-badge-bg",I),e.style.setProperty("--wtmr-tile-width",P+"px"),e.style.setProperty("--wtmr-font-multiplier",j),e.style.setProperty("--wtmr-name-font-scale",o),e.style.setProperty("--wtmr-price-font-scale",i),e.style.setProperty("--wtmr-category-font-scale",n),e.style.setProperty("--wtmr-discount-font-scale",a)}},[E,I,P,j,$]),(0,_.jsxs)("div",{ref:y,className:"wtmr-carousel-tile",style:{maxWidth:b},onClick:()=>L(k),children:[(0,_.jsxs)("div",{className:"wtmr-carousel-tile__video-container",style:{maxHeight:F},children:[(0,_.jsx)(x.A,{className:"wtmr-carousel-tile__video",height:(0,S.u06)(U)+" !important",width:"100%",url:k.thumbnail_image,isPlaying:O||K,event:k}),Y&&(0,_.jsx)("div",{className:"wtmr-carousel-tile__add-to-cart-overlay",onClick:e=>e.stopPropagation(),children:(0,_.jsx)("span",{className:"wtmr-carousel-tile__add-to-cart-label",children:"ADD TO CART"})})]}),Y&&(0,_.jsxs)("div",{className:"wtmr-carousel-tile__product-details-container",children:[(0,_.jsxs)("div",{className:"wtmr-carousel-tile__product-information-section",children:[(null===Y||void 0===Y?void 0:Y.thumbnail_image)&&(0,_.jsx)("div",{className:"wtmr-carousel-tile__product-image-container",children:(0,_.jsx)("img",{className:"wtmr-carousel-tile__product-image "+(W?"wtmr-carousel-tile__product-image--loaded":""),src:(null===Y||void 0===Y||null===(s=Y.thumbnail_image)||void 0===s||null===(l=s.split("?"))||void 0===l?void 0:l[0])+"?width=400&height=400",alt:"thumbnail",onLoad:()=>X(!0)})}),(0,_.jsxs)("div",{className:"wtmr-carousel-tile__product-text-container",children:[(null===Y||void 0===Y?void 0:Y.product_type)&&(0,_.jsx)("p",{className:"wtmr-carousel-tile__product-category-label",children:null===Y||void 0===Y?void 0:Y.product_type}),(null===Y||void 0===Y?void 0:Y.title)&&(0,_.jsx)("p",{className:"wtmr-carousel-tile__product-name",children:null===Y||void 0===Y?void 0:Y.title})]})]}),ee&&(0,_.jsxs)("div",{className:"wtmr-carousel-tile__product-pricing-section",children:[(0,_.jsx)("p",{className:"wtmr-carousel-tile__price-selling",children:(0,D.Sb)(parseFloat((0,R.U)()?(null!==(c=null===V||void 0===V||null===(u=V.variants)||void 0===u||null===(p=u[0])||void 0===p?void 0:p.price)&&void 0!==c?c:null===V||void 0===V?void 0:V.price)/100:null===Y||void 0===Y?void 0:Y.price)," ",U,null===(m=k.products[0])||void 0===m?void 0:m.currency)}),!isNaN(z)&&z>Z&&(0,_.jsx)("p",{className:"wtmr-carousel-tile__price-original",children:(0,D.Sb)(parseFloat((0,R.U)()?(null!==(h=null===V||void 0===V||null===(f=V.variants)||void 0===f||null===(w=f[0])||void 0===w?void 0:w.compare_at_price)&&void 0!==h?h:null===V||void 0===V?void 0:V.compare_at_price)/100:null===Y||void 0===Y?void 0:Y.compare_price)," ",U,null===(g=k.products[0])||void 0===g?void 0:g.currency)}),!isNaN(J)&&0!=J&&(0,_.jsx)("div",{className:"wtmr-carousel-tile__discount-percentage-badge",children:(0,_.jsxs)("p",{className:"wtmr-carousel-tile__discount-percentage-value",children:[J,"%"]})})]})]})]})};const A=(0,l.A)({key:"whatmore-css-ai"});function T(e){const[t,r,i]=(0,d.A)(),[n,a,s]=(0,p.A)(),l=(0,v.Xd)("whatmoreShopId"),m=e.events,h=e.onClick,f=i*(0,S.kcl)(l),x=(0,S.cbh)(l),[N,D]=(0,o.useState)(x?m.length:f),{whatmoreWidgetSourceDetails:M}=(0,o.useContext)(g.B);return(0,o.useEffect)(()=>{N<=f&&D(e=>e+f)},[f]),(0,_.jsx)("div",{className:"wtmr-carousel-container-portrait whatmore-events-carousel-portrait ai-carousel-portrait",style:{width:s-48,zIndex:1},children:(0,_.jsx)(c.RC,{slidesPerView:m.length>1?f:1,initialSlide:m.length>1?1:0,centeredSlides:!0,centeredSlidesBounds:!1,watchSlidesProgress:!0,modules:[u.U1],spaceBetween:12,freeMode:{enabled:!0,sticky:!1,momentum:!0,momentumRatio:.7,momentumBounce:!1,momentumVelocityRatio:.9},touchRatio:1.2,simulateTouch:!0,allowTouchMove:!0,grabCursor:!0,resistance:!0,resistanceRatio:.75,speed:400,onSlideChange:e=>{(0,y.UM)({userInteractionType:C.O.HOMEPAGE_CAROUSEL_SWIPED,widgetSourceDetails:M}),e.realIndex>e.previousIndex&&D(e=>e+f)},loop:x,style:{paddingTop:"8px",paddingBottom:"8px"},children:m.map((e,t)=>t<=N&&(0,_.jsx)(c.qr,{children:({isActive:t,isPrev:r,isNext:o,isVisible:i})=>r||o||t?(0,_.jsx)("div",{className:"wm-carousel__slide-wrapper "+(t?"wtmr-carousel__slide-wrapper--active":"wtmr-carousel__slide-wrapper--inactive"),children:(0,_.jsx)(P,{isOnFocus:t&&i,playOnUnfocus:!1,event:e,onClick:()=>{h(e)}})}):(0,_.jsx)(w.A,{})},"whatmore-event-tile-ai-portrait-"+e.index))})})}function B(e){const[t,r,i,n]=(0,d.A)(),[a,s,l]=(0,p.A)(),[m,f]=(0,o.useState)(-1),x=(0,v.Xd)("whatmoreShopId"),N=e.onClick,D=e.events,M=(0,S.cbh)(x),[R,A]=(0,o.useState)(M?D.length:i),T=Math.min(i,D.length),{whatmoreWidgetSourceDetails:B}=(0,o.useContext)(g.B),b=(0,o.useRef)(null);return(0,o.useEffect)(()=>{if(b.current){const e=r*T*(0,S.fHt)(x)+"px";D.length<4?b.current.style.setProperty("width",e,"important"):b.current.style.width=e}},[r,T,x,R,D.length]),(0,o.useEffect)(()=>{R<=i&&A(e=>e+i)},[i]),(0,_.jsx)("div",{className:"wtmr-carousel-container-landscape whatmore-events-carousel-landscape ai-carousel-landscape",style:{width:l,paddingLeft:n+"px",paddingRight:n+"px"},children:(0,_.jsx)("div",{ref:b,style:{zIndex:1},children:(0,_.jsx)(c.RC,{slidesPerView:T,watchSlidesProgress:!0,modules:[u.FJ,u.U1],freeMode:{enabled:!0,sticky:!1,momentum:!0,momentumRatio:.5,momentumBounce:!1,momentumVelocityRatio:.7},onSlideChange:e=>{(0,y.UM)({userInteractionType:C.O.HOMEPAGE_CAROUSEL_SWIPED,widgetSourceDetails:B}),e.realIndex>e.previousIndex&&A(e=>e+i)},spaceBetween:0,loop:!1,touchRatio:1,simulateTouch:!0,allowTouchMove:!0,grabCursor:!0,resistance:!0,resistanceRatio:.75,speed:500,mousewheel:{forceToAxis:!0,sensitivity:.6,releaseOnEdges:!0,invert:!1},children:D.map((e,t)=>{const r=h()(()=>f(t),50);return t<=R&&(0,_.jsx)(c.qr,{onMouseEnter:()=>{r()},onMouseLeave:()=>{r.cancel(),f(-1)},style:{height:"100%"},children:({isActive:r,isPrev:o,isNext:i,isVisible:n})=>n||o||i?(0,_.jsx)("div",{style:{height:"100%",transform:t===m?"translate3d(0, -1px, 0)":"translate3d(0, 0, 0)",transition:"transform 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94), filter 0.3s ease-out, opacity 0.3s ease-out",filter:t===m?"brightness(1.02)":"none",opacity:t===m?1:.98,willChange:"transform, filter, opacity"},children:(0,_.jsx)(P,{isOnFocus:t==m,playOnUnfocus:!(0,S.aO7)(x)||t==parseInt(T/2)&&-1==m,event:e,onClick:()=>{N(e)}})}):(0,_.jsx)(w.A,{})},"wht-event-tile-ai-landscape-"+e.index)})})})})}var b=function(e){const[t,r,l]=(0,p.A)(),[c]=(0,v.QN)("whatmoreShopId"),[u]=(0,v.QN)("whatmorePrimaryColor"),[d]=(0,v.QN)("whatmoreTitleFont"),m="portrait"==t?(0,v.Xd)("whatmoreTitleFontSizePortrait"):(0,v.Xd)("whatmoreTitleFontSize"),{whatmoreRootId:h}=(0,o.useContext)(g.B),{whatmoreCollectionHeading:w}=(0,o.useContext)(g.B),{whatmoreIsCollectionsTemplate:S}=(0,o.useContext)(g.B),y=e.events,C=e.onClick,x=d,N=(0,o.useRef)(null);function D(e){C(e)}return(0,o.useEffect)(()=>{a.Sn.forEach(e=>{var t;const r=null!==(t=e.querySelector('.whatmore-template-type[data-wh="template-ai"]'))&&void 0!==t?t:e.querySelector('.whatmore-template-type[data="template-ai"]');if(!r)return;r&&e&&(e.style.minHeight="0px")})},[]),(0,o.useEffect)(()=>{if(N.current){const e=N.current;e.style.setProperty("--wtmr-font-family",x),e.setAttribute("data-mode",t)}},[x,t]),delete n.Ay.styles.global,(0,_.jsx)(s.C,{value:A,children:(0,_.jsx)("div",{ref:N,className:"wtmr-carousel whatmore-carousel-events ai-carousel-container",style:{height:"100%",background:"transparent",position:"relative"},children:(0,_.jsx)(i.s,{theme:n.Ay,cssVarsRoot:h,resetCSS:!1,children:(0,_.jsxs)(f.h.Provider,{value:{tileTopMargin:8,tileBottomMMargin:8,tileLeftMargin:2,tileRightMargin:2,showPlayButton:!0},children:[console.log("test",e.heading.trim())&&(e.heading.trim().length>0||S)&&(0,_.jsx)("div",{className:"wtmr-carousel-header",children:(0,_.jsx)("h2",{className:"wtmr-carousel-title",style:{fontSize:m+"px"},children:S?"W"!==w?w:"":e.heading})}),"landscape"===t?(0,_.jsx)(B,{events:y,onClick:D}):(0,_.jsx)(T,{events:y,onClick:D})]})})})})}},9211:function(e,t,r){"use strict";function o(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var o in r)e[o]=r[o]}return e}r.d(t,{A:function(){return i}});var i=function e(t,r){function i(e,i,n){if("undefined"!==typeof document){"number"===typeof(n=o({},r,n)).expires&&(n.expires=new Date(Date.now()+864e5*n.expires)),n.expires&&(n.expires=n.expires.toUTCString()),e=encodeURIComponent(e).replace(/%(2[346B]|5E|60|7C)/g,decodeURIComponent).replace(/[()]/g,escape);var a="";for(var s in n)n[s]&&(a+="; "+s,!0!==n[s]&&(a+="="+n[s].split(";")[0]));return document.cookie=e+"="+t.write(i,e)+a}}return Object.create({set:i,get:function(e){if("undefined"!==typeof document&&(!arguments.length||e)){for(var r=document.cookie?document.cookie.split("; "):[],o={},i=0;i<r.length;i++){var n=r[i].split("="),a=n.slice(1).join("=");try{var s=decodeURIComponent(n[0]);if(o[s]=t.read(a,s),e===s)break}catch(l){}}return e?o[e]:o}},remove:function(e,t){i(e,"",o({},t,{expires:-1}))},withAttributes:function(t){return e(this.converter,o({},this.attributes,t))},withConverter:function(t){return e(o({},this.converter,t),this.attributes)}},{attributes:{value:Object.freeze(r)},converter:{value:Object.freeze(t)}})}({read:function(e){return'"'===e[0]&&(e=e.slice(1,-1)),e.replace(/(%[\dA-F]{2})+/gi,decodeURIComponent)},write:function(e){return encodeURIComponent(e).replace(/%(2[346BF]|3[AC-F]|40|5[BDE]|60|7[BCD])/g,decodeURIComponent)}},{path:"/"})}}]);
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkwhatmorelive_react=self.webpackChunkwhatmorelive_react||[]).push([[374],{1941:function(n,e,t){t.d(e,{A:function(){return u}});var i=t(5830),r=t(9950);function o(n){if(!n)return{};var e={};return Array.from(n.attributes).forEach(n=>{var t;e[n.name]=(t=n.value,isNaN(+t)?t:+t)}),e}function a(...n){try{var e;const t=document.getElementById("whatmorePreviewMode");if(!t)return null;const i=null===n||void 0===n?void 0:n[0];if(!i)return!0;let r={};return r=i.includes("function")?{}:o(t),null!==(e=r)&&void 0!==e&&e[i]?r[i]:null}catch(t){return null}}var s=function({disablePreview:n=!1}={}){var e,t,i=n?window.innerHeight:null!==(e=a("height-wh"))&&void 0!==e?e:window.innerHeight,o=n?window.innerWidth:null!==(t=a("width-wh"))&&void 0!==t?t:window.innerWidth,[s,d]=[i,o];const[c,l]=(0,r.useState)([s>d?"portrait":"landscape",s,d]);return(0,r.useLayoutEffect)(()=>{function e(){var e,t,i=n?window.innerHeight:null!==(e=a("height-wh"))&&void 0!==e?e:window.innerHeight,r=n?window.innerWidth:null!==(t=a("width-wh"))&&void 0!==t?t:window.innerWidth,[o,s]=[i,r];l(o>s?["portrait",o,s]:["landscape",o,s])}return window.addEventListener("resize",e),window.addEventListener("orientationchange",e),screen.orientation&&screen.orientation.addEventListener("change",e),e(),()=>{window.removeEventListener("resize",e),window.removeEventListener("orientationchange",e),screen.orientation&&screen.orientation.removeEventListener("change",e)}},[]),c},d=t(1348);const c=(0,i.Xd)("whatmoreShopId");function l(){if("8908406869"==c||"90518552861"==c||"STRI4V3OYCH"==c||"56517427254"==c||"19506115"==c||"STR4YVJTT37"===c||"71079985468"===c||"1977843785"===c){var n,e,t;let i=document.querySelector('.whatmore-base:has(.whatmore-widget[data-wh="carousel"])');i||(i=document.querySelector('.whatmore-base:has(.whatmore-widget[data-wh="collection"])'));let r=i;for(;r&&r!==document&&(r=r.parentElement,!r||r.classList.contains("whatmore-base")););return[window.innerHeight,(null!==(n=null===(e=r)||void 0===e||null===(t=e.getBoundingClientRect())||void 0===t?void 0:t.width)&&void 0!==n?n:window.innerWidth)+(0,d.$du)(c)]}return"51273072796"==c?[document.documentElement.clientHeight,document.documentElement.clientWidth]:[window.innerHeight,window.innerWidth]}var h=function(){var[n,e]=l();const[t,i]=(0,r.useState)([n>e?"portrait":"landscape",n,e]);return(0,r.useLayoutEffect)(()=>{function n(){var[n,e]=l();i(n>e?["portrait",n,e]:["landscape",n,e])}return window.addEventListener("resize",n),window.addEventListener("orientationchange",n),screen.orientation&&screen.orientation.addEventListener("change",n),n(),()=>{window.removeEventListener("resize",n),window.removeEventListener("orientationchange",n),screen.orientation&&screen.orientation.removeEventListener("change",n)}},[]),t};var u=function(n){var e;const t=(0,i.Xd)("isWhatmorePreviewMode"),r=h(),o=s({disablePreview:null!==(e=null===n||void 0===n?void 0:n.disablePreview)&&void 0!==e&&e});return t?o:r}},5100:function(n,e,t){t.r(e);var i=t(9950),r=t(1941),o=t(5830),a=t(4414);const s=i.memo(()=>{if(!(0,o.Xd)("isLandingSharedLink"))return(0,a.jsx)(a.Fragment,{});const[n]=(0,r.A)();return(0,a.jsxs)("div",{className:`shimmer-container ${n}`,children:["portrait"===n?(0,a.jsx)("div",{className:"shimmer-item portrait-full",children:(0,a.jsx)("div",{className:"shimmer-effect"})}):Array(3).fill().map((n,e)=>(0,a.jsx)("div",{className:"shimmer-item landscape-item "+(1===e?"center-item":""),children:(0,a.jsx)("div",{className:"shimmer-effect"})},e)),(0,a.jsx)("style",{children:"\n .shimmer-container {\n display: flex;\n position: fixed;\n top: 0;\n left: 0;\n width: 100vw;\n height: 100vh;\n overflow-x: scroll;\n scroll-snap-type: x mandatory;\n scroll-behavior: smooth;\n z-index: 1000;\n }\n\n .portrait {\n justify-content: center;\n align-items: center;\n background: rgba(0, 0, 0, 0.6);\n }\n\n .landscape {\n justify-content: center;\n align-items: center;\n background: rgba(0, 0, 0, 0.8);\n }\n\n .shimmer-item {\n scroll-snap-align: start;\n display: flex;\n justify-content: center;\n align-items: center;\n position: relative;\n transition: transform 0.3s ease;\n }\n\n .portrait-full {\n width: 100vw;\n height: 100vh;\n margin: 0; \n }\n\n .landscape-item {\n width: 250px;\n height: 450px;\n background: #D3D3D3;\n border-radius: 8px;\n margin-left: -50px; \n }\n\n .center-item {\n width: 360px;\n height: 620px;\n box-shadow: 0px 4px 15px rgba(0, 0, 0, 0.5); \n z-index: 10; \n }\n\n .shimmer-effect {\n position: absolute;\n top: 0;\n left: 0;\n width: 100%;\n height: 100%;\n background: linear-gradient(90deg, rgba(0, 0, 0, 0.3) 25%, rgba(0, 0, 0, 0.5) 50%, rgba(0, 0, 0, 0.3) 75%);\n animation: shimmer 2s infinite;\n background-size: 200% 100%;\n }\n\n @keyframes shimmer {\n 0% {\n background-position: -200% 0;\n }\n 100% {\n background-position: 200% 0;\n }\n }\n "})]})});e.default=s}}]);