@sunrise-upc/mobile-prod-card 12.1.4 → 12.2.0-beta.0

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 @@
1
+ .content_cJLvv{display:flex;flex-direction:column;gap:16px}.heading_ezKpZ{font-weight:700;font-size:20px;line-height:1.3}.buttons_W8ElH{display:flex;flex-wrap:wrap;justify-content:flex-end;gap:16px;margin-top:8px}
@@ -0,0 +1,2 @@
1
+ import e from"react";import t from"./GenericPopup.module.scss.js";import n from"../NewLineCheck/GenericModal.js";import o from"../FalconButtonV2/FalconButtonV2.js";import l from"../FalconDescription/FalconDescription.js";const i=({modalState:i,onCloseHandler:a,content:r,onPrimaryClick:d,onSecondaryClick:c,wafIdentifier:m=""})=>{var u,s,v,p,h;return e.createElement(n,{modalState:i,handler:a,showFooter:!1,width:"624px",height:"auto",backDrop:!0},e.createElement("div",{className:t.content},(null==r?void 0:r.heading)&&e.createElement("div",{className:t.heading},r.heading),null===(u=null==r?void 0:r.body)||void 0===u?void 0:u.map(t=>e.createElement(l,{content:t,key:t._uid})),(null===(s=null==r?void 0:r.secondaryButton)||void 0===s?void 0:s.length)||(null===(v=null==r?void 0:r.primaryButton)||void 0===v?void 0:v.length)?e.createElement("div",{className:t.buttons},(null===(p=null==r?void 0:r.secondaryButton)||void 0===p?void 0:p.length)?e.createElement(o,{content:r.secondaryButton[0],onClick:()=>c?c():a(),metadata:void 0,wafIdentifier:m}):null,(null===(h=null==r?void 0:r.primaryButton)||void 0===h?void 0:h.length)?e.createElement(o,{content:r.primaryButton[0],onClick:()=>d?d():a(),metadata:void 0,wafIdentifier:m}):null):null))};export{i as default};
2
+ //# sourceMappingURL=GenericPopup.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GenericPopup.js","sources":["../../../../src/components/GenericPopup/GenericPopup.tsx"],"sourcesContent":["import React, { JSX } from 'react';\nimport Styles from './GenericPopup.module.scss';\nimport GenericModal from '../NewLineCheck/GenericModal';\nimport FalconButtonV2 from '../FalconButtonV2/FalconButtonV2';\nimport FalconDescription, {\n FalconDescriptionInterface\n} from '../FalconDescription/FalconDescription';\nimport { FalconButtonSchema, GenericSBProps } from '../types';\n\nexport interface TeleSalesErrorModalSchema extends GenericSBProps {\n heading: string;\n body: FalconDescriptionInterface[];\n primaryButton: FalconButtonSchema[];\n secondaryButton: FalconButtonSchema[];\n primaryButtonType?: string;\n secondaryButtonType?: string;\n}\n\ninterface GenericPopuProps {\n modalState: boolean;\n onCloseHandler: () => void;\n content?: TeleSalesErrorModalSchema;\n onPrimaryClick?: () => void;\n onSecondaryClick?: () => void;\n wafIdentifier?: string;\n}\n\nconst GenericPopu = ({\n modalState,\n onCloseHandler,\n content,\n onPrimaryClick,\n onSecondaryClick,\n wafIdentifier = ''\n}: GenericPopuProps): JSX.Element => {\n return (\n <GenericModal\n modalState={modalState}\n handler={onCloseHandler}\n showFooter={false}\n width='624px'\n height='auto'\n backDrop={true}\n >\n <div className={Styles.content}>\n {content?.heading && <div className={Styles.heading}>{content.heading}</div>}\n {content?.body?.map((item) => (\n <FalconDescription content={item} key={item._uid} />\n ))}\n {(content?.secondaryButton?.length || content?.primaryButton?.length) ? (\n <div className={Styles.buttons}>\n {content?.secondaryButton?.length ? (\n <FalconButtonV2\n content={content.secondaryButton[0]}\n onClick={() => (onSecondaryClick ? onSecondaryClick() : onCloseHandler())}\n metadata={undefined}\n wafIdentifier={wafIdentifier}\n />\n ) : null}\n {content?.primaryButton?.length ? (\n <FalconButtonV2\n content={content.primaryButton[0]}\n onClick={() => (onPrimaryClick ? onPrimaryClick() : onCloseHandler())}\n metadata={undefined}\n wafIdentifier={wafIdentifier}\n />\n ) : null}\n </div>\n ) : null}\n </div>\n </GenericModal>\n );\n};\n\nexport default GenericPopu;\n"],"names":["GenericPopu","modalState","onCloseHandler","content","onPrimaryClick","onSecondaryClick","wafIdentifier","React","createElement","GenericModal","handler","showFooter","width","height","backDrop","className","Styles","heading","_a","body","map","item","FalconDescription","key","_uid","_b","secondaryButton","length","_c","primaryButton","buttons","_d","FalconButtonV2","onClick","metadata","undefined","_e"],"mappings":"6NA2BA,MAAMA,EAAc,EAClBC,aACAC,iBACAC,UACAC,iBACAC,mBACAC,gBAAgB,qBAEhB,OACEC,EAAAC,cAACC,EAAY,CACXR,WAAYA,EACZS,QAASR,EACTS,YAAY,EACZC,MAAM,QACNC,OAAO,OACPC,UAAU,GAEVP,EAAAC,cAAA,MAAA,CAAKO,UAAWC,EAAOb,UACpBA,aAAO,EAAPA,EAASc,UAAWV,EAAAC,cAAA,MAAA,CAAKO,UAAWC,EAAOC,SAAUd,EAAQc,SAChD,QAAbC,EAAAf,aAAO,EAAPA,EAASgB,YAAI,IAAAD,OAAA,IAAEE,IAAKC,GACnBd,gBAACe,EAAiB,CAACnB,QAASkB,EAAME,IAAKF,EAAKG,SAEpB,QAAxBC,EAAAtB,aAAO,EAAPA,EAASuB,uBAAe,IAAAD,OAAA,EAAAA,EAAEE,UAAgC,QAAtBC,EAAAzB,aAAO,EAAPA,EAAS0B,qBAAa,IAAAD,OAAA,EAAAA,EAAED,QAC5DpB,EAAAC,cAAA,MAAA,CAAKO,UAAWC,EAAOc,UACI,QAAxBC,EAAA5B,aAAO,EAAPA,EAASuB,uBAAe,IAAAK,OAAA,EAAAA,EAAEJ,QACzBpB,EAAAC,cAACwB,EAAc,CACb7B,QAASA,EAAQuB,gBAAgB,GACjCO,QAAS,IAAO5B,EAAmBA,IAAqBH,IACxDgC,cAAUC,EACV7B,cAAeA,IAEf,MACmB,QAAtB8B,EAAAjC,aAAO,EAAPA,EAAS0B,qBAAa,IAAAO,OAAA,EAAAA,EAAET,QACvBpB,EAAAC,cAACwB,EAAc,CACb7B,QAASA,EAAQ0B,cAAc,GAC/BI,QAAS,IAAO7B,EAAiBA,IAAmBF,IACpDgC,cAAUC,EACV7B,cAAeA,IAEf,MAEJ"}
@@ -0,0 +1,3 @@
1
+ import './GenericPopup.css';
2
+ var t={content:"content_cJLvv",heading:"heading_ezKpZ",buttons:"buttons_W8ElH"};export{t as default};
3
+ //# sourceMappingURL=GenericPopup.module.scss.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"GenericPopup.module.scss.js","sources":[],"sourcesContent":[],"names":[],"mappings":""}
@@ -1 +1 @@
1
- {"version":3,"file":"CoverCheckWrapper.js","sources":["../../../../src/components/NewLineCheck/CoverCheckWrapper.tsx"],"sourcesContent":["import React, { FC, useEffect, useState } from 'react';\nimport CheckCoverageComponent from './CheckCoverage';\nimport Styles from './CoverCheckWrapper.module.scss';\nimport { viewport } from '../../utils/utils';\n\nconst CheckCoverage: FC<any> = ({\n content,\n isFetchingLineCheck,\n overlayIsOpen,\n externalHandleModal,\n productName,\n onSuccess,\n lineCheckOnClear,\n onCreateCart\n}) => {\n const openInOverlay = overlayIsOpen ? overlayIsOpen : content?.openInOverlay;\n content['openInOverlay'] = true;\n const [openModal, setOpenModal] = useState(overlayIsOpen);\n\n const handleModal = () => {\n setOpenModal(!openModal);\n externalHandleModal && externalHandleModal(!openModal);\n };\n const viewPort = viewport();\n const isMobile = viewPort === 'mobile' ? true : false;\n\n useEffect(() => {\n setOpenModal(overlayIsOpen);\n }, [overlayIsOpen]);\n\n return (\n <div>\n {isMobile && openModal && openInOverlay ? (\n <div className={Styles['overlay']}>\n <div className={Styles['modal-content']}>\n <CheckCoverageComponent\n content={content}\n handleModal={handleModal}\n openModal={openModal}\n isFetchingLineCheck={isFetchingLineCheck}\n productName={productName}\n onSuccess={onSuccess}\n lineCheckOnClear={lineCheckOnClear}\n onCreateCart={onCreateCart}\n />\n </div>\n </div>\n ) : (\n <CheckCoverageComponent\n content={content}\n isFetchingLineCheck={isFetchingLineCheck}\n onSuccess={onSuccess}\n lineCheckOnClear={lineCheckOnClear}\n />\n )}\n </div>\n );\n};\n\nexport default CheckCoverage;\n"],"names":["CheckCoverage","content","isFetchingLineCheck","overlayIsOpen","externalHandleModal","productName","onSuccess","lineCheckOnClear","onCreateCart","openInOverlay","openModal","setOpenModal","useState","isMobile","viewport","useEffect","React","createElement","className","Styles","CheckCoverageComponent","handleModal"],"mappings":"uLAKA,MAAMA,EAAyB,EAC7BC,UACAC,sBACAC,gBACAC,sBACAC,cACAC,YACAC,mBACAC,mBAEA,MAAMC,EAAgBN,IAAgCF,eAAAA,EAASQ,eAC/DR,EAAuB,eAAI,EAC3B,MAAOS,EAAWC,GAAgBC,EAAST,GAOrCU,EAAwB,WADbC,IAOjB,OAJAC,EAAU,KACRJ,EAAaR,IACZ,CAACA,IAGFa,EAAAC,cAAA,MAAA,KACGJ,GAAYH,GAAaD,EACxBO,EAAAC,cAAA,MAAA,CAAKC,UAAWC,EAAgB,SAC9BH,EAAAC,cAAA,MAAA,CAAKC,UAAWC,EAAO,kBACrBH,EAAAC,cAACG,EAAsB,CACrBnB,QAASA,EACToB,YAlBQ,KAClBV,GAAcD,GACdN,GAAuBA,GAAqBM,IAiBlCA,UAAWA,EACXR,oBAAqBA,EACrBG,YAAaA,EACbC,UAAWA,EACXC,iBAAkBA,EAClBC,aAAcA,MAKpBQ,EAAAC,cAACG,EAAsB,CACrBnB,QAASA,EACTC,oBAAqBA,EACrBI,UAAWA,EACXC,iBAAkBA"}
1
+ {"version":3,"file":"CoverCheckWrapper.js","sources":["../../../../src/components/NewLineCheck/CoverCheckWrapper.tsx"],"sourcesContent":["import React, { FC, useEffect, useState } from 'react';\nimport CheckCoverageComponent from './CheckCoverage';\nimport Styles from './CoverCheckWrapper.module.scss';\nimport { viewport } from '../../utils/utils';\n\n\nconst CheckCoverage: FC<any> = ({\n content,\n isFetchingLineCheck,\n overlayIsOpen,\n externalHandleModal,\n productName,\n onSuccess,\n lineCheckOnClear,\n onCreateCart\n}) => {\n const openInOverlay = overlayIsOpen ? overlayIsOpen : content?.openInOverlay;\n content['openInOverlay'] = true;\n const [openModal, setOpenModal] = useState(overlayIsOpen);\n\n const handleModal = () => {\n setOpenModal(!openModal);\n externalHandleModal && externalHandleModal(!openModal);\n };\n const viewPort = viewport();\n const isMobile = viewPort === 'mobile' ? true : false;\n\n useEffect(() => {\n setOpenModal(overlayIsOpen);\n }, [overlayIsOpen]);\n\n return (\n <div>\n {isMobile && openModal && openInOverlay ? (\n <div className={Styles['overlay']}>\n <div className={Styles['modal-content']}>\n <CheckCoverageComponent\n content={content}\n handleModal={handleModal}\n openModal={openModal}\n isFetchingLineCheck={isFetchingLineCheck}\n productName={productName}\n onSuccess={onSuccess}\n lineCheckOnClear={lineCheckOnClear}\n onCreateCart={onCreateCart}\n />\n </div>\n </div>\n ) : (\n <CheckCoverageComponent\n content={content}\n isFetchingLineCheck={isFetchingLineCheck}\n onSuccess={onSuccess}\n lineCheckOnClear={lineCheckOnClear}\n />\n )}\n </div>\n );\n};\n\nexport default CheckCoverage;\n"],"names":["CheckCoverage","content","isFetchingLineCheck","overlayIsOpen","externalHandleModal","productName","onSuccess","lineCheckOnClear","onCreateCart","openInOverlay","openModal","setOpenModal","useState","isMobile","viewport","useEffect","React","createElement","className","Styles","CheckCoverageComponent","handleModal"],"mappings":"uLAMA,MAAMA,EAAyB,EAC7BC,UACAC,sBACAC,gBACAC,sBACAC,cACAC,YACAC,mBACAC,mBAEA,MAAMC,EAAgBN,IAAgCF,eAAAA,EAASQ,eAC/DR,EAAuB,eAAI,EAC3B,MAAOS,EAAWC,GAAgBC,EAAST,GAOrCU,EAAwB,WADbC,IAOjB,OAJAC,EAAU,KACRJ,EAAaR,IACZ,CAACA,IAGFa,EAAAC,cAAA,MAAA,KACGJ,GAAYH,GAAaD,EACxBO,EAAAC,cAAA,MAAA,CAAKC,UAAWC,EAAgB,SAC9BH,EAAAC,cAAA,MAAA,CAAKC,UAAWC,EAAO,kBACrBH,EAAAC,cAACG,EAAsB,CACrBnB,QAASA,EACToB,YAlBQ,KAClBV,GAAcD,GACdN,GAAuBA,GAAqBM,IAiBlCA,UAAWA,EACXR,oBAAqBA,EACrBG,YAAaA,EACbC,UAAWA,EACXC,iBAAkBA,EAClBC,aAAcA,MAKpBQ,EAAAC,cAACG,EAAsB,CACrBnB,QAASA,EACTC,oBAAqBA,EACrBI,UAAWA,EACXC,iBAAkBA"}
@@ -1,2 +1,2 @@
1
- import{__awaiter as e}from"../../_virtual/_tslib.js";import o,{useState as l,useRef as t,useContext as n,useEffect as i}from"react";import d from"../Dotloader/Dotloader.js";import{createPortal as a}from"react-dom";import r from"../SkeletonLoader/SkeletonLoader.js";import s from"./StaticLineTable.module.scss.js";import c from"../richtext.js";import v from"./StaticProductEntitlement.js";import u from"./StaticBenefit.js";import m from"./DynamicPriceSection.js";import p from"./CheckoutButton.js";import g from"./StaticProductDetails.js";import{LineTableBasicPropConfig as f,AssetPathPropConfig as h}from"../../services/LineTableBasicPropConfig.js";import b from"js-cookie";import{LoginBasicPropConfig as E}from"../../services/LoginBasicPropConfig.js";import w from"../login/LoginModalV2.js";import{isTimerActive as C,fetchServiceOptions as P,fetchPrice as S,findHeight as y,checkGiftOrCashback as k,getTimeUntilNextTimerEvent as T,staticCreateCart as x,combineWithVasOptions as $,combineWithSmartPhone as D}from"./Product.utils.js";import L from"../ProductDetailsV3/GiftConfigV2.js";import N from"../ProductDetailsV3/ChooseGiftV2.js";import{viewport as I,replacePlaceholder as B,getUtcTimestamp as O}from"../../utils/utils.js";import j from"./StaticProductCashback.js";import{trackNewDatalayerEvent as A}from"../../utils/AnalyticsUtils.js";import{CTABUTTONCLICK as U,GAEVENT as V,EXISTINGCUSTOMER as F,LINETABLE as M,DOWNLOADPRODUCT as R}from"../../Analytics/AnalyticsConstants.js";import G from"./TVChannelModal.js";import _ from"../LineCheckV3/LinecheckModal.js";import J from"../BenefitWrapper/BenefitsValidateWrapper.js";import q from"../PretoPost/PreToPostSubsPopup.js";import W from"../LineCheckV3/GenericModal.js";import{fetchSubscriptionData as H,trackPegaEvents as z,validateP2P as K}from"../../services/LineTableService.js";import Q from"./ExsistingSubscriptionModal.js";import{getEcomCartInfo as X}from"../../models/Analytics/items.js";import Y from"../NewLineCheck/CoverageCheckModal.js";import{API_BASE_BASEPOINT as Z}from"../../services/api-constants.js";import{AppContext as ee}from"./StaticLineTableStore/StaticLineTableProvider.js";import oe from"./OttServiceOptions/OttServiceOptionsSmallPopup.js";import le from"./StaticExclusiveBenefit.js";import te from"../UserLoggedPricesToggle/UserLoggedPricesToggle.js";import ne from"../FalconButtonV2/FalconButtonV2.js";import{ONE_ECOMMERCE_INTERNET_SUMMARY as ie}from"../../utils/constants.js";import de from"./StaticLineTabelTimer/StaticLineTabelTimer.js";import{BadgeContainer as ae}from"@sunrise-upc/sales-static-components";const re=({content:re,offeringData:se,uniqueId:ce,storyContent:ve,metadata:ue,tabIndex:me,cardsLength:pe,indexKey:ge,constants:fe,mainContent:he,address:be,eligibleBundle:Ee,linecheckSuccessCallBack:we,selectedOption:Ce,fetchOfferData:Pe,basicConfigUrl:Se,selectedExistingOption:ye,setLoginSuccess:ke,enableP2P:Te,lineCheckCallBack:xe,loginSuccess:$e,setToggleState:De,toggleState:Le,noTabs:Ne,deviceFlow:Ie,deviceFlowCallBack:Be,selectedRP:Oe,continueCart:je,lineCheckOnClear:Ae,pegaIntegration:Ue,isProdEnv:Ve,deviceUltimateBundle:Fe,toggleContent:Me,pricesToggleState:Re,isShogunFlow:Ge,shogunToken:_e})=>{var Je,qe,We,He,ze,Ke,Qe,Xe,Ye,Ze,eo,oo,lo,to,no,io,ao,ro,so,co,vo,uo,mo,po,go,fo,ho,bo,Eo,wo,Co,Po,So,yo,ko,To,xo,$o,Do,Lo,No,Io,Bo,Oo,jo,Ao,Uo,Vo,Fo,Mo,Ro,Go,_o,Jo,qo,Wo,Ho,zo,Ko,Qo,Xo,Yo,Zo,el,ol,ll,tl,nl,il,dl,al,rl,sl,cl,vl,ul,ml,pl,gl,fl,hl,bl,El,wl,Cl,Pl;const[Sl,yl]=l(!1),[kl,Tl]=l(!1),[xl,$l]=l({showGift:!1,cashbackAvailable:!1}),[Dl,Ll]=l(!0),[Nl,Il]=l(!1),[Bl,Ol]=l([]),[jl,Al]=l(!1),[Ul,Vl]=l(!1),[Fl,Ml]=l(!1),[Rl,Gl]=l(!1),[_l,Jl]=l(!1),[ql,Wl]=l(!1),Hl=`${Se}inf/customer-management/subscriptions`,zl=`${Se}inf/resource-management/msisdns/pretopost/validation`,[Kl,Ql]=l([]),[Xl,Yl]=l(!1),[Zl,et]=l(!1),[ot,lt]=l(!1),[tt,nt]=l([]),[it,dt]=l(!1),[at,rt]=l(!1),[st,ct]=l(!1),[vt,ut]=l(!1),[mt,pt]=l([]),[gt,ft]=l(0),ht=t(null),bt=`${Se}inf/${Z.CUSTOMER}`,Et=void 0!==typeof window&&document.getElementById("static-linetable"),wt=0===(null===(Je=Object.keys(re))||void 0===Je?void 0:Je.length),Ct=null===(Ke=null===(ze=null===(He=null===(We=null===(qe=null==re?void 0:re.products)||void 0===qe?void 0:qe[0])||void 0===We?void 0:We.reference)||void 0===He?void 0:He.content)||void 0===ze?void 0:ze.product)||void 0===Ke?void 0:Ke[0],Pt=null===(eo=null===(Ze=null===(Ye=null===(Xe=null===(Qe=null==re?void 0:re.promotion)||void 0===Qe?void 0:Qe[0])||void 0===Xe?void 0:Xe.reference)||void 0===Ye?void 0:Ye.content)||void 0===Ze?void 0:Ze.promoDescription)||void 0===eo?void 0:eo[0],St=null===(oo=null==re?void 0:re.timer)||void 0===oo?void 0:oo[0],yt=null==St?void 0:St.enableCounter,[kt,Tt]=l(!!(yt&&(null==St?void 0:St.startTime)&&(null==St?void 0:St.endTime))&&C(St.startTime,St.endTime)),xt=Boolean((null==re?void 0:re.highlightText)&&!0!==Re&&!kt&&!(null==re?void 0:re.badgesContainer)),$t=Boolean((null==Pt?void 0:Pt.displayText)&&!(null==re?void 0:re.notShowPromotionLabel)&&!0!==Re&&!kt),Dt=Boolean((null==re?void 0:re.badgesContainer)&&!0!==Re&&!kt&&!$t),Lt=null==Ct?void 0:Ct.productId,Nt=null===(lo=null==f?void 0:f.getInstance())||void 0===lo?void 0:lo.getCartUrl(),It=null===(to=null==h?void 0:h.getInstance())||void 0===to?void 0:to.getAssetPath(),Bt="MOBILE"===(null==ve?void 0:ve.pageType),Ot=I(),jt=n(ee);let At;At=be&&(null===(no=null==Ee?void 0:Ee.eligibleBundle)||void 0===no?void 0:no.includes(Lt));const Ut=null==re?void 0:re.enableTVStreamingOptionsPopUp,Vt=null==re?void 0:re.enableTVStreamingOptionsStepper,Ft=null==re?void 0:re.disableDiscountedPriceToggle,Mt=null==re?void 0:re.skipAccessoriesPage;E.create({baseURL:null!=Se?Se:""});let Rt=void 0!==typeof window&&b.get("sunriseAuth");Rt=Rt&&JSON.parse(Rt);const Gt=((null==se?void 0:se[ce])||[]).filter(e=>(null==e?void 0:e.id)===Lt),_t=e=>{nt(e)},Jt=()=>{Al(!0),Gl(!Rl),et(!Zl)},qt=()=>{var e,o,l;if(Tl(!1),Te&&null==Rt)Gl(!Rl),et(!Zl);else if(Te&&(null==Rt?void 0:Rt.siteId))Xt();else if(Ce===F&&(null==ye?void 0:ye.length)>0)Jl(!0);else{!!((null==he?void 0:he.enableExistingCustomer)&&null==Rt||!Rt&&!0===Re&&(null==Me?void 0:Me.enableLoggedInPrice))?Al(!0):nn()}if(Ue){const t=localStorage.getItem("prospectId"),n=null!==(l=null===(o=null===(e=null===window||void 0===window?void 0:window.location)||void 0===e?void 0:e.pathname)||void 0===o?void 0:o.split("/"))&&void 0!==l?l:[],i=n[n.length-1],d={eventTimestamp:O(),eventType:"PageView",pageType:"CartCreated",pageLocation:i,targetProduct:Lt};t&&z(bt,d,t)}},Wt=e=>{const o=Bl.findIndex(o=>(null==e?void 0:e.giftGroupId)===(null==o?void 0:o.giftGroupId)),l=Bl;-1===o?l.push(e):l[o]=e,Ol([...l])},Ht=new URLSearchParams(null===(io=null===window||void 0===window?void 0:window.location)||void 0===io?void 0:io.search),zt=null==Ht?void 0:Ht.get("selectedMsisdn"),Kt=e=>{var o;1===(null==e?void 0:e.length)?(Nl?D(dn,ve,Gt,null==e?void 0:e[0],re,Ue):nn(null===(o=null==e?void 0:e[0])||void 0===o?void 0:o.msisdn),Wl(!1)):(null==e?void 0:e.length)>1?(Ql(e),lt(!ot),Wl(!1)):(et(!Zl),Wl(!0),Ll(!0),yl(!1))},Qt=(o,l)=>e(void 0,void 0,void 0,function*(){yield K(null==o?void 0:o.msisdn,zl).then(e=>{e&&l.push(o)}).catch(e=>{console.log("error",e)})}),Xt=()=>{var o;yl(!0);try{null===(o=H("PREPAID",Hl))||void 0===o||o.then(o=>e(void 0,void 0,void 0,function*(){if(204==(null==o?void 0:o.subscriptionData))et(!Zl),Wl(!0),Ll(!0),yl(!1);else{const l=null==o?void 0:o.subscriptionData,t=l.find(e=>e.msisdn===zt);if(l){const o=[];zt?(yield Qt(t,o),Kt(o)):yield Promise.all(null==l?void 0:l.map(l=>e(void 0,void 0,void 0,function*(){yield Qt(l,o)}))).then(e=>{Kt(o)})}}})).catch(e=>{console.log("error---\x3e",e),yl(!1)})}catch(e){console.log("error---\x3e",e),yl(!1)}Yl(!0)},Yt=()=>{et(!Dl),Gl(!1)},Zt=e=>{dt(!1),e&&A(V,U,{headline:"VAS POPUP CLOSE"})},en=()=>{let e="undefined"!=typeof window&&localStorage.getItem("lineCheckResponse");Ee=e&&(null===JSON||void 0===JSON?void 0:JSON.parse(e)),be="undefined"!=typeof window&&b.get("chAddressJson"),Ml(!Fl),"function"==typeof we&&we(),nn()},on=P(null==Ct?void 0:Ct.bloks,Bt),ln=null===(ao=null==on?void 0:on[0])||void 0===ao?void 0:ao.tvProductId,tn=e=>{var o,l,t,n,i,d,a,r,s,c;const v=Ue&&(null===(t=null===(l=null===(o=null==Gt?void 0:Gt[0])||void 0===o?void 0:o.promotionInfo)||void 0===l?void 0:l[0])||void 0===t?void 0:t.id),u=Ue&&(null===(d=null===(i=null===(n=null==Gt?void 0:Gt[0])||void 0===n?void 0:n.promotionInfo)||void 0===i?void 0:i[0])||void 0===d?void 0:d.version),m=Ge?{pointsBurnt:null===(r=null===(a=null==Gt?void 0:Gt[0])||void 0===a?void 0:a.rewards)||void 0===r?void 0:r.points,rewardOfferId:null===(c=null===(s=null==Gt?void 0:Gt[0])||void 0===s?void 0:s.rewards)||void 0===c?void 0:c.offerId,gloxTokenId:_e}:void 0;Gt&&Gt[0]&&(Gt[0].fromPopup=vt),sn("false"),sessionStorage.removeItem("vasPopUp"),rt(!1),x(yl,Nt,Bl,Gt,he,dn,Bt,ln,Ee,be,Ml,Fl,xe,Te,null!=zt?zt:e,re,tt,v,u,m)},nn=e=>{var o,l,t,n,i,d,a,r,s;ut(!1),Tl(!1);let c=void 0!==typeof window&&b.get("sunriseAuth");const v=c&&JSON.parse(c),u=!(!(null==he?void 0:he.enableExistingCustomer)||null!=v);if(sessionStorage.removeItem(ie),(null===(o=null==he?void 0:he.linecheckData)||void 0===o?void 0:o.length)>0&&!Bt&&!At){return void(document.getElementById("linecheck")&&xe())}if(At&&!Bt&&(null===(l=null==he?void 0:he.loginData)||void 0===l?void 0:l.length)>0&&u)Al(!0);else if(Vt&&(null===(t=Gt[0])||void 0===t?void 0:t.isBundle)){let o=!1;Mt||((null===(n=Gt[0])||void 0===n?void 0:n.isBundle)?null===(d=null===(i=Gt[0])||void 0===i?void 0:i.bundledOffers)||void 0===d||d.map(e=>{var l,t,n;"internet"!==(null===(l=null==e?void 0:e.productType)||void 0===l?void 0:l.toLowerCase())&&"tv"!=(null===(t=null==e?void 0:e.productType)||void 0===t?void 0:t.toLowerCase())||(null==e?void 0:e.recommendAccessory)&&(o=null==e?void 0:e.recommendAccessory),"mobile"!==(null===(n=null==e?void 0:e.productType)||void 0===n?void 0:n.toLowerCase())||(o=!1)}):(null===(a=null==Gt?void 0:Gt[0])||void 0===a?void 0:a.recommendAccessory)&&(o=null===(r=null==Gt?void 0:Gt[0])||void 0===r?void 0:r.recommendAccessory)),$(dn,Gt,re,Ue,null==Ct?void 0:Ct.productName,o),tn(e)}else Ut&&(null===(s=Gt[0])||void 0===s?void 0:s.isBundle)&&!at?(dt(!0),rt(!0),sn("true"),window.addEventListener("beforeunload",function(e){sn("false"),sessionStorage.removeItem("vasPopUp"),rt(!1)})):(Te&&yl(!0),tn(e))},dn=S(Gt,Bt,null==he?void 0:he.pageType,!1,tt,Ue);i(()=>{var e,o;setTimeout(()=>{y(me,pe)},100);const l=k(Bt?Gt:null!==(o=null===(e=null==Gt?void 0:Gt[0])||void 0===e?void 0:e.bundledOffers)&&void 0!==o?o:Gt);$l(Object.assign({},l))},[se,Le,tt,gt,((null==Le?void 0:Le.TV)||(null==Le?void 0:Le.gigaSpeed)||(null==Le?void 0:Le.Netflix))&&Array.isArray(Gt)&&3===(null===(so=null===(ro=null==Gt?void 0:Gt[0])||void 0===ro?void 0:ro.bundledOffers)||void 0===so?void 0:so.length)]);const an=()=>{((null==on?void 0:on.length)>0||Ut)&&Vl(!0)},rn=null===(co=null==he?void 0:he.productContainer)||void 0===co?void 0:co[0];i(()=>{Nl&&(Te&&null==Rt?(Gl(!Rl),et(!Zl)):Te&&(null==Rt?void 0:Rt.siteId)&&Xt())},[Nl]),i(()=>{var e;if(jt){const{store:o}=jt;(null===(e=null==o?void 0:o.ottOptionsApi)||void 0===e?void 0:e.length)>0&&0===(null==mt?void 0:mt.length)&&pt(null==o?void 0:o.ottOptionsApi)}},[jt]),i(()=>{if(!yt||!(null==St?void 0:St.startTime)||!(null==St?void 0:St.endTime))return void Tt(!1);Tt(C(St.startTime,St.endTime));const e=T(St.startTime,St.endTime);if(e<=0)return;const o=setTimeout(()=>{Tt(C(St.startTime,St.endTime))},e);return()=>clearTimeout(o)},[yt,null==St?void 0:St.startTime,null==St?void 0:St.endTime]),i(()=>{var e;const o=ht.current;if(!o||!(null===(e=null==re?void 0:re.timer)||void 0===e?void 0:e.length)||!yt)return void ft(0);const l=()=>{ft(o.clientHeight)};if(l(),"undefined"==typeof ResizeObserver)return;const t=new ResizeObserver(l);return t.observe(o),()=>{t.disconnect()}},[null===(vo=null==re?void 0:re.timer)||void 0===vo?void 0:vo.length,yt]),i(()=>{st&&(Zt(),ct(!0),sn("false"),sessionStorage.removeItem("vasPopUp"),rt(!1),tn())},[st]),i(()=>{const e=()=>{const e=sessionStorage.getItem("vasPopUp");rt("true"===e)};e();const o=o=>{o.storageArea===sessionStorage&&"vasPopUp"===o.key&&e(),o.storageArea===sessionStorage&&"vasPopUp"===o.key&&null===o.newValue&&rt(!1)},l=()=>{e()};return window.addEventListener("storage",o),window.addEventListener("vasPopUpChange",l),()=>{window.removeEventListener("storage",o),window.removeEventListener("vasPopUpChange",l)}},[]);const sn=e=>{sessionStorage.setItem("vasPopUp",e);const o=new Event("vasPopUpChange");window.dispatchEvent(o)};return o.createElement("div",null,Sl&&Et&&a(o.createElement(d,{keyParams:"loading"}),Et),wt&&o.createElement("div",{className:"w-75 pb-2"},o.createElement(r,null)),!wt&&Ee&&re&&be&&!Bt&&o.createElement("div",{className:s.selected},o.createElement("span",{style:{paddingBottom:"10px"}},At?o.createElement("span",{className:s.activeicon},o.createElement("img",{src:`${It}/icons/lineCheck-success.svg`,alt:"",width:24,height:24,className:s.activeicon}),o.createElement("span",null,null==fe?void 0:fe.subscriptionAvalTxt)):o.createElement("span",{className:s.inactiveicon},o.createElement("img",{src:`${It}/icons/cross_disabled.svg`,alt:"",width:24,height:24,className:s.inactiveicon}),o.createElement("span",null,null==fe?void 0:fe.notSubscriptionTxt)))),o.createElement("div",{className:`${!Bt&&!1===At&&(null===(uo=null==he?void 0:he.linecheckData)||void 0===uo?void 0:uo.length)>0&&"global/coverage-check"!==(null===(go=null===(po=null===(mo=null==he?void 0:he.linecheckData)||void 0===mo?void 0:mo[0])||void 0===po?void 0:po.reference)||void 0===go?void 0:go.default_full_slug)?s.overlay:""}\n ${Fe&&!(null===(ho=null===(fo=null==Gt?void 0:Gt[0])||void 0===fo?void 0:fo.eligibility)||void 0===ho?void 0:ho.fpb)?s.disabled:""}\n `,style:{flexDirection:"column"}},o.createElement("div",{className:s.bundleproductcard},o.createElement("div",{id:`timer-section${me}${ge}`,"data-timer-active":gt>0?"true":"false"},(null===(bo=null==re?void 0:re.timer)||void 0===bo?void 0:bo.length)&&yt?o.createElement("div",{style:{height:`${gt}px`,transition:"height 0.3s ease"}}):null),o.createElement("div",{className:`${s.productcontainer}`,style:(()=>{const e=$t?Pt:re,o=null==e?void 0:e.showBorder,l=null==e?void 0:e.borderGradient,t=null==e?void 0:e.borderColor;return{borderColor:o&&!l?t||"":"transparent",borderWidth:o?"4px":"0px",borderStyle:o?"solid":"none",borderRadius:o?"8px":"",background:o&&l?`linear-gradient(white, white) padding-box, ${l} border-box`:void 0}})()},Dt&&o.createElement(ae,{badges:re.badgesContainer}),xt&&o.createElement("div",{className:`${s.highlightText}`},null==re?void 0:re.highlightText),$t&&((null==Pt?void 0:Pt.badgeContainer)?o.createElement(ae,{badges:null==Pt?void 0:Pt.badgeContainer}):o.createElement("div",{className:`${s.promocontainer}`,style:{background:null==Pt?void 0:Pt.bestSellerColor}},null==Pt?void 0:Pt.displayText)),o.createElement("div",{ref:ht,className:s.timerContainer},(null===(Eo=null==re?void 0:re.timer)||void 0===Eo?void 0:Eo.length)&&yt?o.createElement(de,{content:null===(wo=null==re?void 0:re.timer)||void 0===wo?void 0:wo[0],hasHighlightText:Dt||$t,onTimerChange:e=>{Tt(e)}}):null),o.createElement("div",{className:`${s.detailsection} ${s.imageFullWidthSection}`,id:`detailsectionv3${me}${ge}`},o.createElement("div",{className:`${s.headersection}`},o.createElement("div",{className:`${s.titlesection}`},o.createElement("div",{className:`${s.productheader}`,id:`titleV3${me}${ge}`},null==Ct?void 0:Ct.productName),o.createElement("div",null,(null===(Co=null==Ct?void 0:Ct.icon)||void 0===Co?void 0:Co.filename)&&o.createElement("img",{className:`${s.imagecontainer}`,src:null===(Po=null==Ct?void 0:Ct.icon)||void 0===Po?void 0:Po.filename,height:15,width:20,alt:"productIcon"}))),o.createElement("div",{className:`${s.productdescription}`,id:`descriptionV3${me}${ge}`},o.createElement(c,{content:null==Ct?void 0:Ct.description})),o.createElement("div",{className:`${s.images}`},(null===(So=null==Ct?void 0:Ct.img)||void 0===So?void 0:So.filename)&&o.createElement("img",{className:`${s.imagespace} ${(null==re?void 0:re.highlightText)&&s.borderimage}`,alt:"cardimg",src:`${null===(yo=null==Ct?void 0:Ct.img)||void 0===yo?void 0:yo.filename}/m/`}))),o.createElement("div",{className:`${s.productconfig}`,id:`product-configv3${me}${ge}`},wt?o.createElement(o.Fragment,null,o.createElement("div",{className:s.space}),o.createElement(r,{stylename:s.skeletontittle,count:1}),o.createElement(r,{stylename:s.skeletonline,count:5}),o.createElement("div",{className:s.space}),o.createElement(r,{stylename:s.skeletontittle,count:1}),o.createElement(r,{stylename:s.skeletonline,count:5})):o.createElement("div",null,(null==Ct?void 0:Ct.bloks)&&(null===(ko=null==Ct?void 0:Ct.bloks)||void 0===ko?void 0:ko.map((e,l)=>o.createElement(v,{content:e,indexKey:l,constants:fe,key:l,showModalPopup:an,setToggleState:De,toggleState:Le,noTabs:Ne,mainContent:he,enableTVStreamingOptions:null==re?void 0:re.enableTVStreamingOptions,metadata:ue,setTvOptionsData:_t})))))),o.createElement("div",{className:`${s.detailsection}`,id:`benefits-price-section${me}${ge}`},o.createElement("div",{id:`exclusive-benefits-section${me}${ge}`},(null===(To=null==Ct?void 0:Ct.extraBenefits)||void 0===To?void 0:To.length)>0&&o.createElement(le,{content:null===(xo=null==Ct?void 0:Ct.extraBenefits)||void 0===xo?void 0:xo[0]})),o.createElement("div",{className:`${s.benefitssection}`,id:`benefits-section${me}${ge}`},(null===($o=null==Ct?void 0:Ct.benefits)||void 0===$o?void 0:$o.length)>0&&o.createElement(u,{content:null==Ct?void 0:Ct.benefits,benefitData:dn,constants:fe,pricesToggleState:Re,togglePriceLabel:null==Me?void 0:Me.togglePriceLabel})),o.createElement("br",null),o.createElement("div",{className:`${s.giftsection}`,id:`gift-section${me}${ge}`},(null==xl?void 0:xl.showGift)&&(null===(Do=null==Pt?void 0:Pt.singleGift)||void 0===Do?void 0:Do.map((e,l)=>o.createElement(L,{content:e,key:l}))),(null==xl?void 0:xl.showGift)&&(null===(Lo=null==Pt?void 0:Pt.giftConfig)||void 0===Lo?void 0:Lo.map((e,l)=>o.createElement(N,{content:e,key:l,selectedGiftItem:Wt,parentPoType:Bt?"MOBILE":"HOME"}))),o.createElement("div",{className:`${s.giftsection}`,id:`cashback-section${me}${ge}`},o.createElement(j,{uniqueProductData:Gt,mainContent:he}))),o.createElement("div",{className:`${s.ordersection}`,id:`order-section${me}${ge}`},""===(null==dn?void 0:dn.base)?o.createElement("div",null,o.createElement(r,{stylename:s.skeletontittle})):o.createElement("div",{id:`price-section${me}${ge}`},o.createElement(m,{priceCollection:dn,constants:fe,promoText:null==Ct?void 0:Ct.promoText,deviceFlow:Ie,content:re,offeringData:se,uniqueId:ce})),!Ge&&o.createElement("div",{className:`${s.discountedpricetoggleSection}`,id:`discountedpricetoggle-section${me}${ge}`},Ft||"INLINE"!==(null==Me?void 0:Me.togglePosition)?null:o.createElement(te,{content:Ct,index:ge,lineTable:!0,toggleContent:Me})),Te&&(null==fe?void 0:fe.P2PDiscountLabel)&&o.createElement("div",{className:s.longterm},null==fe?void 0:fe.P2PDiscountLabel),wt?o.createElement(o.Fragment,null,o.createElement(r,{stylename:s.skeletontittle,count:1}),o.createElement(r,{stylename:s.skeletonline,count:2})):o.createElement("div",{className:`${(null==ve?void 0:ve.swapButton)&&s.swapButton}`},o.createElement("div",{style:{padding:"16px 0 0 0"}},o.createElement(p,{isMobileFlow:Bt,createCartCall:(null==Ie?void 0:Ie.isDeviceFlow)?e=>{Tl(!1);Be({setShowLoader:yl,cartEndPoint:Nt,giftItem:Bl,uniqueProductData:Gt,mainContent:he,showPrice:dn,isMobileFlow:Bt,eligibleBundle:Ee,address:be,setShowLinecheck:Ml,showLinecheck:Fl,lineCheckCallBack:xe,enableP2P:Te,msisdnn:null!=zt?zt:e,content:re,selectedRP:Oe,continueCart:je})}:Bt?qt:nn,constants:fe,storyContent:ve,showPrice:dn,isAvailable:At,address:be,uniqueProductBenefits:null==Gt?void 0:Gt[0],alwaysActive:!At&&(null===(No=null==he?void 0:he.linecheckData)||void 0===No?void 0:No.length)>0&&"global/coverage-check"===(null===(Oo=null===(Bo=null===(Io=null==he?void 0:he.linecheckData)||void 0===Io?void 0:Io[0])||void 0===Bo?void 0:Bo.reference)||void 0===Oo?void 0:Oo.default_full_slug),flexUpgradeFreePopup:null===(Ao=null===(jo=null==he?void 0:he.flexUpgradeFreePopup)||void 0===jo?void 0:jo.reference)||void 0===Ao?void 0:Ao.content,content:re,deviceUltimateBundle:Fe,forceDisabled:Boolean(null===(Vo=null===(Uo=null==Gt?void 0:Gt[0])||void 0===Uo?void 0:Uo.rewards)||void 0===Vo?void 0:Vo.notEligibleReason),notEligibileReason:null===(Mo=null===(Fo=null==Gt?void 0:Gt[0])||void 0===Fo?void 0:Fo.rewards)||void 0===Mo?void 0:Mo.notEligibleReason})),!Ge&&(null===(Ro=null==ve?void 0:ve.addSmartPhone)||void 0===Ro?void 0:Ro.length)>0&&!(null==Ie?void 0:Ie.isDeviceFlow)&&o.createElement("div",{style:{textAlign:"center"}},(null==ve?void 0:ve.swapButton)?(null==ve?void 0:ve.ctaLabel)&&o.createElement("div",{style:{padding:"16px 0"}},o.createElement("button",{className:"primarybutton",onClick:()=>D(dn,ve,Gt,"",re,Ue)},o.createElement("span",{className:s.buttontext},null==ve?void 0:ve.ctaLabel))):!(null==re?void 0:re.redirectOnly)&&o.createElement("div",{style:{padding:"12px 0 0 0"}},o.createElement(ne,{content:{buttonType:"Secondary-V1",buttonLabel:(null==re?void 0:re.ultimateBundlePromotion)?null==fe?void 0:fe.ultimateBundleLbl:null===(_o=null===(Go=null==ve?void 0:ve.addSmartPhone)||void 0===Go?void 0:Go[0])||void 0===_o?void 0:_o.buttonLabel,buttonIcon:null===(qo=null===(Jo=null==ve?void 0:ve.addSmartPhone)||void 0===Jo?void 0:Jo[0])||void 0===qo?void 0:qo.buttonIcon,buttonAlignment:"left"},wafIdentifier:Se,style:{width:"100%"},onClick:()=>Te?void Il(!0):D(dn,ve,Gt,"",re,Ue)}))),o.createElement("div",{className:s.productcontractduration,id:`contract-section${me}${ge}`,style:{paddingTop:(null===(Wo=null==ve?void 0:ve.addSmartPhone)||void 0===Wo?void 0:Wo.length)>0&&!(null==Ie?void 0:Ie.isDeviceFlow)&&!(null==ve?void 0:ve.swapButton)&&!(null==re?void 0:re.redirectOnly)?"8px":void 0}},(null==dn?void 0:dn.contractDuration)>"1"?B(null===(Ho=null==fe?void 0:fe.minContractDuration)||void 0===Ho?void 0:Ho.substring(1),[null==dn?void 0:dn.contractDuration]):null==fe?void 0:fe.noContractDuration)),o.createElement("div",{style:{textAlign:"center",padding:"4px"}},(null===(zo=null==Ct?void 0:Ct.productDetails)||void 0===zo?void 0:zo.length)>0&&o.createElement("span",{className:s.productdetailslink,onClick:()=>{var e,o,l;Tl(!kl),A(V,R,X(Gt,"",M));const t=localStorage.getItem("prospectId"),n=null!==(l=null===(o=null===(e=null===window||void 0===window?void 0:window.location)||void 0===e?void 0:e.pathname)||void 0===o?void 0:o.split("/"))&&void 0!==l?l:[],i=n[n.length-1],d={eventTimestamp:O(),eventType:"PageView",pageType:"ProductDetails",pageLocation:i,targetProduct:Lt};t&&z(bt,d,t)}},null==fe?void 0:fe.productDetailsLink)),kl&&o.createElement(g,{content:null==Ct?void 0:Ct.productDetails,showProductDetail:kl,setShowProductDetail:Tl,constants:fe,showPrice:dn,isMobileFlow:Bt,createCartCall:Bt?qt:nn,storyContent:ve,isAvailable:At,address:be,flexUpgradeFreePopup:null===(Qo=null===(Ko=null==he?void 0:he.flexUpgradeFreePopup)||void 0===Ko?void 0:Ko.reference)||void 0===Qo?void 0:Qo.content,notEligibileReason:null===(Yo=null===(Xo=null==Gt?void 0:Gt[0])||void 0===Xo?void 0:Xo.rewards)||void 0===Yo?void 0:Yo.notEligibleReason})))))),Fe&&Gt&&!(null===(el=null===(Zo=null==Gt?void 0:Gt[0])||void 0===Zo?void 0:Zo.eligibility)||void 0===el?void 0:el.fpb)&&o.createElement("div",{className:s.disabledInfo},o.createElement(c,{content:null==fe?void 0:fe.fpbNotCompatibleText})),Ul&&(wt?o.createElement(r,null):o.createElement(G,{content:null==on?void 0:on[0],setShowModal:Vl,showModal:Ul,constants:fe})),jl&&(null===(ol=null==he?void 0:he.loginData)||void 0===ol?void 0:ol.length)>0&&Et&&a(o.createElement(w,{content:null===(ll=null==he?void 0:he.loginData)||void 0===ll?void 0:ll[0],closeLogin:()=>{Al(!1)},metadata:ue,onSuccess:()=>{Al(!1),ke(),sessionStorage.removeItem("vasPopUp"),rt(!1),Te?Xt():nn()},isProdEnv:Ve}),Et),Rl&&Te&&!jl&&Zl&&o.createElement(W,{modalState:Dl,handler:Yt,showFooter:!1,width:"628px",height:"280px",backgroundColor:"#f7f6f5",noCloseButton:!1,backDrop:!0,bodyPadding:"16px"},o.createElement(q,{onClose:Jt,content:null===(il=null===(nl=null===(tl=null==he?void 0:he.productContainer)||void 0===tl?void 0:tl[0])||void 0===nl?void 0:nl.p2pBloks)||void 0===il?void 0:il[0],prepaid:!1})),Te&&Xl&&ql&&Zl&&o.createElement(W,{modalState:Dl,handler:Yt,showFooter:!1,width:"628px",height:"280px",backgroundColor:"#f7f6f5",noCloseButton:!1,backDrop:!0,bodyPadding:"16px",id:"table-product"},o.createElement(q,{onClose:Jt,content:null===(rl=null===(al=null===(dl=null==he?void 0:he.productContainer)||void 0===dl?void 0:dl[0])||void 0===al?void 0:al.p2pBloks)||void 0===rl?void 0:rl[1],prepaid:!0})),(null==Kl?void 0:Kl.length)>1&&Te&&Xl&&!ql&&ot&&o.createElement(W,{modalState:ot,handler:()=>{yl(!1),lt(!ot)},showFooter:!1,width:"628px",height:"280px",backgroundColor:"#f7f6f5",noCloseButton:!1,backDrop:!0,bodyPadding:"16px"},o.createElement(Q,{onSubmit:e=>{lt(!ot),Nl?D(dn,ve,Gt,e,re,Ue):nn(null==e?void 0:e.msisdn)},exsistingSubscriptionData:Kl,updatedContent:rn})),Fl&&(null==he?void 0:he.enableLinecheckOverlay)&&!Bt&&(null===(sl=null==he?void 0:he.linecheckData)||void 0===sl?void 0:sl.length)>0&&!Te&&"global/new-linecheck-test"===(null===(ul=null===(vl=null===(cl=null==he?void 0:he.linecheckData)||void 0===cl?void 0:cl[0])||void 0===vl?void 0:vl.reference)||void 0===ul?void 0:ul.default_full_slug)?o.createElement(_,{content:null===(ml=null==he?void 0:he.linecheckData)||void 0===ml?void 0:ml[0],onSuccess:en,showModal:Fl,setShowModal:Ml,productName:null==Ct?void 0:Ct.productName,productId:null==Ct?void 0:Ct.productId}):Fl&&(null==he?void 0:he.enableLinecheckOverlay)&&!Bt&&(null===(pl=null==he?void 0:he.linecheckData)||void 0===pl?void 0:pl.length)>0&&!Te&&"global/coverage-check"===(null===(hl=null===(fl=null===(gl=null==he?void 0:he.linecheckData)||void 0===gl?void 0:gl[0])||void 0===fl?void 0:fl.reference)||void 0===hl?void 0:hl.default_full_slug)?o.createElement(Y,{content:null===(bl=null==he?void 0:he.linecheckData)||void 0===bl?void 0:bl[0].reference.content.body[0],overlayIsOpen:!0,externalHandleModal:Ml,productName:null==Ct?void 0:Ct.productName,showModal:Fl,setShowModal:Ml,onSuccess:()=>{let e="undefined"!=typeof window&&localStorage.getItem("lineCheckResponse");Ee=e&&(null===JSON||void 0===JSON?void 0:JSON.parse(e)),be="undefined"!=typeof window&&b.get("chAddressJson"),"function"==typeof we&&we()},onCreateCart:en,lineCheckOnClear:Ae,productId:null==Ct?void 0:Ct.productId}):null,_l&&Bt&&(null===(El=null==ve?void 0:ve.benefitsValidate)||void 0===El?void 0:El.length)>0&&o.createElement(J,{content:null===(wl=null==ve?void 0:ve.benefitsValidate)||void 0===wl?void 0:wl[0],loginContent:null===(Cl=null==he?void 0:he.loginData)||void 0===Cl?void 0:Cl[0],metadata:ue,createCartCall:nn,fetchOfferData:Pe,basicConfigUrl:Se,selectedExistingOption:ye,setShowBenefit:Jl,setLoginSuccess:ke,isProdEnv:Ve}),it&&o.createElement(W,{modalState:it,handler:Zt,showFooter:!1,width:"mobile"===Ot?"":"tablet"===Ot?"700px":"990px",fixedWidth:"mobile"===Ot?"":"tablet"===Ot?"700px":"990px",height:"845px",backgroundColor:"#f7f6f5",noCloseButton:!1,backDrop:!0,bodyPadding:"24px"},o.createElement(oe,{content:null===(Pl=null==he?void 0:he.optionsPopup)||void 0===Pl?void 0:Pl[0],addOptionsCallBack:e=>{ut(!0),ct(!0),_t(e)},metadata:ue,constants:fe,mainContent:he,preSelectedOptions:[],optionsResponse:mt,updateResponseList:pt,showPrice:dn,productData:Ct,offeringData:se,uniqueId:ce,deviceFlow:Ie})))};export{re as default};
1
+ import{__awaiter as e}from"../../_virtual/_tslib.js";import o,{useState as l,useRef as n,useContext as t,useEffect as i}from"react";import d from"../Dotloader/Dotloader.js";import{createPortal as a}from"react-dom";import r from"../SkeletonLoader/SkeletonLoader.js";import s from"./StaticLineTable.module.scss.js";import c from"../richtext.js";import v from"./StaticProductEntitlement.js";import u from"./StaticBenefit.js";import m from"./DynamicPriceSection.js";import p from"./CheckoutButton.js";import g from"./StaticProductDetails.js";import{LineTableBasicPropConfig as f,AssetPathPropConfig as h}from"../../services/LineTableBasicPropConfig.js";import b from"js-cookie";import{LoginBasicPropConfig as E}from"../../services/LoginBasicPropConfig.js";import w from"../login/LoginModalV2.js";import{isTimerActive as C,fetchServiceOptions as P,fetchPrice as S,findHeight as y,checkGiftOrCashback as k,getTimeUntilNextTimerEvent as T,staticCreateCart as x,combineWithVasOptions as $,combineWithSmartPhone as D}from"./Product.utils.js";import I from"../ProductDetailsV3/GiftConfigV2.js";import L from"../ProductDetailsV3/ChooseGiftV2.js";import{viewport as N,replacePlaceholder as B,getUtcTimestamp as O}from"../../utils/utils.js";import j from"./StaticProductCashback.js";import{trackNewDatalayerEvent as A}from"../../utils/AnalyticsUtils.js";import{CTABUTTONCLICK as U,GAEVENT as V,EXISTINGCUSTOMER as F,LINETABLE as M,DOWNLOADPRODUCT as R}from"../../Analytics/AnalyticsConstants.js";import G from"./TVChannelModal.js";import _ from"../LineCheckV3/LinecheckModal.js";import J from"../BenefitWrapper/BenefitsValidateWrapper.js";import W from"../PretoPost/PreToPostSubsPopup.js";import q from"../LineCheckV3/GenericModal.js";import{fetchSubscriptionData as H,trackPegaEvents as z,validateP2P as K}from"../../services/LineTableService.js";import Q from"./ExsistingSubscriptionModal.js";import{getEcomCartInfo as X}from"../../models/Analytics/items.js";import Y from"../NewLineCheck/CoverageCheckModal.js";import{API_BASE_BASEPOINT as Z}from"../../services/api-constants.js";import{AppContext as ee}from"./StaticLineTableStore/StaticLineTableProvider.js";import oe from"./OttServiceOptions/OttServiceOptionsSmallPopup.js";import le from"./StaticExclusiveBenefit.js";import ne from"../UserLoggedPricesToggle/UserLoggedPricesToggle.js";import te from"../FalconButtonV2/FalconButtonV2.js";import{ONE_ECOMMERCE_INTERNET_SUMMARY as ie}from"../../utils/constants.js";import de from"./StaticLineTabelTimer/StaticLineTabelTimer.js";import{BadgeContainer as ae}from"@sunrise-upc/sales-static-components";import re from"../GenericPopup/GenericPopup.js";const se=({content:se,offeringData:ce,uniqueId:ve,storyContent:ue,metadata:me,tabIndex:pe,cardsLength:ge,indexKey:fe,constants:he,mainContent:be,address:Ee,eligibleBundle:we,linecheckSuccessCallBack:Ce,selectedOption:Pe,fetchOfferData:Se,basicConfigUrl:ye,selectedExistingOption:ke,setLoginSuccess:Te,enableP2P:xe,lineCheckCallBack:$e,loginSuccess:De,setToggleState:Ie,toggleState:Le,noTabs:Ne,deviceFlow:Be,deviceFlowCallBack:Oe,selectedRP:je,continueCart:Ae,lineCheckOnClear:Ue,pegaIntegration:Ve,isProdEnv:Fe,deviceUltimateBundle:Me,toggleContent:Re,pricesToggleState:Ge,isShogunFlow:_e,shogunToken:Je})=>{var We,qe,He,ze,Ke,Qe,Xe,Ye,Ze,eo,oo,lo,no,to,io,ao,ro,so,co,vo,uo,mo,po,go,fo,ho,bo,Eo,wo,Co,Po,So,yo,ko,To,xo,$o,Do,Io,Lo,No,Bo,Oo,jo,Ao,Uo,Vo,Fo,Mo,Ro,Go,_o,Jo,Wo,qo,Ho,zo,Ko,Qo,Xo,Yo,Zo,el,ol,ll,nl,tl,il,dl,al,rl,sl,cl,vl,ul,ml,pl,gl,fl,hl,bl,El,wl,Cl,Pl,Sl;const[yl,kl]=l(!1),[Tl,xl]=l(!1),[$l,Dl]=l({showGift:!1,cashbackAvailable:!1}),[Il,Ll]=l(!0),[Nl,Bl]=l(!1),[Ol,jl]=l([]),[Al,Ul]=l(!1),[Vl,Fl]=l(!1),[Ml,Rl]=l(!1),[Gl,_l]=l(!1),[Jl,Wl]=l(!1),[ql,Hl]=l(!1),zl=`${ye}inf/customer-management/subscriptions`,Kl=`${ye}inf/resource-management/msisdns/pretopost/validation`,[Ql,Xl]=l([]),[Yl,Zl]=l(!1),[en,on]=l(!1),[ln,nn]=l(!1),[tn,dn]=l([]),[an,rn]=l(!1),[sn,cn]=l(!1),[vn,un]=l(!1),[mn,pn]=l(!1),[gn,fn]=l([]),[hn,bn]=l(0),[En,wn]=l(!1),Cn=n(null),[Pn,Sn]=l(null),yn=n(!1),kn=n(null),Tn=`${ye}inf/${Z.CUSTOMER}`,xn=void 0!==typeof window&&document.getElementById("static-linetable"),$n=0===(null===(We=Object.keys(se))||void 0===We?void 0:We.length),Dn=null===(Qe=null===(Ke=null===(ze=null===(He=null===(qe=null==se?void 0:se.products)||void 0===qe?void 0:qe[0])||void 0===He?void 0:He.reference)||void 0===ze?void 0:ze.content)||void 0===Ke?void 0:Ke.product)||void 0===Qe?void 0:Qe[0],In=null===(oo=null===(eo=null===(Ze=null===(Ye=null===(Xe=null==se?void 0:se.promotion)||void 0===Xe?void 0:Xe[0])||void 0===Ye?void 0:Ye.reference)||void 0===Ze?void 0:Ze.content)||void 0===eo?void 0:eo.promoDescription)||void 0===oo?void 0:oo[0],Ln=null===(lo=null==se?void 0:se.timer)||void 0===lo?void 0:lo[0],Nn=null==Ln?void 0:Ln.enableCounter,[Bn,On]=l(!!(Nn&&(null==Ln?void 0:Ln.startTime)&&(null==Ln?void 0:Ln.endTime))&&C(Ln.startTime,Ln.endTime)),jn=Boolean((null==se?void 0:se.highlightText)&&!0!==Ge&&!Bn&&!(null==se?void 0:se.badgesContainer)),An=Boolean((null==In?void 0:In.displayText)&&!(null==se?void 0:se.notShowPromotionLabel)&&!0!==Ge&&!Bn),Un=Boolean((null==se?void 0:se.badgesContainer)&&!0!==Ge&&!Bn&&!An),Vn=null==Dn?void 0:Dn.productId,Fn=null===(no=null==f?void 0:f.getInstance())||void 0===no?void 0:no.getCartUrl(),Mn=null===(to=null==h?void 0:h.getInstance())||void 0===to?void 0:to.getAssetPath(),Rn="MOBILE"===(null==ue?void 0:ue.pageType),Gn=N(),_n=t(ee);let Jn;Jn=Ee&&(null===(io=null==we?void 0:we.eligibleBundle)||void 0===io?void 0:io.includes(Vn));const Wn=null==se?void 0:se.enableTVStreamingOptionsPopUp,qn=null==se?void 0:se.enableTVStreamingOptionsStepper,Hn=null==se?void 0:se.disableDiscountedPriceToggle,zn=null==se?void 0:se.skipAccessoriesPage;E.create({baseURL:null!=ye?ye:""});let Kn=void 0!==typeof window&&b.get("sunriseAuth");Kn=Kn&&JSON.parse(Kn);const Qn=((null==ce?void 0:ce[ve])||[]).filter(e=>(null==e?void 0:e.id)===Vn),Xn=e=>{dn(e)},Yn=()=>{Ul(!0),_l(!Gl),on(!en)},Zn=()=>{var e,o,l;if(xl(!1),xe&&null==Kn)_l(!Gl),on(!en);else if(xe&&(null==Kn?void 0:Kn.siteId))it();else if(Pe===F&&(null==ke?void 0:ke.length)>0)Wl(!0);else{!!((null==be?void 0:be.enableExistingCustomer)&&null==Kn||!Kn&&!0===Ge&&(null==Re?void 0:Re.enableLoggedInPrice))?Ul(!0):ut()}if(Ve){const n=localStorage.getItem("prospectId"),t=null!==(l=null===(o=null===(e=null===window||void 0===window?void 0:window.location)||void 0===e?void 0:e.pathname)||void 0===o?void 0:o.split("/"))&&void 0!==l?l:[],i=t[t.length-1],d={eventTimestamp:O(),eventType:"PageView",pageType:"CartCreated",pageLocation:i,targetProduct:Vn};n&&z(Tn,d,n)}},et=e=>{const o=Ol.findIndex(o=>(null==e?void 0:e.giftGroupId)===(null==o?void 0:o.giftGroupId)),l=Ol;-1===o?l.push(e):l[o]=e,jl([...l])},ot=new URLSearchParams(null===(ao=null===window||void 0===window?void 0:window.location)||void 0===ao?void 0:ao.search),lt=null==ot?void 0:ot.get("selectedMsisdn"),nt=e=>{var o;1===(null==e?void 0:e.length)?(Nl?D(pt,ue,Qn,null==e?void 0:e[0],se,Ve):ut(null===(o=null==e?void 0:e[0])||void 0===o?void 0:o.msisdn),Hl(!1)):(null==e?void 0:e.length)>1?(Xl(e),nn(!ln),Hl(!1)):(on(!en),Hl(!0),Ll(!0),kl(!1))},tt=(o,l)=>e(void 0,void 0,void 0,function*(){yield K(null==o?void 0:o.msisdn,Kl).then(e=>{e&&l.push(o)}).catch(e=>{console.log("error",e)})}),it=()=>{var o;kl(!0);try{null===(o=H("PREPAID",zl))||void 0===o||o.then(o=>e(void 0,void 0,void 0,function*(){if(204==(null==o?void 0:o.subscriptionData))on(!en),Hl(!0),Ll(!0),kl(!1);else{const l=null==o?void 0:o.subscriptionData,n=l.find(e=>e.msisdn===lt);if(l){const o=[];lt?(yield tt(n,o),nt(o)):yield Promise.all(null==l?void 0:l.map(l=>e(void 0,void 0,void 0,function*(){yield tt(l,o)}))).then(e=>{nt(o)})}}})).catch(e=>{console.log("error---\x3e",e),kl(!1)})}catch(e){console.log("error---\x3e",e),kl(!1)}Zl(!0)},dt=()=>{on(!Il),_l(!1)},at=e=>{rn(!1),e&&A(V,U,{headline:"VAS POPUP CLOSE"})},rt=()=>{let e="undefined"!=typeof window&&localStorage.getItem("lineCheckResponse");we=e&&(null===JSON||void 0===JSON?void 0:JSON.parse(e)),Ee="undefined"!=typeof window&&b.get("chAddressJson"),Rl(!Ml),"function"==typeof Ce&&Ce(),ut()},st=P(null==Dn?void 0:Dn.bloks,Rn),ct=null===(ro=null==st?void 0:st[0])||void 0===ro?void 0:ro.tvProductId,vt=e=>{var o,l,n,t,i,d,a,r,s,c;const v=Ve&&(null===(n=null===(l=null===(o=null==Qn?void 0:Qn[0])||void 0===o?void 0:o.promotionInfo)||void 0===l?void 0:l[0])||void 0===n?void 0:n.id),u=Ve&&(null===(d=null===(i=null===(t=null==Qn?void 0:Qn[0])||void 0===t?void 0:t.promotionInfo)||void 0===i?void 0:i[0])||void 0===d?void 0:d.version),m=_e?{pointsBurnt:null===(r=null===(a=null==Qn?void 0:Qn[0])||void 0===a?void 0:a.rewards)||void 0===r?void 0:r.points,rewardOfferId:null===(c=null===(s=null==Qn?void 0:Qn[0])||void 0===s?void 0:s.rewards)||void 0===c?void 0:c.offerId,gloxTokenId:Je}:void 0;Qn&&Qn[0]&&(Qn[0].fromPopup=mn),ht("false"),sessionStorage.removeItem("vasPopUp"),cn(!1),x(kl,Fn,Ol,Qn,be,pt,Rn,ct,we,Ee,Rl,Ml,$e,xe,null!=lt?lt:e,se,tn,v,u,m)},ut=e=>{var o,l,n,t,i,d,a,r,s;pn(!1),xl(!1);let c=void 0!==typeof window&&b.get("sunriseAuth");const v=c&&JSON.parse(c),u=!(!(null==be?void 0:be.enableExistingCustomer)||null!=v);if(sessionStorage.removeItem(ie),(null===(o=null==be?void 0:be.linecheckData)||void 0===o?void 0:o.length)>0&&!Rn&&!Jn){return void(document.getElementById("linecheck")&&$e())}if(Jn&&!Rn&&(null===(l=null==be?void 0:be.loginData)||void 0===l?void 0:l.length)>0&&u)Ul(!0);else if(qn&&(null===(n=Qn[0])||void 0===n?void 0:n.isBundle)){let o=!1;zn||((null===(t=Qn[0])||void 0===t?void 0:t.isBundle)?null===(d=null===(i=Qn[0])||void 0===i?void 0:i.bundledOffers)||void 0===d||d.map(e=>{var l,n,t;"internet"!==(null===(l=null==e?void 0:e.productType)||void 0===l?void 0:l.toLowerCase())&&"tv"!=(null===(n=null==e?void 0:e.productType)||void 0===n?void 0:n.toLowerCase())||(null==e?void 0:e.recommendAccessory)&&(o=null==e?void 0:e.recommendAccessory),"mobile"!==(null===(t=null==e?void 0:e.productType)||void 0===t?void 0:t.toLowerCase())||(o=!1)}):(null===(a=null==Qn?void 0:Qn[0])||void 0===a?void 0:a.recommendAccessory)&&(o=null===(r=null==Qn?void 0:Qn[0])||void 0===r?void 0:r.recommendAccessory)),$(pt,Qn,se,Ve,null==Dn?void 0:Dn.productName,o),vt(e)}else Wn&&(null===(s=Qn[0])||void 0===s?void 0:s.isBundle)&&!sn?(rn(!0),cn(!0),ht("true"),window.addEventListener("beforeunload",function(e){ht("false"),sessionStorage.removeItem("vasPopUp"),cn(!1)})):(xe&&kl(!0),vt(e))},mt=(e,o)=>l=>{var n;const t=void 0!==typeof window&&b.get("one-commerce-cartId");(null==be?void 0:be.enableReplacePopup)&&t?(Cn.current=()=>e(l),yn.current=Boolean(o),Sn(null!=o?o:null===(n=null==be?void 0:be.generalReplacePopup)||void 0===n?void 0:n[0]),wn(!0)):e(l)},pt=S(Qn,Rn,null==be?void 0:be.pageType,!1,tn,Ve);i(()=>{var e,o;setTimeout(()=>{y(pe,ge)},100);const l=k(Rn?Qn:null!==(o=null===(e=null==Qn?void 0:Qn[0])||void 0===e?void 0:e.bundledOffers)&&void 0!==o?o:Qn);Dl(Object.assign({},l))},[ce,Le,tn,hn,((null==Le?void 0:Le.TV)||(null==Le?void 0:Le.gigaSpeed)||(null==Le?void 0:Le.Netflix))&&Array.isArray(Qn)&&3===(null===(co=null===(so=null==Qn?void 0:Qn[0])||void 0===so?void 0:so.bundledOffers)||void 0===co?void 0:co.length)]);const gt=()=>{((null==st?void 0:st.length)>0||Wn)&&Fl(!0)},ft=null===(vo=null==be?void 0:be.productContainer)||void 0===vo?void 0:vo[0];i(()=>{Nl&&(xe&&null==Kn?(_l(!Gl),on(!en)):xe&&(null==Kn?void 0:Kn.siteId)&&it())},[Nl]),i(()=>{var e;if(_n){const{store:o}=_n;(null===(e=null==o?void 0:o.ottOptionsApi)||void 0===e?void 0:e.length)>0&&0===(null==gn?void 0:gn.length)&&fn(null==o?void 0:o.ottOptionsApi)}},[_n]),i(()=>{if(!Nn||!(null==Ln?void 0:Ln.startTime)||!(null==Ln?void 0:Ln.endTime))return void On(!1);On(C(Ln.startTime,Ln.endTime));const e=T(Ln.startTime,Ln.endTime);if(e<=0)return;const o=setTimeout(()=>{On(C(Ln.startTime,Ln.endTime))},e);return()=>clearTimeout(o)},[Nn,null==Ln?void 0:Ln.startTime,null==Ln?void 0:Ln.endTime]),i(()=>{var e;const o=kn.current;if(!o||!(null===(e=null==se?void 0:se.timer)||void 0===e?void 0:e.length)||!Nn)return void bn(0);const l=()=>{bn(o.clientHeight)};if(l(),"undefined"==typeof ResizeObserver)return;const n=new ResizeObserver(l);return n.observe(o),()=>{n.disconnect()}},[null===(uo=null==se?void 0:se.timer)||void 0===uo?void 0:uo.length,Nn]),i(()=>{vn&&(at(),un(!0),ht("false"),sessionStorage.removeItem("vasPopUp"),cn(!1),vt())},[vn]),i(()=>{const e=()=>{const e=sessionStorage.getItem("vasPopUp");cn("true"===e)};e();const o=o=>{o.storageArea===sessionStorage&&"vasPopUp"===o.key&&e(),o.storageArea===sessionStorage&&"vasPopUp"===o.key&&null===o.newValue&&cn(!1)},l=()=>{e()};return window.addEventListener("storage",o),window.addEventListener("vasPopUpChange",l),()=>{window.removeEventListener("storage",o),window.removeEventListener("vasPopUpChange",l)}},[]);const ht=e=>{sessionStorage.setItem("vasPopUp",e);const o=new Event("vasPopUpChange");window.dispatchEvent(o)};return o.createElement("div",null,yl&&xn&&a(o.createElement(d,{keyParams:"loading"}),xn),$n&&o.createElement("div",{className:"w-75 pb-2"},o.createElement(r,null)),!$n&&we&&se&&Ee&&!Rn&&o.createElement("div",{className:s.selected},o.createElement("span",{style:{paddingBottom:"10px"}},Jn?o.createElement("span",{className:s.activeicon},o.createElement("img",{src:`${Mn}/icons/lineCheck-success.svg`,alt:"",width:24,height:24,className:s.activeicon}),o.createElement("span",null,null==he?void 0:he.subscriptionAvalTxt)):o.createElement("span",{className:s.inactiveicon},o.createElement("img",{src:`${Mn}/icons/cross_disabled.svg`,alt:"",width:24,height:24,className:s.inactiveicon}),o.createElement("span",null,null==he?void 0:he.notSubscriptionTxt)))),o.createElement("div",{className:`${!Rn&&!1===Jn&&(null===(mo=null==be?void 0:be.linecheckData)||void 0===mo?void 0:mo.length)>0&&"global/coverage-check"!==(null===(fo=null===(go=null===(po=null==be?void 0:be.linecheckData)||void 0===po?void 0:po[0])||void 0===go?void 0:go.reference)||void 0===fo?void 0:fo.default_full_slug)?s.overlay:""}\n ${Me&&!(null===(bo=null===(ho=null==Qn?void 0:Qn[0])||void 0===ho?void 0:ho.eligibility)||void 0===bo?void 0:bo.fpb)?s.disabled:""}\n `,style:{flexDirection:"column"}},o.createElement("div",{className:s.bundleproductcard},o.createElement("div",{id:`timer-section${pe}${fe}`,"data-timer-active":hn>0?"true":"false"},(null===(Eo=null==se?void 0:se.timer)||void 0===Eo?void 0:Eo.length)&&Nn?o.createElement("div",{style:{height:`${hn}px`,transition:"height 0.3s ease"}}):null),o.createElement("div",{className:`${s.productcontainer}`,style:(()=>{const e=An?In:se,o=null==e?void 0:e.showBorder,l=null==e?void 0:e.borderGradient,n=null==e?void 0:e.borderColor;return{borderColor:o&&!l?n||"":"transparent",borderWidth:o?"4px":"0px",borderStyle:o?"solid":"none",borderRadius:o?"8px":"",background:o&&l?`linear-gradient(white, white) padding-box, ${l} border-box`:void 0}})()},Un&&o.createElement(ae,{badges:se.badgesContainer}),jn&&o.createElement("div",{className:`${s.highlightText}`},null==se?void 0:se.highlightText),An&&((null==In?void 0:In.badgeContainer)?o.createElement(ae,{badges:null==In?void 0:In.badgeContainer}):o.createElement("div",{className:`${s.promocontainer}`,style:{background:null==In?void 0:In.bestSellerColor}},null==In?void 0:In.displayText)),o.createElement("div",{ref:kn,className:s.timerContainer},(null===(wo=null==se?void 0:se.timer)||void 0===wo?void 0:wo.length)&&Nn?o.createElement(de,{content:null===(Co=null==se?void 0:se.timer)||void 0===Co?void 0:Co[0],hasHighlightText:Un||An,onTimerChange:e=>{On(e)}}):null),o.createElement("div",{className:`${s.detailsection} ${s.imageFullWidthSection}`,id:`detailsectionv3${pe}${fe}`},o.createElement("div",{className:`${s.headersection}`},o.createElement("div",{className:`${s.titlesection}`},o.createElement("div",{className:`${s.productheader}`,id:`titleV3${pe}${fe}`},null==Dn?void 0:Dn.productName),o.createElement("div",null,(null===(Po=null==Dn?void 0:Dn.icon)||void 0===Po?void 0:Po.filename)&&o.createElement("img",{className:`${s.imagecontainer}`,src:null===(So=null==Dn?void 0:Dn.icon)||void 0===So?void 0:So.filename,height:15,width:20,alt:"productIcon"}))),o.createElement("div",{className:`${s.productdescription}`,id:`descriptionV3${pe}${fe}`},o.createElement(c,{content:null==Dn?void 0:Dn.description})),o.createElement("div",{className:`${s.images}`},(null===(yo=null==Dn?void 0:Dn.img)||void 0===yo?void 0:yo.filename)&&o.createElement("img",{className:`${s.imagespace} ${(null==se?void 0:se.highlightText)&&s.borderimage}`,alt:"cardimg",src:`${null===(ko=null==Dn?void 0:Dn.img)||void 0===ko?void 0:ko.filename}/m/`}))),o.createElement("div",{className:`${s.productconfig}`,id:`product-configv3${pe}${fe}`},$n?o.createElement(o.Fragment,null,o.createElement("div",{className:s.space}),o.createElement(r,{stylename:s.skeletontittle,count:1}),o.createElement(r,{stylename:s.skeletonline,count:5}),o.createElement("div",{className:s.space}),o.createElement(r,{stylename:s.skeletontittle,count:1}),o.createElement(r,{stylename:s.skeletonline,count:5})):o.createElement("div",null,(null==Dn?void 0:Dn.bloks)&&(null===(To=null==Dn?void 0:Dn.bloks)||void 0===To?void 0:To.map((e,l)=>o.createElement(v,{content:e,indexKey:l,constants:he,key:l,showModalPopup:gt,setToggleState:Ie,toggleState:Le,noTabs:Ne,mainContent:be,enableTVStreamingOptions:null==se?void 0:se.enableTVStreamingOptions,metadata:me,setTvOptionsData:Xn})))))),o.createElement("div",{className:`${s.detailsection}`,id:`benefits-price-section${pe}${fe}`},o.createElement("div",{id:`exclusive-benefits-section${pe}${fe}`},(null===(xo=null==Dn?void 0:Dn.extraBenefits)||void 0===xo?void 0:xo.length)>0&&o.createElement(le,{content:null===($o=null==Dn?void 0:Dn.extraBenefits)||void 0===$o?void 0:$o[0]})),o.createElement("div",{className:`${s.benefitssection}`,id:`benefits-section${pe}${fe}`},(null===(Do=null==Dn?void 0:Dn.benefits)||void 0===Do?void 0:Do.length)>0&&o.createElement(u,{content:null==Dn?void 0:Dn.benefits,benefitData:pt,constants:he,pricesToggleState:Ge,togglePriceLabel:null==Re?void 0:Re.togglePriceLabel})),o.createElement("br",null),o.createElement("div",{className:`${s.giftsection}`,id:`gift-section${pe}${fe}`},(null==$l?void 0:$l.showGift)&&(null===(Io=null==In?void 0:In.singleGift)||void 0===Io?void 0:Io.map((e,l)=>o.createElement(I,{content:e,key:l}))),(null==$l?void 0:$l.showGift)&&(null===(Lo=null==In?void 0:In.giftConfig)||void 0===Lo?void 0:Lo.map((e,l)=>o.createElement(L,{content:e,key:l,selectedGiftItem:et,parentPoType:Rn?"MOBILE":"HOME"}))),o.createElement("div",{className:`${s.giftsection}`,id:`cashback-section${pe}${fe}`},o.createElement(j,{uniqueProductData:Qn,mainContent:be}))),o.createElement("div",{className:`${s.ordersection}`,id:`order-section${pe}${fe}`},""===(null==pt?void 0:pt.base)?o.createElement("div",null,o.createElement(r,{stylename:s.skeletontittle})):o.createElement("div",{id:`price-section${pe}${fe}`},o.createElement(m,{priceCollection:pt,constants:he,promoText:null==Dn?void 0:Dn.promoText,deviceFlow:Be,content:se,offeringData:ce,uniqueId:ve})),!_e&&o.createElement("div",{className:`${s.discountedpricetoggleSection}`,id:`discountedpricetoggle-section${pe}${fe}`},Hn||"INLINE"!==(null==Re?void 0:Re.togglePosition)?null:o.createElement(ne,{content:Dn,index:fe,lineTable:!0,toggleContent:Re})),xe&&(null==he?void 0:he.P2PDiscountLabel)&&o.createElement("div",{className:s.longterm},null==he?void 0:he.P2PDiscountLabel),$n?o.createElement(o.Fragment,null,o.createElement(r,{stylename:s.skeletontittle,count:1}),o.createElement(r,{stylename:s.skeletonline,count:2})):o.createElement("div",{className:`${(null==ue?void 0:ue.swapButton)&&s.swapButton}`},o.createElement("div",{style:{padding:"16px 0 0 0"}},o.createElement(p,{isMobileFlow:Rn,createCartCall:(null==Be?void 0:Be.isDeviceFlow)?mt(e=>{xl(!1);Oe({setShowLoader:kl,cartEndPoint:Fn,giftItem:Ol,uniqueProductData:Qn,mainContent:be,showPrice:pt,isMobileFlow:Rn,eligibleBundle:we,address:Ee,setShowLinecheck:Rl,showLinecheck:Ml,lineCheckCallBack:$e,enableP2P:xe,msisdnn:null!=lt?lt:e,content:se,selectedRP:je,continueCart:Ae})}):mt(Rn?Zn:ut),constants:he,storyContent:ue,showPrice:pt,isAvailable:Jn,address:Ee,uniqueProductBenefits:null==Qn?void 0:Qn[0],alwaysActive:!Jn&&(null===(No=null==be?void 0:be.linecheckData)||void 0===No?void 0:No.length)>0&&"global/coverage-check"===(null===(jo=null===(Oo=null===(Bo=null==be?void 0:be.linecheckData)||void 0===Bo?void 0:Bo[0])||void 0===Oo?void 0:Oo.reference)||void 0===jo?void 0:jo.default_full_slug),flexUpgradeFreePopup:null===(Uo=null===(Ao=null==be?void 0:be.flexUpgradeFreePopup)||void 0===Ao?void 0:Ao.reference)||void 0===Uo?void 0:Uo.content,content:se,deviceUltimateBundle:Me,forceDisabled:Boolean(null===(Fo=null===(Vo=null==Qn?void 0:Qn[0])||void 0===Vo?void 0:Vo.rewards)||void 0===Fo?void 0:Fo.notEligibleReason),notEligibileReason:null===(Ro=null===(Mo=null==Qn?void 0:Qn[0])||void 0===Mo?void 0:Mo.rewards)||void 0===Ro?void 0:Ro.notEligibleReason})),!_e&&(null===(Go=null==ue?void 0:ue.addSmartPhone)||void 0===Go?void 0:Go.length)>0&&!(null==Be?void 0:Be.isDeviceFlow)&&o.createElement("div",{style:{textAlign:"center"}},(null==ue?void 0:ue.swapButton)?(null==ue?void 0:ue.ctaLabel)&&o.createElement("div",{style:{padding:"16px 0"}},o.createElement("button",{className:"primarybutton",onClick:()=>{var e;return mt(()=>D(pt,ue,Qn,"",se,Ve),null===(e=null==be?void 0:be.replacePopupWithSmartphone)||void 0===e?void 0:e[0])()}},o.createElement("span",{className:s.buttontext},null==ue?void 0:ue.ctaLabel))):!(null==se?void 0:se.redirectOnly)&&o.createElement("div",{style:{padding:"12px 0 0 0"}},o.createElement(te,{content:{buttonType:"Secondary-V1",buttonLabel:(null==se?void 0:se.ultimateBundlePromotion)?null==he?void 0:he.ultimateBundleLbl:null===(Jo=null===(_o=null==ue?void 0:ue.addSmartPhone)||void 0===_o?void 0:_o[0])||void 0===Jo?void 0:Jo.buttonLabel,buttonIcon:null===(qo=null===(Wo=null==ue?void 0:ue.addSmartPhone)||void 0===Wo?void 0:Wo[0])||void 0===qo?void 0:qo.buttonIcon,buttonAlignment:"left"},wafIdentifier:ye,style:{width:"100%"},onClick:()=>{var e;return mt(()=>xe?void Bl(!0):D(pt,ue,Qn,"",se,Ve),null===(e=null==be?void 0:be.replacePopupWithSmartphone)||void 0===e?void 0:e[0])()}}))),o.createElement("div",{className:s.productcontractduration,id:`contract-section${pe}${fe}`,style:{paddingTop:(null===(Ho=null==ue?void 0:ue.addSmartPhone)||void 0===Ho?void 0:Ho.length)>0&&!(null==Be?void 0:Be.isDeviceFlow)&&!(null==ue?void 0:ue.swapButton)&&!(null==se?void 0:se.redirectOnly)?"8px":void 0}},(null==pt?void 0:pt.contractDuration)>"1"?B(null===(zo=null==he?void 0:he.minContractDuration)||void 0===zo?void 0:zo.substring(1),[null==pt?void 0:pt.contractDuration]):null==he?void 0:he.noContractDuration)),o.createElement("div",{style:{textAlign:"center",padding:"4px"}},(null===(Ko=null==Dn?void 0:Dn.productDetails)||void 0===Ko?void 0:Ko.length)>0&&o.createElement("span",{className:s.productdetailslink,onClick:()=>{var e,o,l;xl(!Tl),A(V,R,X(Qn,"",M));const n=localStorage.getItem("prospectId"),t=null!==(l=null===(o=null===(e=null===window||void 0===window?void 0:window.location)||void 0===e?void 0:e.pathname)||void 0===o?void 0:o.split("/"))&&void 0!==l?l:[],i=t[t.length-1],d={eventTimestamp:O(),eventType:"PageView",pageType:"ProductDetails",pageLocation:i,targetProduct:Vn};n&&z(Tn,d,n)}},null==he?void 0:he.productDetailsLink)),Tl&&o.createElement(g,{content:null==Dn?void 0:Dn.productDetails,showProductDetail:Tl,setShowProductDetail:xl,constants:he,showPrice:pt,isMobileFlow:Rn,createCartCall:Rn?Zn:ut,storyContent:ue,isAvailable:Jn,address:Ee,flexUpgradeFreePopup:null===(Xo=null===(Qo=null==be?void 0:be.flexUpgradeFreePopup)||void 0===Qo?void 0:Qo.reference)||void 0===Xo?void 0:Xo.content,notEligibileReason:null===(Zo=null===(Yo=null==Qn?void 0:Qn[0])||void 0===Yo?void 0:Yo.rewards)||void 0===Zo?void 0:Zo.notEligibleReason})))))),Me&&Qn&&!(null===(ol=null===(el=null==Qn?void 0:Qn[0])||void 0===el?void 0:el.eligibility)||void 0===ol?void 0:ol.fpb)&&o.createElement("div",{className:s.disabledInfo},o.createElement(c,{content:null==he?void 0:he.fpbNotCompatibleText})),Vl&&($n?o.createElement(r,null):o.createElement(G,{content:null==st?void 0:st[0],setShowModal:Fl,showModal:Vl,constants:he})),Al&&(null===(ll=null==be?void 0:be.loginData)||void 0===ll?void 0:ll.length)>0&&xn&&a(o.createElement(w,{content:null===(nl=null==be?void 0:be.loginData)||void 0===nl?void 0:nl[0],closeLogin:()=>{Ul(!1)},metadata:me,onSuccess:()=>{Ul(!1),Te(),sessionStorage.removeItem("vasPopUp"),cn(!1),xe?it():ut()},isProdEnv:Fe}),xn),Gl&&xe&&!Al&&en&&o.createElement(q,{modalState:Il,handler:dt,showFooter:!1,width:"628px",height:"280px",backgroundColor:"#f7f6f5",noCloseButton:!1,backDrop:!0,bodyPadding:"16px"},o.createElement(W,{onClose:Yn,content:null===(dl=null===(il=null===(tl=null==be?void 0:be.productContainer)||void 0===tl?void 0:tl[0])||void 0===il?void 0:il.p2pBloks)||void 0===dl?void 0:dl[0],prepaid:!1})),xe&&Yl&&ql&&en&&o.createElement(q,{modalState:Il,handler:dt,showFooter:!1,width:"628px",height:"280px",backgroundColor:"#f7f6f5",noCloseButton:!1,backDrop:!0,bodyPadding:"16px",id:"table-product"},o.createElement(W,{onClose:Yn,content:null===(sl=null===(rl=null===(al=null==be?void 0:be.productContainer)||void 0===al?void 0:al[0])||void 0===rl?void 0:rl.p2pBloks)||void 0===sl?void 0:sl[1],prepaid:!0})),(null==Ql?void 0:Ql.length)>1&&xe&&Yl&&!ql&&ln&&o.createElement(q,{modalState:ln,handler:()=>{kl(!1),nn(!ln)},showFooter:!1,width:"628px",height:"280px",backgroundColor:"#f7f6f5",noCloseButton:!1,backDrop:!0,bodyPadding:"16px"},o.createElement(Q,{onSubmit:e=>{nn(!ln),Nl?D(pt,ue,Qn,e,se,Ve):ut(null==e?void 0:e.msisdn)},exsistingSubscriptionData:Ql,updatedContent:ft})),Ml&&(null==be?void 0:be.enableLinecheckOverlay)&&!Rn&&(null===(cl=null==be?void 0:be.linecheckData)||void 0===cl?void 0:cl.length)>0&&!xe&&"global/new-linecheck-test"===(null===(ml=null===(ul=null===(vl=null==be?void 0:be.linecheckData)||void 0===vl?void 0:vl[0])||void 0===ul?void 0:ul.reference)||void 0===ml?void 0:ml.default_full_slug)?o.createElement(_,{content:null===(pl=null==be?void 0:be.linecheckData)||void 0===pl?void 0:pl[0],onSuccess:rt,showModal:Ml,setShowModal:Rl,productName:null==Dn?void 0:Dn.productName,productId:null==Dn?void 0:Dn.productId}):Ml&&(null==be?void 0:be.enableLinecheckOverlay)&&!Rn&&(null===(gl=null==be?void 0:be.linecheckData)||void 0===gl?void 0:gl.length)>0&&!xe&&"global/coverage-check"===(null===(bl=null===(hl=null===(fl=null==be?void 0:be.linecheckData)||void 0===fl?void 0:fl[0])||void 0===hl?void 0:hl.reference)||void 0===bl?void 0:bl.default_full_slug)?o.createElement(Y,{content:null===(El=null==be?void 0:be.linecheckData)||void 0===El?void 0:El[0].reference.content.body[0],overlayIsOpen:!0,externalHandleModal:Rl,productName:null==Dn?void 0:Dn.productName,showModal:Ml,setShowModal:Rl,onSuccess:()=>{let e="undefined"!=typeof window&&localStorage.getItem("lineCheckResponse");we=e&&(null===JSON||void 0===JSON?void 0:JSON.parse(e)),Ee="undefined"!=typeof window&&b.get("chAddressJson"),"function"==typeof Ce&&Ce()},onCreateCart:rt,lineCheckOnClear:Ue,productId:null==Dn?void 0:Dn.productId}):null,Jl&&Rn&&(null===(wl=null==ue?void 0:ue.benefitsValidate)||void 0===wl?void 0:wl.length)>0&&o.createElement(J,{content:null===(Cl=null==ue?void 0:ue.benefitsValidate)||void 0===Cl?void 0:Cl[0],loginContent:null===(Pl=null==be?void 0:be.loginData)||void 0===Pl?void 0:Pl[0],metadata:me,createCartCall:ut,fetchOfferData:Se,basicConfigUrl:ye,selectedExistingOption:ke,setShowBenefit:Wl,setLoginSuccess:Te,isProdEnv:Fe}),an&&o.createElement(q,{modalState:an,handler:at,showFooter:!1,width:"mobile"===Gn?"":"tablet"===Gn?"700px":"990px",fixedWidth:"mobile"===Gn?"":"tablet"===Gn?"700px":"990px",height:"845px",backgroundColor:"#f7f6f5",noCloseButton:!1,backDrop:!0,bodyPadding:"24px"},o.createElement(oe,{content:null===(Sl=null==be?void 0:be.optionsPopup)||void 0===Sl?void 0:Sl[0],addOptionsCallBack:e=>{pn(!0),un(!0),Xn(e)},metadata:me,constants:he,mainContent:be,preSelectedOptions:[],optionsResponse:gn,updateResponseList:fn,showPrice:pt,productData:Dn,offeringData:ce,uniqueId:ve,deviceFlow:Be})),En&&Pn&&o.createElement(re,{modalState:En,onCloseHandler:()=>{Cn.current=null,wn(!1)},content:Pn,wafIdentifier:ye,onPrimaryClick:()=>{const e=Cn.current;Cn.current=null,yn.current&&b.remove("one-commerce-cartId"),yn.current=!1,wn(!1),null==e||e()},onSecondaryClick:()=>{Cn.current=null,wn(!1)}}))};export{se as default};
2
2
  //# sourceMappingURL=StaticProduct.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"StaticProduct.js","sources":["../../../../src/components/StaticLineTable/StaticProduct.tsx"],"sourcesContent":["import React, { FC, useContext, useEffect, useRef, useState } from 'react';\nimport Dotloader from '../Dotloader/Dotloader';\nimport { createPortal } from 'react-dom';\nimport SkeletonLoader from '../SkeletonLoader/SkeletonLoader';\nimport Styles from './StaticLineTable.module.scss';\nimport RichText from '../richtext';\nimport StaticProductEntitlement from './StaticProductEntitlement';\nimport StaticBenefit from './StaticBenefit';\nimport DynamicPriceSection from './DynamicPriceSection';\nimport CheckoutButton from './CheckoutButton';\nimport StaticProductDetails from './StaticProductDetails';\nimport { StaticProductSchema } from './StaticProductDatatypes';\nimport {\n AssetPathPropConfig,\n LineTableBasicPropConfig\n} from '../../services/LineTableBasicPropConfig';\nimport Cookies from 'js-cookie';\nimport { LoginBasicPropConfig } from '../../services/LoginBasicPropConfig';\nimport LoginModalV2 from '../login/LoginModalV2';\nimport {\n checkGiftOrCashback,\n combineWithSmartPhone,\n combineWithVasOptions,\n fetchPrice,\n fetchServiceOptions,\n findHeight,\n isTimerActive,\n getTimeUntilNextTimerEvent,\n staticCreateCart\n} from './Product.utils';\nimport GiftConfigV2 from '../ProductDetailsV3/GiftConfigV2';\nimport ChooseGiftV2 from '../ProductDetailsV3/ChooseGiftV2';\nimport { replacePlaceholder, viewport, getUtcTimestamp } from '../../utils/utils';\nimport StaticProductCashback from './StaticProductCashback';\nimport { trackNewDatalayerEvent } from '../../utils/AnalyticsUtils';\nimport {\n CTABUTTONCLICK,\n DOWNLOADPRODUCT,\n EXISTINGCUSTOMER,\n GAEVENT,\n LINETABLE\n} from '../../Analytics/AnalyticsConstants';\nimport TVChannelModal from './TVChannelModal';\nimport LinecheckModal from '../LineCheckV3/LinecheckModal';\nimport BenefitsValidateWrapper from '../BenefitWrapper/BenefitsValidateWrapper';\nimport PreToPostSubsPopup from '../PretoPost/PreToPostSubsPopup';\nimport GenericModal from '../LineCheckV3/GenericModal';\nimport {\n fetchSubscriptionData,\n trackPegaEvents,\n validateP2P\n} from '../../services/LineTableService';\nimport ExsistingSubscriptionModal from './ExsistingSubscriptionModal';\nimport { getEcomCartInfo } from '../../models/Analytics/items';\nimport CoverageCheckModal from '../NewLineCheck/CoverageCheckModal';\n\nimport { API_BASE_BASEPOINT } from '../../services/api-constants';\nimport { AppContext } from './StaticLineTableStore/StaticLineTableProvider';\nimport OttServiceOptionsSmallPopup from './OttServiceOptions/OttServiceOptionsSmallPopup';\nimport StaticExclusiveBenefit from './StaticExclusiveBenefit';\n// US_312953\nimport UserLoggedPricesToggle from '../UserLoggedPricesToggle/UserLoggedPricesToggle';\nimport FalconButtonV2 from '../FalconButtonV2/FalconButtonV2';\nimport { ONE_ECOMMERCE_INTERNET_SUMMARY } from '../../utils/constants';\nimport StaticLineTabelTimer from './StaticLineTabelTimer/StaticLineTabelTimer';\nimport { BadgeContainer } from '@sunrise-upc/sales-static-components';\n\nconst StaticProduct: FC<StaticProductSchema> = ({\n content,\n offeringData,\n uniqueId,\n storyContent,\n metadata,\n tabIndex,\n cardsLength,\n indexKey,\n constants,\n mainContent,\n address,\n eligibleBundle,\n linecheckSuccessCallBack,\n selectedOption,\n fetchOfferData,\n basicConfigUrl,\n selectedExistingOption,\n setLoginSuccess,\n enableP2P,\n lineCheckCallBack,\n loginSuccess,\n setToggleState,\n toggleState,\n noTabs,\n deviceFlow,\n deviceFlowCallBack,\n selectedRP,\n continueCart,\n lineCheckOnClear,\n pegaIntegration,\n isProdEnv,\n deviceUltimateBundle,\n //US_31295\n toggleContent,\n pricesToggleState,\n isShogunFlow,\n shogunToken\n}) => {\n const [showLoader, setShowLoader] = useState<boolean>(false);\n const [showProductDetail, setShowProductDetail] = useState(false);\n const [showGiftOrCashback, setShowGiftOrCashback] = useState({\n showGift: false,\n cashbackAvailable: false\n });\n const [modalClick, updateModalClick] = useState(true);\n const [combine, setCombine] = useState(false);\n const [giftItem, setGiftItem] = useState<any>([]);\n const [showLogin, setShowLogin] = useState<boolean>(false);\n const [showOptions, setShowOptions] = useState<boolean>(false);\n const [showLinecheck, setShowLinecheck] = useState<boolean>(false);\n const [showP2P, setShowP2P] = useState<boolean>(false);\n const [showBenefit, setShowBenefit] = useState<boolean>(false);\n const [subscriptionFailure, setSubscriptionFailure] = useState(false);\n const endpoint = `${basicConfigUrl}inf/customer-management/subscriptions`;\n const validateEndpoint = `${basicConfigUrl}inf/resource-management/msisdns/pretopost/validation`;\n const [userSubscriptionData, setUserSubscriptionData] = useState<any>([]);\n const [afterLogin, setAfterLogin] = useState<boolean>(false);\n const [popUPClick, setModalClick] = useState<boolean>(false);\n const [p2pModal, setP2pModal] = useState<boolean>(false);\n const [tvOptions, setTvOptions] = useState<any[] | undefined>([]);\n const [displayTvOptionsPopUp, setDisplayTvOptionsPopUp] = useState<boolean>(false);\n const [alreadyShowedTvOptionsPopUp, setAlreadyShowedTvOptionsPopUp] = useState<boolean>(false);\n const [tvOptionsPopUpChanged, setTvOptionsPopUpChanged] = useState<boolean>(false);\n const [tvOptionsPopUpAddToCart, setTvOptionsPopUpAddToCart] = useState<boolean>(false);\n const [responseList, setResponseList] = useState([]);\n const [timerSpaceHeight, setTimerSpaceHeight] = useState(0);\n const timerContainerRef = useRef<HTMLDivElement | null>(null);\n const pegaEndpoint = `${basicConfigUrl}inf/${API_BASE_BASEPOINT.CUSTOMER}`;\n\n /*the portal position for the the dotloader*/\n const portalPosition: any =\n typeof window !== undefined && document.getElementById('static-linetable');\n const isSkeletonLoading = Object.keys(content)?.length === 0;\n const productData = content?.products?.[0]?.reference?.content?.product?.[0];\n const promotionData = content?.promotion?.[0]?.reference?.content?.promoDescription?.[0];\n const timerContent = content?.timer?.[0];\n const isCounterEnabled = timerContent?.enableCounter;\n const [timerIsActive, setTimerIsActive] = useState(\n isCounterEnabled && timerContent?.startTime && timerContent?.endTime\n ? isTimerActive(timerContent.startTime, timerContent.endTime)\n : false\n );\n const showHighlightText = Boolean(\n content?.highlightText && pricesToggleState !== true && !timerIsActive && !content?.badgesContainer\n );\n const showPromoContainer = Boolean(\n promotionData?.displayText &&\n !content?.notShowPromotionLabel &&\n pricesToggleState !== true &&\n !timerIsActive\n );\n\n const showBadges = Boolean(\n content?.badgesContainer && pricesToggleState !== true && !timerIsActive && !showPromoContainer\n );\n\n const id = productData?.productId;\n const cartEndPoint = LineTableBasicPropConfig?.getInstance()?.getCartUrl();\n const assetPath = AssetPathPropConfig?.getInstance()?.getAssetPath();\n const isMobileFlow = storyContent?.pageType === 'MOBILE';\n const viewPortType = viewport();\n const context = useContext(AppContext);\n let isAvailable: boolean | undefined = undefined;\n isAvailable = address && eligibleBundle?.eligibleBundle?.includes(id);\n const enableTVStreamingOptionsPopUp = content?.enableTVStreamingOptionsPopUp;\n const enableTVStreamingOptionsStepper = content?.enableTVStreamingOptionsStepper;\n const disableDiscountedPriceToggle = content?.disableDiscountedPriceToggle;\n const skipAccessoriesPage = content?.skipAccessoriesPage;\n\n LoginBasicPropConfig.create({ baseURL: basicConfigUrl ?? '' });\n\n //sunrise auth data\n let AuthData: any = typeof window !== undefined && Cookies.get('sunriseAuth');\n AuthData = AuthData && JSON.parse(AuthData);\n //offer data wrt to tab\n const uniqueProductData: any = (offeringData?.[uniqueId] || []).filter(\n (product: any) => product?.id === id\n );\n\n const setTvOptionsData = (options: any) => {\n setTvOptions(options);\n };\n\n const handleP2PClick = () => {\n setShowLogin(true);\n setShowP2P(!showP2P);\n setModalClick(!popUPClick);\n };\n\n //creacart function or login pop up\n const createCart = () => {\n setShowProductDetail(false);\n if (enableP2P && AuthData == undefined) {\n setShowP2P(!showP2P);\n setModalClick(!popUPClick);\n } else if (enableP2P && AuthData?.siteId) {\n fetchPrepaidData();\n } else if (selectedOption === EXISTINGCUSTOMER && selectedExistingOption?.length > 0) {\n setShowBenefit(true);\n } else {\n //US_31295\n const setLoginCookie =\n (mainContent?.enableExistingCustomer && AuthData == undefined) ||\n (!AuthData && pricesToggleState === true && toggleContent?.enableLoggedInPrice)\n ? true\n : false;\n setLoginCookie ? setShowLogin(true) : createCartCall();\n }\n if (pegaIntegration) {\n const prospectId = localStorage.getItem('prospectId');\n const url = window?.location?.pathname?.split('/') ?? [];\n const pathname = url[url.length - 1];\n const payload = {\n eventTimestamp: getUtcTimestamp(),\n eventType: 'PageView',\n pageType: 'CartCreated',\n pageLocation: pathname,\n // deviceType: viewPortType,#TODO - fix this values, isn't working for tablet\n targetProduct: id\n };\n prospectId && trackPegaEvents(pegaEndpoint, payload, prospectId);\n }\n };\n\n //setting the selected gift from choose gift section\n const selectedGiftItem = (item: any) => {\n const itemValue = giftItem.findIndex((gift: any) => item?.giftGroupId === gift?.giftGroupId);\n const temp = giftItem;\n if (itemValue === -1) temp.push(item);\n else temp[itemValue] = item;\n setGiftItem([...temp]);\n };\n\n // Helper method to get border styles\n const getBorderStyles = () => {\n const borderConfig = showPromoContainer ? promotionData : content;\n const showBorder = borderConfig?.showBorder;\n const borderGradient = borderConfig?.borderGradient;\n const borderColor = borderConfig?.borderColor;\n\n return {\n borderColor: showBorder && !borderGradient ? borderColor || '' : 'transparent',\n borderWidth: showBorder ? '4px' : '0px',\n borderStyle: showBorder ? 'solid' : 'none',\n borderRadius: showBorder ? '8px' : '',\n background: showBorder && borderGradient\n ? `linear-gradient(white, white) padding-box, ${borderGradient} border-box`\n : undefined,\n };\n };\n\n //queryParam for MySunrise P2P flow\n const params = new URLSearchParams(window?.location?.search);\n const queryParams = params?.get('selectedMsisdn');\n const validateNumberFcn = (value: any) => {\n // once all the prepaid numbers are validated\n if (value?.length === 1) {\n combine\n ? combineWithSmartPhone(\n showPrice,\n storyContent,\n uniqueProductData,\n value?.[0],\n content,\n pegaIntegration\n )\n : createCartCall(value?.[0]?.msisdn);\n setSubscriptionFailure(false);\n } else if (value?.length > 1) {\n setUserSubscriptionData(value);\n setP2pModal(!p2pModal);\n setSubscriptionFailure(false);\n } else {\n setModalClick(!popUPClick);\n setSubscriptionFailure(true);\n updateModalClick(true);\n setShowLoader(false);\n }\n };\n const validateFcn = async (value: any, validPrepaidNumbers: any) => {\n await validateP2P(value?.msisdn, validateEndpoint)\n .then((res) => {\n if (res) {\n validPrepaidNumbers.push(value);\n }\n })\n .catch((e: any) => {\n // eslint-disable-next-line no-console\n console.log('error', e);\n });\n };\n //prepaid subscription api and validating those for conversion\n const fetchPrepaidData = () => {\n setShowLoader(true);\n try {\n fetchSubscriptionData('PREPAID', endpoint)\n ?.then(async (resp: any) => {\n if (resp?.subscriptionData == 204) {\n setModalClick(!popUPClick);\n setSubscriptionFailure(true);\n updateModalClick(true);\n setShowLoader(false);\n } else {\n const responseData = resp?.subscriptionData;\n const queryData = responseData.find((entry: any) => entry.msisdn === queryParams);\n if (responseData) {\n const validPrepaidNumbers: any = [];\n if (queryParams) {\n await validateFcn(queryData, validPrepaidNumbers);\n validateNumberFcn(validPrepaidNumbers);\n } else {\n await Promise.all(\n responseData?.map(async (data: any) => {\n await validateFcn(data, validPrepaidNumbers);\n })\n ).then((succ) => {\n validateNumberFcn(validPrepaidNumbers);\n });\n }\n }\n }\n })\n .catch((error: any) => {\n // eslint-disable-next-line no-console\n console.log('error--->', error);\n setShowLoader(false);\n });\n } catch (err: any) {\n // eslint-disable-next-line no-console\n console.log('error--->', err);\n setShowLoader(false);\n }\n setAfterLogin(true);\n };\n\n // on login success\n const onLoginSuccess = () => {\n setShowLogin(false);\n setLoginSuccess();\n sessionStorage.removeItem('vasPopUp');\n setAlreadyShowedTvOptionsPopUp(false);\n if (enableP2P) {\n fetchPrepaidData();\n } else {\n createCartCall();\n }\n };\n\n // to close the pop up of P2P\n const handleClick = () => {\n setModalClick(!modalClick);\n setShowP2P(false);\n };\n\n // to close the pop up of P2P for success prepiad\n const handlePrepaidClick = () => {\n setShowLoader(false);\n setP2pModal(!p2pModal);\n };\n\n const closeTVOptionsModal = (event?: any) => {\n setDisplayTvOptionsPopUp(false);\n\n if (event) {\n trackNewDatalayerEvent(GAEVENT, CTABUTTONCLICK, {\n headline: 'VAS POPUP CLOSE'\n });\n }\n };\n\n //once linecheck success set linecheck pop up false and proceed to checkout section\n const linecheckSuccess = () => {\n let bundle = typeof window !== 'undefined' && localStorage.getItem('lineCheckResponse');\n eligibleBundle = bundle && JSON?.parse(bundle);\n address = typeof window !== 'undefined' && Cookies.get('chAddressJson');\n typeof linecheckSuccessCallBack == 'function' && linecheckSuccessCallBack();\n };\n\n //once linecheck success set linecheck pop up false and proceed to checkout section\n const linecheckSuccessAndCart = () => {\n let bundle = typeof window !== 'undefined' && localStorage.getItem('lineCheckResponse');\n eligibleBundle = bundle && JSON?.parse(bundle);\n address = typeof window !== 'undefined' && Cookies.get('chAddressJson');\n setShowLinecheck(!showLinecheck);\n typeof linecheckSuccessCallBack == 'function' && linecheckSuccessCallBack();\n createCartCall();\n };\n\n //service Option set for TV\n\n const serviceOption = fetchServiceOptions(productData?.bloks, isMobileFlow);\n\n const radioValue = serviceOption?.[0]?.tvProductId;\n\n const createCartCallAction = (msisdn?: string) => {\n const discountRef = pegaIntegration && uniqueProductData?.[0]?.promotionInfo?.[0]?.id;\n const discountVersion = pegaIntegration && uniqueProductData?.[0]?.promotionInfo?.[0]?.version;\n\n // Shogun / rewards (loyalty) flow: attach the pointsBurnt note so the\n // backend can settle the loyalty burn during cart creation. The value\n // comes from the offer response under `rewards.points`.\n const rewardsInfo = isShogunFlow\n ? { pointsBurnt: uniqueProductData?.[0]?.rewards?.points, rewardOfferId: uniqueProductData?.[0]?.rewards?.offerId, gloxTokenId: shogunToken }\n : undefined;\n\n // US 317400- vas options pop tracking\n if (uniqueProductData && uniqueProductData[0]) {\n uniqueProductData[0].fromPopup = tvOptionsPopUpAddToCart;\n }\n updateVasPopUp('false');\n sessionStorage.removeItem('vasPopUp');\n setAlreadyShowedTvOptionsPopUp(false);\n\n staticCreateCart(\n setShowLoader,\n cartEndPoint,\n giftItem,\n uniqueProductData,\n mainContent,\n showPrice,\n isMobileFlow,\n radioValue,\n eligibleBundle,\n address,\n setShowLinecheck,\n showLinecheck,\n lineCheckCallBack,\n enableP2P,\n queryParams ?? msisdn,\n content,\n tvOptions,\n discountRef,\n discountVersion,\n rewardsInfo\n );\n };\n //cart creation\n const createCartCall = (msisdn?: string) => {\n setTvOptionsPopUpAddToCart(false);\n setShowProductDetail(false);\n let AuthData: any = typeof window !== undefined && Cookies.get('sunriseAuth');\n const AuthDataNew = AuthData && JSON.parse(AuthData);\n const setLoginCookie =\n mainContent?.enableExistingCustomer && AuthDataNew == undefined ? true : false;\n sessionStorage.removeItem(ONE_ECOMMERCE_INTERNET_SUMMARY);\n if (mainContent?.linecheckData?.length > 0 && !isMobileFlow && !isAvailable) {\n // setShowLinecheck(true);\n const lineCheckElement = document.getElementById('linecheck');\n if (lineCheckElement) {\n lineCheckCallBack();\n }\n return;\n } else if (\n isAvailable &&\n !isMobileFlow &&\n mainContent?.loginData?.length > 0 &&\n setLoginCookie\n ) {\n setShowLogin(true);\n } else if (enableTVStreamingOptionsStepper && uniqueProductData[0]?.isBundle) {\n let recommendAccessory = false;\n\n if (!skipAccessoriesPage) {\n /**Check if bundle or Internet and add it to cart request*/\n if (uniqueProductData[0]?.isBundle) {\n uniqueProductData[0]?.bundledOffers?.map((item: any) => {\n if (\n item?.productType?.toLowerCase() === 'internet' ||\n item?.productType?.toLowerCase() == 'tv'\n ) {\n if (item?.recommendAccessory) {\n recommendAccessory = item?.recommendAccessory;\n }\n }\n // setting to false incase of Mobile product Type as it is currently out of scope\n if (item?.productType?.toLowerCase() === 'mobile') {\n recommendAccessory = false;\n return;\n }\n });\n } else {\n /**Add standlone product such as internet to cart request*/\n if (uniqueProductData?.[0]?.recommendAccessory) {\n recommendAccessory = uniqueProductData?.[0]?.recommendAccessory;\n }\n }\n }\n\n combineWithVasOptions(\n showPrice,\n uniqueProductData,\n content,\n pegaIntegration,\n productData?.productName,\n recommendAccessory\n );\n createCartCallAction(msisdn);\n } else if (\n enableTVStreamingOptionsPopUp &&\n uniqueProductData[0]?.isBundle &&\n !alreadyShowedTvOptionsPopUp\n ) {\n setDisplayTvOptionsPopUp(true);\n setAlreadyShowedTvOptionsPopUp(true);\n updateVasPopUp('true');\n\n window.addEventListener('beforeunload', function (event) {\n updateVasPopUp('false');\n sessionStorage.removeItem('vasPopUp');\n setAlreadyShowedTvOptionsPopUp(false);\n });\n } else {\n //for mobile p2p\n if (enableP2P) {\n setShowLoader(true);\n }\n createCartCallAction(msisdn);\n }\n };\n\n //cart creation callback For device first flow\n const deviceFirstFlowCreateCartCallback = (msisdn?: string) => {\n setShowProductDetail(false);\n const msisdnn = queryParams ?? msisdn;\n const deviceFirstFlowCartObj = {\n setShowLoader,\n cartEndPoint,\n giftItem,\n uniqueProductData,\n mainContent,\n showPrice,\n isMobileFlow,\n eligibleBundle,\n address,\n setShowLinecheck,\n showLinecheck,\n lineCheckCallBack,\n enableP2P,\n msisdnn,\n content,\n selectedRP,\n continueCart\n };\n deviceFlowCallBack(deviceFirstFlowCartObj);\n };\n\n // after 1 prepaid numbers selection from existingp2pmodal\n const onSelectSubscriptionPreToPost = (value: any) => {\n setP2pModal(!p2pModal);\n combine\n ? combineWithSmartPhone(\n showPrice,\n storyContent,\n uniqueProductData,\n value,\n content,\n pegaIntegration\n )\n : createCartCall(value?.msisdn);\n };\n //show price calculation\n const showPrice = fetchPrice(\n uniqueProductData,\n isMobileFlow,\n mainContent?.pageType,\n false,\n tvOptions,\n pegaIntegration\n );\n\n //card height calculation and gift & cashback check on change of offer data\n //to calculate the height when the tvOptions is added and removed\n useEffect(() => {\n setTimeout(() => {\n findHeight(tabIndex, cardsLength);\n }, 100);\n const result = checkGiftOrCashback(\n isMobileFlow\n ? uniqueProductData\n : (uniqueProductData?.[0]?.bundledOffers ?? uniqueProductData)\n );\n setShowGiftOrCashback({ ...result });\n }, [\n offeringData,\n toggleState,\n tvOptions,\n timerSpaceHeight,\n (toggleState?.TV || toggleState?.gigaSpeed || toggleState?.Netflix) &&\n Array.isArray(uniqueProductData) &&\n uniqueProductData?.[0]?.bundledOffers?.length === 3\n ]);\n\n //product details pop up\n const showDetailsModal = () => {\n setShowProductDetail(!showProductDetail);\n //Analytics Product Details tracking\n let offerData = uniqueProductData;\n trackNewDatalayerEvent(GAEVENT, DOWNLOADPRODUCT, getEcomCartInfo(offerData, '', LINETABLE));\n const prospectId = localStorage.getItem('prospectId');\n const url = window?.location?.pathname?.split('/') ?? [];\n const pathname = url[url.length - 1];\n const payload = {\n eventTimestamp: getUtcTimestamp(),\n eventType: 'PageView',\n pageType: 'ProductDetails',\n pageLocation: pathname,\n // deviceType: viewPortType, #TODO - fix this values, isn't working for tablet\n targetProduct: id\n };\n prospectId && trackPegaEvents(pegaEndpoint, payload, prospectId);\n };\n\n //TV service option\n const showModalPopup = () => {\n if (serviceOption?.length > 0 || enableTVStreamingOptionsPopUp) {\n setShowOptions(true);\n }\n };\n const updatedContent = mainContent?.productContainer?.[0];\n\n // set the combine to true for p2p\n const combineP2P = () => {\n setCombine(true);\n };\n\n // to trigger on click of combinewith smartphone\n useEffect(() => {\n if (combine) {\n if (enableP2P && AuthData == undefined) {\n setShowP2P(!showP2P);\n setModalClick(!popUPClick);\n } else if (enableP2P && AuthData?.siteId) {\n fetchPrepaidData();\n }\n }\n }, [combine]);\n\n useEffect(() => {\n if (context) {\n const { store } = context;\n if (store?.ottOptionsApi?.length > 0 && responseList?.length === 0) {\n setResponseList(store?.ottOptionsApi);\n }\n }\n }, [context]);\n\n useEffect(() => {\n if (!isCounterEnabled || !timerContent?.startTime || !timerContent?.endTime) {\n setTimerIsActive(false);\n return;\n }\n\n setTimerIsActive(isTimerActive(timerContent.startTime, timerContent.endTime));\n\n const delay = getTimeUntilNextTimerEvent(timerContent.startTime, timerContent.endTime);\n if (delay <= 0) return;\n\n const timeout = setTimeout(() => {\n setTimerIsActive(isTimerActive(timerContent.startTime, timerContent.endTime));\n }, delay);\n\n return () => clearTimeout(timeout);\n }, [isCounterEnabled, timerContent?.startTime, timerContent?.endTime]);\n\n useEffect(() => {\n const timerElement = timerContainerRef.current;\n if (!timerElement || !content?.timer?.length || !isCounterEnabled) {\n setTimerSpaceHeight(0);\n return;\n }\n\n const updateTimerSpaceHeight = () => {\n setTimerSpaceHeight(timerElement.clientHeight);\n };\n\n updateTimerSpaceHeight();\n\n if (typeof ResizeObserver === 'undefined') {\n return;\n }\n\n const resizeObserver = new ResizeObserver(updateTimerSpaceHeight);\n resizeObserver.observe(timerElement);\n\n return () => {\n resizeObserver.disconnect();\n };\n }, [content?.timer?.length, isCounterEnabled]);\n\n // to trigger on click tv option pop up closed\n useEffect(() => {\n if (tvOptionsPopUpChanged) {\n closeTVOptionsModal();\n setTvOptionsPopUpChanged(true);\n updateVasPopUp('false');\n sessionStorage.removeItem('vasPopUp');\n setAlreadyShowedTvOptionsPopUp(false);\n createCartCallAction();\n }\n }, [tvOptionsPopUpChanged]);\n\n //US 314008 - only show vas pop up for first time user clicked order now\n useEffect(() => {\n const checkVasPopUp = () => {\n const vasPopUp = sessionStorage.getItem('vasPopUp');\n\n setAlreadyShowedTvOptionsPopUp(vasPopUp === 'true');\n };\n\n checkVasPopUp();\n\n const handleStorageChange = (event: StorageEvent) => {\n if (event.storageArea === sessionStorage && event.key === 'vasPopUp') {\n checkVasPopUp();\n }\n // If vasPopUp is removed (deleted)\n if (\n event.storageArea === sessionStorage &&\n event.key === 'vasPopUp' &&\n event.newValue === null\n ) {\n setAlreadyShowedTvOptionsPopUp(false);\n }\n };\n\n const handleCustomEvent = () => {\n checkVasPopUp();\n };\n window.addEventListener('storage', handleStorageChange);\n window.addEventListener('vasPopUpChange', handleCustomEvent);\n \n return () => {\n window.removeEventListener('storage', handleStorageChange);\n window.removeEventListener('vasPopUpChange', handleCustomEvent);\n };\n \n }, []);\n\n const updateVasPopUp = (value: string) => {\n sessionStorage.setItem('vasPopUp', value);\n const event = new Event('vasPopUpChange');\n window.dispatchEvent(event);\n };\n\n return (\n <div>\n {showLoader &&\n portalPosition &&\n createPortal(<Dotloader keyParams='loading' />, portalPosition)}\n {isSkeletonLoading && (\n <div className='w-75 pb-2'>\n <SkeletonLoader />\n </div>\n )}\n {!isSkeletonLoading && eligibleBundle && content && address && !isMobileFlow && (\n <div className={Styles.selected}>\n <span style={{ paddingBottom: '10px' }}>\n {!isAvailable ? (\n <span className={Styles.inactiveicon}>\n <img\n src={`${assetPath}/icons/cross_disabled.svg`}\n alt=''\n width={24}\n height={24}\n className={Styles.inactiveicon}\n />\n <span>{constants?.notSubscriptionTxt}</span>\n </span>\n ) : (\n <span className={Styles.activeicon}>\n <img\n src={`${assetPath}/icons/lineCheck-success.svg`}\n alt=''\n width={24}\n height={24}\n className={Styles.activeicon}\n />\n <span>{constants?.subscriptionAvalTxt}</span>\n </span>\n )}\n </span>\n </div>\n )}\n\n <div\n className={`${\n !isMobileFlow &&\n isAvailable === false &&\n mainContent?.linecheckData?.length > 0 &&\n mainContent?.linecheckData?.[0]?.reference?.default_full_slug !== 'global/coverage-check'\n ? Styles.overlay\n : ''\n }\n ${deviceUltimateBundle && !uniqueProductData?.[0]?.eligibility?.fpb ? Styles.disabled : ''}\n `}\n style={{ flexDirection: 'column' }}\n >\n <div className={Styles.bundleproductcard}>\n <div\n id={`timer-section${tabIndex}${indexKey}`}\n data-timer-active={timerSpaceHeight > 0 ? 'true' : 'false'}\n >\n {content?.timer?.length && isCounterEnabled ? (\n <div style={{ height: `${timerSpaceHeight}px`, transition: 'height 0.3s ease' }} />\n ) : null}\n </div>\n <div\n className={`${Styles.productcontainer}`}\n style={getBorderStyles()}\n > \n {showBadges &&(\n <BadgeContainer badges={content.badgesContainer}/>\n )}\n {showHighlightText && (\n <div className={`${Styles.highlightText}`}>{content?.highlightText}</div>\n )}\n \n {showPromoContainer && (\n promotionData?.badgeContainer ? (\n <BadgeContainer badges={promotionData?.badgeContainer}/>\n ) : (\n <div\n className={`${Styles.promocontainer}`}\n style={{\n background: promotionData?.bestSellerColor\n }}\n >\n {promotionData?.displayText}\n </div>\n )\n )}\n <div ref={timerContainerRef} className={Styles.timerContainer}>\n {content?.timer?.length && isCounterEnabled ? (\n <StaticLineTabelTimer\n content={content?.timer?.[0]}\n hasHighlightText={ showBadges || showPromoContainer}\n onTimerChange={(active) => {\n setTimerIsActive(active);\n }}\n />\n ) : null}\n </div>\n <div\n className={`${Styles.detailsection} ${Styles.imageFullWidthSection}`}\n id={`detailsectionv3${tabIndex}${indexKey}`}\n >\n <div className={`${Styles.headersection}`}>\n <div className={`${Styles.titlesection}`}>\n <div className={`${Styles.productheader}`} id={`titleV3${tabIndex}${indexKey}`}>\n {productData?.productName}\n </div>\n <div>\n {productData?.icon?.filename && (\n <img\n className={`${Styles.imagecontainer}`}\n src={productData?.icon?.filename}\n height={15}\n width={20}\n alt='productIcon'\n />\n )}\n </div>\n </div>\n <div\n className={`${Styles.productdescription}`}\n id={`descriptionV3${tabIndex}${indexKey}`}\n >\n <RichText content={productData?.description} />\n </div>\n {/* Image(map) */}\n <div className={`${Styles.images}`}>\n {productData?.img?.filename && (\n <img\n className={`${Styles.imagespace} ${\n content?.highlightText && Styles.borderimage\n }`}\n alt='cardimg'\n src={`${productData?.img?.filename}/m/`}\n />\n )}\n </div>\n </div>\n {/* product entitlement section */}\n <div\n className={`${Styles.productconfig}`}\n id={`product-configv3${tabIndex}${indexKey}`}\n >\n {isSkeletonLoading ? (\n <>\n <div className={Styles.space}></div>\n <SkeletonLoader stylename={Styles.skeletontittle} count={1} />\n <SkeletonLoader stylename={Styles.skeletonline} count={5} />\n <div className={Styles.space}></div>\n <SkeletonLoader stylename={Styles.skeletontittle} count={1} />\n <SkeletonLoader stylename={Styles.skeletonline} count={5} />\n </>\n ) : (\n <div>\n {productData?.bloks &&\n productData?.bloks?.map((entitle: any, index: number) => {\n return (\n <StaticProductEntitlement\n content={entitle}\n indexKey={index}\n constants={constants}\n key={index}\n showModalPopup={showModalPopup}\n setToggleState={setToggleState}\n toggleState={toggleState}\n noTabs={noTabs}\n mainContent={mainContent}\n enableTVStreamingOptions={content?.enableTVStreamingOptions}\n metadata={metadata}\n setTvOptionsData={setTvOptionsData}\n />\n );\n })}\n </div>\n )}\n </div>\n </div>\n {/* benefits section */}\n <div\n className={`${Styles.detailsection}`}\n id={`benefits-price-section${tabIndex}${indexKey}`}\n >\n <div id={`exclusive-benefits-section${tabIndex}${indexKey}`}>\n {productData?.extraBenefits?.length > 0 && (\n <StaticExclusiveBenefit content={productData?.extraBenefits?.[0]} />\n )}\n </div>\n <div\n className={`${Styles.benefitssection}`}\n id={`benefits-section${tabIndex}${indexKey}`}\n >\n {productData?.benefits?.length > 0 && (\n <StaticBenefit\n content={productData?.benefits}\n benefitData={showPrice}\n constants={constants}\n //US_31295\n pricesToggleState={pricesToggleState}\n togglePriceLabel={toggleContent?.togglePriceLabel}\n />\n )}\n </div>\n <br />\n\n {/* gift or cashback section */}\n <div className={`${Styles.giftsection}`} id={`gift-section${tabIndex}${indexKey}`}>\n {showGiftOrCashback?.showGift &&\n promotionData?.singleGift?.map((item: any, index: number) => {\n return <GiftConfigV2 content={item} key={index} />;\n })}\n {showGiftOrCashback?.showGift &&\n promotionData?.giftConfig?.map((item: any, index: number) => {\n return (\n <ChooseGiftV2\n content={item}\n key={index}\n selectedGiftItem={selectedGiftItem}\n parentPoType={isMobileFlow ? 'MOBILE' : 'HOME'}\n />\n );\n })}\n <div\n className={`${Styles.giftsection}`}\n id={`cashback-section${tabIndex}${indexKey}`}\n >\n <StaticProductCashback\n uniqueProductData={uniqueProductData}\n mainContent={mainContent}\n />\n </div>\n </div>\n {/* price section */}\n <div className={`${Styles.ordersection}`} id={`order-section${tabIndex}${indexKey}`}>\n {showPrice?.base === '' ? (\n <div>\n <SkeletonLoader stylename={Styles.skeletontittle} />\n </div>\n ) : (\n <div id={`price-section${tabIndex}${indexKey}`}>\n <DynamicPriceSection\n priceCollection={showPrice}\n constants={constants}\n promoText={productData?.promoText}\n deviceFlow={deviceFlow}\n content={content}\n offeringData={offeringData}\n uniqueId={uniqueId}\n />\n </div>\n )}\n\n {/* US_312953 */}\n {!isShogunFlow && (\n <div\n className={`${Styles.discountedpricetoggleSection}`}\n id={`discountedpricetoggle-section${tabIndex}${indexKey}`}\n >\n {!disableDiscountedPriceToggle && toggleContent?.togglePosition === 'INLINE' ? (\n <UserLoggedPricesToggle\n content={productData}\n index={indexKey}\n lineTable={true}\n toggleContent={toggleContent}\n />\n ) : null}\n </div>\n )}\n {/*END US_312953 */}\n\n {/* Longterm text */}\n {enableP2P && constants?.P2PDiscountLabel && (\n <div className={Styles.longterm}>{constants?.P2PDiscountLabel}</div>\n )}\n {/* proceed to checkout section */}\n {isSkeletonLoading ? (\n <>\n <SkeletonLoader stylename={Styles.skeletontittle} count={1} />\n <SkeletonLoader stylename={Styles.skeletonline} count={2} />\n </>\n ) : (\n <div className={`${storyContent?.swapButton && Styles.swapButton}`}>\n <div style={{ padding: '16px 0 0 0' }}>\n <CheckoutButton\n isMobileFlow={isMobileFlow}\n createCartCall={\n deviceFlow?.isDeviceFlow\n ? deviceFirstFlowCreateCartCallback\n : isMobileFlow\n ? createCart\n : createCartCall\n }\n constants={constants}\n storyContent={storyContent}\n showPrice={showPrice}\n isAvailable={isAvailable}\n address={address}\n uniqueProductBenefits={uniqueProductData?.[0]}\n alwaysActive={\n !isAvailable &&\n mainContent?.linecheckData?.length > 0 &&\n mainContent?.linecheckData?.[0]?.reference?.default_full_slug ===\n 'global/coverage-check'\n }\n flexUpgradeFreePopup={mainContent?.flexUpgradeFreePopup?.reference?.content}\n content={content}\n deviceUltimateBundle={deviceUltimateBundle}\n forceDisabled={Boolean(uniqueProductData?.[0]?.rewards?.notEligibleReason)}\n notEligibileReason={uniqueProductData?.[0]?.rewards?.notEligibleReason}\n />\n </div>\n {/* combined with smartphone section */}\n {!isShogunFlow && storyContent?.addSmartPhone?.length > 0 && !deviceFlow?.isDeviceFlow && (\n <div style={{ textAlign: 'center' }}>\n {storyContent?.swapButton\n ? storyContent?.ctaLabel && (\n <div style={{ padding: '16px 0' }}>\n <button\n className={`primarybutton`}\n onClick={() =>\n combineWithSmartPhone(\n showPrice,\n storyContent,\n uniqueProductData,\n '',\n content,\n pegaIntegration\n )\n }\n >\n <span className={Styles.buttontext}>\n {storyContent?.ctaLabel}\n </span>\n </button>\n </div>\n )\n : !content?.redirectOnly && (\n <div style={{ padding: '12px 0 0 0' }}>\n <FalconButtonV2\n content={{\n buttonType: 'Secondary-V1',\n buttonLabel: content?.ultimateBundlePromotion\n ? constants?.ultimateBundleLbl\n : storyContent?.addSmartPhone?.[0]?.buttonLabel,\n buttonIcon: storyContent?.addSmartPhone?.[0]?.buttonIcon,\n buttonAlignment: 'left'\n }}\n wafIdentifier={basicConfigUrl}\n style={{ width: '100%' }}\n onClick={() =>\n enableP2P\n ? combineP2P()\n : combineWithSmartPhone(\n showPrice,\n storyContent,\n uniqueProductData,\n '',\n content,\n pegaIntegration\n )\n }\n />\n </div>\n )}\n </div>\n )}\n <div\n className={Styles.productcontractduration}\n id={`contract-section${tabIndex}${indexKey}`}\n style={{\n paddingTop:\n storyContent?.addSmartPhone?.length > 0 &&\n !deviceFlow?.isDeviceFlow &&\n !storyContent?.swapButton &&\n !content?.redirectOnly\n ? '8px'\n : undefined\n }}\n >\n {showPrice?.contractDuration > '1'\n ? replacePlaceholder(constants?.minContractDuration?.substring(1), [\n showPrice?.contractDuration\n ])\n : constants?.noContractDuration}\n </div>\n </div>\n )}\n {/* product details section */}\n <div style={{ textAlign: 'center', padding: '4px' }}>\n {productData?.productDetails?.length > 0 && (\n <span className={Styles.productdetailslink} onClick={showDetailsModal}>\n {constants?.productDetailsLink}\n </span>\n )}\n </div>\n {showProductDetail && (\n <StaticProductDetails\n content={productData?.productDetails}\n showProductDetail={showProductDetail}\n setShowProductDetail={setShowProductDetail}\n constants={constants}\n showPrice={showPrice}\n isMobileFlow={isMobileFlow}\n createCartCall={isMobileFlow ? createCart : createCartCall}\n storyContent={storyContent}\n isAvailable={isAvailable}\n address={address}\n flexUpgradeFreePopup={mainContent?.flexUpgradeFreePopup?.reference?.content}\n notEligibileReason={uniqueProductData?.[0]?.rewards?.notEligibleReason}\n />\n )}\n </div>\n </div>\n </div>\n </div>\n </div>\n\n {deviceUltimateBundle && uniqueProductData && !uniqueProductData?.[0]?.eligibility?.fpb && (\n <div className={Styles.disabledInfo}>\n <RichText content={constants?.fpbNotCompatibleText} />\n </div>\n )}\n\n {showOptions &&\n (isSkeletonLoading ? (\n <SkeletonLoader />\n ) : (\n <TVChannelModal\n content={serviceOption?.[0]}\n setShowModal={setShowOptions}\n showModal={showOptions}\n constants={constants}\n />\n ))}\n\n {/* login pop up existing customer benefit without login on click of proceed to checkout */}\n {showLogin &&\n mainContent?.loginData?.length > 0 &&\n portalPosition &&\n createPortal(\n <LoginModalV2\n content={mainContent?.loginData?.[0]}\n closeLogin={() => {\n setShowLogin(false);\n }}\n metadata={metadata}\n onSuccess={onLoginSuccess}\n isProdEnv={isProdEnv}\n />,\n portalPosition\n )}\n\n {/* P2P flow first screen to select login */}\n {showP2P && enableP2P && !showLogin && popUPClick && (\n <GenericModal\n modalState={modalClick}\n handler={handleClick}\n showFooter={false}\n width={'628px'}\n height='280px'\n backgroundColor='#f7f6f5'\n noCloseButton={false}\n backDrop={true}\n bodyPadding='16px'\n >\n <PreToPostSubsPopup\n onClose={handleP2PClick}\n content={mainContent?.productContainer?.[0]?.p2pBloks?.[0]}\n prepaid={false}\n />\n </GenericModal>\n )}\n\n {/* P2P flow error screen if the customer is not prepaid customer */}\n {enableP2P && afterLogin && subscriptionFailure && popUPClick && (\n <GenericModal\n modalState={modalClick}\n handler={handleClick}\n showFooter={false}\n width={'628px'}\n height='280px'\n backgroundColor='#f7f6f5'\n noCloseButton={false}\n backDrop={true}\n bodyPadding='16px'\n id='table-product'\n >\n <PreToPostSubsPopup\n onClose={handleP2PClick}\n content={mainContent?.productContainer?.[0]?.p2pBloks?.[1]}\n prepaid={true}\n />\n </GenericModal>\n )}\n\n {/* p2p flow after successfully logged in prepaid customer to select a number for P2P*/}\n {userSubscriptionData?.length > 1 &&\n enableP2P &&\n afterLogin &&\n !subscriptionFailure &&\n p2pModal && (\n <GenericModal\n modalState={p2pModal}\n handler={handlePrepaidClick}\n showFooter={false}\n width={'628px'}\n height='280px'\n backgroundColor='#f7f6f5'\n noCloseButton={false}\n backDrop={true}\n bodyPadding='16px'\n >\n <ExsistingSubscriptionModal\n onSubmit={onSelectSubscriptionPreToPost}\n exsistingSubscriptionData={userSubscriptionData}\n updatedContent={updatedContent}\n />\n </GenericModal>\n )}\n\n {/* lincheck modal */}\n {showLinecheck &&\n mainContent?.enableLinecheckOverlay &&\n !isMobileFlow &&\n mainContent?.linecheckData?.length > 0 &&\n !enableP2P &&\n mainContent?.linecheckData?.[0]?.reference?.default_full_slug ===\n 'global/new-linecheck-test' ? (\n <LinecheckModal\n content={mainContent?.linecheckData?.[0]}\n onSuccess={linecheckSuccessAndCart}\n showModal={showLinecheck}\n setShowModal={setShowLinecheck}\n productName={productData?.productName}\n productId={productData?.productId}\n />\n ) : showLinecheck &&\n mainContent?.enableLinecheckOverlay &&\n !isMobileFlow &&\n mainContent?.linecheckData?.length > 0 &&\n !enableP2P &&\n mainContent?.linecheckData?.[0]?.reference?.default_full_slug ===\n 'global/coverage-check' ? (\n <CoverageCheckModal\n content={mainContent?.linecheckData?.[0].reference.content.body[0]}\n overlayIsOpen={true}\n externalHandleModal={setShowLinecheck}\n productName={productData?.productName}\n showModal={showLinecheck}\n setShowModal={setShowLinecheck}\n onSuccess={linecheckSuccess}\n onCreateCart={linecheckSuccessAndCart}\n lineCheckOnClear={lineCheckOnClear}\n productId={productData?.productId}\n />\n ) : null}\n {/* benefit validate */}\n {showBenefit && isMobileFlow && storyContent?.benefitsValidate?.length > 0 && (\n <BenefitsValidateWrapper\n content={storyContent?.benefitsValidate?.[0]}\n loginContent={mainContent?.loginData?.[0]}\n metadata={metadata}\n createCartCall={createCartCall}\n fetchOfferData={fetchOfferData}\n basicConfigUrl={basicConfigUrl}\n selectedExistingOption={selectedExistingOption}\n setShowBenefit={setShowBenefit}\n setLoginSuccess={setLoginSuccess}\n isProdEnv={isProdEnv}\n />\n )}\n\n {/* Display tv options on pop up after clicking order now button*/}\n {displayTvOptionsPopUp && (\n <GenericModal\n modalState={displayTvOptionsPopUp}\n handler={closeTVOptionsModal}\n showFooter={false}\n width={viewPortType === 'mobile' ? '' : viewPortType === 'tablet' ? '700px' : '990px'}\n fixedWidth={\n viewPortType === 'mobile' ? '' : viewPortType === 'tablet' ? '700px' : '990px'\n }\n height='845px'\n backgroundColor='#f7f6f5'\n noCloseButton={false}\n backDrop={true}\n bodyPadding='24px'\n >\n <OttServiceOptionsSmallPopup\n content={mainContent?.optionsPopup?.[0]}\n addOptionsCallBack={(val: any) => {\n setTvOptionsPopUpAddToCart(true);\n setTvOptionsPopUpChanged(true);\n setTvOptionsData(val);\n }}\n metadata={metadata}\n constants={constants}\n mainContent={mainContent}\n preSelectedOptions={[]}\n optionsResponse={responseList}\n updateResponseList={setResponseList}\n showPrice={showPrice}\n productData={productData}\n offeringData={offeringData}\n uniqueId={uniqueId}\n deviceFlow={deviceFlow}\n />\n </GenericModal>\n )}\n </div>\n );\n};\n\nexport default StaticProduct;\n"],"names":["StaticProduct","content","offeringData","uniqueId","storyContent","metadata","tabIndex","cardsLength","indexKey","constants","mainContent","address","eligibleBundle","linecheckSuccessCallBack","selectedOption","fetchOfferData","basicConfigUrl","selectedExistingOption","setLoginSuccess","enableP2P","lineCheckCallBack","loginSuccess","setToggleState","toggleState","noTabs","deviceFlow","deviceFlowCallBack","selectedRP","continueCart","lineCheckOnClear","pegaIntegration","isProdEnv","deviceUltimateBundle","toggleContent","pricesToggleState","isShogunFlow","shogunToken","showLoader","setShowLoader","useState","showProductDetail","setShowProductDetail","showGiftOrCashback","setShowGiftOrCashback","showGift","cashbackAvailable","modalClick","updateModalClick","combine","setCombine","giftItem","setGiftItem","showLogin","setShowLogin","showOptions","setShowOptions","showLinecheck","setShowLinecheck","showP2P","setShowP2P","showBenefit","setShowBenefit","subscriptionFailure","setSubscriptionFailure","endpoint","validateEndpoint","userSubscriptionData","setUserSubscriptionData","afterLogin","setAfterLogin","popUPClick","setModalClick","p2pModal","setP2pModal","tvOptions","setTvOptions","displayTvOptionsPopUp","setDisplayTvOptionsPopUp","alreadyShowedTvOptionsPopUp","setAlreadyShowedTvOptionsPopUp","tvOptionsPopUpChanged","setTvOptionsPopUpChanged","tvOptionsPopUpAddToCart","setTvOptionsPopUpAddToCart","responseList","setResponseList","timerSpaceHeight","setTimerSpaceHeight","timerContainerRef","useRef","pegaEndpoint","API_BASE_BASEPOINT","CUSTOMER","portalPosition","undefined","window","document","getElementById","isSkeletonLoading","_a","Object","keys","length","productData","_f","_e","_d","_c","_b","products","reference","product","promotionData","_l","_k","_j","_h","_g","promotion","promoDescription","timerContent","_m","timer","isCounterEnabled","enableCounter","timerIsActive","setTimerIsActive","startTime","endTime","isTimerActive","showHighlightText","Boolean","highlightText","badgesContainer","showPromoContainer","displayText","notShowPromotionLabel","showBadges","id","productId","cartEndPoint","_o","LineTableBasicPropConfig","getInstance","getCartUrl","assetPath","_p","AssetPathPropConfig","getAssetPath","isMobileFlow","pageType","viewPortType","viewport","context","useContext","AppContext","isAvailable","_q","includes","enableTVStreamingOptionsPopUp","enableTVStreamingOptionsStepper","disableDiscountedPriceToggle","skipAccessoriesPage","LoginBasicPropConfig","create","baseURL","AuthData","Cookies","get","JSON","parse","uniqueProductData","filter","setTvOptionsData","options","handleP2PClick","createCart","siteId","fetchPrepaidData","EXISTINGCUSTOMER","enableExistingCustomer","enableLoggedInPrice","createCartCall","prospectId","localStorage","getItem","url","location","pathname","split","payload","eventTimestamp","getUtcTimestamp","eventType","pageLocation","targetProduct","trackPegaEvents","selectedGiftItem","item","itemValue","findIndex","gift","giftGroupId","temp","push","params","URLSearchParams","_r","search","queryParams","validateNumberFcn","value","combineWithSmartPhone","showPrice","msisdn","validateFcn","validPrepaidNumbers","__awaiter","validateP2P","then","res","catch","e","console","log","fetchSubscriptionData","resp","subscriptionData","responseData","queryData","find","entry","Promise","all","map","data","succ","error","err","handleClick","closeTVOptionsModal","event","trackNewDatalayerEvent","GAEVENT","CTABUTTONCLICK","headline","linecheckSuccessAndCart","bundle","serviceOption","fetchServiceOptions","bloks","radioValue","_s","tvProductId","createCartCallAction","discountRef","promotionInfo","discountVersion","version","rewardsInfo","pointsBurnt","rewards","points","rewardOfferId","offerId","gloxTokenId","fromPopup","updateVasPopUp","sessionStorage","removeItem","staticCreateCart","AuthDataNew","setLoginCookie","ONE_ECOMMERCE_INTERNET_SUMMARY","linecheckData","loginData","isBundle","recommendAccessory","bundledOffers","productType","toLowerCase","combineWithVasOptions","productName","addEventListener","fetchPrice","useEffect","setTimeout","findHeight","result","checkGiftOrCashback","assign","TV","gigaSpeed","Netflix","Array","isArray","_u","_t","showModalPopup","updatedContent","_v","productContainer","store","ottOptionsApi","delay","getTimeUntilNextTimerEvent","timeout","clearTimeout","timerElement","current","updateTimerSpaceHeight","clientHeight","ResizeObserver","resizeObserver","observe","disconnect","_w","checkVasPopUp","vasPopUp","handleStorageChange","storageArea","key","newValue","handleCustomEvent","removeEventListener","setItem","Event","dispatchEvent","React","createElement","createPortal","Dotloader","keyParams","className","SkeletonLoader","Styles","selected","style","paddingBottom","activeicon","src","alt","width","height","subscriptionAvalTxt","inactiveicon","notSubscriptionTxt","_x","_z","_y","_0","default_full_slug","overlay","_2","_1","eligibility","fpb","disabled","flexDirection","bundleproductcard","_3","transition","productcontainer","borderConfig","showBorder","borderGradient","borderColor","borderWidth","borderStyle","borderRadius","background","getBorderStyles","BadgeContainer","badges","badgeContainer","promocontainer","bestSellerColor","ref","timerContainer","_4","StaticLineTabelTimer","_5","hasHighlightText","onTimerChange","active","detailsection","imageFullWidthSection","headersection","titlesection","productheader","icon","_6","filename","imagecontainer","_7","productdescription","RichText","description","images","_8","img","imagespace","borderimage","_9","productconfig","Fragment","space","stylename","skeletontittle","count","skeletonline","_10","entitle","index","StaticProductEntitlement","enableTVStreamingOptions","_11","extraBenefits","StaticExclusiveBenefit","_12","benefitssection","_13","benefits","StaticBenefit","benefitData","togglePriceLabel","giftsection","_14","singleGift","GiftConfigV2","_15","giftConfig","ChooseGiftV2","parentPoType","StaticProductCashback","ordersection","base","DynamicPriceSection","priceCollection","promoText","discountedpricetoggleSection","togglePosition","UserLoggedPricesToggle","lineTable","P2PDiscountLabel","longterm","swapButton","padding","CheckoutButton","isDeviceFlow","msisdnn","uniqueProductBenefits","alwaysActive","_16","_18","_17","flexUpgradeFreePopup","_21","_20","forceDisabled","_23","_22","notEligibleReason","notEligibileReason","_25","_24","_26","addSmartPhone","textAlign","ctaLabel","onClick","buttontext","redirectOnly","FalconButtonV2","buttonType","buttonLabel","ultimateBundlePromotion","ultimateBundleLbl","_28","_27","buttonIcon","_30","_29","buttonAlignment","wafIdentifier","productcontractduration","paddingTop","_31","contractDuration","replacePlaceholder","_32","minContractDuration","substring","noContractDuration","productDetails","_33","productdetailslink","DOWNLOADPRODUCT","getEcomCartInfo","LINETABLE","productDetailsLink","StaticProductDetails","_35","_34","_37","_36","_39","_38","disabledInfo","fpbNotCompatibleText","TVChannelModal","setShowModal","showModal","_40","LoginModalV2","_41","closeLogin","onSuccess","GenericModal","modalState","handler","showFooter","backgroundColor","noCloseButton","backDrop","bodyPadding","PreToPostSubsPopup","onClose","_44","_43","_42","p2pBloks","prepaid","_47","_46","_45","ExsistingSubscriptionModal","onSubmit","exsistingSubscriptionData","enableLinecheckOverlay","_48","_50","_49","LinecheckModal","_52","_53","_55","_54","CoverageCheckModal","_57","body","overlayIsOpen","externalHandleModal","onCreateCart","_58","benefitsValidate","BenefitsValidateWrapper","_59","loginContent","_60","fixedWidth","OttServiceOptionsSmallPopup","optionsPopup","_61","addOptionsCallBack","val","preSelectedOptions","optionsResponse","updateResponseList"],"mappings":"8hFAmEA,MAAMA,GAAy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kBA,GAClB8G,UAAWpC,cAAW,EAAXA,GAAaoC,YAExB,KAEH/E,IAAeyF,KAA8C,QAA9BqZ,GAAAtiB,cAAY,EAAZA,GAAcuiB,wBAAgB,IAAAD,QAAA,EAAAA,GAAEpc,QAAS,GACvEkO,EAAAC,cAACmO,EAAuB,CACtB3iB,gBAAS4iB,GAAAziB,cAAY,EAAZA,GAAcuiB,yCAAmB,GAC1CG,aAAoC,WAAtBpiB,cAAW,EAAXA,GAAayQ,iBAAS,IAAA4R,QAAA,EAAAA,GAAG,GACvC1iB,SAAUA,GACViL,eAAgBA,GAChBvK,eAAgBA,GAChBC,eAAgBA,GAChBC,uBAAwBA,GACxB4C,eAAgBA,GAChB3C,gBAAiBA,GACjBa,UAAWA,KAKd6C,IACC4P,EAAAC,cAAC6L,EAAY,CACXC,WAAY3b,GACZ4b,QAASxR,GACTyR,YAAY,EACZnL,MAAwB,WAAjB/L,GAA4B,GAAsB,WAAjBA,GAA4B,QAAU,QAC9EyZ,WACmB,WAAjBzZ,GAA4B,GAAsB,WAAjBA,GAA4B,QAAU,QAEzEgM,OAAO,QACPmL,gBAAgB,UAChBC,eAAe,EACfC,UAAU,EACVC,YAAY,QAEZrM,EAAAC,cAACwO,IACChjB,QAAkC,WAAzBS,cAAW,EAAXA,GAAawiB,oBAAY,IAAAC,QAAA,EAAAA,GAAG,GACrCC,mBAAqBC,IACnBle,IAA2B,GAC3BF,IAAyB,GACzB4F,GAAiBwY,IAEnBhjB,SAAUA,GACVI,UAAWA,GACXC,YAAaA,GACb4iB,mBAAoB,GACpBC,gBAAiBne,GACjBoe,mBAAoBne,GACpBgI,UAAWA,GACX9G,YAAaA,GACbrG,aAAcA,GACdC,SAAUA,GACVsB,WAAYA"}
