PageSourceSearch

https://myka.ng/assets/AuthorizedRepPage-q3zTAAVw.js

js myka.ng collected 2026-10-09 22:42:42 UTC 3,831 bytes, 1 lines download raw bytes

1import{j as e,d as E,r as H}from"./vendor-react-DfYGAhtm.js";import{b as v,C as n}from"./vendor-forms-BP-7CbAP.js";import{by as g,bz as R,y as w}from"./vendor-icons-1odZwi-b.js";import{u as P}from"./vendor-state-BsBVN-fX.js";import{m as r,G as m,g as C,bb as _}from"./index-DsBgCU7r.js";import{u as A}from"./useHealthStepBreadcrumbs-CBh-jmUl.js";import{S as F}from"./StepPageLayout-DdZUweau.js";import{C as h}from"./formRules-Cjr9zhBJ.js";import{a as t,i as L,T as a,V as j,H as x,v as c}from"./vendor-ui-DA_r9yXk.js";import{H as k}from"./HealthFormShell-BdiFYoa2.js";import{g as I,H as M}from"./flowGuard-BvyU_Hq7.js";import{H as T}from"./routes-Dr23NpA-.js";import"./stepBreadcrumbs-FCtSk5Kj.js";const W=()=>e.jsxs(t,{children:[e.jsx(L,{fontSize:{base:"2xl",md:"3xl"},fontWeight:"bold",color:r.text.label,mb:2,children:"Authorized Representative"}),e.jsx(a,{fontSize:"sm",color:r.text.gray,children:"Provide the details of the company representative authorized to manage this policy."})]}),p=({children:f})=>e.jsxs(x,{gap:.5,mb:2,children:[e.jsx(a,{fontSize:"sm",fontWeight:"medium",color:r.text.info,children:f}),e.jsx(a,{fontSize:"md",color:r.error[500],children:"*"})]}),d={firstName:h.name("First name"),lastName:h.name("Last name"),email:h.workEmail(),phone:h.nigerianPhone()},Z=()=>{const{items:f}=A(),u=E(),b=P(),i=I(M.AuthorizedRep,null,null,null),{control:l,handleSubmit:y,formState:{errors:o}}=v({defaultValues:{firstName:"",lastName:"",email:"",phone:""}});if(H.useEffect(()=>{i&&u(i,{replace:!0})},[i,u]),i)return null;const S=s=>{b(_({firstName:s.firstName.trim(),lastName:s.lastName.trim(),email:s.email.trim(),phone:s.phone})),u(`/${T.ReviewSubmit}`)};return e.jsx(F,{items:f,contentMaxW:"600px",children:e.jsx(k,{children:e.jsxs(j,{gap:6,align:"stretch",children:[e.jsx(W,{}),e.jsx("form",{onSubmit:y(S),children:e.jsxs(j,{gap:4,align:"stretch",children:[e.jsxs(x,{gap:3,align:"flex-start",children:[e.jsxs(t,{flex:1,children:[e.jsx(p,{children:"First Name"}),e.jsx(n,{name:"firstName",control:l,rules:d.firstName,render:({field:s})=>e.jsx(m,{...s,placeholder:"e.g. Adebayo",border:`1px solid ${r.border.primary}`,bg:"white",_hover:{bg:"white"},hasError:!!o.firstName,error:o.firstName?.message,leftIcon:e.jsx(c,{as:g,boxSize:5,color:r.orange[400]}),pl:"10"})})]}),e.jsxs(t,{flex:1,children:[e.jsx(p,{children:"Last Name"}),e.jsx(n,{name:"lastName",control:l,rules:d.lastName,render:({field:s})=>e.jsx(m,{...s,placeholder:"e.g. Johnson",border:`1px solid ${r.border.primary}`,bg:"white",_hover:{bg:"white"},hasError:!!o.lastName,error:o.lastName?.message,leftIcon:e.jsx(c,{as:g,boxSize:5,color:r.orange[400]}),pl:"10"})})]})]}),e.jsxs(t,{children:[e.jsx(p,{children:"Work Email"}),e.jsx(n,{name:"email",control:l,rules:d.email,render:({field:s})=>e.jsx(m,{...s,type:"email",placeholder:"[email protected]",border:`1px solid ${r.border.primary}`,bg:"white",_hover:{bg:"white"},hasError:!!o.email,error:o.email?.message,leftIcon:e.jsx(c,{as:R,boxSize:5,color:r.gray[400]}),pl:"10"})})]}),e.jsxs(t,{children:[e.jsx(p,{children:"Phone No"}),e.jsx(n,{name:"phone",control:l,rules:d.phone,render:({field:s})=>e.jsx(m,{type:"tel",placeholder:"Phone number",value:s.value,onChange:N=>{const z=N.target.value.replace(/\D/g,"").replace(/^0+/,"").slice(0,10);s.onChange(z)},hasError:!!o.phone,error:o.phone?.message,border:`1px solid ${r.border.primary}`,bg:"white",_hover:{bg:"white"},pl:"16",leftIcon:e.jsx(a,{fontSize:"sm",fontWeight:"600",color:r.gray[700],children:"+234"})})})]}),e.jsxs(x,{justify:"center",gap:2,pt:1,children:[e.jsx(c,{as:w,boxSize:4,color:r.success[500]}),e.jsx(a,{fontSize:"xs",color:r.text.gray,children:"Your data is encrypted and completely safe"})]}),e.jsx(x,{justify:"flex-end",children:e.jsx(C,{buttonType:"primary",text:"Continue",size:"lg",type:"submit"})})]})})]})})})};export{Z as default};

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