1var it=Object.defineProperty,at=Object.defineProperties;var ot=Object.getOwnPropertyDescriptors;var Ue=Object.getOwnPropertySymbols;var lt=Object.prototype.hasOwnProperty,ct=Object.prototype.propertyIsEnumerable;var Oe=(t,n,s)=>n in t?it(t,n,{enumerable:!0,configurable:!0,writable:!0,value:s}):t[n]=s,Me=(t,n)=>{for(var s in n||(n={}))lt.call(n,s)&&Oe(t,s,n[s]);if(Ue)for(var s of Ue(n))ct.call(n,s)&&Oe(t,s,n[s]);return t},We=(t,n)=>at(t,ot(n));import{m as de,E as ne,j as e,M as F,T as U,q as z,ai as re,aX as dt,S as P,e as mt,ad as pt}from"./vendor-mui-BGS3mHwM.js";import{r as b,j as N,R as xt,u as ht}from"./vendor-redux-FtDGt7Mz.js";import{C as H,bw as se,cr as me,bf as pe,qW as ut,cd as Ke,qX as $e,dX as gt,dS as ft,aI as bt,mr as jt,bY as yt,co as Ct,s as vt,op as Et,ct as kt,kX as Ft,kT as wt,d6 as St,qY as Nt,oq as At,or as Lt,qZ as Tt,q_ as Pt,q$ as It,r0 as _t,r1 as Rt,bm as Bt,bn as Ht,r2 as Ut,cu as Ge,c0 as Ve,kG as Ot,r3 as Mt,r4 as Wt,bb as $t}from"./index-D5apbUK-.js";import{b as Gt,h as qe,a as Vt}from"./HomePageAnalytics-D9dS5uFb.js";import{C as M}from"./index-8-NLqzxP.js";import{H as xe,b as qt,a as Dt,c as Qt,m as Yt,d as zt}from"./utils-C42Xe5bM.js";import{u as R,L as De}from"./vendor-react-CUpnpRPD.js";import{u as Kt,H as Xt,S as Zt,O as Jt,D as es,a as ts,V as ss,W as ns,M as rs,P as is,b as as,c as os}from"./HRAHomeCardSection-CYUZqgTc.js";import{u as ls}from"./index-CdaXMd8H.js";import{c as cs}from"./index-DasbGogH.js";import{W as ce}from"./WrapperContainer-2E8x9RQK.js";import{H as ds}from"./constants-zLDXZ88X.js";import{H as ms}from"./index-YHxOhz-z.js";import{B as Qe}from"./BannersCards-Briiwrim.js";import{B as Ye}from"./enum-BI9DAnD2.js";import{a as ps}from"./util-Xb0cgq-H.js";import{a as xs}from"./arrowIcon-CBQpiFm2.js";import{R as f}from"./index-5qh8NZOl.js";import"./vendor-stream-CynyArsg.js";import"./vendor-pdf-Ddbn4B6C.js";import"./vendor-graphql-CuoeCPzn.js";import"./vendor-media-BEZy7yMd.js";import"./vendor-radix-NiTG7895.js";import"./vendor-mui-pickers-BdXKbjEa.js";import"./vendor-forms-BcpGzS3-.js";import"./index-_AhaXIr4.js";import"./index-AL27mQ15.js";import"./slider-5sduuYxH.js";import"./arrowNext-CF_cyRUy.js";import"./FilledPlayButton-BoNWV1LW.js";import"./CrossButton-C59j-tM1.js";import"./PrescriptionBanner-n9j5J7-z.js";import"./GenericAssessment-JOu8aUv9.js";import"./hra-BHHP8J3j.js";import"./index-D0nqMzFV.js";import"./BenefitCard-C-zr9K_k.js";import"./broadcast_consultation_thumbnail-y-IGz1l9.js";import"./index-D8v8Urgc.js";import"./pd-pm-request-data-D7TDIvUG.js";import"./EnableLocationModal-BCK6Dom2.js";import"./index-ConxZptW.js";import"./utils-BDEkMPKy.js";import"./orders-DwHsOPTi.js";import"./PopularVideo-rGXYpOcp.js";import"./FreeImage-C1s3A7iK.js";import"./LockedVideo-ykYgNNCl.js";import"./Constant-DNgBJIJl.js";import"./index-D0u6_Cve.js";import"./UnlockPackageCategoryCard-CgJ-sMet.js";import"./Done-BjVXQUkh.js";import"./index-CKulASNu.js";import"./contants-EjpmJhUC.js";import"./constants-BD6fh2BP.js";import"./arrow-right-BA-5W8Ev.js";import"./createLucideIcon-D0CqTctp.js";import"./index-DANehcwr.js";import"./infoIconPurple-Dovs9vaw.js";const hs="/assets/LinkGmailThumbnail-DymmyTi1.png",us=({healthTipsData:t})=>{var c;const n=de(),s=ne(n.breakpoints.up("md")),i=R();return e.jsx(H,{sx:{padding:{xs:"0 1rem",md:"0 2.5rem"}},children:e.jsxs(F,{display:"flex",flexDirection:"column",gap:"1.75rem",children:[e.jsxs(F,{display:"flex",justifyContent:"space-between",children:[e.jsx(U,{variant:"2xl.bold",color:"textDark.heading",children:"Wellness Tips"}),e.jsx(z,{variant:"outlined",size:s?"sm":"xs",onClick:()=>i("/health-tips"),children:"See All"})]}),e.jsx(M,{parentCss:{gap:"1rem",padding:"0px"},children:(c=t==null?void 0:t.slice(0,10))==null?void 0:c.map((d,r)=>e.jsx(xe,{onClickEvent:()=>Gt(d.title,r),index:r,layoutType:"column",title:d.title,subtitle:d.subTitle,thumbnail:d.backgroundImage,height:s?"18rem":"20rem",width:"11.25rem",thumbnailConfig:{playButton:!0,type:"healthTips",leftTag:d.leftBtn,rightTag:d.duration,mediaLink:d.mediaLink},mediaLinksArray:d.mediaLinksArray},`health-tips-card-${d.title}=${r}`))})]})})},gs=({videosData:t,hideTitle:n=!1})=>{const s=de(),i=ne(s.breakpoints.up("md")),c=R(),d=i?10:3;return e.jsx(H,{sx:{padding:{xs:"0 1rem",md:"0 2.5rem"}},children:e.jsxs(F,{display:"flex",flexDirection:"column",gap:"1.75rem",children:[!n&&e.jsxs(F,{display:"flex",justifyContent:"space-between",children:[e.jsx(U,{variant:"2xl.bold",color:"textDark.heading",children:"Wellness Videos"}),e.jsx(z,{variant:"outlined",size:i?"sm":"xs",onClick:()=>c("/healthcare-videos"),children:"See All"})]}),e.jsx(M,{parentCss:{gap:"1rem",padding:"0px"},children:t==null?void 0:t.slice(0,d).map((r,m)=>e.jsx(xe,{layoutType:"column",title:r.title,onClickEvent:()=>qe(r.title,m,r.duration,r,se.HEALTHCARE_VIDEO_CLICKED),handleMediaClose
1:()=>qe(r.title,m,r.duration,r,se.HEALTHCARE_VIDEO_PLAYED),index:m,subtitle:r.subTitle,thumbnail:r.backgroundImage,height:i?"10.75rem":"11.6085rem",parentCss:{height:"100%",border:"1px solid #EAEDF1",padding:"1rem",borderRadius:"0.5rem"},width:i?"20rem":"18rem",thumbnailConfig:{playButton:!0,type:"healthCareVideos",leftTag:r.leftBtn,rightTag:r.duration,mediaLink:r.mediaLink}},`health-content-card-${r.title}=${m}`))})]})})},fs=({recipeData:t})=>{var d;const n=de(),s=ne(n.breakpoints.up("md")),i=R(),c=s?10:3;return e.jsx(H,{sx:{padding:{xs:"0 1rem",md:"0 2.5rem"}},children:e.jsxs(F,{display:"flex",flexDirection:"column",gap:"1.75rem",children:[e.jsxs(F,{display:"flex",justifyContent:"space-between",children:[e.jsx(U,{variant:"2xl.bold",color:"textDark.heading",children:"Healthy Recipes"}),e.jsx(z,{variant:"outlined",size:s?"sm":"xs",onClick:()=>i("/healthy-recipes"),children:"See All"})]}),e.jsx(M,{parentCss:{gap:"1rem",padding:"0px"},children:(d=t==null?void 0:t.slice(0,c))==null?void 0:d.map((r,m)=>e.jsx(xe,{layoutType:"column",title:r.title,onClickEvent:()=>Vt(r.title,m),subtitle:r.subTitle,thumbnail:r.backgroundImage,width:s?"20rem":"18rem",parentCss:{height:"100%",border:"1px solid #EAEDF1",padding:"1rem",borderRadius:"0.5rem"},height:s?"10.8125rem":"11.5625rem",backgroundWidth:"",thumbnailConfig:{playButton:!0,type:"foodCard",rightTag:r.duration,mediaLink:r.mediaLink}},`healthy-recipes-card-${r.title}=${m}`))})]})})},bs=(t,n)=>{var s;n&&(t!=null&&t.current)&&((s=t==null?void 0:t.current)==null||s.scrollIntoView({behavior:"smooth",block:"center",inline:"nearest"}))},Y=re(P)(({theme:t})=>({padding:"1.5rem",height:"20rem",width:"20.4375rem",borderRadius:"0.75rem",bgcolor:n=>n.bgcolor,boxShadow:"0px 4px 8px -2px rgba(16, 24, 40, 0.10), 0px 2px 4px -2px rgba(16, 24, 40, 0.06)",gap:"1.5rem",alignItems:"center",justifyContent:"space-between",[t.breakpoints.down("sm")]:{maxWidth:"80vw"}})),js=re(Y)({flexDirection:"row",height:"unset",width:"unset"}),oe=re(Y)(()=>({padding:"1rem"})),le=re(dt)(({theme:t})=>({height:"100%",width:"70vw",[t.breakpoints.up("sm")]:{width:"100%"}})),ys=({bgcolor:t})=>e.jsx(ce,{sx:{bgcolor:t},children:e.jsxs(H,{InnerElement:P,sx:{padding:{xs:"1rem",md:"5rem 2.5rem"},"& .content":{flexDirection:"row",gap:"1rem",overflow:"auto"}},children:[e.jsx(oe,{bgcolor:"#fff",children:e.jsx(le,{})}),e.jsx(oe,{bgcolor:"#fff",children:e.jsx(le,{})}),e.jsx(oe,{bgcolor:"#fff",children:e.jsx(le,{})})]})}),Cs=({config:t})=>{const n=R();if(t.type==="image")return e.jsx(Y,{bgcolor:t.bgcolor,children:e.jsx(F,{component:"img",src:t.imageConfig.img})});const s=i=>i.onClick?i.onClick():n(i.path);return t.type==="thumbnail_text"?e.jsxs(js,{bgcolor:t.bgcolor,children:[e.jsxs(P,{direction:"row",alignItems:"center",gap:"1.5rem",children:[e.jsx(F,{component:"img",src:t.thumbnailTextConfig.thumbnail,height:"7.25rem"}),e.jsxs(P,{gap:"0.5rem",padding:"0 1.5rem",children:[e.jsx(U,{variant:"xl.bold",color:"textDark.heading",textAlign:"center",children:t.thumbnailTextConfig.title}),e.jsx(U,{variant:"sm.regular",color:"primary.charcoalGrey",textAlign:"center",children:t.thumbnailTextConfig.subtitle})]})]}),e.jsx(P,{gap:"0.5rem",flexWrap:"wrap",children:t.thumbnailTextConfig.buttons.map((i,c)=>e.jsx(z,{size:"lg",variant:i.variant,onClick:()=>s(i),children:i.text},`promo-content-card-cta-${Math.random()*c}`))})]}):null},ze=({config:t})=>{const n=R();if(t.type==="image")return e.jsx(Y,{bgcolor:t.bgcolor,children:e.jsx(F,{component:"img",src:t.imageConfig.img})});const s=i=>i.onClick?i.onClick():n(i.path);return t.type==="thumbnail_text"?e.jsxs(Y,{bgcolor:t.bgcolor,children:[e.jsx(F,{component:"img",src:t.thumbnailTextConfig.thumbnail,height:"4.6rem"}),e.jsxs(P,{gap:"0.5rem",children:[e.jsx(U,{variant:"lg.bold",color:"textDark.heading",textAlign:"center",children:t.thumbnailTextConfig.title}),e.jsx(U,{variant:"sm.regular",color:"primary.charcoalGrey",textAlign:"center",children:t.thumbnailTextConfig.subtitle})]}),e.jsx(P,{gap:"0.5rem",direction:"row",flexWrap:"wrap",children:t.thumbnailTextConfig.buttons.map((i,c)=>e.jsx(z,{size:"lg",variant:i.variant,onClick:()=>s(i),children:i.text},`promo-content-card-cta-${i.text}-${c}`))})]}):null},vs=({cards:t,bgcolor:n})=>{const s=mt(),i=ne(s.breakpoints.up("md")),c=t.length;return c===0?null:c===1&&i?e.jsx(ce,{sx:{bgcolor:n},children:e.jsx(H,{sx:{padding:{xs:"1rem",md:"5rem 2.5rem"}},children:e.jsx(Cs,{config:t[0]})})}):c===1?e.jsx(H,{InnerElement:P,sx:{bgcolor:n,padding:"1rem","& .content":{alignItems:"center"}},children:e.jsx(ze,{config:t[0]},`promo-cards-${t[0].type}-${Math.random()}`)}):e.jsx(ce,{sx:{bgcolor:n,padding:{xs:"0",md:"0 2.5rem"}},children:e.jsx(H,{sx:{padding:{xs:"1rem",md:"5rem 0"},"& .item-strip":{justifyContent:"flex-start"}},children:e.jsx(M,{children:t.map(d=>e.jsx(ze,{config:d},`promo-cards-${d.type}-${Math.random()}`))})})})},Es=({bgcolor:t})=>{var o,u,x;const[n,s]=b.useState(!1),[i,c]=b.useState({}),d=N(me),r=N(pe),m=N(ut),{data:C}=Ke(),{data:g,isLoading:A}=cs(void 0,{skip:!d}),j=R(),B=d?m&&!((o=C==null?void 0:C.data)!=null&&o.emailConnected)&&$e:$e,L=[{type:"thumbnail_text",bgcolor:"primary.white",thumbnailTextConfig:{thumbnail:hs,title:"Import your health records from Gmail",subtitle:"Effortlessly store and access health records in one place",buttons:[{text:"Link Your Gmail",path:"/gmail/link",variant:"outlined"}]},show:B}];if(A)return e.jsx(ys,{bgcolor:t});const T=((u=g==null?void 0:g.data)==null?void 0:u.conditionManagementPlans)||[],I=l=>{s(!0),c(l)},w=l=>{j(`/hra/${i==null?void 0:i.slug}/${l}`)},S={assessmentSlug:i==null?void 0:i.slug,serviceTypes:(x=ft)==null?void 0:x.HRA};r!==bt&&T.forEach(l=>{L.push({type:"thumbnail_text",bgcolor:"green.extraLight",thumbnailTextConfig:{thumbnail:l.logoUrl,title:l.name,subtitle:l.description,buttons:[{text:l.ctaTitle,variant:"outlined",onClick:()=>I(We(Me({},l),{type:"CMP"}))}]},show:!0})});const y=L.filter(l=>l.show);return y.length===0?null:e.jsxs(e.Fragment,{children:[e.jsx(vs,{cards:y,bgcolor:t}),e.jsx(gt,{open:n,handleDrawerClose:s,handleSelectedPatient:w,patientListingParams:S,headerConfig:ds})]})}
1,ks=t=>t==null?"/sponsored-benefits":`/sponsored-benefits#section-${t+1}`,Fs=t=>{var i,c;const n=(i=t.applicableServiceDetails)==null?void 0:i[0],s=(n==null?void 0:n.type)||t.applicableService;if(s==="HRA")return"/hra";if(s==="CONSULTATION"){if((n==null?void 0:n.mode)==="offline")return"/clinic-consultation";const r=((c=n==null?void 0:n.included)!=null?c:[]).find(m=>m&&m!=="all");return r?`/online-consultation/doctors?specialization=${encodeURIComponent(r)}&mode=online`:"/online-consultation"}return s==="OHC_CONSULTATION"?"/ohc-consultation":s==="PRESCRIBED_SERVICE"?"/prescription":s==="MEDICINE"?"/medicine":s==="VACCINE"?"/vaccine":s==="LAB"?"/labs":s==="AMBULANCE"||s==="IN_CITY_AMBULANCE"?"/ambulance":s==="GYM_MEMBERSHIP"?"/gym-membership":"/"},ws=t=>{const n=t.indexOf("(");return n===-1?[t.trim(),""]:[t.slice(0,n).trim(),t.slice(n).trim()]},Ss=({benefit:t,onMultiService:n})=>{var j,B,L,T,I,w,S,_;const s=R(),[i,c]=ws((j=t.name)!=null?j:""),d=((B=t.imageUrl)==null?void 0:B.web)||((L=t.imageUrl)==null?void 0:L.mobile),r=t.utilised||((I=(T=t.limits)==null?void 0:T.length)!=null?I:0)>0&&((S=(w=t.limits)==null?void 0:w[0])==null?void 0:S.available)===0,m=t.benefitType==="PREGNANCY"||!!t.pregnancyDeclaration,C=r||m,g=Object.entries((_=t.tags)!=null?_:{}),A=()=>{var o,u,x;if(C)return;const y=(o=t.applicableServiceDetails)!=null?o:[];if(y.length>1){n();return}const a=(x=(u=y[0])==null?void 0:u.customTarget)==null?void 0:x.webUrl;if(a){try{const l=new URL(a);s(l.pathname+l.search)}catch(l){window.open(a,"_self")}return}s(Fs(t))};return e.jsxs("div",{role:"button",tabIndex:0,onClick:A,onKeyDown:y=>y.key==="Enter"&&A(),className:`bg-white rounded-[16px] border border-[#DDEAFF] flex flex-col justify-between w-[242px] h-fit shrink-0 overflow-hidden ${C?"cursor-default":"cursor-pointer"}`,children:[e.jsxs("div",{className:"flex items-center gap-[10px] px-3 pt-3 flex-1",children:[d?e.jsx("img",{src:d,alt:"","aria-hidden":!0,className:"w-10 h-10 rounded-[10px] object-cover shrink-0"}):e.jsx("div",{className:"w-10 h-10 rounded-[10px] bg-[#EEF4FF] shrink-0"}),e.jsx("div",{className:"flex flex-col gap-[6px]",children:e.jsxs("p",{className:`text-[13px] font-bold leading-[20px] ${C?"text-[#828282]":"text-[#1A2642]"} m-0 overflow-hidden`,style:{display:"-webkit-box",WebkitLineClamp:2,WebkitBoxOrient:"vertical"},children:[i,c&&e.jsxs("span",{className:"text-[14px] font-normal text-[#8896A5]",children:[" ",c]})]})})]}),(g==null?void 0:g.length)>0?e.jsxs("div",{className:"flex items-center gap-[10px] px-3 flex-1",children:[e.jsx("div",{className:"w-10 h-10 rounded-[10px] object-cover shrink-0"}),g.length>0&&e.jsx("div",{className:"flex flex-wrap gap-[6px]",children:g.map(([y,a])=>e.jsx("span",{className:"text-[10px] font-semibold px-[8px] py-[3px] rounded-full w-fit",style:C?{backgroundColor:"#F0F0F0",color:"#8C8C8C"}:{backgroundColor:a.backgroundColor,color:a.textColor},children:y},y))})]}):e.jsx("div",{className:"h-4"}),C?e.jsx("div",{className:"flex items-center px-3 py-[8px]",style:{background:"#F0F0F0"},children:e.jsx("span",{className:"text-[13px] font-bold text-[#828282]",children:"Benefit Utilised"})}):e.jsxs("div",{className:"flex items-center justify-between px-3 py-[8px]",style:{background:"#F5F9FF"},children:[e.jsx("span",{className:"text-[13px] font-bold text-[#0E63FF]",children:"Use Benefit"}),e.jsx("span",{className:"w-5 h-5 rounded-full bg-[#DAEBFF] flex items-center justify-center text-[#0F67FE] shrink-0","aria-hidden":!0,children:"â"})]})]})},Ns=({section:t})=>{var c,d;const n=R(),s=((c=t.imageUrl)==null?void 0:c.web)||((d=t.imageUrl)==null?void 0:d.mobile),i=()=>n(ks(t.sectionIndex));return e.jsxs("div",{role:"button",tabIndex:0,onClick:i,onKeyDown:r=>r.key==="Enter"&&i(),className:"bg-white rounded-[16px] border border-[#DDEAFF] flex flex-col justify-between w-[242px] h-fit shrink-0 overflow-hidden cursor-pointer",children:[e.jsxs("div",{className:"flex items-center gap-[10px] px-3 pt-3 flex-1",children:[s?e.jsx("img",{src:s,alt:"","aria-hidden":!0,className:"w-10 h-10 rounded-[10px] object-cover shrink-0"}):e.jsx("div",{className:"w-10 h-10 rounded-[10px] bg-[#EEF4FF] shrink-0"}),e.jsx("div",{className:"flex flex-col gap-[6px]",children:e.jsx("p",{className:"text-[13px] font-bold leading-[20px] text-[#1A2642] m-0 overflow-hidden",children:t.name})})]}),e.jsx("div",{className:"h-4"}),e.jsxs("div",{className:"flex items-center justify-between px-3 py-[8px]",style:{background:"#F5F9FF"},children:[e.jsx("span",{className:"text-[13px] font-bold text-[#0E63FF]",children:t.cta||"View Details"}),e.jsx("span",{className:"w-5 h-5 rounded-full bg-[#DAEBFF] flex items-center justify-center text-[#0F67FE] shrink-0","aria-hidden":!0,
1children:"â"})]})]})},Q=()=>{},As=()=>{var I,w,S,_,y;const t=N(me),n=N(pe),{data:s,isLoading:i,isError:c}=jt({},{skip:!t}),d=R(),[r,m]=b.useState(null),g=((I=s==null?void 0:s.data)!=null?I:[])[0],A=(w=g==null?void 0:g.featuredSections)!=null?w:[],j=((S=g==null?void 0:g.benefitSections)!=null?S:[]).flatMap(a=>{var o,u;return(o=a.subSections)!=null&&o.length?a.subSections.flatMap(x=>{var l;return(l=x.benefits)!=null?l:[]}):(u=a.benefits)!=null?u:[]}),B=(()=>{var u;const a=(u=r==null?void 0:r.applicableServiceDetails)!=null?u:[],o=a.filter(x=>x.type==="GENERIC");return o.length>=2?o:a})(),L=!1,T=(y=(_=s==null?void 0:s.data)==null?void 0:_[0])==null?void 0:y.logoUrl;return i||c?null:e.jsxs(H,{sx:{padding:{xs:"1rem",md:"0 2.5rem"}},children:[e.jsxs("section",{className:"bg-[#EEF4FF] rounded-[16px] p-4 desktop:p-6 desktop:pb-1 desktop:m-0 mobile:m-3",children:[e.jsxs("div",{className:"hidden tablet:flex items-center justify-between gap-4 mb-5",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsxs("div",{className:"flex flex-col gap-[3px]",children:[e.jsx("h2",{className:"text-[20px] font-bold text-[#1A2642] m-0",children:"Your Benefits"}),L]}),e.jsx("div",{className:"shrink-0",children:e.jsx("img",{src:T,alt:"Company logo",className:"h-[55px] max-w-[140px] object-contain block"})})]}),e.jsx(De,{to:"/benefits",className:"shrink-0 bg-white border border-[#99C0FF] text-[#0E63FF] rounded-[8px] px-6 py-2 text-[14px] font-semibold no-underline hover:bg-[#F0F6FF] whitespace-nowrap",children:"Explore All Benefits"})]}),e.jsxs("div",{className:"tablet:hidden flex items-start justify-between gap-3 mb-4",children:[e.jsxs("div",{className:"flex flex-col gap-[3px]",children:[e.jsx("h2",{className:"text-[18px] font-bold text-[#1A2642] m-0",children:"Your Benefits"}),L]}),e.jsx("div",{className:"bg-white border border-[#DDEAFF] rounded-[10px] px-3 py-2 shrink-0",children:e.jsx("img",{src:T,alt:"Company logo",className:"h-[34px] max-w-[110px] object-contain block"})})]}),A.length>0?e.jsx(M,{sliderName:"benefits",childrenCss:{scrollSnapAlign:"start"},children:A.map((a,o)=>{var u,x;return e.jsx(Ns,{section:a},`${(u=a.sectionIndex)!=null?u:o}-${(x=a.name)!=null?x:""}`)})}):(j==null?void 0:j.length)>0&&e.jsx(M,{sliderName:"benefits",childrenCss:{scrollSnapAlign:"start"},children:j.map(a=>{var o;return e.jsx(Ss,{benefit:a,onMultiService:()=>m(a)},(o=a.id)!=null?o:a.name)})}),e.jsx("div",{className:"tablet:hidden mt-4",children:e.jsx(De,{to:"/benefits",className:"flex items-center justify-center w-full bg-white border border-[#0F67FE] text-[#0F67FE] rounded-[10px] py-3 text-[15px] font-semibold no-underline",children:"Explore All Benefits"})})]}),e.jsx(yt,{closeBtn:!0,drawerStatus:!!r,drawerClose:()=>m(null),children:e.jsxs("div",{className:"flex flex-col gap-[10px] p-5",children:[e.jsx("p",{className:"text-[18px] font-bold text-[#2D52E1] m-0 mb
1-4",children:"Services"}),e.jsx("div",{children:B.map(a=>{const o=a==null?void 0:a.mode,u=ps(Q,Q,Q,Q,d,n,Q,()=>m(null),null,a==null?void 0:a.customTarget,a==null?void 0:a.serviceSlug).find(h=>h.service===(a==null?void 0:a.type)),x=u==null?void 0:u.modes,l=(x==null?void 0:x[o])||(x==null?void 0:x.DEFAULT);return l?e.jsxs(xt.Fragment,{children:[e.jsxs("button",{type:"button",className:"flex items-center justify-between w-full py-[10px] bg-transparent border-none cursor-pointer",onClick:()=>{var h;l.handleClick((h=a==null?void 0:a.included)==null?void 0:h[0]),m(null)},children:[e.jsx("span",{className:"text-[14px] font-medium text-[#101828]",children:l==null?void 0:l.text}),e.jsx("img",{src:xs,className:"h-6 w-6",alt:"arrow"})]}),e.jsx("hr",{className:"m-0 border-[#EAEDF1]"})]},`${a.type}-${a.mode}`):null})})]})})]})},Rn=({services:t,setShowPrescriptionForm:n,serviceWidgetRef:s,setSelectedPrescriptionService:i})=>{var je,ye,Ce,ve,Ee,ke,Fe,we,Se,Ne,Ae,Le,Te,Pe,Ie,_e,Re,Be;const c=b.useRef(null),d=(ye=(je=window==null?void 0:window.location)==null?void 0:je.hash)==null?void 0:ye.substr(1),r=ht(),m=N(me),C=N(Ct),g=N(vt),A=N(Et),j=N(pe),B=N(kt),[L,T]=b.useState(!1),[I,w]=b.useState(!1),[S,_]=b.useState(null),{navigateToHome:y}=Ft(),a=!B,{data:o}=ls(),{data:u}=Ke(),{data:x}=wt(),{data:l}=St(null,{skip:!m}),h=(Ce=x==null?void 0:x.data)==null?void 0:Ce.find(p=>(p==null?void 0:p.key)==="company_id"),Xe=((Ee=(ve=h==null?void 0:h.config)==null?void 0:ve.services)==null?void 0:Ee.hideMenu)!==!0,he=((ke=h==null?void 0:h.config)==null?void 0:ke.enableHomeScreenBenefit)&&Number((we=(Fe=h==null?void 0:h.config)==null?void 0:Fe.benefitScreen)==null?void 0:we.version)===2,Ze=h!=null&&h.config&&(h==null?void 0:h.value)===(j==null?void 0:j.toString())?(Ae=(Ne=(Se=h==null?void 0:h.config)==null?void 0:Se.homeScreen)==null?void 0:Ne.sections)==null?void 0:Ae.find(p=>(p==null?void 0:p.type)==="CARD_COMPACT"):null,ue=!!((Le=u==null?void 0:u.data)!=null&&Le.isOHCEnabled),{data:v,isLoading:Je,isError:et,isSuccess:tt,isFetching:st}=Kt(g,{skip:!g}),{data:K,isLoading:nt,isSuccess:ge}=Nt({screen_id:2},{skip:!m}),ie=(Ie=(Pe=(Te=K==null?void 0:K.data)==null?void 0:Te.consent_details)==null?void 0:Pe[0])==null?void 0:Ie.consents,{data:fe}=At(void 0,{skip:m}),{data:W,isSuccess:be}=Lt(void 0,{skip:!m});b.useEffect(()=>{var p,$,G,V;if(l!=null&&l.data){const E=(p=l==null?void 0:l.data)==null?void 0:p.config,k=E==null?void 0:E.selfBookedFlow,q=E==null?void 0:E.vaccineSelfBookedFlow;r(Tt(($=E==null?void 0:E.pharmacyFlow)==null?void 0:$.enabled)),r(Pt((k==null?void 0:k.enabled)||!1)),r(It((q==null?void 0:q.enabled)||!1)),r(_t(((G=k==null?void 0:k.forUnverifiedProvider)==null?void 0:G.enabled)||!1)),r(Rt(((V=k==null?void 0:k.forUnverifiedProvider)==null?void 0:V.appointmentTimeBufferInMinutes)||0))}},[l==null?void 0:l.data]),b.useEffect(()=>{r(Bt(!1)),Ht(!1)},[]),b.useEffect(()=>{var p;be&&r(Ut((p=W==null?void 0:W.data)==null?void 0:p.newVideoFeature))},[be]),b.useEffect(()=>{_(m?W:fe)},[fe,W]),b.useEffect(()=>{ge&&(ie==null||ie.forEach(p=>{!p.user_consent&&C===Ge.PROFILE_FULLFILLED&&T(!0)}))},[C,ge,nt]),b.useEffect(()=>{const p=v==null?void 0:v.data;!p||Object.keys(p).length<=0||p.primaryText&&(w(!0),Ve(se.POP_UP_LOAD,{pop_up_name:"ahc"}))},[v==null?void 0:v.data,tt,st]),b.useEffect(()=>Ve(se.HOMEPAGE_PAGELOAD,{is_play_video_visible:A.playEnabled,is_ohc_card_visible:ue}),[m,A.playEnabled,ue]);const{healthTipsData:X,videosData:Z,musicData:J,eatRecipiesData:ee,podCastData:te}=b.useMemo(()=>{var $,G,V,E,k;const p=q=>{const O=q.slice();for(let D=O.length-1;D>0;D-=1){const He=Math.floor(Math.random()*(D+1));[O[D],O[He]]=[O[He],O[D]]}return O};return{healthTipsData:p(zt((($=o==null?void 0:o.data)==null?void 0:$.infographics)||[])),videosData:p(Yt(((G=o==null?void 0:o.data)==null?void 0:G.healthcare_videos)||[])),musicData:p(Qt(((V=o==null?void 0:o.data)==null?void 0:V.music)||[])),eatRecipiesData:p(Dt(((E=o==null?void 0:o.data)==null?void 0:E.recipes)||[])),podCastData:p(qt(((k=o==null?void 0:o.data)==null?void 0:k.podcast)||[]))}},[o==null?void 0:o.data]),rt=m&&C===Ge.PROFILE_FULLFILLED&&!et&&((_e=v==null?void 0:v.data)==null?void 0:_e.primaryText),ae=((Be=(Re=S==null?void 0:S.data)==null?void 0:Re.newVideoFeature)==null?void 0:Be.popUp)||!1;return b.useEffect(()=>{bs(c,d)},[d,c==null?void 0:c.current]),[Ot].includes(j)&&y(),e.jsxs(P,{gap:{xs:"2rem",md:"5rem"},marginBottom:"5rem",children:[m&&e.jsx(Mt,{privacyPolicyUrl:"/privacy-policy",lang:{title:"Cookie consent",description:"We use essential cookies to keep your account secure and ensure you stay logged in.",privacyPolicyUrl:"/privacy-policy",acceptAll:"I understand",essential:"Essential",required:"Required",saveSelection:null,privacyPolicyInfo:"For more information, please visit our",privacyPolicy:"Privacy Policy"}}),e.jsxs(P,{gap:"2.5rem",mb:{xs:"-1rem",md:"-2.5rem"},children:[j!==Wt&&e.jsx(f,{children:e.jsx(Xt,{showKyb:!he})}),he&&e.jsx(f,{children:e.jsx(As,{})}),e.jsx(f,{children:e.jsx(Qe,{position:Ye.HOME_TOP})}),Xe&&e.jsx(f,{children:e.jsx(F,{ref:s,children:e.jsx(Zt,{services:t})})})]}),e.jsx(f,{children:e.jsx(Jt,{})}),e.jsx(ms,{}),e.jsx(f,{children:e.jsx(Qe,{position:Ye.HOME_MIDDLE})}),e.jsx(f,{children:e.jsx(Es,{bgcolor:"themeBlue.extraLight"})}),e.jsx(F,{mb:{xs:"-1rem",md:"-2.5rem"},children:e.jsx(f,{children:e.jsx(es,{CardCompactItems:Ze||{},setShowPrescriptionForm:n,setSelectedPrescriptionService:i})})}),a&&e.jsx(f,{children:e.jsx(ts,{})}),e.jsx(f,{children:e.jsx(ss,{})}),e.jsx(f,{children:e.jsx(ns,{})}),(X==null?void 0:X.length)&&e.jsx(f,{children:e.jsx("div",{ref:c,children:e.jsx(us,{healthTipsData:X})},"health-tips")}),Z!=null&&Z.length?e.jsx(f,{children:e.jsx(gs,{videosData:Z})}):null,J!=null&&J.length?e.jsx(f,{children:e.jsx(rs,{musicData:J})}):null,ee!=null&&ee.length?e.jsx(f,{children:e.jsx(fs,{recipeData:ee})}):null,te!=null&&te.length?e.jsx(f,{children:e.jsx(is,{podCastData:te})}):null,rt&&!(ae!=null&&ae.enabled)&&e.jsx(pt,{open:I,onClose:()=>w(!1),children:e.jsx(as,{data:v==null?void 0:v.data,isLoading:Je,setClosePopup:w,sx:{display:"flex",justifyContent:"center",alignItems:"center",height:"100%",overflow:"hidden"}})}),e.jsx($t,{closeBtn:!1,drawerStatus:L,drawerClose:()=>{},minWidth:"376px",styles:{},enableClose:!0,customCloseBtnComponent:null,enableCustomCloseBtn:!1,children:e.jsx(os,{consent:K,setShowConsentPopup:T})})]})};export{Rn as default};
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.