1
+ {"version":3,"file":"StaticProduct.js","sources":["../../../../src/components/StaticLineTable/StaticProduct.tsx"],"sourcesContent":["import React, { FC, useContext, useEffect, useRef, useState } from 'react';\nimport Dotloader from '../Dotloader/Dotloader';\nimport { createPortal } from 'react-dom';\nimport SkeletonLoader from '../SkeletonLoader/SkeletonLoader';\nimport Styles from './StaticLineTable.module.scss';\nimport RichText from '../richtext';\nimport StaticProductEntitlement from './StaticProductEntitlement';\nimport StaticBenefit from './StaticBenefit';\nimport DynamicPriceSection from './DynamicPriceSection';\nimport CheckoutButton from './CheckoutButton';\nimport StaticProductDetails from './StaticProductDetails';\nimport { StaticProductSchema } from './StaticProductDatatypes';\nimport {\n AssetPathPropConfig,\n LineTableBasicPropConfig\n} from '../../services/LineTableBasicPropConfig';\nimport Cookies from 'js-cookie';\nimport { LoginBasicPropConfig } from '../../services/LoginBasicPropConfig';\nimport LoginModalV2 from '../login/LoginModalV2';\nimport {\n checkGiftOrCashback,\n combineWithSmartPhone,\n combineWithVasOptions,\n fetchPrice,\n fetchServiceOptions,\n findHeight,\n isTimerActive,\n getTimeUntilNextTimerEvent,\n staticCreateCart\n} from './Product.utils';\nimport GiftConfigV2 from '../ProductDetailsV3/GiftConfigV2';\nimport ChooseGiftV2 from '../ProductDetailsV3/ChooseGiftV2';\nimport { replacePlaceholder, viewport, getUtcTimestamp } from '../../utils/utils';\nimport StaticProductCashback from './StaticProductCashback';\nimport { trackNewDatalayerEvent } from '../../utils/AnalyticsUtils';\nimport {\n CTABUTTONCLICK,\n DOWNLOADPRODUCT,\n EXISTINGCUSTOMER,\n GAEVENT,\n LINETABLE\n} from '../../Analytics/AnalyticsConstants';\nimport TVChannelModal from './TVChannelModal';\nimport LinecheckModal from '../LineCheckV3/LinecheckModal';\nimport BenefitsValidateWrapper from '../BenefitWrapper/BenefitsValidateWrapper';\nimport PreToPostSubsPopup from '../PretoPost/PreToPostSubsPopup';\nimport GenericModal from '../LineCheckV3/GenericModal';\nimport {\n fetchSubscriptionData,\n trackPegaEvents,\n validateP2P\n} from '../../services/LineTableService';\nimport ExsistingSubscriptionModal from './ExsistingSubscriptionModal';\nimport { getEcomCartInfo } from '../../models/Analytics/items';\nimport CoverageCheckModal from '../NewLineCheck/CoverageCheckModal';\n\nimport { API_BASE_BASEPOINT } from '../../services/api-constants';\nimport { AppContext } from './StaticLineTableStore/StaticLineTableProvider';\nimport OttServiceOptionsSmallPopup from './OttServiceOptions/OttServiceOptionsSmallPopup';\nimport StaticExclusiveBenefit from './StaticExclusiveBenefit';\n// US_312953\nimport UserLoggedPricesToggle from '../UserLoggedPricesToggle/UserLoggedPricesToggle';\nimport FalconButtonV2 from '../FalconButtonV2/FalconButtonV2';\nimport { ONE_ECOMMERCE_INTERNET_SUMMARY } from '../../utils/constants';\nimport StaticLineTabelTimer from './StaticLineTabelTimer/StaticLineTabelTimer';\nimport { BadgeContainer } from '@sunrise-upc/sales-static-components';\nimport GenericPopup from '../GenericPopup/GenericPopup';\n\nconst StaticProduct: FC<StaticProductSchema> = ({\n content,\n offeringData,\n uniqueId,\n storyContent,\n metadata,\n tabIndex,\n cardsLength,\n indexKey,\n constants,\n mainContent,\n address,\n eligibleBundle,\n linecheckSuccessCallBack,\n selectedOption,\n fetchOfferData,\n basicConfigUrl,\n selectedExistingOption,\n setLoginSuccess,\n enableP2P,\n lineCheckCallBack,\n loginSuccess,\n setToggleState,\n toggleState,\n noTabs,\n deviceFlow,\n deviceFlowCallBack,\n selectedRP,\n continueCart,\n lineCheckOnClear,\n pegaIntegration,\n isProdEnv,\n deviceUltimateBundle,\n //US_31295\n toggleContent,\n pricesToggleState,\n isShogunFlow,\n shogunToken\n}) => {\n const [showLoader, setShowLoader] = useState<boolean>(false);\n const [showProductDetail, setShowProductDetail] = useState(false);\n const [showGiftOrCashback, setShowGiftOrCashback] = useState({\n showGift: false,\n cashbackAvailable: false\n });\n const [modalClick, updateModalClick] = useState(true);\n const [combine, setCombine] = useState(false);\n const [giftItem, setGiftItem] = useState<any>([]);\n const [showLogin, setShowLogin] = useState<boolean>(false);\n const [showOptions, setShowOptions] = useState<boolean>(false);\n const [showLinecheck, setShowLinecheck] = useState<boolean>(false);\n const [showP2P, setShowP2P] = useState<boolean>(false);\n const [showBenefit, setShowBenefit] = useState<boolean>(false);\n const [subscriptionFailure, setSubscriptionFailure] = useState(false);\n const endpoint = `${basicConfigUrl}inf/customer-management/subscriptions`;\n const validateEndpoint = `${basicConfigUrl}inf/resource-management/msisdns/pretopost/validation`;\n const [userSubscriptionData, setUserSubscriptionData] = useState<any>([]);\n const [afterLogin, setAfterLogin] = useState<boolean>(false);\n const [popUPClick, setModalClick] = useState<boolean>(false);\n const [p2pModal, setP2pModal] = useState<boolean>(false);\n const [tvOptions, setTvOptions] = useState<any[] | undefined>([]);\n const [displayTvOptionsPopUp, setDisplayTvOptionsPopUp] = useState<boolean>(false);\n const [alreadyShowedTvOptionsPopUp, setAlreadyShowedTvOptionsPopUp] = useState<boolean>(false);\n const [tvOptionsPopUpChanged, setTvOptionsPopUpChanged] = useState<boolean>(false);\n const [tvOptionsPopUpAddToCart, setTvOptionsPopUpAddToCart] = useState<boolean>(false);\n const [responseList, setResponseList] = useState([]);\n const [timerSpaceHeight, setTimerSpaceHeight] = useState(0);\n const [showReplaceCartModal, setShowReplaceCartModal] = useState<boolean>(false);\n const pendingCartActionRef = useRef<(() => void) | null>(null);\n const [replacePopupContent, setReplacePopupContent] = useState<any>(null);\n const shouldDeleteCartCookieRef = useRef<boolean>(false);\n const timerContainerRef = useRef<HTMLDivElement | null>(null);\n const pegaEndpoint = `${basicConfigUrl}inf/${API_BASE_BASEPOINT.CUSTOMER}`;\n\n /*the portal position for the the dotloader*/\n const portalPosition: any =\n typeof window !== undefined && document.getElementById('static-linetable');\n const isSkeletonLoading = Object.keys(content)?.length === 0;\n const productData = content?.products?.[0]?.reference?.content?.product?.[0];\n const promotionData = content?.promotion?.[0]?.reference?.content?.promoDescription?.[0];\n const timerContent = content?.timer?.[0];\n const isCounterEnabled = timerContent?.enableCounter;\n const [timerIsActive, setTimerIsActive] = useState(\n isCounterEnabled && timerContent?.startTime && timerContent?.endTime\n ? isTimerActive(timerContent.startTime, timerContent.endTime)\n : false\n );\n const showHighlightText = Boolean(\n content?.highlightText && pricesToggleState !== true && !timerIsActive && !content?.badgesContainer\n );\n const showPromoContainer = Boolean(\n promotionData?.displayText &&\n !content?.notShowPromotionLabel &&\n pricesToggleState !== true &&\n !timerIsActive\n );\n\n const showBadges = Boolean(\n content?.badgesContainer && pricesToggleState !== true && !timerIsActive && !showPromoContainer\n );\n\n const id = productData?.productId;\n const cartEndPoint = LineTableBasicPropConfig?.getInstance()?.getCartUrl();\n const assetPath = AssetPathPropConfig?.getInstance()?.getAssetPath();\n const isMobileFlow = storyContent?.pageType === 'MOBILE';\n const viewPortType = viewport();\n const context = useContext(AppContext);\n let isAvailable: boolean | undefined = undefined;\n isAvailable = address && eligibleBundle?.eligibleBundle?.includes(id);\n const enableTVStreamingOptionsPopUp = content?.enableTVStreamingOptionsPopUp;\n const enableTVStreamingOptionsStepper = content?.enableTVStreamingOptionsStepper;\n const disableDiscountedPriceToggle = content?.disableDiscountedPriceToggle;\n const skipAccessoriesPage = content?.skipAccessoriesPage;\n\n LoginBasicPropConfig.create({ baseURL: basicConfigUrl ?? '' });\n\n //sunrise auth data\n let AuthData: any = typeof window !== undefined && Cookies.get('sunriseAuth');\n AuthData = AuthData && JSON.parse(AuthData);\n //offer data wrt to tab\n const uniqueProductData: any = (offeringData?.[uniqueId] || []).filter(\n (product: any) => product?.id === id\n );\n\n const setTvOptionsData = (options: any) => {\n setTvOptions(options);\n };\n\n const handleP2PClick = () => {\n setShowLogin(true);\n setShowP2P(!showP2P);\n setModalClick(!popUPClick);\n };\n\n //creacart function or login pop up\n const createCart = () => {\n setShowProductDetail(false);\n if (enableP2P && AuthData == undefined) {\n setShowP2P(!showP2P);\n setModalClick(!popUPClick);\n } else if (enableP2P && AuthData?.siteId) {\n fetchPrepaidData();\n } else if (selectedOption === EXISTINGCUSTOMER && selectedExistingOption?.length > 0) {\n setShowBenefit(true);\n } else {\n //US_31295\n const setLoginCookie =\n (mainContent?.enableExistingCustomer && AuthData == undefined) ||\n (!AuthData && pricesToggleState === true && toggleContent?.enableLoggedInPrice)\n ? true\n : false;\n setLoginCookie ? setShowLogin(true) : createCartCall();\n }\n if (pegaIntegration) {\n const prospectId = localStorage.getItem('prospectId');\n const url = window?.location?.pathname?.split('/') ?? [];\n const pathname = url[url.length - 1];\n const payload = {\n eventTimestamp: getUtcTimestamp(),\n eventType: 'PageView',\n pageType: 'CartCreated',\n pageLocation: pathname,\n // deviceType: viewPortType,#TODO - fix this values, isn't working for tablet\n targetProduct: id\n };\n prospectId && trackPegaEvents(pegaEndpoint, payload, prospectId);\n }\n };\n\n //setting the selected gift from choose gift section\n const selectedGiftItem = (item: any) => {\n const itemValue = giftItem.findIndex((gift: any) => item?.giftGroupId === gift?.giftGroupId);\n const temp = giftItem;\n if (itemValue === -1) temp.push(item);\n else temp[itemValue] = item;\n setGiftItem([...temp]);\n };\n\n // Helper method to get border styles\n const getBorderStyles = () => {\n const borderConfig = showPromoContainer ? promotionData : content;\n const showBorder = borderConfig?.showBorder;\n const borderGradient = borderConfig?.borderGradient;\n const borderColor = borderConfig?.borderColor;\n\n return {\n borderColor: showBorder && !borderGradient ? borderColor || '' : 'transparent',\n borderWidth: showBorder ? '4px' : '0px',\n borderStyle: showBorder ? 'solid' : 'none',\n borderRadius: showBorder ? '8px' : '',\n background: showBorder && borderGradient\n ? `linear-gradient(white, white) padding-box, ${borderGradient} border-box`\n : undefined,\n };\n };\n\n //queryParam for MySunrise P2P flow\n const params = new URLSearchParams(window?.location?.search);\n const queryParams = params?.get('selectedMsisdn');\n const validateNumberFcn = (value: any) => {\n // once all the prepaid numbers are validated\n if (value?.length === 1) {\n combine\n ? combineWithSmartPhone(\n showPrice,\n storyContent,\n uniqueProductData,\n value?.[0],\n content,\n pegaIntegration\n )\n : createCartCall(value?.[0]?.msisdn);\n setSubscriptionFailure(false);\n } else if (value?.length > 1) {\n setUserSubscriptionData(value);\n setP2pModal(!p2pModal);\n setSubscriptionFailure(false);\n } else {\n setModalClick(!popUPClick);\n setSubscriptionFailure(true);\n updateModalClick(true);\n setShowLoader(false);\n }\n };\n const validateFcn = async (value: any, validPrepaidNumbers: any) => {\n await validateP2P(value?.msisdn, validateEndpoint)\n .then((res) => {\n if (res) {\n validPrepaidNumbers.push(value);\n }\n })\n .catch((e: any) => {\n // eslint-disable-next-line no-console\n console.log('error', e);\n });\n };\n //prepaid subscription api and validating those for conversion\n const fetchPrepaidData = () => {\n setShowLoader(true);\n try {\n fetchSubscriptionData('PREPAID', endpoint)\n ?.then(async (resp: any) => {\n if (resp?.subscriptionData == 204) {\n setModalClick(!popUPClick);\n setSubscriptionFailure(true);\n updateModalClick(true);\n setShowLoader(false);\n } else {\n const responseData = resp?.subscriptionData;\n const queryData = responseData.find((entry: any) => entry.msisdn === queryParams);\n if (responseData) {\n const validPrepaidNumbers: any = [];\n if (queryParams) {\n await validateFcn(queryData, validPrepaidNumbers);\n validateNumberFcn(validPrepaidNumbers);\n } else {\n await Promise.all(\n responseData?.map(async (data: any) => {\n await validateFcn(data, validPrepaidNumbers);\n })\n ).then((succ) => {\n validateNumberFcn(validPrepaidNumbers);\n });\n }\n }\n }\n })\n .catch((error: any) => {\n // eslint-disable-next-line no-console\n console.log('error--->', error);\n setShowLoader(false);\n });\n } catch (err: any) {\n // eslint-disable-next-line no-console\n console.log('error--->', err);\n setShowLoader(false);\n }\n setAfterLogin(true);\n };\n\n // on login success\n const onLoginSuccess = () => {\n setShowLogin(false);\n setLoginSuccess();\n sessionStorage.removeItem('vasPopUp');\n setAlreadyShowedTvOptionsPopUp(false);\n if (enableP2P) {\n fetchPrepaidData();\n } else {\n createCartCall();\n }\n };\n\n // to close the pop up of P2P\n const handleClick = () => {\n setModalClick(!modalClick);\n setShowP2P(false);\n };\n\n // to close the pop up of P2P for success prepiad\n const handlePrepaidClick = () => {\n setShowLoader(false);\n setP2pModal(!p2pModal);\n };\n\n const closeTVOptionsModal = (event?: any) => {\n setDisplayTvOptionsPopUp(false);\n\n if (event) {\n trackNewDatalayerEvent(GAEVENT, CTABUTTONCLICK, {\n headline: 'VAS POPUP CLOSE'\n });\n }\n };\n\n //once linecheck success set linecheck pop up false and proceed to checkout section\n const linecheckSuccess = () => {\n let bundle = typeof window !== 'undefined' && localStorage.getItem('lineCheckResponse');\n eligibleBundle = bundle && JSON?.parse(bundle);\n address = typeof window !== 'undefined' && Cookies.get('chAddressJson');\n typeof linecheckSuccessCallBack == 'function' && linecheckSuccessCallBack();\n };\n\n //once linecheck success set linecheck pop up false and proceed to checkout section\n const linecheckSuccessAndCart = () => {\n let bundle = typeof window !== 'undefined' && localStorage.getItem('lineCheckResponse');\n eligibleBundle = bundle && JSON?.parse(bundle);\n address = typeof window !== 'undefined' && Cookies.get('chAddressJson');\n setShowLinecheck(!showLinecheck);\n typeof linecheckSuccessCallBack == 'function' && linecheckSuccessCallBack();\n createCartCall();\n };\n\n //service Option set for TV\n\n const serviceOption = fetchServiceOptions(productData?.bloks, isMobileFlow);\n\n const radioValue = serviceOption?.[0]?.tvProductId;\n\n const createCartCallAction = (msisdn?: string) => {\n const discountRef = pegaIntegration && uniqueProductData?.[0]?.promotionInfo?.[0]?.id;\n const discountVersion = pegaIntegration && uniqueProductData?.[0]?.promotionInfo?.[0]?.version;\n\n // Shogun / rewards (loyalty) flow: attach the pointsBurnt note so the\n // backend can settle the loyalty burn during cart creation. The value\n // comes from the offer response under `rewards.points`.\n const rewardsInfo = isShogunFlow\n ? { pointsBurnt: uniqueProductData?.[0]?.rewards?.points, rewardOfferId: uniqueProductData?.[0]?.rewards?.offerId, gloxTokenId: shogunToken }\n : undefined;\n\n // US 317400- vas options pop tracking\n if (uniqueProductData && uniqueProductData[0]) {\n uniqueProductData[0].fromPopup = tvOptionsPopUpAddToCart;\n }\n updateVasPopUp('false');\n sessionStorage.removeItem('vasPopUp');\n setAlreadyShowedTvOptionsPopUp(false);\n\n staticCreateCart(\n setShowLoader,\n cartEndPoint,\n giftItem,\n uniqueProductData,\n mainContent,\n showPrice,\n isMobileFlow,\n radioValue,\n eligibleBundle,\n address,\n setShowLinecheck,\n showLinecheck,\n lineCheckCallBack,\n enableP2P,\n queryParams ?? msisdn,\n content,\n tvOptions,\n discountRef,\n discountVersion,\n rewardsInfo\n );\n };\n //cart creation\n const createCartCall = (msisdn?: string) => {\n setTvOptionsPopUpAddToCart(false);\n setShowProductDetail(false);\n let AuthData: any = typeof window !== undefined && Cookies.get('sunriseAuth');\n const AuthDataNew = AuthData && JSON.parse(AuthData);\n const setLoginCookie =\n mainContent?.enableExistingCustomer && AuthDataNew == undefined ? true : false;\n sessionStorage.removeItem(ONE_ECOMMERCE_INTERNET_SUMMARY);\n if (mainContent?.linecheckData?.length > 0 && !isMobileFlow && !isAvailable) {\n // setShowLinecheck(true);\n const lineCheckElement = document.getElementById('linecheck');\n if (lineCheckElement) {\n lineCheckCallBack();\n }\n return;\n } else if (\n isAvailable &&\n !isMobileFlow &&\n mainContent?.loginData?.length > 0 &&\n setLoginCookie\n ) {\n setShowLogin(true);\n } else if (enableTVStreamingOptionsStepper && uniqueProductData[0]?.isBundle) {\n let recommendAccessory = false;\n\n if (!skipAccessoriesPage) {\n /**Check if bundle or Internet and add it to cart request*/\n if (uniqueProductData[0]?.isBundle) {\n uniqueProductData[0]?.bundledOffers?.map((item: any) => {\n if (\n item?.productType?.toLowerCase() === 'internet' ||\n item?.productType?.toLowerCase() == 'tv'\n ) {\n if (item?.recommendAccessory) {\n recommendAccessory = item?.recommendAccessory;\n }\n }\n // setting to false incase of Mobile product Type as it is currently out of scope\n if (item?.productType?.toLowerCase() === 'mobile') {\n recommendAccessory = false;\n return;\n }\n });\n } else {\n /**Add standlone product such as internet to cart request*/\n if (uniqueProductData?.[0]?.recommendAccessory) {\n recommendAccessory = uniqueProductData?.[0]?.recommendAccessory;\n }\n }\n }\n\n combineWithVasOptions(\n showPrice,\n uniqueProductData,\n content,\n pegaIntegration,\n productData?.productName,\n recommendAccessory\n );\n createCartCallAction(msisdn);\n } else if (\n enableTVStreamingOptionsPopUp &&\n uniqueProductData[0]?.isBundle &&\n !alreadyShowedTvOptionsPopUp\n ) {\n setDisplayTvOptionsPopUp(true);\n setAlreadyShowedTvOptionsPopUp(true);\n updateVasPopUp('true');\n\n window.addEventListener('beforeunload', function (event) {\n updateVasPopUp('false');\n sessionStorage.removeItem('vasPopUp');\n setAlreadyShowedTvOptionsPopUp(false);\n });\n } else {\n //for mobile p2p\n if (enableP2P) {\n setShowLoader(true);\n }\n createCartCallAction(msisdn);\n }\n };\n\n //cart creation callback For device first flow\n const deviceFirstFlowCreateCartCallback = (msisdn?: string) => {\n setShowProductDetail(false);\n const msisdnn = queryParams ?? msisdn;\n const deviceFirstFlowCartObj = {\n setShowLoader,\n cartEndPoint,\n giftItem,\n uniqueProductData,\n mainContent,\n showPrice,\n isMobileFlow,\n eligibleBundle,\n address,\n setShowLinecheck,\n showLinecheck,\n lineCheckCallBack,\n enableP2P,\n msisdnn,\n content,\n selectedRP,\n continueCart\n };\n deviceFlowCallBack(deviceFirstFlowCartObj);\n };\n\n // Guards a cart-creation action: if a persistent cart already exists\n // (one-commerce-cartId cookie), show the replace-cart popup and defer the\n // action until the user confirms via the primary button.\n const withReplaceCartCheck =\n (action: (callFunctionArg?: string) => void, popupContent?: any) =>\n (callFunctionArg?: string) => {\n const existingCartId =\n typeof window !== undefined && Cookies.get('one-commerce-cartId');\n if (mainContent?.enableReplacePopup && existingCartId) {\n pendingCartActionRef.current = () => action(callFunctionArg);\n shouldDeleteCartCookieRef.current = Boolean(popupContent);\n setReplacePopupContent(popupContent ?? mainContent?.generalReplacePopup?.[0]);\n setShowReplaceCartModal(true);\n } else {\n action(callFunctionArg);\n }\n };\n\n // after 1 prepaid numbers selection from existingp2pmodal\n const onSelectSubscriptionPreToPost = (value: any) => {\n setP2pModal(!p2pModal);\n combine\n ? combineWithSmartPhone(\n showPrice,\n storyContent,\n uniqueProductData,\n value,\n content,\n pegaIntegration\n )\n : createCartCall(value?.msisdn);\n };\n //show price calculation\n const showPrice = fetchPrice(\n uniqueProductData,\n isMobileFlow,\n mainContent?.pageType,\n false,\n tvOptions,\n pegaIntegration\n );\n\n //card height calculation and gift & cashback check on change of offer data\n //to calculate the height when the tvOptions is added and removed\n useEffect(() => {\n setTimeout(() => {\n findHeight(tabIndex, cardsLength);\n }, 100);\n const result = checkGiftOrCashback(\n isMobileFlow\n ? uniqueProductData\n : (uniqueProductData?.[0]?.bundledOffers ?? uniqueProductData)\n );\n setShowGiftOrCashback({ ...result });\n }, [\n offeringData,\n toggleState,\n tvOptions,\n timerSpaceHeight,\n (toggleState?.TV || toggleState?.gigaSpeed || toggleState?.Netflix) &&\n Array.isArray(uniqueProductData) &&\n uniqueProductData?.[0]?.bundledOffers?.length === 3\n ]);\n\n //product details pop up\n const showDetailsModal = () => {\n setShowProductDetail(!showProductDetail);\n //Analytics Product Details tracking\n let offerData = uniqueProductData;\n trackNewDatalayerEvent(GAEVENT, DOWNLOADPRODUCT, getEcomCartInfo(offerData, '', LINETABLE));\n const prospectId = localStorage.getItem('prospectId');\n const url = window?.location?.pathname?.split('/') ?? [];\n const pathname = url[url.length - 1];\n const payload = {\n eventTimestamp: getUtcTimestamp(),\n eventType: 'PageView',\n pageType: 'ProductDetails',\n pageLocation: pathname,\n // deviceType: viewPortType, #TODO - fix this values, isn't working for tablet\n targetProduct: id\n };\n prospectId && trackPegaEvents(pegaEndpoint, payload, prospectId);\n };\n\n //TV service option\n const showModalPopup = () => {\n if (serviceOption?.length > 0 || enableTVStreamingOptionsPopUp) {\n setShowOptions(true);\n }\n };\n const updatedContent = mainContent?.productContainer?.[0];\n\n // set the combine to true for p2p\n const combineP2P = () => {\n setCombine(true);\n };\n\n // to trigger on click of combinewith smartphone\n useEffect(() => {\n if (combine) {\n if (enableP2P && AuthData == undefined) {\n setShowP2P(!showP2P);\n setModalClick(!popUPClick);\n } else if (enableP2P && AuthData?.siteId) {\n fetchPrepaidData();\n }\n }\n }, [combine]);\n\n useEffect(() => {\n if (context) {\n const { store } = context;\n if (store?.ottOptionsApi?.length > 0 && responseList?.length === 0) {\n setResponseList(store?.ottOptionsApi);\n }\n }\n }, [context]);\n\n useEffect(() => {\n if (!isCounterEnabled || !timerContent?.startTime || !timerContent?.endTime) {\n setTimerIsActive(false);\n return;\n }\n\n setTimerIsActive(isTimerActive(timerContent.startTime, timerContent.endTime));\n\n const delay = getTimeUntilNextTimerEvent(timerContent.startTime, timerContent.endTime);\n if (delay <= 0) return;\n\n const timeout = setTimeout(() => {\n setTimerIsActive(isTimerActive(timerContent.startTime, timerContent.endTime));\n }, delay);\n\n return () => clearTimeout(timeout);\n }, [isCounterEnabled, timerContent?.startTime, timerContent?.endTime]);\n\n useEffect(() => {\n const timerElement = timerContainerRef.current;\n if (!timerElement || !content?.timer?.length || !isCounterEnabled) {\n setTimerSpaceHeight(0);\n return;\n }\n\n const updateTimerSpaceHeight = () => {\n setTimerSpaceHeight(timerElement.clientHeight);\n };\n\n updateTimerSpaceHeight();\n\n if (typeof ResizeObserver === 'undefined') {\n return;\n }\n\n const resizeObserver = new ResizeObserver(updateTimerSpaceHeight);\n resizeObserver.observe(timerElement);\n\n return () => {\n resizeObserver.disconnect();\n };\n }, [content?.timer?.length, isCounterEnabled]);\n\n // to trigger on click tv option pop up closed\n useEffect(() => {\n if (tvOptionsPopUpChanged) {\n closeTVOptionsModal();\n setTvOptionsPopUpChanged(true);\n updateVasPopUp('false');\n sessionStorage.removeItem('vasPopUp');\n setAlreadyShowedTvOptionsPopUp(false);\n createCartCallAction();\n }\n }, [tvOptionsPopUpChanged]);\n\n //US 314008 - only show vas pop up for first time user clicked order now\n useEffect(() => {\n const checkVasPopUp = () => {\n const vasPopUp = sessionStorage.getItem('vasPopUp');\n\n setAlreadyShowedTvOptionsPopUp(vasPopUp === 'true');\n };\n\n checkVasPopUp();\n\n const handleStorageChange = (event: StorageEvent) => {\n if (event.storageArea === sessionStorage && event.key === 'vasPopUp') {\n checkVasPopUp();\n }\n // If vasPopUp is removed (deleted)\n if (\n event.storageArea === sessionStorage &&\n event.key === 'vasPopUp' &&\n event.newValue === null\n ) {\n setAlreadyShowedTvOptionsPopUp(false);\n }\n };\n\n const handleCustomEvent = () => {\n checkVasPopUp();\n };\n window.addEventListener('storage', handleStorageChange);\n window.addEventListener('vasPopUpChange', handleCustomEvent);\n \n return () => {\n window.removeEventListener('storage', handleStorageChange);\n window.removeEventListener('vasPopUpChange', handleCustomEvent);\n };\n \n }, []);\n\n const updateVasPopUp = (value: string) => {\n sessionStorage.setItem('vasPopUp', value);\n const event = new Event('vasPopUpChange');\n window.dispatchEvent(event);\n };\n\n return (\n <div>\n {showLoader &&\n portalPosition &&\n createPortal(<Dotloader keyParams='loading' />, portalPosition)}\n {isSkeletonLoading && (\n <div className='w-75 pb-2'>\n <SkeletonLoader />\n </div>\n )}\n {!isSkeletonLoading && eligibleBundle && content && address && !isMobileFlow && (\n <div className={Styles.selected}>\n <span style={{ paddingBottom: '10px' }}>\n {!isAvailable ? (\n <span className={Styles.inactiveicon}>\n <img\n src={`${assetPath}/icons/cross_disabled.svg`}\n alt=''\n width={24}\n height={24}\n className={Styles.inactiveicon}\n />\n <span>{constants?.notSubscriptionTxt}</span>\n </span>\n ) : (\n <span className={Styles.activeicon}>\n <img\n src={`${assetPath}/icons/lineCheck-success.svg`}\n alt=''\n width={24}\n height={24}\n className={Styles.activeicon}\n />\n <span>{constants?.subscriptionAvalTxt}</span>\n </span>\n )}\n </span>\n </div>\n )}\n\n <div\n className={`${\n !isMobileFlow &&\n isAvailable === false &&\n mainContent?.linecheckData?.length > 0 &&\n mainContent?.linecheckData?.[0]?.reference?.default_full_slug !== 'global/coverage-check'\n ? Styles.overlay\n : ''\n }\n ${deviceUltimateBundle && !uniqueProductData?.[0]?.eligibility?.fpb ? Styles.disabled : ''}\n `}\n style={{ flexDirection: 'column' }}\n >\n <div className={Styles.bundleproductcard}>\n <div\n id={`timer-section${tabIndex}${indexKey}`}\n data-timer-active={timerSpaceHeight > 0 ? 'true' : 'false'}\n >\n {content?.timer?.length && isCounterEnabled ? (\n <div style={{ height: `${timerSpaceHeight}px`, transition: 'height 0.3s ease' }} />\n ) : null}\n </div>\n <div\n className={`${Styles.productcontainer}`}\n style={getBorderStyles()}\n > \n {showBadges &&(\n <BadgeContainer badges={content.badgesContainer}/>\n )}\n {showHighlightText && (\n <div className={`${Styles.highlightText}`}>{content?.highlightText}</div>\n )}\n \n {showPromoContainer && (\n promotionData?.badgeContainer ? (\n <BadgeContainer badges={promotionData?.badgeContainer}/>\n ) : (\n <div\n className={`${Styles.promocontainer}`}\n style={{\n background: promotionData?.bestSellerColor\n }}\n >\n {promotionData?.displayText}\n </div>\n )\n )}\n <div ref={timerContainerRef} className={Styles.timerContainer}>\n {content?.timer?.length && isCounterEnabled ? (\n <StaticLineTabelTimer\n content={content?.timer?.[0]}\n hasHighlightText={ showBadges || showPromoContainer}\n onTimerChange={(active) => {\n setTimerIsActive(active);\n }}\n />\n ) : null}\n </div>\n <div\n className={`${Styles.detailsection} ${Styles.imageFullWidthSection}`}\n id={`detailsectionv3${tabIndex}${indexKey}`}\n >\n <div className={`${Styles.headersection}`}>\n <div className={`${Styles.titlesection}`}>\n <div className={`${Styles.productheader}`} id={`titleV3${tabIndex}${indexKey}`}>\n {productData?.productName}\n </div>\n <div>\n {productData?.icon?.filename && (\n <img\n className={`${Styles.imagecontainer}`}\n src={productData?.icon?.filename}\n height={15}\n width={20}\n alt='productIcon'\n />\n )}\n </div>\n </div>\n <div\n className={`${Styles.productdescription}`}\n id={`descriptionV3${tabIndex}${indexKey}`}\n >\n <RichText content={productData?.description} />\n </div>\n {/* Image(map) */}\n <div className={`${Styles.images}`}>\n {productData?.img?.filename && (\n <img\n className={`${Styles.imagespace} ${\n content?.highlightText && Styles.borderimage\n }`}\n alt='cardimg'\n src={`${productData?.img?.filename}/m/`}\n />\n )}\n </div>\n </div>\n {/* product entitlement section */}\n <div\n className={`${Styles.productconfig}`}\n id={`product-configv3${tabIndex}${indexKey}`}\n >\n {isSkeletonLoading ? (\n <>\n <div className={Styles.space}></div>\n <SkeletonLoader stylename={Styles.skeletontittle} count={1} />\n <SkeletonLoader stylename={Styles.skeletonline} count={5} />\n <div className={Styles.space}></div>\n <SkeletonLoader stylename={Styles.skeletontittle} count={1} />\n <SkeletonLoader stylename={Styles.skeletonline} count={5} />\n </>\n ) : (\n <div>\n {productData?.bloks &&\n productData?.bloks?.map((entitle: any, index: number) => {\n return (\n <StaticProductEntitlement\n content={entitle}\n indexKey={index}\n constants={constants}\n key={index}\n showModalPopup={showModalPopup}\n setToggleState={setToggleState}\n toggleState={toggleState}\n noTabs={noTabs}\n mainContent={mainContent}\n enableTVStreamingOptions={content?.enableTVStreamingOptions}\n metadata={metadata}\n setTvOptionsData={setTvOptionsData}\n />\n );\n })}\n </div>\n )}\n </div>\n </div>\n {/* benefits section */}\n <div\n className={`${Styles.detailsection}`}\n id={`benefits-price-section${tabIndex}${indexKey}`}\n >\n <div id={`exclusive-benefits-section${tabIndex}${indexKey}`}>\n {productData?.extraBenefits?.length > 0 && (\n <StaticExclusiveBenefit content={productData?.extraBenefits?.[0]} />\n )}\n </div>\n <div\n className={`${Styles.benefitssection}`}\n id={`benefits-section${tabIndex}${indexKey}`}\n >\n {productData?.benefits?.length > 0 && (\n <StaticBenefit\n content={productData?.benefits}\n benefitData={showPrice}\n constants={constants}\n //US_31295\n pricesToggleState={pricesToggleState}\n togglePriceLabel={toggleContent?.togglePriceLabel}\n />\n )}\n </div>\n <br />\n\n {/* gift or cashback section */}\n <div className={`${Styles.giftsection}`} id={`gift-section${tabIndex}${indexKey}`}>\n {showGiftOrCashback?.showGift &&\n promotionData?.singleGift?.map((item: any, index: number) => {\n return <GiftConfigV2 content={item} key={index} />;\n })}\n {showGiftOrCashback?.showGift &&\n promotionData?.giftConfig?.map((item: any, index: number) => {\n return (\n <ChooseGiftV2\n content={item}\n key={index}\n selectedGiftItem={selectedGiftItem}\n parentPoType={isMobileFlow ? 'MOBILE' : 'HOME'}\n />\n );\n })}\n <div\n className={`${Styles.giftsection}`}\n id={`cashback-section${tabIndex}${indexKey}`}\n >\n <StaticProductCashback\n uniqueProductData={uniqueProductData}\n mainContent={mainContent}\n />\n </div>\n </div>\n {/* price section */}\n <div className={`${Styles.ordersection}`} id={`order-section${tabIndex}${indexKey}`}>\n {showPrice?.base === '' ? (\n <div>\n <SkeletonLoader stylename={Styles.skeletontittle} />\n </div>\n ) : (\n <div id={`price-section${tabIndex}${indexKey}`}>\n <DynamicPriceSection\n priceCollection={showPrice}\n constants={constants}\n promoText={productData?.promoText}\n deviceFlow={deviceFlow}\n content={content}\n offeringData={offeringData}\n uniqueId={uniqueId}\n />\n </div>\n )}\n\n {/* US_312953 */}\n {!isShogunFlow && (\n <div\n className={`${Styles.discountedpricetoggleSection}`}\n id={`discountedpricetoggle-section${tabIndex}${indexKey}`}\n >\n {!disableDiscountedPriceToggle && toggleContent?.togglePosition === 'INLINE' ? (\n <UserLoggedPricesToggle\n content={productData}\n index={indexKey}\n lineTable={true}\n toggleContent={toggleContent}\n />\n ) : null}\n </div>\n )}\n {/*END US_312953 */}\n\n {/* Longterm text */}\n {enableP2P && constants?.P2PDiscountLabel && (\n <div className={Styles.longterm}>{constants?.P2PDiscountLabel}</div>\n )}\n {/* proceed to checkout section */}\n {isSkeletonLoading ? (\n <>\n <SkeletonLoader stylename={Styles.skeletontittle} count={1} />\n <SkeletonLoader stylename={Styles.skeletonline} count={2} />\n </>\n ) : (\n <div className={`${storyContent?.swapButton && Styles.swapButton}`}>\n <div style={{ padding: '16px 0 0 0' }}>\n <CheckoutButton\n isMobileFlow={isMobileFlow}\n createCartCall={\n deviceFlow?.isDeviceFlow\n ? withReplaceCartCheck(deviceFirstFlowCreateCartCallback)\n : isMobileFlow\n ? withReplaceCartCheck(createCart)\n : withReplaceCartCheck(createCartCall)\n }\n constants={constants}\n storyContent={storyContent}\n showPrice={showPrice}\n isAvailable={isAvailable}\n address={address}\n uniqueProductBenefits={uniqueProductData?.[0]}\n alwaysActive={\n !isAvailable &&\n mainContent?.linecheckData?.length > 0 &&\n mainContent?.linecheckData?.[0]?.reference?.default_full_slug ===\n 'global/coverage-check'\n }\n flexUpgradeFreePopup={mainContent?.flexUpgradeFreePopup?.reference?.content}\n content={content}\n deviceUltimateBundle={deviceUltimateBundle}\n forceDisabled={Boolean(uniqueProductData?.[0]?.rewards?.notEligibleReason)}\n notEligibileReason={uniqueProductData?.[0]?.rewards?.notEligibleReason}\n />\n </div>\n {/* combined with smartphone section */}\n {!isShogunFlow && storyContent?.addSmartPhone?.length > 0 && !deviceFlow?.isDeviceFlow && (\n <div style={{ textAlign: 'center' }}>\n {storyContent?.swapButton\n ? storyContent?.ctaLabel && (\n <div style={{ padding: '16px 0' }}>\n <button\n className={`primarybutton`}\n onClick={() =>\n withReplaceCartCheck(() =>\n combineWithSmartPhone(\n showPrice,\n storyContent,\n uniqueProductData,\n '',\n content,\n pegaIntegration\n ),\n mainContent?.replacePopupWithSmartphone?.[0]\n )()\n }\n >\n <span className={Styles.buttontext}>\n {storyContent?.ctaLabel}\n </span>\n </button>\n </div>\n )\n : !content?.redirectOnly && (\n <div style={{ padding: '12px 0 0 0' }}>\n <FalconButtonV2\n content={{\n buttonType: 'Secondary-V1',\n buttonLabel: content?.ultimateBundlePromotion\n ? constants?.ultimateBundleLbl\n : storyContent?.addSmartPhone?.[0]?.buttonLabel,\n buttonIcon: storyContent?.addSmartPhone?.[0]?.buttonIcon,\n buttonAlignment: 'left'\n }}\n wafIdentifier={basicConfigUrl}\n style={{ width: '100%' }}\n onClick={() =>\n withReplaceCartCheck(\n () =>\n enableP2P\n ? combineP2P()\n : combineWithSmartPhone(\n showPrice,\n storyContent,\n uniqueProductData,\n '',\n content,\n pegaIntegration\n ),\n mainContent?.replacePopupWithSmartphone?.[0]\n )()\n }\n />\n </div>\n )}\n </div>\n )}\n <div\n className={Styles.productcontractduration}\n id={`contract-section${tabIndex}${indexKey}`}\n style={{\n paddingTop:\n storyContent?.addSmartPhone?.length > 0 &&\n !deviceFlow?.isDeviceFlow &&\n !storyContent?.swapButton &&\n !content?.redirectOnly\n ? '8px'\n : undefined\n }}\n >\n {showPrice?.contractDuration > '1'\n ? replacePlaceholder(constants?.minContractDuration?.substring(1), [\n showPrice?.contractDuration\n ])\n : constants?.noContractDuration}\n </div>\n </div>\n )}\n {/* product details section */}\n <div style={{ textAlign: 'center', padding: '4px' }}>\n {productData?.productDetails?.length > 0 && (\n <span className={Styles.productdetailslink} onClick={showDetailsModal}>\n {constants?.productDetailsLink}\n </span>\n )}\n </div>\n {showProductDetail && (\n <StaticProductDetails\n content={productData?.productDetails}\n showProductDetail={showProductDetail}\n setShowProductDetail={setShowProductDetail}\n constants={constants}\n showPrice={showPrice}\n isMobileFlow={isMobileFlow}\n createCartCall={isMobileFlow ? createCart : createCartCall}\n storyContent={storyContent}\n isAvailable={isAvailable}\n address={address}\n flexUpgradeFreePopup={mainContent?.flexUpgradeFreePopup?.reference?.content}\n notEligibileReason={uniqueProductData?.[0]?.rewards?.notEligibleReason}\n />\n )}\n </div>\n </div>\n </div>\n </div>\n </div>\n\n {deviceUltimateBundle && uniqueProductData && !uniqueProductData?.[0]?.eligibility?.fpb && (\n <div className={Styles.disabledInfo}>\n <RichText content={constants?.fpbNotCompatibleText} />\n </div>\n )}\n\n {showOptions &&\n (isSkeletonLoading ? (\n <SkeletonLoader />\n ) : (\n <TVChannelModal\n content={serviceOption?.[0]}\n setShowModal={setShowOptions}\n showModal={showOptions}\n constants={constants}\n />\n ))}\n\n {/* login pop up existing customer benefit without login on click of proceed to checkout */}\n {showLogin &&\n mainContent?.loginData?.length > 0 &&\n portalPosition &&\n createPortal(\n <LoginModalV2\n content={mainContent?.loginData?.[0]}\n closeLogin={() => {\n setShowLogin(false);\n }}\n metadata={metadata}\n onSuccess={onLoginSuccess}\n isProdEnv={isProdEnv}\n />,\n portalPosition\n )}\n\n {/* P2P flow first screen to select login */}\n {showP2P && enableP2P && !showLogin && popUPClick && (\n <GenericModal\n modalState={modalClick}\n handler={handleClick}\n showFooter={false}\n width={'628px'}\n height='280px'\n backgroundColor='#f7f6f5'\n noCloseButton={false}\n backDrop={true}\n bodyPadding='16px'\n >\n <PreToPostSubsPopup\n onClose={handleP2PClick}\n content={mainContent?.productContainer?.[0]?.p2pBloks?.[0]}\n prepaid={false}\n />\n </GenericModal>\n )}\n\n {/* P2P flow error screen if the customer is not prepaid customer */}\n {enableP2P && afterLogin && subscriptionFailure && popUPClick && (\n <GenericModal\n modalState={modalClick}\n handler={handleClick}\n showFooter={false}\n width={'628px'}\n height='280px'\n backgroundColor='#f7f6f5'\n noCloseButton={false}\n backDrop={true}\n bodyPadding='16px'\n id='table-product'\n >\n <PreToPostSubsPopup\n onClose={handleP2PClick}\n content={mainContent?.productContainer?.[0]?.p2pBloks?.[1]}\n prepaid={true}\n />\n </GenericModal>\n )}\n\n {/* p2p flow after successfully logged in prepaid customer to select a number for P2P*/}\n {userSubscriptionData?.length > 1 &&\n enableP2P &&\n afterLogin &&\n !subscriptionFailure &&\n p2pModal && (\n <GenericModal\n modalState={p2pModal}\n handler={handlePrepaidClick}\n showFooter={false}\n width={'628px'}\n height='280px'\n backgroundColor='#f7f6f5'\n noCloseButton={false}\n backDrop={true}\n bodyPadding='16px'\n >\n <ExsistingSubscriptionModal\n onSubmit={onSelectSubscriptionPreToPost}\n exsistingSubscriptionData={userSubscriptionData}\n updatedContent={updatedContent}\n />\n </GenericModal>\n )}\n\n {/* lincheck modal */}\n {showLinecheck &&\n mainContent?.enableLinecheckOverlay &&\n !isMobileFlow &&\n mainContent?.linecheckData?.length > 0 &&\n !enableP2P &&\n mainContent?.linecheckData?.[0]?.reference?.default_full_slug ===\n 'global/new-linecheck-test' ? (\n <LinecheckModal\n content={mainContent?.linecheckData?.[0]}\n onSuccess={linecheckSuccessAndCart}\n showModal={showLinecheck}\n setShowModal={setShowLinecheck}\n productName={productData?.productName}\n productId={productData?.productId}\n />\n ) : showLinecheck &&\n mainContent?.enableLinecheckOverlay &&\n !isMobileFlow &&\n mainContent?.linecheckData?.length > 0 &&\n !enableP2P &&\n mainContent?.linecheckData?.[0]?.reference?.default_full_slug ===\n 'global/coverage-check' ? (\n <CoverageCheckModal\n content={mainContent?.linecheckData?.[0].reference.content.body[0]}\n overlayIsOpen={true}\n externalHandleModal={setShowLinecheck}\n productName={productData?.productName}\n showModal={showLinecheck}\n setShowModal={setShowLinecheck}\n onSuccess={linecheckSuccess}\n onCreateCart={linecheckSuccessAndCart}\n lineCheckOnClear={lineCheckOnClear}\n productId={productData?.productId}\n />\n ) : null}\n {/* benefit validate */}\n {showBenefit && isMobileFlow && storyContent?.benefitsValidate?.length > 0 && (\n <BenefitsValidateWrapper\n content={storyContent?.benefitsValidate?.[0]}\n loginContent={mainContent?.loginData?.[0]}\n metadata={metadata}\n createCartCall={createCartCall}\n fetchOfferData={fetchOfferData}\n basicConfigUrl={basicConfigUrl}\n selectedExistingOption={selectedExistingOption}\n setShowBenefit={setShowBenefit}\n setLoginSuccess={setLoginSuccess}\n isProdEnv={isProdEnv}\n />\n )}\n\n {/* Display tv options on pop up after clicking order now button*/}\n {displayTvOptionsPopUp && (\n <GenericModal\n modalState={displayTvOptionsPopUp}\n handler={closeTVOptionsModal}\n showFooter={false}\n width={viewPortType === 'mobile' ? '' : viewPortType === 'tablet' ? '700px' : '990px'}\n fixedWidth={\n viewPortType === 'mobile' ? '' : viewPortType === 'tablet' ? '700px' : '990px'\n }\n height='845px'\n backgroundColor='#f7f6f5'\n noCloseButton={false}\n backDrop={true}\n bodyPadding='24px'\n >\n <OttServiceOptionsSmallPopup\n content={mainContent?.optionsPopup?.[0]}\n addOptionsCallBack={(val: any) => {\n setTvOptionsPopUpAddToCart(true);\n setTvOptionsPopUpChanged(true);\n setTvOptionsData(val);\n }}\n metadata={metadata}\n constants={constants}\n mainContent={mainContent}\n preSelectedOptions={[]}\n optionsResponse={responseList}\n updateResponseList={setResponseList}\n showPrice={showPrice}\n productData={productData}\n offeringData={offeringData}\n uniqueId={uniqueId}\n deviceFlow={deviceFlow}\n />\n </GenericModal>\n )}\n\n {/* Replace persistent cart confirmation modal */}\n {showReplaceCartModal && replacePopupContent && (\n <GenericPopup\n modalState={showReplaceCartModal}\n onCloseHandler={() => {\n pendingCartActionRef.current = null;\n setShowReplaceCartModal(false);\n }}\n content={replacePopupContent}\n wafIdentifier={basicConfigUrl}\n onPrimaryClick={() => {\n const pendingAction = pendingCartActionRef.current;\n pendingCartActionRef.current = null;\n if (shouldDeleteCartCookieRef.current) {\n Cookies.remove('one-commerce-cartId');\n }\n shouldDeleteCartCookieRef.current = false;\n setShowReplaceCartModal(false);\n pendingAction?.();\n }}\n onSecondaryClick={() => {\n pendingCartActionRef.current = null;\n setShowReplaceCartModal(false);\n }}\n />\n )}\n </div>\n );\n};\n\nexport default StaticProduct;\n"],"names":["StaticProduct","content","offeringData","uniqueId","storyContent","metadata","tabIndex","cardsLength","indexKey","constants","mainContent","address","eligibleBundle","linecheckSuccessCallBack","selectedOption","fetchOfferData","basicConfigUrl","selectedExistingOption","setLoginSuccess","enableP2P","lineCheckCallBack","loginSuccess","setToggleState","toggleState","noTabs","deviceFlow","deviceFlowCallBack","selectedRP","continueCart","lineCheckOnClear","pegaIntegration","isProdEnv","deviceUltimateBundle","toggleContent","pricesToggleState","isShogunFlow","shogunToken","showLoader","setShowLoader","useState","showProductDetail","setShowProductDetail","showGiftOrCashback","setShowGiftOrCashback","showGift","cashbackAvailable","modalClick","updateModalClick","combine","setCombine","giftItem","setGiftItem","showLogin","setShowLogin","showOptions","setShowOptions","showLinecheck","setShowLinecheck","showP2P","setShowP2P","showBenefit","setShowBenefit","subscriptionFailure","setSubscriptionFailure","endpoint","validateEndpoint","userSubscriptionData","setUserSubscriptionData","afterLogin","setAfterLogin","popUPClick","setModalClick","p2pModal","setP2pModal","tvOptions","setTvOptions","displayTvOptionsPopUp","setDisplayTvOptionsPopUp","alreadyShowedTvOptionsPopUp","setAlreadyShowedTvOptionsPopUp","tvOptionsPopUpChanged","setTvOptionsPopUpChanged","tvOptionsPopUpAddToCart","setTvOptionsPopUpAddToCart","responseList","setResponseList","timerSpaceHeight","setTimerSpaceHeight","showReplaceCartModal","setShowReplaceCartModal","pendingCartActionRef","useRef","replacePopupContent","setReplacePopupContent","shouldDeleteCartCookieRef","timerContainerRef","pegaEndpoint","API_BASE_BASEPOINT","CUSTOMER","portalPosition","undefined","window","document","getElementById","isSkeletonLoading","_a","Object","keys","length","productData","_f","_e","_d","_c","_b","products","reference","product","promotionData","_l","_k","_j","_h","_g","promotion","promoDescription","timerContent","_m","timer","isCounterEnabled","enableCounter","timerIsActive","setTimerIsActive","startTime","endTime","isTimerActive","showHighlightText","Boolean","highlightText","badgesContainer","showPromoContainer","displayText","notShowPromotionLabel","showBadges","id","productId","cartEndPoint","_o","LineTableBasicPropConfig","getInstance","getCartUrl","assetPath","_p","AssetPathPropConfig","getAssetPath","isMobileFlow","pageType","viewPortType","viewport","context","useContext","AppContext","isAvailable","_q","includes","enableTVStreamingOptionsPopUp","enableTVStreamingOptionsStepper","disableDiscountedPriceToggle","skipAccessoriesPage","LoginBasicPropConfig","create","baseURL","AuthData","Cookies","get","JSON","parse","uniqueProductData","filter","setTvOptionsData","options","handleP2PClick","createCart","siteId","fetchPrepaidData","EXISTINGCUSTOMER","enableExistingCustomer","enableLoggedInPrice","createCartCall","prospectId","localStorage","getItem","url","location","pathname","split","payload","eventTimestamp","getUtcTimestamp","eventType","pageLocation","targetProduct","trackPegaEvents","selectedGiftItem","item","itemValue","findIndex","gift","giftGroupId","temp","push","params","URLSearchParams","_r","search","queryParams","validateNumberFcn","value","combineWithSmartPhone","showPrice","msisdn","validateFcn","validPrepaidNumbers","__awaiter","validateP2P","then","res","catch","e","console","log","fetchSubscriptionData","resp","subscriptionData","responseData","queryData","find","entry","Promise","all","map","data","succ","error","err","handleClick","closeTVOptionsModal","event","trackNewDatalayerEvent","GAEVENT","CTABUTTONCLICK","headline","linecheckSuccessAndCart","bundle","serviceOption","fetchServiceOptions","bloks","radioValue","_s","tvProductId","createCartCallAction","discountRef","promotionInfo","discountVersion","version","rewardsInfo","pointsBurnt","rewards","points","rewardOfferId","offerId","gloxTokenId","fromPopup","updateVasPopUp","sessionStorage","removeItem","staticCreateCart","AuthDataNew","setLoginCookie","ONE_ECOMMERCE_INTERNET_SUMMARY","linecheckData","loginData","isBundle","recommendAccessory","bundledOffers","productType","toLowerCase","combineWithVasOptions","productName","addEventListener","withReplaceCartCheck","action","popupContent","callFunctionArg","existingCartId","enableReplacePopup","current","generalReplacePopup","fetchPrice","useEffect","setTimeout","findHeight","result","checkGiftOrCashback","assign","TV","gigaSpeed","Netflix","Array","isArray","_u","_t","showModalPopup","updatedContent","_v","productContainer","store","ottOptionsApi","delay","getTimeUntilNextTimerEvent","timeout","clearTimeout","timerElement","updateTimerSpaceHeight","clientHeight","ResizeObserver","resizeObserver","observe","disconnect","_w","checkVasPopUp","vasPopUp","handleStorageChange","storageArea","key","newValue","handleCustomEvent","removeEventListener","setItem","Event","dispatchEvent","React","createElement","createPortal","Dotloader","keyParams","className","SkeletonLoader","Styles","selected","style","paddingBottom","activeicon","src","alt","width","height","subscriptionAvalTxt","inactiveicon","notSubscriptionTxt","_x","_z","_y","_0","default_full_slug","overlay","_2","_1","eligibility","fpb","disabled","flexDirection","bundleproductcard","_3","transition","productcontainer","borderConfig","showBorder","borderGradient","borderColor","borderWidth","borderStyle","borderRadius","background","getBorderStyles","BadgeContainer","badges","badgeContainer","promocontainer","bestSellerColor","ref","timerContainer","_4","StaticLineTabelTimer","_5","hasHighlightText","onTimerChange","active","detailsection","imageFullWidthSection","headersection","titlesection","productheader","icon","_6","filename","imagecontainer","_7","productdescription","RichText","description","images","_8","img","imagespace","borderimage","_9","productconfig","Fragment","space","stylename","skeletontittle","count","skeletonline","_10","entitle","index","StaticProductEntitlement","enableTVStreamingOptions","_11","extraBenefits","StaticExclusiveBenefit","_12","benefitssection","_13","benefits","StaticBenefit","benefitData","togglePriceLabel","giftsection","_14","singleGift","GiftConfigV2","_15","giftConfig","ChooseGiftV2","parentPoType","StaticProductCashback","ordersection","base","DynamicPriceSection","priceCollection","promoText","discountedpricetoggleSection","togglePosition","UserLoggedPricesToggle","lineTable","P2PDiscountLabel","longterm","swapButton","padding","CheckoutButton","isDeviceFlow","msisdnn","uniqueProductBenefits","alwaysActive","_16","_18","_17","flexUpgradeFreePopup","_21","_20","forceDisabled","_23","_22","notEligibleReason","notEligibileReason","_25","_24","_26","addSmartPhone","textAlign","ctaLabel","onClick","replacePopupWithSmartphone","buttontext","redirectOnly","FalconButtonV2","buttonType","buttonLabel","ultimateBundlePromotion","ultimateBundleLbl","_28","_27","buttonIcon","_30","_29","buttonAlignment","wafIdentifier","productcontractduration","paddingTop","_31","contractDuration","replacePlaceholder","_32","minContractDuration","substring","noContractDuration","productDetails","_33","productdetailslink","DOWNLOADPRODUCT","getEcomCartInfo","LINETABLE","productDetailsLink","StaticProductDetails","_35","_34","_37","_36","_39","_38","disabledInfo","fpbNotCompatibleText","TVChannelModal","setShowModal","showModal","_40","LoginModalV2","_41","closeLogin","onSuccess","GenericModal","modalState","handler","showFooter","backgroundColor","noCloseButton","backDrop","bodyPadding","PreToPostSubsPopup","onClose","_44","_43","_42","p2pBloks","prepaid","_47","_46","_45","ExsistingSubscriptionModal","onSubmit","exsistingSubscriptionData","enableLinecheckOverlay","_48","_50","_49","LinecheckModal","_52","_53","_55","_54","CoverageCheckModal","_57","body","overlayIsOpen","externalHandleModal","onCreateCart","_58","benefitsValidate","BenefitsValidateWrapper","_59","loginContent","_60","fixedWidth","OttServiceOptionsSmallPopup","optionsPopup","_61","addOptionsCallBack","val","preSelectedOptions","optionsResponse","updateResponseList","GenericPopup","onCloseHandler","onPrimaryClick","pendingAction","remove","onSecondaryClick"],"mappings":"8kFAoEA,MAAMA,GAAyC,EAC7CC,WACAC,gBACAC,YACAC,gBACAC,YACAC,YACAC,eACAC,YACAC,aACAC,eACAC,WACAC,kBACAC,4BACAC,kBACAC,kBACAC,kBACAC,0BACAC,mBACAC,aACAC,qBACAC,gBACAC,kBACAC,eACA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C,eAAe,EACfC,UAAU,EACVC,YAAY,QAEZtM,EAAAC,cAACyO,IACC9jB,QAAkC,WAAzBS,cAAW,EAAXA,GAAasjB,oBAAY,IAAAC,QAAA,EAAAA,GAAG,GACrCC,mBAAqBC,IACnBhf,IAA2B,GAC3BF,IAAyB,GACzBkG,GAAiBgZ,IAEnB9jB,SAAUA,GACVI,UAAWA,GACXC,YAAaA,GACb0jB,mBAAoB,GACpBC,gBAAiBjf,GACjBkf,mBAAoBjf,GACpBsI,UAAWA,GACX9G,YAAaA,GACb3G,aAAcA,GACdC,SAAUA,GACVsB,WAAYA,MAMjB+D,IAAwBI,IACvByP,gBAACkP,GAAY,CACXlD,WAAY7b,GACZgf,eAAgB,KACd9e,GAAqB8M,QAAU,KAC/B/M,IAAwB,IAE1BxF,QAAS2F,GACTsZ,cAAele,GACfyjB,eAAgB,KACd,MAAMC,EAAgBhf,GAAqB8M,QAC3C9M,GAAqB8M,QAAU,KAC3B1M,GAA0B0M,SAC5B3H,EAAQ8Z,OAAO,uBAEjB7e,GAA0B0M,SAAU,EACpC/M,IAAwB,GACxBif,SAAAA,KAEFE,iBAAkB,KAChBlf,GAAqB8M,QAAU,KAC/B/M,IAAwB"}
@@ -1,2 +1,2 @@
1
- import e,{useState as l,useContext as o,useRef as n,useEffect as i}from"react";import t from"./StaticLineTable.module.scss.js";import d from"../sharedCarousel/CarouselComponent.js";import{viewport as r,getElementMaximumHeight as u,setLocalStoreWithExpiry as s}from"../../utils/utils.js";import v from"./StaticProduct.js";import{getVocherPromotion as a,fetchOttServiceOptions as c,fetchOfferingDataLineTableV2 as p}from"../../services/LineTableService.js";import{LineTableBasicPropConfig as g}from"../../services/LineTableBasicPropConfig.js";import{filterShogunProducts as m,getTimeUntilNextTimerEvent as f,fetchStaticProductIds as w,fetchFilteredProducts as h,isShogunOfferResolved as b,getShogunSharedOffer as L,fetchPegaProducts as C}from"./Product.utils.js";import y from"js-cookie";import{LINETABLE as T}from"../../Analytics/AnalyticsConstants.js";import{trackEligibleItem as P}from"../../models/Analytics/items.js";import{ONE_ECOMMERCE_HARDWARE_SUMMARY as S,VOUCHER as O,VCTYPE as I,NEW as k}from"../../utils/constants.js";import{AppContext as E,actionTypes as j}from"./StaticLineTableStore/StaticLineTableProvider.js";const B=({content:B,setGenericErrorModalDetails:x,metadata:A,tabIndex:F,constants:D,loginSuccess:N,activeIndex:U,mainContent:V,address:$,eligibleBundle:R,linecheckSuccessCallBack:J,selectedOption:q,basicConfigUrl:M,selectedExistingOption:z,setLoginSuccess:_,lineCheckCallBack:G,setToggleState:K,toggleState:H,noTabs:Q,deviceFlow:W,deviceFlowCallBack:X,ubRatePlanObj:Y,lineCheckOnClear:Z,pegaIntegration:ee,pegaCustomerInterest:le,useStoryblokOrder:oe,isFetching:ne,setIsFetching:ie,isProdEnv:te,toggleContent:de,localCacheDuration:re,apiCache:ue})=>{var se,ve;const ae=r(),ce=null==B?void 0:B._uid,[pe,ge]=l(),[me,fe]=l(),[we,he]=l(),be=null===(se=null==g?void 0:g.getInstance())||void 0===se?void 0:se.getBaseUrl();let Le=void 0!==typeof window&&y.get("sunriseAuth");Le=Le&&JSON.parse(Le);const Ce=o(E),ye="MOBILE"===(null==B?void 0:B.pageType),Te=(()=>{var e;if("undefined"==typeof window)return null;const l=new URLSearchParams(null===(e=null===window||void 0===window?void 0:window.location)||void 0===e?void 0:e.search);return null==l?void 0:l.get("gloxtoken")})(),Pe=Boolean(null==V?void 0:V.isRewardsFlow)&&Boolean(Te),Se=void 0!==ue&&ue,[Oe,Ie]=l(()=>{var e;if(!de||!de.enableLoggedInPrice)return null;const l=localStorage.getItem("userLoggedPricesToggle");if("true"===l)return!0;if("false"===l)return!1;const o=(null===(e=null==de?void 0:de.customers)||void 0===e?void 0:e.toLowerCase())===k;return!(!o||!(null==de?void 0:de.newUserToggleEnabled))||(!(o||!(null==de?void 0:de.loggedUserToggleEnabled))||null)}),[ke,Ee]=l(!0),je=n(null),Be=n(""),xe=n({});i(()=>(setTimeout(()=>{Ae()},100),null===window||void 0===window||window.addEventListener("resize",Ae),null===window||void 0===window||window.addEventListener("load",Ae),()=>{window.removeEventListener("resize",Ae),window.removeEventListener("load",Ae)}),[null==B?void 0:B.productList,me,we]);const Ae=()=>{var e;if(Q){const e=[null==H?void 0:H.TV,null==H?void 0:H.Netflix,null==H?void 0:H.gigaSpeed].filter(Boolean).length,l=null==H?void 0:H.TV,o=null==H?void 0:H.Netflix,n=null==H?void 0:H.gigaSpeed;u(`productCardV3${l&&o&&n?3:l&&o||e>=2&&(!n||l||o)?2:1===e||2===e?1:0}`,null==me?void 0:me.length)}else u(`productCardV3${U}`,null===(e=null==B?void 0:B.productList)||void 0===e?void 0:e.length)},Fe=sessionStorage.getItem(S);Fe&&JSON.parse(Fe);const De=null==B?void 0:B.enableFPB;i(()=>{var e,l,o,n,i,t,d,r,u;if(pe&&(null===(e=Object.keys(pe))||void 0===e?void 0:e.length)>0&&P("view",pe[ce],"",T,null,ee),ee&&pe&&(null===(l=Object.keys(pe))||void 0===l?void 0:l.length)>0){const e=(null===(o=null==B?void 0:B.productList)||void 0===o?void 0:o.length)&&(null==B?void 0:B.productList)||new Array((null===(n=null==B?void 0:B.productList)||void 0===n?void 0:n.length)||3).fill(1),l=null===(i=pe[ce])||void 0===i?void 0:i.map(e=>null==e?void 0:e.id),t=e.filter(e=>null==l?void 0:l.includes(e.products[0].reference.name));oe?t.sort((l,o)=>e.indexOf(l)-e.indexOf(o)):t.sort((e,o)=>l.indexOf(e.products[0].reference.name)-l.indexOf(o.products[0].reference.name)),he(t),ie(!1)}if(Pe&&pe&&(null===(t=Object.keys(pe))||void 0===t?void 0:t.length)>0){const e=(null!==(d=pe[ce])&&void 0!==d?d:[]).map(e=>null==e?void 0:e.id),l=(null===(r=null==B?void 0:B.productList)||void 0===r?void 0:r.length)&&(null==B?void 0:B.productList)||new Array((null===(u=null==B?void 0:B.productList)||void 0===u?void 0:u.length)||3).fill(1);he(m(l,e)),ie(!1)}},[pe]),i(()=>{var e;pe&&(null===(e=Object.keys(pe))||void 0===e?void 0:e.length)>0&&!ye&&(null==R?void 0:R.eligibleBundle)&&P("available",pe[ce],"",T,null==R?void 0:R.eligibleBundle,ee)},[R,pe]),i(()=>{if("undefined"==typeof window)return;const e=e=>{Ie(e.detail.value)};return window.addEventListener("user-logged-prices-toggle-all",e),()=>{window.removeEventListener("user-logged-prices-toggle-all",e)}},[]);const Ne=(e=!1)=>{var l,o;const n=[];let i={atlOffers:[]},t=null==V?void 0:V.enableExistingCustomer,d=null==V?void 0:V.subscriptionType,r="4P"==(null==V?void 0:V.pageType);const u=null==B?void 0:B.isReturnPromo,s=(null==z?void 0:z.length)>0,v=null==z?void 0:z.join(",");d=t||Oe?d:v,t=(t||s)&&Le||Oe||!de,(null==Le?void 0:Le.siteId)&&(null==de?void 0:de.enableLoggedInPrice)&&de.customers!==k&&(0==Oe?d="none":!0===Oe&&(d=void 0)),(null==de?void 0:de.enableLoggedInPrice)&&!1===Oe&&(t=!1);const a=!!(null==B?void 0:B.enableP2P),c=`tab-${F}`;if(e||!((e,l)=>{const o=xe.current[e];return!!o&&(0!==l&&(void 0===l||(l<0||(Date.now()-o.timestamp)/6e4<l)))})(c,null!=re?re:1)){if(Pe){const e=Te;if(e)return b(e)||ie(!0),void L(e,ce,be).then(e=>{xe.current[c]={results:e,timestamp:Date.now()},ge({[ce]:e}),x({showPopup:!1})}).catch(()=>{var e;x({showPopup:!0,content:null===(e=null==V?void 0:V.telesalesBlok)||void 0===e?void 0:e[0]})}).finally(()=>{ie(!1)})}if(ie(!0),ee)i=C(B,le,"LineItem");else{w(null==B?void 0:B.productList,n,r,null==V?void 0:V.optionId,Oe);const e=JSON.stringify(n.map(e=>({id:null==e?void 0:e.id,promoIds:(null==e?void 0:e.promoIds)||[]})));Be.current=e}if(e||F===U&&!(null==pe?void 0:pe[ce])||F===U&&N||z)try{null===(l=p(ee?i:n,null==B?void 0:B._uid,be,t,d,u,a,ee,Se,De))||void 0===l||l.then(e=>{var l;const o=null!==(l=null==e?void 0:e[ce])&&void 0!==l?l:[];xe.current[c]={results:o,timestamp:Date.now()},ge(e),x({showPopup:!1})}).catch(e=>{var l;x({showPopup:!0,content:null===(l=null==V?void 0:V.telesalesBlok)||void 0===l?void 0:l[0]})}).finally(()=>{ie(!1)})}catch(e){x({showPopup:!0,content:null===(o=null==V?void 0:V.telesalesBlok)||void 0===o?void 0:o[0]})}else pe&&ie(!1)}else ge({[ce]:xe.current[c].results})};i(()=>{je.current&&(clearTimeout(je.current),je.current=null);if(!(U===F||null==U))return;const e=((null==B?void 0:B.productList)||[]).reduce((e,l)=>{var o;const n=null===(o=null==l?void 0:l.timer)||void 0===o?void 0:o[0];if(!(null==n?void 0:n.enableCounter)||!(null==n?void 0:n.startTime)||!(null==n?void 0:n.endTime))return e;const i=f(n.startTime,n.endTime);return i<=0?e:0===e||i<e?i:e},0);return e<=0?void 0:(je.current=setTimeout(()=>{const e=[];w(null==B?void 0:B.productList,e,"4P"==(null==V?void 0:V.pageType),null==V?void 0:V.optionId,Oe);if(JSON.stringify(e.map(e=>({id:null==e?void 0:e.id,promoIds:(null==e?void 0:e.promoIds)||[]})))===Be.current)return;const l=`tab-${F}`;delete xe.current[l],ge(e=>e&&"object"==typeof e?Object.assign(Object.assign({},e),{[ce]:null}):e),Ne(!0)},e),()=>{je.current&&(clearTimeout(je.current),je.current=null)})},[U,F,null==B?void 0:B.productList,ce,pe]),i(()=>{Ee(!0),U!=F&&null!=U||(void 0!==Oe&&(null==pe?void 0:pe[ce])&&(pe[ce]=null),Ne(),Ee(!1))},[U]),i(()=>{if((null==Le?void 0:Le.siteId)&&N){const e=`tab-${F}`;delete xe.current[e],Ne(),sessionStorage.removeItem("vasPopUp")}},[N]),i(()=>{if(null!=q&&null!=z){const e=`tab-${F}`;delete xe.current[e],Ne()}},[q,z]),i(()=>{if(void 0===Oe||ke)return;const e=`tab-${F}`;delete xe.current[e],(null==pe?void 0:pe[ce])&&(pe[ce]=null),Ne()},[Oe]),i(()=>{var e,l,o,n,i,t,d,r,u,v,p,g,m,f,w,h,b,L,C;const y=window&&new URLSearchParams(null===window||void 0===window?void 0:window.location.search),T=null==y?void 0:y.get(O);if(T&&(null===(r=null===(d=null===(t=null===(i=null===(n=null===(o=null===(l=null===(e=null==B?void 0:B.productList)||void 0===e?void 0:e[0])||void 0===l?void 0:l.products)||void 0===o?void 0:o[0])||void 0===n?void 0:n.reference)||void 0===i?void 0:i.content)||void 0===t?void 0:t.product)||void 0===d?void 0:d[0])||void 0===r?void 0:r.productId))try{a(null===(h=null===(w=null===(f=null===(m=null===(g=null===(p=null===(v=null===(u=null==B?void 0:B.productList)||void 0===u?void 0:u[0])||void 0===v?void 0:v.products)||void 0===p?void 0:p[0])||void 0===g?void 0:g.reference)||void 0===m?void 0:m.content)||void 0===f?void 0:f.product)||void 0===w?void 0:w[0])||void 0===h?void 0:h.productId,T).then(e=>{e&&s(I,{voucher:T,voucherType:"qoqa"})})}catch(e){}if(Ce&&F===U){const{store:e,dispatch:l}=Ce;let o=!1,n=!1;null===(b=(null==B?void 0:B.productList)||[])||void 0===b||b.forEach(e=>{(null==e?void 0:e.enableTVStreamingOptionsPopUp)&&(n=!0),(null==e?void 0:e.enableTVStreamingOptions)&&(o=!0)}),0===(null===(L=null==e?void 0:e.ottOptionsApi)||void 0===L?void 0:L.length)&&(o||n)&&(null===(C=c())||void 0===C||C.then(e=>{(null==e?void 0:e.length)>0&&l({type:null==j?void 0:j.ottOptionsApi,payload:e})}).catch(()=>{}))}},[]);let Ue=[];return i(()=>{Q&&(Ue=h(null==B?void 0:B.productList,H),fe(Ue))},[H]),i(()=>{(null==W?void 0:W.isDeviceFlow)&&pe&&(null==W||W.prodcardcallbackOfferApiData(pe))},[pe]),i(()=>{var e,l;Q&&!(null==W?void 0:W.isDeviceFlow)?he(me):he((null===(e=null==B?void 0:B.productList)||void 0===e?void 0:e.length)&&(null==B?void 0:B.productList)||new Array((null===(l=null==B?void 0:B.productList)||void 0===l?void 0:l.length)||3).fill(1))},[me]),e.createElement("div",null,e.createElement("div",{className:t.titlecontainer},(null==B?void 0:B.title)&&e.createElement("div",{className:t.title},null==B?void 0:B.title),(null==B?void 0:B.subTitle)&&e.createElement("div",{className:t.description},null==B?void 0:B.subTitle)),e.createElement("div",{className:"linetableV3"},ae&&we&&(null==we?void 0:we.length)>0&&e.createElement(d,{carouselIndex:0,key:U,arrow:null==V?void 0:V.enableMobileArrows},we&&(null==we?void 0:we.length)>0&&(null===(ve=we||[])||void 0===ve?void 0:ve.map((l,o)=>{var n;return e.createElement("div",{id:`productCardV3${U}`,style:{textAlign:"center"},key:o},e.createElement(v,{content:ee&&ne&&!pe?{}:l,offeringData:pe,uniqueId:ce,storyContent:B,metadata:A,tabIndex:F,cardsLength:null===(n=null==B?void 0:B.productList)||void 0===n?void 0:n.length,indexKey:o,constants:D,mainContent:V,linecheckSuccessCallBack:J,lineCheckCallBack:G,address:$,eligibleBundle:R,selectedOption:q,fetchOfferData:Ne,basicConfigUrl:M,selectedExistingOption:z,setLoginSuccess:_,enableP2P:null==B?void 0:B.enableP2P,loginSuccess:N,setToggleState:K,toggleState:H,noTabs:Q,deviceFlow:W,deviceFlowCallBack:X,selectedRP:null==Y?void 0:Y.selectedRP,continueCart:null==Y?void 0:Y.continueCart,lineCheckOnClear:Z,pegaIntegration:ee,isProdEnv:te,deviceUltimateBundle:De,toggleContent:de,pricesToggleState:Oe,isShogunFlow:Pe,shogunToken:Te}))})))))};export{B as default};
1
+ import e,{useState as l,useContext as o,useRef as n,useEffect as i}from"react";import t from"./StaticLineTable.module.scss.js";import d from"../sharedCarousel/CarouselComponent.js";import{viewport as r,getElementMaximumHeight as u,setLocalStoreWithExpiry as s}from"../../utils/utils.js";import v from"./StaticProduct.js";import{getVocherPromotion as a,fetchOttServiceOptions as c,fetchOfferingDataLineTableV2 as p}from"../../services/LineTableService.js";import{LineTableBasicPropConfig as g}from"../../services/LineTableBasicPropConfig.js";import{filterShogunProducts as m,getTimeUntilNextTimerEvent as f,fetchStaticProductIds as w,fetchFilteredProducts as h,isShogunOfferResolved as b,getShogunSharedOffer as L,fetchPegaProducts as C}from"./Product.utils.js";import y from"js-cookie";import{LINETABLE as T}from"../../Analytics/AnalyticsConstants.js";import{trackEligibleItem as P}from"../../models/Analytics/items.js";import{ONE_ECOMMERCE_HARDWARE_SUMMARY as S,VOUCHER as O,VCTYPE as I,NEW as k}from"../../utils/constants.js";import{AppContext as E,actionTypes as j}from"./StaticLineTableStore/StaticLineTableProvider.js";const B=({content:B,setGenericErrorModalDetails:x,metadata:A,tabIndex:F,constants:D,loginSuccess:N,activeIndex:U,mainContent:V,address:$,eligibleBundle:R,linecheckSuccessCallBack:J,selectedOption:q,basicConfigUrl:M,selectedExistingOption:z,setLoginSuccess:_,lineCheckCallBack:G,setToggleState:K,toggleState:H,noTabs:Q,deviceFlow:W,deviceFlowCallBack:X,ubRatePlanObj:Y,lineCheckOnClear:Z,pegaIntegration:ee,pegaCustomerInterest:le,useStoryblokOrder:oe,isFetching:ne,setIsFetching:ie,isProdEnv:te,toggleContent:de,localCacheDuration:re,apiCache:ue})=>{var se,ve;const ae=r(),ce=null==B?void 0:B._uid,[pe,ge]=l(),[me,fe]=l(),[we,he]=l(),be=null===(se=null==g?void 0:g.getInstance())||void 0===se?void 0:se.getBaseUrl();let Le=void 0!==typeof window&&y.get("sunriseAuth");Le=Le&&JSON.parse(Le);const Ce=o(E),ye="MOBILE"===(null==B?void 0:B.pageType),Te=void 0!==ue&&ue,Pe=(()=>{var e;if("undefined"==typeof window)return null;const l=new URLSearchParams(null===(e=null===window||void 0===window?void 0:window.location)||void 0===e?void 0:e.search);return null==l?void 0:l.get("gloxtoken")})(),Se=Boolean(null==V?void 0:V.isRewardsFlow)&&Boolean(Pe),[Oe,Ie]=l(()=>{var e;if(!de||!de.enableLoggedInPrice)return null;const l=localStorage.getItem("userLoggedPricesToggle");if("true"===l)return!0;if("false"===l)return!1;const o=(null===(e=null==de?void 0:de.customers)||void 0===e?void 0:e.toLowerCase())===k;return!(!o||!(null==de?void 0:de.newUserToggleEnabled))||(!(o||!(null==de?void 0:de.loggedUserToggleEnabled))||null)}),[ke,Ee]=l(!0),je=n(null),Be=n(""),xe=n({});i(()=>(setTimeout(()=>{Ae()},100),null===window||void 0===window||window.addEventListener("resize",Ae),null===window||void 0===window||window.addEventListener("load",Ae),()=>{window.removeEventListener("resize",Ae),window.removeEventListener("load",Ae)}),[null==B?void 0:B.productList,me,we]);const Ae=()=>{var e;if(Q){const e=[null==H?void 0:H.TV,null==H?void 0:H.Netflix,null==H?void 0:H.gigaSpeed].filter(Boolean).length,l=null==H?void 0:H.TV,o=null==H?void 0:H.Netflix,n=null==H?void 0:H.gigaSpeed;u(`productCardV3${l&&o&&n?3:l&&o||e>=2&&(!n||l||o)?2:1===e||2===e?1:0}`,null==me?void 0:me.length)}else u(`productCardV3${U}`,null===(e=null==B?void 0:B.productList)||void 0===e?void 0:e.length)},Fe=sessionStorage.getItem(S);Fe&&JSON.parse(Fe);const De=null==B?void 0:B.enableFPB;i(()=>{var e,l,o,n,i,t,d,r,u;if(pe&&(null===(e=Object.keys(pe))||void 0===e?void 0:e.length)>0&&P("view",pe[ce],"",T,null,ee),ee&&pe&&(null===(l=Object.keys(pe))||void 0===l?void 0:l.length)>0){const e=(null===(o=null==B?void 0:B.productList)||void 0===o?void 0:o.length)&&(null==B?void 0:B.productList)||new Array((null===(n=null==B?void 0:B.productList)||void 0===n?void 0:n.length)||3).fill(1),l=null===(i=pe[ce])||void 0===i?void 0:i.map(e=>null==e?void 0:e.id),t=e.filter(e=>null==l?void 0:l.includes(e.products[0].reference.name));oe?t.sort((l,o)=>e.indexOf(l)-e.indexOf(o)):t.sort((e,o)=>l.indexOf(e.products[0].reference.name)-l.indexOf(o.products[0].reference.name)),he(t),ie(!1)}if(Se&&pe&&(null===(t=Object.keys(pe))||void 0===t?void 0:t.length)>0){const e=(null!==(d=pe[ce])&&void 0!==d?d:[]).map(e=>null==e?void 0:e.id),l=(null===(r=null==B?void 0:B.productList)||void 0===r?void 0:r.length)&&(null==B?void 0:B.productList)||new Array((null===(u=null==B?void 0:B.productList)||void 0===u?void 0:u.length)||3).fill(1);he(m(l,e)),ie(!1)}},[pe]),i(()=>{var e;pe&&(null===(e=Object.keys(pe))||void 0===e?void 0:e.length)>0&&!ye&&(null==R?void 0:R.eligibleBundle)&&P("available",pe[ce],"",T,null==R?void 0:R.eligibleBundle,ee)},[R,pe]),i(()=>{if("undefined"==typeof window)return;const e=e=>{Ie(e.detail.value)};return window.addEventListener("user-logged-prices-toggle-all",e),()=>{window.removeEventListener("user-logged-prices-toggle-all",e)}},[]);const Ne=(e=!1)=>{var l,o;const n=[];let i={atlOffers:[]},t=null==V?void 0:V.enableExistingCustomer,d=null==V?void 0:V.subscriptionType,r="4P"==(null==V?void 0:V.pageType);const u=null==B?void 0:B.isReturnPromo,s=(null==z?void 0:z.length)>0,v=null==z?void 0:z.join(",");d=t||Oe?d:v,t=(t||s)&&Le||Oe||!de,(null==Le?void 0:Le.siteId)&&(null==de?void 0:de.enableLoggedInPrice)&&de.customers!==k&&(0==Oe?d="none":!0===Oe&&(d=void 0)),(null==de?void 0:de.enableLoggedInPrice)&&!1===Oe&&(t=!1);const a=!!(null==B?void 0:B.enableP2P),c=`tab-${F}`;if(e||!((e,l)=>{const o=xe.current[e];return!!o&&(0!==l&&(void 0===l||(l<0||(Date.now()-o.timestamp)/6e4<l)))})(c,null!=re?re:1)){if(Se){const e=Pe;if(e)return b(e)||ie(!0),void L(e,ce,be).then(e=>{xe.current[c]={results:e,timestamp:Date.now()},ge({[ce]:e}),x({showPopup:!1})}).catch(()=>{var e;x({showPopup:!0,content:null===(e=null==V?void 0:V.telesalesBlok)||void 0===e?void 0:e[0]})}).finally(()=>{ie(!1)})}if(ie(!0),ee)i=C(B,le,"LineItem");else{w(null==B?void 0:B.productList,n,r,null==V?void 0:V.optionId,Oe);const e=JSON.stringify(n.map(e=>({id:null==e?void 0:e.id,promoIds:(null==e?void 0:e.promoIds)||[]})));Be.current=e}if(e||F===U&&!(null==pe?void 0:pe[ce])||F===U&&N||z)try{null===(l=p(ee?i:n,null==B?void 0:B._uid,be,t,d,u,a,ee,Te,De))||void 0===l||l.then(e=>{var l;const o=null!==(l=null==e?void 0:e[ce])&&void 0!==l?l:[];xe.current[c]={results:o,timestamp:Date.now()},ge(e),x({showPopup:!1})}).catch(e=>{var l;x({showPopup:!0,content:null===(l=null==V?void 0:V.telesalesBlok)||void 0===l?void 0:l[0]})}).finally(()=>{ie(!1)})}catch(e){x({showPopup:!0,content:null===(o=null==V?void 0:V.telesalesBlok)||void 0===o?void 0:o[0]})}else pe&&ie(!1)}else ge({[ce]:xe.current[c].results})};i(()=>{je.current&&(clearTimeout(je.current),je.current=null);if(!(U===F||null==U))return;const e=((null==B?void 0:B.productList)||[]).reduce((e,l)=>{var o;const n=null===(o=null==l?void 0:l.timer)||void 0===o?void 0:o[0];if(!(null==n?void 0:n.enableCounter)||!(null==n?void 0:n.startTime)||!(null==n?void 0:n.endTime))return e;const i=f(n.startTime,n.endTime);return i<=0?e:0===e||i<e?i:e},0);return e<=0?void 0:(je.current=setTimeout(()=>{const e=[];w(null==B?void 0:B.productList,e,"4P"==(null==V?void 0:V.pageType),null==V?void 0:V.optionId,Oe);if(JSON.stringify(e.map(e=>({id:null==e?void 0:e.id,promoIds:(null==e?void 0:e.promoIds)||[]})))===Be.current)return;const l=`tab-${F}`;delete xe.current[l],ge(e=>e&&"object"==typeof e?Object.assign(Object.assign({},e),{[ce]:null}):e),Ne(!0)},e),()=>{je.current&&(clearTimeout(je.current),je.current=null)})},[U,F,null==B?void 0:B.productList,ce,pe]),i(()=>{Ee(!0),U!=F&&null!=U||(void 0!==Oe&&(null==pe?void 0:pe[ce])&&(pe[ce]=null),Ne(),Ee(!1))},[U]),i(()=>{if((null==Le?void 0:Le.siteId)&&N){const e=`tab-${F}`;delete xe.current[e],Ne(),sessionStorage.removeItem("vasPopUp")}},[N]),i(()=>{if(null!=q&&null!=z){const e=`tab-${F}`;delete xe.current[e],Ne()}},[q,z]),i(()=>{if(void 0===Oe||ke)return;const e=`tab-${F}`;delete xe.current[e],(null==pe?void 0:pe[ce])&&(pe[ce]=null),Ne()},[Oe]),i(()=>{var e,l,o,n,i,t,d,r,u,v,p,g,m,f,w,h,b,L,C;const y=window&&new URLSearchParams(null===window||void 0===window?void 0:window.location.search),T=null==y?void 0:y.get(O);if(T&&(null===(r=null===(d=null===(t=null===(i=null===(n=null===(o=null===(l=null===(e=null==B?void 0:B.productList)||void 0===e?void 0:e[0])||void 0===l?void 0:l.products)||void 0===o?void 0:o[0])||void 0===n?void 0:n.reference)||void 0===i?void 0:i.content)||void 0===t?void 0:t.product)||void 0===d?void 0:d[0])||void 0===r?void 0:r.productId))try{a(null===(h=null===(w=null===(f=null===(m=null===(g=null===(p=null===(v=null===(u=null==B?void 0:B.productList)||void 0===u?void 0:u[0])||void 0===v?void 0:v.products)||void 0===p?void 0:p[0])||void 0===g?void 0:g.reference)||void 0===m?void 0:m.content)||void 0===f?void 0:f.product)||void 0===w?void 0:w[0])||void 0===h?void 0:h.productId,T).then(e=>{e&&s(I,{voucher:T,voucherType:"qoqa"})})}catch(e){}if(Ce&&F===U){const{store:e,dispatch:l}=Ce;let o=!1,n=!1;null===(b=(null==B?void 0:B.productList)||[])||void 0===b||b.forEach(e=>{(null==e?void 0:e.enableTVStreamingOptionsPopUp)&&(n=!0),(null==e?void 0:e.enableTVStreamingOptions)&&(o=!0)}),0===(null===(L=null==e?void 0:e.ottOptionsApi)||void 0===L?void 0:L.length)&&(o||n)&&(null===(C=c())||void 0===C||C.then(e=>{(null==e?void 0:e.length)>0&&l({type:null==j?void 0:j.ottOptionsApi,payload:e})}).catch(()=>{}))}},[]);let Ue=[];return i(()=>{Q&&(Ue=h(null==B?void 0:B.productList,H),fe(Ue))},[H]),i(()=>{(null==W?void 0:W.isDeviceFlow)&&pe&&(null==W||W.prodcardcallbackOfferApiData(pe))},[pe]),i(()=>{var e,l;Q&&!(null==W?void 0:W.isDeviceFlow)?he(me):he((null===(e=null==B?void 0:B.productList)||void 0===e?void 0:e.length)&&(null==B?void 0:B.productList)||new Array((null===(l=null==B?void 0:B.productList)||void 0===l?void 0:l.length)||3).fill(1))},[me]),e.createElement("div",null,e.createElement("div",{className:t.titlecontainer},(null==B?void 0:B.title)&&e.createElement("div",{className:t.title},null==B?void 0:B.title),(null==B?void 0:B.subTitle)&&e.createElement("div",{className:t.description},null==B?void 0:B.subTitle)),e.createElement("div",{className:"linetableV3"},ae&&we&&(null==we?void 0:we.length)>0&&e.createElement(d,{carouselIndex:0,key:U,arrow:null==V?void 0:V.enableMobileArrows},we&&(null==we?void 0:we.length)>0&&(null===(ve=we||[])||void 0===ve?void 0:ve.map((l,o)=>{var n;return e.createElement("div",{id:`productCardV3${U}`,style:{textAlign:"center"},key:o},e.createElement(v,{content:ee&&ne&&!pe?{}:l,offeringData:pe,uniqueId:ce,storyContent:B,metadata:A,tabIndex:F,cardsLength:null===(n=null==B?void 0:B.productList)||void 0===n?void 0:n.length,indexKey:o,constants:D,mainContent:V,linecheckSuccessCallBack:J,lineCheckCallBack:G,address:$,eligibleBundle:R,selectedOption:q,fetchOfferData:Ne,basicConfigUrl:M,selectedExistingOption:z,setLoginSuccess:_,enableP2P:null==B?void 0:B.enableP2P,loginSuccess:N,setToggleState:K,toggleState:H,noTabs:Q,deviceFlow:W,deviceFlowCallBack:X,selectedRP:null==Y?void 0:Y.selectedRP,continueCart:null==Y?void 0:Y.continueCart,lineCheckOnClear:Z,pegaIntegration:ee,isProdEnv:te,deviceUltimateBundle:De,toggleContent:de,pricesToggleState:Oe,isShogunFlow:Se,shogunToken:Pe}))})))))};export{B as default};
2
2
  //# sourceMappingURL=StaticProductContainer.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"StaticProductContainer.js","sources":["../../../../src/components/StaticLineTable/StaticProductContainer.tsx"],"sourcesContent":["import React, { FC, useContext, useEffect, useRef, useState } from 'react';\nimport Styles from './StaticLineTable.module.scss';\nimport CarouselComponent from '../sharedCarousel/CarouselComponent';\nimport {\n getElementMaximumHeight,\n getNoteValues,\n setLocalStoreWithExpiry,\n viewport\n} from '../../utils/utils';\nimport StaticProduct from './StaticProduct';\nimport { PegaProductRequestBase, ProductRequestBase } from '../lineTable/lineTable.types';\nimport {\n fetchOfferingDataLineTableV2,\n fetchOttServiceOptions,\n getVocherPromotion\n} from '../../services/LineTableService';\nimport { LineTableBasicPropConfig } from '../../services/LineTableBasicPropConfig';\nimport {\n fetchFilteredProducts,\n fetchPegaProducts,\n fetchStaticProductIds,\n filterShogunProducts,\n getShogunSharedOffer,\n getTimeUntilNextTimerEvent,\n isShogunOfferResolved\n} from './Product.utils';\nimport { StaticProductContainerSchema, StaticProductSchema } from './StaticProductDatatypes';\nimport Cookies from 'js-cookie';\nimport { LINETABLE } from '../../Analytics/AnalyticsConstants';\nimport { trackEligibleItem } from '../../models/Analytics/items';\nimport {\n NEW,\n ONE_ECOMMERCE_HARDWARE_SUMMARY,\n ULTIMATEBUNDLE,\n VCTYPE,\n VOUCHER\n} from '../../utils/constants';\nimport { actionTypes, AppContext } from './StaticLineTableStore/StaticLineTableProvider';\n\n/**\n * Query-string parameter name used to trigger the Shogun/rewards (loyalty) flow.\n * The value is passed to the real offer API.\n */\nconst SHOGUN_QUERY_PARAM = 'gloxtoken';\n\n/**\n * Reads the Shogun/rewards token from the URL query-string. Returns null when\n * running outside the browser or when the parameter is not present.\n */\nconst getShogunTokenFromUrl = (): string | null => {\n if (typeof window === 'undefined') return null;\n const params = new URLSearchParams(window?.location?.search);\n return params?.get(SHOGUN_QUERY_PARAM);\n};\n\nconst StaticProductContainer: FC<StaticProductContainerSchema> = ({\n content,\n setGenericErrorModalDetails,\n metadata,\n tabIndex,\n constants,\n loginSuccess,\n activeIndex,\n mainContent,\n address,\n eligibleBundle,\n linecheckSuccessCallBack,\n selectedOption,\n basicConfigUrl,\n selectedExistingOption,\n setLoginSuccess,\n lineCheckCallBack,\n setToggleState,\n toggleState,\n noTabs,\n deviceFlow,\n deviceFlowCallBack,\n ubRatePlanObj,\n lineCheckOnClear,\n pegaIntegration,\n pegaCustomerInterest,\n useStoryblokOrder,\n isFetching,\n setIsFetching,\n isProdEnv,\n //US_31295\n toggleContent,\n localCacheDuration,\n apiCache\n}) => {\n const viewPort = viewport();\n const uniqueId: keyof typeof offeringData = content?._uid;\n const [offeringData, setOfferingData] = useState<any>();\n const [filteredProducts, setFilteredProducts] = useState<any>();\n const [newDisplayContent, setNewDisplayContent] = useState<any>();\n const offerEndpoint = LineTableBasicPropConfig?.getInstance()?.getBaseUrl();\n let AuthData: any = typeof window !== undefined && Cookies.get('sunriseAuth');\n AuthData = AuthData && JSON.parse(AuthData);\n const storeContext = useContext(AppContext);\n const isMobileFlow = content?.pageType === 'MOBILE';\n /**\n * Loyalty (Shogun) flow is active only when BOTH conditions are met:\n * 1. The Storyblok parent-level attribute `isRewardsFlow` is enabled.\n * 2. The URL query-string carries a non-empty `gloxtoken` parameter.\n * Any other combination falls back to the standard offer flow.\n */\n const shogunTokenFromUrl = getShogunTokenFromUrl();\n const isShogunFlow = Boolean(mainContent?.isRewardsFlow) && Boolean(shogunTokenFromUrl);\n // Default apiCache to false if not explicitly set\n const resolvedApiCache = apiCache !== undefined ? apiCache : false;\n //US_31295\n const getPriceToggle = () => {\n if (!toggleContent || !toggleContent.enableLoggedInPrice) return null;\n const stored = localStorage.getItem('userLoggedPricesToggle');\n if (stored === 'true') return true;\n if (stored === 'false') return false;\n const isNewCustomer = toggleContent?.customers?.toLowerCase() === NEW;\n if (isNewCustomer && toggleContent?.newUserToggleEnabled) {\n return true;\n }\n if (!isNewCustomer && toggleContent?.loggedUserToggleEnabled) {\n return true;\n }\n return null;\n };\n const [pricesToggleState, setPricesToggleState] = useState<any>(getPriceToggle);\n const [runOnLoad, setRunOnLoad] = useState<boolean>(true);\n const timerRefreshTimeoutRef = useRef<ReturnType<typeof setTimeout> | null>(null);\n const promoPayloadSignatureRef = useRef<string>('');\n const offerDataCacheRef = useRef<Record<string, { results: any[]; timestamp: number }>>({});\n\n useEffect(() => {\n setTimeout(() => {\n findHeight();\n }, 100);\n window?.addEventListener('resize', findHeight);\n window?.addEventListener('load', findHeight);\n return () => {\n window.removeEventListener('resize', findHeight);\n window.removeEventListener('load', findHeight);\n };\n }, [content?.productList, filteredProducts, newDisplayContent]);\n\n const findHeight = () => {\n if (noTabs) {\n const activeToggles = [toggleState?.TV, toggleState?.Netflix, toggleState?.gigaSpeed].filter(\n Boolean\n ).length;\n const hasTV = toggleState?.TV;\n const hasNetflix = toggleState?.Netflix;\n const hasGigaSpeed = toggleState?.gigaSpeed;\n\n const tabbIndex =\n hasTV && hasNetflix && hasGigaSpeed\n ? 3\n : (hasTV && hasNetflix) ||\n (activeToggles >= 2 && !(hasGigaSpeed && !hasTV && !hasNetflix))\n ? 2\n : activeToggles === 1 || activeToggles === 2\n ? 1\n : 0;\n\n getElementMaximumHeight('productCardV3' + `${tabbIndex}`, filteredProducts?.length);\n } else {\n getElementMaximumHeight('productCardV3' + `${activeIndex}`, content?.productList?.length);\n }\n };\n\n const hardwareSessionObj = sessionStorage.getItem(ONE_ECOMMERCE_HARDWARE_SUMMARY);\n const sessionData = hardwareSessionObj && JSON.parse(hardwareSessionObj);\n const deviceUltimateBundle = content?.enableFPB;\n\n useEffect(() => {\n if (offeringData && Object.keys(offeringData)?.length > 0) {\n trackEligibleItem('view', offeringData[uniqueId], '', LINETABLE, null, pegaIntegration);\n }\n //filter products by pega response\n if (pegaIntegration && offeringData && Object.keys(offeringData)?.length > 0) {\n const availableProducts =\n (content?.productList?.length && content?.productList) ||\n new Array(content?.productList?.length || 3).fill(1);\n\n const pegaProductsIds = offeringData[uniqueId]?.map((item: any) => item?.id);\n\n const onlyPegaProducts = availableProducts.filter((product: any) =>\n pegaProductsIds?.includes(product.products[0].reference.name)\n );\n\n //sort products by storyblok vs pega\n if (useStoryblokOrder) {\n onlyPegaProducts.sort((a: any, b: any) => {\n return availableProducts.indexOf(a) - availableProducts.indexOf(b);\n });\n } else {\n onlyPegaProducts.sort((a: any, b: any) => {\n return (\n pegaProductsIds.indexOf(a.products[0].reference.name) -\n pegaProductsIds.indexOf(b.products[0].reference.name)\n );\n });\n }\n\n setNewDisplayContent(onlyPegaProducts);\n setIsFetching(false);\n }\n\n // Shogun flow: filter storyblok product list to only the products returned by the\n // Shogun offer API (matched by productId). Logic lives in filterShogunProducts (Product.utils).\n if (isShogunFlow && offeringData && Object.keys(offeringData)?.length > 0) {\n const shogunProductIds = (offeringData[uniqueId] ?? []).map((item: any) => item?.id);\n const availableProducts =\n (content?.productList?.length && content?.productList) ||\n new Array(content?.productList?.length || 3).fill(1);\n\n setNewDisplayContent(filterShogunProducts(availableProducts, shogunProductIds));\n setIsFetching(false);\n }\n }, [offeringData]);\n\n useEffect(() => {\n if (\n offeringData &&\n Object.keys(offeringData)?.length > 0 &&\n !isMobileFlow &&\n eligibleBundle?.eligibleBundle\n ) {\n trackEligibleItem(\n 'available',\n offeringData[uniqueId],\n '',\n LINETABLE,\n eligibleBundle?.eligibleBundle,\n pegaIntegration\n );\n }\n }, [eligibleBundle, offeringData]);\n\n //US_31295\n useEffect(() => {\n if (typeof window === 'undefined') return;\n // window.dispatchEvent(\n // new CustomEvent('user-logged-prices-toggle-all', {\n // detail: {\n // auth: AuthData?.siteId ? true : false },\n // })\n // );\n const handleGlobalToggle = (e: any) => {\n setPricesToggleState(e.detail.value);\n };\n window.addEventListener('user-logged-prices-toggle-all', handleGlobalToggle);\n return () => {\n window.removeEventListener('user-logged-prices-toggle-all', handleGlobalToggle);\n };\n }, []);\n\n /**\n * Check if cached offer data is still valid based on localCacheDuration\n */\n const isCacheValid = (cacheKey: string, durationMinutes: number | undefined): boolean => {\n const cached = offerDataCacheRef.current[cacheKey];\n if (!cached) return false;\n\n // A duration of 0 explicitly disables cache reads and always forces a fresh request.\n if (durationMinutes === 0) return false;\n\n // If no duration is specified, cache never expires (until manually cleared).\n if (durationMinutes === undefined) return true;\n\n if (durationMinutes < 0) return true;\n\n const elapsedMinutes = (Date.now() - cached.timestamp) / (1000 * 60);\n return elapsedMinutes < durationMinutes;\n };\n\n /**\n * fetching offer response\n */\n const fetchOfferData = (forceRefresh: boolean = false) => {\n const ProductIds: ProductRequestBase[] = [];\n let pegaPayload: PegaProductRequestBase = { atlOffers: [] };\n // for getting product offer api call request and promo id list\n //existingCustomerBenefit without login\n let existingCustomer = mainContent?.enableExistingCustomer;\n let subscriptionType = mainContent?.subscriptionType;\n let bundle4PProduct = mainContent?.pageType == '4P' ? true : false;\n const enableReturnPromo = content?.isReturnPromo;\n const benefitExistingCustomer = selectedExistingOption?.length > 0 ? true : false;\n const benefitSubscriptionType = selectedExistingOption?.join(',');\n //US_31295\n subscriptionType =\n existingCustomer || pricesToggleState ? subscriptionType : benefitSubscriptionType;\n existingCustomer =\n ((existingCustomer || benefitExistingCustomer) && AuthData) ||\n pricesToggleState ||\n !toggleContent;\n\n if (AuthData?.siteId && toggleContent?.enableLoggedInPrice && toggleContent.customers !== NEW) {\n if (pricesToggleState == false) {\n subscriptionType = 'none';\n } else if (pricesToggleState === true) {\n subscriptionType = undefined;\n }\n }\n\n if (toggleContent?.enableLoggedInPrice && pricesToggleState === false) {\n existingCustomer = false;\n }\n const P2PEnabled = content?.enableP2P ? true : false;\n const cacheDuration = localCacheDuration ?? 1;\n const cacheKey = `tab-${tabIndex}`;\n\n // Serve from cache without triggering loading state\n if (!forceRefresh && isCacheValid(cacheKey, cacheDuration)) {\n setOfferingData({ [uniqueId]: offerDataCacheRef.current[cacheKey].results });\n return;\n }\n\n // Shogun flow: triggered when `gloxtoken` is present in the URL AND the\n // storyblok parent-level `isRewardsFlow` flag is enabled (see isShogunFlow).\n // All containers share a single API call via getShogunSharedOffer (Product.utils).\n if (isShogunFlow) {\n const gloxTokenId = shogunTokenFromUrl;\n\n if (gloxTokenId) {\n // Skip loading state when results are already in the shared cache.\n if (!isShogunOfferResolved(gloxTokenId)) {\n setIsFetching(true);\n }\n\n getShogunSharedOffer(gloxTokenId, uniqueId as string, offerEndpoint)\n .then((shogunResults: any[]) => {\n offerDataCacheRef.current[cacheKey] = { results: shogunResults, timestamp: Date.now() };\n setOfferingData({ [uniqueId]: shogunResults });\n setGenericErrorModalDetails({ showPopup: false });\n })\n .catch(() => {\n setGenericErrorModalDetails({\n showPopup: true,\n content: mainContent?.telesalesBlok?.[0]\n });\n })\n .finally(() => {\n setIsFetching(false);\n });\n return;\n }\n }\n\n setIsFetching(true);\n\n if (pegaIntegration) {\n pegaPayload = fetchPegaProducts(content, pegaCustomerInterest, 'LineItem');\n } else {\n fetchStaticProductIds(\n content?.productList,\n ProductIds,\n bundle4PProduct,\n mainContent?.optionId,\n //US_31295\n pricesToggleState\n );\n const newSignature = JSON.stringify(\n ProductIds.map((item: any) => ({ id: item?.id, promoIds: item?.promoIds || [] }))\n );\n promoPayloadSignatureRef.current = newSignature;\n }\n if (\n forceRefresh ||\n (tabIndex === activeIndex && !offeringData?.[uniqueId]) ||\n (tabIndex === activeIndex && loginSuccess) ||\n selectedExistingOption\n ) {\n try {\n fetchOfferingDataLineTableV2(\n pegaIntegration ? pegaPayload : ProductIds,\n content?._uid,\n offerEndpoint,\n existingCustomer,\n subscriptionType,\n enableReturnPromo,\n P2PEnabled,\n pegaIntegration,\n resolvedApiCache,\n deviceUltimateBundle,\n )\n ?.then((resp: any) => {\n const results = resp?.[uniqueId as string] ?? [];\n offerDataCacheRef.current[cacheKey] = { results, timestamp: Date.now() };\n setOfferingData(resp);\n setGenericErrorModalDetails({ showPopup: false });\n })\n .catch((error: any) => {\n setGenericErrorModalDetails({\n showPopup: true,\n content: mainContent?.telesalesBlok?.[0]\n });\n })\n .finally(() => {\n setIsFetching(false);\n });\n } catch (err: any) {\n setGenericErrorModalDetails({\n showPopup: true,\n content: mainContent?.telesalesBlok?.[0]\n });\n }\n } else if (offeringData) {\n setIsFetching(false);\n }\n };\n\n useEffect(() => {\n if (timerRefreshTimeoutRef.current) {\n clearTimeout(timerRefreshTimeoutRef.current);\n timerRefreshTimeoutRef.current = null;\n }\n\n const isCurrentTab =\n activeIndex === tabIndex || activeIndex === undefined || activeIndex === null;\n\n if (!isCurrentTab) {\n return;\n }\n\n const nextTimerEventDelay = (content?.productList || []).reduce(\n (minimumDelay: number, product: any) => {\n const timer = product?.timer?.[0];\n const isCounterEnabled = timer?.enableCounter;\n\n if (!isCounterEnabled || !timer?.startTime || !timer?.endTime) {\n return minimumDelay;\n }\n\n const delay = getTimeUntilNextTimerEvent(timer.startTime, timer.endTime);\n\n if (delay <= 0) {\n return minimumDelay;\n }\n\n if (minimumDelay === 0 || delay < minimumDelay) {\n return delay;\n }\n\n return minimumDelay;\n },\n 0\n );\n\n if (nextTimerEventDelay <= 0) {\n return;\n }\n timerRefreshTimeoutRef.current = setTimeout(() => {\n const refreshProductIds: ProductRequestBase[] = [];\n fetchStaticProductIds(\n content?.productList,\n refreshProductIds,\n mainContent?.pageType == '4P',\n mainContent?.optionId,\n pricesToggleState\n );\n const nextSignature = JSON.stringify(\n refreshProductIds.map((item: any) => ({ id: item?.id, promoIds: item?.promoIds || [] }))\n );\n\n if (nextSignature === promoPayloadSignatureRef.current) {\n return;\n }\n\n // Clear cache before forcing refresh on timer expiry\n const cacheKey = `tab-${tabIndex}`;\n delete offerDataCacheRef.current[cacheKey];\n\n setOfferingData((prev: any) => {\n if (!prev || typeof prev !== 'object') {\n return prev;\n }\n\n return {\n ...prev,\n [uniqueId]: null\n };\n });\n fetchOfferData(true);\n }, nextTimerEventDelay);\n\n return () => {\n if (timerRefreshTimeoutRef.current) {\n clearTimeout(timerRefreshTimeoutRef.current);\n timerRefreshTimeoutRef.current = null;\n }\n };\n }, [activeIndex, tabIndex, content?.productList, uniqueId, offeringData]);\n\n /**\n * triggering offer api based for the selected tab\n */\n useEffect(() => {\n setRunOnLoad(true);\n if (activeIndex == tabIndex || activeIndex == null) {\n if (pricesToggleState !== undefined && offeringData?.[uniqueId]) {\n offeringData[uniqueId] = null;\n }\n fetchOfferData();\n setRunOnLoad(false);\n }\n }, [activeIndex]);\n\n useEffect(() => {\n if (AuthData?.siteId && loginSuccess) {\n // Clear cache on login to fetch fresh data\n const cacheKey = `tab-${tabIndex}`;\n delete offerDataCacheRef.current[cacheKey];\n fetchOfferData();\n sessionStorage.removeItem('vasPopUp');\n }\n }, [loginSuccess]);\n\n useEffect(() => {\n if (selectedOption != undefined && selectedExistingOption != undefined) {\n // Clear cache when selection options change to fetch fresh data\n const cacheKey = `tab-${tabIndex}`;\n delete offerDataCacheRef.current[cacheKey];\n fetchOfferData();\n }\n }, [selectedOption, selectedExistingOption]);\n\n //US_31295\n useEffect(() => {\n if (pricesToggleState === undefined || runOnLoad) return;\n // Clear cache when price toggle changes to fetch fresh data\n const cacheKey = `tab-${tabIndex}`;\n delete offerDataCacheRef.current[cacheKey];\n if (offeringData?.[uniqueId]) {\n offeringData[uniqueId] = null;\n }\n fetchOfferData();\n }, [pricesToggleState]);\n\n useEffect(() => {\n //For QoQa flow\n const queryParams = window && new URLSearchParams(window?.location.search);\n const voucher: string | null = queryParams?.get(VOUCHER);\n if (\n voucher &&\n content?.productList?.[0]?.products?.[0]?.reference?.content?.product?.[0]?.productId\n ) {\n try {\n getVocherPromotion(\n content?.productList?.[0]?.products?.[0]?.reference?.content?.product?.[0]?.productId,\n voucher\n ).then((res: any) => {\n res && setLocalStoreWithExpiry(VCTYPE, { voucher: voucher, voucherType: 'qoqa' });\n });\n } catch (err: any) {}\n }\n\n //To trigger serviceOptions APi by category and updating it in context\n if (storeContext && tabIndex === activeIndex) {\n const { store, dispatch } = storeContext;\n let enableTvOptions = false;\n let enableTvOptionsPopUp = false;\n (content?.productList || [])?.forEach((prod: any) => {\n if (prod?.enableTVStreamingOptionsPopUp) {\n enableTvOptionsPopUp = true;\n }\n if (prod?.enableTVStreamingOptions) {\n enableTvOptions = true;\n }\n });\n if (store?.ottOptionsApi?.length === 0 && (enableTvOptions || enableTvOptionsPopUp)) {\n fetchOttServiceOptions()\n ?.then((res: any) => {\n if (res?.length > 0) {\n dispatch({ type: actionTypes?.ottOptionsApi, payload: res });\n }\n })\n .catch(() => {});\n }\n }\n }, []);\n\n //No Tabs content set\n let displayContent: any = [];\n useEffect(() => {\n if (noTabs) {\n displayContent = fetchFilteredProducts(content?.productList, toggleState);\n setFilteredProducts(displayContent);\n }\n }, [toggleState]);\n\n // sending offer api data as callback in device Flow to identify Multimobile/fmc\n useEffect(() => {\n if (deviceFlow?.isDeviceFlow && offeringData) {\n deviceFlow?.prodcardcallbackOfferApiData(offeringData);\n }\n }, [offeringData]);\n\n const getProductId = (content: any) => {\n const productData = content?.products?.[0]?.reference?.content?.product?.[0];\n return productData?.productId;\n };\n\n useEffect(() => {\n if (noTabs && !deviceFlow?.isDeviceFlow) {\n setNewDisplayContent(filteredProducts);\n } else {\n setNewDisplayContent(\n (content?.productList?.length && content?.productList) ||\n new Array(content?.productList?.length || 3).fill(1)\n );\n }\n }, [filteredProducts]);\n\n return (\n <div>\n <div className={Styles['titlecontainer']}>\n {content?.title && <div className={Styles['title']}>{content?.title}</div>}\n {content?.subTitle && <div className={Styles['description']}>{content?.subTitle}</div>}\n </div>\n <div className={`linetableV3`}>\n {viewPort && newDisplayContent && newDisplayContent?.length > 0 && (\n <CarouselComponent\n carouselIndex={0}\n key={activeIndex}\n arrow={mainContent?.enableMobileArrows}\n >\n {newDisplayContent &&\n newDisplayContent?.length > 0 &&\n (newDisplayContent || [])?.map((data: StaticProductSchema, indexx: number) => {\n return (\n <div\n id={`productCardV3${activeIndex}`}\n style={{ textAlign: 'center' }}\n key={indexx}\n >\n <StaticProduct\n content={pegaIntegration && isFetching && !offeringData ? {} : data}\n offeringData={offeringData}\n uniqueId={uniqueId}\n storyContent={content}\n metadata={metadata}\n tabIndex={tabIndex}\n cardsLength={content?.productList?.length}\n indexKey={indexx}\n constants={constants}\n mainContent={mainContent}\n linecheckSuccessCallBack={linecheckSuccessCallBack}\n lineCheckCallBack={lineCheckCallBack}\n address={address}\n eligibleBundle={eligibleBundle}\n selectedOption={selectedOption}\n fetchOfferData={fetchOfferData}\n basicConfigUrl={basicConfigUrl}\n selectedExistingOption={selectedExistingOption}\n setLoginSuccess={setLoginSuccess}\n enableP2P={content?.enableP2P}\n loginSuccess={loginSuccess}\n setToggleState={setToggleState}\n toggleState={toggleState}\n noTabs={noTabs}\n deviceFlow={deviceFlow}\n deviceFlowCallBack={deviceFlowCallBack}\n selectedRP={ubRatePlanObj?.selectedRP}\n continueCart={ubRatePlanObj?.continueCart}\n lineCheckOnClear={lineCheckOnClear}\n pegaIntegration={pegaIntegration}\n isProdEnv={isProdEnv}\n deviceUltimateBundle={deviceUltimateBundle}\n //US_31295\n toggleContent={toggleContent}\n pricesToggleState={pricesToggleState}\n isShogunFlow={isShogunFlow}\n shogunToken={shogunTokenFromUrl}\n />\n </div>\n );\n })}\n </CarouselComponent>\n )}\n </div>\n </div>\n );\n};\n\nexport default StaticProductContainer;\n"],"names":["StaticProductContainer","content","setGenericErrorModalDetails","metadata","tabIndex","constants","loginSuccess","activeIndex","mainContent","address","eligibleBundle","linecheckSuccessCallBack","selectedOption","basicConfigUrl","selectedExistingOption","setLoginSuccess","lineCheckCallBack","setToggleState","toggleState","noTabs","deviceFlow","deviceFlowCallBack","ubRatePlanObj","lineCheckOnClear","pegaIntegration","pegaCustomerInterest","useStoryblokOrder","isFetching","setIsFetching","isProdEnv","toggleContent","localCacheDuration","apiCache","viewPort","viewport","uniqueId","_uid","offeringData","setOfferingData","useState","filteredProducts","setFilteredProducts","newDisplayContent","setNewDisplayContent","offerEndpoint","_a","LineTableBasicPropConfig","getInstance","getBaseUrl","AuthData","undefined","window","Cookies","get","JSON","parse","storeContext","useContext","AppContext","isMobileFlow","pageType","shogunTokenFromUrl","params","URLSearchParams","location","search","getShogunTokenFromUrl","isShogunFlow","Boolean","isRewardsFlow","resolvedApiCache","pricesToggleState","setPricesToggleState","enableLoggedInPrice","stored","localStorage","getItem","isNewCustomer","customers","toLowerCase","NEW","newUserToggleEnabled","loggedUserToggleEnabled","runOnLoad","setRunOnLoad","timerRefreshTimeoutRef","useRef","promoPayloadSignatureRef","offerDataCacheRef","useEffect","setTimeout","findHeight","addEventListener","removeEventListener","productList","activeToggles","TV","Netflix","gigaSpeed","filter","length","hasTV","hasNetflix","hasGigaSpeed","getElementMaximumHeight","hardwareSessionObj","sessionStorage","ONE_ECOMMERCE_HARDWARE_SUMMARY","deviceUltimateBundle","enableFPB","Object","keys","trackEligibleItem","LINETABLE","_b","availableProducts","_c","Array","_d","fill","pegaProductsIds","_e","map","item","id","onlyPegaProducts","product","includes","products","reference","name","sort","a","b","indexOf","_f","shogunProductIds","_g","_h","_j","filterShogunProducts","handleGlobalToggle","e","detail","value","fetchOfferData","forceRefresh","ProductIds","pegaPayload","atlOffers","existingCustomer","enableExistingCustomer","subscriptionType","bundle4PProduct","enableReturnPromo","isReturnPromo","benefitExistingCustomer","benefitSubscriptionType","join","siteId","P2PEnabled","enableP2P","cacheKey","durationMinutes","cached","current","Date","now","timestamp","isCacheValid","gloxTokenId","isShogunOfferResolved","getShogunSharedOffer","then","shogunResults","results","showPopup","catch","telesalesBlok","finally","fetchPegaProducts","fetchStaticProductIds","optionId","newSignature","stringify","promoIds","fetchOfferingDataLineTableV2","resp","error","err","clearTimeout","nextTimerEventDelay","reduce","minimumDelay","timer","enableCounter","startTime","endTime","delay","getTimeUntilNextTimerEvent","refreshProductIds","prev","assign","removeItem","queryParams","voucher","VOUCHER","productId","getVocherPromotion","_q","_p","_m","_l","_o","_r","res","setLocalStoreWithExpiry","VCTYPE","voucherType","store","dispatch","enableTvOptions","enableTvOptionsPopUp","_s","forEach","prod","enableTVStreamingOptionsPopUp","enableTVStreamingOptions","ottOptionsApi","_t","_u","fetchOttServiceOptions","type","actionTypes","payload","displayContent","fetchFilteredProducts","isDeviceFlow","prodcardcallbackOfferApiData","React","createElement","className","Styles","title","subTitle","CarouselComponent","carouselIndex","key","arrow","enableMobileArrows","data","indexx","style","textAlign","StaticProduct","storyContent","cardsLength","indexKey","selectedRP","continueCart","shogunToken"],"mappings":"omCA2CA,MAYMA,EAA2D,EAC/DC,UACAC,8BACAC,WACAC,WACAC,YACAC,eACAC,cACAC,cACAC,UACAC,iBACAC,2BACAC,iBACAC,iBACAC,yBACAC,kBACAC,oBACAC,iBACAC,cACAC,SACAC,aACAC,qBACAC,gBACAC,mBACAC,mBACAC,wBACAC,qBACAC,cACAC,iBACAC,aAEAC,iBACAC,sBACAC,0BAEA,MAAMC,GAAWC,IACXC,GAAsClC,aAAO,EAAPA,EAASmC,MAC9CC,GAAcC,IAAmBC,KACjCC,GAAkBC,IAAuBF,KACzCG,GAAmBC,IAAwBJ,IAC5CK,GAAuD,QAAvCC,GAAAC,aAAwB,EAAxBA,EAA0BC,qBAAa,IAAAF,QAAA,EAAAA,GAAEG,aAC/D,IAAIC,QAAkCC,WAAXC,QAAwBC,EAAQC,IAAI,eAC/DJ,GAAWA,IAAYK,KAAKC,MAAMN,IAClC,MAAMO,GAAeC,EAAWC,GAC1BC,GAAqC,YAAtB1D,aAAO,EAAPA,EAAS2D,UAOxBC,GAzDsB,YAC5B,GAAsB,oBAAXV,OAAwB,OAAO,KAC1C,MAAMW,EAAS,IAAIC,gBAAgC,UAAV,OAANZ,aAAM,IAANA,YAAM,EAANA,OAAQa,gBAAQ,IAAAnB,OAAA,EAAAA,EAAEoB,QACrD,OAAOH,aAAM,EAANA,EAAQT,IATU,cA+DEa,GACrBC,GAAeC,QAAQ5D,aAAW,EAAXA,EAAa6D,gBAAkBD,QAAQP,IAE9DS,QAAgCpB,IAAblB,IAAyBA,IAgB3CuC,GAAmBC,IAAwBjC,EAd3B,WACrB,IAAKT,KAAkBA,GAAc2C,oBAAqB,OAAO,KACjE,MAAMC,EAASC,aAAaC,QAAQ,0BACpC,GAAe,SAAXF,EAAmB,OAAO,EAC9B,GAAe,UAAXA,EAAoB,OAAO,EAC/B,MAAMG,GAAwC,QAA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AYS,KAAqBA,cAAiB,EAAjBA,GAAmB0D,QAAS,GAC5D2I,EAAAC,cAACK,GACCC,cAAe,EACfC,IAAKhP,EACLiP,MAAOhP,aAAW,EAAXA,EAAaiP,oBAEnB/M,KACCA,cAAiB,EAAjBA,GAAmB0D,QAAS,IACH,QAAzBc,GAACxE,IAAqB,UAAG,IAAAwE,QAAA,EAAAA,GAAEQ,IAAI,CAACgI,EAA2BC,WACzD,OACEZ,EAAAC,cAAA,MAAA,CACEpH,GAAI,gBAAgBrH,IACpBqP,MAAO,CAAEC,UAAW,UACpBN,IAAKI,GAELZ,EAAAC,cAACc,EAAa,CACZ7P,QAASuB,IAAmBG,KAAeU,GAAe,CAAA,EAAKqN,EAC/DrN,aAAcA,GACdF,SAAUA,GACV4N,aAAc9P,EACdE,SAAUA,EACVC,SAAUA,EACV4P,YAAiC,QAApBnN,EAAA5C,aAAO,EAAPA,EAAS6F,mBAAW,IAAAjD,OAAA,EAAAA,EAAEuD,OACnC6J,SAAUN,EACVtP,UAAWA,EACXG,YAAaA,EACbG,yBAA0BA,EAC1BK,kBAAmBA,EACnBP,QAASA,EACTC,eAAgBA,EAChBE,eAAgBA,EAChBqI,eAAgBA,GAChBpI,eAAgBA,EAChBC,uBAAwBA,EACxBC,gBAAiBA,EACjBkJ,UAAWhK,aAAO,EAAPA,EAASgK,UACpB3J,aAAcA,EACdW,eAAgBA,EAChBC,YAAaA,EACbC,OAAQA,EACRC,WAAYA,EACZC,mBAAoBA,EACpB6O,WAAY5O,eAAAA,EAAe4O,WAC3BC,aAAc7O,aAAa,EAAbA,EAAe6O,aAC7B5O,iBAAkBA,EAClBC,gBAAiBA,GACjBK,UAAWA,GACX+E,qBAAsBA,GAEtB9E,cAAeA,GACfyC,kBAAmBA,GACnBJ,aAAcA,GACdiM,YAAavM"}
