"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[942],{66122:function(e,t,a){a.d(t,{U:function(){return i}});var r=a(10265);let i={[r.JJ.PreEligibility]:"pre_eligibility",[r.JJ.ContactDetails]:"contact_details",[r.JJ.InsuranceDetails]:"insurance_details",[r.JJ.InsuranceDetailsReview]:"insurance_details_review",[r.JJ.ApplicationReview]:"application_review",[r.JJ.ApplicationComplete]:"application_complete",[r.JJ.EligibilityUnmet]:"eligibility_unmet",[r.JJ.ApplicationDetected]:"account_already_exists",[r.JJ.EmailVerification]:"otp_code",[r.JJ.OnboardingChecklist]:"welcome",[r.JJ.ReviewConsents]:"agree_to_receive_care",[r.JJ.CreatePassword]:"create_password",[r.JJ.AppDownload]:"download_the_app",[r.JJ.RequestLabs]:"request_labs",[r.JJ.SubmitLabs]:"submit_labs",closeWorkflowEvent:"eligibility_signup_closed",openPartnerSelectorEvent:"partner_selector_opened",closeWorkflowConfirmationEvent:"eligibility_signup_cancel_confirmation_screen",abortCloseWorkflow:"eligibility_signup_cancel_aborted",phoneNumberClicked:"contact_phone_clicked",editEmail:"edit_email",patientConsent:"patient_consent",declinePatientConsent:"decline_patient_consent"}},11841:function(e,t,a){a.d(t,{x:function(){return passwordChange}});var r,i=a(35697);(r||(r={})).PASSWORD_CHANGE="passwordChange";let passwordChange=async(e,t)=>{let a={action:r.PASSWORD_CHANGE,createPassword:!0,token:e,value:t};return i.Z.post("/api/authmanagement",a)}},91372:function(e,t,a){a.d(t,{t:function(){return requestOtp}});var r=a(35697);let requestOtp=async e=>{let t=await r.Z.post("/api/auth/request-otp",e);return t}},60948:function(e,t,a){a.d(t,{M:function(){return verifyOtp}});var r=a(35697);let verifyOtp=async e=>{let t=await r.Z.post("/api/auth/verify-otp",e);return t}},35697:function(e,t,a){a.d(t,{Z:function(){return n}});var r=a(5121);let i=r.Z.create({timeout:18e4});var n=i},1943:function(e,t,a){a.d(t,{o:function(){return checkBenefits}});var r=a(35697),i=a(24076);let n={name:"Flyte Medical",npi:"1992372403"},serializeBenefitsCheck=e=>{let{payerCode:t,firstName:a,lastName:r,birthdate:o,insuranceMemberID:s,provider:l}=e;return{payer:{payerCode:t},patient:{firstName:a,lastName:r,dateOfBirth:(0,i.f)(o),memberId:s},provider:l||n}},checkBenefits=async e=>{let t=serializeBenefitsCheck(e),a=await r.Z.post("/api/benefits/check",t);return a}},21097:function(e,t,a){a.d(t,{J:function(){return getConsents}});var r=a(35697);let getConsents=async()=>{let e=await r.Z.get("/api/consents");return e}},54285:function(e,t,a){a.d(t,{rE:function(){return createContact},Tk:function(){return updateContact}});var r=a(35697),i=a(24076),n=a(50574),o=a(91736),s=a(69834);let l="/api/contact",serializeContact=e=>{let{birthdate:t,currentWeightInPounds:a,highestWeightInPounds:r,dateOfHighestWeightValue:l,heightInFoot:c,heightInInch:d,phone:S,insuranceCoverage:u,insuranceMemberID:C,state:m,howDidYouFindUS:p,firstName:h,lastName:g,ssn:x,benefitsCheck:b,eligibilityVerifiedBy:y,...H}=e;return{...H,birthdate:(0,i.f)(t),currentWeightInPounds:(0,n.M)(a),highestWeightInPounds:(0,n.M)(r),dateOfHighestWeightValue:"".concat(l,"-01-01"),heightInFoot:(0,n.M)(c),...d&&{heightInInch:(0,n.M)(d)},...C&&{insuranceMemberID:C},...S&&{phone:(0,s.X)(S)},...p&&{howDidYouFindUS:p},...h&&{firstName:h},...g&&{lastName:g},...m&&{state:m},...b&&{...(0,o.D)(b)},...y&&{eligibilityVerifiedBy:y}}},createContact=async e=>{let t=serializeContact(e),a=await r.Z.post(l,t);return a.data},updateContact=async e=>{let t=await r.Z.put(l,e);return t.data}},33546:function(e,t,a){a.d(t,{m:function(){return checkEligibility}});var r=a(35697),i=a(24076);let serializeEligibilityCheck=e=>{let{firstName:t,lastName:a,birthdate:r,insuranceMemberID:n,insurance:o,benefitProgram:s}=e;return{firstName:t,lastName:a,dateOfBirth:(0,i.f)(r),memberId:n,insurer:o,employerProgram:s}},checkEligibility=async e=>{let t=serializeEligibilityCheck(e),a=await r.Z.post("/api/eligibility/check",t);return a}},34474:function(e,t,a){a.d(t,{D:function(){return createFlyteUser}});var r=a(35697);let convertFeetToInches=e=>12*e;var i=a(50574),n=a(56401),o=a(24076);let s={coding:[{system:"http://terminology.hl7.org/CodeSystem/observation-category",code:"vital-signs",display:"Vital Signs"}],text:"Vital Signs"},l={coding:[{system:"http://snomed.info/sct",code:"733985002",display:"Reported (qualifier value)"}],text:"Reported"},c={LOINC:"http://loinc.org",UNITS_OF_MEASURE:"http://unitsofmeasure.org",CONSENT_SCOPE:"http://terminology.hl7.org/CodeSystem/consentscope",CONSENT_ACTION:"http://terminology.hl7.org/CodeSystem/consentaction",IDENTIFIER_TYPE:"http://terminology.hl7.org/CodeSystem/v2-0203",PATIENT_IDENTIFIER:"https://intellihealth.salesforce.com/contacts/"},d={HEIGHT:"http://hl7.org/fhir/us/vitals/StructureDefinition/height",BODY_WEIGHT:"http://hl7.org/fhir/us/vitals/StructureDefinition/body-weight"},createPatientResource=(e,t)=>({resourceType:"Patient",identifier:[{use:"secondary",system:c.PATIENT_IDENTIFIER,value:t,period:{start:new Date().toISOString()}}],name:[{family:e.lastName,given:e.firstName}],telecom:[{system:"phone",value:e.phone,use:"home"},{system:"email",value:e.email},{system:"sms",value:e.phone}],birthDate:(0,o.f)(e.birthDate),address:[{use:"home",type:"both",text:e.addressText||"",line:e.addressLines||[],city:e.city||"",state:e.state,postalCode:e.postalCode||""}],extension:[{url:"http://hl7.org/fhir/StructureDefinition/timezone",valueString:Intl.DateTimeFormat().resolvedOptions().timeZone}]}),createObservationResource=(e,t,a,r,i,n,o)=>({resourceType:"Observation",id:e,meta:{profile:["weight"===e?d.BODY_WEIGHT:d.HEIGHT]},status:"preliminary",category:[s],code:{coding:[{system:c.LOINC,code:r,display:i}]},subject:{type:"Patient",identifier:{use:"secondary",system:c.PATIENT_IDENTIFIER,value:n,period:{start:o}}},effectiveDateTime:o,valueQuantity:{value:t,unit:a,system:c.UNITS_OF_MEASURE,code:a},method:l}),createOrganizationResource=e=>({resourceType:"Organization",name:e.evolveOrganization||n.bV.Flyte,...e.participantDepartmentorOrg&&{contained:[{resourceType:"Organization",name:e.participantDepartmentorOrg}]}}),createDecision=e=>e?"permit":"deny",createConsentResources=e=>e.map(e=>({resource:{resourceType:"Consent",identifier:{use:"official",type:{coding:[{system:c.IDENTIFIER_TYPE,code:"FILL",display:"Filler Identifier"}],text:"An identifier issued by FlyeHealth."},value:e.formType},status:"active",scope:{coding:[{system:c.CONSENT_SCOPE,code:"patient-privacy"}]},category:[{coding:[{system:c.LOINC,code:"59284-0"}]}],provision:[{action:[{coding:[{system:c.CONSENT_ACTION,code:"disclose"}]}],period:{start:new Date().toISOString(),end:new Date(new Date().getTime()+31536e6).toISOString()}}],decision:createDecision(e.isAccepted)}})),serializeFhirData=e=>{let t=new Date().toISOString(),a=(0,i.M)(e.heightInFeet),r=(0,i.M)(e.heightInInch),n=r+convertFeetToInches(a),o={resourceType:"Bundle",identifier:{use:"temp",value:"onboarding-bundle"},type:"collection",timestamp:t,entry:[{resource:createPatientResource(e,e.patientIdentifier)},{resource:createObservationResource("height",n,"[in_i]","8302-2","Body height",e.patientIdentifier,t)},{resource:createObservationResource("weight",(0,i.M)(e.currentWeightInPounds),"[lb_av]","29463-7","Body weight",e.patientIdentifier,t)},{resource:createOrganizationResource(e)},...createConsentResources(e.consents)]};return o},createFlyteUser=async e=>{let t=serializeFhirData(e),a=await r.Z.post("/api/fhir/onboard",t);return a}},64267:function(e,t,a){a.d(t,{$:function(){return createLead}});var r=a(35697),i=a(13064),n=a(91736),o=a(69834);let serializeLead=e=>{let{birthdate:t,currentWeightInPounds:a,highestWeightInPounds:r,dateOfHighestWeightValue:s,heightInFoot:l,heightInInch:c,phone:d,insuranceCoverage:S,insuranceMemberID:u,state:C,benefitProgram:m,howDidYouFindUS:p,firstName:h,lastName:g,ssn:x,benefitsCheck:b,eligibilityVerifiedBy:y,insuranceOther:H,...f}=e;return{...f,birthdate:(0,i.f1)(t),currentWeightInPounds:(0,i.MC)(a),highestWeightInPounds:(0,i.MC)(r),dateOfHighestWeightValue:"".concat(s,"-01-01"),heightInFoot:(0,i.MC)(l),...c&&{heightInInch:(0,i.MC)(c)},...u&&{insuranceMemberID:u},...d&&{phone:(0,o.X)(d)},...p&&{howDidYouFindUS:p},...h&&{firstName:h},...g&&{lastName:g},...C&&{state:C},...b&&{...(0,n.D)(b)},...y&&{eligibilityVerifiedBy:y},...H&&{insuranceProviderName:H}}},createLead=async e=>{let t=serializeLead(e),a=await r.Z.post("/api/lead",t);return a}},44761:function(e,t,a){a.d(t,{B:function(){return AppDownload}});var r=a(85893),i=a(71986),n=a(58976),o=a(73857),s=a(84862),l=a(70908);let AppDownloadMobileFooter=e=>{let{image:t}=e;return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(i.Flex,{justifyContent:"center",width:"100%",pb:{base:"spacer-24",lg:0},children:t?null:(0,r.jsx)(i.Image,{alt:"Application Complete",src:"/static/assets/application-download.png",width:{base:"200px",md:"254px"},height:{base:"200px",md:"254px"}})}),(0,r.jsx)(n.D2,{children:(0,r.jsx)(i.Link,{variant:"primary",size:"m",justifyContent:"center",width:"100%","aria-label":"Download the app",target:"_blank",href:"/api/app-download",children:"Download the app"})})]})},AppDownload=e=>{let{title:t,checklist:a,subTitle:n,image:c}=e,d=(0,s.d)();return(0,r.jsxs)(o.D,{gap:{base:"spacer-10",lg:"spacer-16",xl:"spacer-18",xxl:"spacer-64"},alignItems:"start",flexDirection:{base:"column",lg:"row"},"data-test":l.J.AppDownload,children:[(0,r.jsxs)(i.Flex,{direction:"column",justifyContent:{lg:"space-between"},height:"100%",flex:1,children:[t,n,c]}),d?(0,r.jsx)(AppDownloadMobileFooter,{image:c}):(0,r.jsxs)(i.Flex,{flexDirection:"column",gap:"spacer-9",flex:1,children:[(0,r.jsx)(i.Text,{variant:"text-body-regular",fontWeight:"700",children:"Get Started by downloading the FlyteHealth app"}),a,(0,r.jsx)(i.Flex,{width:"100%",backgroundColor:"background-page-04",justifyContent:"center",padding:"spacer-5",borderRadius:"radii-2",children:(0,r.jsx)(i.Image,{alt:"QR application download",width:"200px",height:"200px",src:"/static/assets/app-qr-download.png"})})]})]})}},33640:function(e,t,a){a.d(t,{J:function(){return ApplicationComplete}});var r=a(85893),i=a(71986),n=a(73857),o=a(44943),s=a(84862),l=a(70908),c=a(25675),d=a.n(c);let ApplicationComplete=e=>{let{title:t,email:a,description:c}=e,S=(0,s.d)();return(0,r.jsxs)(n.D,{gap:{lg:"spacer-16",xl:"spacer-18",xxl:"spacer-64"},alignItems:"start","data-test":l.J.ApplicationComplete,children:[(0,r.jsxs)(i.Flex,{direction:"column",justifyContent:{lg:"space-between"},height:"100%",children:[(0,r.jsxs)(i.Box,{children:[t,(0,r.jsx)(i.Box,{backgroundColor:"background-container-active",px:"spacer-7",py:"spacer-6",borderRadius:"radii-2",mt:"spacer-7",display:{base:"block",lg:"inline-block"},children:(0,r.jsx)(i.Text,{variant:"text-header-M",children:a})}),c]}),(0,r.jsxs)(i.Box,{children:[(0,r.jsx)(i.Text,{mt:"spacer-16",color:"text-secondary",variant:"text-body-bold",children:"Need some help?"}),(0,r.jsxs)(i.Text,{color:"text-secondary",variant:"text-body-regular",mt:"spacer-1",children:["Please call"," ",(0,r.jsx)(o.R,{fontWeight:"thin"})," ","to speak with a Care Coordinator."]})]})]}),!S&&(0,r.jsx)(d(),{alt:"Application Complete",width:340,height:340,src:"/static/assets/application-complete.png"})]})}},65660:function(e,t,a){a.d(t,{v:function(){return ApplicationDetected}});var r=a(85893),i=a(71986),n=a(73857),o=a(44943),s=a(84862),l=a(70908),c=a(25675),d=a.n(c);let ApplicationDetected=e=>{let{title:t,email:a,description:c}=e,S=(0,s.d)();return(0,r.jsxs)(n.D,{gap:{lg:"spacer-16",xl:"spacer-18",xxl:"spacer-64"},alignItems:"start","data-test":l.J.ApplicationDetected,children:[(0,r.jsxs)(i.Flex,{direction:"column",justifyContent:{lg:"space-between"},height:"100%",children:[(0,r.jsxs)(i.Flex,{gap:"spacer-6",direction:"column",children:[t,(0,r.jsx)(i.Box,{alignSelf:{lg:"start"},backgroundColor:"background-container-active",px:"spacer-7",py:"spacer-6",borderRadius:"radii-2",display:{base:"block",lg:"inline-block"},children:(0,r.jsx)(i.Text,{variant:"text-header-M",children:a})}),c]}),(0,r.jsxs)(o.R,{mt:"spacer-7",size:"l",leadingIcon:(0,r.jsx)(i.IconPhone,{}),"aria-label":"Contact Us",variant:"primary-alt",isInline:!1,justifyContent:"center",alignSelf:"start",children:["Call"," ",o._.formatted]})]}),!S&&(0,r.jsx)(d(),{alt:"Application Detected",width:340,height:340,src:"/static/assets/application-detected.png"})]})}},20410:function(e,t,a){a.d(t,{G:function(){return ApplicationReview}});var r=a(85893),i=a(71986),n=a(73857),o=a(44943),s=a(84862),l=a(70908),c=a(25675),d=a.n(c);let ApplicationReview=e=>{let{title:t,note:a}=e,c=(0,s.d)();return(0,r.jsxs)(n.D,{gap:{lg:"spacer-16",xl:"spacer-18",xxl:"spacer-64"},alignItems:"start","data-test":l.J.ApplicationReview,children:[(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-7",children:[t,(0,r.jsxs)(o.R,{size:"l",leadingIcon:(0,r.jsx)(i.IconPhone,{}),"aria-label":"Contact Us",variant:"primary-alt",isInline:!1,justifyContent:"center",alignSelf:"start",children:["Call"," ",o._.formatted]}),a]}),!c&&(0,r.jsx)(d(),{alt:"Application Review",width:340,height:340,src:"/static/assets/application-review.png"})]})}},30624:function(e,t,a){a.d(t,{E:function(){return DynamicStepGuide}});var r=a(85893),i=a(71986),n=a(84862),o=a(67294);let DynamicStepGuide=e=>{let{steps:t,currentStep:a}=e,s=(0,n.d)(),l=t.length,c=t.findIndex(e=>e.label===a),{activeStep:d,setActiveStep:S}=(0,i.useSteps)({index:c,count:l});return((0,o.useEffect)(()=>{-1!==c&&S(c)},[c,S]),-1===c)?null:s?(0,r.jsx)(i.ProgressBar,{value:(d+1)/l*100,size:"xs",position:"absolute",left:0,right:0,bottom:0}):(0,r.jsx)(i.Stepper,{index:d,maxWidth:{base:"21rem",xl:"25rem",xxl:"33rem"},width:"100%",children:t.map((e,t)=>{let a=(0,r.jsx)(e.icon,{"data-testid":"".concat(e.label,"-icon"),size:"m"});return(0,r.jsxs)(i.Stepper.Step,{flexDirection:"column",_horizontal:{alignItems:"start"},gap:"spacer-2",children:[(0,r.jsxs)(i.Flex,{width:"100%",alignItems:"center",children:[(0,r.jsx)(i.Tooltip,{label:e.label,placement:"bottom",display:{base:"block",xxl:"none"},children:(0,r.jsx)(i.Box,{children:(0,r.jsx)(i.Stepper.Step.Indicator,{boxSize:"1.75rem",children:(0,r.jsx)(i.Stepper.Step.Status,{complete:(0,o.cloneElement)(a,{color:"text-light"}),incomplete:(0,o.cloneElement)(a,{color:"background-static"}),active:(0,o.cloneElement)(a,{color:"primary-default"})})})})}),(0,r.jsx)(i.Stepper.Step.Separator,{})]}),(0,r.jsx)(i.Stepper.Step.Title,{display:{base:"none",xxl:"block"},variant:"text-body-floating-label-bold",color:t<=d?"text-primary":"text-disabled",textTransform:{base:"none",xxl:"uppercase"},children:e.label})]},e.label)})})}},38098:function(e,t,a){a.d(t,{x:function(){return r}});let r={email:{pattern:"Enter a valid email address",maxLength:"Email must be less than 150 characters"},phone:{validate:"Enter a valid phone number"},birthdate:{isValid:"Enter a valid date of birth using the format MM/DD/YYYY",isOver18YearsOld:"To be eligible, you must be at least 18 years old",isLessThan150YearsOld:"Enter a valid date of birth using the format MM/DD/YYYY"},currentWeightInPounds:{validate:"Weight must be a number between 1 and 999"},heightInFoot:{validate:"Height (ft) must be a number between 4 and 7"},heightInInch:{validate:"Height (in) must be a number between 0 and 11"},highestWeightInPounds:{isValid:"Weight must be a number between 1 and 999",isLowerThanCurrentWeight:"Weight must be higher than current weight"},dateOfHighestWeightValue:{min:"Enter a year that is after your birth year",pattern:"Enter a year using the format (YYYY)",max:"Enter a year that is not in the future"},ssn:{minLength:"Enter the last 4 digits of your SSN",maxLength:"Enter the last 4 digits of your SSN"}}},58976:function(e,t,a){a.d(t,{AM:function(){return l},s8:function(){return EmailField},VO:function(){return ErrorFormMessage},iQ:function(){return m},lm:function(){return p},Fl:function(){return h},D2:function(){return MobileFormFooter},dO:function(){return NameFields},sb:function(){return b},ed:function(){return y.e},CZ:function(){return H},pm:function(){return s},Fp:function(){return y.F}});var r=a(85893),i=a(71986),n=a(13176),o=a(67294);let s={isValid:e=>10===e.length,isOver18YearsOld:e=>{let t=(0,n.F)(e);return t>=18},isLessThan150YearsOld:e=>{let t=(0,n.F)(e);return t<150}},l=(0,o.forwardRef)((e,t)=>(0,r.jsx)(i.DateInput,{placeholder:"mm/dd/yyyy",inputMode:"numeric",mode:"mm/dd/yyyy",size:"l",variant:"flushed",ref:t,"data-test":"birthdate",...e}));var c=a(38098),d=a(36045),S=a(87536);let u="email",EmailField=e=>{let{name:t=u,label:a="Email address",inputProps:n,...o}=e,{register:s,setValue:l,formState:{errors:C}}=(0,S.Gc)(),m=(0,d.T)(t,C,["maxLength","pattern"]);return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...o,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:t,children:a}),(0,r.jsx)(i.Input,{"data-test":t,autoComplete:"email",placeholder:"name@email.com",inputMode:"email",type:"email",id:t,size:"l",variant:"flushed",isInvalid:m,...n,...s(t,{required:!0,onChange:e=>{var a;l(t,null===(a=e.target.value)||void 0===a?void 0:a.toLowerCase())},pattern:{value:/^[\w.+-]+@[a-z0-9.-]+\.[a-z]{2,150}$/i,message:c.x[u].pattern},maxLength:{value:150,message:c.x[u].maxLength}})}),m&&(0,r.jsx)(ErrorFormMessage,{errors:C,name:t})]})};var C=a(32866);let ErrorFormMessage=e=>{let{errors:t,name:a}=e;return(0,r.jsx)(C.B,{errors:t,name:a,render:e=>{let{message:t}=e;return(0,r.jsxs)(i.InlineAlert,{status:"error",children:[(0,r.jsx)(i.InlineAlert.Icon,{}),(0,r.jsx)(i.InlineAlert.Message,{children:t})]})}})},m=(0,o.forwardRef)((e,t)=>(0,r.jsx)(i.Input,{autoComplete:"given-name","aria-label":"Legal First name",placeholder:"Legal First name",type:"text",size:"l",variant:"flushed",ref:t,...e})),p=(0,o.forwardRef)((e,t)=>{let{unit:a,...n}=e;return(0,r.jsx)(i.MaskInput,{"aria-label":"Height (".concat(a,")"),placeholder:"Height (".concat(a,")"),inputMode:"numeric",size:"l",variant:"flushed",maskOptions:{mask:/^\d*$/,postfix:" (".concat(a,")")},ref:t,...n})});a(68701);let h=(0,o.forwardRef)((e,t)=>(0,r.jsx)(i.Input,{autoComplete:"family-name","aria-label":"Legal Last name",placeholder:"Legal Last name",type:"text",size:"l",variant:"flushed",ref:t,...e})),MobileFormFooter=e=>{let{children:t,...a}=e;return(0,r.jsx)(i.Flex,{position:"fixed",bottom:0,left:0,right:0,role:"contentinfo",px:"spacer-6",py:"spacer-4",background:"background-page",borderTop:"1px",borderColor:"ui-element-divider",borderStyle:"solid",zIndex:1,...a,"data-testid":"mobile-footer",children:t})},g="firstName",x="lastName",NameFields=e=>{let{isDisabled:t}=e,{register:a}=(0,S.Gc)();return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",children:[(0,r.jsxs)(i.Box,{children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",children:"Tell us about yourself"}),(0,r.jsx)(i.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Please enter your full legal name as on your ID or medical insurance."})]}),(0,r.jsxs)(i.Flex,{gap:{base:"spacer-4",md:"spacer-8"},children:[(0,r.jsx)(m,{"data-test":g,id:g,isDisabled:t,...a(g,{required:!0})}),(0,r.jsx)(h,{"data-test":x,id:x,isDisabled:t,...a(x,{required:!0})})]})]})},b=(0,o.forwardRef)((e,t)=>(0,r.jsx)(i.PhoneInput,{autoComplete:"tel-national",inputMode:"numeric",maskOptions:{countryIsoCode:"US",mask:["(",/\d/,/\d/,/\d/,")"," ",/\d/,/\d/,/\d/,"-",/\d/,/\d/,/\d/,/\d/]},placeholder:"(000) 000-0000",size:"l",variant:"flushed",ref:t,...e}));var y=a(47886);let H=(0,o.forwardRef)((e,t)=>(0,r.jsx)(i.MaskInput,{"aria-label":"Weight (lbs)",placeholder:"Weight (lbs)",inputMode:"decimal",size:"l",variant:"flushed",maskOptions:{mask:/^\d{0,3}(\.\d{0,2})?$/,postfix:" (lbs)"},ref:t,...e}))},68701:function(e,t,a){a.d(t,{o:function(){return s}});var r=a(85893),i=a(71986),n=a(67294);let o={mask:/^[a-z0-9]*$/i},s=(0,n.forwardRef)((e,t)=>{let{inputMode:a="text",placeholder:n="Insurance Member ID",maskOptions:s=o,...l}=e;return(0,r.jsx)(i.MaskInput,{type:"text",inputMode:a,size:"l",placeholder:n,variant:"flushed",maskOptions:s,ref:t,...l})})},41240:function(e,t,a){a.d(t,{D:function(){return s}});var r=a(85893),i=a(71986),n=a(67294),o=a(87536);let s=(0,n.forwardRef)((e,t)=>{let{name:a,"aria-label":s,...l}=e,c=(0,n.useRef)(null),d=(0,i.useMergeRefs)(c,t),{watch:S}=(0,o.Gc)(),u=S(a),C=u===l.value;return(0,r.jsx)(i.Flex,{as:"label","aria-label":s,flex:"1",onClick:()=>{var e;return null===(e=c.current)||void 0===e?void 0:e.click()},onKeyDown:e=>{if(" "===e.key||"Enter"===e.key){var t;e.preventDefault(),null===(t=c.current)||void 0===t||t.click()}},tabIndex:0,p:"spacer-3",borderWidth:"1px",borderRadius:"radii-2",cursor:"pointer",_hover:{bg:"background-action-hover"},_focusVisible:{outlineColor:"primary-focus",outlineWidth:"3px"},borderColor:C?"primary-default":"ui-element-outline-default",children:(0,r.jsx)(i.Box,{pointerEvents:"none",children:(0,r.jsx)(i.Radio,{ref:d,_focus:{boxShadow:"none"},...l})})})})},46899:function(e,t,a){a.d(t,{T:function(){return o}});var r=a(85893),i=a(71986),n=a(67294);let o=(0,n.forwardRef)((e,t)=>{let{isDisabled:a,...o}=e,[s,l]=(0,n.useState)(!1),c=s?i.IconEyeOff:i.IconEye;return(0,r.jsx)(i.MaskInput,{type:s?"text":"password",inputMode:"numeric",maskOptions:{mask:[/\d/,/\d/,/\d/,/\d/]},placeholder:"SSN last 4 digits",size:"l",variant:"flushed",ref:t,isDisabled:a,trailingIcon:(0,r.jsx)(i.Box,{userSelect:"none",children:(0,r.jsx)(c,{onClick:()=>{a||l(e=>!e)},cursor:a?"not-allowed":"pointer"})}),...o})})},47886:function(e,t,a){a.d(t,{e:function(){return l},F:function(){return s}});var r=a(85893),i=a(71986),n=a(56401),o=a(67294);let s=Object.entries(n.i$).map(e=>{let[t,a]=e;return{fullName:t,shortCode:a}}),l=(0,o.forwardRef)((e,t)=>{let{options:a=s,...n}=e;return(0,r.jsx)(i.Select,{size:"l",variant:"flushed",placeholder:"Select",ref:t,...n,children:a.map(e=>{let{fullName:t,shortCode:a}=e;return(0,r.jsx)("option",{value:a,children:t},a)})})})},29733:function(e,t,a){a.d(t,{Eg:function(){return FullModalLayout}});var r=a(85893),i=a(71986),n=a(67294),o=a(93103);let FullModalLayoutContextError=class FullModalLayoutContextError extends o.s{constructor(e="useFullModalLayoutContext must be used within a FullModalLayoutProvider"){super(e,"FULL_MODAL_CONTEXT_ERROR")}};let s=(0,n.createContext)({onClose:()=>{}}),useFullModalLayoutContext=()=>{let e=(0,n.useContext)(s);if(!e)throw new FullModalLayoutContextError;return e},FullModalLayout=e=>{let{isOpen:t,onClose:a,children:o}=e,l=n.useMemo(()=>({onClose:a}),[a]);return(0,r.jsx)(s.Provider,{value:l,children:(0,r.jsx)(i.Modal,{isOpen:t,onClose:a,size:"full",autoFocus:!1,children:(0,r.jsx)(i.Modal.Content,{p:0,backgroundColor:"background-page",height:"100%",containerProps:{overflow:"hidden"},motionProps:{initial:{opacity:1},animate:{opacity:1}},children:o})})})};FullModalLayout.Header=e=>{let{children:t}=e,{onClose:a}=useFullModalLayoutContext();return(0,r.jsx)(i.Modal.Header,{backgroundColor:"background-page",borderBottomColor:"ui-element-divider",borderBottomWidth:"1px",borderBottomStyle:"solid",borderRadius:"radius-0",p:0,position:{base:"fixed",lg:"relative"},width:"100%",zIndex:"2",children:(0,r.jsxs)(i.Flex,{alignItems:"center",justifyContent:"space-between",maxWidth:"90rem",px:{base:"spacer-6",md:"spacer-9",lg:"spacer-7",xl:"spacer-20",xxl:"spacer-28"},py:{base:"spacer-2",lg:"spacer-4"},width:"100%",margin:"0 auto",children:[t,(0,r.jsx)(i.ButtonIcon,{variant:"ghost","aria-label":"Close",size:"l",icon:(0,r.jsx)(i.IconX,{}),onClick:a})]})})},FullModalLayout.Body=e=>{let{children:t,...a}=e;return(0,r.jsx)(i.Modal.Body,{p:0,backgroundColor:"background-page",display:"flex",mt:{base:"4.25rem",lg:0},mx:"auto",overflow:"auto",borderRadius:"none",width:"100%",...a,children:(0,r.jsx)(i.Fade,{in:!0,style:{width:"100%"},transition:{enter:{duration:.4}},children:t})})}},73857:function(e,t,a){a.d(t,{D:function(){return ContentLayout},S:function(){return n.S}});var r=a(85893),i=a(71986);let ContentLayout=e=>(0,r.jsx)(i.Flex,{px:{base:"spacer-6",md:"spacer-9",lg:"spacer-14",xl:"spacer-20",xxl:"spacer-28"},py:{base:"spacer-5",lg:"spacer-12"},maxWidth:"90rem",marginY:"0",marginX:"auto",...e});var n=a(89233)},89233:function(e,t,a){a.d(t,{S:function(){return SplitFormLayout}});var r=a(85893),i=a(71986),n=a(73857);let SplitFormLayout=e=>(0,r.jsx)(n.D,{direction:{base:"column",lg:"row"},gap:{base:"spacer-10",lg:"spacer-16",xl:"spacer-28",xxl:"spacer-44"},...e});SplitFormLayout.Side=e=>(0,r.jsx)(i.Flex,{direction:"column",gap:{base:"spacer-6",lg:"spacer-8"},flex:1,...e}),SplitFormLayout.Form=e=>(0,r.jsx)(i.Flex,{direction:"column",gap:"spacer-9",flex:1,...e})},31540:function(e,t,a){a.d(t,{E:function(){return PartnerLogo},Z:function(){return l}});var r=a(85893),i=a(84862),n=a(56401),o=a(25675),s=a.n(o);a(67294);let l={[n.kT.Flyte]:"/static/assets/programs/flyte/flyte-logo.png",[n.kT.CareCompass]:"/static/assets/programs/care-compass/care-compass-logo.png",[n.kT.PequotHealthCare]:"/static/assets/programs/pequot/pequot-logo.png",[n.kT.RiverSpringLiving]:"/static/assets/programs/riverspring/riverspring-logo.png",[n.kT.Aetna]:"/static/assets/programs/aetna/aetna-logo.png",[n.kT.PyleFamilyInsurance]:"/static/assets/programs/pyle/pyle-logo.png",[n.kT.MDSave]:"/static/assets/programs/mdsave/mdsave-logo.png",[n.kT.ChristianaCare]:"/static/assets/programs/christiana-care/christiana-care-logo.png",[n.kT.Emory]:"/static/assets/programs/emory/emory-logo.png",[n.kT.KaiserPermanente]:"/static/assets/kaiser-logo.png",[n.kT.Sone]:"/static/assets/sone-logo.png",[n.kT["1199SEIU"]]:"/static/assets/programs/seiu/seiu-logo.png"},c={[n.kT.Flyte]:{width:{base:95,lg:99},height:{base:27,lg:28}},[n.kT.CareCompass]:{width:{base:44,lg:44},height:{base:44,lg:44}},[n.kT.Aetna]:{width:{base:111,lg:143},height:{base:28,lg:36}},[n.kT.RiverSpringLiving]:{width:{base:184,lg:184},height:{base:23,lg:23}},[n.kT.PequotHealthCare]:{width:{base:103,lg:103},height:{base:40,lg:40}},[n.kT.PyleFamilyInsurance]:{width:{base:118,lg:118},height:{base:36,lg:36}},[n.kT.MDSave]:{width:{base:44,lg:44},height:{base:44,lg:44}},[n.kT.ChristianaCare]:{width:{base:169,lg:169},height:{base:32,lg:32}},[n.kT.Emory]:{width:{base:101,lg:101},height:{base:22,lg:22}},[n.kT["1199SEIU"]]:{width:{base:200,lg:210},height:{base:39,lg:40}}},PartnerLogo=e=>{let{partner:t}=e,a=(0,i.d)(),n=l[t]||l.flyte,o=c[t]||c.flyte;return(0,r.jsx)(s(),{src:n,width:a?o.width.base:o.width.lg,height:a?o.height.base:o.height.lg,alt:"".concat(t," Logo")})}},44943:function(e,t,a){a.d(t,{R:function(){return SupportContactLink},_:function(){return s}});var r=a(85893),i=a(66122),n=a(3183),o=a(71986);let s={formatted:"(844) 359-8363"},SupportContactLink=e=>{let{onClick:t,children:a="(844) 359-8363",...s}=e,{track:l}=(0,n.useAnalytics)();return(0,r.jsx)(o.Link,{isInline:!0,href:"tel:+18443598363",children:a,onClick:e=>{l(i.U.phoneNumberClicked),null==t||t(e)},...s})}},53157:function(e,t,a){a.d(t,{K:function(){return WorkflowHeader},t:function(){return s}});var r=a(85893),i=a(71986),n=a(30624),o=a(70908);a(67294);let s=new Map([[o.J.PreEligibility,{label:"Age & BMI",icon:i.IconScaleOutline}],[o.J.ContactDetails,{label:"Personal Details",icon:i.IconId}],[o.J.InsuranceDetails,{label:"Insurance Info",icon:i.IconClipboardPlus}]]),WorkflowHeader=e=>{var t;let{currentStep:a,steps:i=s}=e,o=null===(t=i.get(a))||void 0===t?void 0:t.label,l=Array.from(i.values());return(0,r.jsx)(n.E,{currentStep:o,steps:l})}},11964:function(e,t,a){a.d(t,{e:function(){return ConfirmationExitModal}});var r=a(85893),i=a(71986),n=a(67294);let ConfirmationExitModal=e=>{let{isOpen:t,onLeave:a,onContinue:o}=e,s=(0,n.useRef)(null);return(0,r.jsxs)(i.Modal,{isOpen:t,onClose:o,autoFocus:!1,isCentered:!0,initialFocusRef:s,children:[(0,r.jsx)(i.Modal.Overlay,{}),(0,r.jsxs)(i.Modal.Content,{px:"spacer-7",py:"spacer-6",gap:"spacer-7",mx:{base:"spacer-9",md:0},maxWidth:"26.25rem",children:[(0,r.jsxs)(i.Modal.Body,{p:0,children:[(0,r.jsx)(i.Text,{variant:"text-body-large-bold",children:"Are you sure you want to leave?"}),(0,r.jsx)(i.Text,{color:"text-secondary",variant:"text-body-regular",children:"You haven't finished signing up. If you leave, all information will be cleared."})]}),(0,r.jsxs)(i.Modal.Footer,{flexDirection:{base:"column",md:"row-reverse"},gap:"spacer-4",p:0,children:[(0,r.jsx)(i.Button,{variant:"secondary",size:"m",flex:1,width:"100%",onClick:o,ref:s,children:"Continue signing up"}),(0,r.jsx)(i.Button,{variant:"destroy",size:"m",flex:1,width:"100%",onClick:a,children:"Leave now"})]})]})]})}},45854:function(e,t,a){a.d(t,{m:function(){return HowDidYouFindUsSelector},p:function(){return l}});var r=a(85893),i=a(71986),n=a(56401),o=a(87536);let s=[n.Op.Brochure,n.Op.CompanyIntranet,n.Op.Email,n.Op.CoworkerReferral,n.Op.EpicEHRReferral,n.Op.FrameFertility,n.Op.GoogleAd,n.Op.Mailer,n.Op.NuvanceRhinebeck,n.Op.OnsiteMonitor,n.Op.Poster,n.Op.PrintAd,n.Op.ProfessionalReferral,n.Op.ProviderReferral,n.Op.QuantumHealth,n.Op.SocialMedia,n.Op.TVAd,n.Op.TradeShow,n.Op.UpswingHealth,n.Op.WebSearch,n.Op.Website,n.Op.WordOfMouth,n.Op.Other],l="howDidYouFindUS",HowDidYouFindUsSelector=e=>{let{isDisabled:t,options:a=s}=e,{register:n,watch:c}=(0,o.Gc)();return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:l,children:"How did you hear about us?"}),(0,r.jsx)(i.Select,{"data-test":l,id:l,size:"l",variant:"flushed",placeholder:"Select",isDisabled:t,...n(l,{required:!0}),value:c(l),children:a.map(e=>(0,r.jsx)("option",{value:e,children:e},e))})]})}},49070:function(e,t,a){a.d(t,{$S:function(){return PhoneField},KP:function(){return TermsAgreementField}});var r=a(85893),i=a(71986),n=a(58976),o=a(38098),s=a(36045),l=a(37887),c=a(98951),d=a(87536);let S="phone",PhoneField=e=>{let{isDisabled:t,...a}=e,{register:u,setValue:C,formState:{errors:m}}=(0,d.Gc)(),p=(0,s.T)(S,m,"validate");return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...a,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:S,children:"Mobile phone"}),(0,r.jsx)(n.sb,{"data-test":S,id:S,isInvalid:p,isDisabled:t,onInput:e=>C(S,e.currentTarget.value),...u(S,{required:!0,validate:e=>(0,l.Z)(e,"US",c.Z)||o.x[S].validate})}),p&&(0,r.jsx)(n.VO,{errors:m,name:S})]})},u="termsAgreement",TermsAgreementField=e=>{let{isDisabled:t,...a}=e,{register:n}=(0,d.Gc)();return(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",...a,children:[(0,r.jsx)(i.Checkbox,{"data-test":u,size:{base:"l",lg:"m"},"aria-label":"I agree to the terms",isDisabled:t,...n(u,{required:!0})}),(0,r.jsxs)(i.Text,{variant:"text-body-regular",color:"text-secondary",children:["I have read and agree to the\xa0",(0,r.jsx)(i.Link,{fontWeight:"thin",variant:"link-primary",isInline:!0,isExternal:!0,href:"https://www.flytehealth.com/terms/#elementor-toc__heading-anchor-2",children:"Terms of Service"}),",\xa0",(0,r.jsx)(i.Link,{fontWeight:"thin",variant:"link-primary",isInline:!0,isExternal:!0,href:"https://www.flytehealth.com/terms/#elementor-toc__heading-anchor-3",children:"Privacy Policy"}),"\xa0&\xa0",(0,r.jsx)(i.Link,{fontWeight:"thin",variant:"link-primary",isInline:!0,href:"https://www.flytehealth.com/terms/#elementor-toc__heading-anchor-4",isExternal:!0,children:"Notice of Privacy Practice"}),"."]})]})}},58848:function(e,t,a){a.d(t,{X:function(){return USStateSelector},x:function(){return s}});var r=a(85893),i=a(71986),n=a(47886),o=a(87536);let s="state",USStateSelector=e=>{let{isDisabled:t,options:a,...l}=e,{register:c,watch:d}=(0,o.Gc)();return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...l,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:s,children:"State"}),(0,r.jsx)(n.e,{"data-test":s,id:s,isDisabled:t,...c(s,{required:!0}),value:d(s),options:a})]})}},39424:function(e,t,a){a.d(t,{q:function(){return ContactDetailsForm}});var r=a(85893),i=a(71986),n=a(58976),o=a(38098),s=a(36045),l=a(87536),c=a(46899);let SsnField=e=>{let{isDisabled:t,...a}=e,{register:d,setValue:S,formState:{errors:u}}=(0,l.Gc)(),C=(0,s.T)("ssn",u,["minLength","maxLength"]);return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...a,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:"ssn",children:"Social Security Number"}),(0,r.jsx)(i.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Last 4 Digits of your Social Security Number"}),(0,r.jsx)(c.T,{"data-test":"ssn",id:"ssn",isInvalid:C,isDisabled:t,onInput:e=>S("ssn",e.currentTarget.value),...d("ssn",{required:!0,minLength:{value:4,message:o.x.ssn.minLength},maxLength:{value:4,message:o.x.ssn.maxLength}})}),C&&(0,r.jsx)(n.VO,{errors:u,name:"ssn"})]})};var d=a(73857),S=a(84862),u=a(49070),C=a(45854),m=a(58848);let ContactDetailsForm=e=>{let{configuration:t,loading:a=!1,onSubmit:o,defaultValues:s}=e,{contentResources:c,fields:p}=t,h=(0,l.cI)({mode:"onBlur",defaultValues:s}),g=(0,S.d)(),renderFormAction=()=>(0,r.jsx)(i.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!h.formState.isValid,width:"100%",isLoading:a,trailingIcon:(0,r.jsx)(i.IconArrowRight,{}),"aria-label":"Continue",children:"Continue"});return(0,r.jsx)(l.RV,{...h,children:(0,r.jsxs)(d.S,{as:"form",onSubmit:h.handleSubmit(o),noValidate:!0,children:[(0,r.jsx)(d.S.Side,{gap:0,children:c.title}),(0,r.jsxs)(d.S.Form,{children:[(0,r.jsx)(n.dO,{isDisabled:a}),(null==p?void 0:p.ssn)&&(0,r.jsx)(SsnField,{isDisabled:a}),(0,r.jsx)(n.s8,{inputProps:{isDisabled:a}}),(0,r.jsxs)(i.Flex,{direction:{base:"column",lg:"row"},gap:"spacer-9",children:[(0,r.jsx)(u.$S,{isDisabled:a,flex:1}),(null==p?void 0:p.state)&&(0,r.jsx)(m.X,{isDisabled:a,flex:1,options:p.state.options})]}),(0,r.jsx)(C.m,{isDisabled:a,options:p.howDidYouFindUs.options}),(0,r.jsx)(u.KP,{isDisabled:a,pb:{base:"spacer-24",lg:0}}),g?(0,r.jsx)(n.D2,{children:renderFormAction()}):renderFormAction()]})]})})}},27350:function(e,t,a){a.d(t,{f:function(){return CreatePasswordForm}});var r=a(85893),i=a(71986),n=a(58976),o=a(67294),s=a(87536),l=a(36045);let c=(0,o.forwardRef)((e,t)=>{let{isDisabled:a,...n}=e,[s,l]=(0,o.useState)(!1),c=s?i.IconEyeOff:i.IconEye;return(0,r.jsx)(i.Input,{type:s?"text":"password",inputMode:"text",placeholder:"Enter your password",size:"l",variant:"flushed",ref:t,isDisabled:a,trailingIcon:(0,r.jsx)(i.Box,{userSelect:"none",children:(0,r.jsx)(c,{onClick:()=>{a||l(e=>!e)},cursor:a?"not-allowed":"pointer"})}),...n})}),d=[{key:"LENGTH",regex:/^.{10,}$/,label:"Password must be at least ten characters long"},{key:"LOWERCASE",regex:/[a-z]/,label:"Use at least one lowercase letter"},{key:"UPPERCASE",regex:/[A-Z]/,label:"Use at least one uppercase letter"},{key:"NUMBER",regex:/\d/,label:"Use at least one number"},{key:"SPECIAL_CHAR",regex:/[^a-z0-9\s]/i,label:"Use at least one special character (like !@#$%)"}],evaluatePasswordRules=e=>Object.fromEntries(d.map(t=>[t.key,t.regex.test(e)])),createPasswordValidation=e=>({validate:Object.fromEntries(d.map(e=>[e.key.toLowerCase(),t=>e.regex.test(t)||e.label])),...e&&{matchesPassword:t=>t===e||"Passwords do not match"}}),S="password",PasswordField=e=>{let{name:t=S,label:a="Create password",showRules:n,checkMatchingPassword:o,isDisabled:u,isInvalid:C,...m}=e,{register:p,watch:h,formState:g,trigger:x}=(0,s.Gc)(),{errors:b,touchedFields:y}=g,H=h(t)||"",f=y[t],v=(0,l.T)(t,b,["matchesPassword"]),I=H?evaluatePasswordRules(H):null,R=!!I&&Object.values(I).every(Boolean);return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...m,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:t,children:a}),(0,r.jsx)(c,{"data-test":t,id:t,isDisabled:u,isInvalid:C,...p(t,{...createPasswordValidation(o),onBlur:()=>x(t)})}),f&&H&&!R&&n&&!v&&(0,r.jsx)(i.Text,{variant:"text-body-meta-regular",color:"text-error",children:"Password does not meet all criteria."}),n&&(0,r.jsx)(i.Flex,{direction:"column",gap:"spacer-1",children:d.map(e=>{let{key:t,label:a}=e;return(0,r.jsxs)(i.Flex,{gap:"spacer-1",alignItems:"center",children:[(null==I?void 0:I[t])?(0,r.jsx)(i.IconCircleCheck,{color:"alert-success-default",size:"s"}):f?(0,r.jsx)(i.IconAlertCircle,{color:"alert-error-default",size:"s"}):(0,r.jsx)(i.IconCircleCheck,{color:"primary-disabled",size:"s"}),(0,r.jsx)(i.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:a})]},a)})})]})},u="confirmPassword",ConfirmPasswordField=e=>{var t;let{name:a=u,label:n="Confirm password",placeholder:l,isDisabled:d,isInvalid:C,...m}=e,{register:p,watch:h,formState:{touchedFields:g,errors:x},trigger:b}=(0,s.Gc)(),y=h(S),H=h(a),f=g[a];(0,o.useEffect)(()=>{f&&H&&b(a)},[y,f,H,b,a]);let v=!!(f&&H&&x[a]);return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...m,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:a,children:n}),(0,r.jsx)(c,{"data-test":a,id:a,isDisabled:d,placeholder:l,isInvalid:v,...p(a,{required:!0,validate:e=>e&&e===y||"Passwords do not match"})}),v&&(0,r.jsx)(i.Text,{variant:"text-body-meta-regular",color:"text-error",children:null===(t=x[a])||void 0===t?void 0:t.message})]})};var C=a(73857),m=a(84862),p=a(70908);let CreatePasswordForm=e=>{let{configuration:t,loading:a=!1,error:o,onSubmit:l}=e,{contentResources:c}=t,d=(0,s.cI)({mode:"onBlur"}),{handleSubmit:h,formState:{errors:g,isValid:x}}=d,b=(0,m.d)(),renderFormAction=()=>(0,r.jsx)(i.Button,{type:"submit",size:{base:"m",lg:"l"},width:"100%","aria-label":"Create account",isDisabled:!x&&!a,isLoading:a,children:"Create account"});return(0,r.jsx)(s.RV,{...d,children:(0,r.jsxs)(C.S,{as:"form",onSubmit:h(l),noValidate:!0,"data-test":p.J.CreatePassword,children:[(0,r.jsx)(C.S.Side,{children:c.title}),(0,r.jsxs)(C.S.Form,{children:[o&&(0,r.jsxs)(i.Alert,{status:"error",variant:"subtle",children:[(0,r.jsx)(i.Alert.Icon,{}),(0,r.jsx)(i.Alert.Title,{children:o.message||"There was an error submitting your password. Please try again."})]}),(0,r.jsx)(PasswordField,{label:"Create password",isDisabled:a,isInvalid:!!g[S],showRules:!0}),(0,r.jsx)(ConfirmPasswordField,{label:"Confirm password",placeholder:"Retype your password",isDisabled:a,isInvalid:!!g[u],pb:{base:"spacer-24",lg:0}}),b?(0,r.jsx)(n.D2,{children:renderFormAction()}):renderFormAction()]})]})})}},86640:function(e,t,a){a.d(t,{X:function(){return EligibilityUnmetForm}});var r=a(85893),i=a(71986),n=a(58976),o=a(73857),s=a(84862),l=a(70908),c=a(87536);let EligibilityUnmetForm=e=>{let{configuration:t,loading:a=!1,isEmailSent:d=!1,hasError:S=!1,isMobileFooterSticky:u=!0,onSubmit:C}=e,{contentResources:m}=t,p=(0,c.cI)({mode:"onBlur"}),h=(0,s.d)(),renderFormAction=()=>(0,r.jsx)(i.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!p.formState.isValid||d,width:"100%",isLoading:a,"aria-label":"Keep me posted",children:"Keep me posted"});return(0,r.jsx)(c.RV,{...p,children:(0,r.jsxs)(o.S,{as:"form",onSubmit:p.handleSubmit(C),noValidate:!0,"data-test":l.J.EligibilityUnmet,children:[(0,r.jsx)(o.S.Side,{children:m.title}),(0,r.jsxs)(o.S.Form,{pb:{base:"spacer-24",lg:0},children:[m.alert,(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-L",children:[(0,r.jsx)(i.TextPairing.Label,{children:"We work hard to try to offer our services to everyone who wants them."}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"Please provide your contact information so we can get in touch if our criteria change and you become eligible to join."})]}),(0,r.jsx)(n.dO,{isDisabled:a||d}),(0,r.jsx)(n.s8,{inputProps:{isDisabled:a||d}}),h&&u?(0,r.jsx)(n.D2,{children:renderFormAction()}):renderFormAction(),d&&(0,r.jsxs)(i.Alert,{status:"success",variant:"subtle",children:[(0,r.jsx)(i.Alert.Icon,{}),(0,r.jsxs)(i.Box,{children:[(0,r.jsx)(i.Alert.Title,{children:(0,r.jsx)(i.Text,{variant:"text-body-bold",children:"Email received"})}),(0,r.jsx)(i.Alert.Description,{children:(0,r.jsx)(i.Text,{variant:"text-body-regular",children:"We'll keep you up to date on our latest news and will send you an email if you become eligible to join."})})]})]}),S&&(0,r.jsxs)(i.Alert,{status:"error",variant:"subtle",children:[(0,r.jsx)(i.Alert.Icon,{}),(0,r.jsx)(i.Alert.Title,{children:"There was an error submitting your information. Please review the email address above and try again."})]})]})]})})}},96693:function(e,t,a){a.d(t,{Z:function(){return EmailVerificationForm}});var r=a(85893),i=a(66122),n=a(3183),o=a(71986),s=a(67294),l=a(87536),c=a(58976);let EditEmailModal=e=>{let{isOpen:t,onClose:a,onSubmit:i,currentEmail:n,loading:d=!1,hasError:S}=e,u=(0,l.cI)({defaultValues:{currentEmail:n},mode:"onBlur"});(0,s.useEffect)(()=>{u.setValue("currentEmail",n)},[n]);let handleClose=()=>{d||(a(),u.reset())};return(0,r.jsxs)(o.Modal,{isOpen:t,onClose:handleClose,isCentered:!0,closeOnEsc:!d,closeOnOverlayClick:!d,children:[(0,r.jsx)(o.Modal.Overlay,{}),(0,r.jsxs)(o.Modal.Content,{borderRadius:"0.75rem",px:"spacer-7",py:"spacer-6",gap:"spacer-7",maxWidth:"26.25rem",mx:{base:"spacer-5",md:0},children:[(0,r.jsxs)(o.Modal.Header,{p:0,children:[(0,r.jsx)(o.Text,{variant:"text-body-large-bold",color:"text-primary",children:"Edit your email address"}),(0,r.jsx)(o.Text,{variant:"text-body-regular",color:"text-secondary",mt:"spacer-4",children:"This email will be used to create your FlyteHealth account. Next, you'll receive an email with a 6-digit code. Use this code to confirm your email."})]}),(0,r.jsx)(o.Modal.CloseButton,{isDisabled:d}),S&&(0,r.jsxs)(o.Alert,{status:"error",variant:"subtle",children:[(0,r.jsx)(o.Alert.Icon,{}),(0,r.jsx)(o.Alert.Title,{children:"There was an error submitting your information. Please call (844) 359-8363 to speak with a Care Coordinator."})]}),(0,r.jsx)(o.Modal.Body,{p:0,children:(0,r.jsx)(l.RV,{...u,children:(0,r.jsxs)(o.Flex,{as:"form",noValidate:!0,direction:"column",gap:"spacer-7",children:[(0,r.jsx)(c.s8,{name:"currentEmail",label:"Current email address",inputProps:{isDisabled:!0}}),(0,r.jsx)(c.s8,{name:"newEmail",label:"Enter your correct email address",inputProps:{isRequired:!0,isDisabled:d}})]})})}),(0,r.jsxs)(o.Modal.Footer,{p:0,gap:"spacer-4",children:[(0,r.jsx)(o.Button,{variant:"primary-alt",onClick:handleClose,size:"m",isDisabled:d,"aria-label":"Cancel",flex:1,width:"100%",children:"Cancel"}),(0,r.jsx)(o.Button,{flex:1,width:"100%","aria-label":"Update email",onClick:u.handleSubmit(i),variant:"primary",isLoading:d,size:"m",isDisabled:!u.formState.isValid,children:"Update email"})]})]})]})},d="verificationCode",VerificationCodeField=e=>{let{name:t=d,hasError:a=!1,loading:i=!1,onResendCode:n,onSubmit:c}=e,{control:S,reset:u,watch:C}=(0,l.Gc)(),[m,p]=(0,s.useState)(60),h=a&&!C(d);(0,s.useEffect)(()=>{let e;return m>0&&(e=setInterval(()=>{p(t=>t<=1?(clearInterval(e),0):t-1)},1e3)),()=>clearInterval(e)},[m]);let handlePinInputChange=e=>{6===e.length&&c(e)};return(0,s.useEffect)(()=>{a&&u({[t]:""})},[a,u,t]),(0,r.jsxs)(o.Flex,{direction:"column",gap:"spacer-2",children:[(0,r.jsxs)(o.Flex,{gap:"spacer-2",direction:"column",children:[(0,r.jsx)(l.Qr,{name:t,control:S,rules:{required:!0,minLength:6,maxLength:6},render:e=>{let{field:{onChange:a,value:n}}=e;return(0,r.jsx)(o.PinInput,{"data-test":t,id:t,value:n,onChange:e=>{a(e),handlePinInputChange(e)},"aria-label":"Enter the code",otp:!0,size:"l",variant:"outline",type:"number",isDisabled:i,isInvalid:h,children:Array.from({length:6}).map((e,a)=>(0,r.jsx)(o.PinInput.Field,{"data-test":"".concat(t,"-").concat(a),width:{base:"auto",lg:"4rem",xl:"5rem",xxl:"5.25rem"}},"pin-field-position-".concat(a+1)))})}}),h&&(0,r.jsxs)(o.InlineAlert,{status:"error",children:[(0,r.jsx)(o.InlineAlert.Icon,{}),(0,r.jsx)(o.InlineAlert.Message,{children:"Incorrect code. Please try again."})]})]}),(0,r.jsxs)(o.Flex,{gap:"spacer-1",mt:"spacer-2",flexWrap:"wrap",children:[(0,r.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Do you need a new code?"}),m>0?(0,r.jsxs)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:["You can request a new one in"," ",(0,r.jsxs)(o.Text,{as:"span",variant:"text-body-meta-medium",color:"text-secondary",children:[m,"s"]})]}):(0,r.jsx)(o.Button,{variant:"link-primary","aria-label":"Resend code",size:"s",textDecoration:"underline",onClick:()=>{n(),p(60)},isDisabled:i,children:"Resend code"})]})]})};var S=a(73857),u=a(44943),C=a(84862);let EmailVerificationForm=e=>{let{configuration:t,email:a,hasError:d=!1,loading:m=!1,isUpdateEmailLoading:p,hasUpdateEmailError:h,onResendCode:g,onEditEmail:x,onSubmit:b}=e,y=(0,l.cI)({mode:"onBlur"}),{contentResources:H}=t,[f,v]=(0,s.useState)(!1),[I,R]=(0,s.useState)(!0),D=(0,C.d)(),E=(0,o.useToast)(),{track:j}=(0,n.useAnalytics)(),renderFormAction=()=>(0,r.jsx)(o.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!y.formState.isValid||m,width:"100%",isLoading:m,"aria-label":"Verify code",children:"Verify code"}),w=(0,s.useCallback)(e=>{I&&(b({verificationCode:e}),R(!1))},[b,I]),handleCloseEditEmailModal=()=>{v(!1)},handleEditEmailSubmit=e=>{x(e,()=>{handleCloseEditEmailModal(),E({title:"Email address updated",description:"Check your email for a 6-digit code to confirm your email address.",status:"success",titleAlignment:"top",position:"bottom",variant:"subtle",duration:3e3})})};return(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(l.RV,{...y,children:(0,r.jsxs)(S.S,{as:"form",onSubmit:y.handleSubmit(b),noValidate:!0,children:[(0,r.jsxs)(S.S.Side,{gap:"spacer-7",children:[H.title,(0,r.jsxs)(o.Flex,{gap:"spacer-1",children:[(0,r.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Not your email?"}),(0,r.jsx)(o.Button,{variant:"link-primary",size:"s",textDecoration:"underline",onClick:()=>{v(!0),j(i.U.editEmail)},isDisabled:m,"aria-label":"Edit email address",children:"Edit email address"})]})]}),(0,r.jsxs)(S.S.Form,{children:[(0,r.jsx)(VerificationCodeField,{hasError:d,loading:m,onResendCode:()=>{g(()=>{E({title:"New code sent to your email",status:"success",position:"bottom",variant:"solid",duration:3e3})})},onSubmit:w}),(0,r.jsxs)(o.Flex,{direction:"column",children:[(0,r.jsx)(o.Text,{variant:"text-body-bold",color:"text-secondary",children:"Need some help?"}),(0,r.jsxs)(o.Text,{color:"text-secondary",variant:"text-body-regular",mt:"spacer-1",children:["Please call"," ",(0,r.jsx)(u.R,{fontWeight:"thin"})," ","to speak with a Care Coordinator."]})]}),D?(0,r.jsx)(c.D2,{children:renderFormAction()}):renderFormAction()]})]})}),f&&(0,r.jsx)(EditEmailModal,{isOpen:f,onClose:handleCloseEditEmailModal,onSubmit:e=>{let{newEmail:t}=e;return handleEditEmailSubmit(t)},currentEmail:a,loading:p,hasError:h})]})}},97324:function(e,t,a){a.d(t,{vu:function(){return InsuranceCarrierSelector},nK:function(){return InsuranceCoverageField},nB:function(){return InsuranceMemberIdField},dn:function(){return OtherInsurerField},OF:function(){return l},o0:function(){return S},rI:function(){return p},zQ:function(){return h}});var r=a(85893),i=a(71986),n=a(56401),o=a(67294),s=a(87536);let l="insurance",c=Object.values(n.PF).filter(e=>e!==n.PF.SelfPay),InsuranceCarrierSelector=e=>{let{label:t="Name of the insurer",isRequired:a=!0,isDisabled:n=!1,defaultSelectedItem:d,insuranceCarriers:S=c,...u}=e,[C,m]=(0,o.useState)(S),{control:p,watch:h}=(0,s.Gc)();return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...u,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:l,children:t}),(0,r.jsx)(s.Qr,{control:p,name:l,rules:{required:a},render:e=>{let{field:{onChange:t,onBlur:a}}=e;return(0,r.jsxs)(i.Autocomplete,{id:"".concat(l,"-autocomplete"),items:C,onInputValueChange:e=>{let{inputValue:a}=e;if(!a){m(S),t(a);return}m(S.filter(e=>null==e?void 0:e.toLowerCase().includes(a.toLowerCase())))},onSelectedItemChange:e=>{let{selectedItem:a}=e;return t(a)},initialSelectedItem:d,selectedItem:h(l)||"",children:[(0,r.jsx)(i.Autocomplete.Input,{"data-test":l,id:l,size:"l",placeholder:"Select your insurance carrier",clearButtonMode:n?"never":"has-value",leadingIcon:(0,r.jsx)(i.IconSearch,{}),variant:"flushed",isDisabled:n,onBlur:a}),(0,r.jsx)(i.Autocomplete.List,{"data-test":"".concat(l,"List"),zIndex:2,renderItem:e=>(0,r.jsx)(i.Text,{variant:"text-body-regular",children:e}),overflowY:"auto",maxHeight:"13.5rem"})]})}})]})};var d=a(41240);let S="insuranceCoverage",InsuranceCoverageField=e=>{let{isDisabled:t}=e,{register:a}=(0,s.Gc)();return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-4",children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",children:"Do you have insurance coverage?"}),(0,r.jsxs)(i.RadioGroup,{display:"flex",flexDirection:"column",gap:"spacer-3",isDisabled:t,"data-test":S,name:S,children:[(0,r.jsx)(d.D,{name:S,value:n.eF.Insured,size:"m",isDisabled:t,...a(S,{required:!0}),children:"Yes, I'd like to check if my insurance can help cover the cost"}),(0,r.jsx)(d.D,{value:n.eF.SelfPay,size:"m",...a(S),name:S,isDisabled:t,children:"No, I will pay for it myself"})]})]})};var u=a(58976),C=a(68701),m=a(36045);let p="insuranceMemberID",InsuranceMemberIdField=e=>{let{label:t="Insurance Member ID",placeholder:a,description:n,tooltip:o,type:l,maxLength:c,minLength:d,maskOptions:S,inputMode:h,registerOptions:g,isDisabled:x=!1,isRequired:b=!0,...y}=e,{setValue:H,register:f,formState:{errors:v}}=(0,s.Gc)(),I=(0,m.T)(p,v,["minLength","maxLength","pattern"]);return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...y,children:[(0,r.jsxs)(i.Box,{children:[(0,r.jsxs)(i.Flex,{gap:"spacer-2",alignItems:"center",children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:p,children:t}),o&&(0,r.jsx)(i.Tooltip,{label:o,placement:"auto-end",children:(0,r.jsx)(i.Flex,{children:(0,r.jsx)(i.IconInfoCircle,{size:"m",color:"text-link-primary-default"})})})]}),n]}),(0,r.jsx)(C.o,{"data-test":p,id:p,isInvalid:I,isDisabled:x,placeholder:a,type:l,inputMode:h,maxLength:c,minLength:d,maskOptions:S,onInput:e=>{let t=e.currentTarget.value,a=!d||d&&t.length>=d;H(p,t,{shouldValidate:a})},...f(p,{required:b,...g})}),I&&(0,r.jsx)(u.VO,{errors:v,name:p})]})},h="insuranceOther",OtherInsurerField=e=>{let{label:t="Name of your Insurer",isRequired:a=!0,description:n,isDisabled:o=!1,...l}=e,{register:c}=(0,s.Gc)();return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",...l,children:[(0,r.jsxs)(i.Box,{children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",children:t}),n]}),(0,r.jsx)(i.Input,{"data-test":h,"aria-label":"Insurer company name",placeholder:"Insurance company name",isRequired:a,type:"text",size:"l",variant:"flushed",isDisabled:o,...c(h,{required:a})})]})}},50793:function(e,t,a){a.d(t,{v:function(){return InsuranceDetailsForm}});var r=a(85893),i=a(71986),n=a(58976),o=a(73857),s=a(84862),l=a(56401),c=a(67294),d=a(87536),S=a(97324);let InsuranceDetailsForm=e=>{let{configuration:t,loading:a=!1,onSubmit:u,onBack:C}=e,{contentResources:m,fields:p}=t,h=(0,d.cI)({mode:"onBlur"}),g=(0,s.d)(),x=h.watch(S.o0)===l.eF.SelfPay,b=h.watch(S.OF)===l.PF.Other;(0,c.useEffect)(()=>{x&&(h.resetField(S.OF),h.resetField(S.rI))},[x,h]),(0,c.useEffect)(()=>{h.resetField(S.zQ)},[h.watch(S.OF),h]);let renderFormActions=()=>(0,r.jsxs)(i.Flex,{gap:{base:"spacer-8",md:"spacer-16"},alignItems:"center",flex:{base:1,lg:"unset"},children:[(0,r.jsx)(i.Button,{size:{base:"m",lg:"l"},isLoading:a,variant:"link","aria-label":"Back",leadingIcon:(0,r.jsx)(i.IconArrowLeft,{}),onClick:C,children:"Back"}),(0,r.jsx)(i.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!h.formState.isValid,flex:1,isLoading:a,trailingIcon:(0,r.jsx)(i.IconArrowRight,{}),"aria-label":"Continue",children:"Continue"})]});return(0,r.jsx)(d.RV,{...h,children:(0,r.jsxs)(o.S,{as:"form",onSubmit:h.handleSubmit(u),noValidate:!0,children:[(0,r.jsx)(o.S.Side,{gap:0,flex:{base:"none",lg:1},children:m.title}),(0,r.jsxs)(o.S.Form,{children:[(null==p?void 0:p.insuranceCoverage)&&(0,r.jsx)(S.nK,{isDisabled:a}),(null==p?void 0:p.insurance)&&(0,r.jsx)(S.vu,{isDisabled:a||x,isRequired:!x,...null==p?void 0:p.insurance},x.toString()),b&&(0,r.jsx)(S.dn,{isDisabled:a,...null==p?void 0:p.insuranceOther}),(0,r.jsx)(S.nB,{isDisabled:a||x,isRequired:!x,pb:{base:"spacer-24",lg:0},...null==p?void 0:p.insuranceMemberID}),g?(0,r.jsx)(n.D2,{children:renderFormActions()}):renderFormActions()]})]})})}},83344:function(e,t,a){a.d(t,{b:function(){return InsuranceDetailsReviewForm}});var r=a(85893),i=a(71986),n=a(58976),o=a(73857),s=a(84862),l=a(67294),c=a(87536),d=a(38098),S=a(46899),u=a(49070),C=a(36045);let m="firstName",p="lastName",h="birthdate",g="state",IdentityFields=e=>{let{isDisabled:t,...a}=e,{register:o,formState:{errors:s,defaultValues:l},setValue:x,watch:b}=(0,c.Gc)(),y=(0,C.T)(h,s,["isValid","isOver18YearsOld","isLessThan150YearsOld"]),H=(0,C.T)("ssn",s,["minLength","maxLength"]);return(0,r.jsxs)(i.Flex,{direction:"column",...a,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-header-M",color:"text-primary",children:"About you"}),(0,r.jsxs)(i.Flex,{gap:{base:"spacer-4",md:"spacer-8"},mt:"spacer-5",children:[(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",flex:1,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:m,children:"Legal First name"}),(0,r.jsx)(n.iQ,{id:m,isDisabled:t,...o(m,{required:!0})})]}),(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",flex:1,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:p,children:"Legal Last name"}),(0,r.jsx)(n.Fl,{id:p,isDisabled:t,...o(p,{required:!0})})]})]}),(0,r.jsxs)(i.Flex,{gap:{base:"spacer-4",md:"spacer-8"},mt:"spacer-5",children:[(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",flex:1,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:h,children:"Date of birth"}),(0,r.jsx)(n.AM,{"aria-label":"Date of birth",id:h,isInvalid:y,isDisabled:t,onInput:e=>x(h,e.currentTarget.value),...o(h,{required:!0,validate:{isValid:e=>n.pm.isValid(e)||d.x[h].isValid,isOver18YearsOld:e=>n.pm.isOver18YearsOld(e)||d.x[h].isOver18YearsOld,isLessThan150YearsOld:e=>n.pm.isLessThan150YearsOld(e)||d.x[h].isLessThan150YearsOld}})}),y&&(0,r.jsx)(n.VO,{errors:s,name:h})]}),l[g]&&(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",flex:1,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:g,children:"State"}),(0,r.jsx)(n.ed,{"aria-label":"State",id:g,isDisabled:t,...o(g,{required:!0}),value:b(g)})]})]}),l.ssn&&(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",flex:1,mt:"spacer-5",children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:"ssn",children:"Social Security Number"}),(0,r.jsx)(i.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Last 4 Digits of your Social Security Number"}),(0,r.jsx)(S.T,{"data-test":"ssn",id:"ssn",isInvalid:H,isDisabled:t,onInput:e=>x("ssn",e.currentTarget.value),...o("ssn",{required:!0,minLength:{value:4,message:d.x.ssn.minLength},maxLength:{value:4,message:d.x.ssn.maxLength}})}),H&&(0,r.jsx)(n.VO,{errors:s,name:"ssn"})]}),(0,r.jsxs)(i.Flex,{gap:{base:"spacer-4",md:"spacer-8"},mt:"spacer-5",children:[(0,r.jsx)(n.s8,{inputProps:{isDisabled:t},flex:1}),(0,r.jsx)(u.$S,{isDisabled:t,flex:1})]})]})};var x=a(68701),b=a(97324),y=a(56401);let H="insuranceMemberID",InsuranceFields=e=>{let{isDisabled:t,insuranceMemberID:a,insurance:o,...s}=e,{register:d,formState:{defaultValues:S,errors:u},watch:m,setValue:p,resetField:h}=(0,c.Gc)(),g=S[b.OF],f=m(b.OF)===y.PF.Other,v=(0,C.T)(H,u,["minLength","maxLength"]),{registerOptions:I,...R}=a||{};(0,l.useEffect)(()=>{f||h(b.zQ,{defaultValue:null})},[h,f]);let D=(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-2",flex:1,children:[(0,r.jsx)(i.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:H,children:(null==a?void 0:a.label)||"Insurance Member ID"}),(0,r.jsx)(x.o,{id:H,isDisabled:t,onInput:e=>{let t=e.currentTarget.value,a=null==R?void 0:R.minLength,r=!a||a&&t.length>=a;p(H,t,{shouldValidate:r})},...R,...d(H,{required:!0,...I})}),v&&(0,r.jsx)(n.VO,{errors:u,name:H})]});return(0,r.jsxs)(i.Flex,{direction:"column",gap:"spacer-5",...s,children:[(0,r.jsx)(i.Text,{variant:"text-header-M",color:"text-primary",children:"Insurance information"}),(0,r.jsxs)(i.Flex,{direction:"column",gap:{base:"spacer-4",md:"spacer-8"},children:[(0,r.jsxs)(i.Flex,{direction:{base:"column",md:"row"},gap:{base:"spacer-4",md:"spacer-8"},children:[g&&(0,r.jsx)(b.vu,{isDisabled:t,isRequired:!0,defaultSelectedItem:g,flex:1,...o}),f?(0,r.jsx)(b.dn,{isDisabled:t,flex:1}):D]}),f&&D]})]})},InsuranceDetailsReviewForm=e=>{var t,a;let{configuration:d,defaultValues:S,loading:u=!1,hasError:C=!1,onSubmit:m}=e,{contentResources:p}=d,h=(0,c.cI)({mode:"onBlur",defaultValues:S}),g=(0,s.d)(),[x,b]=(0,l.useState)(!1),y=u||!x,H=S.insurance||S.insuranceMemberID||S.insuranceOther,toggleEditMode=()=>b(e=>!e),handleCancel=()=>{h.reset(S),toggleEditMode()},renderFormActions=()=>(0,r.jsxs)(i.Flex,{gap:{base:"spacer-6"},flex:1,children:[x&&!u&&(0,r.jsx)(i.Button,{size:{base:"m",lg:"l"},variant:"primary-alt","aria-label":"Cancel",onClick:handleCancel,children:"Cancel"}),(0,r.jsx)(i.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!h.formState.isValid,flex:1,isLoading:u,leadingIcon:(0,r.jsx)(i.IconCircleCheck,{}),"aria-label":"My information is correct",children:g&&x?"Confirm":"My information is correct"})]});return(0,r.jsx)(c.RV,{...h,children:(0,r.jsxs)(o.S,{as:"form",onSubmit:h.handleSubmit(e=>{b(!1),m(e)}),noValidate:!0,children:[(0,r.jsx)(o.S.Side,{gap:0,children:p.title}),(0,r.jsxs)(o.S.Form,{gap:0,children:[(0,r.jsx)(i.Text,{variant:"text-header-L",color:"text-primary",children:"Please confirm your personal information"}),(0,r.jsx)(i.Button,{mt:"spacer-2",variant:"link-primary",verticalAlign:"initial",onClick:toggleEditMode,alignSelf:"start",isDisabled:u||x,leadingIcon:(0,r.jsx)(i.IconPencil,{}),textDecoration:"underline",_hover:{textDecoration:"underline"},children:"Edit your information"}),x&&(0,r.jsxs)(i.Alert,{status:"warning",variant:"subtle",mt:"spacer-5",children:[(0,r.jsx)(i.Alert.Icon,{}),(0,r.jsx)(i.Alert.Title,{children:"You are editing your personal information"})]}),C&&(0,r.jsxs)(i.Alert,{status:"error",variant:"subtle",mt:"spacer-5",children:[(0,r.jsx)(i.Alert.Icon,{}),(0,r.jsx)(i.Alert.Title,{children:"There was an error submitting your information. Please try again."})]}),(0,r.jsxs)(i.Flex,{direction:"column",mt:"spacer-5",_last:{pb:{base:"spacer-24",lg:0}},children:[(0,r.jsx)(IdentityFields,{isDisabled:y,mb:{base:H?"spacer-9":0,lg:"spacer-9"}}),H&&(0,r.jsx)(InsuranceFields,{isDisabled:y,insuranceMemberID:null==d?void 0:null===(t=d.fields)||void 0===t?void 0:t.insuranceMemberID,insurance:null==d?void 0:null===(a=d.fields)||void 0===a?void 0:a.insurance,mb:{base:0,lg:"spacer-9"}}),g?(0,r.jsx)(n.D2,{children:renderFormActions()}):renderFormActions()]})]})]})})}},76311:function(e,t,a){a.d(t,{O:function(){return OnboardingChecklist}});var r=a(85893),i=a(71986),n=a(58976),o=a(73857),s=a(84862),l=a(70908),c=a(87536);let OnboardingChecklist=e=>{let{configuration:t,onSubmit:a,showLabs:d=!1}=e,{contentResources:S}=t,u=(0,c.cI)({mode:"onBlur"}),C=(0,s.d)(),renderFormAction=()=>(0,r.jsx)(i.Button,{type:"submit",size:{base:"m",lg:"l"},width:"100%","aria-label":"Continue",trailingIcon:(0,r.jsx)(i.IconArrowRight,{}),children:"Continue"});return(0,r.jsx)(c.RV,{...u,children:(0,r.jsxs)(o.S,{as:"form",onSubmit:u.handleSubmit(a),noValidate:!0,"data-test":l.J.OnboardingChecklist,children:[(0,r.jsx)(o.S.Side,{gap:"spacer-4",children:S.title}),(0,r.jsxs)(o.S.Form,{children:[d?S.checklistWithLabs:S.checklist,C?(0,r.jsx)(n.D2,{children:renderFormAction()}):renderFormAction()]})]})})}},27950:function(e,t,a){a.d(t,{_:function(){return OnboardingErrorScreen}});var r=a(85893),i=a(71986),n=a(73857),o=a(44943),s=a(25675),l=a.n(s);let OnboardingErrorScreen=()=>(0,r.jsxs)(n.D,{gap:{lg:"spacer-20"},alignItems:"center",direction:"column",height:"100%",pt:{base:"spacer-16",md:"spacer-20",lg:"spacer-20"},children:[(0,r.jsxs)(i.Flex,{direction:"column",alignItems:"center",gap:"spacer-6",children:[(0,r.jsx)(l(),{alt:"Application Complete",width:180,height:180,src:"/static/assets/onboarding-error.png"}),(0,r.jsxs)(i.Text,{color:"text-primary",variant:{base:"text-header-L",md:"text-header-XL"},textAlign:"center",children:["Sorry, there was an error",(0,r.jsx)("br",{}),"submitting your information"]})]}),(0,r.jsxs)(i.Box,{position:{base:"fixed",lg:"unset"},bottom:0,pb:{base:"spacer-9",md:"spacer-12",lg:"0"},px:{md:"spacer-20",lg:"0"},children:[(0,r.jsx)(i.Text,{color:"text-secondary",variant:"text-body-bold",textAlign:"center",children:"Need some help?"}),(0,r.jsxs)(i.Text,{color:"text-secondary",variant:"text-body-regular",mt:"spacer-1",textAlign:"center",children:["Please call"," ",(0,r.jsx)(o.R,{fontWeight:"thin"})," ","to speak with a Care Coordinator."]})]})]})},43505:function(e,t,a){a.d(t,{fk:function(){return BMIFields},IQ:function(){return i},Dy:function(){return ComorbidityStatusField},R2:function(){return DateOfBirthField},zi:function(){return EligibilityCriteriaNote},t_:function(){return HighestWeightFields}});var r,i,n=a(85893),o=a(71986),s=a(58976),l=a(38098),c=a(36045),d=a(50574),S=a(87536);let u="currentWeightInPounds",C="heightInFoot",m="heightInInch",BMIFields=e=>{let{isDisabled:t}=e,{register:a,setValue:r,formState:{errors:i}}=(0,S.Gc)(),p=(0,c.T)(u,i,"validate"),h=(0,c.T)(C,i,"validate"),g=(0,c.T)(m,i,"validate");return(0,n.jsxs)(o.Flex,{direction:"column",gap:"spacer-2",children:[(0,n.jsx)(o.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",children:"What is your current weight and height?"}),(0,n.jsxs)(o.Flex,{direction:{base:"column",md:"row",lg:"column",xl:"row"},gap:{base:"spacer-9",xl:"spacer-12"},children:[(0,n.jsx)(o.Flex,{flex:.6,children:(0,n.jsx)(s.CZ,{"data-test":u,isDisabled:t,isInvalid:p,onInput:e=>r(u,e.currentTarget.value),...a(u,{required:!0,validate:e=>{let t=(0,d.M)(e);return t>=1&&t<1e3||l.x[u].validate}})})}),(0,n.jsxs)(o.Flex,{gap:"spacer-4",flex:1,children:[(0,n.jsx)(s.lm,{unit:"ft","data-test":C,isDisabled:t,isInvalid:h,onInput:e=>r(C,e.currentTarget.value),...a(C,{required:!0,validate:e=>{let t=(0,d.M)(e);return t>=4&&t<=7||l.x[C].validate}})}),(0,n.jsx)(s.lm,{"data-test":m,unit:"in",isDisabled:t,isInvalid:g,onInput:e=>r(m,e.currentTarget.value),...a(m,{required:!0,validate:e=>{let t=(0,d.M)(e);return t>=0&&t<=11||l.x[m].validate}})})]})]}),p&&(0,n.jsx)(s.VO,{errors:i,name:u}),h&&(0,n.jsx)(s.VO,{errors:i,name:C}),g&&(0,n.jsx)(s.VO,{errors:i,name:m})]})};(r=i||(i={})).Yes="yes",r.No="no";let p="comorbidity",h=["Asthma","Binge eating disorder","Chronic obstructive pulmonary disease","Cirrhosis","Congestive heart failure","Coronary artery disease","Fatty liver disease","Heart attack","Hyperlipidemia (high cholesterol)","Hypertension (high blood pressure)","Idiopathic intracranial hypertension","Insulin resistance/Metabolic syndrome","Low Testosterone/Hypogonadism in men","NASH (Non-alcoholic steatohepatitis)","Obstructive sleep apnea","Osteoarthritis","Polycystic ovarian syndrome","Prediabetes","Pseudotumor cerebri","Stress urinary incontinence","Stroke"],ComorbidityStatusField=e=>{let{trigger:t,isDisabled:a}=e,{control:r,setValue:i}=(0,S.Gc)();return(0,n.jsxs)(o.Flex,{direction:"column",children:[(0,n.jsxs)(o.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:p,children:["Do you have a weight-related health condition?",(0,n.jsxs)(o.Popover,{trigger:t,closeOnBlur:!0,placement:"auto",children:[(0,n.jsx)(o.Popover.Trigger,{children:(0,n.jsx)(o.Flex,{display:"inline-flex",verticalAlign:"text-top",ml:"spacer-2",children:(0,n.jsx)(o.IconInfoCircle,{size:"m",color:"text-link-primary-default"})})}),(0,n.jsxs)(o.Popover.Content,{children:[(0,n.jsx)(o.Popover.Arrow,{backgroundColor:"text-secondary"}),(0,n.jsx)(o.Popover.Body,{backgroundColor:"text-secondary",borderColor:"transparent",borderRadius:"radii-1",p:"spacer-2",children:(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-light",children:"Examples include heart or cardiovascular disease, high blood pressure, sleep apnea, diabetes, gastrointestinal disease, fatty liver."})})]})]})]}),(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",marginBottom:"spacer-2",children:"If yes, select all that apply. If no, skip to the next question."}),(0,n.jsx)(S.Qr,{name:p,control:r,rules:{required:!1},render:e=>{let{field:{onChange:t}}=e;return(0,n.jsxs)(o.AutocompleteMultiSelect,{items:h,useMultipleSelectionProps:{onSelectedItemsChange:e=>{let{selectedItems:a}=e;t(a),i(p,a,{shouldValidate:!0})}},isDisabled:a,children:[(0,n.jsx)(o.AutocompleteMultiSelect.SelectedItems,{renderSelectedItem:e=>{let{selectedItem:t,removeSelectedItem:r}=e;return(0,n.jsxs)(o.Tag,{size:"s",isDisabled:a,onClick:e=>{e.stopPropagation(),r(t)},cursor:"pointer",children:[(0,n.jsx)(o.Tag.Label,{children:t}),(0,n.jsx)(o.Tag.RightIcon,{as:o.IconX})]})}}),(0,n.jsx)(o.AutocompleteMultiSelect.Input,{"data-test":p,placeholder:"Select health condition",variant:"flushed"}),(0,n.jsx)(o.AutocompleteMultiSelect.List,{"data-test":"".concat(p,"List"),renderItem:e=>(0,n.jsx)(n.Fragment,{children:e}),overflowY:"auto",maxHeight:"13.5rem",zIndex:2})]})}})]})},g="birthdate",DateOfBirthField=e=>{let{isDisabled:t}=e,{register:a,setValue:r,formState:{errors:i}}=(0,S.Gc)(),d=(0,c.T)(g,i,["isValid","isOver18YearsOld","isLessThan150YearsOld"]);return(0,n.jsxs)(o.Flex,{direction:"column",gap:"spacer-2",children:[(0,n.jsx)(o.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:g,children:"What is your date of birth?"}),(0,n.jsx)(s.AM,{id:g,isInvalid:d,isDisabled:t,onInput:e=>r(g,e.currentTarget.value),...a(g,{required:!0,validate:{isValid:e=>s.pm.isValid(e)||l.x[g].isValid,isOver18YearsOld:e=>s.pm.isOver18YearsOld(e)||l.x[g].isOver18YearsOld,isLessThan150YearsOld:e=>s.pm.isLessThan150YearsOld(e)||l.x[g].isLessThan150YearsOld}})}),d&&(0,n.jsx)(s.VO,{errors:i,name:g})]})},EligibilityCriteriaNote=()=>(0,n.jsx)(o.Text,{variant:"text-body-floating-label-regular",color:"text-secondary",textAlign:"center",children:"Meeting eligibility criteria based on this information does not automatically guarantee program enrollment."});var x=a(67294);let b="highestWeightInPounds",y="dateOfHighestWeightValue",HighestWeightFields=e=>{let{isDisabled:t}=e,{register:a,setValue:r,trigger:i,formState:{errors:C},watch:m}=(0,S.Gc)(),p=m(u),h=m(g),H=(0,c.T)(b,C,["isValid","isLowerThanCurrentWeight"]),f=(0,c.T)(y,C,["pattern","min","max"]);return(0,x.useEffect)(()=>{i(b)},[p]),(0,n.jsxs)(o.Flex,{direction:"column",gap:"spacer-2",children:[(0,n.jsxs)(o.Box,{children:[(0,n.jsx)(o.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:b,children:"What was your highest non-pregnancy lifetime weight and when did you reach it?"}),(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"This will help your doctor customize your treatment plan"})]}),(0,n.jsxs)(o.Flex,{gap:"spacer-8",children:[(0,n.jsx)(o.MaskInput,{"data-test":b,"aria-label":"Weight (lbs)",id:b,inputMode:"decimal",size:"l",variant:"flushed",placeholder:"Weight (lbs)",isDisabled:t,isInvalid:H,maskOptions:{mask:/^\d{0,3}(\.\d{0,2})?$/,postfix:" (lbs)"},onInput:e=>r(b,e.currentTarget.value),...a(b,{required:!0,validate:{isValid:e=>{let t=(0,d.M)(e);return t>=1&&t<1e3||l.x[b].isValid},isLowerThanCurrentWeight:e=>{let t=(0,d.M)(p),a=(0,d.M)(e);return a>=t||l.x[b].isLowerThanCurrentWeight}}})}),(0,n.jsx)(o.MaskInput,{"data-test":y,inputMode:"numeric",id:y,size:"l",variant:"flushed",placeholder:"YYYY",isDisabled:t,isInvalid:f,maskOptions:{mask:/^\d{0,4}$/},onInput:e=>{r(y,e.currentTarget.value),4===e.currentTarget.value.length&&i(y)},...a(y,{required:!0,pattern:{value:/^\d{4}$/,message:l.x[y].pattern},min:{value:new Date(h).getFullYear(),message:l.x[y].min},max:{value:new Date().getFullYear(),message:l.x[y].max}})})]}),H&&(0,n.jsx)(s.VO,{errors:C,name:b}),f&&(0,n.jsx)(s.VO,{errors:C,name:y})]})}},73071:function(e,t,a){a.d(t,{b:function(){return PreEligibilityForm}});var r,i,n,o,s=a(85893),l=a(71986),c=a(58976),d=a(73857),S=a(84862),u=a(70908),C=a(87536),m=a(43505),p=a(41240);(r=n||(n={})).Yes="yes",r.No="no";let h="bariatricSurgery",BariatricSurgeryField=e=>{let{isDisabled:t}=e,{register:a}=(0,C.Gc)();return(0,s.jsxs)(l.Flex,{direction:"column",gap:"spacer-4",children:[(0,s.jsx)(l.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",children:"Have you had Bariatric surgery?"}),(0,s.jsxs)(l.RadioGroup,{display:"flex",gap:"spacer-3",isDisabled:t,"data-test":h,"data-testid":h,name:h,children:[(0,s.jsx)(p.D,{name:h,value:"yes",size:"m",isDisabled:t,"aria-label":"bariatric-surgery-yes",...a(h,{required:!0}),children:"Yes"}),(0,s.jsx)(p.D,{value:"no",size:"m",...a(h),name:h,isDisabled:t,"aria-label":"bariatric-surgery-no",children:"No"})]})]})};(i=o||(o={})).Yes="yes",i.No="no";let g="diabetes",DiabetesField=e=>{let{isDisabled:t}=e,{register:a}=(0,C.Gc)();return(0,s.jsxs)(l.Flex,{direction:"column",gap:"spacer-4",children:[(0,s.jsx)(l.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",children:"Do you have Type 1 or Type 2 Diabetes?"}),(0,s.jsxs)(l.RadioGroup,{display:"flex",gap:"spacer-3",isDisabled:t,"data-test":g,"data-testid":g,name:g,children:[(0,s.jsx)(p.D,{name:g,value:"yes",size:"m",isDisabled:t,"aria-label":"diabetes-yes",...a(g,{required:!0}),children:"Yes"}),(0,s.jsx)(p.D,{value:"no",size:"m","aria-label":"diabetes-no",...a(g),name:g,isDisabled:t,children:"No"})]})]})},PreEligibilityForm=e=>{let{configuration:t,loading:a=!1,onSubmit:r}=e,{contentResources:i}=t,n=(0,C.cI)({mode:"onBlur"}),o=(0,S.d)(),renderFormAction=()=>(0,s.jsx)(l.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!n.formState.isValid,width:"100%",isLoading:a,"aria-label":"Am I eligible?",children:"Am I eligible?"});return(0,s.jsx)(C.RV,{...n,children:(0,s.jsxs)(d.S,{as:"form",onSubmit:n.handleSubmit(e=>{var t;let a=(null===(t=e.comorbidity)||void 0===t?void 0:t.length)>0,i={...e,comorbidities:e.comorbidity,comorbidity:a?m.IQ.Yes:m.IQ.No};r(i)}),noValidate:!0,"data-test":u.J.PreEligibility,children:[(0,s.jsxs)(d.S.Side,{children:[i.title,!o&&i.bmiEnrollmentDisclaimer]}),(0,s.jsxs)(d.S.Form,{children:[(0,s.jsx)(m.R2,{isDisabled:a}),(0,s.jsx)(m.Dy,{isDisabled:a,trigger:o?"click":"hover"}),(0,s.jsx)(DiabetesField,{isDisabled:a}),(0,s.jsx)(BariatricSurgeryField,{isDisabled:a}),(0,s.jsx)(m.fk,{isDisabled:a}),(0,s.jsx)(m.t_,{isDisabled:a}),o?(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)(l.Flex,{gap:"spacer-10",direction:"column",pb:"spacer-24",children:[i.bmiEnrollmentDisclaimer,(0,s.jsx)(m.zi,{})]}),(0,s.jsx)(c.D2,{children:renderFormAction()})]}):(0,s.jsxs)(l.Flex,{direction:"column",gap:"spacer-5",children:[renderFormAction(),(0,s.jsx)(m.zi,{})]})]})]})})}},9051:function(e,t,a){a.d(t,{R:function(){return ReviewConsents}});var r=a(85893),i=a(66122),n=a(3183),o=a(71986),s=a(58976),l=a(73857),c=a(44943),d=a(67294);let ConsentDeclineModal=e=>{let{isOpen:t,onClose:a,onDeclineConsent:i,consentTitle:n,isConsentRequired:s=!1}=e;return(0,r.jsxs)(o.Modal,{isOpen:t,onClose:a,autoFocus:!1,isCentered:!0,children:[(0,r.jsx)(o.Modal.Overlay,{}),(0,r.jsxs)(o.Modal.Content,{px:"spacer-7",py:"spacer-6",maxWidth:{base:"342px",md:"460px"},borderRadius:"radii-4",children:[(0,r.jsx)(o.Modal.Header,{p:0,children:(0,r.jsxs)(o.Text,{variant:"text-body-large-bold",children:["Decline the"," ",n,"?"]})}),(0,r.jsx)(o.Modal.Body,{p:0,children:(0,r.jsx)(o.Text,{color:"text-secondary",variant:"text-body-regular",mb:"spacer-7",children:s?"Agreement with this document is required for us to provide care for you. Declining will stop you from joining FlyteHealth.":"To continue, we need to know if you decline or agree to this document."})}),(0,r.jsxs)(o.Modal.Footer,{flexDirection:{base:"column",md:"row-reverse"},gap:"spacer-4",p:0,children:[(0,r.jsx)(o.Button,{variant:"secondary",size:"m",width:{base:"100%",md:"auto"},flex:{base:1,md:"auto"},onClick:a,children:"Go back"}),(0,r.jsx)(o.Button,{variant:"destroy",size:"m",width:{base:"100%",md:"auto"},flex:{base:1,md:"1 0 0"},onClick:i,children:"I decline"})]})]})]})};var S=a(22424);let ConsentDetailModal=e=>{let{isOpen:t,consent:a,onClose:i,onDeclineConsent:n,onAgreeConsent:s,agreementLink:l,loading:u=!1,hasError:C=!1}=e,m=(0,d.useRef)(null),p=(0,d.useMemo)(()=>S.Z.sanitize(a.forms[0]),[a]);return(0,r.jsxs)(o.Modal,{isOpen:t,onClose:i,autoFocus:!1,isCentered:!0,initialFocusRef:m,children:[(0,r.jsx)(o.Modal.Overlay,{}),(0,r.jsxs)(o.Modal.Content,{px:{base:"spacer-6",lg:"spacer-7"},pb:"spacer-6",gap:"spacer-6",mx:0,maxWidth:{lg:"680px"},mb:{base:0,lg:"auto"},height:{base:"calc(100% - 24px)",lg:"100%"},maxHeight:{lg:"80%"},children:[(0,r.jsxs)(o.Modal.Header,{p:0,children:[(0,r.jsx)(o.Text,{variant:"text-body-large-bold",pt:"20px",children:a.title}),(0,r.jsx)(o.Modal.CloseButton,{color:"text-secondary"})]}),(0,r.jsxs)(o.Modal.Body,{p:0,overflow:"hidden",display:"flex",flexDirection:"column",children:[C&&(0,r.jsxs)(o.Alert,{status:"error",variant:"subtle",mb:{base:"spacer-3",lg:"spacer-6"},flex:"none",children:[(0,r.jsx)(o.Alert.Icon,{}),(0,r.jsxs)(o.Alert.Title,{children:["We couldn't process the documents. Please try again or call"," ",(0,r.jsx)(c.R,{size:"m",variant:"link-primary","aria-label":"Contact Us",isInline:!0,children:"(844) 359-8363"})," ","to speak with a Care Coordinator."]})]}),(0,r.jsxs)(o.Text,{color:"text-secondary",variant:"text-body-regular",mb:{base:"spacer-3",lg:"spacer-6"},children:['By selecting "I agree", you agree to the terms of the'," ",(0,r.jsx)(o.Link,{textDecoration:"underline",href:l,target:"_blank",rel:"noopener noreferrer",isInline:!0,children:a.title}),". We will email you a confirmation for your records."]}),(0,r.jsx)(o.Flex,{height:"100%",direction:"column",wordBreak:"break-word",p:"spacer-3",backgroundColor:"background-page-01",borderRadius:"radii-3",overflow:"auto",__css:{ul:{paddingLeft:"2.5rem"},"h1, h2, h3, h4, h5, h6":{fontWeight:"bold",marginY:"0.67em"},"& p":{marginBottom:"1em"}},dangerouslySetInnerHTML:{__html:p}})]}),(0,r.jsxs)(o.Modal.Footer,{flexDirection:"row-reverse",gap:"spacer-2",p:0,children:[(0,r.jsx)(o.Button,{variant:"primary",size:{base:"m",lg:"l"},flex:1,width:"100%",onClick:s,ref:m,isLoading:u,"data-test":"agree-consent",children:"I agree"}),(0,r.jsx)(o.Button,{isDisabled:u,variant:"primary-alt",size:{base:"m",lg:"l"},flex:1,width:"100%",onClick:n,children:"I decline"})]})]})]})};var u=a(84862),C=a(87536);let m={consents:"https://www.joinflyte.com/patient-consent",consentHie:"https://www.joinflyte.com/health-information-exchange-consent"},ConsentReviewCard=e=>{let{consent:t,isRequired:a,isApproved:i,onReview:n,...s}=e,{register:l}=(0,C.Gc)();return(0,r.jsxs)(o.Flex,{onClick:n,cursor:"pointer",py:"spacer-4",px:"spacer-3",backgroundColor:i?"background-success":"background-card",border:"1px solid",borderColor:i?"alert-success-default":"primary-default",borderRadius:"radii-4",alignItems:"center",gap:"spacer-5",...!i&&{_hover:{backgroundColor:"background-action-hover"},_active:{backgroundColor:"background-action-pressed"}},...l(t.formType,{validate:e=>void 0!==e,required:a}),...s,children:[(0,r.jsx)(o.IconFile,{size:"l",color:"text-secondary"}),(0,r.jsxs)(o.Flex,{direction:"column",flex:1,children:[(0,r.jsxs)(o.Flex,{flexDirection:"row",flexWrap:"wrap",gap:"8px",alignItems:"center",children:[(0,r.jsx)(o.Text,{variant:"text-header-S",children:t.title}),a&&!i&&(0,r.jsx)(o.Badge,{variant:"outline",status:"secondary",textTransform:"capitalize",children:"Required"})]}),!i&&(0,r.jsx)(o.Button,{mt:"6px",onClick:e=>{e.stopPropagation(),n()},variant:"link-primary",textDecoration:"underline",alignSelf:"start",_hover:{textDecoration:"underline"},p:0,size:"s","data-test":"review-consent",children:"Review and sign"})]}),(0,r.jsx)(o.IconCircleCheckFilled,{size:"l",color:i?"text-success":"primary-disabled"})]})},p=["consents"],ReviewConsents=e=>{let{consents:t,configuration:a,hasError:S=!1,loading:h=!1,onSubmit:g}=e,{contentResources:x}=a,b=(0,C.cI)({mode:"onBlur"}),{track:y}=(0,n.useAnalytics)(),H=(0,u.d)(),[f,v]=(0,d.useState)(null),[I,R]=(0,d.useState)(!1),D=t.sort((e,t)=>(p.includes(t.formType)?1:0)-(p.includes(e.formType)?1:0)),E=p.some(e=>{let t=b.getValues()[e];return!1===t}),renderFormAction=()=>(0,r.jsx)(o.Button,{type:"submit",size:{base:"m",lg:"l"},width:"100%","aria-label":"Continue",isDisabled:h||!b.formState.isValid||0===t.length,isLoading:h,trailingIcon:(0,r.jsx)(o.IconArrowRight,{}),children:"Continue"}),handleOpenConsent=e=>{v(e),y(i.U.patientConsent)};return(0,r.jsxs)(r.Fragment,{children:[E&&(0,r.jsx)(o.Alert,{status:"warning",variant:"subtle",px:0,children:(0,r.jsx)(o.Flex,{margin:"0 auto",maxWidth:"90rem",width:"100%",px:{base:"spacer-6",md:"spacer-9",lg:"spacer-14",xl:"spacer-20",xxl:"spacer-28"},children:(0,r.jsxs)(o.Flex,{children:[(0,r.jsx)(o.Alert.Icon,{}),(0,r.jsxs)(o.Flex,{direction:"column",children:[(0,r.jsx)(o.Alert.Title,{children:"Patient Consent Form"}),(0,r.jsx)(o.Alert.Description,{children:"Agreement with the Patient Consent document is required for us to provide care for you."})]})]})})}),(0,r.jsx)(C.RV,{...b,children:(0,r.jsxs)(l.S,{as:"form",onSubmit:b.handleSubmit(g),noValidate:!0,gap:{base:"spacer-6",md:"spacer-10"},width:"100%",children:[(0,r.jsx)(l.S.Side,{gap:0,children:x.title}),(0,r.jsxs)(l.S.Form,{width:"100%",gap:"spacer-9",children:[S&&(0,r.jsxs)(o.Alert,{status:"error",variant:"subtle",width:"100%",children:[(0,r.jsx)(o.Alert.Icon,{}),(0,r.jsxs)(o.Alert.Title,{children:["We couldn't process the documents. Please try again or call"," ",(0,r.jsx)(c.R,{size:"m",variant:"link-primary","aria-label":"Contact Us",isInline:!0,fontWeight:"bold",children:"(844) 359-8363"})," ","to speak with a Care Coordinator."]})]}),(0,r.jsx)(o.Flex,{direction:"column",gap:"spacer-5",children:0===t.length?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)(o.Skeleton,{height:"80px",borderRadius:"radii-4"}),(0,r.jsx)(o.Skeleton,{height:"80px",borderRadius:"radii-4"})]}):D.map(e=>(0,r.jsx)(ConsentReviewCard,{consent:e,isRequired:p.includes(e.formType),isApproved:b.getValues()[e.formType],onReview:()=>handleOpenConsent(e)},e.formType))}),H?(0,r.jsx)(s.D2,{children:renderFormAction()}):renderFormAction()]})]})}),f&&(0,r.jsx)(ConsentDetailModal,{isOpen:!!f,onClose:()=>v(null),onAgreeConsent:()=>{b.setValue(f.formType,!0,{shouldValidate:!0}),v(null)},onDeclineConsent:()=>R(!0),consent:f,agreementLink:m[f.formType]}),(0,r.jsx)(ConsentDeclineModal,{isOpen:I,onClose:()=>R(!1),onDeclineConsent:()=>{b.setValue(f.formType,!1,{shouldValidate:!0}),R(!1),v(null),y(i.U.declinePatientConsent)},consentTitle:null==f?void 0:f.title})]})}},93103:function(e,t,a){a.d(t,{s:function(){return CustomError}});var r=a(19182);let CustomError=class CustomError extends Error{constructor(e,t,a){super(e),this.message=e,this.code=t,this.status=a,this.name=this.constructor.name,Object.setPrototypeOf(this,new.target.prototype),r.ZP.error(e,{error_code:t,error_type:this.constructor.name,stack:this.stack})}}},41016:function(e,t,a){a.d(t,{WB:function(){return InvalidInputError},q7:function(){return InvalidDateFormatError}});var r=a(93103);let InvalidInputError=class InvalidInputError extends r.s{constructor(e){super(e,"INVALID_INPUT")}};let InvalidDateFormatError=class InvalidDateFormatError extends r.s{constructor(e){super(e,"INVALID_DATE_FORMAT")}}},84862:function(e,t,a){a.d(t,{d:function(){return useIsMobile}});var r=a(71986);let useIsMobile=()=>{let e=(0,r.useBreakpointValue)({base:!0,lg:!1},{ssr:!1});return e}},64504:function(e,t,a){a.d(t,{R:function(){return useWorkflowTracker}});var r=a(66122),i=a(3183),n=a(67294);let useWorkflowTracker=(e,t)=>{let{track:a}=(0,i.useAnalytics)(),o=(0,n.useRef)(null);(0,n.useEffect)(()=>{o.current!==e&&(a(r.U[e],{partner:t}),o.current=e)},[e,a])}},19182:function(e,t,a){a.d(t,{ZP:function(){return c}});var r=a(53416),i=a(36559),n=a.n(i),o=a(34155);let getLoggerConfig=()=>({level:o.env.LOG_LEVEL||"info",formatters:{level:e=>({level:e.toUpperCase()})},timestamp:()=>',"time":"'.concat(new Date(Date.now()).toISOString(),'"'),base:{environment:"production",service:"flyte-registration",branch:o.env.AWS_BRANCH||o.env.BRANCH||"local"}});var s=a(34155);let AsyncLocalStorage=class AsyncLocalStorage{run(e,t){let a=this.currentId++;return this.storage.set(a,e),t().finally(()=>this.storage.delete(a))}getContext(){return this.storage.get(this.currentId-1)}setContext(e){this.storage.set(this.currentId-1,e)}constructor(){this.storage=new Map,this.currentId=0}};let AppLogger=class AppLogger{setContext(e){let t=this.contextStorage.getContext()||{};this.contextStorage.setContext({...t,...e})}async withContext(e,t){return this.contextStorage.run(e,t)}createRequestContext(e,t,a){let i=(0,r.x0)();a.setHeader("x-request-id",i);let n={host:t.headers.host,referer:t.headers.referer,handler:e,requestId:i,method:t.method,url:t.url,path:t.url?new URL(t.url,"http://".concat(t.headers.host)).pathname:void 0,query:t.query,params:t.query,timestamp:new Date().toISOString(),..."dev"===s.env.NODE&&{body:t.body}};return this.setContext(n),n}createLogEntry(e,t){let a=this.contextStorage.getContext();return{...a,environment:"production",service:(null==a?void 0:a.service)||"flyte-registration",branch:s.env.AWS_BRANCH||s.env.BRANCH||"local",...t,message:e}}error(e,t){this.pinoLogger.error(this.createLogEntry(e,t))}warn(e,t){this.pinoLogger.warn(this.createLogEntry(e,t))}info(e,t){this.pinoLogger.info(this.createLogEntry(e,t))}debug(e,t){this.pinoLogger.debug(this.createLogEntry(e,t))}constructor(){this.pinoLogger=n()(getLoggerConfig()),this.contextStorage=new AsyncLocalStorage}};let l=new AppLogger;var c=l},19474:function(e,t,a){a.d(t,{N:function(){return SEIUWorkflow}});var r,i,n=a(85893),o=a(71986),s=a(44761),l=a(33640),c=a(65660),d=a(20410),S=a(31540),u=a(53157),C=a(39424),m=a(27350),p=a(86640),h=a(96693),g=a(83344),x=a(76311),b=a(27950),y=a(73071),H=a(9051),f=a(64504),v=a(56401),I=a(70908),R=a(17304),D=a(94445),E=a(67294);Object.values(v.PF).filter(e=>e!==v.PF.SelfPay);var j=a(58976),w=a(73857),T=a(84862),A=a(87536),k=a(97324),P=a(68701),L=a(36045);let M="insuranceMemberID",F=(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Your Unique ID is your ten-digit Benefit Funds’ Member ID Number. For Eligible dependents, use the guidance below:"}),SeiuInsuranceMemberIdField=e=>{let{label:t="1199SEIU Unique ID",placeholder:a="Unique ID Number",description:r=F,tooltip:i,type:s,maxLength:l,minLength:c,maskOptions:d,inputMode:S,registerOptions:u,isDisabled:C=!1,isRequired:m=!0,...p}=e,{setValue:h,register:g,formState:{errors:x}}=(0,A.Gc)(),b=(0,L.T)(M,x,["minLength","maxLength","pattern"]);return(0,n.jsxs)(o.Flex,{direction:"column",gap:"spacer-2",...p,children:[(0,n.jsxs)(o.Box,{children:[(0,n.jsxs)(o.Flex,{gap:"spacer-2",alignItems:"center",children:[(0,n.jsx)(o.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:M,children:t}),i&&(0,n.jsx)(o.Tooltip,{label:i,placement:"auto-end",children:(0,n.jsx)(o.Flex,{children:(0,n.jsx)(o.IconInfoCircle,{size:"m",color:"text-link-primary-default"})})})]}),r]}),(0,n.jsx)(P.o,{"data-test":M,id:M,isInvalid:b,isDisabled:C,placeholder:a,type:s,inputMode:S,maxLength:l,minLength:c,maskOptions:d,onInput:e=>{let t=e.currentTarget.value,a=!c||c&&t.length>=c;h(M,t,{shouldValidate:a})},...g(M,{required:m,...u})}),(0,n.jsxs)(o.Text,{variant:"text-body-regular",fontSize:12,color:"text-secondary",children:[(0,n.jsx)("b",{children:"- For Spouse:"})," ","member’s ID number + first nine characters of spouse’s first name + S."," ",(0,n.jsx)("br",{}),"Example: 1234567890JohnathonS",(0,n.jsx)("br",{}),(0,n.jsx)("b",{children:"- For Child (18 or older)"}),": member’s ID number + first nine characters of dependent’s first name + D. Example: 1234567890MariaD"]}),b&&(0,n.jsx)(j.VO,{errors:x,name:M})]})},SeiuInsuranceDetailsForm=e=>{let{configuration:t,loading:a=!1,onSubmit:r,onBack:i}=e,{contentResources:s,fields:l}=t,c=(0,A.cI)({mode:"onBlur"}),d=(0,T.d)(),S=c.watch(k.o0)===v.eF.SelfPay,u=c.watch(k.OF)===v.PF.Other;(0,E.useEffect)(()=>{S&&(c.resetField(k.OF),c.resetField(k.rI))},[S,c]),(0,E.useEffect)(()=>{c.resetField(k.zQ)},[c.watch(k.OF),c]);let renderFormActions=()=>(0,n.jsxs)(o.Flex,{gap:{base:"spacer-8",md:"spacer-16"},alignItems:"center",flex:{base:1,lg:"unset"},children:[(0,n.jsx)(o.Button,{size:{base:"m",lg:"l"},isLoading:a,variant:"link","aria-label":"Back",leadingIcon:(0,n.jsx)(o.IconArrowLeft,{}),onClick:i,children:"Back"}),(0,n.jsx)(o.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!c.formState.isValid,flex:1,isLoading:a,trailingIcon:(0,n.jsx)(o.IconArrowRight,{}),"aria-label":"Continue",children:"Continue"})]});return(0,n.jsx)(A.RV,{...c,children:(0,n.jsxs)(w.S,{as:"form",onSubmit:c.handleSubmit(r),noValidate:!0,children:[(0,n.jsx)(w.S.Side,{gap:0,flex:{base:"none",lg:1},children:s.title}),(0,n.jsxs)(w.S.Form,{children:[(null==l?void 0:l.insuranceCoverage)&&(0,n.jsx)(k.nK,{isDisabled:a}),(null==l?void 0:l.insurance)&&(0,n.jsx)(k.vu,{isDisabled:a||S,isRequired:!S,...null==l?void 0:l.insurance},S.toString()),u&&(0,n.jsx)(k.dn,{isDisabled:a,...null==l?void 0:l.insuranceOther}),(0,n.jsx)(SeiuInsuranceMemberIdField,{isDisabled:a||S,isRequired:!S,pb:{base:"spacer-24",lg:0},...null==l?void 0:l.insuranceMemberID}),d?(0,n.jsx)(j.D2,{children:renderFormActions()}):renderFormActions()]})]})})};var O=a(11841),B=a(91372),U=a(60948),J=a(21097),N=a(54285),W=a(33546),V=a(34474),_=a(64267),q=a(10265),z=a(63317),Y=a(10503),X=a(19171),G=a(67618),K=a(10002),Q=a(13064),$=a(94788),Z=a(30368),ee=a(47243),et=a(37053);let isEligibleForAutoEnrollment=e=>e===et._.FULL_MATCH||e===et._.ELIGIBLE_MATCH||e===et._.PERSON_MATCH,getLeadStatus=e=>{switch(e){case et._.INSURANCE_MATCH:case et._.EXPIRED:case et._.NOT_FOUND:return v.rl.EligibleWaiting;case et._.PERSON_MATCH:case et._.FULL_MATCH:case et._.ELIGIBLE_MATCH:default:return}};(r=i||(i={})).CreateLead="createLead",r.CreateContact="createContact",r.UpdateContact="updateContact",r.DetermineContactOrLead="determineContactOrLead",r.FetchConsents="fetchConsents",r.UpdateEmail="updateEmail",r.CheckEligibility="checkEligibility";let ea={...K.a,...i},er=G.aU[q.kT["1199SEIU"]],ei={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",ssn:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insurance:void 0,lastName:"",phone:"",termsAgreement:!1,howDidYouFindUS:"",diabetes:"",bariatricSurgery:"",comorbidities:[""]},eligibilityCheckMatchType:void 0,matchingRecord:void 0,bmi:void 0,otpData:void 0,consentsData:{items:[],userConsentStatus:[]},contactData:{},passwordData:{password:void 0,confirmPassword:void 0},flyteUserData:void 0,error:void 0},en={...z.OX,...z.cp,...z.sW,...z.Oz,...z.S8,...z.oQ,...z.q6,...z.nB,...z.v1,...(0,z.Ww)(ei).reset},eo=(0,$.cY)({types:{},guards:{isPreEligibilityMet:e=>{let{context:{formData:t,bmi:a}}=e;return Q.Pq["1199SEIU"]({bmi:a,comorbidity:t.comorbidity,birthdate:t.birthdate})},isApplicationReviewRequired:e=>{let{context:{eligibilityCheckMatchType:t}}=e;return!isEligibleForAutoEnrollment(t)},isApplicationDetected:X.Q,isAthenaRecordCreated:Y.w},actions:en}).createMachine({context:()=>ei,id:"SEIUMachine",initial:ea.PreEligibility,states:{[ea.PreEligibility]:{id:ea.PreEligibility,initial:ea.Idle,states:{[ea.Idle]:{on:{SUBMIT:{target:ea.Submitting,actions:"updateFormData"}}},[ea.Submitting]:{entry:"assignBMI",always:[{target:"#".concat(ea.ContactDetails),guard:"isPreEligibilityMet"},{target:"#".concat(ea.EligibilityUnmet)}]}}},[ea.ContactDetails]:{id:ea.ContactDetails,initial:ea.Idle,states:{[ea.Idle]:{on:{SUBMIT:{target:"#".concat(ea.InsuranceDetails),actions:"updateFormData"}}}}},[ea.InsuranceDetails]:{id:ea.InsuranceDetails,initial:ea.Idle,states:{[ea.Idle]:{on:{BACK:{target:"#".concat(ea.ContactDetails)},SUBMIT:{target:"#".concat(ea.InsuranceDetailsReview),actions:"updateFormData"}}}}},[ea.InsuranceDetailsReview]:{id:ea.InsuranceDetailsReview,initial:ea.Idle,states:{[ea.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:ea.Submitting}}},[ea.Submitting]:{id:ea.Submitting,initial:ea.CheckEligibility,states:{[ea.CheckEligibility]:{id:ea.CheckEligibility,invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={...t,insurance:G.Er[q.kT["1199SEIU"]],benefitProgram:G.Q1[q.kT["1199SEIU"]]};return await (0,W.m)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:[{actions:(0,ee.a)({eligibilityCheckMatchType:e=>{let{event:t}=e;return t.output.data.matchType},matchingRecord:e=>{let{event:t}=e;return t.output.data.matchingRecord}}),target:"#".concat(ea.DetermineContactOrLead)}],onError:"#".concat(ea.InsuranceDetailsReview,".").concat(ea.Error)}},[ea.DetermineContactOrLead]:{id:ea.DetermineContactOrLead,always:[{guard:"isApplicationReviewRequired",target:ea.CreateLead},{target:ea.CreateContact}]},[ea.CreateContact]:{id:ea.CreateContact,invoke:{src:(0,Z.p4)(async e=>{var t;let{input:a}=e,r=null===(t=a.matchingRecord)||void 0===t?void 0:t.accountName,i={...a.formData,employmentVerificationCode:a.formData.insuranceMemberID,eligibilityVerifiedBy:q.Vn.Evolve,insuranceMemberID:a.formData.insuranceMemberID,company:er,insurance:G.KG[q.kT["1199SEIU"]],evolveOrganization:q.bV["1199SEIU"],accountId:G.kS[q.kT["1199SEIU"]],...r&&{participantDepartmentorOrg:r}};return await (0,N.rE)(i)}),input:e=>{let{context:t}=e;return t},onDone:{actions:"assignContactData",target:"#".concat(ea.EmailVerification)},onError:[{guard:"isApplicationDetected",target:"#".concat(ea.ApplicationDetected)},{target:"#".concat(ea.InsuranceDetailsReview,".").concat(ea.Error)}]}},[ea.CreateLead]:{id:ea.CreateLead,invoke:{src:(0,Z.p4)(async e=>{var t;let{input:a}=e,r=null===(t=a.matchingRecord)||void 0===t?void 0:t.accountName,i={...a.formData,employmentVerificationCode:a.formData.insuranceMemberID,insuranceMemberID:a.formData.insuranceMemberID,company:er,insurance:G.KG[q.kT["1199SEIU"]],evolveOrganization:q.bV["1199SEIU"],leadStatus:getLeadStatus(a.eligibilityCheckMatchType),automateEvolveEnrollment:isEligibleForAutoEnrollment(a.eligibilityCheckMatchType),...r&&{participantDepartmentorOrg:r}};return await (0,_.$)(i)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isApplicationReviewRequired",target:"#".concat(ea.ApplicationReview)},{target:"#".concat(ea.ApplicationComplete)}],onError:[{guard:"isApplicationDetected",target:"#".concat(ea.ApplicationDetected)},{target:"#".concat(ea.InsuranceDetailsReview,".").concat(ea.Error)}]}}}},[ea.Error]:{id:"".concat(ea.InsuranceDetailsReview,".").concat(ea.Error),on:{SUBMIT:{actions:"updateFormData",target:ea.Submitting}}}}},[ea.EmailVerification]:{id:ea.EmailVerification,initial:ea.Idle,states:{[ea.Idle]:{id:"".concat(ea.EmailVerification,".").concat(ea.Idle),on:{SUBMIT:{actions:"assignOtpCode",target:ea.Submitting},RESEND_EMAIL_VERIFICATION:{target:ea.Idle,reenter:!0},UPDATE_EMAIL:{target:ea.UpdateEmail}},invoke:{input:e=>{var t;let{context:a,event:r}=e;return{email:a.formData.email,firstName:a.formData.firstName,onSuccess:null==r?void 0:null===(t=r.data)||void 0===t?void 0:t.onSuccess}},src:(0,Z.p4)(async e=>{let{input:t}=e,a={email:t.email,firstName:t.firstName},r=await (0,B.t)(a);return{token:r.data.token,onSuccess:t.onSuccess}}),onDone:{actions:[(0,ee.a)({otpData:e=>{let{context:t,event:a}=e;return{...t.otpData,token:a.output.token}}}),e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}]},onError:ea.Error}},[ea.Submitting]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,token:t.otpData.token,otp:t.otpData.otp};return await (0,U.M)(a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(ea.OnboardingChecklist),onError:ea.Error}},[ea.Error]:{on:{SUBMIT:{actions:"assignOtpCode",target:ea.Submitting},RESEND_EMAIL_VERIFICATION:{target:ea.Idle},UPDATE_EMAIL:{target:ea.UpdateEmail}}},[ea.UpdateEmail]:{initial:ea.Idle,states:{[ea.Idle]:{invoke:{input:e=>{let{context:t,event:a}=e;return{contactId:t.contactData.contactId,email:a.data.email,onSuccess:a.data.onSuccess}},src:(0,Z.p4)(async e=>{let{input:t}=e,a={contactId:t.contactId,email:t.email};await (0,N.Tk)(a);let r={email:t.email,onSuccess:t.onSuccess};return r}),onDone:{actions:["assignNewEmail",e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}],target:"#".concat(ea.EmailVerification,".").concat(ea.Idle)},onError:ea.Error}},[ea.Error]:{on:{SUBMIT:{target:"#".concat(ea.EmailVerification,".").concat(ea.Idle)},RESEND_EMAIL_VERIFICATION:{target:"#".concat(ea.EmailVerification,".").concat(ea.Idle)},UPDATE_EMAIL:{target:ea.Idle}}}}}}},[ea.ReviewConsents]:{id:ea.ReviewConsents,initial:ea.FetchConsents,states:{[ea.Idle]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:ea.Submitting}}},[ea.FetchConsents]:{invoke:{src:(0,Z.p4)(async()=>await (0,J.J)()),onDone:{actions:"assignConsents",target:ea.Idle},onError:ea.Error}},[ea.Submitting]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={patientIdentifier:t.contactData.contactId,firstName:t.formData.firstName,lastName:t.formData.lastName,phone:t.formData.phone,email:t.formData.email,birthDate:t.formData.birthdate,state:t.formData.state,heightInInch:t.formData.heightInInch,heightInFeet:t.formData.heightInFoot,currentWeightInPounds:t.formData.currentWeightInPounds,evolveOrganization:q.bV["1199SEIU"],consents:t.consentsData.userConsentStatus};return await (0,V.D)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{actions:"assignFlyteUserData",target:ea.UpdateContact}],onError:"#".concat(ea.OnboardingUserError)}},[ea.UpdateContact]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={contactId:t.contactData.contactId,evolvePatientID:t.flyteUserData.patientId};return await (0,N.Tk)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isAthenaRecordCreated",target:"#".concat(ea.CreatePassword)},{target:"#".concat(ea.OnboardingUserError)}],onError:"#".concat(ea.OnboardingUserError)}},[ea.Error]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:ea.Submitting}}}}},[ea.CreatePassword]:{id:ea.CreatePassword,initial:ea.Idle,states:{[ea.Idle]:{on:{SUBMIT:{actions:"assignPasswordData",target:ea.Submitting}}},[ea.Submitting]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,password:t.passwordData.password,confirmPassword:t.passwordData.confirmPassword};return await (0,O.x)(t.flyteUserData.verifyToken,a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(ea.AppDownload),onError:{target:ea.Error,actions:"assignError"}}},[ea.Error]:{on:{SUBMIT:{actions:["resetError","assignPasswordData"],target:ea.Submitting}}}}},[ea.OnboardingChecklist]:{id:ea.OnboardingChecklist,on:{SUBMIT:{target:"#".concat(ea.ReviewConsents)}}},[ea.AppDownload]:{id:ea.AppDownload},[ea.ApplicationReview]:{id:ea.ApplicationReview},[ea.OnboardingUserError]:{id:ea.OnboardingUserError},[ea.ApplicationComplete]:{id:ea.ApplicationComplete},[ea.ApplicationDetected]:{id:ea.ApplicationDetected},[ea.EligibilityUnmet]:{id:ea.EligibilityUnmet,initial:ea.Idle,states:{[ea.Idle]:{on:{SUBMIT:{target:ea.Submitting,actions:"updateFormData"}}},[ea.Submitting]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={...t,company:er,leadStatus:q.rl.Ineligible,ineligibilityReason:q.ib.BMI,automateEvolveEnrollment:!1};return await (0,_.$)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:ea.Success,onError:ea.Error}},[ea.Success]:{},[ea.Error]:{on:{SUBMIT:{target:ea.Submitting}}}}}},on:{RESET:{target:"#".concat(ea.PreEligibility),actions:"reset"}}});var es=a(56344);let el={[I.J.PreEligibility]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"Let's make sure you're eligible for the FlyteHealth program."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"To be eligible for the FlyteHealth program through the 1199SEIU Benefit Funds, you must meet specific age and Body Mass Index (BMI)* requirements."})]}),bmiEnrollmentDisclaimer:(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. FlyteHealth providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the FlyteHealth program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[I.J.EligibilityUnmet]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Unfortunately, you are not eligible to join FlyteHealth at this time."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"The FlyteHealth program requires a minimum BMI of 27+ (plus one or more weight-related health conditions) or a BMI of 30+."})]})},[I.J.ContactDetails]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Next, tell us about yourself"}),(0,n.jsxs)(o.TextPairing.SubLabel,{color:"text-secondary",children:["To help match your information with the 1199SEIU Health Benefits Plan, we need to verify a few personal details.",(0,n.jsx)("br",{})," ",(0,n.jsx)("br",{}),"Be sure to have your member ID card handy for the next step."]})]})},[I.J.InsuranceDetails]:{title:(0,n.jsxs)(o.Text,{variant:"text-header-2XL",color:"text-secondary-negative",children:["One more thing:"," ",(0,n.jsx)(o.Text,{as:"span",variant:"text-header-2XL",color:"text-primary",children:"Do you have health insurance?"})]})},[I.J.InsuranceDetailsReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{children:"Let's review: Is your info correct?"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Please double-check the information you provided to make sure everything is correct."})]})},[I.J.ApplicationComplete]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Welcome aboard! We're so excited you're here."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Next, we need to confirm your email. Click the link we sent to:"})]}),description:(0,n.jsx)(o.Text,{mt:"spacer-8",color:"text-secondary",variant:"text-body-regular",children:"Can’t find the email? Make sure to check your Spam folder."})},[I.J.ApplicationReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]})},[I.J.ApplicationDetected]:{title:(0,n.jsx)(o.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,n.jsx)(o.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[I.J.EmailVerification]:es.T[I.J.EmailVerification],[I.J.OnboardingChecklist]:es.T[I.J.OnboardingChecklist],[I.J.CreatePassword]:es.T[I.J.CreatePassword],[I.J.AppDownload]:es.T[I.J.AppDownload],[I.J.ReviewConsents]:es.T[I.J.ReviewConsents]},ec=[v.Op.BenefitsWebsite,v.Op.CoworkerReferral,v.Op.PrescriptionDenial,v.Op.ProviderReferral,v.Op.WordOfMouth,v.Op.Other],ed={[I.J.ContactDetails]:{state:{options:j.Fp},howDidYouFindUs:{options:ec}},[I.J.InsuranceDetails]:{insuranceMemberID:{}},[I.J.InsuranceDetailsReview]:{insuranceMemberID:{}}},SEIUWorkflow=e=>{let{render:t}=e,[a,r]=(0,D.eO)(eo),i=(0,E.useMemo)(()=>(0,R.k)(a.value),[a.value]);(0,f.R)(i);let j=(0,E.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),w=(0,E.useCallback)(()=>{r({type:"BACK"})},[r]),T=(0,E.useCallback)(()=>{switch(i){case ea.PreEligibility:return(0,n.jsx)(y.b,{configuration:{contentResources:el[I.J.PreEligibility]},onSubmit:j});case ea.ContactDetails:return(0,n.jsx)(C.q,{configuration:{contentResources:el[I.J.ContactDetails],fields:ed[I.J.ContactDetails]},onSubmit:j,defaultValues:a.context.formData});case ea.EligibilityUnmet:return(0,n.jsx)(p.X,{configuration:{contentResources:el[I.J.EligibilityUnmet]},onSubmit:j,loading:a.matches({[ea.EligibilityUnmet]:ea.Submitting}),isEmailSent:a.matches({[ea.EligibilityUnmet]:ea.Success}),hasError:a.matches({[ea.EligibilityUnmet]:ea.Error})});case ea.InsuranceDetails:return(0,n.jsx)(SeiuInsuranceDetailsForm,{configuration:{contentResources:el[I.J.InsuranceDetails],fields:ed[I.J.InsuranceDetails]},onSubmit:j,onBack:w});case ea.InsuranceDetailsReview:return(0,n.jsx)(g.b,{configuration:{contentResources:el[I.J.InsuranceDetailsReview],fields:ed[I.J.InsuranceDetailsReview]},onSubmit:j,loading:a.matches({[ea.InsuranceDetailsReview]:ea.Submitting}),hasError:a.matches({[ea.InsuranceDetailsReview]:ea.Error}),defaultValues:a.context.formData});case ea.ApplicationComplete:return(0,n.jsx)(l.J,{...el[I.J.ApplicationComplete],email:a.context.formData.email});case ea.ApplicationDetected:return(0,n.jsx)(c.v,{...el[I.J.ApplicationDetected],email:a.context.formData.email});case ea.ApplicationReview:return(0,n.jsx)(d.G,{...el[I.J.ApplicationReview]});case ea.EmailVerification:return(0,n.jsx)(h.Z,{configuration:{contentResources:{title:el[I.J.EmailVerification](a.context.formData.email).title}},email:a.context.formData.email,hasError:a.matches({[ea.EmailVerification]:ea.Error}),loading:a.matches({[ea.EmailVerification]:ea.Submitting}),isUpdateEmailLoading:a.matches({[ea.EmailVerification]:{[ea.UpdateEmail]:ea.Idle}}),hasUpdateEmailError:a.matches({[ea.EmailVerification]:{[ea.UpdateEmail]:ea.Error}}),onSubmit:j,onResendCode:e=>r({type:"RESEND_EMAIL_VERIFICATION",data:{onSuccess:e}}),onEditEmail:(e,t)=>r({type:"UPDATE_EMAIL",data:{email:e,onSuccess:t}})});case ea.OnboardingChecklist:return(0,n.jsx)(x.O,{configuration:{contentResources:el[I.J.OnboardingChecklist]},onSubmit:j});case ea.ReviewConsents:return(0,n.jsx)(H.R,{configuration:{contentResources:el[I.J.ReviewConsents]},consents:a.context.consentsData.items,hasError:a.matches({[ea.ReviewConsents]:ea.Error}),loading:a.matches({[ea.ReviewConsents]:ea.FetchConsents})||a.matches({[ea.ReviewConsents]:ea.Submitting})||a.matches({[ea.ReviewConsents]:ea.UpdateContact}),onSubmit:j});case ea.CreatePassword:return(0,n.jsx)(m.f,{configuration:{contentResources:el[I.J.CreatePassword]},loading:a.matches({[ea.CreatePassword]:ea.Submitting}),error:a.context.error,onSubmit:j});case ea.AppDownload:return(0,n.jsx)(s.B,{title:el[I.J.AppDownload].title,checklist:el[I.J.AppDownload].checklist});case ea.OnboardingUserError:return(0,n.jsx)(b._,{});default:return null}},[i,a]);return t({header:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(o.Flex,{gap:"spacer-5",alignItems:"center",children:[(0,n.jsx)(S.E,{partner:v.kT.Flyte}),(0,n.jsx)(o.Divider,{orientation:"vertical",alignSelf:"stretch",height:"auto"}),(0,n.jsx)(S.E,{partner:v.kT["1199SEIU"]})]}),(0,n.jsx)(u.K,{currentStep:i})]}),body:T(),currentWorkFlowStep:i})}},24045:function(e,t,a){a.d(t,{U:function(){return AetnaWorkflow}});var r,i,n=a(85893),o=a(71986),s=a(33640),l=a(65660),c=a(20410),d=a(31540),S=a(53157),u=a(39424),C=a(86640),m=a(50793),p=a(83344),h=a(73071),g=a(64504),x=a(56401),b=a(70908),y=a(10002),H=a(17304),f=a(94445),v=a(67294),I=a(1943),R=a(33546),D=a(64267),E=a(10265),j=a(19171),w=a(67618),T=a(13064),A=a(94788),k=a(47243),P=a(30368),L=a(37053);let isEligibleForAutoEnrollment=e=>e===L._.FULL_MATCH||e===L._.ELIGIBLE_MATCH,getLeadStatus=e=>{switch(e){case L._.PERSON_MATCH:case L._.INSURANCE_MATCH:case L._.EXPIRED:case L._.NOT_FOUND:return x.rl.EligibleWaiting;case L._.FULL_MATCH:case L._.ELIGIBLE_MATCH:default:return}};(r=i||(i={})).CheckEligibility="checkEligibility",r.CreateLead="createLead",r.CheckBenefits="checkBenefits";let M={...y.a,...i},F=w.aU[E.kT.Aetna],O={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insurance:void 0,lastName:"",phone:"",state:void 0,termsAgreement:!1,howDidYouFindUS:"",comorbidities:[],diabetes:"",bariatricSurgery:""},eligibilityCheckMatchType:void 0,bmi:void 0,benefitsCheck:void 0},B=(0,A.cY)({types:{},guards:{isPreEligibilityMet:e=>{let{context:{formData:t,bmi:a}}=e;return T.Pq.aetna({bmi:a,comorbidity:t.comorbidity,birthdate:t.birthdate})},isApplicationReviewRequired:e=>{let{context:{eligibilityCheckMatchType:t}}=e;return[E._q.EXPIRED,E._q.INSURANCE_MATCH,E._q.PERSON_MATCH,E._q.NOT_FOUND].includes(t)},isApplicationDetected:j.Q},actions:{updateFormData:(0,k.a)({formData:e=>{let{context:t,event:a}=e;return{...t.formData,...a.data}}}),assignBMI:(0,k.a)({bmi:e=>{let{context:t}=e,{heightInFoot:a,heightInInch:r,highestWeightInPounds:i}=t.formData;return(0,T.V2)({heightFeet:(0,T.MC)(a),heightInches:(0,T.MC)(r),weightPounds:(0,T.MC)(i)})}}),reset:(0,k.a)({...O}),resetBenefitsCheck:(0,k.a)({benefitsCheck:void 0})}}).createMachine({context:()=>O,id:"aetnaMachine",initial:M.PreEligibility,states:{[M.PreEligibility]:{id:M.PreEligibility,initial:M.Idle,states:{[M.Idle]:{on:{SUBMIT:{target:M.Submitting,actions:"updateFormData"}}},[M.Submitting]:{entry:"assignBMI",always:[{target:"#".concat(M.ContactDetails),guard:"isPreEligibilityMet"},{target:"#".concat(M.EligibilityUnmet)}]}}},[M.ContactDetails]:{id:M.ContactDetails,initial:M.Idle,states:{[M.Idle]:{on:{SUBMIT:{target:"#".concat(M.InsuranceDetails),actions:"updateFormData"}}}}},[M.InsuranceDetails]:{id:M.InsuranceDetails,initial:M.Idle,states:{[M.Idle]:{on:{BACK:{target:"#".concat(M.ContactDetails)},SUBMIT:{target:"#".concat(M.InsuranceDetailsReview),actions:"updateFormData"}}}}},[M.InsuranceDetailsReview]:{id:M.InsuranceDetailsReview,initial:M.Idle,states:{[M.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:M.Submitting}}},[M.Submitting]:{id:M.Submitting,initial:M.CheckEligibility,states:{[M.CheckEligibility]:{id:M.CheckEligibility,invoke:{src:(0,P.p4)(async e=>{let{input:t}=e,a={...t,insurance:w.Er[E.kT.Aetna],benefitProgram:w.Q1[E.kT.Aetna]};return await (0,R.m)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:[{actions:(0,k.a)({eligibilityCheckMatchType:e=>{let{event:t}=e;return t.output.data.matchType}}),target:"#".concat(M.CheckBenefits)}],onError:"#".concat(M.Error)}},[M.CheckBenefits]:{id:M.CheckBenefits,invoke:{src:(0,P.p4)(async e=>{let{input:t}=e,a={...t,payerCode:w.qK[E.PF["Aetna Medicare"]]};return await (0,I.o)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:[{actions:(0,k.a)({benefitsCheck:e=>{let{event:t}=e;return t.output.data}}),target:"#".concat(M.CreateLead)}],onError:"#".concat(M.CreateLead)}},[M.CreateLead]:{id:M.CreateLead,invoke:{src:(0,P.p4)(async e=>{let{input:t}=e,a={...t.formData,...t.formData.insuranceMemberID&&{employmentVerificationCode:t.formData.insuranceMemberID},...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},eligibilityVerifiedBy:E.Vn.Evolve,company:F,insurance:w.KG[E.kT.Aetna],evolveOrganization:E.bV["State of Connecticut Retirees"],leadStatus:getLeadStatus(t.eligibilityCheckMatchType),automateEvolveEnrollment:isEligibleForAutoEnrollment(t.eligibilityCheckMatchType)};return await (0,D.$)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isApplicationReviewRequired",target:"#".concat(M.ApplicationReview)},{target:"#".concat(M.ApplicationComplete)}],onError:[{guard:"isApplicationDetected",target:"#".concat(M.ApplicationDetected)},{target:"#".concat(M.Error)}]}}}},[M.Error]:{id:M.Error,on:{SUBMIT:{actions:["updateFormData","resetBenefitsCheck"],target:M.Submitting}}}}},[M.ApplicationReview]:{id:M.ApplicationReview},[M.ApplicationComplete]:{id:M.ApplicationComplete},[M.ApplicationDetected]:{id:M.ApplicationDetected},[M.EligibilityUnmet]:{id:M.EligibilityUnmet,initial:M.Idle,states:{[M.Idle]:{on:{SUBMIT:{target:M.Submitting,actions:"updateFormData"}}},[M.Submitting]:{invoke:{src:(0,P.p4)(async e=>{let{input:t}=e,a={...t,company:F,leadStatus:E.rl.Ineligible,ineligibilityReason:E.ib.BMI,automateEvolveEnrollment:!1};return await (0,D.$)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:M.Success,onError:M.Error}},[M.Success]:{},[M.Error]:{on:{SUBMIT:{target:M.Submitting}}}}}},on:{RESET:{target:"#".concat(M.PreEligibility),actions:"reset"}}});var U=a(56344);let J={[b.J.PreEligibility]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"Let's make sure you're eligible for the Flyte program."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"To be eligible for the Flyte program through your Aetna Medicare Advantage benefits, you must meet specific age and Body Mass Index (BMI)* requirements."})]}),bmiEnrollmentDisclaimer:(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. Flyte providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the Flyte program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[b.J.EligibilityUnmet]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Unfortunately, you are not eligible to join FlyteHealth at this time."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"The Flyte program requires a minimum BMI of 27+ (plus one or more weight-related health conditions) or a BMI of 30+."})]})},[b.J.ContactDetails]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Congratulations! You're eligible for the FlyteHealth program"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"To help us match your information with your health plan, tell us about yourself. Next, we'll ask about your Aetna membership. Be sure to have your insurance card handy."})]})},[b.J.InsuranceDetails]:{title:(0,n.jsxs)(o.Text,{variant:"text-header-2XL",color:"text-secondary-negative",children:["One more thing:"," ",(0,n.jsx)(o.Text,{as:"span",variant:"text-header-2XL",color:"text-primary",children:"What's your Aetna membership number?"})]})},[b.J.InsuranceDetailsReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{children:"Let's review: Is your info correct?"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Please double-check the information you provided to make sure everything is correct."})]})},[b.J.ApplicationComplete]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Welcome aboard! We're so excited you're here."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Next, we need to confirm your email. Click the link we sent to:"})]}),description:(0,n.jsx)(o.Text,{mt:"spacer-8",color:"text-secondary",variant:"text-body-regular",children:"Can’t find the email? Make sure to check your Spam folder."})},[b.J.ApplicationReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]})},[b.J.ApplicationDetected]:{title:(0,n.jsx)(o.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,n.jsx)(o.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[b.J.OnboardingChecklist]:U.T[b.J.OnboardingChecklist],[b.J.CreatePassword]:U.T[b.J.CreatePassword],[b.J.AppDownload]:U.T[b.J.AppDownload],[b.J.ReviewConsents]:U.T[b.J.ReviewConsents]};var N=a(58976);let W=[x.Op.BenefitsWebsite,x.Op.ProviderReferral,x.Op.WordOfMouth,x.Op.Other],V={[b.J.ContactDetails]:{state:{options:N.Fp},howDidYouFindUs:{options:W}},[b.J.InsuranceDetails]:{insuranceMemberID:{tooltip:(0,n.jsxs)(o.Box,{children:[(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-light",children:"Where to find my Membership ID Number:"}),(0,n.jsx)(o.Image,{width:"100%",height:"auto",src:"/static/assets/programs/aetna/aetna-insurance-card.png",alt:"Member ID guidance"})]})}},[b.J.InsuranceDetailsReview]:{insuranceMemberID:{}}},_=x.kT.Aetna,AetnaWorkflow=e=>{let{render:t}=e,[a,r]=(0,f.eO)(B),i=(0,v.useMemo)(()=>(0,H.k)(a.value),[a.value]);(0,g.R)(i,_);let I=(0,v.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),R=(0,v.useCallback)(()=>{r({type:"BACK"})},[r]),D=(0,v.useCallback)(()=>{switch(i){case y.a.PreEligibility:return(0,n.jsx)(h.b,{configuration:{contentResources:J[b.J.PreEligibility]},onSubmit:I});case y.a.ContactDetails:return(0,n.jsx)(u.q,{configuration:{contentResources:J[b.J.ContactDetails],fields:V[b.J.ContactDetails]},onSubmit:I,defaultValues:a.context.formData});case y.a.EligibilityUnmet:return(0,n.jsx)(C.X,{configuration:{contentResources:J[b.J.EligibilityUnmet]},onSubmit:I,loading:a.matches({[y.a.EligibilityUnmet]:y.a.Submitting}),isEmailSent:a.matches({[y.a.EligibilityUnmet]:y.a.Success}),hasError:a.matches({[y.a.EligibilityUnmet]:y.a.Error})});case y.a.InsuranceDetails:return(0,n.jsx)(m.v,{configuration:{contentResources:J[b.J.InsuranceDetails],fields:V[b.J.InsuranceDetails]},onSubmit:I,onBack:R});case y.a.InsuranceDetailsReview:return(0,n.jsx)(p.b,{configuration:{contentResources:J[b.J.InsuranceDetailsReview],fields:V[b.J.InsuranceDetailsReview]},onSubmit:I,loading:a.matches({[y.a.InsuranceDetailsReview]:y.a.Submitting}),hasError:a.matches({[y.a.InsuranceDetailsReview]:y.a.Error}),defaultValues:a.context.formData});case y.a.ApplicationComplete:return(0,n.jsx)(s.J,{...J[b.J.ApplicationComplete],email:a.context.formData.email});case y.a.ApplicationDetected:return(0,n.jsx)(l.v,{...J[b.J.ApplicationDetected],email:a.context.formData.email});case y.a.ApplicationReview:return(0,n.jsx)(c.G,{...J[b.J.ApplicationReview]});default:return null}},[i,a]);return t({header:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(o.Flex,{gap:"spacer-5",alignItems:"center",children:[(0,n.jsx)(d.E,{partner:x.kT.Flyte}),(0,n.jsx)(o.Divider,{orientation:"vertical",alignSelf:"stretch",height:"auto"}),(0,n.jsx)(d.E,{partner:_})]}),(0,n.jsx)(S.K,{currentStep:i})]}),body:D(),currentWorkFlowStep:i})}},38660:function(e,t,a){a.d(t,{$:function(){return CareCompassWorkflow}});var r,i,n=a(85893),o=a(71986),s=a(33640),l=a(65660),c=a(20410),d=a(31540),S=a(53157),u=a(39424),C=a(86640),m=a(50793),p=a(83344),h=a(73071),g=a(64504),x=a(56401),b=a(70908),y=a(17304),H=a(94445),f=a(67294),v=a(1943),I=a(33546),R=a(64267),D=a(10265),E=a(19171),j=a(67618),w=a(10002),T=a(13064),A=a(63317),k=a(94788),P=a(30368),L=a(47243),M=a(37053);let F=["031800000H","031800000S","031800001H","031800001S","031801001A","031801001H","031801001S","031801002A","031801002H","031801002S","031801003A","031801003H","031801003S","031801004H","031801004S","031801005A","031801005H","031801005S","031801006A","031801006H","031801006S","031802000H","031802000S","031802004H","031802004S","031802055H","031802055S","031803000H","031803000S","031804000H","031804000S","031805000A","031805000H","031805000S","031805001A","031805001H","031805001S","031805002A","031805002H","031805002S","031806000H","031806000S","031808000H","031808000S","031808055H","031808055S","031809055H","031809055S","031809056H","031809056S","031809057H","031809057S","031809058H","031809058S","031809059H","031809059S","031810000H","031810000S","031810004H","031810004S","031810055H","031810055S","031811000H","031811000S","031811001H","031811001S","031812000H","031812000S","031812001H","031812001S","031813001H","031813001S","031814000H","031814000S","031815000H","031815000S","031820004H","031820004S","031821000H","031821000S","031822000H","031822000S","031827000H","031827000S","031830000H","031830000S","031830001H","031830001S","031830002H","031830002S","031830003H","031830003S","031831000H","031831000S","031832000H","031832000S","031833000H","031833000S","031835000H","031835000S","031836004H","031836004S","031839000H","031839000S","031843000H","031843000S","031843002H","031843002S","031844000H","031844000S","031844003H","031844003S","031844006H","031844006S","031844007A","031844008A","031845000H","031845000S","031846001H","031846001S","031846002H","031846002S","031847000H","031847000S","031848000H","031848000S","031848003H","031848003S","031849015H","031849015S","031849017H","031849017S","031850001H","031850001S","031851000A","031851000H","031851000S","031851002A","031851002H","031851002S","031851003A","031851003H","031851003S","031851004A","031851004H","031851004S","031851009A","031851009H","031851009S","031851010A","031851010H","031851010S","031851013A","031851013H","031851013S","031851023A","031851023H","031851023S","031853000H","031853000S","031855000H","031855000S","031856000H","031856000S","031856001H","031856001S","031857000H","031857000S","031858000A","031858000H","031858000S","031859002A","031859002H","031859002S","031859008A","031859008H","031859008S","031859011A","031859011H","031859011S","031860000H","031860000S","031860002H","031860002S","031862004H","031862004S","031863011A","031863011H","031863011S","031863016H","031863016S","031863017H","031863017S","031864000A","031864000H","031864000S","031865001H","031865001S","031865002H","031865002S","031867000H","031867000S","031867001H","031867001S","031867002H","031867002S","031867003H","031867003S","031868001A","031869001S","031871000H","031871000S","031871001S","031871002A","031872000H","031872000S","031872001H","031872001S","031872002H","031872002S","031872003H","031872003S","031873001H","031873001S","031874000H","031874000S","031874003H","031874003S","031877000H","031877000S","031877001H","031877001S","031877058A","031877061A","031877065A","031877070A","031877071A","031878000H","031878000S","031879000H","031879000S","031880005H","031880005S","031881000H","031881000S","031881001A","031881001H","031881001S","031881002H","031881002S","031881003H","031881003S","031881004H","031881004S","031882000H","031882000S","031883000H","031883000S","031884000A","031884000H","031884000S","031885000H","031885000S","031886000A","031886000H","031886000S","031888000H","031888000S","031888001H","031888001S","031889043A","031889044H","031889044S","031889046A","031889047A","031889048A","031889143A","031889143B","031889144A","031889144B","031889146A","031889146B","031889147A","031889147B","031889243H","031889243S","031889244A","031889246H","031889246S","031889343H","031889343S","031889346A","031890004H","031890004S","031890010A","031891000H","031891000S","031892000H","031892000S","031894000H","031894000S","031895000H","031895000S","031895001H","031895001S","031895002H","031895002S","031895003H","031895003S","031895004H","031895004S","031895005H","031895005S","031895006H","031895006S","031895102H","031895102S","031895103H","031895103S","031895104H","031895104S","031896000H","031896000S","031896001H","031896001S","031898000H","031898000S","031899000H","031899000S","041800000H","041800000S","041800001H","041800001S","041801001A","041801001H","041801001S","041801002A","041801002H","041801002S","041801003A","041801003H","041801003S","041801004H","041801004S","041801005A","041801005H","041801005S","041801006A","041801006H","041801006S","041802000H","041802000S","041802004H","041802004S","041802055H","041802055S","041803000H","041803000S","041804000H","041804000S","041805000A","041805000H","041805000S","041805001A","041805001H","041805001S","041805002A","041805002H","041805002S","041806000H","041806000S","041808000H","041808000S","041808055H","041808055S","041809055H","041809055S","041809056H","041809056S","041809057H","041809057S","041809058H","041809058S","041809059H","041809059S","041810000H","041810000S","041810004H","041810004S","041810055H","041810055S","041811000H","041811000S","041811001H","041811001S","041812000H","041812000S","041812001H","041812001S","041813001H","041813001S","041814000H","041814000S","041815000H","041815000S","041820004H","041820004S","041821000H","041821000S","041822000H","041822000S","041827000H","041827000S","041830000H","041830000S","041830001H","041830001S","041830002H","041830002S","041830003H","041830003S","041831000H","041831000S","041832000H","041832000S","041833000H","041833000S","041835000H","041835000S","041836004H","041836004S","041839000H","041839000S","041843000H","041843000S","041843002H","041843002S","041844000H","041844000S","041844003H","041844003S","041844006H","041844006S","041844008A","041844408A","041845000H","041845000S","041846001H","041846001S","041846002H","041846002S","041847000H","041847000S","041848000H","041848000S","041848003H","041848003S","041849015H","041849015S","041849017H","041849017S","041850001H","041850001S","041851000A","041851000H","041851000S","041851002A","041851002H","041851002S","041851003A","041851003H","041851003S","041851004A","041851004H","041851004S","041851009A","041851009H","041851009S","041851010A","041851010H","041851010S","041851013A","041851013H","041851013S","041851023A","041851023H","041851023S","041853000H","041853000S","041855000H","041855000S","041856000H","041856000S","041856001H","041856001S","041857000H","041857000S","041858000A","041858000H","041858000S","041859002A","041859002H","041859002S","041859008A","041859008H","041859008S","041859011A","041859011H","041859011S","041860000H","041860000S","041860002H","041860002S","041862004H","041862004S","041863011A","041863011H","041863011S","041863016H","041863016S","041863017H","041863017S","041864000A","041864000H","041864000S","041865001H","041865001S","041865002H","041865002S","041867000H","041867000S","041867001H","041867001S","041867002H","041867002S","041868001A","041869001S","041871000H","041871000S","041871001A","041871002A","041872000H","041872000S","041872001H","041872001S","041872002H","041872002S","041872003H","041872003S","041873001H","041873001S","041874000H","041874000S","041874001H","041874001S","041874003H","041874003S","041877000H","041877000S","041877001H","041877001S","041877050A","041877051A","041877058A","041877059A","041877065A","041877066A","041877070A","041877071A","041877408A","041878000H","041878000S","041879000H","041879000S","041880003H","041880003S","041880005H","041880005S","041881000H","041881000S","041881001A","041881001H","041881001S","041881002H","041881002S","041881003H","041881003S","041881004H","041881004S","041882000H","041882000S","041883000H","041883000S","041884000A","041884000H","041884000S","041885000H","041885000S","041886000A","041886000H","041886000S","041888000H","041888000S","041888001H","041888001S","041889009A","041889010A","041889040A","041889043A","041889044H","041889044S","041889045A","041889046A","041889049A","041889140A","041889140B","041889145A","041889145B","041889146A","041889146B","041889147A","041889147B","041889149A","041889149B","041889244A","041889245H","041889245S","041889249H","041889249S","041889345H","041889345S","041889346A","041890004H","041890004S","041890010A","041890011A","041890410A","041891000H","041891000S","041892000H","041892000S","041894000H","041894000S","041895000H","041895000S","041895001H","041895001S","041895002H","041895002S","041895003H","041895003S","041895004H","041895004S","041895005H","041895005S","041895006H","041895006S","041895102H","041895102S","041895103H","041895103S","041895104H","041895104S","041896000H","041896000S","041896001H","041896001S","041898000H","041898000S","041899000H","041899000S","051800000H","051800000S","051800001H","051800001S","051801001A","051801001H","051801001S","051801002A","051801002H","051801002S","051801003A","051801003H","051801003S","051801004H","051801004S","051801005A","051801005H","051801005S","051801006A","051801006H","051801006S","051802000H","051802000S","051802004H","051802004S","051803000H","051803000S","051804000H","051804000S","051805000A","051805000H","051805000S","051805001A","051805001H","051805001S","051805002A","051805002H","051805002S","051806000H","051806000S","051808000H","051808000S","051808055H","051808055S","051809055H","051809055S","051809056H","051809056S","051809057H","051809057S","051809058H","051809058S","051809059H","051809059S","051810000H","051810000S","051810004H","051810004S","051810055H","051810055S","051811001H","051811001S","051812000H","051812000S","051812001H","051812001S","051813001H","051813001S","051814000H","051814000S","051815000H","051815000S","051820004H","051820004S","051821000H","051821000S","051827000H","051827000S","051830000H","051830000S","051830001H","051830001S","051830002H","051830002S","051830003H","051830003S","051831000H","051831000S","051832000H","051832000S","051833000H","051833000S","051835000H","051835000S","051836004H","051836004S","051839000H","051839000S","051843000H","051843000S","051844000H","051844000S","051844003H","051844003S","051844006H","051844006S","051845000H","051845000S","051846001H","051846001S","051846002H","051846002S","051847000H","051847000S","051848000H","051848000S","051848003H","051848003S","051849015H","051849015S","051849017H","051849017S","051850001H","051850001S","051851000A","051851000H","051851000S","051851002A","051851002H","051851002S","051851003A","051851003H","051851003S","051851004A","051851004H","051851004S","051851009A","051851009H","051851009S","051851010A","051851010H","051851010S","051851013A","051851013H","051851013S","051851023A","051851023H","051851023S","051853000H","051853000S","051855000H","051855000S","051856000H","051856000S","051856001H","051856001S","051857000H","051857000S","051858000A","051858000H","051858000S","051859002A","051859002H","051859002S","051859008A","051859008H","051859008S","051859011A","051859011H","051859011S","051860000H","051860000S","051860002H","051860002S","051862004H","051862004S","051863011A","051863011H","051863011S","051863016H","051863016S","051863017H","051863017S","051864000A","051864000H","051864000S","051865002H","051865002S","051867000H","051867000S","051867001H","051867001S","051869001S","051871000H","051871000S","051872001H","051872001S","051872003H","051872003S","051873001H","051873001S","051874000H","051874000S","051874003H","051874003S","051877000H","051877000S","051877001H","051877001S","051877058A","051877070A","051877071A","051878000H","051878000S","051880005H","051880005S","051881001A","051881001H","051881001S","051881002H","051881002S","051881003H","051881003S","051881004H","051881004S","051882000H","051882000S","051883000H","051883000S","051884000A","051884000H","051884000S","051885000H","051885000S","051886000A","051886000H","051886000S","051888000H","051888000S","051888001H","051888001S","051889008A","051889040A","051889043A","051889044H","051889044S","051889046A","051889047A","051889140A","051889140B","051889143A","051889143B","051889146A","051889146B","051889147A","051889147B","051889243H","051889243S","051889244A","051889246H","051889246S","051889343H","051889343S","051889346A","051890004H","051890004S","051892000H","051892000S","051895000H","051895000S","051895001H","051895001S","051895002H","051895002S","051895003H","051895003S","051895004H","051895004S","051895005H","051895005S","051895006H","051895006S","051895102H","051895102S","051895103H","051895103S","051895104H","051895104S","051896000H","051896000S","051896001H","051896001S","051899000H","051899000S","061800000H","061800000S","061800001H","061800001S","061801001A","061801001H","061801001S","061801002A","061801002H","061801002S","061801003A","061801003H","061801003S","061801004H","061801004S","061801005A","061801005H","061801005S","061801006A","061801006H","061801006S","061802000H","061802000S","061802004H","061802004S","061802055H","061802055S","061803000H","061803000S","061804000H","061804000S","061805000A","061805000H","061805000S","061805001A","061805001H","061805001S","061805002A","061805002H","061805002S","061806000H","061806000S","061808000H","061808000S","061808055H","061808055S","061809055H","061809055S","061809056H","061809056S","061809057H","061809057S","061809058H","061809058S","061809059H","061809059S","061810000H","061810000S","061810004H","061810004S","061810055H","061810055S","061811001H","061811001S","061812000H","061812000S","061812001H","061812001S","061813001H","061813001S","061814000H","061814000S","061815000H","061815000S","061820004H","061820004S","061821000H","061821000S","061822000H","061822000S","061827000H","061827000S","061830000H","061830000S","061830001H","061830001S","061830002H","061830002S","061830003H","061830003S","061831000H","061831000S","061832000H","061832000S","061833000H","061833000S","061835000H","061835000S","061836004H","061836004S","061839000H","061839000S","061843000H","061843000S","061843002H","061843002S","061844000H","061844000S","061844003H","061844003S","061844006H","061844006S","061845000H","061845000S","061846001H","061846001S","061846002H","061846002S","061847000H","061847000S","061848000H","061848000S","061848003H","061848003S","061849015H","061849015S","061849017H","061849017S","061850001H","061850001S","061851000A","061851000H","061851000S","061851002A","061851002H","061851002S","061851003A","061851003H","061851003S","061851004A","061851004H","061851004S","061851009A","061851009H","061851009S","061851010A","061851010H","061851010S","061851013A","061851013H","061851013S","061851023A","061851023H","061851023S","061853000H","061853000S","061855000H","061855000S","061856000H","061856000S","061856001H","061856001S","061857000H","061857000S","061858000A","061858000H","061858000S","061859002A","061859002H","061859002S","061859008A","061859008H","061859008S","061859011A","061859011H","061859011S","061860000H","061860000S","061860002H","061860002S","061862004H","061862004S","061863011A","061863011H","061863011S","061863016H","061863016S","061863017H","061863017S","061864000A","061864000H","061864000S","061865001H","061865001S","061865002H","061865002S","061867000H","061867000S","061867001H","061867001S","061867002H","061867002S","061867003H","061867003S","061868001H","061868001S","061869001H","061869001S","061871000H","061871000S","061871001A","061871002A","061872000H","061872000S","061872001H","061872001S","061872002H","061872002S","061872003H","061872003S","061873001H","061873001S","061874000H","061874000S","061874001H","061874001S","061874003H","061874003S","061877000H","061877000S","061877001H","061877001S","061877058A","061877060A","061877061A","061877070A","061877071A","061877408A","061877410A","061878000H","061878000S","061879000H","061879000S","061880003H","061880003S","061880005H","061880005S","061881000H","061881000S","061881001A","061881001H","061881001S","061881002H","061881002S","061881003H","061881003S","061881004H","061881004S","061882000H","061882000S","061883000H","061883000S","061884000A","061884000H","061884000S","061885000H","061885000S","061886000A","061886000H","061886000S","061888000H","061888000S","061888001H","061888001S","061889008A","061889043A","061889046A","061889143A","061889143B","061889146A","061889146B","061889147A","061889147B","061889243H","061889243S","061889244A","061889246H","061889246S","061889343H","061889343S","061889346A","061890004H","061890004S","061890010A","061891000H","061891000S","061892000H","061892000S","061894000H","061894000S","061895000H","061895000S","061895001H","061895001S","061895002H","061895002S","061895003H","061895003S","061895004H","061895004S","061895005H","061895005S","061895006H","061895006S","061895102H","061895102S","061895103H","061895103S","061895104H","061895104S","061896000H","061896000S","061896001H","061896001S","061898000H","061898000S","061899000H","061899000S","071800000H","071800000S","071800001H","071800001S","071801001A","071801001H","071801001S","071801002A","071801002H","071801002S","071801003A","071801003H","071801003S","071801004H","071801004S","071801005A","071801005H","071801005S","071801006A","071801006H","071801006S","071802000H","071802000S","071802004H","071802004S","071802055H","071802055S","071803000H","071803000S","071804000H","071804000S","071805000A","071805000H","071805000S","071805001A","071805001H","071805001S","071805002A","071805002H","071805002S","071806000H","071806000S","071808000H","071808000S","071808055H","071808055S","071809055H","071809055S","071809056H","071809056S","071809057H","071809057S","071809058H","071809058S","071809059H","071809059S","071810000H","071810000S","071810004H","071810004S","071810055H","071810055S","071811000H","071811000S","071811001H","071811001S","071812000H","071812000S","071812001H","071812001S","071813001H","071813001S","071814000H","071814000S","071815000H","071815000S","071820004H","071820004S","071821000H","071821000S","071822000H","071822000S","071827000H","071827000S","071830000H","071830000S","071830001H","071830001S","071830002H","071830002S","071830003H","071830003S","071831000H","071831000S","071832000H","071832000S","071833000H","071833000S","071835000H","071835000S","071836004H","071836004S","071839000H","071839000S","071843000H","071843000S","071843002H","071843002S","071844000H","071844000S","071844003H","071844003S","071844006H","071844006S","071845000H","071845000S","071846001H","071846001S","071846002H","071846002S","071847000H","071847000S","071848000H","071848000S","071848003H","071848003S","071849015H","071849015S","071849017H","071849017S","071850001H","071850001S","071851000A","071851000H","071851000S","071851002A","071851002H","071851002S","071851003A","071851003H","071851003S","071851004A","071851004H","071851004S","071851009A","071851009H","071851009S","071851010A","071851010H","071851010S","071851013A","071851013H","071851013S","071851023A","071851023H","071851023S","071853000H","071853000S","071855000H","071855000S","071856000H","071856000S","071856001H","071856001S","071857000H","071857000S","071858000A","071858000H","071858000S","071859002A","071859002H","071859002S","071859008A","071859008H","071859008S","071859011A","071859011H","071859011S","071860000H","071860000S","071860002H","071860002S","071862004H","071862004S","071863011A","071863011H","071863011S","071863016H","071863016S","071863017H","071863017S","071864000A","071864000H","071864000S","071865001H","071865001S","071865002H","071865002S","071867000H","071867000S","071867001H","071867001S","071867002H","071867002S","071867003H","071867003S","071868001A","071869001S","071871000H","071871000S","071871001S","071871002A","071872000H","071872000S","071872001H","071872001S","071872002H","071872002S","071872003H","071872003S","071873001H","071873001S","071874000H","071874000S","071874001H","071874001S","071874003H","071874003S","071877000H","071877000S","071877001H","071877001S","071877058A","071877059A","071877060A","071877070A","071877071A","071877408A","071878000H","071878000S","071879000H","071879000S","071879001A","071880003H","071880003S","071880005H","071880005S","071881000H","071881000S","071881001A","071881001H","071881001S","071881002H","071881002S","071881003H","071881003S","071881004H","071881004S","071882000H","071882000S","071883000H","071883000S","071884000A","071884000H","071884000S","071885000H","071885000S","071886000A","071886000H","071886000S","071888000H","071888000S","071888001H","071888001S","071889008A","071889040A","071889043A","071889044H","071889044S","071889046A","071889140A","071889140B","071889143A","071889143B","071889146A","071889146B","071889147A","071889147B","071889243H","071889243S","071889244A","071889246H","071889246S","071889343H","071889343S","071889346A","071890004H","071890004S","071890010A","071890410A","071891000H","071891000S","071892000H","071892000S","071894000H","071894000S","071895000H","071895000S","071895001H","071895001S","071895002H","071895002S","071895003H","071895003S","071895004H","071895004S","071895005H","071895005S","071895006H","071895006S","071895102H","071895102S","071895103H","071895103S","071895104H","071895104S","071896000H","071896000S","071896001H","071896001S","071898000H","071898000S","071899000H","071899000S","081800000H","081800000S","081800001H","081800001S","081801001A","081801001H","081801001S","081801002A","081801002H","081801002S","081801003A","081801003H","081801003S","081801004H","081801004S","081801005A","081801005H","081801005S","081801006A","081801006H","081801006S","081802000H","081802000S","081802004H","081802004S","081802055H","081802055S","081803000H","081803000S","081804000H","081804000S","081805000A","081805000H","081805000S","081805001A","081805001H","081805001S","081805002A","081805002H","081805002S","081806000H","081806000S","081808000H","081808000S","081808055H","081808055S","081809055H","081809055S","081809056H","081809056S","081809057H","081809057S","081809058H","081809058S","081809059H","081809059S","081810000H","081810000S","081810004H","081810004S","081810055H","081810055S","081811000H","081811000S","081811001H","081811001S","081812000H","081812000S","081812001H","081812001S","081813001H","081813001S","081814000H","081814000S","081815000H","081815000S","081820004H","081820004S","081821000H","081821000S","081822000H","081822000S","081827000H","081827000S","081830000H","081830000S","081830001H","081830001S","081830002H","081830002S","081830003H","081830003S","081831000H","081831000S","081832000H","081832000S","081833000H","081833000S","081835000H","081835000S","081836004H","081836004S","081839000H","081839000S","081843000H","081843000S","081843002H","081843002S","081844000H","081844000S","081844003H","081844003S","081844006H","081844006S","081845000H","081845000S","081846001H","081846001S","081846002H","081846002S","081847000H","081847000S","081848000H","081848000S","081848003H","081848003S","081849015H","081849015S","081849017H","081849017S","081850001H","081850001S","081851000A","081851000H","081851000S","081851002A","081851002H","081851002S","081851003A","081851003H","081851003S","081851004A","081851004H","081851004S","081851009A","081851009H","081851009S","081851010A","081851010H","081851010S","081851013A","081851013H","081851013S","081851023A","081851023H","081851023S","081853000H","081853000S","081855000H","081855000S","081856000H","081856000S","081856001H","081856001S","081857000H","081857000S","081858000A","081858000H","081858000S","081859002A","081859002H","081859002S","081859008A","081859008H","081859008S","081859011A","081859011H","081859011S","081860000H","081860000S","081860002H","081860002S","081862004H","081862004S","081863011A","081863011H","081863011S","081863016H","081863016S","081863017H","081863017S","081864000A","081864000H","081864000S","081865001H","081865001S","081865002H","081865002S","081867000H","081867000S","081867001H","081867001S","081867002H","081867002S","081867003H","081867003S","081868001A","081869001S","081871000H","081871000S","081871001S","081871002A","081872000H","081872000S","081872001H","081872001S","081872002H","081872002S","081872003H","081872003S","081873001H","081873001S","081874000H","081874000S","081874001H","081874001S","081874003H","081874003S","081877000H","081877000S","081877001H","081877001S","081877058A","081877059A","081877060A","081877070A","081877071A","081877408A","081878000H","081878000S","081879000H","081879000S","081879001A","081880003H","081880003S","081880005H","081880005S","081881000H","081881000S","081881001A","081881001H","081881001S","081881002H","081881002S","081881003H","081881003S","081881004H","081881004S","081882000H","081882000S","081883000H","081883000S","081884000A","081884000H","081884000S","081885000H","081885000S","081886000A","081886000H","081886000S","081888000H","081888000S","081888001H","081888001S","081889008A","081889009A","081889040A","081889043A","081889044H","081889044S","081889046A","081889140A","081889140B","081889143A","081889143B","081889146A","081889146B","081889147A","081889147B","081889243H","081889243S","081889244A","081889246H","081889246S","081889343H","081889343S","081889346A","081890004H","081890004S","081890010A","081890410A","081891000H","081891000S","081892000H","081892000S","081894000H","081894000S","081895000H","081895000S","081895001H","081895001S","081895002H","081895002S","081895003H","081895003S","081895004H","081895004S","081895005H","081895005S","081895006H","081895006S","081895102H","081895102S","081895103H","081895103S","081895104H","081895104S","081896000H","081896000S","081896001H","081896001S","081898000H","081898000S","081899000H","081899000S","CS0001000C","CS0001000H","CS0001M001","CS000200HR","CS0002M001","CS000200SR","CS0002000H","CS0002000S","CS0002000C","CS0004000H","CS0004000S","CS0004M001","CS0004000C","CS0005M001","CS0005000S","CS0005000C","CS0005000H","CS0007004H","CS0007002H","CS0007000H","CS0007003S","CS0007000S","CS0007001H","CS0007004S","CS0007000C","CS0007003H","CS0007002S","CS0007001S","CS0007M001","CS0008000S","CS0008M001","CS0008000H","CS0008000C","CS000902HR","CS0009007H","CS000909HR","CS000901SR","CS0009010H","CS0009006H","CS000902SR","CS000906SR","CS0009001S","CS000905HR","CS000911HR","CS000906HR","CS0009005S","CS000910SR","CS0009004S","CS000901HR","CS0009010S","CS000904HR","CS000910HR","CS0009009H","CS000905SR","CS0009006S","CS0009008H","CS0009004H","CS0009003H","CS000903HR","CS0009002C","CS0009009S","CS000907SR","CS0009002H","CS000903SR","CS0009000C","CS000909SR","CS0009003C","CS0009001H","CS0009011S","CS000908SR","CS0009008S","CS0009005H","CS0009000H","CS0009002S","CS000904SR","CS000908HR","CS000900HR","CS000907HR","CS0009003S","CS0009M001","CS0009001C","CS000911SR","CS0009011H","CS0009007S","CS0009000S","CS000900SR","CS0010000S","CS0010000C","CS0010M001","CS0010000H","CS0011M001","CS0011000H","CS0011000S","CS0011000C","CS0012000S","CS0012M001","CS0012000C","CS0012000H","CS001301SR","CS0013005H","CS0013001H","CS001300HR","CS0013006H","CS0013M001","CS0013002H","CS0013005S","CS0013000C","CS0013001S","CS0013000S","CS0013006S","CS0013003H","CS0013000H","CS0013004S","CS0013004H","CS0013002S","CS001300SR","CS001301HR","CS0013003S","CS0014M001","CS0014000S","CS0014000C","CS0014000H","CS0015013S","CS0015012S","CS0015026S","CS0015004H","CS0015011H","CS0015017S","CS0015022H","CS0015018S","CS001507HR","CS0015018H","CS001500HR","CS0015010S","CS0015013H","CS0015010H","CS0015M001","CS001505SR","CS001507SR","CS001502HR","CS001503HR","CS0015007H","CS0015017H","CS0015012H","CS0015015S","CS0015025S","CS0015005S","CS0015022S","CS0015005H","CS0015003H","CS0015026H","CS0015011S","CS0015025H","CS0015019H","CS0015021S","CS0015016H","CS0015020H","CS0015016S","CS001505HR","CS0015003S","CS0015001H","CS0015023H","CS0015019S","CS001506SR","CS0015009S","CS0015024H","CS001502SR","CS0015015H","CS0015023S","CS001501SR","CS0015008S","CS0015001C","CS0015014H","CS001506HR","CS0015028H","CS0015006H","CS0015002S","CS0015027H","CS0015014S","CS001500SR","CS0015027S","CS0015000H","CS0015021H","CS0015004S","CS0015007S","CS001501HR","CS0015000C","CS001503SR","CS0015020S","CS0015024S","CS0015000S","CS0015008H","CS0015001S","CS0015002H","CS0015006S","CS001504HR","CS0015009H","CS001504SR","CS0016000H","CS0016000C","CS0016M001","CS001600SR","CS0016001S","CS001600HR","CS0016000S","CS0016005S","CS0016004H","CS0016003S","CS0016002H","CS0016005H","CS001601HR","CS0016002S","CS0016003H","CS0016001H","CS0016004S","CS001601SR","CS0017004H","CS0017003S","CS0017002S","CS0017001H","CS0017001S","CS001700SR","CS0017000H","CS0017003H","CS0017000S","CS001700HR","CS0017000C","CS0017004S","CS0017M001","CS0017002H","CS001801HR","CS0018M001","CS001800SR","CS001801SR","CS0018000H","CS001800HR","CS0018000S","CS0018000C","CS0020002S","CS0020M001","CS0020000H","CS0020006H","CS0020000S","CS0020000C","CS002000HR","CS002000SR","CS0020005H","CS0020003H","CS002001SR","CS0020004H","CS0020004S","CS0020006S","CS0020005S","CS0020001H","CS0020003S","CS002001HR","CS0020001S","CS0020002H","CS002130SR","CS002128SR","CS002105SR","CS002127HR","CS0021023S","CS002118HR","CS002128HR","CS002124HR","CS002101HR","CS002104SR","CS002127SR","CS0021011H","CS0021020S","CS0021005H","CS0021008S","CS002108HR","CS002112SR","CS0021021H","CS002100HR","CS0021000H","CS0021002S","CS0021016S","CS0021006H","CS0021014H","CS002120SR","CS002117HR","CS0021026H","CS002113SR","CS002103SR","CS002110HR","CS002126SR","CS002116SR","CS0021016H","CS0021009H","CS0021015S","CS002121HR","CS002130HR","CS0021023H","CS002131HR","CS0021002H","CS0021007S","CS002124SR","CS0021022S","CS002117SR","CS0021020H","CS0021013S","CS0021022H","CS002113HR","CS002107HR","CS002115SR","CS0021010H","CS0021014S","CS0021000S","CS0021012H","CS002108SR","CS002123SR","CS002114SR","CS0021015H","CS002129SR","CS0021011S","CS002102HR","CS002129HR","CS002104HR","CS0021018S","CS002120HR","CS002103HR","CS0021003H","CS0021000C","CS0021003S","CS002118SR","CS002119HR","CS0021006S","CS0021019H","CS0021027H","CS002109HR","CS0021026S","CS0021012S","CS002123HR","CS002116HR","CS002122HR","CS0021027S","CS0021005S","CS0021024H","CS0021017H","CS002111HR","CS002110SR","CS0021001S","CS002126HR","CS002100SR","CS002125SR","CS0021025S","CS002114HR","CS0021010S","CS002109SR","CS002102SR","CS0021025H","CS0021001H","CS002111SR","CS002105HR","CS0021007H","CS0021024S","CS002125HR","CS002115HR","CS002131SR","CS0021017S","CS002112HR","CS002119SR","CS0021019S","CS002101SR","CS0021008H","CS0021004H","CS002107SR","CS0021021S","CS002122SR","CS0021M001","CS0021009S","CS002106SR","CS0021013H","CS002106HR","CS0021018H","CS002121SR","CS0021004S","CS0022000C","CS0022000H","CS0022000S","CS0022M001","CS0023000H","CS0023000S","CS0023000C","CS0023M001","CS0024000C","CS0024000H","CS0024M001","CS0024000S","CS0025002H","CS002501HR","CS0025009S","CS002504HR","CS002501SR","CS002503HR","CS0025007S","CS0025008S","CS002505HR","CS002500HR","CS0025010H","CS002502SR","CS0025000H","CS0025006S","CS0025006H","CS0025000C","CS002507SR","CS0025M001","CS002504SR","CS0025007H","CS002500SR","CS002502HR","CS0025004S","CS0025002S","CS0025011S","CS0025009H","CS0025004H","CS0025011H","CS002505SR","CS0025010S","CS0025005H","CS002506HR","CS0025001H","CS002507HR","CS0025003S","CS0025005S","CS002503SR","CS0025001S","CS0025008H","CS002506SR","CS0025003H","CS0025000S","CS002601HR","CS0026001S","CS002601SR","CS0026000C","CS0026002S","CS0026M001","CS0026000S","CS0026003S","CS0026000H","CS0026001H","CS002600HR","CS0026003H","CS002600SR","CS0026002H","CS0028M001","CS0028000H","CS0028000S","CS0028000C","CS0029000S","CS0029000C","CS0029000H","CS0029M001","CS0032000S","CS0032M001","CS0032000H","CS0032000C","CS0034000H","CS0034000C","CS0034M001","CS0034000S","CS0035010H","CS0035002S","CS0035012S","CS003505SR","CS0035004C","CS003509HR","CS0035013S","CS0035008S","CS003500SR","CS0035000S","CS0035011H","CS003506SR","CS0035007C","CS0035009C","CS003506HR","CS0035006C","CS003502SR","CS0035002C","CS003503HR","CS0035010S","CS003509SR","CS0035003S","CS003504HR","CS003500HR","CS0035006H","CS0035007H","CS0035012H","CS0035005S","CS0035004H","CS003501SR","CS0035010C","CS0035008H","CS0035M001","CS0035005C","CS003507HR","CS0035002H","CS0035000H","CS0035000C","CS0035004S","CS003501HR","CS0035001H","CS003508SR","CS0035003H","CS0035001S","CS0035003C","CS0035008C","CS003504SR","CS0035009S","CS0035013H","CS003505HR","CS0035001C","CS0035005H","CS003507SR","CS0035011C","CS0035007S","CS003503SR","CS003508HR","CS0035006S","CS0035009H","CS0035011S","CS003502HR","CS0037001S","CS0037000C","CS003701SR","CS0037003H","CS0037000S","CS003700SR","CS0037003S","CS0037002H","CS0037002S","CS0037001C","CS0037M001","CS003700HR","CS0037001H","CS003701HR","CS0037000H","CS0038000S","CS0038M001","CS0038000C","CS0038000H","CS003901SR","CS0039000S","CS0039000H","CS0039003S","CS0039000C","CS0039001S","CS003900SR","CS0039001C","CS003900HR","CS0039002S","CS0039M001","CS0039002H","CS0039001H","CS003901HR","CS0039003H","CS004002SR","CS0040000S","CS004000HR","CS0040003S","CS0040001S","CS0040003H","CS0040000H","CS0040002H","CS0040001H","CS004000SR","CS0040002S","CS004002HR","CS0040000C","CS0040M001","CS004104SR","CS004100SR","CS004109SR","CS0041011H","CS0041004H","CS004102HR","CS004101SR","CS004111SR","CS004110SR","CS0041004S","CS0041008S","CS0041005S","CS004107HR","CS0041003H","CS004106SR","CS0041002S","CS004105HR","CS004112SR","CS004101HR","CS0041011S","CS004108HR","CS004108SR","CS0041010H","CS0041000C","CS004109HR","CS0041013H","CS0041007S","CS0041013S","CS004106HR","CS0041007H","CS0041001S","CS004103SR","CS004100HR","CS0041000S","CS0041009S","CS004111HR","CS0041000H","CS0041005H","CS0041006S","CS0041002H","CS0041012H","CS004105SR","CS0041010S","CS004110HR","CS0041009H","CS004112HR","CS0041001H","CS0041006H","CS004103HR","CS0041003S","CS004107SR","CS004102SR","CS0041012S","CS0041008H","CS004104HR","CS0041M001","CS0042M001","CS0042000H","CS0042000C","CS0042000S","CS0043001S","CS004301SR","CS004301HR","CS0043000S","CS0043001H","CS0043M001","CS004300SR","CS0043001C","CS0043003H","CS0043003S","CS0043002S","CS0043000C","CS0043002H","CS0043000H","CS004300HR","CS004400SR","CS004402HR","CS0044005H","CS0044006S","CS0044000H","CS0044007H","CS0044001H","CS0044004S","CS0044000C","CS0044006H","CS0044003H","CS0044001S","CS0044008H","CS0044002S","CS0044M001","CS0044000S","CS004400HR","CS004402SR","CS004403SR","CS0044002H","CS004401HR","CS0044004H","CS004401SR","CS004403HR","CS0044005S","CS0044003S","CS0044008S","CS0044007S","CS0046000S","CS004600SR","CS0046000C","CS004601HR","CS004600HR","CS004601SR","CS0046000H","CS0046M001","CS0048000C","CS0048002H","CS0048000S","CS004801HR","CS0048002S","CS0048003H","CS0048000H","CS004800SR","CS004801SR","CS0048M001","CS0048001S","CS0048003S","CS004800HR","CS0048001C","CS0048001H","CS0049003H","CS0049001S","CS0049003S","CS0049001H","CS004900SR","CS004901SR","CS004900HR","CS0049001C","CS0049000H","CS004901HR","CS0049000C","CS0049002S","CS0049M001","CS0049000S","CS0049002H","CS0050000S","CS0050000C","CS0050M001","CS0050000H","CS0051000C","CS0051000H","CS0051000S","CS0051M001","CS005201SR","CS0052M001","CS0052003H","CS0052002S","CS0052001S","CS0052001C","CS0052000H","CS0052000C","CS005200SR","CS0052003S","CS005200HR","CS0052002H","CS0052001H","CS005201HR","CS0052000S","CS0053001H","CS0053003S","CS0053001S","CS0053004H","CS0053M001","CS0053005H","CS0053006H","CS0053000C","CS005301SR","CS0053000S","CS0053003H","CS0053000H","CS0053002S","CS0053006S","CS0053005S","CS005300SR","CS005300HR","CS0053002H","CS005301HR","CS0053004S","CS0055M001","CS005500SR","CS005500HR","CS0055000H","CS0055000S","CS0055000C","CS0056000H","CS0056000C","CS0056M001","CS0056000S","CS0057001H","CS005700SR","CS0057000H","CS005700HR","CS0057003S","CS0057001C","CS005701SR","CS0057000C","CS0057M001","CS0057002H","CS0057003H","CS0057002S","CS0057001S","CS005701HR","CS0057000S","CS0058001H","CS0058000H","CS0058000S","CS005800SR","CS005800HR","CS0058M001","CS0058000C","CS0058001S","CS0059000S","CS0059M001","CS0059000H","CS0059000C","CS0060000C","CS0060000H","CS0060M001","CS0060000S","CS006100SR","CS0061000C","CS0061001S","CS006100HR","CS0061000S","CS0061001H","CS0061M001","CS0061000H","CS0065M001","CS0065000S","CS0065000C","CS0065000H","CS006601SR","CS0066000S","CS0066000H","CS0066000C","CS0066M001","CS006600HR","CS006600SR","CS006601HR","CS006815SR","CS0068011H","CS006805SR","CS006815HR","CS0068000H","CS0068012H","CS006812SR","CS0068007S","CS006805HR","CS006800SR","CS006811HR","CS006800HR","CS006804HR","CS006819SR","CS0068007H","CS0068004S","CS0068000S","CS006806SR","CS0068005H","CS0068005S","CS006807SR","CS006807HR","CS006817HR","CS0068001S","CS006816HR","CS006816SR","CS006811SR","CS0068013S","CS0068009H","CS006814SR","CS006806HR","CS006810HR","CS0068015S","CS0068002S","CS006809HR","CS0068002H","CS0068014S","CS006809SR","CS006820SR","CS006813SR","CS006820HR","CS006810SR","CS006814HR","CS0068013H","CS0068006H","CS0068003S","CS0068006S","CS006801SR","CS0068014H","CS006804SR","CS0068015H","CS006812HR","CS006803HR","CS006819HR","CS0068009S","CS0068003H","CS0068010S","CS0068011S","CS006803SR","CS006801HR","CS006802HR","CS0068001H","CS006813HR","CS006817SR","CS0068012S","CS0068004H","CS0068010H","CS0068M002","CS006802SR","CS0068M001","CS0068000C","CS0069002H","CS0069M001","CS0069002S","CS0069001C","CS0069000C","CS0069001H","CS0069001S","CS0069000H","CS0069003S","CS0069002C","CS0069000S","CS0069003H","CS0069003C","CS0070000S","CS0070M001","CS007000HR","CS0070000H","CS0070000C","CS007000SR","CS0071M001","CS0071000S","CS0071000C","CS0071001H","CS0071000H","CS0071001S","CS0072000H","CS0072000C","CS0072000S","CS007201HR","CS007200SR","CS0072001S","CS007202HR","CS0072M001","CS007200HR","CS007202SR","CS0072001H","CS007201SR","CS0073000S","CS0073000C","CS0073000H","CS0073M001","CS0074000H","CS0074M001","CS0074000C","CS0074000S","CS0075000S","CS0075M001","CS0075000H","CS0075000C","CS007700HR","CS0077002S","CS0077001H","CS0077002H","CS0077M001","CS0077001S","CS0077000C","CS0077000H","CS0077000S","CS007700SR","CS0080M002","CS008002SR","CS0080000S","CS008002HR","CS0080012H","CS0080002H","CS0080004S","CS0080000C","CS0080011S","CS0080005H","CS0080006S","CS0080M001","CS0080009H","CS0080009S","CS0080007H","CS0080012S","CS0080006H","CS0080004H","CS0080008S","CS008001HR","CS0080005S","CS008001SR","CS0080001C","CS0080000H","CS0080010H","CS0080001S","CS0080010S","CS0080001H","CS0080002S","CS0080003H","CS0080011H","CS0080003S","CS0080008H","CS0080007S","CS008000HR","CS008000SR","CS0081000H","CS0081M001","CS0081000C","CS0081000S","CS0082M001","CS0082000C","CS0082000H","CS0082000S","CS0083006H","CS008302SR","CS0083008S","CS0083001S","CS0083001C","CS0083011H","CS0083005S","CS008300HR","CS008302HR","CS008300SR","CS0083013H","CS008303HR","CS0083012S","CS0083002S","CS0083015H","CS0083004S","CS0083007H","CS0083012H","CS0083006S","CS0083010S","CS0083000H","CS0083014S","CS0083005H","CS0083009H","CS0083016S","CS0083008H","CS0083007S","CS0083002H","CS008301SR","CS0083000S","CS0083011S","CS0083015S","CS0083M001","CS008301HR","CS0083014H","CS0083001H","CS0083013S","CS0083004H","CS0083009S","CS0083M002","CS0083000C","CS0083010H","CS0083016H","CS0083003H","CS008303SR","CS0083003S","CS0084000S","CS0084000C","CS0084000H","CS0084001S","CS0084M001","CS0084001H","CS0088M001","CS0088000S","CS0088000C","CS0088000H","CS0090M001","CS0090000C","CS009000SR","CS0090000H","CS0090000S","CS009000HR","CS0091000C","CS0091M001","CS0091000S","CS0091000H","CS0093000H","CS0093M001","CS0093000S","CS0093000C","CS0095007S","CS009503SR","CS0095005S","CS009513SR","CS009509SR","CS0095000H","CS0095001H","CS0095006H","CS0095004S","CS0095001S","CS009512SR","CS009501HR","CS0095000S","CS0095009H","CS0095002S","CS009506SR","CS0095003S","CS009502HR","CS009510SR","CS009504SR","CS0095003H","CS009500HR","CS009511HR","CS0095008H","CS0095009S","CS009503HR","CS009505HR","CS009512HR","CS0095007H","CS009501SR","CS009507HR","CS0095M001","CS009509HR","CS0095008S","CS0095002H","CS009502SR","CS009513HR","CS009508HR","CS0095000C","CS0095005H","CS009500SR","CS009507SR","CS009504HR","CS009510HR","CS009505SR","CS009506HR","CS0095004H","CS0095006S","CS009511SR","CS009508SR","CS0098003H","CS009800SR","CS0098004S","CS009804SR","CS0098006S","CS0098001H","CS009805HR","CS0098006H","CS009805SR","CS009801HR","CS0098000H","CS0098000C","CS0098002H","CS0098005S","CS0098003S","CS0098005H","CS0098001S","CS009806SR","CS009807HR","CS009803SR","CS0098M001","CS0098000S","CS009800HR","CS0098004H","CS009804HR","CS009802HR","CS0098002S","CS009803HR","CS009806HR","CS009801SR","CS009807SR","CS009802SR","CS0099000H","CS0099000C","CS0099000S","CS0099M001","CS0104M001","CS0104000C","CS0104000H","CS0104000S","CS0105M001","CS0105000H","CS0105000C","CS0105000S","CS0106004S","CS0106002S","CS0106001S","CS0106005S","CS010601HR","CS010600HR","CS0106004H","CS0106008S","CS010602SR","CS0106002H","CS0106000C","CS0106007H","CS0106006H","CS0106008H","CS010601SR","CS0106003S","CS0106003H","CS0106M001","CS0106000H","CS0106006S","CS0106000S","CS0106005H","CS010600SR","CS0106007S","CS0106001H","CS010602HR","CS0108000H","CS0108002S","CS0108000S","CS0108000C","CS0108001S","CS0108001H","CS0108002H","CS0108M001","CS010900HR","CS0109001S","CS010900SR","CS0109003S","CS0109000H","CS0109004S","CS0109000C","CS0109002S","CS0109003H","CS010901SR","CS010901HR","CS0109004H","CS0109002H","CS0109M001","CS0109001H","CS0109000S","CS0111M001","CS0111000H","CS0111000C","CS0111000S","CS0112000S","CS0112000H","CS0112M001","CS0112000C","CS0113000S","CS0113M001","CS0113000C","CS0113000H","CS0114001H","CS0114006S","CS011402HR","CS0114005S","CS0114M001","CS0114000C","CS011402SR","CS0114000S","CS011400HR","CS0114004H","CS0114003S","CS011401SR","CS0114006H","CS0114004S","CS0114002H","CS011401HR","CS0114002S","CS0114005H","CS0114000H","CS0114001S","CS011400SR","CS0114003H","CS0115000H","CS0115001H","CS0115000C","CS0115001S","CS0115000S","CS0115M001","CS011600HR","CS0116000S","CS0116M001","CS011600SR","CS0116000C","CS0116000H","CS0118000S","CS0118000C","CS0118000H","CS0118M001","CS011900SR","CS0119000H","CS0119002H","CS0119002S","CS0119001H","CS011900HR","CS0119000S","CS0119000C","CS0119M001","CS0119001S","CS012000SR","CS012000HR","CS012001HR","CS0120000H","CS0120M001","CS0120000S","CS012001SR","CS0120000C","CS012100HR","CS012100SR","CS0121000S","CS0121M001","CS0121000H","CS0121000C","CS0122000S","CS0122006H","CS0122004S","CS0122004H","CS0122000H","CS0122M001","CS0122001S","CS0122003H","CS0122002H","CS0122005S","CS0122000C","CS0122002S","CS0122001H","CS0122003S","CS0122M002","CS0122005H","CS0122006S","CS0123000S","CS0123M001","CS0123000H","CS0123000C","CS0125000S","CS0125001C","CS0125M001","CS0125001S","CS0125000C","CS0125000H","CS0125001H","CS0126000H","CS0126000C","CS0126000S","CS0126M001","CS012700HR","CS0127000H","CS012700SR","CS0127000C","CS012701HR","CS012701SR","CS0127000S","CS0127M001","CS012801HR","CS0128001C","CS012800HR","CS0128M001","CS012801SR","CS0128000H","CS0128000S","CS012800SR","CS0129000S","CS0129000C","CS0129001H","CS0129000H","CS012900HR","CS0129M001","CS0129001S","CS012900SR","CS013002HR","CS0130000S","CS0130006H","CS013001SR","CS0130003H","CS013002SR","CS013004SR","CS0130001S","CS0130000H","CS0130005S","CS0130005H","CS0130006S","CS013003HR","CS0130004H","CS013004HR","CS0130M001","CS0130001H","CS013001HR","CS0130004S","CS0130002S","CS0130000C","CS0130002H","CS0130003S","CS013003SR","CS0131M001","CS0131000H","CS0131000S","CS0131000C","CS0133M001","CS0133000C","CS0133001P","CS0133000P","CS0134001C","CS0134002S","CS0134000S","CS013400SR","CS013400HR","CS0134002H","CS0134M001","CS0134000C","CS0134000H","CS0134001S","CS0134002C","CS0134001H","CS0135M001","CS0135001P","CS0135000P","CS0135000C","CS0136M001","CS0136M002","CS013600SR","CS0136002S","CS013600HR","CS0136006H","CS0136000C","CS0136002H","CS0136003H","CS0136005S","CS0136000S","CS0136005H","CS0136001S","CS0136004S","CS0136004H","CS0136006S","CS0136000H","CS0136001H","CS0136003S","CS0137000H","CS0137000C","CS0137000S","CS0137M001","CS0138000C","CS0138000S","CS0138000H","CS013801SR","CS013801HR","CS013800HR","CS013800SR","CS0138M001","CS0139000C","CS0139000S","CS0139000H","CS0139M001","CS0140000H","CS0140000S","CS0140000C","CS0140M001","CS0141000C","CS0141007H","CS014101HR","CS0141004H","CS0141000H","CS014101SR","CS0141008S","CS0141005H","CS0141008H","CS0141001S","CS014100SR","CS0141002S","CS0141007S","CS0141005S","CS0141001H","CS0141003H","CS0141M001","CS0141006S","CS0141000S","CS0141002H","CS0141003S","CS0141004S","CS014100HR","CS0141006H","CS0142000H","CS0142000C","CS0142000S","CS014200SR","CS0142001S","CS014200HR","CS0142002H","CS0142001H","CS014201SR","CS0142002S","CS014201HR","CS0142M001","CS0143M001","CS0143000C","CS0143000H","CS0143000S","CS0144000H","CS014401SR","CS0144M001","CS014400HR","CS0144000C","CS014400SR","CS014401HR","CS0144000S","CS0145000H","CS0145M001","CS0145000S","CS0145000C","CS0147000H","CS0147000S","CS0147M001","CS014701SR","CS014702SR","CS014701HR","CS014702HR","CS0147000C","CS014800SR","CS014800HR","CS0148M001","CS0148000S","CS0148000C","CS0148000H","CS014916SR","CS0149004H","CS014905HR","CS0149005S","CS0149005H","CS014918HR","CS0149M001","CS014913SR","CS014908HR","CS0149009S","CS014901HR","CS014918SR","CS014913HR","CS014903SR","CS0149001S","CS014902HR","CS014907SR","CS0149002S","CS014910SR","CS0149020H","CS014919HR","CS014910HR","CS014911HR","CS014915HR","CS014914HR","CS014909HR","CS0149004S","CS014901SR","CS0149010H","CS0149006S","CS014906HR","CS0149020S","CS014907HR","CS0149011H","CS0149008H","CS014908SR","CS0149001H","CS014917HR","CS014904HR","CS014904SR","CS0149M003","CS014902SR","CS014920HR","CS0149003H","CS014914SR","CS0149012S","CS014917SR","CS0149007S","CS0149011S","CS014916HR","CS0149009H","CS014920SR","CS014912HR","CS0149012H","CS014919SR","CS0149001C","CS0149006H","CS0149010S","CS0149002H","CS014915SR","CS014911SR","CS014912SR","CS014906SR","CS014905SR","CS014903HR","CS0149003S","CS0149008S","CS0149007H","CS014909SR","CS0150000C","CS0150000H","CS0150M001","CS0150000S","CS0151000H","CS0151000C","CS0151000S","CS0151M001","CS0152002H","CS0152001S","CS0152001C","CS0152001H","CS0152M001","CS0152002S","CS0153002S","CS0153003S","CS015302SR","CS015302HR","CS0153003H","CS0153005H","CS0153M001","CS0153004S","CS0153005S","CS0153006S","CS015301SR","CS0153001S","CS0153002H","CS0153001C","CS0153001H","CS0153006H","CS015301HR","CS0153004H","CS0154001H","CS015400SR","CS015408HR","CS0154002S","CS0154008S","CS0154006H","CS0154008H","CS015405SR","CS015406HR","CS015408SR","CS0154000H","CS015405HR","CS015401HR","CS0154000C","CS0154003H","CS015402HR","CS0154M001","CS015404HR","CS0154000S","CS0154005S","CS0154006S","CS015407SR","CS0154004H","CS015402SR","CS0154003S","CS015407HR","CS0154007H","CS015406SR","CS015401SR","CS015403SR","CS0154001S","CS0154005H","CS015400HR","CS0154007S","CS0154002H","CS0154004S","CS015403HR","CS015404SR","CS0155001C","CS015502SR","CS0155M001","CS015501HR","CS0155001S","CS015501SR","CS015502HR","CS0155001H","CS0156001H","CS0156M001","CS015602HR","CS0156001S","CS015603HR","CS015601SR","CS015604HR","CS015602SR","CS015603SR","CS0156M002","CS0156002S","CS015604SR","CS0156002H","CS0156001C","CS015601HR","CS0157M001","CS0157004H","CS0157005S","CS015702HR","CS0157002S","CS0157006S","CS0157004S","CS0157001H","CS0157002H","CS0157007H","CS0157001S","CS015702SR","CS0157003H","CS0157003S","CS0157005H","CS0157007S","CS0157001C","CS015701HR","CS0157006H","CS015701SR","CS0158M001","CS0158003S","CS0158001H","CS0158002H","CS0158001S","CS0158003H","CS0158002S","CS0158001C","CS015902SR","CS0159002H","CS015901SR","CS0159004S","CS015902HR","CS0159005C","CS0159002C","CS0159003S","CS0159003C","CS0159003H","CS0159004H","CS0159M001","CS0159001H","CS0159001C","CS0159002S","CS015901HR","CS0159001S","CS0159004C","CS0161007S","CS0161008H","CS0161M001","CS0161001H","CS0161005S","CS0161002H","CS0161003S","CS0161002S","CS0161010S","CS016102SR","CS016101HR","CS0161010H","CS0161008S","CS0161006S","CS0161006H","CS016102HR","CS0161003H","CS0161007H","CS0161009H","CS0161002C","CS016101SR","CS0161001S","CS0161005H","CS0161M002","CS0161001C","CS0161004H","CS0161009S","CS0161004S","CS0162M001","CS0162000H","CS0162000S","CS0162000C","CS0163001S","CS0163001H","CS0163M001","CS016302SR","CS0163001C","CS016302HR","CS0164001H","CS016403HR","CS016402SR","CS016403SR","CS016402HR","CS0164001S","CS0164001C","CS0164M001","CS0165000C","CS0165000S","CS0165000H","CS0165M001","CS0166M001","CS0166001C","CS0166001H","CS0166001S","CS0167000H","CS0167M001","CS0167000S","CS0167000C","CS016800HR","CS0168M001","CS0168001C","CS0168001H","CS016801SR","CS016801HR","CS016800SR","CS0168001S","CS016901SR","CS0169M001","CS0169001H","CS016901HR","CS016902HR","CS016902SR","CS0169001S","CS0169001C","CS0170M001","CS017000SR","CS017001HR","CS0170001H","CS017000HR","CS0170001C","CS017001SR","CS0170001S","CS017101SR","CS0171M001","CS017100SR","CS0171001S","CS0171001C","CS017100HR","CS017101HR","CS0171001H","CS017200SR","CS017201SR","CS017201HR","CS0172001C","CS017200HR","CS0172M001","CS0172001S","CS0172001H","CS017300SR","CS0173001C","CS017300HR","CS017301SR","CS0173M001","CS0173001S","CS017301HR","CS0173001H","CS0174M001","CS017401SR","CS0174001S","CS0174001C","CS017400HR","CS0174001H","CS017400SR","CS017401HR","CS017500SR","CS0175001H","CS0175001C","CS017501SR","CS017501HR","CS017500HR","CS0175002S","CS0175006S","CS0175003S","CS0175003H","CS0175004H","CS0175005S","CS0175001S","CS0175M001","CS0175007S","CS0175007H","CS0175006H","CS0175005H","CS0175004S","CS0175002H","CS0176001C","CS0176001S","CS0176M001","CS0176001H","CS0177006H","CS0177003H","CS0177002H","CS0177008H","CS0177005S","CS0177008S","CS0177009S","CS017701HR","CS0177009H","CS017701SR","CS0177007S","CS0177004H","CS0177001C","CS017702SR","CS0177003S","CS0177004S","CS0177005H","CS0177M001","CS0177006S","CS0177007H","CS0177002S","CS0177001S","CS017702HR","CS0177001H","CS0178001C","CS0178001S","CS0178001H","CS0178M001","CS0179001H","CS0179M001","CS0179001C","CS0179001S","CS0180001H","CS0180001C","CS0180001S","CS0180M001","CS0181001S","CS018102HR","CS0181M001","CS0181001H","CS0181005H","CS0181003S","CS0181002S","CS018101HR","CS0181004S","CS0181003H","CS0181002H","CS0181000C","CS0181004H","CS0181005S","CS018101SR","CS018102SR","CS0182001S","CS018202SR","CS018201HR","CS0182M001","CS018201SR","CS018202HR","CS0182001H","CS0182000C","CS0183M001","CS0183001H","CS0183000C","CS0183001S","CS0184M001","CS0184000S","CS0184000H","CS0184000C","CS0185001H","CS0185000C","CS0185001S","CS0185M001","CS0186000S","CS0186M001","CS0186000H","CS0186000C","CS0187000H","CS0187000C","CS0187000S","CS0187M001","CS0188005H","CS018804SR","CS0188007S","CS018801SR","CS0188002H","CS0188003H","CS018806HR","CS0188005S","CS0188001C","CS018803HR","CS0188000C","CS0188006H","CS018807SR","CS0188004S","CS0188001H","CS0188005C","CS018803SR","CS0188M001","CS0188003S","CS018802HR","CS018807HR","CS0188004H","CS0188007C","CS0188002C","CS018801HR","CS018805SR","CS018804HR","CS0188007H","CS0188006C","CS018806SR","CS0188004C","CS018805HR","CS0188001S","CS0188003C","CS018802SR","CS0188006S","CS0188002S","CS0189005H","CS0189M001","CS0189004S","CS0189009H","CS018902SR","CS0189007S","CS0189000C","CS0189010S","CS0189003S","CS0189008H","CS0189007H","CS0189006S","CS0189006H","CS0189001H","CS0189009S","CS0189004H","CS0189002S","CS0189005S","CS0189002H","CS0189001S","CS0189010H","CS0189008S","CS018902HR","CS0189003H","CS018901SR","CS018901HR","CS0190000C","CS0190000H","CS0190M001","CS019001HR","CS0190000S","CS019001SR","CS019000HR","CS019000SR","CS0191000C","CS0191000S","CS0191M001","CS019100SR","CS019100HR","CS0191000H","CS0192001H","CS019201HR","CS0192011H","CS0192009H","CS019202SR","CS0192008S","CS0192007H","CS0192004H","CS0192011S","CS019204SR","CS0192005S","CS019202HR","CS0192004S","CS0192000C","CS0192003H","CS019201SR","CS0192002H","CS0192007S","CS019204HR","CS0192M001","CS0192010H","CS0192008H","CS0192002S","CS0192003S","CS0192009S","CS0192005H","CS0192006S","CS0192010S","CS019203SR","CS019203HR","CS0192001S","CS0192006H","CS019305HR","CS019304SR","CS0193005H","CS019302SR","CS0193002S","CS019304HR","CS0193003S","CS0193004C","CS0193002H","CS0193M001","CS0193005C","CS0193004H","CS019305SR","CS0193003C","CS019303HR","CS0193001H","CS019301SR","CS019301HR","CS0193003H","CS0193000C","CS019303SR","CS0193005S","CS0193004S","CS0193002C","CS0193001C","CS019302HR","CS0193001S","CS0194001C","CS0194000C","CS0194002H","CS0194001H","CS0194M002","CS0194001S","CS0194002S","CS0194M001","CS0195006S","CS019504HR","CS019502SR","CS019503HR","CS0195001H","CS0195002H","CS0195001S","CS0195008S","CS019504SR","CS0195008H","CS0195005S","CS019506SR","CS019503SR","CS0195004S","CS0195002S","CS0195M001","CS0195003S","CS0195007H","CS019501SR","CS0195005H","CS019506HR","CS0195006H","CS0195003H","CS0195004H","CS0195000C","CS019505SR","CS019505HR","CS019501HR","CS0195007S","CS019502HR","CS019601HR","CS019606HR","CS019608HR","CS019607HR","CS019614HR","CS019611SR","CS019603HR","CS0196003S","CS019610SR","CS0196012H","CS0196M001","CS0196006H","CS0196011H","CS0196005H","CS019602SR","CS019611HR","CS0196007H","CS0196002H","CS0196010S","CS0196004S","CS0196011S","CS0196004H","CS0196001S","CS019605SR","CS0196015H","CS019612HR","CS0196010H","CS019610HR","CS019603SR","CS019614SR","CS019601SR","CS0196009H","CS0196013S","CS0196005S","CS019609SR","CS019604HR","CS0196008H","CS019613HR","CS019609HR","CS0196003H","CS0196006S","CS0196007S","CS019602HR","CS0196000C","CS019605HR","CS0196002S","CS0196014S","CS0196008S","CS019612SR","CS0196013H","CS019608SR","CS0196001H","CS0196012S","CS019606SR","CS0196009S","CS0196014H","CS0196015S","CS019607SR","CS019613SR","CS019604SR","CS019702HR","CS0197005H","CS0197M001","CS019701HR","CS0197003S","CS019702SR","CS0197000C","CS0197002S","CS0197001H","CS019701SR","CS0197003H","CS0197002H","CS0197004H","CS0197005S","CS0197001S","CS0197004S","CS0198M001","CS0198000C","CS0198001H","CS0198001S","CS0198002H","CS0198002S","CS0198003H","CS0198003S","CS0198004H","CS0198004S","CS0198005H","CS0198005S","CS0198006H","CS0198006S","CS0198007H","CS0198007S","CT223901HR","CT223900HR","CT223900SR","CT2239005H","CT2239001H","CT2239006H","CT2239004S","CT2239002H","CT2239003H","CT2239004H","CT2239000H","CT223901SR","CT2239M001","CT2239003S","CT2239000S","CT2239002S","CT2239006S","CT2239005S","CT2239001S","CT2239000C","CT2246000S","CT2246000H","CT2246000C","CT2246M001","CT2252000C","CT2252000S","CT2252000H","CT2252M001","L0012501SR","L00125002S","L00125004S","L00125000C","L0012501HR","L00125000H","L00125000S","L00125M001","L00125001S","L0012500SR","L00125002H","L00125003H","L00125004H","L00125005H","L0012500HR","L00125003S","L00125001H","L00125005S","L00268M001","L00268000S","L00268001S","L00268000H","L00268000C","L00268001H","L00283000S","L00283000C","L00283000H","L00283M001","L00284000S","L00284M001","L00284000C","L00284000H","L00285001S","L00285000C","L00285002S","L00285001H","L00285002H","L00285000H","L00285000S","L00285M001","L00334002H","L00334004S","L00334004H","L0033400SR","L0033401HR","L00334003S","L00334000C","L00334001H","L00334002S","L0033401SR","L00334001S","L00334000S","L00334003H","L00334M001","L00334000H","L0033400HR","L00357000S","L00357M001","L00357001H","L00357001S","L00357000H","L0036703SR","L00367002S","L0036702HR","L00367000S","L00367M001","L00367000H","L00367001S","L0036700HR","L00367001H","L00367002H","L0036701SR","L00367000C","L0036703HR","L0036700SR","L0036701HR","L0036702SR"],isEligibleByMatchType=e=>{switch(e){case M._.FULL_MATCH:case M._.ELIGIBLE_MATCH:return!0;case M._.PERSON_MATCH:case M._.INSURANCE_MATCH:case M._.EXPIRED:case M._.NOT_FOUND:default:return!1}},isBenefitsEligible=e=>{var t,a,r;return!!e&&(null===(t=e.coverage)||void 0===t?void 0:t.status)==="Active"&&(null===(a=e.payer)||void 0===a?void 0:a.payerName)==="BCBS of Connecticut"&&F.includes(null===(r=e.coverage)||void 0===r?void 0:r.groupNumber)},isEligibleForAutoEnrollment=e=>{let{matchType:t,benefitsCheck:a}=e;return isEligibleByMatchType(t)||isBenefitsEligible(a)},getLeadStatus=e=>{let{matchType:t,benefitsCheck:a}=e;if(!isEligibleForAutoEnrollment({matchType:t,benefitsCheck:a}))return x.rl.EligibleWaiting},removeInsuranceMemberIdPrefix=e=>e.substring(3),getEligibilityVerifiedBy=e=>{let{matchType:t,benefitsCheck:a}=e,r=isEligibleByMatchType(t),i=isBenefitsEligible(a);return r&&i?M.V.EvolveAndPverify:i?M.V.Pverify:r?M.V.Evolve:void 0};(r=i||(i={})).CheckEligibility="checkEligibility",r.CreateLead="createLead",r.CheckBenefits="checkBenefits";let O={...w.a,...i},B=j.aU[D.kT.CareCompass],U={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insurance:void 0,lastName:"",phone:"",state:void 0,termsAgreement:!1,howDidYouFindUS:"",comorbidities:[],diabetes:"",bariatricSurgery:""},eligibilityCheckMatchType:void 0,bmi:void 0,benefitsCheck:void 0},J={...A.OX,...A.cp,...(0,A.Ww)(U)},N=(0,k.cY)({types:{},guards:{isPreEligibilityMet:e=>{let{context:{formData:t,bmi:a}}=e;return T.Pq.careCompass({bmi:a,comorbidity:t.comorbidity,birthdate:t.birthdate})},isApplicationReviewRequired:e=>{let{context:{eligibilityCheckMatchType:t,benefitsCheck:a}}=e;return!isEligibleForAutoEnrollment({matchType:t,benefitsCheck:a})},isApplicationDetected:E.Q},actions:J}).createMachine({context:()=>U,id:"careCompassMachine",initial:O.PreEligibility,states:{[O.PreEligibility]:{id:O.PreEligibility,initial:O.Idle,states:{[O.Idle]:{on:{SUBMIT:{target:O.Submitting,actions:"updateFormData"}}},[O.Submitting]:{entry:"assignBMI",always:[{target:"#".concat(O.ContactDetails),guard:"isPreEligibilityMet"},{target:"#".concat(O.EligibilityUnmet)}]}}},[O.ContactDetails]:{id:O.ContactDetails,initial:O.Idle,states:{[O.Idle]:{on:{SUBMIT:{target:"#".concat(O.InsuranceDetails),actions:"updateFormData"}}}}},[O.InsuranceDetails]:{id:O.InsuranceDetails,initial:O.Idle,states:{[O.Idle]:{on:{BACK:{target:"#".concat(O.ContactDetails)},SUBMIT:{target:"#".concat(O.InsuranceDetailsReview),actions:"updateFormData"}}}}},[O.InsuranceDetailsReview]:{id:O.InsuranceDetailsReview,initial:O.Idle,states:{[O.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:O.Submitting}}},[O.Submitting]:{type:"parallel",states:{[O.CheckEligibility]:{id:O.CheckEligibility,initial:O.Idle,states:{[O.Idle]:{invoke:{src:(0,P.p4)(async e=>{let{input:t}=e,a={...t,insuranceMemberID:removeInsuranceMemberIdPrefix(t.insuranceMemberID),insurance:j.Er[D.kT.CareCompass],benefitProgram:j.Q1[D.kT.CareCompass]};return await (0,I.m)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:{actions:(0,L.a)({eligibilityCheckMatchType:e=>{let{event:t}=e;return t.output.data.matchType}}),target:O.Success},onError:O.Success}},[O.Success]:{type:"final"}}},[O.CheckBenefits]:{id:O.CheckBenefits,initial:O.Idle,states:{[O.Idle]:{invoke:{src:(0,P.p4)(async e=>{let{input:t}=e,a={...t,payerCode:j.qK[D.PF.Anthem]};return await (0,v.o)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:{actions:(0,L.a)({benefitsCheck:e=>{let{event:t}=e;return t.output.data}}),target:O.Success},onError:{target:O.Success}}},[O.Success]:{type:"final"}}}},onDone:{target:O.CreateLead}},[O.CreateLead]:{id:O.CreateLead,invoke:{src:(0,P.p4)(async e=>{let{input:t}=e,a=removeInsuranceMemberIdPrefix(t.formData.insuranceMemberID),r={...t.formData,...t.formData.insuranceMemberID&&{employmentVerificationCode:a,insuranceMemberID:a},...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},eligibilityVerifiedBy:getEligibilityVerifiedBy({matchType:t.eligibilityCheckMatchType,benefitsCheck:t.benefitsCheck}),company:B,insurance:j.KG[D.kT.CareCompass],evolveOrganization:D.bV["State of Connecticut"],leadStatus:getLeadStatus({matchType:t.eligibilityCheckMatchType,benefitsCheck:t.benefitsCheck}),automateEvolveEnrollment:isEligibleForAutoEnrollment({matchType:t.eligibilityCheckMatchType,benefitsCheck:t.benefitsCheck})};return await (0,R.$)(r)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isApplicationReviewRequired",target:"#".concat(O.ApplicationReview)},{target:"#".concat(O.ApplicationComplete)}],onError:[{guard:"isApplicationDetected",target:"#".concat(O.ApplicationDetected)},{target:"#".concat(O.Error)}]}},[O.Error]:{id:O.Error,on:{SUBMIT:{actions:["updateFormData","resetBenefitsCheck"],target:O.Submitting}}}}},[O.ApplicationReview]:{id:O.ApplicationReview},[O.ApplicationComplete]:{id:O.ApplicationComplete},[O.ApplicationDetected]:{id:O.ApplicationDetected},[O.EligibilityUnmet]:{id:O.EligibilityUnmet,initial:O.Idle,states:{[O.Idle]:{on:{SUBMIT:{target:O.Submitting,actions:"updateFormData"}}},[O.Submitting]:{invoke:{src:(0,P.p4)(async e=>{let{input:t}=e,a={...t,company:B,leadStatus:D.rl.Ineligible,ineligibilityReason:D.ib.BMI,automateEvolveEnrollment:!1};return await (0,R.$)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:O.Success,onError:O.Error}},[O.Success]:{},[O.Error]:{on:{SUBMIT:{actions:"updateFormData",target:O.Submitting}}}}}},on:{RESET:{target:"#".concat(O.PreEligibility),actions:"reset"}}});var W=a(56344);let V={[b.J.PreEligibility]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"Let's make sure you're eligible for the FlyteHealth program."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"To be eligible for the FlyteHealth program through your State of Connecticut Health Plan benefits, you must meet specific age and Body Mass Index (BMI)* requirements."})]}),bmiEnrollmentDisclaimer:(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. FlyteHealth providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the FlyteHealth program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[b.J.EligibilityUnmet]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Unfortunately, you are not eligible to join FlyteHealth at this time."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"The FlyteHealth program requires a minimum BMI of 27+ (plus one or more weight-related health conditions) or a BMI of 30+."})]}),alert:(0,n.jsx)(()=>(0,n.jsxs)(o.Alert,{status:"info",variant:"subtle",bgColor:"background-action-hover",p:"spacer-5",flexDirection:{base:"column",md:"row"},gap:{base:"spacer-3",md:"spacer-5"},alignItems:{base:"flex-start"},children:[(0,n.jsx)(o.Image,{width:"70.56px",height:"auto",src:"/static/assets/insurance-cards.png",alt:"Insurance cards illustration"}),(0,n.jsxs)(o.Flex,{direction:"column",flex:"1",children:[(0,n.jsx)(o.Alert.Title,{textStyle:"text-body-large-bold",mb:"spacer-1",children:"Additional State of Connecticut Benefits"}),(0,n.jsx)(o.Alert.Description,{mb:"spacer-3",children:"While the FlyteHealth program isn't a match for you today, the State of Connecticut Health Plan offers a wide range of options that might suit your needs."}),(0,n.jsx)(o.Link,{href:"https://carecompass.ct.gov/state/medical/",color:"text-link-primary-default",isExternal:!0,trailingIcon:(0,n.jsx)(o.IconArrowRight,{color:"text-link-primary-default"}),children:"Learn More"})]})]}),{})},[b.J.ContactDetails]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Congratulations! You're eligible for the FlyteHealth program"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"To help us match your information with your employer, tell us about yourself. Next, we'll ask about your Anthem membership. Be sure to have your insurance card handy."})]})},[b.J.InsuranceDetails]:{title:(0,n.jsxs)(o.Text,{variant:"text-header-2XL",color:"text-secondary-negative",children:["One more thing:"," ",(0,n.jsx)(o.Text,{as:"span",variant:"text-header-2XL",color:"text-primary",children:"What's your Anthem membership number?"})]})},[b.J.InsuranceDetailsReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{children:"Let's review: Is your info correct?"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Please double-check the information you provided to make sure everything is correct."})]})},[b.J.ApplicationComplete]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Welcome aboard! We're so excited you're here."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Next, we need to confirm your email. Click the link we sent to:"})]}),description:(0,n.jsx)(o.Text,{mt:"spacer-8",color:"text-secondary",variant:"text-body-regular",children:"Can’t find the email? Make sure to check your Spam folder."})},[b.J.ApplicationReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]})},[b.J.ApplicationDetected]:{title:(0,n.jsx)(o.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,n.jsx)(o.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[b.J.OnboardingChecklist]:W.T[b.J.OnboardingChecklist],[b.J.CreatePassword]:W.T[b.J.CreatePassword],[b.J.AppDownload]:W.T[b.J.AppDownload],[b.J.ReviewConsents]:W.T[b.J.ReviewConsents]};var _=a(58976);let q=[x.Op.EmailMailer,x.Op.CoworkerReferral,x.Op.ProviderReferral,x.Op.QuantumHealth,x.Op.WordOfMouth,x.Op.Pharmacy,x.Op.BenefitsWebsite,x.Op.Other],z={maxLength:13,minLength:13,registerOptions:{minLength:{value:13,message:"Enter the 13-character member ID number."},maxLength:{value:13,message:"Enter the 13-character member ID number."}},inputMode:"text",maskOptions:{mask:/^[a-z0-9]+$/i},label:"Anthem Membership ID Number",placeholder:"Insurance ID"},Y={[b.J.ContactDetails]:{state:{options:_.Fp},howDidYouFindUs:{options:q}},[b.J.InsuranceDetails]:{insuranceMemberID:{...z,tooltip:(0,n.jsxs)(o.Box,{children:[(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-light",children:"Where to find my Membership ID Number:"}),(0,n.jsx)(o.Image,{width:"100%",height:"auto",src:"https://images.ctfassets.net/0t897tgc80v7/7uNdTqwf8eRDlvJB51S69E/972a00db0acaa4136dd531435cc22d36/anthem_member_id_13_char.png",alt:"Member ID guidance"})]}),description:(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Enter the 13-character Member ID number as displayed on your Anthem Membership ID Card."})}},[b.J.InsuranceDetailsReview]:{insuranceMemberID:z}},X=x.kT.CareCompass,CareCompassWorkflow=e=>{let{render:t}=e,[a,r]=(0,H.eO)(N),i=(0,f.useMemo)(()=>(0,y.k)(a.value),[a.value]);(0,g.R)(i,X);let v=(0,f.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),I=(0,f.useCallback)(()=>{r({type:"BACK"})},[r]),R=(0,f.useCallback)(()=>{switch(i){case O.PreEligibility:return(0,n.jsx)(h.b,{configuration:{contentResources:V[b.J.PreEligibility]},onSubmit:v});case O.ContactDetails:return(0,n.jsx)(u.q,{configuration:{contentResources:V[b.J.ContactDetails],fields:Y[b.J.ContactDetails]},onSubmit:v,defaultValues:a.context.formData});case O.EligibilityUnmet:return(0,n.jsx)(C.X,{configuration:{contentResources:V[b.J.EligibilityUnmet]},onSubmit:v,loading:a.matches({[O.EligibilityUnmet]:O.Submitting}),isEmailSent:a.matches({[O.EligibilityUnmet]:O.Success}),hasError:a.matches({[O.EligibilityUnmet]:O.Error}),isMobileFooterSticky:!1});case O.InsuranceDetails:return(0,n.jsx)(m.v,{configuration:{contentResources:V[b.J.InsuranceDetails],fields:Y[b.J.InsuranceDetails]},onSubmit:v,onBack:I});case O.InsuranceDetailsReview:return(0,n.jsx)(p.b,{configuration:{contentResources:V[b.J.InsuranceDetailsReview],fields:Y[b.J.InsuranceDetailsReview]},onSubmit:v,loading:a.matches({[O.InsuranceDetailsReview]:O.Submitting})||a.matches({[O.InsuranceDetailsReview]:O.CreateLead}),hasError:a.matches({[O.InsuranceDetailsReview]:O.Error}),defaultValues:a.context.formData});case O.ApplicationComplete:return(0,n.jsx)(s.J,{...V[b.J.ApplicationComplete],email:a.context.formData.email});case O.ApplicationReview:return(0,n.jsx)(c.G,{...V[b.J.ApplicationReview]});case O.ApplicationDetected:return(0,n.jsx)(l.v,{...V[b.J.ApplicationDetected],email:a.context.formData.email});default:return null}},[i,a]);return t({header:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(o.Flex,{gap:"spacer-5",alignItems:"center",children:[(0,n.jsx)(d.E,{partner:x.kT.Flyte}),(0,n.jsx)(o.Divider,{orientation:"vertical",alignSelf:"stretch",height:"auto"}),(0,n.jsx)(d.E,{partner:X})]}),(0,n.jsx)(S.K,{currentStep:i})]}),body:R(),currentWorkFlowStep:i})}},33407:function(e,t,a){a.d(t,{k:function(){return ChristianaCareWorkflow}});var r,i,n=a(85893),o=a(71986),s=a(44761),l=a(33640),c=a(65660),d=a(20410),S=a(31540),u=a(30624),C=a(70908),m=a(67294);let p=[{label:"Age & BMI",icon:o.IconScaleOutline},{label:"Personal Details",icon:o.IconId},{label:"Insurance Info",icon:o.IconClipboardPlus}],h=[{label:"CARE AGREEMENTS",icon:o.IconFile},{label:"CREATE PASSWORD",icon:o.IconLock},{label:"LABS",icon:o.IconPill},{label:"DOWNLOAD APP",icon:o.IconDownload}],WorkflowHeaderLabs=e=>{let{currentStep:t}=e;switch(t){case C.J.PreEligibility:return(0,n.jsx)(u.E,{currentStep:"Age & BMI",steps:p});case C.J.ContactDetails:return(0,n.jsx)(u.E,{currentStep:"Personal Details",steps:h});case C.J.InsuranceDetails:return(0,n.jsx)(u.E,{currentStep:"Insurance Info",steps:h});case C.J.RequestLabs:case C.J.SubmitLabs:return(0,n.jsx)(u.E,{currentStep:"LABS",steps:h});case C.J.AppDownload:return(0,n.jsx)(u.E,{currentStep:"DOWNLOAD APP",steps:h});default:return null}};var g=a(39424),x=a(27350),b=a(86640),y=a(96693),H=a(50793),f=a(83344),v=a(76311),I=a(27950),R=a(73071),D=a(89233);function getLabRequirements(e){return _getGenericLabRequirements({diabetes:e.diabetes,bariatric:e.bariatric})}function _getGenericLabRequirements(e){let t=["Complete Blood Count (CBC)","Comprehensive Metabolic Panel (CMP)","Folate/Folic Acid Level (Vitamin B9)","Hemoglobin A1C (HbA1c)","High-Sensitivity C-Reactive Protein (hs-CRP)","Insulin Level","Iron Status Panel (Iron, Ferritin, and TIBC)","Kidney Protein Test (Urine Albumin/Creatinine Ratio or ACR)","Cholesterol Panel (Lipid Panel)","Thyroid Function Test (TSH with FT4 reflex)","Vitamin B12 Level","Vitamin D Level (25-OH, total)"];return e.bariatric&&t.push("Copper Level, Blood","Folate Level (Vitamin B9)","Free T3 Level","Free T4 Level","Magnesium Level","Manganese Level, Blood","Methylmalonic Acid and Homocysteine Levels","Parathyroid Hormone (PTH), Intact Without Calcium","Prothrombin Time (PT-INR)","Selenium Level","Thyroid Stimulating Hormone (TSH)","Vitamin A Level (Retinol)","Vitamin B1 Level (Thiamine)","Vitamin B6 Level, Plasma","Vitamin C Level","Vitamin E Level (Tocopherol)","Vitamin K Level","Zinc Level"),e.diabetes&&t.push("C-Peptide Level"),t.sort((e,t)=>e.localeCompare(t))}function LabRequirementsDialog(e){let{isOpen:t,onRequestLabs:a,onContinue:r,onClose:i,diabetes:s,bariatric:l}=e;if(!t)return null;let c=getLabRequirements({diabetes:s,bariatric:l,labName:"generic"});return(0,n.jsxs)(o.Modal,{isOpen:t,onClose:i,isCentered:!0,autoFocus:!1,closeOnOverlayClick:!0,children:[(0,n.jsx)(o.Modal.Overlay,{}),(0,n.jsxs)(o.Modal.Content,{px:{base:"spacer-6",lg:"spacer-7"},pb:"spacer-6",mx:0,maxWidth:{base:"100%",md:"600px"},mb:{base:0,lg:"auto"},borderTopRadius:{base:"xl",md:"lg"},borderBottomRadius:{base:"0",md:"lg"},maxHeight:"100vh",children:[(0,n.jsxs)(o.Modal.Header,{px:0,children:[(0,n.jsx)(o.Text,{variant:"text-header-M",color:"text-primary",display:{base:"block",md:"none"},children:"Required Lab results"}),(0,n.jsx)(o.Text,{variant:"text-header-M",color:"text-primary",display:{base:"none",md:"block"},children:"Lab Results Upload Requirements"})]}),(0,n.jsxs)(o.Modal.Body,{p:0,overflow:"hidden",display:"flex",flexDirection:"column",children:[(0,n.jsxs)(o.Alert,{status:"info",variant:"subtle",p:{base:"spacer-4",md:"spacer-2"},overflow:"hidden",children:[(0,n.jsx)(o.Alert.Icon,{}),(0,n.jsxs)(o.Alert.Description,{children:["You can only upload lab results if results are dated within the last"," ",(0,n.jsx)("strong",{children:"90 days"})]})]}),(0,n.jsx)(o.Text,{variant:"text-body-large-medium",mt:"spacer-4",mb:"spacer-3",display:{base:"none",md:"block"},children:"Results should include the following:"}),(0,n.jsx)(o.Box,{mt:{base:"spacer-4",md:"spacer-0"},bg:"background-page-01",fontSize:"18px",maxH:"360px",overflowY:"scroll",mb:"spacer-7",borderRadius:"radii-2",children:c.map(e=>(0,n.jsx)(o.Text,{mx:"spacer-4",py:"spacer-2",variant:"text-body-large-regular",fontSize:"18px",color:"text-secondary",children:e},e))})]}),(0,n.jsxs)(o.Modal.Footer,{flexDirection:"column",gap:"spacer-4",p:0,children:[(0,n.jsx)(o.Button,{variant:"primary",size:"l",width:"100%",onClick:r,rightIcon:(0,n.jsx)(o.IconArrowRight,{}),children:"Continue"}),(0,n.jsx)(o.Button,{size:"l",variant:"primary-alt",width:"100%",onClick:a,leftIcon:(0,n.jsx)(o.IconArrowLeft,{}),children:"Request Labs Instead"}),(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Not sure if your labs meet these requirements? We recommend you to request labs instead."})]})]})]})}function RequestingLabDialog(e){let{isOpen:t}=e;return t?(0,n.jsx)(o.Box,{position:"fixed",top:0,left:0,right:0,bottom:0,bg:"background-overlay",zIndex:9999,display:"flex",alignItems:"center",justifyContent:"center",children:(0,n.jsxs)(o.Flex,{direction:"column",alignItems:"center",justifyContent:"center",textAlign:"center",px:"spacer-6",children:[(0,n.jsx)(o.Spinner,{size:"s",color:"text-light",thickness:"4px",mb:"spacer-6"}),(0,n.jsx)(o.Text,{variant:"text-header-S",color:"text-light",mb:"spacer-2",fontWeight:"bold",children:"We're requesting your Lab"}),(0,n.jsx)(o.Text,{variant:"text-body-meta-medium",color:"text-light",children:"This may take a few seconds, do not close this window."})]})}):null}let LabItemOption=e=>{let{name:t,address:a,city:r,state:i,zipCode:s,distance:l,isRecommended:c=!1,isSelected:d=!1,onChange:S,"data-test":u}=e;return(0,n.jsxs)(o.Box,{borderWidth:"1px",borderStyle:"solid",borderColor:d?"primary-default":"border-subtle",borderRadius:"md",p:"spacer-4",mb:"spacer-3",bg:"background-card",position:"relative",_hover:{borderColor:"border-hovered"},cursor:"pointer",onClick:S,"data-test":u,justifyContent:"start",children:[c&&(0,n.jsx)(o.Tooltip,{hasArrow:!0,placement:"top",label:"These labs offer next-day appointments or walk-in options, and your lab results will be sent directly to FlyteHealth—no manual upload needed",bg:"accent-default",color:"text-light",borderRadius:"md",maxW:"320px",textAlign:"center",children:(0,n.jsx)(o.Tag,{position:"absolute",top:"0",size:"s",right:"spacer-12",transform:"translate(0, -50%)",bg:"background-static",color:"text-light",_hover:{bg:"accent-default"},children:"Recommended"})}),(0,n.jsxs)(o.Flex,{justifyContent:"space-between",alignItems:"start",children:[(0,n.jsxs)(o.Box,{mr:"spacer-3",children:[(0,n.jsxs)(o.Flex,{alignItems:"flex-start",mb:"spacer-2",children:[(0,n.jsx)(o.Text,{variant:"text-header-S",color:"text-primary",fontWeight:"bold",mr:"spacer-3",noOfLines:2,children:t}),(0,n.jsx)(o.Tag,{size:"s",bgColor:"background-static",minWidth:"max-content",children:(0,n.jsxs)(o.Tag.Label,{color:"text-primary",children:[l," ","miles"]})})]}),(0,n.jsx)(o.Text,{fontWeight:400,variant:"text-header-S",color:"text-primary",children:a}),(0,n.jsxs)(o.Text,{fontWeight:400,variant:"text-header-S",color:"text-primary",children:[r,",",i," ",s]})]}),(0,n.jsx)(o.Radio,{isChecked:d,onChange:S,colorScheme:"primary",size:"l"})]})]})};var E=a(35697);async function findLabByZipCode(e){return E.Z.get("api/find-lab?zipCode=".concat(encodeURIComponent(e.zipCode),"&organizationName=").concat(encodeURIComponent(e.organizationName))).then(e=>e.data)}let j={selectedLabId:null,searchResults:[],isLoading:!1,error:null};function searchReducer(e,t){switch(t.type){case"SET_LOADING":return{...e,isLoading:t.payload,error:null};case"SET_RESULTS":return{...e,searchResults:t.payload,isLoading:!1,error:null};case"SET_ERROR":return{...e,error:t.payload,isLoading:!1};case"SELECT_LAB":return{...e,selectedLabId:t.payload};case"RESET_SEARCH":return{...e,searchResults:[],error:null};default:return e}}function SearchLabForm(e){let{organizationName:t,onLabSelected:a}=e,[r,i]=(0,m.useReducer)(searchReducer,j),[s,l]=(0,m.useState)(""),[c,d]=(0,m.useState)(null),S=(0,m.useCallback)(async e=>{if(l(e),!e.trim()){i({type:"RESET_SEARCH"});return}if(5===e.length){i({type:"SET_LOADING",payload:!0});try{let a=await findLabByZipCode({zipCode:e,organizationName:t});if(!a.success)throw Error("Error finding labs. Please try again.");let r=a.data.map(e=>({id:e.id,name:e.name,address:e.address1,city:e.city,state:e.state,zipCode:"",distance:Number(e.distance),isRecommended:e.flags.includes("recommended")}));i({type:"SET_RESULTS",payload:r})}catch(e){console.error(e),i({type:"SET_ERROR",payload:"Error finding labs. Please try again."})}}},[]),u=(0,m.useCallback)(e=>{l(e),c&&clearTimeout(c);let t=setTimeout(()=>{S(e)},500);d(t)},[S,c]),handleLabSelect=e=>{i({type:"SELECT_LAB",payload:e.id})};return(0,n.jsxs)(o.Box,{display:"flex",flexDirection:"column",h:{base:"auto",md:"100%"},children:[(0,n.jsx)(o.Box,{bg:"white",position:"sticky",top:-5,zIndex:1,pt:{base:4,md:0},pb:{base:4,md:4},children:(0,n.jsxs)(o.Box,{py:"spacer-4",px:"spacer-3",bg:"background-dark",borderRadius:"md",flexShrink:0,children:[(0,n.jsx)(o.Text,{variant:"text-header-S",color:"text-light",pb:"spacer-3",children:"Find a Lab Near You"}),(0,n.jsx)(o.Input,{leadingIcon:(0,n.jsx)(o.IconSearch,{}),placeholder:"Enter your zip code to find a lab",value:s,onChange:e=>u(e.target.value),maxLength:5,"data-test":"zipCode"})]})}),(0,n.jsxs)(o.Box,{flexGrow:1,overflowY:"auto",children:[(0,n.jsx)(o.Text,{variant:"text-header-S",mt:"spacer-4",fontWeight:400,color:"text-secondary",children:"Your FlyteHealth provider can submit orders to any listed location. Some locations may have out-of-pocket costs. Please check with the lab or your insurance provider for details."}),(0,n.jsxs)(o.Box,{mt:"spacer-6",children:[r.isLoading&&(0,n.jsx)(o.Box,{textAlign:"center",py:"spacer-8",children:(0,n.jsx)(o.Text,{children:"Searching for labs..."})}),r.error&&(0,n.jsx)(o.Box,{textAlign:"center",py:"spacer-8",children:(0,n.jsx)(o.Text,{color:"text-error",children:r.error})}),!r.isLoading&&!r.error&&0===r.searchResults.length&&5===s.length&&(0,n.jsx)(o.Box,{textAlign:"center",py:"spacer-8",children:(0,n.jsxs)(o.Text,{children:['No labs found for zip code "',s,'". Please try another zip code.']})}),!r.isLoading&&r.searchResults.map(e=>(0,n.jsx)(LabItemOption,{name:e.name,address:e.address,city:e.city,state:e.state,zipCode:e.zipCode,distance:e.distance,isRecommended:e.isRecommended,isSelected:r.selectedLabId===e.id,onChange:()=>handleLabSelect(e),"data-test":"labOption"},e.id))]})]}),r.selectedLabId?(0,n.jsx)(o.Box,{flexShrink:0,position:"sticky",bottom:-5,bg:"white",pt:{base:"spacer-4",md:0},pb:{base:"spacer-4",md:0},mt:{base:0,md:"spacer-6"},mb:{base:0,md:"spacer-6"},children:(0,n.jsx)(o.Button,{size:"l",variant:"primary",width:"100%",isDisabled:!r.selectedLabId,onClick:()=>{if(!r.selectedLabId)return;let e=r.searchResults.find(e=>e.id===r.selectedLabId);e&&a(e)},"data-test":"selectLabButton",children:"Select Lab"})}):null]})}let SelectLabLoadingScreen=()=>(0,n.jsxs)(o.Box,{position:"fixed",top:"0",left:"0",width:"100vw",height:"100vh",backgroundColor:"background-overlay",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",zIndex:"overlay",children:[(0,n.jsx)(o.Spinner,{size:"xs",color:"text-light"}),(0,n.jsx)(o.Text,{variant:"text-body-bold",color:"text-light",mt:"spacer-3",children:"We’re requesting your Lab"}),(0,n.jsx)(o.Text,{variant:"text-body-regular",color:"text-light",mt:"spacer-2",textAlign:"center",children:"This may take a few seconds, do not close this window."})]});async function selectLab(e){await E.Z.post("/api/select-lab",{clinicalProviderId:e.clinicalProviderId,patientId:e.patientId,note:e.note,labName:e.labName,bariatric:e.bariatricSurgery,diabetes:e.diabetes})}function SelectLabForm(e){let{onLabRequested:t,lab:a,onChooseAnotherLab:r,patientId:i,bariatricSurgery:s,diabetes:l}=e,[c,d]=(0,m.useState)(""),[S,u]=(0,m.useState)(!1),[C,p]=(0,m.useState)(null),handleLabRequest=async()=>{try{u(!0),p(null),await selectLab({patientId:i,clinicalProviderId:a.id,note:c.trim()||void 0,labName:a.name,bariatricSurgery:s,diabetes:l}),t(a)}catch(e){console.error("Error selecting lab:",e),p("There was an error selecting the lab. Please try again.")}finally{u(!1)}};return(0,n.jsxs)(o.Box,{children:[(0,n.jsx)(o.Text,{variant:"text-header-S",color:"text-primary",mb:"spacer-2",children:"Your preferred lab"}),(0,n.jsx)(o.Box,{borderWidth:"1px",borderStyle:"solid",borderColor:"border-subtle",borderRadius:"md",p:"spacer-4",mb:"spacer-3",bg:"background-card",position:"relative",_hover:{borderColor:"border-hovered"},cursor:"pointer",children:(0,n.jsx)(o.Flex,{justifyContent:"space-between",alignItems:"center",children:(0,n.jsxs)(o.Box,{children:[(0,n.jsxs)(o.Flex,{alignItems:"center",mb:"spacer-2",children:[(0,n.jsx)(o.Text,{variant:"text-header-S",color:"text-primary",fontWeight:"bold",mr:"spacer-3",children:a.name}),(0,n.jsx)(o.Tag,{size:"s",bgColor:"background-static",children:(0,n.jsxs)(o.Tag.Label,{color:"text-primary",children:[a.distance," ","miles"]})})]}),(0,n.jsx)(o.Text,{fontWeight:400,variant:"text-header-S",color:"text-primary",children:a.address}),(0,n.jsxs)(o.Text,{fontWeight:400,variant:"text-header-S",color:"text-primary",children:[a.city,",",a.state," ",a.zipCode]})]})})}),(0,n.jsxs)(o.Text,{variant:"text-header-S",color:"text-primary",mt:"spacer-5",mb:"spacer-2",children:["Add a note for the care team"," ",(0,n.jsx)(o.Text,{as:"span",variant:"text-body-regular",color:"text-secondary",mb:"spacer-2",children:"(Optional)"})]}),(0,n.jsx)(o.Textarea,{placeholder:"Write a note here",value:c,onChange:e=>d(e.target.value),mb:"spacer-9",rows:1,variant:"flushed",disabled:S}),C&&(0,n.jsx)(o.Text,{color:"text-error",mb:"spacer-4",textAlign:"center",children:C}),(0,n.jsx)(o.Button,{variant:"primary",width:"100%",mb:"spacer-6",onClick:handleLabRequest,disabled:S,size:"l",children:"Request Lab"}),(0,n.jsx)(o.Box,{textAlign:"center",children:(0,n.jsx)(o.Text,{as:"span",variant:"text-body-meta-medium",color:"text-link-primary-default",cursor:"pointer",onClick:r,_hover:{textDecoration:"underline"},children:"Choose another Lab"})}),S?(0,n.jsx)(SelectLabLoadingScreen,{}):null]})}let w={selectedLab:null,isRequesting:!1,showRequirements:!1};function reducer(e,t){switch(t.type){case"RESET_LAB":return{...e,selectedLab:null};case"SELECT_LAB":return{...e,selectedLab:t.lab};case"SET_REQUESTING":return{...e,isRequesting:t.isRequesting};case"SET_SHOW_REQUIREMENTS":return{...e,showRequirements:t.show};default:return e}}function RequestLabsForm(e){let{organizationName:t,patientId:a,onLabRequested:r,onProceedToSubmitLabs:i,formData:s}=e,[l,c]=(0,m.useReducer)(reducer,w),handleShowRequirements=()=>{c({type:"SET_SHOW_REQUIREMENTS",show:!0})};return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(LabRequirementsDialog,{isOpen:l.showRequirements,onRequestLabs:()=>{c({type:"SET_SHOW_REQUIREMENTS",show:!1})},onContinue:()=>{c({type:"SET_SHOW_REQUIREMENTS",show:!1}),i()},onClose:()=>c({type:"SET_SHOW_REQUIREMENTS",show:!1}),diabetes:"yes"===s.diabetes,bariatric:"yes"===s.bariatricSurgery}),(0,n.jsx)(RequestingLabDialog,{isOpen:l.isRequesting}),(0,n.jsxs)(D.S,{opacity:l.isRequesting?0:1,overflow:{base:"auto",md:"hidden"},h:"100%","data-testid":"request-labs-form",children:[(0,n.jsxs)(D.S.Side,{flex:{base:0,md:1},children:[(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"Request labs"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Lab results are essential for creating your personalized care plan. These tests provide key insights into your health, allowing us to guide your journey safely and effectively."})]}),(0,n.jsxs)(o.Box,{display:{base:"none",md:"block"},children:[(0,n.jsx)(o.Text,{variant:"text-header-S",children:"Already have lab results?"}),(0,n.jsx)(o.Box,{mt:"spacer-3",mb:"spacer-5",children:(0,n.jsx)(o.Button,{variant:"link-primary",onClick:handleShowRequirements,children:"Submit your Lab results"})}),(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",children:"*Be aware that complete lab results must be submitted to FlyteHealth before you can meet with a provider."})]})]}),(0,n.jsx)(D.S.Form,{children:l.selectedLab?(0,n.jsx)(SelectLabForm,{lab:l.selectedLab,onChooseAnotherLab:()=>{c({type:"RESET_LAB"})},onLabRequested:e=>{r(e)},patientId:a,bariatricSurgery:"yes"===s.bariatricSurgery,diabetes:"yes"===s.diabetes}):(0,n.jsxs)(o.Box,{overflowY:{base:"initial",md:"hidden"},children:[(0,n.jsx)(SearchLabForm,{organizationName:t,onLabSelected:e=>{c({type:"SELECT_LAB",lab:e})}}),(0,n.jsxs)(o.Box,{display:{base:"block",md:"none"},px:"spacer-6",pt:"spacer-6",pb:"spacer-5",children:[(0,n.jsx)(o.Text,{variant:"text-header-S",children:"Already have lab results?"}),(0,n.jsx)(o.Box,{my:"spacer-3",children:(0,n.jsx)(o.Button,{p:0,variant:"text-body-meta-medium",color:"text-link-primary-default",onClick:handleShowRequirements,children:"Submit your Lab results"})}),(0,n.jsx)(o.Text,{variant:"text-header-S",mt:"spacer-5",children:"Are labs required?"}),(0,n.jsx)(o.Text,{color:"text-secondary",mt:"spacer-2",children:"Yes. Lab results must be submitted to FlyteHealth before you can meet with a provider to ensure quality of care."})]})]})})]})]})}var T=a(9051);function FilePlaceholderView(e){let{name:t,onDelete:a}=e;return(0,n.jsxs)(o.Flex,{justify:"space-between",align:"center",borderBottomWidth:"1px",borderBottomColor:"border-subtle",borderBottomStyle:"solid",width:"100%",children:[(0,n.jsx)(o.Text,{variant:"text-body-regular",color:"text-primary",fontWeight:"normal",children:t}),(0,n.jsx)(o.ButtonIcon,{variant:"ghost",onClick:a,icon:(0,n.jsx)(o.IconTrash,{}),size:"l","aria-label":"delete",borderRadius:"radii-2",p:"spacer-1",m:"spacer-1"})]})}function FileUploadForm(){let{onSubmit:e,isSubmitting:t=!1}=arguments.length>0&&void 0!==arguments[0]?arguments[0]:{},[a,r]=(0,m.useState)([]),i=(0,m.useRef)(null),s=(0,o.useToast)(),generateId=()=>Math.random().toString(36).substring(2,9),handleDeleteFile=e=>{r(t=>t.filter(t=>t.id!==e))};return(0,n.jsxs)(o.Box,{children:[(0,n.jsxs)(o.Box,{py:"spacer-4",px:"spacer-3",bg:"background-dark",borderRadius:"radii-4",mb:"spacer-4",children:[(0,n.jsx)(o.Text,{variant:"text-header-M",color:"text-light",pb:"spacer-4",children:"Upload Your Lab Results"}),(0,n.jsx)(o.Button,{borderRadius:"radii-3",as:"label",htmlFor:"input-files",variant:"secondary",w:"full",bg:"white",color:"text-link-secondary-default",_hover:{bg:"background-action-hover"},leadingIcon:(0,n.jsx)(o.IconFileUpload,{}),children:"Add File"})]}),(0,n.jsx)("input",{id:"input-files",type:"file",ref:i,onChange:e=>{let t=e.target.files;if(!t||0===t.length)return;let a=Array.from(t).map(e=>({id:generateId(),name:e.name,file:e}));r(e=>[...e,...a]),i.current&&(i.current.value="")},style:{display:"none"},multiple:!0,accept:".pdf,.jpg,.jpeg,.png"}),a.length>0&&(0,n.jsx)(o.Box,{mb:"spacer-6",mt:"spacer-4",children:a.map(e=>(0,n.jsx)(FilePlaceholderView,{name:e.name,onDelete:()=>handleDeleteFile(e.id)},e.id))}),a.length>0?(0,n.jsx)(o.Button,{onClick:()=>{if(0===a.length){s({title:"Error",description:"Please upload at least one file",status:"error"});return}let t=a.map(e=>e.file);e?e(t):s({title:"Success",description:"Submitting ".concat(a.length," file(s): ").concat(a.map(e=>e.name).join(", ")),status:"success"})},variant:"primary",w:"full",h:"50px",borderRadius:"3xl",isDisabled:0===a.length||t,isLoading:t,display:0===a.length?{base:"none",md:"flex"}:"flex",mt:a.length>0?"spacer-9":0,children:"Submit Lab Results"}):null]})}function RequiredLabsDialog(e){let{isOpen:t,onClose:a,diabetes:r,bariatric:i}=e;if(!t)return null;let s=getLabRequirements({diabetes:r,bariatric:i,labName:"generic"});return(0,n.jsx)(o.Box,{position:"fixed",top:0,left:0,right:0,bottom:0,bg:"background-overlay",zIndex:9999,display:"flex",alignItems:"center",justifyContent:"center",p:"spacer-4",children:(0,n.jsxs)(o.Box,{bg:"background-card",borderRadius:"lg",p:"spacer-8",maxW:"500px",w:"100%",children:[(0,n.jsxs)(o.Flex,{alignItems:"center",justifyContent:"space-between",mb:"spacer-6",children:[(0,n.jsx)(o.Text,{variant:"text-header-M",color:"text-primary",children:"Required labs"}),(0,n.jsx)(o.IconX,{color:"text-secondary",cursor:"pointer",onClick:a})]}),(0,n.jsx)(o.Box,{as:"ul",pl:"spacer-6",mb:"spacer-4",maxH:"400px",overflowY:"auto",children:s.map(e=>(0,n.jsx)(o.Text,{as:"li",color:"text-secondary",mb:"spacer-2",children:e},e))})]})})}function SubmitLabsLaterDialog(e){let{isOpen:t,onClose:a,onSubmitLater:r,onRequestLabs:i}=e;return t?(0,n.jsx)(o.Box,{position:"fixed",top:0,left:0,right:0,bottom:0,bg:"background-overlay",zIndex:9999,display:"flex",alignItems:{base:"flex-end",md:"center"},justifyContent:"center",p:{base:0,md:"spacer-4"},children:(0,n.jsxs)(o.Box,{bg:"background-card",borderTopRadius:{base:"lg",md:"lg"},borderBottomRadius:{base:"none",md:"lg"},p:"spacer-8",maxW:{base:"100%",md:"420px"},w:"100%",position:"relative",children:[(0,n.jsx)(o.ButtonIcon,{icon:(0,n.jsx)(o.IconX,{}),"aria-label":"Close",variant:"ghost",size:"l",onClick:a,position:"absolute",top:"spacer-4",right:"spacer-4"}),(0,n.jsx)(o.Text,{variant:"text-header-M",color:"text-primary",mb:"spacer-6",children:"Submit labs later?"}),(0,n.jsx)(o.Text,{variant:"text-body-large-regular",color:"text-secondary",mb:"spacer-6",children:'By selecting "Submit later" you acknowledge that you will not be able to schedule a visit with a provider until labs are completed. You can submit labs using the FlyteHealth patient app or you can request new labs below.'}),(0,n.jsxs)(o.Flex,{direction:"column",gap:"spacer-4",children:[(0,n.jsx)(o.Button,{variant:"primary",onClick:r,borderRadius:"3xl",size:"l",children:"Submit labs later"}),(0,n.jsx)(o.Button,{variant:"primary-alt",onClick:i,borderRadius:"3xl",size:"l",children:"Request Labs"})]})]})}):null}let SubmittingLabsScreen=()=>(0,n.jsxs)(o.Box,{position:"fixed",top:"0",left:"0",width:"100vw",height:"100vh",backgroundColor:"background-overlay",display:"flex",flexDirection:"column",alignItems:"center",justifyContent:"center",zIndex:"overlay",children:[(0,n.jsx)(o.Spinner,{size:"s",color:"text-light"}),(0,n.jsx)(o.Text,{variant:"text-body-bold",color:"text-light",mt:"spacer-3",children:"We're sending your lab results"}),(0,n.jsx)(o.Text,{variant:"text-body-regular",color:"text-light",mt:"spacer-2",maxW:"300px",textAlign:"center",children:"This may take a few seconds, do not close this window."})]});var A=a(19182);let k={submitLabs:async(e,t)=>{A.ZP.info("Submitting ".concat(e.length," lab PDF(s) to Evolve API for patient ").concat(t));let a=new FormData;a.append("patientId",t),e.forEach(e=>{a.append("file",e)});let r=await E.Z.post("api/submit-labs",a,{headers:{"Content-Type":"multipart/form-data"}});return r.data}};function SubmitLabsForm(e){let{patientId:t,onSubmitLabsLater:a,onLabSubmitted:r,onGoBackToRequestLabs:i,diabetes:s,bariatric:l}=e,c=(0,o.useToast)(),[d,S]=(0,m.useState)(!1),[u,C]=(0,m.useState)(!1),[p,h]=(0,m.useState)(!1),validateFiles=e=>{if(e.length>10)return c({title:"Error",description:"You can only upload up to ".concat(10," files"),status:"error"}),!1;for(let t of e){if(t.size>5242880)return c({title:"Error",description:"File ".concat(t.name," exceeds the maximum size of 5MB"),status:"error"}),!1;if("application/pdf"!==t.type)return c({title:"Error",description:"File ".concat(t.name," must be a PDF"),status:"error"}),!1}return!0},handleFileSubmit=async e=>{if(validateFiles(e))try{h(!0);let a=await k.submitLabs(e,t);r(),c({title:"Success",description:a.message,status:"success"})}catch(e){c({title:"Error",description:e instanceof Error?e.message:"Failed to submit lab results",status:"error"})}finally{h(!1)}},handleRequestLabOrder=()=>{C(!1),i()};return p?(0,n.jsx)(SubmittingLabsScreen,{}):(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(RequiredLabsDialog,{isOpen:d,onClose:()=>{S(!1)},diabetes:s,bariatric:l}),(0,n.jsx)(SubmitLabsLaterDialog,{isOpen:u,onClose:()=>C(!1),onSubmitLater:()=>{C(!1),a()},onRequestLabs:handleRequestLabOrder}),(0,n.jsxs)(D.S,{children:[(0,n.jsxs)(D.S.Side,{children:[(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"Submit Lab Results"}),(0,n.jsxs)(o.TextPairing.SubLabel,{color:"text-secondary",fontSize:"20px",children:["Upload results dated within the last 90 days and include all"," ",(0,n.jsx)(o.Button,{fontSize:20,variant:"link",fontWeight:"400",onClick:()=>{S(!0)},children:"required labs."}),(0,n.jsx)("br",{}),"Our team will review uploaded files and will be in touch if there are any issues or if new labs are needed."]})]}),(0,n.jsxs)(o.Box,{children:[(0,n.jsx)(o.Text,{variant:"text-header-S",color:"text-primary",children:"Don't have lab results yet?"}),(0,n.jsx)(o.Box,{my:"spacer-3",children:(0,n.jsx)(o.Button,{size:"s",variant:"link",onClick:handleRequestLabOrder,children:"Request a lab order"})}),(0,n.jsx)(o.Text,{mt:"spacer-6",variant:"text-header-S",color:"text-primary",children:"Not ready?"}),(0,n.jsx)(o.Box,{my:"spacer-3",children:(0,n.jsx)(o.Button,{size:"s",variant:"link",onClick:()=>{C(!0)},children:"Submit lab results later"})})]})]}),(0,n.jsx)(D.S.Form,{children:(0,n.jsx)(FileUploadForm,{onSubmit:handleFileSubmit,isSubmitting:p})})]})]})}var P=a(64504),L=a(56401),M=a(17304),F=a(94445),O=a(11841),B=a(91372),U=a(60948),J=a(1943),N=a(21097),W=a(54285),V=a(34474),_=a(64267),q=a(10265),z=a(63317),Y=a(10503),X=a(19171),G=a(67618),K=a(10002),Q=a(13064),$=a(94788),Z=a(30368),ee=a(47243);let isEligibleForAutoEnrollment=e=>{let{groupNumber:t,status:a}=e;return["10556700","10556701","10556702","10556703","10556704","10556705","10556706","10556707","10556708","10556709","10556710","10556711","10556712","10556713","10556714","10556715","10556716","10556717","10556718","10556719","10556720","10556721","10556722","10556723","10556724","10556725","10556726","10556727","10556728"].includes(t)&&"Active"===a},getLeadStatus=e=>{let{groupNumber:t,status:a}=e;if(!isEligibleForAutoEnrollment({groupNumber:t,status:a}))return L.rl.EligibleWaiting};(r=i||(i={})).CreateLead="createLead",r.CreateContact="createContact",r.UpdateContact="updateContact",r.CheckBenefits="checkBenefits",r.DetermineBenefitsOrLead="determineBenefitsOrLead",r.DetermineContactOrLead="determineContactOrLead",r.FetchConsents="fetchConsents",r.UpdateEmail="updateEmail";let et={...K.a,...i},ea=G.aU[q.kT.ChristianaCare],er={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insurance:void 0,lastName:"",phone:"",state:void 0,termsAgreement:!1,howDidYouFindUS:"",comorbidities:[],diabetes:"",bariatricSurgery:""},bmi:void 0,benefitsCheck:void 0,otpData:void 0,consentsData:{items:[],userConsentStatus:[]},contactData:{},passwordData:{password:void 0,confirmPassword:void 0},flyteUserData:void 0,error:void 0,labs:void 0},ei={...z.OX,...z.cp,...z.sW,...z.Oz,...z.S8,...z.oQ,...z.q6,...z.nB,...z.v1,...z.Kj,...(0,z.Ww)(er)},en=(0,$.cY)({types:{},guards:{isPreEligibilityMet:e=>{let{context:{formData:t,bmi:a}}=e;return Q.Pq.christianaCare({bmi:a,comorbidity:t.comorbidity,birthdate:t.birthdate})},isApplicationReviewRequired:e=>{var t,a;let{context:{benefitsCheck:r}}=e;return!isEligibleForAutoEnrollment({groupNumber:null==r?void 0:null===(t=r.coverage)||void 0===t?void 0:t.groupNumber,status:null==r?void 0:null===(a=r.coverage)||void 0===a?void 0:a.status})},isApplicationDetected:X.Q,isAthenaRecordCreated:Y.w},actions:ei}).createMachine({context:()=>er,id:"christianaCareMachine",initial:et.PreEligibility,states:{[et.PreEligibility]:{id:et.PreEligibility,initial:et.Idle,states:{[et.Idle]:{on:{SUBMIT:{target:et.Submitting,actions:"updateFormData"}}},[et.Submitting]:{entry:"assignBMI",always:[{target:"#".concat(et.ContactDetails),guard:"isPreEligibilityMet"},{target:"#".concat(et.EligibilityUnmet)}]}}},[et.ContactDetails]:{id:et.ContactDetails,initial:et.Idle,states:{[et.Idle]:{on:{SUBMIT:{target:"#".concat(et.InsuranceDetails),actions:"updateFormData"}}}}},[et.InsuranceDetails]:{id:et.InsuranceDetails,initial:et.Idle,states:{[et.Idle]:{on:{BACK:{target:"#".concat(et.ContactDetails)},SUBMIT:{target:"#".concat(et.InsuranceDetailsReview),actions:"updateFormData"}}}}},[et.InsuranceDetailsReview]:{id:et.InsuranceDetailsReview,initial:et.Idle,states:{[et.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:et.Submitting}}},[et.Submitting]:{id:et.Submitting,initial:et.CheckBenefits,states:{[et.CheckBenefits]:{id:et.CheckBenefits,invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={...t,payerCode:G.qK[q.PF.Highmark]};return await (0,J.o)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:[{actions:(0,ee.a)({benefitsCheck:e=>{let{event:t}=e;return t.output.data}}),target:"#".concat(et.DetermineContactOrLead)}],onError:"#".concat(et.DetermineContactOrLead)}},[et.DetermineContactOrLead]:{id:et.DetermineContactOrLead,always:[{guard:"isApplicationReviewRequired",target:et.CreateLead},{target:et.CreateContact}]},[et.CreateContact]:{id:et.CreateContact,invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={...t.formData,...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},company:ea,insurance:G.KG[q.kT.ChristianaCare],evolveOrganization:q.bV["ChristianaCare - Caregivers"],accountId:G.kS[q.kT.ChristianaCare],eligibilityVerifiedBy:q.Vn.Pverify};return await (0,W.rE)(a)}),input:e=>{let{context:t}=e;return t},onDone:{actions:"assignContactData",target:"#".concat(et.EmailVerification)},onError:[{guard:"isApplicationDetected",target:"#".concat(et.ApplicationDetected)},{target:"#".concat(et.InsuranceDetailsReview,".").concat(et.Error)}]}},[et.CreateLead]:{id:et.CreateLead,invoke:{src:(0,Z.p4)(async e=>{var t,a,r,i,n,o,s,l,c,d,S,u;let{input:C}=e,m={...C.formData,...C.formData.insuranceMemberID&&{employmentVerificationCode:C.formData.insuranceMemberID},...C.benefitsCheck&&{benefitsCheck:C.benefitsCheck},...isEligibleForAutoEnrollment({groupNumber:null===(a=C.benefitsCheck)||void 0===a?void 0:null===(t=a.coverage)||void 0===t?void 0:t.groupNumber,status:null===(i=C.benefitsCheck)||void 0===i?void 0:null===(r=i.coverage)||void 0===r?void 0:r.status})&&{eligibilityVerifiedBy:q.Vn.Pverify},insurance:G.KG[q.kT.ChristianaCare],evolveOrganization:q.bV["ChristianaCare - Caregivers"],company:ea,leadStatus:getLeadStatus({groupNumber:null===(o=C.benefitsCheck)||void 0===o?void 0:null===(n=o.coverage)||void 0===n?void 0:n.groupNumber,status:null===(l=C.benefitsCheck)||void 0===l?void 0:null===(s=l.coverage)||void 0===s?void 0:s.status}),automateEvolveEnrollment:isEligibleForAutoEnrollment({groupNumber:null===(d=C.benefitsCheck)||void 0===d?void 0:null===(c=d.coverage)||void 0===c?void 0:c.groupNumber,status:null===(u=C.benefitsCheck)||void 0===u?void 0:null===(S=u.coverage)||void 0===S?void 0:S.status})};return await (0,_.$)(m)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isApplicationReviewRequired",target:"#".concat(et.ApplicationReview)},{target:"#".concat(et.ApplicationComplete)}],onError:[{guard:"isApplicationDetected",target:"#".concat(et.ApplicationDetected)},{target:"#".concat(et.InsuranceDetailsReview,".").concat(et.Error)}]}}}},[et.Error]:{id:"".concat(et.InsuranceDetailsReview,".").concat(et.Error),on:{SUBMIT:{actions:["updateFormData","resetBenefitsCheck"],target:et.Submitting}}}}},[et.EmailVerification]:{id:et.EmailVerification,initial:et.Idle,states:{[et.Idle]:{id:"".concat(et.EmailVerification,".").concat(et.Idle),on:{SUBMIT:{actions:"assignOtpCode",target:et.Submitting},RESEND_EMAIL_VERIFICATION:{target:et.Idle,reenter:!0},UPDATE_EMAIL:{target:et.UpdateEmail}},invoke:{input:e=>{var t;let{context:a,event:r}=e;return{email:a.formData.email,firstName:a.formData.firstName,onSuccess:null==r?void 0:null===(t=r.data)||void 0===t?void 0:t.onSuccess}},src:(0,Z.p4)(async e=>{let{input:t}=e,a={email:t.email,firstName:t.firstName},r=await (0,B.t)(a);return{token:r.data.token,onSuccess:t.onSuccess}}),onDone:{actions:[(0,ee.a)({otpData:e=>{let{context:t,event:a}=e;return{...t.otpData,token:a.output.token}}}),e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}]},onError:et.Error}},[et.Submitting]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,token:t.otpData.token,otp:t.otpData.otp};return await (0,U.M)(a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(et.OnboardingChecklist),onError:et.Error}},[et.Error]:{on:{SUBMIT:{actions:"assignOtpCode",target:et.Submitting},RESEND_EMAIL_VERIFICATION:{target:et.Idle},UPDATE_EMAIL:{target:et.UpdateEmail}}},[et.UpdateEmail]:{initial:et.Idle,states:{[et.Idle]:{invoke:{input:e=>{let{context:t,event:a}=e;return{contactId:t.contactData.contactId,email:a.data.email,onSuccess:a.data.onSuccess}},src:(0,Z.p4)(async e=>{let{input:t}=e,a={contactId:t.contactId,email:t.email};await (0,W.Tk)(a);let r={email:t.email,onSuccess:t.onSuccess};return r}),onDone:{actions:["assignNewEmail",e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}],target:"#".concat(et.EmailVerification,".").concat(et.Idle)},onError:et.Error}},[et.Error]:{on:{SUBMIT:{target:"#".concat(et.EmailVerification,".").concat(et.Idle)},RESEND_EMAIL_VERIFICATION:{target:"#".concat(et.EmailVerification,".").concat(et.Idle)},UPDATE_EMAIL:{target:et.Idle}}}}}}},[et.ReviewConsents]:{id:et.ReviewConsents,initial:et.FetchConsents,states:{[et.Idle]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:et.Submitting}}},[et.FetchConsents]:{invoke:{src:(0,Z.p4)(async()=>await (0,N.J)()),onDone:{actions:"assignConsents",target:et.Idle},onError:et.Error}},[et.Submitting]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={patientIdentifier:t.contactData.contactId,firstName:t.formData.firstName,lastName:t.formData.lastName,phone:t.formData.phone,email:t.formData.email,birthDate:t.formData.birthdate,state:t.formData.state,heightInInch:t.formData.heightInInch,heightInFeet:t.formData.heightInFoot,currentWeightInPounds:t.formData.currentWeightInPounds,evolveOrganization:q.bV["ChristianaCare - Caregivers"],consents:t.consentsData.userConsentStatus};return await (0,V.D)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{actions:"assignFlyteUserData",target:et.UpdateContact}],onError:"#".concat(et.OnboardingUserError)}},[et.UpdateContact]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={contactId:t.contactData.contactId,evolvePatientID:t.flyteUserData.patientId};return await (0,W.Tk)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isAthenaRecordCreated",target:"#".concat(et.CreatePassword)},{target:"#".concat(et.OnboardingUserError)}],onError:"#".concat(et.OnboardingUserError)}},[et.Error]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:et.Submitting}}}}},[et.CreatePassword]:{id:et.CreatePassword,initial:et.Idle,states:{[et.Idle]:{on:{SUBMIT:{actions:"assignPasswordData",target:et.Submitting}}},[et.Submitting]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,password:t.passwordData.password,confirmPassword:t.passwordData.confirmPassword};return await (0,O.x)(t.flyteUserData.verifyToken,a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(et.RequestLabs),onError:{target:et.Error,actions:"assignError"}}},[et.Error]:{on:{SUBMIT:{actions:["resetError","assignPasswordData"],target:et.Submitting}}}}},[et.OnboardingChecklist]:{id:et.OnboardingChecklist,on:{SUBMIT:{target:"#".concat(et.ReviewConsents)}}},[et.RequestLabs]:{id:et.RequestLabs,on:{PROCEED_TO_SUBMIT_LABS:"#".concat(et.SubmitLabs),LAB_REQUESTED:{target:"#".concat(et.AppDownload),actions:"assignLabLocation"},SUBMIT_LABS_LATER:{actions:"assignLabsSkipped",target:"#".concat(et.AppDownload)}}},[et.SubmitLabs]:{id:et.SubmitLabs,on:{GO_BACK_TO_REQUEST_LABS:"#".concat(et.RequestLabs),LAB_SUBMITTED:{actions:"registerLabsUploaded",target:"#".concat(et.AppDownload)},SUBMIT_LABS_LATER:{actions:"assignLabsSkipped",target:"#".concat(et.AppDownload)}}},[et.AppDownload]:{id:et.AppDownload},[et.ApplicationReview]:{id:et.ApplicationReview},[et.OnboardingUserError]:{id:et.OnboardingUserError},[et.ApplicationComplete]:{id:et.ApplicationComplete},[et.ApplicationDetected]:{id:et.ApplicationDetected},[et.EligibilityUnmet]:{id:et.EligibilityUnmet,initial:et.Idle,states:{[et.Idle]:{on:{SUBMIT:{target:et.Submitting,actions:"updateFormData"}}},[et.Submitting]:{invoke:{src:(0,Z.p4)(async e=>{let{input:t}=e,a={...t,company:ea,leadStatus:q.rl.Ineligible,ineligibilityReason:q.ib.BMI,automateEvolveEnrollment:!1};return await (0,_.$)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:et.Success,onError:et.Error}},[et.Success]:{},[et.Error]:{on:{SUBMIT:{actions:"updateFormData",target:et.Submitting}}}}}},on:{RESET:{target:"#".concat(et.PreEligibility),actions:"reset"}}});var eo=a(56344);let es={[C.J.PreEligibility]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"Let's make sure you're eligible for the FlyteHealth program."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"To be eligible for the FlyteHealth program through ChristianaCare, you must meet specific age and Body Mass Index (BMI)* requirements."})]}),bmiEnrollmentDisclaimer:(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. FlyteHealth providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the FlyteHealth program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[C.J.EligibilityUnmet]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Unfortunately, you are not eligible to join FlyteHealth at this time."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"The FlyteHealth program requires a minimum BMI of 27+ (plus one or more weight-related health conditions) or a BMI of 30+."})]})},[C.J.ContactDetails]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Congratulations! You're eligible for the FlyteHealth program"}),(0,n.jsxs)(o.TextPairing.SubLabel,{color:"text-secondary",children:["To help match your information with the ChristianaCare Caregivers with Highmark insurance plan, tell us about yourself.",(0,n.jsx)("br",{}),(0,n.jsx)("br",{}),"Next, we'll ask about your Highmark membership. Be sure to have your insurance card handy."]})]})},[C.J.InsuranceDetails]:{title:(0,n.jsx)(o.TextPairing,{variant:"textpairing-header-2XL",children:(0,n.jsxs)(o.TextPairing.Label,{color:"text-primary",children:[(0,n.jsxs)(o.Text,{display:{base:"inline",lg:"block"},as:"label",variant:"text-header-2XL",color:"text-secondary-negative",children:["One more thing:"," "]}),"What's your Highmark membership number?"]})})},[C.J.InsuranceDetailsReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{children:"Let's review: Is your info correct?"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Please double-check the information you provided to make sure everything is correct."})]})},[C.J.ApplicationComplete]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Welcome aboard! We're so excited you're here."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Next, we need to confirm your email. Click the link we sent to:"})]}),description:(0,n.jsx)(o.Text,{mt:"spacer-8",color:"text-secondary",variant:"text-body-regular",children:"Can’t find the email? Make sure to check your Spam folder."})},[C.J.ApplicationReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]})},[C.J.ApplicationDetected]:{title:(0,n.jsx)(o.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,n.jsx)(o.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[C.J.EmailVerification]:eo.T[C.J.EmailVerification],[C.J.OnboardingChecklist]:eo.T[C.J.OnboardingChecklist],[C.J.CreatePassword]:eo.T[C.J.CreatePassword],[C.J.AppDownload]:eo.T[C.J.AppDownload],[C.J.ReviewConsents]:eo.T[C.J.ReviewConsents]};var el=a(58976);let ec=[L.Op.BenefitsWebsite,L.Op.CoworkerReferral,L.Op.PrescriptionDenial,L.Op.ProviderReferral,L.Op.WordOfMouth,L.Op.Other],ed={maxLength:15,minLength:15,registerOptions:{minLength:{value:15,message:"Enter the 15-character member ID number."},maxLength:{value:15,message:"Enter the 15-character member ID number."},pattern:{value:/^(C9I|C9O)/i,message:"Member ID must begin with C9i or C9o."}},label:"Highmark Membership ID Number",placeholder:"C9XXXXXXXXXXXXX"},eS={[C.J.ContactDetails]:{state:{options:el.Fp},howDidYouFindUs:{options:ec}},[C.J.InsuranceDetails]:{insuranceMemberID:{...ed,description:(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Enter the 15-digit Member ID as displayed on your Highmark Membership ID Card."}),tooltip:(0,n.jsxs)(o.Box,{children:[(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-light",children:"Where to find my Membership ID Number:"}),(0,n.jsx)(o.Image,{width:"100%",height:"auto",src:"/static/assets/programs/christiana-care/christiana-care-insurance-card.png",alt:"Member ID guidance"})]})}},[C.J.InsuranceDetailsReview]:{insuranceMemberID:ed}},eu=L.kT.ChristianaCare,ChristianaCareWorkflow=e=>{let{render:t}=e,[a,r]=(0,F.eO)(en),i=(0,m.useMemo)(()=>(0,M.k)(a.value),[a.value]);(0,P.R)(i,eu);let u=(0,m.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),p=(0,m.useCallback)(()=>{r({type:"BACK"})},[r]),h=(0,m.useCallback)(()=>{switch(i){case et.PreEligibility:return(0,n.jsx)(R.b,{configuration:{contentResources:es[C.J.PreEligibility]},onSubmit:u});case et.ContactDetails:return(0,n.jsx)(g.q,{configuration:{contentResources:es[C.J.ContactDetails],fields:eS[C.J.ContactDetails]},onSubmit:u,defaultValues:a.context.formData});case et.EligibilityUnmet:return(0,n.jsx)(b.X,{configuration:{contentResources:es[C.J.EligibilityUnmet]},onSubmit:u,loading:a.matches({[et.EligibilityUnmet]:et.Submitting}),isEmailSent:a.matches({[et.EligibilityUnmet]:et.Success}),hasError:a.matches({[et.EligibilityUnmet]:et.Error})});case et.InsuranceDetails:return(0,n.jsx)(H.v,{configuration:{contentResources:es[C.J.InsuranceDetails],fields:eS[C.J.InsuranceDetails]},onSubmit:u,onBack:p});case et.InsuranceDetailsReview:return(0,n.jsx)(f.b,{configuration:{contentResources:es[C.J.InsuranceDetailsReview],fields:eS[C.J.InsuranceDetailsReview]},onSubmit:u,loading:a.matches({[et.InsuranceDetailsReview]:et.Submitting}),hasError:a.matches({[et.InsuranceDetailsReview]:et.Error}),defaultValues:a.context.formData});case et.ApplicationComplete:return(0,n.jsx)(l.J,{...es[C.J.ApplicationComplete],email:a.context.formData.email});case et.ApplicationDetected:return(0,n.jsx)(c.v,{...es[C.J.ApplicationDetected],email:a.context.formData.email});case et.ApplicationReview:return(0,n.jsx)(d.G,{...es[C.J.ApplicationReview]});case et.EmailVerification:return(0,n.jsx)(y.Z,{configuration:{contentResources:{title:es[C.J.EmailVerification](a.context.formData.email).title}},email:a.context.formData.email,hasError:a.matches({[et.EmailVerification]:et.Error}),loading:a.matches({[et.EmailVerification]:et.Submitting}),isUpdateEmailLoading:a.matches({[et.EmailVerification]:{[et.UpdateEmail]:et.Idle}}),hasUpdateEmailError:a.matches({[et.EmailVerification]:{[et.UpdateEmail]:et.Error}}),onSubmit:u,onResendCode:e=>r({type:"RESEND_EMAIL_VERIFICATION",data:{onSuccess:e}}),onEditEmail:(e,t)=>r({type:"UPDATE_EMAIL",data:{email:e,onSuccess:t}})});case et.OnboardingChecklist:return(0,n.jsx)(v.O,{showLabs:!0,configuration:{contentResources:es[C.J.OnboardingChecklist]},onSubmit:u});case et.ReviewConsents:return(0,n.jsx)(T.R,{configuration:{contentResources:es[C.J.ReviewConsents]},consents:a.context.consentsData.items,hasError:a.matches({[et.ReviewConsents]:et.Error}),loading:a.matches({[et.ReviewConsents]:et.FetchConsents})||a.matches({[et.ReviewConsents]:et.Submitting})||a.matches({[et.ReviewConsents]:et.UpdateContact}),onSubmit:u});case et.CreatePassword:return(0,n.jsx)(x.f,{configuration:{contentResources:es[C.J.CreatePassword]},loading:a.matches({[et.CreatePassword]:et.Submitting}),error:a.context.error,onSubmit:u});case et.AppDownload:return(0,n.jsx)(s.B,{title:"SUBMIT_LATER"===a.context.labs?es[C.J.AppDownload].titleLabSkipped:"LABS_UPLOADED"===a.context.labs?es[C.J.AppDownload].titleLabSubmitted:es[C.J.AppDownload].titleLabRequested,checklist:es[C.J.AppDownload].checklist,image:(0,n.jsx)(o.Image,{m:"auto",mt:8,maxWidth:"300px",src:"/static/assets/app-download.png",alt:"app-download"})});case et.OnboardingUserError:return(0,n.jsx)(I._,{});case et.RequestLabs:var e;return(0,n.jsx)(RequestLabsForm,{organizationName:"ChristianaCare - Caregivers",patientId:null===(e=a.context.flyteUserData)||void 0===e?void 0:e.patientId,onProceedToSubmitLabs:()=>r({type:"PROCEED_TO_SUBMIT_LABS"}),onLabRequested:e=>r({type:"LAB_REQUESTED",data:{lab:e}}),formData:a.context.formData});case et.SubmitLabs:return(0,n.jsx)(SubmitLabsForm,{onGoBackToRequestLabs:()=>r({type:"GO_BACK_TO_REQUEST_LABS"}),onSubmitLabsLater:()=>r({type:"SUBMIT_LABS_LATER"}),onLabSubmitted:()=>r({type:"LAB_SUBMITTED"}),patientId:a.context.flyteUserData.patientId,diabetes:"yes"===a.context.formData.diabetes,bariatric:"yes"===a.context.formData.bariatricSurgery});default:return null}},[i,a]);return t({header:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(o.Flex,{gap:"spacer-5",alignItems:"center",children:[(0,n.jsx)(S.E,{partner:L.kT.Flyte}),(0,n.jsx)(o.Divider,{orientation:"vertical",alignSelf:"stretch",height:"auto"}),(0,n.jsx)(S.E,{partner:eu})]}),(0,n.jsx)(WorkflowHeaderLabs,{currentStep:i})]}),body:h(),currentWorkFlowStep:i})}},56344:function(e,t,a){a.d(t,{T:function(){return o}});var r=a(85893),i=a(71986),n=a(70908);let o={[n.J.OnboardingChecklist]:{title:(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-2XL",children:[(0,r.jsxs)(i.TextPairing.Label,{color:"text-primary",children:["Welcome to"," ",(0,r.jsx)(i.Text,{as:"span",variant:"text-header-2XL",color:"text-secondary-negative",children:"FlyteHealth!"})]}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"Before we can connect you to your care team, you'll need to:"})]}),checklist:(0,r.jsxs)(i.Flex,{gap:"spacer-9",pb:{base:"spacer-24",lg:0},flexDirection:"column",children:[(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle1,{color:"text-secondary",size:"l"}),(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-M",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Complete Care Agreements"}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"These allow us to provide care for you"})]})]}),(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle2,{color:"text-secondary",size:"l"}),(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-M",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Create a Password"}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"So you can log into FlyteHealth and get support along the way."})]})]}),(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle3,{color:"text-secondary",size:"l"}),(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-M",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Download the App"}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"The patient app helps you prepare for your first visit with a FlyteHealth provider. Log into FlyteHealth and get support along the way."})]})]})]}),checklistWithLabs:(0,r.jsxs)(i.Flex,{gap:"spacer-9",pb:{base:"spacer-24",lg:0},flexDirection:"column",children:[(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle1,{color:"text-secondary",size:"l"}),(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-M",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Complete Care Agreements"}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"These allow us to provide care for you"})]})]}),(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle2,{color:"text-secondary",size:"l"}),(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-M",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Create a Password"}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"So you can log into FlyteHealth and get support along the way."})]})]}),(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle3,{color:"text-secondary",size:"l"}),(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-M",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Request Labs "}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"Request your lab results for FlyteHealth to accurately assess your treatment plan."})]})]}),(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle4,{color:"text-secondary",size:"l"}),(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-M",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Download the App"}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"The patient app helps you prepare for your first visit with a FlyteHealth provider. Log into FlyteHealth and get support along the way."})]})]})]})},[n.J.CreatePassword]:{title:(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-2XL",children:[(0,r.jsxs)(i.TextPairing.Label,{color:"text-primary",children:["Create a"," ",(0,r.jsxs)(i.Text,{as:"span",variant:"text-header-2XL",color:"text-secondary-negative",children:["password"," "]}),"for your account"]}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"Once created, you will use your email and this password to log into the FlyteHealth mobile app."})]})},[n.J.AppDownload]:{title:(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-2XL",children:[(0,r.jsxs)(i.TextPairing.Label,{color:"text-primary",children:["Download the"," ",(0,r.jsxs)(i.Text,{as:"span",color:"text-secondary-negative",variant:"text-header-2XL",children:["FlyteHealth"," "]}),"patient app"]}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"Now that your account is ready, use it to log into the patient app and complete the checklist so you can schedule your first visit."})]}),titleLabRequested:(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-2XL",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"You’re all set! Your Lab has been Requested"}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"Please check your email for detailed instructions on next steps."})]}),titleLabSubmitted:(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-2XL",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Your lab results have been successfully submitted"}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"Our team will review them shortly and you'll receive an update by email."})]}),titleLabSkipped:(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-2XL",children:[(0,r.jsxs)(i.TextPairing.Label,{color:"text-primary",children:[(0,r.jsx)(i.Text,{as:"span",color:"text-secondary-negative",variant:"text-header-2XL",children:"You’re all set!"})," ","Now Download the FlyteHealth app"]}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"Your FlyteHealth account has been created. You'll use this to log into the FlyteHealth app to take the next steps towards scheduling your first appointment."})]}),checklist:(0,r.jsxs)(i.Flex,{gap:"spacer-6",pb:{base:"spacer-24",lg:0},flexDirection:"column",children:[(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle1,{color:"text-secondary",size:"l"}),(0,r.jsx)(i.Text,{variant:"text-body-regular",color:"text-secondary",children:"Open the camera app on your phone"})]}),(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle2,{color:"text-secondary",size:"l"}),(0,r.jsx)(i.Text,{variant:"text-body-regular",color:"text-secondary",children:"Scan the QR Code below"})]}),(0,r.jsxs)(i.Flex,{direction:"row",gap:"spacer-2",children:[(0,r.jsx)(i.IconCircle3,{color:"text-secondary",size:"l"}),(0,r.jsx)(i.Text,{variant:"text-body-regular",color:"text-secondary",children:"Follow the steps on your phone to download the app"})]})]})},[n.J.ReviewConsents]:{title:(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-2XL",children:[(0,r.jsx)(i.TextPairing.Label,{color:"text-primary",children:"Agree to Receive Care "}),(0,r.jsx)(i.TextPairing.SubLabel,{color:"text-secondary",children:"To begin your health journey, review the following documents."})]})},[n.J.EmailVerification]:e=>({title:(0,r.jsxs)(i.TextPairing,{variant:"textpairing-header-2XL",children:[(0,r.jsxs)(i.TextPairing.Label,{children:["Enter the"," ",(0,r.jsx)(i.Text,{color:"text-secondary-negative",as:"span",variant:"text-header-2XL",children:"6 digit code"})," ","we've sent you"]}),(0,r.jsxs)(i.TextPairing.SubLabel,{color:"text-secondary",children:["To confirm your email, enter the code we sent to"," ",(0,r.jsx)("b",{children:e})]})]})})}},93942:function(e,t,a){a.d(t,{U:function(){return FlyteSignUpLauncher}});var r,i,n,o,s=a(85893),l=a(66122),c=a(3183),d=a(71986),S=a(29733),u=a(11964),C=a(70908),m=a(67294),p=a(31540),h=a(56401),g=a(17257),x=a(17304),b=a(94445),y=a(24045),H=a(38660),f=a(33407),v=a(44761),I=a(33640),R=a(65660),D=a(20410),E=a(53157),j=a(27350),w=a(86640),T=a(96693),A=a(50793),k=a(83344),P=a(76311),L=a(27950),M=a(73071),F=a(9051),O=a(64504),B=a(58976),U=a(73857),J=a(49070),N=a(45854),W=a(58848),V=a(84862),_=a(87536);(r=n||(n={})).NotReferred="Not referred",r.AccessHealthcare="Access Healthcare, PC",r.AnandKanjolia="Anand Kanjolia, MD, LLC",r.AnneMarieVilla="Anne Marie Villa, MD, PC",r.ArthurSkalski="Arthur H Skalski, MD Internal Medicine FACSG LLC",r.AvantaClinic="Avanta Clinic, LLC",r.ComprehensiveMedicalGroup="Comprehensive Medical Group, LLC",r.ConnecticutValleyPediatricCenter="Connecticut Valley Pediatric Center, Inc",r.DushyantParikh="Dushyant Parikh, MD",r.EastGranbyFamilyPractice="East Granby Family Practice, LLC",r.EileenComia="Eileen C Comia, MD, LLC",r.EllenMarmer="Ellen L Marmer, MD",r.FeelWellHealthCenter="Feel Well Health Center of Southington, PC dba Confidia Health Institute",r.HRobertSilverstein="H Robert Silverstein MD, FACC, PC",r.IvelisseViruet="Ivelisse Viruet, MD Internal Medicine, LLC",r.JamesHainesAndWilliamBelcastro="James Haines, MD & William Belcastro, MD",r.JudithMascolo="Judith M Mascolo, MD, LLC",r.JulieSacharko="Julie Sacharko, APRN LLC",r.KaiserPermanente="Kaiser Permanente",r.MahmoodYekta="Mahmood Yekta, MD, PC dba Shafa Medical Clinic",r.MeadowsHealthCenter="Meadows Health Center, PC",r.MobileCarePartners="Mobile Care Partners of Connecticut, PLLC",r.MouliAssociates="Mouli Associates LLC",r.OksanaKloyzner="Oksana Kloyzner, MD, LLC",r.OliverDiaz="Oliver B Diaz, MD",r.PeiSun="Pei Sun MD, LLC",r.PersonalPrimaryCare="Personal Primary Care and Weight Management LLC",r.PreferredHealthcareAssociates="Preferred Healthcare Associates, Inc",r.PrimaryPhysicalMedicine="Primary Physical Medicine, LLC",r.QuinonesMedicalGroup="Quinones Medical Group, LLC",r.RamirezMedicalPractice="Ramirez Medical Practice, PLLC",r.ReviveCenterForHealth="REVIVE Center for Health & Wellness, PLLC",r.RobertCarlson="Robert D Carlson, MD, LLC",r.RockyHillMedicalCenter="Rocky Hill Medical Center, LLC",r.RoyKellerman="Roy A Kellerman, MD, LLC",r.SoNEHealthMedicalGroup="SoNE Health Medical Group, PLLC",r.SuffieldMedicalAssociates="Suffield Medical Associates",r.WarrenPediatrics="Warren Pediatrics, LLC",r.WinstedInternalMedicine="Winsted Internal Medicine Associates",r.YounusMasih="Younus Masih, MD",r.Other="Other";let q="referralProgram",z=Object.values(n),ReferralProgramSelector=e=>{let{options:t=z,isRequired:a,isDisabled:r,defaultSelectedItem:i,placeholder:n}=e,{watch:o,control:l}=(0,_.Gc)(),[c,S]=(0,m.useState)(""),u=c?t.filter(e=>e.toLowerCase().includes(c.toLowerCase())):t;return(0,s.jsxs)(d.Flex,{direction:"column",gap:"spacer-2",children:[(0,s.jsxs)(d.Box,{children:[(0,s.jsx)(d.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:q,children:"Were you referred to FlyteHealth?"}),(0,s.jsx)(d.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"If yes, select the healthcare organization, clinic, or provider."})]}),(0,s.jsx)(_.Qr,{control:l,name:q,rules:{required:a},render:e=>{let{field:{onChange:t,onBlur:a}}=e;return(0,s.jsxs)(d.Autocomplete,{id:"".concat(q,"-autocomplete"),items:u,onInputValueChange:e=>{let{inputValue:a}=e;S(a||""),a||t(a)},onSelectedItemChange:e=>{let{selectedItem:a}=e;return t(a)},initialSelectedItem:i,selectedItem:o(q)||"",children:[(0,s.jsx)(d.Autocomplete.Input,{"data-test":q,id:q,size:"l",placeholder:n,clearButtonMode:r?"never":"has-value",leadingIcon:(0,s.jsx)(d.IconSearch,{}),variant:"flushed",isDisabled:r,onBlur:a}),(0,s.jsx)(d.Autocomplete.List,{"data-test":"".concat(q,"List"),zIndex:2,renderItem:e=>(0,s.jsx)(d.Text,{variant:"text-body-regular",children:e}),overflowY:"auto",maxHeight:"13.5rem"})]})}})]})},Y=[h.i$.California,h.i$.Connecticut,h.i$.Massachusetts,h.i$["New York"],h.i$["Rhode Island"],h.i$["New Hampshire"],h.i$.Vermont],X=[h.i$.California,h.i$.Colorado,h.i$.Oregon,h.i$.Georgia,h.i$.Hawaii,h.i$.Maryland,h.i$.Virginia,h.i$.Washington,h.i$["Washington D.C."]],getReferralOptions=e=>X.includes(e)?[n.NotReferred,n.KaiserPermanente,n.Other]:Object.values(n).filter(e=>e!==n.KaiserPermanente),FlyteContactDetailsForm=e=>{let{configuration:t,loading:a=!1,onSubmit:r,defaultValues:i}=e,{contentResources:n,fields:o}=t,l=(0,_.cI)({mode:"onBlur",defaultValues:i,shouldUnregister:!1}),c=(0,m.useRef)(null==i?void 0:i.state),S=(0,m.useRef)(null==i?void 0:i.referralProgram),{watch:u}=l,C=(0,V.d)(),p=u(W.x),h=u(q),g=p&&(Y.includes(p)||X.includes(p)),x=!p||a||!g,b=p&&!g?"There are no organizations or clinics in your state":"Select referral location",y=!!h,H=!p||a||g&&!y,f="Not referred"===h||""===h?o.howDidYouFindUs.options.notReferrerOptions:o.howDidYouFindUs.options.referrerOptions;(0,m.useEffect)(()=>{h!==S.current&&(l.resetField(N.p,{defaultValue:""}),S.current=h)},[h,l]),(0,m.useEffect)(()=>{p!==c.current&&(l.resetField(q,{defaultValue:""}),l.resetField(N.p,{defaultValue:""}),c.current=p)},[p,l]);let renderFormAction=()=>(0,s.jsx)(d.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!l.formState.isValid,width:"100%",isLoading:a,trailingIcon:(0,s.jsx)(d.IconArrowRight,{}),"aria-label":"Continue",children:"Continue"});return(0,s.jsx)(_.RV,{...l,children:(0,s.jsxs)(U.S,{as:"form",onSubmit:l.handleSubmit(r),noValidate:!0,children:[(0,s.jsx)(U.S.Side,{gap:0,flex:{base:"none",lg:1},children:n.title}),(0,s.jsxs)(U.S.Form,{children:[(0,s.jsx)(B.dO,{isDisabled:a}),(0,s.jsx)(B.s8,{inputProps:{isDisabled:a}}),(0,s.jsxs)(d.Flex,{direction:{base:"column",lg:"row"},gap:"spacer-9",children:[(0,s.jsx)(J.$S,{isDisabled:a,flex:1}),(null==o?void 0:o.state)&&(0,s.jsx)(W.X,{isDisabled:a,flex:1,options:o.state.options})]}),(0,s.jsx)(ReferralProgramSelector,{isDisabled:x,isRequired:g&&!y,placeholder:b,options:getReferralOptions(p)}),(0,s.jsx)(N.m,{isDisabled:H,options:f}),(0,s.jsx)(J.KP,{isDisabled:a,pb:{base:"spacer-24",lg:0}}),C?(0,s.jsx)(B.D2,{children:renderFormAction()}):renderFormAction()]})]})})};var G=a(11841),K=a(91372),Q=a(60948),$=a(1943),Z=a(21097),ee=a(54285),et=a(34474),ea=a(35697);let serializeHraQuestionnaire=e=>{let t={bariatricSurgery:2200,diabetes:2199,comorbidities:2201};return{answers:{[t.bariatricSurgery]:{order:1,answer:e.bariatricSurgery},[t.diabetes]:{order:2,answer:e.diabetes},[t.comorbidities]:{order:3,answer:e.comorbidities}},status:"completed",percentage:100,patientId:e.patientId,slug:"screener-questionnaire"}},submitHraQuestionnaire=async e=>{let t=serializeHraQuestionnaire(e),a=await ea.Z.post("/api/hra-questionnaire",t);return a};var er=a(64267),ei=a(10265),en=a(63317),eo=a(10503),es=a(19171),el=a(67618),ec=a(10002),ed=a(13064),eS=a(94788),eu=a(30368),eC=a(47243),em=a(43505);let ep=[h.PF["1199SEIU"],h.PF.BCBS,h.PF.BCBSPPO,h.PF.United],eh=[h.PF.Aetna,h.PF.Cigna],getEvolveOrganization=(e,t,a,r)=>{if(a===h.eF.SelfPay)return t===h.i$["New York"]?h.bV.SIA:h.bV.Flyte;if(r===n.KaiserPermanente)return h.bV["Kaiser Permanente"];let i=ep.includes(e)||eh.includes(e)&&t===h.i$["New York"]||e===h.PF.Other&&t===h.i$["New York"];return i?h.bV.SIA:h.bV.Flyte},getParticipantDepartmentorOrg=(e,t)=>{if(e===n.KaiserPermanente)return t},isInsuranceStateEligible=(e,t)=>{switch(e){case h.PF["1199SEIU"]:return!0;case h.PF.Aetna:case h.PF.Cigna:return[h.i$["New York"],h.i$["New Jersey"],h.i$.Connecticut].includes(t);case h.PF.BCBS:case h.PF.United:return t===h.i$["New York"];case h.PF.BCBSPPO:case h.PF.Other:case h.PF["Kaiser Colorado"]:case h.PF["Kaiser Georgia"]:case h.PF["Kaiser Hawaii"]:case h.PF["Kaiser MidAtlantic"]:case h.PF["Kaiser Northern California"]:case h.PF["Kaiser Northwest"]:case h.PF["Kaiser Southern California"]:case h.PF["Kaiser Washington"]:case h.PF["Kaiser Washington Options"]:default:return!1}},isEligibleForAutoEnrollment=e=>{let{bmi:t,comorbidity:a,insurance:r,insuranceCoverage:i,state:n}=e;return(!(t>=27)||!(t<=30)||a!==em.IQ.Yes)&&i!==h.eF.SelfPay&&isInsuranceStateEligible(r,n)},getIneligibilityReason=e=>{let{insuranceCoverage:t,insurance:a,state:r}=e;return t===h.eF.SelfPay?h.ib.CashPay:isInsuranceStateEligible(a,r)?void 0:h.ib.Insurance},getLeadStatus=e=>{let{bmi:t,comorbidity:a,insuranceCoverage:r,insurance:i,state:n}=e;if(!isEligibleForAutoEnrollment({bmi:t,comorbidity:a,insurance:i,insuranceCoverage:r,state:n}))return h.rl.EligibleWaiting},getInsurance=e=>{let{insurance:t,insuranceCoverage:a}=e;return a===h.eF.SelfPay?h.PF.SelfPay:t};(i=o||(o={})).CreateLead="createLead",i.CreateContact="createContact",i.UpdateContact="updateContact",i.CheckBenefits="checkBenefits",i.DetermineBenefitsOrLead="determineBenefitsOrLead",i.DetermineContactOrLead="determineContactOrLead",i.FetchConsents="fetchConsents",i.UpdateEmail="updateEmail",i.SubmitHRA="submitHRA";let eg={...ec.a,...o},ex=el.aU[ei.kT.Flyte],eb={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insuranceOther:void 0,insurance:void 0,lastName:"",phone:"",state:void 0,termsAgreement:!1,howDidYouFindUS:"",referralProgram:void 0,comorbidities:[],diabetes:"",bariatricSurgery:""},bmi:void 0,benefitsCheck:void 0,otpData:void 0,consentsData:{items:[],userConsentStatus:[]},contactData:{},passwordData:{password:void 0,confirmPassword:void 0},flyteUserData:void 0,error:void 0},ey={...en.OX,...en.cp,...en.sW,...en.Oz,...en.S8,...en.oQ,...en.q6,...en.nB,...en.v1,...(0,en.Ww)(eb)},eH=(0,eS.cY)({types:{},guards:{isPreEligibilityMet:e=>{let{context:{formData:t,bmi:a}}=e;return ed.Pq.flyte({bmi:a,comorbidity:t.comorbidity})},isApplicationReviewRequired:e=>{let{context:{formData:t,bmi:a}}=e;return!isEligibleForAutoEnrollment({bmi:a,comorbidity:t.comorbidity,insuranceCoverage:t.insuranceCoverage,insurance:t.insurance,state:t.state})},isApplicationDetected:es.Q,isInsurerSelected:e=>{let{context:{formData:t}}=e;return!!t.insurance&&t.insurance!==ei.PF.Other},isAthenaRecordCreated:eo.w},actions:ey}).createMachine({context:()=>eb,id:"flyteMachine",initial:eg.PreEligibility,states:{[eg.PreEligibility]:{id:eg.PreEligibility,initial:eg.Idle,states:{[eg.Idle]:{on:{SUBMIT:{target:eg.Submitting,actions:"updateFormData"}}},[eg.Submitting]:{entry:"assignBMI",always:[{guard:"isPreEligibilityMet",target:"#".concat(eg.ContactDetails)},{target:"#".concat(eg.EligibilityUnmet)}]}}},[eg.ContactDetails]:{id:eg.ContactDetails,initial:eg.Idle,states:{[eg.Idle]:{on:{SUBMIT:{target:"#".concat(eg.InsuranceDetails),actions:"updateFormData"}}}}},[eg.InsuranceDetails]:{id:eg.InsuranceDetails,initial:eg.Idle,states:{[eg.Idle]:{on:{BACK:{target:"#".concat(eg.ContactDetails)},SUBMIT:{target:"#".concat(eg.InsuranceDetailsReview),actions:"updateFormData"}}}}},[eg.InsuranceDetailsReview]:{id:eg.InsuranceDetailsReview,initial:eg.Idle,states:{[eg.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:eg.Submitting}}},[eg.Submitting]:{initial:eg.DetermineBenefitsOrLead,states:{[eg.DetermineBenefitsOrLead]:{id:eg.DetermineBenefitsOrLead,always:[{guard:"isInsurerSelected",target:eg.CheckBenefits},{target:eg.CreateLead}]},[eg.CheckBenefits]:{id:eg.CheckBenefits,invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={...t,payerCode:el.qK[t.insurance]};return await (0,$.o)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:{actions:(0,eC.a)({benefitsCheck:e=>{let{event:t}=e;return t.output.data}}),target:eg.DetermineContactOrLead},onError:eg.DetermineContactOrLead}},[eg.DetermineContactOrLead]:{id:eg.DetermineContactOrLead,always:[{guard:"isApplicationReviewRequired",target:eg.CreateLead},{target:eg.CreateContact}]},[eg.CreateContact]:{id:eg.CreateContact,invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={...t.formData,referralProgram:t.formData.referralProgram||n.NotReferred,...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},company:ex,insurance:getInsurance({insuranceCoverage:t.formData.insuranceCoverage,insurance:t.formData.insurance}),evolveOrganization:getEvolveOrganization(t.formData.insurance,t.formData.state,t.formData.insuranceCoverage,t.formData.referralProgram),participantDepartmentorOrg:getParticipantDepartmentorOrg(t.formData.referralProgram,t.formData.insurance),accountId:el.kS[ei.kT.Flyte]};return await (0,ee.rE)(a)}),input:e=>{let{context:t}=e;return t},onDone:{actions:"assignContactData",target:"#".concat(eg.EmailVerification)},onError:[{guard:"isApplicationDetected",target:"#".concat(eg.ApplicationDetected)},{target:"#".concat(eg.InsuranceDetailsReview,".").concat(eg.Error)}]}},[eg.CreateLead]:{id:eg.CreateLead,invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={...t.formData,referralProgram:t.formData.referralProgram||n.NotReferred,...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},company:ex,insurance:getInsurance({insuranceCoverage:t.formData.insuranceCoverage,insurance:t.formData.insurance}),evolveOrganization:getEvolveOrganization(t.formData.insurance,t.formData.state,t.formData.insuranceCoverage,t.formData.referralProgram),ineligibilityReason:getIneligibilityReason({insuranceCoverage:t.formData.insuranceCoverage,insurance:t.formData.insurance,state:t.formData.state}),leadStatus:getLeadStatus({bmi:t.bmi,comorbidity:t.formData.comorbidity,insuranceCoverage:t.formData.insuranceCoverage,insurance:t.formData.insurance,state:t.formData.state}),automateEvolveEnrollment:isEligibleForAutoEnrollment({bmi:t.bmi,comorbidity:t.formData.comorbidity,insuranceCoverage:t.formData.insuranceCoverage,insurance:t.formData.insurance,state:t.formData.state}),participantDepartmentorOrg:getParticipantDepartmentorOrg(t.formData.referralProgram,t.formData.insurance)};return await (0,er.$)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isApplicationReviewRequired",target:"#".concat(eg.ApplicationReview)},{target:"#".concat(eg.ApplicationComplete)}],onError:[{guard:"isApplicationDetected",target:"#".concat(eg.ApplicationDetected)},{target:"#".concat(eg.InsuranceDetailsReview,".").concat(eg.Error)}]}}}},[eg.Error]:{id:"".concat(eg.InsuranceDetailsReview,".").concat(eg.Error),on:{SUBMIT:{actions:["updateFormData","resetBenefitsCheck"],target:eg.Submitting}}}}},[eg.EmailVerification]:{id:eg.EmailVerification,initial:eg.Idle,states:{[eg.Idle]:{id:"".concat(eg.EmailVerification,".").concat(eg.Idle),on:{SUBMIT:{actions:"assignOtpCode",target:eg.Submitting},RESEND_EMAIL_VERIFICATION:{target:eg.Idle,reenter:!0},UPDATE_EMAIL:{target:eg.UpdateEmail}},invoke:{input:e=>{var t;let{context:a,event:r}=e;return{email:a.formData.email,firstName:a.formData.firstName,onSuccess:null==r?void 0:null===(t=r.data)||void 0===t?void 0:t.onSuccess}},src:(0,eu.p4)(async e=>{let{input:t}=e,a={email:t.email,firstName:t.firstName},r=await (0,K.t)(a);return{token:r.data.token,onSuccess:t.onSuccess}}),onDone:{actions:[(0,eC.a)({otpData:e=>{let{context:t,event:a}=e;return{...t.otpData,token:a.output.token}}}),e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}]},onError:eg.Error}},[eg.Submitting]:{invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,token:t.otpData.token,otp:t.otpData.otp};return await (0,Q.M)(a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(eg.OnboardingChecklist),onError:eg.Error}},[eg.Error]:{on:{SUBMIT:{actions:"assignOtpCode",target:eg.Submitting},RESEND_EMAIL_VERIFICATION:{target:eg.Idle},UPDATE_EMAIL:{target:eg.UpdateEmail}}},[eg.UpdateEmail]:{initial:eg.Idle,states:{[eg.Idle]:{invoke:{input:e=>{let{context:t,event:a}=e;return{contactId:t.contactData.contactId,email:a.data.email,onSuccess:a.data.onSuccess}},src:(0,eu.p4)(async e=>{let{input:t}=e,a={contactId:t.contactId,email:t.email};await (0,ee.Tk)(a);let r={email:t.email,onSuccess:t.onSuccess};return r}),onDone:{actions:["assignNewEmail",e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}],target:"#".concat(eg.EmailVerification,".").concat(eg.Idle)},onError:eg.Error}},[eg.Error]:{on:{SUBMIT:{target:"#".concat(eg.EmailVerification,".").concat(eg.Idle)},RESEND_EMAIL_VERIFICATION:{target:"#".concat(eg.EmailVerification,".").concat(eg.Idle)},UPDATE_EMAIL:{target:eg.Idle}}}}}}},[eg.ReviewConsents]:{id:eg.ReviewConsents,initial:eg.FetchConsents,states:{[eg.Idle]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:eg.Submitting}}},[eg.FetchConsents]:{invoke:{src:(0,eu.p4)(async()=>await (0,Z.J)()),onDone:{actions:"assignConsents",target:eg.Idle},onError:eg.Error}},[eg.Submitting]:{invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={patientIdentifier:t.contactData.contactId,firstName:t.formData.firstName,lastName:t.formData.lastName,phone:t.formData.phone,email:t.formData.email,birthDate:t.formData.birthdate,state:t.formData.state,heightInInch:t.formData.heightInInch,heightInFeet:t.formData.heightInFoot,currentWeightInPounds:t.formData.currentWeightInPounds,evolveOrganization:ei.bV.Flyte,consents:t.consentsData.userConsentStatus};return await (0,et.D)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{actions:"assignFlyteUserData",target:eg.SubmitHRA}],onError:"#".concat(eg.OnboardingUserError)}},[eg.SubmitHRA]:{id:eg.SubmitHRA,invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={bariatricSurgery:t.formData.bariatricSurgery,diabetes:t.formData.diabetes,comorbidities:t.formData.comorbidities,patientId:t.flyteUserData.patientId};return await submitHraQuestionnaire(a)}),input:e=>{let{context:t}=e;return t},onDone:{target:eg.UpdateContact},onError:{target:eg.UpdateContact}}},[eg.UpdateContact]:{invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={contactId:t.contactData.contactId,evolvePatientID:t.flyteUserData.patientId};return await (0,ee.Tk)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isAthenaRecordCreated",target:"#".concat(eg.CreatePassword)},{target:"#".concat(eg.OnboardingUserError)}],onError:"#".concat(eg.OnboardingUserError)}},[eg.Error]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:eg.Submitting}}}}},[eg.CreatePassword]:{id:eg.CreatePassword,initial:eg.Idle,states:{[eg.Idle]:{on:{SUBMIT:{actions:"assignPasswordData",target:eg.Submitting}}},[eg.Submitting]:{invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,password:t.passwordData.password,confirmPassword:t.passwordData.confirmPassword};return await (0,G.x)(t.flyteUserData.verifyToken,a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(eg.AppDownload),onError:{target:eg.Error,actions:"assignError"}}},[eg.Error]:{on:{SUBMIT:{actions:["resetError","assignPasswordData"],target:eg.Submitting}}}}},[eg.OnboardingChecklist]:{id:eg.OnboardingChecklist,on:{SUBMIT:{target:"#".concat(eg.ReviewConsents)}}},[eg.AppDownload]:{id:eg.AppDownload},[eg.ApplicationReview]:{id:eg.ApplicationReview},[eg.OnboardingUserError]:{id:eg.OnboardingUserError},[eg.ApplicationComplete]:{id:eg.ApplicationComplete},[eg.ApplicationDetected]:{id:eg.ApplicationDetected},[eg.EligibilityUnmet]:{id:eg.EligibilityUnmet,initial:eg.Idle,states:{[eg.Idle]:{on:{SUBMIT:{target:eg.Submitting,actions:"updateFormData"}}},[eg.Submitting]:{invoke:{src:(0,eu.p4)(async e=>{let{input:t}=e,a={...t,company:el.aU[ei.kT.Flyte],leadStatus:ei.rl.Ineligible,ineligibilityReason:ei.ib.BMI,automateEvolveEnrollment:!1};return await (0,er.$)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:eg.Success,onError:eg.Error}},[eg.Success]:{},[eg.Error]:{on:{SUBMIT:{target:eg.Submitting}}}}}},on:{RESET:{target:"#".concat(eg.PreEligibility),actions:"reset"}}});var ef=a(56344);let ev={[C.J.PreEligibility]:{title:(0,s.jsxs)(d.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsxs)(d.TextPairing.Label,{color:"text-secondary-negative",children:["We're so glad you're here!"," ",(0,s.jsx)(d.Text,{as:"span",variant:"text-header-2XL",color:"text-primary",children:"Let's make sure you're eligible for FlyteHealth."})]}),(0,s.jsx)(d.TextPairing.SubLabel,{color:"text-secondary",children:"You must meet specific age and Body Mass Index (BMI) requirements* to be eligible for the FlyteHealth program."})]}),bmiEnrollmentDisclaimer:(0,s.jsx)(d.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. FlyteHealth providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the FlyteHealth program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[C.J.EligibilityUnmet]:{title:(0,s.jsxs)(d.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(d.TextPairing.Label,{color:"text-secondary-negative",children:"Unfortunately, you are not eligible to join FlyteHealth at this time."}),(0,s.jsx)(d.TextPairing.SubLabel,{color:"text-secondary",children:"FlyteHealth requires a minimum BMI of 27+ (plus one or more weight-related health conditions) or a BMI of 30+"})]})},[C.J.ContactDetails]:{title:(0,s.jsxs)(d.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(d.TextPairing.Label,{color:"text-secondary-negative",children:"Congratulations! You're eligible for the FlyteHealth program"}),(0,s.jsx)(d.TextPairing.SubLabel,{color:"text-secondary",children:"Tell us a little more about yourself."})]})},[C.J.InsuranceDetails]:{title:(0,s.jsxs)(d.Text,{variant:"text-header-2XL",color:"text-secondary-negative",children:["One more thing:"," ",(0,s.jsx)(d.Text,{as:"span",variant:"text-header-2XL",color:"text-primary",children:"Do you have health insurance?"})]})},[C.J.InsuranceDetailsReview]:{title:(0,s.jsxs)(d.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(d.TextPairing.Label,{children:"Let's review: Is your info correct?"}),(0,s.jsx)(d.TextPairing.SubLabel,{color:"text-secondary",children:"Please double-check the information you provided to make sure everything is correct."})]})},[C.J.ApplicationComplete]:{title:(0,s.jsxs)(d.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(d.TextPairing.Label,{color:"text-secondary-negative",children:"Welcome aboard! We're so excited you're here."}),(0,s.jsx)(d.TextPairing.SubLabel,{color:"text-secondary",children:"Next, we need to confirm your email. Click the link we sent to:"})]}),description:(0,s.jsx)(d.Text,{mt:"spacer-8",color:"text-secondary",variant:"text-body-regular",children:"Can’t find the email? Make sure to check your Spam folder."})},[C.J.ApplicationReview]:{title:(0,s.jsxs)(d.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(d.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,s.jsx)(d.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]})},[C.J.ApplicationDetected]:{title:(0,s.jsx)(d.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,s.jsx)(d.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[C.J.EmailVerification]:ef.T[C.J.EmailVerification],[C.J.OnboardingChecklist]:ef.T[C.J.OnboardingChecklist],[C.J.CreatePassword]:ef.T[C.J.CreatePassword],[C.J.AppDownload]:ef.T[C.J.AppDownload],[C.J.ReviewConsents]:ef.T[C.J.ReviewConsents]},eI=[h.PF["1199SEIU"],h.PF.Aetna,h.PF.BCBS,h.PF.BCBSPPO,h.PF.Cigna,h.PF["Kaiser Colorado"],h.PF["Kaiser Georgia"],h.PF["Kaiser Hawaii"],h.PF["Kaiser MidAtlantic"],h.PF["Kaiser Northern California"],h.PF["Kaiser Northwest"],h.PF["Kaiser Southern California"],h.PF["Kaiser Washington"],h.PF["Kaiser Washington Options"],h.PF.United,h.PF.Other],eR=[h.Op.Brochure,h.Op.Email,h.Op.Mailer,h.Op.OnsiteMonitor,h.Op.Poster,h.Op.ProviderReferral,h.Op.Other],eD=[h.Op.Brochure,h.Op.CoworkerReferral,h.Op.Email,h.Op.GoogleAd,h.Op.Poster,h.Op.PrintAd,h.Op.ProviderReferral,h.Op.SocialMedia,h.Op.TradeShow,h.Op.TVAd,h.Op.WebSearch,h.Op.WordOfMouth,h.Op.Other],eE={[C.J.ContactDetails]:{state:{options:B.Fp},howDidYouFindUs:{options:{referrerOptions:eR,notReferrerOptions:eD}}},[C.J.InsuranceDetails]:{insuranceCoverage:{},insurance:{label:"Insurance Company",insuranceCarriers:eI},insuranceOther:{description:(0,s.jsx)(d.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"Enter the name of your insurance company"})},insuranceMemberID:{}},[C.J.InsuranceDetailsReview]:{insurance:{label:"Insurance Company",insuranceCarriers:eI}}},ej=h.kT.Flyte,FlyteWorkflow=e=>{let{render:t}=e,[a,r]=(0,b.eO)(eH),i=(0,m.useMemo)(()=>(0,x.k)(a.value),[a.value]);(0,O.R)(i,ej);let n=(0,m.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),o=(0,m.useCallback)(()=>{r({type:"BACK"})},[r]),l=(0,m.useCallback)(()=>{switch(i){case eg.PreEligibility:return(0,s.jsx)(M.b,{configuration:{contentResources:ev[C.J.PreEligibility]},onSubmit:n});case eg.ContactDetails:return(0,s.jsx)(FlyteContactDetailsForm,{configuration:{contentResources:ev[C.J.ContactDetails],fields:eE[C.J.ContactDetails]},onSubmit:n,defaultValues:a.context.formData});case eg.EligibilityUnmet:return(0,s.jsx)(w.X,{configuration:{contentResources:ev[C.J.EligibilityUnmet]},onSubmit:n,loading:a.matches({[eg.EligibilityUnmet]:eg.Submitting}),isEmailSent:a.matches({[eg.EligibilityUnmet]:eg.Success}),hasError:a.matches({[eg.EligibilityUnmet]:eg.Error})});case eg.InsuranceDetails:return(0,s.jsx)(A.v,{configuration:{contentResources:ev[C.J.InsuranceDetails],fields:eE[C.J.InsuranceDetails]},onSubmit:n,onBack:o});case eg.InsuranceDetailsReview:return(0,s.jsx)(k.b,{configuration:{contentResources:ev[C.J.InsuranceDetailsReview],fields:eE[C.J.InsuranceDetailsReview]},onSubmit:n,loading:a.matches({[eg.InsuranceDetailsReview]:eg.Submitting}),hasError:a.matches({[eg.InsuranceDetailsReview]:eg.Error}),defaultValues:a.context.formData});case eg.ApplicationComplete:return(0,s.jsx)(I.J,{...ev[C.J.ApplicationComplete],email:a.context.formData.email});case eg.ApplicationReview:return(0,s.jsx)(D.G,{...ev[C.J.ApplicationReview]});case eg.ApplicationDetected:return(0,s.jsx)(R.v,{...ev[C.J.ApplicationDetected],email:a.context.formData.email});case eg.EmailVerification:return(0,s.jsx)(T.Z,{configuration:{contentResources:{title:ev[C.J.EmailVerification](a.context.formData.email).title}},email:a.context.formData.email,hasError:a.matches({[eg.EmailVerification]:eg.Error}),loading:a.matches({[eg.EmailVerification]:eg.Submitting}),isUpdateEmailLoading:a.matches({[eg.EmailVerification]:{[eg.UpdateEmail]:eg.Idle}}),hasUpdateEmailError:a.matches({[eg.EmailVerification]:{[eg.UpdateEmail]:eg.Error}}),onSubmit:n,onResendCode:e=>r({type:"RESEND_EMAIL_VERIFICATION",data:{onSuccess:e}}),onEditEmail:(e,t)=>r({type:"UPDATE_EMAIL",data:{email:e,onSuccess:t}})});case eg.OnboardingChecklist:return(0,s.jsx)(P.O,{configuration:{contentResources:ev[C.J.OnboardingChecklist]},onSubmit:n});case eg.ReviewConsents:return(0,s.jsx)(F.R,{configuration:{contentResources:ev[C.J.ReviewConsents]},consents:a.context.consentsData.items,hasError:a.matches({[eg.ReviewConsents]:eg.Error}),loading:a.matches({[eg.ReviewConsents]:eg.FetchConsents})||a.matches({[eg.ReviewConsents]:eg.Submitting})||a.matches({[eg.ReviewConsents]:eg.UpdateContact})||a.matches({[eg.ReviewConsents]:eg.SubmitHRA}),onSubmit:n});case eg.CreatePassword:return(0,s.jsx)(j.f,{configuration:{contentResources:ev[C.J.CreatePassword]},loading:a.matches({[eg.CreatePassword]:eg.Submitting}),error:a.context.error,onSubmit:n});case eg.AppDownload:return(0,s.jsx)(v.B,{title:ev[C.J.AppDownload].title,checklist:ev[C.J.AppDownload].checklist});case eg.OnboardingUserError:return(0,s.jsx)(L._,{});default:return null}},[i,a]);return t({header:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(p.E,{partner:ej}),(0,s.jsx)(E.K,{currentStep:i})]}),body:l(),currentWorkFlowStep:i})};var ew=a(35592),eT=a(17219),eA=a(84901),ek=a(16428),eP=a(19474),eL=a(44943);let eM={[h.kT.CareCompass]:{asset:{src:p.Z[h.kT.CareCompass],width:"64px",height:"64px",alt:"Care Compass Logo"},name:"Care Compass",description:"State of Connecticut Health Plan Members"},[h.kT.Aetna]:{asset:{src:p.Z[h.kT.Aetna],width:"141px",height:"32px",alt:"Aetna Logo"},name:"State of Connecticut: Aetna",description:"Aetna MA for State of Connecticut Retirees"},[h.kT.PequotHealthCare]:{asset:{src:p.Z[h.kT.PequotHealthCare],width:"103px",height:"40px",alt:"Pequot Health Care Logo"},name:"Mashantucket Pequot Tribal Nation",description:"Pequot Healthy Weight Program"},[h.kT.RiverSpringLiving]:{asset:{src:p.Z[h.kT.RiverSpringLiving],width:"158px",height:"24px",alt:"RiverSpring Living Logo"},name:"RiverSpring Living Employee Program",description:"Employees at The Hebrew Home at Riverdale by RiverSpring Living"},[h.kT.PyleFamilyInsurance]:{asset:{src:p.Z[h.kT.PyleFamilyInsurance],width:"157px",height:"48px",alt:"Pyle Family Insurance Logo"},name:"A. Duie Pyle",description:"Pyle Weight Management Program for Employees"},[h.kT.MDSave]:{asset:{src:p.Z[h.kT.MDSave],width:"56px",height:"56px",alt:"MDsave Logo"},name:"MDsave",description:"Patients in partnership with MDsave"},[h.kT["1199SEIU"]]:{asset:{src:p.Z[h.kT["1199SEIU"]],width:"211px",height:"122px",alt:"1199SEIU Logo"},name:"1199SEIU",description:"1199SEIU"}},WorkflowCard=e=>(0,s.jsx)(d.Flex,{direction:"column",gap:"spacer-2",alignItems:"center",cursor:"pointer",role:"group",tabIndex:0,outline:"none",as:"button",onKeyDown:t=>{"Enter"===t.key&&e.onClick()},...e});WorkflowCard.Image=e=>(0,s.jsx)(d.Image,{flex:1,objectFit:"contain",...e}),WorkflowCard.Description=e=>(0,s.jsx)(d.Text,{variant:"text-body-floating-label-regular",color:"text-secondary",textAlign:"center",...e}),WorkflowCard.Title=e=>(0,s.jsx)(d.Text,{color:"text-secondary",variant:"text-body-meta-medium",transition:"color 100ms linear",_groupHover:{color:"text-link-primary-hover"},_groupActive:{color:"text-link-primary-pressed"},_groupFocusVisible:{color:"text-link-primary-default"},...e}),WorkflowCard.Frame=e=>(0,s.jsx)(d.Flex,{px:"spacer-3",pb:"spacer-5",borderRadius:"radii-1",borderWidth:"1px",borderStyle:"solid",borderColor:"ui-element-outline-active",transition:"background-color 100ms linear, border-color 100ms linear",_groupFocusVisible:{outlineWidth:"3px",outlineStyle:"solid",outlineColor:"primary-focus"},_groupHover:{borderColor:"primary-hover",backgroundColor:"background-action-hover"},_groupActive:{borderColor:"primary-pressed",backgroundColor:"background-action-pressed"},direction:"column",alignItems:"center",minHeight:"160px",width:"100%",...e});let WorkflowSelector=e=>{let{onSelectWorkflow:t}=e,{track:a}=(0,c.useAnalytics)(),handleWorkflowClick=e=>()=>(a("".concat(e,"_selected"),{partner:e}),t(e)),r=Object.entries(eM);return(0,s.jsxs)(U.D,{direction:"column",gap:"spacer-9",children:[(0,s.jsx)(d.Flex,{direction:"column",gap:"spacer-2",children:(0,s.jsxs)(d.Text,{variant:"text-header-XL",color:"text-secondary-negative",children:["Welcome!"," ",(0,s.jsxs)(d.Text,{as:"span",variant:"text-header-XL",color:"text-primary",children:["To get started, please select your benefit program."," "]})]})}),(0,s.jsxs)(d.Flex,{direction:"column",gap:{base:"spacer-9"},children:[(0,s.jsx)(d.Flex,{direction:"column",gap:"spacer-4",flex:1}),(0,s.jsxs)(d.Flex,{direction:"column",gap:"spacer-4",pb:{base:"spacer-9",md:"spacer-6"},flex:1,children:[(0,s.jsx)(d.Flex,{direction:{base:"column",md:"row"},gap:{base:"spacer-6",md:"spacer-3"},justifyContent:{md:"space-between"},alignItems:{md:"end"},children:(0,s.jsxs)(d.Flex,{gap:"spacer-3",alignItems:"center",flex:1,children:[(0,s.jsx)(d.IconArrowRight,{color:"primary-default",size:"l"}),(0,s.jsx)(d.Text,{variant:"text-body-large-medium",color:"text-primary",children:"Available Programs:"})]})}),(0,s.jsxs)(d.Grid,{spacingX:"spacer-4",spacingY:{base:"spacer-4",lg:"spacer-6"},columns:{base:2,md:3,lg:4,xxl:5},children:[r.map(e=>{let[t,{asset:a,description:r,name:i}]=e;return(0,s.jsxs)(WorkflowCard,{onClick:handleWorkflowClick(t),children:[(0,s.jsxs)(WorkflowCard.Frame,{children:[(0,s.jsx)(WorkflowCard.Image,{...a}),(0,s.jsx)(WorkflowCard.Description,{children:r})]}),(0,s.jsx)(WorkflowCard.Title,{children:i})]},t)}),(0,s.jsxs)(WorkflowCard,{"aria-label":"Provider Referral",onClick:handleWorkflowClick(h.kT.Flyte),maxWidth:"16rem",children:[(0,s.jsx)(WorkflowCard.Frame,{p:0,width:"100%",minHeight:{base:"7.5rem",md:"10rem"},children:(0,s.jsx)(WorkflowCard.Image,{src:p.Z[h.kT.KaiserPermanente],width:"123px",height:"40px",alt:"Kaiser Permanente Logo"})}),(0,s.jsx)(WorkflowCard.Title,{children:"Provider Referral"})]}),(0,s.jsxs)(WorkflowCard,{onClick:handleWorkflowClick(h.kT.Flyte),maxWidth:"16rem",children:[(0,s.jsx)(WorkflowCard.Frame,{p:0,width:"100%",minHeight:{base:"7.5rem",md:"10rem"},children:(0,s.jsx)(WorkflowCard.Image,{src:p.Z[h.kT.Sone],width:"123px",height:"40px",alt:"Sone Logo"})}),(0,s.jsx)(WorkflowCard.Title,{children:"Provider Referral"})]})]})]})]}),(0,s.jsxs)(d.Flex,{direction:"column",gap:"spacer-1",children:[(0,s.jsx)(d.Text,{color:"text-secondary",variant:"text-body-bold",children:"Need some help?"}),(0,s.jsxs)(d.Text,{color:"text-secondary",variant:"text-body-regular",children:["Please call"," ",(0,s.jsx)(eL.R,{})," ","to speak with a Care Coordinator."]})]})]})},eF={WorkflowSelector:"workflowSelector",...ei.kT},eO=(0,eS.cY)({types:{},guards:{isCareCompassSelected:e=>{let{event:t}=e;return t.data.workflow===ei.kT.CareCompass},isAetnaSelected:e=>{let{event:t}=e;return t.data.workflow===ei.kT.Aetna},isRiverspringSelected:e=>{let{event:t}=e;return t.data.workflow===ei.kT.RiverSpringLiving},isPequotSelected:e=>{let{event:t}=e;return t.data.workflow===ei.kT.PequotHealthCare},isPyleSelected:e=>{let{event:t}=e;return t.data.workflow===ei.kT.PyleFamilyInsurance},isMDSaveSelected:e=>{let{event:t}=e;return t.data.workflow===ei.kT.MDSave},isChristianaCareSelected:e=>{let{event:t}=e;return t.data.workflow===ei.kT.ChristianaCare},is1199SEIUSelected:e=>{let{event:t}=e;return t.data.workflow===ei.kT["1199SEIU"]}}}).createMachine({id:"workflowManagerMachine",initial:eF.WorkflowSelector,states:{[eF.WorkflowSelector]:{id:eF.WorkflowSelector,on:{SUBMIT:[{guard:"isCareCompassSelected",target:eF.CareCompass},{guard:"isAetnaSelected",target:eF.Aetna},{guard:"isRiverspringSelected",target:eF.RiverSpringLiving},{guard:"isPequotSelected",target:eF.PequotHealthCare},{guard:"isPyleSelected",target:eF.PyleFamilyInsurance},{guard:"isMDSaveSelected",target:eF.MDSave},{guard:"isChristianaCareSelected",target:eF.ChristianaCare},{guard:"is1199SEIUSelected",target:eF["1199SEIU"]},{target:eF.Flyte}]}},[eF.PequotHealthCare]:{},[eF.RiverSpringLiving]:{},[eF.CareCompass]:{},[eF.Aetna]:{},[eF.Flyte]:{},[eF.PyleFamilyInsurance]:{},[eF.MDSave]:{},[eF.ChristianaCare]:{},[eF["1199SEIU"]]:{}}}),WorkflowManager=e=>{let{render:t}=e,[a,r]=(0,b.eO)(eO),i=(0,m.useMemo)(()=>(0,x.k)(a.value),[a.value]),n=(0,m.useCallback)(e=>{r({type:"SUBMIT",data:{workflow:e}})},[r]),o=(0,m.useCallback)(()=>{switch(i){case eF.WorkflowSelector:return t({header:(0,s.jsx)(p.E,{partner:h.kT.Flyte}),body:(0,s.jsx)(WorkflowSelector,{onSelectWorkflow:n}),currentWorkFlowStep:i});case eF.Aetna:return(0,s.jsx)(d.ComposerProvider,{theme:g.rS.aetna,children:(0,s.jsx)(y.U,{render:t})});case eF.CareCompass:return(0,s.jsx)(d.ComposerProvider,{theme:g.rS.careCompass,children:(0,s.jsx)(H.$,{render:t})});case eF.RiverSpringLiving:return(0,s.jsx)(d.ComposerProvider,{theme:g.rS.riverspring,children:(0,s.jsx)(ek.l,{render:t})});case eF.PequotHealthCare:return(0,s.jsx)(d.ComposerProvider,{theme:g.rS.pequot,children:(0,s.jsx)(eT.u,{render:t})});case eF.PyleFamilyInsurance:return(0,s.jsx)(d.ComposerProvider,{theme:g.rS.pyle,children:(0,s.jsx)(eA.u,{render:t})});case eF.MDSave:return(0,s.jsx)(d.ComposerProvider,{theme:g.rS.standard,children:(0,s.jsx)(ew.t,{render:t})});case eF.ChristianaCare:return(0,s.jsx)(d.ComposerProvider,{theme:g.rS.standard,children:(0,s.jsx)(f.k,{render:t})});case eF["1199SEIU"]:return(0,s.jsx)(d.ComposerProvider,{theme:g.rS.standard,children:(0,s.jsx)(eP.N,{render:t})});case eF.Flyte:default:return(0,s.jsx)(FlyteWorkflow,{render:t})}},[i]);return o()},FlyteSignUpLauncher=e=>{let{size:t="l",children:a="Get Started",...r}=e,[i,n]=(0,m.useState)(!1),[o,p]=(0,m.useState)(!1),{track:h}=(0,c.useAnalytics)(),g=(0,m.useCallback)(()=>{p(!1),n(!1),h(l.U.closeWorkflowEvent)},[]),x=(0,m.useCallback)(()=>p(e=>!e),[]),b=(0,m.useCallback)(e=>{let t=[C.J.ApplicationReview,C.J.ApplicationComplete,C.J.ApplicationDetected,C.J.EligibilityUnmet,C.J.AppDownload],a=t.includes(e);a?n(!1):(h(l.U.closeWorkflowConfirmationEvent),x())},[]),y=(0,m.useCallback)(()=>{h(l.U.abortCloseWorkflow),x()},[x]),H=(0,m.useCallback)(()=>{h(l.U.openPartnerSelectorEvent),n(!0)},[h,n]);return(0,s.jsxs)(s.Fragment,{children:[(0,s.jsx)(d.Button,{onClick:H,trailingIcon:(0,s.jsx)(d.IconArrowRight,{}),size:t,children:a,"data-test":"flyteSignUpLauncher",...r}),i&&(0,s.jsx)(WorkflowManager,{render:e=>{let{header:t,body:a,currentWorkFlowStep:r}=e;return(0,s.jsxs)(S.Eg,{isOpen:!0,onClose:()=>b(r),children:[(0,s.jsx)(S.Eg.Header,{children:t}),(0,s.jsx)(S.Eg.Body,{children:a},r)]})}}),(0,s.jsx)(u.e,{isOpen:o,onContinue:y,onLeave:g})]})}},35592:function(e,t,a){a.d(t,{t:function(){return MDSaveWorkflow}});var r,i=a(85893),n=a(71986),o=a(65660),s=a(20410),l=a(31540),c=a(53157),d=a(39424),S=a(86640),u=a(73071),C=a(64504),m=a(56401),p=a(70908),h=a(10002),g=a(17304),x=a(94445),b=a(67294),y=a(64267),H=a(10265),f=a(19171),v=a(67618),I=a(13064),R=a(94788),D=a(47243),E=a(30368);(r||(r={})).CreateLead="createLead";let j={...h.a,...r},w=v.aU[H.kT.MDSave],T={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insurance:void 0,lastName:"",phone:"",state:void 0,termsAgreement:!1,howDidYouFindUS:"",comorbidities:[],diabetes:"",bariatricSurgery:""},bmi:void 0},A=(0,R.cY)({types:{},guards:{isPreEligibilityMet:e=>{let{context:{bmi:t,formData:a}}=e;return I.Pq.mdSave({bmi:t,comorbidity:a.comorbidity})},isApplicationDetected:f.Q},actions:{updateFormData:(0,D.a)({formData:e=>{let{context:t,event:a}=e;return{...t.formData,...a.data}}}),assignBMI:(0,D.a)({bmi:e=>{let{context:t}=e,{heightInFoot:a,heightInInch:r,highestWeightInPounds:i}=t.formData;return(0,I.V2)({heightFeet:(0,I.MC)(a),heightInches:(0,I.MC)(r),weightPounds:(0,I.MC)(i)})}}),reset:(0,D.a)({...T})}}).createMachine({context:()=>T,id:"mdSaveMachine",initial:j.PreEligibility,states:{[j.PreEligibility]:{id:j.PreEligibility,initial:j.Idle,states:{[j.Idle]:{on:{SUBMIT:{target:j.Submitting,actions:"updateFormData"}}},[j.Submitting]:{entry:"assignBMI",always:[{target:"#".concat(j.ContactDetails),guard:"isPreEligibilityMet"},{target:"#".concat(j.EligibilityUnmet)}]}}},[j.ContactDetails]:{id:j.ContactDetails,initial:j.Idle,states:{[j.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:j.Submitting}}},[j.Submitting]:{id:j.Submitting,initial:j.CreateLead,states:{[j.CreateLead]:{id:j.CreateLead,invoke:{src:(0,E.p4)(async e=>{let{input:t}=e,a={...t.formData,company:w,evolveOrganization:H.bV.MDsave,leadStatus:H.rl.EligibleWaiting,automateEvolveEnrollment:!1};return await (0,y.$)(a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(j.ApplicationReview),onError:[{guard:"isApplicationDetected",target:"#".concat(j.ApplicationDetected)},{target:"#".concat(j.Error)}]}}}},[j.Error]:{id:j.Error,on:{SUBMIT:{actions:"updateFormData",target:j.Submitting}}}}},[j.ApplicationReview]:{id:j.ApplicationReview},[j.ApplicationDetected]:{id:j.ApplicationDetected},[j.EligibilityUnmet]:{id:j.EligibilityUnmet,initial:j.Idle,states:{[j.Idle]:{on:{SUBMIT:{target:j.Submitting,actions:"updateFormData"}}},[j.Submitting]:{invoke:{src:(0,E.p4)(async e=>{let{input:t}=e,a={...t,company:w,leadStatus:H.rl.Ineligible,ineligibilityReason:H.ib.BMI,automateEvolveEnrollment:!1};return await (0,y.$)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:j.Success,onError:j.Error}},[j.Success]:{},[j.Error]:{on:{SUBMIT:{target:j.Submitting}}}}}},on:{RESET:{target:"#".concat(j.PreEligibility),actions:"reset"}}});var k=a(56344);let P={[p.J.PreEligibility]:{title:(0,i.jsxs)(n.TextPairing,{variant:"textpairing-header-2XL",children:[(0,i.jsx)(n.TextPairing.Label,{color:"text-primary",children:"Let's make sure you're eligible for the FlyteHealth program."}),(0,i.jsx)(n.TextPairing.SubLabel,{color:"text-secondary",children:"To be eligible for the FlyteHealth program through your MDsave benefits, you must meet specific age and Body Mass Index (BMI)* requirements."})]}),bmiEnrollmentDisclaimer:(0,i.jsx)(n.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. FlyteHealth providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the FlyteHealth program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[p.J.EligibilityUnmet]:{title:(0,i.jsxs)(n.TextPairing,{variant:"textpairing-header-2XL",children:[(0,i.jsx)(n.TextPairing.Label,{color:"text-secondary-negative",children:"Unfortunately, you are not eligible to join FlyteHealth at this time."}),(0,i.jsx)(n.TextPairing.SubLabel,{color:"text-secondary",children:"The FlyteHealth program requires a minimum BMI of 27+ (plus one or more weight-related health conditions) or a BMI of 30+."})]})},[p.J.ContactDetails]:{title:(0,i.jsxs)(n.TextPairing,{variant:"textpairing-header-2XL",children:[(0,i.jsx)(n.TextPairing.Label,{color:"text-secondary-negative",children:"Congratulations! You're eligible for the FlyteHealth program"}),(0,i.jsx)(n.TextPairing.SubLabel,{color:"text-secondary",children:"To help us match your information with your employer, tell us about yourself."})]})},[p.J.ApplicationReview]:{title:(0,i.jsxs)(n.TextPairing,{variant:"textpairing-header-2XL",children:[(0,i.jsx)(n.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,i.jsx)(n.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]})},[p.J.ApplicationDetected]:{title:(0,i.jsx)(n.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,i.jsx)(n.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[p.J.OnboardingChecklist]:k.T[p.J.OnboardingChecklist],[p.J.CreatePassword]:k.T[p.J.CreatePassword],[p.J.AppDownload]:k.T[p.J.AppDownload],[p.J.ReviewConsents]:k.T[p.J.ReviewConsents]};var L=a(58976);let M=[m.Op.WordOfMouth,m.Op.Other],F={[p.J.ContactDetails]:{state:{options:L.Fp},howDidYouFindUs:{options:M}}},O=new Map([[p.J.PreEligibility,c.t.get(p.J.PreEligibility)],[p.J.ContactDetails,c.t.get(p.J.ContactDetails)]]),B=m.kT.MDSave,MDSaveWorkflow=e=>{let{render:t}=e,[a,r]=(0,x.eO)(A),y=(0,b.useMemo)(()=>(0,g.k)(a.value),[a.value]);(0,C.R)(y,B);let H=(0,b.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),f=(0,b.useCallback)(()=>{switch(y){case h.a.PreEligibility:return(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.Alert,{variant:"subtle",status:"warning",borderRadius:"none",justifyContent:"center",children:[(0,i.jsx)(n.Alert.Icon,{}),(0,i.jsxs)(n.Alert.Title,{children:["To continue, you must first purchase the MDsave FlyteHealth bundle. To purchase, click"," ",(0,i.jsx)(n.Link,{isExternal:!0,href:"https://www.mdsave.com/p/flyte-weight-loss-and-nutritional-counseling",fontWeight:"bold",children:"here"}),"."]})]}),(0,i.jsx)(u.b,{configuration:{contentResources:P[p.J.PreEligibility]},onSubmit:H})]});case h.a.ContactDetails:return(0,i.jsx)(d.q,{configuration:{contentResources:P[p.J.ContactDetails],fields:F[p.J.ContactDetails]},loading:a.matches({[h.a.ContactDetails]:h.a.Submitting}),onSubmit:H,defaultValues:a.context.formData});case h.a.EligibilityUnmet:return(0,i.jsx)(S.X,{configuration:{contentResources:P[p.J.EligibilityUnmet]},onSubmit:H,loading:a.matches({[h.a.EligibilityUnmet]:h.a.Submitting}),isEmailSent:a.matches({[h.a.EligibilityUnmet]:h.a.Success}),hasError:a.matches({[h.a.EligibilityUnmet]:h.a.Error})});case h.a.ApplicationReview:return(0,i.jsx)(s.G,{...P[p.J.ApplicationReview]});case h.a.ApplicationDetected:return(0,i.jsx)(o.v,{...P[p.J.ApplicationDetected],email:a.context.formData.email});default:return null}},[y,a]);return t({header:(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.Flex,{gap:"spacer-5",alignItems:"center",children:[(0,i.jsx)(l.E,{partner:m.kT.Flyte}),(0,i.jsx)(n.Divider,{orientation:"vertical",alignSelf:"stretch",height:"auto"}),(0,i.jsx)(l.E,{partner:B})]}),(0,i.jsx)(c.K,{currentStep:y,steps:O})]}),body:f(),currentWorkFlowStep:y})}},17219:function(e,t,a){a.d(t,{u:function(){return PequotWorkflow}});var r,i,n=a(85893),o=a(71986),s=a(44761),l=a(33640),c=a(65660),d=a(20410),S=a(31540),u=a(53157),C=a(39424),m=a(27350),p=a(86640),h=a(96693),g=a(50793),x=a(83344),b=a(76311),y=a(27950),H=a(73071),f=a(9051),v=a(64504),I=a(56401),R=a(70908),D=a(17304),E=a(94445),j=a(67294),w=a(11841),T=a(91372),A=a(60948),k=a(1943),P=a(21097),L=a(54285),M=a(33546),F=a(34474),O=a(64267),B=a(10265),U=a(63317),J=a(10503),N=a(19171),W=a(67618),V=a(10002),_=a(13064),q=a(94788),z=a(30368),Y=a(47243),X=a(37053);let isEligibleForAutoEnrollment=e=>e===X._.FULL_MATCH||e===X._.ELIGIBLE_MATCH,getLeadStatus=e=>{switch(e){case X._.PERSON_MATCH:case X._.INSURANCE_MATCH:case X._.EXPIRED:case X._.NOT_FOUND:return I.rl.EligibleWaiting;case X._.FULL_MATCH:case X._.ELIGIBLE_MATCH:default:return}};(r=i||(i={})).CreateLead="createLead",r.CreateContact="createContact",r.UpdateContact="updateContact",r.DetermineContactOrLead="determineContactOrLead",r.FetchConsents="fetchConsents",r.UpdateEmail="updateEmail",r.CheckEligibility="checkEligibility",r.CheckBenefits="checkBenefits";let G={...V.a,...i},K=W.aU[B.kT.PequotHealthCare],Q={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insurance:void 0,lastName:"",phone:"",state:void 0,termsAgreement:!1,howDidYouFindUS:"",comorbidities:[],diabetes:"",bariatricSurgery:""},eligibilityCheckMatchType:void 0,bmi:void 0,benefitsCheck:void 0,otpData:void 0,consentsData:{items:[],userConsentStatus:[]},contactData:{},passwordData:{password:void 0,confirmPassword:void 0},flyteUserData:void 0,error:void 0},$={...U.OX,...U.cp,...U.sW,...U.Oz,...U.S8,...U.oQ,...U.q6,...U.nB,...U.v1,...(0,U.Ww)(Q).reset},Z=(0,q.cY)({types:{},guards:{isPreEligibilityMet:e=>{let{context:{formData:t,bmi:a}}=e;return _.Pq.pequotHealthCare({bmi:a,comorbidity:t.comorbidity,birthdate:t.birthdate})},isApplicationReviewRequired:e=>{let{context:{eligibilityCheckMatchType:t}}=e;return[B._q.EXPIRED,B._q.INSURANCE_MATCH,B._q.PERSON_MATCH,B._q.NOT_FOUND].includes(t)},isApplicationDetected:N.Q,isAthenaRecordCreated:J.w},actions:$}).createMachine({context:()=>Q,id:"pequotMachine",initial:G.PreEligibility,states:{[G.PreEligibility]:{id:G.PreEligibility,initial:G.Idle,states:{[G.Idle]:{on:{SUBMIT:{target:G.Submitting,actions:"updateFormData"}}},[G.Submitting]:{entry:"assignBMI",always:[{target:"#".concat(G.ContactDetails),guard:"isPreEligibilityMet"},{target:"#".concat(G.EligibilityUnmet)}]}}},[G.ContactDetails]:{id:G.ContactDetails,initial:G.Idle,states:{[G.Idle]:{on:{SUBMIT:{target:"#".concat(G.InsuranceDetails),actions:"updateFormData"}}}}},[G.InsuranceDetails]:{id:G.InsuranceDetails,initial:G.Idle,states:{[G.Idle]:{on:{BACK:{target:"#".concat(G.ContactDetails)},SUBMIT:{target:"#".concat(G.InsuranceDetailsReview),actions:"updateFormData"}}}}},[G.InsuranceDetailsReview]:{id:G.InsuranceDetailsReview,initial:G.Idle,states:{[G.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:G.Submitting}}},[G.Submitting]:{id:G.Submitting,initial:G.CheckEligibility,states:{[G.CheckEligibility]:{id:G.CheckEligibility,invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={...t,insurance:W.Er[B.kT.PequotHealthCare],benefitProgram:W.Q1[B.kT.PequotHealthCare]};return await (0,M.m)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:[{actions:(0,Y.a)({eligibilityCheckMatchType:e=>{let{event:t}=e;return t.output.data.matchType}}),target:"#".concat(G.CheckBenefits)}],onError:"#".concat(G.InsuranceDetailsReview,".").concat(G.Error)}},[G.CheckBenefits]:{id:G.CheckBenefits,invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={...t,payerCode:W.qK[B.PF["Pequot HealthCare"]]};return await (0,k.o)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:[{actions:(0,Y.a)({benefitsCheck:e=>{let{event:t}=e;return t.output.data}}),target:"#".concat(G.DetermineContactOrLead)}],onError:"#".concat(G.DetermineContactOrLead)}},[G.DetermineContactOrLead]:{id:G.DetermineContactOrLead,always:[{guard:"isApplicationReviewRequired",target:G.CreateLead},{target:G.CreateContact}]},[G.CreateContact]:{id:G.CreateContact,invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={...t.formData,...t.formData.insuranceMemberID&&{employmentVerificationCode:t.formData.insuranceMemberID},...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},eligibilityVerifiedBy:B.Vn.Evolve,company:K,insurance:W.KG[B.kT.PequotHealthCare],evolveOrganization:B.bV["Pequot Tribal Family Health Plan"],accountId:W.kS[B.kT.PequotHealthCare]};return await (0,L.rE)(a)}),input:e=>{let{context:t}=e;return t},onDone:{actions:"assignContactData",target:"#".concat(G.EmailVerification)},onError:[{guard:"isApplicationDetected",target:"#".concat(G.ApplicationDetected)},{target:"#".concat(G.InsuranceDetailsReview,".").concat(G.Error)}]}},[G.CreateLead]:{id:G.CreateLead,invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={...t.formData,...t.formData.insuranceMemberID&&{employmentVerificationCode:t.formData.insuranceMemberID},...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},eligibilityVerifiedBy:B.Vn.Evolve,company:K,insurance:W.KG[B.kT.PequotHealthCare],evolveOrganization:B.bV["Pequot Tribal Family Health Plan"],leadStatus:getLeadStatus(t.eligibilityCheckMatchType),automateEvolveEnrollment:isEligibleForAutoEnrollment(t.eligibilityCheckMatchType)};return await (0,O.$)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isApplicationReviewRequired",target:"#".concat(G.ApplicationReview)},{target:"#".concat(G.ApplicationComplete)}],onError:[{guard:"isApplicationDetected",target:"#".concat(G.ApplicationDetected)},{target:"#".concat(G.InsuranceDetailsReview,".").concat(G.Error)}]}}}},[G.Error]:{id:"".concat(G.InsuranceDetailsReview,".").concat(G.Error),on:{SUBMIT:{actions:["updateFormData","resetBenefitsCheck"],target:G.Submitting}}}}},[G.EmailVerification]:{id:G.EmailVerification,initial:G.Idle,states:{[G.Idle]:{id:"".concat(G.EmailVerification,".").concat(G.Idle),on:{SUBMIT:{actions:"assignOtpCode",target:G.Submitting},RESEND_EMAIL_VERIFICATION:{target:G.Idle,reenter:!0},UPDATE_EMAIL:{target:G.UpdateEmail}},invoke:{input:e=>{var t;let{context:a,event:r}=e;return{email:a.formData.email,firstName:a.formData.firstName,onSuccess:null==r?void 0:null===(t=r.data)||void 0===t?void 0:t.onSuccess}},src:(0,z.p4)(async e=>{let{input:t}=e,a={email:t.email,firstName:t.firstName},r=await (0,T.t)(a);return{token:r.data.token,onSuccess:t.onSuccess}}),onDone:{actions:[(0,Y.a)({otpData:e=>{let{context:t,event:a}=e;return{...t.otpData,token:a.output.token}}}),e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}]},onError:G.Error}},[G.Submitting]:{invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,token:t.otpData.token,otp:t.otpData.otp};return await (0,A.M)(a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(G.OnboardingChecklist),onError:G.Error}},[G.Error]:{on:{SUBMIT:{actions:"assignOtpCode",target:G.Submitting},RESEND_EMAIL_VERIFICATION:{target:G.Idle},UPDATE_EMAIL:{target:G.UpdateEmail}}},[G.UpdateEmail]:{initial:G.Idle,states:{[G.Idle]:{invoke:{input:e=>{let{context:t,event:a}=e;return{contactId:t.contactData.contactId,email:a.data.email,onSuccess:a.data.onSuccess}},src:(0,z.p4)(async e=>{let{input:t}=e,a={contactId:t.contactId,email:t.email};await (0,L.Tk)(a);let r={email:t.email,onSuccess:t.onSuccess};return r}),onDone:{actions:["assignNewEmail",e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}],target:"#".concat(G.EmailVerification,".").concat(G.Idle)},onError:G.Error}},[G.Error]:{on:{SUBMIT:{target:"#".concat(G.EmailVerification,".").concat(G.Idle)},RESEND_EMAIL_VERIFICATION:{target:"#".concat(G.EmailVerification,".").concat(G.Idle)},UPDATE_EMAIL:{target:G.Idle}}}}}}},[G.ReviewConsents]:{id:G.ReviewConsents,initial:G.FetchConsents,states:{[G.Idle]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:G.Submitting}}},[G.FetchConsents]:{invoke:{src:(0,z.p4)(async()=>await (0,P.J)()),onDone:{actions:"assignConsents",target:G.Idle},onError:G.Error}},[G.Submitting]:{invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={patientIdentifier:t.contactData.contactId,firstName:t.formData.firstName,lastName:t.formData.lastName,phone:t.formData.phone,email:t.formData.email,birthDate:t.formData.birthdate,state:t.formData.state,heightInInch:t.formData.heightInInch,heightInFeet:t.formData.heightInFoot,currentWeightInPounds:t.formData.currentWeightInPounds,evolveOrganization:B.bV["Pequot Tribal Family Health Plan"],consents:t.consentsData.userConsentStatus};return await (0,F.D)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{actions:"assignFlyteUserData",target:G.UpdateContact}],onError:"#".concat(G.OnboardingUserError)}},[G.UpdateContact]:{invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={contactId:t.contactData.contactId,evolvePatientID:t.flyteUserData.patientId};return await (0,L.Tk)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isAthenaRecordCreated",target:"#".concat(G.CreatePassword)},{target:"#".concat(G.OnboardingUserError)}],onError:"#".concat(G.OnboardingUserError)}},[G.Error]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:G.Submitting}}}}},[G.CreatePassword]:{id:G.CreatePassword,initial:G.Idle,states:{[G.Idle]:{on:{SUBMIT:{actions:"assignPasswordData",target:G.Submitting}}},[G.Submitting]:{invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,password:t.passwordData.password,confirmPassword:t.passwordData.confirmPassword};return await (0,w.x)(t.flyteUserData.verifyToken,a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(G.AppDownload),onError:{target:G.Error,actions:"assignError"}}},[G.Error]:{on:{SUBMIT:{actions:["resetError","assignPasswordData"],target:G.Submitting}}}}},[G.OnboardingChecklist]:{id:G.OnboardingChecklist,on:{SUBMIT:{target:"#".concat(G.ReviewConsents)}}},[G.AppDownload]:{id:G.AppDownload},[G.ApplicationReview]:{id:G.ApplicationReview},[G.OnboardingUserError]:{id:G.OnboardingUserError},[G.ApplicationComplete]:{id:G.ApplicationComplete},[G.ApplicationDetected]:{id:G.ApplicationDetected},[G.EligibilityUnmet]:{id:G.EligibilityUnmet,initial:G.Idle,states:{[G.Idle]:{on:{SUBMIT:{target:G.Submitting,actions:"updateFormData"}}},[G.Submitting]:{invoke:{src:(0,z.p4)(async e=>{let{input:t}=e,a={...t,company:K,leadStatus:B.rl.Ineligible,ineligibilityReason:B.ib.BMI,automateEvolveEnrollment:!1};return await (0,O.$)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:G.Success,onError:G.Error}},[G.Success]:{},[G.Error]:{on:{SUBMIT:{actions:"updateFormData",target:G.Submitting}}}}}},on:{RESET:{target:"#".concat(G.PreEligibility),actions:"reset"}}});var ee=a(56344);let et={[R.J.PreEligibility]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"Let's make sure you're eligible for the FlyteHealth program."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"To be eligible for the FlyteHealth program through your Pequot HealthCare benefits, you must meet specific age and Body Mass Index (BMI)* requirements."})]}),bmiEnrollmentDisclaimer:(0,n.jsx)(o.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. FlyteHealth providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the FlyteHealth program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[R.J.EligibilityUnmet]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Unfortunately, you are not eligible to join FlyteHealth at this time."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"The FlyteHealth program requires a minimum BMI of 27+ (plus one or more weight-related health conditions) or a BMI of 30+."})]})},[R.J.ContactDetails]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Congratulations! You're eligible for the FlyteHealth program"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"To help us match your information with your employer, tell us about yourself. Next, we'll ask about your Pequot Healthcare membership. Be sure to have your insurance card handy."})]})},[R.J.InsuranceDetails]:{title:(0,n.jsxs)(o.Text,{variant:"text-header-2XL",color:"text-secondary-negative",children:["One more thing:"," ",(0,n.jsx)(o.Text,{as:"span",variant:"text-header-2XL",color:"text-primary",children:"What's your Pequot HealthCare membership number?"})]})},[R.J.InsuranceDetailsReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{children:"Let's review: Is your info correct?"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Please double-check the information you provided to make sure everything is correct."})]})},[R.J.ApplicationComplete]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-secondary-negative",children:"Welcome aboard! We're so excited you're here."}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"Next, we need to confirm your email. Click the link we sent to:"})]}),description:(0,n.jsx)(o.Text,{mt:"spacer-8",color:"text-secondary",variant:"text-body-regular",children:"Can’t find the email? Make sure to check your Spam folder."})},[R.J.ApplicationReview]:{title:(0,n.jsxs)(o.TextPairing,{variant:"textpairing-header-2XL",children:[(0,n.jsx)(o.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,n.jsx)(o.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]})},[R.J.ApplicationDetected]:{title:(0,n.jsx)(o.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,n.jsx)(o.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[R.J.EmailVerification]:ee.T[R.J.EmailVerification],[R.J.OnboardingChecklist]:ee.T[R.J.OnboardingChecklist],[R.J.CreatePassword]:ee.T[R.J.CreatePassword],[R.J.AppDownload]:ee.T[R.J.AppDownload],[R.J.ReviewConsents]:ee.T[R.J.ReviewConsents]};var ea=a(58976);let er=[I.Op.BenefitsWebsite,I.Op.ProviderReferral,I.Op.WordOfMouth,I.Op.Other],ei={[R.J.ContactDetails]:{state:{options:ea.Fp},howDidYouFindUs:{options:er}},[R.J.InsuranceDetails]:{insuranceMemberID:{}},[R.J.InsuranceDetailsReview]:{insuranceMemberID:{}}},en=I.kT.PequotHealthCare,PequotWorkflow=e=>{let{render:t}=e,[a,r]=(0,E.eO)(Z),i=(0,j.useMemo)(()=>(0,D.k)(a.value),[a.value]);(0,v.R)(i,en);let w=(0,j.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),T=(0,j.useCallback)(()=>{r({type:"BACK"})},[r]),A=(0,j.useCallback)(()=>{switch(i){case G.PreEligibility:return(0,n.jsx)(H.b,{configuration:{contentResources:et[R.J.PreEligibility]},onSubmit:w});case G.ContactDetails:return(0,n.jsx)(C.q,{configuration:{contentResources:et[R.J.ContactDetails],fields:ei[R.J.ContactDetails]},onSubmit:w,defaultValues:a.context.formData});case G.EligibilityUnmet:return(0,n.jsx)(p.X,{configuration:{contentResources:et[R.J.EligibilityUnmet]},onSubmit:w,loading:a.matches({[G.EligibilityUnmet]:G.Submitting}),isEmailSent:a.matches({[G.EligibilityUnmet]:G.Success}),hasError:a.matches({[G.EligibilityUnmet]:G.Error})});case G.InsuranceDetails:return(0,n.jsx)(g.v,{configuration:{contentResources:et[R.J.InsuranceDetails],fields:ei[R.J.InsuranceDetails]},onSubmit:w,onBack:T});case G.InsuranceDetailsReview:return(0,n.jsx)(x.b,{configuration:{contentResources:et[R.J.InsuranceDetailsReview],fields:ei[R.J.InsuranceDetailsReview]},onSubmit:w,loading:a.matches({[G.InsuranceDetailsReview]:G.Submitting}),hasError:a.matches({[G.InsuranceDetailsReview]:G.Error}),defaultValues:a.context.formData});case G.ApplicationComplete:return(0,n.jsx)(l.J,{...et[R.J.ApplicationComplete],email:a.context.formData.email});case G.ApplicationReview:return(0,n.jsx)(d.G,{...et[R.J.ApplicationReview]});case G.ApplicationDetected:return(0,n.jsx)(c.v,{...et[R.J.ApplicationDetected],email:a.context.formData.email});case G.EmailVerification:return(0,n.jsx)(h.Z,{configuration:{contentResources:{title:et[R.J.EmailVerification](a.context.formData.email).title}},email:a.context.formData.email,hasError:a.matches({[G.EmailVerification]:G.Error}),loading:a.matches({[G.EmailVerification]:G.Submitting}),isUpdateEmailLoading:a.matches({[G.EmailVerification]:{[G.UpdateEmail]:G.Idle}}),hasUpdateEmailError:a.matches({[G.EmailVerification]:{[G.UpdateEmail]:G.Error}}),onSubmit:w,onResendCode:e=>r({type:"RESEND_EMAIL_VERIFICATION",data:{onSuccess:e}}),onEditEmail:(e,t)=>r({type:"UPDATE_EMAIL",data:{email:e,onSuccess:t}})});case G.OnboardingChecklist:return(0,n.jsx)(b.O,{configuration:{contentResources:et[R.J.OnboardingChecklist]},onSubmit:w});case G.ReviewConsents:return(0,n.jsx)(f.R,{configuration:{contentResources:et[R.J.ReviewConsents]},consents:a.context.consentsData.items,hasError:a.matches({[G.ReviewConsents]:G.Error}),loading:a.matches({[G.ReviewConsents]:G.FetchConsents})||a.matches({[G.ReviewConsents]:G.Submitting})||a.matches({[G.ReviewConsents]:G.UpdateContact}),onSubmit:w});case G.CreatePassword:return(0,n.jsx)(m.f,{configuration:{contentResources:et[R.J.CreatePassword]},loading:a.matches({[G.CreatePassword]:G.Submitting}),error:a.context.error,onSubmit:w});case G.AppDownload:return(0,n.jsx)(s.B,{title:et[R.J.AppDownload].title,checklist:et[R.J.AppDownload].checklist});case G.OnboardingUserError:return(0,n.jsx)(y._,{});default:return null}},[i,a]);return t({header:(0,n.jsxs)(n.Fragment,{children:[(0,n.jsxs)(o.Flex,{gap:"spacer-5",alignItems:"center",children:[(0,n.jsx)(S.E,{partner:I.kT.Flyte}),(0,n.jsx)(o.Divider,{orientation:"vertical",alignSelf:"stretch",height:"auto"}),(0,n.jsx)(S.E,{partner:en})]}),(0,n.jsx)(u.K,{currentStep:i})]}),body:A(),currentWorkFlowStep:i})}},84901:function(e,t,a){a.d(t,{u:function(){return PyleWorkflow}});var r,i=a(85893),n=a(71986),o=a(65660),s=a(20410),l=a(31540),c=a(53157),d=a(39424),S=a(86640),u=a(73071),C=a(64504),m=a(56401),p=a(70908),h=a(10002),g=a(17304),x=a(94445),b=a(67294),y=a(64267),H=a(10265),f=a(19171),v=a(67618),I=a(13064),R=a(94788),D=a(47243),E=a(30368);(r||(r={})).CreateLead="createLead";let j={...h.a,...r},w=v.aU[H.kT.PyleFamilyInsurance],T={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insurance:void 0,lastName:"",phone:"",state:void 0,termsAgreement:!1,howDidYouFindUS:"",comorbidities:[],diabetes:"",bariatricSurgery:""},bmi:void 0},A=(0,R.cY)({types:{},guards:{isPreEligibilityMet:e=>{let{context:{bmi:t}}=e;return I.Pq.pyleFamilyInsurance({bmi:t})},isApplicationDetected:f.Q},actions:{updateFormData:(0,D.a)({formData:e=>{let{context:t,event:a}=e;return{...t.formData,...a.data}}}),assignBMI:(0,D.a)({bmi:e=>{let{context:t}=e,{heightInFoot:a,heightInInch:r,highestWeightInPounds:i}=t.formData;return(0,I.V2)({heightFeet:(0,I.MC)(a),heightInches:(0,I.MC)(r),weightPounds:(0,I.MC)(i)})}}),reset:(0,D.a)({...T})}}).createMachine({context:()=>T,id:"pyleMachine",initial:j.PreEligibility,states:{[j.PreEligibility]:{id:j.PreEligibility,initial:j.Idle,states:{[j.Idle]:{on:{SUBMIT:{target:j.Submitting,actions:"updateFormData"}}},[j.Submitting]:{entry:"assignBMI",always:[{target:"#".concat(j.ContactDetails),guard:"isPreEligibilityMet"},{target:"#".concat(j.EligibilityUnmet)}]}}},[j.ContactDetails]:{id:j.ContactDetails,initial:j.Idle,states:{[j.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:j.Submitting}}},[j.Submitting]:{id:j.Submitting,initial:j.CreateLead,states:{[j.CreateLead]:{id:j.CreateLead,invoke:{src:(0,E.p4)(async e=>{let{input:t}=e,a={...t.formData,company:w,evolveOrganization:H.bV["A Duie Pyle"],leadStatus:H.rl.EligibleWaiting,automateEvolveEnrollment:!1};return await (0,y.$)(a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(j.ApplicationReview),onError:[{guard:"isApplicationDetected",target:"#".concat(j.ApplicationDetected)},{target:"#".concat(j.Error)}]}}}},[j.Error]:{id:j.Error,on:{SUBMIT:{actions:"updateFormData",target:j.Submitting}}}}},[j.ApplicationReview]:{id:j.ApplicationReview},[j.ApplicationDetected]:{id:j.ApplicationDetected},[j.EligibilityUnmet]:{id:j.EligibilityUnmet,initial:j.Idle,states:{[j.Idle]:{on:{SUBMIT:{target:j.Submitting,actions:"updateFormData"}}},[j.Submitting]:{invoke:{src:(0,E.p4)(async e=>{let{input:t}=e,a={...t,company:w,leadStatus:H.rl.Ineligible,ineligibilityReason:H.ib.BMI,automateEvolveEnrollment:!1};return await (0,y.$)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:j.Success,onError:j.Error}},[j.Success]:{},[j.Error]:{on:{SUBMIT:{target:j.Submitting}}}}}},on:{RESET:{target:"#".concat(j.PreEligibility),actions:"reset"}}});var k=a(56344);let P={[p.J.PreEligibility]:{title:(0,i.jsxs)(n.TextPairing,{variant:"textpairing-header-2XL",children:[(0,i.jsx)(n.TextPairing.Label,{color:"text-primary",children:"Let's make sure you're eligible for the FlyteHealth program."}),(0,i.jsx)(n.TextPairing.SubLabel,{color:"text-secondary",children:"To be eligible for the FlyteHealth program through your A-Duie Pyle benefits, you must meet specific age and Body Mass Index (BMI)* requirements."})]}),bmiEnrollmentDisclaimer:(0,i.jsx)(n.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. FlyteHealth providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the FlyteHealth program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[p.J.EligibilityUnmet]:{title:(0,i.jsxs)(n.TextPairing,{variant:"textpairing-header-2XL",children:[(0,i.jsx)(n.TextPairing.Label,{color:"text-secondary-negative",children:"Unfortunately, you are not eligible to join FlyteHealth at this time."}),(0,i.jsx)(n.TextPairing.SubLabel,{color:"text-secondary",children:"The FlyteHealth program requires a minimum BMI of 27+ (plus one or more weight-related health conditions) or a BMI of 30+."})]})},[p.J.ContactDetails]:{title:(0,i.jsxs)(n.TextPairing,{variant:"textpairing-header-2XL",children:[(0,i.jsx)(n.TextPairing.Label,{color:"text-secondary-negative",children:"Congratulations! You're eligible for the FlyteHealth program"}),(0,i.jsx)(n.TextPairing.SubLabel,{color:"text-secondary",children:"To help us match your information with your employer, tell us about yourself."})]})},[p.J.ApplicationReview]:{title:(0,i.jsxs)(n.TextPairing,{variant:"textpairing-header-2XL",children:[(0,i.jsx)(n.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,i.jsx)(n.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]}),note:(0,i.jsx)(n.Text,{variant:"text-body-large-regular",color:"text-secondary",children:"There is a one-time $235 FlyteHealth program fee for eligible employees collected during scheduling. A portion of this fee ($150) will be reimbursed by A-Duie Pyle upon confirmation of eligibility and program start. Please contact Pyle HR for instructions on how to obtain this reimbursement."})},[p.J.ApplicationDetected]:{title:(0,i.jsx)(n.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,i.jsx)(n.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[p.J.OnboardingChecklist]:k.T[p.J.OnboardingChecklist],[p.J.CreatePassword]:k.T[p.J.CreatePassword],[p.J.AppDownload]:k.T[p.J.AppDownload],[p.J.ReviewConsents]:k.T[p.J.ReviewConsents]};var L=a(58976);let M=[m.Op.BenefitsWebsite,m.Op.CoworkerReferral,m.Op.ProviderReferral,m.Op.WordOfMouth,m.Op.Other],F={[p.J.ContactDetails]:{state:{options:L.Fp},howDidYouFindUs:{options:M}}},O=new Map([[p.J.PreEligibility,c.t.get(p.J.PreEligibility)],[p.J.ContactDetails,c.t.get(p.J.ContactDetails)]]),B=m.kT.PyleFamilyInsurance,PyleWorkflow=e=>{let{render:t}=e,[a,r]=(0,x.eO)(A),y=(0,b.useMemo)(()=>(0,g.k)(a.value),[a.value]);(0,C.R)(y,B);let H=(0,b.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),f=(0,b.useCallback)(()=>{switch(y){case h.a.PreEligibility:return(0,i.jsx)(u.b,{configuration:{contentResources:P[p.J.PreEligibility]},onSubmit:H});case h.a.ContactDetails:return(0,i.jsx)(d.q,{configuration:{contentResources:P[p.J.ContactDetails],fields:F[p.J.ContactDetails]},loading:a.matches({[h.a.ContactDetails]:h.a.Submitting}),onSubmit:H,defaultValues:a.context.formData});case h.a.EligibilityUnmet:return(0,i.jsx)(S.X,{configuration:{contentResources:P[p.J.EligibilityUnmet]},onSubmit:H,loading:a.matches({[h.a.EligibilityUnmet]:h.a.Submitting}),isEmailSent:a.matches({[h.a.EligibilityUnmet]:h.a.Success}),hasError:a.matches({[h.a.EligibilityUnmet]:h.a.Error})});case h.a.ApplicationReview:return(0,i.jsx)(s.G,{...P[p.J.ApplicationReview]});case h.a.ApplicationDetected:return(0,i.jsx)(o.v,{...P[p.J.ApplicationDetected],email:a.context.formData.email});default:return null}},[y,a]);return t({header:(0,i.jsxs)(i.Fragment,{children:[(0,i.jsxs)(n.Flex,{gap:"spacer-5",alignItems:"center",children:[(0,i.jsx)(l.E,{partner:m.kT.Flyte}),(0,i.jsx)(n.Divider,{orientation:"vertical",alignSelf:"stretch",height:"auto"}),(0,i.jsx)(l.E,{partner:B})]}),(0,i.jsx)(c.K,{currentStep:y,steps:O})]}),body:f(),currentWorkFlowStep:y})}},16428:function(e,t,a){a.d(t,{l:function(){return RiverspringWorkflow}});var r,i,n,o,s=a(85893),l=a(71986),c=a(44761),d=a(33640),S=a(65660),u=a(20410),C=a(31540),m=a(53157),p=a(39424),h=a(27350),g=a(96693),x=a(83344),b=a(76311),y=a(27950),H=a(73071),f=a(9051),v=a(64504),I=a(56401),R=a(70908),D=a(43356),E=a(17304),j=a(94445),w=a(67294),T=a(58976),A=a(73857),k=a(97324),P=a(84862),L=a(87536);let M="participantDepartmentorOrg",F=["Hebrew Home at Riverdale","RiverSpring Services Corp","RiverSpring Licensed Home Care Services Agency","RiverSpring Health Plans (ElderServe Health, Inc.)"],ParticipantDepartmentSelector=()=>{let{register:e,watch:t}=(0,L.Gc)();return(0,s.jsxs)(l.Flex,{direction:"column",gap:"spacer-2",children:[(0,s.jsx)(l.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",htmlFor:M,children:"Participating organization"}),(0,s.jsx)(l.Select,{"data-test":M,id:M,size:"l",variant:"flushed",placeholder:"Select organization",...e(M,{required:!0}),value:t(M),children:F.map(e=>(0,s.jsx)("option",{value:e,children:e},e))})]})};var O=a(41240);let B="evolveProgram";(r=n||(n={})).Guided="Guided",r.SelfGuided="Self-Guided";let ProgramField=()=>{let{register:e}=(0,L.Gc)();return(0,s.jsxs)(l.Flex,{direction:"column",gap:"spacer-4",children:[(0,s.jsx)(l.Text,{as:"label",variant:"text-body-large-bold",color:"text-primary-negative",children:"Program selection"}),(0,s.jsxs)(l.RadioGroup,{display:"flex",gap:"spacer-3",name:B,flexDirection:{base:"column",md:"row"},"data-test":B,children:[(0,s.jsx)(O.D,{value:"Guided",size:"m",name:B,...e(B,{required:!0}),children:"Physician-guided"}),(0,s.jsx)(O.D,{value:"Self-Guided",size:"m",...e(B),name:B,children:"Self-guided"})]})]})},RiverspringInsuranceDetailsForm=e=>{let{configuration:t,loading:a=!1,onSubmit:r,onBack:i}=e,{contentResources:n,fields:o}=t,c=(0,L.cI)({mode:"onBlur",defaultValues:{insuranceMemberID:"",insurance:void 0,evolveProgram:void 0}}),d=(0,P.d)(),renderFormActions=()=>(0,s.jsxs)(l.Flex,{gap:{base:"spacer-8",md:"spacer-16"},alignItems:"center",flex:{base:1,lg:"unset"},children:[(0,s.jsx)(l.Button,{size:{base:"m",lg:"l"},isLoading:a,variant:"link","aria-label":"Back",leadingIcon:(0,s.jsx)(l.IconArrowLeft,{}),onClick:i,children:"Back"}),(0,s.jsx)(l.Button,{type:"submit",size:{base:"m",lg:"l"},isDisabled:!c.formState.isValid,flex:1,isLoading:a,trailingIcon:(0,s.jsx)(l.IconArrowRight,{}),"aria-label":"Continue",children:"Continue"})]});return(0,s.jsx)(L.RV,{...c,children:(0,s.jsxs)(A.S,{as:"form",onSubmit:c.handleSubmit(r),noValidate:!0,children:[(0,s.jsx)(A.S.Side,{gap:0,flex:{base:"none",lg:1},children:n.title}),(0,s.jsxs)(A.S.Form,{children:[(null==o?void 0:o.evolveProgram)&&(0,s.jsx)(ProgramField,{}),(0,s.jsx)(ParticipantDepartmentSelector,{}),(null==o?void 0:o.insurance)&&(0,s.jsx)(k.vu,{isDisabled:a,isRequired:!0,...null==o?void 0:o.insurance}),(0,s.jsx)(k.nB,{isDisabled:a,isRequired:!0,pb:{base:"spacer-24",lg:0},...null==o?void 0:o.insuranceMemberID}),d?(0,s.jsx)(T.D2,{children:renderFormActions()}):renderFormActions()]})]})})};var U=a(11841),J=a(91372),N=a(60948),W=a(1943),V=a(21097),_=a(54285),q=a(34474),z=a(64267),Y=a(10265),X=a(63317),G=a(10503),K=a(19171),Q=a(67618),$=a(10002),Z=a(94788),ee=a(47243),et=a(30368);let ea={Guided:I.bV["RiverSpring Living - Guided"],"Self-Guided":I.bV["RiverSpring Living - Self Guided"]},isEligibleForAutoEnrollment=(e,t,a)=>{if(a===I.bV["RiverSpring Living - Self Guided"])return!0;switch(e){case I.PF["1199SEIU"]:return!0;case I.PF.Aetna:return[I.i$["New York"],I.i$["New Jersey"],I.i$.Connecticut].includes(t);default:return!1}},getLeadStatus=(e,t,a)=>{if(!isEligibleForAutoEnrollment(e,t,a))return I.rl.EligibleWaiting};(i=o||(o={})).CreateLead="createLead",i.CreateContact="createContact",i.UpdateContact="updateContact",i.CheckBenefits="checkBenefits",i.DetermineContactOrLead="determineContactOrLead",i.FetchConsents="fetchConsents",i.UpdateEmail="updateEmail";let er={...$.a,...o},ei=Q.aU[Y.kT.RiverSpringLiving],en={formData:{birthdate:"",comorbidity:"",currentWeightInPounds:"",dateOfHighestWeightValue:"",email:"",firstName:"",heightInFoot:"",heightInInch:"",highestWeightInPounds:"",insuranceCoverage:void 0,insuranceMemberID:"",insurance:void 0,lastName:"",phone:"",state:void 0,termsAgreement:!1,howDidYouFindUS:"",participantDepartmentorOrg:"",evolveProgram:void 0,comorbidities:[],diabetes:"",bariatricSurgery:""},evolveOrganization:void 0,bmi:void 0,benefitsCheck:void 0,otpData:void 0,consentsData:{items:[],userConsentStatus:[]},contactData:{},passwordData:{password:void 0,confirmPassword:void 0},flyteUserData:void 0,error:void 0},eo={...X.OX,...X.cp,...X.sW,...X.Oz,...X.S8,...X.oQ,...X.q6,...X.nB,...X.v1,...(0,X.Ww)(en)},es=(0,Z.cY)({types:{},guards:{isApplicationReviewRequired:e=>{let{context:{formData:t,evolveOrganization:a}}=e;return!isEligibleForAutoEnrollment(t.insurance,t.state,a)},isApplicationDetected:K.Q,isAthenaRecordCreated:G.w},actions:{...eo,assignEvolveOrganization:(0,ee.a)({evolveOrganization:e=>{let{context:t}=e;return ea[t.formData.evolveProgram||n.SelfGuided]}})}}).createMachine({context:()=>en,id:"riverspringMachine",initial:er.PreEligibility,states:{[er.PreEligibility]:{id:er.PreEligibility,initial:er.Idle,states:{[er.Idle]:{on:{SUBMIT:{target:er.Submitting,actions:"updateFormData"}}},[er.Submitting]:{entry:["assignBMI"],always:"#".concat(er.ContactDetails)}}},[er.ContactDetails]:{id:er.ContactDetails,initial:er.Idle,states:{[er.Idle]:{on:{SUBMIT:{target:"#".concat(er.InsuranceDetails),actions:"updateFormData"}}}}},[er.InsuranceDetails]:{id:er.InsuranceDetails,initial:er.Idle,states:{[er.Idle]:{on:{BACK:{target:"#".concat(er.ContactDetails)},SUBMIT:{target:"#".concat(er.InsuranceDetailsReview),actions:["updateFormData","assignEvolveOrganization"]}}}}},[er.InsuranceDetailsReview]:{id:er.InsuranceDetailsReview,initial:er.Idle,states:{[er.Idle]:{on:{SUBMIT:{actions:"updateFormData",target:er.Submitting}}},[er.Submitting]:{initial:er.CheckBenefits,states:{[er.CheckBenefits]:{id:er.CheckBenefits,invoke:{src:(0,et.p4)(async e=>{let{input:t}=e,a={...t,payerCode:Q.qK[t.insurance]};return await (0,W.o)(a)}),input:e=>{let{context:{formData:t}}=e;return t},onDone:[{actions:(0,ee.a)({benefitsCheck:e=>{let{event:t}=e;return t.output.data}}),target:"#".concat(er.DetermineContactOrLead)}],onError:"#".concat(er.DetermineContactOrLead)}},[er.DetermineContactOrLead]:{id:er.DetermineContactOrLead,always:[{guard:"isApplicationReviewRequired",target:er.CreateLead},{target:er.CreateContact}]},[er.CreateLead]:{id:er.CreateLead,invoke:{src:(0,et.p4)(async e=>{let{input:t}=e,a={...t.formData,evolveOrganization:t.evolveOrganization,...t.formData.insuranceMemberID&&{employmentVerificationCode:t.formData.insuranceMemberID},...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},company:ei,leadStatus:getLeadStatus(t.formData.insurance,t.formData.state,t.evolveOrganization),automateEvolveEnrollment:isEligibleForAutoEnrollment(t.formData.insurance,t.formData.state,t.evolveOrganization),evolveProgram:t.formData.evolveProgram||n.SelfGuided};return await (0,z.$)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isApplicationReviewRequired",target:"#".concat(er.ApplicationReview)},{target:"#".concat(er.ApplicationComplete)}],onError:[{guard:"isApplicationDetected",target:"#".concat(er.ApplicationDetected)},{target:"#".concat(er.InsuranceDetailsReview,".").concat(er.Error)}]}},[er.CreateContact]:{id:er.CreateContact,invoke:{src:(0,et.p4)(async e=>{let{input:t}=e,a={...t.formData,evolveOrganization:t.evolveOrganization,...t.formData.insuranceMemberID&&{employmentVerificationCode:t.formData.insuranceMemberID},...t.benefitsCheck&&{benefitsCheck:t.benefitsCheck},company:ei,accountId:Q.kS[Y.kT.RiverSpringLiving],evolveProgram:t.formData.evolveProgram||n.SelfGuided,eligibilityVerifiedBy:Y.Vn.Pverify};return await (0,_.rE)(a)}),input:e=>{let{context:t}=e;return t},onDone:{actions:"assignContactData",target:"#".concat(er.EmailVerification)},onError:[{guard:"isApplicationDetected",target:"#".concat(er.ApplicationDetected)},{target:"#".concat(er.InsuranceDetailsReview,".").concat(er.Error)}]}}}},[er.Error]:{id:"".concat(er.InsuranceDetailsReview,".").concat(er.Error),on:{SUBMIT:{actions:["updateFormData","resetBenefitsCheck"],target:er.Submitting}}}}},[er.EmailVerification]:{id:er.EmailVerification,initial:er.Idle,states:{[er.Idle]:{id:"".concat(er.EmailVerification,".").concat(er.Idle),on:{SUBMIT:{actions:"assignOtpCode",target:er.Submitting},RESEND_EMAIL_VERIFICATION:{target:er.Idle,reenter:!0},UPDATE_EMAIL:{target:er.UpdateEmail}},invoke:{input:e=>{var t;let{context:a,event:r}=e;return{email:a.formData.email,firstName:a.formData.firstName,onSuccess:null==r?void 0:null===(t=r.data)||void 0===t?void 0:t.onSuccess}},src:(0,et.p4)(async e=>{let{input:t}=e,a={email:t.email,firstName:t.firstName},r=await (0,J.t)(a);return{token:r.data.token,onSuccess:t.onSuccess}}),onDone:{actions:[(0,ee.a)({otpData:e=>{let{context:t,event:a}=e;return{...t.otpData,token:a.output.token}}}),e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}]},onError:er.Error}},[er.Submitting]:{invoke:{src:(0,et.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,token:t.otpData.token,otp:t.otpData.otp};return await (0,N.M)(a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(er.OnboardingChecklist),onError:er.Error}},[er.Error]:{on:{SUBMIT:{actions:"assignOtpCode",target:er.Submitting},RESEND_EMAIL_VERIFICATION:{target:er.Idle},UPDATE_EMAIL:{target:er.UpdateEmail}}},[er.UpdateEmail]:{initial:er.Idle,states:{[er.Idle]:{invoke:{input:e=>{let{context:t,event:a}=e;return{contactId:t.contactData.contactId,email:a.data.email,onSuccess:a.data.onSuccess}},src:(0,et.p4)(async e=>{let{input:t}=e,a={contactId:t.contactId,email:t.email};await (0,_.Tk)(a);let r={email:t.email,onSuccess:t.onSuccess};return r}),onDone:{actions:["assignNewEmail",e=>{var t;let{event:a}=e;(null==a?void 0:null===(t=a.output)||void 0===t?void 0:t.onSuccess)&&a.output.onSuccess()}],target:"#".concat(er.EmailVerification,".").concat(er.Idle)},onError:er.Error}},[er.Error]:{on:{SUBMIT:{target:"#".concat(er.EmailVerification,".").concat(er.Idle)},RESEND_EMAIL_VERIFICATION:{target:"#".concat(er.EmailVerification,".").concat(er.Idle)},UPDATE_EMAIL:{target:er.Idle}}}}}}},[er.ReviewConsents]:{id:er.ReviewConsents,initial:er.FetchConsents,states:{[er.Idle]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:er.Submitting}}},[er.FetchConsents]:{invoke:{src:(0,et.p4)(async()=>await (0,V.J)()),onDone:{actions:"assignConsents",target:er.Idle},onError:er.Error}},[er.Submitting]:{invoke:{src:(0,et.p4)(async e=>{let{input:t}=e,a={patientIdentifier:t.contactData.contactId,firstName:t.formData.firstName,lastName:t.formData.lastName,phone:t.formData.phone,email:t.formData.email,birthDate:t.formData.birthdate,state:t.formData.state,heightInInch:t.formData.heightInInch,heightInFeet:t.formData.heightInFoot,currentWeightInPounds:t.formData.currentWeightInPounds,evolveOrganization:t.evolveOrganization,consents:t.consentsData.userConsentStatus};return await (0,q.D)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{actions:"assignFlyteUserData",target:er.UpdateContact}],onError:"#".concat(er.OnboardingUserError)}},[er.UpdateContact]:{invoke:{src:(0,et.p4)(async e=>{let{input:t}=e,a={contactId:t.contactData.contactId,evolvePatientID:t.flyteUserData.patientId};return await (0,_.Tk)(a)}),input:e=>{let{context:t}=e;return t},onDone:[{guard:"isAthenaRecordCreated",target:"#".concat(er.CreatePassword)},{target:"#".concat(er.OnboardingUserError)}],onError:"#".concat(er.OnboardingUserError)}},[er.Error]:{on:{SUBMIT:{actions:["assignUserConsentStatus"],target:er.Submitting}}}}},[er.CreatePassword]:{id:er.CreatePassword,initial:er.Idle,states:{[er.Idle]:{on:{SUBMIT:{actions:"assignPasswordData",target:er.Submitting}}},[er.Submitting]:{invoke:{src:(0,et.p4)(async e=>{let{input:t}=e,a={email:t.formData.email,password:t.passwordData.password,confirmPassword:t.passwordData.confirmPassword};return await (0,U.x)(t.flyteUserData.verifyToken,a)}),input:e=>{let{context:t}=e;return t},onDone:"#".concat(er.AppDownload),onError:{target:er.Error,actions:"assignError"}}},[er.Error]:{on:{SUBMIT:{actions:["resetError","assignPasswordData"],target:er.Submitting}}}}},[er.OnboardingChecklist]:{id:er.OnboardingChecklist,on:{SUBMIT:{target:"#".concat(er.ReviewConsents)}}},[er.AppDownload]:{id:er.AppDownload},[er.ApplicationReview]:{id:er.ApplicationReview},[er.OnboardingUserError]:{id:er.OnboardingUserError},[er.ApplicationComplete]:{id:er.ApplicationComplete},[er.ApplicationDetected]:{id:er.ApplicationDetected}},on:{RESET:{target:"#".concat(er.PreEligibility),actions:"reset"}}});var el=a(56344);let ec={[R.J.PreEligibility]:{title:(0,s.jsxs)(l.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(l.TextPairing.Label,{color:"text-primary",children:"Let's make sure you're eligible for the FlyteHealth program."}),(0,s.jsxs)(l.TextPairing.SubLabel,{color:"text-secondary",children:["All employees are eligible to access the"," ",(0,s.jsx)("b",{children:"Self-Guided"})," ","program through the RiverSpring Living benefits.",(0,s.jsx)("br",{}),"To be eligible for the"," ",(0,s.jsx)("b",{children:"Physician-Guided"})," ","program, you must meet specific age and Body Mass Index (BMI)* requirements."]})]}),bmiEnrollmentDisclaimer:(0,s.jsx)(l.Text,{variant:"text-body-meta-regular",color:"text-secondary",children:"*We acknowledge that Body Mass Index (BMI) is an imperfect way to screen for excess weight. FlyteHealth providers do not use BMI alone as a measure of overall health. Instead, BMI is used as a data point to see if someone is eligible to join the FlyteHealth program. Once someone joins the program, we'll ask each person more about their health to create a personalized treatment plan."})},[R.J.ContactDetails]:(e,t)=>({title:(0,s.jsxs)(l.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsxs)(l.TextPairing.Label,{color:"text-primary",children:[(0,s.jsxs)(l.Text,{display:{base:"inline",lg:"block"},as:"label",variant:"text-header-2XL",color:"text-secondary-negative",children:["Congratulations!"," "]}),"You're eligible for the"," ",D.P.riverSpringLiving({bmi:e,comorbidity:t})?"Physician":"Self","-Guided FlyteHealth program"]}),(0,s.jsx)(l.TextPairing.SubLabel,{color:"text-secondary",children:"To help us match your information with your employer, please tell us a bit more about yourself."})]})}),[R.J.InsuranceDetails]:{title:(0,s.jsxs)(l.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsxs)(l.TextPairing.Label,{color:"text-secondary-negative",children:["Almost done:"," ",(0,s.jsx)(l.Text,{as:"span",variant:"text-header-2XL",color:"text-primary",children:"Select your program and let us know if you have health insurance"})]}),(0,s.jsxs)(l.TextPairing.SubLabel,{color:"text-secondary",children:["Before selecting your program, review summaries below."," ",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),(0,s.jsx)("b",{children:"Physician-Guided:"})," ","Access to the entire FlyteHealth care team and our patient app.",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),(0,s.jsx)("b",{children:"Self-Guided:"})," ","Access to the FlyteHealth patient app only."]})]})},[R.J.InsuranceDetailsReview]:{title:(0,s.jsxs)(l.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(l.TextPairing.Label,{children:"Let's review: Is your info correct?"}),(0,s.jsx)(l.TextPairing.SubLabel,{color:"text-secondary",children:"Please double-check the information you provided to make sure everything is correct."})]})},[R.J.ApplicationComplete]:{title:(0,s.jsxs)(l.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(l.TextPairing.Label,{color:"text-secondary-negative",children:"Welcome aboard! We're so excited you're here."}),(0,s.jsx)(l.TextPairing.SubLabel,{color:"text-secondary",children:"Next, we need to confirm your email. Click the link we sent to:"})]}),description:(0,s.jsxs)(l.Text,{color:"text-secondary",mt:"spacer-8",variant:"text-body-meta-regular",children:["Please note that for Physician-Guided users, clinical encounters and prescription costs are covered by RiverSpring Living insurance (either Aetna or 1199SEIU), and out-of-pocket costs will vary based on your plan coverage, deductibles, co-pays, and limits. For more information, please contact the RiverSpring Living Benefits Department or your insurance company.",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"If you don't have RiverSpring Living insurance, FlyteHealth also accepts a number of other plans. Please check with a FlyteHealth Patient Coordinator about whether your insurance is accepted.",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"For Self-Guided users, there is no cost for RiverSpring Living employees."]})},[R.J.ApplicationReview]:{title:(0,s.jsxs)(l.TextPairing,{variant:"textpairing-header-2XL",children:[(0,s.jsx)(l.TextPairing.Label,{color:"text-primary",children:"You're almost finished!"}),(0,s.jsx)(l.TextPairing.SubLabel,{color:"text-secondary",children:"We've received your application, but we need a little more information from you to move forward. Please call us to complete the application process."})]}),note:(0,s.jsxs)(l.Text,{color:"text-secondary",variant:"text-body-meta-regular",children:["Please note that for Guided users, clinical encounters and prescription costs are covered by RiverSpring Living insurance (either Aetna or 1199SEIU), and out-of-pocket costs will vary based on your plan coverage, deductibles, co-pays, and limits. For more information, please contact the RiverSpring Living Benefits Department or your insurance company."," ",(0,s.jsx)("br",{}),(0,s.jsx)("br",{}),"If you don't have RiverSpring Living insurance, FlyteHealth also accepts a number of other plans. Please check with a FlyteHealth Patient Coordinator about whether your insurance is accepted."]})},[R.J.ApplicationDetected]:{title:(0,s.jsx)(l.Text,{variant:"text-header-2XL",color:"text-primary",children:"We found an existing account for:"}),description:(0,s.jsx)(l.Text,{variant:"text-body-display-S",color:"text-secondary",children:"It looks like you already have an account with us. To continue or update your registration details, please contact our Care Coordinator team."})},[R.J.EmailVerification]:el.T[R.J.EmailVerification],[R.J.OnboardingChecklist]:el.T[R.J.OnboardingChecklist],[R.J.CreatePassword]:el.T[R.J.CreatePassword],[R.J.AppDownload]:el.T[R.J.AppDownload],[R.J.ReviewConsents]:el.T[R.J.ReviewConsents]},ed=[I.Op.BenefitsWebsite,I.Op.CoworkerReferral,I.Op.OnsiteMonitor,I.Op.Poster,I.Op.ProviderReferral,I.Op.WordOfMouth,I.Op.Other],eS={[R.J.ContactDetails]:{state:{options:T.Fp},howDidYouFindUs:{options:ed}},[R.J.InsuranceDetails]:e=>({insurance:{insuranceCarriers:[I.PF.Aetna,I.PF["1199SEIU"]]},insuranceMemberID:{},evolveProgram:e?{}:void 0}),[R.J.InsuranceDetailsReview]:{insurance:{insuranceCarriers:[I.PF.Aetna,I.PF["1199SEIU"]]}}},eu=I.kT.RiverSpringLiving,RiverspringWorkflow=e=>{let{render:t}=e,[a,r]=(0,j.eO)(es),i=(0,w.useMemo)(()=>(0,E.k)(a.value),[a.value]);(0,v.R)(i,eu);let n=(0,w.useCallback)(e=>{r({type:"SUBMIT",data:e})},[r]),o=(0,w.useCallback)(()=>{r({type:"BACK"})},[r]),T=(0,w.useCallback)(()=>{switch(i){case er.PreEligibility:return(0,s.jsx)(H.b,{configuration:{contentResources:ec[R.J.PreEligibility]},onSubmit:n});case er.ContactDetails:return(0,s.jsx)(p.q,{configuration:{contentResources:ec[R.J.ContactDetails](a.context.bmi,a.context.formData.comorbidity),fields:eS[R.J.ContactDetails]},onSubmit:n,defaultValues:a.context.formData});case er.InsuranceDetails:return(0,s.jsx)(RiverspringInsuranceDetailsForm,{configuration:{contentResources:ec[R.J.InsuranceDetails],fields:eS[R.J.InsuranceDetails](D.P.riverSpringLiving({bmi:a.context.bmi}))},onSubmit:n,onBack:o});case er.InsuranceDetailsReview:return(0,s.jsx)(x.b,{configuration:{contentResources:ec[R.J.InsuranceDetailsReview],fields:eS[R.J.InsuranceDetailsReview]},onSubmit:n,loading:a.matches({[er.InsuranceDetailsReview]:er.Submitting}),hasError:a.matches({[er.InsuranceDetailsReview]:er.Error}),defaultValues:a.context.formData});case er.ApplicationComplete:return(0,s.jsx)(d.J,{...ec[R.J.ApplicationComplete],email:a.context.formData.email});case er.ApplicationReview:return(0,s.jsx)(u.G,{...ec[R.J.ApplicationReview]});case er.ApplicationDetected:return(0,s.jsx)(S.v,{...ec[R.J.ApplicationDetected],email:a.context.formData.email});case er.EmailVerification:return(0,s.jsx)(g.Z,{configuration:{contentResources:{title:ec[R.J.EmailVerification](a.context.formData.email).title}},email:a.context.formData.email,hasError:a.matches({[er.EmailVerification]:er.Error}),loading:a.matches({[er.EmailVerification]:er.Submitting}),isUpdateEmailLoading:a.matches({[er.EmailVerification]:{[er.UpdateEmail]:er.Idle}}),hasUpdateEmailError:a.matches({[er.EmailVerification]:{[er.UpdateEmail]:er.Error}}),onSubmit:n,onResendCode:e=>r({type:"RESEND_EMAIL_VERIFICATION",data:{onSuccess:e}}),onEditEmail:(e,t)=>r({type:"UPDATE_EMAIL",data:{email:e,onSuccess:t}})});case er.OnboardingChecklist:return(0,s.jsx)(b.O,{configuration:{contentResources:ec[R.J.OnboardingChecklist]},onSubmit:n});case er.ReviewConsents:return(0,s.jsx)(f.R,{configuration:{contentResources:ec[R.J.ReviewConsents]},consents:a.context.consentsData.items,hasError:a.matches({[er.ReviewConsents]:er.Error}),loading:a.matches({[er.ReviewConsents]:er.FetchConsents})||a.matches({[er.ReviewConsents]:er.Submitting})||a.matches({[er.ReviewConsents]:er.UpdateContact}),onSubmit:n});case er.CreatePassword:return(0,s.jsx)(h.f,{configuration:{contentResources:ec[R.J.CreatePassword]},loading:a.matches({[er.CreatePassword]:er.Submitting}),error:a.context.error,onSubmit:n});case er.AppDownload:return(0,s.jsx)(c.B,{title:ec[R.J.AppDownload].title,checklist:ec[R.J.AppDownload].checklist});case er.OnboardingUserError:return(0,s.jsx)(y._,{});default:return null}},[i,a]);return t({header:(0,s.jsxs)(s.Fragment,{children:[(0,s.jsxs)(l.Flex,{gap:"spacer-5",alignItems:"center",children:[(0,s.jsx)(C.E,{partner:I.kT.Flyte}),(0,s.jsx)(l.Divider,{orientation:"vertical",alignSelf:"stretch",height:"auto"}),(0,s.jsx)(C.E,{partner:eu})]}),(0,s.jsx)(m.K,{currentStep:i})]}),body:T(),currentWorkFlowStep:i})}},63317:function(e,t,a){a.d(t,{cp:function(){return s},Oz:function(){return c},S8:function(){return d},Ww:function(){return createResetActions},q6:function(){return u},nB:function(){return C},OX:function(){return o},Kj:function(){return n},sW:function(){return l},oQ:function(){return S},v1:function(){return m}});var r=a(13064),i=a(47243);let n={assignLabLocation:(0,i.a)({labLocation:e=>{let{event:t}=e;return t.data}}),assignLabsSkipped:(0,i.a)({labs:"SUBMIT_LATER"}),registerLabsUploaded:(0,i.a)({labs:"LABS_UPLOADED"})},o={updateFormData:(0,i.a)({formData:e=>{let{context:t,event:a}=e;return{...t.formData,...a.data}}})},s={assignBMI:(0,i.a)({bmi:e=>{let{context:t}=e,{heightInFoot:a,heightInInch:i,highestWeightInPounds:n}=t.formData;return(0,r.V2)({heightFeet:(0,r.MC)(a),heightInches:(0,r.MC)(i),weightPounds:(0,r.MC)(n)})}})},l={assignOtpCode:(0,i.a)({otpData:e=>{let{context:t,event:a}=e;return{...t.otpData,otp:a.data.verificationCode}}})},c={assignConsents:(0,i.a)({consentsData:e=>{let{context:t,event:a}=e;return{...t.consentsData,items:a.output.data}}}),assignUserConsentStatus:(0,i.a)({consentsData:e=>{let{context:t,event:a}=e;return{...t.consentsData,userConsentStatus:Object.entries(a.data).map(e=>{let[t,a]=e;return{formType:t,isAccepted:a}})}}})},d={assignContactData:(0,i.a)({contactData:e=>{var t;let{context:a,event:r}=e;return{...a.contactData,contactId:null===(t=r.output)||void 0===t?void 0:t.contactId}}})},S={assignPasswordData:(0,i.a)({passwordData:e=>{let{context:t,event:a}=e;return{...t.passwordData,...a.data}}})},u={assignNewEmail:(0,i.a)({formData:e=>{let{context:t,event:a}=e;return{...t.formData,email:a.output.email}}})},C={assignError:(0,i.a)({error:e=>{var t,a,r;let{event:i}=e,n=(null==i?void 0:null===(r=i.error)||void 0===r?void 0:null===(a=r.response)||void 0===a?void 0:null===(t=a.data)||void 0===t?void 0:t.code)==="PASSWORD_PWNED"?"This password has been exposed in previous data breaches by an unrelated party. To keep your account secure, please choose a different, unique password.":"There was an error submitting. Please try again.";return{message:n}}}),resetError:(0,i.a)({error:void 0})},createResetActions=e=>({reset:(0,i.a)(e),resetBenefitsCheck:(0,i.a)({benefitsCheck:void 0})}),m={assignFlyteUserData:(0,i.a)({flyteUserData:e=>{let{event:t}=e;return t.output.data}})}},19171:function(e,t,a){a.d(t,{Q:function(){return isApplicationDetected}});let isApplicationDetected=e=>{var t,a;let{event:r}=e;return(null==r?void 0:null===(a=r.error)||void 0===a?void 0:null===(t=a.response)||void 0===t?void 0:t.status)===409}},10503:function(e,t,a){a.d(t,{w:function(){return isAthenaRecordCreated}});let isAthenaRecordCreated=e=>{var t;let{context:a}=e;return!!(null==a?void 0:null===(t=a.flyteUserData)||void 0===t?void 0:t.verifyToken)}},67618:function(e,t,a){a.d(t,{Q1:function(){return i},Er:function(){return n},qK:function(){return l},kS:function(){return d},aU:function(){return s},KG:function(){return o}});var r=a(10265);let i={[r.kT.Aetna]:"State of Connecticut - Retirees",[r.kT.CareCompass]:"State of Connecticut - Employees",[r.kT.PequotHealthCare]:"PEQUOT - EMPLOYEES",[r.kT["1199SEIU"]]:"1199SEIU BENEFIT FUNDS"},n={[r.kT.Aetna]:"Aetna",[r.kT.CareCompass]:"Anthem",[r.kT.PequotHealthCare]:"PEQUOT",[r.kT["1199SEIU"]]:"1199SEIU BENEFIT FUNDS"},o={[r.kT.Aetna]:"Aetna",[r.kT.CareCompass]:"SoCT",[r.kT.PequotHealthCare]:"Pequot Healthcare",[r.kT.ChristianaCare]:"Highmark",[r.kT.Emory]:"Aetna",[r.kT["1199SEIU"]]:"1199SEIU"},s={[r.kT.Flyte]:"Flyte Direct",[r.kT.CareCompass]:"State of Connecticut (Flyte)",[r.kT.Aetna]:"State of Connecticut Retirees (Flyte)",[r.kT.RiverSpringLiving]:"RiverSpring Living (Flyte)",[r.kT.PequotHealthCare]:"Pequot Tribal Family Health Plan (Flyte)",[r.kT.PyleFamilyInsurance]:"A. Duie Pyle (Flyte)",[r.kT.MDSave]:"MDsave (Flyte)",[r.kT.ChristianaCare]:"ChristianaCare - Caregivers (Flyte)",[r.kT.Emory]:"Emory (Flyte)",[r.kT["1199SEIU"]]:"1199SEIU Benefit Funds (Flyte)"},l={[r.PF["1199SEIU"]]:"00634",[r.PF.BCBS]:"S001",[r.PF.BCBSPPO]:"S001",[r.PF.Aetna]:"00001",[r.PF.Cigna]:"00004",[r.PF.United]:"00192",[r.PF.Anthem]:"S001",[r.PF["Pequot HealthCare"]]:"00192",[r.PF["Aetna Medicare"]]:"00001",[r.PF.Highmark]:"01015",[r.PF["Kaiser Colorado"]]:"00121",[r.PF["Kaiser Georgia"]]:"00126",[r.PF["Kaiser Hawaii"]]:"00122",[r.PF["Kaiser MidAtlantic"]]:"00124",[r.PF["Kaiser Northern California"]]:"00127",[r.PF["Kaiser Northwest"]]:"00125",[r.PF["Kaiser Southern California"]]:"00488",[r.PF["Kaiser Washington"]]:"01340",[r.PF["Kaiser Washington Options"]]:"01341"},c={[r.kT.Flyte]:"0014U00003DawbO",[r.kT.CareCompass]:"0014U000034qD18",[r.kT.Aetna]:"0014U00003LU03D",[r.kT.RiverSpringLiving]:"0014U00002tQPkK",[r.kT.PequotHealthCare]:"0014U00003DCPzp",[r.kT.PyleFamilyInsurance]:"0014U00002ngNsZ",[r.kT.MDSave]:"001VY00000CYbSs",[r.kT.ChristianaCare]:"001VY00000AE6Ny",[r.kT.Emory]:"001VY00000GpdUN",[r.kT["1199SEIU"]]:"001VY00000JEmuvYAD"};r.kT.Flyte,r.kT.CareCompass,r.kT.Aetna,r.kT.RiverSpringLiving,r.kT.PequotHealthCare,r.kT.PyleFamilyInsurance,r.kT.MDSave,r.kT.ChristianaCare,r.kT.Emory,r.kT["1199SEIU"];let d=c},10002:function(e,t,a){a.d(t,{a:function(){return o}});var r,i,n=a(70908);(r=i||(i={})).Idle="idle",r.Submitting="submitting",r.Error="error",r.Success="success";let o={...n.J,...i}},37053:function(e,t,a){var r,i,n,o;a.d(t,{V:function(){return i},_:function(){return r}}),(n=r||(r={})).FULL_MATCH="FULL_MATCH",n.EXPIRED="EXPIRED",n.PERSON_MATCH="PERSON_MATCH",n.INSURANCE_MATCH="INSURANCE_MATCH",n.NOT_FOUND="NOT_FOUND",n.ELIGIBLE_MATCH="ELIGIBLE_MATCH",(o=i||(i={})).Evolve="Evolve",o.Pverify="Pverify",o.EvolveAndPverify="Evolve & Pverify"},10265:function(e,t,a){a.d(t,{JJ:function(){return n.J},PF:function(){return i.PF},Vn:function(){return r.V},_q:function(){return r._},bV:function(){return i.bV},ib:function(){return i.ib},kT:function(){return i.kT},rl:function(){return i.rl}});var r=a(37053),i=a(56401),n=a(70908)},56401:function(e,t,a){var r,i,n,o,s,l,c,d,S,u,C,m,p,h,g,x;a.d(t,{Op:function(){return d},PF:function(){return l},bV:function(){return n},eF:function(){return s},i$:function(){return o},ib:function(){return r},kT:function(){return c},rl:function(){return i}}),(S=r||(r={})).Insurance="Insurance",S.CashPay="Cash Pay",S.BMI="BMI",S.Expired="Expired",(u=i||(i={})).EligibleWaiting="Eligible Waiting",u.Ineligible="Ineligible",u.Review="Review",(C=n||(n={})).SIA="SIA Medical PC",C.Flyte="Flyte Medical PC",C["State of Connecticut"]="State of Connecticut",C["State of Connecticut Retirees"]="State of Connecticut Retirees",C["RiverSpring Living - Self Guided"]="RiverSpring Living - Self Guided",C["RiverSpring Living - Guided"]="RiverSpring Living - Guided",C["Pequot Tribal Family Health Plan"]="Pequot Tribal Family Health Plan",C["A Duie Pyle"]="A Duie Pyle",C.MDsave="MDsave",C["ChristianaCare - Caregivers"]="ChristianaCare - Caregivers",C["Kaiser Permanente"]="Kaiser Permanente",C.Emory="Emory",C["1199SEIU"]="1199SEIU Benefit Funds",(m=o||(o={})).Alabama="AL",m.Alaska="AK",m.Arizona="AZ",m.Arkansas="AR",m.California="CA",m.Colorado="CO",m.Connecticut="CT",m.Delaware="DE",m.Florida="FL",m.Georgia="GA",m.Hawaii="HI",m.Idaho="ID",m.Illinois="IL",m.Indiana="IN",m.Iowa="IA",m.Kansas="KS",m.Kentucky="KY",m.Louisiana="LA",m.Maine="ME",m.Maryland="MD",m.Massachusetts="MA",m.Michigan="MI",m.Minnesota="MN",m.Mississippi="MS",m.Missouri="MO",m.Montana="MT",m.Nebraska="NE",m.Nevada="NV",m["New Hampshire"]="NH",m["New Jersey"]="NJ",m["New Mexico"]="NM",m["New York"]="NY",m["North Carolina"]="NC",m["North Dakota"]="ND",m.Ohio="OH",m.Oklahoma="OK",m.Oregon="OR",m.Pennsylvania="PA",m["Rhode Island"]="RI",m["South Carolina"]="SC",m["South Dakota"]="SD",m.Tennessee="TN",m.Texas="TX",m.Utah="UT",m.Vermont="VT",m.Virginia="VA",m.Washington="WA",m["Washington D.C."]="DC",m["West Virginia"]="WV",m.Wisconsin="WI",m.Wyoming="WY",(p=s||(s={})).Insured="yes",p.SelfPay="no",(h=l||(l={}))["1199SEIU"]="1199SEIU",h.Aetna="Aetna",h.Anthem="Anthem",h.Cigna="Cigna",h.BCBS="BCBS",h.BCBSPPO="BCBS Bluecard - PPO Briefcase",h.United="United",h.Other="Other",h.SelfPay="Self-Pay",h["Pequot HealthCare"]="Pequot HealthCare",h["Aetna Medicare"]="Aetna Medicare",h.Highmark="Highmark",h["Kaiser Colorado"]="Kaiser Permanente - Colorado",h["Kaiser Georgia"]="Kaiser Permanente - Georgia",h["Kaiser Hawaii"]="Kaiser Permanente - Hawaii",h["Kaiser MidAtlantic"]="Kaiser Permanente - Mid-Atlantic (Maryland / Virginia / D.C.)",h["Kaiser Northern California"]="Kaiser Permanente - Northern California",h["Kaiser Northwest"]="Kaiser Permanente - Northwest (Oregon / SW Washington)",h["Kaiser Southern California"]="Kaiser Permanente - Southern California",h["Kaiser Washington"]="Kaiser Permanente - Washington",h["Kaiser Washington Options"]="Kaiser Permanente - Washington Options",(g=c||(c={})).Flyte="flyte",g.CareCompass="careCompass",g.PequotHealthCare="pequotHealthCare",g.RiverSpringLiving="riverSpringLiving",g.PyleFamilyInsurance="pyleFamilyInsurance",g.Aetna="aetna",g.MDSave="mdSave",g.ChristianaCare="christianaCare",g.Emory="emory",g.KaiserPermanente="kaiserPermanente",g.Sone="sone",g["1199SEIU"]="1199SEIU",(x=d||(d={})).Brochure="Brochure",x.CompanyIntranet="Company Intranet",x.Email="Email",x.CoworkerReferral="Coworker Referral",x.EpicEHRReferral="Epic EHR Referral",x.FrameFertility="Frame Fertility",x.GoogleAd="Google Ad",x.Mailer="Mailer",x.NuvanceRhinebeck="Nuvance Rhinebeck",x.OnsiteMonitor="Onsite Monitor",x.Poster="Poster",x.PrintAd="Print Ad",x.ProfessionalReferral="Professional Referral",x.ProviderReferral="Provider Referral",x.QuantumHealth="Quantum Health",x.SocialMedia="Social Media",x.TVAd="TV Ad",x.TradeShow="Trade Show",x.UpswingHealth="Upswing Health",x.WebSearch="Web Search",x.WordOfMouth="Word of Mouth",x.Other="Other",x.BenefitsWebsite="Benefits Website",x.PrescriptionDenial="Prescription Denial",x.Website="Website",x.Pharmacy="Pharmacy",x.EmailMailer="Email/Mailer"},70908:function(e,t,a){var r,i;a.d(t,{J:function(){return r}}),(i=r||(r={})).WorkflowSelector="workflowSelector",i.PreEligibility="preEligibility",i.ContactDetails="contactDetails",i.InsuranceDetails="insuranceDetails",i.InsuranceDetailsReview="insuranceDetailsReview",i.ApplicationReview="applicationReview",i.ApplicationComplete="applicationComplete",i.ApplicationDetected="applicationDetected",i.EligibilityUnmet="eligibilityUnmet",i.EmailVerification="emailVerification",i.OnboardingChecklist="onboardingChecklist",i.CreatePassword="createPassword",i.AppDownload="appDownload",i.ReviewConsents="reviewConsents",i.OnboardingUserError="onboardingUserError",i.RequestLabs="requestLabs",i.SubmitLabs="submitLabs"},13176:function(e,t,a){a.d(t,{F:function(){return calculateAge}});let calculateAge=e=>{let t=new Date,a=new Date(e),r=t.getFullYear()-a.getFullYear(),i=t.getMonth()-a.getMonth();return(i<0||0===i&&t.getDate(){let{heightFeet:t,heightInches:a,weightPounds:i}=e;if(t<0||a<0||i<=0)throw new r.WB("Negative values are not allowed.");let n=12*t+a;return i/(n*n)*703}},36045:function(e,t,a){a.d(t,{T:function(){return checkFieldErrors}});let checkFieldErrors=(e,t,a)=>{var r;if(!t[e])return!1;let i=Array.isArray(a)?a:[a],n=null===(r=t[e])||void 0===r?void 0:r.type;return"string"==typeof n&&i.includes(n)}},43356:function(e,t,a){a.d(t,{P:function(){return o}});var r=a(43505),i=a(56401),n=a(13064);let o={[i.kT.Flyte]:e=>{let{bmi:t,comorbidity:a}=e;return t>=30||t>=27&&a===r.IQ.Yes},[i.kT.CareCompass]:e=>{let{birthdate:t,bmi:a,comorbidity:i}=e,o=(0,n.Fw)(t);return o>=18&&(a>=30||a>=27&&i===r.IQ.Yes)},[i.kT.Aetna]:e=>{let{birthdate:t,bmi:a,comorbidity:i}=e,o=(0,n.Fw)(t);return o>=18&&(a>=30||a>=27&&i===r.IQ.Yes)},[i.kT.RiverSpringLiving]:e=>{let{bmi:t}=e;return t>=27},[i.kT.PequotHealthCare]:e=>{let{birthdate:t,bmi:a,comorbidity:i}=e,o=(0,n.Fw)(t);return o>=18&&(a>=30||a>=27&&i===r.IQ.Yes)},[i.kT.PyleFamilyInsurance]:e=>{let{bmi:t}=e;return t>=30},[i.kT.MDSave]:e=>{let{bmi:t,comorbidity:a}=e;return t>=30||t>=27&&a===r.IQ.Yes},[i.kT.ChristianaCare]:e=>{let{birthdate:t,bmi:a,comorbidity:i}=e,o=(0,n.Fw)(t);return o>=18&&(a>=30||a>=27&&i===r.IQ.Yes)},[i.kT.Emory]:e=>{let{birthdate:t,bmi:a,comorbidity:i}=e,o=(0,n.Fw)(t);return o>=18&&(a>=30||a>=27&&i===r.IQ.Yes)},[i.kT["1199SEIU"]]:e=>{let{birthdate:t,bmi:a,comorbidity:i}=e,o=(0,n.Fw)(t);return o>=18&&(a>=35||a>=27&&i===r.IQ.Yes)}}},24076:function(e,t,a){a.d(t,{f:function(){return convertDateToISO}});var r=a(41016);let convertDateToISO=e=>{let t=e.match(/^(\d{2})[-/](\d{2})[-/](\d{4})$/);if(t)return"".concat(t[3],"-").concat(t[1],"-").concat(t[2]);throw new r.q7("convertDateToISO was given an invalid date format, expected MM/DD/YYYY")}},50574:function(e,t,a){a.d(t,{M:function(){return extractNumericValue}});let extractNumericValue=e=>{let t=null==e?void 0:e.match(/\d+(\.\d+)?/);return t?Number.parseFloat(t[0]):null}},17304:function(e,t,a){a.d(t,{k:function(){return getParentStateValue}});let getParentStateValue=e=>"string"==typeof e?e:Object.keys(e)[0]},13064:function(e,t,a){a.d(t,{Fw:function(){return r.F},V2:function(){return i.V},Pq:function(){return n.P},f1:function(){return o.f},MC:function(){return s.M}}),a(93103);var r=a(13176),i=a(79929),n=a(43356),o=a(24076),s=a(50574)},91736:function(e,t,a){a.d(t,{D:function(){return normalizeBenefitsCheck}});let normalizeBenefitsCheck=e=>({pvRequestID:e.checkId,pvStartDateOfService:e.startDateOfService,pvEndDateOfService:e.endDateOfService,pvPayerName:e.payer.payerName,pvSubscriberFullName:e.patient.fullName,pvMemberID:e.patient.memberId,pvEffectiveDate:e.coverage.effectiveDate,pvExpiryDate:e.coverage.expiryDate,pvStatus:e.coverage.status,pvPolicyType:e.coverage.policyType,pvGroupNumber:e.coverage.groupNumber,pvPlanName:e.coverage.planName,pvPlanNumber:e.coverage.planNumber,pvErrorDescription:e.errorDescription,pvEligibilityResult:e.eligibilityResult,pvDetailsURL:e.detailsUrl})},69834:function(e,t,a){a.d(t,{X:function(){return normalizePhoneNumber}});var r=a(18398);let normalizePhoneNumber=e=>{let t=(0,r.h)(e,"US");return t.nationalNumber}}}]);