PageSourceSearch

https://www.lycamobile.de/_next/static/chunks/7769-8063d0695e6665a4.js

js lycamobile.de collected 2026-09-28 06:48:02 UTC 148,594 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[7769],{4207:l=>{l.exports={headerContainer:"deliveryPayment_headerContainer__L67UZ",progressBarContainer:"deliveryPayment_progressBarContainer__Mbt3a",progressLabel:"deliveryPayment_progressLabel__dpdEm",marketingHeading:"deliveryPayment_marketingHeading__bg8eX",heading:"deliveryPayment_heading__Rw_TJ",mainContainer:"deliveryPayment_mainContainer__4APTE",main:"deliveryPayment_main__7dx_c",deliveryPaymentTitle:"deliveryPayment_deliveryPaymentTitle___wSZg",freeSim:"deliveryPayment_freeSim__voloQ",ssnMain:"deliveryPayment_ssnMain__3_zC9",imageWrapperAreaCover:"deliveryPayment_imageWrapperAreaCover__bq5o9",mapGreen:"deliveryPayment_mapGreen__jdbmA",promoCode:"deliveryPayment_promoCode__Dk2cf",ssnInside:"deliveryPayment_ssnInside__Uaj11",checkSuccess:"deliveryPayment_checkSuccess__wJbdj",ssn_text:"deliveryPayment_ssn_text__CK2Kz",deactivePlan:"deliveryPayment_deactivePlan__Q99yg",activePlan:"deliveryPayment_activePlan__P_7Hp",hotSIMSwitch_Portin:"deliveryPayment_hotSIMSwitch_Portin___e3FE",mainHead:"deliveryPayment_mainHead__0sUor",hotSimHead:"deliveryPayment_hotSimHead__eGIy4",textHead:"deliveryPayment_textHead__vCL3l",radioButton:"deliveryPayment_radioButton__Pluxm",areaCoverageMain:"deliveryPayment_areaCoverageMain__UTQH5",checkAreaCoverageInside:"deliveryPayment_checkAreaCoverageInside__W0648",zipFieldWrapper:"deliveryPayment_zipFieldWrapper__tsrKX",coverageSuccess:"deliveryPayment_coverageSuccess__kRNsy",coverageSubHeading:"deliveryPayment_coverageSubHeading__21PL4"}},7769:(l,e,n)=>{"use strict";n.r(e),n.d(e,{default:()=>lk});var i=n(37876),o=n(14232),t=n(27921),d=n(6995),a=n(9129),r=n(55134),s=n(5067),u=n(84733),c=n(21758),v=n(33034),_=n(54587),m=n.n(_),p=n(4207),y=n.n(p),f=n(34260),g=n(16455),h=n(81516),b=n(94528),A=n.n(b),x=n(77225),S=n(31777),I=n(23683),C=n.n(I),D=n(80063),j=n(4833),T=n(89099),F=n(60849),w=n(40501),P=n(95694),N=n(52864),k=n(79927),$=n(41244),M=n(29671),E=n(85488),H=n(1127),O=n(13201),L=n(44058),B=n(81004);let U=l=>{var e,n,t,r,u,c,v,_,p,y,b,I,U,z,G,R,V,W,J,K,q,Z,X,Y,Q,ll;let{handleDeliveryData:le,country:ln,error:li,type:lo,isQuickTopUp:lt=!1,open:ld,freeSim:la,freeSimClicked:lr,allPlanFromFreeSim:ls,adobeData:lu,typeOfSim:lc,isMarkingPage:lv,fieldInteractionDetails:l_,hideFormOnly:lm=!1}=l,lp=null;lp=window;let ly=(0,j.KeO)(),lf=(null==lp||null==(e=lp.location)?void 0:e.host)&&(0,k.A)(null==lp||null==(n=lp.location)?void 0:n.host),lg=(0,o.useRef)(null),lh=(0,o.useRef)(null),lb=(0,d.A)("(max-width:768px)"),lA=(0,S.wA)(),lx=(0,S.d4)(D.Xk),lS=(null==lx?void 0:lx.show_phone_number_delivery_address)||!1,lI=(0,S.d4)(D.tL),lC=(0,S.d4)(D.Rl),lD=(0,S.d4)(D.Bn),lj=!(null==lf?void 0:lf.smartSearch)||!1===lx.address_finder,lT=(0,S.d4)(D.HX),lF=(0,S.d4)(D.O),[lw,lP]=(0,o.useState)(!1),[lN,lk]=(0,o.useState)(""),[l$,lM]=(0,o.useState)(!1),[lE,lH]=(0,o.useState)(!1),[lO,lL]=(0,o.useState)([]),[lB,lU]=(0,o.useState)([]),[lz,lG]=(0,o.useState)([]),[lR,lV]=(0,o.useState)(!1),lW=(null==lD?void 0:lD.country_code)==="IT",[lJ,lK]=(0,o.useState)(!!lj||(lt?null==lF||null==(t=lF.billingInfo)?void 0:t.billingMannualAddress:"billingAddess"===lo?null==lT||null==(r=lT.billingInfo)?void 0:r.billingMannualAddress:(null==lT||null==(u=lT.delivery_info)?void 0:u.billingMannualAddress)||!1)),[lq,lZ]=(0,o.useState)(lt?null==lF||null==(c=lF.billingInfo)?void 0:c.addressFinderValue:(null==lT||null==(v=lT.delivery_info)?void 0:v.addressFinder)?(null==lT||null==(_=lT.billingInfo)?void 0:_.override)?null==lT||null==(p=lT.billingInfo)?void 0:p.addressFinderValue:null==lT||null==(y=lT.delivery_info)?void 0:y.addressFinderValue:(null==lT||null==(b=lT.billingInfo)?void 0:b.addressFinder)?null==lT||null==(I=lT.billingInfo)?void 0:I.addressFinderValue:""),[l
1X,lY]=(0,o.useState)(""),[lQ,l0]=(0,o.useState)(!1),[l1,l2]=(0,o.useState)(!1),[l4,l5]=(0,o.useState)(""),l3=(null==lD?void 0:lD.country_code)=="MK",l8=!!l3||(null==lx?void 0:lx.disable_manual_address)||!1,l9=l4.trim().length===(null==lx?void 0:lx.msisdn_length),[l7,l6]=(0,o.useState)({cityId:(null==lT||null==(U=lT.delivery_info)?void 0:U.city)||"",municipalityId:(null==lT||null==(z=lT.delivery_info)?void 0:z.muncipality)||""}),el=(0,T.useRouter)(),{currentStep:ee,formStep:en}=l_??{},ei=(0,o.useRef)(new Set);(0,o.useEffect)(()=>{l3&&(null==lO?void 0:lO.length)===0&&eo(),l3&&l7.cityId&&(null==lB?void 0:lB.length)===0&&et(),l3&&l7.municipalityId&&(null==lz?void 0:lz.length)===0&&ed()},[l3,l7,lO,lB,lz]);let eo=async()=>{try{let{data:l,status:e}=await (null===H.A||void 0===H.A?void 0:H.A.get(null===O.t||void 0===O.t?void 0:O.t.getAllCityMacedonia("")));if(l&&200==e){let e=null==l?void 0:l.map(l=>({...l,value:null==l?void 0:l.id,label:null==l?void 0:l.name}));lL(e)}}catch(n){var l,e;lA((0,B.ZD)({display:!0,severity:"error",message:`${f.A.city} ${null==n||null==(e=n.response)||null==(l=e.data)?void 0:l.message}`})),console.log(n)}},et=async()=>{if((null==lO?void 0:lO.length)>0)try{let l=null==lO?void 0:lO.find(l=>(null==l?void 0:l.id)===(null==l7?void 0:l7.cityId)),{data:e,status:n}=await (null===H.A||void 0===H.A?void 0:H.A.get(null===O.t||void 0===O.t?void 0:O.t.getAllCityMacedonia(`?type=city&id=${null==l?void 0:l.id}`)));if(e&&200==n){let l=null==e?void 0:e.map(l=>({...l,value:null==l?void 0:l.id,label:null==l?void 0:l.name}));lU(l)}}catch(n){var l,e;console.log("error",n),lA((0,B.ZD)({display:!0,severity:"error",message:`${f.A.muncipality} ${null==n||null==(e=n.response)||null==(l=e.data)?void 0:l.message}`})),console.log(n)}},ed=async()=>{if((null==lB?void 0:lB.length)>0)try{let l=null==lB?void 0:lB.find(l=>(null==l?void 0:l.id)===(null==l7?void 0:l7.municipalityId)),{data:e,status:n}=await (null===H.A||void 0===H.A?void 0:H.A.get(null===O.t||void 0===O.t?void 0:O.t.getAllCityMacedonia(`?type=municipality&id=${null==l?void 0:l.id}`)));if(e&&200==n){let l=null==e?void 0:e.map(l=>({...l,value:null==l?void 0:l.id,label:null==l?void 0:l.name}));lG(l)}}catch(n){var l,e;lA((0,B.ZD)({display:!0,severity:"error",message:`${f.A.place} ${null==n||null==(e=n.response)||null==(l=e.data)?void 0:l.message}`})),console.log(n)}};(0,o.useEffect)(()=>{ea()},[lC]),(0,o.useEffect)(()=>{if(null==el?void 0:el.query){let{retry:c=""}=el.query;if("true"===c){var l,e,n,i,o,t,d,a,r,s,u;let c=(0,F.wb)(w.H.personalDetails,!0),v=c&&JSON.parse(c);lZ(lt?null==lF||null==(l=lF.billingInfo)?void 0:l.addressFinderValue:(null==lT||null==(e=lT.delivery_info)?void 0:e.addressFinder)?"billingAddess"===lo?(null==lT||null==(n=lT.billingInfo)?void 0:n.override)?null==lT||null==(i=lT.billingInfo)?void 0:i.addressFinderValue:null==lT||null==(o=lT.delivery_info)?void 0:o.addressFinderValue:null==lT||null==(t=lT.delivery_info)?void 0:t.addressFinderValue:(null==lT||null==(d=lT.billingInfo)?void 0:d.addressFinder)?null==lT||null==(a=lT.billingInfo)?void 0:a.addressFinderValue:""),(!lt||(null==lF?void 0:lF.billingInfo))&&(lt||(null==lT?void 0:lT.billingInfo)&&(null==lT?void 0:lT.delivery_info))||(lK(!!lj||(lt?null==lF||null==(r=lF.billingInfo)?void 0:r.billingMannualAddress:"billingAddess"===lo?null==v||null==(s=v.billingInfo)?void 0:s.billingMannualAddress:(null==v||null==(u=v.delivery_info)?void 0:u.billingMannualAddress)||!1)),(null==v?void 0:v.billingInfo)&&(null==v?void 0:v.delivery_info)&&lA((0,D.X0)(v)))}}},[null==el?void 0:el.query,lA,lT]),(0,o.useEffect)(()=>{(null==lT?void 0:lT.contact_number)&&l5(null==lT?void 0:lT.contact_number)},[null==lT?void 0:lT.contact_number]);let ea=async()=>{try{var l,e;let n=null==lC||null==(e=lC.data)||null==(l=e.getDestinationsListing)?void 0:l.edges;if(n&&(null==lD?void 0:lD.country_code)){let l=n.filter(l=>{var e,n,i;if((null==(e=l.node)?void 0:e.country)&&(null==(n=l.node)?void 0:n.countryCode))return(null==(i=l.node)?void 0:i.countryCode)===("SW"===lD.country_code?"CH":lD.country_code)}).map(l=>{var e;return(null==l||null==(e=l.node)?void 0:e.key)||""});lk((null==l?void 0:l[0])||(null==lD?void 0:lD.country_name))}else lk("")}catch(l){console.error("Error fetching countries:",l)}},er=(0,o.useCallback)(l=>{let e;lZ(l);let n=null;if(l&&(n=(0,P.Y)(null==l?void 0:l.Address,lN,null==lx?void 0:lx.country_code)),"billingAddess"===lo){var i,o;e={...lT,paypalInfo:null,billingInfo:{billingMannualAddress:!1,billingAddressFinderData:n,addressFinderValue:l,addressFinder:!0,override:!0,isvalid:(null==lh||null==(o=lh.current)||null==(i=o.getFormData())?void 0:i.isFormValid)||!1}}}else e={...lT,delivery_info:{...n,billingMannualAddress:!!n,deliveryInfoAddressFinderData:n,addressFinder:!0,addressFinderValue:l,override:!1,isvalid:!!l&&lE},paypalInfo:null,billingInfo:{...n,billingMannualAddress:!0,billingAddressFinderData:n,addressFinderValue:l,addressFinder:!0,override:!1,overrideValue:n&&(0,j.qZB)(n),isvalid:!0}};lt?lA((0,D.x5)({...lF,paypalInfo:null,billingInfo:e.billingInfo})):lA((0,D.X0)({...lT,...e})),lK(!0)},[lT]),es=(l,e,n,i)=>{let o;if(l3&&("city"===l&&(l6(l=>({...l,cityId:n.city,municipalityId:""})),n.muncipality="",n.muncipalityError=!0,n.place="",n.placeError=!0,lU([]),lG([])),"muncipality"===l&&(l6(l=>({...l,municipalityId:n.muncipality})),lG([]),n.place="",n.placeError=!0)),i){let l=(0,j._1n)(n);if(le&&"billingAddess"===lo)le(n,i),o={...lT,paypalInfo:null,delivery_info_isvali
1d:i,billingInfo:{...l,isvalid:i,billingMannualAddress:!0,addressFinder:!lt,override:!0}};else{var t,d,a,r,s,u;o={...lT,delivery_info:{...l,isvalid:i,billingMannualAddress:!0,delivery_info_isvalid:i,addressFinder:(null==lT||null==(t=lT.delivery_info)?void 0:t.addressFinder)&&!lj,addressFinderValue:(null==lT||null==(d=lT.delivery_info)?void 0:d.billingMannualAddress)&&(null==lT||null==(a=lT.delivery_info)?void 0:a.addressFinder)&&(null==lT||null==(r=lT.delivery_info)?void 0:r.addressFinderValue)||null,override:!0},paypalInfo:null,billingInfo:{...l,isvalid:i,billingMannualAddress:!0,addressFinder:!1,overrideValue:l&&(0,j.qZB)(l),override:(null==lT||null==(s=lT.billingInfo)?void 0:s.override)||!1}},(null==lT?void 0:lT.billingInfo)&&!(null==lT||null==(u=lT.billingInfo)?void 0:u.override)&&lA((0,D.b9)({...lI,...null==lT?void 0:lT.billingInfo}))}lt?lA((0,D.x5)({...lF,paypalInfo:null,billingInfo:null==o?void 0:o.billingInfo})):lA((0,D.X0)(o))}else"billingAddess"!==lo&&lA((0,D.X0)({...lT,delivery_info_isvalid:!1}));!ei.current.has(l)&&(null==e?void 0:e.length)>0&&(ei.current.add(l),(0,M.$d)((0,M.ar)(null==lu?void 0:lu.basketState),ee,en,`Domestic shipping address ${l}`,"checkout"))};(0,o.useEffect)(()=>{lM(li)},[li]);let eu="billingAddess"===lo,ec=()=>{lP(!lw)},ev=()=>{er(null),lP(!lw)},e_=()=>{er(null),lK(!1),lA((0,D.X0)({...lT,delivery_info:{isvalid:!1},delivery_info_isvalid:!1,billingInfo_isvalid:!1}))},em=l=>{lt||(lH(l),lA((0,D.X0)({...lT,delivery_info:null==lT?void 0:lT.delivery_info,delivery_info_isvalid:l,billingInfo_isvalid:(null==lT?void 0:lT.billingInfo_isvalid)||l||!1})))},ep=(null==lc?void 0:lc.toLowerCase())!=="esim"&&(null==lD?void 0:lD.country_code)==="IT",ey=(null==lT?void 0:lT.delivery_info)===void 0&&lJ||!!(null==lT||null==(G=lT.delivery_info)?void 0:G.billingMannualAddress)&&"billingAddess"!==lo&&!(null==lT||null==(R=lT.delivery_info)?void 0:R.addressFinder),ef=function(){var l,e,n,i;let o,t=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if((0,M.$d)((0,M.ar)(null==lu?void 0:lu.basketState),ee,en,"Change Address btn","checkout"),t&&(()=>{var l,e,n,i,o,t,d,a,r,s,u,c,v,_,m,p,y,f,g,h,b,A,x,S,I,C;if(la&&lr&&(null==ls?void 0:ls.length)===0){let e={event:"addressConfirmation",customerType:ly?"logged-in":"non-logged-in",journeyName:null===w.H||void 0===w.H?void 0:w.H.freesimJourneyName,currencyCode:(null==lf||null==(l=lf.tradeDoubler)?void 0:l.currencyCode)||"na",simType:lc,products:[{SKU:"sim",name:"SIM 1",price:"0",quantity:"1"}]};(0,M.Rd)(e)}if(la&&(null==ls?void 0:ls.length)>0){let l=(null==ls||null==(n=ls[0])||null==(e=n.bundleGroupDetails[0])?void 0:e.promotionalPricing)?null==ls||null==(t=ls[0])||null==(o=t.bundleGroupDetails)||null==(i=o[0])?void 0:i.promotionalPricing:null==ls||null==(r=ls[0])||null==(a=r.bundleGroupDetails)||null==(d=a[0])?void 0:d.basePrice,D=(null==ls||null==(u=ls[0])||null==(s=u.bundleGroupDetails[0])?void 0:s.basePrice)?null==ls||null==(_=ls[0])||null==(v=_.bundleGroupDetails)||null==(c=v[0])?void 0:c.basePrice:null==ls||null==(y=ls[0])||null==(p=y.bundleGroupDetails)||null==(m
1=p[0])?void 0:m.promotionalPricing,j={event:"addressConfirmation",customerType:ly?"logged-in":"non-logged-in",journeyName:null===w.H||void 0===w.H?void 0:w.H.freesimJourneyName,currencyCode:(null==lf||null==(f=lf.tradeDoubler)?void 0:f.currencyCode)||"na",simType:lc,products:[{SKU:"sim",name:"SIM 1",price:"0",quantity:"1"},{SKU:"bundle",name:null==ls||null==(g=ls[0])?void 0:g.productName,price:l?`${l}`:"0",quantity:"1",renewal_type:(null==ls||null==(b=ls[0])||null==(h=b.bundleGroupDetails)?void 0:h.length)>1?`${null==ls||null==(x=ls[0])||null==(A=x.selectedMonthlyBundleVal)?void 0:A.productValidity}M-yes`:"yes",auto_renewal:"yes",pimId:(null==ls||null==(S=ls[0])?void 0:S.id)||"",productCode:(null==ls||null==(C=ls[0])||null==(I=C.bundleGroupDetails[0])?void 0:I.bundleCode)||"",discount:`${parseInt(D||0)-parseInt(l||0)}`||"0"}]};(0,M.Rd)(j)}!la&&!lr&&(null==lu?void 0:lu.basketState)&&(0,M.sY)(lu)})(),l3){let i=null==lz||null==(l=lz.find(l=>{var e;return(null==l?void 0:l.id)===(null==lT||null==(e=lT.delivery_info)?void 0:e.place)}))?void 0:l.name;o={placeName:i,muncipalityName:null==lB||null==(e=lB.find(l=>{var e;return(null==l?void 0:l.id)===(null==lT||null==(e=lT.delivery_info)?void 0:e.muncipality)}))?void 0:e.name,cityName:null==lO||null==(n=lO.find(l=>{var e;return(null==l?void 0:l.id)===(null==lT||null==(e=lT.delivery_info)?void 0:e.city)}))?void 0:n.name}}lS&&(null==l4?void 0:l4.length)?lA((0,D.X0)({...lT,contact_number:(0,j.beD)(l4)?null==l4?void 0:l4.slice(1):l4,collapseDelivery:!(null==lT?void 0:lT.collapseDelivery),deliveryAddressConfirm:!0,delivery_info:{...null==lT?void 0:lT.delivery_info,...o}})):lA((0,D.X0)({...lT,collapseDelivery:!(null==lT?void 0:lT.collapseDelivery),deliveryAddressConfirm:!0,delivery_info:{...null==lT?void 0:lT.delivery_info,...o},billingInfo:{override:!1,...lT.billigIfo,overrideValue:(0,j.qZB)({...null==(i=lT.billigIfo)?void 0:i.overrideValue,dropdownValue:o})}}))},eg=(0,o.useMemo)(()=>!lj&&"billingAddess"!==lo&&!l8&&(0,i.jsx)(s.A,{variant:"h5",my:0,sx:{marginTop:lS?"16px":"0px"},className:A().enterAddressText,onClick:()=>{(()=>{let l;if("billingAddess"===lo)l={...lT,collapseDelivery:!1,paypalInfo:null,billingInfo:{billingMannualAddress:!lJ,billingAddressFinderData:null,addressFinder:!1,addressFinderValue:null,isvalid:!1}};else{var e,n,i,o;l={...lT,delivery_info:{billingMannualAddress:!lJ,deliveryInfoAddressFinderData:null,addressFinder:lJ,addressFinderValue:(null==lT||null==(e=lT.delivery_info)?void 0:e.billingMannualAddress)&&(null==lT||null==(n=lT.delivery_info)?void 0:n.addressFinder)&&(null==lT||null==(i=lT.delivery_info)?void 0:i.addressFinderValue)||null},paypalInfo:null,billingInfo:{billingMannualAddress:!lJ,billingAddressFinderData:null,addressFinder:lJ,addressFinderValue:null,isvalid:!1,override:(null==lT||null==(o=lT.billingInfo)?void 0:o.override)||!1}}}lt?lA((0,D.x5)({...lF,paypalInfo:null,billingInfo:l.billingInfo})):lA((0,D.X0)({...lT,...l})),lK(l=>!l)})(),(0,M.$d)((0,M.ar)(null==lu?void 0:lu.basketState),ee,en,lJ?f.A.switchToAddrs:f.A.addressManually,"checkout")},children:lJ?(0,i.jsx)("span",{onClick:ev,children:f.A.switchToAddrs}):(0,i.jsx)("span",{onClick:ec,children:f.A.addressManually})}),[lj,lo,lJ,lT]),eh=async(l,e,n)=>{!ei.current.has(e)&&(null==l?void 0:l.length)>0&&(ei.current.add(e),(0,M.$d)((0,M.ar)(null==lu?void 0:lu.basketState),ee,en,"Phone number","checkout"));let i=l.startsWith("0")?((null==lx?void 0:lx.msisdn_length)??0)+1:null==lx?void 0:lx.msisdn_length;(null==l?void 0:l.length)<=(i??0)&&(n?l2(n.error):l2(n),/^\d*$/.test(l)&&l5(l),l0(!1))},eb=(0,o.useMemo)(()=>{var l,e,n;let o="billingAddess"!==lo&&!l8&&lJ&&!(null==lT||null==(l=lT.delivery_info)?void 0:l.addressFinder),t=lJ&&!!(null==lT||null==(e=lT.delivery_info)?void 0:e.addressFinder)&&!!(null==lT||null==(n=lT.delivery_info)?void 0:n.addressFinderValue);return(o||t)&&(0,i.jsxs)("div",{className:null===A()||void 0===A()?void 0:A().phoneNumberContainer,children:[(0,i.jsx)(E.A,{textChange:eh,placeholder:f.A.mobileNumber,ariaLabel:f.A.mobileNumber,inputValue:l4,validators:[],country_number_code:null==lx?void 0:lx.country_number_code,showError:lQ&&!l1,phoneNumberLocalError:lX,className:A().custom_input_field,pageId:"renew-bundle",typeValue:"string",endAdornmentText:ep?"":f.A.optional}),(0,i.jsxs)(s.A,{variant:"h5",my:0,className:A().weMayContactYouForYourSIMDelivery,children:[(0,i.jsx)(m(),{src:g.z.ph
1oneInfoIcon,alt:"phoneInfoIcon"})," ",null===f.A||void 0===f.A?void 0:f.A.weMayContactYouForYourSIMDelivery]})]})},[lj,lo,lJ,lT,l4]),eA=(0,o.useMemo)(()=>{var l,e;return(!!(null==lT||null==(l=lT.delivery_info)?void 0:l.addressFinder)&&(null==lT||null==(e=lT.delivery_info)?void 0:e.addressFinderValue)&&lJ||ey)&&(0,i.jsx)($.A,{className:"fullcustomButton",variant:"contained",disabled:!(null==lT?void 0:lT.delivery_info_isvalid)||ep&&!l9,onClick:()=>{ef(!0),(0,M.$d)((0,M.ar)(null==lu?void 0:lu.basketState),ee,en,f.A.confirmContinue,"checkout")},children:f.A.confirmContinue})},[lT,ey,lJ,l4]),ex=(0,o.useMemo)(()=>(0,i.jsx)(N.A,{addressFinderValue:lq,handleAddressChange:er,type:lo,defaultValue:null==lT?void 0:lT.delivery_info,setAddressNotSelected:e_,fieldInteractionDetails:l_,basketData:null==lu?void 0:lu.basketState,onAutoFillChange:lW?lV:void 0}),[lq,lo,lT,lJ,lj]);return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(a.Ay,{id:"deliveryTo",container:!0,direction:"column",alignItems:"center",children:[(0,i.jsx)(L.A,{}),(0,i.jsx)(a.Ay,{sx:{width:lb?"100%":"inherit"},item:!0,className:`${eu&&A().addTocardWrapper}`,children:(0,i.jsxs)(h.A,{className:`${(null==lT?void 0:lT.personalDetailsButton)?A().formContainer_confirmed:A().formContainer} ${eu&&A().addTocard} ${!(null==lT?void 0:lT.personalDetailsButton)&&A().flexRow}`,children:[(0,i.jsxs)(a.Ay,{item:!0,display:"flex",justifyContent:"space-between",alignItems:"baseline",children:[!eu&&(0,i.jsxs)(a.Ay,{children:[(0,i.jsx)(a.Ay,{item:!0,display:"flex",justifyContent:"space-between",alignItems:"center",children:(0,i.jsx)(s.A,{variant:"h5",className:A().textHead,children:f.A.deliveryDetails})}),(0,i.jsx)(s.A,{variant:"h5",gutterBottom:!0,className:A().subHead,children:f.A.localAddress})]}),(null==lT?void 0:lT.collapseDelivery)&&(0,i.jsx)($.A,{variant:"text",className:A().changeButton,onClick:()=>ef(!1),children:f.A.change})]}),(null==lT?void 0:lT.personalDetailsButton)&&!lm&&(0,i.jsx)(i.Fragment,{children:(0,j.Ime)(lT)||lT&&!(null==lT?void 0:lT.collapseDelivery)?(0,i.jsx)(a.Ay,{container:!0,spacing:2,style:{position:"relative"},children:(0,i.jsx)(a.Ay,{item:!0,xs:12,alignItems:"left",display:lb?void 0:"flex",flexDirection:lb?void 0:"column",children:la?(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(a.Ay,{item:!0,xs:12,sx:{marginBottom:lb?"10px":void 0},children:(!lJ||!!(null==lT||null==(Z=lT.delivery_info)?void 0:Z.addressFinder)&&lJ)&&"billingAddess"!==lo&&!lj&&(0,i.jsxs)(i.Fragment,{children:[ex,!!(null==lT||null==(X=lT.delivery_info)?void 0:X.addressFinder)&&(null==lT||null==(Y=lT.delivery_info)?void 0:Y.addressFinderValue)&&lJ&&(0,i.jsxs)(a.Ay,{container:!0,spacing:2,children:[(0,i.jsx)(x.A,{setFormStatus:em,hasError:l$,isFormUpdated:ln,defaultCountryLoad:!0,defaultCountryName:lN,fromShippingFreesim:lo,ref:lh,model:null==(Q=(0,j.XkQ)(f.A,ln,lo,!1,lO,lB,lz,!1,lW&&lR,lW?null==lT?void 0:lT.delivery_info:{}))?void 0:Q.filter(l=>(null==lx?void 0:lx.country_code)!=="AU"||"house_no"!==l.field),values:(null==lT||null==(ll=lT.delivery_info)?void 0:ll.addressFinder)?null==lT?void 0:lT.delivery_info:{},onChange:es}),(0,i.jsx)(a.Ay,{width:"100%",item:!0,sx:{paddingLeft:"16px"}})]})]})}),ey&&(0,i.jsx)(a.Ay,{container:!0,spacing:2,children:(0,i.jsx)(x.A,{setFormStatus:em,hasError:l$,isFormUpdated:ln,defaultCountryLoad:!0,defaultCountryName:lN,fromShippingFreesim:lo,ref:lg,model:(0,j.XkQ)(f.A,ln,lo,!1,lO,lB,lz),values:lt?null==lF?void 0:lF.billingInfo:lT?"billingAddess"===lo?null==lT?void 0:lT.billingInfo:null==lT?void 0:lT.delivery_info:{},onChange:es})}),lS?[eg,eb,eA]:[eA,eg]]}):(0,i.jsxs)(i.Fragment,{children:[(!lJ||!!(null==lT||null==(V=lT.delivery_info)?void 0:V.addressFinder)&&lJ)&&"billingAddess"!==lo&&!lj&&(0,i.jsxs)(i.Fragment,{children:[ex,!!(null==lT||null==(W=lT.delivery_info)?void 0:W.addressFinder)&&(null==lT||null==(J=lT.delivery_info)?void 0:J.addressFinderValue)&&lJ&&(0,i.jsx)(a.Ay,{container:!0,spacing:2,children:(0,i.jsx)(x.A,{setFormStatus:em,hasError:l$,defaultCountryLoad:!0,defaultCountryName:lN,fromShippingFreesim:lo,isFormUpdated:ln,ref:lh,model:null==(K=(0,j.XkQ)(f.A,ln,lo,!1,lO,lB,lz,!1,lW&&lR,lW?null==lT?void 0:lT.delivery_info:{}))?void 0:K.filter(l=>(null==lx?void 0:lx.country_code)!=="AU"||"house_no"!==l.field),values:(null==lT||null==(q=lT.delivery_info)?void 0:q.addressFinder)?null==lT?void 0:lT.delivery_info:{},onChange:es})})]}),ey&&(0,i.jsx)(a.Ay,{container:!0,spacing:2,children:(0,i.jsx)(x.A,{isFormUpdated:ln,setFormStatus:em,hasError:l$,defaultCountryLoad:!0,defaultCountryName:lN,fromShippingFreesim:l3?void 0:lo,ref:lg,model:(0,j.XkQ)(f.A,ln,lo,!1,lO,lB,lz),values:lt?null==lF?void 0:lF.billingInfo:lT?"billingAddess"===lo?null==lT?void 0:lT.billingInfo:null==lT?void 0:lT.delivery_info:{},onChange:es})}),lS?[eg,eb,eA]:[eA,eg]]})})}):(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(a.Ay,{children:[(0,i.jsx)("span",{className:C().location_img,children:(0,i.jsx)(m(),{src:g.z.locationIcon,alt:"locationIcon"})}),(0,i.jsx)("span",{className:A().address_detail,children:(null==lT?void 0:lT.delivery_info)&&(0,j.qZB)(null==lT?void 0:lT.delivery_info)})]}),(null==lT?void 0:lT.contact_number)&&(0,i.jsxs)(a.Ay,{mt:1.5,children:[(0,i.jsx)("span",{className:C().location_img,children:(0,i.jsx)(m(),{src:g.z.mobileIconSmall,alt:"mobileIconSmall"})}),(0,i.jsx)("span",{className:A().address_detail,children:null==lT?void 0:lT.contact_number})]})]})})]})})]})})};var z=n(54026),G=n.n(z),R=n(26216);window;let V=l=>{var e;let{handlePortinChange:n,hotSimValue:o}=l;
1(0,R.A)(768),null==(e=document.querySelector("#footer-section"))||e.clientHeight;let t=(0,d.A)("(max-width:768px)");return(0,S.wA)(),(0,i.jsx)(a.Ay,{children:(0,i.jsx)(a.Ay,{container:!0,direction:"column",alignItems:"center",children:(0,i.jsxs)(a.Ay,{item:!0,className:G().hotSimHead,children:[(0,i.jsx)(s.A,{variant:"h5",gutterBottom:!0,className:null===G()||void 0===G()?void 0:G().textHead,children:f.A.switchtoLycaTxt}),(0,i.jsx)(s.A,{sx:{color:"#8D8D8D",fontSize:"14px",margin:"12px 0"},children:f.A.hotSimQuestion}),(0,i.jsxs)(a.Ay,{container:!0,spacing:2,children:[(0,i.jsx)(a.Ay,{item:!0,xs:12,alignItems:"center",display:t?void 0:"flex",flexDirection:t?void 0:"row",children:(0,i.jsxs)(a.Ay,{item:!0,xs:12,sx:{cursor:"pointer",border:o?"1px solid #D9D9D9":"2px solid #1996F3"},children:[(0,i.jsxs)(a.Ay,{container:!0,display:"flex",justifyContent:"space-between",alignItems:"center",sx:{cursor:"pointer",padding:"13px 8px 13px 8px",backgroundColor:o?"#FAFBFF":"#E8F4FE",height:"50px"},children:[(0,i.jsx)(a.Ay,{item:!0,sx:{flexGrow:1,height:"50px"},children:(0,i.jsx)(a.Ay,{container:!0,display:"flex",alignItems:"center",gap:1,children:(0,i.jsx)(s.A,{className:G().label1,children:f.A.ProceedMNPyes})})}),(0,i.jsx)(a.Ay,{sx:{display:"flex",alignItems:"center",justifyContent:"center",marginBottom:"25px"},children:o?(0,i.jsx)("input",{type:"radio",id:"option_yesportin",name:"mnphotsim",className:G().radioButton,checked:!o,onChange:n,style:{margin:0,marginLeft:"0px"}}):(0,i.jsx)(m(),{src:g.z.checkCircleBlue,width:20,height:20,alt:"checkCircle"})})]}),!o&&(0,i.jsxs)(u.A,{sx:{display:"flex",flexDirection:"row",alignItems:"center",padding:"12px 8px",height:"50px"},children:[(0,i.jsx)(m(),{src:g.z.infoGray,height:20,width:20,alt:"info"}),(0,i.jsx)(s.A,{className:` ${G().text_physicalsim}`,sx:{fontSize:"12px",fontWeight:"400",marginLeft:"8px"},children:null===f.A||void 0===f.A?void 0:f.A.hotSimInfoText})]})]})}),(0,i.jsx)(a.Ay,{item:!0,xs:12,alignItems:"center",display:t?void 0:"flex",flexDirection:t?void 0:"row",sx:{paddingTop:"0px !important"},children:(0,i.jsx)(a.Ay,{item:!0,xs:12,children:(0,i.jsxs)(a.Ay,{container:!0,display:"flex",justifyContent:"space-between",alignItems:"center",sx:{cursor:"pointer",padding:"13px 8px 13px 8px",backgroundColor:o?"#E8F4FE":"#FAFBFF",border:o?"2px solid #1996F3":"1px solid #D9D9D9",height:"50px"},children:[(0,i.jsx)(a.Ay,{item:!0,sx:{flexGrow:1,height:"50px"},children:(0,i.jsx)(a.Ay,{container:!0,display:"flex",alignItems:"center",gap:1,children:(0,i.jsx)(s.A,{className:G().label1,children:f.A.ProceedMNPno})})}),(0,i.jsx)(a.Ay,{sx:{display:"flex",alignItems:"center",justifyContent:"center",marginBottom:"25px"},children:o?(0,i.jsx)(m(),{src:g.z.checkCircleBlue,width:20,height:20,alt:"checkCircle"}):(0,i.jsx)("input",{type:"radio",id:"option_noportin",name:"mnphotsim",className:G().radioButton,checked:o,onChange:n,style:{margin:0,marginLeft:"0px"}})})]})})})]})]})})})};var W=n(65823),J=n(78332),K=n(28816),q=n(33804),Z=n(20878),X=n(70496),Y=n(51897),Q=n.n(Y),ll=n(25070),le=n(29454),ln=n(39870),li=n(85185),lo=n(75488),lt=n(58998),ld=n(55485),la=n(25060),lr=n(36905),ls=n(84210),lu=n(37779),lc=n(16562),lv=n(50828),l_=n(20495);let lm=l=>{var e,n,t,r,u,c,v,_,m,p,y,g,b,A,x,I,C,P,N,$,E,U,z,G;let{handleAdobeProgress:R,allPlanWithCartData:V,physicalSim:W,getTotalAmount:J,allTopUpPlans:K,typeOfSim:q,cmsData:Y,termsData:lm,countryName:lp,freeSim:ly,getTotalFreeSimAmount:lf,freeSimClicked:lg,allPlanFromFreeSim:lh,taxDetails:lb,shippingCharges:lA,isCvm:lx,type:lS,selectedPromoDetails:lI,getTotalCaCvmAmount:lC,promo_type:lD,confirmPaymentDetail:lj,captchRequired:lT,hotSim:lF,couponData:lw,fieldInteractionDetails:lP}=l,lN=null;lN=window;let lk="marketing"===lS,l$=(0,S.d4)(ls.CU),{currentStep:lM,formStep:lE}=lP??{},lH=(null==l$?void 0:l$.family_plan)&&(null==l$||null==(e=l$.cart_line_item_details)?void 0:e.length)>0,lO=(0,S.d4)(lu.uO),lL=(0,S.d4)(lu.Uv),lB=(0,S.d4)(ls.kV),lU=(null==lL||null==(n=lL[0])?void 0:n.field_customer_type[0])===null?"":null==lL||null==(t=lL[0])?void 0:t.field_customer_type[0],lz=!!((null==lU?void 0:lU.includes("Both"))||(null==lU?void 0:lU.includes("New"))),lG=null==lL||null==(u=lL[0])||null==(r=u.field_auto_renew
1al_section)?void 0:r[0],lR=null==(c=window)?void 0:c.location.origin,{executeRecaptcha:lV}=(0,lr._Y)(),lW=(null==lN||null==(v=lN.location)?void 0:v.host)&&(0,k.A)(null==lN||null==(_=lN.location)?void 0:_.host),lJ=(0,S.wA)(),lK=(0,d.A)("(max-width:768px)"),lq=(0,S.d4)(D.O),lZ=(0,S.d4)(D.wp),lX=(0,F.wb)(w.H.basket_data),lY=(0,T.useRouter)(),lQ=(0,S.d4)(D.K$),l0=(0,S.d4)(D.Xk),l1=(null==l0?void 0:l0.country_code)==="MK",l2=le.A.get("NEXT_LOCALE")||"en",l4=le.A.get("affiliate"),l5=l4?JSON.parse(l4):"",[l3,l8]=(0,o.useState)(!1),[l9,l7]=(0,o.useState)(!1),l6=(0,S.d4)(D.HX),el=(0,S.d4)(D.tL),ee=(0,S.d4)(D.lp),[en,ei]=(0,o.useState)(!1),[eo,et]=(0,o.useState)(!1),[ed,ea]=(0,o.useState)(!1),[er,es]=(0,o.useState)(!1),eu=lY.asPath,ec=null==l0?void 0:l0.is_card_validation,ev=(0,j.Iv3)(null==el?void 0:el.card_type,ec);(null==el?void 0:el.paymentType)==="54"&&(null==l0||l0.country_code);let e_=(null==l0||null==(m=l0.simple_checkout)?void 0:m.prepaid_web)||!1,em=(0,S.d4)(l_._2),ep=(0,S.d4)(l_.n0);((null==lR?void 0:lR.country_prefix)||(null==l0?void 0:l0.country_number_code)||"+44").replace("+","");ep&&em.portin_msisdn&&(em.portin_msisdn,em.pac_code&&em.pac_code,em.portin_date&&em.portin_date,em.portin_wish_time&&em.portin_wish_time,em.preferred_language&&em.preferred_language,em.contract_type&&em.contract_type,em.company_name&&em.company_name,em.portin_date_postpaid&&em.portin_date_postpaid,em.service_provider&&em.service_provider,em.function_type&&em.function_type,em.rio&&em.rio,em.port_in_iccid&&em.port_in_iccid);let ey=((null==lq?void 0:lq.paymentType)==="1000"||(null==el?void 0:el.paymentType)=="1000")&&e_,ef=(null==q?void 0:q.toLocaleLowerCase())!=="esim",eg=le.A.get("ccText")??!1,eh=(0,S.d4)(D.xy),eb=(0,F.wb)(w.H.verifyedUSAPostcode,!0)||(null==(p=JSON.parse((0,F.wb)(w.H.freeSimUSAPostcode,!0)))?void 0:p.zip_code),eA=JSON.parse((0,F.wb)("ctaBtn",!0)),ex=(0,j.ApL)("validateTDS"),eS=(0,S.d4)(D.Ok),eI=ef?eS:(0,F.wb)(w.H.verifyedUSAPostcode,!0),eC=null==Y?void 0:Y.find(l=>"node--checkout_disclosure_content"===l.type),eD=null==Y||null==(g=Y.find(l=>"node--landing_page_t_c_popup"===l.type))||null==(y=g.field_lg_t_c_popup)?void 0:y[0],ej=(null==l0||null==(b=l0.simple_checkout)?void 0:b.is_adyen_back_url_web)||!1;(0,o.useEffect)(()=>{sessionStorage.removeItem("freeSimUSAPostcode")},[]);let eT=+J+((null==l0?void 0:l0.country)==="USA"?+(null==lb?void 0:lb.total_tax):0)||0,eF=+lf+((null==l0?void 0:l0.country)==="USA"?+(null==lb?void 0:lb.total_tax):0),ew=(null==lI||null==(A=lI.api_type)?void 0:A.toLowerCase())===(null==(x=f.A.internal)?void 0:x.toLowerCase()),eP=+lC+((null==l0?void 0:l0.country)==="USA"&&+(null==lb?void 0:lb.total_tax)||0),eN=(null==lI?void 0:lI.calculated_discount)||0,ek=(0,j.PHN)(eP,lI,eN),[e$,eM]=(0,o.useState)(!0),eE=(null==l0?void 0:l0.country)==="USA",eH=l=>{"terms"===l?(ei(!0),ea(!1)):"payment"===l?(ei(!1),ea(!0)):"privacy"===l&&(es(!0),ei(!1),ea(!1))};(0,o.useEffect)(()=>{(0,F.UI)(w.H.purchessFreeSimRequest,!0)},[]);let eO=l=>{var e,n,i;return l?null==K||null==(i=K.find(e=>{var n,i;return(null==e||null==(i=e.topUpDetails)||null==(n=i[0])?void 0:n.topUpId)==l}))||null==(n=i.topUpDetails)||null==(e=n[0])?void 0:e.topUpAmount:""},eL=(l,e)=>{var n;return null==l||null==(n=l.filter(l=>(null==l?void 0:l.bundleCode)==e))?void 0:n[0]};(0,o.useEffect)(()=>{lg&&((null==lh?void 0:lh.length)===0||void 0===lh)&&(0,j.GL_)(lW.tradeDoubler,lN)},[lg,lh]);let eB=l=>(null==l?void 0:l.replace(/[^a-zA-Z0-9]/g,""))||"",eU=async(l,e)=>{if((null==l0?void 0:l0.country)==="USA"&&0!==l&&!lg)try{et(!0);let n={brand_name:"Lycamobile",channel_name:"Myaccounts",country_code:"USA",delivery_zip_code:"10021",feature_name:"ONLINE_TOPUP",msisdn_zip_code:e||"",password:"lyca",payment_zip_code:"",state_code:"",tax_id:Math.random().toString(36).slice(2),user_id:"lyca",subscriber_id:"lycadummy345",amount:l.toString()},{status:i,data:o}=await H.A.post(O.t.calculateUsaTax,n);if(200==i||204==i)return et(!1),{status:i,data:o}}catch(l){et(!1)}};(0,o.useEffect)(()=>{if((null==lh?void 0:lh.length)>0){var l,e,n,i,o;let t={name:(null==lh||null==(l=lh[0])?void 0:l.productDisplayName)||(null==lh||null==(e=lh[0])?void 0:e.productName),price:(null==lh||null==(o=lh[0])||null==(i=o.bundleGroupDetail
1s)||null==(n=i[0])?void 0:n.promotionalPricing)||"0",topUp:0};(0,j.EIq)(t,lW.tradeDoubler,lN)}},[lg,lh]);let ez=null==V?void 0:V.find(l=>{var e;return null==l||null==(e=l.cartItem)?void 0:e.bundle_selected}),eG=l=>{var e,n,i,o,t,d,a,r,s,u,c,v,_,m,p,y,f,g,h,b,A,x,S,I,C,D,T,F,w,P,N,k,$,M,E,H,O,L,B,U,z,G,R,V,W,J;return{type_of_sim:(null==l||null==(e=l.cartItem)?void 0:e.physical_sim)?"Standard":"eSIM",purchase_type:(null==l||null==(n=l.cartItem)?void 0:n.bundle_code)!==""&&(null==l||null==(i=l.cartItem)?void 0:i.bundle_selected)&&(null==l||null==(o=l.cartItem)?void 0:o.card_id)!==""&&(null==l||null==(t=l.cartItem)?void 0:t.card_id)!==void 0?"FBT":(null==l||null==(d=l.cartItem)?void 0:d.bundle_code)!==""&&(null==l||null==(a=l.cartItem)?void 0:a.bundle_selected)&&(null==l||null==(r=l.cartItem)?void 0:r.bundle_code)!==void 0?"FB":"FT",topup_id:(null==l||null==(s=l.cartItem)?void 0:s.card_id)?(l=>{var e;return l?null==K||null==(e=K.find(e=>{var n,i;return(null==e||null==(i=e.topUpDetails)||null==(n=i[0])?void 0:n.topUpId)==l}))?void 0:e.id:""})(null==l||null==(u=l.cartItem)?void 0:u.card_id):"",topup_amount:(null==l||null==(c=l.cartItem)?void 0:c.card_id)?eO(null==l||null==(v=l.cartItem)?void 0:v.card_id):"",card_id:(null==l||null==(_=l.cartItem)?void 0:_.card_id)||"",bundle_detail:(null==l||null==(m=l.cartItem)?void 0:m.bundle_selected)?{sim_bundle_details:[{product_id:null==l||null==(p=l.planItem)?void 0:p.id,bundle_code:(0,j.Fz)(l,lH),bundle_name:(null==l||null==(y=l.cartItem)?void 0:y.bundle_selected)?null==(f=l.planItem)?void 0:f.productName:"",discount_amount:(null==l||null==(g=l.cartItem)?void 0:g.bundle_selected)?(null==(h=(null==(b=eL(null==l||null==(A=l.planItem)?void 0:A.bundleGroupDetails,null==l||null==(x=l.cartItem)?void 0:x.bundle_code))?void 0:b.promotionalPricing)?null==(S=eL(null==l||null==(I=l.planItem)?void 0:I.bundleGroupDetails,null==l||null==(C=l.cartItem)?void 0:C.bundle_code))?void 0:S.promotionalPricing:null==(D=eL(null==l||null==(T=l.planItem)?void 0:T.bundleGroupDetails,null==l||null==(F=l.cartItem)?void 0:F.bundle_code))?void 0:D.basePrice)?void 0:h.toString())??"0":"",bundle_type:(null==l||null==(N=l.planItem)||null==(P=N.productType)||null==(w=P[0])?void 0:w.productTypeCode)==="internationalPlan"?"international":"national",is_disable_auto_renewal:((null==ez||null==(k=ez.cartItem)?void 0:k.bundle_selected)||(null==lh?void 0:lh.length)!==0)&&(null==lq?void 0:lq.paymentType)!=="49"&&(null==lq?void 0:lq.paymentType)!=="13"&&(null==lq?void 0:lq.paymentType)!=="53"&&!l1?!0===(lG&&lz)&&!1===lO?"0":"1":"0",bundle_tax_details:{tax:(null==l0?void 0:l0.country)==="USA"?null==l||null==($=l.bundle_tax_details)?void 0:$.tax:"",tax_id:(null==l0?void 0:l0.country)==="USA"?null==l||null==(M=l.bundle_tax_details)?void 0:M.tax_id:""},no_of_month:(0,j.TfO)(eL(null==l||null==(E=l.planItem)?void 0:E.bundleGroupDetails,null==l||null==(H=l.cartItem)?void 0:H.bundle_code)),bundle_vat_id:"",...(null==lI?void 0:lI.promo_code_type)==="1"&&(()=>{var e,n;let i=String((null==lI?void 0:lI.applicable_to_bundle_codes)||"").split(",").map(l=>l.trim()).filter(Boolean),o=String((0,j.Fz)(l,lH)).trim();return i.includes(o)?{promo_code:ew?"":(null==lI?void 0:lI.promo_code_name)??"",promo_type:ew?"":(null==lI?void 0:lI.promo_code_type)??"",promo_discount_amount:ew?"":(null==(n=Number(null==lI?void 0:lI.discount_value))||null==(e=n.toFixed(2))?void 0:e.replace(/\.?0+$/,""))??""}:{}})(),special_discount_code:"",bundle_vat_amount:"",bundle_fee:"",vendus_product_id:(null==l||null==(B=l.planItem)||null==(L=B.bundleGroupDetails)||null==(O=L[0])?void 0:O.vendusProductId)??""}]}:null,topup_tax_details:{tax:(null==l0?void 0:l0.country)==="USA"?null==l||null==(U=l.topup_tax_details)?void 0:U.tax:"",tax_id:(null==l0?void 0:l0.country)==="USA"?null==l||null==(z=l.topup_tax_details)?void 0:z.tax_id:""},topup_vat_id:"",topup_vat_amount:"",...(null==lI?void 0:lI.promo_code_type)==="2"&&String(null==lI?void 0:lI.topup_denomination_amount)===String(eO(null==l||null==(G=l.cartItem)?void 0:G.card_id)||"0")?{promo_code:ew?"":(null==lI?void 0:lI.promo_code_name)??"",promo_type:ew?"":(null==lI?void 0:lI.promo_code_type)??"",promo_discount_amount:ew?"":(null==(V=Number(null==lI?void 0:lI.discount_value))||null==(R=V.toFixed(2))?void 0:R.replace(/\.?0+$/,""))??""}:{},topup_fee:"",nus_flag:"",nus_id:"",nus_expiry_date:"",sim_type:(null==l||null==(W=l.cartItem)?void 0:W.physical_sim)?"0":"1",sim_category:ly||(null==l||null==(J=l.cartItem)?void 0:J.physical_sim)?"0":"1",is_activation_fee:"",activation_fee:"",activation_fee_sim_type:""}},eR=()=>{let l=[];return null==V||V.map(e=>{let n=(l=>{var e;return null==lB||null==(e=lB.filter(e=>{var n,i,o,t,d,a,r,s;return(null==e||null==(n=e.planItem)?void 0:n.id)===(null==l||null==(i=l.planItem)?void 0:i.id)&&(null==e||null==(o=e.cartItem)?void 0:o.cart_line_item_id)===(null==l||null==(t=l.cartItem)?void 0:t.cart_line_item_id)&&(null==e||null==(d=e.cartItem)?void 0:d.buddy_plan_selected)&&(null==e||null==(s=e.planItem)||null==(r=s.bundleGroupDetail
1s)||null==(a=r[0])?void 0:a.buddyBundleCode)}))?void 0:e.map(l=>{var e,n,i,o,t,d,a,r,s,u,c,v,_;return{...eG(l),purchase_type:"FB",topup_id:"",topup_amount:"",card_id:"",bundle_detail:(null==l||null==(e=l.cartItem)?void 0:e.buddy_plan_selected)&&(null==l||null==(o=l.planItem)||null==(i=o.bundleGroupDetails)||null==(n=i[0])?void 0:n.buddyBundleCode)?{sim_bundle_details:[{...null==(a=eG(l))||null==(d=a.bundle_detail)||null==(t=d.sim_bundle_details)?void 0:t[0],bundle_code:(null==l||null==(u=l.planItem)||null==(s=u.bundleGroupDetails)||null==(r=s[0])?void 0:r.buddyBundleCode)??"",discount_amount:(null==l||null==(_=l.planItem)||null==(v=_.bundleGroupDetails)||null==(c=v[0])?void 0:c.buddyBundlePrice)??"0",is_disable_auto_renewal:(null==l0?void 0:l0.buddy_plan_auto_renewal)?"1":"0"}]}:null}})})(e);l.push(eG(e)),(null==n?void 0:n.length)&&(null==l0?void 0:l0.buddy_plan_enabled_web)&&l.push(null==n?void 0:n[0])}),l},eV=()=>{var l,e;return[{type_of_sim:"eSIM"===q?"eSIM":"Standard",purchase_type:"S",topup_amount:"",card_id:"",topup_tax_details:{tax:"",tax_id:""},shipping_charge:lA,topup_vat_id:"",topup_vat_amount:"",...["2","4"].includes(null==lI?void 0:lI.promo_code_type)?{promo_code:ew?"":(null==lI?void 0:lI.promo_code_name)??"",promo_type:ew?"":(null==lI?void 0:lI.promo_code_type)??"",promo_discount_amount:ew?"":(null==(e=Number(null==lI?void 0:lI.discount_value))||null==(l=e.toFixed(2))?void 0:l.replace(/\.?0+$/,""))??""}:{},topup_fee:"",nus_flag:"",nus_id:"",nus_expiry_date:"",sim_type:"0",sim_category:"0",is_activation_fee:"",activation_fee:"",activation_fee_sim_type:""}]},eW=()=>null==lh?void 0:lh.map(l=>{var e,n,i,o,t,d,a,r,s,u,c,v,_,m,p,y,f,g,h,b,A;return{type_of_sim:"eSIM"===q?"eSIM":"Standard",purchase_type:(null==l||null==(e=l.bundleGroupDetails[0])?void 0:e.bundleCode)?"FB":"",topup_amount:"",card_id:"",bundle_detail:{sim_bundle_details:[{product_id:null==l?void 0:l.id,bundle_code:(null==l||null==(i=l.bundleGroupDetails)||null==(n=i[0])?void 0:n.bundleCode)?null==l||null==(t=l.bundleGroupDetails)||null==(o=t[0])?void 0:o.bundleCode:"",bundle_name:null==l?void 0:l.productName,discount_amount:(null==l||null==(a=l.bundleGroupDetails)||null==(d=a[0])?void 0:d.promotionalPricing)?null==l||null==(s=l.bundleGroupDetails)||null==(r=s[0])?void 0:r.promotionalPricing:(null==l||null==(c=l.bundleGroupDetails)||null==(u=c[0])?void 0:u.basePrice)??"0",bundle_type:(null==l||null==(_=l.productType)||null==(v=_[0])?void 0:v.productTypeCode)==="internationalPlan"?"international":"national",is_disable_auto_renewal:((null==ez||null==(m=ez.cartItem)?void 0:m.bundle_selected)||(null==lh?void 0:lh.length)!==0)&&(null==lq?void 0:lq.paymentType)!=="49"&&(null==lq?void 0:lq.paymentType)!=="13"&&(null==lq?void 0:lq.paymentType)!=="53"&&!l1?!0===(lG&&lz)&&!1===lO?"0":"1":"0",bundle_tax_details:{tax:(null==l0?void 0:l0.country)==="USA"?null==lb?void 0:lb.total_tax:"",tax_id:(null==l0?void 0:l0.country)==="USA"?null==lb?void 0:lb.tax_id:""},no_of_month:(0,j.TfO)(null==l||null==(p=l.bundleGroupDetails)?void 0:p[0])||"1",bundle_vat_id:"",bundle_vat_amount:"",...(null==lI?void 0:lI.promo_code_type)==="1"?{promo_code:ew?"":(null==lI?void 0:lI.promo_code_name)??"",promo_type:ew?"":(null==lI?void 0:lI.promo_code_type)??"",promo_discount_amount:ew?"":(null==(f=Number(null==lI?void 0:lI.discount_value))||null==(y=f.toFixed(2))?void 0:y.replace(/\.?0+$/,""))??""}:{},bundle_fee:""}]},topup_tax_details:{tax:(null==l0?void 0:l0.country)==="USA"?null==l||null==(g=l.topup_tax_details)?void 0:g.tax:"",tax_id:(null==l0?void 0:l0.country)==="USA"?null==l||null==(h=l.topup_tax_details)?void 0:h.tax_id:""},topup_vat_id:"",topup_vat_amount:"",...(null==lI?void 0:lI.promo_code_type)==="2"?{promo_code:ew?"":(null==lI?void 0:lI.promo_code_name)??"",promo_type:ew?"":(null==lI?void 0:lI.promo_code_type)??"",promo_discount_amount:ew?"":(null==(A=Number(null==lI?void 0:lI.discount_value))||null==(b=A.toFixed(2))?void 0:b.replace(/\.?0+$/,""))??""}:{},topup_fee:"",nus_flag:"",nus_id:"",nus_expiry_date:"",sim_type:"eSIM"===q?"1":"0",sim_category:"eSIM"===q?"1":"0",is_activation_fee:"",activation_fee:"",activation_fee_sim_type:""}}),eJ=ly&&lg?eV():ly&&!lg?eW():eR(),eK=(null==eJ||null==(C=eJ[0])||null==(I=C.type_of_sim)?void 0:I.toLowerCase())==="esim",eq=()=>{var l,e,n,i,o,t,d,a,r,s,u,c,v,_,m,p,y,f,g,h,b,A,x,S,I,C,D,j,T,F,w,P,N,k,$,M,E,H,O,L,B,U,z,G,R,V,W,J,K,Z,X,Y,Q,ll,le,ln,li,lo,lt,ld,la,lr,ls;let lu=(null==q?void 0:q.toLowerCase())==="esim";if(!(null==l6||null==(l=l6.delivery_info)?void 0:l.billingMannualAddress)&&(null==l6||null==(e=l6.delivery_info)?void 0:e.addressFinder))return{post_code:lu?(null==l0?void 0:l0.country_code)==="PT"?eI:eB(eI):(null==l0?void 0:l0.country_code)==="PT"?(null==l6||null==(i=l6.delivery_info)||null==(n=i.deliveryInfoAddressFinderData)?void 0:n.post_code)||(null==l6||null==(t=l6.billingInfo)||null==(o=t.billingAddressFinderData)?void 0:o.post_code):eB((null==l6||null==(a=l6.delivery_info)||null==(d=a.deliveryInfoAddressFinderData)?void 0:d.post_code)||(null==l6||null==(s=l6.billingInfo)||null==(r=s.billingAddressFinderData)?void 0:r.post_code)),street:(null==l6||null==(c=l6.delivery_info)||null==(u=c.deliveryInfoAddressFinderData)?void 0:u.street_name)||"",city:(null==l6||null==(_=l6.delivery_info)||null==(v=_.deliveryInfoAddressFinderData)?void 0:v.city)||"",country:(null==l6||null==(p=l6.delivery_info)||null==(m
1=p.deliveryInfoAddressFinderData)?void 0:m.country)||lp||(null==l0?void 0:l0.country)||"",house_no:(null==l0?void 0:l0.country)==="USA"?"":(null==l6||null==(f=l6.delivery_info)||null==(y=f.deliveryInfoAddressFinderData)?void 0:y.house_no)||"",county:(null==l6||null==(h=l6.delivery_info)||null==(g=h.deliveryInfoAddressFinderData)?void 0:g.county)||"",houseno_extn:(null==l6||null==(b=l6.delivery_info)?void 0:b.houseno_extn)||"",apartment_no:(null==l0?void 0:l0.country)==="AU"||(null==l0?void 0:l0.country)==="PL"||(null==l0?void 0:l0.country)==="USA"?null==l6||null==(x=l6.delivery_info)||null==(A=x.deliveryInfoAddressFinderData)?void 0:A.house_no:"",block:"",lift:"",floor:"",door:"",administrative_area:"",neighbourhood:"",street_number:"",co:""};{let l=`${(null==l6||null==(S=l6.delivery_info)?void 0:S.street_name)||""} ${(null==l6||null==(I=l6.delivery_info)?void 0:I.address2)||""}`,e=(null==l0?void 0:l0.country_code)==="GB"&&(null==eJ||null==(D=eJ[0])||null==(C=D.type_of_sim)?void 0:C.toLowerCase())!=="esim"?null==l?void 0:l.slice(0,50):(null==l0?void 0:l0.country_code)==="USA"?null==l6||null==(j=l6.delivery_info)?void 0:j.house_no:(null==l0?void 0:l0.country_code)==="AU"?(null==l6||null==(T=l6.delivery_info)?void 0:T.addressFinder)?(null==l6||null==(F=l6.delivery_info)?void 0:F.street)?null==l6||null==(w=l6.delivery_info)?void 0:w.street:"":`${(null==l6||null==(P=l6.delivery_info)?void 0:P.house_no)||""}${(null==l6||null==(N=l6.delivery_info)?void 0:N.house_no)&&(null==l6||null==(k=l6.delivery_info)?void 0:k.street)?" ":""}${(null==l6||null==($=l6.delivery_info)?void 0:$.street)||""}`:(null==l0?void 0:l0.country_code)==="FR"||(null==l0?void 0:l0.country_code)==="DK"||(null==l0?void 0:l0.country_code)==="IE"?null==l6||null==(M=l6.delivery_info)?void 0:M.street:l1?(null==l6||null==(E=l6.delivery_info)?void 0:E.address1)+", "+(null==l6||null==(H=l6.delivery_info)?void 0:H.placeName)+", "+(null==l6||null==(O=l6.delivery_info)?void 0:O.muncipalityName):eK?"":null==l6||null==(L=l6.delivery_info)?void 0:L.street_name;return{post_code:lu?(null==l0?void 0:l0.country_code)==="PT"?eI:eB(eI):(null==l0?void 0:l0.country_code)==="PT"?(null==l6||null==(B=l6.delivery_info)?void 0:B.post_code)||(null==l6||null==(U=l6.billingInfo)?void 0:U.post_code)||(null==l6||null==(G=l6.billingInfo)||null==(z=G.billingAddressFinderData)?void 0:z.post_code):eB((null==l6||null==(R=l6.delivery_info)?void 0:R.post_code)||(null==l6||null==(V=l6.billingInfo)?void 0:V.post_code)||(null==l6||null==(J=l6.billingInfo)||null==(W=J.billingAddressFinderData)?void 0:W.post_code)),street:(null==l0?void 0:l0.country_code)==="IT"?null==l6||null==(K=l6.delivery_info)?void 0:K.street:e,city:eK?"":l1?null==l6||null==(Z=l6.delivery_info)?void 0:Z.cityName:null==l6||null==(X=l6.delivery_info)?void 0:X.city,country:(null==l6||null==(Y=l6.delivery_info)?void 0:Y.country)||lp||(null==l0?void 0:l0.country)||"",house_no:(null==l0?void 0:l0.country)==="USA"||(null==l0?void 0:l0.country_code)==="AU"||eK?"":null==l6||null==(Q=l6.delivery_info)?void 0:Q.house_no,county:eK?"":null==l6||null==(ll=l6.delivery_info)?void 0:ll.county,houseno_extn:eK?"":(null==l6||null==(le=l6.delivery_info)?void 0:le.houseno_extn)||(null==l6?void 0:l6.co)||"",apartment_no:eK?"":(null==l0?void 0:l0.country_code)==="GB"?null==l6||null==(ln=l6.delivery_info)?void 0:ln.apartment_no:(null==l0?void 0:l0.country_code)==="USA"?null==l6||null==(li=l6.delivery_info)?void 0:li.street_name:null==l6||null==(lo=l6.delivery_info)?void 0:lo.apartment_no,block:eK?"":(null==l0?void 0:l0.country_code)==="PT"?null==l6||null==(lt=l6.delivery_info)?void 0:lt.house_no:(null==l6||null==(ld=l6.delivery_info)?void 0:ld.block)||"",lift:"",floor:eK?"":null==l6||null==(la=l6.delivery_info)?void 0:la.floor,door:eK?"":null==l6||null==(lr=l6.delivery_info)?void 0:lr.door,administrative_area:"",neighbourhood:eK?"":null==l6?void 0:l6.co,street_number:eK||(null==l0?void 0:l0.country_code)==="AU"?"":null==l6||null==(ls=l6.delivery_info)?void 0:ls.street_number,co:eK?"":null==l6?void 0:l6.co}}},eZ=(0,o.useCallback)(l=>(0,j.SCz)(l,K,null==l0?void 0:l0.buddy_plan_enabled_web),[lX,K]),eX=async()=>{var l,e,n,i,o,t,d,a,r,s,u,c,v,_,m,p,y,g,h,b,A,x,S,I,C,T,P,N,k,$,M,E,L,U,z,G,V,W,q,X,Y,Q,ll,le,ln,li,lo,lt,la,lr,ls,lu,lc,l_,lm,lf,lx,lS,lC,lD,lj,lP,lk,l$,lM,lE,lL,lB,lU,lK,lZ,l4,l3,l8,en,ei,eo,ed,ea,er,es,ec,eg,eA,eS,eC,eD,eP,eN,e$,eM,eE,eH,eO,eL,eU,eG,eK,eX,eY,e0,e1,e2,e4,e5,e3,e8,e9,e7,e6,nl,ne,nn,ni,no,nt,nd,na,nr,ns,nu,nc,nv,n_,nm,np,ny,nf,ng,nh,nb,nA,nx,nS,nI,nC,nD,nj,nT,nF,nw,nP,nN,nk,n$,nM,nE,nH,nO,nL,nB,nU,nz,nG,nR,nV,nW,nJ,nK,nq,nZ,nX,nY,nQ,n0,n1,n2,n4,n5,n3,n8,n9,n7,n6,il,ie,ii,io,it,id,ia,ir,is,iu,ic,iv,i_,im,ip,iy,ig,ih,ib,iA,ix,iS,iI,iC;if(l9)return;if(l7(!0),(null==el?void 0:el.paymentType)==="1000"&&(0,j.Ime)(ev)&&!e_)return lJ((0,B.ZD)({display:!0,severity:"error",message:f.A.validCardNo})),!1;R();let iD={title:"",first_name:l6.first_name,last_name:l6.last_name,date_of_birth:"",chk_email:!0,contact_number:(0,j.c2J)(l6.contact_number)?((null==l6?void 0:l6.country_code)?null==l6||null==(l=l6.country_code)?void 0:l.substring(1):null==l0||null==(e=l0.c
1ountry_number_code)?void 0:e.substring(1))+(0,j.c2J)(l6.contact_number):"",email:null==(n=l6.email)?void 0:n.trim(),payment_mode:(null==el?void 0:el.paymentType)==="1"||(null==el?void 0:el.paymentType)==="0"||(null==el?void 0:el.paymentType)==="54"||(null==el?void 0:el.paymentType)==="157"||(null==el?void 0:el.paymentType)==="209"?"3":"1",sim_with_bundle_details:{sim_details:ly&&lg?eV():ly&&!lg?eW():eR()},address:eq(),card_detail:(null==el?void 0:el.paymentType)==="1"||(null==el?void 0:el.paymentType)==="209"?{}:{card_type:ev||"",name_on_card:(null==el?void 0:el.name_on_card)||"",card_no:(0,j.KAJ)(null==el?void 0:el.card_no)||"",issue_date:"",expiry_date:(null==el?void 0:el.expiry_date_send)||"",issue_no:"",cvv:(null==el?void 0:el.cvv)||"",billing_address:(()=>{var l,e,n,i,o,t,d,a,r,s,u,c,v,_,m,p,y,f,g,h,b,A,x,S,I,C,D,j,T,F,w,P,N,k,$,M,E,H,O,L,B,U,z,G,R,V,W,J,K,q,Z,X,Y;if(!(null==l6||null==(l=l6.billingInfo)?void 0:l.billingMannualAddress)&&(null==l6||null==(e=l6.billingInfo)?void 0:e.addressFinder))return{post_code:(null==l6||null==(i=l6.billingInfo)||null==(n=i.billingAddressFinderData)?void 0:n.post_code)||"",street:(null==l6||null==(t=l6.billingInfo)||null==(o=t.billingAddressFinderData)?void 0:o.street_name)||"",city:(null==l6||null==(a=l6.billingInfo)||null==(d=a.billingAddressFinderData)?void 0:d.city)||"",country:(null==l6||null==(s=l6.billingInfo)||null==(r=s.billingAddressFinderData)?void 0:r.country)||lp||(null==l0?void 0:l0.country)||"",house_no:(null==l0?void 0:l0.country)==="USA"?"":(null==l6||null==(c=l6.billingInfo)||null==(u=c.billingAddressFinderData)?void 0:u.house_no)||"",county:(null==l6||null==(_=l6.billingInfo)||null==(v=_.billingAddressFinderData)?void 0:v.county)||"",houseno_extn:(null==l6||null==(m=l6.billingInfo)?void 0:m.houseno_extn)?null==l6||null==(p=l6.billingInfo)?void 0:p.houseno_extn:"",apartment_no:(null==l0?void 0:l0.country)==="AU"||(null==l0?void 0:l0.country)==="PL"||(null==l0?void 0:l0.country)==="USA"?null==l6||null==(f=l6.billingInfo)||null==(y=f.billingAddressFinderData)?void 0:y.house_no:"",block:"",lift:"",floor:"",door:"",administrative_area:"",neighbourhood:"",street_number:"",co:""};{let l=`${(null==l6||null==(g=l6.billingInfo)?void 0:g.street_name)||""} ${(null==l6||null==(h=l6.billingInfo)?void 0:h.address2)||""}`,e=(null==l0?void 0:l0.country_code)==="GB"&&(null==eJ||null==(A=eJ[0])||null==(b=A.type_of_sim)?void 0:b.toLowerCase())!=="esim"||(null==l0?void 0:l0.country_code)==="GB"&&(null==el?void 0:el.paymentType)==="0"&&(null==eJ||null==(S=eJ[0])||null==(x=S.type_of_sim)?void 0:x.toLowerCase())==="esim"?null==l?void 0:l.slice(0,50):(null==l0?void 0:l0.country_code)==="USA"?null==l6||null==(I=l6.billingInfo)?void 0:I.house_no:(null==l0?void 0:l0.country_code)==="AU"?((null==l6||null==(C=l6.billingInfo)?void 0:C.house_no)?(null==l6||null==(D=l6.billingInfo)?void 0:D.house_no)+" ":"")+((null==l6||null==(j=l6.billingInfo)?void 0:j.street)?(null==l6||null==(T=l6.billingInfo)?void 0:T.street)+" ":"")+((null==l6||null==(F=l6.billingInfo)?void 0:F.street_number)?null==l6||null==(w=l6.billingInfo)?void 0:w.street_number:""):(null==l0?void 0:l0.country_code)==="FR"||(null==l0?void 0:l0.country_code)==="DK"||(null==l0?void 0:l0.country_code)==="IE"?null==l6||null==(P=l6.billingInfo)?void 0:P.street:l1?(null==l6||null==(N=l6.billingInfo)?void 0:N.address1)+", "+(null==l6||null==(k=l6.billingInfo)?void 0:k.placeName)+", "+(null==l6||null==($=l6.billingInfo)?void 0:$.muncipalityName):(null==l6||null==(M=l6.billingInfo)?void 0:M.street_name)||"";return{post_code:(null==l6||null==(E=l6.bsetCardDetailsautillingInfo)?void 0:E.post_code)||(null==l6||null==(H=l6.billingInfo)?void 0:H.post_code)||"",street:(null==l0?void 0:l0.country_code)==="IT"?null==l6||null==(O=l6.billingInfo)?void 0:O.street:e,city:l1?null==l6||null==(L=l6.billingInfo)?void 0:L.cityName:(null==l6||null==(B=l6.billingInfo)?void 0:B.city)||"",country:(null==l6||null==(U=l6.billingInfo)?void 0:U.country)||lp||(null==l0?void 0:l0.country)||"",house_no:(null==l0?void 0:l0.country)==="USA"||(null==l0?void 0:l0.country_code)==="AU"?"":(null==l6||null==(z=l6.billingInfo)?void 0:z.house_no)||"",county:(null==l6||null==(G=l6.billingInfo)?void 0:G.county)||"",houseno_extn:(null==l6||null==(R=l6.billingInfo)?void 0:R.houseno_extn)||(null==l6?void 0:l6.co)||"",apartment_no:(null==l0?void 0:l0.country_code)==="GB"?null==l6||null==(V=l6.billingInfo)?void 0:V.apartment_no:(null==l0?void 0:l0.country_code)==="USA"?null==l6||null==(W=l6.billingInfo)?void 0:W.street_name:null==l6||null==(J=l6.billingInfo)?void 0:J.apartment_no,block:(null==l0?void 0:l0.country_code)==="PT"?null==l6||null==(K=l6.billingInfo)?void 0:K.house_no:(null==l6||null==(q=l6.billingInfo)?void 0:q.block)||"",lift:"",floor:(null==l6||null==(Z=l6.billingInfo)?void 0:Z.floor)||"",door:(null==l6||null==(X=l6.billingInfo)?void 0:X.door)||"",administrative_area:"",neighbourhood:(null==l6?void 0:l6.co)||"",street_number:(null==l0?void 0:l0.country_code)==="AU"?"":(null==l6||null==(Y=l6.billingInfo)?void 0:Y.street_number)||"",co:(null==l6?void 0:l6.co)||""}}})()},wp_payment:{accept_header:"",user_agent_header:"Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/114.0.0.0 Safari/537.36",pares:"",session_id:0x51d9237cb7,eco_data:""},ipaddress:"",card_nickname:"",card_number:"",e911_address:{zip:"",address_line2:"",address_line1:"",city:"",state_code:""},no_of_sim:ly?"1":(null==eJ?void 0:eJ.length)||"",purchase_type_flag:ly&&lg?"FREE SIM ONLY":"PAID_SIM",referer_url:null==lN?void 0:lN.location.href,friend_name:"",friend_country:"",friend_msisdn:"",...(null==lI?void 0:lI.promo_code_type)==="3"?{promo_code:ew?"":(null==lI?void 0:lI.promo_code_name)??"",promo_type:ew?"":(null==lI?void 0:lI.promo_code_type)??"",promo_discount_amount:ew?"":(null==(o=Number(null==lI?void 0:lI.discount_value))||null==(i=o.toFixed(2))?void 0:i.replace(/\.?0+$/,""))??""}:{},transaction_id:"23232332",vat_id:"",medium:(null==l5?void 0:l5.utm_medium)??"",source:(null==l5?void 0:l5.utm_source)??"",campaign:(null==l5?void 0:l5.utm_campaign)??"",shipping_charge:(null==l0?void 0:l0.country)==="USA"&&ly&&lg?lA||0:"",payment_id:"",issuer_id:"",account_holder_name:"",account_mobile_no:"",customer_consent:((null==ez||null==(t=ez.cartItem)?void 0:t.bundle_selected)||(null==lh?void 0:lh.length)!==0)&&(null==lq?void 0:lq.paymentType)!=="49"&&(null==lq?void 0:lq.paymentType)!=="13"&&(null==lq?void 0:lq.paymentType)!=="53"?!0===(lG&&lz)&&!1===lO?"0":"1":"0",marketing_consent:(null==l6?void 0:l6.receiveUpdates)??!1,url:`${lR}/${l2}/order-confirmation`,bundle_category:lH?"1":"0"};if(ee&&l0&&(null==l0?void 0:l0.is_fraud_rules_enabled)){let l={...ee,tran_description:"purchaseFreeSim"};iD={...iD,additional_payment_info:{...l}}}if((null==el?void 0:el.paymentType)==="0"&&(iD={...iD,apm_input_details:{apm_id:"0",apm_name:"APMS"},payment_mode:3}),(null==el?void 0:el.paymentType)==="54"&&(iD={...iD,apm_input_details:{apm_id:"54",apm_name:"REVOLUT PAY",address_details:{bank_swift_code:"",shopper_bank_code:"",first_name:l6.first_name,last_name:l6.last_name,address_line1:"",address_line2:"",city:"",post_code:"",country_iso_code:null==l0?void 0:l0.country_code}}}),(null==l0?void 0:l0.country_code)==="SE"&&"54"===el.paymentType&&(iD=(null==ez||null==(a=ez.cartItem)?void 0:a.bundle_selected)?{...iD,apm_input_details:{apm_id:"54",apm_name:"PAYIN DEPOSIT",address_details:{bank_swift_code:"",shopper_bank_code:"",first_name:l6.first_name,last_name:l6.last_name,address_line1:(null==l6||null==(y=l6.billingInfo)?void 0:y.house_no)||"",address_line2:(null==(g=(null==l6||null==(h=l6.billingInfo)?void 0:h.street_name)?null==l6||null==(b=l6.billingInfo)?void 0:b.street_name:(null==l6||null==(A=l6.billingInfo)||A.address2,null==l6||null==(x=l6.billingInfo)?void 0:x.address2))?void 0:g.substring(0,50))||"",city:(null==el?void 0:el.card_no)?"":null==l6||null==(S=l6.billingInfo)?void 0:S.city,post_code:(null==el?void 0:el.card_no)?"":null==l6||null==(I=l6.billingInfo)?void 0:I.post_code,country_iso_code:null==l0?void 0:l0.country_code}},direct_debit:{iban:"",contact_no:"",account_holder_name:l6.first_name,first_name:l6.first_name,last_name:l6.last_name,address_line1:(null==l6||null==(C=l6.billingInfo)?void 0:C.house_no)||"",address_line2:(null==(T=(null==l6||null==(P=l6.billingInfo)?void 0:P.street_name)?null==l6||null==(N=l6.billingInfo)?void 0:N.street_name:(null==l6||null==(k=l6.billingInfo)||k.address2,null==l6||null==($=l6.billingInfo)?void 0:$.address2))?void 0:T.substring(0,50))||"",city:(null==el?void 0:el.card_no)?"":null==l6||null==(M=l6.billingInfo)?void 0:M.city,post_code:(null==el?void 0:el.card_no)?"":null==l6||null==(E=l6.billingInfo)?void 0:E.post_code,country_iso_code:null==l0?void 0:l0.country_code,account_holder_last_name:l6.last_name}
1,recurring:!0,payment_mode:6,auto_renewal_mode:"1"}:{...iD,apm_input_details:{apm_id:"54",apm_name:"PAYIN DEPOSIT",address_details:{bank_swift_code:"",shopper_bank_code:"",first_name:l6.first_name,last_name:l6.last_name,address_line1:(null==l6||null==(r=l6.billingInfo)?void 0:r.house_no)||"",address_line2:(null==(s=(null==l6||null==(u=l6.billingInfo)?void 0:u.street_name)?null==l6||null==(c=l6.billingInfo)?void 0:c.street_name:(null==l6||null==(v=l6.billingInfo)||v.address2,null==l6||null==(_=l6.billingInfo)?void 0:_.address2))?void 0:s.substring(0,50))||"",city:(null==el?void 0:el.card_no)?"":null==l6||null==(m=l6.billingInfo)?void 0:m.city,post_code:(null==el?void 0:el.card_no)?"":null==l6||null==(p=l6.billingInfo)?void 0:p.post_code,country_iso_code:null==l0?void 0:l0.country_code}},recurring:!1,payment_mode:3,auto_renewal_mode:"0"}),((null==lq?void 0:lq.paymentType)==="1"||(null==lq?void 0:lq.paymentType)==="157"||(null==lq?void 0:lq.paymentType)==="209"||(null==el?void 0:el.paymentType)==="1"||(null==el?void 0:el.paymentType)==="157"||(null==el?void 0:el.paymentType)==="209"&&(null==el?void 0:el.paymentType)!="0"&&(null==el?void 0:el.paymentType)!="54")&&(iD={...iD,apm_input_details:{apm_id:(null==el?void 0:el.paymentType)||"1",apm_name:(null==el?void 0:el.paymentType)!=="209"?"PAYPAL":"TWINT",address_details:{first_name:l6.first_name,last_name:l6.last_name,address_line1:(null==l0?void 0:l0.country_code)!=="GB"||(null==el?void 0:el.card_no)?"":null==l6||null==(L=l6.billingInfo)?void 0:L.house_no,address_line2:(null==l0?void 0:l0.country_code)!=="GB"||(null==el?void 0:el.card_no)?"":null==(U=(null==l6||null==(z=l6.billingInfo)?void 0:z.street_name)?null==l6||null==(G=l6.billingInfo)?void 0:G.street_name:(null==l6||null==(V=l6.billingInfo)||V.address2,null==l6||null==(W=l6.billingInfo)?void 0:W.address2))?void 0:U.substring(0,50),city:(null==el?void 0:el.card_no)?"":null==l6||null==(q=l6.billingInfo)?void 0:q.city,post_code:(null==el?void 0:el.card_no)?"":null==l6||null==(X=l6.billingInfo)?void 0:X.post_code}}}),iD=(null==ez||null==(d=ez.cartItem)?void 0:d.bundle_selected)||(null==lh?void 0:lh.length)?{...iD,recurring:!0!==(lG&&lz)||!1!==lO}:{...iD,recurring:!0===(lG&&lz)&&!0===lO},(null==el?void 0:el.paymentType)!="1"&&(null==el?void 0:el.paymentType)!="0"&&(null==el?void 0:el.paymentType)!="54"&&(null==el?void 0:el.paymentType)!="157"&&(null==el?void 0:el.paymentType)!="209"&&(iD={...iD,auto_renewal_mode:(null==ez||null==(Y=ez.cartItem)?void 0:Y.bundle_selected)||(null==lh?void 0:lh.length)!==0?!0===(lG&&lz)&&!1===lO?"0":"1":"0"}),(null==lq?void 0:lq.paymentType)!=="13"||(null==el?void 0:el.paymentType)||(iD={...iD,apm_input_details:{apm_id:"13",apm_name:"MISTERCASH",address_details:{first_name:(null==lq||null==(Q=lq.banContactInfo)?void 0:Q.first_name)||"",last_name:(null==lq||null==(ll=lq.banContactInfo)?void 0:ll.last_name)||"",address_line1:(null==lq||null==(le=lq.banContactInfo)?void 0:le.house_number)||"",address_line2:(ln=(null==lq||null==(li=lq.banContactInfo)?void 0:li.street)+" "+(null==lq||null==(lo=lq.banContactInfo)?void 0:lo.house_no)||"",ln.substring(0,50)),address_line3:(lt=(null==lq||null==(la=lq.banContactInfo)?void 0:la.county)+" "+(null==lq||null==(lr=lq.banContactInfo)?void 0:lr.country)||"",lt.substring(0,50)),city:(null==lq||null==(ls=lq.banContactInfo)?void 0:ls.city)||"",post_code:(null==lq||null==(lu=lq.banContactInfo)?void 0:lu.post_code)||""}},address:{...null==iD?void 0:iD.address,post_code:(null==lq||null==(lc=lq.banContactInfo)?void 0:lc.post_code)||"",country:null==l0?void 0:l0.country}
1,card_detail:{...null==iD?void 0:iD.card_detail,billing_address:{...null==iD||null==(l_=iD.card_detail)?void 0:l_.billing_address,post_code:(null==lq||null==(lm=lq.banContactInfo)?void 0:lm.post_code)||""}},payment_mode:3,recurring:!1,auto_renewal_mode:"0"}),((null==lq?void 0:lq.paymentType)!=="49"||(null==el?void 0:el.paymentType))&&(!e_||(null==lq?void 0:lq.paymentType)!=="49")||(iD={...iD,apm_input_details:{apm_id:"49",apm_name:"IDEAL",shopper_bank_code:(null==lq||null==(lx=lq.idealPaymentInfo)||null==(lf=lx.selectedBank)?void 0:lf.shopper_bank_code)||"false",address_details:{first_name:(null==lq||null==(lC=lq.idealPaymentInfo)||null==(lS=lC.data)?void 0:lS.first_name)||"",last_name:(null==lq||null==(lj=lq.idealPaymentInfo)||null==(lD=lj.data)?void 0:lD.last_name)||"",address_line1:(null==lq||null==(lk=lq.idealPaymentInfo)||null==(lP=lk.data)?void 0:lP.address_line_1)||"",address_line2:(null==lq||null==(lM=lq.idealPaymentInfo)||null==(l$=lM.data)?void 0:l$.address_line_2)||"",address_line3:(null==lq||null==(lL=lq.idealPaymentInfo)||null==(lE=lL.data)?void 0:lE.address_line_3)||"",city:(null==lq||null==(lU=lq.idealPaymentInfo)||null==(lB=lU.data)?void 0:lB.city)||"",post_code:(null==lq||null==(lZ=lq.idealPaymentInfo)||null==(lK=lZ.data)?void 0:lK.post_code)||""}},address:{...null==iD?void 0:iD.address,post_code:e_?(null==iD?void 0:iD.address.post_code)??"":(null==lq||null==(l3=lq.idealPaymentInfo)||null==(l4=l3.data)?void 0:l4.post_code)??"",country:null==l0?void 0:l0.country}
1,card_detail:{...null==iD?void 0:iD.card_detail,billing_address:{...null==iD||null==(l8=iD.card_detail)?void 0:l8.billing_address,post_code:(null==lq||null==(ei=lq.idealPaymentInfo)||null==(en=ei.data)?void 0:en.post_code)||""}},payment_mode:3,recurring:!1,auto_renewal_mode:"0",customer_consent:"0"}),(null==lq?void 0:lq.paymentType)==="53"&&(iD={...iD,apm_input_details:{apm_id:"53",apm_name:"BLIK",blik_code:(null==lq||null==(eo=lq.blikInfo)?void 0:eo.blik_code)||"",address_details:{}},address:{...null==iD?void 0:iD.address,post_code:(null==l6||null==(ed=l6.delivery_info)?void 0:ed.post_code)||"",country:null==l0?void 0:l0.country},card_detail:{...null==iD?void 0:iD.card_detail,billing_address:{...null==iD||null==(ea=iD.card_detail)?void 0:ea.billing_address,post_code:(null==l6||null==(er=l6.delivery_info)?void 0:er.post_code)||""}},payment_mode:3,recurring:!1,auto_renewal_mode:"0",customer_consent:"0"}),((null==l0?void 0:l0.country)!="USA"||!ef||eh||lg)&&((null==l0?void 0:l0.country)!="USA"||ef||eh||lg)){if((null==l0?void 0:l0.country)==="USA"&&!lg)return void lJ((0,B.ZD)({display:!0,severity:"error",message:ef?f.A.differentPostalCode:f.A.pleaseEnterValidPostal}))}else{let l=ef?eB((null==l6||null==(ec=l6.delivery_info)||null==(es=ec.deliveryInfoAddressFinderData)?void 0:es.post_code)||(null==l6||null==(eA=l6.billingInfo)||null==(eg=eA.billingAddressFinderData)?void 0:eg.post_code)||(null==l6||null==(eS=l6.delivery_info)?void 0:eS.post_code)||(null==l6||null==(eC=l6.billingInfo)?void 0:eC.post_code)||(null==l6||null==(eP=l6.billingInfo)||null==(eD=eP.billingAddressFinderData)?void 0:eD.post_code))??eb:eB(eI);if(!l)return void lJ((0,B.ZD)({display:!0,severity:"error",message:f.A.differentPostalCode}));et(!0);try{let{status:e,data:n}=await H.A.post(O.t.areaNetwork,{zip_code:l});(200==e||204===e)&&(null==n||null==(eN=n.sim_availability)?void 0:eN.availability)&&(lJ((0,D.lu)(!1)),et(!1))}catch(l){et(!1),lJ((0,B.ZD)({display:!0,severity:"error",message:f.A.differentPostalCode??(null==l||null==(eM=l.response)||null==(e$=eM.data)?void 0:e$.message)}));return}}if((null==lI?void 0:lI.promo_code_name)&&!lg){let l={msisdn:(null==lq?void 0:lq.contact_number)??"",promo_code:(null==lI?void 0:lI.promo_code_name)??"",promo_type:(null==lI?void 0:lI.promo_code_type)??"",total_amount:(0,j.qVQ)(J)??"",payment_state:"PAYMENT_INITIATED",email_id:l6.email??""};await (0,Z.Br)(l)}if(null==l0?void 0:l0.is_hot_sim){let l="0";!(0,j.a44)(lF)||lg||lH||(l=lF?"1":"0"),iD={...iD,allocate_sim:l}}lw&&(iD={...iD,coupon_id:null==lw?void 0:lw.coupon_id}),ey&&(iD={...iD,payment_mode:"5",card_detail:{...null==iD?void 0:iD.card_detail,billing_address:eq()}}),(null==l6?void 0:l6.isValid)&&(null==l6?void 0:l6.fiscal_id)!=""&&(iD={...iD,fiscal_id:null==l6?void 0:l6.fiscal_id}),ej&&(iD=(0,j.GAo)(iD));try{let l;if((0,F.gC)(w.H.personalDetails,JSON.stringify({...l6}),!0),lT){if(!lV)return void console.log("not available to execute recaptcha");l=await lV("freesim")}let e=l?await (0,lv.bQ)(l,w.H.rsaKey):null;if(et(!0),(null==eJ||null==(eE=eJ[0])?void 0:eE.bundle_detail)===null&&(null==eJ||null==(eH=eJ[0])?void 0:eH.topup_id)&&!ly&&!lg&&(iD=(0,j.s5j)(iD)),em){let l=((null==lR?void 0:lR.country_prefix)||(null==l0?void 0:l0.country_number_code)||"").replace("+",""),e={};ep&&(null==l0||null==(eL=l0.sim_details)||null==(eO=eL.prepaid)?void 0:eO.enable_checkout_portin)&&(e={portin_msisdn:`${l}${(null==em?void 0:em.portin_msisdn)||""}`,...(null==em?void 0:em.pac_code)&&{pac_code:em.pac_code},...(null==em?void 0:em.portin_date)&&{portin_date:em.portin_date},...(null==em?void 0:em.portin_wish_time)&&{portin_wish_time:em.portin_wish_time},...(null==em?void 0:em.preferred_language)&&{preferred_language:em.preferred_language},...(null==em?void 0:em.contract_type)&&{contract_type:em.contract_type},...(null==em?void 0:em.portin_date_postpaid)&&{portin_date_postpaid:em.portin_date_postpaid},...(null==em?void 0:em.company_name)&&{company_name:em.company_name},...(null==em?void 0:em.service_provider)&&{donar_service_provider:em.service_provider},...(null==em?void 0:em.function_type)&&{function_type:em.function_type},...(null==em?void 0:em.rio)&&{rio_code:em.rio},...(null==em?void 0:em.port_in_iccid)&&{portin_iccid:em.port_in_iccid}}),iD={...iD,...Object.keys(e).length>0&&{portin_info:e}}}let{status:n,data:i}=await H.A.post(O.t.freeSim,iD,{headers:{"captcha-response":e||""}});
1if(200===n)if(eQ(),et(!1),(0,F.UI)("paymentInfo",!0),lJ((0,D.x5)({})),lJ((0,D.X0)({...l6,billingInfo:{...null==l6?void 0:l6.billingInfo,name_on_card:"",card_no:"",expiry_date:"",cvv:""}})),(0,F.gC)(w.H.personalDetails,JSON.stringify({...l6,billingInfo:{...null==l6?void 0:l6.billingInfo,name_on_card:"",card_no:"",expiry_date:"",cvv:""}}),!0),ly||lg){if(ly&&!lg){localStorage.removeItem("cart_data"),localStorage.removeItem("basket_data");let l={...iD,card_detail:"",taxDetails:null==lb?void 0:lb.total_tax,transaction_id:i.transaction_id||(null==i||null==(e3=i.topup)?void 0:e3.transaction_id),card_no:null==(e9=(0,j.KAJ)(null==el?void 0:el.card_no))||null==(e8=e9.slice)?void 0:e8.call(e9,-4),cardType:(null==iD?void 0:iD.payment_mode)==="3"?"paypal":ev||"na",freeSim:ly,ca:eu,isQuickTop:!1,fromCart:!1,selectedPromoDetails:lI};(0,F.gC)(w.H.purchessFreeSimRequest,JSON.stringify(l),!0);let e={transaction_id:null==l?void 0:l.transaction_id,session_data:JSON.stringify({...l,freeSimDetails:{totalAmount:null==lQ?void 0:lQ.totalAmount,id:null==lQ||null==(e7=lQ.selectedPlan[0])?void 0:e7.id,selectedPlan:[{productDisplayName:null==lQ||null==(e6=lQ.selectedPlan)?void 0:e6[0].productDisplayName,planName:null==lQ||null==(nl=lQ.selectedPlan)?void 0:nl[0].productName,selectedBundle:null==lQ||null==(nn=lQ.selectedPlan)||null==(ne=nn[0])?void 0:ne.selectedBundle,bundleGroupDetails:null==lQ||null==(no=lQ.selectedPlan)||null==(ni=no[0])?void 0:ni.bundleGroupDetails,unlimitedData:null==lQ||null==(nd=lQ.selectedPlan)||null==(nt=nd[0])?void 0:nt.unlimitedData,dataAllowance:(null==lQ||null==(nr=lQ.selectedPlan)||null==(na=nr[0])?void 0:na.dataAllowance)||"",dataAllowanceUnit:(null==lQ||null==(nu=lQ.selectedPlan)||null==(ns=nu[0])?void 0:ns.dataAllowanceUnit)||"",dataAllowanceDuration:(null==lQ||null==(nv=lQ.selectedPlan)||null==(nc=nv[0])?void 0:nc.dataAllowanceDuration)||""}]}})};(null==i?void 0:i.payment_type_identifier)!=="2D"&&await (0,Z.U9)(e);let n=(0,F.wb)(w.H.basket_data);if(n&&(0,F.gC)(w.H.cartInfo,n,!0),(null==i?void 0:i.tds_pareq)&&(null==i?void 0:i.tds_acsurl)&&(null==i?void 0:i.redorder_id)||(null==i?void 0:i.payment_type_identifier)==="3D"||(null==i||null==(n_=i.topup)?void 0:n_.tds_acsurl)){await H.A.post(O.t.printLogs,{message:`Initiating 3D redirection to url - ${null==i||null==(nm=i.topup)?void 0:nm.tds_acsurl} for transaction: ${e.transaction_id}`,...ex&&{url:null==i||null==(np=i.topup)?void 0:np.tds_acsurl}});try{ex?window.location.href=null==i||null==(ny=i.topup)?void 0:ny.tds_acsurl:window.open(null==i||null==(nf=i.topup)?void 0:nf.tds_acsurl,"_self")}catch(l){await H.A.post(O.t.printLogs,{message:`Redirection to url - ${null==i||null==(ng=i.topup)?void 0:ng.tds_acsurl} failed for transaction ID: ${e.transaction_id}. Error: ${(null==l?void 0:l.message)||l}`})}}else if((null==i?void 0:i.payment_type_identifier)==="2D"&&(null==i?void 0:i.error_code)==="395"){let l={tranId:null==i||null==(nh=i.topup)?void 0:nh.transaction_id,total:null==i?void 0:i.total_payment_amount};lY.push(`${ld.Ay.pending}?id=${null==l?void 0:l.tranId}`,void 0,{shallow:!0})}else if((null==i?void 0:i.payment_type_identifier)==="2D"){let e={id:(null==l?void 0:l.transaction_id)||"",orderId:"",total:ly&&!lg?ek.toString()||"0":ly&&lg?"0":eT.toString()||"0",sim_order_ids:(null==i?void 0:i.sim_order_ids)||[]};(0,F.gC)("paymentInfo",JSON.stringify(e),!0),await lY.push(`${ld.Ay.success}?id=${null==e?void 0:e.id}&total=${e.total}&p=s`)}}else if(ly&&!lg){localStorage.removeItem("cart_data"),localStorage.removeItem("basket_data");let l={...iD,taxDetails:null==lb?void 0:lb.total_tax,transaction_id:i.transaction_id||(null==i||null==(nb=i.topup)?void 0:nb.transaction_id),card_no:null==el||null==(nx=el.card_no)||null==(nA=nx.slice)?void 0:nA.call(nx,-4),freeSim:ly,ca:eu,isQuickTop:!1,fromCart:!1,selectedPromoDetails:lI};(0,F.gC)(w.H.purchessFreeSimRequest,JSON.stringify(l),!0);let e=(0,F.wb)(w.H.basket_data);if(e&&(0,F.gC)(w.H.cartInfo,e,!0),(null==i?void 0:i.tds_pareq)&&(null==i?void 0:i.tds_acsurl)&&(null==i?void 0:i.redorder_id)||(null==i?void 0:i.payment_type_identifier)==="3D"||(null==i||null==(nS=i.topup)?void 0:nS.tds_acsurl)){await H.A.post(O.t.printLogs,{message:`Initiating 3D redirection to url - ${null==i||null==(nI=i.topup)?void 0:nI.tds_acsurl} for transaction: ${l.transaction_id}`,...ex&&{url:null==i||null==(nC=i.topup)?void 0:nC.tds_acsurl}});try{ex?window.location.href=null==i||null==(nD=i.topup)?void 0:nD.tds_acsurl:window.open(null==i||null==(nj=i.topup)?void 0:nj.tds_acsurl,"_self")}catch(e){await H.A.post(O.t.printLogs,{message:`Redirection to url - ${null==i||null==(nT=i.topup)?void 0:nT.tds_acsurl} failed for transaction ID: ${l.transaction_id}. Error: ${(null==e?void 0:e.message)||e}`})}}else if((null==i?void 0:i.payment_type_identifier)==="2D"){let l={id:i.transaction_id||(null==i||null==(nF=i.topup)?void 0:nF.transaction_id)||"",orderId:"",total:ly&&!lg?ek.toString()||"0":ly&&lg?(null==l0?void 0:l0.country)==="USA"&&lA||0:eT.toString()||"0",sim_order_ids:(null==i?void 0:i.sim_order_ids)||[]};(0,F.gC)("paymentInfo",JSON.stringify(l),!0),await lY.push(`${ld.Ay.success}?id=${null==l?void 0:l.id}&total=${l.total}
1&bundleCode=${(null==lh||null==(nP=lh.bundleGroupDetails)||null==(nw=nP[0])?void 0:nw.bundleCode)?null==lh||null==(nk=lh.bundleGroupDetails)||null==(nN=nk[0])?void 0:nN.bundleCode:""}&p=s`)}}else if(ly&&lg){localStorage.removeItem("cart_data"),localStorage.removeItem("basket_data");let l={...iD,card_detail:"",transaction_id:i.transaction_id||(null==i||null==(n$=i.topup)?void 0:n$.transaction_id),card_no:null==(nE=(0,j.KAJ)(null==el?void 0:el.card_no))||null==(nM=nE.slice)?void 0:nM.call(nE,-4),cardType:ev||"na",freeSim:ly,ca:eu,isQuickTop:!1,selectedPromoDetails:lI,freeSimClicked:lg,onlyFreeSim:ly&&lg,fromCart:!1,shippingCharges:(null==l0?void 0:l0.country)==="USA"&&lA||0};(0,F.gC)(w.H.purchessFreeSimRequest,JSON.stringify(l),!0);let e={transaction_id:null==l?void 0:l.transaction_id,session_data:JSON.stringify(l)};(null==i?void 0:i.payment_type_identifier)!=="2D"&&await (0,Z.U9)(e),lJ((0,D.X0)({...l6,billingInfo:{...null==l6?void 0:l6.billingInfo,name_on_card:"",card_no:"",expiry_date:"",cvv:""}}));let n=(0,F.wb)(w.H.basket_data);if(n&&(0,F.gC)(w.H.cartInfo,n,!0),(null==i?void 0:i.tds_pareq)&&(null==i?void 0:i.tds_acsurl)&&(null==i?void 0:i.redorder_id)||(null==i?void 0:i.payment_type_identifier)==="3D"||(null==i||null==(nH=i.topup)?void 0:nH.tds_acsurl)){await H.A.post(O.t.printLogs,{message:`Initiating 3D redirection to url - ${null==i||null==(nO=i.topup)?void 0:nO.tds_acsurl} for transaction: ${e.transaction_id}`,...ex&&{url:null==i||null==(nL=i.topup)?void 0:nL.tds_acsurl}});try{ex?window.location.href=null==i||null==(nB=i.topup)?void 0:nB.tds_acsurl:window.open(null==i||null==(nU=i.topup)?void 0:nU.tds_acsurl,"_self")}catch(l){await H.A.post(O.t.printLogs,{message:`Redirection to url - ${null==i||null==(nz=i.topup)?void 0:nz.tds_acsurl} failed for transaction ID: ${e.transaction_id}. Error: ${(null==l?void 0:l.message)||l}`})}}else if((null==i?void 0:i.payment_type_identifier)==="2D"&&(null==i?void 0:i.error_code)==="395"){let l={tranId:null==i||null==(nG=i.topup)?void 0:nG.transaction_id,total:null==i?void 0:i.total_payment_amount};lY.push(`${ld.Ay.pending}?id=${null==l?void 0:l.tranId}`,void 0,{shallow:!0})}else if((null==i?void 0:i.payment_type_identifier)==="2D"){let l={id:i.transaction_id||(null==i||null==(nR=i.topup)?void 0:nR.transaction_id)||"",orderId:"",total:(null==l0?void 0:l0.country)==="USA"&&lA||0,sim_order_ids:(null==i?void 0:i.sim_order_ids)||[]};(0,F.gC)("paymentInfo",JSON.stringify(l),!0),await lY.push(`${ld.Ay.success}?id=${null==l?void 0:l.id}'&total=${null==l?void 0:l.total}&p=s`)}}}
1else{let l={...iD,card_detail:"",transaction_id:i.transaction_id||(null==i||null==(eU=i.topup)?void 0:eU.transaction_id),card_no:null==(eK=(0,j.KAJ)(null==el?void 0:el.card_no))||null==(eG=eK.slice)?void 0:eG.call(eK,-4),cardType:(null==iD?void 0:iD.payment_mode)==="3"?"paypal":null==el?void 0:el.card_type,ca:eu,isQuickTop:!1,fromCart:!ly&&!lg,taxDetails:(null==lb?void 0:lb.total_tax)||0,selectedPromoDetails:lI};(0,F.gC)(w.H.purchessFreeSimRequest,JSON.stringify(l),!0);let e=(0,F.wb)(w.H.basket_data);e&&(0,F.gC)(w.H.cartInfo,e,!0);let n={transaction_id:null==l?void 0:l.transaction_id,session_data:JSON.stringify({...l,basketState:e,card_detail:""})};if((null==i?void 0:i.payment_type_identifier)!=="2D"&&await (0,Z.U9)(n),(null==i?void 0:i.tds_pareq)&&(null==i?void 0:i.tds_acsurl)&&(null==i?void 0:i.redorder_id)||(null==i?void 0:i.payment_type_identifier)==="3D"||(null==i||null==(eX=i.topup)?void 0:eX.tds_acsurl)){await H.A.post(O.t.printLogs,{message:`Initiating 3D redirection to url - ${null==i||null==(eY=i.topup)?void 0:eY.tds_acsurl} for transaction: ${n.transaction_id}`,...ex&&{url:null==i||null==(e0=i.topup)?void 0:e0.tds_acsurl}});try{ex?window.location.href=null==i||null==(e1=i.topup)?void 0:e1.tds_acsurl:window.open(null==i||null==(e2=i.topup)?void 0:e2.tds_acsurl,"_self")}catch(l){await H.A.post(O.t.printLogs,{message:`Redirection to url - ${null==i||null==(e4=i.topup)?void 0:e4.tds_acsurl} failed for transaction ID: ${n.transaction_id}. Error: ${(null==l?void 0:l.message)||l}`})}}else if((null==i?void 0:i.payment_type_identifier)==="2D"&&(null==i?void 0:i.error_code)==="395"){let l={tranId:null==i||null==(e5=i.topup)?void 0:e5.transaction_id,total:null==i?void 0:i.total_payment_amount};lY.push(`${ld.Ay.pending}?id=${null==l?void 0:l.tranId}`,void 0,{shallow:!0})}else if((null==i?void 0:i.payment_type_identifier)==="2D"){let e={id:(null==l?void 0:l.transaction_id)||"",orderId:"",total:ly&&!lg?eF.toString()||"0":ly&&lg?"0":eT.toString()||"0",sim_order_ids:(null==i?void 0:i.sim_order_ids)||[]};(0,F.gC)("paymentInfo",JSON.stringify(e),!0),await lY.push(`${ld.Ay.success}?id=${null==e?void 0:e.id}&total=${e.total}&p=s`)}}et(!1)}catch(l){if(et(!1),l7(!1),lg&&(null==lh?void 0:lh.length)===0){let e={onlyFreeSim:!0,baseWindow:lN,formName:"free sim failure ",paymentError:(null==l||null==(nq=l.response)||null==(nK=nq.data)||null==(nJ=nK.cause)||null==(nW=nJ[0])?void 0:nW.plintron_error_message)||"na",transactionId:(null==l||null==(nQ=l.response)||null==(nY=nQ.data)||null==(nX=nY.cause)||null==(nZ=nX[0])?void 0:nZ.channel_transaction_id)||"na",event:"purchase failure",total:"0",currencyCode:l0,paymentType:(null==iD?void 0:iD.payment_mode)==="3"?"paypal":(0,j.$UG)(null==el?void 0:el.card_type),simSelection:null==iD||null==(n4=iD.sim_with_bundle_details)||null==(n2=n4.sim_details)||null==(n1=n2[0])||null==(n0=n1.type_of_sim)?void 0:n0.toLowerCase()};(0,j.ub8)(e)}if(ly&&(null==lh?void 0:lh.length)>0){let e=(null==lh||null==(n3=lh[0])||null==(n5=n3.bundleGroupDetails[0])?void 0:n5.promotionalPricing)?null==lh||null==(n7=lh[0])||null==(n9=n7.bundleGroupDetails)||null==(n8=n9[0])?void 0:n8.promotionalPricing:null==lh||null==(ie=lh[0])||null==(il=ie.bundleGroupDetails)||null==(n6=il[0])?void 0:n6.basePrice,n={isFreeSim:!0,baseWindow:lN,formName:"free sim with bundle failure ",paymentError:(null==l||null==(id=l.response)||null==(it=id.data)||null==(io=it.cause)||null==(ii=io[0])?void 0:ii.plintron_error_message)||"na",transactionId:(null==l||null==(iu=l.response)||null==(is=iu.data)||null==(ir=is.cause)||null==(ia=ir[0])?void 0:ia.channel_transaction_id)||"na",event:"purchase failure",currencyCode:l0,price:e,planName:null==lh||null==(ic=lh[0])?void 0:ic.productName,paymentType:(null==iD?void 0:iD.payment_mode)==="3"?"paypal":(0,j.$UG)(null==el?void 0:el.card_type),total:e,simSelection:null==iD||null==(ip=iD.sim_with_bundle_details)||null==(im=ip.sim_details)||null==(i_=im[0])||null==(iv=i_.type_of_sim)?void 0:iv.toLowerCase()};(0,j.ub8)(n)}if(!ly&&!lg){let e={basketState:lX&&JSON.parse(lX),allTopUpPlans:K,baseWindow:lN,total:eZ(lX&&JSON.parse(lX)),currency_code:(null==lW||null==(iy=lW.tradeDoubler)?void 0:iy.currencyCode)||"na",configData:l0,formName:"new sim bundle and topup",paymentError:(null==l||null==(iA=l.response)||null==(ib=iA.data)||null==(ih=ib.cause)||null==(ig=ih[0])?void 0:ig.plintron_error_message)||"na",transactionId:(null==l||null==(iC=l.response)||null==(iI=iC.data)||null==(iS=iI.cause)||null==(ix=iS[0])?void 0:ix.channel_transaction_id)||"na",paymentType:(null==iD?void 0:iD.payment_mode)==="3"?"paypal":(0,j.$UG)(null==el?void 0:el.card_type),auto_renew
1al:"yes",renewal_type:"yes",event:"purchase failure"};(0,j.p8o)(e)}lJ((0,B.ZD)({display:!0,severity:"error",message:null==l||null==(nV=l.response)?void 0:nV.data.message}))}(0,F.UI)(null===w.H||void 0===w.H?void 0:w.H.purchaseSatus,!0)},eY=(0,o.useMemo)(()=>{var l,e,n,i,o,t,d,a,r,s,u,c,v,_;let m=lk?!lg:!0===lg;return eE&&!ef&&eh&&m||(!!ly||!!lg)&&((null===q||""===q)&&((null==lQ?void 0:lQ.selectedSIM)===0||(null==lQ?void 0:lQ.selectedSIM)===void 0)||(null==q?void 0:q.toLowerCase())!=="esim"&&!(null==l6||null==(l=l6.billingInfo)?void 0:l.addressFinderValue)&&!(null==l6||null==(e=l6.delivery_info)?void 0:e.addressFinderValue)&&!(null==l6||null==(n=l6.delivery_info)?void 0:n.isvalid))||null===el&&(null==l6?void 0:l6.selectedCardOption)==="1000"||((null==el?void 0:el.validForm)?!(null==el?void 0:el.validForm):(null==el?void 0:el.paymentType)==="1000"&&!ey)||!(null==l6||null==(i=l6.billingInfo)?void 0:i.isvalid)&&(null==l6||null==(o=l6.billingInfo)?void 0:o.addressFinderValue)===null&&((null==el?void 0:el.paymentType)!=="1"||(null==el?void 0:el.paymentType)!=="157"||(null==el?void 0:el.paymentType)!=="49"||(null==el?void 0:el.paymentType)!=="13"||(null==el?void 0:el.paymentType)!=="53")||!(null==l6||null==(t=l6.delivery_info)?void 0:t.isvali
1d)&&(null==l6||null==(d=l6.delivery_info)||d.addressFinderValue,!1)||!(ly||lg)&&(null==(r=V[0])||null==(a=r.cartItem)?void 0:a.physical_sim)&&((null==l6?void 0:l6.delivery_info)===void 0||(null==l6||null==(s=l6.delivery_info)?void 0:s.addressFinder)&&!(null==l6||null==(u=l6.delivery_info)?void 0:u.addressFinderValue))||!(null==l6?void 0:l6.delivery_info_isvalid)&&(null==q?void 0:q.toLowerCase())!=="esim"&&e_||!(null==l6?void 0:l6.isValid)||!(null==l6?void 0:l6.first_name)||!(null==l6?void 0:l6.last_name)||!(null==l6||null==(c=l6.email)?void 0:c.trim())||((null==q?void 0:q.toLowerCase())==="esim"&&(null==l0?void 0:l0.esim_verification)?!(null==l6?void 0:l6.emailVerified):(null==q?void 0:q.toLowerCase())!=="esim"&&null!=l0&&!!l0.physical_sim_verification&&!(null==l6?void 0:l6.emailVerified))||!lZ||((null==(_=V[0])||null==(v=_.cartItem)?void 0:v.physical_sim)||(ly||lg)&&"eSIM"!==q?!(l6.delivery_info_isvalid&&l6.billingInfo_isvalid&&lj)&&(null==l6?void 0:l6.selectedCardOption)==="1000"||!l6.delivery_info_isvalid&&lj&&((null==l6?void 0:l6.selectedCardOption)==="1"||(null==l6?void 0:l6.selectedCardOption)==="157"):!(null==l6?void 0:l6.billingInfo_isvalid)&&(null==l6?void 0:l6.selectedCardOption)==="1000")},[el,q,l6,null==l6?void 0:l6.emailVerified,null==l6?void 0:l6.email,null==l6||null==(P=l6.billingInfo)?void 0:P.isvalid,(null==l6||null==(N=l6.delivery_info)?void 0:N.isvalid)&&W,null==l0?void 0:l0.esim_verification,null==l0?void 0:l0.physical_sim_verification,lZ,null==l6?void 0:l6.delivery_info_isvalid,null==l6?void 0:l6.billingInfo_isvalid,eh]);(0,o.useEffect)(()=>{(null==l0?void 0:l0.country)!=="USA"||!l6||eY||(null==lh?void 0:lh.length)!==0&&void 0!==lh||lg||(async()=>{var l,e,n,i,o,t,d,a,r,s;try{let s={zip_code:ef?eB((null==l6||null==(e=l6.delivery_info)||null==(l=e.deliveryInfoAddressFinderData)?void 0:l.post_code)||(null==l6||null==(i=l6.billingInfo)||null==(n=i.billingAddressFinderData)?void 0:n.post_code)||(null==l6||null==(o=l6.delivery_info)?void 0:o.post_code)||(null==l6||null==(t=l6.billingInfo)?void 0:t.post_code)||(null==l6||null==(a=l6.billingInfo)||null==(d=a.billingAddressFinderData)?void 0:d.post_code))??eb:eB(eI)};if(eb){et(!0);let{status:l,data:e}=await H.A.post(O.t.areaNetwork,s);if((200==l||204===l)&&(null==e||null==(r=e.sim_availability)?void 0:r.availability)){lJ((0,D.lu)(!1)),eM(!1),et(!1);let l=0,n=0;V.forEach(async i=>{var o,t,d,a,r,s,u,c,v,_,m,p;if(null==i||null==(o=i.cartItem)?void 0:o.card_id){l=eO(null==i||null==(p=i.cartItem)?void 0:p.card_id);try{let{data:n}=await eU(l,null==e?void 0:e.postcode);i.topup_tax_details={tax:(null==n?void 0:n.total_tax)||"",tax_id:(null==n?void 0:n.tax_id)||""}}catch(l){}}if(n=(null==i||null==(t=i.cartItem)?void 0:t.bundle_selected)?((null==(d=eL(null==i||null==(a=i.planItem)?void 0:a.bundleGroupDetails,null==i||null==(r=i.cartItem)?void 0:r.bundle_code))?void 0:d.promotionalPricing)?null==(s=eL(null==i||null==(u=i.planItem)?void 0:u.bundleGroupDetails,null==i||null==(c=i.cartItem)?void 0:c.bundle_code))?void 0:s.promotionalPricing:null==(v=eL(null==i||null==(_=i.planItem)?void 0:_.bundleGroupDetails,null==i||null==(m=i.cartItem)?void 0:m.bundle_code))?void 0:v.basePrice)??0:0,0!==n)try{let{data:l}=await eU(n,null==e?void 0:e.postcode);i.bundle_tax_details={tax:(null==l?void 0:l.total_tax)||"",tax_id:(null==l?void 0:l.tax_id)||""}}catch(l){}})}}}catch(l){eM(!0),et(!1),lJ((0,B.ZD)({display:!0,severity:"error",message:f.A.differentPostalCode??(null==l||null==(s=l.response)?void 0:s.data.message)}))}})()},[V,eY,null==l0?void 0:l0.country]),(0,o.useEffect)(()=>{ef&&(null==l0?void 0:l0.country)==="USA"&&l6&&!eY&&!lg&&(null==lh?void 0:lh.length)>0&&(async()=>{var l,e,n,i,o,t,d,a,r,s;try{et(!0);let s={zip_code:eB((null==l6||null==(e=l6.delivery_info)||null==(l=e.deliveryInfoAddressFinderData)?void 0:l.post_code)||(null==l6||null==(i=l6.billingInfo)||null==(n=i.billingAddressFinderData)?void 0:n.post_code)||(null==l6||null==(o=l6.delivery_info)?void 0:o.post_code)||(null==l6||null==(t=l6.billingInfo)?void 0:t.post_code)||(null==l6||null==(a=l6.billingInfo)||null==(d=a.billingAddressFinderData)?void 0:d.post_code))??eb};if(eb){let{status:l,data:e}=await H.A.post(O.t.areaNetwork,s);(200==l||204===l)&&(null==e||null==(r=e.sim_availability)?void 0:r.availability)&&(lJ((0,D.lu)(!1)),eM(!1),et(!1),lh.forEach(async l=>{var n,i,o,t,d,a;
1let r=(null==l||null==(i=l.bundleGroupDetails)||null==(n=i[0])?void 0:n.promotionalPricing)?null==l||null==(t=l.bundleGroupDetails)||null==(o=t[0])?void 0:o.promotionalPricing:null==l||null==(a=l.bundleGroupDetails)||null==(d=a[0])?void 0:d.basePrice;if(0!==r)try{let{data:n}=await eU(r,null==e?void 0:e.postcode);lJ((0,D.o4)({...lb,total_tax:null==n?void 0:n.total_tax,tax_id:null==n?void 0:n.tax_id})),l.bundle_tax_details={tax:(null==n?void 0:n.total_tax)||"",tax_id:(null==n?void 0:n.tax_id)||""}}catch(l){}}))}}catch(l){eM(!0),lJ((0,B.ZD)({display:!0,severity:"error",message:f.A.differentPostalCode??(null==l||null==(s=l.response)?void 0:s.data.message)})),et(!1)}})()},[lh,eY,null==l0?void 0:l0.country,null==l6||null==($=l6.delivery_info)?void 0:$.addressFinder,null==l6||null==(E=l6.delivery_info)?void 0:E.post_code]),(0,o.useEffect)(()=>{eE&&((null==lI?void 0:lI.promo_code_type)==="1"&&(null==lI?void 0:lI.calculated_discount)||(null==lI?void 0:lI.promo_code_removed))&&(async()=>{try{var l,e,n,i,o,t;let d=lh?eW():eR(),a=0,r=0;if(!(null==lI?void 0:lI.promo_code_removed)){let l=(null==eJ?void 0:eJ.length)||0;a=l?(Number(eN)||0)/l:0}if(lh){let i=null==(n=d[0])||null==(e=n.bundle_detail)||null==(l=e.sim_bundle_details)?void 0:l[0],o=Number(i.discount_amount||0);r=(null==lI?void 0:lI.promo_code_removed)?o:Math.max(o-a,0);let t=await eU(r,eI);if(null==t?void 0:t.data){let{total_tax:l,tax_id:e}=t.data;lJ((0,D.o4)({...lb,total_tax:l,tax_id:e}))}return}let s=0;for(let l=0;l<V.length;l++){let e=V[l],n=null==(t=d[l])||null==(o=t.bundle_detail)||null==(i=o.sim_bundle_details)?void 0:i[0],u=Number(n.discount_amount||0);if((r=(null==lI?void 0:lI.promo_code_removed)?u:Math.max(u-a,0))<=0)continue;let c=await eU(r,eI);if(null==c?void 0:c.data){let{total_tax:n,tax_id:i}=c.data;s+=Number(n),V[l]={...e,bundle_tax_details:{tax:n,tax_id:i}}}}s>0&&lJ((0,D.o4)({...lb,total_tax:s}))}catch(l){console.error("Error calculating tax:",l)}})()},[eE,eN,null==lI?void 0:lI.promo_code_removed]);let eQ=async()=>{try{let l={first_name:l6.first_name,last_name:l6.last_name,permission:[{permission_type:"termsAndCondition privacyPolicy paymentTerms",permission_accepted_time:new Date}]},{status:e}=await H.A.post(O.t.delivery_market_consent(l6.email),l)}catch(l){}};return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsx)(L.A,{}),(0,i.jsxs)(a.Ay,{id:lx?"termsConditionsCvm":"termsConditions",container:!0,direction:"column",alignItems:"center",children:[eo&&(0,i.jsx)(lo.A,{}),(0,i.jsx)(a.Ay,{item:!0,children:(0,i.jsxs)(h.A,{className:`${Q().formContainer}`,children:[lx&&(0,i.jsxs)(s.A,{children:[(0,i.jsx)("span",{className:Q().labelStyleCvm,children:f.A.byContinuingIagree})," ",(0,i.jsx)("span",{onClick:()=>(0,j.PAx)("node--landing_page_terms_and_condition"),className:Q().nestedSpanCvm,children:f.A.termsAndCond})]}),!lx&&(0,i.jsx)(s.A,{variant:"h5",...(0,j.$h_)("review-terms-heading-n"),gutterBottom:!0,className:Q().textHead,children:f.A.reviewTerms}),(0,i.jsxs)(a.Ay,{spacing:2,className:"toggle-terms-section",children:[lx?"":(0,i.jsxs)(a.Ay,{item:!0,xs:12,display:"flex",justifyContent:lK?"left":"center",sx:{marginLeft:"2px"},className:Q().entryWrapper,children:[(null==l0?void 0:l0.tnc_toggle)&&(0,i.jsx)(ll.A,{...(0,j.$h_)("switch-terms-n"),checked:l3,onChange:()=>{l8(!en&&!ed&&!er&&!l3)}}),ly?(0,i.jsx)(a.Ay,{...(0,j.$h_)("first-line-terms-free-n"),className:`${Q().labelStyle}`,children:eD?(0,i.jsxs)(i.Fragment,{children:[(null==l0?void 0:l0.country_code)==="FR"||"marketing"===lS?f.A.readAndAgree:f.A.termsFirstLine,(0,i.jsxs)("span",{className:Q().nestedSpan,onClick:l=>{l.preventDefault(),eH("terms")},children:[" ",f.A.termsCondition]}),(null==l0?void 0:l0.country_code)!=="FR"&&(0,i.jsxs)("span",{...(0,j.$h_)("privacy-policy-n"),className:Q().nestedSpan,onClick:()=>eH("privacy"),children:[" ",f.A.privacyPolicy]}),(null==l0?void 0:l0.country_code)==="FR"&&(0,i.jsx)("span",{children:" & "}),(0,i.jsxs)("span",{className:Q().nestedSpan,onClick:()=>eH("payment"),children:[" ",f.A.paymentTerm]}),(0,j.a44)(f.A.readAndAgreeText)&&(0,i.jsx)("span",{...(0,j.$h_)("read-agree-n_subtext"),style:{display:"block",paddingTop:"5px",fontSize:"14px",fontWeight:400,lineHeight:"19px"},children:f.A.readAndAgreeText})]}):(0,i.jsxs)(i.Fragment,{children:[(null==l0?void 0:l0.country_code)==="FR"||"marketing"===lS?f.A.readAndAgree:f.A.termsFirstLine,(0,i.jsxs)("span",{className:`${Q().nestedSpan}
1`,onClick:()=>{(null==l0?void 0:l0.is_terms_downloadable)?!1===(0,j.a44)(f.A.termsPdf)&&eH("terms"):"marketing"===lS?(0,j.PAx)("node--landing_page_terms_and_condition"):eH("terms")},children:[" ",(0,j.a44)(f.A.termsPdf)&&(null==l0?void 0:l0.is_terms_downloadable)?(0,i.jsx)("a",{href:f.A.termsPdf,target:"_blank",rel:"noopener noreferrer",children:f.A.termsCondition}):f.A.termsCondition]}),(null==l0?void 0:l0.country_code)!=="FR"&&(0,i.jsxs)("span",{...(0,j.$h_)("privacy-policy-n"),className:`${Q().nestedSpan}`,onClick:()=>{eH("privacy"),(0,M.$d)((0,M.ar)(lB),lM,lE,"Privacy and policy","checkout")},children:[" ",f.A.privacyPolicy]}),(null==l0?void 0:l0.country_code)==="FR"&&(0,i.jsx)("span",{children:" & "}),(0,i.jsx)("span",{className:Q().nestedSpan,onClick:(0,j.a44)(f.A.paymentTermsPdf)?void 0:()=>eH("payment"),children:(0,j.a44)(f.A.paymentTermsPdf)?(0,i.jsx)("a",{href:f.A.paymentTermsPdf,target:"_blank",rel:"noopener noreferrer",children:f.A.paymentTerm}):f.A.paymentTerm}),!0===(0,j.a44)(f.A.readAndAgreeText)&&(0,i.jsx)("span",{...(0,j.$h_)("read-agree-n_subtext"),style:{display:"block",paddingTop:"5px",fontSize:"14px",fontWeight:400,lineHeight:"19px"},children:f.A.readAndAgreeText}),(0,i.jsxs)("span",{...(0,j.$h_)("privacy-free-n"),className:`${Q().nestedSpan} ${Q().hidden}`,onClick:()=>eH("privacy"),children:[" ",f.A.privacyPolicy]}),(0,i.jsxs)("span",{...(0,j.$h_)("payment-terms-free-n"),className:`${Q().nestedSpan}${Q().hidden}`,onClick:()=>eH("payment"),style:{visibility:"hidden"},children:[" ",f.A.paymentTerm]})]})}):(0,i.jsxs)("div",{...(0,j.$h_)("read-agree-n"),className:`${Q().labelStyle}`,children:[(null==l0?void 0:l0.country_code)==="FR"?f.A.readAndAgree:f.A.readAndAgreement,(0,i.jsxs)("span",{...(0,j.$h_)("terms-conditions-n"),className:`${Q().nestedSpan}`,onClick:()=>{(null==l0?void 0:l0.is_terms_downloadable)?!1===(0,j.a44)(f.A.termsPdf)&&eH("terms"):"marketing"===lS?(0,j.PAx)("node--landing_page_terms_and_condition"):eH("terms"),(0,M.$d)((0,M.ar)(lB),lM,lE,"Terms and conditions","checkout")},children:[" ",(0,j.a44)(f.A.termsPdf)&&(null==l0?void 0:l0.is_terms_downloadable)?(0,i.jsx)("a",{href:f.A.termsPdf,target:"_blank",rel:"noopener noreferrer",children:f.A.termsCondition}):f.A.termsCondition]}),(null==l0?void 0:l0.country_code)!=="FR"&&(0,i.jsxs)("span",{...(0,j.$h_)("privacy-policy-n"),className:`${Q().nestedSpan}`,onClick:()=>{eH("privacy"),(0,M.$d)((0,M.ar)(lB),lM,lE,"Privacy and policy","checkout")},children:[" ",f.A.privacyPolicy]}),(null==l0?void 0:l0.country_code)==="FR"&&(0,i.jsx)("span",{children:" & "}),(0,i.jsxs)("span",{...(0,j.$h_)("payment-terms-n"),className:`${Q().nestedSpan}`,onClick:!1===(0,j.a44)(f.A.paymentTermsPdf)?()=>eH("payment"):void 0,children:[" ",(0,j.a44)(f.A.paymentTermsPdf)?(0,i.jsx)("a",{href:f.A.paymentTermsPdf,target:"_blank",rel:"noopener noreferrer",children:f.A.paymentTerm}):f.A.paymentTerm]}),!0===(0,j.a44)(f.A.readAndAgreeText)&&(0,i.jsx)("span",{...(0,j.$h_)("read-agree-n_subtext"),style:{display:"block",paddingTop:"5px",fontSize:"14px",fontWeight:400,lineHeight:"19px"},children:f.A.readAndAgreeText})]})]}),eg&&(0,j.a44)(eC)&&!lx&&(0,i.jsx)(a.Ay,{item:!0,...(0,j.$h_)("complaints-updates-n"),className:`${Q().complaintsMsgStyle} `,children:(0,i.jsx)(lc.A,{content:null==eC||null==(z=eC.field_checkout_disclosure_con)||null==(U=z[0])?void 0:U.processed})}),(0,i.jsx)(a.Ay,{item:!0,xs:12,className:Q().buttonWraper,children:(0,i.jsxs)(X.A,{...(0,j.$h_)("confirm-pay-n"),disableElevation:!0,disabled:l9||(eE?!eA||"true"===eA||eY:(null==l0?void 0:l0.country_code)==="FR"?!l3&&!eY:eY),className:`${Q().buttonStyle} ${l9?Q().disabledButton:eE?eA&&"true"!==eA?eY&&Q().disabledButton:Q().disabledButton:(null==l0?void 0:l0.country_code)==="FR"&&!l3&&!eY?Q().disabledButton:eY&&Q().disabledButton}`,variant:"contained",onClick:()=>{eX(),(0,M.$d)((0,M.ar)(lB),lM,lE,f.A.confirmAndPay,lk?"Marketing checkout":"checkout")},children:[lk?f.A.confirmAndPay:f.A.confirmAndPayText,"\xa0\xa0",(0,i.jsx)(lt.A,{amountValue:ly&&!lg?ek.toString()||"0":ly&&lg?(null==l0?void 0:l0.country)==="USA"&&lA||0:ek.toString()||"0"})]})}),(null==l0?void 0:l0.is_hot_sim)&&lF&&!lg&&(0,i.jsx)(a.Ay,{item:!0,xs:12,className:Q().hotSIMWraper,children:(0,i.jsx)("div",{...(0,j.$h_)("hotsim-terms-text-n"),className:`${Q().hotSimTermsStyle} `,children:f.A.termsHotSIM})})]})]})})]}),!!l4&&(0,i.jsx)(la.A,{type:"checkout",id:null==lR||null==(G=lR.tradeDoubler)?void 0:G.checkout,pageInfo:JSON.parse(l4)}),null==Y?void 0:Y.map(l=>{var e,n,o,t,d,a;return(null==l||null==(n=l.field_popup_type)||null==(e=n[0])?void 0:e.search(/privacy-policy/i))==0?(0,i.jsx)(ln.default,{size:"sm",id:"homepageOfferT&CPopup",className:"success_modal",children:(0,i.jsx)(li.A,{data:Y.filter(l=>{var e,n;if((null==l||null==(n=l.field_popup_type)||null==(e=n[0])?void 0:e.search(/privacy-policy/i))==0)return l})[0],onClose:()=>es(!1)}),open:er,onClose:()=>es(!1)}):(null==l||null==(t=l.field_popup_type)||null==(o=t[0])?void 0:o.search(/payment-terms/i))==0?(0,i.jsx)(ln.default,{size:"sm",id:"homepageOfferT&CPopup",className:"success_modal",children:(0,i.jsx)(li.A,{data:l,onClose:()=>ea(!1)}),open:ed,onClose:()=>ea(!1)}):(null==l||null==(a=l.field_popup_type)||null==(d=a[0])?void 0:d.search(/terms-and-conditions/i))==0?(0,i.jsx)(ln.default,{size:"sm",id:"homepageOfferT&CPopup",className:"success_modal",children:(0,i.jsx)(li.A,{data:l,onClose:()=>ei(!1)}),open:en,onClose:()=>ei(!1)}):void 0})]})};var lp=n(24638),ly=n(17840),lf=n(75855),lg=n(70490),lh=n(12579),lb=n.n(lh),lA=n(53612);let lx=l=>{let{esimData:e,setTypeOfSim:n,type:t="",freeSimClicked:u=!1,freeSim:c=!1,disableSimType:v,defaultSimType:_=""}=l,p=(0,d.A)("(max-width:768px)"),[y,b]=(0,o.useState)(!1),A=(0,S.d4)(D.K$);(0,S.d4)(D.HX);let x=(0,S.d4)(D.pY),[I,C]=(0,o.useState)([]),[P,N]=(0,o.useState)(null),[k,$]=(0,o.useState)(!1),M=(0,S.d4)(D.Xk),E=(0,S.wA)(),H=(0,T.useRouter)(),O=[{label:f.A.simCard,esim:""},{label:f.A.eSIM,esim:f.A.checkDeviceCompatibility}];(0,o.useEffect)(()=>{""!==_&&"eSIM"==_?(N(1),b(!0)):(u||c||(null==A?void 0:A.selectedSIM)===1)&&N(0)},[u,c]);let[L,B]=(0,o.useState)(null);(0,o.useEffect)(()=>{(null==M?void 0:M.esim)&&!u&&"eSIM"!=v?(null==M?void 0:M.esim)&&"physical"==v?(C(O),B(0),R(1)):C(O):C(O.filter(l=>(null==l?void 0:l.label)!=="eSIM"))},[null==M?void 0:M.esim,u]);let U=(0,F.wb)(w.H.freeSimDetails,!0),z=U&&JSON.parse(U);(0,o.useEffect)(()=>{var l;(null==O||null==(l=O[0])?void 0:l.label)&&null!==P&&n(O[P].label),E((0,D.qx)({...z,selectedSIM:P??0,typeOfSim:O[P??0].label}))},[P,f.A.simCard,f.A.eSIM,f.A.checkDeviceCompatibility]);let G={FR:f.A.simActivatedTextFrance,DE:f.A.simActivatedTextGermany,CH:f.A.simActivatedTextSwiss,AT:f.A.simActivatedTextAustria,IT:f.A.simActivatedTextItaly,NL:f.A.simActivatedTextNetherland}[null==M?void 0:M.country_code],R=l=>{O[l].label!==(null==z?void 0:z.typeOfSim)&&(N(e=>l),n(O[l].label),b(1===l),E((0,D.X0)({first_name:""}
1)),(0,F.UI)(w.H.taxDetails,!0),E((0,D.qx)({...z,selectedSIM:l,typeOfSim:O[l].label})))};return(0,o.useEffect)(()=>{if(null==H?void 0:H.query){let{retry:l=""}=null==H?void 0:H.query;if("true"===l){let l=(0,F.wb)(w.H.freeSimDetails,!0);if((null==M?void 0:M.esim)&&"physical"==v)N(1),n(O[1].label),b(!0);else{let{selectedSIM:e,typeOfSim:i=""}=l&&JSON.parse(l)||{};N(e),n(i)}}}},[null==H?void 0:H.query]),(0,i.jsxs)(a.Ay,{id:"deliveryBy",container:!0,direction:"column",alignItems:"center",display:"block",children:[(0,i.jsx)(a.Ay,{item:!0,children:(0,i.jsxs)(h.A,{className:"marketing"===t?lb().mobFormContainer:lb().formContainer,children:[(0,i.jsx)(s.A,{variant:"h5",gutterBottom:!0,className:"marketing"===t?lb().textHeadMarketing:lb().textHead,children:(null==M?void 0:M.esim)&&!u&&!v?f.A.chooseSimType:f.A.yourSimType}),(0,i.jsx)(a.Ay,{container:!0,spacing:2,children:(0,i.jsx)(a.Ay,{item:!0,xs:12,alignItems:"center",display:p?void 0:"flex",flexDirection:p?void 0:"row",children:(null==M?void 0:M.esim)&&!u&&!v?(0,i.jsx)(a.Ay,{item:!0,xs:12,sx:{marginBottom:p?"10px":void 0},children:null==O?void 0:O.map((l,e)=>(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(a.Ay,{container:!0,display:"flex",justifyContent:"space-between",alignItems:"center",onClick:()=>R(e),className:`${lb().optionsBox} ${null==l?void 0:l.label}`,...(0,j.$h_)((null==l?void 0:l.label)=="eSIM"?"check-out-swap-cta-n-1":"check-out-compatibility-cta-n-1"),sx:{backgroundColor:P===e?"#E8F4FE":"#FAFBFF",cursor:"pointer",padding:"13px 8px 0px 8px",border:P===e?"2px solid #1996F3":"1px solid #D9D9D9",height:"50px",borderBottom:P===e&&y&&(null==M?void 0:M.esim)?"none":void 0},children:[(0,i.jsx)(a.Ay,{item:!0,sx:{flexGrow:1,height:"50px"},children:p?(0,i.jsxs)(a.Ay,{item:!0,sx:{marginTop:"px"},gap:2,display:"flex",alignItems:"center",children:["eSIM"===l.label?(0,i.jsx)(m(),{src:g.z.esim,alt:"esim"}):(0,i.jsx)(m(),{src:g.z.physicalSimOrder,alt:"esim"}),(0,i.jsx)(s.A,{className:lb().label1,children:l.label})]}):(0,i.jsxs)(a.Ay,{container:!0,display:"flex",alignItems:"center",gap:1,children:["eSIM"===l.label?(0,i.jsx)(m(),{src:g.z.esim,alt:"esim"}):(0,i.jsx)(m(),{src:g.z.physicalSimOrder,alt:"esim"}),(0,i.jsx)(s.A,{className:lb().label1,children:l.label})]})}),(0,i.jsxs)(a.Ay,{item:!0,gap:2,display:"flex",alignItems:"center",justifyContent:"space-between",sx:{marginBottom:"25px"},children:[!p&&l.label===f.A.eSIM&&(0,i.jsx)(r.A,{disableRipple:!0,onClick:()=>$(!0),children:(0,i.jsx)(s.A,{className:lb().priceFree,children:l.esim})}),(0,i.jsx)(a.Ay,{sx:{display:"flex",alignItems:"center",justifyContent:"center"},children:P===e?(0,i.jsx)(m(),{src:g.z.checkCircleBlue,width:20,height:20,alt:"checkCircle"}):(0,i.jsx)("input",{type:"radio",id:`option_${e}`,name:"typeofsim",value:l.esim,className:lb().radioButton,checked:!1,onChange:()=>{},style:{margin:0,marginLeft:"0px"}})})]})]},e),l.label!==f.A.eSIM&&!y&&(0,i.jsxs)(a.Ay,{item:!0,gap:1,display:"flex",justifyContent:"center",alignItems:"center",className:lb().infoContainer,children:[(0,i.jsx)(lA.A,{fill:"#667085",className:lb().infoIcon}),(0,i.jsx)(s.A,{className:lb().infoText,children:f.A.whatsphyicalsim})]}),P===e&&y&&(null==M?void 0:M.esim)&&(0,i.jsxs)(a.Ay,{item:!0,gap:1,display:"flex",justifyContent:"center",alignItems:"center",className:lb().infoContainer,children:[(0,i.jsx)(lA.A,{fill:"#667085",className:lb().infoIcon}),G&&(0,i.jsx)(s.A,{className:lb().infoText,children:G}),(null==M?void 0:M.country_code)!=="FR"&&(null==M?void 0:M.country_code)!=="DE"&&(null==M?void 0:M.country_code)!=="AT"&&(null==M?void 0:M.country_code)!=="CH"&&(null==M?void 0:M.country_code)!=="IT"&&(null==M?void 0:M.country_code)!=="NL"&&(0,i.jsx)(s.A,{className:lb().infoText,children:`${f.A.yourLycaMobileSIMMustBeActivatedInThe} ${(null==M?void 0:M.country)==="UK"?"United Kingdom":null==M?void 0:M.country}${f.A.onceYourSIMIsActivatedIn} ${(null==M?void 0:M.country)==="UK"?"United Kingdom":null==M?void 0:M.country}${f.A.youCanUseItInternationally}`})]})]}))}):(0,i.jsx)(a.Ay,{item:!0,xs:12,sx:{marginBottom:p?"10px":void 0},children:I.map((l,e)=>{if(!v||L!=e)return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(a.Ay,{container:!0,display:"flex",justifyContent:"space-between",alignItems:"center",onClick:()=>R(e),sx:{backgroundColor:P===e?"#E8F4FE":"#FAFBFF",cursor:"pointer",padding:"13px 8px 0px 8px",border:P===e?"2px solid #1996F3":"1px solid #D9D9D9",height:"50px",borderBottom:P===e&&y&&(null==M?void 0:M.esim)?"none":void 0},children:[(0,i.jsx)(a.Ay,{item:!0,sx:{flexGrow:1,height:"50px"},children:p?(0,i.jsxs)(a.Ay,{item:!0,sx:{marginTop:"px"},gap:2,display:"flex",alignItems:"center",children:["eSIM"===l.label?(0,i.jsx)(m(),{src:g.z.esim,alt:"esim"}):(0,i.jsx)(m(),{src:g.z.physicalSimOrder,alt:"esim"}),(0,i.jsx)(s.A,{className:lb().label1,children:l.label})]}):(0,i.jsxs)(a.Ay,{container:!0,display:"flex",alignItems:"center",gap:1,children:["eSIM"===l.label?(0,i.jsx)(m(),{src:g.z.esim,alt:"esim"}):(0,i.jsx)(m(),{src:g.z.physicalSimOrder,alt:"esim"}),(0,i.jsx)(s.A,{className:lb().label1,children:l.label})]})}),(0,i.jsxs)(a.Ay,{item:!0,gap:2,display:"flex",alignItems:"center",justifyContent:"space-between",sx:{marginBottom:"25px"},children:[!p&&l.label===f.A.eSIM&&(0,i.jsx)(r.A,{disableRipple:!0,onClick:()=>$(!0),children:(0,i.jsx)(s.A,{className:lb().priceFree,children:l.esim})}),(0,i.jsx)(a.Ay,{sx:{display:"flex",alignItems:"center",justifyContent:"center"},children:P===e?(0,i.jsx)(m(),{src:g.z.checkCircleBlue,width:20,height:20,alt:"checkCircle"}):(0,i.jsx)("input",{type:"radio",id:`option_${e}`,name:"typeofsim",value:l.esim,className:lb().radioButton,checked:!1,onChange:()=>{},style:{margin:0,marginLeft:"0px"}})})]})]},e),l.label!==f.A.eSIM&&!y&&(0,i.jsxs)(a.Ay,{item:!0,gap:1,display:"flex",justifyContent:"center",alignItems:"center",className:lb().infoContainer,children:[(0,i.jsx)(lA.A,{fill:"#667085",className:lb().infoIcon}),(0,i.jsx)(s.A,{className:lb().infoText,children:f.A.whatsphyicalsim})]}),P===e&&y&&(null==M?void 0:M.esim)&&(0,i.jsxs)(a.Ay,{item:!0,gap:1,display:"flex",justifyContent:"center",alignItems:"center",className:lb().infoContainer,children:[(0,i.jsx)(lA.A,{fill:"#667085",style:{marginLeft:4}}),G&&(0,i.jsx)(s.A,{className:lb().infoText,children:G}),(null==M?void 0:M.country_code)!=="FR"&&(null==M?void 0:M.country_code)!=="DE"&&(null==M?void 0:M.country_code)!=="AT"&&(null==M?void 0:M.country_code)!=="CH"&&(null==M?void 0:M.country_code)!=="IT"&&(0,i.jsx)(s.A,{className:lb().infoText,children:`${f.A.yourLycaMobileSIMMustBeActivatedInThe} ${(null==M?void 0:M.country)==="UK"?"United Kingdom":null==M?void 0:M.country}${f.A.onceYourSIMIsActivatedIn} ${(null==M?void 0:M.country)==="UK"?"United Kingdom":null==M?void 0:M.country}${f.A.youCanUseItInternationally}`})]})]})})})})})]})}),(0,i.jsx)(ln.default,{size:"md",className:"simDetails",id:f.A.viewDetails,children:(0,i.jsx)(lg.A,{onClose:()=>$(!1),activeTab:0,compatibilityData:(null==x?void 0:x.type)?x:e}),open:k,onClose:()=>$(!1)})]})};var lS=n(18028),lI=n(34358),lC=n(91040),lD=n(64030),lj=n(62541),lT=n(22353),lF=n(54811),lw=n.n(lF);let lP=l=>{let{handleActivationCode:e,cmsData:n}=l;(0,S.d4)(D.Xk);let[t,d]=(0,o.useState)(!1),[r,c]=(0,o.useState)(!1),[v,_]=(0,o.useState)(""),[m,p]=(0,o.useState)({ActivationCode:""}),[y,g]=(0,o.useState)({ActivationCodeError:!1}),h=async()=>{var l,i,o,t,a,r;c(!1),_(""),d(!0);try{let o=(null==n||null==(l=n.field_campaign_id)?void 0:l[0])!==null&&(null==n||null==(i=n.field_campaign_id)?void 0:i[0])||"",t={coupon_code:(null==m?void 0:m.ActivationCode)??"",campaign_id:o},{status:d,data:a}=await H.A.post(O.t.validateCouponCode,t);if(200===d&&(null==a?void 0:a.coupon_id)){let l={coupon_code:null==m?void 0:m.ActivationCode,coupon_id:null==a?void 0:a.coupon_id};e(l)}}catch(l){d(!1),(null==l||null==(t=l.response)||null==(o=t.data)?void 0:o.cause)==="1"?_(f.A.activationCodeErrorMsg):(null==l||null==(r=l.response)||null==(a=r.data)?void 0:a.cause)==="2"&&_(f.A.activationCodeInactiveErrorMsg),c(!0)}};return(0,i.jsxs)(i.Fragment,{children:[t&&(0,i.jsx)(lo.A,{}),(0,i.jsx)(a.Ay,{container:!0,direction:"column",alignItems:"center",display:"block",children:(0,i.jsxs)(a.Ay,{item:!0,className:lw().ActivationCodeMain,children:[(0,i.jsx)(s.A,{className:lw().subHead,children:f.A.EnterYourActivationCode}),(0,i.jsx)(u.A,{marginBottom:"10px",children:(0,i.jsx)(E.A,{field:"ActivationCode",hideCountryCode:!0,placeholder:f.A.EnterActivationCode,ariaLabel:f.A.EnterActivationCode,inputValue:m.ActivationCode,validators:[{check:J.k0.required,message:f.A.activationCodeError}],maxLength:15,textChange:(l,e,n)=>{c(!1);let i=n?n.error:n;"ActivationCode"===e&&g(l=>({...l,[`${e}Error`]:i})),p(n=>({...n,[e]:l}))},showError:y.ActivationCodeError,phoneNumberLocalError:f.A.activationCodeError,pageId:"renew-bundle",isErrorInRed:!0,...(0,j.$h_)("ActivationCode")})}),(0,i.jsx)(u.A,{className:lw().submit_btn_conatainer,...(0,j.$h_)("submit_btn_container"),children:(0,i.jsx)(X.A,{className:lw().submit_btn,...(0,j.$h_)("submit_btn"),disabled:(()=>{let{ActivationCode:l}=m,{ActivationCodeError:e}=y;return!l||e||l.length<6})(),onClick:h,children:f.A.confirmContinue})}),r&&(0,i.jsx)(u.A,{children:(0,i.jsx)(lT.A,{className:lw().alert,severity:"error",children:v||f.A.activationCodeErrorMsg})})]})})]})},lN=(0,lf.Ay)(c.A)(l=>{let{theme:e}=l;return{height:4,borderRadius:0,[`& .${v.A.bar}`]:{borderRadius:0}}}),lk=l=>{var e,n,c,v,_,p,h,b,A,x,I,C,P,N,M,E,L,B,z,G,X,Y,Q,ll;let{data:le,type:ln}=l,li=null;li=window;let lt=(0,R.A)(768),ld=(0,S.d4)(D.K$),la=(0,S.d4)(D.HX);
1null==(e=document.querySelector("#footer-section"))||e.clientHeight;let lr=(0,d.A)("(max-width:768px)"),lu=(null==li||null==(n=li.location)?void 0:n.host)&&(0,k.A)(null==li||null==(c=li.location)?void 0:c.host),lv=(0,S.d4)(D.Xk),l_=(0,S.d4)(D.Bn),lf=(0,S.d4)(D.Rl),lg=(0,S.d4)(ls.kV),lh=(0,S.wA)(),[lb,lA]=o.useState(!1),lT=(0,T.useRouter)(),lF=(0,S.d4)(D.tL),lw=(0,S.d4)(ls.gD),[lk,l$]=(0,o.useState)(null),[lM,lE]=(0,o.useState)(0),[lH,lO]=(0,o.useState)(!1),[lL,lB]=(0,o.useState)(0),[lU,lz]=(0,o.useState)([]),[lG,lR]=(0,o.useState)(""),[lV,lW]=(0,o.useState)(null),[lJ,lK]=(0,o.useState)([]),[lq,lZ]=(0,o.useState)([]),[lX,lY]=(0,o.useState)(),[lQ,l0]=(0,o.useState)(),[l1,l2]=(0,o.useState)(),[l4,l5]=(0,o.useState)(f.A.standardPhysicalSIM),[l3,l8]=(0,o.useState)(""),[l9,l7]=(0,o.useState)(!1),l6=(0,S.d4)(ly.qr),el=(0,S.d4)(D.Qr),[ee,en]=(0,o.useState)(!1),ei=(0,S.d4)(D.O),eo=(0,S.d4)(D.xy),et=(0,S.d4)(D.wp),ed=JSON.parse((0,F.wb)("ctaBtn",!0)),ea=(null==lv?void 0:lv.country)==="USA",er=(0,F.wb)(w.H.taxDetails,!0),[es,eu]=(0,o.useState)(!1),[ec,ev]=(0,o.useState)({}),[e_,em]=(0,o.useState)(!1),[ep,ey]=(0,o.useState)(!1),[ef,eg]=(0,o.useState)(!1),eh="marketing"===ln,eb=(0,S.d4)(D.b0),[eA,ex]=(0,o.useState)(!1),[eS,eI]=(0,o.useState)(!1),[eC,eD]=(0,o.useState)({post_code:""}),[ej,eT]=(0,o.useState)({post_code:""}),[eF,ew]=(0,o.useState)(null==le?void 0:le.hotSim),[eP,eN]=(0,o.useState)({promo_code_name:"",discount_value:"",discount_type:""}),ek=(null==le||null==(_=le.cmsCAData)||null==(v=_.field_choose_sim_type)?void 0:v[0])??"",e$={currentStep:2,formStep:"Delivery and payment",fieldName:"Email & SMS toggle"},eM=(0,S.d4)(ls.CU),eE=(null==eM?void 0:eM.family_plan)&&(null==eM||null==(p=eM.cart_line_item_details)?void 0:p.length)>0,eH={marginTop:"4px",width:lr?"100%":"inherit",padding:lr&&"marketing"!==ln&&!eP?"0 20px":"inherit"},[eO,eL]=(0,o.useState)(!1),[eB,eU]=(0,o.useState)({personal_id:""}),[ez,eG]=(0,o.useState)({personal_id:""}),[eR,eV]=(0,o.useState)(!1),[eW,eJ]=(0,o.useState)(),eK=er&&JSON.parse(er),eq=!ef&&"marketing"!==ln&&!(null==le?void 0:le.freeSim),eZ=(null==le?void 0:le.freeSimClicked)?[]:null==le?void 0:le.productDataFreeSim,eX=null==le?void 0:le.freeSimClicked,eY=null==le?void 0:le.freeSim,eQ=(null==lv||null==(h=lv.simple_checkout)?void 0:h.prepaid_web)||!1,e0=((null==ei?void 0:ei.paymentType)==="1000"||(null==lF?void 0:lF.paymentType)=="1000")&&eQ;(0,o.useEffect)(()=>{(null==le?void 0:le.freesim)&&(sessionStorage.clear(),localStorage.clear())},[]),(0,o.useEffect)(()=>{(async()=>{try{let l=await (0,Z.j9)("SIM");lY(l.data.apm_list)}catch(l){lC.A.isCancel(l)&&lL<1&&lB(l=>l+1)}})()},[lL]),(0,o.useEffect)(()=>{nd(),(null==le?void 0:le.freeSim)||no(),e2()},[]),(0,o.useEffect)(()=>{if((null==lT?void 0:lT.pathname)!=="/freesim"&&(null==lk?void 0:lk.cart_line_item_details)){var l;let e=null==lk||null==(l=lk.cart_line_item_details)?void 0:l.some(l=>null==l?void 0:l.physical_sim);l7(e),e||l5("eSim")}},[lk]),(0,o.useEffect)(()=>{ld&&l7((null==ld?void 0:ld.selectedSIM)===0)},[ld]);let e1=(null==l4?void 0:l4.toLowerCase())!=="esim"&&((null==le?void 0:le.freeSim)?l9:l4===f.A.standardPhysicalSIM||l9);(0,o.useEffect)(()=>{var l,e;(null==lk||null==(l=lk.cart_line_item_details)?void 0:l.length)&&lE(null==lk||null==(e=lk.cart_line_item_details)?void 0:e.length)},[lk]);let e2=async()=>{try{let{status:l,data:e}=await H.A.get(O.t.deliveryTerms);200===l&&lz(e.cms_data)}catch(l){}};(0,o.useEffect)(()=>{(0,j.HRA)(lt)},[lt]);let e4=l=>{lh((0,D.b9)({...lF,paymentType:l}))};(0,o.useEffect)(()=>{var l,e,n;let i=(null==la||null==(e=la.delivery_info)||null==(l=e.deliveryInfoAddressFinderData)?void 0:l.post_code)||(null==la||null==(n=la.delivery_info)?void 0:n.post_code);(null==lv?void 0:lv.country)==="USA"&&i&&(null==le?void 0:le.freeSimClicked)&&(null==le?void 0:le.freeSim)&&(null==i?void 0:i.length)>=5&&(lh((0,D.o4)(null)),e9())},[null==la||null==(A=la.delivery_info)||null==(b=A.deliveryInfoAddressFinderData)?void 0:b.post_code,null==la||null==(x=la.delivery_info)?void 0:x.post_code]),(0,o.useEffect)(()=>{sessionStorage.setItem("ctaBtn",JSON.stringify(ee))},[ee]);let e5=async()=>
1{if(!ej.post_code){lA(!0);try{var l,e;let n={zip_code:eC.post_code},{status:i,data:o}=await H.A.post(O.t.areaNetwork,n);200==i&&(null==o||null==(l=o.sim_availability)?void 0:l.availability)&&(null==o||null==(e=o.sim_availability)?void 0:e.postcode)===eC.post_code?(ex(l=>!l),eI(!1),en(!0),lA(!1),e3(eC.post_code),lh((0,D.lu)(!1)),(0,F.gC)(w.H.verifyedUSAPostcode,eC.post_code,!0)):(lA(!1),en(!1),eI(!0))}catch(l){console.log(l),lA(!1),en(!1),eI(!0)}}},e3=async l=>{var e,n,i,o,t,d,a,r,s,u,c;if(!l)return;let v=(null==eZ||null==(i=eZ[0])||null==(n=i.bundleGroupDetails)||null==(e=n[0])?void 0:e.promotionalPricing)?null==eZ||null==(a=eZ[0])||null==(d=a.bundleGroupDetails)||null==(t=d[0])||null==(o=t.promotionalPricing)?void 0:o.toString():null==eZ||null==(c=eZ[0])||null==(u=c.bundleGroupDetails)||null==(s=u[0])||null==(r=s.basePrice)?void 0:r.toString();try{let e={brand_name:"Lycamobile",channel_name:"Myaccounts",country_code:"USA",delivery_zip_code:l||"10001",feature_name:"ONLINE_TOPUP",msisdn_zip_code:"",password:"lyca",payment_zip_code:l,state_code:"",tax_id:Math.random().toString(36).slice(2),user_id:"lyca",subscriber_id:"lycadummy345",amount:v},{status:n,data:i}=await H.A.post(O.t.calculateUsaTax,e);200===n&&(lh((0,D.o4)(i)),(0,F.gC)(w.H.taxDetails,JSON.stringify(i),!0))}catch{}},e8=ea&&(null==la?void 0:la.personalDetailsButton);(0,o.useEffect)(()=>{ex(!1)},[null==la?void 0:la.first_name,null==la?void 0:la.last_name,null==la?void 0:la.email]);let e9=async()=>{var l,e,n;let i=(null==la||null==(e=la.delivery_info)||null==(l=e.deliveryInfoAddressFinderData)?void 0:l.post_code)||(null==la||null==(n=la.delivery_info)?void 0:n.post_code);try{let{status:l,data:e}=await H.A.post(O.t.shippingCharges,{free_sim:"True",free_sim_bundle:"",free_sim_topup:"",free_sim_bundle_topup:"",zip_code:i,device_purchase:"",bundle_code:"",no_of_months:""});200==l&&lW(null==e?void 0:e.shipping_charge)}catch(l){}},[e7,e6]=(0,o.useState)(!1),[nl,ne]=(0,o.useState)(null);(0,o.useEffect)(()=>{var l,e;(null==le||null==(e=le.cmsCAData)||null==(l=e.field_apply_coupon_code)?void 0:l[0])===!0&&e6(!0)},[null==le||null==(C=le.cmsCAData)||null==(I=C.field_apply_coupon_code)?void 0:I[0]]);let nn=(0,o.useMemo)(()=>{let l=(0,j.hXT)(lJ,eZ,eX,eY,lq);return(null==lv?void 0:lv.global_captcha)&&l},[null==lv?void 0:lv.global_captcha,lJ,eZ]),ni=()=>{var l;let e={emailAddress:la.email,phoneNumber:la.contact_number,basketState:lg,allTopUpPlans:lq,baseWindow:li,total:lM,currency_code:(null==lu||null==(l=lu.tradeDoubler)?void 0:l.currencyCode)||"na",configData:lv,formName:"newsim",formStep:"Step 2 - Delivery and payment",event:"formProgress"};(0,j.qP)(e)},no=async()=>{let l=await (0,Z.Vx)(lw);(null==l?void 0:l.cart_id)?lh((0,ls.Td)(l)):lh((0,ls.Td)({})),await nu(l),l$(l),(null==l?void 0:l.status)===410&&(lh((0,ls.Td)([])),lh((0,ls.Cc)([])),lh((0,ls._2)("")))},nt=(0,o.useCallback)(async()=>{try{var l,e,n,i,o,t,d,a,r;let s=null==lf||null==(e=lf.data)||null==(l=e.getDestinationsListing)?void 0:l.edges;if(s){let l=null==(n=s.filter(l=>{var e;return(null==(e=l.node)?void 0:e.countryCode)===((null==l_?void 0:l_.country_code)==="SW"?"CH":null==l_?void 0:l_.country_code)}))?void 0:n.map(l=>l.node.destinationName).filter(l=>!!l);l8((null==l?void 0:l[0])||(null==l_?void 0:l_.country_name));let e=[],u=[];lf&&(null==lf||null==(t=lf.data)||null==(o=t.getDestinationsListing)||null==(i=o.edges)||i.forEach(l=>{l.node.country&&e.push({label:l.node.country,value:l.node.key})})),lf&&(null==lf||null==(r=lf.data)||null==(a=r.getDestinationsListing)||null==(d=a.edges)||d.forEach(l=>{var e,n,i,o;(null==l||null==(n=l.node)||null==(e=n.callingCountry)?void 0:e.isdCode)&&u.push({label:null==(i=l.node.callingCountry)?void 0:i.isdCode,value:null==(o=l.node.callingCountry)?void 0:o.isdCode})})),l0(e),l2(u)}else l8("")}catch(l){console.error("Error fetching countries:",l)}},[lf]);(0,o.useEffect)(()=>{nt()},[nt]);let nd=async()=>{try{let{status:l,data:e}=await H.A.get(O.t.getAllPlan("topup")),n=null==e?void 0:e.filter(l=>{var e,n;return(null==l||null==(n=l.customerType)||null==(e=n[0])?void 0:e.customerTypeCode)==="ca"});200==l&&lZ(n)}catch(l){}},na=(0,o.useCallback)(l=>(0,j.SCz)(l,lq,null==lv?void 0:lv.buddy_plan_enabled_web),[lJ]),nr=(0,o.useMemo)(()=>l=>{let{classname:e,children:n}=l;return(0,i.jsx)(a.Ay,{container:!0,mt:2,item:!0,className:`${e}`,children:(0,i.jsx)(a.Ay,{className:`${y().header}`,item:!0,sm:12,display:"flex",flexDirection:"row",justifyContent:"center",children:n})})},[]),ns=(0,o.useCallback)(l=>(0,j.XeV)(l),[null==le?void 0:le.productDataFreeSim]),nu=async l=>{var e;l&&(null==l||null==(e=l.cart_line_item_details)?void 0:e.length)>0?(await (0,Z.rD)(l,lq,lK),lh((0,D.pW)(lJ))):lK([])},nc=async()=>
1{if(lA(!0),!ez.personal_id)try{var l,e,n,i,o,t,d,a,r,s,u,c,v,_,m,p,y,f;let g={msisdn:eB.personal_id},{status:h,data:b}=await H.A.post(O.t.ssn,g);200===h&&!b.hasOwnProperty("error")&&(null==b?void 0:b.success)&&(null==b||null==(e=b.success)||null==(l=e.socialSecurityNumber)?void 0:l.toString())===(null==eB||null==(n=eB.personal_id)?void 0:n.toString())?(lA(!1),eV(!1),en(!0),eu(!0),b&&(ev({first_name:null==b||null==(i=b.success)?void 0:i.firstName,last_name:null==b||null==(o=b.success)?void 0:o.lastName,co:null==b||null==(t=b.success)?void 0:t.co}),lh((0,D.X0)({...la,billingInfo:{first_name:null==b||null==(d=b.success)?void 0:d.firstName,last_name:null==b||null==(a=b.success)?void 0:a.lastName,city:null==b||null==(r=b.success)?void 0:r.city,street_name:null==b||null==(s=b.success)?void 0:s.street,post_code:null==b||null==(u=b.success)?void 0:u.zipCode,co:null==b||null==(c=b.success)?void 0:c.co,billingMannualAddress:!0,addressFinder:!1},delivery_info:{first_name:null==b||null==(v=b.success)?void 0:v.firstName,last_name:null==b||null==(_=b.success)?void 0:_.lastName,city:null==b||null==(m=b.success)?void 0:m.city,street_name:null==b||null==(p=b.success)?void 0:p.street,post_code:null==b||null==(y=b.success)?void 0:y.zipCode,co:null==b||null==(f=b.success)?void 0:f.co,billingMannualAddress:!0,addressFinder:!1}}))),eL(!eO)):(lA(!1),en(!1),eV(!0),eJ(b.error))}catch(l){lA(!1),en(!1),eV(!0),eJ(l.response.data.name)}},nv=(l,e)=>null==l?void 0:l.some(l=>{var n;return null==l||null==(n=l.cartItem)?void 0:n[e]}),n_=l=>{if(null==le?void 0:le.productDataFreeSim)return(null==lv?void 0:lv.country)==="USA"&&(null==le?void 0:le.freeSimClicked)?"4":(null==le?void 0:le.freeSim)&&!(null==le?void 0:le.freeSimClicked)?"1,3":(null==le?void 0:le.freeSim)&&(null==le?void 0:le.freeSimClicked)?"":"1";{let e=nv(l,"bundle_selected"),n=nv(l,"card_id");return n&&e?"1,2,3":e?"1,3":n?"2,3":""}},nm=(l,e)=>[null,void 0].includes(null==l?void 0:l.freeSim)?na(e)??0:eh||(null==l?void 0:l.freeSim)&&!(null==l?void 0:l.freeSimClicked)?ns(null==l?void 0:l.productDataFreeSim)??0:(null==l?void 0:l.freeSim)&&(null==l?void 0:l.freeSimClicked)&&(null==lv?void 0:lv.country)==="USA"?lV??0:0,np=(null==l4?void 0:l4.toLocaleLowerCase())!=="esim",ny=(0,o.useMemo)(()=>{var l,e,n,i,o,t,d,a,r,s,u,c,v,_;let m=eh?!eX:!0===eX;if(!e0||null==la||!la.email||!et)return ea&&!np&&eo&&m||(!!eY||!!eX)&&((null===l4||""===l4)&&((null==ld?void 0:ld.selectedSIM)===0||(null==ld?void 0:ld.selectedSIM)===void 0)||(null==l4?void 0:l4.toLowerCase())!=="esim"&&!(null==la||null==(l=la.billingInfo)?void 0:l.addressFinderValue)&&!(null==la||null==(e=la.delivery_info)?void 0:e.addressFinderValue)&&!(null==la||null==(n=la.delivery_info)?void 0:n.isvalid))||null===lF&&(null==la?void 0:la.selectedCardOption)==="1000"||((null==lF?void 0:lF.validForm)?!(null==lF?void 0:lF.validForm):(null==lF?void 0:lF.paymentType)==="1000")||!(null==la||null==(i=la.billingInfo)?void 0:i.isvalid)&&(null==la||null==(o=la.billingInfo)?void 0:o.addressFinderValue)===null&&((null==lF?void 0:lF.paymentType)!=="1"||(null==lF?void 0:lF.paymentType)!=="157"||(null==lF?void 0:lF.paymentType)!=="49"||(null==lF?void 0:lF.paymentType)!=="13"||(null==lF?void 0:lF.paymentType)!=="53")||!(null==la||null==(t=la.delivery_info)?void 0:t.isvali
1d)&&(null==la||null==(d=la.delivery_info)||d.addressFinderValue,!1)||!(eY||eX)&&(null==(r=lJ[0])||null==(a=r.cartItem)?void 0:a.physical_sim)&&((null==la?void 0:la.delivery_info)===void 0||(null==la||null==(s=la.delivery_info)?void 0:s.addressFinder)&&!(null==la||null==(u=la.delivery_info)?void 0:u.addressFinderValue))||!(null==la?void 0:la.first_name)||!(null==la?void 0:la.last_name)||!(null==la||null==(c=la.email)?void 0:c.trim())||((null==l4?void 0:l4.toLowerCase())==="esim"&&(null==lv?void 0:lv.esim_verification)?!(null==la?void 0:la.emailVerified):(null==l4?void 0:l4.toLowerCase())!=="esim"&&null!=lv&&!!lv.physical_sim_verification&&!(null==la?void 0:la.emailVerified))||!et||((null==(_=lJ[0])||null==(v=_.cartItem)?void 0:v.physical_sim)||(eY||eX)&&"eSIM"!==l4?!(la.delivery_info_isvalid&&la.billingInfo_isvalid&&lH)&&(null==la?void 0:la.selectedCardOption)==="1000"||!la.delivery_info_isvalid&&lH&&((null==la?void 0:la.selectedCardOption)==="1"||(null==la?void 0:la.selectedCardOption)==="157"):!(null==la?void 0:la.billingInfo_isvalid)&&(null==la?void 0:la.selectedCardOption)==="1000")},[lF,l4,la,null==la?void 0:la.emailVerified,null==la?void 0:la.email,null==la||null==(P=la.billingInfo)?void 0:P.isvalid,(null==la||null==(N=la.delivery_info)?void 0:N.isvalid)&&l9,null==lv?void 0:lv.esim_verification,null==lv?void 0:lv.physical_sim_verification,et,null==la?void 0:la.delivery_info_isvalid,null==la?void 0:la.billingInfo_isvalid,eo]),nf=(0,o.useMemo)(()=>({pageType:"Delivery & Payment",journeyName:null===w.H||void 0===w.H?void 0:w.H.deliveryJourneyName,siteSection:"payG",postTitle:"Checkout",siteSubsection:"checkout"}),[]);return(0,i.jsxs)(i.Fragment,{children:[!eh&&(0,i.jsx)(lS.A,{pageInfo:nf}),(null==le?void 0:le.progressBar)?"":(0,i.jsxs)(a.Ay,{container:!0,id:"linearProgress",className:y().headerContainer,children:[(0,i.jsx)(a.Ay,{container:!0,item:!0,justifyContent:"center",alignItems:"center",sx:{marginBottom:"14.7px"},children:(0,i.jsx)(m(),{...(0,j.$h_)("checkout-header-lyca-brand-logo-re"),src:g.z.lycaLogo,width:80,height:31,alt:"logo"})}),(0,i.jsxs)(a.Ay,{container:!0,item:!0,children:[(0,i.jsxs)(a.Ay,{container:!0,item:!0,justifyContent:"space-around",children:[(0,i.jsx)(a.Ay,{item:!0,className:y().progressLabel,...(0,j.$h_)("checkout-progress-heading-basket-text-re"),children:f.A.basket}),(0,i.jsx)(a.Ay,{item:!0,className:y().progressLabel,sx:{marginLeft:"40px"},...(0,j.$h_)("checkout-progress-heading-payment-text-re"),children:f.A.deliveryPayment}),(0,i.jsx)(a.Ay,{...(0,j.$h_)("checkout-progress-heading-confirmation-text-re"),item:!0,className:y().progressLabel,children:f.A.confirmation})]}),(0,i.jsxs)(a.Ay,{item:!0,display:"flex",justifyContent:"space-between",sx:{width:"100%",marginTop:"7px"},children:[(0,i.jsx)(lN,{sx:{backgroundColor:"white",width:"100%","& .MuiLinearProgress-bar":{backgroundColor:"#08DC7D"}},variant:"determinate",value:100}),(0,i.jsx)(lN,{sx:{backgroundColor:"white",width:lr?"140%":"50%","& .MuiLinearProgress-bar":{backgroundColor:"#006AE0"}},variant:"determinate",value:100}),(0,i.jsx)(lN,{sx:{backgroundColor:"white",width:"100%","& .MuiLinearProgress-bar":{backgroundColor:"#BEC6D5"}},variant:"determinate",value:100})]})]})]}),(0,i.jsxs)(a.Ay,{className:`${y().mainContainer}${(null==le?void 0:le.progressBar)?y().freeSim:""} ${eq?y().lycaSelection:""}`,sx:{borderRadius:(null==le?void 0:le.progressBar)?"8px":""},children:[(null==le?void 0:le.topHead)?"":(0,i.jsxs)(a.Ay,{container:!0,className:y().main,display:"flex",justifyContent:"center",alignItems:"center",children:[(0,i.jsx)(r.A,{...(0,j.$h_)("back-to-button-re"),onClick:()=>lT.push("/checkout"),children:(0,i.jsx)(m(),{...(0,j.$h_)("back-arrow-button-re"),src:g.z.arrowLeftCircle,width:lr?30:40,height:lr?30:40,alt:"left-arrow"})}),(0,i.jsx)("p",{className:y().deliveryPaymentTitle,...(0,j.$h_)("delivery-header-re"),children:f.A.deliveryPayment})]}),(null==le||null==(L=le.cmsCAData)||null==(E=L.field_form_heading)||null==(M=E[0])?void 0:M.processed)&&(0,i.jsx)(a.Ay,{item:!0,children:(0,i.jsx)(s.A,{...(0,j.$h_)("first-sim-order-head-re"),className:"marketing"===ln?y().marketingHeading:y().heading,children:(0,i.jsx)(lc.A,{content:null==le||null==(G=le.cmsCAData)||null==(z=G.field_form_heading)||null==(B=z[0])?void 0:B.processed})})}),!0===e7&&(0,i.jsx)(lP,{handleActivationCode:l=>{e6(!1),ne(l)},cmsData:null==le?void 0:le.cmsCAData}),!e7&&(0,i.jsxs)(a.Ay,{children:[(null==le?void 0:le.freeSim)&&(0,i.jsx)(a.Ay,{sx:eH,children:(0,i.jsx)(lx,{setTypeOfSim:l5,esimData:null==le?void 0:le.esimData,type:ln,freeSimClicked:null==le?void 0:le.freeSimClicked,freeSim:null==le?void 0:le.freeSim,disableSimType:null==le||null==(Y=le.cmsCAData)||null==(X=Y.field_disable_sim_type)?void 0:X[0],defaultSimType:ek})}),(null==le?void 0:le.freeSim)&&(null==lv?void 0:lv.country)==="Sweden"&&(0,i.jsx)(a.Ay,{className:y().mainHead,children:(0,i.jsxs)(nr,{classname:y().ssnMain,children:[(0,i.jsx)(u.A,{className:`${y().imageWrapperAreaCover} topLeftBorderRadius ${eO?"textBlack":"textBlue"}`,children:(0,i.jsx)(m(),{...(0,j.$h_)("sw-ssn-map-re"),className:y().mapGreen,src:g.z.ssnIcon,alt:"ssn icon"})}),(0,i.jsx)(u.A,{sx:{width:"inherit",justifyContent:"space-between",display:"flex"},children:(0,i.jsxs)(a.Ay,{item:!0,display:"flex",flexDirection:"column",className:y().ssnInside,children:[(0,i.jsx)(a.Ay,{item:!0,sm:12,children:(0,i.jsx)(s.A,{...(0,j.$h_)("ssn-text-re"),gutterBottom:!0,className:y().ssn_text,sx:{dis
1play:"flex",flexDirection:"row",alignItems:"center"},children:f.A.ssn})}),eO&&(0,i.jsxs)(a.Ay,{item:!0,className:y().checkSuccess,gap:1.2,display:"flex",justifyContent:"center",alignItems:"center",children:[(0,i.jsx)(m(),{...(0,j.$h_)("thumbs-up-Green-icon-re"),src:g.z.thumbsupGreen,alt:"thumbs-up"}),(0,i.jsx)(s.A,{...(0,j.$h_)("personal-id-re"),children:`***${eB.personal_id.toString().slice(-4)}`}),(0,i.jsx)($.A,{...(0,j.$h_)("change-personal-id-cta-btn-re"),onClick:()=>{eL(!eO),en(!1)},children:f.A.change})]}),!eO&&(0,i.jsx)(a.Ay,{item:!0,sm:12,xs:8,children:(0,i.jsx)(lI.A,{fieldName:"personal-id-input",type:"number",selectValue:"",selectOptions:[],IconComponent:"",maxLength:12,textFieldLabel:f.A.personalId,textFieldValue:eB.personal_id,notDisableEndAdor:!0,setErrorNotDisable:eV,ssnErrorNotDisable:eR,handleNotDisableText:()=>{eB.personal_id&&nc()},error:!!ez.personal_id,name:"ssn",helperText:ez.personal_id,setErrors:eG,onTextFieldChange:l=>((l,e)=>{if(e.length>12)return!1;"ssn"===l&&(""!==e?(eU(l=>({...l,personal_id:e})),eG(l=>({...l,personal_id:""})),lh((0,D.AJ)(e))):eU(l=>({...l,personal_id:""})),eV(!1))})("ssn",l.target.value),borderColor:"#BEC6D5",displaySuffix:!0,displaySelect:!1,notDisableEndAdorText:f.A.check,ssnErrorMessage:eW})})]})})]})}),(null==lv?void 0:lv.is_hot_sim)&&!(null==le?void 0:le.freeSimClicked)&&void 0!==eF&&(0,i.jsx)(V,{handlePortinChange:()=>{ew(l=>!l)},hotSimValue:eF}),(0,i.jsx)(a.Ay,{sx:eH,children:(0,i.jsx)(t.A,{cartTotal:lM,getTotalAmount:Number(na(lJ)),orderTotal:null==le?void 0:le.orderTotal,personalDetailsAlias:null==le?void 0:le.personalDetailsAlias,personalDetailsHead:null==le?void 0:le.personalDetailsHead,freeSim:null==le?void 0:le.freeSim,countryCode:l1,freeSimClicked:null==le?void 0:le.freeSimClicked,taxDetails:el??eK,allPlanFromFreeSim:(null==le?void 0:le.freeSimClicked)?[]:null==le?void 0:le.productDataFreeSim,adobeData:{basketState:lg,allTopUpPlans:lq,baseWindow:li,currency_code:(null==lu||null==(Q=lu.tradeDoubler)?void 0:Q.currencyCode)||"na",configData:lv,journeyName:null===w.H||void 0===w.H?void 0:w.H.deliveryJourneyName,event:"contactConfirmation"},hideDelivery:!e1,selectedPromoDetails:eP,typeOfSim:l4,fieldInteractionDetails:e$})}),(null==lv?void 0:lv.country)==="USA"&&(0,i.jsx)(a.Ay,{sx:eH,display:"flex",flexDirection:"column",children:(0,i.jsx)(nr,{classname:y().areaCoverageMain,children:(0,i.jsx)(u.A,{sx:{width:"inherit",justifyContent:"center",display:"flex"},children:(0,i.jsxs)(a.Ay,{item:!0,display:"flex",flexDirection:"column",justifyContent:"center",className:y().checkAreaCoverageInside,width:lr?"100%":"auto",children:[(0,i.jsx)(s.A,{...(0,j.$h_)("us-area-coverage-re"),gutterBottom:!0,className:y().text_sm,children:f.A.checkAreaCoverage}),(0,i.jsx)(s.A,{variant:"h5",gutterBottom:!0,className:y().coverageSubHeading,children:f.A.coverageSubHeading}),e8&&(0,i.jsxs)(i.Fragment,{children:[lb&&(0,i.jsx)(lo.A,{}),eA?(0,i.jsxs)(a.Ay,{className:y().coverageSuccess,gap:2,display:"flex",alignItems:"center",children:[(0,i.jsx)(m(),{src:g.z.thumbsupGreen,alt:"success",width:20,height:20}),(0,i.jsxs)(s.A,{children:[f.A.excelentCoverage," ",eC.post_code]}),(0,i.jsx)($.A,{onClick:()=>{ex(!1),lh((0,D.o4)(null))},children:f.A.changeZipCode})]}):(0,i.jsx)(lI.A,{fieldName:"post-code-input",selectValue:"",selectOptions:[],IconComponent:"",maxLength:12,textFieldLabel:f.A.postCode,textFieldValue:eC.post_code,notDisableEndAdor:!0,setErrorNotDisable:eI,errorNotDisable:eS,handleNotDisableText:()=>{eC.post_code&&e5()},onEnter:!0,error:!!ej.post_code,name:"zip_code",helperText:ej.post_code,setErrors:eT,onTextFieldChange:l=>((l,e)=>{if("zip_code"===l){let l=null===J.yG||void 0===J.yG?void 0:J.yG.usaPinCode;""!==e?(eD(l=>({...l,post_code:e})),l.test(e)?(eT(l=>({...l,post_code:""})),lh((0,D.sw)(e)),eI(!1)):(lh((0,D.sw)("")),eT(l=>({...l,post_code:null===f.A||void 0===f.A?void 0:f.A.invalidZipcode})))):(eD(l=>({...l,post_code:""})),eT(l=>({...l,post_code:f.A.zipCodeRequired})),eI(!1))}})("zip_code",l.target.value),borderColor:"#BEC6D5",displaySuffix:!0,displaySelect:!1,notDisableEndAdorText:f.A.check})]})]})})})}),e1&&(0,i.jsx)(a.Ay,{sx:eH,children:(0,i.jsx)(U,{country:lQ,freeSim:!!(null==le?void 0:le.freeSim),isMarkingPage:"marketing"===ln,freeSimDeliveryHead:f.A.billingAddressFreesim,type:"deliveryAddress",allPlanWithCartData:lJ,allPlanFromFreeSim:(null==le?void 0:le.freeSimClicked)?[]:null==le?void 0:le.productDataFreeSim,freeSimClicked:null==le?void 0:le.freeSimClicked,typeOfSim:l4,adobeData:{basketState:lg,allTopUpPlans:lq,baseWindow:li,currency_code:(null==lu||null==(ll=lu.tradeDoubler)?void 0:ll.currencyCode)||"na",configData:lv,journeyName:null===w.H||void 0===w.H?void 0:w.H.deliveryJourneyName,event:"addressConfirmation",simType:l4}
1,fieldInteractionDetails:e$,hideFormOnly:!!ea&&!eA})}),(0,i.jsx)(a.Ay,{sx:eH,children:eQ?(0,i.jsx)(q.A,{setConfirmPaymentDetail:lO,cmsData:lU,acceptedCardList:null==lU?void 0:lU[4],country:lQ,onSelect:e4,apmList:lX,isQuickTopUp:!1,type:ln,isFamilyPlan:eE,isPhysicalSimAtFreesim:e1,allPlanWithCartData:eh?null==le?void 0:le.productDataFreeSim:lJ,payPalStatus:!!((null==le?void 0:le.freeSim)&&(null==le?void 0:le.freeSimClicked)||(null==le?void 0:le.disableAPM)),allPlanFromFreeSim:(null==le?void 0:le.freeSimClicked)?[]:null==le?void 0:le.productDataFreeSim,fieldInteractionDetails:e$,hideFormOnly:!!ea&&!eA}):(0,i.jsx)(K.A,{setConfirmPaymentDetail:lO,cmsData:lU,acceptedCardList:null==lU?void 0:lU[4],country:lQ,onSelect:e4,apmList:lX,isQuickTopUp:!1,type:ln,isFamilyPlan:eE,isPhysicalSimAtFreesim:e1,allPlanWithCartData:eh?null==le?void 0:le.productDataFreeSim:lJ,payPalStatus:!!((null==le?void 0:le.freeSim)&&(null==le?void 0:le.freeSimClicked)||(null==le?void 0:le.disableAPM)),allPlanFromFreeSim:(null==le?void 0:le.freeSimClicked)?[]:null==le?void 0:le.productDataFreeSim,fieldInteractionDetails:e$,hideFormOnly:!!ea&&!eA})}),(null==lv?void 0:lv.is_promo_code_enabled_web)&&(0,i.jsx)(a.Ay,{sx:{marginTop:"4px"},children:(0,i.jsx)(lD.A,{getTotalAmount:nm(le,lJ),promo_type:n_(lJ),selectedPlan:((l,e)=>{var n,i,o,t,d;return e?null==e||null==(t=e.productDataFreeSim)||null==(o=t[0])||null==(i=o.bundleGroupDetails)||null==(n=i[0])?void 0:n.bundleCode:null==l||null==(d=l.filter(l=>{var e;return null==(e=l.cartItem)?void 0:e.bundle_selected}))?void 0:d.map(l=>{var e;return null==l||null==(e=l.cartItem)?void 0:e.bundle_code})})(lJ,le),isCA:!0,selectedPromoDetails:eP,setSelectedPromoDetails:eN,setPromoSelect:em,promoSelect:e_,disabled:ea&&(!ed||"true"===ed)||ny,wentForm:(null==le?void 0:le.freeSim)?"freeSim":"",emailId:null==la?void 0:la.email,fromBasket:!eh,shouldCouponReset:ep,setShouldCouponReset:ey,bundleData:(0,j.xDE)(le,lJ),topUpData:(0,j.Piq)(le,lJ,lq),scenario:"freeSim",fieldInteractionDetails:e$})}),(null==le?void 0:le.freeSim)?(0,i.jsx)(a.Ay,{sx:eH,children:(0,i.jsx)(W.A,{shippingCharges:lV,allTopUpPlans:lq,allPlanWithCartData:null==le?void 0:le.productDataFreeSim,getTotalAmount:ns(null==le?void 0:le.productDataFreeSim),freeSim:null==le?void 0:le.freeSim,freeSimClicked:null==le?void 0:le.freeSimClicked,typeOfSim:l4,taxDetails:el??eK,fromCart:!0,fromOrderTax:!0,promoSelect:e_,selectedPromoDetails:eP,activationCodeInfo:nl||""})}):(0,i.jsx)(a.Ay,{sx:eH,children:(0,i.jsx)(W.A,{allTopUpPlans:lq,allPlanWithCartData:lJ,getTotalAmount:na(lJ),taxDetails:el??eK,fromCart:!0,fromOrderTax:!0,promoSelect:e_,selectedPromoDetails:eP})}),(()=>{let l=(0,i.jsx)(a.Ay,{sx:eH,children:(0,i.jsx)(lm,{captchRequired:nn,handleAdobeProgress:ni,cmsData:lU,countryName:l3,allTopUpPlans:lq,physicalSim:l9,allPlanWithCartData:lJ,getTotalAmount:na(lJ),freeSim:null==le?void 0:le.freeSim,termsData:null==le?void 0:le.termsData,freeSimClicked:null==le?void 0:le.freeSimClicked,allPlanFromFreeSim:(null==le?void 0:le.freeSimClicked)?[]:null==le?void 0:le.productDataFreeSim,typeOfSim:l4,getTotalFreeSimAmount:ns(null==le?void 0:le.productDataFreeSim),type:ln,taxDetails:el??eK,shippingCharges:lV,confirmPaymentDetail:lH,selectedPromoDetails:eP,getTotalCaCvmAmount:nm(le,lJ),promo_type:n_(lJ),hotSim:!eE&&(eF||eb),couponData:nl,fieldInteractionDetails:e$})});return nn?(0,i.jsx)(lj.A,{children:l}):l})()]}),(null==le?void 0:le.footer)?"":(0,i.jsx)(lp.default,{data:l6,onlyBottomFooter:!0})]})]})}},12579:l=>{l.exports={subHead:"TypeOfSim_subHead__tv7dY",radioButton:"TypeOfSim_radioButton__DQegK",enterAddressText:"TypeOfSim_enterAddressText__HzKWy",priceFree:"TypeOfSim_priceFree___toKh",price2:"TypeOfSim_price2__Tup5E",label1:"TypeOfSim_label1__iOPxf",label2:"TypeOfSim_label2__3OsNZ",formContainer:"TypeOfSim_formContainer__fEM0t",mobFormContainer:"TypeOfSim_mobFormContainer__Z_4AG",textHead:"TypeOfSim_textHead__lw5w8",textHeadMarketing:"TypeOfSim_textHeadMarketing__B9bzM",infoContainer:"TypeOfSim_infoContainer__CLNOx",optionsBox:"TypeOfSim_optionsBox__PcXDy"}},23435:l=>{l.exports={simDetails:"SimDetailsPopup_simDetails__AuFl4",header:"SimDetailsPopup_header__iI1_J",content:"SimDetailsPopup_content__w
1BBzt",simInfo:"SimDetailsPopup_simInfo__qwFJC",buttonWrapper:"SimDetailsPopup_buttonWrapper__zKR4h",button:"SimDetailsPopup_button__lGi4o",active:"SimDetailsPopup_active__Vd_jr",compatibilityContent:"SimDetailsPopup_compatibilityContent__SAHZH",tabs:"SimDetailsPopup_tabs__j7R_A",listText:"SimDetailsPopup_listText__OZx7g"}},51897:l=>{l.exports={formContainer:"TermsAndConditions_formContainer__jTDw_",textHead:"TermsAndConditions_textHead__Fg_qw",entryWrapper:"TermsAndConditions_entryWrapper__icYrl",labelStyle:"TermsAndConditions_labelStyle__41K_0",nestedSpan:"TermsAndConditions_nestedSpan__Tchq4",hidden:"TermsAndConditions_hidden__10AWS",labelStyleCvm:"TermsAndConditions_labelStyleCvm__iJAZN",recievEmailStyle:"TermsAndConditions_recievEmailStyle__Hm8lu",complaintsMsgStyle:"TermsAndConditions_complaintsMsgStyle__Rjtwl",buttonWraper:"TermsAndConditions_buttonWraper__Z2hHa",hotSIMWraper:"TermsAndConditions_hotSIMWraper__zdNST",hotSimTermsStyle:"TermsAndConditions_hotSimTermsStyle__a1wAL",nestedSpanCvm:"TermsAndConditions_nestedSpanCvm__z6ZO2",buttonStyle:"TermsAndConditions_buttonStyle__2oeZ1",disabledButton:"TermsAndConditions_disabledButton__vHUfi"}},52864:(l,e,n)=>{"use strict";n.d(e,{A:()=>w});var i=n(37876),o=n(14232),t=n(6995),d=n(9129),a=n(22353),r=n(70546),s=n(84733),u=n(72311),c=n(94528),v=n.n(c),_=n(34260),m=n(77225),p=n(41244),y=n(1127),f=n(4833),g=n(80063),h=n(31777),b=n(91040),A=n(76281),x=n.n(A),S=n(75488),I=n(40501),C=n(89317);let D=l=>{let{handleGAFData:e}=l,n=(0,h.d4)(g.Bn),t=(0,o.useRef)(null),d=(0,C.d)(),a=null==n?void 0:n.country_code;return(0,o.useEffect)(()=>{t.current&&(0,f.exO)(null===I.H||void 0===I.H?void 0:I.H.GAFKey,d).then(()=>{let l=new window.google.maps.places.Autocomplete(t.current,{componentRestrictions:{country:[a]},fields:["place_id","geometry","name","formatted_address","address_components"]});l.addListener("place_changed",()=>{let n=l.getPlace();if(!n.address_components)return;let i={Premise:"",Thoroughfare:"",Locality:"",AdministrativeArea:"",PostalCode:"",Address:n.formatted_address||"",Organization:""};n.address_components.forEach(l=>{let e=l.types;e.includes("street_number")&&(i.Premise=l.long_name),e.includes("route")&&(i.Thoroughfare=l.long_name),e.includes("locality")&&(i.Locality=l.long_name),e.includes("administrative_area_level_1")&&(i.AdministrativeArea=l.long_name),e.includes("postal_code")&&(i.PostalCode=l.long_name),e.includes("subpremise")&&(i.Organization=l.long_name)});let o={Address:{Premise:i.Premise,Thoroughfare:i.Thoroughfare,Locality:i.Locality,AdministrativeArea:i.AdministrativeArea,PostalCode:i.PostalCode,Organization:i.Organization}};null==e||e(o,!0)})}).catch(l=>{null==e||e({Address:{}},!1),console.error("Failed to load Google Maps script:",l)})},[]),(0,i.jsx)("div",{children:(0,i.jsx)(u.A,{inputRef:t,id:"autocomplete",label:_.A.melisaAddressDropdownPlaceholder,variant:"outlined",fullWidth:!0,size:"small"})})};var j=n(29671);let T={color:"#667585",fontSize:"16px",fontWeight:400,lineHeight:"16px",fontFamily:"GTEestiLCDisplayRegular","&.MuiInputLabel-shrink":{color:"#667085",fontSize:"12px",fontWeight:400,lineHeight:"14px"}},F={transform:"translate(14px, 8px) scale(0.75)"},w=l=>{let{error:e,type:n,addressFinderValue:c,handleAddressChange:A,defaultValue:I,setAddressNotSelected:C,fieldInteractionDetails:w,basketData:P,onAutoFillChange:N}=l,k=(0,o.useRef)(null),{currentStep:$,formStep:M,fieldName:E}=w??{},H=(0,t.A)("(max-width:768px)"),O=(0,h.d4)(g.Bn),L=(0,h.d4)(g.Xk),B=(null==O?void 0:O.country_code)==="AU",U=(null==O?void 0:O.country_code)==="IT",[z,G]=(0,o.useState)(""),[R,V]=(0,o.useState)((null==I?void 0:I.post_code)?I:null),[W,J]=(0,o.useState)(!1),[K,q]=(0,o.useState)(!1),[Z,X]=(0,o.useState)([]),[Y,Q]=(0,o.useState)(!1),[ll,le]=(0,o.useState)(!1),[ln,li]=(0,o.useState)(!0),lo=(0,f.GP8)(),[lt,ld]=(0,o.useState)(!1),la=(0,o.useRef)(new Set),lr=(0,o.useRef)(!1),ls=(null==L?void 0:L.address_smart_search)===!0,[lu,lc]=(0,o.useState)(!1),lv=l=>{lc(l),null==N||N(l)};(0,o.useEffect)(()=>{q(e)},[e]);let l_=async l=>{Q(!0),J(!1),q(!1);let e=[];
1if((null==l?void 0:l.length)<=2)return;let n=btoa("lycagroup_live_user:OgexPHtDwszMSJ5enDnRbOADHKWRPadh");try{let o=b.A.create({headers:{Accept:"application/json, text/plain, */*","Content-Type":"application/json",Authorization:"Basic "+n},params:{fullAddress:l,sourceOfTruth:"GNAF"}}),{data:t}=await o.get("https://hosted.mastersoftgroup.com/harmony/rest/au/address");if((null==t?void 0:t.status)==="SUCCESS"){var i;Q(!1),null==t||null==(i=t.payload)||i.forEach(l=>{e.push({Address:{Address:l.fullAddress,Line1:(0,f.FRT)(l),streetType:null==l?void 0:l.streetType,streetNumber:null==l?void 0:l.streetNumber,City:l.locality,State:l.state,PostalCode:l.postcode,completepayload:l}})}),X(e),B||A(""),(null==e?void 0:e.length)<1&&!B&&(C(null),J(!0))}}catch(l){Q(!1)}},lm=async()=>{var l,e,n;let i=k.current;J(!1),q(!1);let o=(0,f._1n)(null==i||null==(l=i.getFormData())?void 0:l.formData);if(null==i||null==(e=i.getFormData())?void 0:e.isFormValid)try{V(o),Q(!0);let{status:l,data:e}=await y.A.get((0,f.ZbH)(o,3e3,ls));if(200==l){Q(!1);let l=null==e||null==(n=e.Results)?void 0:n.filter(l=>{var e,n,i,o,t,d;return[null==l||null==(e=l.Address)?void 0:e.Address,null==l||null==(n=l.Address)?void 0:n.Address1,null==l||null==(i=l.Address)?void 0:i.Address2,null==l||null==(o=l.Address)?void 0:o.Address3,null==l||null==(t=l.Address)?void 0:t.Address4,null==l||null==(d=l.Address)?void 0:d.Address5].some(l=>!!l)});A(""),X(l),(null==l?void 0:l.length)<1&&(C(null),J(!0))}}catch(l){Q(!1)}},lp=function(l,e){let n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:"",[i,t]=(0,o.useState)(n);return(0,o.useEffect)(()=>{let n=setTimeout(()=>t(l),e);return()=>{clearTimeout(n)}},[l,e]),i}(z,1e3);(0,o.useEffect)(()=>{lp&&B&&(null==z?void 0:z.length)>2&&l_(z)},[lp]),(0,o.useEffect)(()=>{var l;(null==c||null==(l=c.Address)?void 0:l.Address)&&G(c.Address.Address)},[c]);let ly=async l=>{try{Q(!0);let{status:n,data:i}=await y.A.get((0,f.ZbH)({searchText:l,street_name:l},3e3,ls));if(200===n){var e;let n=null==i||null==(e=i.Results)?void 0:e.filter(l=>{var e;return null==l||null==(e=l.Address)?void 0:e.Address});X(n||[]),(null==n?void 0:n.length)?(ld(!0),J(!1)):(ld(!1),l.length>5?(C(null),J(!0)):J(!1))}}catch(l){console.error("USA Melissa error:",l)}finally{Q(!1)}},lf=ls?_.A.melisaFreeSearch_streetName_common:_.A.melisaAddressDropdownLabel,lg=ls?_.A.melisaFreeSearch_streetName_common:_.A.melisaAddressDropdownPlaceholder;return(0,o.useEffect)(()=>{if(!ls)return;if(lr.current){lr.current=!1;return}if(!z||z.length<3)return;let l=setTimeout(()=>{ly(z)},400);return()=>clearTimeout(l)},[z,ls]),(0,i.jsxs)(d.Ay,{className:v().addressFinderNew,item:!0,xs:12,sx:{marginBottom:H?"10px":void 0},children:[Y&&!B&&(0,i.jsx)(S.A,{}),!B&&(lo?(0,i.jsx)(D,{handleGAFData:(l,e)=>{A(l)}}):(0,i.jsxs)(i.Fragment,{children:[!ls&&(ln||(0,f.Ime)(c))&&(0,i.jsx)(m.A,{hasError:K,fromShippingFreesim:n,ref:k,model:(0,f.J4e)(_.A,ls,U&&lu),values:R??{},onChange:(l,e,n,i)=>{le(i),J(!1),i||X([]),!la.current.has(l)&&(null==e?void 0:e.length)>0&&(la.current.add(l),(0,j.$d)((0,j.ar)(P),$,M,`Deliver address ${l}`,"delivery and payment"))}}),W&&(0,i.jsx)(a.A,{className:v().alert,severity:"error",children:_.A.addressFinderNotfoundError}),!ls&&(ln||(0,f.Ime)(c))&&(0,i.jsx)(p.A,{disabled:!ll||Y,className:v().findAddressButton,onClick:()=>{lm(),(0,j.$d)((0,j.ar)(P),$,M,"Find adrress","delivery and payment")},children:_.A.findAddress})]})),!lo&&(B||ls||(null==Z?void 0:Z.length)>0)&&(0,i.jsx)(r.A,{sx:{mb:1},popupIcon:ls?null:void 0,forcePopupIcon:!ls,openOnFocus:ls,isOptionEqualToValue:(l,e)=>{var n,i;return(null==l||null==(n=l.Address)?void 0:n.Address)===(null==e||null==(i=e.Address)?void 0:i.Address)},open:ls?lt&&Z.length>0:void 0,onOpen:()=>{ls&&Z.length>0&&ld(!0)},onClose:()=>{ls&&(ld(!1),X([]))},noOptionsText:_.A.noAddressFonud,loadingText:"loading....",loading:Y,value:c||null,onChange:(l,e)=>{var n;if(ls&&(lr.current=!0,ld(!1),X([])),ls&&(null==e?void 0:e.Address)){let l=e.Address;A(((l,e)=>{switch(e){case"USA":case"ES":return{Address:{Premise:(null==l?void 0:l.Premise)||"",Thoroughfare:(null==l?void 0:l.Thoroughfare)||"",Locality:(null==l?void 0:l.Locality)||"",AdministrativeArea:(null==l?void 0:l.AdministrativeArea)||"",PostalCode:(null==l?void 0:l.PostalCodePrimary)||(null==l?void 0:l.PostalCode)||"",Organization:(null==l?void 0:l.Building)||"",Address:(null==l?void 0:l.Address)||""}};default:return{Address:{Premise:(null==l?void 0:l.SubBuilding)||(null==l?void 0:l.Premise)||"",Thoroughfare:(null==l?void 0:l.Building)||(null==l?void 0:l.Thoroughfare)||"",Locality:(null==l?void 0:l.Locality)||"",AdministrativeArea:(null==l?void 0:l.AdministrativeArea)||"",PostalCode:(null==l?void 0:l.PostalCodePrimary)||(null==l?void 0:l.PostalCode)||"",Organization:(null==l?void 0:l.Organization)||"",DependentLocality:(null==l?void 0:l.DependentLocality)||"",Address:(null==l?void 0:l.Address)||""}}}})(l,null==O?void 0:O.country_code)),G((null==l?void 0:l.Address)||"")}else A(e);(null==e?void 0:e.Address)?(li(!1),lv(!0)):(li(!0),lv(!1)),(0,j.$d)((0,j.ar)(P),$,M,(null==e||null==(n=e.Address)?void 0:n.Address)||"Address value","delivery and payment")},getOptionLabel:l=>{var e;return"string"==typeof l?l:(null==l||null==(e=l.Address)?void 0:e.Address)||""},onInputChange:(l,e,n)=>{if(ls){if("clear"===n){G(""),X([]),ld(!1),A(null),li(!0),J(!1),lv(!1);return}if("input"!==n)return;G(e),e.length<3&&(X([]),ld(!1),J(!1));return}G(e)},inputValue:ls?z:void 0,...B?{filterOptions:l=>l}:{},renderOption:(l,e)=>{var n;return(0,i.jsx)("li",{...l,children:(0,i.jsx)(d.Ay,{container:!0,alignItems:"center",children:(0,i.jsx)(d.Ay,{item:!0,children:(0,i.jsx)(s.A,{className:null===x()||void 0===x()?void 0:x().listText,component:"span",children:null==e||null==(n=e.Address)?void 0:n.Address})})})})},id:"combo-box-demo",options:Z||[],filterOptions:ls?l=>l:void 0,renderInput:l=>{var e,n,o,t;return(0,i.jsx)(u.A,{autocomplete:"off",...l,label:lf,placeholder:lg,className:(null==l||null==(n=l.inputProps)||null==(e=n.value)?void 0:e.length)>0?null===x()||void 0===x()?void 0:x().inputPadding1:null===x()||void 0===x()?void 0:x().inputNOPadding1,InputLabelProps:{shrink:!1,sx:(null==l||null==(t=l.inputProps)||null==(o=t.value)?void 0:o.length)>0?{...T,...F}:T}})}})]})}},54026:l=>
1{l.exports={hotSIMSwitch_Portin:"HotSIM_hotSIMSwitch_Portin__tXKcs",mainHead:"HotSIM_mainHead__H5Wjs",hotSimHead:"HotSIM_hotSimHead__2cmbK",textHead:"HotSIM_textHead__kv6Oj",radioButton:"HotSIM_radioButton__wdMJN"}},54811:l=>{l.exports={ActivationCodeMain:"ActivationCode_ActivationCodeMain__tbqRM",subHead:"ActivationCode_subHead__5F9vZ",submit_btn_conatainer:"ActivationCode_submit_btn_conatainer__kuVSy",submit_btn:"ActivationCode_submit_btn__VnE_E",alert:"ActivationCode_alert__OFjIU"}},70490:(l,e,n)=>{"use strict";n.d(e,{A:()=>b});var i=n(37876),o=n(14232),t=n(84733),d=n(5067),a=n(9129),r=n(55134),s=n(54587),u=n.n(s),c=n(16455),v=n(23435),_=n.n(v),m=n(41244),p=n(35814),y=n(25601),f=n(16562),g=n(4833);function h(l){let{children:e,value:n,index:o,...a}=l;return(0,i.jsx)("div",{role:"tabpanel",hidden:n!==o,id:`simple-tabpanel-${o}`,"aria-labelledby":`simple-tab-${o}`,...a,children:n===o&&(0,i.jsx)(t.A,{children:(0,i.jsx)(d.A,{className:_().listText,textAlign:"center",children:e})})})}let b=l=>{var e,n,d,s,v,b;let{onClose:A,activeTab:x=0,compatibilityData:S}=l,[I,C]=(0,o.useState)(x),[D,j]=o.useState(0),T=null==S||null==(n=S.field_heading)||null==(e=n[0])?void 0:e.processed,F=null==S||null==(s=S.field_second_heading)||null==(d=s[0])?void 0:d.processed,w=null==S||null==(b=S.field_content)||null==(v=b[0])?void 0:v.processed,P=null==S?void 0:S.children;return(0,i.jsx)(i.Fragment,{children:(0,i.jsxs)(a.Ay,{p:4,container:!0,className:_().simDetails,children:[(0,i.jsx)(a.Ay,{item:!0,sm:12,className:_().header,children:(0,i.jsx)(r.A,{onClick:A,...(0,g.$h_)("sim-details-close-button-n"),children:(0,i.jsx)(u(),{...(0,g.$h_)("sim-modal-close-icon-n"),src:c.z.popup_close,alt:"closeCicle"})})}),(0,i.jsxs)(a.Ay,{container:!0,className:`${_().content} ${1===I&&_().simInfo}`,children:[(0,i.jsxs)(a.Ay,{className:_().buttonWrapper,item:!0,sm:12,textAlign:"center",children:[(0,i.jsx)(m.A,{...(0,g.$h_)("esim-intro-tab-n"),onClick:()=>C(0),className:`${_().button} ${0===I?_().active:""}`,children:(0,i.jsx)(f.A,{content:T})}),(0,i.jsx)(m.A,{...(0,g.$h_)("compatibility-tab-n"),onClick:()=>C(1),sx:{p:0},className:`${_().button} ${1===I?_().active:""}`,children:(0,i.jsx)(f.A,{content:F})})]}),(0,i.jsx)(a.Ay,{item:!0,sx:{width:"100%",height:"318px"},children:0===I?(0,i.jsx)(f.A,{content:w}):(0,i.jsxs)(t.A,{sx:{width:"100%"},children:[(0,i.jsx)(t.A,{sx:{width:"100%",margin:"26px 0px"},children:(0,i.jsx)(p.A,{value:D,onChange:(l,e)=>{j(e)},className:_().tabs,variant:"scrollable",scrollButtons:"auto","aria-label":"scrollable auto tabs example",children:null==P?void 0:P.map((l,e)=>{var n,o;return(0,i.jsx)(y.A,{label:(0,i.jsx)(f.A,{content:null==(o=l.field_tab)||null==(n=o[0])?void 0:n.processed}),...function(l){return{id:`simple-tab-${l}`,"aria-controls":`simple-tabpanel-${l}`}}(e)})})})}),null==P?void 0:P.map((l,e)=>{var n,o;return(0,i.jsx)(h,{value:D,index:e,children:(0,i.jsx)(t.A,{className:_().compatibilityContent,children:(0,i.jsx)(f.A,{content:null==(o=l.field_device_list)||null==(n=o[0])?void 0:n.processed})})},e)})]})})]})]})})}},76281:l=>{l.exports={inputPadding1:"input_inputPadding1__8CH_Z",inputNOPadding1:"input_inputNOPadding1__BMEfZ",listText:"input_listText__PU8Mt"}},94528:l=>{l.exports={subHead:"DeliveryTo_subHead___LlaS",mainGrid:"DeliveryTo_mainGrid__kOrf9",phoneNumberContainer:"DeliveryTo_phoneNumberContainer__NqvYo",enterAddressText:"DeliveryTo_enterAddressText___foDD",weMayContactYouForYourSIMDelivery:"DeliveryTo_weMayContactYouForYourSIMDelivery__WcVFc",fromAddTocard:"DeliveryTo_fromAddTocard__nCB82",addTocardWrapper:"DeliveryTo_addTocardWrapper__euZZS",formContainer:"DeliveryTo_formContainer__Z7SmA",formContainer_confirmed:"DeliveryTo_formContainer_confirmed__th8P_",flexRow:"DeliveryTo_flexRow__0R9o_",findAddress:"DeliveryTo_findAddress__ab9US",addTocard:"DeliveryTo_addTocard__K1f2e",autRenewMain:"DeliveryTo_autRenewMain__q_N_n",payAuto:"DeliveryTo_payAuto__349na",method:"DeliveryTo_method__jzZlo",textHead:"DeliveryTo_textHead__xPYvG",freeSimHead:"DeliveryTo_freeSimHead__YtGm_",findAddressButton:"DeliveryTo_findAddressButton__tJPut",alert:"DeliveryTo_alert__nXcGK",address_detail
1:"DeliveryTo_address_detail__6u0WK",changeButton:"DeliveryTo_changeButton__hLrH8"}},95694:(l,e,n)=>{"use strict";n.d(e,{Y:()=>i});let i=(l,e,n)=>{let{DeliveryAddress:i="",DeliveryAddress1:o="",Locality:t="",CountryName:d="",PostalCode:a="",Organization:r="",SubBuilding:s="",Premise:u="",Building:c="",Thoroughfare:v="",DoubleDependentLocality:_="",DependentLocality:m="",DependentThoroughfare:p="",AdministrativeArea:y="",PostBox:f,PostalCodePrimary:g}=l||{},h="",b="",A="",x="";switch(n){case"AU":return h=""!==s||""!==u?s||(""+u?u:""):(null==l?void 0:l.streetNumber)||"",b=""!==v?v:""!==c?c:"",{street:null==l?void 0:l.Line1,street_type:null==l?void 0:l.streetType,street_number:(null==l?void 0:l.streetNumber)||"",house_no:h||"",city:null==l?void 0:l.City,county:(null==l?void 0:l.State)||"",country:d||e,post_code:null==l?void 0:l.PostalCode,isvalid:!0};case"AT":case"BE":return h=""!==u?u||"":""!==s?s:"",b=""!==v?v:""!==c?c:"",{house_no:h,street_name:`${b.substring(0,50)}`,city:t,county:y||"",country:d||e,post_code:null==a?void 0:a.replace("-",""),Organization:r||"",isvalid:!0};case"NL":return h=""!==u?u||"":""!==s?s:"",b=""!==v?v:""!==c?c:"",{house_no:(null==h?void 0:h.substring(0,50))||"",street_name:`${b.substring(0,50)}`,city:t,county:y||"",country:d||e,post_code:a,Organization:r||"",houseno_extn:s||"",isvalid:!0};case"SW":case"CH":return h=""!==u||""!==s?u||(""+s?s:""):"",b=""!==v?v:""!==c?c:"",{house_no:(null==h?void 0:h.substring(0,50))||"",street_name:`${b.substring(0,50)}`,city:t,county:y||"",country:e||d,post_code:a,Organization:r||"",isvalid:!0};case"SE":return h=""!==u?u:""!==s?s:"",b=""!==v?v:""!==c?c:"",{street_name:`${""!==h?h+", "+(null==b?void 0:b.substring(0,50)):b.substring(0,50)}`,street:`${""!==h?h+", "+(null==b?void 0:b.substring(0,50)):b.substring(0,50)}`,city:t,county:y||"",country:d||e,post_code:null==a?void 0:a.replace(" ",""),Organization:r||"",isvalid:!0};case"DK":case"PL":case"DE":return h=""!==u?u:""!==s?s:"",b=""!==v?v:""!==c?c:"",{house_no:(null==h?void 0:h.substring(0,50))||"",street_name:`${b.substring(0,50)}`,street:`${b.substring(0,50)}`,city:t,county:y||"",country:d||e,post_code:null==a?void 0:a.replace("-",""),Organization:r||"",apartment_no:r||"",isvalid:!0};case"PT":return h=""!==u?u:"",b=""!==v?v:"",{house_no:(null==h?void 0:h.substring(0,50))||"",street_name:`${b.substring(0,50)}`,city:t,county:y||"",country:d||e,post_code:a,Organization:r||"",isvalid:!0};case"FR":return h=""!==s||""!==u?s||(""+u?u:""):"",b=""!==v?v:""!==c?c:"",{house_no:(null==h?void 0:h.substring(0,50))||"",street_name:`${b.substring(0,50)}`,street:`${b.substring(0,50)}`,city:t,county:y||"",country:d||e,post_code:a,Organization:r||"",isvalid:!0};case"USA":return{house_no:`${u||""} ${v||""}`.trim(),street_name:c||"",city:t||"",county:y||"",country:d||e,post_code:g||a||"",Organization:r||"",isvalid:!0};case"ES":return{house_no:u||"",street:v||"",city:`${y||""} , ${t||""}`,country:d||e,post_code:g||a||"",isvalid:!0};case"GB":return h=""!==s?s:""!==u?u:r,b=""!==c&&h!==c?c:""!==s&&""!==u?`${u} ${v}`:v,""!==s&&""!==c?A=""!==u?`${u} ${v}`:v:""!==c&&h!==c&&(A=v),{house_no:(null==h?void 0:h.substring(0,50))||"",street_name:b.substring(0,50),city:t,county:"",address2:A.substring(0,50),country:d||e,post_code:a,Organization:r||"",apartment_no:r||"",isvalid:!0};case"IT":return h=""!==u?u:""!==s?s:"",b=""!==v?v:""!==c?c:"",{house_no:(null==h?void 0:h.substring(0,50))||"",street_name:`${b.substring(0,50)}`,street:`${b.substring(0,50)}`,city:t,county:y||"",post_code:a,isvalid:!0};case"FR":return h=""!==s||""!==u?s||(""+u?u:""):"",b=""!==v?v:""!==c?c:"",{house_no:(null==h?void 0:h.substring(0,50))||"",street_name:`${b.substring(0,50)}`,city:t,county:y||"",country:d||e,post_code:a,Organization:r||"",isvalid:!0};case"IE":return""!==s&&(h=s),""!==u&&(""!==h&&(h+=","),h+=u),""!==c&&(""!==h&&(h+=","),h+=c),""!==_&&(""!==h&&(h+=","),h+=_),""!==m&&(""!==h&&(h+=","),h+=m),""!==v&&(""!==b&&(b+=","),b+=v),""!==p&&(""!==b&&(b+=","),b+=p),""!==t&&(""!==b&&(b+=","),b+=t),""!==y&&(""!==x&&(x+=","),x+=y),{house_no:(null==h?void 0:h.substring(0,50))||"",street:`${b.substring(0,50)}`,city:x,county:"",country:d||e,post_code:a,Organization:r||"",isvalid:!0}}}}}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.