1
+ {"version":3,"file":"StaticProductContainer.js","sources":["../../../../src/components/StaticLineTable/StaticProductContainer.tsx"],"sourcesContent":["import React, { FC, useContext, useEffect, useRef, useState } from 'react';\nimport Styles from './StaticLineTable.module.scss';\nimport CarouselComponent from '../sharedCarousel/CarouselComponent';\nimport {\n getElementMaximumHeight,\n getNoteValues,\n setLocalStoreWithExpiry,\n viewport\n} from '../../utils/utils';\nimport StaticProduct from './StaticProduct';\nimport { PegaProductRequestBase, ProductRequestBase } from '../lineTable/lineTable.types';\nimport {\n fetchOfferingDataLineTableV2,\n fetchOttServiceOptions,\n getVocherPromotion\n} from '../../services/LineTableService';\nimport { LineTableBasicPropConfig } from '../../services/LineTableBasicPropConfig';\nimport {\n fetchFilteredProducts,\n fetchPegaProducts,\n fetchStaticProductIds,\n filterShogunProducts,\n getShogunSharedOffer,\n getTimeUntilNextTimerEvent,\n isShogunOfferResolved\n} from './Product.utils';\nimport { StaticProductContainerSchema, StaticProductSchema } from './StaticProductDatatypes';\nimport Cookies from 'js-cookie';\nimport { LINETABLE } from '../../Analytics/AnalyticsConstants';\nimport { trackEligibleItem } from '../../models/Analytics/items';\nimport {\n NEW,\n ONE_ECOMMERCE_HARDWARE_SUMMARY,\n ULTIMATEBUNDLE,\n VCTYPE,\n VOUCHER\n} from '../../utils/constants';\nimport { actionTypes, AppContext } from './StaticLineTableStore/StaticLineTableProvider';\n\n/**\n * Query-string parameter name used to trigger the Shogun/rewards (loyalty) flow.\n * The value is passed to the real offer API.\n */\nconst SHOGUN_QUERY_PARAM = 'gloxtoken';\n\n/**\n * Reads the Shogun/rewards token from the URL query-string. Returns null when\n * running outside the browser or when the parameter is not present.\n */\nconst getShogunTokenFromUrl = (): string | null => {\n if (typeof window === 'undefined') return null;\n const params = new URLSearchParams(window?.location?.search);\n return params?.get(SHOGUN_QUERY_PARAM);\n};\n\nconst StaticProductContainer: FC<StaticProductContainerSchema> = ({\n content,\n setGenericErrorModalDetails,\n metadata,\n tabIndex,\n constants,\n loginSuccess,\n activeIndex,\n mainContent,\n address,\n eligibleBundle,\n linecheckSuccessCallBack,\n selectedOption,\n basicConfigUrl,\n selectedExistingOption,\n setLoginSuccess,\n lineCheckCallBack,\n setToggleState,\n toggleState,\n noTabs,\n deviceFlow,\n deviceFlowCallBack,\n ubRatePlanObj,\n lineCheckOnClear,\n pegaIntegration,\n pegaCustomerInterest,\n useStoryblokOrder,\n isFetching,\n setIsFetching,\n isProdEnv,\n //US_31295\n toggleContent,\n localCacheDuration,\n apiCache\n}) => {\n const viewPort = viewport();\n const uniqueId: keyof typeof offeringData = content?._uid;\n const [offeringData, setOfferingData] = useState<any>();\n const [filteredProducts, setFilteredProducts] = useState<any>();\n const [newDisplayContent, setNewDisplayContent] = useState<any>();\n const offerEndpoint = LineTableBasicPropConfig?.getInstance()?.getBaseUrl();\n let AuthData: any = typeof window !== undefined && Cookies.get('sunriseAuth');\n AuthData = AuthData && JSON.parse(AuthData);\n const storeContext = useContext(AppContext);\n const isMobileFlow = content?.pageType === 'MOBILE';\n // Default apiCache to false if not explicitly set\n const resolvedApiCache = apiCache !== undefined ? apiCache : false;\n\n /**\n * Loyalty (Shogun) flow is active only when BOTH conditions are met:\n * 1. The Storyblok parent-level attribute `isRewardsFlow` is enabled.\n * 2. The URL query-string carries a non-empty `gloxtoken` parameter.\n * Any other combination falls back to the standard offer flow.\n */\n const shogunTokenFromUrl = getShogunTokenFromUrl();\n const isShogunFlow = Boolean(mainContent?.isRewardsFlow) && Boolean(shogunTokenFromUrl);\n //US_31295\n const getPriceToggle = () => {\n if (!toggleContent || !toggleContent.enableLoggedInPrice) return null;\n const stored = localStorage.getItem('userLoggedPricesToggle');\n if (stored === 'true') return true;\n if (stored === 'false') return false;\n const isNewCustomer = toggleContent?.customers?.toLowerCase() === NEW;\n if (isNewCustomer && toggleContent?.newUserToggleEnabled) {\n return true;\n }\n if (!isNewCustomer && toggleContent?.loggedUserToggleEnabled) {\n return true;\n }\n return null;\n };\n const [pricesToggleState, setPricesToggleState] = useState<any>(getPriceToggle);\n const [runOnLoad, setRunOnLoad] = useState<boolean>(true);\n const timerRefreshTimeoutRef = useRef<ReturnType<typeof setTimeout> | null>(null);\n const promoPayloadSignatureRef = useRef<string>('');\n const offerDataCacheRef = useRef<Record<string, { results: any[]; timestamp: number }>>({});\n\n useEffect(() => {\n setTimeout(() => {\n findHeight();\n }, 100);\n window?.addEventListener('resize', findHeight);\n window?.addEventListener('load', findHeight);\n return () => {\n window.removeEventListener('resize', findHeight);\n window.removeEventListener('load', findHeight);\n };\n }, [content?.productList, filteredProducts, newDisplayContent]);\n\n const findHeight = () => {\n if (noTabs) {\n const activeToggles = [toggleState?.TV, toggleState?.Netflix, toggleState?.gigaSpeed].filter(\n Boolean\n ).length;\n const hasTV = toggleState?.TV;\n const hasNetflix = toggleState?.Netflix;\n const hasGigaSpeed = toggleState?.gigaSpeed;\n\n const tabbIndex =\n hasTV && hasNetflix && hasGigaSpeed\n ? 3\n : (hasTV && hasNetflix) ||\n (activeToggles >= 2 && !(hasGigaSpeed && !hasTV && !hasNetflix))\n ? 2\n : activeToggles === 1 || activeToggles === 2\n ? 1\n : 0;\n\n getElementMaximumHeight('productCardV3' + `${tabbIndex}`, filteredProducts?.length);\n } else {\n getElementMaximumHeight('productCardV3' + `${activeIndex}`, content?.productList?.length);\n }\n };\n\n const hardwareSessionObj = sessionStorage.getItem(ONE_ECOMMERCE_HARDWARE_SUMMARY);\n const sessionData = hardwareSessionObj && JSON.parse(hardwareSessionObj);\n const deviceUltimateBundle = content?.enableFPB;\n\n useEffect(() => {\n if (offeringData && Object.keys(offeringData)?.length > 0) {\n trackEligibleItem('view', offeringData[uniqueId], '', LINETABLE, null, pegaIntegration);\n }\n //filter products by pega response\n if (pegaIntegration && offeringData && Object.keys(offeringData)?.length > 0) {\n const availableProducts =\n (content?.productList?.length && content?.productList) ||\n new Array(content?.productList?.length || 3).fill(1);\n\n const pegaProductsIds = offeringData[uniqueId]?.map((item: any) => item?.id);\n\n const onlyPegaProducts = availableProducts.filter((product: any) =>\n pegaProductsIds?.includes(product.products[0].reference.name)\n );\n\n //sort products by storyblok vs pega\n if (useStoryblokOrder) {\n onlyPegaProducts.sort((a: any, b: any) => {\n return availableProducts.indexOf(a) - availableProducts.indexOf(b);\n });\n } else {\n onlyPegaProducts.sort((a: any, b: any) => {\n return (\n pegaProductsIds.indexOf(a.products[0].reference.name) -\n pegaProductsIds.indexOf(b.products[0].reference.name)\n );\n });\n }\n\n setNewDisplayContent(onlyPegaProducts);\n setIsFetching(false);\n }\n\n // Shogun flow: filter storyblok product list to only the products returned by the\n // Shogun offer API (matched by productId). Logic lives in filterShogunProducts (Product.utils).\n if (isShogunFlow && offeringData && Object.keys(offeringData)?.length > 0) {\n const shogunProductIds = (offeringData[uniqueId] ?? []).map((item: any) => item?.id);\n const availableProducts =\n (content?.productList?.length && content?.productList) ||\n new Array(content?.productList?.length || 3).fill(1);\n\n setNewDisplayContent(filterShogunProducts(availableProducts, shogunProductIds));\n setIsFetching(false);\n }\n }, [offeringData]);\n\n useEffect(() => {\n if (\n offeringData &&\n Object.keys(offeringData)?.length > 0 &&\n !isMobileFlow &&\n eligibleBundle?.eligibleBundle\n ) {\n trackEligibleItem(\n 'available',\n offeringData[uniqueId],\n '',\n LINETABLE,\n eligibleBundle?.eligibleBundle,\n pegaIntegration\n );\n }\n }, [eligibleBundle, offeringData]);\n\n //US_31295\n useEffect(() => {\n if (typeof window === 'undefined') return;\n // window.dispatchEvent(\n // new CustomEvent('user-logged-prices-toggle-all', {\n // detail: {\n // auth: AuthData?.siteId ? true : false },\n // })\n // );\n const handleGlobalToggle = (e: any) => {\n setPricesToggleState(e.detail.value);\n };\n window.addEventListener('user-logged-prices-toggle-all', handleGlobalToggle);\n return () => {\n window.removeEventListener('user-logged-prices-toggle-all', handleGlobalToggle);\n };\n }, []);\n\n /**\n * Check if cached offer data is still valid based on localCacheDuration\n */\n const isCacheValid = (cacheKey: string, durationMinutes: number | undefined): boolean => {\n const cached = offerDataCacheRef.current[cacheKey];\n if (!cached) return false;\n\n // A duration of 0 explicitly disables cache reads and always forces a fresh request.\n if (durationMinutes === 0) return false;\n\n // If no duration is specified, cache never expires (until manually cleared).\n if (durationMinutes === undefined) return true;\n\n if (durationMinutes < 0) return true;\n\n const elapsedMinutes = (Date.now() - cached.timestamp) / (1000 * 60);\n return elapsedMinutes < durationMinutes;\n };\n\n /**\n * fetching offer response\n */\n const fetchOfferData = (forceRefresh: boolean = false) => {\n const ProductIds: ProductRequestBase[] = [];\n let pegaPayload: PegaProductRequestBase = { atlOffers: [] };\n // for getting product offer api call request and promo id list\n //existingCustomerBenefit without login\n let existingCustomer = mainContent?.enableExistingCustomer;\n let subscriptionType = mainContent?.subscriptionType;\n let bundle4PProduct = mainContent?.pageType == '4P' ? true : false;\n const enableReturnPromo = content?.isReturnPromo;\n const benefitExistingCustomer = selectedExistingOption?.length > 0 ? true : false;\n const benefitSubscriptionType = selectedExistingOption?.join(',');\n //US_31295\n subscriptionType =\n existingCustomer || pricesToggleState ? subscriptionType : benefitSubscriptionType;\n existingCustomer =\n ((existingCustomer || benefitExistingCustomer) && AuthData) ||\n pricesToggleState ||\n !toggleContent;\n\n if (AuthData?.siteId && toggleContent?.enableLoggedInPrice && toggleContent.customers !== NEW) {\n if (pricesToggleState == false) {\n subscriptionType = 'none';\n } else if (pricesToggleState === true) {\n subscriptionType = undefined;\n }\n }\n\n if (toggleContent?.enableLoggedInPrice && pricesToggleState === false) {\n existingCustomer = false;\n }\n const P2PEnabled = content?.enableP2P ? true : false;\n const cacheDuration = localCacheDuration ?? 1;\n const cacheKey = `tab-${tabIndex}`;\n\n // Serve from cache without triggering loading state\n if (!forceRefresh && isCacheValid(cacheKey, cacheDuration)) {\n setOfferingData({ [uniqueId]: offerDataCacheRef.current[cacheKey].results });\n return;\n }\n\n // Shogun flow: triggered when `gloxtoken` is present in the URL AND the\n // storyblok parent-level `isRewardsFlow` flag is enabled (see isShogunFlow).\n // All containers share a single API call via getShogunSharedOffer (Product.utils).\n if (isShogunFlow) {\n const gloxTokenId = shogunTokenFromUrl;\n\n if (gloxTokenId) {\n // Skip loading state when results are already in the shared cache.\n if (!isShogunOfferResolved(gloxTokenId)) {\n setIsFetching(true);\n }\n\n getShogunSharedOffer(gloxTokenId, uniqueId as string, offerEndpoint)\n .then((shogunResults: any[]) => {\n offerDataCacheRef.current[cacheKey] = { results: shogunResults, timestamp: Date.now() };\n setOfferingData({ [uniqueId]: shogunResults });\n setGenericErrorModalDetails({ showPopup: false });\n })\n .catch(() => {\n setGenericErrorModalDetails({\n showPopup: true,\n content: mainContent?.telesalesBlok?.[0]\n });\n })\n .finally(() => {\n setIsFetching(false);\n });\n return;\n }\n }\n\n setIsFetching(true);\n\n if (pegaIntegration) {\n pegaPayload = fetchPegaProducts(content, pegaCustomerInterest, 'LineItem');\n } else {\n fetchStaticProductIds(\n content?.productList,\n ProductIds,\n bundle4PProduct,\n mainContent?.optionId,\n //US_31295\n pricesToggleState\n );\n const newSignature = JSON.stringify(\n ProductIds.map((item: any) => ({ id: item?.id, promoIds: item?.promoIds || [] }))\n );\n promoPayloadSignatureRef.current = newSignature;\n }\n if (\n forceRefresh ||\n (tabIndex === activeIndex && !offeringData?.[uniqueId]) ||\n (tabIndex === activeIndex && loginSuccess) ||\n selectedExistingOption\n ) {\n try {\n fetchOfferingDataLineTableV2(\n pegaIntegration ? pegaPayload : ProductIds,\n content?._uid,\n offerEndpoint,\n existingCustomer,\n subscriptionType,\n enableReturnPromo,\n P2PEnabled,\n pegaIntegration,\n resolvedApiCache,\n deviceUltimateBundle\n )\n ?.then((resp: any) => {\n const results = resp?.[uniqueId as string] ?? [];\n offerDataCacheRef.current[cacheKey] = { results, timestamp: Date.now() };\n setOfferingData(resp);\n setGenericErrorModalDetails({ showPopup: false });\n })\n .catch((error: any) => {\n setGenericErrorModalDetails({\n showPopup: true,\n content: mainContent?.telesalesBlok?.[0]\n });\n })\n .finally(() => {\n setIsFetching(false);\n });\n } catch (err: any) {\n setGenericErrorModalDetails({\n showPopup: true,\n content: mainContent?.telesalesBlok?.[0]\n });\n }\n } else if (offeringData) {\n setIsFetching(false);\n }\n };\n\n useEffect(() => {\n if (timerRefreshTimeoutRef.current) {\n clearTimeout(timerRefreshTimeoutRef.current);\n timerRefreshTimeoutRef.current = null;\n }\n\n const isCurrentTab =\n activeIndex === tabIndex || activeIndex === undefined || activeIndex === null;\n\n if (!isCurrentTab) {\n return;\n }\n\n const nextTimerEventDelay = (content?.productList || []).reduce(\n (minimumDelay: number, product: any) => {\n const timer = product?.timer?.[0];\n const isCounterEnabled = timer?.enableCounter;\n\n if (!isCounterEnabled || !timer?.startTime || !timer?.endTime) {\n return minimumDelay;\n }\n\n const delay = getTimeUntilNextTimerEvent(timer.startTime, timer.endTime);\n\n if (delay <= 0) {\n return minimumDelay;\n }\n\n if (minimumDelay === 0 || delay < minimumDelay) {\n return delay;\n }\n\n return minimumDelay;\n },\n 0\n );\n\n if (nextTimerEventDelay <= 0) {\n return;\n }\n timerRefreshTimeoutRef.current = setTimeout(() => {\n const refreshProductIds: ProductRequestBase[] = [];\n fetchStaticProductIds(\n content?.productList,\n refreshProductIds,\n mainContent?.pageType == '4P',\n mainContent?.optionId,\n pricesToggleState\n );\n const nextSignature = JSON.stringify(\n refreshProductIds.map((item: any) => ({ id: item?.id, promoIds: item?.promoIds || [] }))\n );\n\n if (nextSignature === promoPayloadSignatureRef.current) {\n return;\n }\n\n // Clear cache before forcing refresh on timer expiry\n const cacheKey = `tab-${tabIndex}`;\n delete offerDataCacheRef.current[cacheKey];\n\n setOfferingData((prev: any) => {\n if (!prev || typeof prev !== 'object') {\n return prev;\n }\n\n return {\n ...prev,\n [uniqueId]: null\n };\n });\n fetchOfferData(true);\n }, nextTimerEventDelay);\n\n return () => {\n if (timerRefreshTimeoutRef.current) {\n clearTimeout(timerRefreshTimeoutRef.current);\n timerRefreshTimeoutRef.current = null;\n }\n };\n }, [activeIndex, tabIndex, content?.productList, uniqueId, offeringData]);\n\n /**\n * triggering offer api based for the selected tab\n */\n useEffect(() => {\n setRunOnLoad(true);\n if (activeIndex == tabIndex || activeIndex == null) {\n if (pricesToggleState !== undefined && offeringData?.[uniqueId]) {\n offeringData[uniqueId] = null;\n }\n fetchOfferData();\n setRunOnLoad(false);\n }\n }, [activeIndex]);\n\n useEffect(() => {\n if (AuthData?.siteId && loginSuccess) {\n // Clear cache on login to fetch fresh data\n const cacheKey = `tab-${tabIndex}`;\n delete offerDataCacheRef.current[cacheKey];\n fetchOfferData();\n sessionStorage.removeItem('vasPopUp');\n }\n }, [loginSuccess]);\n\n useEffect(() => {\n if (selectedOption != undefined && selectedExistingOption != undefined) {\n // Clear cache when selection options change to fetch fresh data\n const cacheKey = `tab-${tabIndex}`;\n delete offerDataCacheRef.current[cacheKey];\n fetchOfferData();\n }\n }, [selectedOption, selectedExistingOption]);\n\n //US_31295\n useEffect(() => {\n if (pricesToggleState === undefined || runOnLoad) return;\n // Clear cache when price toggle changes to fetch fresh data\n const cacheKey = `tab-${tabIndex}`;\n delete offerDataCacheRef.current[cacheKey];\n if (offeringData?.[uniqueId]) {\n offeringData[uniqueId] = null;\n }\n fetchOfferData();\n }, [pricesToggleState]);\n\n useEffect(() => {\n //For QoQa flow\n const queryParams = window && new URLSearchParams(window?.location.search);\n const voucher: string | null = queryParams?.get(VOUCHER);\n if (\n voucher &&\n content?.productList?.[0]?.products?.[0]?.reference?.content?.product?.[0]?.productId\n ) {\n try {\n getVocherPromotion(\n content?.productList?.[0]?.products?.[0]?.reference?.content?.product?.[0]?.productId,\n voucher\n ).then((res: any) => {\n res && setLocalStoreWithExpiry(VCTYPE, { voucher: voucher, voucherType: 'qoqa' });\n });\n } catch (err: any) {}\n }\n\n //To trigger serviceOptions APi by category and updating it in context\n if (storeContext && tabIndex === activeIndex) {\n const { store, dispatch } = storeContext;\n let enableTvOptions = false;\n let enableTvOptionsPopUp = false;\n (content?.productList || [])?.forEach((prod: any) => {\n if (prod?.enableTVStreamingOptionsPopUp) {\n enableTvOptionsPopUp = true;\n }\n if (prod?.enableTVStreamingOptions) {\n enableTvOptions = true;\n }\n });\n if (store?.ottOptionsApi?.length === 0 && (enableTvOptions || enableTvOptionsPopUp)) {\n fetchOttServiceOptions()\n ?.then((res: any) => {\n if (res?.length > 0) {\n dispatch({ type: actionTypes?.ottOptionsApi, payload: res });\n }\n })\n .catch(() => {});\n }\n }\n }, []);\n\n //No Tabs content set\n let displayContent: any = [];\n useEffect(() => {\n if (noTabs) {\n displayContent = fetchFilteredProducts(content?.productList, toggleState);\n setFilteredProducts(displayContent);\n }\n }, [toggleState]);\n\n // sending offer api data as callback in device Flow to identify Multimobile/fmc\n useEffect(() => {\n if (deviceFlow?.isDeviceFlow && offeringData) {\n deviceFlow?.prodcardcallbackOfferApiData(offeringData);\n }\n }, [offeringData]);\n\n const getProductId = (content: any) => {\n const productData = content?.products?.[0]?.reference?.content?.product?.[0];\n return productData?.productId;\n };\n\n useEffect(() => {\n if (noTabs && !deviceFlow?.isDeviceFlow) {\n setNewDisplayContent(filteredProducts);\n } else {\n setNewDisplayContent(\n (content?.productList?.length && content?.productList) ||\n new Array(content?.productList?.length || 3).fill(1)\n );\n }\n }, [filteredProducts]);\n\n return (\n <div>\n <div className={Styles['titlecontainer']}>\n {content?.title && <div className={Styles['title']}>{content?.title}</div>}\n {content?.subTitle && <div className={Styles['description']}>{content?.subTitle}</div>}\n </div>\n <div className={`linetableV3`}>\n {viewPort && newDisplayContent && newDisplayContent?.length > 0 && (\n <CarouselComponent\n carouselIndex={0}\n key={activeIndex}\n arrow={mainContent?.enableMobileArrows}\n >\n {newDisplayContent &&\n newDisplayContent?.length > 0 &&\n (newDisplayContent || [])?.map((data: StaticProductSchema, indexx: number) => {\n return (\n <div\n id={`productCardV3${activeIndex}`}\n style={{ textAlign: 'center' }}\n key={indexx}\n >\n <StaticProduct\n content={pegaIntegration && isFetching && !offeringData ? {} : data}\n offeringData={offeringData}\n uniqueId={uniqueId}\n storyContent={content}\n metadata={metadata}\n tabIndex={tabIndex}\n cardsLength={content?.productList?.length}\n indexKey={indexx}\n constants={constants}\n mainContent={mainContent}\n linecheckSuccessCallBack={linecheckSuccessCallBack}\n lineCheckCallBack={lineCheckCallBack}\n address={address}\n eligibleBundle={eligibleBundle}\n selectedOption={selectedOption}\n fetchOfferData={fetchOfferData}\n basicConfigUrl={basicConfigUrl}\n selectedExistingOption={selectedExistingOption}\n setLoginSuccess={setLoginSuccess}\n enableP2P={content?.enableP2P}\n loginSuccess={loginSuccess}\n setToggleState={setToggleState}\n toggleState={toggleState}\n noTabs={noTabs}\n deviceFlow={deviceFlow}\n deviceFlowCallBack={deviceFlowCallBack}\n selectedRP={ubRatePlanObj?.selectedRP}\n continueCart={ubRatePlanObj?.continueCart}\n lineCheckOnClear={lineCheckOnClear}\n pegaIntegration={pegaIntegration}\n isProdEnv={isProdEnv}\n deviceUltimateBundle={deviceUltimateBundle}\n //US_31295\n toggleContent={toggleContent}\n pricesToggleState={pricesToggleState}\n isShogunFlow={isShogunFlow}\n shogunToken={shogunTokenFromUrl}\n />\n </div>\n );\n })}\n </CarouselComponent>\n )}\n </div>\n </div>\n );\n};\n\nexport default StaticProductContainer;\n"],"names":["StaticProductContainer","content","setGenericErrorModalDetails","metadata","tabIndex","constants","loginSuccess","activeIndex","mainContent","address","eligibleBundle","linecheckSuccessCallBack","selectedOption","basicConfigUrl","selectedExistingOption","setLoginSuccess","lineCheckCallBack","setToggleState","toggleState","noTabs","deviceFlow","deviceFlowCallBack","ubRatePlanObj","lineCheckOnClear","pegaIntegration","pegaCustomerInterest","useStoryblokOrder","isFetching","setIsFetching","isProdEnv","toggleContent","localCacheDuration","apiCache","viewPort","viewport","uniqueId","_uid","offeringData","setOfferingData","useState","filteredProducts","setFilteredProducts","newDisplayContent","setNewDisplayContent","offerEndpoint","_a","LineTableBasicPropConfig","getInstance","getBaseUrl","AuthData","undefined","window","Cookies","get","JSON","parse","storeContext","useContext","AppContext","isMobileFlow","pageType","resolvedApiCache","shogunTokenFromUrl","params","URLSearchParams","location","search","getShogunTokenFromUrl","isShogunFlow","Boolean","isRewardsFlow","pricesToggleState","setPricesToggleState","enableLoggedInPrice","stored","localStorage","getItem","isNewCustomer","customers","toLowerCase","NEW","newUserToggleEnabled","loggedUserToggleEnabled","runOnLoad","setRunOnLoad","timerRefreshTimeoutRef","useRef","promoPayloadSignatureRef","offerDataCacheRef","useEffect","setTimeout","findHeight","addEventListener","removeEventListener","productList","activeToggles","TV","Netflix","gigaSpeed","filter","length","hasTV","hasNetflix","hasGigaSpeed","getElementMaximumHeight","hardwareSessionObj","sessionStorage","ONE_ECOMMERCE_HARDWARE_SUMMARY","deviceUltimateBundle","enableFPB","Object","keys","trackEligibleItem","LINETABLE","_b","availableProducts","_c","Array","_d","fill","pegaProductsIds","_e","map","item","id","onlyPegaProducts","product","includes","products","reference","name","sort","a","b","indexOf","_f","shogunProductIds","_g","_h","_j","filterShogunProducts","handleGlobalToggle","e","detail","value","fetchOfferData","forceRefresh","ProductIds","pegaPayload","atlOffers","existingCustomer","enableExistingCustomer","subscriptionType","bundle4PProduct","enableReturnPromo","isReturnPromo","benefitExistingCustomer","benefitSubscriptionType","join","siteId","P2PEnabled","enableP2P","cacheKey","durationMinutes","cached","current","Date","now","timestamp","isCacheValid","gloxTokenId","isShogunOfferResolved","getShogunSharedOffer","then","shogunResults","results","showPopup","catch","telesalesBlok","finally","fetchPegaProducts","fetchStaticProductIds","optionId","newSignature","stringify","promoIds","fetchOfferingDataLineTableV2","resp","error","err","clearTimeout","nextTimerEventDelay","reduce","minimumDelay","timer","enableCounter","startTime","endTime","delay","getTimeUntilNextTimerEvent","refreshProductIds","prev","assign","removeItem","queryParams","voucher","VOUCHER","productId","getVocherPromotion","_q","_p","_m","_l","_o","_r","res","setLocalStoreWithExpiry","VCTYPE","voucherType","store","dispatch","enableTvOptions","enableTvOptionsPopUp","_s","forEach","prod","enableTVStreamingOptionsPopUp","enableTVStreamingOptions","ottOptionsApi","_t","_u","fetchOttServiceOptions","type","actionTypes","payload","displayContent","fetchFilteredProducts","isDeviceFlow","prodcardcallbackOfferApiData","React","createElement","className","Styles","title","subTitle","CarouselComponent","carouselIndex","key","arrow","enableMobileArrows","data","indexx","style","textAlign","StaticProduct","storyContent","cardsLength","indexKey","selectedRP","continueCart","shogunToken"],"mappings":"omCA2CA,MAYMA,EAA2D,EAC/DC,UACAC,8BACAC,WACAC,WACAC,YACAC,eACAC,cACAC,cACAC,UACAC,iBACAC,2BACAC,iBACAC,iBACAC,yBACAC,kBACAC,oBACAC,iBACAC,cACAC,SACAC,aACAC,qBACAC,gBACAC,mBACAC,mBACAC,wBACAC,qBACAC,cACAC,iBACAC,aAEAC,iBACAC,sBACAC,0BAEA,MAAMC,GAAWC,IACXC,GAAsClC,aAAO,EAAPA,EAASmC,MAC9CC,GAAcC,IAAmBC,KACjCC,GAAkBC,IAAuBF,KACzCG,GAAmBC,IAAwBJ,IAC5CK,GAAuD,QAAvCC,GAAAC,aAAwB,EAAxBA,EAA0BC,qBAAa,IAAAF,QAAA,EAAAA,GAAEG,aAC/D,IAAIC,QAAkCC,WAAXC,QAAwBC,EAAQC,IAAI,eAC/DJ,GAAWA,IAAYK,KAAKC,MAAMN,IAClC,MAAMO,GAAeC,EAAWC,GAC1BC,GAAqC,YAAtB1D,aAAO,EAAPA,EAAS2D,UAExBC,QAAgCX,IAAblB,IAAyBA,GAQ5C8B,GA5DsB,YAC5B,GAAsB,oBAAXX,OAAwB,OAAO,KAC1C,MAAMY,EAAS,IAAIC,gBAAgC,UAAV,OAANb,aAAM,IAANA,YAAM,EAANA,OAAQc,gBAAQ,IAAApB,OAAA,EAAAA,EAAEqB,QACrD,OAAOH,aAAM,EAANA,EAAQV,IATU,cAkEEc,GACrBC,GAAeC,QAAQ7D,aAAW,EAAXA,EAAa8D,gBAAkBD,QAAQP,KAgB7DS,GAAmBC,IAAwBjC,EAd3B,WACrB,IAAKT,KAAkBA,GAAc2C,oBAAqB,OAAO,KACjE,MAAMC,EAASC,aAAaC,QAAQ,0BACpC,GAAe,SAAXF,EAAmB,OAAO,EAC9B,GAAe,UAAXA,EAAoB,OAAO,EAC/B,MAAMG,GAAwC,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IAAYS,KAAqBA,cAAiB,EAAjBA,GAAmB0D,QAAS,GAC5D2I,EAAAC,cAACK,GACCC,cAAe,EACfC,IAAKhP,EACLiP,MAAOhP,aAAW,EAAXA,EAAaiP,oBAEnB/M,KACCA,cAAiB,EAAjBA,GAAmB0D,QAAS,IACH,QAAzBc,GAACxE,IAAqB,UAAG,IAAAwE,QAAA,EAAAA,GAAEQ,IAAI,CAACgI,EAA2BC,WACzD,OACEZ,EAAAC,cAAA,MAAA,CACEpH,GAAI,gBAAgBrH,IACpBqP,MAAO,CAAEC,UAAW,UACpBN,IAAKI,GAELZ,EAAAC,cAACc,EAAa,CACZ7P,QAASuB,IAAmBG,KAAeU,GAAe,CAAA,EAAKqN,EAC/DrN,aAAcA,GACdF,SAAUA,GACV4N,aAAc9P,EACdE,SAAUA,EACVC,SAAUA,EACV4P,YAAiC,QAApBnN,EAAA5C,aAAO,EAAPA,EAAS6F,mBAAW,IAAAjD,OAAA,EAAAA,EAAEuD,OACnC6J,SAAUN,EACVtP,UAAWA,EACXG,YAAaA,EACbG,yBAA0BA,EAC1BK,kBAAmBA,EACnBP,QAASA,EACTC,eAAgBA,EAChBE,eAAgBA,EAChBqI,eAAgBA,GAChBpI,eAAgBA,EAChBC,uBAAwBA,EACxBC,gBAAiBA,EACjBkJ,UAAWhK,aAAO,EAAPA,EAASgK,UACpB3J,aAAcA,EACdW,eAAgBA,EAChBC,YAAaA,EACbC,OAAQA,EACRC,WAAYA,EACZC,mBAAoBA,EACpB6O,WAAY5O,eAAAA,EAAe4O,WAC3BC,aAAc7O,aAAa,EAAbA,EAAe6O,aAC7B5O,iBAAkBA,EAClBC,gBAAiBA,GACjBK,UAAWA,GACX+E,qBAAsBA,GAEtB9E,cAAeA,GACfyC,kBAAmBA,GACnBH,aAAcA,GACdgM,YAAatM"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sunrise-upc/mobile-prod-card",
3
- "version": "12.1.4",
3
+ "version": "12.2.0-beta.0",
4
4
  "description": "Starter project to create reusable functional component",
5
5
  "type": "module",
6
6
  "main": "dist/esm/index.js",
@@ -31,7 +31,8 @@
31
31
  "release:minor": "npm version minor && npm publish --access public --tag latest",
32
32
  "release:patch": "npm version patch && npm publish --access public --tag latest",
33
33
  "release:prepatch": "npm version prepatch --preid=beta && npm publish --access public --tag latest",
34
- "release:prerelease": "npm version prerelease --preid=beta && npm publish --access public --tag latest"
34
+ "release:prerelease": "npm version prerelease --preid=beta && npm publish --access public --tag latest",
35
+ "release:beta:minor": "npm version preminor --preid=beta && npm publish --access public --tag beta"
35
36
  },
36
37
  "repository": {
37
38
  "type": "git",