@flarehr/apollo-personal-details-app 0.1.2277 → 0.1.2281

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -34,7 +34,7 @@ Thoth.Json.Net only support the following enum types:
34
34
  - int
35
35
  - uint32
36
36
  If you can't use one of these types, please pass an extra decoder.
37
- `))(c);return d=>h(d)}}else if(Pi(r))if(bo(r)){const f=Jt(c=>Ze(e,t,!1,c),Li(r));return c=>h=>Array.isArray(h)?ze(d=>Qc(An(d)),Na(0,f,c,h)):new $(1,[[c,new x(0,["an array",h])]])}else switch(W(Ri(r))){case"Microsoft.FSharp.Core.FSharpOption`1[System.Object]":return o=Ze(e,t,!0,ee(0,ke(r))),c=>h=>th(A(o),c,h);case"Microsoft.FSharp.Collections.FSharpList`1[System.Object]":return s=Ze(e,t,!1,ee(0,ke(r))),c=>h=>ka(A(s),c,h);case"System.Collections.Generic.IEnumerable`1[System.Object]":return i=Ze(e,t,!1,ee(0,ke(r))),c=>h=>nh(A(i),c,h);case"Microsoft.FSharp.Collections.FSharpMap`2[System.Object,System.Object]":{const c=Ze(e,t,!1,ee(0,ke(r))),h=Ze(e,t,!1,ee(1,ke(r)));let d;const p=E([m=>_=>ch(A(c),A(h),m,_),(u=ih(A(c),A(h)),m=>_=>ka(A(u),m,_))]);return d=m=>_=>rh(p,m,_),m=>_=>sh(uh,A(d),m,_)}case"Microsoft.FSharp.Collections.FSharpSet`1[System.Object]":{const c=Ze(e,t,!1,ee(0,ke(r)));return h=>d=>{const p=Ma(A(c),h,d);return p.tag===0?new $(0,[ah(p.fields[0])]):new $(1,[p.fields[0]])}}default:return Ia(e,t,n,r)}else switch(a){case"System.Boolean":return f=>c=>Jd(f,c);case"Microsoft.FSharp.Core.Unit":return f=>c=>Zd(f,c);case"System.String":return f=>c=>ga(f,c);case"System.Char":return f=>c=>Wd(f,c);case"System.SByte":return ya;case"System.Byte":return ba;case"System.Int16":return Sa;case"System.UInt16":return Ca;case"System.Int32":return va;case"System.UInt32":return Ea;case"System.Double":return f=>c=>Yd(f,c);case"System.Single":return f=>c=>Kd(f,c);case"System.DateTime":return f=>c=>Xd(f,c);case"System.DateTimeOffset":return f=>c=>Qd(f,c);case"System.TimeSpan":return f=>c=>eh(f,c);case"System.Guid":return f=>c=>qd(f,c);case"System.Object":return f=>c=>new $(0,[c]);default:return Ia(e,t,n,r)}else{const f=l;return c=>h=>f.contents(c)(h)}}function fh(e){return Io({Compare:nr})}function Zo(e,t,n){const r=ye(t,new Dt(0,[]));return Ze(fh(),r,!1,e)}class Fa extends ne{constructor(t,n,r,o,s,i,u){super(),this.Name=t,this.Title=n,this.Gender=r,this.Email=o,this.MobilePhone=s,this.DateOfBirth=i,this.Address=u}}function Da(){return En("Dto.Api.Backend.Common.FullProfileDto",[],Fa,()=>[["Name",Ru()],["Title",Y],["Gender",Y],["Email",Y],["MobilePhone",Y],["DateOfBirth",Y],["Address",Ro()]])}function $h(e){return Xu(0,ea(Di(Lu()),new Dt(1,[]),void 0,void 0)(e))}function dh(e){return qo(A(Zo(Di(Lu()),new Dt(1,[]))),e)}const P=si,hh=(e,t)=>{vt(()=>{const n=e();return()=>{n.Dispose()}},t)},ph=e=>{Et(()=>{const t=e();return()=>{t.Dispose()}})};function mh(e){return{Dispose(){Nt(t=>{L(t)},$r(e))}}}function Oa(e){return{Dispose(){e()}}}function Jo(e){const t=P.useRef(!1);P.useEffect(()=>{t.current||(t.current=!0,e())},[])}function _h(e){const t=P.useRef(void 0),n=P.useRef(!1),r=P.useRef(!1);n.current&&(r.current=!0),hh(()=>mh(n.current?void 0:(n.current=!0,t.current=$e(e()),r.current?t.current:void 0)),[])}function wh(e){const t=P.useRef(e),n=P.useCallback(r=>t.current(r),[]);return ph(r=>(t.current=e,Oa(()=>{}))),n}class Ir extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Success","Failure","Info"]}}function gh(e){switch(e.tag){case 0:return"text-green-700";case 2:return"text-blue-700";default:return"text-red-700"}}function yh(e){switch(e.tag){case 0:return"bg-green-50";case 2:return"bg-blue-50";default:return"bg-red-50"}}function bh(e){switch(e.tag){case 0:return E(["bg-green-50","text-green-500","hover:bg-green-100","focus:ring-offset-green-50","focus:ring-green-600"]);case 2:return E(["bg-blue-50","text-blue-500","hover:bg-blue-100","focus:ring-offset-blue-50","focus:ring-blue-600"]);default:return E(["bg-red-50","text-red-500","hover:bg-red-100","focus:ring-offset-red-50","focus:ring-red-600"])}}function Sh(e){switch(e.tag){case 0:return e.fields[0];case 2:return e.fields[0];default:return e.fields[0]}}function Ch(e,t){vo(N.Delay(()=>N.Bind(cf(5e3),()=>(e(),N.Zero()))),t)}function Pa(e){let t,n,r,o,s,i;const u=e.hideAlert,a=e.alert,l=qi();Jo(()=>{Ch(u,l)});const f=C("svg",B(E([["className",M(" ",["h-5","w-5"])],["fill","currentColor"],["viewBox","0 0 20 20"],["xmlns","http://www.w3.org/2000/svg"],(t=se(C("path",B(E([["fill-rule","evenodd"],(n="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",["d",n]),["clipRule","evenodd"]])))),["children",P.Children.toArray(Array.from(t))])])));return C("div",B(E([["className",M(" ",["rounded-md","p-4","my-4",yh(a)])],(r=[C("div",B(E([["className",M(" ",["flex"])],(o=[C("p",{className:M(" ",["text-sm",gh(a)]),children:Sh(a)}),C("div",B(E([["className",M(" ",["ml-auto"])],(s=[C("div",B(E([["className",M(" ",["-mx-1.5","-my-1.5"])],(i=[C("button",{type:"button",className:M(" ",te(w(()=>b(g("inline-flex"),w(()=>b(g("rounded-md"),w(()=>b(g("p-1.5"),w(()=>b(g("focus:outline-none"),w(()=>b(g("focus:ring-2"),w(()=>b(g("focus:ring-offset-2"),w(()=>bh(a)))))))))))))))),children:P.Children.toArray([f]),onClick:c=>{Zi(l),u()}})],["children",P.Children.toArray(Array.from(i))])])))],["children",P.Children.toArray(Array.from(s))])])))],["children",P.Children.toArray(Array.from(o))])])))],["children",P.Children.toArray(Array.from(r))])])))}class vh extends ne{constructor(t,n,r,o,s,i,u){super(),this.Name=t,this.Email=n,this.MobilePhone=r,this.Title=o,this.Gender=s,this.DateOfBirth=i,this.Address=u}}function Eh(){return En("Dto.Api.Backend.Read.PartialProfileDto",[],vh,()=>[["Name",Ru()],["Email",Y],["MobilePhone",ft(Y)],["Title",ft(Y)],["Gender",ft(Y)],["DateOfBirth",ft(Y)],["Address",ft(Ro())]])}class xh extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Full","Partial"]}}function kh(){return cr("Dto.Api.Backend.Read.ProfileDto",[],xh,()=>[[["Item",Da()]],[["Item",Eh()]]])}function Mh(e){return qo(A(Zo(kh(),new Dt(1,[]))),e)}class Th extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Success","EmailNotUnique"]}}function Nh(){return cr("Dto.Api.Backend.Read.ProfileUpdateStatus",[],Th,()=>[[],[]])}function Ah(e){return qo(A(Zo(Nh(),new Dt(1,[]))),e)}class Q extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["HasNotStartedYet","InProgress","Resolved","Failed"]}}function Ra(e,t){let n;const r=qi();return n=P.useRef(r),_h(()=>Oa(()=>{Zi(n.current)})),wh(o=>{sf(n.current)||vo(N.Delay(()=>N.TryWith(N.Delay(()=>(t(new Q(1,[])),N.Bind(e(o),s=>(t(new Q(2,[s])),N.Zero())))),s=>(t(new Q(3,[s])),N.Zero()))),n.current)})}function Va(e){return Nu(e)}function Ih(e){return gn(e,"yyyy-MM-dd")}function La(){return E([[new Qt(0,[]),"Male"],[new Qt(1,[]),"Female"],[new Qt(2,[]),"Intersex"],[new Qt(3,[]),"Transgender"],[new Qt(4,[]),"Prefer not to answer"],[new Qt(5,[]),"Other"]])}function Yo(e){return Fn(t=>{if(t[1]===e)return t[0]},La())}class Ot extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Mr","Miss","Mrs","Ms","Mx","Dr","Prof"]}}function Fh(e){return ve(e)}function Ha(){return E([[new Ot(0,[]),"Mr"],[new Ot(1,[]),"Miss"],[new Ot(2,[]),"Mrs"],[new Ot(3,[]),"Ms"],[new Ot(4,[]),"Mx"],[new Ot(5,[]),"Dr"],[new Ot(6,[]),"Prof"]])}function Ko(e){return Fn(t=>{if(t[1]===e)return t[0]},Ha())}class pt extends ne{constructor(t,n,r,o,s,i){super(),this.FirstName=t,this.MiddleName=n,this.LastName=r,this.Title=o,this.DateOfBirth=s,this.Gender=i}}const Dh=new pt("","","",void 0,void 0,void 0);class rt extends ne{constructor(t,n,r,o,s,i,u){super(),this.Email=t,this.MobileNumber=n,this.StreetAddress=r,this.Suburb=o,this.State=s,this.Postcode=i,this.NonUniqueEmails=u}}const Oh=new rt("","","","",void 0,"",K());class Hn extends ne{constructor(t,n){super(),this.Identification=t,this.ContactDetails=n}}const Ph=new Hn(Dh,Oh);function Rh(e){let t,n;const r=e.Identification.Gender;if(n=r==null?new $(1,["Gender missing"]):new $(0,[r]),t=n.tag===1?new $(1,[n.fields[0]]):new $(0,[V$(n.fields[0])]),t.tag===1)return new $(1,[t.fields[0]]);{let o,s;const i=e.ContactDetails.State;if(s=i==null?new $(1,["State missing"]):new $(0,[i]),o=s.tag===1?new $(1,[s.fields[0]]):new $(0,[Vo(s.fields[0])]),o.tag===1)return new $(1,[o.fields[0]]);{let u,a;const l=e.Identification.Title;if(a=l==null?new $(1,["Title missing"]):new $(0,[l]),u=a.tag===1?new $(1,[a.fields[0]]):new $(0,[Fh(a.fields[0])]),u.tag===1)return new $(1,[u.fields[0]]);{let f,c;const h=e.Identification.DateOfBirth;return c=h==null?new $(1,["DateOfBirth missing"]):new $(0,[h]),f=c.tag===1?new $(1,[c.fields[0]]):new $(0,[Ih(c.fields[0])]),f.tag===1?new $(1,[f.fields[0]]):new $(0,[new Fa(new Pu(e.Identification.FirstName.trim(),Er(e.Identification.MiddleName.trim()),e.Identification.LastName.trim()),u.fields[0],t.fields[0],e.ContactDetails.Email.trim(),Bu(e.ContactDetails.MobileNumber),f.fields[0],new Po(e.ContactDetails.StreetAddress.trim(),void 0,e.ContactDetails.Suburb.trim(),o.fields[0],e.ContactDetails.Postcode.trim(),"AU"))])}}}}function Vh(e){let t,n,r,o,s,i,u;if(e.tag===1){const a=e.fields[0];return new Hn(new pt(a.Name.FirstName,ye(a.Name.MiddleName,""),a.Name.LastName,(t=a.Title,t==null?void 0:Ko(t)),(n=a.DateOfBirth,n==null?void 0:Va(n)),(r=a.Gender,r==null?void 0:Yo(r))),new rt(a.Email,Ho(ye(a.MobilePhone,"")),ye((o=a.Address,o==null?void 0:o.AddressLine1),""),ye((s=a.Address,s==null?void 0:s.City),""),(i=a.Address,i==null?void 0:On(i.State)),ye((u=a.Address,u==null?void 0:u.Postcode),""),K()))}else{const a=e.fields[0];return new Hn(new pt(a.Name.FirstName,ye(a.Name.MiddleName,""),a.Name.LastName,Ko(a.Title),Va(a.DateOfBirth),Yo(a.Gender)),new rt(a.Email,Ho(a.MobilePhone),a.Address.AddressLine1,a.Address.City,On(a.Address.State),a.Address.Postcode,K()))}}let De=class extends ne{constructor(t,n,r,o){super(),this.FormModel=t,this.CurrentAlert=n,this.ExistingProfile=r,this.SaveStatus=o}},re=class extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["SetIdentification","SetContactDetails","GetProfileCallback","SaveStarted","SaveFinished","ShowAlert","HideAlert"]}};class Lh{constructor(t,n,r){this.OnNext=t,this.OnError=n||(o=>{}),this.OnCompleted=r||(()=>{})}}function Hh(e,t){t.Subscribe(new Lh(e))}class Bh{constructor(){this.delegates=[]}_add(t){this.delegates.push(t)}_remove(t){const n=this.delegates.indexOf(t);n>-1&&this.delegates.splice(n,1)}get Publish(){return Uh(t=>{this._add(t)},t=>{this._remove(t)})}Trigger(t,n){let r=null;const o=n===void 0?t:(r=t,n);this.delegates.forEach(s=>{s(r,o)})}}class Gh extends Bh{}function Uh(e,t){return{AddHandler(n){e(n)},RemoveHandler(n){t(n)},Subscribe(n){const r=(o,s)=>n.OnNext(s);return e(r),{Dispose(){t(r)}}}}}class jh{constructor(t){this._enabled=!1,this._isDisposed=!1,this._intervalId=0,this._timeoutId=0,this.Interval=t&&t>0?t:100,this.AutoReset=!0,this._elapsed=new Gh}Elapsed(){return this._elapsed.Publish}get Enabled(){return this._enabled}set Enabled(t){!this._isDisposed&&this._enabled!==t&&(this._enabled=t,this._enabled?this.AutoReset?this._intervalId=setInterval(()=>{this.AutoReset||(this.Enabled=!1),this._elapsed.Trigger(new Date)},this.Interval):this._timeoutId=setTimeout(()=>{this.Enabled=!1,this._timeoutId=0,this.AutoReset&&(this.Enabled=!0),this._elapsed.Trigger(new Date)},this.Interval):(this._timeoutId&&(clearTimeout(this._timeoutId),this._timeoutId=0),this._intervalId&&(clearInterval(this._intervalId),this._intervalId=0)))}Dispose(){this.Enabled=!1,this._isDisposed=!0}Close(){this.Dispose()}Start(){this.Enabled=!0}Stop(){this.Enabled=!1}}function zh(e,t){console.error($e(e),t)}function Wh(e,t){let n,r=new jh(e);r.AutoReset=!1,n=r,Hh(t,n.Elapsed()),n.Enabled=!0,n.Start()}function Ba(e,t,n){mr(r=>{try{r(t)}catch(o){e(o)}},n)}function ue(){return K()}function Ga(e,t,n,r,o){return se(s=>{e(N.Delay(()=>N.Bind(af(t(n)),i=>{const u=i;return s(u.tag===1?o(u.fields[0]):r(u.fields[0])),N.Zero()})))})}function Ua(e){Wh(1,t=>{vo(e)})}function qh(e){return Xu(0,ea(Da(),new Dt(1,[]),void 0,void 0)(e))}function ja(e){return`${e}/profiles/backend/profiles`}function Zh(e,t){const n=N.Delay(()=>{const r=xr(t,vr(new Mn(0,[]),Cr(ja(e))));return N.Bind(r,o=>{const s=o;if(s.tag===1)return N.Return(new $(1,[s.fields[0]]));{const i=s.fields[0];if(i.statusCode===200){const u=Mh(i.responseText);return N.Return(u)}else return N.Return(new $(1,[""]))}})});return N.Bind(n,r=>{let o;const s=r;return o=s.tag===1?new $(1,[new nt(1,[])]):new $(0,[s.fields[0]]),N.Return(o)})}function Jh(e,t,n){const r=N.Delay(()=>{let o;const s=xr(t,(o=xu(new Eo(1,[qh(n)]),vr(new Mn(2,[]),Cr(ja(e)))),Fo(vu("application/json"),o)));return N.Bind(s,i=>{const u=i;if(u.tag===1)return N.Return(new $(1,[u.fields[0]]));{const a=u.fields[0];if(a.statusCode===200){const l=Ah(a.responseText);return N.Return(l)}else return N.Return(new $(1,[""]))}})});return N.Bind(r,o=>{let s;const i=o;return s=i.tag===1?new $(1,[new nt(0,[])]):new $(0,[i.fields[0]]),N.Return(s)})}function Yh(){return[new De(Ph,void 0,new Q(0,[]),new Q(0,[])),ue()]}function Kh(e,t){let n;switch(e.tag){case 1:return[new De(new Hn(t.FormModel.Identification,e.fields[0](t.FormModel.ContactDetails)),t.CurrentAlert,t.ExistingProfile,t.SaveStatus),ue()];case 2:{let r,o;switch(e.fields[0].tag){case 3:{r=1;break}case 0:{r=2;break}case 1:{r=3;break}default:e.fields[0].fields[0].tag===1?r=1:(r=0,o=e.fields[0].fields[0].fields[0])}switch(r){case 0:return[new De(Vh(o),t.CurrentAlert,new Q(2,[o]),t.SaveStatus),ue()];case 1:return[new De(t.FormModel,t.CurrentAlert,new Q(3,[new Error(en(new nt(1,[])))]),t.SaveStatus),ue()];case 2:return[new De(t.FormModel,t.CurrentAlert,new Q(0,[]),t.SaveStatus),ue()];default:return[new De(t.FormModel,t.CurrentAlert,new Q(1,[]),t.SaveStatus),ue()]}}case 3:{const r=new De(t.FormModel,t.CurrentAlert,t.ExistingProfile,new Q(1,[])),o=Rh(t.FormModel);return o.tag===1?[r,se(s=>{s(new re(4,[new $(1,[new nt(0,[])])]))})]:[r,Ga(s=>{Ua(s)},s=>Jh(e.fields[0],e.fields[1],s),o.fields[0],s=>new re(4,[ze(i=>[i,e.fields[2]],s)]),s=>new re(4,[new $(1,[new nt(0,[])])]))]}case 4:return e.fields[0].tag===1?[new De(t.FormModel,t.CurrentAlert,t.ExistingProfile,new Q(3,[new Error(en(e.fields[0].fields[0]))])),(n=new re(5,[new Ir(1,[en(e.fields[0].fields[0])])]),se(r=>{r(n)}))]:e.fields[0].fields[0][0].tag===1?[new De(t.FormModel,t.CurrentAlert,t.ExistingProfile,new Q(2,[void 0])),se(r=>{r(new re(1,[o=>new rt(o.Email,o.MobileNumber,o.StreetAddress,o.Suburb,o.State,o.Postcode,_r(o.NonUniqueEmails,se(t.FormModel.ContactDetails.Email)))]))})]:(e.fields[0].fields[0][1](),[new De(t.FormModel,t.CurrentAlert,t.ExistingProfile,new Q(2,[void 0])),ue()]);case 5:return[new De(t.FormModel,e.fields[0],t.ExistingProfile,t.SaveStatus),ue()];case 6:return[new De(t.FormModel,void 0,t.ExistingProfile,t.SaveStatus),ue()];default:return[new De(new Hn(e.fields[0](t.FormModel.Identification),t.FormModel.ContactDetails),t.CurrentAlert,t.ExistingProfile,t.SaveStatus),ue()]}}function Xh(){return K()}function Xo(e){return M("/",e)}function Qh(e,t){const n=new Error("Duplicate SubId");return e(["Duplicate SubId: "+Xo(t),n])}function za(e,t,n){try{L(n)}catch(r){e(["Error stopping subscription: "+Xo(t),r])}}function e0(e,t,n,r){try{return[n,r(t)]}catch(o){e(["Error starting subscription: "+Xo(n),o]);return}}function t0(e,t){mr(n=>{za(e,n[0],n[1])},t)}function Wa(e,t,n,r,o,s){return mr(i=>{Qh(e,i)},n),mr(i=>{za(e,i[0],i[1])},r),_r(o,ou(i=>e0(e,t,i[0],i[1]),s))}function n0(){return[K(),Gd({Compare:Pe}),K()]}function r0(e,t,n,r,o){return Wo(e,r)?[Te(e,n),r,o]:[n,Bd(e,r),Te([e,t],o)]}function o0(e){return Cf((t,n)=>r0(t[0],t[1],n[0],n[1],n[2]),e,n0())}const s0=K();function qa(e,t){const n=Ud(In(i=>i[0],e),{Compare:Pe}),r=o0(t),o=r[1],s=r[0];if(n.Equals(o))return[s,K(),e,K()];{const i=Mf(u=>Wo(u[0],o),e);return[s,i[1],i[0],kf(u=>!Wo(u[0],n),r[2])]}}function i0(e,t,n,r){const o=Pe(e,n)|0;if(o===0)throw new Error("The step of a range cannot be zero");const s=o>0;return i=>{const u=Pe(i,t)|0;return s&&u<=0||!s&&u>=0?[i,r(i,e)]:void 0}}function u0(e,t,n,r,o){const s=i0(t,n,r,o);return w(()=>Uf(s,e))}function a0(e,t,n){return u0(e,t,n,0,(r,o)=>r+o)}class on extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Writable","ReadWritable"]}}class l0{constructor(t){this.state=new on(0,[dr(new Array(Qi(t,10)),0,Qi(t,10),null),0])}}function c0(e){return new l0(e)}function Za(e){const t=e.state;if(t.tag===1){const n=t.fields[1]|0,r=t.fields[2]|0,o=t.fields[0],s=(r+1)%o.length|0;return s===n?e.state=new on(0,[o,n]):e.state=new on(1,[o,n,s]),$e(ee(r,o))}else return}function f0(e,t){const n=e.state;if(n.tag===1){const r=n.fields[1]|0,o=n.fields[2]|0,s=n.fields[0];Ue(s,r,t);const i=(r+1)%s.length|0;i===o?e.state=new on(1,[$0(e,o,s),s.length,0]):e.state=new on(1,[s,i,o])}else{const r=n.fields[1]|0,o=n.fields[0];Ue(o,r,t);const s=(r+1)%o.length|0;e.state=new on(1,[o,s,r])}}function $0(e,t,n){return Array.from(w(()=>b(Kf(t,n),w(()=>b(Xf(t,n),w(()=>No(r=>g(ge()),a0(0,1,n.length))))))))}class Qo extends ne{constructor(t,n,r,o,s,i,u){super(),this.init=t,this.update=n,this.subscribe=r,this.view=o,this.setState=s,this.onError=i,this.termination=u}}function Ja(e,t,n){return new Qo(e,t,r=>Xh(),n,A(r=>{const o=Re(n)(r);return s=>{o(s)}}),r=>{zh(r[0],r[1])},[r=>!1,r=>{}])}function d0(e,t){return new Qo(t.init,t.update,t.subscribe,t.view,e,t.onError,t.termination)}function h0(e){return e.init}function p0(e,t,n,r,o,s,i){const u=Re(e)(i.init),a=J(t)(Re(i.update)),l=J(n)(Re(i.view)),f=J(r)(Re(i.setState));return new Qo(u,A(a),Re(o)(i.subscribe),A(l),A(f),i.onError,s(i.termination))}function m0(e,t,n){let r;const o=n.init(t),s=o[0],i=n.subscribe(s),u=n.termination,a=c0(10);let l=!1,f=s,c=s0,h=!1;const d=_=>{h||(f0(a,_),l||(l=!0,m(),l=!1))},p=Re(e)(d),m=()=>{let _,y=Za(a);for(;!h&&y!=null;){const v=S(y);if(u[0](v))t0(n.onError,c),u[1](f),h=!0;else{const T=n.update(v,f),U=T[0],Oe=n.subscribe(U);n.setState(U,p),Ba(mt=>{n.onError([et(Ve("Error handling the message: %A"))(v),mt])},p,T[1]),f=U,c=(_=qa(c,Oe),Wa(n.onError,p,_[0],_[1],_[2],_[3])),y=Za(a)}}};l=!0,n.setState(s,p),Ba(_=>{n.onError([et(Ve("Error intitializing:")),_])},p,o[1]),c=(r=qa(c,i),Wa(n.onError,p,r[0],r[1],r[2],r[3])),m(),l=!1}function _0(e,t){m0(A(n=>n),e,t)}function w0(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Ya={exports:{}},Ka={};const g0=w0(Pl);/**
37
+ `))(c);return d=>h(d)}}else if(Pi(r))if(bo(r)){const f=Jt(c=>Ze(e,t,!1,c),Li(r));return c=>h=>Array.isArray(h)?ze(d=>Qc(An(d)),Na(0,f,c,h)):new $(1,[[c,new x(0,["an array",h])]])}else switch(W(Ri(r))){case"Microsoft.FSharp.Core.FSharpOption`1[System.Object]":return o=Ze(e,t,!0,ee(0,ke(r))),c=>h=>th(A(o),c,h);case"Microsoft.FSharp.Collections.FSharpList`1[System.Object]":return s=Ze(e,t,!1,ee(0,ke(r))),c=>h=>ka(A(s),c,h);case"System.Collections.Generic.IEnumerable`1[System.Object]":return i=Ze(e,t,!1,ee(0,ke(r))),c=>h=>nh(A(i),c,h);case"Microsoft.FSharp.Collections.FSharpMap`2[System.Object,System.Object]":{const c=Ze(e,t,!1,ee(0,ke(r))),h=Ze(e,t,!1,ee(1,ke(r)));let d;const p=E([m=>_=>ch(A(c),A(h),m,_),(u=ih(A(c),A(h)),m=>_=>ka(A(u),m,_))]);return d=m=>_=>rh(p,m,_),m=>_=>sh(uh,A(d),m,_)}case"Microsoft.FSharp.Collections.FSharpSet`1[System.Object]":{const c=Ze(e,t,!1,ee(0,ke(r)));return h=>d=>{const p=Ma(A(c),h,d);return p.tag===0?new $(0,[ah(p.fields[0])]):new $(1,[p.fields[0]])}}default:return Ia(e,t,n,r)}else switch(a){case"System.Boolean":return f=>c=>Jd(f,c);case"Microsoft.FSharp.Core.Unit":return f=>c=>Zd(f,c);case"System.String":return f=>c=>ga(f,c);case"System.Char":return f=>c=>Wd(f,c);case"System.SByte":return ya;case"System.Byte":return ba;case"System.Int16":return Sa;case"System.UInt16":return Ca;case"System.Int32":return va;case"System.UInt32":return Ea;case"System.Double":return f=>c=>Yd(f,c);case"System.Single":return f=>c=>Kd(f,c);case"System.DateTime":return f=>c=>Xd(f,c);case"System.DateTimeOffset":return f=>c=>Qd(f,c);case"System.TimeSpan":return f=>c=>eh(f,c);case"System.Guid":return f=>c=>qd(f,c);case"System.Object":return f=>c=>new $(0,[c]);default:return Ia(e,t,n,r)}else{const f=l;return c=>h=>f.contents(c)(h)}}function fh(e){return Io({Compare:nr})}function Zo(e,t,n){const r=ye(t,new Dt(0,[]));return Ze(fh(),r,!1,e)}class Fa extends ne{constructor(t,n,r,o,s,i,u){super(),this.Name=t,this.Title=n,this.Gender=r,this.Email=o,this.MobilePhone=s,this.DateOfBirth=i,this.Address=u}}function Da(){return En("Dto.Api.Backend.Common.FullProfileDto",[],Fa,()=>[["Name",Ru()],["Title",Y],["Gender",Y],["Email",Y],["MobilePhone",Y],["DateOfBirth",Y],["Address",Ro()]])}function $h(e){return Xu(0,ea(Di(Lu()),new Dt(1,[]),void 0,void 0)(e))}function dh(e){return qo(A(Zo(Di(Lu()),new Dt(1,[]))),e)}const P=si,hh=(e,t)=>{vt(()=>{const n=e();return()=>{n.Dispose()}},t)},ph=e=>{Et(()=>{const t=e();return()=>{t.Dispose()}})};function mh(e){return{Dispose(){Nt(t=>{L(t)},$r(e))}}}function Oa(e){return{Dispose(){e()}}}function Jo(e){const t=P.useRef(!1);P.useEffect(()=>{t.current||(t.current=!0,e())},[])}function _h(e){const t=P.useRef(void 0),n=P.useRef(!1),r=P.useRef(!1);n.current&&(r.current=!0),hh(()=>mh(n.current?void 0:(n.current=!0,t.current=$e(e()),r.current?t.current:void 0)),[])}function wh(e){const t=P.useRef(e),n=P.useCallback(r=>t.current(r),[]);return ph(r=>(t.current=e,Oa(()=>{}))),n}class Ir extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Success","Failure","Info"]}}function gh(e){switch(e.tag){case 0:return"text-green-700";case 2:return"text-blue-700";default:return"text-red-700"}}function yh(e){switch(e.tag){case 0:return"bg-green-50";case 2:return"bg-blue-50";default:return"bg-red-50"}}function bh(e){switch(e.tag){case 0:return E(["bg-green-50","text-green-500","hover:bg-green-100","focus:ring-offset-green-50","focus:ring-green-600"]);case 2:return E(["bg-blue-50","text-blue-500","hover:bg-blue-100","focus:ring-offset-blue-50","focus:ring-blue-600"]);default:return E(["bg-red-50","text-red-500","hover:bg-red-100","focus:ring-offset-red-50","focus:ring-red-600"])}}function Sh(e){switch(e.tag){case 0:return e.fields[0];case 2:return e.fields[0];default:return e.fields[0]}}function Ch(e,t){vo(N.Delay(()=>N.Bind(cf(5e3),()=>(e(),N.Zero()))),t)}function Pa(e){let t,n,r,o,s,i;const u=e.hideAlert,a=e.alert,l=qi();Jo(()=>{Ch(u,l)});const f=C("svg",B(E([["className",M(" ",["h-5","w-5"])],["fill","currentColor"],["viewBox","0 0 20 20"],["xmlns","http://www.w3.org/2000/svg"],(t=se(C("path",B(E([["fill-rule","evenodd"],(n="M4.293 4.293a1 1 0 011.414 0L10 8.586l4.293-4.293a1 1 0 111.414 1.414L11.414 10l4.293 4.293a1 1 0 01-1.414 1.414L10 11.414l-4.293 4.293a1 1 0 01-1.414-1.414L8.586 10 4.293 5.707a1 1 0 010-1.414z",["d",n]),["clipRule","evenodd"]])))),["children",P.Children.toArray(Array.from(t))])])));return C("div",B(E([["className",M(" ",["rounded-md","p-4","my-4",yh(a)])],(r=[C("div",B(E([["className",M(" ",["flex"])],(o=[C("p",{className:M(" ",["text-sm",gh(a)]),children:Sh(a)}),C("div",B(E([["className",M(" ",["ml-auto"])],(s=[C("div",B(E([["className",M(" ",["-mx-1.5 -my-1.5"])],(i=[C("button",{type:"button",className:M(" ",te(w(()=>b(g("inline-flex"),w(()=>b(g("rounded-md"),w(()=>b(g("p-1.5"),w(()=>b(g("focus:outline-none"),w(()=>b(g("focus:ring-2"),w(()=>b(g("focus:ring-offset-2"),w(()=>bh(a)))))))))))))))),children:P.Children.toArray([f]),onClick:c=>{Zi(l),u()}})],["children",P.Children.toArray(Array.from(i))])])))],["children",P.Children.toArray(Array.from(s))])])))],["children",P.Children.toArray(Array.from(o))])])))],["children",P.Children.toArray(Array.from(r))])])))}class vh extends ne{constructor(t,n,r,o,s,i,u){super(),this.Name=t,this.Email=n,this.MobilePhone=r,this.Title=o,this.Gender=s,this.DateOfBirth=i,this.Address=u}}function Eh(){return En("Dto.Api.Backend.Read.PartialProfileDto",[],vh,()=>[["Name",Ru()],["Email",Y],["MobilePhone",ft(Y)],["Title",ft(Y)],["Gender",ft(Y)],["DateOfBirth",ft(Y)],["Address",ft(Ro())]])}class xh extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Full","Partial"]}}function kh(){return cr("Dto.Api.Backend.Read.ProfileDto",[],xh,()=>[[["Item",Da()]],[["Item",Eh()]]])}function Mh(e){return qo(A(Zo(kh(),new Dt(1,[]))),e)}class Th extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Success","EmailNotUnique"]}}function Nh(){return cr("Dto.Api.Backend.Read.ProfileUpdateStatus",[],Th,()=>[[],[]])}function Ah(e){return qo(A(Zo(Nh(),new Dt(1,[]))),e)}class Q extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["HasNotStartedYet","InProgress","Resolved","Failed"]}}function Ra(e,t){let n;const r=qi();return n=P.useRef(r),_h(()=>Oa(()=>{Zi(n.current)})),wh(o=>{sf(n.current)||vo(N.Delay(()=>N.TryWith(N.Delay(()=>(t(new Q(1,[])),N.Bind(e(o),s=>(t(new Q(2,[s])),N.Zero())))),s=>(t(new Q(3,[s])),N.Zero()))),n.current)})}function Va(e){return Nu(e)}function Ih(e){return gn(e,"yyyy-MM-dd")}function La(){return E([[new Qt(0,[]),"Male"],[new Qt(1,[]),"Female"],[new Qt(2,[]),"Intersex"],[new Qt(3,[]),"Transgender"],[new Qt(4,[]),"Prefer not to answer"],[new Qt(5,[]),"Other"]])}function Yo(e){return Fn(t=>{if(t[1]===e)return t[0]},La())}class Ot extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Mr","Miss","Mrs","Ms","Mx","Dr","Prof"]}}function Fh(e){return ve(e)}function Ha(){return E([[new Ot(0,[]),"Mr"],[new Ot(1,[]),"Miss"],[new Ot(2,[]),"Mrs"],[new Ot(3,[]),"Ms"],[new Ot(4,[]),"Mx"],[new Ot(5,[]),"Dr"],[new Ot(6,[]),"Prof"]])}function Ko(e){return Fn(t=>{if(t[1]===e)return t[0]},Ha())}class pt extends ne{constructor(t,n,r,o,s,i){super(),this.FirstName=t,this.MiddleName=n,this.LastName=r,this.Title=o,this.DateOfBirth=s,this.Gender=i}}const Dh=new pt("","","",void 0,void 0,void 0);class rt extends ne{constructor(t,n,r,o,s,i,u){super(),this.Email=t,this.MobileNumber=n,this.StreetAddress=r,this.Suburb=o,this.State=s,this.Postcode=i,this.NonUniqueEmails=u}}const Oh=new rt("","","","",void 0,"",K());class Hn extends ne{constructor(t,n){super(),this.Identification=t,this.ContactDetails=n}}const Ph=new Hn(Dh,Oh);function Rh(e){let t,n;const r=e.Identification.Gender;if(n=r==null?new $(1,["Gender missing"]):new $(0,[r]),t=n.tag===1?new $(1,[n.fields[0]]):new $(0,[V$(n.fields[0])]),t.tag===1)return new $(1,[t.fields[0]]);{let o,s;const i=e.ContactDetails.State;if(s=i==null?new $(1,["State missing"]):new $(0,[i]),o=s.tag===1?new $(1,[s.fields[0]]):new $(0,[Vo(s.fields[0])]),o.tag===1)return new $(1,[o.fields[0]]);{let u,a;const l=e.Identification.Title;if(a=l==null?new $(1,["Title missing"]):new $(0,[l]),u=a.tag===1?new $(1,[a.fields[0]]):new $(0,[Fh(a.fields[0])]),u.tag===1)return new $(1,[u.fields[0]]);{let f,c;const h=e.Identification.DateOfBirth;return c=h==null?new $(1,["DateOfBirth missing"]):new $(0,[h]),f=c.tag===1?new $(1,[c.fields[0]]):new $(0,[Ih(c.fields[0])]),f.tag===1?new $(1,[f.fields[0]]):new $(0,[new Fa(new Pu(e.Identification.FirstName.trim(),Er(e.Identification.MiddleName.trim()),e.Identification.LastName.trim()),u.fields[0],t.fields[0],e.ContactDetails.Email.trim(),Bu(e.ContactDetails.MobileNumber),f.fields[0],new Po(e.ContactDetails.StreetAddress.trim(),void 0,e.ContactDetails.Suburb.trim(),o.fields[0],e.ContactDetails.Postcode.trim(),"AU"))])}}}}function Vh(e){let t,n,r,o,s,i,u;if(e.tag===1){const a=e.fields[0];return new Hn(new pt(a.Name.FirstName,ye(a.Name.MiddleName,""),a.Name.LastName,(t=a.Title,t==null?void 0:Ko(t)),(n=a.DateOfBirth,n==null?void 0:Va(n)),(r=a.Gender,r==null?void 0:Yo(r))),new rt(a.Email,Ho(ye(a.MobilePhone,"")),ye((o=a.Address,o==null?void 0:o.AddressLine1),""),ye((s=a.Address,s==null?void 0:s.City),""),(i=a.Address,i==null?void 0:On(i.State)),ye((u=a.Address,u==null?void 0:u.Postcode),""),K()))}else{const a=e.fields[0];return new Hn(new pt(a.Name.FirstName,ye(a.Name.MiddleName,""),a.Name.LastName,Ko(a.Title),Va(a.DateOfBirth),Yo(a.Gender)),new rt(a.Email,Ho(a.MobilePhone),a.Address.AddressLine1,a.Address.City,On(a.Address.State),a.Address.Postcode,K()))}}let De=class extends ne{constructor(t,n,r,o){super(),this.FormModel=t,this.CurrentAlert=n,this.ExistingProfile=r,this.SaveStatus=o}},re=class extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["SetIdentification","SetContactDetails","GetProfileCallback","SaveStarted","SaveFinished","ShowAlert","HideAlert"]}};class Lh{constructor(t,n,r){this.OnNext=t,this.OnError=n||(o=>{}),this.OnCompleted=r||(()=>{})}}function Hh(e,t){t.Subscribe(new Lh(e))}class Bh{constructor(){this.delegates=[]}_add(t){this.delegates.push(t)}_remove(t){const n=this.delegates.indexOf(t);n>-1&&this.delegates.splice(n,1)}get Publish(){return Uh(t=>{this._add(t)},t=>{this._remove(t)})}Trigger(t,n){let r=null;const o=n===void 0?t:(r=t,n);this.delegates.forEach(s=>{s(r,o)})}}class Gh extends Bh{}function Uh(e,t){return{AddHandler(n){e(n)},RemoveHandler(n){t(n)},Subscribe(n){const r=(o,s)=>n.OnNext(s);return e(r),{Dispose(){t(r)}}}}}class jh{constructor(t){this._enabled=!1,this._isDisposed=!1,this._intervalId=0,this._timeoutId=0,this.Interval=t&&t>0?t:100,this.AutoReset=!0,this._elapsed=new Gh}Elapsed(){return this._elapsed.Publish}get Enabled(){return this._enabled}set Enabled(t){!this._isDisposed&&this._enabled!==t&&(this._enabled=t,this._enabled?this.AutoReset?this._intervalId=setInterval(()=>{this.AutoReset||(this.Enabled=!1),this._elapsed.Trigger(new Date)},this.Interval):this._timeoutId=setTimeout(()=>{this.Enabled=!1,this._timeoutId=0,this.AutoReset&&(this.Enabled=!0),this._elapsed.Trigger(new Date)},this.Interval):(this._timeoutId&&(clearTimeout(this._timeoutId),this._timeoutId=0),this._intervalId&&(clearInterval(this._intervalId),this._intervalId=0)))}Dispose(){this.Enabled=!1,this._isDisposed=!0}Close(){this.Dispose()}Start(){this.Enabled=!0}Stop(){this.Enabled=!1}}function zh(e,t){console.error($e(e),t)}function Wh(e,t){let n,r=new jh(e);r.AutoReset=!1,n=r,Hh(t,n.Elapsed()),n.Enabled=!0,n.Start()}function Ba(e,t,n){mr(r=>{try{r(t)}catch(o){e(o)}},n)}function ue(){return K()}function Ga(e,t,n,r,o){return se(s=>{e(N.Delay(()=>N.Bind(af(t(n)),i=>{const u=i;return s(u.tag===1?o(u.fields[0]):r(u.fields[0])),N.Zero()})))})}function Ua(e){Wh(1,t=>{vo(e)})}function qh(e){return Xu(0,ea(Da(),new Dt(1,[]),void 0,void 0)(e))}function ja(e){return`${e}/profiles/backend/profiles`}function Zh(e,t){const n=N.Delay(()=>{const r=xr(t,vr(new Mn(0,[]),Cr(ja(e))));return N.Bind(r,o=>{const s=o;if(s.tag===1)return N.Return(new $(1,[s.fields[0]]));{const i=s.fields[0];if(i.statusCode===200){const u=Mh(i.responseText);return N.Return(u)}else return N.Return(new $(1,[""]))}})});return N.Bind(n,r=>{let o;const s=r;return o=s.tag===1?new $(1,[new nt(1,[])]):new $(0,[s.fields[0]]),N.Return(o)})}function Jh(e,t,n){const r=N.Delay(()=>{let o;const s=xr(t,(o=xu(new Eo(1,[qh(n)]),vr(new Mn(2,[]),Cr(ja(e)))),Fo(vu("application/json"),o)));return N.Bind(s,i=>{const u=i;if(u.tag===1)return N.Return(new $(1,[u.fields[0]]));{const a=u.fields[0];if(a.statusCode===200){const l=Ah(a.responseText);return N.Return(l)}else return N.Return(new $(1,[""]))}})});return N.Bind(r,o=>{let s;const i=o;return s=i.tag===1?new $(1,[new nt(0,[])]):new $(0,[i.fields[0]]),N.Return(s)})}function Yh(){return[new De(Ph,void 0,new Q(0,[]),new Q(0,[])),ue()]}function Kh(e,t){let n;switch(e.tag){case 1:return[new De(new Hn(t.FormModel.Identification,e.fields[0](t.FormModel.ContactDetails)),t.CurrentAlert,t.ExistingProfile,t.SaveStatus),ue()];case 2:{let r,o;switch(e.fields[0].tag){case 3:{r=1;break}case 0:{r=2;break}case 1:{r=3;break}default:e.fields[0].fields[0].tag===1?r=1:(r=0,o=e.fields[0].fields[0].fields[0])}switch(r){case 0:return[new De(Vh(o),t.CurrentAlert,new Q(2,[o]),t.SaveStatus),ue()];case 1:return[new De(t.FormModel,t.CurrentAlert,new Q(3,[new Error(en(new nt(1,[])))]),t.SaveStatus),ue()];case 2:return[new De(t.FormModel,t.CurrentAlert,new Q(0,[]),t.SaveStatus),ue()];default:return[new De(t.FormModel,t.CurrentAlert,new Q(1,[]),t.SaveStatus),ue()]}}case 3:{const r=new De(t.FormModel,t.CurrentAlert,t.ExistingProfile,new Q(1,[])),o=Rh(t.FormModel);return o.tag===1?[r,se(s=>{s(new re(4,[new $(1,[new nt(0,[])])]))})]:[r,Ga(s=>{Ua(s)},s=>Jh(e.fields[0],e.fields[1],s),o.fields[0],s=>new re(4,[ze(i=>[i,e.fields[2]],s)]),s=>new re(4,[new $(1,[new nt(0,[])])]))]}case 4:return e.fields[0].tag===1?[new De(t.FormModel,t.CurrentAlert,t.ExistingProfile,new Q(3,[new Error(en(e.fields[0].fields[0]))])),(n=new re(5,[new Ir(1,[en(e.fields[0].fields[0])])]),se(r=>{r(n)}))]:e.fields[0].fields[0][0].tag===1?[new De(t.FormModel,t.CurrentAlert,t.ExistingProfile,new Q(2,[void 0])),se(r=>{r(new re(1,[o=>new rt(o.Email,o.MobileNumber,o.StreetAddress,o.Suburb,o.State,o.Postcode,_r(o.NonUniqueEmails,se(t.FormModel.ContactDetails.Email)))]))})]:(e.fields[0].fields[0][1](),[new De(t.FormModel,t.CurrentAlert,t.ExistingProfile,new Q(2,[void 0])),ue()]);case 5:return[new De(t.FormModel,e.fields[0],t.ExistingProfile,t.SaveStatus),ue()];case 6:return[new De(t.FormModel,void 0,t.ExistingProfile,t.SaveStatus),ue()];default:return[new De(new Hn(e.fields[0](t.FormModel.Identification),t.FormModel.ContactDetails),t.CurrentAlert,t.ExistingProfile,t.SaveStatus),ue()]}}function Xh(){return K()}function Xo(e){return M("/",e)}function Qh(e,t){const n=new Error("Duplicate SubId");return e(["Duplicate SubId: "+Xo(t),n])}function za(e,t,n){try{L(n)}catch(r){e(["Error stopping subscription: "+Xo(t),r])}}function e0(e,t,n,r){try{return[n,r(t)]}catch(o){e(["Error starting subscription: "+Xo(n),o]);return}}function t0(e,t){mr(n=>{za(e,n[0],n[1])},t)}function Wa(e,t,n,r,o,s){return mr(i=>{Qh(e,i)},n),mr(i=>{za(e,i[0],i[1])},r),_r(o,ou(i=>e0(e,t,i[0],i[1]),s))}function n0(){return[K(),Gd({Compare:Pe}),K()]}function r0(e,t,n,r,o){return Wo(e,r)?[Te(e,n),r,o]:[n,Bd(e,r),Te([e,t],o)]}function o0(e){return Cf((t,n)=>r0(t[0],t[1],n[0],n[1],n[2]),e,n0())}const s0=K();function qa(e,t){const n=Ud(In(i=>i[0],e),{Compare:Pe}),r=o0(t),o=r[1],s=r[0];if(n.Equals(o))return[s,K(),e,K()];{const i=Mf(u=>Wo(u[0],o),e);return[s,i[1],i[0],kf(u=>!Wo(u[0],n),r[2])]}}function i0(e,t,n,r){const o=Pe(e,n)|0;if(o===0)throw new Error("The step of a range cannot be zero");const s=o>0;return i=>{const u=Pe(i,t)|0;return s&&u<=0||!s&&u>=0?[i,r(i,e)]:void 0}}function u0(e,t,n,r,o){const s=i0(t,n,r,o);return w(()=>Uf(s,e))}function a0(e,t,n){return u0(e,t,n,0,(r,o)=>r+o)}class on extends j{constructor(t,n){super(),this.tag=t,this.fields=n}cases(){return["Writable","ReadWritable"]}}class l0{constructor(t){this.state=new on(0,[dr(new Array(Qi(t,10)),0,Qi(t,10),null),0])}}function c0(e){return new l0(e)}function Za(e){const t=e.state;if(t.tag===1){const n=t.fields[1]|0,r=t.fields[2]|0,o=t.fields[0],s=(r+1)%o.length|0;return s===n?e.state=new on(0,[o,n]):e.state=new on(1,[o,n,s]),$e(ee(r,o))}else return}function f0(e,t){const n=e.state;if(n.tag===1){const r=n.fields[1]|0,o=n.fields[2]|0,s=n.fields[0];Ue(s,r,t);const i=(r+1)%s.length|0;i===o?e.state=new on(1,[$0(e,o,s),s.length,0]):e.state=new on(1,[s,i,o])}else{const r=n.fields[1]|0,o=n.fields[0];Ue(o,r,t);const s=(r+1)%o.length|0;e.state=new on(1,[o,s,r])}}function $0(e,t,n){return Array.from(w(()=>b(Kf(t,n),w(()=>b(Xf(t,n),w(()=>No(r=>g(ge()),a0(0,1,n.length))))))))}class Qo extends ne{constructor(t,n,r,o,s,i,u){super(),this.init=t,this.update=n,this.subscribe=r,this.view=o,this.setState=s,this.onError=i,this.termination=u}}function Ja(e,t,n){return new Qo(e,t,r=>Xh(),n,A(r=>{const o=Re(n)(r);return s=>{o(s)}}),r=>{zh(r[0],r[1])},[r=>!1,r=>{}])}function d0(e,t){return new Qo(t.init,t.update,t.subscribe,t.view,e,t.onError,t.termination)}function h0(e){return e.init}function p0(e,t,n,r,o,s,i){const u=Re(e)(i.init),a=J(t)(Re(i.update)),l=J(n)(Re(i.view)),f=J(r)(Re(i.setState));return new Qo(u,A(a),Re(o)(i.subscribe),A(l),A(f),i.onError,s(i.termination))}function m0(e,t,n){let r;const o=n.init(t),s=o[0],i=n.subscribe(s),u=n.termination,a=c0(10);let l=!1,f=s,c=s0,h=!1;const d=_=>{h||(f0(a,_),l||(l=!0,m(),l=!1))},p=Re(e)(d),m=()=>{let _,y=Za(a);for(;!h&&y!=null;){const v=S(y);if(u[0](v))t0(n.onError,c),u[1](f),h=!0;else{const T=n.update(v,f),U=T[0],Oe=n.subscribe(U);n.setState(U,p),Ba(mt=>{n.onError([et(Ve("Error handling the message: %A"))(v),mt])},p,T[1]),f=U,c=(_=qa(c,Oe),Wa(n.onError,p,_[0],_[1],_[2],_[3])),y=Za(a)}}};l=!0,n.setState(s,p),Ba(_=>{n.onError([et(Ve("Error intitializing:")),_])},p,o[1]),c=(r=qa(c,i),Wa(n.onError,p,r[0],r[1],r[2],r[3])),m(),l=!1}function _0(e,t){m0(A(n=>n),e,t)}function w0(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){return this instanceof r?Reflect.construct(t,arguments,this.constructor):t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var o=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return e[r]}})}),n}var Ya={exports:{}},Ka={};const g0=w0(Pl);/**
38
38
  * @license React
39
39
  * use-sync-external-store-shim.production.min.js
40
40
  *
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@flarehr/apollo-personal-details-app",
3
- "version": "0.1.2277",
3
+ "version": "0.1.2281",
4
4
  "description": "Flare Personal Details Component",
5
5
  "license": "SEE LICENSE IN LICENSE.md",
6
6
  "files": [