dealposbarcode 25.42.0 → 25.50.0

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.
package/chunk-AVMIS4JH.js DELETED
@@ -1,5 +0,0 @@
1
- import{$a as Wo,$b as Hu,$c as $n,A as Fo,Aa as O,Ab as R,B as Q,Ba as Ho,Bb as Lu,Bd as rd,C as b,Ca as C,Cb as qr,D as un,Da as h,Dc as Et,Dd as ts,E as hu,Ea as st,Eb as Bu,Ec as Ke,Ed as sd,F as fu,Fa as Cu,Fb as Vu,Fd as ns,G as pu,Ga as Si,Gb as Vn,H as Fn,Ha as We,Hb as Jr,I,Ia as Ie,Id as od,J as Ei,Ja as F,Jd as ia,K as Ce,Kb as Je,L as Lo,La as qe,M as gu,Mb as xe,Md as is,N as Bo,Na as Su,Nb as Yo,Nd as rs,O as mu,Oa as ot,Ob as Uu,Oc as Pi,P as we,Pa as ke,Pb as ju,Pc as Ku,Pd as ra,Q as _u,Qa as Go,Qb as Qo,Qc as Yr,Ra as at,Rb as dn,Rc as Qr,Sa as zr,Sc as ta,Ta as Wr,Tb as $u,Tc as Zr,U as ce,Ua as Ut,Ub as Te,Uc as Ye,Va as zo,Vb as me,Vc as Xr,W as Vo,Wa as J,Wb as Un,X as Ci,Xa as Ii,Xb as Z,Xc as Ct,Ya as Ai,Yb as _e,Yc as Yu,Z as De,Za as B,Zc as jn,_ as Bt,_a as $,a as m,ad as Qe,b as k,ba as Uo,bb as ie,bc as Gu,bd as Qu,ca as ge,cc as zu,cd as fn,da as vu,db as Iu,dc as Wu,dd as Zu,ea as yu,eb as qo,ec as Ae,ed as Hn,f as ln,fb as Au,fc as Fe,fd as Xu,g as f,ga as bu,gb as ct,gc as jt,gd as ed,ha as yt,hc as Ri,hd as G,ia as Vt,ib as Jo,ic as Mi,id as td,ja as jo,jb as Ln,jd as Ni,ka as wu,kb as Bn,kc as Kr,kd as nd,l as au,lb as Ou,lc as hn,ld as id,m as cu,ma as Du,mb as Ru,mc as qu,md as ki,n as Ne,nb as Mu,nc as ue,nd as es,o as No,oa as Tu,ob as Pu,oc as de,p as ko,pb as Nu,pc as Zo,q as N,qa as $o,qb as ku,qc as Xo,qd as na,r as be,ra as le,rb as xu,s as lu,sa as W,sb as wt,sc as $t,ta as U,tb as Ko,tc as Ju,u as uu,ua as Gr,uc as Dt,v as du,va as j,vb as Fu,vc as Tt,wa as bt,x as rt,xa as y,xc as Le,y as Hr,ya as Se,yb as Oi,yc as ea,z as xo,za as Eu,zb as K,zc as Ht}from"./chunk-YB6XMFOT.js";var Fi=class{},os=class{},St=class n{constructor(t){this.normalizedNames=new Map,this.lazyUpdate=null,t?typeof t=="string"?this.lazyInit=()=>{this.headers=new Map,t.split(`
2
- `).forEach(e=>{let i=e.indexOf(":");if(i>0){let r=e.slice(0,i),s=r.toLowerCase(),o=e.slice(i+1).trim();this.maybeSetNormalizedName(r,s),this.headers.has(s)?this.headers.get(s).push(o):this.headers.set(s,[o])}})}:typeof Headers<"u"&&t instanceof Headers?(this.headers=new Map,t.forEach((e,i)=>{this.setHeaderEntries(i,e)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(t).forEach(([e,i])=>{this.setHeaderEntries(e,i)})}:this.headers=new Map}has(t){return this.init(),this.headers.has(t.toLowerCase())}get(t){this.init();let e=this.headers.get(t.toLowerCase());return e&&e.length>0?e[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(t){return this.init(),this.headers.get(t.toLowerCase())||null}append(t,e){return this.clone({name:t,value:e,op:"a"})}set(t,e){return this.clone({name:t,value:e,op:"s"})}delete(t,e){return this.clone({name:t,value:e,op:"d"})}maybeSetNormalizedName(t,e){this.normalizedNames.has(e)||this.normalizedNames.set(e,t)}init(){this.lazyInit&&(this.lazyInit instanceof n?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(t=>this.applyUpdate(t)),this.lazyUpdate=null))}copyFrom(t){t.init(),Array.from(t.headers.keys()).forEach(e=>{this.headers.set(e,t.headers.get(e)),this.normalizedNames.set(e,t.normalizedNames.get(e))})}clone(t){let e=new n;return e.lazyInit=this.lazyInit&&this.lazyInit instanceof n?this.lazyInit:this,e.lazyUpdate=(this.lazyUpdate||[]).concat([t]),e}applyUpdate(t){let e=t.name.toLowerCase();switch(t.op){case"a":case"s":let i=t.value;if(typeof i=="string"&&(i=[i]),i.length===0)return;this.maybeSetNormalizedName(t.name,e);let r=(t.op==="a"?this.headers.get(e):void 0)||[];r.push(...i),this.headers.set(e,r);break;case"d":let s=t.value;if(!s)this.headers.delete(e),this.normalizedNames.delete(e);else{let o=this.headers.get(e);if(!o)return;o=o.filter(c=>s.indexOf(c)===-1),o.length===0?(this.headers.delete(e),this.normalizedNames.delete(e)):this.headers.set(e,o)}break}}setHeaderEntries(t,e){let i=(Array.isArray(e)?e:[e]).map(s=>s.toString()),r=t.toLowerCase();this.headers.set(r,i),this.maybeSetNormalizedName(t,r)}forEach(t){this.init(),Array.from(this.normalizedNames.keys()).forEach(e=>t(this.normalizedNames.get(e),this.headers.get(e)))}};var oa=class{encodeKey(t){return ad(t)}encodeValue(t){return ad(t)}decodeKey(t){return decodeURIComponent(t)}decodeValue(t){return decodeURIComponent(t)}};function lg(n,t){let e=new Map;return n.length>0&&n.replace(/^\?/,"").split("&").forEach(r=>{let s=r.indexOf("="),[o,c]=s==-1?[t.decodeKey(r),""]:[t.decodeKey(r.slice(0,s)),t.decodeValue(r.slice(s+1))],a=e.get(o)||[];a.push(c),e.set(o,a)}),e}var ug=/%(\d[a-f0-9])/gi,dg={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function ad(n){return encodeURIComponent(n).replace(ug,(t,e)=>dg[e]??t)}function ss(n){return`${n}`}var Gt=class n{constructor(t={}){if(this.updates=null,this.cloneFrom=null,this.encoder=t.encoder||new oa,t.fromString){if(t.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=lg(t.fromString,this.encoder)}else t.fromObject?(this.map=new Map,Object.keys(t.fromObject).forEach(e=>{let i=t.fromObject[e],r=Array.isArray(i)?i.map(ss):[ss(i)];this.map.set(e,r)})):this.map=null}has(t){return this.init(),this.map.has(t)}get(t){this.init();let e=this.map.get(t);return e?e[0]:null}getAll(t){return this.init(),this.map.get(t)||null}keys(){return this.init(),Array.from(this.map.keys())}append(t,e){return this.clone({param:t,value:e,op:"a"})}appendAll(t){let e=[];return Object.keys(t).forEach(i=>{let r=t[i];Array.isArray(r)?r.forEach(s=>{e.push({param:i,value:s,op:"a"})}):e.push({param:i,value:r,op:"a"})}),this.clone(e)}set(t,e){return this.clone({param:t,value:e,op:"s"})}delete(t,e){return this.clone({param:t,value:e,op:"d"})}toString(){return this.init(),this.keys().map(t=>{let e=this.encoder.encodeKey(t);return this.map.get(t).map(i=>e+"="+this.encoder.encodeValue(i)).join("&")}).filter(t=>t!=="").join("&")}clone(t){let e=new n({encoder:this.encoder});return e.cloneFrom=this.cloneFrom||this,e.updates=(this.updates||[]).concat(t),e}init(){this.map===null&&(this.map=new Map),this.cloneFrom!==null&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(t=>this.map.set(t,this.cloneFrom.map.get(t))),this.updates.forEach(t=>{switch(t.op){case"a":case"s":let e=(t.op==="a"?this.map.get(t.param):void 0)||[];e.push(ss(t.value)),this.map.set(t.param,e);break;case"d":if(t.value!==void 0){let i=this.map.get(t.param)||[],r=i.indexOf(ss(t.value));r!==-1&&i.splice(r,1),i.length>0?this.map.set(t.param,i):this.map.delete(t.param)}else{this.map.delete(t.param);break}}}),this.cloneFrom=this.updates=null)}};var aa=class{constructor(){this.map=new Map}set(t,e){return this.map.set(t,e),this}get(t){return this.map.has(t)||this.map.set(t,t.defaultValue()),this.map.get(t)}delete(t){return this.map.delete(t),this}has(t){return this.map.has(t)}keys(){return this.map.keys()}};function hg(n){switch(n){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}function cd(n){return typeof ArrayBuffer<"u"&&n instanceof ArrayBuffer}function ld(n){return typeof Blob<"u"&&n instanceof Blob}function ud(n){return typeof FormData<"u"&&n instanceof FormData}function fg(n){return typeof URLSearchParams<"u"&&n instanceof URLSearchParams}var xi=class n{constructor(t,e,i,r){this.url=e,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=t.toUpperCase();let s;if(hg(this.method)||r?(this.body=i!==void 0?i:null,s=r):s=i,s&&(this.reportProgress=!!s.reportProgress,this.withCredentials=!!s.withCredentials,s.responseType&&(this.responseType=s.responseType),s.headers&&(this.headers=s.headers),s.context&&(this.context=s.context),s.params&&(this.params=s.params),this.transferCache=s.transferCache),this.headers??=new St,this.context??=new aa,!this.params)this.params=new Gt,this.urlWithParams=e;else{let o=this.params.toString();if(o.length===0)this.urlWithParams=e;else{let c=e.indexOf("?"),a=c===-1?"?":c<e.length-1?"&":"";this.urlWithParams=e+a+o}}}serializeBody(){return this.body===null?null:typeof this.body=="string"||cd(this.body)||ld(this.body)||ud(this.body)||fg(this.body)?this.body:this.body instanceof Gt?this.body.toString():typeof this.body=="object"||typeof this.body=="boolean"||Array.isArray(this.body)?JSON.stringify(this.body):this.body.toString()}detectContentTypeHeader(){return this.body===null||ud(this.body)?null:ld(this.body)?this.body.type||null:cd(this.body)?null:typeof this.body=="string"?"text/plain":this.body instanceof Gt?"application/x-www-form-urlencoded;charset=UTF-8":typeof this.body=="object"||typeof this.body=="number"||typeof this.body=="boolean"?"application/json":null}clone(t={}){let e=t.method||this.method,i=t.url||this.url,r=t.responseType||this.responseType,s=t.transferCache??this.transferCache,o=t.body!==void 0?t.body:this.body,c=t.withCredentials??this.withCredentials,a=t.reportProgress??this.reportProgress,l=t.headers||this.headers,u=t.params||this.params,d=t.context??this.context;return t.setHeaders!==void 0&&(l=Object.keys(t.setHeaders).reduce((p,g)=>p.set(g,t.setHeaders[g]),l)),t.setParams&&(u=Object.keys(t.setParams).reduce((p,g)=>p.set(g,t.setParams[g]),u)),new n(e,i,o,{params:u,headers:l,context:d,reportProgress:a,responseType:r,withCredentials:c,transferCache:s})}},zt=function(n){return n[n.Sent=0]="Sent",n[n.UploadProgress=1]="UploadProgress",n[n.ResponseHeader=2]="ResponseHeader",n[n.DownloadProgress=3]="DownloadProgress",n[n.Response=4]="Response",n[n.User=5]="User",n}(zt||{}),Li=class{constructor(t,e=200,i="OK"){this.headers=t.headers||new St,this.status=t.status!==void 0?t.status:e,this.statusText=t.statusText||i,this.url=t.url||null,this.ok=this.status>=200&&this.status<300}},as=class n extends Li{constructor(t={}){super(t),this.type=zt.ResponseHeader}clone(t={}){return new n({headers:t.headers||this.headers,status:t.status!==void 0?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}},Bi=class n extends Li{constructor(t={}){super(t),this.type=zt.Response,this.body=t.body!==void 0?t.body:null}clone(t={}){return new n({body:t.body!==void 0?t.body:this.body,headers:t.headers||this.headers,status:t.status!==void 0?t.status:this.status,statusText:t.statusText||this.statusText,url:t.url||this.url||void 0})}},lt=class extends Li{constructor(t){super(t,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.status>=200&&this.status<300?this.message=`Http failure during parsing for ${t.url||"(unknown url)"}`:this.message=`Http failure response for ${t.url||"(unknown url)"}: ${t.status} ${t.statusText}`,this.error=t.error||null}},gd=200,pg=204;function sa(n,t){return{body:t,headers:n.headers,context:n.context,observe:n.observe,params:n.params,reportProgress:n.reportProgress,responseType:n.responseType,withCredentials:n.withCredentials,transferCache:n.transferCache}}var ua=(()=>{class n{constructor(e){this.handler=e}request(e,i,r={}){let s;if(e instanceof xi)s=e;else{let a;r.headers instanceof St?a=r.headers:a=new St(r.headers);let l;r.params&&(r.params instanceof Gt?l=r.params:l=new Gt({fromObject:r.params})),s=new xi(e,i,r.body!==void 0?r.body:null,{headers:a,context:r.context,params:l,reportProgress:r.reportProgress,responseType:r.responseType||"json",withCredentials:r.withCredentials,transferCache:r.transferCache})}let o=b(s).pipe(Bt(a=>this.handler.handle(a)));if(e instanceof xi||r.observe==="events")return o;let c=o.pipe(ce(a=>a instanceof Bi));switch(r.observe||"body"){case"body":switch(s.responseType){case"arraybuffer":return c.pipe(I(a=>{if(a.body!==null&&!(a.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return a.body}));case"blob":return c.pipe(I(a=>{if(a.body!==null&&!(a.body instanceof Blob))throw new Error("Response is not a Blob.");return a.body}));case"text":return c.pipe(I(a=>{if(a.body!==null&&typeof a.body!="string")throw new Error("Response is not a string.");return a.body}));case"json":default:return c.pipe(I(a=>a.body))}case"response":return c;default:throw new Error(`Unreachable: unhandled observe type ${r.observe}}`)}}delete(e,i={}){return this.request("DELETE",e,i)}get(e,i={}){return this.request("GET",e,i)}head(e,i={}){return this.request("HEAD",e,i)}jsonp(e,i){return this.request("JSONP",e,{params:new Gt().append(i,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(e,i={}){return this.request("OPTIONS",e,i)}patch(e,i,r={}){return this.request("PATCH",e,sa(r,i))}post(e,i,r={}){return this.request("POST",e,sa(r,i))}put(e,i,r={}){return this.request("PUT",e,sa(r,i))}static{this.\u0275fac=function(i){return new(i||n)(C(Fi))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})(),gg=/^\)\]\}',?\n/,mg="X-Request-URL";function dd(n){if(n.url)return n.url;let t=mg.toLocaleLowerCase();return n.headers.get(t)}var _g=(()=>{class n{constructor(){this.fetchImpl=h(ca,{optional:!0})?.fetch??((...e)=>globalThis.fetch(...e)),this.ngZone=h($)}handle(e){return new Ne(i=>{let r=new AbortController;return this.doRequest(e,r.signal,i).then(la,s=>i.error(new lt({error:s}))),()=>r.abort()})}doRequest(e,i,r){return f(this,null,function*(){let s=this.createRequestInit(e),o;try{let g=this.ngZone.runOutsideAngular(()=>this.fetchImpl(e.urlWithParams,m({signal:i},s)));vg(g),r.next({type:zt.Sent}),o=yield g}catch(g){r.error(new lt({error:g,status:g.status??0,statusText:g.statusText,url:e.urlWithParams,headers:g.headers}));return}let c=new St(o.headers),a=o.statusText,l=dd(o)??e.urlWithParams,u=o.status,d=null;if(e.reportProgress&&r.next(new as({headers:c,status:u,statusText:a,url:l})),o.body){let g=o.headers.get("content-length"),w=[],v=o.body.getReader(),_=0,S,x,D=typeof Zone<"u"&&Zone.current;yield this.ngZone.runOutsideAngular(()=>f(this,null,function*(){for(;;){let{done:M,value:P}=yield v.read();if(M)break;if(w.push(P),_+=P.length,e.reportProgress){x=e.responseType==="text"?(x??"")+(S??=new TextDecoder).decode(P,{stream:!0}):void 0;let V=()=>r.next({type:zt.DownloadProgress,total:g?+g:void 0,loaded:_,partialText:x});D?D.run(V):V()}}}));let E=this.concatChunks(w,_);try{let M=o.headers.get("Content-Type")??"";d=this.parseBody(e,E,M)}catch(M){r.error(new lt({error:M,headers:new St(o.headers),status:o.status,statusText:o.statusText,url:dd(o)??e.urlWithParams}));return}}u===0&&(u=d?gd:0),u>=200&&u<300?(r.next(new Bi({body:d,headers:c,status:u,statusText:a,url:l})),r.complete()):r.error(new lt({error:d,headers:c,status:u,statusText:a,url:l}))})}parseBody(e,i,r){switch(e.responseType){case"json":let s=new TextDecoder().decode(i).replace(gg,"");return s===""?null:JSON.parse(s);case"text":return new TextDecoder().decode(i);case"blob":return new Blob([i],{type:r});case"arraybuffer":return i.buffer}}createRequestInit(e){let i={},r=e.withCredentials?"include":void 0;if(e.headers.forEach((s,o)=>i[s]=o.join(",")),e.headers.has("Accept")||(i.Accept="application/json, text/plain, */*"),!e.headers.has("Content-Type")){let s=e.detectContentTypeHeader();s!==null&&(i["Content-Type"]=s)}return{body:e.serializeBody(),method:e.method,headers:i,credentials:r}}concatChunks(e,i){let r=new Uint8Array(i),s=0;for(let o of e)r.set(o,s),s+=o.length;return r}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})(),ca=class{};function la(){}function vg(n){n.then(la,la)}function md(n,t){return t(n)}function yg(n,t){return(e,i)=>t.intercept(e,{handle:r=>n(r,i)})}function bg(n,t,e){return(i,r)=>ke(e,()=>t(i,s=>n(s,r)))}var wg=new O(""),ls=new O(""),Dg=new O(""),_d=new O("",{providedIn:"root",factory:()=>!0});function Tg(){let n=null;return(t,e)=>{n===null&&(n=(h(wg,{optional:!0})??[]).reduceRight(yg,md));let i=h(Ai);if(h(_d)){let s=i.add();return n(t,e).pipe(yt(()=>i.remove(s)))}else return n(t,e)}}var hd=(()=>{class n extends Fi{constructor(e,i){super(),this.backend=e,this.injector=i,this.chain=null,this.pendingTasks=h(Ai),this.contributeToStability=h(_d)}handle(e){if(this.chain===null){let i=Array.from(new Set([...this.injector.get(ls),...this.injector.get(Dg,[])]));this.chain=i.reduceRight((r,s)=>bg(r,s,this.injector),md)}if(this.contributeToStability){let i=this.pendingTasks.add();return this.chain(e,r=>this.backend.handle(r)).pipe(yt(()=>this.pendingTasks.remove(i)))}else return this.chain(e,i=>this.backend.handle(i))}static{this.\u0275fac=function(i){return new(i||n)(C(os),C(ot))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})();var Eg=/^\)\]\}',?\n/;function Cg(n){return"responseURL"in n&&n.responseURL?n.responseURL:/^X-Request-URL:/m.test(n.getAllResponseHeaders())?n.getResponseHeader("X-Request-URL"):null}var fd=(()=>{class n{constructor(e){this.xhrFactory=e}handle(e){if(e.method==="JSONP")throw new j(-2800,!1);let i=this.xhrFactory;return(i.\u0275loadImpl?Q(i.\u0275loadImpl()):b(null)).pipe(le(()=>new Ne(s=>{let o=i.build();if(o.open(e.method,e.urlWithParams),e.withCredentials&&(o.withCredentials=!0),e.headers.forEach((v,_)=>o.setRequestHeader(v,_.join(","))),e.headers.has("Accept")||o.setRequestHeader("Accept","application/json, text/plain, */*"),!e.headers.has("Content-Type")){let v=e.detectContentTypeHeader();v!==null&&o.setRequestHeader("Content-Type",v)}if(e.responseType){let v=e.responseType.toLowerCase();o.responseType=v!=="json"?v:"text"}let c=e.serializeBody(),a=null,l=()=>{if(a!==null)return a;let v=o.statusText||"OK",_=new St(o.getAllResponseHeaders()),S=Cg(o)||e.url;return a=new as({headers:_,status:o.status,statusText:v,url:S}),a},u=()=>{let{headers:v,status:_,statusText:S,url:x}=l(),D=null;_!==pg&&(D=typeof o.response>"u"?o.responseText:o.response),_===0&&(_=D?gd:0);let E=_>=200&&_<300;if(e.responseType==="json"&&typeof D=="string"){let M=D;D=D.replace(Eg,"");try{D=D!==""?JSON.parse(D):null}catch(P){D=M,E&&(E=!1,D={error:P,text:D})}}E?(s.next(new Bi({body:D,headers:v,status:_,statusText:S,url:x||void 0})),s.complete()):s.error(new lt({error:D,headers:v,status:_,statusText:S,url:x||void 0}))},d=v=>{let{url:_}=l(),S=new lt({error:v,status:o.status||0,statusText:o.statusText||"Unknown Error",url:_||void 0});s.error(S)},p=!1,g=v=>{p||(s.next(l()),p=!0);let _={type:zt.DownloadProgress,loaded:v.loaded};v.lengthComputable&&(_.total=v.total),e.responseType==="text"&&o.responseText&&(_.partialText=o.responseText),s.next(_)},w=v=>{let _={type:zt.UploadProgress,loaded:v.loaded};v.lengthComputable&&(_.total=v.total),s.next(_)};return o.addEventListener("load",u),o.addEventListener("error",d),o.addEventListener("timeout",d),o.addEventListener("abort",d),e.reportProgress&&(o.addEventListener("progress",g),c!==null&&o.upload&&o.upload.addEventListener("progress",w)),o.send(c),s.next({type:zt.Sent}),()=>{o.removeEventListener("error",d),o.removeEventListener("abort",d),o.removeEventListener("load",u),o.removeEventListener("timeout",d),e.reportProgress&&(o.removeEventListener("progress",g),c!==null&&o.upload&&o.upload.removeEventListener("progress",w)),o.readyState!==o.DONE&&o.abort()}})))}static{this.\u0275fac=function(i){return new(i||n)(C(ns))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})(),vd=new O(""),Sg="XSRF-TOKEN",Ig=new O("",{providedIn:"root",factory:()=>Sg}),Ag="X-XSRF-TOKEN",Og=new O("",{providedIn:"root",factory:()=>Ag}),cs=class{},Rg=(()=>{class n{constructor(e,i,r){this.doc=e,this.platform=i,this.cookieName=r,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if(this.platform==="server")return null;let e=this.doc.cookie||"";return e!==this.lastCookieString&&(this.parseCount++,this.lastToken=es(e,this.cookieName),this.lastCookieString=e),this.lastToken}static{this.\u0275fac=function(i){return new(i||n)(C(G),C(ct),C(Ig))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})();function Mg(n,t){let e=n.url.toLowerCase();if(!h(vd)||n.method==="GET"||n.method==="HEAD"||e.startsWith("http://")||e.startsWith("https://"))return t(n);let i=h(cs).getToken(),r=h(Og);return i!=null&&!n.headers.has(r)&&(n=n.clone({headers:n.headers.set(r,i)})),t(n)}var da=function(n){return n[n.Interceptors=0]="Interceptors",n[n.LegacyInterceptors=1]="LegacyInterceptors",n[n.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",n[n.NoXsrfProtection=3]="NoXsrfProtection",n[n.JsonpSupport=4]="JsonpSupport",n[n.RequestsMadeViaParent=5]="RequestsMadeViaParent",n[n.Fetch=6]="Fetch",n}(da||{});function yd(n,t){return{\u0275kind:n,\u0275providers:t}}function ND(...n){let t=[ua,fd,hd,{provide:Fi,useExisting:hd},{provide:os,useFactory:()=>h(_g,{optional:!0})??h(fd)},{provide:ls,useValue:Mg,multi:!0},{provide:vd,useValue:!0},{provide:cs,useClass:Rg}];for(let e of n)t.push(...e.\u0275providers);return qe(t)}function kD(n){return yd(da.Interceptors,n.map(t=>({provide:ls,useValue:t,multi:!0})))}var pd=new O("");function xD(){return yd(da.LegacyInterceptors,[{provide:pd,useFactory:Tg},{provide:ls,useExisting:pd,multi:!0}])}var pa=class extends ed{constructor(){super(...arguments),this.supportsDOMEvents=!0}},ga=class n extends pa{static makeCurrent(){Xu(new n)}onAndCancel(t,e,i){return t.addEventListener(e,i),()=>{t.removeEventListener(e,i)}}dispatchEvent(t,e){t.dispatchEvent(e)}remove(t){t.remove()}createElement(t,e){return e=e||this.getDefaultDocument(),e.createElement(t)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(t){return t.nodeType===Node.ELEMENT_NODE}isShadowRoot(t){return t instanceof DocumentFragment}getGlobalEventTarget(t,e){return e==="window"?window:e==="document"?t:e==="body"?t.body:null}getBaseHref(t){let e=Ng();return e==null?null:kg(e)}resetBaseElement(){Vi=null}getUserAgent(){return window.navigator.userAgent}getCookie(t){return es(document.cookie,t)}},Vi=null;function Ng(){return Vi=Vi||document.querySelector("base"),Vi?Vi.getAttribute("href"):null}function kg(n){return new URL(n,document.baseURI).pathname}var xg=(()=>{class n{build(){return new XMLHttpRequest}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})(),ma=new O(""),Td=(()=>{class n{constructor(e,i){this._zone=i,this._eventNameToPlugin=new Map,e.forEach(r=>{r.manager=this}),this._plugins=e.slice().reverse()}addEventListener(e,i,r){return this._findPluginFor(i).addEventListener(e,i,r)}getZone(){return this._zone}_findPluginFor(e){let i=this._eventNameToPlugin.get(e);if(i)return i;if(i=this._plugins.find(s=>s.supports(e)),!i)throw new j(5101,!1);return this._eventNameToPlugin.set(e,i),i}static{this.\u0275fac=function(i){return new(i||n)(C(ma),C($))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})(),us=class{constructor(t){this._doc=t}},ha="ng-app-id",Ed=(()=>{class n{constructor(e,i,r,s={}){this.doc=e,this.appId=i,this.nonce=r,this.platformId=s,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=ts(s),this.resetHostNodes()}addStyles(e){for(let i of e)this.changeUsageCount(i,1)===1&&this.onStyleAdded(i)}removeStyles(e){for(let i of e)this.changeUsageCount(i,-1)<=0&&this.onStyleRemoved(i)}ngOnDestroy(){let e=this.styleNodesInDOM;e&&(e.forEach(i=>i.remove()),e.clear());for(let i of this.getAllStyles())this.onStyleRemoved(i);this.resetHostNodes()}addHost(e){this.hostNodes.add(e);for(let i of this.getAllStyles())this.addStyleToHost(e,i)}removeHost(e){this.hostNodes.delete(e)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(e){for(let i of this.hostNodes)this.addStyleToHost(i,e)}onStyleRemoved(e){let i=this.styleRef;i.get(e)?.elements?.forEach(r=>r.remove()),i.delete(e)}collectServerRenderedStyles(){let e=this.doc.head?.querySelectorAll(`style[${ha}="${this.appId}"]`);if(e?.length){let i=new Map;return e.forEach(r=>{r.textContent!=null&&i.set(r.textContent,r)}),i}return null}changeUsageCount(e,i){let r=this.styleRef;if(r.has(e)){let s=r.get(e);return s.usage+=i,s.usage}return r.set(e,{usage:i,elements:[]}),i}getStyleElement(e,i){let r=this.styleNodesInDOM,s=r?.get(i);if(s?.parentNode===e)return r.delete(i),s.removeAttribute(ha),s;{let o=this.doc.createElement("style");return this.nonce&&o.setAttribute("nonce",this.nonce),o.textContent=i,this.platformIsServer&&o.setAttribute(ha,this.appId),e.appendChild(o),o}}addStyleToHost(e,i){let r=this.getStyleElement(e,i),s=this.styleRef,o=s.get(i)?.elements;o?o.push(r):s.set(i,{elements:[r],usage:1})}resetHostNodes(){let e=this.hostNodes;e.clear(),e.add(this.doc.head)}static{this.\u0275fac=function(i){return new(i||n)(C(G),C(qo),C(Jo,8),C(ct))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})(),fa={svg:"http://www.w3.org/2000/svg",xhtml:"http://www.w3.org/1999/xhtml",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/",math:"http://www.w3.org/1998/Math/MathML"},va=/%COMP%/g,Cd="%COMP%",Fg=`_nghost-${Cd}`,Lg=`_ngcontent-${Cd}`,Bg=!0,Vg=new O("",{providedIn:"root",factory:()=>Bg});function Ug(n){return Lg.replace(va,n)}function jg(n){return Fg.replace(va,n)}function Sd(n,t){return t.map(e=>e.replace(va,n))}var bd=(()=>{class n{constructor(e,i,r,s,o,c,a,l=null){this.eventManager=e,this.sharedStylesHost=i,this.appId=r,this.removeStylesOnCompDestroy=s,this.doc=o,this.platformId=c,this.ngZone=a,this.nonce=l,this.rendererByCompId=new Map,this.platformIsServer=ts(c),this.defaultRenderer=new Ui(e,o,a,this.platformIsServer)}createRenderer(e,i){if(!e||!i)return this.defaultRenderer;this.platformIsServer&&i.encapsulation===Si.ShadowDom&&(i=k(m({},i),{encapsulation:Si.Emulated}));let r=this.getOrCreateRenderer(e,i);return r instanceof ds?r.applyToHost(e):r instanceof ji&&r.applyStyles(),r}getOrCreateRenderer(e,i){let r=this.rendererByCompId,s=r.get(i.id);if(!s){let o=this.doc,c=this.ngZone,a=this.eventManager,l=this.sharedStylesHost,u=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(i.encapsulation){case Si.Emulated:s=new ds(a,l,i,this.appId,u,o,c,d);break;case Si.ShadowDom:return new _a(a,l,e,i,o,c,this.nonce,d);default:s=new ji(a,l,i,u,o,c,d);break}r.set(i.id,s)}return s}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(i){return new(i||n)(C(Td),C(Ed),C(qo),C(Vg),C(G),C(ct),C($),C(Jo))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})(),Ui=class{constructor(t,e,i,r){this.eventManager=t,this.doc=e,this.ngZone=i,this.platformIsServer=r,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(t,e){return e?this.doc.createElementNS(fa[e]||e,t):this.doc.createElement(t)}createComment(t){return this.doc.createComment(t)}createText(t){return this.doc.createTextNode(t)}appendChild(t,e){(wd(t)?t.content:t).appendChild(e)}insertBefore(t,e,i){t&&(wd(t)?t.content:t).insertBefore(e,i)}removeChild(t,e){e.remove()}selectRootElement(t,e){let i=typeof t=="string"?this.doc.querySelector(t):t;if(!i)throw new j(-5104,!1);return e||(i.textContent=""),i}parentNode(t){return t.parentNode}nextSibling(t){return t.nextSibling}setAttribute(t,e,i,r){if(r){e=r+":"+e;let s=fa[r];s?t.setAttributeNS(s,e,i):t.setAttribute(e,i)}else t.setAttribute(e,i)}removeAttribute(t,e,i){if(i){let r=fa[i];r?t.removeAttributeNS(r,e):t.removeAttribute(`${i}:${e}`)}else t.removeAttribute(e)}addClass(t,e){t.classList.add(e)}removeClass(t,e){t.classList.remove(e)}setStyle(t,e,i,r){r&(Oi.DashCase|Oi.Important)?t.style.setProperty(e,i,r&Oi.Important?"important":""):t.style[e]=i}removeStyle(t,e,i){i&Oi.DashCase?t.style.removeProperty(e):t.style[e]=""}setProperty(t,e,i){t!=null&&(t[e]=i)}setValue(t,e){t.nodeValue=e}listen(t,e,i){if(typeof t=="string"&&(t=Hn().getGlobalEventTarget(this.doc,t),!t))throw new Error(`Unsupported event target ${t} for event ${e}`);return this.eventManager.addEventListener(t,e,this.decoratePreventDefault(i))}decoratePreventDefault(t){return e=>{if(e==="__ngUnwrap__")return t;(this.platformIsServer?this.ngZone.runGuarded(()=>t(e)):t(e))===!1&&e.preventDefault()}}};function wd(n){return n.tagName==="TEMPLATE"&&n.content!==void 0}var _a=class extends Ui{constructor(t,e,i,r,s,o,c,a){super(t,s,o,a),this.sharedStylesHost=e,this.hostEl=i,this.shadowRoot=i.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);let l=Sd(r.id,r.styles);for(let u of l){let d=document.createElement("style");c&&d.setAttribute("nonce",c),d.textContent=u,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(t){return t===this.hostEl?this.shadowRoot:t}appendChild(t,e){return super.appendChild(this.nodeOrShadowRoot(t),e)}insertBefore(t,e,i){return super.insertBefore(this.nodeOrShadowRoot(t),e,i)}removeChild(t,e){return super.removeChild(null,e)}parentNode(t){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(t)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}},ji=class extends Ui{constructor(t,e,i,r,s,o,c,a){super(t,s,o,c),this.sharedStylesHost=e,this.removeStylesOnCompDestroy=r,this.styles=a?Sd(a,i.styles):i.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}},ds=class extends ji{constructor(t,e,i,r,s,o,c,a){let l=r+"-"+i.id;super(t,e,i,s,o,c,a,l),this.contentAttr=Ug(l),this.hostAttr=jg(l)}applyToHost(t){this.applyStyles(),this.setAttribute(t,this.hostAttr,"")}createElement(t,e){let i=super.createElement(t,e);return super.setAttribute(i,this.contentAttr,""),i}},$g=(()=>{class n extends us{constructor(e){super(e)}supports(e){return!0}addEventListener(e,i,r){return e.addEventListener(i,r,!1),()=>this.removeEventListener(e,i,r)}removeEventListener(e,i,r){return e.removeEventListener(i,r)}static{this.\u0275fac=function(i){return new(i||n)(C(G))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})(),Dd=["alt","control","meta","shift"],Hg={"\b":"Backspace"," ":"Tab","\x7F":"Delete","\x1B":"Escape",Del:"Delete",Esc:"Escape",Left:"ArrowLeft",Right:"ArrowRight",Up:"ArrowUp",Down:"ArrowDown",Menu:"ContextMenu",Scroll:"ScrollLock",Win:"OS"},Gg={alt:n=>n.altKey,control:n=>n.ctrlKey,meta:n=>n.metaKey,shift:n=>n.shiftKey},zg=(()=>{class n extends us{constructor(e){super(e)}supports(e){return n.parseEventName(e)!=null}addEventListener(e,i,r){let s=n.parseEventName(i),o=n.eventCallback(s.fullKey,r,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Hn().onAndCancel(e,s.domEventName,o))}static parseEventName(e){let i=e.toLowerCase().split("."),r=i.shift();if(i.length===0||!(r==="keydown"||r==="keyup"))return null;let s=n._normalizeKey(i.pop()),o="",c=i.indexOf("code");if(c>-1&&(i.splice(c,1),o="code."),Dd.forEach(l=>{let u=i.indexOf(l);u>-1&&(i.splice(u,1),o+=l+".")}),o+=s,i.length!=0||s.length===0)return null;let a={};return a.domEventName=r,a.fullKey=o,a}static matchEventFullKeyCode(e,i){let r=Hg[e.key]||e.key,s="";return i.indexOf("code.")>-1&&(r=e.code,s="code."),r==null||!r?!1:(r=r.toLowerCase(),r===" "?r="space":r==="."&&(r="dot"),Dd.forEach(o=>{if(o!==r){let c=Gg[o];c(e)&&(s+=o+".")}}),s+=r,s===i)}static eventCallback(e,i,r){return s=>{n.matchEventFullKeyCode(s,e)&&r.runGuarded(()=>i(s))}}static _normalizeKey(e){return e==="esc"?"escape":e}static{this.\u0275fac=function(i){return new(i||n)(C(G))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})();function sT(n,t){return Yu(m({rootComponent:n},Wg(t)))}function Wg(n){return{appProviders:[...Qg,...n?.providers??[]],platformProviders:Yg}}function qg(){ga.makeCurrent()}function Jg(){return new Wo}function Kg(){return Iu(document),document}var Yg=[{provide:ct,useValue:rd},{provide:Au,useValue:qg,multi:!0},{provide:G,useFactory:Kg,deps:[]}];var Qg=[{provide:Su,useValue:"root"},{provide:Wo,useFactory:Jg,deps:[]},{provide:ma,useClass:$g,multi:!0,deps:[G,$,ct]},{provide:ma,useClass:zg,multi:!0,deps:[G]},bd,Ed,Td,{provide:Vu,useExisting:bd},{provide:ns,useClass:xg,deps:[]},[]];var Id=(()=>{class n{constructor(e){this._doc=e}getTitle(){return this._doc.title}setTitle(e){this._doc.title=e||""}static{this.\u0275fac=function(i){return new(i||n)(C(G))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();var ya=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:function(i){let r=null;return i?r=new(i||n):r=C(Zg),r},providedIn:"root"})}}return n})(),Zg=(()=>{class n extends ya{constructor(e){super(),this._doc=e}sanitize(e,i){if(i==null)return null;switch(e){case wt.NONE:return i;case wt.HTML:return Bn(i,"HTML")?Ln(i):xu(this._doc,String(i)).toString();case wt.STYLE:return Bn(i,"Style")?Ln(i):i;case wt.SCRIPT:if(Bn(i,"Script"))return Ln(i);throw new j(5200,!1);case wt.URL:return Bn(i,"URL")?Ln(i):ku(String(i));case wt.RESOURCE_URL:if(Bn(i,"ResourceURL"))return Ln(i);throw new j(5201,!1);default:throw new j(5202,!1)}}bypassSecurityTrustHtml(e){return Ou(e)}bypassSecurityTrustStyle(e){return Ru(e)}bypassSecurityTrustScript(e){return Mu(e)}bypassSecurityTrustUrl(e){return Pu(e)}bypassSecurityTrustResourceUrl(e){return Nu(e)}static{this.\u0275fac=function(i){return new(i||n)(C(G))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();var A="primary",nr=Symbol("RouteTitle"),Ea=class{constructor(t){this.params=t||{}}has(t){return Object.prototype.hasOwnProperty.call(this.params,t)}get(t){if(this.has(t)){let e=this.params[t];return Array.isArray(e)?e[0]:e}return null}getAll(t){if(this.has(t)){let e=this.params[t];return Array.isArray(e)?e:[e]}return[]}get keys(){return Object.keys(this.params)}};function Kn(n){return new Ea(n)}function Xg(n,t,e){let i=e.path.split("/");if(i.length>n.length||e.pathMatch==="full"&&(t.hasChildren()||i.length<n.length))return null;let r={};for(let s=0;s<i.length;s++){let o=i[s],c=n[s];if(o[0]===":")r[o.substring(1)]=c;else if(o!==c.path)return null}return{consumed:n.slice(0,i.length),posParams:r}}function em(n,t){if(n.length!==t.length)return!1;for(let e=0;e<n.length;++e)if(!ut(n[e],t[e]))return!1;return!0}function ut(n,t){let e=n?Ca(n):void 0,i=t?Ca(t):void 0;if(!e||!i||e.length!=i.length)return!1;let r;for(let s=0;s<e.length;s++)if(r=e[s],!Vd(n[r],t[r]))return!1;return!0}function Ca(n){return[...Object.keys(n),...Object.getOwnPropertySymbols(n)]}function Vd(n,t){if(Array.isArray(n)&&Array.isArray(t)){if(n.length!==t.length)return!1;let e=[...n].sort(),i=[...t].sort();return e.every((r,s)=>i[s]===r)}else return n===t}function Ud(n){return n.length>0?n[n.length-1]:null}function Jt(n){return hu(n)?n:Qr(n)?Q(Promise.resolve(n)):b(n)}var tm={exact:$d,subset:Hd},jd={exact:nm,subset:im,ignored:()=>!0};function Od(n,t,e){return tm[e.paths](n.root,t.root,e.matrixParams)&&jd[e.queryParams](n.queryParams,t.queryParams)&&!(e.fragment==="exact"&&n.fragment!==t.fragment)}function nm(n,t){return ut(n,t)}function $d(n,t,e){if(!gn(n.segments,t.segments)||!ps(n.segments,t.segments,e)||n.numberOfChildren!==t.numberOfChildren)return!1;for(let i in t.children)if(!n.children[i]||!$d(n.children[i],t.children[i],e))return!1;return!0}function im(n,t){return Object.keys(t).length<=Object.keys(n).length&&Object.keys(t).every(e=>Vd(n[e],t[e]))}function Hd(n,t,e){return Gd(n,t,t.segments,e)}function Gd(n,t,e,i){if(n.segments.length>e.length){let r=n.segments.slice(0,e.length);return!(!gn(r,e)||t.hasChildren()||!ps(r,e,i))}else if(n.segments.length===e.length){if(!gn(n.segments,e)||!ps(n.segments,e,i))return!1;for(let r in t.children)if(!n.children[r]||!Hd(n.children[r],t.children[r],i))return!1;return!0}else{let r=e.slice(0,n.segments.length),s=e.slice(n.segments.length);return!gn(n.segments,r)||!ps(n.segments,r,i)||!n.children[A]?!1:Gd(n.children[A],t,s,i)}}function ps(n,t,e){return t.every((i,r)=>jd[e](n[r].parameters,i.parameters))}var At=class{constructor(t=new L([],{}),e={},i=null){this.root=t,this.queryParams=e,this.fragment=i}get queryParamMap(){return this._queryParamMap??=Kn(this.queryParams),this._queryParamMap}toString(){return om.serialize(this)}},L=class{constructor(t,e){this.segments=t,this.children=e,this.parent=null,Object.values(e).forEach(i=>i.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return gs(this)}},pn=class{constructor(t,e){this.path=t,this.parameters=e}get parameterMap(){return this._parameterMap??=Kn(this.parameters),this._parameterMap}toString(){return Wd(this)}};function rm(n,t){return gn(n,t)&&n.every((e,i)=>ut(e.parameters,t[i].parameters))}function gn(n,t){return n.length!==t.length?!1:n.every((e,i)=>e.path===t[i].path)}function sm(n,t){let e=[];return Object.entries(n.children).forEach(([i,r])=>{i===A&&(e=e.concat(t(r,i)))}),Object.entries(n.children).forEach(([i,r])=>{i!==A&&(e=e.concat(t(r,i)))}),e}var ir=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:()=>new Yn,providedIn:"root"})}}return n})(),Yn=class{parse(t){let e=new Ia(t);return new At(e.parseRootSegment(),e.parseQueryParams(),e.parseFragment())}serialize(t){let e=`/${$i(t.root,!0)}`,i=lm(t.queryParams),r=typeof t.fragment=="string"?`#${am(t.fragment)}`:"";return`${e}${i}${r}`}},om=new Yn;function gs(n){return n.segments.map(t=>Wd(t)).join("/")}function $i(n,t){if(!n.hasChildren())return gs(n);if(t){let e=n.children[A]?$i(n.children[A],!1):"",i=[];return Object.entries(n.children).forEach(([r,s])=>{r!==A&&i.push(`${r}:${$i(s,!1)}`)}),i.length>0?`${e}(${i.join("//")})`:e}else{let e=sm(n,(i,r)=>r===A?[$i(n.children[A],!1)]:[`${r}:${$i(i,!1)}`]);return Object.keys(n.children).length===1&&n.children[A]!=null?`${gs(n)}/${e[0]}`:`${gs(n)}/(${e.join("//")})`}}function zd(n){return encodeURIComponent(n).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function hs(n){return zd(n).replace(/%3B/gi,";")}function am(n){return encodeURI(n)}function Sa(n){return zd(n).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function ms(n){return decodeURIComponent(n)}function Rd(n){return ms(n.replace(/\+/g,"%20"))}function Wd(n){return`${Sa(n.path)}${cm(n.parameters)}`}function cm(n){return Object.entries(n).map(([t,e])=>`;${Sa(t)}=${Sa(e)}`).join("")}function lm(n){let t=Object.entries(n).map(([e,i])=>Array.isArray(i)?i.map(r=>`${hs(e)}=${hs(r)}`).join("&"):`${hs(e)}=${hs(i)}`).filter(e=>e);return t.length?`?${t.join("&")}`:""}var um=/^[^\/()?;#]+/;function ba(n){let t=n.match(um);return t?t[0]:""}var dm=/^[^\/()?;=#]+/;function hm(n){let t=n.match(dm);return t?t[0]:""}var fm=/^[^=?&#]+/;function pm(n){let t=n.match(fm);return t?t[0]:""}var gm=/^[^&#]+/;function mm(n){let t=n.match(gm);return t?t[0]:""}var Ia=class{constructor(t){this.url=t,this.remaining=t}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new L([],{}):new L([],this.parseChildren())}parseQueryParams(){let t={};if(this.consumeOptional("?"))do this.parseQueryParam(t);while(this.consumeOptional("&"));return t}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(this.remaining==="")return{};this.consumeOptional("/");let t=[];for(this.peekStartsWith("(")||t.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),t.push(this.parseSegment());let e={};this.peekStartsWith("/(")&&(this.capture("/"),e=this.parseParens(!0));let i={};return this.peekStartsWith("(")&&(i=this.parseParens(!1)),(t.length>0||Object.keys(e).length>0)&&(i[A]=new L(t,e)),i}parseSegment(){let t=ba(this.remaining);if(t===""&&this.peekStartsWith(";"))throw new j(4009,!1);return this.capture(t),new pn(ms(t),this.parseMatrixParams())}parseMatrixParams(){let t={};for(;this.consumeOptional(";");)this.parseParam(t);return t}parseParam(t){let e=hm(this.remaining);if(!e)return;this.capture(e);let i="";if(this.consumeOptional("=")){let r=ba(this.remaining);r&&(i=r,this.capture(i))}t[ms(e)]=ms(i)}parseQueryParam(t){let e=pm(this.remaining);if(!e)return;this.capture(e);let i="";if(this.consumeOptional("=")){let o=mm(this.remaining);o&&(i=o,this.capture(i))}let r=Rd(e),s=Rd(i);if(t.hasOwnProperty(r)){let o=t[r];Array.isArray(o)||(o=[o],t[r]=o),o.push(s)}else t[r]=s}parseParens(t){let e={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let i=ba(this.remaining),r=this.remaining[i.length];if(r!=="/"&&r!==")"&&r!==";")throw new j(4010,!1);let s;i.indexOf(":")>-1?(s=i.slice(0,i.indexOf(":")),this.capture(s),this.capture(":")):t&&(s=A);let o=this.parseChildren();e[s]=Object.keys(o).length===1?o[A]:new L([],o),this.consumeOptional("//")}return e}peekStartsWith(t){return this.remaining.startsWith(t)}consumeOptional(t){return this.peekStartsWith(t)?(this.remaining=this.remaining.substring(t.length),!0):!1}capture(t){if(!this.consumeOptional(t))throw new j(4011,!1)}};function qd(n){return n.segments.length>0?new L([],{[A]:n}):n}function Jd(n){let t={};for(let[i,r]of Object.entries(n.children)){let s=Jd(r);if(i===A&&s.segments.length===0&&s.hasChildren())for(let[o,c]of Object.entries(s.children))t[o]=c;else(s.segments.length>0||s.hasChildren())&&(t[i]=s)}let e=new L(n.segments,t);return _m(e)}function _m(n){if(n.numberOfChildren===1&&n.children[A]){let t=n.children[A];return new L(n.segments.concat(t.segments),t.children)}return n}function mn(n){return n instanceof At}function vm(n,t,e=null,i=null){let r=Kd(n);return Yd(r,t,e,i)}function Kd(n){let t;function e(s){let o={};for(let a of s.children){let l=e(a);o[a.outlet]=l}let c=new L(s.url,o);return s===n&&(t=c),c}let i=e(n.root),r=qd(i);return t??r}function Yd(n,t,e,i){let r=n;for(;r.parent;)r=r.parent;if(t.length===0)return wa(r,r,r,e,i);let s=ym(t);if(s.toRoot())return wa(r,r,new L([],{}),e,i);let o=bm(s,r,n),c=o.processChildren?zi(o.segmentGroup,o.index,s.commands):Zd(o.segmentGroup,o.index,s.commands);return wa(r,o.segmentGroup,c,e,i)}function _s(n){return typeof n=="object"&&n!=null&&!n.outlets&&!n.segmentPath}function Ji(n){return typeof n=="object"&&n!=null&&n.outlets}function wa(n,t,e,i,r){let s={};i&&Object.entries(i).forEach(([a,l])=>{s[a]=Array.isArray(l)?l.map(u=>`${u}`):`${l}`});let o;n===t?o=e:o=Qd(n,t,e);let c=qd(Jd(o));return new At(c,s,r)}function Qd(n,t,e){let i={};return Object.entries(n.children).forEach(([r,s])=>{s===t?i[r]=e:i[r]=Qd(s,t,e)}),new L(n.segments,i)}var vs=class{constructor(t,e,i){if(this.isAbsolute=t,this.numberOfDoubleDots=e,this.commands=i,t&&i.length>0&&_s(i[0]))throw new j(4003,!1);let r=i.find(Ji);if(r&&r!==Ud(i))throw new j(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function ym(n){if(typeof n[0]=="string"&&n.length===1&&n[0]==="/")return new vs(!0,0,n);let t=0,e=!1,i=n.reduce((r,s,o)=>{if(typeof s=="object"&&s!=null){if(s.outlets){let c={};return Object.entries(s.outlets).forEach(([a,l])=>{c[a]=typeof l=="string"?l.split("/"):l}),[...r,{outlets:c}]}if(s.segmentPath)return[...r,s.segmentPath]}return typeof s!="string"?[...r,s]:o===0?(s.split("/").forEach((c,a)=>{a==0&&c==="."||(a==0&&c===""?e=!0:c===".."?t++:c!=""&&r.push(c))}),r):[...r,s]},[]);return new vs(e,t,i)}var Wn=class{constructor(t,e,i){this.segmentGroup=t,this.processChildren=e,this.index=i}};function bm(n,t,e){if(n.isAbsolute)return new Wn(t,!0,0);if(!e)return new Wn(t,!1,NaN);if(e.parent===null)return new Wn(e,!0,0);let i=_s(n.commands[0])?0:1,r=e.segments.length-1+i;return wm(e,r,n.numberOfDoubleDots)}function wm(n,t,e){let i=n,r=t,s=e;for(;s>r;){if(s-=r,i=i.parent,!i)throw new j(4005,!1);r=i.segments.length}return new Wn(i,!1,r-s)}function Dm(n){return Ji(n[0])?n[0].outlets:{[A]:n}}function Zd(n,t,e){if(n??=new L([],{}),n.segments.length===0&&n.hasChildren())return zi(n,t,e);let i=Tm(n,t,e),r=e.slice(i.commandIndex);if(i.match&&i.pathIndex<n.segments.length){let s=new L(n.segments.slice(0,i.pathIndex),{});return s.children[A]=new L(n.segments.slice(i.pathIndex),n.children),zi(s,0,r)}else return i.match&&r.length===0?new L(n.segments,{}):i.match&&!n.hasChildren()?Aa(n,t,e):i.match?zi(n,0,r):Aa(n,t,e)}function zi(n,t,e){if(e.length===0)return new L(n.segments,{});{let i=Dm(e),r={};if(Object.keys(i).some(s=>s!==A)&&n.children[A]&&n.numberOfChildren===1&&n.children[A].segments.length===0){let s=zi(n.children[A],t,e);return new L(n.segments,s.children)}return Object.entries(i).forEach(([s,o])=>{typeof o=="string"&&(o=[o]),o!==null&&(r[s]=Zd(n.children[s],t,o))}),Object.entries(n.children).forEach(([s,o])=>{i[s]===void 0&&(r[s]=o)}),new L(n.segments,r)}}function Tm(n,t,e){let i=0,r=t,s={match:!1,pathIndex:0,commandIndex:0};for(;r<n.segments.length;){if(i>=e.length)return s;let o=n.segments[r],c=e[i];if(Ji(c))break;let a=`${c}`,l=i<e.length-1?e[i+1]:null;if(r>0&&a===void 0)break;if(a&&l&&typeof l=="object"&&l.outlets===void 0){if(!Pd(a,l,o))return s;i+=2}else{if(!Pd(a,{},o))return s;i++}r++}return{match:!0,pathIndex:r,commandIndex:i}}function Aa(n,t,e){let i=n.segments.slice(0,t),r=0;for(;r<e.length;){let s=e[r];if(Ji(s)){let a=Em(s.outlets);return new L(i,a)}if(r===0&&_s(e[0])){let a=n.segments[t];i.push(new pn(a.path,Md(e[0]))),r++;continue}let o=Ji(s)?s.outlets[A]:`${s}`,c=r<e.length-1?e[r+1]:null;o&&c&&_s(c)?(i.push(new pn(o,Md(c))),r+=2):(i.push(new pn(o,{})),r++)}return new L(i,{})}function Em(n){let t={};return Object.entries(n).forEach(([e,i])=>{typeof i=="string"&&(i=[i]),i!==null&&(t[e]=Aa(new L([],{}),0,i))}),t}function Md(n){let t={};return Object.entries(n).forEach(([e,i])=>t[e]=`${i}`),t}function Pd(n,t,e){return n==e.path&&ut(t,e.parameters)}var Wi="imperative",re=function(n){return n[n.NavigationStart=0]="NavigationStart",n[n.NavigationEnd=1]="NavigationEnd",n[n.NavigationCancel=2]="NavigationCancel",n[n.NavigationError=3]="NavigationError",n[n.RoutesRecognized=4]="RoutesRecognized",n[n.ResolveStart=5]="ResolveStart",n[n.ResolveEnd=6]="ResolveEnd",n[n.GuardsCheckStart=7]="GuardsCheckStart",n[n.GuardsCheckEnd=8]="GuardsCheckEnd",n[n.RouteConfigLoadStart=9]="RouteConfigLoadStart",n[n.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",n[n.ChildActivationStart=11]="ChildActivationStart",n[n.ChildActivationEnd=12]="ChildActivationEnd",n[n.ActivationStart=13]="ActivationStart",n[n.ActivationEnd=14]="ActivationEnd",n[n.Scroll=15]="Scroll",n[n.NavigationSkipped=16]="NavigationSkipped",n}(re||{}),Be=class{constructor(t,e){this.id=t,this.url=e}},Qn=class extends Be{constructor(t,e,i="imperative",r=null){super(t,e),this.type=re.NavigationStart,this.navigationTrigger=i,this.restoredState=r}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},dt=class extends Be{constructor(t,e,i){super(t,e),this.urlAfterRedirects=i,this.type=re.NavigationEnd}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},Pe=function(n){return n[n.Redirect=0]="Redirect",n[n.SupersededByNewNavigation=1]="SupersededByNewNavigation",n[n.NoDataFromResolver=2]="NoDataFromResolver",n[n.GuardRejected=3]="GuardRejected",n}(Pe||{}),ys=function(n){return n[n.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",n[n.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",n}(ys||{}),It=class extends Be{constructor(t,e,i,r){super(t,e),this.reason=i,this.code=r,this.type=re.NavigationCancel}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}},qt=class extends Be{constructor(t,e,i,r){super(t,e),this.reason=i,this.code=r,this.type=re.NavigationSkipped}},Ki=class extends Be{constructor(t,e,i,r){super(t,e),this.error=i,this.target=r,this.type=re.NavigationError}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},bs=class extends Be{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=re.RoutesRecognized}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Oa=class extends Be{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=re.GuardsCheckStart}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Ra=class extends Be{constructor(t,e,i,r,s){super(t,e),this.urlAfterRedirects=i,this.state=r,this.shouldActivate=s,this.type=re.GuardsCheckEnd}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},Ma=class extends Be{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=re.ResolveStart}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Pa=class extends Be{constructor(t,e,i,r){super(t,e),this.urlAfterRedirects=i,this.state=r,this.type=re.ResolveEnd}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Na=class{constructor(t){this.route=t,this.type=re.RouteConfigLoadStart}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},ka=class{constructor(t){this.route=t,this.type=re.RouteConfigLoadEnd}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},xa=class{constructor(t){this.snapshot=t,this.type=re.ChildActivationStart}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Fa=class{constructor(t){this.snapshot=t,this.type=re.ChildActivationEnd}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},La=class{constructor(t){this.snapshot=t,this.type=re.ActivationStart}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Ba=class{constructor(t){this.snapshot=t,this.type=re.ActivationEnd}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},ws=class{constructor(t,e,i){this.routerEvent=t,this.position=e,this.anchor=i,this.type=re.Scroll}toString(){let t=this.position?`${this.position[0]}, ${this.position[1]}`:null;return`Scroll(anchor: '${this.anchor}', position: '${t}')`}},Yi=class{},Zn=class{constructor(t,e){this.url=t,this.navigationBehaviorOptions=e}};function Cm(n,t){return n.providers&&!n._injector&&(n._injector=Qo(n.providers,t,`Route: ${n.path}`)),n._injector??t}function Ze(n){return n.outlet||A}function Sm(n,t){let e=n.filter(i=>Ze(i)===t);return e.push(...n.filter(i=>Ze(i)!==t)),e}function rr(n){if(!n)return null;if(n.routeConfig?._injector)return n.routeConfig._injector;for(let t=n.parent;t;t=t.parent){let e=t.routeConfig;if(e?._loadedInjector)return e._loadedInjector;if(e?._injector)return e._injector}return null}var Va=class{get injector(){return rr(this.route?.snapshot)??this.rootInjector}set injector(t){}constructor(t){this.rootInjector=t,this.outlet=null,this.route=null,this.children=new sr(this.rootInjector),this.attachRef=null}},sr=(()=>{class n{constructor(e){this.rootInjector=e,this.contexts=new Map}onChildOutletCreated(e,i){let r=this.getOrCreateContext(e);r.outlet=i,this.contexts.set(e,r)}onChildOutletDestroyed(e){let i=this.getContext(e);i&&(i.outlet=null,i.attachRef=null)}onOutletDeactivated(){let e=this.contexts;return this.contexts=new Map,e}onOutletReAttached(e){this.contexts=e}getOrCreateContext(e){let i=this.getContext(e);return i||(i=new Va(this.rootInjector),this.contexts.set(e,i)),i}getContext(e){return this.contexts.get(e)||null}static{this.\u0275fac=function(i){return new(i||n)(C(ot))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),Ds=class{constructor(t){this._root=t}get root(){return this._root.value}parent(t){let e=this.pathFromRoot(t);return e.length>1?e[e.length-2]:null}children(t){let e=Ua(t,this._root);return e?e.children.map(i=>i.value):[]}firstChild(t){let e=Ua(t,this._root);return e&&e.children.length>0?e.children[0].value:null}siblings(t){let e=ja(t,this._root);return e.length<2?[]:e[e.length-2].children.map(r=>r.value).filter(r=>r!==t)}pathFromRoot(t){return ja(t,this._root).map(e=>e.value)}};function Ua(n,t){if(n===t.value)return t;for(let e of t.children){let i=Ua(n,e);if(i)return i}return null}function ja(n,t){if(n===t.value)return[t];for(let e of t.children){let i=ja(n,e);if(i.length)return i.unshift(t),i}return[]}var Me=class{constructor(t,e){this.value=t,this.children=e}toString(){return`TreeNode(${this.value})`}};function zn(n){let t={};return n&&n.children.forEach(e=>t[e.value.outlet]=e),t}var Ts=class extends Ds{constructor(t,e){super(t),this.snapshot=e,Ya(this,t)}toString(){return this.snapshot.toString()}};function Xd(n){let t=Im(n),e=new be([new pn("",{})]),i=new be({}),r=new be({}),s=new be({}),o=new be(""),c=new ht(e,i,s,o,r,A,n,t.root);return c.snapshot=t.root,new Ts(new Me(c,[]),t)}function Im(n){let t={},e={},i={},r="",s=new qn([],t,i,r,e,A,n,null,{});return new Cs("",new Me(s,[]))}var ht=class{constructor(t,e,i,r,s,o,c,a){this.urlSubject=t,this.paramsSubject=e,this.queryParamsSubject=i,this.fragmentSubject=r,this.dataSubject=s,this.outlet=o,this.component=c,this._futureSnapshot=a,this.title=this.dataSubject?.pipe(I(l=>l[nr]))??b(void 0),this.url=t,this.params=e,this.queryParams=i,this.fragment=r,this.data=s}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe(I(t=>Kn(t))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(I(t=>Kn(t))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function Es(n,t,e="emptyOnly"){let i,{routeConfig:r}=n;return t!==null&&(e==="always"||r?.path===""||!t.component&&!t.routeConfig?.loadComponent)?i={params:m(m({},t.params),n.params),data:m(m({},t.data),n.data),resolve:m(m(m(m({},n.data),t.data),r?.data),n._resolvedData)}:i={params:m({},n.params),data:m({},n.data),resolve:m(m({},n.data),n._resolvedData??{})},r&&th(r)&&(i.resolve[nr]=r.title),i}var qn=class{get title(){return this.data?.[nr]}constructor(t,e,i,r,s,o,c,a,l){this.url=t,this.params=e,this.queryParams=i,this.fragment=r,this.data=s,this.outlet=o,this.component=c,this.routeConfig=a,this._resolve=l}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=Kn(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=Kn(this.queryParams),this._queryParamMap}toString(){let t=this.url.map(i=>i.toString()).join("/"),e=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${t}', path:'${e}')`}},Cs=class extends Ds{constructor(t,e){super(e),this.url=t,Ya(this,e)}toString(){return eh(this._root)}};function Ya(n,t){t.value._routerState=n,t.children.forEach(e=>Ya(n,e))}function eh(n){let t=n.children.length>0?` { ${n.children.map(eh).join(", ")} } `:"";return`${n.value}${t}`}function Da(n){if(n.snapshot){let t=n.snapshot,e=n._futureSnapshot;n.snapshot=e,ut(t.queryParams,e.queryParams)||n.queryParamsSubject.next(e.queryParams),t.fragment!==e.fragment&&n.fragmentSubject.next(e.fragment),ut(t.params,e.params)||n.paramsSubject.next(e.params),em(t.url,e.url)||n.urlSubject.next(e.url),ut(t.data,e.data)||n.dataSubject.next(e.data)}else n.snapshot=n._futureSnapshot,n.dataSubject.next(n._futureSnapshot.data)}function $a(n,t){let e=ut(n.params,t.params)&&rm(n.url,t.url),i=!n.parent!=!t.parent;return e&&!i&&(!n.parent||$a(n.parent,t.parent))}function th(n){return typeof n.title=="string"||n.title===null}var Am=(()=>{class n{constructor(){this.activated=null,this._activatedRoute=null,this.name=A,this.activateEvents=new B,this.deactivateEvents=new B,this.attachEvents=new B,this.detachEvents=new B,this.parentContexts=h(sr),this.location=h(Jr),this.changeDetector=h(Ct),this.inputBinder=h(Os,{optional:!0}),this.supportsBindingToComponentInputs=!0}get activatedComponentRef(){return this.activated}ngOnChanges(e){if(e.name){let{firstChange:i,previousValue:r}=e.name;if(i)return;this.isTrackedInParentContexts(r)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(r)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(e){return this.parentContexts.getContext(e)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let e=this.parentContexts.getContext(this.name);e?.route&&(e.attachRef?this.attach(e.attachRef,e.route):this.activateWith(e.route,e.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new j(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new j(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new j(4012,!1);this.location.detach();let e=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(e.instance),e}attach(e,i){this.activated=e,this._activatedRoute=i,this.location.insert(e.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(e.instance)}deactivate(){if(this.activated){let e=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(e)}}activateWith(e,i){if(this.isActivated)throw new j(4013,!1);this._activatedRoute=e;let r=this.location,o=e.snapshot.component,c=this.parentContexts.getOrCreateContext(this.name).children,a=new Ha(e,c,r.injector);this.activated=r.createComponent(o,{index:r.length,injector:a,environmentInjector:i}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["router-outlet"]],inputs:{name:"name"},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],standalone:!0,features:[at]})}}return n})(),Ha=class n{__ngOutletInjector(t){return new n(this.route,this.childContexts,t)}constructor(t,e,i){this.route=t,this.childContexts=e,this.parent=i}get(t,e){return t===ht?this.route:t===sr?this.childContexts:this.parent.get(t,e)}},Os=new O(""),Nd=(()=>{class n{constructor(){this.outletDataSubscriptions=new Map}bindActivatedRouteToOutletComponent(e){this.unsubscribeFromRouteData(e),this.subscribeToRouteData(e)}unsubscribeFromRouteData(e){this.outletDataSubscriptions.get(e)?.unsubscribe(),this.outletDataSubscriptions.delete(e)}subscribeToRouteData(e){let{activatedRoute:i}=e,r=Ei([i.queryParams,i.params,i.data]).pipe(le(([s,o,c],a)=>(c=m(m(m({},s),o),c),a===0?b(c):Promise.resolve(c)))).subscribe(s=>{if(!e.isActivated||!e.activatedComponentRef||e.activatedRoute!==i||i.component===null){this.unsubscribeFromRouteData(e);return}let o=Zu(i.component);if(!o){this.unsubscribeFromRouteData(e);return}for(let{templateName:c}of o.inputs)e.activatedComponentRef.setInput(c,s[c])});this.outletDataSubscriptions.set(e,r)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})();function Om(n,t,e){let i=Qi(n,t._root,e?e._root:void 0);return new Ts(i,t)}function Qi(n,t,e){if(e&&n.shouldReuseRoute(t.value,e.value.snapshot)){let i=e.value;i._futureSnapshot=t.value;let r=Rm(n,t,e);return new Me(i,r)}else{if(n.shouldAttach(t.value)){let s=n.retrieve(t.value);if(s!==null){let o=s.route;return o.value._futureSnapshot=t.value,o.children=t.children.map(c=>Qi(n,c)),o}}let i=Mm(t.value),r=t.children.map(s=>Qi(n,s));return new Me(i,r)}}function Rm(n,t,e){return t.children.map(i=>{for(let r of e.children)if(n.shouldReuseRoute(i.value,r.value.snapshot))return Qi(n,i,r);return Qi(n,i)})}function Mm(n){return new ht(new be(n.url),new be(n.params),new be(n.queryParams),new be(n.fragment),new be(n.data),n.outlet,n.component,n)}var Zi=class{constructor(t,e){this.redirectTo=t,this.navigationBehaviorOptions=e}},nh="ngNavigationCancelingError";function Ss(n,t){let{redirectTo:e,navigationBehaviorOptions:i}=mn(t)?{redirectTo:t,navigationBehaviorOptions:void 0}:t,r=ih(!1,Pe.Redirect);return r.url=e,r.navigationBehaviorOptions=i,r}function ih(n,t){let e=new Error(`NavigationCancelingError: ${n||""}`);return e[nh]=!0,e.cancellationCode=t,e}function Pm(n){return rh(n)&&mn(n.url)}function rh(n){return!!n&&n[nh]}var Nm=(n,t,e,i)=>I(r=>(new Ga(t,r.targetRouterState,r.currentRouterState,e,i).activate(n),r)),Ga=class{constructor(t,e,i,r,s){this.routeReuseStrategy=t,this.futureState=e,this.currState=i,this.forwardEvent=r,this.inputBindingEnabled=s}activate(t){let e=this.futureState._root,i=this.currState?this.currState._root:null;this.deactivateChildRoutes(e,i,t),Da(this.futureState.root),this.activateChildRoutes(e,i,t)}deactivateChildRoutes(t,e,i){let r=zn(e);t.children.forEach(s=>{let o=s.value.outlet;this.deactivateRoutes(s,r[o],i),delete r[o]}),Object.values(r).forEach(s=>{this.deactivateRouteAndItsChildren(s,i)})}deactivateRoutes(t,e,i){let r=t.value,s=e?e.value:null;if(r===s)if(r.component){let o=i.getContext(r.outlet);o&&this.deactivateChildRoutes(t,e,o.children)}else this.deactivateChildRoutes(t,e,i);else s&&this.deactivateRouteAndItsChildren(e,i)}deactivateRouteAndItsChildren(t,e){t.value.component&&this.routeReuseStrategy.shouldDetach(t.value.snapshot)?this.detachAndStoreRouteSubtree(t,e):this.deactivateRouteAndOutlet(t,e)}detachAndStoreRouteSubtree(t,e){let i=e.getContext(t.value.outlet),r=i&&t.value.component?i.children:e,s=zn(t);for(let o of Object.values(s))this.deactivateRouteAndItsChildren(o,r);if(i&&i.outlet){let o=i.outlet.detach(),c=i.children.onOutletDeactivated();this.routeReuseStrategy.store(t.value.snapshot,{componentRef:o,route:t,contexts:c})}}deactivateRouteAndOutlet(t,e){let i=e.getContext(t.value.outlet),r=i&&t.value.component?i.children:e,s=zn(t);for(let o of Object.values(s))this.deactivateRouteAndItsChildren(o,r);i&&(i.outlet&&(i.outlet.deactivate(),i.children.onOutletDeactivated()),i.attachRef=null,i.route=null)}activateChildRoutes(t,e,i){let r=zn(e);t.children.forEach(s=>{this.activateRoutes(s,r[s.value.outlet],i),this.forwardEvent(new Ba(s.value.snapshot))}),t.children.length&&this.forwardEvent(new Fa(t.value.snapshot))}activateRoutes(t,e,i){let r=t.value,s=e?e.value:null;if(Da(r),r===s)if(r.component){let o=i.getOrCreateContext(r.outlet);this.activateChildRoutes(t,e,o.children)}else this.activateChildRoutes(t,e,i);else if(r.component){let o=i.getOrCreateContext(r.outlet);if(this.routeReuseStrategy.shouldAttach(r.snapshot)){let c=this.routeReuseStrategy.retrieve(r.snapshot);this.routeReuseStrategy.store(r.snapshot,null),o.children.onOutletReAttached(c.contexts),o.attachRef=c.componentRef,o.route=c.route.value,o.outlet&&o.outlet.attach(c.componentRef,c.route.value),Da(c.route.value),this.activateChildRoutes(t,null,o.children)}else o.attachRef=null,o.route=r,o.outlet&&o.outlet.activateWith(r,o.injector),this.activateChildRoutes(t,null,o.children)}else this.activateChildRoutes(t,null,i)}},Is=class{constructor(t){this.path=t,this.route=this.path[this.path.length-1]}},Jn=class{constructor(t,e){this.component=t,this.route=e}};function km(n,t,e){let i=n._root,r=t?t._root:null;return Hi(i,r,e,[i.value])}function xm(n){let t=n.routeConfig?n.routeConfig.canActivateChild:null;return!t||t.length===0?null:{node:n,guards:t}}function ei(n,t){let e=Symbol(),i=t.get(n,e);return i===e?typeof n=="function"&&!Eu(n)?n:t.get(n):i}function Hi(n,t,e,i,r={canDeactivateChecks:[],canActivateChecks:[]}){let s=zn(t);return n.children.forEach(o=>{Fm(o,s[o.value.outlet],e,i.concat([o.value]),r),delete s[o.value.outlet]}),Object.entries(s).forEach(([o,c])=>qi(c,e.getContext(o),r)),r}function Fm(n,t,e,i,r={canDeactivateChecks:[],canActivateChecks:[]}){let s=n.value,o=t?t.value:null,c=e?e.getContext(n.value.outlet):null;if(o&&s.routeConfig===o.routeConfig){let a=Lm(o,s,s.routeConfig.runGuardsAndResolvers);a?r.canActivateChecks.push(new Is(i)):(s.data=o.data,s._resolvedData=o._resolvedData),s.component?Hi(n,t,c?c.children:null,i,r):Hi(n,t,e,i,r),a&&c&&c.outlet&&c.outlet.isActivated&&r.canDeactivateChecks.push(new Jn(c.outlet.component,o))}else o&&qi(t,c,r),r.canActivateChecks.push(new Is(i)),s.component?Hi(n,null,c?c.children:null,i,r):Hi(n,null,e,i,r);return r}function Lm(n,t,e){if(typeof e=="function")return e(n,t);switch(e){case"pathParamsChange":return!gn(n.url,t.url);case"pathParamsOrQueryParamsChange":return!gn(n.url,t.url)||!ut(n.queryParams,t.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!$a(n,t)||!ut(n.queryParams,t.queryParams);case"paramsChange":default:return!$a(n,t)}}function qi(n,t,e){let i=zn(n),r=n.value;Object.entries(i).forEach(([s,o])=>{r.component?t?qi(o,t.children.getContext(s),e):qi(o,null,e):qi(o,t,e)}),r.component?t&&t.outlet&&t.outlet.isActivated?e.canDeactivateChecks.push(new Jn(t.outlet.component,r)):e.canDeactivateChecks.push(new Jn(null,r)):e.canDeactivateChecks.push(new Jn(null,r))}function or(n){return typeof n=="function"}function Bm(n){return typeof n=="boolean"}function Vm(n){return n&&or(n.canLoad)}function Um(n){return n&&or(n.canActivate)}function jm(n){return n&&or(n.canActivateChild)}function $m(n){return n&&or(n.canDeactivate)}function Hm(n){return n&&or(n.canMatch)}function sh(n){return n instanceof fu||n?.name==="EmptyError"}var fs=Symbol("INITIAL_VALUE");function Xn(){return le(n=>Ei(n.map(t=>t.pipe(ge(1),$o(fs)))).pipe(I(t=>{for(let e of t)if(e!==!0){if(e===fs)return fs;if(e===!1||Gm(e))return e}return!0}),ce(t=>t!==fs),ge(1)))}function Gm(n){return mn(n)||n instanceof Zi}function zm(n,t){return Ce(e=>{let{targetSnapshot:i,currentSnapshot:r,guards:{canActivateChecks:s,canDeactivateChecks:o}}=e;return o.length===0&&s.length===0?b(k(m({},e),{guardsResult:!0})):Wm(o,i,r,n).pipe(Ce(c=>c&&Bm(c)?qm(i,s,n,t):b(c)),I(c=>k(m({},e),{guardsResult:c})))})}function Wm(n,t,e,i){return Q(n).pipe(Ce(r=>Zm(r.component,r.route,e,t,i)),Vt(r=>r!==!0,!0))}function qm(n,t,e,i){return Q(t).pipe(Bt(r=>gu(Km(r.route.parent,i),Jm(r.route,i),Qm(n,r.path,e),Ym(n,r.route,e))),Vt(r=>r!==!0,!0))}function Jm(n,t){return n!==null&&t&&t(new La(n)),b(!0)}function Km(n,t){return n!==null&&t&&t(new xa(n)),b(!0)}function Ym(n,t,e){let i=t.routeConfig?t.routeConfig.canActivate:null;if(!i||i.length===0)return b(!0);let r=i.map(s=>Bo(()=>{let o=rr(t)??e,c=ei(s,o),a=Um(c)?c.canActivate(t,n):ke(o,()=>c(t,n));return Jt(a).pipe(Vt())}));return b(r).pipe(Xn())}function Qm(n,t,e){let i=t[t.length-1],s=t.slice(0,t.length-1).reverse().map(o=>xm(o)).filter(o=>o!==null).map(o=>Bo(()=>{let c=o.guards.map(a=>{let l=rr(o.node)??e,u=ei(a,l),d=jm(u)?u.canActivateChild(i,n):ke(l,()=>u(i,n));return Jt(d).pipe(Vt())});return b(c).pipe(Xn())}));return b(s).pipe(Xn())}function Zm(n,t,e,i,r){let s=t&&t.routeConfig?t.routeConfig.canDeactivate:null;if(!s||s.length===0)return b(!0);let o=s.map(c=>{let a=rr(t)??r,l=ei(c,a),u=$m(l)?l.canDeactivate(n,t,e,i):ke(a,()=>l(n,t,e,i));return Jt(u).pipe(Vt())});return b(o).pipe(Xn())}function Xm(n,t,e,i){let r=t.canLoad;if(r===void 0||r.length===0)return b(!0);let s=r.map(o=>{let c=ei(o,n),a=Vm(c)?c.canLoad(t,e):ke(n,()=>c(t,e));return Jt(a)});return b(s).pipe(Xn(),oh(i))}function oh(n){return cu(U(t=>{if(typeof t!="boolean")throw Ss(n,t)}),I(t=>t===!0))}function e_(n,t,e,i){let r=t.canMatch;if(!r||r.length===0)return b(!0);let s=r.map(o=>{let c=ei(o,n),a=Hm(c)?c.canMatch(t,e):ke(n,()=>c(t,e));return Jt(a)});return b(s).pipe(Xn(),oh(i))}var Xi=class{constructor(t){this.segmentGroup=t||null}},er=class extends Error{constructor(t){super(),this.urlTree=t}};function Gn(n){return un(new Xi(n))}function t_(n){return un(new j(4e3,!1))}function n_(n){return un(ih(!1,Pe.GuardRejected))}var za=class{constructor(t,e){this.urlSerializer=t,this.urlTree=e}lineralizeSegments(t,e){let i=[],r=e.root;for(;;){if(i=i.concat(r.segments),r.numberOfChildren===0)return b(i);if(r.numberOfChildren>1||!r.children[A])return t_(`${t.redirectTo}`);r=r.children[A]}}applyRedirectCommands(t,e,i,r,s){if(typeof e!="string"){let c=e,{queryParams:a,fragment:l,routeConfig:u,url:d,outlet:p,params:g,data:w,title:v}=r,_=ke(s,()=>c({params:g,data:w,queryParams:a,fragment:l,routeConfig:u,url:d,outlet:p,title:v}));if(_ instanceof At)throw new er(_);e=_}let o=this.applyRedirectCreateUrlTree(e,this.urlSerializer.parse(e),t,i);if(e[0]==="/")throw new er(o);return o}applyRedirectCreateUrlTree(t,e,i,r){let s=this.createSegmentGroup(t,e.root,i,r);return new At(s,this.createQueryParams(e.queryParams,this.urlTree.queryParams),e.fragment)}createQueryParams(t,e){let i={};return Object.entries(t).forEach(([r,s])=>{if(typeof s=="string"&&s[0]===":"){let c=s.substring(1);i[r]=e[c]}else i[r]=s}),i}createSegmentGroup(t,e,i,r){let s=this.createSegments(t,e.segments,i,r),o={};return Object.entries(e.children).forEach(([c,a])=>{o[c]=this.createSegmentGroup(t,a,i,r)}),new L(s,o)}createSegments(t,e,i,r){return e.map(s=>s.path[0]===":"?this.findPosParam(t,s,r):this.findOrReturn(s,i))}findPosParam(t,e,i){let r=i[e.path.substring(1)];if(!r)throw new j(4001,!1);return r}findOrReturn(t,e){let i=0;for(let r of e){if(r.path===t.path)return e.splice(i),r;i++}return t}},Wa={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function i_(n,t,e,i,r){let s=ah(n,t,e);return s.matched?(i=Cm(t,i),e_(i,t,e,r).pipe(I(o=>o===!0?s:m({},Wa)))):b(s)}function ah(n,t,e){if(t.path==="**")return r_(e);if(t.path==="")return t.pathMatch==="full"&&(n.hasChildren()||e.length>0)?m({},Wa):{matched:!0,consumedSegments:[],remainingSegments:e,parameters:{},positionalParamSegments:{}};let r=(t.matcher||Xg)(e,n,t);if(!r)return m({},Wa);let s={};Object.entries(r.posParams??{}).forEach(([c,a])=>{s[c]=a.path});let o=r.consumed.length>0?m(m({},s),r.consumed[r.consumed.length-1].parameters):s;return{matched:!0,consumedSegments:r.consumed,remainingSegments:e.slice(r.consumed.length),parameters:o,positionalParamSegments:r.posParams??{}}}function r_(n){return{matched:!0,parameters:n.length>0?Ud(n).parameters:{},consumedSegments:n,remainingSegments:[],positionalParamSegments:{}}}function kd(n,t,e,i){return e.length>0&&a_(n,e,i)?{segmentGroup:new L(t,o_(i,new L(e,n.children))),slicedSegments:[]}:e.length===0&&c_(n,e,i)?{segmentGroup:new L(n.segments,s_(n,e,i,n.children)),slicedSegments:e}:{segmentGroup:new L(n.segments,n.children),slicedSegments:e}}function s_(n,t,e,i){let r={};for(let s of e)if(Rs(n,t,s)&&!i[Ze(s)]){let o=new L([],{});r[Ze(s)]=o}return m(m({},i),r)}function o_(n,t){let e={};e[A]=t;for(let i of n)if(i.path===""&&Ze(i)!==A){let r=new L([],{});e[Ze(i)]=r}return e}function a_(n,t,e){return e.some(i=>Rs(n,t,i)&&Ze(i)!==A)}function c_(n,t,e){return e.some(i=>Rs(n,t,i))}function Rs(n,t,e){return(n.hasChildren()||t.length>0)&&e.pathMatch==="full"?!1:e.path===""}function l_(n,t,e){return t.length===0&&!n.children[e]}var qa=class{};function u_(n,t,e,i,r,s,o="emptyOnly"){return new Ja(n,t,e,i,r,o,s).recognize()}var d_=31,Ja=class{constructor(t,e,i,r,s,o,c){this.injector=t,this.configLoader=e,this.rootComponentType=i,this.config=r,this.urlTree=s,this.paramsInheritanceStrategy=o,this.urlSerializer=c,this.applyRedirects=new za(this.urlSerializer,this.urlTree),this.absoluteRedirectCount=0,this.allowRedirects=!0}noMatchError(t){return new j(4002,`'${t.segmentGroup}'`)}recognize(){let t=kd(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(t).pipe(I(({children:e,rootSnapshot:i})=>{let r=new Me(i,e),s=new Cs("",r),o=vm(i,[],this.urlTree.queryParams,this.urlTree.fragment);return o.queryParams=this.urlTree.queryParams,s.url=this.urlSerializer.serialize(o),{state:s,tree:o}}))}match(t){let e=new qn([],Object.freeze({}),Object.freeze(m({},this.urlTree.queryParams)),this.urlTree.fragment,Object.freeze({}),A,this.rootComponentType,null,{});return this.processSegmentGroup(this.injector,this.config,t,A,e).pipe(I(i=>({children:i,rootSnapshot:e})),De(i=>{if(i instanceof er)return this.urlTree=i.urlTree,this.match(i.urlTree.root);throw i instanceof Xi?this.noMatchError(i):i}))}processSegmentGroup(t,e,i,r,s){return i.segments.length===0&&i.hasChildren()?this.processChildren(t,e,i,s):this.processSegment(t,e,i,i.segments,r,!0,s).pipe(I(o=>o instanceof Me?[o]:[]))}processChildren(t,e,i,r){let s=[];for(let o of Object.keys(i.children))o==="primary"?s.unshift(o):s.push(o);return Q(s).pipe(Bt(o=>{let c=i.children[o],a=Sm(e,o);return this.processSegmentGroup(t,a,c,o,r)}),Du((o,c)=>(o.push(...c),o)),Uo(null),wu(),Ce(o=>{if(o===null)return Gn(i);let c=ch(o);return h_(c),b(c)}))}processSegment(t,e,i,r,s,o,c){return Q(e).pipe(Bt(a=>this.processSegmentAgainstRoute(a._injector??t,e,a,i,r,s,o,c).pipe(De(l=>{if(l instanceof Xi)return b(null);throw l}))),Vt(a=>!!a),De(a=>{if(sh(a))return l_(i,r,s)?b(new qa):Gn(i);throw a}))}processSegmentAgainstRoute(t,e,i,r,s,o,c,a){return Ze(i)!==o&&(o===A||!Rs(r,s,i))?Gn(r):i.redirectTo===void 0?this.matchSegmentAgainstRoute(t,r,i,s,o,a):this.allowRedirects&&c?this.expandSegmentAgainstRouteUsingRedirect(t,r,e,i,s,o,a):Gn(r)}expandSegmentAgainstRouteUsingRedirect(t,e,i,r,s,o,c){let{matched:a,parameters:l,consumedSegments:u,positionalParamSegments:d,remainingSegments:p}=ah(e,r,s);if(!a)return Gn(e);typeof r.redirectTo=="string"&&r.redirectTo[0]==="/"&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>d_&&(this.allowRedirects=!1));let g=new qn(s,l,Object.freeze(m({},this.urlTree.queryParams)),this.urlTree.fragment,xd(r),Ze(r),r.component??r._loadedComponent??null,r,Fd(r)),w=Es(g,c,this.paramsInheritanceStrategy);g.params=Object.freeze(w.params),g.data=Object.freeze(w.data);let v=this.applyRedirects.applyRedirectCommands(u,r.redirectTo,d,g,t);return this.applyRedirects.lineralizeSegments(r,v).pipe(Ce(_=>this.processSegment(t,i,e,_.concat(p),o,!1,c)))}matchSegmentAgainstRoute(t,e,i,r,s,o){let c=i_(e,i,r,t,this.urlSerializer);return i.path==="**"&&(e.children={}),c.pipe(le(a=>a.matched?(t=i._injector??t,this.getChildConfig(t,i,r).pipe(le(({routes:l})=>{let u=i._loadedInjector??t,{parameters:d,consumedSegments:p,remainingSegments:g}=a,w=new qn(p,d,Object.freeze(m({},this.urlTree.queryParams)),this.urlTree.fragment,xd(i),Ze(i),i.component??i._loadedComponent??null,i,Fd(i)),v=Es(w,o,this.paramsInheritanceStrategy);w.params=Object.freeze(v.params),w.data=Object.freeze(v.data);let{segmentGroup:_,slicedSegments:S}=kd(e,p,g,l);if(S.length===0&&_.hasChildren())return this.processChildren(u,l,_,w).pipe(I(D=>new Me(w,D)));if(l.length===0&&S.length===0)return b(new Me(w,[]));let x=Ze(i)===s;return this.processSegment(u,l,_,S,x?A:s,!0,w).pipe(I(D=>new Me(w,D instanceof Me?[D]:[])))}))):Gn(e)))}getChildConfig(t,e,i){return e.children?b({routes:e.children,injector:t}):e.loadChildren?e._loadedRoutes!==void 0?b({routes:e._loadedRoutes,injector:e._loadedInjector}):Xm(t,e,i,this.urlSerializer).pipe(Ce(r=>r?this.configLoader.loadChildren(t,e).pipe(U(s=>{e._loadedRoutes=s.routes,e._loadedInjector=s.injector})):n_(e))):b({routes:[],injector:t})}};function h_(n){n.sort((t,e)=>t.value.outlet===A?-1:e.value.outlet===A?1:t.value.outlet.localeCompare(e.value.outlet))}function f_(n){let t=n.value.routeConfig;return t&&t.path===""}function ch(n){let t=[],e=new Set;for(let i of n){if(!f_(i)){t.push(i);continue}let r=t.find(s=>i.value.routeConfig===s.value.routeConfig);r!==void 0?(r.children.push(...i.children),e.add(r)):t.push(i)}for(let i of e){let r=ch(i.children);t.push(new Me(i.value,r))}return t.filter(i=>!e.has(i))}function xd(n){return n.data||{}}function Fd(n){return n.resolve||{}}function p_(n,t,e,i,r,s){return Ce(o=>u_(n,t,e,i,o.extractedUrl,r,s).pipe(I(({state:c,tree:a})=>k(m({},o),{targetSnapshot:c,urlAfterRedirects:a}))))}function g_(n,t){return Ce(e=>{let{targetSnapshot:i,guards:{canActivateChecks:r}}=e;if(!r.length)return b(e);let s=new Set(r.map(a=>a.route)),o=new Set;for(let a of s)if(!o.has(a))for(let l of lh(a))o.add(l);let c=0;return Q(o).pipe(Bt(a=>s.has(a)?m_(a,i,n,t):(a.data=Es(a,a.parent,n).resolve,b(void 0))),U(()=>c++),jo(1),Ce(a=>c===o.size?b(e):rt))})}function lh(n){let t=n.children.map(e=>lh(e)).flat();return[n,...t]}function m_(n,t,e,i){let r=n.routeConfig,s=n._resolve;return r?.title!==void 0&&!th(r)&&(s[nr]=r.title),__(s,n,t,i).pipe(I(o=>(n._resolvedData=o,n.data=Es(n,n.parent,e).resolve,null)))}function __(n,t,e,i){let r=Ca(n);if(r.length===0)return b({});let s={};return Q(r).pipe(Ce(o=>v_(n[o],t,e,i).pipe(Vt(),U(c=>{if(c instanceof Zi)throw Ss(new Yn,c);s[o]=c}))),jo(1),vu(s),De(o=>sh(o)?rt:un(o)))}function v_(n,t,e,i){let r=rr(t)??i,s=ei(n,r),o=s.resolve?s.resolve(t,e):ke(r,()=>s(t,e));return Jt(o)}function Ta(n){return le(t=>{let e=n(t);return e?Q(e).pipe(I(()=>t)):b(t)})}var uh=(()=>{class n{buildTitle(e){let i,r=e.root;for(;r!==void 0;)i=this.getResolvedTitleForRoute(r)??i,r=r.children.find(s=>s.outlet===A);return i}getResolvedTitleForRoute(e){return e.data[nr]}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:()=>h(y_),providedIn:"root"})}}return n})(),y_=(()=>{class n extends uh{constructor(e){super(),this.title=e}updateTitle(e){let i=this.buildTitle(e);i!==void 0&&this.title.setTitle(i)}static{this.\u0275fac=function(i){return new(i||n)(C(Id))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),ar=new O("",{providedIn:"root",factory:()=>({})}),b_=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=We({type:n,selectors:[["ng-component"]],standalone:!0,features:[Ke],decls:1,vars:0,template:function(i,r){i&1&&jt(0,"router-outlet")},dependencies:[Am],encapsulation:2})}}return n})();function Qa(n){let t=n.children&&n.children.map(Qa),e=t?k(m({},n),{children:t}):m({},n);return!e.component&&!e.loadComponent&&(t||e.loadChildren)&&e.outlet&&e.outlet!==A&&(e.component=b_),e}var tr=new O(""),Za=(()=>{class n{constructor(){this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap,this.compiler=h(Xr)}loadComponent(e){if(this.componentLoaders.get(e))return this.componentLoaders.get(e);if(e._loadedComponent)return b(e._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(e);let i=Jt(e.loadComponent()).pipe(I(dh),U(s=>{this.onLoadEndListener&&this.onLoadEndListener(e),e._loadedComponent=s}),yt(()=>{this.componentLoaders.delete(e)})),r=new ko(i,()=>new N).pipe(No());return this.componentLoaders.set(e,r),r}loadChildren(e,i){if(this.childrenLoaders.get(i))return this.childrenLoaders.get(i);if(i._loadedRoutes)return b({routes:i._loadedRoutes,injector:i._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(i);let s=w_(i,this.compiler,e,this.onLoadEndListener).pipe(yt(()=>{this.childrenLoaders.delete(i)})),o=new ko(s,()=>new N).pipe(No());return this.childrenLoaders.set(i,o),o}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function w_(n,t,e,i){return Jt(n.loadChildren()).pipe(I(dh),Ce(r=>r instanceof ju||Array.isArray(r)?b(r):Q(t.compileModuleAsync(r))),I(r=>{i&&i(n);let s,o,c=!1;return Array.isArray(r)?(o=r,c=!0):(s=r.create(e).injector,o=s.get(tr,[],{optional:!0,self:!0}).flat()),{routes:o.map(Qa),injector:s}}))}function D_(n){return n&&typeof n=="object"&&"default"in n}function dh(n){return D_(n)?n.default:n}var Xa=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:()=>h(T_),providedIn:"root"})}}return n})(),T_=(()=>{class n{shouldProcessUrl(e){return!0}extract(e){return e}merge(e,i){return e}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),hh=new O(""),fh=new O("");function E_(n,t,e){let i=n.get(fh),r=n.get(G);return n.get($).runOutsideAngular(()=>{if(!r.startViewTransition||i.skipNextTransition)return i.skipNextTransition=!1,new Promise(l=>setTimeout(l));let s,o=new Promise(l=>{s=l}),c=r.startViewTransition(()=>(s(),C_(n))),{onViewTransitionCreated:a}=i;return a&&ke(n,()=>a({transition:c,from:t,to:e})),o})}function C_(n){return new Promise(t=>{$u({read:()=>setTimeout(t)},{injector:n})})}var S_=new O(""),ec=(()=>{class n{get hasRequestedNavigation(){return this.navigationId!==0}constructor(){this.currentNavigation=null,this.currentTransition=null,this.lastSuccessfulNavigation=null,this.events=new N,this.transitionAbortSubject=new N,this.configLoader=h(Za),this.environmentInjector=h(ot),this.urlSerializer=h(ir),this.rootContexts=h(sr),this.location=h(ki),this.inputBindingEnabled=h(Os,{optional:!0})!==null,this.titleStrategy=h(uh),this.options=h(ar,{optional:!0})||{},this.paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly",this.urlHandlingStrategy=h(Xa),this.createViewTransition=h(hh,{optional:!0}),this.navigationErrorHandler=h(S_,{optional:!0}),this.navigationId=0,this.afterPreactivation=()=>b(void 0),this.rootComponentType=null;let e=r=>this.events.next(new Na(r)),i=r=>this.events.next(new ka(r));this.configLoader.onLoadEndListener=i,this.configLoader.onLoadStartListener=e}complete(){this.transitions?.complete()}handleNavigationRequest(e){let i=++this.navigationId;this.transitions?.next(k(m(m({},this.transitions.value),e),{id:i}))}setupNavigations(e,i,r){return this.transitions=new be({id:0,currentUrlTree:i,currentRawUrl:i,extractedUrl:this.urlHandlingStrategy.extract(i),urlAfterRedirects:this.urlHandlingStrategy.extract(i),rawUrl:i,extras:{},resolve:()=>{},reject:()=>{},promise:Promise.resolve(!0),source:Wi,restoredState:null,currentSnapshot:r.snapshot,targetSnapshot:null,currentRouterState:r,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe(ce(s=>s.id!==0),I(s=>k(m({},s),{extractedUrl:this.urlHandlingStrategy.extract(s.rawUrl)})),le(s=>{let o=!1,c=!1;return b(s).pipe(le(a=>{if(this.navigationId>s.id)return this.cancelNavigationTransition(s,"",Pe.SupersededByNewNavigation),rt;this.currentTransition=s,this.currentNavigation={id:a.id,initialUrl:a.rawUrl,extractedUrl:a.extractedUrl,targetBrowserUrl:typeof a.extras.browserUrl=="string"?this.urlSerializer.parse(a.extras.browserUrl):a.extras.browserUrl,trigger:a.source,extras:a.extras,previousNavigation:this.lastSuccessfulNavigation?k(m({},this.lastSuccessfulNavigation),{previousNavigation:null}):null};let l=!e.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),u=a.extras.onSameUrlNavigation??e.onSameUrlNavigation;if(!l&&u!=="reload"){let d="";return this.events.next(new qt(a.id,this.urlSerializer.serialize(a.rawUrl),d,ys.IgnoredSameUrlNavigation)),a.resolve(!1),rt}if(this.urlHandlingStrategy.shouldProcessUrl(a.rawUrl))return b(a).pipe(le(d=>{let p=this.transitions?.getValue();return this.events.next(new Qn(d.id,this.urlSerializer.serialize(d.extractedUrl),d.source,d.restoredState)),p!==this.transitions?.getValue()?rt:Promise.resolve(d)}),p_(this.environmentInjector,this.configLoader,this.rootComponentType,e.config,this.urlSerializer,this.paramsInheritanceStrategy),U(d=>{s.targetSnapshot=d.targetSnapshot,s.urlAfterRedirects=d.urlAfterRedirects,this.currentNavigation=k(m({},this.currentNavigation),{finalUrl:d.urlAfterRedirects});let p=new bs(d.id,this.urlSerializer.serialize(d.extractedUrl),this.urlSerializer.serialize(d.urlAfterRedirects),d.targetSnapshot);this.events.next(p)}));if(l&&this.urlHandlingStrategy.shouldProcessUrl(a.currentRawUrl)){let{id:d,extractedUrl:p,source:g,restoredState:w,extras:v}=a,_=new Qn(d,this.urlSerializer.serialize(p),g,w);this.events.next(_);let S=Xd(this.rootComponentType).snapshot;return this.currentTransition=s=k(m({},a),{targetSnapshot:S,urlAfterRedirects:p,extras:k(m({},v),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.finalUrl=p,b(s)}else{let d="";return this.events.next(new qt(a.id,this.urlSerializer.serialize(a.extractedUrl),d,ys.IgnoredByUrlHandlingStrategy)),a.resolve(!1),rt}}),U(a=>{let l=new Oa(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot);this.events.next(l)}),I(a=>(this.currentTransition=s=k(m({},a),{guards:km(a.targetSnapshot,a.currentSnapshot,this.rootContexts)}),s)),zm(this.environmentInjector,a=>this.events.next(a)),U(a=>{if(s.guardsResult=a.guardsResult,a.guardsResult&&typeof a.guardsResult!="boolean")throw Ss(this.urlSerializer,a.guardsResult);let l=new Ra(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects),a.targetSnapshot,!!a.guardsResult);this.events.next(l)}),ce(a=>a.guardsResult?!0:(this.cancelNavigationTransition(a,"",Pe.GuardRejected),!1)),Ta(a=>{if(a.guards.canActivateChecks.length)return b(a).pipe(U(l=>{let u=new Ma(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(u)}),le(l=>{let u=!1;return b(l).pipe(g_(this.paramsInheritanceStrategy,this.environmentInjector),U({next:()=>u=!0,complete:()=>{u||this.cancelNavigationTransition(l,"",Pe.NoDataFromResolver)}}))}),U(l=>{let u=new Pa(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(u)}))}),Ta(a=>{let l=u=>{let d=[];u.routeConfig?.loadComponent&&!u.routeConfig._loadedComponent&&d.push(this.configLoader.loadComponent(u.routeConfig).pipe(U(p=>{u.component=p}),I(()=>{})));for(let p of u.children)d.push(...l(p));return d};return Ei(l(a.targetSnapshot.root)).pipe(Uo(null),ge(1))}),Ta(()=>this.afterPreactivation()),le(()=>{let{currentSnapshot:a,targetSnapshot:l}=s,u=this.createViewTransition?.(this.environmentInjector,a.root,l.root);return u?Q(u).pipe(I(()=>s)):b(s)}),I(a=>{let l=Om(e.routeReuseStrategy,a.targetSnapshot,a.currentRouterState);return this.currentTransition=s=k(m({},a),{targetRouterState:l}),this.currentNavigation.targetRouterState=l,s}),U(()=>{this.events.next(new Yi)}),Nm(this.rootContexts,e.routeReuseStrategy,a=>this.events.next(a),this.inputBindingEnabled),ge(1),U({next:a=>{o=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new dt(a.id,this.urlSerializer.serialize(a.extractedUrl),this.urlSerializer.serialize(a.urlAfterRedirects))),this.titleStrategy?.updateTitle(a.targetRouterState.snapshot),a.resolve(!0)},complete:()=>{o=!0}}),W(this.transitionAbortSubject.pipe(U(a=>{throw a}))),yt(()=>{!o&&!c&&this.cancelNavigationTransition(s,"",Pe.SupersededByNewNavigation),this.currentTransition?.id===s.id&&(this.currentNavigation=null,this.currentTransition=null)}),De(a=>{if(c=!0,rh(a))this.events.next(new It(s.id,this.urlSerializer.serialize(s.extractedUrl),a.message,a.cancellationCode)),Pm(a)?this.events.next(new Zn(a.url,a.navigationBehaviorOptions)):s.resolve(!1);else{let l=new Ki(s.id,this.urlSerializer.serialize(s.extractedUrl),a,s.targetSnapshot??void 0);try{let u=ke(this.environmentInjector,()=>this.navigationErrorHandler?.(l));if(u instanceof Zi){let{message:d,cancellationCode:p}=Ss(this.urlSerializer,u);this.events.next(new It(s.id,this.urlSerializer.serialize(s.extractedUrl),d,p)),this.events.next(new Zn(u.redirectTo,u.navigationBehaviorOptions))}else{this.events.next(l);let d=e.errorHandler(a);s.resolve(!!d)}}catch(u){this.options.resolveNavigationPromiseOnError?s.resolve(!1):s.reject(u)}}return rt}))}))}cancelNavigationTransition(e,i,r){let s=new It(e.id,this.urlSerializer.serialize(e.extractedUrl),i,r);this.events.next(s),e.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){let e=this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))),i=this.currentNavigation?.targetBrowserUrl??this.currentNavigation?.extractedUrl;return e.toString()!==i?.toString()&&!this.currentNavigation?.extras.skipLocationChange}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function I_(n){return n!==Wi}var A_=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:()=>h(O_),providedIn:"root"})}}return n})(),Ka=class{shouldDetach(t){return!1}store(t,e){}shouldAttach(t){return!1}retrieve(t){return null}shouldReuseRoute(t,e){return t.routeConfig===e.routeConfig}},O_=(()=>{class n extends Ka{static{this.\u0275fac=(()=>{let e;return function(r){return(e||(e=Ut(n)))(r||n)}})()}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),ph=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:()=>h(R_),providedIn:"root"})}}return n})(),R_=(()=>{class n extends ph{constructor(){super(...arguments),this.location=h(ki),this.urlSerializer=h(ir),this.options=h(ar,{optional:!0})||{},this.canceledNavigationResolution=this.options.canceledNavigationResolution||"replace",this.urlHandlingStrategy=h(Xa),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.currentUrlTree=new At,this.rawUrlTree=this.currentUrlTree,this.currentPageId=0,this.lastSuccessfulId=-1,this.routerState=Xd(null),this.stateMemento=this.createStateMemento()}getCurrentUrlTree(){return this.currentUrlTree}getRawUrlTree(){return this.rawUrlTree}restoredState(){return this.location.getState()}get browserPageId(){return this.canceledNavigationResolution!=="computed"?this.currentPageId:this.restoredState()?.\u0275routerPageId??this.currentPageId}getRouterState(){return this.routerState}createStateMemento(){return{rawUrlTree:this.rawUrlTree,currentUrlTree:this.currentUrlTree,routerState:this.routerState}}registerNonRouterCurrentEntryChangeListener(e){return this.location.subscribe(i=>{i.type==="popstate"&&e(i.url,i.state)})}handleRouterEvent(e,i){if(e instanceof Qn)this.stateMemento=this.createStateMemento();else if(e instanceof qt)this.rawUrlTree=i.initialUrl;else if(e instanceof bs){if(this.urlUpdateStrategy==="eager"&&!i.extras.skipLocationChange){let r=this.urlHandlingStrategy.merge(i.finalUrl,i.initialUrl);this.setBrowserUrl(i.targetBrowserUrl??r,i)}}else e instanceof Yi?(this.currentUrlTree=i.finalUrl,this.rawUrlTree=this.urlHandlingStrategy.merge(i.finalUrl,i.initialUrl),this.routerState=i.targetRouterState,this.urlUpdateStrategy==="deferred"&&!i.extras.skipLocationChange&&this.setBrowserUrl(i.targetBrowserUrl??this.rawUrlTree,i)):e instanceof It&&(e.code===Pe.GuardRejected||e.code===Pe.NoDataFromResolver)?this.restoreHistory(i):e instanceof Ki?this.restoreHistory(i,!0):e instanceof dt&&(this.lastSuccessfulId=e.id,this.currentPageId=this.browserPageId)}setBrowserUrl(e,i){let r=e instanceof At?this.urlSerializer.serialize(e):e;if(this.location.isCurrentPathEqualTo(r)||i.extras.replaceUrl){let s=this.browserPageId,o=m(m({},i.extras.state),this.generateNgRouterState(i.id,s));this.location.replaceState(r,"",o)}else{let s=m(m({},i.extras.state),this.generateNgRouterState(i.id,this.browserPageId+1));this.location.go(r,"",s)}}restoreHistory(e,i=!1){if(this.canceledNavigationResolution==="computed"){let r=this.browserPageId,s=this.currentPageId-r;s!==0?this.location.historyGo(s):this.currentUrlTree===e.finalUrl&&s===0&&(this.resetState(e),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(i&&this.resetState(e),this.resetUrlToCurrentUrlTree())}resetState(e){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,e.finalUrl??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(e,i){return this.canceledNavigationResolution==="computed"?{navigationId:e,\u0275routerPageId:i}:{navigationId:e}}static{this.\u0275fac=(()=>{let e;return function(r){return(e||(e=Ut(n)))(r||n)}})()}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),Gi=function(n){return n[n.COMPLETE=0]="COMPLETE",n[n.FAILED=1]="FAILED",n[n.REDIRECTING=2]="REDIRECTING",n}(Gi||{});function gh(n,t){n.events.pipe(ce(e=>e instanceof dt||e instanceof It||e instanceof Ki||e instanceof qt),I(e=>e instanceof dt||e instanceof qt?Gi.COMPLETE:(e instanceof It?e.code===Pe.Redirect||e.code===Pe.SupersededByNewNavigation:!1)?Gi.REDIRECTING:Gi.FAILED),ce(e=>e!==Gi.REDIRECTING),ge(1)).subscribe(()=>{t()})}function M_(n){throw n}var P_={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},N_={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"},Xe=(()=>{class n{get currentUrlTree(){return this.stateManager.getCurrentUrlTree()}get rawUrlTree(){return this.stateManager.getRawUrlTree()}get events(){return this._events}get routerState(){return this.stateManager.getRouterState()}constructor(){this.disposed=!1,this.console=h(Yr),this.stateManager=h(ph),this.options=h(ar,{optional:!0})||{},this.pendingTasks=h(Ai),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.navigationTransitions=h(ec),this.urlSerializer=h(ir),this.location=h(ki),this.urlHandlingStrategy=h(Xa),this._events=new N,this.errorHandler=this.options.errorHandler||M_,this.navigated=!1,this.routeReuseStrategy=h(A_),this.onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore",this.config=h(tr,{optional:!0})?.flat()??[],this.componentInputBindingEnabled=!!h(Os,{optional:!0}),this.eventsSubscription=new au,this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this,this.currentUrlTree,this.routerState).subscribe({error:e=>{this.console.warn(e)}}),this.subscribeToNavigationEvents()}subscribeToNavigationEvents(){let e=this.navigationTransitions.events.subscribe(i=>{try{let r=this.navigationTransitions.currentTransition,s=this.navigationTransitions.currentNavigation;if(r!==null&&s!==null){if(this.stateManager.handleRouterEvent(i,s),i instanceof It&&i.code!==Pe.Redirect&&i.code!==Pe.SupersededByNewNavigation)this.navigated=!0;else if(i instanceof dt)this.navigated=!0;else if(i instanceof Zn){let o=i.navigationBehaviorOptions,c=this.urlHandlingStrategy.merge(i.url,r.currentRawUrl),a=m({browserUrl:r.extras.browserUrl,info:r.extras.info,skipLocationChange:r.extras.skipLocationChange,replaceUrl:r.extras.replaceUrl||this.urlUpdateStrategy==="eager"||I_(r.source)},o);this.scheduleNavigation(c,Wi,null,a,{resolve:r.resolve,reject:r.reject,promise:r.promise})}}x_(i)&&this._events.next(i)}catch(r){this.navigationTransitions.transitionAbortSubject.next(r)}});this.eventsSubscription.add(e)}resetRootComponentType(e){this.routerState.root.component=e,this.navigationTransitions.rootComponentType=e}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),Wi,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((e,i)=>{setTimeout(()=>{this.navigateToSyncWithBrowser(e,"popstate",i)},0)})}navigateToSyncWithBrowser(e,i,r){let s={replaceUrl:!0},o=r?.navigationId?r:null;if(r){let a=m({},r);delete a.navigationId,delete a.\u0275routerPageId,Object.keys(a).length!==0&&(s.state=a)}let c=this.parseUrl(e);this.scheduleNavigation(c,i,o,s)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(e){this.config=e.map(Qa),this.navigated=!1}ngOnDestroy(){this.dispose()}dispose(){this.navigationTransitions.complete(),this.nonRouterCurrentEntryChangeSubscription&&(this.nonRouterCurrentEntryChangeSubscription.unsubscribe(),this.nonRouterCurrentEntryChangeSubscription=void 0),this.disposed=!0,this.eventsSubscription.unsubscribe()}createUrlTree(e,i={}){let{relativeTo:r,queryParams:s,fragment:o,queryParamsHandling:c,preserveFragment:a}=i,l=a?this.currentUrlTree.fragment:o,u=null;switch(c??this.options.defaultQueryParamsHandling){case"merge":u=m(m({},this.currentUrlTree.queryParams),s);break;case"preserve":u=this.currentUrlTree.queryParams;break;default:u=s||null}u!==null&&(u=this.removeEmptyProps(u));let d;try{let p=r?r.snapshot:this.routerState.snapshot.root;d=Kd(p)}catch{(typeof e[0]!="string"||e[0][0]!=="/")&&(e=[]),d=this.currentUrlTree.root}return Yd(d,e,u,l??null)}navigateByUrl(e,i={skipLocationChange:!1}){let r=mn(e)?e:this.parseUrl(e),s=this.urlHandlingStrategy.merge(r,this.rawUrlTree);return this.scheduleNavigation(s,Wi,null,i)}navigate(e,i={skipLocationChange:!1}){return k_(e),this.navigateByUrl(this.createUrlTree(e,i),i)}serializeUrl(e){return this.urlSerializer.serialize(e)}parseUrl(e){try{return this.urlSerializer.parse(e)}catch{return this.urlSerializer.parse("/")}}isActive(e,i){let r;if(i===!0?r=m({},P_):i===!1?r=m({},N_):r=i,mn(e))return Od(this.currentUrlTree,e,r);let s=this.parseUrl(e);return Od(this.currentUrlTree,s,r)}removeEmptyProps(e){return Object.entries(e).reduce((i,[r,s])=>(s!=null&&(i[r]=s),i),{})}scheduleNavigation(e,i,r,s,o){if(this.disposed)return Promise.resolve(!1);let c,a,l;o?(c=o.resolve,a=o.reject,l=o.promise):l=new Promise((d,p)=>{c=d,a=p});let u=this.pendingTasks.add();return gh(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(u))}),this.navigationTransitions.handleNavigationRequest({source:i,restoredState:r,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:e,extras:s,resolve:c,reject:a,promise:l,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),l.catch(d=>Promise.reject(d))}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function k_(n){for(let t=0;t<n.length;t++)if(n[t]==null)throw new j(4008,!1)}function x_(n){return!(n instanceof Yi)&&!(n instanceof Zn)}var ET=(()=>{class n{constructor(e,i,r,s,o,c){this.router=e,this.route=i,this.tabIndexAttribute=r,this.renderer=s,this.el=o,this.locationStrategy=c,this.href=null,this.onChanges=new N,this.preserveFragment=!1,this.skipLocationChange=!1,this.replaceUrl=!1,this.routerLinkInput=null;let a=o.nativeElement.tagName?.toLowerCase();this.isAnchorElement=a==="a"||a==="area",this.isAnchorElement?this.subscription=e.events.subscribe(l=>{l instanceof dt&&this.updateHref()}):this.setTabIndexIfNotOnNativeEl("0")}setTabIndexIfNotOnNativeEl(e){this.tabIndexAttribute!=null||this.isAnchorElement||this.applyAttributeValue("tabindex",e)}ngOnChanges(e){this.isAnchorElement&&this.updateHref(),this.onChanges.next(this)}set routerLink(e){e==null?(this.routerLinkInput=null,this.setTabIndexIfNotOnNativeEl(null)):(mn(e)?this.routerLinkInput=e:this.routerLinkInput=Array.isArray(e)?e:[e],this.setTabIndexIfNotOnNativeEl("0"))}onClick(e,i,r,s,o){let c=this.urlTree;if(c===null||this.isAnchorElement&&(e!==0||i||r||s||o||typeof this.target=="string"&&this.target!="_self"))return!0;let a={skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info};return this.router.navigateByUrl(c,a),!this.isAnchorElement}ngOnDestroy(){this.subscription?.unsubscribe()}updateHref(){let e=this.urlTree;this.href=e!==null&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(e)):null;let i=this.href===null?null:Fu(this.href,this.el.nativeElement.tagName.toLowerCase(),"href");this.applyAttributeValue("href",i)}applyAttributeValue(e,i){let r=this.renderer,s=this.el.nativeElement;i!==null?r.setAttribute(s,e,i):r.removeAttribute(s,e)}get urlTree(){return this.routerLinkInput===null?null:mn(this.routerLinkInput)?this.routerLinkInput:this.router.createUrlTree(this.routerLinkInput,{relativeTo:this.relativeTo!==void 0?this.relativeTo:this.route,queryParams:this.queryParams,fragment:this.fragment,queryParamsHandling:this.queryParamsHandling,preserveFragment:this.preserveFragment})}static{this.\u0275fac=function(i){return new(i||n)(R(Xe),R(ht),zo("tabindex"),R(Vn),R(ie),R(Ni))}}static{this.\u0275dir=F({type:n,selectors:[["","routerLink",""]],hostVars:1,hostBindings:function(i,r){i&1&&ue("click",function(o){return r.onClick(o.button,o.ctrlKey,o.shiftKey,o.altKey,o.metaKey)}),i&2&&Te("target",r.target)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[2,"preserveFragment","preserveFragment",jn],skipLocationChange:[2,"skipLocationChange","skipLocationChange",jn],replaceUrl:[2,"replaceUrl","replaceUrl",jn],routerLink:"routerLink"},standalone:!0,features:[Uu,at]})}}return n})();var As=class{};var F_=(()=>{class n{constructor(e,i,r,s,o){this.router=e,this.injector=r,this.preloadingStrategy=s,this.loader=o}setUpPreloading(){this.subscription=this.router.events.pipe(ce(e=>e instanceof dt),Bt(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(e,i){let r=[];for(let s of i){s.providers&&!s._injector&&(s._injector=Qo(s.providers,e,`Route: ${s.path}`));let o=s._injector??e,c=s._loadedInjector??o;(s.loadChildren&&!s._loadedRoutes&&s.canLoad===void 0||s.loadComponent&&!s._loadedComponent)&&r.push(this.preloadConfig(o,s)),(s.children||s._loadedRoutes)&&r.push(this.processRoutes(c,s.children??s._loadedRoutes))}return Q(r).pipe(Lo())}preloadConfig(e,i){return this.preloadingStrategy.preload(i,()=>{let r;i.loadChildren&&i.canLoad===void 0?r=this.loader.loadChildren(e,i):r=b(null);let s=r.pipe(Ce(o=>o===null?b(void 0):(i._loadedRoutes=o.routes,i._loadedInjector=o.injector,this.processRoutes(o.injector??e,o.routes))));if(i.loadComponent&&!i._loadedComponent){let o=this.loader.loadComponent(i);return Q([s,o]).pipe(Lo())}else return s})}static{this.\u0275fac=function(i){return new(i||n)(C(Xe),C(Xr),C(ot),C(As),C(Za))}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),mh=new O(""),L_=(()=>{class n{constructor(e,i,r,s,o={}){this.urlSerializer=e,this.transitions=i,this.viewportScroller=r,this.zone=s,this.options=o,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},o.scrollPositionRestoration||="disabled",o.anchorScrolling||="disabled"}init(){this.options.scrollPositionRestoration!=="disabled"&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(e=>{e instanceof Qn?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=e.navigationTrigger,this.restoredId=e.restoredState?e.restoredState.navigationId:0):e instanceof dt?(this.lastId=e.id,this.scheduleScrollEvent(e,this.urlSerializer.parse(e.urlAfterRedirects).fragment)):e instanceof qt&&e.code===ys.IgnoredSameUrlNavigation&&(this.lastSource=void 0,this.restoredId=0,this.scheduleScrollEvent(e,this.urlSerializer.parse(e.url).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(e=>{e instanceof ws&&(e.position?this.options.scrollPositionRestoration==="top"?this.viewportScroller.scrollToPosition([0,0]):this.options.scrollPositionRestoration==="enabled"&&this.viewportScroller.scrollToPosition(e.position):e.anchor&&this.options.anchorScrolling==="enabled"?this.viewportScroller.scrollToAnchor(e.anchor):this.options.scrollPositionRestoration!=="disabled"&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(e,i){this.zone.runOutsideAngular(()=>{setTimeout(()=>{this.zone.run(()=>{this.transitions.events.next(new ws(e,this.lastSource==="popstate"?this.store[this.restoredId]:null,i))})},0)})}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}static{this.\u0275fac=function(i){Lu()}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac})}}return n})();function CT(n,...t){return qe([{provide:tr,multi:!0,useValue:n},[],{provide:ht,useFactory:_h,deps:[Xe]},{provide:Zr,multi:!0,useFactory:vh},t.map(e=>e.\u0275providers)])}function _h(n){return n.routerState.root}function cr(n,t){return{\u0275kind:n,\u0275providers:t}}function vh(){let n=h(J);return t=>{let e=n.get(Ye);if(t!==e.components[0])return;let i=n.get(Xe),r=n.get(yh);n.get(tc)===1&&i.initialNavigation(),n.get(bh,null,Ho.Optional)?.setUpPreloading(),n.get(mh,null,Ho.Optional)?.init(),i.resetRootComponentType(e.componentTypes[0]),r.closed||(r.next(),r.complete(),r.unsubscribe())}}var yh=new O("",{factory:()=>new N}),tc=new O("",{providedIn:"root",factory:()=>1});function B_(){return cr(2,[{provide:tc,useValue:0},{provide:ta,multi:!0,deps:[J],useFactory:t=>{let e=t.get(td,Promise.resolve());return()=>e.then(()=>new Promise(i=>{let r=t.get(Xe),s=t.get(yh);gh(r,()=>{i(!0)}),t.get(ec).afterPreactivation=()=>(i(!0),s.closed?b(void 0):s),r.initialNavigation()}))}}])}function V_(){return cr(3,[{provide:ta,multi:!0,useFactory:()=>{let t=h(Xe);return()=>{t.setUpLocationChangeListener()}}},{provide:tc,useValue:2}])}var bh=new O("");function U_(n){return cr(0,[{provide:bh,useExisting:F_},{provide:As,useExisting:n}])}function j_(){return cr(8,[Nd,{provide:Os,useExisting:Nd}])}function $_(n){let t=[{provide:hh,useValue:E_},{provide:fh,useValue:m({skipNextTransition:!!n?.skipInitialTransition},n)}];return cr(9,t)}var Ld=new O("ROUTER_FORROOT_GUARD"),H_=[ki,{provide:ir,useClass:Yn},Xe,sr,{provide:ht,useFactory:_h,deps:[Xe]},Za,[]],ST=(()=>{class n{constructor(e){}static forRoot(e,i){return{ngModule:n,providers:[H_,[],{provide:tr,multi:!0,useValue:e},{provide:Ld,useFactory:q_,deps:[[Xe,new st,new Cu]]},{provide:ar,useValue:i||{}},i?.useHash?z_():W_(),G_(),i?.preloadingStrategy?U_(i.preloadingStrategy).\u0275providers:[],i?.initialNavigation?J_(i):[],i?.bindToComponentInputs?j_().\u0275providers:[],i?.enableViewTransitions?$_().\u0275providers:[],K_()]}}static forChild(e){return{ngModule:n,providers:[{provide:tr,multi:!0,useValue:e}]}}static{this.\u0275fac=function(i){return new(i||n)(C(Ld,8))}}static{this.\u0275mod=Ie({type:n})}static{this.\u0275inj=Se({})}}return n})();function G_(){return{provide:mh,useFactory:()=>{let n=h(sd),t=h($),e=h(ar),i=h(ec),r=h(ir);return e.scrollOffset&&n.setOffset(e.scrollOffset),new L_(r,i,n,t,e)}}}function z_(){return{provide:Ni,useClass:id}}function W_(){return{provide:Ni,useClass:nd}}function q_(n){return"guarded"}function J_(n){return[n.initialNavigation==="disabled"?V_().\u0275providers:[],n.initialNavigation==="enabledBlocking"?B_().\u0275providers:[]]}var Bd=new O("");function K_(){return[{provide:Bd,useFactory:vh},{provide:Zr,multi:!0,useExisting:Bd}]}function Ms(n){n||(Go(Ms),n=h(Ii));let t=new Ne(e=>n.onDestroy(e.next.bind(e)));return e=>e.pipe(W(t))}function Y_(n,t){!t?.injector&&Go(Y_);let e=t?.injector??h(J),i=new lu(1),r=Qu(()=>{let s;try{s=n()}catch(o){Qe(()=>i.error(o));return}Qe(()=>i.next(s))},{injector:e,manualCleanup:!0});return e.get(Ii).onDestroy(()=>{r.destroy(),i.complete()}),i.asObservable()}var Rh=(()=>{class n{constructor(e,i){this._renderer=e,this._elementRef=i,this.onChange=r=>{},this.onTouched=()=>{}}setProperty(e,i){this._renderer.setProperty(this._elementRef.nativeElement,e,i)}registerOnTouched(e){this.onTouched=e}registerOnChange(e){this.onChange=e}setDisabledState(e){this.setProperty("disabled",e)}static{this.\u0275fac=function(i){return new(i||n)(R(Vn),R(ie))}}static{this.\u0275dir=F({type:n})}}return n})(),cc=(()=>{class n extends Rh{static{this.\u0275fac=(()=>{let e;return function(r){return(e||(e=Ut(n)))(r||n)}})()}static{this.\u0275dir=F({type:n,features:[xe]})}}return n})(),pr=new O(""),Q_={provide:pr,useExisting:bt(()=>Z_),multi:!0},Z_=(()=>{class n extends cc{writeValue(e){this.setProperty("checked",e)}static{this.\u0275fac=(()=>{let e;return function(r){return(e||(e=Ut(n)))(r||n)}})()}static{this.\u0275dir=F({type:n,selectors:[["input","type","checkbox","formControlName",""],["input","type","checkbox","formControl",""],["input","type","checkbox","ngModel",""]],hostBindings:function(i,r){i&1&&ue("change",function(o){return r.onChange(o.target.checked)})("blur",function(){return r.onTouched()})},features:[Et([Q_]),xe]})}}return n})(),X_={provide:pr,useExisting:bt(()=>Mh),multi:!0};function ev(){let n=Hn()?Hn().getUserAgent():"";return/android (\d+)/.test(n.toLowerCase())}var tv=new O(""),Mh=(()=>{class n extends Rh{constructor(e,i,r){super(e,i),this._compositionMode=r,this._composing=!1,this._compositionMode==null&&(this._compositionMode=!ev())}writeValue(e){let i=e??"";this.setProperty("value",i)}_handleInput(e){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(e)}_compositionStart(){this._composing=!0}_compositionEnd(e){this._composing=!1,this._compositionMode&&this.onChange(e)}static{this.\u0275fac=function(i){return new(i||n)(R(Vn),R(ie),R(tv,8))}}static{this.\u0275dir=F({type:n,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(i,r){i&1&&ue("input",function(o){return r._handleInput(o.target.value)})("blur",function(){return r.onTouched()})("compositionstart",function(){return r._compositionStart()})("compositionend",function(o){return r._compositionEnd(o.target.value)})},features:[Et([X_]),xe]})}}return n})();function Kt(n){return n==null||(typeof n=="string"||Array.isArray(n))&&n.length===0}function Ph(n){return n!=null&&typeof n.length=="number"}var lc=new O(""),uc=new O(""),nv=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/,wh=class{static min(t){return iv(t)}static max(t){return rv(t)}static required(t){return sv(t)}static requiredTrue(t){return ov(t)}static email(t){return av(t)}static minLength(t){return cv(t)}static maxLength(t){return lv(t)}static pattern(t){return uv(t)}static nullValidator(t){return Nh(t)}static compose(t){return Vh(t)}static composeAsync(t){return jh(t)}};function iv(n){return t=>{if(Kt(t.value)||Kt(n))return null;let e=parseFloat(t.value);return!isNaN(e)&&e<n?{min:{min:n,actual:t.value}}:null}}function rv(n){return t=>{if(Kt(t.value)||Kt(n))return null;let e=parseFloat(t.value);return!isNaN(e)&&e>n?{max:{max:n,actual:t.value}}:null}}function sv(n){return Kt(n.value)?{required:!0}:null}function ov(n){return n.value===!0?null:{required:!0}}function av(n){return Kt(n.value)||nv.test(n.value)?null:{email:!0}}function cv(n){return t=>Kt(t.value)||!Ph(t.value)?null:t.value.length<n?{minlength:{requiredLength:n,actualLength:t.value.length}}:null}function lv(n){return t=>Ph(t.value)&&t.value.length>n?{maxlength:{requiredLength:n,actualLength:t.value.length}}:null}function uv(n){if(!n)return Nh;let t,e;return typeof n=="string"?(e="",n.charAt(0)!=="^"&&(e+="^"),e+=n,n.charAt(n.length-1)!=="$"&&(e+="$"),t=new RegExp(e)):(e=n.toString(),t=n),i=>{if(Kt(i.value))return null;let r=i.value;return t.test(r)?null:{pattern:{requiredPattern:e,actualValue:r}}}}function Nh(n){return null}function kh(n){return n!=null}function xh(n){return Qr(n)?Q(n):n}function Fh(n){let t={};return n.forEach(e=>{t=e!=null?m(m({},t),e):t}),Object.keys(t).length===0?null:t}function Lh(n,t){return t.map(e=>e(n))}function dv(n){return!n.validate}function Bh(n){return n.map(t=>dv(t)?t:e=>t.validate(e))}function Vh(n){if(!n)return null;let t=n.filter(kh);return t.length==0?null:function(e){return Fh(Lh(e,t))}}function Uh(n){return n!=null?Vh(Bh(n)):null}function jh(n){if(!n)return null;let t=n.filter(kh);return t.length==0?null:function(e){let i=Lh(e,t).map(xh);return mu(i).pipe(I(Fh))}}function $h(n){return n!=null?jh(Bh(n)):null}function Dh(n,t){return n===null?[t]:Array.isArray(n)?[...n,t]:[n,t]}function Hh(n){return n._rawValidators}function Gh(n){return n._rawAsyncValidators}function nc(n){return n?Array.isArray(n)?n:[n]:[]}function Ns(n,t){return Array.isArray(n)?n.includes(t):n===t}function Th(n,t){let e=nc(t);return nc(n).forEach(r=>{Ns(e,r)||e.push(r)}),e}function Eh(n,t){return nc(t).filter(e=>!Ns(n,e))}var ks=class{constructor(){this._rawValidators=[],this._rawAsyncValidators=[],this._onDestroyCallbacks=[]}get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_setValidators(t){this._rawValidators=t||[],this._composedValidatorFn=Uh(this._rawValidators)}_setAsyncValidators(t){this._rawAsyncValidators=t||[],this._composedAsyncValidatorFn=$h(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(t){this._onDestroyCallbacks.push(t)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(t=>t()),this._onDestroyCallbacks=[]}reset(t=void 0){this.control&&this.control.reset(t)}hasError(t,e){return this.control?this.control.hasError(t,e):!1}getError(t,e){return this.control?this.control.getError(t,e):null}},_n=class extends ks{get formDirective(){return null}get path(){return null}},Yt=class extends ks{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}},xs=class{constructor(t){this._cd=t}get isTouched(){return this._cd?.control?._touched?.(),!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return this._cd?.control?._pristine?.(),!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return this._cd?.control?._status?.(),!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return this._cd?._submitted?.(),!!this._cd?.submitted}},hv={"[class.ng-untouched]":"isUntouched","[class.ng-touched]":"isTouched","[class.ng-pristine]":"isPristine","[class.ng-dirty]":"isDirty","[class.ng-valid]":"isValid","[class.ng-invalid]":"isInvalid","[class.ng-pending]":"isPending"},YT=k(m({},hv),{"[class.ng-submitted]":"isSubmitted"}),QT=(()=>{class n extends xs{constructor(e){super(e)}static{this.\u0275fac=function(i){return new(i||n)(R(Yt,2))}}static{this.\u0275dir=F({type:n,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(i,r){i&2&&Z("ng-untouched",r.isUntouched)("ng-touched",r.isTouched)("ng-pristine",r.isPristine)("ng-dirty",r.isDirty)("ng-valid",r.isValid)("ng-invalid",r.isInvalid)("ng-pending",r.isPending)},features:[xe]})}}return n})(),ZT=(()=>{class n extends xs{constructor(e){super(e)}static{this.\u0275fac=function(i){return new(i||n)(R(_n,10))}}static{this.\u0275dir=F({type:n,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(i,r){i&2&&Z("ng-untouched",r.isUntouched)("ng-touched",r.isTouched)("ng-pristine",r.isPristine)("ng-dirty",r.isDirty)("ng-valid",r.isValid)("ng-invalid",r.isInvalid)("ng-pending",r.isPending)("ng-submitted",r.isSubmitted)},features:[xe]})}}return n})();var lr="VALID",Ps="INVALID",ti="PENDING",ur="DISABLED",Qt=class{},Fs=class extends Qt{constructor(t,e){super(),this.value=t,this.source=e}},dr=class extends Qt{constructor(t,e){super(),this.pristine=t,this.source=e}},hr=class extends Qt{constructor(t,e){super(),this.touched=t,this.source=e}},ni=class extends Qt{constructor(t,e){super(),this.status=t,this.source=e}},ic=class extends Qt{constructor(t){super(),this.source=t}},rc=class extends Qt{constructor(t){super(),this.source=t}};function dc(n){return(Us(n)?n.validators:n)||null}function fv(n){return Array.isArray(n)?Uh(n):n||null}function hc(n,t){return(Us(t)?t.asyncValidators:n)||null}function pv(n){return Array.isArray(n)?$h(n):n||null}function Us(n){return n!=null&&!Array.isArray(n)&&typeof n=="object"}function zh(n,t,e){let i=n.controls;if(!(t?Object.keys(i):i).length)throw new j(1e3,"");if(!i[e])throw new j(1001,"")}function Wh(n,t,e){n._forEachChild((i,r)=>{if(e[r]===void 0)throw new j(1002,"")})}var ii=class{constructor(t,e){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=null,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this._status=$n(()=>this.statusReactive()),this.statusReactive=Je(void 0),this._pristine=$n(()=>this.pristineReactive()),this.pristineReactive=Je(!0),this._touched=$n(()=>this.touchedReactive()),this.touchedReactive=Je(!1),this._events=new N,this.events=this._events.asObservable(),this._onDisabledChange=[],this._assignValidators(t),this._assignAsyncValidators(e)}get validator(){return this._composedValidatorFn}set validator(t){this._rawValidators=this._composedValidatorFn=t}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(t){this._rawAsyncValidators=this._composedAsyncValidatorFn=t}get parent(){return this._parent}get status(){return Qe(this.statusReactive)}set status(t){Qe(()=>this.statusReactive.set(t))}get valid(){return this.status===lr}get invalid(){return this.status===Ps}get pending(){return this.status==ti}get disabled(){return this.status===ur}get enabled(){return this.status!==ur}get pristine(){return Qe(this.pristineReactive)}set pristine(t){Qe(()=>this.pristineReactive.set(t))}get dirty(){return!this.pristine}get touched(){return Qe(this.touchedReactive)}set touched(t){Qe(()=>this.touchedReactive.set(t))}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(t){this._assignValidators(t)}setAsyncValidators(t){this._assignAsyncValidators(t)}addValidators(t){this.setValidators(Th(t,this._rawValidators))}addAsyncValidators(t){this.setAsyncValidators(Th(t,this._rawAsyncValidators))}removeValidators(t){this.setValidators(Eh(t,this._rawValidators))}removeAsyncValidators(t){this.setAsyncValidators(Eh(t,this._rawAsyncValidators))}hasValidator(t){return Ns(this._rawValidators,t)}hasAsyncValidator(t){return Ns(this._rawAsyncValidators,t)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(t={}){let e=this.touched===!1;this.touched=!0;let i=t.sourceControl??this;this._parent&&!t.onlySelf&&this._parent.markAsTouched(k(m({},t),{sourceControl:i})),e&&t.emitEvent!==!1&&this._events.next(new hr(!0,i))}markAllAsTouched(t={}){this.markAsTouched({onlySelf:!0,emitEvent:t.emitEvent,sourceControl:this}),this._forEachChild(e=>e.markAllAsTouched(t))}markAsUntouched(t={}){let e=this.touched===!0;this.touched=!1,this._pendingTouched=!1;let i=t.sourceControl??this;this._forEachChild(r=>{r.markAsUntouched({onlySelf:!0,emitEvent:t.emitEvent,sourceControl:i})}),this._parent&&!t.onlySelf&&this._parent._updateTouched(t,i),e&&t.emitEvent!==!1&&this._events.next(new hr(!1,i))}markAsDirty(t={}){let e=this.pristine===!0;this.pristine=!1;let i=t.sourceControl??this;this._parent&&!t.onlySelf&&this._parent.markAsDirty(k(m({},t),{sourceControl:i})),e&&t.emitEvent!==!1&&this._events.next(new dr(!1,i))}markAsPristine(t={}){let e=this.pristine===!1;this.pristine=!0,this._pendingDirty=!1;let i=t.sourceControl??this;this._forEachChild(r=>{r.markAsPristine({onlySelf:!0,emitEvent:t.emitEvent})}),this._parent&&!t.onlySelf&&this._parent._updatePristine(t,i),e&&t.emitEvent!==!1&&this._events.next(new dr(!0,i))}markAsPending(t={}){this.status=ti;let e=t.sourceControl??this;t.emitEvent!==!1&&(this._events.next(new ni(this.status,e)),this.statusChanges.emit(this.status)),this._parent&&!t.onlySelf&&this._parent.markAsPending(k(m({},t),{sourceControl:e}))}disable(t={}){let e=this._parentMarkedDirty(t.onlySelf);this.status=ur,this.errors=null,this._forEachChild(r=>{r.disable(k(m({},t),{onlySelf:!0}))}),this._updateValue();let i=t.sourceControl??this;t.emitEvent!==!1&&(this._events.next(new Fs(this.value,i)),this._events.next(new ni(this.status,i)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(k(m({},t),{skipPristineCheck:e}),this),this._onDisabledChange.forEach(r=>r(!0))}enable(t={}){let e=this._parentMarkedDirty(t.onlySelf);this.status=lr,this._forEachChild(i=>{i.enable(k(m({},t),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:t.emitEvent}),this._updateAncestors(k(m({},t),{skipPristineCheck:e}),this),this._onDisabledChange.forEach(i=>i(!1))}_updateAncestors(t,e){this._parent&&!t.onlySelf&&(this._parent.updateValueAndValidity(t),t.skipPristineCheck||this._parent._updatePristine({},e),this._parent._updateTouched({},e))}setParent(t){this._parent=t}getRawValue(){return this.value}updateValueAndValidity(t={}){if(this._setInitialStatus(),this._updateValue(),this.enabled){let i=this._cancelExistingSubscription();this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===lr||this.status===ti)&&this._runAsyncValidator(i,t.emitEvent)}let e=t.sourceControl??this;t.emitEvent!==!1&&(this._events.next(new Fs(this.value,e)),this._events.next(new ni(this.status,e)),this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!t.onlySelf&&this._parent.updateValueAndValidity(k(m({},t),{sourceControl:e}))}_updateTreeValidity(t={emitEvent:!0}){this._forEachChild(e=>e._updateTreeValidity(t)),this.updateValueAndValidity({onlySelf:!0,emitEvent:t.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?ur:lr}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(t,e){if(this.asyncValidator){this.status=ti,this._hasOwnPendingAsyncValidator={emitEvent:e!==!1};let i=xh(this.asyncValidator(this));this._asyncValidationSubscription=i.subscribe(r=>{this._hasOwnPendingAsyncValidator=null,this.setErrors(r,{emitEvent:e,shouldHaveEmitted:t})})}}_cancelExistingSubscription(){if(this._asyncValidationSubscription){this._asyncValidationSubscription.unsubscribe();let t=this._hasOwnPendingAsyncValidator?.emitEvent??!1;return this._hasOwnPendingAsyncValidator=null,t}return!1}setErrors(t,e={}){this.errors=t,this._updateControlsErrors(e.emitEvent!==!1,this,e.shouldHaveEmitted)}get(t){let e=t;return e==null||(Array.isArray(e)||(e=e.split(".")),e.length===0)?null:e.reduce((i,r)=>i&&i._find(r),this)}getError(t,e){let i=e?this.get(e):this;return i&&i.errors?i.errors[t]:null}hasError(t,e){return!!this.getError(t,e)}get root(){let t=this;for(;t._parent;)t=t._parent;return t}_updateControlsErrors(t,e,i){this.status=this._calculateStatus(),t&&this.statusChanges.emit(this.status),(t||i)&&this._events.next(new ni(this.status,e)),this._parent&&this._parent._updateControlsErrors(t,e,i)}_initObservables(){this.valueChanges=new B,this.statusChanges=new B}_calculateStatus(){return this._allControlsDisabled()?ur:this.errors?Ps:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(ti)?ti:this._anyControlsHaveStatus(Ps)?Ps:lr}_anyControlsHaveStatus(t){return this._anyControls(e=>e.status===t)}_anyControlsDirty(){return this._anyControls(t=>t.dirty)}_anyControlsTouched(){return this._anyControls(t=>t.touched)}_updatePristine(t,e){let i=!this._anyControlsDirty(),r=this.pristine!==i;this.pristine=i,this._parent&&!t.onlySelf&&this._parent._updatePristine(t,e),r&&this._events.next(new dr(this.pristine,e))}_updateTouched(t={},e){this.touched=this._anyControlsTouched(),this._events.next(new hr(this.touched,e)),this._parent&&!t.onlySelf&&this._parent._updateTouched(t,e)}_registerOnCollectionChange(t){this._onCollectionChange=t}_setUpdateStrategy(t){Us(t)&&t.updateOn!=null&&(this._updateOn=t.updateOn)}_parentMarkedDirty(t){let e=this._parent&&this._parent.dirty;return!t&&!!e&&!this._parent._anyControlsDirty()}_find(t){return null}_assignValidators(t){this._rawValidators=Array.isArray(t)?t.slice():t,this._composedValidatorFn=fv(this._rawValidators)}_assignAsyncValidators(t){this._rawAsyncValidators=Array.isArray(t)?t.slice():t,this._composedAsyncValidatorFn=pv(this._rawAsyncValidators)}},Ls=class extends ii{constructor(t,e,i){super(dc(e),hc(i,e)),this.controls=t,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(t,e){return this.controls[t]?this.controls[t]:(this.controls[t]=e,e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange),e)}addControl(t,e,i={}){this.registerControl(t,e),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}removeControl(t,e={}){this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),delete this.controls[t],this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}setControl(t,e,i={}){this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),delete this.controls[t],e&&this.registerControl(t,e),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}contains(t){return this.controls.hasOwnProperty(t)&&this.controls[t].enabled}setValue(t,e={}){Wh(this,!0,t),Object.keys(t).forEach(i=>{zh(this,!0,i),this.controls[i].setValue(t[i],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)}patchValue(t,e={}){t!=null&&(Object.keys(t).forEach(i=>{let r=this.controls[i];r&&r.patchValue(t[i],{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(t={},e={}){this._forEachChild((i,r)=>{i.reset(t?t[r]:null,{onlySelf:!0,emitEvent:e.emitEvent})}),this._updatePristine(e,this),this._updateTouched(e,this),this.updateValueAndValidity(e)}getRawValue(){return this._reduceChildren({},(t,e,i)=>(t[i]=e.getRawValue(),t))}_syncPendingControls(){let t=this._reduceChildren(!1,(e,i)=>i._syncPendingControls()?!0:e);return t&&this.updateValueAndValidity({onlySelf:!0}),t}_forEachChild(t){Object.keys(this.controls).forEach(e=>{let i=this.controls[e];i&&t(i,e)})}_setUpControls(){this._forEachChild(t=>{t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(t){for(let[e,i]of Object.entries(this.controls))if(this.contains(e)&&t(i))return!0;return!1}_reduceValue(){let t={};return this._reduceChildren(t,(e,i,r)=>((i.enabled||this.disabled)&&(e[r]=i.value),e))}_reduceChildren(t,e){let i=t;return this._forEachChild((r,s)=>{i=e(i,r,s)}),i}_allControlsDisabled(){for(let t of Object.keys(this.controls))if(this.controls[t].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(t){return this.controls.hasOwnProperty(t)?this.controls[t]:null}};var sc=class extends Ls{};var gr=new O("CallSetDisabledState",{providedIn:"root",factory:()=>mr}),mr="always";function qh(n,t){return[...t.path,n]}function oc(n,t,e=mr){fc(n,t),t.valueAccessor.writeValue(n.value),(n.disabled||e==="always")&&t.valueAccessor.setDisabledState?.(n.disabled),mv(n,t),vv(n,t),_v(n,t),gv(n,t)}function Ch(n,t,e=!0){let i=()=>{};t.valueAccessor&&(t.valueAccessor.registerOnChange(i),t.valueAccessor.registerOnTouched(i)),Vs(n,t),n&&(t._invokeOnDestroyCallbacks(),n._registerOnCollectionChange(()=>{}))}function Bs(n,t){n.forEach(e=>{e.registerOnValidatorChange&&e.registerOnValidatorChange(t)})}function gv(n,t){if(t.valueAccessor.setDisabledState){let e=i=>{t.valueAccessor.setDisabledState(i)};n.registerOnDisabledChange(e),t._registerOnDestroy(()=>{n._unregisterOnDisabledChange(e)})}}function fc(n,t){let e=Hh(n);t.validator!==null?n.setValidators(Dh(e,t.validator)):typeof e=="function"&&n.setValidators([e]);let i=Gh(n);t.asyncValidator!==null?n.setAsyncValidators(Dh(i,t.asyncValidator)):typeof i=="function"&&n.setAsyncValidators([i]);let r=()=>n.updateValueAndValidity();Bs(t._rawValidators,r),Bs(t._rawAsyncValidators,r)}function Vs(n,t){let e=!1;if(n!==null){if(t.validator!==null){let r=Hh(n);if(Array.isArray(r)&&r.length>0){let s=r.filter(o=>o!==t.validator);s.length!==r.length&&(e=!0,n.setValidators(s))}}if(t.asyncValidator!==null){let r=Gh(n);if(Array.isArray(r)&&r.length>0){let s=r.filter(o=>o!==t.asyncValidator);s.length!==r.length&&(e=!0,n.setAsyncValidators(s))}}}let i=()=>{};return Bs(t._rawValidators,i),Bs(t._rawAsyncValidators,i),e}function mv(n,t){t.valueAccessor.registerOnChange(e=>{n._pendingValue=e,n._pendingChange=!0,n._pendingDirty=!0,n.updateOn==="change"&&Jh(n,t)})}function _v(n,t){t.valueAccessor.registerOnTouched(()=>{n._pendingTouched=!0,n.updateOn==="blur"&&n._pendingChange&&Jh(n,t),n.updateOn!=="submit"&&n.markAsTouched()})}function Jh(n,t){n._pendingDirty&&n.markAsDirty(),n.setValue(n._pendingValue,{emitModelToViewChange:!1}),t.viewToModelUpdate(n._pendingValue),n._pendingChange=!1}function vv(n,t){let e=(i,r)=>{t.valueAccessor.writeValue(i),r&&t.viewToModelUpdate(i)};n.registerOnChange(e),t._registerOnDestroy(()=>{n._unregisterOnChange(e)})}function yv(n,t){n==null,fc(n,t)}function bv(n,t){return Vs(n,t)}function Kh(n,t){if(!n.hasOwnProperty("model"))return!1;let e=n.model;return e.isFirstChange()?!0:!Object.is(t,e.currentValue)}function wv(n){return Object.getPrototypeOf(n.constructor)===cc}function Dv(n,t){n._syncPendingControls(),t.forEach(e=>{let i=e.control;i.updateOn==="submit"&&i._pendingChange&&(e.viewToModelUpdate(i._pendingValue),i._pendingChange=!1)})}function Yh(n,t){if(!t)return null;Array.isArray(t);let e,i,r;return t.forEach(s=>{s.constructor===Mh?e=s:wv(s)?i=s:r=s}),r||i||e||null}function Tv(n,t){let e=n.indexOf(t);e>-1&&n.splice(e,1)}function Sh(n,t){let e=n.indexOf(t);e>-1&&n.splice(e,1)}function Ih(n){return typeof n=="object"&&n!==null&&Object.keys(n).length===2&&"value"in n&&"disabled"in n}var fr=class extends ii{constructor(t=null,e,i){super(dc(e),hc(i,e)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(t),this._setUpdateStrategy(e),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),Us(e)&&(e.nonNullable||e.initialValueIsDefault)&&(Ih(t)?this.defaultValue=t.value:this.defaultValue=t)}setValue(t,e={}){this.value=this._pendingValue=t,this._onChange.length&&e.emitModelToViewChange!==!1&&this._onChange.forEach(i=>i(this.value,e.emitViewToModelChange!==!1)),this.updateValueAndValidity(e)}patchValue(t,e={}){this.setValue(t,e)}reset(t=this.defaultValue,e={}){this._applyFormState(t),this.markAsPristine(e),this.markAsUntouched(e),this.setValue(this.value,e),this._pendingChange=!1}_updateValue(){}_anyControls(t){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(t){this._onChange.push(t)}_unregisterOnChange(t){Sh(this._onChange,t)}registerOnDisabledChange(t){this._onDisabledChange.push(t)}_unregisterOnDisabledChange(t){Sh(this._onDisabledChange,t)}_forEachChild(t){}_syncPendingControls(){return this.updateOn==="submit"&&(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),this._pendingChange)?(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),!0):!1}_applyFormState(t){Ih(t)?(this.value=this._pendingValue=t.value,t.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=t}};var Ev=n=>n instanceof fr;var Cv={provide:Yt,useExisting:bt(()=>Sv)},Ah=Promise.resolve(),Sv=(()=>{class n extends Yt{constructor(e,i,r,s,o,c){super(),this._changeDetectorRef=o,this.callSetDisabledState=c,this.control=new fr,this._registered=!1,this.name="",this.update=new B,this._parent=e,this._setValidators(i),this._setAsyncValidators(r),this.valueAccessor=Yh(this,s)}ngOnChanges(e){if(this._checkForErrors(),!this._registered||"name"in e){if(this._registered&&(this._checkName(),this.formDirective)){let i=e.name.previousValue;this.formDirective.removeControl({name:i,path:this._getPath(i)})}this._setUpControl()}"isDisabled"in e&&this._updateDisabled(e),Kh(e,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&this.options.updateOn!=null&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!!(this.options&&this.options.standalone)}_setUpStandalone(){oc(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),!this._isStandalone()&&this.name}_updateValue(e){Ah.then(()=>{this.control.setValue(e,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(e){let i=e.isDisabled.currentValue,r=i!==0&&jn(i);Ah.then(()=>{r&&!this.control.disabled?this.control.disable():!r&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(e){return this._parent?qh(e,this._parent):[e]}static{this.\u0275fac=function(i){return new(i||n)(R(_n,9),R(lc,10),R(uc,10),R(pr,10),R(Ct,8),R(gr,8))}}static{this.\u0275dir=F({type:n,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"],options:[0,"ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],features:[Et([Cv]),xe,at]})}}return n})(),eE=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""]})}}return n})();var Iv={provide:pr,useExisting:bt(()=>Ov),multi:!0};var Av=(()=>{class n{constructor(){this._accessors=[]}add(e,i){this._accessors.push([e,i])}remove(e){for(let i=this._accessors.length-1;i>=0;--i)if(this._accessors[i][1]===e){this._accessors.splice(i,1);return}}select(e){this._accessors.forEach(i=>{this._isSameGroup(i,e)&&i[1]!==e&&i[1].fireUncheck(e.value)})}_isSameGroup(e,i){return e[0].control?e[0]._parent===i._control._parent&&e[1].name===i.name:!1}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),Ov=(()=>{class n extends cc{constructor(e,i,r,s){super(e,i),this._registry=r,this._injector=s,this.setDisabledStateFired=!1,this.onChange=()=>{},this.callSetDisabledState=h(gr,{optional:!0})??mr}ngOnInit(){this._control=this._injector.get(Yt),this._checkName(),this._registry.add(this._control,this)}ngOnDestroy(){this._registry.remove(this)}writeValue(e){this._state=e===this.value,this.setProperty("checked",this._state)}registerOnChange(e){this._fn=e,this.onChange=()=>{e(this.value),this._registry.select(this)}}setDisabledState(e){(this.setDisabledStateFired||e||this.callSetDisabledState==="whenDisabledForLegacyCode")&&this.setProperty("disabled",e),this.setDisabledStateFired=!0}fireUncheck(e){this.writeValue(e)}_checkName(){this.name&&this.formControlName&&(this.name,this.formControlName),!this.name&&this.formControlName&&(this.name=this.formControlName)}static{this.\u0275fac=function(i){return new(i||n)(R(Vn),R(ie),R(Av),R(J))}}static{this.\u0275dir=F({type:n,selectors:[["input","type","radio","formControlName",""],["input","type","radio","formControl",""],["input","type","radio","ngModel",""]],hostBindings:function(i,r){i&1&&ue("change",function(){return r.onChange()})("blur",function(){return r.onTouched()})},inputs:{name:"name",formControlName:"formControlName",value:"value"},features:[Et([Iv]),xe]})}}return n})();var Qh=new O("");var Rv={provide:_n,useExisting:bt(()=>Mv)},Mv=(()=>{class n extends _n{get submitted(){return Qe(this._submittedReactive)}set submitted(e){this._submittedReactive.set(e)}constructor(e,i,r){super(),this.callSetDisabledState=r,this._submitted=$n(()=>this._submittedReactive()),this._submittedReactive=Je(!1),this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new B,this._setValidators(e),this._setAsyncValidators(i)}ngOnChanges(e){this._checkFormPresent(),e.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(Vs(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(e){let i=this.form.get(e.path);return oc(i,e,this.callSetDisabledState),i.updateValueAndValidity({emitEvent:!1}),this.directives.push(e),i}getControl(e){return this.form.get(e.path)}removeControl(e){Ch(e.control||null,e,!1),Tv(this.directives,e)}addFormGroup(e){this._setUpFormContainer(e)}removeFormGroup(e){this._cleanUpFormContainer(e)}getFormGroup(e){return this.form.get(e.path)}addFormArray(e){this._setUpFormContainer(e)}removeFormArray(e){this._cleanUpFormContainer(e)}getFormArray(e){return this.form.get(e.path)}updateModel(e,i){this.form.get(e.path).setValue(i)}onSubmit(e){return this._submittedReactive.set(!0),Dv(this.form,this.directives),this.ngSubmit.emit(e),this.form._events.next(new ic(this.control)),e?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(e=void 0){this.form.reset(e),this._submittedReactive.set(!1),this.form._events.next(new rc(this.form))}_updateDomValue(){this.directives.forEach(e=>{let i=e.control,r=this.form.get(e.path);i!==r&&(Ch(i||null,e),Ev(r)&&(oc(r,e,this.callSetDisabledState),e.control=r))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(e){let i=this.form.get(e.path);yv(i,e),i.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(e){if(this.form){let i=this.form.get(e.path);i&&bv(i,e)&&i.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){fc(this.form,this),this._oldForm&&Vs(this._oldForm,this)}_checkFormPresent(){this.form}static{this.\u0275fac=function(i){return new(i||n)(R(lc,10),R(uc,10),R(gr,8))}}static{this.\u0275dir=F({type:n,selectors:[["","formGroup",""]],hostBindings:function(i,r){i&1&&ue("submit",function(o){return r.onSubmit(o)})("reset",function(){return r.onReset()})},inputs:{form:[0,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Et([Rv]),xe,at]})}}return n})();var Pv={provide:Yt,useExisting:bt(()=>Nv)},Nv=(()=>{class n extends Yt{set isDisabled(e){}static{this._ngModelWarningSentOnce=!1}constructor(e,i,r,s,o){super(),this._ngModelWarningConfig=o,this._added=!1,this.name=null,this.update=new B,this._ngModelWarningSent=!1,this._parent=e,this._setValidators(i),this._setAsyncValidators(r),this.valueAccessor=Yh(this,s)}ngOnChanges(e){this._added||this._setUpControl(),Kh(e,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(e){this.viewModel=e,this.update.emit(e)}get path(){return qh(this.name==null?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_checkParentType(){}_setUpControl(){this._checkParentType(),this.control=this.formDirective.addControl(this),this._added=!0}static{this.\u0275fac=function(i){return new(i||n)(R(_n,13),R(lc,10),R(uc,10),R(pr,10),R(Qh,8))}}static{this.\u0275dir=F({type:n,selectors:[["","formControlName",""]],inputs:{name:[0,"formControlName","name"],isDisabled:[0,"disabled","isDisabled"],model:[0,"ngModel","model"]},outputs:{update:"ngModelChange"},features:[Et([Pv]),xe,at]})}}return n})();var Zh=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Ie({type:n})}static{this.\u0275inj=Se({})}}return n})(),ac=class extends ii{constructor(t,e,i){super(dc(e),hc(i,e)),this.controls=t,this._initObservables(),this._setUpdateStrategy(e),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}at(t){return this.controls[this._adjustIndex(t)]}push(t,e={}){this.controls.push(t),this._registerControl(t),this.updateValueAndValidity({emitEvent:e.emitEvent}),this._onCollectionChange()}insert(t,e,i={}){this.controls.splice(t,0,e),this._registerControl(e),this.updateValueAndValidity({emitEvent:i.emitEvent})}removeAt(t,e={}){let i=this._adjustIndex(t);i<0&&(i=0),this.controls[i]&&this.controls[i]._registerOnCollectionChange(()=>{}),this.controls.splice(i,1),this.updateValueAndValidity({emitEvent:e.emitEvent})}setControl(t,e,i={}){let r=this._adjustIndex(t);r<0&&(r=0),this.controls[r]&&this.controls[r]._registerOnCollectionChange(()=>{}),this.controls.splice(r,1),e&&(this.controls.splice(r,0,e),this._registerControl(e)),this.updateValueAndValidity({emitEvent:i.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(t,e={}){Wh(this,!1,t),t.forEach((i,r)=>{zh(this,!1,r),this.at(r).setValue(i,{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e)}patchValue(t,e={}){t!=null&&(t.forEach((i,r)=>{this.at(r)&&this.at(r).patchValue(i,{onlySelf:!0,emitEvent:e.emitEvent})}),this.updateValueAndValidity(e))}reset(t=[],e={}){this._forEachChild((i,r)=>{i.reset(t[r],{onlySelf:!0,emitEvent:e.emitEvent})}),this._updatePristine(e,this),this._updateTouched(e,this),this.updateValueAndValidity(e)}getRawValue(){return this.controls.map(t=>t.getRawValue())}clear(t={}){this.controls.length<1||(this._forEachChild(e=>e._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:t.emitEvent}))}_adjustIndex(t){return t<0?t+this.length:t}_syncPendingControls(){let t=this.controls.reduce((e,i)=>i._syncPendingControls()?!0:e,!1);return t&&this.updateValueAndValidity({onlySelf:!0}),t}_forEachChild(t){this.controls.forEach((e,i)=>{t(e,i)})}_updateValue(){this.value=this.controls.filter(t=>t.enabled||this.disabled).map(t=>t.value)}_anyControls(t){return this.controls.some(e=>e.enabled&&t(e))}_setUpControls(){this._forEachChild(t=>this._registerControl(t))}_allControlsDisabled(){for(let t of this.controls)if(t.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(t){t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange)}_find(t){return this.at(t)??null}};function Oh(n){return!!n&&(n.asyncValidators!==void 0||n.validators!==void 0||n.updateOn!==void 0)}var tE=(()=>{class n{constructor(){this.useNonNullable=!1}get nonNullable(){let e=new n;return e.useNonNullable=!0,e}group(e,i=null){let r=this._reduceControls(e),s={};return Oh(i)?s=i:i!==null&&(s.validators=i.validator,s.asyncValidators=i.asyncValidator),new Ls(r,s)}record(e,i=null){let r=this._reduceControls(e);return new sc(r,i)}control(e,i,r){let s={};return this.useNonNullable?(Oh(i)?s=i:(s.validators=i,s.asyncValidators=r),new fr(e,k(m({},s),{nonNullable:!0}))):new fr(e,i,r)}array(e,i,r){let s=e.map(o=>this._createControl(o));return new ac(s,i,r)}_reduceControls(e){let i={};return Object.keys(e).forEach(r=>{i[r]=this._createControl(e[r])}),i}_createControl(e){if(e instanceof fr)return e;if(e instanceof ii)return e;if(Array.isArray(e)){let i=e[0],r=e.length>1?e[1]:null,s=e.length>2?e[2]:null;return this.control(i,r,s)}else return this.control(e)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();var nE=(()=>{class n{static withConfig(e){return{ngModule:n,providers:[{provide:gr,useValue:e.callSetDisabledState??mr}]}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Ie({type:n})}static{this.\u0275inj=Se({imports:[Zh]})}}return n})(),iE=(()=>{class n{static withConfig(e){return{ngModule:n,providers:[{provide:Qh,useValue:e.warnOnNgModelWithFormControl??"always"},{provide:gr,useValue:e.callSetDisabledState??mr}]}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Ie({type:n})}static{this.\u0275inj=Se({imports:[Zh]})}}return n})();var X="top",he="bottom",se="right",te="left",js="auto",Zt=[X,he,se,te],Ot="start",vn="end",Xh="clippingParents",$s="viewport",ri="popper",ef="reference",pc=Zt.reduce(function(n,t){return n.concat([t+"-"+Ot,t+"-"+vn])},[]),Hs=[].concat(Zt,[js]).reduce(function(n,t){return n.concat([t,t+"-"+Ot,t+"-"+vn])},[]),kv="beforeRead",xv="read",Fv="afterRead",Lv="beforeMain",Bv="main",Vv="afterMain",Uv="beforeWrite",jv="write",$v="afterWrite",tf=[kv,xv,Fv,Lv,Bv,Vv,Uv,jv,$v];function oe(n){return n?(n.nodeName||"").toLowerCase():null}function z(n){if(n==null)return window;if(n.toString()!=="[object Window]"){var t=n.ownerDocument;return t&&t.defaultView||window}return n}function Ve(n){var t=z(n).Element;return n instanceof t||n instanceof Element}function ne(n){var t=z(n).HTMLElement;return n instanceof t||n instanceof HTMLElement}function si(n){if(typeof ShadowRoot>"u")return!1;var t=z(n).ShadowRoot;return n instanceof t||n instanceof ShadowRoot}function Hv(n){var t=n.state;Object.keys(t.elements).forEach(function(e){var i=t.styles[e]||{},r=t.attributes[e]||{},s=t.elements[e];!ne(s)||!oe(s)||(Object.assign(s.style,i),Object.keys(r).forEach(function(o){var c=r[o];c===!1?s.removeAttribute(o):s.setAttribute(o,c===!0?"":c)}))})}function Gv(n){var t=n.state,e={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,e.popper),t.styles=e,t.elements.arrow&&Object.assign(t.elements.arrow.style,e.arrow),function(){Object.keys(t.elements).forEach(function(i){var r=t.elements[i],s=t.attributes[i]||{},o=Object.keys(t.styles.hasOwnProperty(i)?t.styles[i]:e[i]),c=o.reduce(function(a,l){return a[l]="",a},{});!ne(r)||!oe(r)||(Object.assign(r.style,c),Object.keys(s).forEach(function(a){r.removeAttribute(a)}))})}}var nf={name:"applyStyles",enabled:!0,phase:"write",fn:Hv,effect:Gv,requires:["computeStyles"]};function ae(n){return n.split("-")[0]}var et=Math.max,yn=Math.min,Rt=Math.round;function oi(){var n=navigator.userAgentData;return n!=null&&n.brands&&Array.isArray(n.brands)?n.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function _r(){return!/^((?!chrome|android).)*safari/i.test(oi())}function Ue(n,t,e){t===void 0&&(t=!1),e===void 0&&(e=!1);var i=n.getBoundingClientRect(),r=1,s=1;t&&ne(n)&&(r=n.offsetWidth>0&&Rt(i.width)/n.offsetWidth||1,s=n.offsetHeight>0&&Rt(i.height)/n.offsetHeight||1);var o=Ve(n)?z(n):window,c=o.visualViewport,a=!_r()&&e,l=(i.left+(a&&c?c.offsetLeft:0))/r,u=(i.top+(a&&c?c.offsetTop:0))/s,d=i.width/r,p=i.height/s;return{width:d,height:p,top:u,right:l+d,bottom:u+p,left:l,x:l,y:u}}function bn(n){var t=Ue(n),e=n.offsetWidth,i=n.offsetHeight;return Math.abs(t.width-e)<=1&&(e=t.width),Math.abs(t.height-i)<=1&&(i=t.height),{x:n.offsetLeft,y:n.offsetTop,width:e,height:i}}function vr(n,t){var e=t.getRootNode&&t.getRootNode();if(n.contains(t))return!0;if(e&&si(e)){var i=t;do{if(i&&n.isSameNode(i))return!0;i=i.parentNode||i.host}while(i)}return!1}function Ee(n){return z(n).getComputedStyle(n)}function gc(n){return["table","td","th"].indexOf(oe(n))>=0}function fe(n){return((Ve(n)?n.ownerDocument:n.document)||window.document).documentElement}function Mt(n){return oe(n)==="html"?n:n.assignedSlot||n.parentNode||(si(n)?n.host:null)||fe(n)}function rf(n){return!ne(n)||Ee(n).position==="fixed"?null:n.offsetParent}function zv(n){var t=/firefox/i.test(oi()),e=/Trident/i.test(oi());if(e&&ne(n)){var i=Ee(n);if(i.position==="fixed")return null}var r=Mt(n);for(si(r)&&(r=r.host);ne(r)&&["html","body"].indexOf(oe(r))<0;){var s=Ee(r);if(s.transform!=="none"||s.perspective!=="none"||s.contain==="paint"||["transform","perspective"].indexOf(s.willChange)!==-1||t&&s.willChange==="filter"||t&&s.filter&&s.filter!=="none")return r;r=r.parentNode}return null}function tt(n){for(var t=z(n),e=rf(n);e&&gc(e)&&Ee(e).position==="static";)e=rf(e);return e&&(oe(e)==="html"||oe(e)==="body"&&Ee(e).position==="static")?t:e||zv(n)||t}function wn(n){return["top","bottom"].indexOf(n)>=0?"x":"y"}function Dn(n,t,e){return et(n,yn(t,e))}function sf(n,t,e){var i=Dn(n,t,e);return i>e?e:i}function yr(){return{top:0,right:0,bottom:0,left:0}}function br(n){return Object.assign({},yr(),n)}function wr(n,t){return t.reduce(function(e,i){return e[i]=n,e},{})}var Wv=function(t,e){return t=typeof t=="function"?t(Object.assign({},e.rects,{placement:e.placement})):t,br(typeof t!="number"?t:wr(t,Zt))};function qv(n){var t,e=n.state,i=n.name,r=n.options,s=e.elements.arrow,o=e.modifiersData.popperOffsets,c=ae(e.placement),a=wn(c),l=[te,se].indexOf(c)>=0,u=l?"height":"width";if(!(!s||!o)){var d=Wv(r.padding,e),p=bn(s),g=a==="y"?X:te,w=a==="y"?he:se,v=e.rects.reference[u]+e.rects.reference[a]-o[a]-e.rects.popper[u],_=o[a]-e.rects.reference[a],S=tt(s),x=S?a==="y"?S.clientHeight||0:S.clientWidth||0:0,D=v/2-_/2,E=d[g],M=x-p[u]-d[w],P=x/2-p[u]/2+D,V=Dn(E,P,M),ee=a;e.modifiersData[i]=(t={},t[ee]=V,t.centerOffset=V-P,t)}}function Jv(n){var t=n.state,e=n.options,i=e.element,r=i===void 0?"[data-popper-arrow]":i;r!=null&&(typeof r=="string"&&(r=t.elements.popper.querySelector(r),!r)||vr(t.elements.popper,r)&&(t.elements.arrow=r))}var mc={name:"arrow",enabled:!0,phase:"main",fn:qv,effect:Jv,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function je(n){return n.split("-")[1]}var Kv={top:"auto",right:"auto",bottom:"auto",left:"auto"};function Yv(n,t){var e=n.x,i=n.y,r=t.devicePixelRatio||1;return{x:Rt(e*r)/r||0,y:Rt(i*r)/r||0}}function of(n){var t,e=n.popper,i=n.popperRect,r=n.placement,s=n.variation,o=n.offsets,c=n.position,a=n.gpuAcceleration,l=n.adaptive,u=n.roundOffsets,d=n.isFixed,p=o.x,g=p===void 0?0:p,w=o.y,v=w===void 0?0:w,_=typeof u=="function"?u({x:g,y:v}):{x:g,y:v};g=_.x,v=_.y;var S=o.hasOwnProperty("x"),x=o.hasOwnProperty("y"),D=te,E=X,M=window;if(l){var P=tt(e),V="clientHeight",ee="clientWidth";if(P===z(e)&&(P=fe(e),Ee(P).position!=="static"&&c==="absolute"&&(V="scrollHeight",ee="scrollWidth")),P=P,r===X||(r===te||r===se)&&s===vn){E=he;var q=d&&P===M&&M.visualViewport?M.visualViewport.height:P[V];v-=q-i.height,v*=a?1:-1}if(r===te||(r===X||r===he)&&s===vn){D=se;var Y=d&&P===M&&M.visualViewport?M.visualViewport.width:P[ee];g-=Y-i.width,g*=a?1:-1}}var pe=Object.assign({position:c},l&&Kv),Ge=u===!0?Yv({x:g,y:v},z(e)):{x:g,y:v};if(g=Ge.x,v=Ge.y,a){var ye;return Object.assign({},pe,(ye={},ye[E]=x?"0":"",ye[D]=S?"0":"",ye.transform=(M.devicePixelRatio||1)<=1?"translate("+g+"px, "+v+"px)":"translate3d("+g+"px, "+v+"px, 0)",ye))}return Object.assign({},pe,(t={},t[E]=x?v+"px":"",t[D]=S?g+"px":"",t.transform="",t))}function Qv(n){var t=n.state,e=n.options,i=e.gpuAcceleration,r=i===void 0?!0:i,s=e.adaptive,o=s===void 0?!0:s,c=e.roundOffsets,a=c===void 0?!0:c,l={placement:ae(t.placement),variation:je(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:r,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,of(Object.assign({},l,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:o,roundOffsets:a})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,of(Object.assign({},l,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:a})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}var af={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:Qv,data:{}};var Gs={passive:!0};function Zv(n){var t=n.state,e=n.instance,i=n.options,r=i.scroll,s=r===void 0?!0:r,o=i.resize,c=o===void 0?!0:o,a=z(t.elements.popper),l=[].concat(t.scrollParents.reference,t.scrollParents.popper);return s&&l.forEach(function(u){u.addEventListener("scroll",e.update,Gs)}),c&&a.addEventListener("resize",e.update,Gs),function(){s&&l.forEach(function(u){u.removeEventListener("scroll",e.update,Gs)}),c&&a.removeEventListener("resize",e.update,Gs)}}var cf={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:Zv,data:{}};var Xv={left:"right",right:"left",bottom:"top",top:"bottom"};function ai(n){return n.replace(/left|right|bottom|top/g,function(t){return Xv[t]})}var e0={start:"end",end:"start"};function zs(n){return n.replace(/start|end/g,function(t){return e0[t]})}function Tn(n){var t=z(n),e=t.pageXOffset,i=t.pageYOffset;return{scrollLeft:e,scrollTop:i}}function En(n){return Ue(fe(n)).left+Tn(n).scrollLeft}function _c(n,t){var e=z(n),i=fe(n),r=e.visualViewport,s=i.clientWidth,o=i.clientHeight,c=0,a=0;if(r){s=r.width,o=r.height;var l=_r();(l||!l&&t==="fixed")&&(c=r.offsetLeft,a=r.offsetTop)}return{width:s,height:o,x:c+En(n),y:a}}function vc(n){var t,e=fe(n),i=Tn(n),r=(t=n.ownerDocument)==null?void 0:t.body,s=et(e.scrollWidth,e.clientWidth,r?r.scrollWidth:0,r?r.clientWidth:0),o=et(e.scrollHeight,e.clientHeight,r?r.scrollHeight:0,r?r.clientHeight:0),c=-i.scrollLeft+En(n),a=-i.scrollTop;return Ee(r||e).direction==="rtl"&&(c+=et(e.clientWidth,r?r.clientWidth:0)-s),{width:s,height:o,x:c,y:a}}function Cn(n){var t=Ee(n),e=t.overflow,i=t.overflowX,r=t.overflowY;return/auto|scroll|overlay|hidden/.test(e+r+i)}function Ws(n){return["html","body","#document"].indexOf(oe(n))>=0?n.ownerDocument.body:ne(n)&&Cn(n)?n:Ws(Mt(n))}function Xt(n,t){var e;t===void 0&&(t=[]);var i=Ws(n),r=i===((e=n.ownerDocument)==null?void 0:e.body),s=z(i),o=r?[s].concat(s.visualViewport||[],Cn(i)?i:[]):i,c=t.concat(o);return r?c:c.concat(Xt(Mt(o)))}function ci(n){return Object.assign({},n,{left:n.x,top:n.y,right:n.x+n.width,bottom:n.y+n.height})}function t0(n,t){var e=Ue(n,!1,t==="fixed");return e.top=e.top+n.clientTop,e.left=e.left+n.clientLeft,e.bottom=e.top+n.clientHeight,e.right=e.left+n.clientWidth,e.width=n.clientWidth,e.height=n.clientHeight,e.x=e.left,e.y=e.top,e}function lf(n,t,e){return t===$s?ci(_c(n,e)):Ve(t)?t0(t,e):ci(vc(fe(n)))}function n0(n){var t=Xt(Mt(n)),e=["absolute","fixed"].indexOf(Ee(n).position)>=0,i=e&&ne(n)?tt(n):n;return Ve(i)?t.filter(function(r){return Ve(r)&&vr(r,i)&&oe(r)!=="body"}):[]}function yc(n,t,e,i){var r=t==="clippingParents"?n0(n):[].concat(t),s=[].concat(r,[e]),o=s[0],c=s.reduce(function(a,l){var u=lf(n,l,i);return a.top=et(u.top,a.top),a.right=yn(u.right,a.right),a.bottom=yn(u.bottom,a.bottom),a.left=et(u.left,a.left),a},lf(n,o,i));return c.width=c.right-c.left,c.height=c.bottom-c.top,c.x=c.left,c.y=c.top,c}function Dr(n){var t=n.reference,e=n.element,i=n.placement,r=i?ae(i):null,s=i?je(i):null,o=t.x+t.width/2-e.width/2,c=t.y+t.height/2-e.height/2,a;switch(r){case X:a={x:o,y:t.y-e.height};break;case he:a={x:o,y:t.y+t.height};break;case se:a={x:t.x+t.width,y:c};break;case te:a={x:t.x-e.width,y:c};break;default:a={x:t.x,y:t.y}}var l=r?wn(r):null;if(l!=null){var u=l==="y"?"height":"width";switch(s){case Ot:a[l]=a[l]-(t[u]/2-e[u]/2);break;case vn:a[l]=a[l]+(t[u]/2-e[u]/2);break;default:}}return a}function en(n,t){t===void 0&&(t={});var e=t,i=e.placement,r=i===void 0?n.placement:i,s=e.strategy,o=s===void 0?n.strategy:s,c=e.boundary,a=c===void 0?Xh:c,l=e.rootBoundary,u=l===void 0?$s:l,d=e.elementContext,p=d===void 0?ri:d,g=e.altBoundary,w=g===void 0?!1:g,v=e.padding,_=v===void 0?0:v,S=br(typeof _!="number"?_:wr(_,Zt)),x=p===ri?ef:ri,D=n.rects.popper,E=n.elements[w?x:p],M=yc(Ve(E)?E:E.contextElement||fe(n.elements.popper),a,u,o),P=Ue(n.elements.reference),V=Dr({reference:P,element:D,strategy:"absolute",placement:r}),ee=ci(Object.assign({},D,V)),q=p===ri?ee:P,Y={top:M.top-q.top+S.top,bottom:q.bottom-M.bottom+S.bottom,left:M.left-q.left+S.left,right:q.right-M.right+S.right},pe=n.modifiersData.offset;if(p===ri&&pe){var Ge=pe[r];Object.keys(Y).forEach(function(ye){var rn=[se,he].indexOf(ye)>=0?1:-1,sn=[X,he].indexOf(ye)>=0?"y":"x";Y[ye]+=Ge[sn]*rn})}return Y}function bc(n,t){t===void 0&&(t={});var e=t,i=e.placement,r=e.boundary,s=e.rootBoundary,o=e.padding,c=e.flipVariations,a=e.allowedAutoPlacements,l=a===void 0?Hs:a,u=je(i),d=u?c?pc:pc.filter(function(w){return je(w)===u}):Zt,p=d.filter(function(w){return l.indexOf(w)>=0});p.length===0&&(p=d);var g=p.reduce(function(w,v){return w[v]=en(n,{placement:v,boundary:r,rootBoundary:s,padding:o})[ae(v)],w},{});return Object.keys(g).sort(function(w,v){return g[w]-g[v]})}function i0(n){if(ae(n)===js)return[];var t=ai(n);return[zs(n),t,zs(t)]}function r0(n){var t=n.state,e=n.options,i=n.name;if(!t.modifiersData[i]._skip){for(var r=e.mainAxis,s=r===void 0?!0:r,o=e.altAxis,c=o===void 0?!0:o,a=e.fallbackPlacements,l=e.padding,u=e.boundary,d=e.rootBoundary,p=e.altBoundary,g=e.flipVariations,w=g===void 0?!0:g,v=e.allowedAutoPlacements,_=t.options.placement,S=ae(_),x=S===_,D=a||(x||!w?[ai(_)]:i0(_)),E=[_].concat(D).reduce(function(xn,Lt){return xn.concat(ae(Lt)===js?bc(t,{placement:Lt,boundary:u,rootBoundary:d,padding:l,flipVariations:w,allowedAutoPlacements:v}):Lt)},[]),M=t.rects.reference,P=t.rects.popper,V=new Map,ee=!0,q=E[0],Y=0;Y<E.length;Y++){var pe=E[Y],Ge=ae(pe),ye=je(pe)===Ot,rn=[X,he].indexOf(Ge)>=0,sn=rn?"width":"height",Re=en(t,{placement:pe,boundary:u,rootBoundary:d,altBoundary:p,padding:l}),ze=rn?ye?se:te:ye?he:X;M[sn]>P[sn]&&(ze=ai(ze));var Br=ai(ze),on=[];if(s&&on.push(Re[Ge]<=0),c&&on.push(Re[ze]<=0,Re[Br]<=0),on.every(function(xn){return xn})){q=pe,ee=!1;break}V.set(pe,on)}if(ee)for(var Vr=w?3:1,Oo=function(Lt){var Ti=E.find(function(jr){var an=V.get(jr);if(an)return an.slice(0,Lt).every(function(Ro){return Ro})});if(Ti)return q=Ti,"break"},Di=Vr;Di>0;Di--){var Ur=Oo(Di);if(Ur==="break")break}t.placement!==q&&(t.modifiersData[i]._skip=!0,t.placement=q,t.reset=!0)}}var wc={name:"flip",enabled:!0,phase:"main",fn:r0,requiresIfExists:["offset"],data:{_skip:!1}};function s0(n,t,e){var i=ae(n),r=[te,X].indexOf(i)>=0?-1:1,s=typeof e=="function"?e(Object.assign({},t,{placement:n})):e,o=s[0],c=s[1];return o=o||0,c=(c||0)*r,[te,se].indexOf(i)>=0?{x:c,y:o}:{x:o,y:c}}function o0(n){var t=n.state,e=n.options,i=n.name,r=e.offset,s=r===void 0?[0,0]:r,o=Hs.reduce(function(u,d){return u[d]=s0(d,t.rects,s),u},{}),c=o[t.placement],a=c.x,l=c.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=a,t.modifiersData.popperOffsets.y+=l),t.modifiersData[i]=o}var Dc={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:o0};function a0(n){var t=n.state,e=n.name;t.modifiersData[e]=Dr({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}var uf={name:"popperOffsets",enabled:!0,phase:"read",fn:a0,data:{}};function Tc(n){return n==="x"?"y":"x"}function c0(n){var t=n.state,e=n.options,i=n.name,r=e.mainAxis,s=r===void 0?!0:r,o=e.altAxis,c=o===void 0?!1:o,a=e.boundary,l=e.rootBoundary,u=e.altBoundary,d=e.padding,p=e.tether,g=p===void 0?!0:p,w=e.tetherOffset,v=w===void 0?0:w,_=en(t,{boundary:a,rootBoundary:l,padding:d,altBoundary:u}),S=ae(t.placement),x=je(t.placement),D=!x,E=wn(S),M=Tc(E),P=t.modifiersData.popperOffsets,V=t.rects.reference,ee=t.rects.popper,q=typeof v=="function"?v(Object.assign({},t.rects,{placement:t.placement})):v,Y=typeof q=="number"?{mainAxis:q,altAxis:q}:Object.assign({mainAxis:0,altAxis:0},q),pe=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,Ge={x:0,y:0};if(P){if(s){var ye,rn=E==="y"?X:te,sn=E==="y"?he:se,Re=E==="y"?"height":"width",ze=P[E],Br=ze+_[rn],on=ze-_[sn],Vr=g?-ee[Re]/2:0,Oo=x===Ot?V[Re]:ee[Re],Di=x===Ot?-ee[Re]:-V[Re],Ur=t.elements.arrow,xn=g&&Ur?bn(Ur):{width:0,height:0},Lt=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:yr(),Ti=Lt[rn],jr=Lt[sn],an=Dn(0,V[Re],xn[Re]),Ro=D?V[Re]/2-Vr-an-Ti-Y.mainAxis:Oo-an-Ti-Y.mainAxis,tg=D?-V[Re]/2+Vr+an+jr+Y.mainAxis:Di+an+jr+Y.mainAxis,Mo=t.elements.arrow&&tt(t.elements.arrow),ng=Mo?E==="y"?Mo.clientTop||0:Mo.clientLeft||0:0,Zl=(ye=pe?.[E])!=null?ye:0,ig=ze+Ro-Zl-ng,rg=ze+tg-Zl,Xl=Dn(g?yn(Br,ig):Br,ze,g?et(on,rg):on);P[E]=Xl,Ge[E]=Xl-ze}if(c){var eu,sg=E==="x"?X:te,og=E==="x"?he:se,cn=P[M],$r=M==="y"?"height":"width",tu=cn+_[sg],nu=cn-_[og],Po=[X,te].indexOf(S)!==-1,iu=(eu=pe?.[M])!=null?eu:0,ru=Po?tu:cn-V[$r]-ee[$r]-iu+Y.altAxis,su=Po?cn+V[$r]+ee[$r]-iu-Y.altAxis:nu,ou=g&&Po?sf(ru,cn,su):Dn(g?ru:tu,cn,g?su:nu);P[M]=ou,Ge[M]=ou-cn}t.modifiersData[i]=Ge}}var Ec={name:"preventOverflow",enabled:!0,phase:"main",fn:c0,requiresIfExists:["offset"]};function Cc(n){return{scrollLeft:n.scrollLeft,scrollTop:n.scrollTop}}function Sc(n){return n===z(n)||!ne(n)?Tn(n):Cc(n)}function l0(n){var t=n.getBoundingClientRect(),e=Rt(t.width)/n.offsetWidth||1,i=Rt(t.height)/n.offsetHeight||1;return e!==1||i!==1}function Ic(n,t,e){e===void 0&&(e=!1);var i=ne(t),r=ne(t)&&l0(t),s=fe(t),o=Ue(n,r,e),c={scrollLeft:0,scrollTop:0},a={x:0,y:0};return(i||!i&&!e)&&((oe(t)!=="body"||Cn(s))&&(c=Sc(t)),ne(t)?(a=Ue(t,!0),a.x+=t.clientLeft,a.y+=t.clientTop):s&&(a.x=En(s))),{x:o.left+c.scrollLeft-a.x,y:o.top+c.scrollTop-a.y,width:o.width,height:o.height}}function u0(n){var t=new Map,e=new Set,i=[];n.forEach(function(s){t.set(s.name,s)});function r(s){e.add(s.name);var o=[].concat(s.requires||[],s.requiresIfExists||[]);o.forEach(function(c){if(!e.has(c)){var a=t.get(c);a&&r(a)}}),i.push(s)}return n.forEach(function(s){e.has(s.name)||r(s)}),i}function Ac(n){var t=u0(n);return tf.reduce(function(e,i){return e.concat(t.filter(function(r){return r.phase===i}))},[])}function Oc(n){var t;return function(){return t||(t=new Promise(function(e){Promise.resolve().then(function(){t=void 0,e(n())})})),t}}function Rc(n){var t=n.reduce(function(e,i){var r=e[i.name];return e[i.name]=r?Object.assign({},r,i,{options:Object.assign({},r.options,i.options),data:Object.assign({},r.data,i.data)}):i,e},{});return Object.keys(t).map(function(e){return t[e]})}var df={placement:"bottom",modifiers:[],strategy:"absolute"};function hf(){for(var n=arguments.length,t=new Array(n),e=0;e<n;e++)t[e]=arguments[e];return!t.some(function(i){return!(i&&typeof i.getBoundingClientRect=="function")})}function ff(n){n===void 0&&(n={});var t=n,e=t.defaultModifiers,i=e===void 0?[]:e,r=t.defaultOptions,s=r===void 0?df:r;return function(c,a,l){l===void 0&&(l=s);var u={placement:"bottom",orderedModifiers:[],options:Object.assign({},df,s),modifiersData:{},elements:{reference:c,popper:a},attributes:{},styles:{}},d=[],p=!1,g={state:u,setOptions:function(S){var x=typeof S=="function"?S(u.options):S;v(),u.options=Object.assign({},s,u.options,x),u.scrollParents={reference:Ve(c)?Xt(c):c.contextElement?Xt(c.contextElement):[],popper:Xt(a)};var D=Ac(Rc([].concat(i,u.options.modifiers)));return u.orderedModifiers=D.filter(function(E){return E.enabled}),w(),g.update()},forceUpdate:function(){if(!p){var S=u.elements,x=S.reference,D=S.popper;if(hf(x,D)){u.rects={reference:Ic(x,tt(D),u.options.strategy==="fixed"),popper:bn(D)},u.reset=!1,u.placement=u.options.placement,u.orderedModifiers.forEach(function(Y){return u.modifiersData[Y.name]=Object.assign({},Y.data)});for(var E=0;E<u.orderedModifiers.length;E++){if(u.reset===!0){u.reset=!1,E=-1;continue}var M=u.orderedModifiers[E],P=M.fn,V=M.options,ee=V===void 0?{}:V,q=M.name;typeof P=="function"&&(u=P({state:u,options:ee,name:q,instance:g})||u)}}}},update:Oc(function(){return new Promise(function(_){g.forceUpdate(),_(u)})}),destroy:function(){v(),p=!0}};if(!hf(c,a))return g;g.setOptions(l).then(function(_){!p&&l.onFirstUpdate&&l.onFirstUpdate(_)});function w(){u.orderedModifiers.forEach(function(_){var S=_.name,x=_.options,D=x===void 0?{}:x,E=_.effect;if(typeof E=="function"){var M=E({state:u,name:S,instance:g,options:D}),P=function(){};d.push(M||P)}})}function v(){d.forEach(function(_){return _()}),d=[]}return g}}var d0=[cf,uf,af,nf],Mc=ff({defaultModifiers:d0});var bf=["*"];var h0=["dialog"];function f0(n,t){if(n&1&&(Ae(0,"span"),Le(1),Fe()),n&2){let e=de().$implicit,i=de();_e(i.highlightClass),K(),ea(e)}}function p0(n,t){if(n&1&&(Ri(0),Le(1),Mi()),n&2){let e=de().$implicit;K(),ea(e)}}function g0(n,t){if(n&1&&dn(0,f0,2,4,"span",0)(1,p0,2,1,"ng-container"),n&2){let e=t.$index;Hu(e%2!==0?0:1)}}var wf={animation:!0,transitionTimerDelayMs:5},Qs=(()=>{class n{constructor(){this.animation=wf.animation}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),m0=(()=>{class n{constructor(){this._ngbConfig=h(Qs),this.closeOthers=!1,this.destroyOnHide=!0}get animation(){return this._animation??this._ngbConfig.animation}set animation(e){this._animation=e}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();function _0(n){let{transitionDelay:t,transitionDuration:e}=window.getComputedStyle(n),i=parseFloat(t),r=parseFloat(e);return(i+r)*1e3}function pf(n){return n!=null?`${n}`:""}function Zs(n){return typeof n=="string"}function li(n){return n!=null}function Df(n){return n&&n.then}function v0(n){return n.replace(/[-[\]{}()*+?.,\\^$|#\s]/g,"\\$&")}function y0(n,t){return!t||typeof n.closest>"u"?null:n.closest(t)}function Tr(n){return(n||document.body).getBoundingClientRect()}function b0(n){return t=>new Ne(e=>{let i=o=>n.run(()=>e.next(o)),r=o=>n.run(()=>e.error(o)),s=()=>n.run(()=>e.complete());return t.subscribe({next:i,error:r,complete:s})})}function gf(n){return n.normalize("NFD").replace(/[\u0300-\u036f]/g,"")}function Tf(n=document){let t=n?.activeElement;return t?t.shadowRoot?Tf(t.shadowRoot):t:null}var w0=()=>{},{transitionTimerDelayMs:D0}=wf,qs=new Map,He=(n,t,e,i)=>{let r=i.context||{},s=qs.get(t);if(s)switch(i.runningTransition){case"continue":return rt;case"stop":n.run(()=>s.transition$.complete()),r=Object.assign(s.context,r),qs.delete(t)}let o=e(t,i.animation,r)||w0;if(!i.animation||window.getComputedStyle(t).transitionProperty==="none")return n.run(()=>o()),b(void 0).pipe(b0(n));let c=new N,a=new N,l=c.pipe(bu(!0));qs.set(t,{transition$:c,complete:()=>{a.next(),a.complete()},context:r});let u=_0(t);return n.runOutsideAngular(()=>{let d=we(t,"transitionend").pipe(W(l),ce(({target:g})=>g===t)),p=_u(u+D0).pipe(W(l));Vo(p,d,a).pipe(W(l)).subscribe(()=>{qs.delete(t),n.run(()=>{o(),c.next(),c.complete()})})}),c.asObservable()};function T0(n,t){if(typeof navigator>"u")return"0px";let{classList:e}=n,i=e.contains("show");i||e.add("show"),n.style[t]="";let r=n.getBoundingClientRect()[t]+"px";return i||e.remove("show"),r}var E0=(n,t,e)=>{let{direction:i,maxSize:r,dimension:s}=e,{classList:o}=n;function c(){o.add("collapse"),i==="show"?o.add("show"):o.remove("show")}if(!t){c();return}return r||(r=T0(n,s),e.maxSize=r,n.style[s]=i!=="show"?r:"0px",o.remove("collapse"),o.remove("collapsing"),o.remove("show"),Tr(n),o.add("collapsing")),n.style[s]=i==="show"?r:"0px",()=>{c(),o.remove("collapsing"),n.style[s]=""}},C0=(()=>{class n{constructor(){this._ngbConfig=h(Qs),this.horizontal=!1}get animation(){return this._animation??this._ngbConfig.animation}set animation(e){this._animation=e}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),mf=(()=>{class n{constructor(){this._config=h(C0),this._element=h(ie),this._zone=h($),this.animation=this._config.animation,this._afterInit=!1,this._isCollapsed=!1,this.ngbCollapseChange=new B,this.horizontal=this._config.horizontal,this.shown=new B,this.hidden=new B}set collapsed(e){this._isCollapsed!==e&&(this._isCollapsed=e,this._afterInit&&this._runTransitionWithEvents(e,this.animation))}ngOnInit(){this._runTransition(this._isCollapsed,!1),this._afterInit=!0}toggle(e=this._isCollapsed){this.collapsed=!e,this.ngbCollapseChange.next(this._isCollapsed)}_runTransition(e,i){return He(this._zone,this._element.nativeElement,E0,{animation:i,runningTransition:"stop",context:{direction:e?"hide":"show",dimension:this.horizontal?"width":"height"}})}_runTransitionWithEvents(e,i){this._runTransition(e,i).subscribe(()=>{e?this.hidden.emit():this.shown.emit()})}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbCollapse",""]],hostVars:2,hostBindings:function(i,r){i&2&&Z("collapse-horizontal",r.horizontal)},inputs:{animation:"animation",collapsed:[0,"ngbCollapse","collapsed"],horizontal:"horizontal"},outputs:{ngbCollapseChange:"ngbCollapseChange",shown:"shown",hidden:"hidden"},exportAs:["ngbCollapse"],standalone:!0})}}return n})(),S0=0,UA=(()=>{class n{constructor(){this._vcr=h(Jr),this._element=h(ie).nativeElement,this._item=h(ui),this._viewRef=null}ngAfterContentChecked(){this._bodyTpl&&(this._item._shouldBeInDOM?this._createViewIfNotExists():this._destroyViewIfExists())}ngOnDestroy(){this._destroyViewIfExists()}_destroyViewIfExists(){this._viewRef&&(this._viewRef.destroy(),this._viewRef=null)}_createViewIfNotExists(){if(!this._viewRef){this._viewRef=this._vcr.createEmbeddedView(this._bodyTpl),this._viewRef.detectChanges();for(let e of this._viewRef.rootNodes)this._element.appendChild(e)}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbAccordionBody",""]],contentQueries:function(i,r,s){if(i&1&&$t(s,qr,7),i&2){let o;Dt(o=Tt())&&(r._bodyTpl=o.first)}},hostVars:2,hostBindings:function(i,r){i&2&&Z("accordion-body",!0)},standalone:!0})}}return n})(),I0=(()=>{class n{constructor(){this.item=h(ui),this.ngbCollapse=h(mf)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbAccordionCollapse",""]],hostAttrs:["role","region"],hostVars:4,hostBindings:function(i,r){i&2&&(hn("id",r.item.collapseId),Te("aria-labelledby",r.item.toggleId),Z("accordion-collapse",!0))},exportAs:["ngbAccordionCollapse"],standalone:!0,features:[Yo([mf])]})}}return n})(),A0=(()=>{class n{constructor(){this.item=h(ui),this.accordion=h(Ef)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbAccordionToggle",""]],hostVars:5,hostBindings:function(i,r){i&1&&ue("click",function(){return!r.item.disabled&&r.accordion.toggle(r.item.id)}),i&2&&(hn("id",r.item.toggleId),Te("aria-controls",r.item.collapseId)("aria-expanded",!r.item.collapsed),Z("collapsed",r.item.collapsed))},standalone:!0})}}return n})(),jA=(()=>{class n{constructor(){this.item=h(ui)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["button","ngbAccordionButton",""]],hostAttrs:["type","button"],hostVars:3,hostBindings:function(i,r){i&2&&(hn("disabled",r.item.disabled),Z("accordion-button",!0))},standalone:!0,features:[Yo([A0])]})}}return n})(),$A=(()=>{class n{constructor(){this.item=h(ui)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbAccordionHeader",""]],hostAttrs:["role","heading"],hostVars:4,hostBindings:function(i,r){i&2&&Z("accordion-header",!0)("collapsed",r.item.collapsed)},standalone:!0})}}return n})(),ui=(()=>{class n{constructor(){this._accordion=h(Ef),this._cd=h(Ct),this._destroyRef=h(Ii),this._collapsed=!0,this._id=`ngb-accordion-item-${S0++}`,this._collapseAnimationRunning=!1,this.disabled=!1,this.show=new B,this.shown=new B,this.hide=new B,this.hidden=new B}set id(e){Zs(e)&&e!==""&&(this._id=e)}set destroyOnHide(e){this._destroyOnHide=e}get destroyOnHide(){return this._destroyOnHide===void 0?this._accordion.destroyOnHide:this._destroyOnHide}set collapsed(e){e?this.collapse():this.expand()}get collapsed(){return this._collapsed}get id(){return`${this._id}`}get toggleId(){return`${this.id}-toggle`}get collapseId(){return`${this.id}-collapse`}get _shouldBeInDOM(){return!this.collapsed||this._collapseAnimationRunning||!this.destroyOnHide}ngAfterContentInit(){let{ngbCollapse:e}=this._collapse;e.animation=!1,e.collapsed=this.collapsed,e.animation=this._accordion.animation,e.hidden.pipe(Ms(this._destroyRef)).subscribe(()=>{this._collapseAnimationRunning=!1,this.hidden.emit(),this._accordion.hidden.emit(this.id)}),e.shown.pipe(Ms(this._destroyRef)).subscribe(()=>{this.shown.emit(),this._accordion.shown.emit(this.id)})}toggle(){this.collapsed=!this.collapsed}expand(){if(this.collapsed){if(!this._accordion._ensureCanExpand(this))return;this._collapsed=!1,this._cd.markForCheck(),this._cd.detectChanges(),this.show.emit(),this._accordion.show.emit(this.id),this._collapse.ngbCollapse.animation=this._accordion.animation,this._collapse.ngbCollapse.collapsed=!1}}collapse(){this.collapsed||(this._collapsed=!0,this._collapseAnimationRunning=!0,this._cd.markForCheck(),this.hide.emit(),this._accordion.hide.emit(this.id),this._collapse.ngbCollapse.animation=this._accordion.animation,this._collapse.ngbCollapse.collapsed=!0)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbAccordionItem",""]],contentQueries:function(i,r,s){if(i&1&&$t(s,I0,7),i&2){let o;Dt(o=Tt())&&(r._collapse=o.first)}},hostVars:3,hostBindings:function(i,r){i&2&&(hn("id",r.id),Z("accordion-item",!0))},inputs:{id:[0,"ngbAccordionItem","id"],destroyOnHide:"destroyOnHide",disabled:"disabled",collapsed:"collapsed"},outputs:{show:"show",shown:"shown",hide:"hide",hidden:"hidden"},exportAs:["ngbAccordionItem"],standalone:!0})}}return n})(),Ef=(()=>{class n{constructor(){this._config=h(m0),this._anItemWasAlreadyExpandedDuringInitialisation=!1,this.animation=this._config.animation,this.closeOthers=this._config.closeOthers,this.destroyOnHide=this._config.destroyOnHide,this.show=new B,this.shown=new B,this.hide=new B,this.hidden=new B}toggle(e){this._getItem(e)?.toggle()}expand(e){this._getItem(e)?.expand()}expandAll(){this._items&&(this.closeOthers?this._items.find(e=>!e.collapsed)||this._items.first.expand():this._items.forEach(e=>e.expand()))}collapse(e){this._getItem(e)?.collapse()}collapseAll(){this._items?.forEach(e=>e.collapse())}isExpanded(e){let i=this._getItem(e);return i?!i.collapsed:!1}_ensureCanExpand(e){return this.closeOthers?this._items?(this._items.find(i=>!i.collapsed&&e!==i)?.collapse(),!0):this._anItemWasAlreadyExpandedDuringInitialisation?!1:(this._anItemWasAlreadyExpandedDuringInitialisation=!0,!0):!0}_getItem(e){return this._items?.find(i=>i.id===e)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbAccordion",""]],contentQueries:function(i,r,s){if(i&1&&$t(s,ui,4),i&2){let o;Dt(o=Tt())&&(r._items=o)}},hostVars:2,hostBindings:function(i,r){i&2&&Z("accordion",!0)},inputs:{animation:"animation",closeOthers:"closeOthers",destroyOnHide:"destroyOnHide"},outputs:{show:"show",shown:"shown",hide:"hide",hidden:"hidden"},exportAs:["ngbAccordion"],standalone:!0})}}return n})();var HA=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Ie({type:n})}static{this.\u0275inj=Se({})}}return n})();var $e=function(n){return n[n.Tab=9]="Tab",n[n.Enter=13]="Enter",n[n.Escape=27]="Escape",n[n.Space=32]="Space",n[n.PageUp=33]="PageUp",n[n.PageDown=34]="PageDown",n[n.End=35]="End",n[n.Home=36]="Home",n[n.ArrowLeft=37]="ArrowLeft",n[n.ArrowUp=38]="ArrowUp",n[n.ArrowRight=39]="ArrowRight",n[n.ArrowDown=40]="ArrowDown",n}($e||{});var Js=(n,t)=>t?t.some(e=>e.contains(n)):!1,_f=(n,t)=>!t||y0(n,t)!=null,O0=(()=>{let n=()=>/iPad|iPhone|iPod/.test(navigator.userAgent)||/Macintosh/.test(navigator.userAgent)&&navigator.maxTouchPoints&&navigator.maxTouchPoints>2,t=()=>/Android/.test(navigator.userAgent);return typeof navigator<"u"?!!navigator.userAgent&&(n()||t()):!1})(),R0=n=>O0?()=>setTimeout(()=>n(),100):n;function M0(n,t,e,i,r,s,o,c){e&&n.runOutsideAngular(R0(()=>{let a=p=>{let g=p.target;return p.button===2||Js(g,o)?!1:e==="inside"?Js(g,s)&&_f(g,c):e==="outside"?!Js(g,s):_f(g,c)||!Js(g,s)},l=we(t,"keydown").pipe(W(r),ce(p=>p.which===$e.Escape),U(p=>p.preventDefault())),u=we(t,"mousedown").pipe(I(a),W(r)),d=we(t,"mouseup").pipe(Gr(u),ce(([p,g])=>g),yu(0),W(r));Vo([l.pipe(I(p=>0)),d.pipe(I(p=>1))]).subscribe(p=>n.run(()=>i(p)))}))}var Cf=["a[href]","button:not([disabled])",'input:not([disabled]):not([type="hidden"])',"select:not([disabled])","textarea:not([disabled])","[contenteditable]",'[tabindex]:not([tabindex="-1"])'].join(", ");function Fc(n){let t=Array.from(n.querySelectorAll(Cf)).filter(e=>e.tabIndex!==-1);return[t[0],t[t.length-1]]}var Sf=(n,t,e,i=!1)=>{n.runOutsideAngular(()=>{let r=we(t,"focusin").pipe(W(e),I(s=>s.target));we(t,"keydown").pipe(W(e),ce(s=>s.which===$e.Tab),Gr(r)).subscribe(([s,o])=>{let[c,a]=Fc(t);(o===c||o===t)&&s.shiftKey&&(a.focus(),s.preventDefault()),o===a&&!s.shiftKey&&(c.focus(),s.preventDefault())}),i&&we(t,"click").pipe(W(e),Gr(r),I(s=>s[1])).subscribe(s=>s.focus())})},P0=(()=>{class n{constructor(){this._element=h(G).documentElement}isRTL(){return(this._element.getAttribute("dir")||"").toLowerCase()==="rtl"}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),N0=/\s+/,k0=/ +/gi,x0={top:["top"],bottom:["bottom"],start:["left","right"],left:["left"],end:["right","left"],right:["right"],"top-start":["top-start","top-end"],"top-left":["top-start"],"top-end":["top-end","top-start"],"top-right":["top-end"],"bottom-start":["bottom-start","bottom-end"],"bottom-left":["bottom-start"],"bottom-end":["bottom-end","bottom-start"],"bottom-right":["bottom-end"],"start-top":["left-start","right-start"],"left-top":["left-start"],"start-bottom":["left-end","right-end"],"left-bottom":["left-end"],"end-top":["right-start","left-start"],"right-top":["right-start"],"end-bottom":["right-end","left-end"],"right-bottom":["right-end"]};function F0(n,t){let[e,i]=x0[n];return t&&i||e}var L0=/^left/,B0=/^right/,V0=/^start/,U0=/^end/;function j0(n,t){let[e,i]=t.split("-"),r=e.replace(L0,"start").replace(B0,"end"),s=[r];if(i){let o=i;(e==="left"||e==="right")&&(o=o.replace(V0,"top").replace(U0,"bottom")),s.push(`${r}-${o}`)}return n&&(s=s.map(o=>`${n}-${o}`)),s.join(" ")}function vf({placement:n,baseClass:t},e){let i=Array.isArray(n)?n:n.split(N0),r=["top","bottom","start","end","top-start","top-end","bottom-start","bottom-end","start-top","start-bottom","end-top","end-bottom"],s=i.findIndex(l=>l==="auto");s>=0&&r.forEach(function(l){i.find(u=>u.search("^"+l)!==-1)==null&&i.splice(s++,1,l)});let o=i.map(l=>F0(l,e.isRTL()));return{placement:o.shift(),modifiers:[{name:"bootstrapClasses",enabled:!!t,phase:"write",fn({state:l}){let u=new RegExp(t+"(-[a-z]+)*","gi"),d=l.elements.popper,p=l.placement,g=d.className;g=g.replace(u,""),g+=` ${j0(t,p)}`,g=g.trim().replace(k0," "),d.className=g}},wc,Ec,mc,{enabled:!0,name:"flip",options:{fallbackPlacements:o}},{enabled:!0,name:"preventOverflow",phase:"main",fn:function(){}}]}}function yf(n){return n}function $0(){let n=h(P0),t=null;return{createPopper(e){if(!t){let r=(e.updatePopperOptions||yf)(vf(e,n));t=Mc(e.hostElement,e.targetElement,r)}},update(){t&&t.update()},setOptions(e){if(t){let r=(e.updatePopperOptions||yf)(vf(e,n));t.setOptions(r)}},destroy(){t&&(t.destroy(),t=null)}}}function H0(n){return t=>(t.modifiers.push(Dc,{name:"offset",options:{offset:()=>n}}),t)}var GA=new Date(1882,10,12),zA=new Date(2174,10,25);var WA=1e3*60*60*24;var Lc=1080,G0=24*Lc,z0=12*Lc+793,qA=29*G0+z0,JA=11*Lc+204;var KA=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Ie({type:n})}static{this.\u0275inj=Se({})}}return n})(),W0=(()=>{class n{constructor(){this.autoClose=!0,this.placement=["bottom-start","bottom-end","top-start","top-end"],this.popperOptions=e=>e,this.container=null}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),If=(()=>{class n{constructor(){this._disabled=!1,this.nativeElement=h(ie).nativeElement,this.tabindex=0}set disabled(e){this._disabled=e===""||e===!0}get disabled(){return this._disabled}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbDropdownItem",""]],hostAttrs:[1,"dropdown-item"],hostVars:3,hostBindings:function(i,r){i&2&&(hn("tabIndex",r.disabled?-1:r.tabindex),Z("disabled",r.disabled))},inputs:{tabindex:"tabindex",disabled:"disabled"},standalone:!0})}}return n})(),YA=(()=>{class n{constructor(){this.item=h(If)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["button","ngbDropdownItem",""]],hostVars:1,hostBindings:function(i,r){i&2&&hn("disabled",r.item.disabled)},standalone:!0})}}return n})(),q0=(()=>{class n{constructor(){this.dropdown=h(Af),this.nativeElement=h(ie).nativeElement}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbDropdownMenu",""]],contentQueries:function(i,r,s){if(i&1&&$t(s,If,4),i&2){let o;Dt(o=Tt())&&(r.menuItems=o)}},hostVars:4,hostBindings:function(i,r){i&1&&ue("keydown.ArrowUp",function(o){return r.dropdown.onKeyDown(o)})("keydown.ArrowDown",function(o){return r.dropdown.onKeyDown(o)})("keydown.Home",function(o){return r.dropdown.onKeyDown(o)})("keydown.End",function(o){return r.dropdown.onKeyDown(o)})("keydown.Enter",function(o){return r.dropdown.onKeyDown(o)})("keydown.Space",function(o){return r.dropdown.onKeyDown(o)})("keydown.Tab",function(o){return r.dropdown.onKeyDown(o)})("keydown.Shift.Tab",function(o){return r.dropdown.onKeyDown(o)}),i&2&&Z("dropdown-menu",!0)("show",r.dropdown.isOpen())},standalone:!0})}}return n})(),Pc=(()=>{class n{constructor(){this.dropdown=h(Af),this.nativeElement=h(ie).nativeElement}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbDropdownAnchor",""]],hostAttrs:[1,"dropdown-toggle"],hostVars:3,hostBindings:function(i,r){i&2&&(Te("aria-expanded",r.dropdown.isOpen()),Z("show",r.dropdown.isOpen()))},standalone:!0})}}return n})(),QA=(()=>{class n extends Pc{static{this.\u0275fac=(()=>{let e;return function(r){return(e||(e=Ut(n)))(r||n)}})()}static{this.\u0275dir=F({type:n,selectors:[["","ngbDropdownToggle",""]],hostAttrs:[1,"dropdown-toggle"],hostVars:3,hostBindings:function(i,r){i&1&&ue("click",function(){return r.dropdown.toggle()})("keydown.ArrowUp",function(o){return r.dropdown.onKeyDown(o)})("keydown.ArrowDown",function(o){return r.dropdown.onKeyDown(o)})("keydown.Home",function(o){return r.dropdown.onKeyDown(o)})("keydown.End",function(o){return r.dropdown.onKeyDown(o)})("keydown.Tab",function(o){return r.dropdown.onKeyDown(o)})("keydown.Shift.Tab",function(o){return r.dropdown.onKeyDown(o)}),i&2&&(Te("aria-expanded",r.dropdown.isOpen()),Z("show",r.dropdown.isOpen()))},standalone:!0,features:[Et([{provide:Pc,useExisting:bt(()=>n)}]),xe]})}}return n})(),Af=(()=>{class n{constructor(){this._changeDetector=h(Ct),this._config=h(W0),this._document=h(G),this._ngZone=h($),this._nativeElement=h(ie).nativeElement,this._destroyCloseHandlers$=new N,this._bodyContainer=null,this._positioning=$0(),this.autoClose=this._config.autoClose,this._open=!1,this.placement=this._config.placement,this.popperOptions=this._config.popperOptions,this.container=this._config.container,this.openChange=new B}ngOnInit(){this.display||(this.display=this._nativeElement.closest(".navbar")?"static":"dynamic")}ngAfterContentInit(){this._ngZone.onStable.pipe(ge(1)).subscribe(()=>{this._applyPlacementClasses(),this._open&&this._setCloseHandlers()})}ngOnChanges(e){if(e.container&&this._open&&this._applyContainer(this.container),e.placement&&!e.placement.firstChange&&(this._positioning.setOptions({hostElement:this._anchor.nativeElement,targetElement:this._bodyContainer||this._menu.nativeElement,placement:this.placement,appendToBody:this.container==="body"}),this._applyPlacementClasses()),e.dropdownClass){let{currentValue:i,previousValue:r}=e.dropdownClass;this._applyCustomDropdownClass(i,r)}e.autoClose&&this._open&&(this.autoClose=e.autoClose.currentValue,this._setCloseHandlers())}isOpen(){return this._open}open(){this._open||(this._open=!0,this._applyContainer(this.container),this.openChange.emit(!0),this._setCloseHandlers(),this._anchor&&(this._anchor.nativeElement.focus(),this.display==="dynamic"&&this._ngZone.runOutsideAngular(()=>{this._positioning.createPopper({hostElement:this._anchor.nativeElement,targetElement:this._bodyContainer||this._menu.nativeElement,placement:this.placement,appendToBody:this.container==="body",updatePopperOptions:e=>this.popperOptions(H0([0,2])(e))}),this._applyPlacementClasses(),this._zoneSubscription=this._ngZone.onStable.subscribe(()=>this._positionMenu())})))}_setCloseHandlers(){this._destroyCloseHandlers$.next(),M0(this._ngZone,this._document,this.autoClose,e=>{this.close(),e===0&&this._anchor.nativeElement.focus()},this._destroyCloseHandlers$,this._menu?[this._menu.nativeElement]:[],this._anchor?[this._anchor.nativeElement]:[],".dropdown-item,.dropdown-divider")}close(){this._open&&(this._open=!1,this._resetContainer(),this._positioning.destroy(),this._zoneSubscription?.unsubscribe(),this._destroyCloseHandlers$.next(),this.openChange.emit(!1),this._changeDetector.markForCheck())}toggle(){this.isOpen()?this.close():this.open()}ngOnDestroy(){this.close()}onKeyDown(e){let i=e.which,r=this._getMenuElements(),s=-1,o=null,c=this._isEventFromToggle(e);if(!c&&r.length&&r.forEach((a,l)=>{a.contains(e.target)&&(o=a),a===Tf(this._document)&&(s=l)}),i===$e.Space||i===$e.Enter){o&&(this.autoClose===!0||this.autoClose==="inside")&&we(o,"click").pipe(ge(1)).subscribe(()=>this.close());return}if(i===$e.Tab){if(e.target&&this.isOpen()&&this.autoClose)if(this._anchor.nativeElement===e.target){this.container==="body"&&!e.shiftKey?(this._menu.nativeElement.setAttribute("tabindex","0"),this._menu.nativeElement.focus(),this._menu.nativeElement.removeAttribute("tabindex")):e.shiftKey&&this.close();return}else if(this.container==="body"){let a=this._menu.nativeElement.querySelectorAll(Cf);e.shiftKey&&e.target===a[0]?(this._anchor.nativeElement.focus(),e.preventDefault()):!e.shiftKey&&e.target===a[a.length-1]&&(this._anchor.nativeElement.focus(),this.close())}else we(e.target,"focusout").pipe(ge(1)).subscribe(({relatedTarget:a})=>{this._nativeElement.contains(a)||this.close()});return}if(c||o){if(this.open(),r.length){switch(i){case $e.ArrowDown:s=Math.min(s+1,r.length-1);break;case $e.ArrowUp:if(this._isDropup()&&s===-1){s=r.length-1;break}s=Math.max(s-1,0);break;case $e.Home:s=0;break;case $e.End:s=r.length-1;break}r[s].focus()}e.preventDefault()}}_isDropup(){return this._nativeElement.classList.contains("dropup")}_isEventFromToggle(e){return this._anchor.nativeElement.contains(e.target)}_getMenuElements(){return this._menu?this._menu.menuItems.filter(({disabled:e})=>!e).map(({nativeElement:e})=>e):[]}_positionMenu(){let e=this._menu;this.isOpen()&&e&&(this.display==="dynamic"?(this._positioning.update(),this._applyPlacementClasses()):this._applyPlacementClasses(this._getFirstPlacement(this.placement)))}_getFirstPlacement(e){return Array.isArray(e)?e[0]:e.split(" ")[0]}_resetContainer(){this._menu&&this._nativeElement.appendChild(this._menu.nativeElement),this._bodyContainer&&(this._document.body.removeChild(this._bodyContainer),this._bodyContainer=null)}_applyContainer(e=null){if(this._resetContainer(),e==="body"){let i=this._menu.nativeElement,r=this._bodyContainer=this._bodyContainer||this._document.createElement("div");r.style.position="absolute",i.style.position="static",r.style.zIndex="1055",r.appendChild(i),this._document.body.appendChild(r)}this._applyCustomDropdownClass(this.dropdownClass)}_applyCustomDropdownClass(e,i){let r=this.container==="body"?this._bodyContainer:this._nativeElement;r&&(i&&r.classList.remove(i),e&&r.classList.add(e))}_applyPlacementClasses(e){if(this._menu){e||(e=this._getFirstPlacement(this.placement)),this._nativeElement.classList.remove("dropup","dropdown"),this.display==="static"?this._menu.nativeElement.setAttribute("data-bs-popper","static"):this._menu.nativeElement.removeAttribute("data-bs-popper");let i=e.search("^top")!==-1?"dropup":"dropdown";this._nativeElement.classList.add(i),this._bodyContainer&&(this._bodyContainer.classList.remove("dropup","dropdown"),this._bodyContainer.classList.add(i))}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275dir=F({type:n,selectors:[["","ngbDropdown",""]],contentQueries:function(i,r,s){if(i&1&&($t(s,q0,5),$t(s,Pc,5)),i&2){let o;Dt(o=Tt())&&(r._menu=o.first),Dt(o=Tt())&&(r._anchor=o.first)}},hostVars:2,hostBindings:function(i,r){i&2&&Z("show",r.isOpen())},inputs:{autoClose:"autoClose",dropdownClass:"dropdownClass",_open:[0,"open","_open"],placement:"placement",popperOptions:"popperOptions",container:"container",display:"display"},outputs:{openChange:"openChange"},exportAs:["ngbDropdown"],standalone:!0,features:[at]})}}return n})();var ZA=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Ie({type:n})}static{this.\u0275inj=Se({})}}return n})(),J0=(()=>{class n{constructor(){this._ngbConfig=h(Qs),this.backdrop=!0,this.fullscreen=!1,this.keyboard=!0}get animation(){return this._animation??this._ngbConfig.animation}set animation(e){this._animation=e}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),ft=class{constructor(t,e,i){this.nodes=t,this.viewRef=e,this.componentRef=i}};var Of=(()=>{class n{constructor(){this._document=h(G)}hide(){let e=Math.abs(window.innerWidth-this._document.documentElement.clientWidth),i=this._document.body,r=i.style,{overflow:s,paddingRight:o}=r;if(e>0){let c=parseFloat(window.getComputedStyle(i).paddingRight);r.paddingRight=`${c+e}px`}return r.overflow="hidden",()=>{e>0&&(r.paddingRight=o),r.overflow=s}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),K0=(()=>{class n{constructor(){this._nativeElement=h(ie).nativeElement,this._zone=h($)}ngOnInit(){this._zone.onStable.asObservable().pipe(ge(1)).subscribe(()=>{He(this._zone,this._nativeElement,(e,i)=>{i&&Tr(e),e.classList.add("show")},{animation:this.animation,runningTransition:"continue"})})}hide(){return He(this._zone,this._nativeElement,({classList:e})=>e.remove("show"),{animation:this.animation,runningTransition:"stop"})}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=We({type:n,selectors:[["ngb-modal-backdrop"]],hostAttrs:[2,"z-index","1055"],hostVars:6,hostBindings:function(i,r){i&2&&(_e("modal-backdrop"+(r.backdropClass?" "+r.backdropClass:"")),Z("show",!r.animation)("fade",r.animation))},inputs:{animation:"animation",backdropClass:"backdropClass"},standalone:!0,features:[Ke],decls:0,vars:0,template:function(i,r){},encapsulation:2})}}return n})(),Ks=class{update(t){}close(t){}dismiss(t){}},Y0=["animation","ariaLabelledBy","ariaDescribedBy","backdrop","centered","fullscreen","keyboard","scrollable","size","windowClass","modalDialogClass"],Q0=["animation","backdropClass"],Nc=class{_applyWindowOptions(t,e){Y0.forEach(i=>{li(e[i])&&(t[i]=e[i])})}_applyBackdropOptions(t,e){Q0.forEach(i=>{li(e[i])&&(t[i]=e[i])})}update(t){this._applyWindowOptions(this._windowCmptRef.instance,t),this._backdropCmptRef&&this._backdropCmptRef.instance&&this._applyBackdropOptions(this._backdropCmptRef.instance,t)}get componentInstance(){if(this._contentRef&&this._contentRef.componentRef)return this._contentRef.componentRef.instance}get closed(){return this._closed.asObservable().pipe(W(this._hidden))}get dismissed(){return this._dismissed.asObservable().pipe(W(this._hidden))}get hidden(){return this._hidden.asObservable()}get shown(){return this._windowCmptRef.instance.shown.asObservable()}constructor(t,e,i,r){this._windowCmptRef=t,this._contentRef=e,this._backdropCmptRef=i,this._beforeDismiss=r,this._closed=new N,this._dismissed=new N,this._hidden=new N,t.instance.dismissEvent.subscribe(s=>{this.dismiss(s)}),this.result=new Promise((s,o)=>{this._resolve=s,this._reject=o}),this.result.then(null,()=>{})}close(t){this._windowCmptRef&&(this._closed.next(t),this._resolve(t),this._removeModalElements())}_dismiss(t){this._dismissed.next(t),this._reject(t),this._removeModalElements()}dismiss(t){if(this._windowCmptRef)if(!this._beforeDismiss)this._dismiss(t);else{let e=this._beforeDismiss();Df(e)?e.then(i=>{i!==!1&&this._dismiss(t)},()=>{}):e!==!1&&this._dismiss(t)}}_removeModalElements(){let t=this._windowCmptRef.instance.hide(),e=this._backdropCmptRef?this._backdropCmptRef.instance.hide():b(void 0);t.subscribe(()=>{let{nativeElement:i}=this._windowCmptRef.location;i.parentNode.removeChild(i),this._windowCmptRef.destroy(),this._contentRef&&this._contentRef.viewRef&&this._contentRef.viewRef.destroy(),this._windowCmptRef=null,this._contentRef=null}),e.subscribe(()=>{if(this._backdropCmptRef){let{nativeElement:i}=this._backdropCmptRef.location;i.parentNode.removeChild(i),this._backdropCmptRef.destroy(),this._backdropCmptRef=null}}),Ci(t,e).subscribe(()=>{this._hidden.next(),this._hidden.complete()})}},kc=function(n){return n[n.BACKDROP_CLICK=0]="BACKDROP_CLICK",n[n.ESC=1]="ESC",n}(kc||{}),Z0=(()=>{class n{constructor(){this._document=h(G),this._elRef=h(ie),this._zone=h($),this._closed$=new N,this._elWithFocus=null,this.backdrop=!0,this.keyboard=!0,this.dismissEvent=new B,this.shown=new N,this.hidden=new N}get fullscreenClass(){return this.fullscreen===!0?" modal-fullscreen":Zs(this.fullscreen)?` modal-fullscreen-${this.fullscreen}-down`:""}dismiss(e){this.dismissEvent.emit(e)}ngOnInit(){this._elWithFocus=this._document.activeElement,this._zone.onStable.asObservable().pipe(ge(1)).subscribe(()=>{this._show()})}ngOnDestroy(){this._disableEventHandling()}hide(){let{nativeElement:e}=this._elRef,i={animation:this.animation,runningTransition:"stop"},r=He(this._zone,e,()=>e.classList.remove("show"),i),s=He(this._zone,this._dialogEl.nativeElement,()=>{},i),o=Ci(r,s);return o.subscribe(()=>{this.hidden.next(),this.hidden.complete()}),this._disableEventHandling(),this._restoreFocus(),o}_show(){let e={animation:this.animation,runningTransition:"continue"},i=He(this._zone,this._elRef.nativeElement,(s,o)=>{o&&Tr(s),s.classList.add("show")},e),r=He(this._zone,this._dialogEl.nativeElement,()=>{},e);Ci(i,r).subscribe(()=>{this.shown.next(),this.shown.complete()}),this._enableEventHandling(),this._setFocus()}_enableEventHandling(){let{nativeElement:e}=this._elRef;this._zone.runOutsideAngular(()=>{we(e,"keydown").pipe(W(this._closed$),ce(r=>r.which===$e.Escape)).subscribe(r=>{this.keyboard?requestAnimationFrame(()=>{r.defaultPrevented||this._zone.run(()=>this.dismiss(kc.ESC))}):this.backdrop==="static"&&this._bumpBackdrop()});let i=!1;we(this._dialogEl.nativeElement,"mousedown").pipe(W(this._closed$),U(()=>i=!1),le(()=>we(e,"mouseup").pipe(W(this._closed$),ge(1))),ce(({target:r})=>e===r)).subscribe(()=>{i=!0}),we(e,"click").pipe(W(this._closed$)).subscribe(({target:r})=>{e===r&&(this.backdrop==="static"?this._bumpBackdrop():this.backdrop===!0&&!i&&this._zone.run(()=>this.dismiss(kc.BACKDROP_CLICK))),i=!1})})}_disableEventHandling(){this._closed$.next()}_setFocus(){let{nativeElement:e}=this._elRef;if(!e.contains(document.activeElement)){let i=e.querySelector("[ngbAutofocus]"),r=Fc(e)[0];(i||r||e).focus()}}_restoreFocus(){let e=this._document.body,i=this._elWithFocus,r;i&&i.focus&&e.contains(i)?r=i:r=e,this._zone.runOutsideAngular(()=>{setTimeout(()=>r.focus()),this._elWithFocus=null})}_bumpBackdrop(){this.backdrop==="static"&&He(this._zone,this._elRef.nativeElement,({classList:e})=>(e.add("modal-static"),()=>e.remove("modal-static")),{animation:this.animation,runningTransition:"continue"})}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=We({type:n,selectors:[["ngb-modal-window"]],viewQuery:function(i,r){if(i&1&&Ju(h0,7),i&2){let s;Dt(s=Tt())&&(r._dialogEl=s.first)}},hostAttrs:["role","dialog","tabindex","-1"],hostVars:7,hostBindings:function(i,r){i&2&&(Te("aria-modal",!0)("aria-labelledby",r.ariaLabelledBy)("aria-describedby",r.ariaDescribedBy),_e("modal d-block"+(r.windowClass?" "+r.windowClass:"")),Z("fade",r.animation))},inputs:{animation:"animation",ariaLabelledBy:"ariaLabelledBy",ariaDescribedBy:"ariaDescribedBy",backdrop:"backdrop",centered:"centered",fullscreen:"fullscreen",keyboard:"keyboard",scrollable:"scrollable",size:"size",windowClass:"windowClass",modalDialogClass:"modalDialogClass"},outputs:{dismissEvent:"dismiss"},standalone:!0,features:[Ke],ngContentSelectors:bf,decls:4,vars:2,consts:[["dialog",""],["role","document"],[1,"modal-content"]],template:function(i,r){i&1&&(Zo(),Ae(0,"div",1,0)(2,"div",2),Xo(3),Fe()()),i&2&&_e("modal-dialog"+(r.size?" modal-"+r.size:"")+(r.centered?" modal-dialog-centered":"")+r.fullscreenClass+(r.scrollable?" modal-dialog-scrollable":"")+(r.modalDialogClass?" "+r.modalDialogClass:""))},styles:[`ngb-modal-window .component-host-scrollable{display:flex;flex-direction:column;overflow:hidden}
3
- `],encapsulation:2})}}return n})(),X0=(()=>{class n{constructor(){this._applicationRef=h(Ye),this._injector=h(J),this._environmentInjector=h(ot),this._document=h(G),this._scrollBar=h(Of),this._activeWindowCmptHasChanged=new N,this._ariaHiddenValues=new Map,this._scrollBarRestoreFn=null,this._modalRefs=[],this._windowCmpts=[],this._activeInstances=new B;let e=h($);this._activeWindowCmptHasChanged.subscribe(()=>{if(this._windowCmpts.length){let i=this._windowCmpts[this._windowCmpts.length-1];Sf(e,i.location.nativeElement,this._activeWindowCmptHasChanged),this._revertAriaHidden(),this._setAriaHidden(i.location.nativeElement)}})}_restoreScrollBar(){let e=this._scrollBarRestoreFn;e&&(this._scrollBarRestoreFn=null,e())}_hideScrollBar(){this._scrollBarRestoreFn||(this._scrollBarRestoreFn=this._scrollBar.hide())}open(e,i,r){let s=r.container instanceof HTMLElement?r.container:li(r.container)?this._document.querySelector(r.container):this._document.body;if(!s)throw new Error(`The specified modal container "${r.container||"body"}" was not found in the DOM.`);this._hideScrollBar();let o=new Ks;e=r.injector||e;let c=e.get(ot,null)||this._environmentInjector,a=this._getContentRef(e,c,i,o,r),l=r.backdrop!==!1?this._attachBackdrop(s):void 0,u=this._attachWindowComponent(s,a.nodes),d=new Nc(u,a,l,r.beforeDismiss);return this._registerModalRef(d),this._registerWindowCmpt(u),d.hidden.pipe(ge(1)).subscribe(()=>Promise.resolve(!0).then(()=>{this._modalRefs.length||(this._document.body.classList.remove("modal-open"),this._restoreScrollBar(),this._revertAriaHidden())})),o.close=p=>{d.close(p)},o.dismiss=p=>{d.dismiss(p)},o.update=p=>{d.update(p)},d.update(r),this._modalRefs.length===1&&this._document.body.classList.add("modal-open"),l&&l.instance&&l.changeDetectorRef.detectChanges(),u.changeDetectorRef.detectChanges(),d}get activeInstances(){return this._activeInstances}dismissAll(e){this._modalRefs.forEach(i=>i.dismiss(e))}hasOpenModals(){return this._modalRefs.length>0}_attachBackdrop(e){let i=fn(K0,{environmentInjector:this._applicationRef.injector,elementInjector:this._injector});return this._applicationRef.attachView(i.hostView),e.appendChild(i.location.nativeElement),i}_attachWindowComponent(e,i){let r=fn(Z0,{environmentInjector:this._applicationRef.injector,elementInjector:this._injector,projectableNodes:i});return this._applicationRef.attachView(r.hostView),e.appendChild(r.location.nativeElement),r}_getContentRef(e,i,r,s,o){return r?r instanceof qr?this._createFromTemplateRef(r,s):Zs(r)?this._createFromString(r):this._createFromComponent(e,i,r,s,o):new ft([])}_createFromTemplateRef(e,i){let r={$implicit:i,close(o){i.close(o)},dismiss(o){i.dismiss(o)}},s=e.createEmbeddedView(r);return this._applicationRef.attachView(s),new ft([s.rootNodes],s)}_createFromString(e){let i=this._document.createTextNode(`${e}`);return new ft([[i]])}_createFromComponent(e,i,r,s,o){let c=J.create({providers:[{provide:Ks,useValue:s}],parent:e}),a=fn(r,{environmentInjector:i,elementInjector:c}),l=a.location.nativeElement;return o.scrollable&&l.classList.add("component-host-scrollable"),this._applicationRef.attachView(a.hostView),new ft([[l]],a.hostView,a)}_setAriaHidden(e){let i=e.parentElement;i&&e!==this._document.body&&(Array.from(i.children).forEach(r=>{r!==e&&r.nodeName!=="SCRIPT"&&(this._ariaHiddenValues.set(r,r.getAttribute("aria-hidden")),r.setAttribute("aria-hidden","true"))}),this._setAriaHidden(i))}_revertAriaHidden(){this._ariaHiddenValues.forEach((e,i)=>{e?i.setAttribute("aria-hidden",e):i.removeAttribute("aria-hidden")}),this._ariaHiddenValues.clear()}_registerModalRef(e){let i=()=>{let r=this._modalRefs.indexOf(e);r>-1&&(this._modalRefs.splice(r,1),this._activeInstances.emit(this._modalRefs))};this._modalRefs.push(e),this._activeInstances.emit(this._modalRefs),e.result.then(i,i)}_registerWindowCmpt(e){this._windowCmpts.push(e),this._activeWindowCmptHasChanged.next(),e.onDestroy(()=>{let i=this._windowCmpts.indexOf(e);i>-1&&(this._windowCmpts.splice(i,1),this._activeWindowCmptHasChanged.next())})}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),XA=(()=>{class n{constructor(){this._injector=h(J),this._modalStack=h(X0),this._config=h(J0)}open(e,i={}){let r=m(k(m({},this._config),{animation:this._config.animation}),i);return this._modalStack.open(this._injector,e,r)}get activeInstances(){return this._modalStack.activeInstances}dismissAll(e){this._modalStack.dismissAll(e)}hasOpenModals(){return this._modalStack.hasOpenModals()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();var eO=(()=>{class n{static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275mod=Ie({type:n})}static{this.\u0275inj=Se({})}}return n})();var tO=(()=>{class n{constructor(){this.highlightClass="ngb-highlight",this.accentSensitive=!0}ngOnChanges(e){!this.accentSensitive&&!String.prototype.normalize&&(console.warn("The `accentSensitive` input in `ngb-highlight` cannot be set to `false` in a browser that does not implement the `String.normalize` function. You will have to include a polyfill in your application to use this feature in the current browser."),this.accentSensitive=!0);let i=pf(this.result),r=Array.isArray(this.term)?this.term:[this.term],s=l=>this.accentSensitive?l:gf(l),o=r.map(l=>v0(s(pf(l)))).filter(l=>l),c=this.accentSensitive?i:gf(i),a=o.length?c.split(new RegExp(`(${o.join("|")})`,"gmi")):[i];if(this.accentSensitive)this.parts=a;else{let l=0;this.parts=a.map(u=>i.substring(l,l+=u.length))}}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=We({type:n,selectors:[["ngb-highlight"]],inputs:{highlightClass:"highlightClass",result:"result",term:"term",accentSensitive:"accentSensitive"},standalone:!0,features:[at,Ke],decls:2,vars:0,consts:[[3,"class"]],template:function(i,r){i&1&&zu(0,g0,2,1,null,null,Gu),i&2&&Wu(r.parts)},styles:[`.ngb-highlight{font-weight:700}
4
- `],encapsulation:2,changeDetection:0})}}return n})(),nO=new O("live announcer delay",{providedIn:"root",factory:()=>100});var ey=(()=>{class n{constructor(){this._ngbConfig=h(Qs),this.backdrop=!0,this.keyboard=!0,this.position="start",this.scroll=!1}get animation(){return this._animation??this._ngbConfig.animation}set animation(e){this._animation=e}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),Ys=class{close(t){}dismiss(t){}},xc=class{get componentInstance(){if(this._contentRef&&this._contentRef.componentRef)return this._contentRef.componentRef.instance}get closed(){return this._closed.asObservable().pipe(W(this._hidden))}get dismissed(){return this._dismissed.asObservable().pipe(W(this._hidden))}get hidden(){return this._hidden.asObservable()}get shown(){return this._panelCmptRef.instance.shown.asObservable()}constructor(t,e,i,r){this._panelCmptRef=t,this._contentRef=e,this._backdropCmptRef=i,this._beforeDismiss=r,this._closed=new N,this._dismissed=new N,this._hidden=new N,t.instance.dismissEvent.subscribe(s=>{this.dismiss(s)}),i&&i.instance.dismissEvent.subscribe(s=>{this.dismiss(s)}),this.result=new Promise((s,o)=>{this._resolve=s,this._reject=o}),this.result.then(null,()=>{})}close(t){this._panelCmptRef&&(this._closed.next(t),this._resolve(t),this._removeOffcanvasElements())}_dismiss(t){this._dismissed.next(t),this._reject(t),this._removeOffcanvasElements()}dismiss(t){if(this._panelCmptRef)if(!this._beforeDismiss)this._dismiss(t);else{let e=this._beforeDismiss();Df(e)?e.then(i=>{i!==!1&&this._dismiss(t)},()=>{}):e!==!1&&this._dismiss(t)}}_removeOffcanvasElements(){let t=this._panelCmptRef.instance.hide(),e=this._backdropCmptRef?this._backdropCmptRef.instance.hide():b(void 0);t.subscribe(()=>{let{nativeElement:i}=this._panelCmptRef.location;i.parentNode.removeChild(i),this._panelCmptRef.destroy(),this._contentRef&&this._contentRef.viewRef&&this._contentRef.viewRef.destroy(),this._panelCmptRef=null,this._contentRef=null}),e.subscribe(()=>{if(this._backdropCmptRef){let{nativeElement:i}=this._backdropCmptRef.location;i.parentNode.removeChild(i),this._backdropCmptRef.destroy(),this._backdropCmptRef=null}}),Ci(t,e).subscribe(()=>{this._hidden.next(),this._hidden.complete()})}},Bc=function(n){return n[n.BACKDROP_CLICK=0]="BACKDROP_CLICK",n[n.ESC=1]="ESC",n}(Bc||{}),ty=(()=>{class n{constructor(){this._nativeElement=h(ie).nativeElement,this._zone=h($),this.dismissEvent=new B}ngOnInit(){this._zone.onStable.asObservable().pipe(ge(1)).subscribe(()=>{He(this._zone,this._nativeElement,(e,i)=>{i&&Tr(e),e.classList.add("show")},{animation:this.animation,runningTransition:"continue"})})}hide(){return He(this._zone,this._nativeElement,({classList:e})=>e.remove("show"),{animation:this.animation,runningTransition:"stop"})}dismiss(){this.static||this.dismissEvent.emit(Bc.BACKDROP_CLICK)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=We({type:n,selectors:[["ngb-offcanvas-backdrop"]],hostVars:6,hostBindings:function(i,r){i&1&&ue("mousedown",function(){return r.dismiss()}),i&2&&(_e("offcanvas-backdrop"+(r.backdropClass?" "+r.backdropClass:"")),Z("show",!r.animation)("fade",r.animation))},inputs:{animation:"animation",backdropClass:"backdropClass",static:"static"},outputs:{dismissEvent:"dismiss"},standalone:!0,features:[Ke],decls:0,vars:0,template:function(i,r){},encapsulation:2})}}return n})(),ny=(()=>{class n{constructor(){this._document=h(G),this._elRef=h(ie),this._zone=h($),this._closed$=new N,this._elWithFocus=null,this.keyboard=!0,this.position="start",this.dismissEvent=new B,this.shown=new N,this.hidden=new N}dismiss(e){this.dismissEvent.emit(e)}ngOnInit(){this._elWithFocus=this._document.activeElement,this._zone.onStable.asObservable().pipe(ge(1)).subscribe(()=>{this._show()})}ngOnDestroy(){this._disableEventHandling()}hide(){let e={animation:this.animation,runningTransition:"stop"},i=He(this._zone,this._elRef.nativeElement,r=>(r.classList.remove("showing"),r.classList.add("hiding"),()=>r.classList.remove("show","hiding")),e);return i.subscribe(()=>{this.hidden.next(),this.hidden.complete()}),this._disableEventHandling(),this._restoreFocus(),i}_show(){let e={animation:this.animation,runningTransition:"continue"};He(this._zone,this._elRef.nativeElement,(r,s)=>(s&&Tr(r),r.classList.add("show","showing"),()=>r.classList.remove("showing")),e).subscribe(()=>{this.shown.next(),this.shown.complete()}),this._enableEventHandling(),this._setFocus()}_enableEventHandling(){let{nativeElement:e}=this._elRef;this._zone.runOutsideAngular(()=>{we(e,"keydown").pipe(W(this._closed$),ce(i=>i.which===$e.Escape)).subscribe(i=>{this.keyboard&&requestAnimationFrame(()=>{i.defaultPrevented||this._zone.run(()=>this.dismiss(Bc.ESC))})})})}_disableEventHandling(){this._closed$.next()}_setFocus(){let{nativeElement:e}=this._elRef;if(!e.contains(document.activeElement)){let i=e.querySelector("[ngbAutofocus]"),r=Fc(e)[0];(i||r||e).focus()}}_restoreFocus(){let e=this._document.body,i=this._elWithFocus,r;i&&i.focus&&e.contains(i)?r=i:r=e,this._zone.runOutsideAngular(()=>{setTimeout(()=>r.focus()),this._elWithFocus=null})}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275cmp=We({type:n,selectors:[["ngb-offcanvas-panel"]],hostAttrs:["role","dialog","tabindex","-1"],hostVars:5,hostBindings:function(i,r){i&2&&(Te("aria-modal",!0)("aria-labelledby",r.ariaLabelledBy)("aria-describedby",r.ariaDescribedBy),_e("offcanvas offcanvas-"+r.position+(r.panelClass?" "+r.panelClass:"")))},inputs:{animation:"animation",ariaLabelledBy:"ariaLabelledBy",ariaDescribedBy:"ariaDescribedBy",keyboard:"keyboard",panelClass:"panelClass",position:"position"},outputs:{dismissEvent:"dismiss"},standalone:!0,features:[Ke],ngContentSelectors:bf,decls:1,vars:0,template:function(i,r){i&1&&(Zo(),Xo(0))},encapsulation:2})}}return n})(),iy=(()=>{class n{constructor(){this._applicationRef=h(Ye),this._injector=h(J),this._document=h(G),this._scrollBar=h(Of),this._activePanelCmptHasChanged=new N,this._scrollBarRestoreFn=null,this._backdropAttributes=["animation","backdropClass"],this._panelAttributes=["animation","ariaDescribedBy","ariaLabelledBy","keyboard","panelClass","position"],this._activeInstance=new B;let e=h($);this._activePanelCmptHasChanged.subscribe(()=>{this._panelCmpt&&Sf(e,this._panelCmpt.location.nativeElement,this._activePanelCmptHasChanged)})}_restoreScrollBar(){let e=this._scrollBarRestoreFn;e&&(this._scrollBarRestoreFn=null,e())}_hideScrollBar(){this._scrollBarRestoreFn||(this._scrollBarRestoreFn=this._scrollBar.hide())}open(e,i,r){let s=r.container instanceof HTMLElement?r.container:li(r.container)?this._document.querySelector(r.container):this._document.body;if(!s)throw new Error(`The specified offcanvas container "${r.container||"body"}" was not found in the DOM.`);r.scroll||this._hideScrollBar();let o=new Ys,c=this._getContentRef(r.injector||e,i,o),a=r.backdrop!==!1?this._attachBackdrop(s):void 0,l=this._attachWindowComponent(s,c.nodes),u=new xc(l,c,a,r.beforeDismiss);return this._registerOffcanvasRef(u),this._registerPanelCmpt(l),u.hidden.pipe(yt(()=>this._restoreScrollBar())).subscribe(),o.close=d=>{u.close(d)},o.dismiss=d=>{u.dismiss(d)},this._applyPanelOptions(l.instance,r),a&&a.instance&&(this._applyBackdropOptions(a.instance,r),a.changeDetectorRef.detectChanges()),l.changeDetectorRef.detectChanges(),u}get activeInstance(){return this._activeInstance}dismiss(e){this._offcanvasRef?.dismiss(e)}hasOpenOffcanvas(){return!!this._offcanvasRef}_attachBackdrop(e){let i=fn(ty,{environmentInjector:this._applicationRef.injector,elementInjector:this._injector});return this._applicationRef.attachView(i.hostView),e.appendChild(i.location.nativeElement),i}_attachWindowComponent(e,i){let r=fn(ny,{environmentInjector:this._applicationRef.injector,elementInjector:this._injector,projectableNodes:i});return this._applicationRef.attachView(r.hostView),e.appendChild(r.location.nativeElement),r}_applyPanelOptions(e,i){this._panelAttributes.forEach(r=>{li(i[r])&&(e[r]=i[r])})}_applyBackdropOptions(e,i){this._backdropAttributes.forEach(r=>{li(i[r])&&(e[r]=i[r])}),e.static=i.backdrop==="static"}_getContentRef(e,i,r){return i?i instanceof qr?this._createFromTemplateRef(i,r):Zs(i)?this._createFromString(i):this._createFromComponent(e,i,r):new ft([])}_createFromTemplateRef(e,i){let r={$implicit:i,close(o){i.close(o)},dismiss(o){i.dismiss(o)}},s=e.createEmbeddedView(r);return this._applicationRef.attachView(s),new ft([s.rootNodes],s)}_createFromString(e){let i=this._document.createTextNode(`${e}`);return new ft([[i]])}_createFromComponent(e,i,r){let s=J.create({providers:[{provide:Ys,useValue:r}],parent:e}),o=fn(i,{environmentInjector:this._applicationRef.injector,elementInjector:s}),c=o.location.nativeElement;return this._applicationRef.attachView(o.hostView),new ft([[c]],o.hostView,o)}_registerOffcanvasRef(e){let i=()=>{this._offcanvasRef=void 0,this._activeInstance.emit(this._offcanvasRef)};this._offcanvasRef=e,this._activeInstance.emit(this._offcanvasRef),e.result.then(i,i)}_registerPanelCmpt(e){this._panelCmpt=e,this._activePanelCmptHasChanged.next(),e.onDestroy(()=>{this._panelCmpt=void 0,this._activePanelCmptHasChanged.next()})}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})(),iO=(()=>{class n{constructor(){this._injector=h(J),this._offcanvasStack=h(iy),this._config=h(ey)}open(e,i={}){let r=m(k(m({},this._config),{animation:this._config.animation}),i);return this._offcanvasStack.open(this._injector,e,r)}get activeInstance(){return this._offcanvasStack.activeInstance}dismiss(e){this._offcanvasStack.dismiss(e)}hasOpenOffcanvas(){return this._offcanvasStack.hasOpenOffcanvas()}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();var Rf=["toast-component",""];function ry(n,t){if(n&1){let e=Kr();Ae(0,"button",5),ue("click",function(){zr(e);let r=de();return Wr(r.remove())}),Ae(1,"span",6),Le(2,"\xD7"),Fe()()}}function sy(n,t){if(n&1&&(Ri(0),Le(1),Mi()),n&2){let e=de(2);K(),Ht("[",e.duplicatesCount+1,"]")}}function oy(n,t){if(n&1&&(Ae(0,"div"),Le(1),dn(2,sy,2,1,"ng-container",4),Fe()),n&2){let e=de();_e(e.options.titleClass),Te("aria-label",e.title),K(),Ht(" ",e.title," "),K(),me("ngIf",e.duplicatesCount)}}function ay(n,t){if(n&1&&jt(0,"div",7),n&2){let e=de();_e(e.options.messageClass),me("innerHTML",e.message,Ko)}}function cy(n,t){if(n&1&&(Ae(0,"div",8),Le(1),Fe()),n&2){let e=de();_e(e.options.messageClass),Te("aria-label",e.message),K(),Ht(" ",e.message," ")}}function ly(n,t){if(n&1&&(Ae(0,"div"),jt(1,"div",9),Fe()),n&2){let e=de();K(),Un("width",e.width()+"%")}}function uy(n,t){if(n&1){let e=Kr();Ae(0,"button",5),ue("click",function(){zr(e);let r=de();return Wr(r.remove())}),Ae(1,"span",6),Le(2,"\xD7"),Fe()()}}function dy(n,t){if(n&1&&(Ri(0),Le(1),Mi()),n&2){let e=de(2);K(),Ht("[",e.duplicatesCount+1,"]")}}function hy(n,t){if(n&1&&(Ae(0,"div"),Le(1),dn(2,dy,2,1,"ng-container",4),Fe()),n&2){let e=de();_e(e.options.titleClass),Te("aria-label",e.title),K(),Ht(" ",e.title," "),K(),me("ngIf",e.duplicatesCount)}}function fy(n,t){if(n&1&&jt(0,"div",7),n&2){let e=de();_e(e.options.messageClass),me("innerHTML",e.message,Ko)}}function py(n,t){if(n&1&&(Ae(0,"div",8),Le(1),Fe()),n&2){let e=de();_e(e.options.messageClass),Te("aria-label",e.message),K(),Ht(" ",e.message," ")}}function gy(n,t){if(n&1&&(Ae(0,"div"),jt(1,"div",9),Fe()),n&2){let e=de();K(),Un("width",e.width()+"%")}}var Vc=class{_attachedHost;component;viewContainerRef;injector;constructor(t,e){this.component=t,this.injector=e}attach(t,e){return this._attachedHost=t,t.attach(this,e)}detach(){let t=this._attachedHost;if(t)return this._attachedHost=void 0,t.detach()}get isAttached(){return this._attachedHost!=null}setAttachedHost(t){this._attachedHost=t}},Uc=class{_attachedPortal;_disposeFn;attach(t,e){return this._attachedPortal=t,this.attachComponentPortal(t,e)}detach(){this._attachedPortal&&this._attachedPortal.setAttachedHost(),this._attachedPortal=void 0,this._disposeFn&&(this._disposeFn(),this._disposeFn=void 0)}setDisposeFn(t){this._disposeFn=t}},jc=class{_overlayRef;componentInstance;duplicatesCount=0;_afterClosed=new N;_activate=new N;_manualClose=new N;_resetTimeout=new N;_countDuplicate=new N;constructor(t){this._overlayRef=t}manualClose(){this._manualClose.next(),this._manualClose.complete()}manualClosed(){return this._manualClose.asObservable()}timeoutReset(){return this._resetTimeout.asObservable()}countDuplicate(){return this._countDuplicate.asObservable()}close(){this._overlayRef.detach(),this._afterClosed.next(),this._manualClose.next(),this._afterClosed.complete(),this._manualClose.complete(),this._activate.complete(),this._resetTimeout.complete(),this._countDuplicate.complete()}afterClosed(){return this._afterClosed.asObservable()}isInactive(){return this._activate.isStopped}activate(){this._activate.next(),this._activate.complete()}afterActivate(){return this._activate.asObservable()}onDuplicate(t,e){t&&this._resetTimeout.next(),e&&this._countDuplicate.next(++this.duplicatesCount)}},di=class{toastId;config;message;title;toastType;toastRef;_onTap=new N;_onAction=new N;constructor(t,e,i,r,s,o){this.toastId=t,this.config=e,this.message=i,this.title=r,this.toastType=s,this.toastRef=o,this.toastRef.afterClosed().subscribe(()=>{this._onAction.complete(),this._onTap.complete()})}triggerTap(){this._onTap.next(),this.config.tapToDismiss&&this._onTap.complete()}onTap(){return this._onTap.asObservable()}triggerAction(t){this._onAction.next(t)}onAction(){return this._onAction.asObservable()}},Mf={maxOpened:0,autoDismiss:!1,newestOnTop:!0,preventDuplicates:!1,countDuplicates:!1,resetTimeoutOnDuplicate:!1,includeTitleDuplicates:!1,iconClasses:{error:"toast-error",info:"toast-info",success:"toast-success",warning:"toast-warning"},closeButton:!1,disableTimeOut:!1,timeOut:5e3,extendedTimeOut:1e3,enableHtml:!1,progressBar:!1,toastClass:"ngx-toastr",positionClass:"toast-top-right",titleClass:"toast-title",messageClass:"toast-message",easing:"ease-in",easeTime:300,tapToDismiss:!0,onActivateTick:!1,progressAnimation:"decreasing"},Pf=new O("ToastConfig"),$c=class extends Uc{_hostDomElement;_componentFactoryResolver;_appRef;constructor(t,e,i){super(),this._hostDomElement=t,this._componentFactoryResolver=e,this._appRef=i}attachComponentPortal(t,e){let i=this._componentFactoryResolver.resolveComponentFactory(t.component),r;return r=i.create(t.injector),this._appRef.attachView(r.hostView),this.setDisposeFn(()=>{this._appRef.detachView(r.hostView),r.destroy()}),e?this._hostDomElement.insertBefore(this._getComponentRootNode(r),this._hostDomElement.firstChild):this._hostDomElement.appendChild(this._getComponentRootNode(r)),r}_getComponentRootNode(t){return t.hostView.rootNodes[0]}},my=(()=>{class n{_document=h(G);_containerElement;ngOnDestroy(){this._containerElement&&this._containerElement.parentNode&&this._containerElement.parentNode.removeChild(this._containerElement)}getContainerElement(){return this._containerElement||this._createContainer(),this._containerElement}_createContainer(){let e=this._document.createElement("div");e.classList.add("overlay-container"),e.setAttribute("aria-live","polite"),this._document.body.appendChild(e),this._containerElement=e}static \u0275fac=function(i){return new(i||n)};static \u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})(),Hc=class{_portalHost;constructor(t){this._portalHost=t}attach(t,e=!0){return this._portalHost.attach(t,e)}detach(){return this._portalHost.detach()}},_y=(()=>{class n{_overlayContainer=h(my);_componentFactoryResolver=h(Bu);_appRef=h(Ye);_document=h(G);_paneElements=new Map;create(e,i){return this._createOverlayRef(this.getPaneElement(e,i))}getPaneElement(e="",i){return this._paneElements.get(i)||this._paneElements.set(i,{}),this._paneElements.get(i)[e]||(this._paneElements.get(i)[e]=this._createPaneElement(e,i)),this._paneElements.get(i)[e]}_createPaneElement(e,i){let r=this._document.createElement("div");return r.id="toast-container",r.classList.add(e),r.classList.add("toast-container"),i?i.getContainerElement().appendChild(r):this._overlayContainer.getContainerElement().appendChild(r),r}_createPortalHost(e){return new $c(e,this._componentFactoryResolver,this._appRef)}_createOverlayRef(e){return new Hc(this._createPortalHost(e))}static \u0275fac=function(i){return new(i||n)};static \u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})(),Xs=(()=>{class n{overlay;_injector;sanitizer;ngZone;toastrConfig;currentlyActive=0;toasts=[];overlayContainer;previousToastMessage;index=0;constructor(e,i,r,s,o){this.overlay=i,this._injector=r,this.sanitizer=s,this.ngZone=o,this.toastrConfig=m(m({},e.default),e.config),e.config.iconClasses&&(this.toastrConfig.iconClasses=m(m({},e.default.iconClasses),e.config.iconClasses))}show(e,i,r={},s=""){return this._preBuildNotification(s,e,i,this.applyConfig(r))}success(e,i,r={}){let s=this.toastrConfig.iconClasses.success||"";return this._preBuildNotification(s,e,i,this.applyConfig(r))}error(e,i,r={}){let s=this.toastrConfig.iconClasses.error||"";return this._preBuildNotification(s,e,i,this.applyConfig(r))}info(e,i,r={}){let s=this.toastrConfig.iconClasses.info||"";return this._preBuildNotification(s,e,i,this.applyConfig(r))}warning(e,i,r={}){let s=this.toastrConfig.iconClasses.warning||"";return this._preBuildNotification(s,e,i,this.applyConfig(r))}clear(e){for(let i of this.toasts)if(e!==void 0){if(i.toastId===e){i.toastRef.manualClose();return}}else i.toastRef.manualClose()}remove(e){let i=this._findToast(e);if(!i||(i.activeToast.toastRef.close(),this.toasts.splice(i.index,1),this.currentlyActive=this.currentlyActive-1,!this.toastrConfig.maxOpened||!this.toasts.length))return!1;if(this.currentlyActive<this.toastrConfig.maxOpened&&this.toasts[this.currentlyActive]){let r=this.toasts[this.currentlyActive].toastRef;r.isInactive()||(this.currentlyActive=this.currentlyActive+1,r.activate())}return!0}findDuplicate(e="",i="",r,s){let{includeTitleDuplicates:o}=this.toastrConfig;for(let c of this.toasts){let a=o&&c.title===e;if((!o||a)&&c.message===i)return c.toastRef.onDuplicate(r,s),c}return null}applyConfig(e={}){return m(m({},this.toastrConfig),e)}_findToast(e){for(let i=0;i<this.toasts.length;i++)if(this.toasts[i].toastId===e)return{index:i,activeToast:this.toasts[i]};return null}_preBuildNotification(e,i,r,s){return s.onActivateTick?this.ngZone.run(()=>this._buildNotification(e,i,r,s)):this._buildNotification(e,i,r,s)}_buildNotification(e,i,r,s){if(!s.toastComponent)throw new Error("toastComponent required");let o=this.findDuplicate(r,i,this.toastrConfig.resetTimeoutOnDuplicate&&s.timeOut>0,this.toastrConfig.countDuplicates);if((this.toastrConfig.includeTitleDuplicates&&r||i)&&this.toastrConfig.preventDuplicates&&o!==null)return o;this.previousToastMessage=i;let c=!1;this.toastrConfig.maxOpened&&this.currentlyActive>=this.toastrConfig.maxOpened&&(c=!0,this.toastrConfig.autoDismiss&&this.clear(this.toasts[0].toastId));let a=this.overlay.create(s.positionClass,this.overlayContainer);this.index=this.index+1;let l=i;i&&s.enableHtml&&(l=this.sanitizer.sanitize(wt.HTML,i));let u=new jc(a),d=new di(this.index,s,l,r,e,u),p=[{provide:di,useValue:d}],g=J.create({providers:p,parent:this._injector}),w=new Vc(s.toastComponent,g),v=a.attach(w,s.newestOnTop);u.componentInstance=v.instance;let _={toastId:this.index,title:r||"",message:i||"",toastRef:u,onShown:u.afterActivate(),onHidden:u.afterClosed(),onTap:d.onTap(),onAction:d.onAction(),portal:v};return c||(this.currentlyActive=this.currentlyActive+1,setTimeout(()=>{_.toastRef.activate()})),this.toasts.push(_),_}static \u0275fac=function(i){return new(i||n)(C(Pf),C(_y),C(J),C(ya),C($))};static \u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})(),vy=(()=>{class n{toastrService;toastPackage;ngZone;message;title;options;duplicatesCount;originalTimeout;width=Je(-1);toastClasses="";state;get _state(){return this.state()}get displayStyle(){if(this.state().value==="inactive")return"none"}timeout;intervalId;hideTime;sub;sub1;sub2;sub3;constructor(e,i,r){this.toastrService=e,this.toastPackage=i,this.ngZone=r,this.message=i.message,this.title=i.title,this.options=i.config,this.originalTimeout=i.config.timeOut,this.toastClasses=`${i.toastType} ${i.config.toastClass}`,this.sub=i.toastRef.afterActivate().subscribe(()=>{this.activateToast()}),this.sub1=i.toastRef.manualClosed().subscribe(()=>{this.remove()}),this.sub2=i.toastRef.timeoutReset().subscribe(()=>{this.resetTimeout()}),this.sub3=i.toastRef.countDuplicate().subscribe(s=>{this.duplicatesCount=s}),this.state=Je({value:"inactive",params:{easeTime:this.toastPackage.config.easeTime,easing:"ease-in"}})}ngOnDestroy(){this.sub.unsubscribe(),this.sub1.unsubscribe(),this.sub2.unsubscribe(),this.sub3.unsubscribe(),clearInterval(this.intervalId),clearTimeout(this.timeout)}activateToast(){this.state.update(e=>k(m({},e),{value:"active"})),!(this.options.disableTimeOut===!0||this.options.disableTimeOut==="timeOut")&&this.options.timeOut&&(this.outsideTimeout(()=>this.remove(),this.options.timeOut),this.hideTime=new Date().getTime()+this.options.timeOut,this.options.progressBar&&this.outsideInterval(()=>this.updateProgress(),10))}updateProgress(){if(this.width()===0||this.width()===100||!this.options.timeOut)return;let e=new Date().getTime(),i=this.hideTime-e;this.width.set(i/this.options.timeOut*100),this.options.progressAnimation==="increasing"&&this.width.update(r=>100-r),this.width()<=0&&this.width.set(0),this.width()>=100&&this.width.set(100)}resetTimeout(){clearTimeout(this.timeout),clearInterval(this.intervalId),this.state.update(e=>k(m({},e),{value:"active"})),this.outsideTimeout(()=>this.remove(),this.originalTimeout),this.options.timeOut=this.originalTimeout,this.hideTime=new Date().getTime()+(this.options.timeOut||0),this.width.set(-1),this.options.progressBar&&this.outsideInterval(()=>this.updateProgress(),10)}remove(){this.state().value!=="removed"&&(clearTimeout(this.timeout),this.state.update(e=>k(m({},e),{value:"removed"})),this.outsideTimeout(()=>this.toastrService.remove(this.toastPackage.toastId),+this.toastPackage.config.easeTime))}tapToast(){this.state().value!=="removed"&&(this.toastPackage.triggerTap(),this.options.tapToDismiss&&this.remove())}stickAround(){this.state().value!=="removed"&&this.options.disableTimeOut!=="extendedTimeOut"&&(clearTimeout(this.timeout),this.options.timeOut=0,this.hideTime=0,clearInterval(this.intervalId),this.width.set(0))}delayedHideToast(){this.options.disableTimeOut===!0||this.options.disableTimeOut==="extendedTimeOut"||this.options.extendedTimeOut===0||this.state().value==="removed"||(this.outsideTimeout(()=>this.remove(),this.options.extendedTimeOut),this.options.timeOut=this.options.extendedTimeOut,this.hideTime=new Date().getTime()+(this.options.timeOut||0),this.width.set(-1),this.options.progressBar&&this.outsideInterval(()=>this.updateProgress(),10))}outsideTimeout(e,i){this.ngZone?this.ngZone.runOutsideAngular(()=>this.timeout=setTimeout(()=>this.runInsideAngular(e),i)):this.timeout=setTimeout(()=>e(),i)}outsideInterval(e,i){this.ngZone?this.ngZone.runOutsideAngular(()=>this.intervalId=setInterval(()=>this.runInsideAngular(e),i)):this.intervalId=setInterval(()=>e(),i)}runInsideAngular(e){this.ngZone?this.ngZone.run(()=>e()):e()}static \u0275fac=function(i){return new(i||n)(R(Xs),R(di),R($))};static \u0275cmp=We({type:n,selectors:[["","toast-component",""]],hostVars:5,hostBindings:function(i,r){i&1&&ue("click",function(){return r.tapToast()})("mouseenter",function(){return r.stickAround()})("mouseleave",function(){return r.delayedHideToast()}),i&2&&(qu("@flyInOut",r._state),_e(r.toastClasses),Un("display",r.displayStyle))},standalone:!0,features:[Ke],attrs:Rf,decls:5,vars:5,consts:[["type","button","class","toast-close-button","aria-label","Close",3,"click",4,"ngIf"],[3,"class",4,"ngIf"],["role","alert",3,"class","innerHTML",4,"ngIf"],["role","alert",3,"class",4,"ngIf"],[4,"ngIf"],["type","button","aria-label","Close",1,"toast-close-button",3,"click"],["aria-hidden","true"],["role","alert",3,"innerHTML"],["role","alert"],[1,"toast-progress"]],template:function(i,r){i&1&&dn(0,ry,3,0,"button",0)(1,oy,3,5,"div",1)(2,ay,1,3,"div",2)(3,cy,2,4,"div",3)(4,ly,2,2,"div",4),i&2&&(me("ngIf",r.options.closeButton),K(),me("ngIf",r.title),K(),me("ngIf",r.message&&r.options.enableHtml),K(),me("ngIf",r.message&&!r.options.enableHtml),K(),me("ngIf",r.options.progressBar))},dependencies:[na],encapsulation:2,data:{animation:[od("flyInOut",[rs("inactive",is({opacity:0})),rs("active",is({opacity:1})),rs("removed",is({opacity:0})),ra("inactive => active",ia("{{ easeTime }}ms {{ easing }}")),ra("active => removed",ia("{{ easeTime }}ms {{ easing }}"))])]},changeDetection:0})}return n})(),yy=k(m({},Mf),{toastComponent:vy}),vO=(n={})=>qe([{provide:Pf,useValue:{default:yy,config:n}}]);var by=(()=>{class n{toastrService;toastPackage;appRef;message;title;options;duplicatesCount;originalTimeout;width=Je(-1);toastClasses="";get displayStyle(){return this.state()==="inactive"?"none":null}state=Je("inactive");timeout;intervalId;hideTime;sub;sub1;sub2;sub3;constructor(e,i,r){this.toastrService=e,this.toastPackage=i,this.appRef=r,this.message=i.message,this.title=i.title,this.options=i.config,this.originalTimeout=i.config.timeOut,this.toastClasses=`${i.toastType} ${i.config.toastClass}`,this.sub=i.toastRef.afterActivate().subscribe(()=>{this.activateToast()}),this.sub1=i.toastRef.manualClosed().subscribe(()=>{this.remove()}),this.sub2=i.toastRef.timeoutReset().subscribe(()=>{this.resetTimeout()}),this.sub3=i.toastRef.countDuplicate().subscribe(s=>{this.duplicatesCount=s})}ngOnDestroy(){this.sub.unsubscribe(),this.sub1.unsubscribe(),this.sub2.unsubscribe(),this.sub3.unsubscribe(),clearInterval(this.intervalId),clearTimeout(this.timeout)}activateToast(){this.state.set("active"),!(this.options.disableTimeOut===!0||this.options.disableTimeOut==="timeOut")&&this.options.timeOut&&(this.timeout=setTimeout(()=>{this.remove()},this.options.timeOut),this.hideTime=new Date().getTime()+this.options.timeOut,this.options.progressBar&&(this.intervalId=setInterval(()=>this.updateProgress(),10))),this.options.onActivateTick&&this.appRef.tick()}updateProgress(){if(this.width()===0||this.width()===100||!this.options.timeOut)return;let e=new Date().getTime(),i=this.hideTime-e;this.width.set(i/this.options.timeOut*100),this.options.progressAnimation==="increasing"&&this.width.update(r=>100-r),this.width()<=0&&this.width.set(0),this.width()>=100&&this.width.set(100)}resetTimeout(){clearTimeout(this.timeout),clearInterval(this.intervalId),this.state.set("active"),this.options.timeOut=this.originalTimeout,this.timeout=setTimeout(()=>this.remove(),this.originalTimeout),this.hideTime=new Date().getTime()+(this.originalTimeout||0),this.width.set(-1),this.options.progressBar&&(this.intervalId=setInterval(()=>this.updateProgress(),10))}remove(){this.state()!=="removed"&&(clearTimeout(this.timeout),this.state.set("removed"),this.timeout=setTimeout(()=>this.toastrService.remove(this.toastPackage.toastId)))}tapToast(){this.state()!=="removed"&&(this.toastPackage.triggerTap(),this.options.tapToDismiss&&this.remove())}stickAround(){this.state()!=="removed"&&(clearTimeout(this.timeout),this.options.timeOut=0,this.hideTime=0,clearInterval(this.intervalId),this.width.set(0))}delayedHideToast(){this.options.disableTimeOut===!0||this.options.disableTimeOut==="extendedTimeOut"||this.options.extendedTimeOut===0||this.state()==="removed"||(this.timeout=setTimeout(()=>this.remove(),this.options.extendedTimeOut),this.options.timeOut=this.options.extendedTimeOut,this.hideTime=new Date().getTime()+(this.options.timeOut||0),this.width.set(-1),this.options.progressBar&&(this.intervalId=setInterval(()=>this.updateProgress(),10)))}static \u0275fac=function(i){return new(i||n)(R(Xs),R(di),R(Ye))};static \u0275cmp=We({type:n,selectors:[["","toast-component",""]],hostVars:4,hostBindings:function(i,r){i&1&&ue("click",function(){return r.tapToast()})("mouseenter",function(){return r.stickAround()})("mouseleave",function(){return r.delayedHideToast()}),i&2&&(_e(r.toastClasses),Un("display",r.displayStyle))},standalone:!0,features:[Ke],attrs:Rf,decls:5,vars:5,consts:[["type","button","class","toast-close-button","aria-label","Close",3,"click",4,"ngIf"],[3,"class",4,"ngIf"],["role","alert",3,"class","innerHTML",4,"ngIf"],["role","alert",3,"class",4,"ngIf"],[4,"ngIf"],["type","button","aria-label","Close",1,"toast-close-button",3,"click"],["aria-hidden","true"],["role","alert",3,"innerHTML"],["role","alert"],[1,"toast-progress"]],template:function(i,r){i&1&&dn(0,uy,3,0,"button",0)(1,hy,3,5,"div",1)(2,fy,1,3,"div",2)(3,py,2,4,"div",3)(4,gy,2,2,"div",4),i&2&&(me("ngIf",r.options.closeButton),K(),me("ngIf",r.title),K(),me("ngIf",r.message&&r.options.enableHtml),K(),me("ngIf",r.message&&!r.options.enableHtml),K(),me("ngIf",r.options.progressBar))},dependencies:[na],encapsulation:2,changeDetection:0})}return n})(),yO=k(m({},Mf),{toastComponent:by});var Nf=(()=>{class n{constructor(){this.http=h(ua),this.toastr=h(Xs),this.requestTimeout=1e4}get(e,i={},r="/"){return this.http.get(`${r}${e}`,m({},i)).pipe(Fn(this.requestTimeout),De(this.handleError.bind(this)))}post(e,i,r={},s="/"){return this.http.post(`${s}${e}`,i,m({},r)).pipe(Fn(this.requestTimeout),De(this.handleError.bind(this)))}postFormData(e,i,r={},s="/"){return this.http.post(`${s}/${e}`,i,m({},r)).pipe(Fn(this.requestTimeout),De(this.handleError.bind(this)))}put(e,i,r={},s="/"){return this.http.put(`${s}/${e}`,i,m({},r)).pipe(Fn(this.requestTimeout),De(this.handleError.bind(this)))}delete(e,i={},r="/"){return this.http.delete(`${r}/${e}`,m({},i)).pipe(Fn(this.requestTimeout),De(this.handleError.bind(this)))}handleError(e){let i={header:"API Error ",message:"An unknown error occurred."};return e instanceof pu&&e.name=="TimeoutError"&&(i.header="Request Timeout",i.message="The request took too long to complete. Please try again later."),e instanceof lt&&(Object.keys(e.error).length?(i.header="API Error - "+e.status,i.message=e.error.Message||e.error.message):(e.status===401&&(i.header="Unauthorized",i.message="We can't log you in because of authentication error"),i.header="API Error - "+e.status,i.message=e.error.message)),this.toastr.error(i.message,i.header),un(()=>i)}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();var xf=function(n){let t=[],e=0;for(let i=0;i<n.length;i++){let r=n.charCodeAt(i);r<128?t[e++]=r:r<2048?(t[e++]=r>>6|192,t[e++]=r&63|128):(r&64512)===55296&&i+1<n.length&&(n.charCodeAt(i+1)&64512)===56320?(r=65536+((r&1023)<<10)+(n.charCodeAt(++i)&1023),t[e++]=r>>18|240,t[e++]=r>>12&63|128,t[e++]=r>>6&63|128,t[e++]=r&63|128):(t[e++]=r>>12|224,t[e++]=r>>6&63|128,t[e++]=r&63|128)}return t},wy=function(n){let t=[],e=0,i=0;for(;e<n.length;){let r=n[e++];if(r<128)t[i++]=String.fromCharCode(r);else if(r>191&&r<224){let s=n[e++];t[i++]=String.fromCharCode((r&31)<<6|s&63)}else if(r>239&&r<365){let s=n[e++],o=n[e++],c=n[e++],a=((r&7)<<18|(s&63)<<12|(o&63)<<6|c&63)-65536;t[i++]=String.fromCharCode(55296+(a>>10)),t[i++]=String.fromCharCode(56320+(a&1023))}else{let s=n[e++],o=n[e++];t[i++]=String.fromCharCode((r&15)<<12|(s&63)<<6|o&63)}}return t.join("")},Ff={byteToCharMap_:null,charToByteMap_:null,byteToCharMapWebSafe_:null,charToByteMapWebSafe_:null,ENCODED_VALS_BASE:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",get ENCODED_VALS(){return this.ENCODED_VALS_BASE+"+/="},get ENCODED_VALS_WEBSAFE(){return this.ENCODED_VALS_BASE+"-_."},HAS_NATIVE_SUPPORT:typeof atob=="function",encodeByteArray(n,t){if(!Array.isArray(n))throw Error("encodeByteArray takes an array as a parameter");this.init_();let e=t?this.byteToCharMapWebSafe_:this.byteToCharMap_,i=[];for(let r=0;r<n.length;r+=3){let s=n[r],o=r+1<n.length,c=o?n[r+1]:0,a=r+2<n.length,l=a?n[r+2]:0,u=s>>2,d=(s&3)<<4|c>>4,p=(c&15)<<2|l>>6,g=l&63;a||(g=64,o||(p=64)),i.push(e[u],e[d],e[p],e[g])}return i.join("")},encodeString(n,t){return this.HAS_NATIVE_SUPPORT&&!t?btoa(n):this.encodeByteArray(xf(n),t)},decodeString(n,t){return this.HAS_NATIVE_SUPPORT&&!t?atob(n):wy(this.decodeStringToByteArray(n,t))},decodeStringToByteArray(n,t){this.init_();let e=t?this.charToByteMapWebSafe_:this.charToByteMap_,i=[];for(let r=0;r<n.length;){let s=e[n.charAt(r++)],c=r<n.length?e[n.charAt(r)]:0;++r;let l=r<n.length?e[n.charAt(r)]:64;++r;let d=r<n.length?e[n.charAt(r)]:64;if(++r,s==null||c==null||l==null||d==null)throw new zc;let p=s<<2|c>>4;if(i.push(p),l!==64){let g=c<<4&240|l>>2;if(i.push(g),d!==64){let w=l<<6&192|d;i.push(w)}}}return i},init_(){if(!this.byteToCharMap_){this.byteToCharMap_={},this.charToByteMap_={},this.byteToCharMapWebSafe_={},this.charToByteMapWebSafe_={};for(let n=0;n<this.ENCODED_VALS.length;n++)this.byteToCharMap_[n]=this.ENCODED_VALS.charAt(n),this.charToByteMap_[this.byteToCharMap_[n]]=n,this.byteToCharMapWebSafe_[n]=this.ENCODED_VALS_WEBSAFE.charAt(n),this.charToByteMapWebSafe_[this.byteToCharMapWebSafe_[n]]=n,n>=this.ENCODED_VALS_BASE.length&&(this.charToByteMap_[this.ENCODED_VALS_WEBSAFE.charAt(n)]=n,this.charToByteMapWebSafe_[this.ENCODED_VALS.charAt(n)]=n)}}},zc=class extends Error{constructor(){super(...arguments),this.name="DecodeBase64StringError"}},Dy=function(n){let t=xf(n);return Ff.encodeByteArray(t,!0)},qc=function(n){return Dy(n).replace(/\./g,"")},Jc=function(n){try{return Ff.decodeString(n,!0)}catch(t){console.error("base64Decode failed: ",t)}return null};function Ty(){if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("Unable to locate global object.")}var Ey=()=>Ty().__FIREBASE_DEFAULTS__,Cy=()=>{if(typeof process>"u"||typeof process.env>"u")return;let n=process.env.__FIREBASE_DEFAULTS__;if(n)return JSON.parse(n)},Sy=()=>{if(typeof document>"u")return;let n;try{n=document.cookie.match(/__FIREBASE_DEFAULTS__=([^;]+)/)}catch{return}let t=n&&Jc(n[1]);return t&&JSON.parse(t)},Kc=()=>{try{return Ey()||Cy()||Sy()}catch(n){console.info(`Unable to get __FIREBASE_DEFAULTS__ due to: ${n}`);return}},Lf=n=>{var t,e;return(e=(t=Kc())===null||t===void 0?void 0:t.emulatorHosts)===null||e===void 0?void 0:e[n]};var Yc=()=>{var n;return(n=Kc())===null||n===void 0?void 0:n.config},Qc=n=>{var t;return(t=Kc())===null||t===void 0?void 0:t[`_${n}`]};var eo=class{constructor(){this.reject=()=>{},this.resolve=()=>{},this.promise=new Promise((t,e)=>{this.resolve=t,this.reject=e})}wrapCallback(t){return(e,i)=>{e?this.reject(e):this.resolve(i),typeof t=="function"&&(this.promise.catch(()=>{}),t.length===1?t(e):t(e,i))}}};function ve(){return typeof navigator<"u"&&typeof navigator.userAgent=="string"?navigator.userAgent:""}function Bf(){return typeof window<"u"&&!!(window.cordova||window.phonegap||window.PhoneGap)&&/ios|iphone|ipod|ipad|android|blackberry|iemobile/i.test(ve())}function Vf(){return typeof navigator<"u"&&navigator.userAgent==="Cloudflare-Workers"}function Uf(){let n=typeof chrome=="object"?chrome.runtime:typeof browser=="object"?browser.runtime:void 0;return typeof n=="object"&&n.id!==void 0}function jf(){return typeof navigator=="object"&&navigator.product==="ReactNative"}function $f(){let n=ve();return n.indexOf("MSIE ")>=0||n.indexOf("Trident/")>=0}function Hf(){try{return typeof indexedDB=="object"}catch{return!1}}function Gf(){return new Promise((n,t)=>{try{let e=!0,i="validate-browser-context-for-indexeddb-analytics-module",r=self.indexedDB.open(i);r.onsuccess=()=>{r.result.close(),e||self.indexedDB.deleteDatabase(i),n(!0)},r.onupgradeneeded=()=>{e=!1},r.onerror=()=>{var s;t(((s=r.error)===null||s===void 0?void 0:s.message)||"")}}catch(e){t(e)}})}var Iy="FirebaseError",nt=class n extends Error{constructor(t,e,i){super(e),this.code=t,this.customData=i,this.name=Iy,Object.setPrototypeOf(this,n.prototype),Error.captureStackTrace&&Error.captureStackTrace(this,Pt.prototype.create)}},Pt=class{constructor(t,e,i){this.service=t,this.serviceName=e,this.errors=i}create(t,...e){let i=e[0]||{},r=`${this.service}/${t}`,s=this.errors[t],o=s?Ay(s,i):"Error",c=`${this.serviceName}: ${o} (${r}).`;return new nt(r,c,i)}};function Ay(n,t){return n.replace(Oy,(e,i)=>{let r=t[i];return r!=null?String(r):`<${i}?>`})}var Oy=/\{\$([^}]+)}/g;function zf(n){for(let t in n)if(Object.prototype.hasOwnProperty.call(n,t))return!1;return!0}function hi(n,t){if(n===t)return!0;let e=Object.keys(n),i=Object.keys(t);for(let r of e){if(!i.includes(r))return!1;let s=n[r],o=t[r];if(kf(s)&&kf(o)){if(!hi(s,o))return!1}else if(s!==o)return!1}for(let r of i)if(!e.includes(r))return!1;return!0}function kf(n){return n!==null&&typeof n=="object"}function fi(n){let t=[];for(let[e,i]of Object.entries(n))Array.isArray(i)?i.forEach(r=>{t.push(encodeURIComponent(e)+"="+encodeURIComponent(r))}):t.push(encodeURIComponent(e)+"="+encodeURIComponent(i));return t.length?"&"+t.join("&"):""}function Wf(n,t){let e=new Wc(n,t);return e.subscribe.bind(e)}var Wc=class{constructor(t,e){this.observers=[],this.unsubscribes=[],this.observerCount=0,this.task=Promise.resolve(),this.finalized=!1,this.onNoObservers=e,this.task.then(()=>{t(this)}).catch(i=>{this.error(i)})}next(t){this.forEachObserver(e=>{e.next(t)})}error(t){this.forEachObserver(e=>{e.error(t)}),this.close(t)}complete(){this.forEachObserver(t=>{t.complete()}),this.close()}subscribe(t,e,i){let r;if(t===void 0&&e===void 0&&i===void 0)throw new Error("Missing Observer.");Ry(t,["next","error","complete"])?r=t:r={next:t,error:e,complete:i},r.next===void 0&&(r.next=Gc),r.error===void 0&&(r.error=Gc),r.complete===void 0&&(r.complete=Gc);let s=this.unsubscribeOne.bind(this,this.observers.length);return this.finalized&&this.task.then(()=>{try{this.finalError?r.error(this.finalError):r.complete()}catch{}}),this.observers.push(r),s}unsubscribeOne(t){this.observers===void 0||this.observers[t]===void 0||(delete this.observers[t],this.observerCount-=1,this.observerCount===0&&this.onNoObservers!==void 0&&this.onNoObservers(this))}forEachObserver(t){if(!this.finalized)for(let e=0;e<this.observers.length;e++)this.sendOne(e,t)}sendOne(t,e){this.task.then(()=>{if(this.observers!==void 0&&this.observers[t]!==void 0)try{e(this.observers[t])}catch(i){typeof console<"u"&&console.error&&console.error(i)}})}close(t){this.finalized||(this.finalized=!0,t!==void 0&&(this.finalError=t),this.task.then(()=>{this.observers=void 0,this.onNoObservers=void 0}))}};function Ry(n,t){if(typeof n!="object"||n===null)return!1;for(let e of t)if(e in n&&typeof n[e]=="function")return!0;return!1}function Gc(){}var RO=4*60*60*1e3;function Sn(n){return n&&n._delegate?n._delegate:n}var pt=class{constructor(t,e,i){this.name=t,this.instanceFactory=e,this.type=i,this.multipleInstances=!1,this.serviceProps={},this.instantiationMode="LAZY",this.onInstanceCreated=null}setInstantiationMode(t){return this.instantiationMode=t,this}setMultipleInstances(t){return this.multipleInstances=t,this}setServiceProps(t){return this.serviceProps=t,this}setInstanceCreatedCallback(t){return this.onInstanceCreated=t,this}};var In="[DEFAULT]";var Zc=class{constructor(t,e){this.name=t,this.container=e,this.component=null,this.instances=new Map,this.instancesDeferred=new Map,this.instancesOptions=new Map,this.onInitCallbacks=new Map}get(t){let e=this.normalizeInstanceIdentifier(t);if(!this.instancesDeferred.has(e)){let i=new eo;if(this.instancesDeferred.set(e,i),this.isInitialized(e)||this.shouldAutoInitialize())try{let r=this.getOrInitializeService({instanceIdentifier:e});r&&i.resolve(r)}catch{}}return this.instancesDeferred.get(e).promise}getImmediate(t){var e;let i=this.normalizeInstanceIdentifier(t?.identifier),r=(e=t?.optional)!==null&&e!==void 0?e:!1;if(this.isInitialized(i)||this.shouldAutoInitialize())try{return this.getOrInitializeService({instanceIdentifier:i})}catch(s){if(r)return null;throw s}else{if(r)return null;throw Error(`Service ${this.name} is not available`)}}getComponent(){return this.component}setComponent(t){if(t.name!==this.name)throw Error(`Mismatching Component ${t.name} for Provider ${this.name}.`);if(this.component)throw Error(`Component for ${this.name} has already been provided`);if(this.component=t,!!this.shouldAutoInitialize()){if(Py(t))try{this.getOrInitializeService({instanceIdentifier:In})}catch{}for(let[e,i]of this.instancesDeferred.entries()){let r=this.normalizeInstanceIdentifier(e);try{let s=this.getOrInitializeService({instanceIdentifier:r});i.resolve(s)}catch{}}}}clearInstance(t=In){this.instancesDeferred.delete(t),this.instancesOptions.delete(t),this.instances.delete(t)}delete(){return f(this,null,function*(){let t=Array.from(this.instances.values());yield Promise.all([...t.filter(e=>"INTERNAL"in e).map(e=>e.INTERNAL.delete()),...t.filter(e=>"_delete"in e).map(e=>e._delete())])})}isComponentSet(){return this.component!=null}isInitialized(t=In){return this.instances.has(t)}getOptions(t=In){return this.instancesOptions.get(t)||{}}initialize(t={}){let{options:e={}}=t,i=this.normalizeInstanceIdentifier(t.instanceIdentifier);if(this.isInitialized(i))throw Error(`${this.name}(${i}) has already been initialized`);if(!this.isComponentSet())throw Error(`Component ${this.name} has not been registered yet`);let r=this.getOrInitializeService({instanceIdentifier:i,options:e});for(let[s,o]of this.instancesDeferred.entries()){let c=this.normalizeInstanceIdentifier(s);i===c&&o.resolve(r)}return r}onInit(t,e){var i;let r=this.normalizeInstanceIdentifier(e),s=(i=this.onInitCallbacks.get(r))!==null&&i!==void 0?i:new Set;s.add(t),this.onInitCallbacks.set(r,s);let o=this.instances.get(r);return o&&t(o,r),()=>{s.delete(t)}}invokeOnInitCallbacks(t,e){let i=this.onInitCallbacks.get(e);if(i)for(let r of i)try{r(t,e)}catch{}}getOrInitializeService({instanceIdentifier:t,options:e={}}){let i=this.instances.get(t);if(!i&&this.component&&(i=this.component.instanceFactory(this.container,{instanceIdentifier:My(t),options:e}),this.instances.set(t,i),this.instancesOptions.set(t,e),this.invokeOnInitCallbacks(i,t),this.component.onInstanceCreated))try{this.component.onInstanceCreated(this.container,t,i)}catch{}return i||null}normalizeInstanceIdentifier(t=In){return this.component?this.component.multipleInstances?t:In:t}shouldAutoInitialize(){return!!this.component&&this.component.instantiationMode!=="EXPLICIT"}};function My(n){return n===In?void 0:n}function Py(n){return n.instantiationMode==="EAGER"}var to=class{constructor(t){this.name=t,this.providers=new Map}addComponent(t){let e=this.getProvider(t.name);if(e.isComponentSet())throw new Error(`Component ${t.name} has already been registered with ${this.name}`);e.setComponent(t)}addOrOverwriteComponent(t){this.getProvider(t.name).isComponentSet()&&this.providers.delete(t.name),this.addComponent(t)}getProvider(t){if(this.providers.has(t))return this.providers.get(t);let e=new Zc(t,this);return this.providers.set(t,e),e}getProviders(){return Array.from(this.providers.values())}};var Ny=[],H=function(n){return n[n.DEBUG=0]="DEBUG",n[n.VERBOSE=1]="VERBOSE",n[n.INFO=2]="INFO",n[n.WARN=3]="WARN",n[n.ERROR=4]="ERROR",n[n.SILENT=5]="SILENT",n}(H||{}),ky={debug:H.DEBUG,verbose:H.VERBOSE,info:H.INFO,warn:H.WARN,error:H.ERROR,silent:H.SILENT},xy=H.INFO,Fy={[H.DEBUG]:"log",[H.VERBOSE]:"log",[H.INFO]:"info",[H.WARN]:"warn",[H.ERROR]:"error"},Ly=(n,t,...e)=>{if(t<n.logLevel)return;let i=new Date().toISOString(),r=Fy[t];if(r)console[r](`[${i}] ${n.name}:`,...e);else throw new Error(`Attempted to log a message with an invalid logType (value: ${t})`)},pi=class{constructor(t){this.name=t,this._logLevel=xy,this._logHandler=Ly,this._userLogHandler=null,Ny.push(this)}get logLevel(){return this._logLevel}set logLevel(t){if(!(t in H))throw new TypeError(`Invalid value "${t}" assigned to \`logLevel\``);this._logLevel=t}setLogLevel(t){this._logLevel=typeof t=="string"?ky[t]:t}get logHandler(){return this._logHandler}set logHandler(t){if(typeof t!="function")throw new TypeError("Value assigned to `logHandler` must be a function");this._logHandler=t}get userLogHandler(){return this._userLogHandler}set userLogHandler(t){this._userLogHandler=t}debug(...t){this._userLogHandler&&this._userLogHandler(this,H.DEBUG,...t),this._logHandler(this,H.DEBUG,...t)}log(...t){this._userLogHandler&&this._userLogHandler(this,H.VERBOSE,...t),this._logHandler(this,H.VERBOSE,...t)}info(...t){this._userLogHandler&&this._userLogHandler(this,H.INFO,...t),this._logHandler(this,H.INFO,...t)}warn(...t){this._userLogHandler&&this._userLogHandler(this,H.WARN,...t),this._logHandler(this,H.WARN,...t)}error(...t){this._userLogHandler&&this._userLogHandler(this,H.ERROR,...t),this._logHandler(this,H.ERROR,...t)}};var By=(n,t)=>t.some(e=>n instanceof e),qf,Jf;function Vy(){return qf||(qf=[IDBDatabase,IDBObjectStore,IDBIndex,IDBCursor,IDBTransaction])}function Uy(){return Jf||(Jf=[IDBCursor.prototype.advance,IDBCursor.prototype.continue,IDBCursor.prototype.continuePrimaryKey])}var Kf=new WeakMap,el=new WeakMap,Yf=new WeakMap,Xc=new WeakMap,nl=new WeakMap;function jy(n){let t=new Promise((e,i)=>{let r=()=>{n.removeEventListener("success",s),n.removeEventListener("error",o)},s=()=>{e(gt(n.result)),r()},o=()=>{i(n.error),r()};n.addEventListener("success",s),n.addEventListener("error",o)});return t.then(e=>{e instanceof IDBCursor&&Kf.set(e,n)}).catch(()=>{}),nl.set(t,n),t}function $y(n){if(el.has(n))return;let t=new Promise((e,i)=>{let r=()=>{n.removeEventListener("complete",s),n.removeEventListener("error",o),n.removeEventListener("abort",o)},s=()=>{e(),r()},o=()=>{i(n.error||new DOMException("AbortError","AbortError")),r()};n.addEventListener("complete",s),n.addEventListener("error",o),n.addEventListener("abort",o)});el.set(n,t)}var tl={get(n,t,e){if(n instanceof IDBTransaction){if(t==="done")return el.get(n);if(t==="objectStoreNames")return n.objectStoreNames||Yf.get(n);if(t==="store")return e.objectStoreNames[1]?void 0:e.objectStore(e.objectStoreNames[0])}return gt(n[t])},set(n,t,e){return n[t]=e,!0},has(n,t){return n instanceof IDBTransaction&&(t==="done"||t==="store")?!0:t in n}};function Qf(n){tl=n(tl)}function Hy(n){return n===IDBDatabase.prototype.transaction&&!("objectStoreNames"in IDBTransaction.prototype)?function(t,...e){let i=n.call(no(this),t,...e);return Yf.set(i,t.sort?t.sort():[t]),gt(i)}:Uy().includes(n)?function(...t){return n.apply(no(this),t),gt(Kf.get(this))}:function(...t){return gt(n.apply(no(this),t))}}function Gy(n){return typeof n=="function"?Hy(n):(n instanceof IDBTransaction&&$y(n),By(n,Vy())?new Proxy(n,tl):n)}function gt(n){if(n instanceof IDBRequest)return jy(n);if(Xc.has(n))return Xc.get(n);let t=Gy(n);return t!==n&&(Xc.set(n,t),nl.set(t,n)),t}var no=n=>nl.get(n);function Xf(n,t,{blocked:e,upgrade:i,blocking:r,terminated:s}={}){let o=indexedDB.open(n,t),c=gt(o);return i&&o.addEventListener("upgradeneeded",a=>{i(gt(o.result),a.oldVersion,a.newVersion,gt(o.transaction),a)}),e&&o.addEventListener("blocked",a=>e(a.oldVersion,a.newVersion,a)),c.then(a=>{s&&a.addEventListener("close",()=>s()),r&&a.addEventListener("versionchange",l=>r(l.oldVersion,l.newVersion,l))}).catch(()=>{}),c}var zy=["get","getKey","getAll","getAllKeys","count"],Wy=["put","add","delete","clear"],il=new Map;function Zf(n,t){if(!(n instanceof IDBDatabase&&!(t in n)&&typeof t=="string"))return;if(il.get(t))return il.get(t);let e=t.replace(/FromIndex$/,""),i=t!==e,r=Wy.includes(e);if(!(e in(i?IDBIndex:IDBObjectStore).prototype)||!(r||zy.includes(e)))return;let s=function(o,...c){return f(this,null,function*(){let a=this.transaction(o,r?"readwrite":"readonly"),l=a.store;return i&&(l=l.index(c.shift())),(yield Promise.all([l[e](...c),r&&a.done]))[0]})};return il.set(t,s),s}Qf(n=>k(m({},n),{get:(t,e,i)=>Zf(t,e)||n.get(t,e,i),has:(t,e)=>!!Zf(t,e)||n.has(t,e)}));var sl=class{constructor(t){this.container=t}getPlatformInfoString(){return this.container.getProviders().map(e=>{if(qy(e)){let i=e.getImmediate();return`${i.library}/${i.version}`}else return null}).filter(e=>e).join(" ")}};function qy(n){let t=n.getComponent();return t?.type==="VERSION"}var ol="@firebase/app",ep="0.10.13";var Nt=new pi("@firebase/app"),Jy="@firebase/app-compat",Ky="@firebase/analytics-compat",Yy="@firebase/analytics",Qy="@firebase/app-check-compat",Zy="@firebase/app-check",Xy="@firebase/auth",eb="@firebase/auth-compat",tb="@firebase/database",nb="@firebase/data-connect",ib="@firebase/database-compat",rb="@firebase/functions",sb="@firebase/functions-compat",ob="@firebase/installations",ab="@firebase/installations-compat",cb="@firebase/messaging",lb="@firebase/messaging-compat",ub="@firebase/performance",db="@firebase/performance-compat",hb="@firebase/remote-config",fb="@firebase/remote-config-compat",pb="@firebase/storage",gb="@firebase/storage-compat",mb="@firebase/firestore",_b="@firebase/vertexai-preview",vb="@firebase/firestore-compat",yb="firebase",bb="10.14.1";var al="[DEFAULT]",wb={[ol]:"fire-core",[Jy]:"fire-core-compat",[Yy]:"fire-analytics",[Ky]:"fire-analytics-compat",[Zy]:"fire-app-check",[Qy]:"fire-app-check-compat",[Xy]:"fire-auth",[eb]:"fire-auth-compat",[tb]:"fire-rtdb",[nb]:"fire-data-connect",[ib]:"fire-rtdb-compat",[rb]:"fire-fn",[sb]:"fire-fn-compat",[ob]:"fire-iid",[ab]:"fire-iid-compat",[cb]:"fire-fcm",[lb]:"fire-fcm-compat",[ub]:"fire-perf",[db]:"fire-perf-compat",[hb]:"fire-rc",[fb]:"fire-rc-compat",[pb]:"fire-gcs",[gb]:"fire-gcs-compat",[mb]:"fire-fst",[vb]:"fire-fst-compat",[_b]:"fire-vertex","fire-js":"fire-js",[yb]:"fire-js-all"};var Er=new Map,Db=new Map,cl=new Map;function tp(n,t){try{n.container.addComponent(t)}catch(e){Nt.debug(`Component ${t.name} failed to register with FirebaseApp ${n.name}`,e)}}function gi(n){let t=n.name;if(cl.has(t))return Nt.debug(`There were multiple attempts to register component ${t}.`),!1;cl.set(t,n);for(let e of Er.values())tp(e,n);for(let e of Db.values())tp(e,n);return!0}function hl(n,t){let e=n.container.getProvider("heartbeat").getImmediate({optional:!0});return e&&e.triggerHeartbeat(),n.container.getProvider(t)}function mt(n){return n.settings!==void 0}var Tb={"no-app":"No Firebase App '{$appName}' has been created - call initializeApp() first","bad-app-name":"Illegal App name: '{$appName}'","duplicate-app":"Firebase App named '{$appName}' already exists with different options or config","app-deleted":"Firebase App named '{$appName}' already deleted","server-app-deleted":"Firebase Server App has been deleted","no-options":"Need to provide options, when not being deployed to hosting via source.","invalid-app-argument":"firebase.{$appName}() takes either no argument or a Firebase App instance.","invalid-log-argument":"First argument to `onLog` must be null or a function.","idb-open":"Error thrown when opening IndexedDB. Original error: {$originalErrorMessage}.","idb-get":"Error thrown when reading from IndexedDB. Original error: {$originalErrorMessage}.","idb-set":"Error thrown when writing to IndexedDB. Original error: {$originalErrorMessage}.","idb-delete":"Error thrown when deleting from IndexedDB. Original error: {$originalErrorMessage}.","finalization-registry-not-supported":"FirebaseServerApp deleteOnDeref field defined but the JS runtime does not support FinalizationRegistry.","invalid-server-app-environment":"FirebaseServerApp is not for use in browser environments."},tn=new Pt("app","Firebase",Tb);var ll=class{constructor(t,e,i){this._isDeleted=!1,this._options=Object.assign({},t),this._config=Object.assign({},e),this._name=e.name,this._automaticDataCollectionEnabled=e.automaticDataCollectionEnabled,this._container=i,this.container.addComponent(new pt("app",()=>this,"PUBLIC"))}get automaticDataCollectionEnabled(){return this.checkDestroyed(),this._automaticDataCollectionEnabled}set automaticDataCollectionEnabled(t){this.checkDestroyed(),this._automaticDataCollectionEnabled=t}get name(){return this.checkDestroyed(),this._name}get options(){return this.checkDestroyed(),this._options}get config(){return this.checkDestroyed(),this._config}get container(){return this._container}get isDeleted(){return this._isDeleted}set isDeleted(t){this._isDeleted=t}checkDestroyed(){if(this.isDeleted)throw tn.create("app-deleted",{appName:this._name})}};var mi=bb;function fl(n,t={}){let e=n;typeof t!="object"&&(t={name:t});let i=Object.assign({name:al,automaticDataCollectionEnabled:!1},t),r=i.name;if(typeof r!="string"||!r)throw tn.create("bad-app-name",{appName:String(r)});if(e||(e=Yc()),!e)throw tn.create("no-options");let s=Er.get(r);if(s){if(hi(e,s.options)&&hi(i,s.config))return s;throw tn.create("duplicate-app",{appName:r})}let o=new to(r);for(let a of cl.values())o.addComponent(a);let c=new ll(e,i,o);return Er.set(r,c),c}function io(n=al){let t=Er.get(n);if(!t&&n===al&&Yc())return fl();if(!t)throw tn.create("no-app",{appName:n});return t}function ro(){return Array.from(Er.values())}function Oe(n,t,e){var i;let r=(i=wb[n])!==null&&i!==void 0?i:n;e&&(r+=`-${e}`);let s=r.match(/\s|\//),o=t.match(/\s|\//);if(s||o){let c=[`Unable to register library "${r}" with version "${t}":`];s&&c.push(`library name "${r}" contains illegal characters (whitespace or "/")`),s&&o&&c.push("and"),o&&c.push(`version name "${t}" contains illegal characters (whitespace or "/")`),Nt.warn(c.join(" "));return}gi(new pt(`${r}-version`,()=>({library:r,version:t}),"VERSION"))}var Eb="firebase-heartbeat-database",Cb=1,Cr="firebase-heartbeat-store",rl=null;function sp(){return rl||(rl=Xf(Eb,Cb,{upgrade:(n,t)=>{switch(t){case 0:try{n.createObjectStore(Cr)}catch(e){console.warn(e)}}}}).catch(n=>{throw tn.create("idb-open",{originalErrorMessage:n.message})})),rl}function Sb(n){return f(this,null,function*(){try{let e=(yield sp()).transaction(Cr),i=yield e.objectStore(Cr).get(op(n));return yield e.done,i}catch(t){if(t instanceof nt)Nt.warn(t.message);else{let e=tn.create("idb-get",{originalErrorMessage:t?.message});Nt.warn(e.message)}}})}function np(n,t){return f(this,null,function*(){try{let i=(yield sp()).transaction(Cr,"readwrite");yield i.objectStore(Cr).put(t,op(n)),yield i.done}catch(e){if(e instanceof nt)Nt.warn(e.message);else{let i=tn.create("idb-set",{originalErrorMessage:e?.message});Nt.warn(i.message)}}})}function op(n){return`${n.name}!${n.options.appId}`}var Ib=1024,Ab=30*24*60*60*1e3,ul=class{constructor(t){this.container=t,this._heartbeatsCache=null;let e=this.container.getProvider("app").getImmediate();this._storage=new dl(e),this._heartbeatsCachePromise=this._storage.read().then(i=>(this._heartbeatsCache=i,i))}triggerHeartbeat(){return f(this,null,function*(){var t,e;try{let r=this.container.getProvider("platform-logger").getImmediate().getPlatformInfoString(),s=ip();return((t=this._heartbeatsCache)===null||t===void 0?void 0:t.heartbeats)==null&&(this._heartbeatsCache=yield this._heartbeatsCachePromise,((e=this._heartbeatsCache)===null||e===void 0?void 0:e.heartbeats)==null)||this._heartbeatsCache.lastSentHeartbeatDate===s||this._heartbeatsCache.heartbeats.some(o=>o.date===s)?void 0:(this._heartbeatsCache.heartbeats.push({date:s,agent:r}),this._heartbeatsCache.heartbeats=this._heartbeatsCache.heartbeats.filter(o=>{let c=new Date(o.date).valueOf();return Date.now()-c<=Ab}),this._storage.overwrite(this._heartbeatsCache))}catch(i){Nt.warn(i)}})}getHeartbeatsHeader(){return f(this,null,function*(){var t;try{if(this._heartbeatsCache===null&&(yield this._heartbeatsCachePromise),((t=this._heartbeatsCache)===null||t===void 0?void 0:t.heartbeats)==null||this._heartbeatsCache.heartbeats.length===0)return"";let e=ip(),{heartbeatsToSend:i,unsentEntries:r}=Ob(this._heartbeatsCache.heartbeats),s=qc(JSON.stringify({version:2,heartbeats:i}));return this._heartbeatsCache.lastSentHeartbeatDate=e,r.length>0?(this._heartbeatsCache.heartbeats=r,yield this._storage.overwrite(this._heartbeatsCache)):(this._heartbeatsCache.heartbeats=[],this._storage.overwrite(this._heartbeatsCache)),s}catch(e){return Nt.warn(e),""}})}};function ip(){return new Date().toISOString().substring(0,10)}function Ob(n,t=Ib){let e=[],i=n.slice();for(let r of n){let s=e.find(o=>o.agent===r.agent);if(s){if(s.dates.push(r.date),rp(e)>t){s.dates.pop();break}}else if(e.push({agent:r.agent,dates:[r.date]}),rp(e)>t){e.pop();break}i=i.slice(1)}return{heartbeatsToSend:e,unsentEntries:i}}var dl=class{constructor(t){this.app=t,this._canUseIndexedDBPromise=this.runIndexedDBEnvironmentCheck()}runIndexedDBEnvironmentCheck(){return f(this,null,function*(){return Hf()?Gf().then(()=>!0).catch(()=>!1):!1})}read(){return f(this,null,function*(){if(yield this._canUseIndexedDBPromise){let e=yield Sb(this.app);return e?.heartbeats?e:{heartbeats:[]}}else return{heartbeats:[]}})}overwrite(t){return f(this,null,function*(){var e;if(yield this._canUseIndexedDBPromise){let r=yield this.read();return np(this.app,{lastSentHeartbeatDate:(e=t.lastSentHeartbeatDate)!==null&&e!==void 0?e:r.lastSentHeartbeatDate,heartbeats:t.heartbeats})}else return})}add(t){return f(this,null,function*(){var e;if(yield this._canUseIndexedDBPromise){let r=yield this.read();return np(this.app,{lastSentHeartbeatDate:(e=t.lastSentHeartbeatDate)!==null&&e!==void 0?e:r.lastSentHeartbeatDate,heartbeats:[...r.heartbeats,...t.heartbeats]})}else return})}};function rp(n){return qc(JSON.stringify({version:2,heartbeats:n})).length}function Rb(n){gi(new pt("platform-logger",t=>new sl(t),"PRIVATE")),gi(new pt("heartbeat",t=>new ul(t),"PRIVATE")),Oe(ol,ep,n),Oe(ol,ep,"esm2017"),Oe("fire-js","")}Rb("");var Mb="firebase",Pb="10.14.1";Oe(Mb,Pb,"app");var Sr=new Pi("ANGULARFIRE2_VERSION");function ap(n,t,e){if(t){if(t.length===1)return t[0];let s=t.filter(o=>o.app===e);if(s.length===1)return s[0]}return e.container.getProvider(n).getImmediate({optional:!0})}var gl=(n,t)=>{let e=t?[t]:ro(),i=[];return e.forEach(r=>{r.container.getProvider(n).instances.forEach(o=>{i.includes(o)||i.push(o)})}),i},so=class{constructor(){return gl(Nb)}},Nb="app-check";function _i(){}var oo=class{zone;delegate;constructor(t,e=du){this.zone=t,this.delegate=e}now(){return this.delegate.now()}schedule(t,e,i){let r=this.zone,s=function(o){r.runGuarded(()=>{t.apply(this,[o])})};return this.delegate.schedule(s,e,i)}},pl=class{zone;task=null;constructor(t){this.zone=t}call(t,e){let i=this.unscheduleTask.bind(this);return this.task=this.zone.run(()=>Zone.current.scheduleMacroTask("firebaseZoneBlock",_i,{},_i,_i)),e.pipe(U({next:i,complete:i,error:i})).subscribe(t).add(i)}unscheduleTask(){setTimeout(()=>{this.task!=null&&this.task.state==="scheduled"&&(this.task.invoke(),this.task=null)},10)}},ao=(()=>{class n{ngZone;outsideAngular;insideAngular;constructor(e){this.ngZone=e,this.outsideAngular=e.runOutsideAngular(()=>new oo(Zone.current)),this.insideAngular=e.run(()=>new oo(Zone.current,uu)),globalThis.\u0275AngularFireScheduler||=this}static \u0275fac=function(i){return new(i||n)(C($))};static \u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}return n})();function co(){let n=globalThis.\u0275AngularFireScheduler;if(!n)throw new Error(`Either AngularFireModule has not been provided in your AppModule (this can be done manually or implictly using
5
- provideFirebaseApp) or you're calling an AngularFire method outside of an NgModule (which is not supported).`);return n}function kb(n){return co().ngZone.runOutsideAngular(()=>n())}function An(n){return co().ngZone.run(()=>n())}function xb(n){return Fb(co())(n)}function Fb(n){return function(e){return e=e.lift(new pl(n.ngZone)),e.pipe(Fo(n.outsideAngular),xo(n.insideAngular))}}var Lb=(n,t)=>function(){let i=arguments;return t&&setTimeout(()=>{t.state==="scheduled"&&t.invoke()},10),An(()=>n.apply(void 0,i))},vi=(n,t)=>function(){let e,i=arguments;for(let s=0;s<arguments.length;s++)typeof i[s]=="function"&&(t&&(e||=An(()=>Zone.current.scheduleMacroTask("firebaseZoneBlock",_i,{},_i,_i))),i[s]=Lb(i[s],e));let r=kb(()=>n.apply(this,i));if(!t)if(r instanceof Ne){let s=co();return r.pipe(Fo(s.outsideAngular),xo(s.insideAngular))}else return An(()=>r);return r instanceof Ne?r.pipe(xb):r instanceof Promise?An(()=>new Promise((s,o)=>r.then(c=>An(()=>s(c)),c=>An(()=>o(c))))):typeof r=="function"&&e?function(){return setTimeout(()=>{e&&e.state==="scheduled"&&e.invoke()},10),r.apply(this,arguments)}:An(()=>r)};var On=class{constructor(t){return t}},Ir=class{constructor(){return ro()}};function Bb(n){return n&&n.length===1?n[0]:new On(io())}var ml=new O("angularfire2._apps"),Vb={provide:On,useFactory:Bb,deps:[[new st,ml]]},Ub={provide:Ir,deps:[[new st,ml]]};function jb(n){return(t,e)=>{let i=e.get(ct);Oe("angularfire",Sr.full,"core"),Oe("angularfire",Sr.full,"app"),Oe("angular",Ku.full,i.toString());let r=t.runOutsideAngular(()=>n(e));return new On(r)}}function mR(n,...t){return qe([Vb,Ub,{provide:ml,useFactory:jb(n),multi:!0,deps:[$,J,ao,...t]}])}var _R=vi(fl,!0);function Dp(){return{"dependent-sdk-initialized-before-auth":"Another Firebase SDK was initialized and is trying to use Auth before Auth is initialized. Please be sure to call `initializeAuth` or `getAuth` before starting any other Firebase SDK."}}var Tp=Dp,Ep=new Pt("auth","Firebase",Dp());var go=new pi("@firebase/auth");function $b(n,...t){go.logLevel<=H.WARN&&go.warn(`Auth (${mi}): ${n}`,...t)}function uo(n,...t){go.logLevel<=H.ERROR&&go.error(`Auth (${mi}): ${n}`,...t)}function vt(n,...t){throw kl(n,...t)}function it(n,...t){return kl(n,...t)}function Nl(n,t,e){let i=Object.assign(Object.assign({},Tp()),{[t]:e});return new Pt("auth","Firebase",i).create(t,{appName:n.name})}function Rn(n){return Nl(n,"operation-not-supported-in-this-environment","Operations that alter the current user are not supported in conjunction with FirebaseServerApp")}function Hb(n,t,e){let i=e;if(!(t instanceof i))throw i.name!==t.constructor.name&&vt(n,"argument-error"),Nl(n,"argument-error",`Type of ${t.constructor.name} does not match expected instance.Did you pass a reference from a different Auth SDK?`)}function kl(n,...t){if(typeof n!="string"){let e=t[0],i=[...t.slice(1)];return i[0]&&(i[0].appName=n.name),n._errorFactory.create(e,...i)}return Ep.create(n,...t)}function T(n,t,...e){if(!n)throw kl(t,...e)}function kt(n){let t="INTERNAL ASSERTION FAILED: "+n;throw uo(t),new Error(t)}function Ft(n,t){n||kt(t)}function yl(){var n;return typeof self<"u"&&((n=self.location)===null||n===void 0?void 0:n.href)||""}function Gb(){return cp()==="http:"||cp()==="https:"}function cp(){var n;return typeof self<"u"&&((n=self.location)===null||n===void 0?void 0:n.protocol)||null}function zb(){return typeof navigator<"u"&&navigator&&"onLine"in navigator&&typeof navigator.onLine=="boolean"&&(Gb()||Uf()||"connection"in navigator)?navigator.onLine:!0}function Wb(){if(typeof navigator>"u")return null;let n=navigator;return n.languages&&n.languages[0]||n.language||null}var Mn=class{constructor(t,e){this.shortDelay=t,this.longDelay=e,Ft(e>t,"Short delay should be less than long delay!"),this.isMobile=Bf()||jf()}get(){return zb()?this.isMobile?this.longDelay:this.shortDelay:Math.min(5e3,this.shortDelay)}};function xl(n,t){Ft(n.emulator,"Emulator should always be set here");let{url:e}=n.emulator;return t?`${e}${t.startsWith("/")?t.slice(1):t}`:e}var mo=class{static initialize(t,e,i){this.fetchImpl=t,e&&(this.headersImpl=e),i&&(this.responseImpl=i)}static fetch(){if(this.fetchImpl)return this.fetchImpl;if(typeof self<"u"&&"fetch"in self)return self.fetch;if(typeof globalThis<"u"&&globalThis.fetch)return globalThis.fetch;if(typeof fetch<"u")return fetch;kt("Could not find fetch implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}static headers(){if(this.headersImpl)return this.headersImpl;if(typeof self<"u"&&"Headers"in self)return self.Headers;if(typeof globalThis<"u"&&globalThis.Headers)return globalThis.Headers;if(typeof Headers<"u")return Headers;kt("Could not find Headers implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}static response(){if(this.responseImpl)return this.responseImpl;if(typeof self<"u"&&"Response"in self)return self.Response;if(typeof globalThis<"u"&&globalThis.Response)return globalThis.Response;if(typeof Response<"u")return Response;kt("Could not find Response implementation, make sure you call FetchProvider.initialize() with an appropriate polyfill")}};var qb={CREDENTIAL_MISMATCH:"custom-token-mismatch",MISSING_CUSTOM_TOKEN:"internal-error",INVALID_IDENTIFIER:"invalid-email",MISSING_CONTINUE_URI:"internal-error",INVALID_PASSWORD:"wrong-password",MISSING_PASSWORD:"missing-password",INVALID_LOGIN_CREDENTIALS:"invalid-credential",EMAIL_EXISTS:"email-already-in-use",PASSWORD_LOGIN_DISABLED:"operation-not-allowed",INVALID_IDP_RESPONSE:"invalid-credential",INVALID_PENDING_TOKEN:"invalid-credential",FEDERATED_USER_ID_ALREADY_LINKED:"credential-already-in-use",MISSING_REQ_TYPE:"internal-error",EMAIL_NOT_FOUND:"user-not-found",RESET_PASSWORD_EXCEED_LIMIT:"too-many-requests",EXPIRED_OOB_CODE:"expired-action-code",INVALID_OOB_CODE:"invalid-action-code",MISSING_OOB_CODE:"internal-error",CREDENTIAL_TOO_OLD_LOGIN_AGAIN:"requires-recent-login",INVALID_ID_TOKEN:"invalid-user-token",TOKEN_EXPIRED:"user-token-expired",USER_NOT_FOUND:"user-token-expired",TOO_MANY_ATTEMPTS_TRY_LATER:"too-many-requests",PASSWORD_DOES_NOT_MEET_REQUIREMENTS:"password-does-not-meet-requirements",INVALID_CODE:"invalid-verification-code",INVALID_SESSION_INFO:"invalid-verification-id",INVALID_TEMPORARY_PROOF:"invalid-credential",MISSING_SESSION_INFO:"missing-verification-id",SESSION_EXPIRED:"code-expired",MISSING_ANDROID_PACKAGE_NAME:"missing-android-pkg-name",UNAUTHORIZED_DOMAIN:"unauthorized-continue-uri",INVALID_OAUTH_CLIENT_ID:"invalid-oauth-client-id",ADMIN_ONLY_OPERATION:"admin-restricted-operation",INVALID_MFA_PENDING_CREDENTIAL:"invalid-multi-factor-session",MFA_ENROLLMENT_NOT_FOUND:"multi-factor-info-not-found",MISSING_MFA_ENROLLMENT_ID:"missing-multi-factor-info",MISSING_MFA_PENDING_CREDENTIAL:"missing-multi-factor-session",SECOND_FACTOR_EXISTS:"second-factor-already-in-use",SECOND_FACTOR_LIMIT_EXCEEDED:"maximum-second-factor-count-exceeded",BLOCKING_FUNCTION_ERROR_RESPONSE:"internal-error",RECAPTCHA_NOT_ENABLED:"recaptcha-not-enabled",MISSING_RECAPTCHA_TOKEN:"missing-recaptcha-token",INVALID_RECAPTCHA_TOKEN:"invalid-recaptcha-token",INVALID_RECAPTCHA_ACTION:"invalid-recaptcha-action",MISSING_CLIENT_TYPE:"missing-client-type",MISSING_RECAPTCHA_VERSION:"missing-recaptcha-version",INVALID_RECAPTCHA_VERSION:"invalid-recaptcha-version",INVALID_REQ_TYPE:"invalid-req-type"};var Jb=new Mn(3e4,6e4);function Fl(n,t){return n.tenantId&&!t.tenantId?Object.assign(Object.assign({},t),{tenantId:n.tenantId}):t}function wi(s,o,c,a){return f(this,arguments,function*(n,t,e,i,r={}){return Cp(n,r,()=>f(this,null,function*(){let l={},u={};i&&(t==="GET"?u=i:l={body:JSON.stringify(i)});let d=fi(Object.assign({key:n.config.apiKey},u)).slice(1),p=yield n._getAdditionalHeaders();p["Content-Type"]="application/json",n.languageCode&&(p["X-Firebase-Locale"]=n.languageCode);let g=Object.assign({method:t,headers:p},l);return Vf()||(g.referrerPolicy="no-referrer"),mo.fetch()(Sp(n,n.config.apiHost,e,d),g)}))})}function Cp(n,t,e){return f(this,null,function*(){n._canInitEmulator=!1;let i=Object.assign(Object.assign({},qb),t);try{let r=new bl(n),s=yield Promise.race([e(),r.promise]);r.clearNetworkTimeout();let o=yield s.json();if("needConfirmation"in o)throw lo(n,"account-exists-with-different-credential",o);if(s.ok&&!("errorMessage"in o))return o;{let c=s.ok?o.errorMessage:o.error.message,[a,l]=c.split(" : ");if(a==="FEDERATED_USER_ID_ALREADY_LINKED")throw lo(n,"credential-already-in-use",o);if(a==="EMAIL_EXISTS")throw lo(n,"email-already-in-use",o);if(a==="USER_DISABLED")throw lo(n,"user-disabled",o);let u=i[a]||a.toLowerCase().replace(/[_\s]+/g,"-");if(l)throw Nl(n,u,l);vt(n,u)}}catch(r){if(r instanceof nt)throw r;vt(n,"network-request-failed",{message:String(r)})}})}function Kb(s,o,c,a){return f(this,arguments,function*(n,t,e,i,r={}){let l=yield wi(n,t,e,i,r);return"mfaPendingCredential"in l&&vt(n,"multi-factor-auth-required",{_serverResponse:l}),l})}function Sp(n,t,e,i){let r=`${t}${e}?${i}`;return n.config.emulator?xl(n.config,r):`${n.config.apiScheme}://${r}`}var bl=class{constructor(t){this.auth=t,this.timer=null,this.promise=new Promise((e,i)=>{this.timer=setTimeout(()=>i(it(this.auth,"network-request-failed")),Jb.get())})}clearNetworkTimeout(){clearTimeout(this.timer)}};function lo(n,t,e){let i={appName:n.name};e.email&&(i.email=e.email),e.phoneNumber&&(i.phoneNumber=e.phoneNumber);let r=it(n,t,i);return r.customData._tokenResponse=e,r}function Yb(n,t){return f(this,null,function*(){return wi(n,"POST","/v1/accounts:delete",t)})}function Ip(n,t){return f(this,null,function*(){return wi(n,"POST","/v1/accounts:lookup",t)})}function Ar(n){if(n)try{let t=new Date(Number(n));if(!isNaN(t.getTime()))return t.toUTCString()}catch{}}function Ll(n,t=!1){return f(this,null,function*(){let e=Sn(n),i=yield e.getIdToken(t),r=Bl(i);T(r&&r.exp&&r.auth_time&&r.iat,e.auth,"internal-error");let s=typeof r.firebase=="object"?r.firebase:void 0,o=s?.sign_in_provider;return{claims:r,token:i,authTime:Ar(_l(r.auth_time)),issuedAtTime:Ar(_l(r.iat)),expirationTime:Ar(_l(r.exp)),signInProvider:o||null,signInSecondFactor:s?.sign_in_second_factor||null}})}function _l(n){return Number(n)*1e3}function Bl(n){let[t,e,i]=n.split(".");if(t===void 0||e===void 0||i===void 0)return uo("JWT malformed, contained fewer than 3 sections"),null;try{let r=Jc(e);return r?JSON.parse(r):(uo("Failed to decode base64 JWT payload"),null)}catch(r){return uo("Caught error parsing JWT payload as JSON",r?.toString()),null}}function lp(n){let t=Bl(n);return T(t,"internal-error"),T(typeof t.exp<"u","internal-error"),T(typeof t.iat<"u","internal-error"),Number(t.exp)-Number(t.iat)}function Rr(n,t,e=!1){return f(this,null,function*(){if(e)return t;try{return yield t}catch(i){throw i instanceof nt&&Qb(i)&&n.auth.currentUser===n&&(yield n.auth.signOut()),i}})}function Qb({code:n}){return n==="auth/user-disabled"||n==="auth/user-token-expired"}var wl=class{constructor(t){this.user=t,this.isRunning=!1,this.timerId=null,this.errorBackoff=3e4}_start(){this.isRunning||(this.isRunning=!0,this.schedule())}_stop(){this.isRunning&&(this.isRunning=!1,this.timerId!==null&&clearTimeout(this.timerId))}getInterval(t){var e;if(t){let i=this.errorBackoff;return this.errorBackoff=Math.min(this.errorBackoff*2,96e4),i}else{this.errorBackoff=3e4;let r=((e=this.user.stsTokenManager.expirationTime)!==null&&e!==void 0?e:0)-Date.now()-3e5;return Math.max(0,r)}}schedule(t=!1){if(!this.isRunning)return;let e=this.getInterval(t);this.timerId=setTimeout(()=>f(this,null,function*(){yield this.iteration()}),e)}iteration(){return f(this,null,function*(){try{yield this.user.getIdToken(!0)}catch(t){t?.code==="auth/network-request-failed"&&this.schedule(!0);return}this.schedule()})}};var Mr=class{constructor(t,e){this.createdAt=t,this.lastLoginAt=e,this._initializeTime()}_initializeTime(){this.lastSignInTime=Ar(this.lastLoginAt),this.creationTime=Ar(this.createdAt)}_copy(t){this.createdAt=t.createdAt,this.lastLoginAt=t.lastLoginAt,this._initializeTime()}toJSON(){return{createdAt:this.createdAt,lastLoginAt:this.lastLoginAt}}};function _o(n){return f(this,null,function*(){var t;let e=n.auth,i=yield n.getIdToken(),r=yield Rr(n,Ip(e,{idToken:i}));T(r?.users.length,e,"internal-error");let s=r.users[0];n._notifyReloadListener(s);let o=!((t=s.providerUserInfo)===null||t===void 0)&&t.length?Ap(s.providerUserInfo):[],c=Zb(n.providerData,o),a=n.isAnonymous,l=!(n.email&&s.passwordHash)&&!c?.length,u=a?l:!1,d={uid:s.localId,displayName:s.displayName||null,photoURL:s.photoUrl||null,email:s.email||null,emailVerified:s.emailVerified||!1,phoneNumber:s.phoneNumber||null,tenantId:s.tenantId||null,providerData:c,metadata:new Mr(s.createdAt,s.lastLoginAt),isAnonymous:u};Object.assign(n,d)})}function Vl(n){return f(this,null,function*(){let t=Sn(n);yield _o(t),yield t.auth._persistUserIfCurrent(t),t.auth._notifyListenersIfCurrent(t)})}function Zb(n,t){return[...n.filter(i=>!t.some(r=>r.providerId===i.providerId)),...t]}function Ap(n){return n.map(t=>{var{providerId:e}=t,i=Hr(t,["providerId"]);return{providerId:e,uid:i.rawId||"",displayName:i.displayName||null,email:i.email||null,phoneNumber:i.phoneNumber||null,photoURL:i.photoUrl||null}})}function Xb(n,t){return f(this,null,function*(){let e=yield Cp(n,{},()=>f(this,null,function*(){let i=fi({grant_type:"refresh_token",refresh_token:t}).slice(1),{tokenApiHost:r,apiKey:s}=n.config,o=Sp(n,r,"/v1/token",`key=${s}`),c=yield n._getAdditionalHeaders();return c["Content-Type"]="application/x-www-form-urlencoded",mo.fetch()(o,{method:"POST",headers:c,body:i})}));return{accessToken:e.access_token,expiresIn:e.expires_in,refreshToken:e.refresh_token}})}function e1(n,t){return f(this,null,function*(){return wi(n,"POST","/v2/accounts:revokeToken",Fl(n,t))})}var Or=class n{constructor(){this.refreshToken=null,this.accessToken=null,this.expirationTime=null}get isExpired(){return!this.expirationTime||Date.now()>this.expirationTime-3e4}updateFromServerResponse(t){T(t.idToken,"internal-error"),T(typeof t.idToken<"u","internal-error"),T(typeof t.refreshToken<"u","internal-error");let e="expiresIn"in t&&typeof t.expiresIn<"u"?Number(t.expiresIn):lp(t.idToken);this.updateTokensAndExpiration(t.idToken,t.refreshToken,e)}updateFromIdToken(t){T(t.length!==0,"internal-error");let e=lp(t);this.updateTokensAndExpiration(t,null,e)}getToken(t,e=!1){return f(this,null,function*(){return!e&&this.accessToken&&!this.isExpired?this.accessToken:(T(this.refreshToken,t,"user-token-expired"),this.refreshToken?(yield this.refresh(t,this.refreshToken),this.accessToken):null)})}clearRefreshToken(){this.refreshToken=null}refresh(t,e){return f(this,null,function*(){let{accessToken:i,refreshToken:r,expiresIn:s}=yield Xb(t,e);this.updateTokensAndExpiration(i,r,Number(s))})}updateTokensAndExpiration(t,e,i){this.refreshToken=e||null,this.accessToken=t||null,this.expirationTime=Date.now()+i*1e3}static fromJSON(t,e){let{refreshToken:i,accessToken:r,expirationTime:s}=e,o=new n;return i&&(T(typeof i=="string","internal-error",{appName:t}),o.refreshToken=i),r&&(T(typeof r=="string","internal-error",{appName:t}),o.accessToken=r),s&&(T(typeof s=="number","internal-error",{appName:t}),o.expirationTime=s),o}toJSON(){return{refreshToken:this.refreshToken,accessToken:this.accessToken,expirationTime:this.expirationTime}}_assign(t){this.accessToken=t.accessToken,this.refreshToken=t.refreshToken,this.expirationTime=t.expirationTime}_clone(){return Object.assign(new n,this.toJSON())}_performRefresh(){return kt("not implemented")}};function nn(n,t){T(typeof n=="string"||typeof n>"u","internal-error",{appName:t})}var bi=class n{constructor(t){var{uid:e,auth:i,stsTokenManager:r}=t,s=Hr(t,["uid","auth","stsTokenManager"]);this.providerId="firebase",this.proactiveRefresh=new wl(this),this.reloadUserInfo=null,this.reloadListener=null,this.uid=e,this.auth=i,this.stsTokenManager=r,this.accessToken=r.accessToken,this.displayName=s.displayName||null,this.email=s.email||null,this.emailVerified=s.emailVerified||!1,this.phoneNumber=s.phoneNumber||null,this.photoURL=s.photoURL||null,this.isAnonymous=s.isAnonymous||!1,this.tenantId=s.tenantId||null,this.providerData=s.providerData?[...s.providerData]:[],this.metadata=new Mr(s.createdAt||void 0,s.lastLoginAt||void 0)}getIdToken(t){return f(this,null,function*(){let e=yield Rr(this,this.stsTokenManager.getToken(this.auth,t));return T(e,this.auth,"internal-error"),this.accessToken!==e&&(this.accessToken=e,yield this.auth._persistUserIfCurrent(this),this.auth._notifyListenersIfCurrent(this)),e})}getIdTokenResult(t){return Ll(this,t)}reload(){return Vl(this)}_assign(t){this!==t&&(T(this.uid===t.uid,this.auth,"internal-error"),this.displayName=t.displayName,this.photoURL=t.photoURL,this.email=t.email,this.emailVerified=t.emailVerified,this.phoneNumber=t.phoneNumber,this.isAnonymous=t.isAnonymous,this.tenantId=t.tenantId,this.providerData=t.providerData.map(e=>Object.assign({},e)),this.metadata._copy(t.metadata),this.stsTokenManager._assign(t.stsTokenManager))}_clone(t){let e=new n(Object.assign(Object.assign({},this),{auth:t,stsTokenManager:this.stsTokenManager._clone()}));return e.metadata._copy(this.metadata),e}_onReload(t){T(!this.reloadListener,this.auth,"internal-error"),this.reloadListener=t,this.reloadUserInfo&&(this._notifyReloadListener(this.reloadUserInfo),this.reloadUserInfo=null)}_notifyReloadListener(t){this.reloadListener?this.reloadListener(t):this.reloadUserInfo=t}_startProactiveRefresh(){this.proactiveRefresh._start()}_stopProactiveRefresh(){this.proactiveRefresh._stop()}_updateTokensIfNecessary(t,e=!1){return f(this,null,function*(){let i=!1;t.idToken&&t.idToken!==this.stsTokenManager.accessToken&&(this.stsTokenManager.updateFromServerResponse(t),i=!0),e&&(yield _o(this)),yield this.auth._persistUserIfCurrent(this),i&&this.auth._notifyListenersIfCurrent(this)})}delete(){return f(this,null,function*(){if(mt(this.auth.app))return Promise.reject(Rn(this.auth));let t=yield this.getIdToken();return yield Rr(this,Yb(this.auth,{idToken:t})),this.stsTokenManager.clearRefreshToken(),this.auth.signOut()})}toJSON(){return Object.assign(Object.assign({uid:this.uid,email:this.email||void 0,emailVerified:this.emailVerified,displayName:this.displayName||void 0,isAnonymous:this.isAnonymous,photoURL:this.photoURL||void 0,phoneNumber:this.phoneNumber||void 0,tenantId:this.tenantId||void 0,providerData:this.providerData.map(t=>Object.assign({},t)),stsTokenManager:this.stsTokenManager.toJSON(),_redirectEventId:this._redirectEventId},this.metadata.toJSON()),{apiKey:this.auth.config.apiKey,appName:this.auth.name})}get refreshToken(){return this.stsTokenManager.refreshToken||""}static _fromJSON(t,e){var i,r,s,o,c,a,l,u;let d=(i=e.displayName)!==null&&i!==void 0?i:void 0,p=(r=e.email)!==null&&r!==void 0?r:void 0,g=(s=e.phoneNumber)!==null&&s!==void 0?s:void 0,w=(o=e.photoURL)!==null&&o!==void 0?o:void 0,v=(c=e.tenantId)!==null&&c!==void 0?c:void 0,_=(a=e._redirectEventId)!==null&&a!==void 0?a:void 0,S=(l=e.createdAt)!==null&&l!==void 0?l:void 0,x=(u=e.lastLoginAt)!==null&&u!==void 0?u:void 0,{uid:D,emailVerified:E,isAnonymous:M,providerData:P,stsTokenManager:V}=e;T(D&&V,t,"internal-error");let ee=Or.fromJSON(this.name,V);T(typeof D=="string",t,"internal-error"),nn(d,t.name),nn(p,t.name),T(typeof E=="boolean",t,"internal-error"),T(typeof M=="boolean",t,"internal-error"),nn(g,t.name),nn(w,t.name),nn(v,t.name),nn(_,t.name),nn(S,t.name),nn(x,t.name);let q=new n({uid:D,auth:t,email:p,emailVerified:E,displayName:d,isAnonymous:M,photoURL:w,phoneNumber:g,tenantId:v,stsTokenManager:ee,createdAt:S,lastLoginAt:x});return P&&Array.isArray(P)&&(q.providerData=P.map(Y=>Object.assign({},Y))),_&&(q._redirectEventId=_),q}static _fromIdTokenResponse(t,e,i=!1){return f(this,null,function*(){let r=new Or;r.updateFromServerResponse(e);let s=new n({uid:e.localId,auth:t,stsTokenManager:r,isAnonymous:i});return yield _o(s),s})}static _fromGetAccountInfoResponse(t,e,i){return f(this,null,function*(){let r=e.users[0];T(r.localId!==void 0,"internal-error");let s=r.providerUserInfo!==void 0?Ap(r.providerUserInfo):[],o=!(r.email&&r.passwordHash)&&!s?.length,c=new Or;c.updateFromIdToken(i);let a=new n({uid:r.localId,auth:t,stsTokenManager:c,isAnonymous:o}),l={uid:r.localId,displayName:r.displayName||null,photoURL:r.photoUrl||null,email:r.email||null,emailVerified:r.emailVerified||!1,phoneNumber:r.phoneNumber||null,tenantId:r.tenantId||null,providerData:s,metadata:new Mr(r.createdAt,r.lastLoginAt),isAnonymous:!(r.email&&r.passwordHash)&&!s?.length};return Object.assign(a,l),a})}};var up=new Map;function xt(n){Ft(n instanceof Function,"Expected a class definition");let t=up.get(n);return t?(Ft(t instanceof n,"Instance stored in cache mismatched with class"),t):(t=new n,up.set(n,t),t)}var t1=(()=>{class n{constructor(){this.type="NONE",this.storage={}}_isAvailable(){return f(this,null,function*(){return!0})}_set(e,i){return f(this,null,function*(){this.storage[e]=i})}_get(e){return f(this,null,function*(){let i=this.storage[e];return i===void 0?null:i})}_remove(e){return f(this,null,function*(){delete this.storage[e]})}_addListener(e,i){}_removeListener(e,i){}}return n.type="NONE",n})(),Dl=t1;function ho(n,t,e){return`firebase:${n}:${t}:${e}`}var vo=class n{constructor(t,e,i){this.persistence=t,this.auth=e,this.userKey=i;let{config:r,name:s}=this.auth;this.fullUserKey=ho(this.userKey,r.apiKey,s),this.fullPersistenceKey=ho("persistence",r.apiKey,s),this.boundEventHandler=e._onStorageEvent.bind(e),this.persistence._addListener(this.fullUserKey,this.boundEventHandler)}setCurrentUser(t){return this.persistence._set(this.fullUserKey,t.toJSON())}getCurrentUser(){return f(this,null,function*(){let t=yield this.persistence._get(this.fullUserKey);return t?bi._fromJSON(this.auth,t):null})}removeCurrentUser(){return this.persistence._remove(this.fullUserKey)}savePersistenceForRedirect(){return this.persistence._set(this.fullPersistenceKey,this.persistence.type)}setPersistence(t){return f(this,null,function*(){if(this.persistence===t)return;let e=yield this.getCurrentUser();if(yield this.removeCurrentUser(),this.persistence=t,e)return this.setCurrentUser(e)})}delete(){this.persistence._removeListener(this.fullUserKey,this.boundEventHandler)}static create(t,e,i="authUser"){return f(this,null,function*(){if(!e.length)return new n(xt(Dl),t,i);let r=(yield Promise.all(e.map(l=>f(this,null,function*(){if(yield l._isAvailable())return l})))).filter(l=>l),s=r[0]||xt(Dl),o=ho(i,t.config.apiKey,t.name),c=null;for(let l of e)try{let u=yield l._get(o);if(u){let d=bi._fromJSON(t,u);l!==s&&(c=d),s=l;break}}catch{}let a=r.filter(l=>l._shouldAllowMigration);return!s._shouldAllowMigration||!a.length?new n(s,t,i):(s=a[0],c&&(yield s._set(o,c.toJSON())),yield Promise.all(e.map(l=>f(this,null,function*(){if(l!==s)try{yield l._remove(o)}catch{}}))),new n(s,t,i))})}};function dp(n){let t=n.toLowerCase();if(t.includes("opera/")||t.includes("opr/")||t.includes("opios/"))return"Opera";if(Pp(t))return"IEMobile";if(t.includes("msie")||t.includes("trident/"))return"IE";if(t.includes("edge/"))return"Edge";if(Op(t))return"Firefox";if(t.includes("silk/"))return"Silk";if(kp(t))return"Blackberry";if(xp(t))return"Webos";if(Rp(t))return"Safari";if((t.includes("chrome/")||Mp(t))&&!t.includes("edge/"))return"Chrome";if(Np(t))return"Android";{let e=/([a-zA-Z\d\.]+)\/[a-zA-Z\d\.]*$/,i=n.match(e);if(i?.length===2)return i[1]}return"Other"}function Op(n=ve()){return/firefox\//i.test(n)}function Rp(n=ve()){let t=n.toLowerCase();return t.includes("safari/")&&!t.includes("chrome/")&&!t.includes("crios/")&&!t.includes("android")}function Mp(n=ve()){return/crios\//i.test(n)}function Pp(n=ve()){return/iemobile/i.test(n)}function Np(n=ve()){return/android/i.test(n)}function kp(n=ve()){return/blackberry/i.test(n)}function xp(n=ve()){return/webos/i.test(n)}function Ul(n=ve()){return/iphone|ipad|ipod/i.test(n)||/macintosh/i.test(n)&&/mobile/i.test(n)}function n1(n=ve()){var t;return Ul(n)&&!!(!((t=window.navigator)===null||t===void 0)&&t.standalone)}function i1(){return $f()&&document.documentMode===10}function Fp(n=ve()){return Ul(n)||Np(n)||xp(n)||kp(n)||/windows phone/i.test(n)||Pp(n)}function Lp(n,t=[]){let e;switch(n){case"Browser":e=dp(ve());break;case"Worker":e=`${dp(ve())}-${n}`;break;default:e=n}let i=t.length?t.join(","):"FirebaseCore-web";return`${e}/JsCore/${mi}/${i}`}var Tl=class{constructor(t){this.auth=t,this.queue=[]}pushCallback(t,e){let i=s=>new Promise((o,c)=>{try{let a=t(s);o(a)}catch(a){c(a)}});i.onAbort=e,this.queue.push(i);let r=this.queue.length-1;return()=>{this.queue[r]=()=>Promise.resolve()}}runMiddleware(t){return f(this,null,function*(){if(this.auth.currentUser===t)return;let e=[];try{for(let i of this.queue)yield i(t),i.onAbort&&e.push(i.onAbort)}catch(i){e.reverse();for(let r of e)try{r()}catch{}throw this.auth._errorFactory.create("login-blocked",{originalMessage:i?.message})}})}};function r1(e){return f(this,arguments,function*(n,t={}){return wi(n,"GET","/v2/passwordPolicy",Fl(n,t))})}var s1=6,El=class{constructor(t){var e,i,r,s;let o=t.customStrengthOptions;this.customStrengthOptions={},this.customStrengthOptions.minPasswordLength=(e=o.minPasswordLength)!==null&&e!==void 0?e:s1,o.maxPasswordLength&&(this.customStrengthOptions.maxPasswordLength=o.maxPasswordLength),o.containsLowercaseCharacter!==void 0&&(this.customStrengthOptions.containsLowercaseLetter=o.containsLowercaseCharacter),o.containsUppercaseCharacter!==void 0&&(this.customStrengthOptions.containsUppercaseLetter=o.containsUppercaseCharacter),o.containsNumericCharacter!==void 0&&(this.customStrengthOptions.containsNumericCharacter=o.containsNumericCharacter),o.containsNonAlphanumericCharacter!==void 0&&(this.customStrengthOptions.containsNonAlphanumericCharacter=o.containsNonAlphanumericCharacter),this.enforcementState=t.enforcementState,this.enforcementState==="ENFORCEMENT_STATE_UNSPECIFIED"&&(this.enforcementState="OFF"),this.allowedNonAlphanumericCharacters=(r=(i=t.allowedNonAlphanumericCharacters)===null||i===void 0?void 0:i.join(""))!==null&&r!==void 0?r:"",this.forceUpgradeOnSignin=(s=t.forceUpgradeOnSignin)!==null&&s!==void 0?s:!1,this.schemaVersion=t.schemaVersion}validatePassword(t){var e,i,r,s,o,c;let a={isValid:!0,passwordPolicy:this};return this.validatePasswordLengthOptions(t,a),this.validatePasswordCharacterOptions(t,a),a.isValid&&(a.isValid=(e=a.meetsMinPasswordLength)!==null&&e!==void 0?e:!0),a.isValid&&(a.isValid=(i=a.meetsMaxPasswordLength)!==null&&i!==void 0?i:!0),a.isValid&&(a.isValid=(r=a.containsLowercaseLetter)!==null&&r!==void 0?r:!0),a.isValid&&(a.isValid=(s=a.containsUppercaseLetter)!==null&&s!==void 0?s:!0),a.isValid&&(a.isValid=(o=a.containsNumericCharacter)!==null&&o!==void 0?o:!0),a.isValid&&(a.isValid=(c=a.containsNonAlphanumericCharacter)!==null&&c!==void 0?c:!0),a}validatePasswordLengthOptions(t,e){let i=this.customStrengthOptions.minPasswordLength,r=this.customStrengthOptions.maxPasswordLength;i&&(e.meetsMinPasswordLength=t.length>=i),r&&(e.meetsMaxPasswordLength=t.length<=r)}validatePasswordCharacterOptions(t,e){this.updatePasswordCharacterOptionsStatuses(e,!1,!1,!1,!1);let i;for(let r=0;r<t.length;r++)i=t.charAt(r),this.updatePasswordCharacterOptionsStatuses(e,i>="a"&&i<="z",i>="A"&&i<="Z",i>="0"&&i<="9",this.allowedNonAlphanumericCharacters.includes(i))}updatePasswordCharacterOptionsStatuses(t,e,i,r,s){this.customStrengthOptions.containsLowercaseLetter&&(t.containsLowercaseLetter||(t.containsLowercaseLetter=e)),this.customStrengthOptions.containsUppercaseLetter&&(t.containsUppercaseLetter||(t.containsUppercaseLetter=i)),this.customStrengthOptions.containsNumericCharacter&&(t.containsNumericCharacter||(t.containsNumericCharacter=r)),this.customStrengthOptions.containsNonAlphanumericCharacter&&(t.containsNonAlphanumericCharacter||(t.containsNonAlphanumericCharacter=s))}};var Cl=class{constructor(t,e,i,r){this.app=t,this.heartbeatServiceProvider=e,this.appCheckServiceProvider=i,this.config=r,this.currentUser=null,this.emulatorConfig=null,this.operations=Promise.resolve(),this.authStateSubscription=new yo(this),this.idTokenSubscription=new yo(this),this.beforeStateQueue=new Tl(this),this.redirectUser=null,this.isProactiveRefreshEnabled=!1,this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION=1,this._canInitEmulator=!0,this._isInitialized=!1,this._deleted=!1,this._initializationPromise=null,this._popupRedirectResolver=null,this._errorFactory=Ep,this._agentRecaptchaConfig=null,this._tenantRecaptchaConfigs={},this._projectPasswordPolicy=null,this._tenantPasswordPolicies={},this.lastNotifiedUid=void 0,this.languageCode=null,this.tenantId=null,this.settings={appVerificationDisabledForTesting:!1},this.frameworks=[],this.name=t.name,this.clientVersion=r.sdkClientVersion}_initializeWithPersistence(t,e){return e&&(this._popupRedirectResolver=xt(e)),this._initializationPromise=this.queue(()=>f(this,null,function*(){var i,r;if(!this._deleted&&(this.persistenceManager=yield vo.create(this,t),!this._deleted)){if(!((i=this._popupRedirectResolver)===null||i===void 0)&&i._shouldInitProactively)try{yield this._popupRedirectResolver._initialize(this)}catch{}yield this.initializeCurrentUser(e),this.lastNotifiedUid=((r=this.currentUser)===null||r===void 0?void 0:r.uid)||null,!this._deleted&&(this._isInitialized=!0)}})),this._initializationPromise}_onStorageEvent(){return f(this,null,function*(){if(this._deleted)return;let t=yield this.assertedPersistence.getCurrentUser();if(!(!this.currentUser&&!t)){if(this.currentUser&&t&&this.currentUser.uid===t.uid){this._currentUser._assign(t),yield this.currentUser.getIdToken();return}yield this._updateCurrentUser(t,!0)}})}initializeCurrentUserFromIdToken(t){return f(this,null,function*(){try{let e=yield Ip(this,{idToken:t}),i=yield bi._fromGetAccountInfoResponse(this,e,t);yield this.directlySetCurrentUser(i)}catch(e){console.warn("FirebaseServerApp could not login user with provided authIdToken: ",e),yield this.directlySetCurrentUser(null)}})}initializeCurrentUser(t){return f(this,null,function*(){var e;if(mt(this.app)){let o=this.app.settings.authIdToken;return o?new Promise(c=>{setTimeout(()=>this.initializeCurrentUserFromIdToken(o).then(c,c))}):this.directlySetCurrentUser(null)}let i=yield this.assertedPersistence.getCurrentUser(),r=i,s=!1;if(t&&this.config.authDomain){yield this.getOrInitRedirectPersistenceManager();let o=(e=this.redirectUser)===null||e===void 0?void 0:e._redirectEventId,c=r?._redirectEventId,a=yield this.tryRedirectSignIn(t);(!o||o===c)&&a?.user&&(r=a.user,s=!0)}if(!r)return this.directlySetCurrentUser(null);if(!r._redirectEventId){if(s)try{yield this.beforeStateQueue.runMiddleware(r)}catch(o){r=i,this._popupRedirectResolver._overrideRedirectResult(this,()=>Promise.reject(o))}return r?this.reloadAndSetCurrentUserOrClear(r):this.directlySetCurrentUser(null)}return T(this._popupRedirectResolver,this,"argument-error"),yield this.getOrInitRedirectPersistenceManager(),this.redirectUser&&this.redirectUser._redirectEventId===r._redirectEventId?this.directlySetCurrentUser(r):this.reloadAndSetCurrentUserOrClear(r)})}tryRedirectSignIn(t){return f(this,null,function*(){let e=null;try{e=yield this._popupRedirectResolver._completeRedirectFn(this,t,!0)}catch{yield this._setRedirectUser(null)}return e})}reloadAndSetCurrentUserOrClear(t){return f(this,null,function*(){try{yield _o(t)}catch(e){if(e?.code!=="auth/network-request-failed")return this.directlySetCurrentUser(null)}return this.directlySetCurrentUser(t)})}useDeviceLanguage(){this.languageCode=Wb()}_delete(){return f(this,null,function*(){this._deleted=!0})}updateCurrentUser(t){return f(this,null,function*(){if(mt(this.app))return Promise.reject(Rn(this));let e=t?Sn(t):null;return e&&T(e.auth.config.apiKey===this.config.apiKey,this,"invalid-user-token"),this._updateCurrentUser(e&&e._clone(this))})}_updateCurrentUser(t,e=!1){return f(this,null,function*(){if(!this._deleted)return t&&T(this.tenantId===t.tenantId,this,"tenant-id-mismatch"),e||(yield this.beforeStateQueue.runMiddleware(t)),this.queue(()=>f(this,null,function*(){yield this.directlySetCurrentUser(t),this.notifyAuthListeners()}))})}signOut(){return f(this,null,function*(){return mt(this.app)?Promise.reject(Rn(this)):(yield this.beforeStateQueue.runMiddleware(null),(this.redirectPersistenceManager||this._popupRedirectResolver)&&(yield this._setRedirectUser(null)),this._updateCurrentUser(null,!0))})}setPersistence(t){return mt(this.app)?Promise.reject(Rn(this)):this.queue(()=>f(this,null,function*(){yield this.assertedPersistence.setPersistence(xt(t))}))}_getRecaptchaConfig(){return this.tenantId==null?this._agentRecaptchaConfig:this._tenantRecaptchaConfigs[this.tenantId]}validatePassword(t){return f(this,null,function*(){this._getPasswordPolicyInternal()||(yield this._updatePasswordPolicy());let e=this._getPasswordPolicyInternal();return e.schemaVersion!==this.EXPECTED_PASSWORD_POLICY_SCHEMA_VERSION?Promise.reject(this._errorFactory.create("unsupported-password-policy-schema-version",{})):e.validatePassword(t)})}_getPasswordPolicyInternal(){return this.tenantId===null?this._projectPasswordPolicy:this._tenantPasswordPolicies[this.tenantId]}_updatePasswordPolicy(){return f(this,null,function*(){let t=yield r1(this),e=new El(t);this.tenantId===null?this._projectPasswordPolicy=e:this._tenantPasswordPolicies[this.tenantId]=e})}_getPersistence(){return this.assertedPersistence.persistence.type}_updateErrorMap(t){this._errorFactory=new Pt("auth","Firebase",t())}onAuthStateChanged(t,e,i){return this.registerStateListener(this.authStateSubscription,t,e,i)}beforeAuthStateChanged(t,e){return this.beforeStateQueue.pushCallback(t,e)}onIdTokenChanged(t,e,i){return this.registerStateListener(this.idTokenSubscription,t,e,i)}authStateReady(){return new Promise((t,e)=>{if(this.currentUser)t();else{let i=this.onAuthStateChanged(()=>{i(),t()},e)}})}revokeAccessToken(t){return f(this,null,function*(){if(this.currentUser){let e=yield this.currentUser.getIdToken(),i={providerId:"apple.com",tokenType:"ACCESS_TOKEN",token:t,idToken:e};this.tenantId!=null&&(i.tenantId=this.tenantId),yield e1(this,i)}})}toJSON(){var t;return{apiKey:this.config.apiKey,authDomain:this.config.authDomain,appName:this.name,currentUser:(t=this._currentUser)===null||t===void 0?void 0:t.toJSON()}}_setRedirectUser(t,e){return f(this,null,function*(){let i=yield this.getOrInitRedirectPersistenceManager(e);return t===null?i.removeCurrentUser():i.setCurrentUser(t)})}getOrInitRedirectPersistenceManager(t){return f(this,null,function*(){if(!this.redirectPersistenceManager){let e=t&&xt(t)||this._popupRedirectResolver;T(e,this,"argument-error"),this.redirectPersistenceManager=yield vo.create(this,[xt(e._redirectPersistence)],"redirectUser"),this.redirectUser=yield this.redirectPersistenceManager.getCurrentUser()}return this.redirectPersistenceManager})}_redirectUserForId(t){return f(this,null,function*(){var e,i;return this._isInitialized&&(yield this.queue(()=>f(this,null,function*(){}))),((e=this._currentUser)===null||e===void 0?void 0:e._redirectEventId)===t?this._currentUser:((i=this.redirectUser)===null||i===void 0?void 0:i._redirectEventId)===t?this.redirectUser:null})}_persistUserIfCurrent(t){return f(this,null,function*(){if(t===this.currentUser)return this.queue(()=>f(this,null,function*(){return this.directlySetCurrentUser(t)}))})}_notifyListenersIfCurrent(t){t===this.currentUser&&this.notifyAuthListeners()}_key(){return`${this.config.authDomain}:${this.config.apiKey}:${this.name}`}_startProactiveRefresh(){this.isProactiveRefreshEnabled=!0,this.currentUser&&this._currentUser._startProactiveRefresh()}_stopProactiveRefresh(){this.isProactiveRefreshEnabled=!1,this.currentUser&&this._currentUser._stopProactiveRefresh()}get _currentUser(){return this.currentUser}notifyAuthListeners(){var t,e;if(!this._isInitialized)return;this.idTokenSubscription.next(this.currentUser);let i=(e=(t=this.currentUser)===null||t===void 0?void 0:t.uid)!==null&&e!==void 0?e:null;this.lastNotifiedUid!==i&&(this.lastNotifiedUid=i,this.authStateSubscription.next(this.currentUser))}registerStateListener(t,e,i,r){if(this._deleted)return()=>{};let s=typeof e=="function"?e:e.next.bind(e),o=!1,c=this._isInitialized?Promise.resolve():this._initializationPromise;if(T(c,this,"internal-error"),c.then(()=>{o||s(this.currentUser)}),typeof e=="function"){let a=t.addObserver(e,i,r);return()=>{o=!0,a()}}else{let a=t.addObserver(e);return()=>{o=!0,a()}}}directlySetCurrentUser(t){return f(this,null,function*(){this.currentUser&&this.currentUser!==t&&this._currentUser._stopProactiveRefresh(),t&&this.isProactiveRefreshEnabled&&t._startProactiveRefresh(),this.currentUser=t,t?yield this.assertedPersistence.setCurrentUser(t):yield this.assertedPersistence.removeCurrentUser()})}queue(t){return this.operations=this.operations.then(t,t),this.operations}get assertedPersistence(){return T(this.persistenceManager,this,"internal-error"),this.persistenceManager}_logFramework(t){!t||this.frameworks.includes(t)||(this.frameworks.push(t),this.frameworks.sort(),this.clientVersion=Lp(this.config.clientPlatform,this._getFrameworks()))}_getFrameworks(){return this.frameworks}_getAdditionalHeaders(){return f(this,null,function*(){var t;let e={"X-Client-Version":this.clientVersion};this.app.options.appId&&(e["X-Firebase-gmpid"]=this.app.options.appId);let i=yield(t=this.heartbeatServiceProvider.getImmediate({optional:!0}))===null||t===void 0?void 0:t.getHeartbeatsHeader();i&&(e["X-Firebase-Client"]=i);let r=yield this._getAppCheckToken();return r&&(e["X-Firebase-AppCheck"]=r),e})}_getAppCheckToken(){return f(this,null,function*(){var t;let e=yield(t=this.appCheckServiceProvider.getImmediate({optional:!0}))===null||t===void 0?void 0:t.getToken();return e?.error&&$b(`Error while retrieving App Check token: ${e.error}`),e?.token})}};function Io(n){return Sn(n)}var yo=class{constructor(t){this.auth=t,this.observer=null,this.addObserver=Wf(e=>this.observer=e)}get next(){return T(this.observer,this.auth,"internal-error"),this.observer.next.bind(this.observer)}};var jl={loadJS(){return f(this,null,function*(){throw new Error("Unable to load external scripts")})},recaptchaV2Script:"",recaptchaEnterpriseScript:"",gapiScript:""};function o1(n){jl=n}function a1(n){return jl.loadJS(n)}function c1(){return jl.gapiScript}function Bp(n){return`__${n}${Math.floor(Math.random()*1e6)}`}function $l(n,t){let e=hl(n,"auth");if(e.isInitialized()){let r=e.getImmediate(),s=e.getOptions();if(hi(s,t??{}))return r;vt(r,"already-initialized")}return e.initialize({options:t})}function l1(n,t){let e=t?.persistence||[],i=(Array.isArray(e)?e:[e]).map(xt);t?.errorMap&&n._updateErrorMap(t.errorMap),n._initializeWithPersistence(i,t?.popupRedirectResolver)}function Hl(n,t,e){let i=Io(n);T(i._canInitEmulator,i,"emulator-config-failed"),T(/^https?:\/\//.test(t),i,"invalid-emulator-scheme");let r=!!e?.disableWarnings,s=Vp(t),{host:o,port:c}=u1(t),a=c===null?"":`:${c}`;i.config.emulator={url:`${s}//${o}${a}/`},i.settings.appVerificationDisabledForTesting=!0,i.emulatorConfig=Object.freeze({host:o,port:c,protocol:s.replace(":",""),options:Object.freeze({disableWarnings:r})}),r||d1()}function Vp(n){let t=n.indexOf(":");return t<0?"":n.substr(0,t+1)}function u1(n){let t=Vp(n),e=/(\/\/)?([^?#/]+)/.exec(n.substr(t.length));if(!e)return{host:"",port:null};let i=e[2].split("@").pop()||"",r=/^(\[[^\]]+\])(:|$)/.exec(i);if(r){let s=r[1];return{host:s,port:hp(i.substr(s.length+1))}}else{let[s,o]=i.split(":");return{host:s,port:hp(o)}}}function hp(n){if(!n)return null;let t=Number(n);return isNaN(t)?null:t}function d1(){function n(){let t=document.createElement("p"),e=t.style;t.innerText="Running in emulator mode. Do not use with production credentials.",e.position="fixed",e.width="100%",e.backgroundColor="#ffffff",e.border=".1em solid #000000",e.color="#b50000",e.bottom="0px",e.left="0px",e.margin="0px",e.zIndex="10000",e.textAlign="center",t.classList.add("firebase-emulator-warning"),document.body.appendChild(t)}typeof console<"u"&&typeof console.info=="function"&&console.info("WARNING: You are using the Auth Emulator, which is intended for local testing only. Do not use with production credentials."),typeof window<"u"&&typeof document<"u"&&(document.readyState==="loading"?window.addEventListener("DOMContentLoaded",n):n())}var Pr=class{constructor(t,e){this.providerId=t,this.signInMethod=e}toJSON(){return kt("not implemented")}_getIdTokenResponse(t){return kt("not implemented")}_linkToIdToken(t,e){return kt("not implemented")}_getReauthenticationResolver(t){return kt("not implemented")}};function yi(n,t){return f(this,null,function*(){return Kb(n,"POST","/v1/accounts:signInWithIdp",Fl(n,t))})}var h1="http://localhost",bo=class n extends Pr{constructor(){super(...arguments),this.pendingToken=null}static _fromParams(t){let e=new n(t.providerId,t.signInMethod);return t.idToken||t.accessToken?(t.idToken&&(e.idToken=t.idToken),t.accessToken&&(e.accessToken=t.accessToken),t.nonce&&!t.pendingToken&&(e.nonce=t.nonce),t.pendingToken&&(e.pendingToken=t.pendingToken)):t.oauthToken&&t.oauthTokenSecret?(e.accessToken=t.oauthToken,e.secret=t.oauthTokenSecret):vt("argument-error"),e}toJSON(){return{idToken:this.idToken,accessToken:this.accessToken,secret:this.secret,nonce:this.nonce,pendingToken:this.pendingToken,providerId:this.providerId,signInMethod:this.signInMethod}}static fromJSON(t){let e=typeof t=="string"?JSON.parse(t):t,{providerId:i,signInMethod:r}=e,s=Hr(e,["providerId","signInMethod"]);if(!i||!r)return null;let o=new n(i,r);return o.idToken=s.idToken||void 0,o.accessToken=s.accessToken||void 0,o.secret=s.secret,o.nonce=s.nonce,o.pendingToken=s.pendingToken||null,o}_getIdTokenResponse(t){let e=this.buildRequest();return yi(t,e)}_linkToIdToken(t,e){let i=this.buildRequest();return i.idToken=e,yi(t,i)}_getReauthenticationResolver(t){let e=this.buildRequest();return e.autoCreate=!1,yi(t,e)}buildRequest(){let t={requestUri:h1,returnSecureToken:!0};if(this.pendingToken)t.pendingToken=this.pendingToken;else{let e={};this.idToken&&(e.id_token=this.idToken),this.accessToken&&(e.access_token=this.accessToken),this.secret&&(e.oauth_token_secret=this.secret),e.providerId=this.providerId,this.nonce&&!this.pendingToken&&(e.nonce=this.nonce),t.postBody=fi(e)}return t}};var Nr=class{constructor(t){this.providerId=t,this.defaultLanguageCode=null,this.customParameters={}}setDefaultLanguage(t){this.defaultLanguageCode=t}setCustomParameters(t){return this.customParameters=t,this}getCustomParameters(){return this.customParameters}};var wo=class extends Nr{constructor(){super(...arguments),this.scopes=[]}addScope(t){return this.scopes.includes(t)||this.scopes.push(t),this}getScopes(){return[...this.scopes]}};var Fr=(()=>{class n extends wo{constructor(){super("google.com"),this.addScope("profile")}static credential(e,i){return bo._fromParams({providerId:n.PROVIDER_ID,signInMethod:n.GOOGLE_SIGN_IN_METHOD,idToken:e,accessToken:i})}static credentialFromResult(e){return n.credentialFromTaggedObject(e)}static credentialFromError(e){return n.credentialFromTaggedObject(e.customData||{})}static credentialFromTaggedObject({_tokenResponse:e}){if(!e)return null;let{oauthIdToken:i,oauthAccessToken:r}=e;if(!i&&!r)return null;try{return n.credential(i,r)}catch{return null}}}n.GOOGLE_SIGN_IN_METHOD="google.com",n.PROVIDER_ID="google.com";return n})();var kr=class n{constructor(t){this.user=t.user,this.providerId=t.providerId,this._tokenResponse=t._tokenResponse,this.operationType=t.operationType}static _fromIdTokenResponse(t,e,i,r=!1){return f(this,null,function*(){let s=yield bi._fromIdTokenResponse(t,i,r),o=fp(i);return new n({user:s,providerId:o,_tokenResponse:i,operationType:e})})}static _forOperation(t,e,i){return f(this,null,function*(){yield t._updateTokensIfNecessary(i,!0);let r=fp(i);return new n({user:t,providerId:r,_tokenResponse:i,operationType:e})})}};function fp(n){return n.providerId?n.providerId:"phoneNumber"in n?"phone":null}var Sl=class n extends nt{constructor(t,e,i,r){var s;super(e.code,e.message),this.operationType=i,this.user=r,Object.setPrototypeOf(this,n.prototype),this.customData={appName:t.name,tenantId:(s=t.tenantId)!==null&&s!==void 0?s:void 0,_serverResponse:e.customData._serverResponse,operationType:i}}static _fromErrorAndOperation(t,e,i,r){return new n(t,e,i,r)}};function Up(n,t,e,i){return(t==="reauthenticate"?e._getReauthenticationResolver(n):e._getIdTokenResponse(n)).catch(s=>{throw s.code==="auth/multi-factor-auth-required"?Sl._fromErrorAndOperation(n,s,t,i):s})}function f1(n,t,e=!1){return f(this,null,function*(){let i=yield Rr(n,t._linkToIdToken(n.auth,yield n.getIdToken()),e);return kr._forOperation(n,"link",i)})}function p1(n,t,e=!1){return f(this,null,function*(){let{auth:i}=n;if(mt(i.app))return Promise.reject(Rn(i));let r="reauthenticate";try{let s=yield Rr(n,Up(i,r,t,n),e);T(s.idToken,i,"internal-error");let o=Bl(s.idToken);T(o,i,"internal-error");let{sub:c}=o;return T(n.uid===c,i,"user-mismatch"),kr._forOperation(n,r,s)}catch(s){throw s?.code==="auth/user-not-found"&&vt(i,"user-mismatch"),s}})}function g1(n,t,e=!1){return f(this,null,function*(){if(mt(n.app))return Promise.reject(Rn(n));let i="signIn",r=yield Up(n,i,t),s=yield kr._fromIdTokenResponse(n,i,r);return e||(yield n._updateCurrentUser(s.user)),s})}function Lr(n,t,e,i){return Sn(n).onIdTokenChanged(t,e,i)}function Gl(n,t,e){return Sn(n).beforeAuthStateChanged(t,e)}var Do="__sak";var To=class{constructor(t,e){this.storageRetriever=t,this.type=e}_isAvailable(){try{return this.storage?(this.storage.setItem(Do,"1"),this.storage.removeItem(Do),Promise.resolve(!0)):Promise.resolve(!1)}catch{return Promise.resolve(!1)}}_set(t,e){return this.storage.setItem(t,JSON.stringify(e)),Promise.resolve()}_get(t){let e=this.storage.getItem(t);return Promise.resolve(e?JSON.parse(e):null)}_remove(t){return this.storage.removeItem(t),Promise.resolve()}get storage(){return this.storageRetriever()}};var m1=1e3,_1=10,v1=(()=>{class n extends To{constructor(){super(()=>window.localStorage,"LOCAL"),this.boundEventHandler=(e,i)=>this.onStorageEvent(e,i),this.listeners={},this.localCache={},this.pollTimer=null,this.fallbackToPolling=Fp(),this._shouldAllowMigration=!0}forAllChangedKeys(e){for(let i of Object.keys(this.listeners)){let r=this.storage.getItem(i),s=this.localCache[i];r!==s&&e(i,s,r)}}onStorageEvent(e,i=!1){if(!e.key){this.forAllChangedKeys((c,a,l)=>{this.notifyListeners(c,l)});return}let r=e.key;i?this.detachListener():this.stopPolling();let s=()=>{let c=this.storage.getItem(r);!i&&this.localCache[r]===c||this.notifyListeners(r,c)},o=this.storage.getItem(r);i1()&&o!==e.newValue&&e.newValue!==e.oldValue?setTimeout(s,_1):s()}notifyListeners(e,i){this.localCache[e]=i;let r=this.listeners[e];if(r)for(let s of Array.from(r))s(i&&JSON.parse(i))}startPolling(){this.stopPolling(),this.pollTimer=setInterval(()=>{this.forAllChangedKeys((e,i,r)=>{this.onStorageEvent(new StorageEvent("storage",{key:e,oldValue:i,newValue:r}),!0)})},m1)}stopPolling(){this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null)}attachListener(){window.addEventListener("storage",this.boundEventHandler)}detachListener(){window.removeEventListener("storage",this.boundEventHandler)}_addListener(e,i){Object.keys(this.listeners).length===0&&(this.fallbackToPolling?this.startPolling():this.attachListener()),this.listeners[e]||(this.listeners[e]=new Set,this.localCache[e]=this.storage.getItem(e)),this.listeners[e].add(i)}_removeListener(e,i){this.listeners[e]&&(this.listeners[e].delete(i),this.listeners[e].size===0&&delete this.listeners[e]),Object.keys(this.listeners).length===0&&(this.detachListener(),this.stopPolling())}_set(e,i){return f(this,null,function*(){yield ln(n.prototype,this,"_set").call(this,e,i),this.localCache[e]=JSON.stringify(i)})}_get(e){return f(this,null,function*(){let i=yield ln(n.prototype,this,"_get").call(this,e);return this.localCache[e]=JSON.stringify(i),i})}_remove(e){return f(this,null,function*(){yield ln(n.prototype,this,"_remove").call(this,e),delete this.localCache[e]})}}return n.type="LOCAL",n})(),jp=v1;var y1=(()=>{class n extends To{constructor(){super(()=>window.sessionStorage,"SESSION")}_addListener(e,i){}_removeListener(e,i){}}return n.type="SESSION",n})(),zl=y1;function b1(n){return Promise.all(n.map(t=>f(this,null,function*(){try{return{fulfilled:!0,value:yield t}}catch(e){return{fulfilled:!1,reason:e}}})))}var w1=(()=>{class n{constructor(e){this.eventTarget=e,this.handlersMap={},this.boundEventHandler=this.handleEvent.bind(this)}static _getInstance(e){let i=this.receivers.find(s=>s.isListeningto(e));if(i)return i;let r=new n(e);return this.receivers.push(r),r}isListeningto(e){return this.eventTarget===e}handleEvent(e){return f(this,null,function*(){let i=e,{eventId:r,eventType:s,data:o}=i.data,c=this.handlersMap[s];if(!c?.size)return;i.ports[0].postMessage({status:"ack",eventId:r,eventType:s});let a=Array.from(c).map(u=>f(this,null,function*(){return u(i.origin,o)})),l=yield b1(a);i.ports[0].postMessage({status:"done",eventId:r,eventType:s,response:l})})}_subscribe(e,i){Object.keys(this.handlersMap).length===0&&this.eventTarget.addEventListener("message",this.boundEventHandler),this.handlersMap[e]||(this.handlersMap[e]=new Set),this.handlersMap[e].add(i)}_unsubscribe(e,i){this.handlersMap[e]&&i&&this.handlersMap[e].delete(i),(!i||this.handlersMap[e].size===0)&&delete this.handlersMap[e],Object.keys(this.handlersMap).length===0&&this.eventTarget.removeEventListener("message",this.boundEventHandler)}}n.receivers=[];return n})();function Wl(n="",t=10){let e="";for(let i=0;i<t;i++)e+=Math.floor(Math.random()*10);return n+e}var Il=class{constructor(t){this.target=t,this.handlers=new Set}removeMessageHandler(t){t.messageChannel&&(t.messageChannel.port1.removeEventListener("message",t.onMessage),t.messageChannel.port1.close()),this.handlers.delete(t)}_send(t,e,i=50){return f(this,null,function*(){let r=typeof MessageChannel<"u"?new MessageChannel:null;if(!r)throw new Error("connection_unavailable");let s,o;return new Promise((c,a)=>{let l=Wl("",20);r.port1.start();let u=setTimeout(()=>{a(new Error("unsupported_event"))},i);o={messageChannel:r,onMessage(d){let p=d;if(p.data.eventId===l)switch(p.data.status){case"ack":clearTimeout(u),s=setTimeout(()=>{a(new Error("timeout"))},3e3);break;case"done":clearTimeout(s),c(p.data.response);break;default:clearTimeout(u),clearTimeout(s),a(new Error("invalid_response"));break}}},this.handlers.add(o),r.port1.addEventListener("message",o.onMessage),this.target.postMessage({eventType:t,eventId:l,data:e},[r.port2])}).finally(()=>{o&&this.removeMessageHandler(o)})})}};function _t(){return window}function D1(n){_t().location.href=n}function $p(){return typeof _t().WorkerGlobalScope<"u"&&typeof _t().importScripts=="function"}function T1(){return f(this,null,function*(){if(!navigator?.serviceWorker)return null;try{return(yield navigator.serviceWorker.ready).active}catch{return null}})}function E1(){var n;return((n=navigator?.serviceWorker)===null||n===void 0?void 0:n.controller)||null}function C1(){return $p()?self:null}var Hp="firebaseLocalStorageDb",S1=1,Eo="firebaseLocalStorage",Gp="fbase_key",Pn=class{constructor(t){this.request=t}toPromise(){return new Promise((t,e)=>{this.request.addEventListener("success",()=>{t(this.request.result)}),this.request.addEventListener("error",()=>{e(this.request.error)})})}};function Ao(n,t){return n.transaction([Eo],t?"readwrite":"readonly").objectStore(Eo)}function I1(){let n=indexedDB.deleteDatabase(Hp);return new Pn(n).toPromise()}function Al(){let n=indexedDB.open(Hp,S1);return new Promise((t,e)=>{n.addEventListener("error",()=>{e(n.error)}),n.addEventListener("upgradeneeded",()=>{let i=n.result;try{i.createObjectStore(Eo,{keyPath:Gp})}catch(r){e(r)}}),n.addEventListener("success",()=>f(this,null,function*(){let i=n.result;i.objectStoreNames.contains(Eo)?t(i):(i.close(),yield I1(),t(yield Al()))}))})}function pp(n,t,e){return f(this,null,function*(){let i=Ao(n,!0).put({[Gp]:t,value:e});return new Pn(i).toPromise()})}function A1(n,t){return f(this,null,function*(){let e=Ao(n,!1).get(t),i=yield new Pn(e).toPromise();return i===void 0?null:i.value})}function gp(n,t){let e=Ao(n,!0).delete(t);return new Pn(e).toPromise()}var O1=800,R1=3,M1=(()=>{class n{constructor(){this.type="LOCAL",this._shouldAllowMigration=!0,this.listeners={},this.localCache={},this.pollTimer=null,this.pendingWrites=0,this.receiver=null,this.sender=null,this.serviceWorkerReceiverAvailable=!1,this.activeServiceWorker=null,this._workerInitializationPromise=this.initializeServiceWorkerMessaging().then(()=>{},()=>{})}_openDb(){return f(this,null,function*(){return this.db?this.db:(this.db=yield Al(),this.db)})}_withRetries(e){return f(this,null,function*(){let i=0;for(;;)try{let r=yield this._openDb();return yield e(r)}catch(r){if(i++>R1)throw r;this.db&&(this.db.close(),this.db=void 0)}})}initializeServiceWorkerMessaging(){return f(this,null,function*(){return $p()?this.initializeReceiver():this.initializeSender()})}initializeReceiver(){return f(this,null,function*(){this.receiver=w1._getInstance(C1()),this.receiver._subscribe("keyChanged",(e,i)=>f(this,null,function*(){return{keyProcessed:(yield this._poll()).includes(i.key)}})),this.receiver._subscribe("ping",(e,i)=>f(this,null,function*(){return["keyChanged"]}))})}initializeSender(){return f(this,null,function*(){var e,i;if(this.activeServiceWorker=yield T1(),!this.activeServiceWorker)return;this.sender=new Il(this.activeServiceWorker);let r=yield this.sender._send("ping",{},800);r&&!((e=r[0])===null||e===void 0)&&e.fulfilled&&!((i=r[0])===null||i===void 0)&&i.value.includes("keyChanged")&&(this.serviceWorkerReceiverAvailable=!0)})}notifyServiceWorker(e){return f(this,null,function*(){if(!(!this.sender||!this.activeServiceWorker||E1()!==this.activeServiceWorker))try{yield this.sender._send("keyChanged",{key:e},this.serviceWorkerReceiverAvailable?800:50)}catch{}})}_isAvailable(){return f(this,null,function*(){try{if(!indexedDB)return!1;let e=yield Al();return yield pp(e,Do,"1"),yield gp(e,Do),!0}catch{}return!1})}_withPendingWrite(e){return f(this,null,function*(){this.pendingWrites++;try{yield e()}finally{this.pendingWrites--}})}_set(e,i){return f(this,null,function*(){return this._withPendingWrite(()=>f(this,null,function*(){return yield this._withRetries(r=>pp(r,e,i)),this.localCache[e]=i,this.notifyServiceWorker(e)}))})}_get(e){return f(this,null,function*(){let i=yield this._withRetries(r=>A1(r,e));return this.localCache[e]=i,i})}_remove(e){return f(this,null,function*(){return this._withPendingWrite(()=>f(this,null,function*(){return yield this._withRetries(i=>gp(i,e)),delete this.localCache[e],this.notifyServiceWorker(e)}))})}_poll(){return f(this,null,function*(){let e=yield this._withRetries(s=>{let o=Ao(s,!1).getAll();return new Pn(o).toPromise()});if(!e)return[];if(this.pendingWrites!==0)return[];let i=[],r=new Set;if(e.length!==0)for(let{fbase_key:s,value:o}of e)r.add(s),JSON.stringify(this.localCache[s])!==JSON.stringify(o)&&(this.notifyListeners(s,o),i.push(s));for(let s of Object.keys(this.localCache))this.localCache[s]&&!r.has(s)&&(this.notifyListeners(s,null),i.push(s));return i})}notifyListeners(e,i){this.localCache[e]=i;let r=this.listeners[e];if(r)for(let s of Array.from(r))s(i)}startPolling(){this.stopPolling(),this.pollTimer=setInterval(()=>f(this,null,function*(){return this._poll()}),O1)}stopPolling(){this.pollTimer&&(clearInterval(this.pollTimer),this.pollTimer=null)}_addListener(e,i){Object.keys(this.listeners).length===0&&this.startPolling(),this.listeners[e]||(this.listeners[e]=new Set,this._get(e)),this.listeners[e].add(i)}_removeListener(e,i){this.listeners[e]&&(this.listeners[e].delete(i),this.listeners[e].size===0&&delete this.listeners[e]),Object.keys(this.listeners).length===0&&this.stopPolling()}}return n.type="LOCAL",n})(),zp=M1;var IR=Bp("rcb"),AR=new Mn(3e4,6e4);function Wp(n,t){return t?xt(t):(T(n._popupRedirectResolver,n,"argument-error"),n._popupRedirectResolver)}var xr=class extends Pr{constructor(t){super("custom","custom"),this.params=t}_getIdTokenResponse(t){return yi(t,this._buildIdpRequest())}_linkToIdToken(t,e){return yi(t,this._buildIdpRequest(e))}_getReauthenticationResolver(t){return yi(t,this._buildIdpRequest())}_buildIdpRequest(t){let e={requestUri:this.params.requestUri,sessionId:this.params.sessionId,postBody:this.params.postBody,tenantId:this.params.tenantId,pendingToken:this.params.pendingToken,returnSecureToken:!0,returnIdpCredential:!0};return t&&(e.idToken=t),e}};function P1(n){return g1(n.auth,new xr(n),n.bypassAuthState)}function N1(n){let{auth:t,user:e}=n;return T(e,t,"internal-error"),p1(e,new xr(n),n.bypassAuthState)}function k1(n){return f(this,null,function*(){let{auth:t,user:e}=n;return T(e,t,"internal-error"),f1(e,new xr(n),n.bypassAuthState)})}var Co=class{constructor(t,e,i,r,s=!1){this.auth=t,this.resolver=i,this.user=r,this.bypassAuthState=s,this.pendingPromise=null,this.eventManager=null,this.filter=Array.isArray(e)?e:[e]}execute(){return new Promise((t,e)=>f(this,null,function*(){this.pendingPromise={resolve:t,reject:e};try{this.eventManager=yield this.resolver._initialize(this.auth),yield this.onExecution(),this.eventManager.registerConsumer(this)}catch(i){this.reject(i)}}))}onAuthEvent(t){return f(this,null,function*(){let{urlResponse:e,sessionId:i,postBody:r,tenantId:s,error:o,type:c}=t;if(o){this.reject(o);return}let a={auth:this.auth,requestUri:e,sessionId:i,tenantId:s||void 0,postBody:r||void 0,user:this.user,bypassAuthState:this.bypassAuthState};try{this.resolve(yield this.getIdpTask(c)(a))}catch(l){this.reject(l)}})}onError(t){this.reject(t)}getIdpTask(t){switch(t){case"signInViaPopup":case"signInViaRedirect":return P1;case"linkViaPopup":case"linkViaRedirect":return k1;case"reauthViaPopup":case"reauthViaRedirect":return N1;default:vt(this.auth,"internal-error")}}resolve(t){Ft(this.pendingPromise,"Pending promise was never set"),this.pendingPromise.resolve(t),this.unregisterAndCleanUp()}reject(t){Ft(this.pendingPromise,"Pending promise was never set"),this.pendingPromise.reject(t),this.unregisterAndCleanUp()}unregisterAndCleanUp(){this.eventManager&&this.eventManager.unregisterConsumer(this),this.pendingPromise=null,this.cleanUp()}};var x1=new Mn(2e3,1e4);function ql(n,t,e){return f(this,null,function*(){if(mt(n.app))return Promise.reject(it(n,"operation-not-supported-in-this-environment"));let i=Io(n);Hb(n,t,Nr);let r=Wp(i,e);return new F1(i,"signInViaPopup",t,r).executeNotNull()})}var F1=(()=>{class n extends Co{constructor(e,i,r,s,o){super(e,i,s,o),this.provider=r,this.authWindow=null,this.pollId=null,n.currentPopupAction&&n.currentPopupAction.cancel(),n.currentPopupAction=this}executeNotNull(){return f(this,null,function*(){let e=yield this.execute();return T(e,this.auth,"internal-error"),e})}onExecution(){return f(this,null,function*(){Ft(this.filter.length===1,"Popup operations only handle one event");let e=Wl();this.authWindow=yield this.resolver._openPopup(this.auth,this.provider,this.filter[0],e),this.authWindow.associatedEvent=e,this.resolver._originValidation(this.auth).catch(i=>{this.reject(i)}),this.resolver._isIframeWebStorageSupported(this.auth,i=>{i||this.reject(it(this.auth,"web-storage-unsupported"))}),this.pollUserCancellation()})}get eventId(){var e;return((e=this.authWindow)===null||e===void 0?void 0:e.associatedEvent)||null}cancel(){this.reject(it(this.auth,"cancelled-popup-request"))}cleanUp(){this.authWindow&&this.authWindow.close(),this.pollId&&window.clearTimeout(this.pollId),this.authWindow=null,this.pollId=null,n.currentPopupAction=null}pollUserCancellation(){let e=()=>{var i,r;if(!((r=(i=this.authWindow)===null||i===void 0?void 0:i.window)===null||r===void 0)&&r.closed){this.pollId=window.setTimeout(()=>{this.pollId=null,this.reject(it(this.auth,"popup-closed-by-user"))},8e3);return}this.pollId=window.setTimeout(e,x1.get())};e()}}n.currentPopupAction=null;return n})(),L1="pendingRedirect",fo=new Map,Ol=class n extends Co{constructor(t,e,i=!1){super(t,["signInViaRedirect","linkViaRedirect","reauthViaRedirect","unknown"],e,void 0,i),this.eventId=null}execute(){return f(this,null,function*(){let t=fo.get(this.auth._key());if(!t){try{let i=(yield B1(this.resolver,this.auth))?yield ln(n.prototype,this,"execute").call(this):null;t=()=>Promise.resolve(i)}catch(e){t=()=>Promise.reject(e)}fo.set(this.auth._key(),t)}return this.bypassAuthState||fo.set(this.auth._key(),()=>Promise.resolve(null)),t()})}onAuthEvent(t){return f(this,null,function*(){if(t.type==="signInViaRedirect")return ln(n.prototype,this,"onAuthEvent").call(this,t);if(t.type==="unknown"){this.resolve(null);return}if(t.eventId){let e=yield this.auth._redirectUserForId(t.eventId);if(e)return this.user=e,ln(n.prototype,this,"onAuthEvent").call(this,t);this.resolve(null)}})}onExecution(){return f(this,null,function*(){})}cleanUp(){}};function B1(n,t){return f(this,null,function*(){let e=j1(t),i=U1(n);if(!(yield i._isAvailable()))return!1;let r=(yield i._get(e))==="true";return yield i._remove(e),r})}function V1(n,t){fo.set(n._key(),t)}function U1(n){return xt(n._redirectPersistence)}function j1(n){return ho(L1,n.config.apiKey,n.name)}function $1(n,t,e=!1){return f(this,null,function*(){if(mt(n.app))return Promise.reject(Rn(n));let i=Io(n),r=Wp(i,t),o=yield new Ol(i,r,e).execute();return o&&!e&&(delete o.user._redirectEventId,yield i._persistUserIfCurrent(o.user),yield i._setRedirectUser(null,t)),o})}var H1=10*60*1e3,Rl=class{constructor(t){this.auth=t,this.cachedEventUids=new Set,this.consumers=new Set,this.queuedRedirectEvent=null,this.hasHandledPotentialRedirect=!1,this.lastProcessedEventTime=Date.now()}registerConsumer(t){this.consumers.add(t),this.queuedRedirectEvent&&this.isEventForConsumer(this.queuedRedirectEvent,t)&&(this.sendToConsumer(this.queuedRedirectEvent,t),this.saveEventToCache(this.queuedRedirectEvent),this.queuedRedirectEvent=null)}unregisterConsumer(t){this.consumers.delete(t)}onEvent(t){if(this.hasEventBeenHandled(t))return!1;let e=!1;return this.consumers.forEach(i=>{this.isEventForConsumer(t,i)&&(e=!0,this.sendToConsumer(t,i),this.saveEventToCache(t))}),this.hasHandledPotentialRedirect||!G1(t)||(this.hasHandledPotentialRedirect=!0,e||(this.queuedRedirectEvent=t,e=!0)),e}sendToConsumer(t,e){var i;if(t.error&&!qp(t)){let r=((i=t.error.code)===null||i===void 0?void 0:i.split("auth/")[1])||"internal-error";e.onError(it(this.auth,r))}else e.onAuthEvent(t)}isEventForConsumer(t,e){let i=e.eventId===null||!!t.eventId&&t.eventId===e.eventId;return e.filter.includes(t.type)&&i}hasEventBeenHandled(t){return Date.now()-this.lastProcessedEventTime>=H1&&this.cachedEventUids.clear(),this.cachedEventUids.has(mp(t))}saveEventToCache(t){this.cachedEventUids.add(mp(t)),this.lastProcessedEventTime=Date.now()}};function mp(n){return[n.type,n.eventId,n.sessionId,n.tenantId].filter(t=>t).join("-")}function qp({type:n,error:t}){return n==="unknown"&&t?.code==="auth/no-auth-event"}function G1(n){switch(n.type){case"signInViaRedirect":case"linkViaRedirect":case"reauthViaRedirect":return!0;case"unknown":return qp(n);default:return!1}}function z1(e){return f(this,arguments,function*(n,t={}){return wi(n,"GET","/v1/projects",t)})}var W1=/^\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}$/,q1=/^https?/;function J1(n){return f(this,null,function*(){if(n.config.emulator)return;let{authorizedDomains:t}=yield z1(n);for(let e of t)try{if(K1(e))return}catch{}vt(n,"unauthorized-domain")})}function K1(n){let t=yl(),{protocol:e,hostname:i}=new URL(t);if(n.startsWith("chrome-extension://")){let o=new URL(n);return o.hostname===""&&i===""?e==="chrome-extension:"&&n.replace("chrome-extension://","")===t.replace("chrome-extension://",""):e==="chrome-extension:"&&o.hostname===i}if(!q1.test(e))return!1;if(W1.test(n))return i===n;let r=n.replace(/\./g,"\\.");return new RegExp("^(.+\\."+r+"|"+r+")$","i").test(i)}var Y1=new Mn(3e4,6e4);function _p(){let n=_t().___jsl;if(n?.H){for(let t of Object.keys(n.H))if(n.H[t].r=n.H[t].r||[],n.H[t].L=n.H[t].L||[],n.H[t].r=[...n.H[t].L],n.CP)for(let e=0;e<n.CP.length;e++)n.CP[e]=null}}function Q1(n){return new Promise((t,e)=>{var i,r,s;function o(){_p(),gapi.load("gapi.iframes",{callback:()=>{t(gapi.iframes.getContext())},ontimeout:()=>{_p(),e(it(n,"network-request-failed"))},timeout:Y1.get()})}if(!((r=(i=_t().gapi)===null||i===void 0?void 0:i.iframes)===null||r===void 0)&&r.Iframe)t(gapi.iframes.getContext());else if(!((s=_t().gapi)===null||s===void 0)&&s.load)o();else{let c=Bp("iframefcb");return _t()[c]=()=>{gapi.load?o():e(it(n,"network-request-failed"))},a1(`${c1()}?onload=${c}`).catch(a=>e(a))}}).catch(t=>{throw po=null,t})}var po=null;function Z1(n){return po=po||Q1(n),po}var X1=new Mn(5e3,15e3),ew="__/auth/iframe",tw="emulator/auth/iframe",nw={style:{position:"absolute",top:"-100px",width:"1px",height:"1px"},"aria-hidden":"true",tabindex:"-1"},iw=new Map([["identitytoolkit.googleapis.com","p"],["staging-identitytoolkit.sandbox.googleapis.com","s"],["test-identitytoolkit.sandbox.googleapis.com","t"]]);function rw(n){let t=n.config;T(t.authDomain,n,"auth-domain-config-required");let e=t.emulator?xl(t,tw):`https://${n.config.authDomain}/${ew}`,i={apiKey:t.apiKey,appName:n.name,v:mi},r=iw.get(n.config.apiHost);r&&(i.eid=r);let s=n._getFrameworks();return s.length&&(i.fw=s.join(",")),`${e}?${fi(i).slice(1)}`}function sw(n){return f(this,null,function*(){let t=yield Z1(n),e=_t().gapi;return T(e,n,"internal-error"),t.open({where:document.body,url:rw(n),messageHandlersFilter:e.iframes.CROSS_ORIGIN_IFRAMES_FILTER,attributes:nw,dontclear:!0},i=>new Promise((r,s)=>f(this,null,function*(){yield i.restyle({setHideOnLeave:!1});let o=it(n,"network-request-failed"),c=_t().setTimeout(()=>{s(o)},X1.get());function a(){_t().clearTimeout(c),r(i)}i.ping(a).then(a,()=>{s(o)})})))})}var ow={location:"yes",resizable:"yes",statusbar:"yes",toolbar:"no"},aw=500,cw=600,lw="_blank",uw="http://localhost",So=class{constructor(t){this.window=t,this.associatedEvent=null}close(){if(this.window)try{this.window.close()}catch{}}};function dw(n,t,e,i=aw,r=cw){let s=Math.max((window.screen.availHeight-r)/2,0).toString(),o=Math.max((window.screen.availWidth-i)/2,0).toString(),c="",a=Object.assign(Object.assign({},ow),{width:i.toString(),height:r.toString(),top:s,left:o}),l=ve().toLowerCase();e&&(c=Mp(l)?lw:e),Op(l)&&(t=t||uw,a.scrollbars="yes");let u=Object.entries(a).reduce((p,[g,w])=>`${p}${g}=${w},`,"");if(n1(l)&&c!=="_self")return hw(t||"",c),new So(null);let d=window.open(t||"",c,u);T(d,n,"popup-blocked");try{d.focus()}catch{}return new So(d)}function hw(n,t){let e=document.createElement("a");e.href=n,e.target=t;let i=document.createEvent("MouseEvent");i.initMouseEvent("click",!0,!0,window,1,0,0,0,0,!1,!1,!1,!1,1,null),e.dispatchEvent(i)}var fw="__/auth/handler",pw="emulator/auth/handler",gw=encodeURIComponent("fac");function vp(n,t,e,i,r,s){return f(this,null,function*(){T(n.config.authDomain,n,"auth-domain-config-required"),T(n.config.apiKey,n,"invalid-api-key");let o={apiKey:n.config.apiKey,appName:n.name,authType:e,redirectUrl:i,v:mi,eventId:r};if(t instanceof Nr){t.setDefaultLanguage(n.languageCode),o.providerId=t.providerId||"",zf(t.getCustomParameters())||(o.customParameters=JSON.stringify(t.getCustomParameters()));for(let[u,d]of Object.entries(s||{}))o[u]=d}if(t instanceof wo){let u=t.getScopes().filter(d=>d!=="");u.length>0&&(o.scopes=u.join(","))}n.tenantId&&(o.tid=n.tenantId);let c=o;for(let u of Object.keys(c))c[u]===void 0&&delete c[u];let a=yield n._getAppCheckToken(),l=a?`#${gw}=${encodeURIComponent(a)}`:"";return`${mw(n)}?${fi(c).slice(1)}${l}`})}function mw({config:n}){return n.emulator?xl(n,pw):`https://${n.authDomain}/${fw}`}var vl="webStorageSupport",Ml=class{constructor(){this.eventManagers={},this.iframes={},this.originValidationPromises={},this._redirectPersistence=zl,this._completeRedirectFn=$1,this._overrideRedirectResult=V1}_openPopup(t,e,i,r){return f(this,null,function*(){var s;Ft((s=this.eventManagers[t._key()])===null||s===void 0?void 0:s.manager,"_initialize() not called before _openPopup()");let o=yield vp(t,e,i,yl(),r);return dw(t,o,Wl())})}_openRedirect(t,e,i,r){return f(this,null,function*(){yield this._originValidation(t);let s=yield vp(t,e,i,yl(),r);return D1(s),new Promise(()=>{})})}_initialize(t){let e=t._key();if(this.eventManagers[e]){let{manager:r,promise:s}=this.eventManagers[e];return r?Promise.resolve(r):(Ft(s,"If manager is not set, promise should be"),s)}let i=this.initAndGetManager(t);return this.eventManagers[e]={promise:i},i.catch(()=>{delete this.eventManagers[e]}),i}initAndGetManager(t){return f(this,null,function*(){let e=yield sw(t),i=new Rl(t);return e.register("authEvent",r=>(T(r?.authEvent,t,"invalid-auth-event"),{status:i.onEvent(r.authEvent)?"ACK":"ERROR"}),gapi.iframes.CROSS_ORIGIN_IFRAMES_FILTER),this.eventManagers[t._key()]={manager:i},this.iframes[t._key()]=e,i})}_isIframeWebStorageSupported(t,e){this.iframes[t._key()].send(vl,{type:vl},r=>{var s;let o=(s=r?.[0])===null||s===void 0?void 0:s[vl];o!==void 0&&e(!!o),vt(t,"internal-error")},gapi.iframes.CROSS_ORIGIN_IFRAMES_FILTER)}_originValidation(t){let e=t._key();return this.originValidationPromises[e]||(this.originValidationPromises[e]=J1(t)),this.originValidationPromises[e]}get _shouldInitProactively(){return Fp()||Rp()||Ul()}},Jp=Ml;var yp="@firebase/auth",bp="1.7.9";var Pl=class{constructor(t){this.auth=t,this.internalListeners=new Map}getUid(){var t;return this.assertAuthConfigured(),((t=this.auth.currentUser)===null||t===void 0?void 0:t.uid)||null}getToken(t){return f(this,null,function*(){return this.assertAuthConfigured(),yield this.auth._initializationPromise,this.auth.currentUser?{accessToken:yield this.auth.currentUser.getIdToken(t)}:null})}addAuthTokenListener(t){if(this.assertAuthConfigured(),this.internalListeners.has(t))return;let e=this.auth.onIdTokenChanged(i=>{t(i?.stsTokenManager.accessToken||null)});this.internalListeners.set(t,e),this.updateProactiveRefresh()}removeAuthTokenListener(t){this.assertAuthConfigured();let e=this.internalListeners.get(t);e&&(this.internalListeners.delete(t),e(),this.updateProactiveRefresh())}assertAuthConfigured(){T(this.auth._initializationPromise,"dependent-sdk-initialized-before-auth")}updateProactiveRefresh(){this.internalListeners.size>0?this.auth._startProactiveRefresh():this.auth._stopProactiveRefresh()}};function _w(n){switch(n){case"Node":return"node";case"ReactNative":return"rn";case"Worker":return"webworker";case"Cordova":return"cordova";case"WebExtension":return"web-extension";default:return}}function vw(n){gi(new pt("auth",(t,{options:e})=>{let i=t.getProvider("app").getImmediate(),r=t.getProvider("heartbeat"),s=t.getProvider("app-check-internal"),{apiKey:o,authDomain:c}=i.options;T(o&&!o.includes(":"),"invalid-api-key",{appName:i.name});let a={apiKey:o,authDomain:c,clientPlatform:n,apiHost:"identitytoolkit.googleapis.com",tokenApiHost:"securetoken.googleapis.com",apiScheme:"https",sdkClientVersion:Lp(n)},l=new Cl(i,r,s,a);return l1(l,e),l},"PUBLIC").setInstantiationMode("EXPLICIT").setInstanceCreatedCallback((t,e,i)=>{t.getProvider("auth-internal").initialize()})),gi(new pt("auth-internal",t=>{let e=Io(t.getProvider("auth").getImmediate());return(i=>new Pl(i))(e)},"PRIVATE").setInstantiationMode("EXPLICIT")),Oe(yp,bp,_w(n)),Oe(yp,bp,"esm2017")}var yw=5*60,bw=Qc("authIdTokenMaxAge")||yw,wp=null,ww=n=>t=>f(void 0,null,function*(){let e=t&&(yield t.getIdTokenResult()),i=e&&(new Date().getTime()-Date.parse(e.issuedAtTime))/1e3;if(i&&i>bw)return;let r=e?.token;wp!==r&&(wp=r,yield fetch(n,{method:r?"POST":"DELETE",headers:r?{Authorization:`Bearer ${r}`}:{}}))});function Jl(n=io()){let t=hl(n,"auth");if(t.isInitialized())return t.getImmediate();let e=$l(n,{popupRedirectResolver:Jp,persistence:[zp,jp,zl]}),i=Qc("authTokenSyncURL");if(i&&typeof isSecureContext=="boolean"&&isSecureContext){let s=new URL(i,location.origin);if(location.origin===s.origin){let o=ww(s.toString());Gl(e,o,()=>o(e.currentUser)),Lr(e,c=>o(c))}}let r=Lf("auth");return r&&Hl(e,`http://${r}`),e}function Dw(){var n,t;return(t=(n=document.getElementsByTagName("head"))===null||n===void 0?void 0:n[0])!==null&&t!==void 0?t:document}o1({loadJS(n){return new Promise((t,e)=>{let i=document.createElement("script");i.setAttribute("src",n),i.onload=t,i.onerror=r=>{let s=it("internal-error");s.customData=r,e(s)},i.type="text/javascript",i.charset="UTF-8",Dw().appendChild(i)})},gapiScript:"https://apis.google.com/js/api.js",recaptchaV2Script:"https://www.google.com/recaptcha/api.js",recaptchaEnterpriseScript:"https://www.google.com/recaptcha/enterprise.js?render="});vw("Browser");function Qp(n){return new Ne(function(t){var e=Lr(n,t.next.bind(t),t.error.bind(t),t.complete.bind(t));return{unsubscribe:e}})}var Zp="auth",Nn=class{constructor(t){return t}},Kl=class{constructor(){return gl(Zp)}};var Yl=new O("angularfire2.auth-instances");function fD(n,t){let e=ap(Zp,n,t);return e&&new Nn(e)}function pD(n){return(t,e)=>{let i=t.runOutsideAngular(()=>n(e));return new Nn(i)}}var gD={provide:Kl,deps:[[new st,Yl]]},mD={provide:Nn,useFactory:fD,deps:[[new st,Yl],On]};function vM(n,...t){return Oe("angularfire",Sr.full,"auth"),qe([mD,gD,{provide:Yl,useFactory:pD(n),multi:!0,deps:[$,J,ao,Ir,[new st,so],...t]}])}var Xp=vi(Qp,!0);var yM=vi(Jl,!0);var eg=vi(ql,!0);var kn=class extends Error{};kn.prototype.name="InvalidTokenError";function _D(n){return decodeURIComponent(atob(n).replace(/(.)/g,(t,e)=>{let i=e.charCodeAt(0).toString(16).toUpperCase();return i.length<2&&(i="0"+i),"%"+i}))}function vD(n){let t=n.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return _D(t)}catch{return atob(t)}}function Ql(n,t){if(typeof n!="string")throw new kn("Invalid token specified: must be a string");t||(t={});let e=t.header===!0?0:1,i=n.split(".")[e];if(typeof i!="string")throw new kn(`Invalid token specified: missing part #${e+1}`);let r;try{r=vD(i)}catch(s){throw new kn(`Invalid token specified: invalid base64 for part #${e+1} (${s.message})`)}try{return JSON.parse(r)}catch(s){throw new kn(`Invalid token specified: invalid json for part #${e+1} (${s.message})`)}}var MM=(()=>{class n{constructor(){this.httpService=h(Nf),this._roles=new be([]),this.route=h(ht),this.router=h(Xe),this.auth=h(Nn),this.provider=new Fr,this.user$=Xp(this.auth),this.destroy=new N,this.automateLogon()}login(e){return this.httpService.post("api/Token/Login",e).pipe(U(i=>this.storeLoginResponse(i)),U(i=>this.decodeRoles(i)),U(()=>this.storeFormLogin(e)),Tu(1))}storeLoginResponse(e){localStorage.setItem("Token",e.access_token),localStorage.setItem("ExpireDate",e.expiredAt),localStorage.setItem("TokenType",e.token_type)}storeFormLogin(e){localStorage.setItem("Domain",e.Host),localStorage.setItem("Username",e.Username)}decodeRoles(e){let i=Ql(e.access_token);localStorage.setItem("Brand",i.Brand);let r=i["http://schemas.microsoft.com/ws/2008/06/identity/claims/role"];return this._roles.next(r),this.storeRoles(),r}storeRoles(){localStorage.setItem("Roles",JSON.stringify(this._roles.value))}isTokenExpired(){let e=localStorage.getItem("Token");try{let i=Ql(e),r=Math.floor(Date.now()/1e3);return i.exp?i.exp<r:!1}catch{return!0}}isAuthenticated(){return localStorage.getItem("Token")!==null&&!this.isTokenExpired()}getAuthToken(){return localStorage.getItem("Token")??""}getAuthTokenType(){return localStorage.getItem("TokenType")??""}redirectUrl(){return this.router.navigate(["/pages/shelf/barcode"])}automateLogon(){return f(this,null,function*(){return this.isAuthenticated()?yield this.router.navigate([""]):yield this.router.navigate([""])})}getDomain(){return localStorage.getItem("Domain")!==null?localStorage.getItem("Domain"):""}logout(){return f(this,null,function*(){let e=["ExpireDate","Token","TokenType","Roles","PrintMode"];for(let i of e)localStorage.removeItem(i);yield this.router.navigate([""])})}signInWithPopup(e){return Q(eg(this.auth,new Fr)).pipe(le(i=>{let r=Fr.credentialFromResult(i),s={Host:e,IDToken:r?.idToken};return this.httpService.post("api/token/LoginWithSocialProvider",s).pipe(I(o=>o),U(o=>this.storeLoginResponse(o)),U(o=>this.decodeRoles(o)),De(o=>b(null)))}),De(i=>b(null)))}ngOnDestroy(){this.destroy.next(),this.destroy.complete()}checkAuthKeysExists(){return["ExpireDate","Token","TokenType","Roles","Brand","Domain","Username","PrintMode"].every(i=>!!localStorage.getItem(i))}static{this.\u0275fac=function(i){return new(i||n)}}static{this.\u0275prov=y({token:n,factory:n.\u0275fac,providedIn:"root"})}}return n})();export{St as a,Bi as b,lt as c,ua as d,ND as e,kD as f,xD as g,bd as h,sT as i,Id as j,ya as k,ht as l,Am as m,Xe as n,ET as o,CT as p,ST as q,Ms as r,Y_ as s,pr as t,Z_ as u,Mh as v,wh as w,_n as x,QT as y,ZT as z,Ls as A,fr as B,Sv as C,eE as D,Ov as E,Mv as F,Nv as G,tE as H,nE as I,iE as J,mf as K,UA as L,I0 as M,jA as N,$A as O,ui as P,Ef as Q,HA as R,KA as S,If as T,YA as U,q0 as V,QA as W,Af as X,ZA as Y,Ks as Z,XA as _,eO as $,tO as aa,Bc as ba,iO as ca,Xs as da,vy as ea,vO as fa,Nf as ga,mR as ha,_R as ia,vM as ja,yM as ka,Ql as la,MM as ma};