From c1b351de9dc23c395bbd529608e71c3b7fa209e1 Mon Sep 17 00:00:00 2001 From: Anthony Enrique Velasquez Honorio Date: Sat, 23 Nov 2024 21:31:52 -0500 Subject: [PATCH] Auto-generated commit --- 404.html | 2 +- index.html | 2 +- main-E3V7JEQE.js | 13 +++++++++++++ main-WIBJQLKF.js | 13 ------------- 4 files changed, 15 insertions(+), 15 deletions(-) create mode 100644 main-E3V7JEQE.js delete mode 100644 main-WIBJQLKF.js diff --git a/404.html b/404.html index 3d2d67a..538b266 100644 --- a/404.html +++ b/404.html @@ -11,5 +11,5 @@ - + diff --git a/index.html b/index.html index 3d2d67a..538b266 100644 --- a/index.html +++ b/index.html @@ -11,5 +11,5 @@ - + diff --git a/main-E3V7JEQE.js b/main-E3V7JEQE.js new file mode 100644 index 0000000..6957205 --- /dev/null +++ b/main-E3V7JEQE.js @@ -0,0 +1,13 @@ +import{b as Kd,c as Jd,f as My,g as Xd}from"./chunk-5PDZ6P5C.js";import{a as _,b as G,d as vt,f as Ey,g as Iy,h}from"./chunk-RS6LHQUM.js";var Sd=vt(Md=>{"use strict";Object.defineProperty(Md,"__esModule",{value:!0});var Id=class extends Error{constructor(n){super(n.message),this.name="PostgrestError",this.details=n.details,this.hint=n.hint,this.code=n.code}};Md.default=Id});var Td=vt(oi=>{"use strict";var lv=oi&&oi.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(oi,"__esModule",{value:!0});var mM=lv((Xd(),Iy(My))),vM=lv(Sd()),xd=class{constructor(n){this.shouldThrowOnError=!1,this.method=n.method,this.url=n.url,this.headers=n.headers,this.schema=n.schema,this.body=n.body,this.shouldThrowOnError=n.shouldThrowOnError,this.signal=n.signal,this.isMaybeSingle=n.isMaybeSingle,n.fetch?this.fetch=n.fetch:typeof fetch>"u"?this.fetch=mM.default:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(n,t){return this.headers=Object.assign({},this.headers),this.headers[n]=t,this}then(n,t){this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers["Accept-Profile"]=this.schema:this.headers["Content-Profile"]=this.schema),this.method!=="GET"&&this.method!=="HEAD"&&(this.headers["Content-Type"]="application/json");let r=this.fetch,o=r(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(i=>h(this,null,function*(){var s,a,c;let l=null,u=null,d=null,p=i.status,f=i.statusText;if(i.ok){if(this.method!=="HEAD"){let C=yield i.text();C===""||(this.headers.Accept==="text/csv"||this.headers.Accept&&this.headers.Accept.includes("application/vnd.pgrst.plan+text")?u=C:u=JSON.parse(C))}let m=(s=this.headers.Prefer)===null||s===void 0?void 0:s.match(/count=(exact|planned|estimated)/),y=(a=i.headers.get("content-range"))===null||a===void 0?void 0:a.split("/");m&&y&&y.length>1&&(d=parseInt(y[1])),this.isMaybeSingle&&this.method==="GET"&&Array.isArray(u)&&(u.length>1?(l={code:"PGRST116",details:`Results contain ${u.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},u=null,d=null,p=406,f="Not Acceptable"):u.length===1?u=u[0]:u=null)}else{let m=yield i.text();try{l=JSON.parse(m),Array.isArray(l)&&i.status===404&&(u=[],l=null,p=200,f="OK")}catch{i.status===404&&m===""?(p=204,f="No Content"):l={message:m}}if(l&&this.isMaybeSingle&&(!((c=l?.details)===null||c===void 0)&&c.includes("0 rows"))&&(l=null,p=200,f="OK"),l&&this.shouldThrowOnError)throw new vM.default(l)}return{error:l,data:u,count:d,status:p,statusText:f}}));return this.shouldThrowOnError||(o=o.catch(i=>{var s,a,c;return{error:{message:`${(s=i?.name)!==null&&s!==void 0?s:"FetchError"}: ${i?.message}`,details:`${(a=i?.stack)!==null&&a!==void 0?a:""}`,hint:"",code:`${(c=i?.code)!==null&&c!==void 0?c:""}`},data:null,count:null,status:0,statusText:""}})),o.then(n,t)}};oi.default=xd});var Od=vt(ii=>{"use strict";var yM=ii&&ii.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(ii,"__esModule",{value:!0});var wM=yM(Td()),Ad=class extends wM.default{select(n){let t=!1,r=(n??"*").split("").map(o=>/\s/.test(o)&&!t?"":(o==='"'&&(t=!t),o)).join("");return this.url.searchParams.set("select",r),this.headers.Prefer&&(this.headers.Prefer+=","),this.headers.Prefer+="return=representation",this}order(n,{ascending:t=!0,nullsFirst:r,foreignTable:o,referencedTable:i=o}={}){let s=i?`${i}.order`:"order",a=this.url.searchParams.get(s);return this.url.searchParams.set(s,`${a?`${a},`:""}${n}.${t?"asc":"desc"}${r===void 0?"":r?".nullsfirst":".nullslast"}`),this}limit(n,{foreignTable:t,referencedTable:r=t}={}){let o=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(o,`${n}`),this}range(n,t,{foreignTable:r,referencedTable:o=r}={}){let i=typeof o>"u"?"offset":`${o}.offset`,s=typeof o>"u"?"limit":`${o}.limit`;return this.url.searchParams.set(i,`${n}`),this.url.searchParams.set(s,`${t-n+1}`),this}abortSignal(n){return this.signal=n,this}single(){return this.headers.Accept="application/vnd.pgrst.object+json",this}maybeSingle(){return this.method==="GET"?this.headers.Accept="application/json":this.headers.Accept="application/vnd.pgrst.object+json",this.isMaybeSingle=!0,this}csv(){return this.headers.Accept="text/csv",this}geojson(){return this.headers.Accept="application/geo+json",this}explain({analyze:n=!1,verbose:t=!1,settings:r=!1,buffers:o=!1,wal:i=!1,format:s="text"}={}){var a;let c=[n?"analyze":null,t?"verbose":null,r?"settings":null,o?"buffers":null,i?"wal":null].filter(Boolean).join("|"),l=(a=this.headers.Accept)!==null&&a!==void 0?a:"application/json";return this.headers.Accept=`application/vnd.pgrst.plan+${s}; for="${l}"; options=${c};`,s==="json"?this:this}rollback(){var n;return((n=this.headers.Prefer)!==null&&n!==void 0?n:"").trim().length>0?this.headers.Prefer+=",tx=rollback":this.headers.Prefer="tx=rollback",this}returns(){return this}};ii.default=Ad});var ka=vt(si=>{"use strict";var _M=si&&si.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(si,"__esModule",{value:!0});var DM=_M(Od()),Nd=class extends DM.default{eq(n,t){return this.url.searchParams.append(n,`eq.${t}`),this}neq(n,t){return this.url.searchParams.append(n,`neq.${t}`),this}gt(n,t){return this.url.searchParams.append(n,`gt.${t}`),this}gte(n,t){return this.url.searchParams.append(n,`gte.${t}`),this}lt(n,t){return this.url.searchParams.append(n,`lt.${t}`),this}lte(n,t){return this.url.searchParams.append(n,`lte.${t}`),this}like(n,t){return this.url.searchParams.append(n,`like.${t}`),this}likeAllOf(n,t){return this.url.searchParams.append(n,`like(all).{${t.join(",")}}`),this}likeAnyOf(n,t){return this.url.searchParams.append(n,`like(any).{${t.join(",")}}`),this}ilike(n,t){return this.url.searchParams.append(n,`ilike.${t}`),this}ilikeAllOf(n,t){return this.url.searchParams.append(n,`ilike(all).{${t.join(",")}}`),this}ilikeAnyOf(n,t){return this.url.searchParams.append(n,`ilike(any).{${t.join(",")}}`),this}is(n,t){return this.url.searchParams.append(n,`is.${t}`),this}in(n,t){let r=Array.from(new Set(t)).map(o=>typeof o=="string"&&new RegExp("[,()]").test(o)?`"${o}"`:`${o}`).join(",");return this.url.searchParams.append(n,`in.(${r})`),this}contains(n,t){return typeof t=="string"?this.url.searchParams.append(n,`cs.${t}`):Array.isArray(t)?this.url.searchParams.append(n,`cs.{${t.join(",")}}`):this.url.searchParams.append(n,`cs.${JSON.stringify(t)}`),this}containedBy(n,t){return typeof t=="string"?this.url.searchParams.append(n,`cd.${t}`):Array.isArray(t)?this.url.searchParams.append(n,`cd.{${t.join(",")}}`):this.url.searchParams.append(n,`cd.${JSON.stringify(t)}`),this}rangeGt(n,t){return this.url.searchParams.append(n,`sr.${t}`),this}rangeGte(n,t){return this.url.searchParams.append(n,`nxl.${t}`),this}rangeLt(n,t){return this.url.searchParams.append(n,`sl.${t}`),this}rangeLte(n,t){return this.url.searchParams.append(n,`nxr.${t}`),this}rangeAdjacent(n,t){return this.url.searchParams.append(n,`adj.${t}`),this}overlaps(n,t){return typeof t=="string"?this.url.searchParams.append(n,`ov.${t}`):this.url.searchParams.append(n,`ov.{${t.join(",")}}`),this}textSearch(n,t,{config:r,type:o}={}){let i="";o==="plain"?i="pl":o==="phrase"?i="ph":o==="websearch"&&(i="w");let s=r===void 0?"":`(${r})`;return this.url.searchParams.append(n,`${i}fts${s}.${t}`),this}match(n){return Object.entries(n).forEach(([t,r])=>{this.url.searchParams.append(t,`eq.${r}`)}),this}not(n,t,r){return this.url.searchParams.append(n,`not.${t}.${r}`),this}or(n,{foreignTable:t,referencedTable:r=t}={}){let o=r?`${r}.or`:"or";return this.url.searchParams.append(o,`(${n})`),this}filter(n,t,r){return this.url.searchParams.append(n,`${t}.${r}`),this}};si.default=Nd});var Pd=vt(ci=>{"use strict";var bM=ci&&ci.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(ci,"__esModule",{value:!0});var ai=bM(ka()),Rd=class{constructor(n,{headers:t={},schema:r,fetch:o}){this.url=n,this.headers=t,this.schema=r,this.fetch=o}select(n,{head:t=!1,count:r}={}){let o=t?"HEAD":"GET",i=!1,s=(n??"*").split("").map(a=>/\s/.test(a)&&!i?"":(a==='"'&&(i=!i),a)).join("");return this.url.searchParams.set("select",s),r&&(this.headers.Prefer=`count=${r}`),new ai.default({method:o,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch,allowEmpty:!1})}insert(n,{count:t,defaultToNull:r=!0}={}){let o="POST",i=[];if(this.headers.Prefer&&i.push(this.headers.Prefer),t&&i.push(`count=${t}`),r||i.push("missing=default"),this.headers.Prefer=i.join(","),Array.isArray(n)){let s=n.reduce((a,c)=>a.concat(Object.keys(c)),[]);if(s.length>0){let a=[...new Set(s)].map(c=>`"${c}"`);this.url.searchParams.set("columns",a.join(","))}}return new ai.default({method:o,url:this.url,headers:this.headers,schema:this.schema,body:n,fetch:this.fetch,allowEmpty:!1})}upsert(n,{onConflict:t,ignoreDuplicates:r=!1,count:o,defaultToNull:i=!0}={}){let s="POST",a=[`resolution=${r?"ignore":"merge"}-duplicates`];if(t!==void 0&&this.url.searchParams.set("on_conflict",t),this.headers.Prefer&&a.push(this.headers.Prefer),o&&a.push(`count=${o}`),i||a.push("missing=default"),this.headers.Prefer=a.join(","),Array.isArray(n)){let c=n.reduce((l,u)=>l.concat(Object.keys(u)),[]);if(c.length>0){let l=[...new Set(c)].map(u=>`"${u}"`);this.url.searchParams.set("columns",l.join(","))}}return new ai.default({method:s,url:this.url,headers:this.headers,schema:this.schema,body:n,fetch:this.fetch,allowEmpty:!1})}update(n,{count:t}={}){let r="PATCH",o=[];return this.headers.Prefer&&o.push(this.headers.Prefer),t&&o.push(`count=${t}`),this.headers.Prefer=o.join(","),new ai.default({method:r,url:this.url,headers:this.headers,schema:this.schema,body:n,fetch:this.fetch,allowEmpty:!1})}delete({count:n}={}){let t="DELETE",r=[];return n&&r.push(`count=${n}`),this.headers.Prefer&&r.unshift(this.headers.Prefer),this.headers.Prefer=r.join(","),new ai.default({method:t,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch,allowEmpty:!1})}};ci.default=Rd});var uv=vt(Fa=>{"use strict";Object.defineProperty(Fa,"__esModule",{value:!0});Fa.version=void 0;Fa.version="0.0.0-automated"});var dv=vt(La=>{"use strict";Object.defineProperty(La,"__esModule",{value:!0});La.DEFAULT_HEADERS=void 0;var CM=uv();La.DEFAULT_HEADERS={"X-Client-Info":`postgrest-js/${CM.version}`}});var hv=vt(li=>{"use strict";var fv=li&&li.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(li,"__esModule",{value:!0});var EM=fv(Pd()),IM=fv(ka()),MM=dv(),kd=class e{constructor(n,{headers:t={},schema:r,fetch:o}={}){this.url=n,this.headers=Object.assign(Object.assign({},MM.DEFAULT_HEADERS),t),this.schemaName=r,this.fetch=o}from(n){let t=new URL(`${this.url}/${n}`);return new EM.default(t,{headers:Object.assign({},this.headers),schema:this.schemaName,fetch:this.fetch})}schema(n){return new e(this.url,{headers:this.headers,schema:n,fetch:this.fetch})}rpc(n,t={},{head:r=!1,get:o=!1,count:i}={}){let s,a=new URL(`${this.url}/rpc/${n}`),c;r||o?(s=r?"HEAD":"GET",Object.entries(t).filter(([u,d])=>d!==void 0).map(([u,d])=>[u,Array.isArray(d)?`{${d.join(",")}}`:`${d}`]).forEach(([u,d])=>{a.searchParams.append(u,d)})):(s="POST",c=t);let l=Object.assign({},this.headers);return i&&(l.Prefer=`count=${i}`),new IM.default({method:s,url:a,headers:l,schema:this.schemaName,body:c,fetch:this.fetch,allowEmpty:!1})}};li.default=kd});var _v=vt(ye=>{"use strict";var $r=ye&&ye.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(ye,"__esModule",{value:!0});ye.PostgrestError=ye.PostgrestBuilder=ye.PostgrestTransformBuilder=ye.PostgrestFilterBuilder=ye.PostgrestQueryBuilder=ye.PostgrestClient=void 0;var pv=$r(hv());ye.PostgrestClient=pv.default;var gv=$r(Pd());ye.PostgrestQueryBuilder=gv.default;var mv=$r(ka());ye.PostgrestFilterBuilder=mv.default;var vv=$r(Od());ye.PostgrestTransformBuilder=vv.default;var yv=$r(Td());ye.PostgrestBuilder=yv.default;var wv=$r(Sd());ye.PostgrestError=wv.default;ye.default={PostgrestClient:pv.default,PostgrestQueryBuilder:gv.default,PostgrestFilterBuilder:mv.default,PostgrestTransformBuilder:vv.default,PostgrestBuilder:yv.default,PostgrestError:wv.default}});function Sy(e,n){return Object.is(e,n)}var de=null,eo=!1,Di=1,St=Symbol("SIGNAL");function L(e){let n=de;return de=e,n}function xy(){return eo}var bi={version:0,lastCleanEpoch:0,dirty:!1,producerNode:void 0,producerLastReadVersion:void 0,producerIndexOfThis:void 0,nextProducerIndex:0,liveConsumerNode:void 0,liveConsumerIndexOfThis:void 0,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function ic(e){if(eo)throw new Error("");if(de===null)return;de.consumerOnSignalRead(e);let n=de.nextProducerIndex++;if($n(de),ne.nextProducerIndex;)e.producerNode.pop(),e.producerLastReadVersion.pop(),e.producerIndexOfThis.pop()}}function Ci(e){$n(e);for(let n=0;n0}function $n(e){e.producerNode??=[],e.producerIndexOfThis??=[],e.producerLastReadVersion??=[]}function of(e){e.liveConsumerNode??=[],e.liveConsumerIndexOfThis??=[]}function Oy(){throw new Error}var sf=Oy;function af(){sf()}function cf(e){sf=e}var Ny=null;function lf(e){let n=Object.create(lc);n.value=e;let t=()=>(ic(n),n.value);return t[St]=n,t}function Ii(e,n){tf()||af(),e.equal(e.value,n)||(e.value=n,Ry(e))}function uf(e,n){tf()||af(),Ii(e,n(e.value))}var lc=G(_({},bi),{equal:Sy,value:void 0});function Ry(e){e.version++,Ty(),ef(e),Ny?.()}function df(e,n,t){let r=Object.create(Py);t&&(r.consumerAllowSignalWrites=!0),r.fn=e,r.schedule=n;let o=c=>{r.cleanupFn=c};function i(c){return c.fn===null&&c.schedule===null}function s(c){i(c)||(cc(c),c.cleanupFn(),c.fn=null,c.schedule=null,c.cleanupFn=oc)}let a=()=>{if(r.fn===null)return;if(xy())throw new Error("Schedulers cannot synchronously execute watches while scheduling.");if(r.dirty=!1,r.hasRun&&!Ci(r))return;r.hasRun=!0;let c=sc(r);try{r.cleanupFn(),r.cleanupFn=oc,r.fn(o)}finally{ac(r,c)}};return r.ref={notify:()=>nf(r),run:a,cleanup:()=>r.cleanupFn(),destroy:()=>s(r),[St]:r},r.ref}var oc=()=>{},Py=G(_({},bi),{consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!1,consumerMarkedDirty:e=>{e.schedule!==null&&e.schedule(e.ref)},hasRun:!1,cleanupFn:oc});function T(e){return typeof e=="function"}function Un(e){let t=e(r=>{Error.call(r),r.stack=new Error().stack});return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var Mi=Un(e=>function(t){e(this),this.message=t?`${t.length} errors occurred during unsubscription: +${t.map((r,o)=>`${o+1}) ${r.toString()}`).join(` + `)}`:"",this.name="UnsubscriptionError",this.errors=t});function no(e,n){if(e){let t=e.indexOf(n);0<=t&&e.splice(t,1)}}var le=class e{constructor(n){this.initialTeardown=n,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let n;if(!this.closed){this.closed=!0;let{_parentage:t}=this;if(t)if(this._parentage=null,Array.isArray(t))for(let i of t)i.remove(this);else t.remove(this);let{initialTeardown:r}=this;if(T(r))try{r()}catch(i){n=i instanceof Mi?i.errors:[i]}let{_finalizers:o}=this;if(o){this._finalizers=null;for(let i of o)try{ff(i)}catch(s){n=n??[],s instanceof Mi?n=[...n,...s.errors]:n.push(s)}}if(n)throw new Mi(n)}}add(n){var t;if(n&&n!==this)if(this.closed)ff(n);else{if(n instanceof e){if(n.closed||n._hasParent(this))return;n._addParent(this)}(this._finalizers=(t=this._finalizers)!==null&&t!==void 0?t:[]).push(n)}}_hasParent(n){let{_parentage:t}=this;return t===n||Array.isArray(t)&&t.includes(n)}_addParent(n){let{_parentage:t}=this;this._parentage=Array.isArray(t)?(t.push(n),t):t?[t,n]:n}_removeParent(n){let{_parentage:t}=this;t===n?this._parentage=null:Array.isArray(t)&&no(t,n)}remove(n){let{_finalizers:t}=this;t&&no(t,n),n instanceof e&&n._removeParent(this)}};le.EMPTY=(()=>{let e=new le;return e.closed=!0,e})();var uc=le.EMPTY;function Si(e){return e instanceof le||e&&"closed"in e&&T(e.remove)&&T(e.add)&&T(e.unsubscribe)}function ff(e){T(e)?e():e.unsubscribe()}var Je={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1};var Bn={setTimeout(e,n,...t){let{delegate:r}=Bn;return r?.setTimeout?r.setTimeout(e,n,...t):setTimeout(e,n,...t)},clearTimeout(e){let{delegate:n}=Bn;return(n?.clearTimeout||clearTimeout)(e)},delegate:void 0};function xi(e){Bn.setTimeout(()=>{let{onUnhandledError:n}=Je;if(n)n(e);else throw e})}function ro(){}var hf=dc("C",void 0,void 0);function pf(e){return dc("E",void 0,e)}function gf(e){return dc("N",e,void 0)}function dc(e,n,t){return{kind:e,value:n,error:t}}var Kt=null;function Hn(e){if(Je.useDeprecatedSynchronousErrorHandling){let n=!Kt;if(n&&(Kt={errorThrown:!1,error:null}),e(),n){let{errorThrown:t,error:r}=Kt;if(Kt=null,t)throw r}}else e()}function mf(e){Je.useDeprecatedSynchronousErrorHandling&&Kt&&(Kt.errorThrown=!0,Kt.error=e)}var Jt=class extends le{constructor(n){super(),this.isStopped=!1,n?(this.destination=n,Si(n)&&n.add(this)):this.destination=Ly}static create(n,t,r){return new zn(n,t,r)}next(n){this.isStopped?hc(gf(n),this):this._next(n)}error(n){this.isStopped?hc(pf(n),this):(this.isStopped=!0,this._error(n))}complete(){this.isStopped?hc(hf,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(n){this.destination.next(n)}_error(n){try{this.destination.error(n)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}},ky=Function.prototype.bind;function fc(e,n){return ky.call(e,n)}var pc=class{constructor(n){this.partialObserver=n}next(n){let{partialObserver:t}=this;if(t.next)try{t.next(n)}catch(r){Ti(r)}}error(n){let{partialObserver:t}=this;if(t.error)try{t.error(n)}catch(r){Ti(r)}else Ti(n)}complete(){let{partialObserver:n}=this;if(n.complete)try{n.complete()}catch(t){Ti(t)}}},zn=class extends Jt{constructor(n,t,r){super();let o;if(T(n)||!n)o={next:n??void 0,error:t??void 0,complete:r??void 0};else{let i;this&&Je.useDeprecatedNextContext?(i=Object.create(n),i.unsubscribe=()=>this.unsubscribe(),o={next:n.next&&fc(n.next,i),error:n.error&&fc(n.error,i),complete:n.complete&&fc(n.complete,i)}):o=n}this.destination=new pc(o)}};function Ti(e){Je.useDeprecatedSynchronousErrorHandling?mf(e):xi(e)}function Fy(e){throw e}function hc(e,n){let{onStoppedNotification:t}=Je;t&&Bn.setTimeout(()=>t(e,n))}var Ly={closed:!0,next:ro,error:Fy,complete:ro};var Gn=typeof Symbol=="function"&&Symbol.observable||"@@observable";function ke(e){return e}function gc(...e){return mc(e)}function mc(e){return e.length===0?ke:e.length===1?e[0]:function(t){return e.reduce((r,o)=>o(r),t)}}var B=(()=>{class e{constructor(t){t&&(this._subscribe=t)}lift(t){let r=new e;return r.source=this,r.operator=t,r}subscribe(t,r,o){let i=Vy(t)?t:new zn(t,r,o);return Hn(()=>{let{operator:s,source:a}=this;i.add(s?s.call(i,a):a?this._subscribe(i):this._trySubscribe(i))}),i}_trySubscribe(t){try{return this._subscribe(t)}catch(r){t.error(r)}}forEach(t,r){return r=vf(r),new r((o,i)=>{let s=new zn({next:a=>{try{t(a)}catch(c){i(c),s.unsubscribe()}},error:i,complete:o});this.subscribe(s)})}_subscribe(t){var r;return(r=this.source)===null||r===void 0?void 0:r.subscribe(t)}[Gn](){return this}pipe(...t){return mc(t)(this)}toPromise(t){return t=vf(t),new t((r,o)=>{let i;this.subscribe(s=>i=s,s=>o(s),()=>r(i))})}}return e.create=n=>new e(n),e})();function vf(e){var n;return(n=e??Je.Promise)!==null&&n!==void 0?n:Promise}function jy(e){return e&&T(e.next)&&T(e.error)&&T(e.complete)}function Vy(e){return e&&e instanceof Jt||jy(e)&&Si(e)}function vc(e){return T(e?.lift)}function U(e){return n=>{if(vc(n))return n.lift(function(t){try{return e(t,this)}catch(r){this.error(r)}});throw new TypeError("Unable to lift unknown Observable type")}}function j(e,n,t,r,o){return new yc(e,n,t,r,o)}var yc=class extends Jt{constructor(n,t,r,o,i,s){super(n),this.onFinalize=i,this.shouldUnsubscribe=s,this._next=t?function(a){try{t(a)}catch(c){n.error(c)}}:super._next,this._error=o?function(a){try{o(a)}catch(c){n.error(c)}finally{this.unsubscribe()}}:super._error,this._complete=r?function(){try{r()}catch(a){n.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var n;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){let{closed:t}=this;super.unsubscribe(),!t&&((n=this.onFinalize)===null||n===void 0||n.call(this))}}};function qn(){return U((e,n)=>{let t=null;e._refCount++;let r=j(n,void 0,void 0,void 0,()=>{if(!e||e._refCount<=0||0<--e._refCount){t=null;return}let o=e._connection,i=t;t=null,o&&(!i||o===i)&&o.unsubscribe(),n.unsubscribe()});e.subscribe(r),r.closed||(t=e.connect())})}var Wn=class extends B{constructor(n,t){super(),this.source=n,this.subjectFactory=t,this._subject=null,this._refCount=0,this._connection=null,vc(n)&&(this.lift=n.lift)}_subscribe(n){return this.getSubject().subscribe(n)}getSubject(){let n=this._subject;return(!n||n.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;let{_connection:n}=this;this._subject=this._connection=null,n?.unsubscribe()}connect(){let n=this._connection;if(!n){n=this._connection=new le;let t=this.getSubject();n.add(this.source.subscribe(j(t,void 0,()=>{this._teardown(),t.complete()},r=>{this._teardown(),t.error(r)},()=>this._teardown()))),n.closed&&(this._connection=null,n=le.EMPTY)}return n}refCount(){return qn()(this)}};var yf=Un(e=>function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var we=(()=>{class e extends B{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(t){let r=new Ai(this,this);return r.operator=t,r}_throwIfClosed(){if(this.closed)throw new yf}next(t){Hn(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(let r of this.currentObservers)r.next(t)}})}error(t){Hn(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=t;let{observers:r}=this;for(;r.length;)r.shift().error(t)}})}complete(){Hn(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;let{observers:t}=this;for(;t.length;)t.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0}_trySubscribe(t){return this._throwIfClosed(),super._trySubscribe(t)}_subscribe(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)}_innerSubscribe(t){let{hasError:r,isStopped:o,observers:i}=this;return r||o?uc:(this.currentObservers=null,i.push(t),new le(()=>{this.currentObservers=null,no(i,t)}))}_checkFinalizedStatuses(t){let{hasError:r,thrownError:o,isStopped:i}=this;r?t.error(o):i&&t.complete()}asObservable(){let t=new B;return t.source=this,t}}return e.create=(n,t)=>new Ai(n,t),e})(),Ai=class extends we{constructor(n,t){super(),this.destination=n,this.source=t}next(n){var t,r;(r=(t=this.destination)===null||t===void 0?void 0:t.next)===null||r===void 0||r.call(t,n)}error(n){var t,r;(r=(t=this.destination)===null||t===void 0?void 0:t.error)===null||r===void 0||r.call(t,n)}complete(){var n,t;(t=(n=this.destination)===null||n===void 0?void 0:n.complete)===null||t===void 0||t.call(n)}_subscribe(n){var t,r;return(r=(t=this.source)===null||t===void 0?void 0:t.subscribe(n))!==null&&r!==void 0?r:uc}};var ge=class extends we{constructor(n){super(),this._value=n}get value(){return this.getValue()}_subscribe(n){let t=super._subscribe(n);return!t.closed&&n.next(this._value),t}getValue(){let{hasError:n,thrownError:t,_value:r}=this;if(n)throw t;return this._throwIfClosed(),r}next(n){super.next(this._value=n)}};var Fe=new B(e=>e.complete());function wf(e){return e&&T(e.schedule)}function _f(e){return e[e.length-1]}function Oi(e){return T(_f(e))?e.pop():void 0}function xt(e){return wf(_f(e))?e.pop():void 0}function bf(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})}function Df(e){var n=typeof Symbol=="function"&&Symbol.iterator,t=n&&e[n],r=0;if(t)return t.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function Xt(e){return this instanceof Xt?(this.v=e,this):new Xt(e)}function Cf(e,n,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=t.apply(e,n||[]),o,i=[];return o=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",s),o[Symbol.asyncIterator]=function(){return this},o;function s(f){return function(v){return Promise.resolve(v).then(f,d)}}function a(f,v){r[f]&&(o[f]=function(m){return new Promise(function(y,C){i.push([f,m,y,C])>1||c(f,m)})},v&&(o[f]=v(o[f])))}function c(f,v){try{l(r[f](v))}catch(m){p(i[0][3],m)}}function l(f){f.value instanceof Xt?Promise.resolve(f.value.v).then(u,d):p(i[0][2],f)}function u(f){c("next",f)}function d(f){c("throw",f)}function p(f,v){f(v),i.shift(),i.length&&c(i[0][0],i[0][1])}}function Ef(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=e[Symbol.asyncIterator],t;return n?n.call(e):(e=typeof Df=="function"?Df(e):e[Symbol.iterator](),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(i){t[i]=e[i]&&function(s){return new Promise(function(a,c){s=e[i](s),o(a,c,s.done,s.value)})}}function o(i,s,a,c){Promise.resolve(c).then(function(l){i({value:l,done:a})},s)}}var Ni=e=>e&&typeof e.length=="number"&&typeof e!="function";function Ri(e){return T(e?.then)}function Pi(e){return T(e[Gn])}function ki(e){return Symbol.asyncIterator&&T(e?.[Symbol.asyncIterator])}function Fi(e){return new TypeError(`You provided ${e!==null&&typeof e=="object"?"an invalid object":`'${e}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function $y(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var Li=$y();function ji(e){return T(e?.[Li])}function Vi(e){return Cf(this,arguments,function*(){let t=e.getReader();try{for(;;){let{value:r,done:o}=yield Xt(t.read());if(o)return yield Xt(void 0);yield yield Xt(r)}}finally{t.releaseLock()}})}function $i(e){return T(e?.getReader)}function se(e){if(e instanceof B)return e;if(e!=null){if(Pi(e))return Uy(e);if(Ni(e))return By(e);if(Ri(e))return Hy(e);if(ki(e))return If(e);if(ji(e))return zy(e);if($i(e))return Gy(e)}throw Fi(e)}function Uy(e){return new B(n=>{let t=e[Gn]();if(T(t.subscribe))return t.subscribe(n);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function By(e){return new B(n=>{for(let t=0;t{e.then(t=>{n.closed||(n.next(t),n.complete())},t=>n.error(t)).then(null,xi)})}function zy(e){return new B(n=>{for(let t of e)if(n.next(t),n.closed)return;n.complete()})}function If(e){return new B(n=>{qy(e,n).catch(t=>n.error(t))})}function Gy(e){return If(Vi(e))}function qy(e,n){var t,r,o,i;return bf(this,void 0,void 0,function*(){try{for(t=Ef(e);r=yield t.next(),!r.done;){let s=r.value;if(n.next(s),n.closed)return}}catch(s){o={error:s}}finally{try{r&&!r.done&&(i=t.return)&&(yield i.call(t))}finally{if(o)throw o.error}}n.complete()})}function xe(e,n,t,r=0,o=!1){let i=n.schedule(function(){t(),o?e.add(this.schedule(null,r)):this.unsubscribe()},r);if(e.add(i),!o)return i}function Ui(e,n=0){return U((t,r)=>{t.subscribe(j(r,o=>xe(r,e,()=>r.next(o),n),()=>xe(r,e,()=>r.complete(),n),o=>xe(r,e,()=>r.error(o),n)))})}function Bi(e,n=0){return U((t,r)=>{r.add(e.schedule(()=>t.subscribe(r),n))})}function Mf(e,n){return se(e).pipe(Bi(n),Ui(n))}function Sf(e,n){return se(e).pipe(Bi(n),Ui(n))}function xf(e,n){return new B(t=>{let r=0;return n.schedule(function(){r===e.length?t.complete():(t.next(e[r++]),t.closed||this.schedule())})})}function Tf(e,n){return new B(t=>{let r;return xe(t,n,()=>{r=e[Li](),xe(t,n,()=>{let o,i;try{({value:o,done:i}=r.next())}catch(s){t.error(s);return}i?t.complete():t.next(o)},0,!0)}),()=>T(r?.return)&&r.return()})}function Hi(e,n){if(!e)throw new Error("Iterable cannot be null");return new B(t=>{xe(t,n,()=>{let r=e[Symbol.asyncIterator]();xe(t,n,()=>{r.next().then(o=>{o.done?t.complete():t.next(o.value)})},0,!0)})})}function Af(e,n){return Hi(Vi(e),n)}function Of(e,n){if(e!=null){if(Pi(e))return Mf(e,n);if(Ni(e))return xf(e,n);if(Ri(e))return Sf(e,n);if(ki(e))return Hi(e,n);if(ji(e))return Tf(e,n);if($i(e))return Af(e,n)}throw Fi(e)}function te(e,n){return n?Of(e,n):se(e)}function x(...e){let n=xt(e);return te(e,n)}function Zn(e,n){let t=T(e)?e:()=>e,r=o=>o.error(t());return new B(n?o=>n.schedule(r,0,o):r)}function wc(e){return!!e&&(e instanceof B||T(e.lift)&&T(e.subscribe))}var yt=Un(e=>function(){e(this),this.name="EmptyError",this.message="no elements in sequence"});function O(e,n){return U((t,r)=>{let o=0;t.subscribe(j(r,i=>{r.next(e.call(n,i,o++))}))})}var{isArray:Wy}=Array;function Zy(e,n){return Wy(n)?e(...n):e(n)}function zi(e){return O(n=>Zy(e,n))}var{isArray:Yy}=Array,{getPrototypeOf:Qy,prototype:Ky,keys:Jy}=Object;function Gi(e){if(e.length===1){let n=e[0];if(Yy(n))return{args:n,keys:null};if(Xy(n)){let t=Jy(n);return{args:t.map(r=>n[r]),keys:t}}}return{args:e,keys:null}}function Xy(e){return e&&typeof e=="object"&&Qy(e)===Ky}function qi(e,n){return e.reduce((t,r,o)=>(t[r]=n[o],t),{})}function Wi(...e){let n=xt(e),t=Oi(e),{args:r,keys:o}=Gi(e);if(r.length===0)return te([],n);let i=new B(ew(r,n,o?s=>qi(o,s):ke));return t?i.pipe(zi(t)):i}function ew(e,n,t=ke){return r=>{Nf(n,()=>{let{length:o}=e,i=new Array(o),s=o,a=o;for(let c=0;c{let l=te(e[c],n),u=!1;l.subscribe(j(r,d=>{i[c]=d,u||(u=!0,a--),a||r.next(t(i.slice()))},()=>{--s||r.complete()}))},r)},r)}}function Nf(e,n,t){e?xe(t,e,n):n()}function Rf(e,n,t,r,o,i,s,a){let c=[],l=0,u=0,d=!1,p=()=>{d&&!c.length&&!l&&n.complete()},f=m=>l{i&&n.next(m),l++;let y=!1;se(t(m,u++)).subscribe(j(n,C=>{o?.(C),i?f(C):n.next(C)},()=>{y=!0},void 0,()=>{if(y)try{for(l--;c.length&&lv(C)):v(C)}p()}catch(C){n.error(C)}}))};return e.subscribe(j(n,f,()=>{d=!0,p()})),()=>{a?.()}}function ue(e,n,t=1/0){return T(n)?ue((r,o)=>O((i,s)=>n(r,i,o,s))(se(e(r,o))),t):(typeof n=="number"&&(t=n),U((r,o)=>Rf(r,o,e,t)))}function _c(e=1/0){return ue(ke,e)}function Pf(){return _c(1)}function Yn(...e){return Pf()(te(e,xt(e)))}function Zi(e){return new B(n=>{se(e()).subscribe(n)})}function Dc(...e){let n=Oi(e),{args:t,keys:r}=Gi(e),o=new B(i=>{let{length:s}=t;if(!s){i.complete();return}let a=new Array(s),c=s,l=s;for(let u=0;u{d||(d=!0,l--),a[u]=p},()=>c--,void 0,()=>{(!c||!d)&&(l||i.next(r?qi(r,a):a),i.complete())}))}});return n?o.pipe(zi(n)):o}function Le(e,n){return U((t,r)=>{let o=0;t.subscribe(j(r,i=>e.call(n,i,o++)&&r.next(i)))})}function Tt(e){return U((n,t)=>{let r=null,o=!1,i;r=n.subscribe(j(t,void 0,void 0,s=>{i=se(e(s,Tt(e)(n))),r?(r.unsubscribe(),r=null,i.subscribe(t)):o=!0})),o&&(r.unsubscribe(),r=null,i.subscribe(t))})}function kf(e,n,t,r,o){return(i,s)=>{let a=t,c=n,l=0;i.subscribe(j(s,u=>{let d=l++;c=a?e(c,u,d):(a=!0,u),r&&s.next(c)},o&&(()=>{a&&s.next(c),s.complete()})))}}function At(e,n){return T(n)?ue(e,n,1):ue(e,1)}function Ot(e){return U((n,t)=>{let r=!1;n.subscribe(j(t,o=>{r=!0,t.next(o)},()=>{r||t.next(e),t.complete()}))})}function wt(e){return e<=0?()=>Fe:U((n,t)=>{let r=0;n.subscribe(j(t,o=>{++r<=e&&(t.next(o),e<=r&&t.complete())}))})}function bc(e){return O(()=>e)}function Yi(e=tw){return U((n,t)=>{let r=!1;n.subscribe(j(t,o=>{r=!0,t.next(o)},()=>r?t.complete():t.error(e())))})}function tw(){return new yt}function en(e){return U((n,t)=>{try{n.subscribe(t)}finally{t.add(e)}})}function ct(e,n){let t=arguments.length>=2;return r=>r.pipe(e?Le((o,i)=>e(o,i,r)):ke,wt(1),t?Ot(n):Yi(()=>new yt))}function Qn(e){return e<=0?()=>Fe:U((n,t)=>{let r=[];n.subscribe(j(t,o=>{r.push(o),e{for(let o of r)t.next(o);t.complete()},void 0,()=>{r=null}))})}function Cc(e,n){let t=arguments.length>=2;return r=>r.pipe(e?Le((o,i)=>e(o,i,r)):ke,Qn(1),t?Ot(n):Yi(()=>new yt))}function Ec(e,n){return U(kf(e,n,arguments.length>=2,!0))}function Ic(...e){let n=xt(e);return U((t,r)=>{(n?Yn(e,t,n):Yn(e,t)).subscribe(r)})}function je(e,n){return U((t,r)=>{let o=null,i=0,s=!1,a=()=>s&&!o&&r.complete();t.subscribe(j(r,c=>{o?.unsubscribe();let l=0,u=i++;se(e(c,u)).subscribe(o=j(r,d=>r.next(n?n(c,d,u,l++):d),()=>{o=null,a()}))},()=>{s=!0,a()}))})}function Mc(e){return U((n,t)=>{se(e).subscribe(j(t,()=>t.complete(),ro)),!t.closed&&n.subscribe(t)})}function fe(e,n,t){let r=T(e)||n||t?{next:e,error:n,complete:t}:e;return r?U((o,i)=>{var s;(s=r.subscribe)===null||s===void 0||s.call(r);let a=!0;o.subscribe(j(i,c=>{var l;(l=r.next)===null||l===void 0||l.call(r,c),i.next(c)},()=>{var c;a=!1,(c=r.complete)===null||c===void 0||c.call(r),i.complete()},c=>{var l;a=!1,(l=r.error)===null||l===void 0||l.call(r,c),i.error(c)},()=>{var c,l;a&&((c=r.unsubscribe)===null||c===void 0||c.call(r)),(l=r.finalize)===null||l===void 0||l.call(r)}))}):ke}var wh="https://g.co/ng/security#xss",I=class extends Error{constructor(n,t){super(Es(n,t)),this.code=n}};function Es(e,n){return`${`NG0${Math.abs(e)}`}${n?": "+n:""}`}var _h=Symbol("InputSignalNode#UNSET"),nw=G(_({},lc),{transformFn:void 0,applyValueToInputSignal(e,n){Ii(e,n)}});function Dh(e,n){let t=Object.create(nw);t.value=e,t.transformFn=n?.transform;function r(){if(ic(t),t.value===_h)throw new I(-950,!1);return t.value}return r[St]=t,r}function Is(e){return{toString:e}.toString()}var tn=globalThis;function Y(e){for(let n in e)if(e[n]===Y)return n;throw Error("Could not find renamed property on target object.")}function rw(e,n){for(let t in n)n.hasOwnProperty(t)&&!e.hasOwnProperty(t)&&(e[t]=n[t])}function Te(e){if(typeof e=="string")return e;if(Array.isArray(e))return"["+e.map(Te).join(", ")+"]";if(e==null)return""+e;if(e.overriddenName)return`${e.overriddenName}`;if(e.name)return`${e.name}`;let n=e.toString();if(n==null)return""+n;let t=n.indexOf(` +`);return t===-1?n:n.substring(0,t)}function Ff(e,n){return e==null||e===""?n===null?"":n:n==null||n===""?e:e+" "+n}var ow=Y({__forward_ref__:Y});function dr(e){return e.__forward_ref__=dr,e.toString=function(){return Te(this())},e}function Ee(e){return bh(e)?e():e}function bh(e){return typeof e=="function"&&e.hasOwnProperty(ow)&&e.__forward_ref__===dr}function E(e){return{token:e.token,providedIn:e.providedIn||null,factory:e.factory,value:void 0}}function fn(e){return{providers:e.providers||[],imports:e.imports||[]}}function Ms(e){return Lf(e,Eh)||Lf(e,Ih)}function Ch(e){return Ms(e)!==null}function Lf(e,n){return e.hasOwnProperty(n)?e[n]:null}function iw(e){let n=e&&(e[Eh]||e[Ih]);return n||null}function jf(e){return e&&(e.hasOwnProperty(Vf)||e.hasOwnProperty(sw))?e[Vf]:null}var Eh=Y({\u0275prov:Y}),Vf=Y({\u0275inj:Y}),Ih=Y({ngInjectableDef:Y}),sw=Y({ngInjectorDef:Y}),M=class{constructor(n,t){this._desc=n,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,typeof t=="number"?this.__NG_ELEMENT_ID__=t:t!==void 0&&(this.\u0275prov=E({token:this,providedIn:t.providedIn||"root",factory:t.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}};function Mh(e){return e&&!!e.\u0275providers}var aw=Y({\u0275cmp:Y}),cw=Y({\u0275dir:Y}),lw=Y({\u0275pipe:Y}),uw=Y({\u0275mod:Y}),is=Y({\u0275fac:Y}),oo=Y({__NG_ELEMENT_ID__:Y}),$f=Y({__NG_ENV_ID__:Y});function Ss(e){return typeof e=="string"?e:e==null?"":String(e)}function dw(e){return typeof e=="function"?e.name||e.toString():typeof e=="object"&&e!=null&&typeof e.type=="function"?e.type.name||e.type.toString():Ss(e)}function fw(e,n){let t=n?`. Dependency path: ${n.join(" > ")} > ${e}`:"";throw new I(-200,e)}function Nl(e,n){throw new I(-201,!1)}var k=function(e){return e[e.Default=0]="Default",e[e.Host=1]="Host",e[e.Self=2]="Self",e[e.SkipSelf=4]="SkipSelf",e[e.Optional=8]="Optional",e}(k||{}),Bc;function Sh(){return Bc}function ze(e){let n=Bc;return Bc=e,n}function xh(e,n,t){let r=Ms(e);if(r&&r.providedIn=="root")return r.value===void 0?r.value=r.factory():r.value;if(t&k.Optional)return null;if(n!==void 0)return n;Nl(e,"Injector")}var hw={},io=hw,pw="__NG_DI_FLAG__",ss="ngTempTokenPath",gw="ngTokenPath",mw=/\n/gm,vw="\u0275",Uf="__source",er;function yw(){return er}function Nt(e){let n=er;return er=e,n}function ww(e,n=k.Default){if(er===void 0)throw new I(-203,!1);return er===null?xh(e,void 0,n):er.get(e,n&k.Optional?null:void 0,n)}function A(e,n=k.Default){return(Sh()||ww)(Ee(e),n)}function g(e,n=k.Default){return A(e,xs(n))}function xs(e){return typeof e>"u"||typeof e=="number"?e:0|(e.optional&&8)|(e.host&&1)|(e.self&&2)|(e.skipSelf&&4)}function Hc(e){let n=[];for(let t=0;t ");else if(typeof n=="object"){let i=[];for(let s in n)if(n.hasOwnProperty(s)){let a=n[s];i.push(s+":"+(typeof a=="string"?JSON.stringify(a):Te(a)))}o=`{${i.join(", ")}}`}return`${t}${r?"("+r+")":""}[${o}]: ${e.replace(mw,` + `)}`}function nr(e,n){let t=e.hasOwnProperty(is);return t?e[is]:null}function Rl(e,n){e.forEach(t=>Array.isArray(t)?Rl(t,n):n(t))}function Th(e,n,t){n>=e.length?e.push(t):e.splice(n,0,t)}function as(e,n){return n>=e.length-1?e.pop():e.splice(n,1)[0]}function Cw(e,n,t,r){let o=e.length;if(o==n)e.push(t,r);else if(o===1)e.push(r,e[0]),e[0]=t;else{for(o--,e.push(e[o-1],e[o]);o>n;){let i=o-2;e[o]=e[i],o--}e[n]=t,e[n+1]=r}}function Ew(e,n,t){let r=Do(e,n);return r>=0?e[r|1]=t:(r=~r,Cw(e,r,n,t)),r}function Sc(e,n){let t=Do(e,n);if(t>=0)return e[t|1]}function Do(e,n){return Iw(e,n,1)}function Iw(e,n,t){let r=0,o=e.length>>t;for(;o!==r;){let i=r+(o-r>>1),s=e[i<n?o=i:r=i+1}return~(o<n){s=i-1;break}}}for(;i-1){let i;for(;++oi?d="":d=o[u+1].toLowerCase(),r&2&&l!==d){if(Xe(r))return!1;s=!0}}}}return Xe(r)||s}function Xe(e){return(e&1)===0}function Ow(e,n,t,r){if(n===null)return-1;let o=0;if(r||!t){let i=!1;for(;o-1)for(t++;t0?'="'+a+'"':"")+"]"}else r&8?o+="."+s:r&4&&(o+=" "+s);else o!==""&&!Xe(s)&&(n+=Hf(i,o),o=""),r=s,i=i||!Xe(r);t++}return o!==""&&(n+=Hf(i,o)),n}function Fw(e){return e.map(kw).join(",")}function Lw(e){let n=[],t=[],r=1,o=2;for(;r{let n=Vh(e),t=G(_({},n),{decls:e.decls,vars:e.vars,template:e.template,consts:e.consts||null,ngContentSelectors:e.ngContentSelectors,onPush:e.changeDetection===Nh.OnPush,directiveDefs:null,pipeDefs:null,dependencies:n.standalone&&e.dependencies||null,getStandaloneInjector:null,signals:e.signals??!1,data:e.data||{},encapsulation:e.encapsulation||dt.Emulated,styles:e.styles||Ge,_:null,schemas:e.schemas||null,tView:null,id:""});$h(t);let r=e.dependencies;return t.directiveDefs=Gf(r,!1),t.pipeDefs=Gf(r,!0),t.id=$w(t),t})}function jw(e){return on(e)||kh(e)}function Vw(e){return e!==null}function hn(e){return Is(()=>({type:e.type,bootstrap:e.bootstrap||Ge,declarations:e.declarations||Ge,imports:e.imports||Ge,exports:e.exports||Ge,transitiveCompileScopes:null,schemas:e.schemas||null,id:e.id||null}))}function zf(e,n){if(e==null)return rr;let t={};for(let r in e)if(e.hasOwnProperty(r)){let o=e[r],i,s,a=ne.None;Array.isArray(o)?(a=o[0],i=o[1],s=o[2]??i):(i=o,s=o),n?(t[i]=a!==ne.None?[r,a]:r,n[i]=s):t[i]=r}return t}function Ve(e){return Is(()=>{let n=Vh(e);return $h(n),n})}function on(e){return e[aw]||null}function kh(e){return e[cw]||null}function Fh(e){return e[lw]||null}function Lh(e){let n=on(e)||kh(e)||Fh(e);return n!==null?n.standalone:!1}function jh(e,n){let t=e[uw]||null;if(!t&&n===!0)throw new Error(`Type ${Te(e)} does not have '\u0275mod' property.`);return t}function Vh(e){let n={};return{type:e.type,providersResolver:null,factory:null,hostBindings:e.hostBindings||null,hostVars:e.hostVars||0,hostAttrs:e.hostAttrs||null,contentQueries:e.contentQueries||null,declaredInputs:n,inputTransforms:null,inputConfig:e.inputs||rr,exportAs:e.exportAs||null,standalone:e.standalone===!0,signals:e.signals===!0,selectors:e.selectors||Ge,viewQuery:e.viewQuery||null,features:e.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:zf(e.inputs,n),outputs:zf(e.outputs),debugInfo:null}}function $h(e){e.features?.forEach(n=>n(e))}function Gf(e,n){if(!e)return null;let t=n?Fh:jw;return()=>(typeof e=="function"?e():e).map(r=>t(r)).filter(Vw)}function $w(e){let n=0,t=[e.selectors,e.ngContentSelectors,e.hostVars,e.hostAttrs,e.consts,e.vars,e.decls,e.encapsulation,e.standalone,e.signals,e.exportAs,JSON.stringify(e.inputs),JSON.stringify(e.outputs),Object.getOwnPropertyNames(e.type.prototype),!!e.contentQueries,!!e.viewQuery].join("|");for(let o of t)n=Math.imul(31,n)+o.charCodeAt(0)<<0;return n+=2147483648,"c"+n}function fr(e){return{\u0275providers:e}}function Uw(...e){return{\u0275providers:Uh(!0,e),\u0275fromNgModule:!0}}function Uh(e,...n){let t=[],r=new Set,o,i=s=>{t.push(s)};return Rl(n,s=>{let a=s;Gc(a,i,[],r)&&(o||=[],o.push(a))}),o!==void 0&&Bh(o,i),t}function Bh(e,n){for(let t=0;t{n(i,r)})}}function Gc(e,n,t,r){if(e=Ee(e),!e)return!1;let o=null,i=jf(e),s=!i&&on(e);if(!i&&!s){let c=e.ngModule;if(i=jf(c),i)o=c;else return!1}else{if(s&&!s.standalone)return!1;o=e}let a=r.has(o);if(s){if(a)return!1;if(r.add(o),s.dependencies){let c=typeof s.dependencies=="function"?s.dependencies():s.dependencies;for(let l of c)Gc(l,n,t,r)}}else if(i){if(i.imports!=null&&!a){r.add(o);let l;try{Rl(i.imports,u=>{Gc(u,n,t,r)&&(l||=[],l.push(u))})}finally{}l!==void 0&&Bh(l,n)}if(!a){let l=nr(o)||(()=>new o);n({provide:o,useFactory:l,deps:Ge},o),n({provide:Oh,useValue:o,multi:!0},o),n({provide:or,useValue:()=>A(o),multi:!0},o)}let c=i.providers;if(c!=null&&!a){let l=e;kl(c,u=>{n(u,l)})}}else return!1;return o!==e&&e.providers!==void 0}function kl(e,n){for(let t of e)Mh(t)&&(t=t.\u0275providers),Array.isArray(t)?kl(t,n):n(t)}var Bw=Y({provide:String,useValue:Y});function Hh(e){return e!==null&&typeof e=="object"&&Bw in e}function Hw(e){return!!(e&&e.useExisting)}function zw(e){return!!(e&&e.useFactory)}function ir(e){return typeof e=="function"}function Gw(e){return!!e.useClass}var Ts=new M(""),Xi={},qw={},xc;function Fl(){return xc===void 0&&(xc=new cs),xc}var Ae=class{},ao=class extends Ae{get destroyed(){return this._destroyed}constructor(n,t,r,o){super(),this.parent=t,this.source=r,this.scopes=o,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,Wc(n,s=>this.processProvider(s)),this.records.set(Ah,Kn(void 0,this)),o.has("environment")&&this.records.set(Ae,Kn(void 0,this));let i=this.records.get(Ts);i!=null&&typeof i.value=="string"&&this.scopes.add(i.value),this.injectorDefTypes=new Set(this.get(Oh,Ge,k.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;let n=L(null);try{for(let r of this._ngOnDestroyHooks)r.ngOnDestroy();let t=this._onDestroyHooks;this._onDestroyHooks=[];for(let r of t)r()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),L(n)}}onDestroy(n){return this.assertNotDestroyed(),this._onDestroyHooks.push(n),()=>this.removeOnDestroy(n)}runInContext(n){this.assertNotDestroyed();let t=Nt(this),r=ze(void 0),o;try{return n()}finally{Nt(t),ze(r)}}get(n,t=io,r=k.Default){if(this.assertNotDestroyed(),n.hasOwnProperty($f))return n[$f](this);r=xs(r);let o,i=Nt(this),s=ze(void 0);try{if(!(r&k.SkipSelf)){let c=this.records.get(n);if(c===void 0){let l=Kw(n)&&Ms(n);l&&this.injectableDefInScope(l)?c=Kn(qc(n),Xi):c=null,this.records.set(n,c)}if(c!=null)return this.hydrate(n,c)}let a=r&k.Self?Fl():this.parent;return t=r&k.Optional&&t===io?null:t,a.get(n,t)}catch(a){if(a.name==="NullInjectorError"){if((a[ss]=a[ss]||[]).unshift(Te(n)),i)throw a;return Dw(a,n,"R3InjectorError",this.source)}else throw a}finally{ze(s),Nt(i)}}resolveInjectorInitializers(){let n=L(null),t=Nt(this),r=ze(void 0),o;try{let i=this.get(or,Ge,k.Self);for(let s of i)s()}finally{Nt(t),ze(r),L(n)}}toString(){let n=[],t=this.records;for(let r of t.keys())n.push(Te(r));return`R3Injector[${n.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new I(205,!1)}processProvider(n){n=Ee(n);let t=ir(n)?n:Ee(n&&n.provide),r=Zw(n);if(!ir(n)&&n.multi===!0){let o=this.records.get(t);o||(o=Kn(void 0,Xi,!0),o.factory=()=>Hc(o.multi),this.records.set(t,o)),t=n,o.multi.push(n)}this.records.set(t,r)}hydrate(n,t){let r=L(null);try{return t.value===Xi&&(t.value=qw,t.value=t.factory()),typeof t.value=="object"&&t.value&&Qw(t.value)&&this._ngOnDestroyHooks.add(t.value),t.value}finally{L(r)}}injectableDefInScope(n){if(!n.providedIn)return!1;let t=Ee(n.providedIn);return typeof t=="string"?t==="any"||this.scopes.has(t):this.injectorDefTypes.has(t)}removeOnDestroy(n){let t=this._onDestroyHooks.indexOf(n);t!==-1&&this._onDestroyHooks.splice(t,1)}};function qc(e){let n=Ms(e),t=n!==null?n.factory:nr(e);if(t!==null)return t;if(e instanceof M)throw new I(204,!1);if(e instanceof Function)return Ww(e);throw new I(204,!1)}function Ww(e){if(e.length>0)throw new I(204,!1);let t=iw(e);return t!==null?()=>t.factory(e):()=>new e}function Zw(e){if(Hh(e))return Kn(void 0,e.useValue);{let n=zh(e);return Kn(n,Xi)}}function zh(e,n,t){let r;if(ir(e)){let o=Ee(e);return nr(o)||qc(o)}else if(Hh(e))r=()=>Ee(e.useValue);else if(zw(e))r=()=>e.useFactory(...Hc(e.deps||[]));else if(Hw(e))r=()=>A(Ee(e.useExisting));else{let o=Ee(e&&(e.useClass||e.provide));if(Yw(e))r=()=>new o(...Hc(e.deps));else return nr(o)||qc(o)}return r}function Kn(e,n,t=!1){return{factory:e,value:n,multi:t?[]:void 0}}function Yw(e){return!!e.deps}function Qw(e){return e!==null&&typeof e=="object"&&typeof e.ngOnDestroy=="function"}function Kw(e){return typeof e=="function"||typeof e=="object"&&e instanceof M}function Wc(e,n){for(let t of e)Array.isArray(t)?Wc(t,n):t&&Mh(t)?Wc(t.\u0275providers,n):n(t)}function Dt(e,n){e instanceof ao&&e.assertNotDestroyed();let t,r=Nt(e),o=ze(void 0);try{return n()}finally{Nt(r),ze(o)}}function Gh(){return Sh()!==void 0||yw()!=null}function Jw(e){if(!Gh())throw new I(-203,!1)}function Xw(e){return typeof e=="function"}var bt=0,P=1,S=2,be=3,et=4,it=5,co=6,lo=7,De=8,sr=9,tt=10,he=11,uo=12,qf=13,hr=14,nt=15,As=16,Jn=17,ar=18,Os=19,qh=20,Rt=21,es=22,sn=23,rt=25,Wh=1;var an=7,ls=8,us=9,Ie=10,Ll=function(e){return e[e.None=0]="None",e[e.HasTransplantedViews=2]="HasTransplantedViews",e}(Ll||{});function nn(e){return Array.isArray(e)&&typeof e[Wh]=="object"}function Ct(e){return Array.isArray(e)&&e[Wh]===!0}function Zh(e){return(e.flags&4)!==0}function Ns(e){return e.componentOffset>-1}function jl(e){return(e.flags&1)===1}function Pt(e){return!!e.template}function e_(e){return(e[S]&512)!==0}var Zc=class{constructor(n,t,r){this.previousValue=n,this.currentValue=t,this.firstChange=r}isFirstChange(){return this.firstChange}};function Yh(e,n,t,r){n!==null?n.applyValueToInputSignal(n,r):e[t]=r}function Ft(){return Qh}function Qh(e){return e.type.prototype.ngOnChanges&&(e.setInput=n_),t_}Ft.ngInherit=!0;function t_(){let e=Jh(this),n=e?.current;if(n){let t=e.previous;if(t===rr)e.previous=n;else for(let r in n)t[r]=n[r];e.current=null,this.ngOnChanges(n)}}function n_(e,n,t,r,o){let i=this.declaredInputs[r],s=Jh(e)||r_(e,{previous:rr,current:null}),a=s.current||(s.current={}),c=s.previous,l=c[i];a[i]=new Zc(l&&l.currentValue,t,c===rr),Yh(e,n,o,t)}var Kh="__ngSimpleChanges__";function Jh(e){return e[Kh]||null}function r_(e,n){return e[Kh]=n}var Wf=null;var lt=function(e,n,t){Wf?.(e,n,t)},o_="svg",i_="math",s_=!1;function a_(){return s_}function ft(e){for(;Array.isArray(e);)e=e[bt];return e}function Xh(e,n){return ft(n[e])}function qe(e,n){return ft(n[e.index])}function Vl(e,n){return e.data[n]}function Lt(e,n){let t=n[e];return nn(t)?t:t[bt]}function $l(e){return(e[S]&128)===128}function c_(e){return Ct(e[be])}function ds(e,n){return n==null?null:e[n]}function ep(e){e[Jn]=0}function l_(e){e[S]&1024||(e[S]|=1024,$l(e)&&fo(e))}function u_(e,n){for(;e>0;)n=n[hr],e--;return n}function Ul(e){return!!(e[S]&9216||e[sn]?.dirty)}function Yc(e){e[tt].changeDetectionScheduler?.notify(1),Ul(e)?fo(e):e[S]&64&&(a_()?(e[S]|=1024,fo(e)):e[tt].changeDetectionScheduler?.notify())}function fo(e){e[tt].changeDetectionScheduler?.notify();let n=ho(e);for(;n!==null&&!(n[S]&8192||(n[S]|=8192,!$l(n)));)n=ho(n)}function tp(e,n){if((e[S]&256)===256)throw new I(911,!1);e[Rt]===null&&(e[Rt]=[]),e[Rt].push(n)}function d_(e,n){if(e[Rt]===null)return;let t=e[Rt].indexOf(n);t!==-1&&e[Rt].splice(t,1)}function ho(e){let n=e[be];return Ct(n)?n[be]:n}var V={lFrame:up(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function f_(){return V.lFrame.elementDepthCount}function h_(){V.lFrame.elementDepthCount++}function p_(){V.lFrame.elementDepthCount--}function np(){return V.bindingsEnabled}function g_(){return V.skipHydrationRootTNode!==null}function m_(e){return V.skipHydrationRootTNode===e}function v_(){V.skipHydrationRootTNode=null}function Q(){return V.lFrame.lView}function We(){return V.lFrame.tView}function rp(e){return V.lFrame.contextLView=e,e[De]}function op(e){return V.lFrame.contextLView=null,e}function Ze(){let e=ip();for(;e!==null&&e.type===64;)e=e.parent;return e}function ip(){return V.lFrame.currentTNode}function y_(){let e=V.lFrame,n=e.currentTNode;return e.isParent?n:n.parent}function bo(e,n){let t=V.lFrame;t.currentTNode=e,t.isParent=n}function sp(){return V.lFrame.isParent}function w_(){V.lFrame.isParent=!1}function __(e){return V.lFrame.bindingIndex=e}function Co(){return V.lFrame.bindingIndex++}function D_(e){let n=V.lFrame,t=n.bindingIndex;return n.bindingIndex=n.bindingIndex+e,t}function b_(){return V.lFrame.inI18n}function C_(e,n){let t=V.lFrame;t.bindingIndex=t.bindingRootIndex=e,Qc(n)}function E_(){return V.lFrame.currentDirectiveIndex}function Qc(e){V.lFrame.currentDirectiveIndex=e}function I_(e){let n=V.lFrame.currentDirectiveIndex;return n===-1?null:e[n]}function ap(e){V.lFrame.currentQueryIndex=e}function M_(e){let n=e[P];return n.type===2?n.declTNode:n.type===1?e[it]:null}function cp(e,n,t){if(t&k.SkipSelf){let o=n,i=e;for(;o=o.parent,o===null&&!(t&k.Host);)if(o=M_(i),o===null||(i=i[hr],o.type&10))break;if(o===null)return!1;n=o,e=i}let r=V.lFrame=lp();return r.currentTNode=n,r.lView=e,!0}function Bl(e){let n=lp(),t=e[P];V.lFrame=n,n.currentTNode=t.firstChild,n.lView=e,n.tView=t,n.contextLView=e,n.bindingIndex=t.bindingStartIndex,n.inI18n=!1}function lp(){let e=V.lFrame,n=e===null?null:e.child;return n===null?up(e):n}function up(e){let n={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:e,child:null,inI18n:!1};return e!==null&&(e.child=n),n}function dp(){let e=V.lFrame;return V.lFrame=e.parent,e.currentTNode=null,e.lView=null,e}var fp=dp;function Hl(){let e=dp();e.isParent=!0,e.tView=null,e.selectedIndex=-1,e.contextLView=null,e.elementDepthCount=0,e.currentDirectiveIndex=-1,e.currentNamespace=null,e.bindingRootIndex=-1,e.bindingIndex=-1,e.currentQueryIndex=0}function S_(e){return(V.lFrame.contextLView=u_(e,V.lFrame.contextLView))[De]}function pn(){return V.lFrame.selectedIndex}function cn(e){V.lFrame.selectedIndex=e}function zl(){let e=V.lFrame;return Vl(e.tView,e.selectedIndex)}function x_(){return V.lFrame.currentNamespace}var hp=!0;function Gl(){return hp}function ql(e){hp=e}function T_(e,n,t){let{ngOnChanges:r,ngOnInit:o,ngDoCheck:i}=n.type.prototype;if(r){let s=Qh(n);(t.preOrderHooks??=[]).push(e,s),(t.preOrderCheckHooks??=[]).push(e,s)}o&&(t.preOrderHooks??=[]).push(0-e,o),i&&((t.preOrderHooks??=[]).push(e,i),(t.preOrderCheckHooks??=[]).push(e,i))}function Wl(e,n){for(let t=n.directiveStart,r=n.directiveEnd;t=r)break}else n[c]<0&&(e[Jn]+=65536),(a>14>16&&(e[S]&3)===n&&(e[S]+=16384,Zf(a,i)):Zf(a,i)}var tr=-1,ln=class{constructor(n,t,r){this.factory=n,this.resolving=!1,this.canSeeViewProviders=t,this.injectImpl=r}};function O_(e){return e instanceof ln}function N_(e){return(e.flags&8)!==0}function R_(e){return(e.flags&16)!==0}function gp(e){return e!==tr}function fs(e){return e&32767}function P_(e){return e>>16}function hs(e,n){let t=P_(e),r=n;for(;t>0;)r=r[hr],t--;return r}var Kc=!0;function Yf(e){let n=Kc;return Kc=e,n}var k_=256,mp=k_-1,vp=5,F_=0,ut={};function L_(e,n,t){let r;typeof t=="string"?r=t.charCodeAt(0)||0:t.hasOwnProperty(oo)&&(r=t[oo]),r==null&&(r=t[oo]=F_++);let o=r&mp,i=1<>vp)]|=i}function ps(e,n){let t=yp(e,n);if(t!==-1)return t;let r=n[P];r.firstCreatePass&&(e.injectorIndex=n.length,Ac(r.data,e),Ac(n,null),Ac(r.blueprint,null));let o=Zl(e,n),i=e.injectorIndex;if(gp(o)){let s=fs(o),a=hs(o,n),c=a[P].data;for(let l=0;l<8;l++)n[i+l]=a[s+l]|c[s+l]}return n[i+8]=o,i}function Ac(e,n){e.push(0,0,0,0,0,0,0,0,n)}function yp(e,n){return e.injectorIndex===-1||e.parent&&e.parent.injectorIndex===e.injectorIndex||n[e.injectorIndex+8]===null?-1:e.injectorIndex}function Zl(e,n){if(e.parent&&e.parent.injectorIndex!==-1)return e.parent.injectorIndex;let t=0,r=null,o=n;for(;o!==null;){if(r=Cp(o),r===null)return tr;if(t++,o=o[hr],r.injectorIndex!==-1)return r.injectorIndex|t<<16}return tr}function Jc(e,n,t){L_(e,n,t)}function j_(e,n){if(n==="class")return e.classes;if(n==="style")return e.styles;let t=e.attrs;if(t){let r=t.length,o=0;for(;o>20,d=r?a:a+u,p=o?a+u:l;for(let f=d;f=c&&v.type===t)return f}if(o){let f=s[c];if(f&&Pt(f)&&f.type===t)return c}return null}function cr(e,n,t,r){let o=e[t],i=n.data;if(O_(o)){let s=o;s.resolving&&fw(dw(i[t]));let a=Yf(s.canSeeViewProviders);s.resolving=!0;let c,l=s.injectImpl?ze(s.injectImpl):null,u=cp(e,r,k.Default);try{o=e[t]=s.factory(void 0,i,e,r),n.firstCreatePass&&t>=r.directiveStart&&T_(t,i[t],n)}finally{l!==null&&ze(l),Yf(a),s.resolving=!1,fp()}}return o}function U_(e){if(typeof e=="string")return e.charCodeAt(0)||0;let n=e.hasOwnProperty(oo)?e[oo]:void 0;return typeof n=="number"?n>=0?n&mp:B_:n}function Qf(e,n,t){let r=1<>vp)]&r)}function Kf(e,n){return!(e&k.Self)&&!(e&k.Host&&n)}var rn=class{constructor(n,t){this._tNode=n,this._lView=t}get(n,t,r){return Dp(this._tNode,this._lView,n,xs(r),t)}};function B_(){return new rn(Ze(),Q())}function Eo(e){return Is(()=>{let n=e.prototype.constructor,t=n[is]||Xc(n),r=Object.prototype,o=Object.getPrototypeOf(e.prototype).constructor;for(;o&&o!==r;){let i=o[is]||Xc(o);if(i&&i!==t)return i;o=Object.getPrototypeOf(o)}return i=>new i})}function Xc(e){return bh(e)?()=>{let n=Xc(Ee(e));return n&&n()}:nr(e)}function H_(e,n,t,r,o){let i=e,s=n;for(;i!==null&&s!==null&&s[S]&2048&&!(s[S]&512);){let a=bp(i,s,t,r|k.Self,ut);if(a!==ut)return a;let c=i.parent;if(!c){let l=s[qh];if(l){let u=l.get(t,ut,r);if(u!==ut)return u}c=Cp(s),s=s[hr]}i=c}return o}function Cp(e){let n=e[P],t=n.type;return t===2?n.declTNode:t===1?e[it]:null}function Yl(e){return j_(Ze(),e)}function Jf(e,n=null,t=null,r){let o=Ep(e,n,t,r);return o.resolveInjectorInitializers(),o}function Ep(e,n=null,t=null,r,o=new Set){let i=[t||Ge,Uw(e)];return r=r||(typeof e=="object"?void 0:Te(e)),new ao(i,n||Fl(),r||null,o)}var gn=(()=>{class e{static{this.THROW_IF_NOT_FOUND=io}static{this.NULL=new cs}static create(t,r){if(Array.isArray(t))return Jf({name:""},r,t,"");{let o=t.name??"";return Jf({name:o},t.parent,t.providers,o)}}static{this.\u0275prov=E({token:e,providedIn:"any",factory:()=>A(Ah)})}static{this.__NG_ELEMENT_ID__=-1}}return e})();var z_="ngOriginalError";function Oc(e){return e[z_]}var ot=class{constructor(){this._console=console}handleError(n){let t=this._findOriginalError(n);this._console.error("ERROR",n),t&&this._console.error("ORIGINAL ERROR",t)}_findOriginalError(n){let t=n&&Oc(n);for(;t&&Oc(t);)t=Oc(t);return t||null}},Ip=new M("",{providedIn:"root",factory:()=>g(ot).handleError.bind(void 0)}),Rs=(()=>{class e{static{this.__NG_ELEMENT_ID__=G_}static{this.__NG_ENV_ID__=t=>t}}return e})(),el=class extends Rs{constructor(n){super(),this._lView=n}onDestroy(n){return tp(this._lView,n),()=>d_(this._lView,n)}};function G_(){return new el(Q())}var tl=class{constructor(){this.destroyed=!1,this.listeners=null,this.errorHandler=g(ot,{optional:!0}),this.destroyRef=g(Rs),this.destroyRef.onDestroy(()=>{this.destroyed=!0,this.listeners=null})}subscribe(n){if(this.destroyed)throw new I(953,!1);return(this.listeners??=[]).push(n),{unsubscribe:()=>{let t=this.listeners?.indexOf(n);t!==void 0&&t!==-1&&this.listeners?.splice(t,1)}}}emit(n){if(this.destroyed)throw new I(953,!1);if(this.listeners===null)return;let t=L(null);try{for(let r of this.listeners)try{r(n)}catch(o){this.errorHandler?.handleError(o)}}finally{L(t)}}};function Ps(e){return new tl}function Xf(e,n){return Dh(e,n)}function q_(e){return Dh(_h,e)}var pr=(Xf.required=q_,Xf);function W_(){return Ql(Ze(),Q())}function Ql(e,n){return new jt(qe(e,n))}var jt=(()=>{class e{constructor(t){this.nativeElement=t}static{this.__NG_ELEMENT_ID__=W_}}return e})();var nl=class extends we{constructor(n=!1){super(),this.destroyRef=void 0,this.__isAsync=n,Gh()&&(this.destroyRef=g(Rs,{optional:!0})??void 0)}emit(n){let t=L(null);try{super.next(n)}finally{L(t)}}subscribe(n,t,r){let o=n,i=t||(()=>null),s=r;if(n&&typeof n=="object"){let c=n;o=c.next?.bind(c),i=c.error?.bind(c),s=c.complete?.bind(c)}this.__isAsync&&(i=Nc(i),o&&(o=Nc(o)),s&&(s=Nc(s)));let a=super.subscribe({next:o,error:i,complete:s});return n instanceof le&&n.add(a),a}};function Nc(e){return n=>{setTimeout(e,void 0,n)}}var _e=nl;function Mp(e){return(e.flags&128)===128}var Sp=new Map,Z_=0;function Y_(){return Z_++}function Q_(e){Sp.set(e[Os],e)}function K_(e){Sp.delete(e[Os])}var eh="__ngContext__";function un(e,n){nn(n)?(e[eh]=n[Os],Q_(n)):e[eh]=n}function xp(e){return Ap(e[uo])}function Tp(e){return Ap(e[et])}function Ap(e){for(;e!==null&&!Ct(e);)e=e[et];return e}var rl;function Op(e){rl=e}function J_(){if(rl!==void 0)return rl;if(typeof document<"u")return document;throw new I(210,!1)}var Kl=new M("",{providedIn:"root",factory:()=>X_}),X_="ng",Jl=new M(""),Vt=new M("",{providedIn:"platform",factory:()=>"unknown"});var Xl=new M("",{providedIn:"root",factory:()=>J_().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});var eD="h",tD="b";var nD=()=>null;function eu(e,n,t=!1){return nD(e,n,t)}var Np=!1,rD=new M("",{providedIn:"root",factory:()=>Np});var Qi;function oD(){if(Qi===void 0&&(Qi=null,tn.trustedTypes))try{Qi=tn.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return Qi}function th(e){return oD()?.createScriptURL(e)||e}var gs=class{constructor(n){this.changingThisBreaksApplicationSecurity=n}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${wh})`}};function Io(e){return e instanceof gs?e.changingThisBreaksApplicationSecurity:e}function tu(e,n){let t=iD(e);if(t!=null&&t!==n){if(t==="ResourceURL"&&n==="URL")return!0;throw new Error(`Required a safe ${n}, got a ${t} (see ${wh})`)}return t===n}function iD(e){return e instanceof gs&&e.getTypeName()||null}var sD=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function Rp(e){return e=String(e),e.match(sD)?e:"unsafe:"+e}var ks=function(e){return e[e.NONE=0]="NONE",e[e.HTML=1]="HTML",e[e.STYLE=2]="STYLE",e[e.SCRIPT=3]="SCRIPT",e[e.URL=4]="URL",e[e.RESOURCE_URL=5]="RESOURCE_URL",e}(ks||{});function aD(e){let n=kp();return n?n.sanitize(ks.URL,e)||"":tu(e,"URL")?Io(e):Rp(Ss(e))}function cD(e){let n=kp();if(n)return th(n.sanitize(ks.RESOURCE_URL,e)||"");if(tu(e,"ResourceURL"))return th(Io(e));throw new I(904,!1)}function lD(e,n){return n==="src"&&(e==="embed"||e==="frame"||e==="iframe"||e==="media"||e==="script")||n==="href"&&(e==="base"||e==="link")?cD:aD}function Pp(e,n,t){return lD(n,t)(e)}function kp(){let e=Q();return e&&e[tt].sanitizer}function Fp(e){return e instanceof Function?e():e}var _t=function(e){return e[e.Important=1]="Important",e[e.DashCase=2]="DashCase",e}(_t||{}),uD;function nu(e,n){return uD(e,n)}function Xn(e,n,t,r,o){if(r!=null){let i,s=!1;Ct(r)?i=r:nn(r)&&(s=!0,r=r[bt]);let a=ft(r);e===0&&t!==null?o==null?$p(n,t,a):ms(n,t,a,o||null,!0):e===1&&t!==null?ms(n,t,a,o||null,!0):e===2?SD(n,a,s):e===3&&n.destroyNode(a),i!=null&&TD(n,e,i,t,o)}}function dD(e,n){return e.createText(n)}function fD(e,n,t){e.setValue(n,t)}function Lp(e,n,t){return e.createElement(n,t)}function hD(e,n){jp(e,n),n[bt]=null,n[it]=null}function pD(e,n,t,r,o,i){r[bt]=o,r[it]=n,Ls(e,r,t,1,o,i)}function jp(e,n){n[tt].changeDetectionScheduler?.notify(1),Ls(e,n,n[he],2,null,null)}function gD(e){let n=e[uo];if(!n)return Rc(e[P],e);for(;n;){let t=null;if(nn(n))t=n[uo];else{let r=n[Ie];r&&(t=r)}if(!t){for(;n&&!n[et]&&n!==e;)nn(n)&&Rc(n[P],n),n=n[be];n===null&&(n=e),nn(n)&&Rc(n[P],n),t=n&&n[et]}n=t}}function mD(e,n,t,r){let o=Ie+r,i=t.length;r>0&&(t[o-1][et]=n),r0&&(e[t-1][et]=r[et]);let i=as(e,Ie+n);hD(r[P],r);let s=i[ar];s!==null&&s.detachView(i[P]),r[be]=null,r[et]=null,r[S]&=-129}return r}function Fs(e,n){if(!(n[S]&256)){let t=n[he];t.destroyNode&&Ls(e,n,t,3,null,null),gD(n)}}function Rc(e,n){if(n[S]&256)return;let t=L(null);try{n[S]&=-129,n[S]|=256,n[sn]&&cc(n[sn]),wD(e,n),yD(e,n),n[P].type===1&&n[he].destroy();let r=n[As];if(r!==null&&Ct(n[be])){r!==n[be]&&Vp(r,n);let o=n[ar];o!==null&&o.detachView(e)}K_(n)}finally{L(t)}}function yD(e,n){let t=e.cleanup,r=n[lo];if(t!==null)for(let i=0;i=0?r[s]():r[-s].unsubscribe(),i+=2}else{let s=r[t[i+1]];t[i].call(s)}r!==null&&(n[lo]=null);let o=n[Rt];if(o!==null){n[Rt]=null;for(let i=0;i-1){let{encapsulation:i}=e.data[r.directiveStart+o];if(i===dt.None||i===dt.Emulated)return null}return qe(r,t)}}function ms(e,n,t,r,o){e.insertBefore(n,t,r,o)}function $p(e,n,t){e.appendChild(n,t)}function nh(e,n,t,r,o){r!==null?ms(e,n,t,r,o):$p(e,n,t)}function bD(e,n,t,r){e.removeChild(n,t,r)}function ru(e,n){return e.parentNode(n)}function CD(e,n){return e.nextSibling(n)}function ED(e,n,t){return MD(e,n,t)}function ID(e,n,t){return e.type&40?qe(e,t):null}var MD=ID,rh;function ou(e,n,t,r){let o=_D(e,r,n),i=n[he],s=r.parent||n[it],a=ED(s,r,n);if(o!=null)if(Array.isArray(t))for(let c=0;crt&&zp(e,n,rt,!1),lt(s?2:0,o),t(r,o)}finally{cn(i),lt(s?3:1,o)}}function Zp(e,n,t){if(Zh(n)){let r=L(null);try{let o=n.directiveStart,i=n.directiveEnd;for(let s=o;snull;function jD(e,n,t,r,o,i){let s=n?n.injectorIndex:-1,a=0;return g_()&&(a|=128),{type:t,index:r,insertBeforeIndex:null,injectorIndex:s,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:o,attrs:i,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:n,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}function oh(e,n,t,r,o){for(let i in n){if(!n.hasOwnProperty(i))continue;let s=n[i];if(s===void 0)continue;r??={};let a,c=ne.None;Array.isArray(s)?(a=s[0],c=s[1]):a=s;let l=i;if(o!==null){if(!o.hasOwnProperty(i))continue;l=o[i]}e===0?ih(r,t,l,a,c):ih(r,t,l,a)}return r}function ih(e,n,t,r,o){let i;e.hasOwnProperty(t)?(i=e[t]).push(n,r):i=e[t]=[n,r],o!==void 0&&i.push(o)}function VD(e,n,t){let r=n.directiveStart,o=n.directiveEnd,i=e.data,s=n.attrs,a=[],c=null,l=null;for(let u=r;u0;){let t=e[--n];if(typeof t=="number"&&t<0)return t}return 0}function zD(e,n,t,r){let o=t.directiveStart,i=t.directiveEnd;Ns(t)&&KD(n,t,e.data[o+t.componentOffset]),e.firstCreatePass||ps(t,n),un(r,n);let s=t.initialInputs;for(let a=o;a{fo(e.lView)},consumerOnSignalRead(){this.lView[sn]=this}}),cg=100;function lg(e,n=!0,t=0){let r=e[tt],o=r.rendererFactory,i=!1;i||o.begin?.();try{hb(e,t)}catch(s){throw n&&og(e,s),s}finally{i||(o.end?.(),r.inlineEffectRunner?.flush())}}function hb(e,n){al(e,n);let t=0;for(;Ul(e);){if(t===cg)throw new I(103,!1);t++,al(e,1)}}function pb(e,n,t,r){let o=n[S];if((o&256)===256)return;let i=!1;!i&&n[tt].inlineEffectRunner?.flush(),Bl(n);let s=null,a=null;!i&&gb(e)&&(a=lb(n),s=sc(a));try{ep(n),__(e.bindingStartIndex),t!==null&&Wp(e,n,t,2,r);let c=(o&3)===3;if(!i)if(c){let d=e.preOrderCheckHooks;d!==null&&ts(n,d,null)}else{let d=e.preOrderHooks;d!==null&&ns(n,d,0,null),Tc(n,0)}if(mb(n),ug(n,0),e.contentQueries!==null&&rg(e,n),!i)if(c){let d=e.contentCheckHooks;d!==null&&ts(n,d)}else{let d=e.contentHooks;d!==null&&ns(n,d,1),Tc(n,1)}ND(e,n);let l=e.components;l!==null&&fg(n,l,0);let u=e.viewQuery;if(u!==null&&sl(2,u,r),!i)if(c){let d=e.viewCheckHooks;d!==null&&ts(n,d)}else{let d=e.viewHooks;d!==null&&ns(n,d,2),Tc(n,2)}if(e.firstUpdatePass===!0&&(e.firstUpdatePass=!1),n[es]){for(let d of n[es])d();n[es]=null}i||(n[S]&=-73)}catch(c){throw fo(n),c}finally{a!==null&&(ac(a,s),db(a)),Hl()}}function gb(e){return e.type!==2}function ug(e,n){for(let t=xp(e);t!==null;t=Tp(t))for(let r=Ie;r-1&&(po(n,r),as(t,r))}this._attachedToViewContainer=!1}Fs(this._lView[P],this._lView)}onDestroy(n){tp(this._lView,n)}markForCheck(){uu(this._cdRefInjectingView||this._lView)}detach(){this._lView[S]&=-129}reattach(){Yc(this._lView),this._lView[S]|=128}detectChanges(){this._lView[S]|=1024,lg(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new I(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,jp(this._lView[P],this._lView)}attachToAppRef(n){if(this._attachedToViewContainer)throw new I(902,!1);this._appRef=n,Yc(this._lView)}};var gR=new RegExp(`^(\\d+)*(${tD}|${eD})*(.*)`);var yb=()=>null;function mo(e,n){return yb(e,n)}var cl=class{},ll=class{},ys=class{};function wb(e){let n=Error(`No component factory found for ${Te(e)}.`);return n[_b]=e,n}var _b="ngComponent";var ul=class{resolveComponentFactory(n){throw wb(n)}},Bs=(()=>{class e{static{this.NULL=new ul}}return e})(),vo=class{},vn=(()=>{class e{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>Db()}}return e})();function Db(){let e=Q(),n=Ze(),t=Lt(n.index,e);return(nn(t)?t:e)[he]}var bb=(()=>{class e{static{this.\u0275prov=E({token:e,providedIn:"root",factory:()=>null})}}return e})(),Pc={};var sh=new Set;function yn(e){sh.has(e)||(sh.add(e),performance?.mark?.("mark_feature_usage",{detail:{feature:e}}))}function ah(...e){}function Cb(){let e=typeof tn.requestAnimationFrame=="function",n=tn[e?"requestAnimationFrame":"setTimeout"],t=tn[e?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&n&&t){let r=n[Zone.__symbol__("OriginalDelegate")];r&&(n=r);let o=t[Zone.__symbol__("OriginalDelegate")];o&&(t=o)}return{nativeRequestAnimationFrame:n,nativeCancelAnimationFrame:t}}var oe=class e{constructor({enableLongStackTrace:n=!1,shouldCoalesceEventChangeDetection:t=!1,shouldCoalesceRunChangeDetection:r=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new _e(!1),this.onMicrotaskEmpty=new _e(!1),this.onStable=new _e(!1),this.onError=new _e(!1),typeof Zone>"u")throw new I(908,!1);Zone.assertZonePatched();let o=this;o._nesting=0,o._outer=o._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(o._inner=o._inner.fork(new Zone.TaskTrackingZoneSpec)),n&&Zone.longStackTraceZoneSpec&&(o._inner=o._inner.fork(Zone.longStackTraceZoneSpec)),o.shouldCoalesceEventChangeDetection=!r&&t,o.shouldCoalesceRunChangeDetection=r,o.lastRequestAnimationFrameId=-1,o.nativeRequestAnimationFrame=Cb().nativeRequestAnimationFrame,Mb(o)}static isInAngularZone(){return typeof Zone<"u"&&Zone.current.get("isAngularZone")===!0}static assertInAngularZone(){if(!e.isInAngularZone())throw new I(909,!1)}static assertNotInAngularZone(){if(e.isInAngularZone())throw new I(909,!1)}run(n,t,r){return this._inner.run(n,t,r)}runTask(n,t,r,o){let i=this._inner,s=i.scheduleEventTask("NgZoneEvent: "+o,n,Eb,ah,ah);try{return i.runTask(s,t,r)}finally{i.cancelTask(s)}}runGuarded(n,t,r){return this._inner.runGuarded(n,t,r)}runOutsideAngular(n){return this._outer.run(n)}},Eb={};function du(e){if(e._nesting==0&&!e.hasPendingMicrotasks&&!e.isStable)try{e._nesting++,e.onMicrotaskEmpty.emit(null)}finally{if(e._nesting--,!e.hasPendingMicrotasks)try{e.runOutsideAngular(()=>e.onStable.emit(null))}finally{e.isStable=!0}}}function Ib(e){e.isCheckStableRunning||e.lastRequestAnimationFrameId!==-1||(e.lastRequestAnimationFrameId=e.nativeRequestAnimationFrame.call(tn,()=>{e.fakeTopEventTask||(e.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{e.lastRequestAnimationFrameId=-1,dl(e),e.isCheckStableRunning=!0,du(e),e.isCheckStableRunning=!1},void 0,()=>{},()=>{})),e.fakeTopEventTask.invoke()}),dl(e))}function Mb(e){let n=()=>{Ib(e)};e._inner=e._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(t,r,o,i,s,a)=>{if(Sb(a))return t.invokeTask(o,i,s,a);try{return ch(e),t.invokeTask(o,i,s,a)}finally{(e.shouldCoalesceEventChangeDetection&&i.type==="eventTask"||e.shouldCoalesceRunChangeDetection)&&n(),lh(e)}},onInvoke:(t,r,o,i,s,a,c)=>{try{return ch(e),t.invoke(o,i,s,a,c)}finally{e.shouldCoalesceRunChangeDetection&&n(),lh(e)}},onHasTask:(t,r,o,i)=>{t.hasTask(o,i),r===o&&(i.change=="microTask"?(e._hasPendingMicrotasks=i.microTask,dl(e),du(e)):i.change=="macroTask"&&(e.hasPendingMacrotasks=i.macroTask))},onHandleError:(t,r,o,i)=>(t.handleError(o,i),e.runOutsideAngular(()=>e.onError.emit(i)),!1)})}function dl(e){e._hasPendingMicrotasks||(e.shouldCoalesceEventChangeDetection||e.shouldCoalesceRunChangeDetection)&&e.lastRequestAnimationFrameId!==-1?e.hasPendingMicrotasks=!0:e.hasPendingMicrotasks=!1}function ch(e){e._nesting++,e.isStable&&(e.isStable=!1,e.onUnstable.emit(null))}function lh(e){e._nesting--,du(e)}function Sb(e){return!Array.isArray(e)||e.length!==1?!1:e[0].data?.__ignore_ng_zone__===!0}var hg=(()=>{class e{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){this.executeInternalCallbacks(),this.handler?.execute()}executeInternalCallbacks(){let t=[...this.internalCallbacks];this.internalCallbacks.length=0;for(let r of t)r()}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=E({token:e,providedIn:"root",factory:()=>new e})}}return e})();function fl(e,n,t){let r=t?e.styles:null,o=t?e.classes:null,i=0;if(n!==null)for(let s=0;s0&&Bp(e,t,i.join(" "))}}function Pb(e,n,t){let r=e.projection=[];for(let o=0;o{class e{static{this.__NG_ELEMENT_ID__=Fb}}return e})();function Fb(){let e=Ze();return jb(e,Q())}var Lb=Hs,pg=class extends Lb{constructor(n,t,r){super(),this._lContainer=n,this._hostTNode=t,this._hostLView=r}get element(){return Ql(this._hostTNode,this._hostLView)}get injector(){return new rn(this._hostTNode,this._hostLView)}get parentInjector(){let n=Zl(this._hostTNode,this._hostLView);if(gp(n)){let t=hs(n,this._hostLView),r=fs(n),o=t[P].data[r+8];return new rn(o,t)}else return new rn(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(n){let t=dh(this._lContainer);return t!==null&&t[n]||null}get length(){return this._lContainer.length-Ie}createEmbeddedView(n,t,r){let o,i;typeof r=="number"?o=r:r!=null&&(o=r.index,i=r.injector);let s=mo(this._lContainer,n.ssrId),a=n.createEmbeddedViewImpl(t||{},i,s);return this.insertImpl(a,o,go(this._hostTNode,s)),a}createComponent(n,t,r,o,i){let s=n&&!Xw(n),a;if(s)a=t;else{let v=t||{};a=v.index,r=v.injector,o=v.projectableNodes,i=v.environmentInjector||v.ngModuleRef}let c=s?n:new yo(on(n)),l=r||this.parentInjector;if(!i&&c.ngModule==null){let m=(s?l:this.parentInjector).get(Ae,null);m&&(i=m)}let u=on(c.componentType??{}),d=mo(this._lContainer,u?.id??null),p=d?.firstChild??null,f=c.create(l,o,p,i);return this.insertImpl(f.hostView,a,go(this._hostTNode,d)),f}insert(n,t){return this.insertImpl(n,t,!0)}insertImpl(n,t,r){let o=n._lView;if(c_(o)){let a=this.indexOf(n);if(a!==-1)this.detach(a);else{let c=o[be],l=new pg(c,c[it],c[be]);l.detach(l.indexOf(n))}}let i=this._adjustIndex(t),s=this._lContainer;return Us(s,o,i,r),n.attachToViewContainerRef(),Th(kc(s),i,n),n}move(n,t){return this.insert(n,t)}indexOf(n){let t=dh(this._lContainer);return t!==null?t.indexOf(n):-1}remove(n){let t=this._adjustIndex(n,-1),r=po(this._lContainer,t);r&&(as(kc(this._lContainer),t),Fs(r[P],r))}detach(n){let t=this._adjustIndex(n,-1),r=po(this._lContainer,t);return r&&as(kc(this._lContainer),t)!=null?new lr(r):null}_adjustIndex(n,t=0){return n??this.length+t}};function dh(e){return e[ls]}function kc(e){return e[ls]||(e[ls]=[])}function jb(e,n){let t,r=n[e.index];return Ct(r)?t=r:(t=ng(r,n,null,e),n[e.index]=t,$s(n,t)),$b(t,n,e,r),new pg(t,e,n)}function Vb(e,n){let t=e[he],r=t.createComment(""),o=qe(n,e),i=ru(t,o);return ms(t,i,r,CD(t,o),!1),r}var $b=Hb,Ub=()=>!1;function Bb(e,n,t){return Ub(e,n,t)}function Hb(e,n,t,r){if(e[an])return;let o;t.type&8?o=ft(r):o=Vb(n,t),e[an]=o}function gr(e,n){yn("NgSignals");let t=lf(e),r=t[St];return n?.equal&&(r.equal=n.equal),t.set=o=>Ii(r,o),t.update=o=>uf(r,o),t.asReadonly=zb.bind(t),t}function zb(){let e=this[St];if(e.readonlyFn===void 0){let n=()=>this();n[St]=e,e.readonlyFn=n}return e.readonlyFn}function Gb(e){return Object.getPrototypeOf(e.prototype).constructor}function $t(e){let n=Gb(e.type),t=!0,r=[e];for(;n;){let o;if(Pt(e))o=n.\u0275cmp||n.\u0275dir;else{if(n.\u0275cmp)throw new I(903,!1);o=n.\u0275dir}if(o){if(t){r.push(o);let s=e;s.inputs=Ki(e.inputs),s.inputTransforms=Ki(e.inputTransforms),s.declaredInputs=Ki(e.declaredInputs),s.outputs=Ki(e.outputs);let a=o.hostBindings;a&&Qb(e,a);let c=o.viewQuery,l=o.contentQueries;if(c&&Zb(e,c),l&&Yb(e,l),qb(e,o),rw(e.outputs,o.outputs),Pt(o)&&o.data.animation){let u=e.data;u.animation=(u.animation||[]).concat(o.data.animation)}}let i=o.features;if(i)for(let s=0;s=0;r--){let o=e[r];o.hostVars=n+=o.hostVars,o.hostAttrs=so(o.hostAttrs,t=so(t,o.hostAttrs))}}function Ki(e){return e===rr?{}:e===Ge?[]:e}function Zb(e,n){let t=e.viewQuery;t?e.viewQuery=(r,o)=>{n(r,o),t(r,o)}:e.viewQuery=n}function Yb(e,n){let t=e.contentQueries;t?e.contentQueries=(r,o,i)=>{n(r,o,i),t(r,o,i)}:e.contentQueries=n}function Qb(e,n){let t=e.hostBindings;t?e.hostBindings=(r,o)=>{n(r,o),t(r,o)}:e.hostBindings=n}function fu(e){let n=e.inputConfig,t={};for(let r in n)if(n.hasOwnProperty(r)){let o=n[r];Array.isArray(o)&&o[3]&&(t[r]=o[3])}e.inputTransforms=t}var kt=class{},wo=class{};var gl=class extends kt{constructor(n,t,r){super(),this._parent=t,this._bootstrapComponents=[],this.destroyCbs=[],this.componentFactoryResolver=new ws(this);let o=jh(n);this._bootstrapComponents=Fp(o.bootstrap),this._r3Injector=Ep(n,t,[{provide:kt,useValue:this},{provide:Bs,useValue:this.componentFactoryResolver},...r],Te(n),new Set(["environment"])),this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(n)}get injector(){return this._r3Injector}destroy(){let n=this._r3Injector;!n.destroyed&&n.destroy(),this.destroyCbs.forEach(t=>t()),this.destroyCbs=null}onDestroy(n){this.destroyCbs.push(n)}},ml=class extends wo{constructor(n){super(),this.moduleType=n}create(n){return new gl(this.moduleType,n,[])}};var _s=class extends kt{constructor(n){super(),this.componentFactoryResolver=new ws(this),this.instance=null;let t=new ao([...n.providers,{provide:kt,useValue:this},{provide:Bs,useValue:this.componentFactoryResolver}],n.parent||Fl(),n.debugName,new Set(["environment"]));this.injector=t,n.runEnvironmentInitializers&&t.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(n){this.injector.onDestroy(n)}};function hu(e,n,t=null){return new _s({providers:e,parent:n,debugName:t,runEnvironmentInitializers:!0}).injector}var wn=(()=>{class e{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new ge(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);let t=this.taskId++;return this.pendingTasks.add(t),t}remove(t){this.pendingTasks.delete(t),this.pendingTasks.size===0&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function mr(e,n,t){let r=e[n];return Object.is(r,t)?!1:(e[n]=t,!0)}function Kb(e){return(e.flags&32)===32}function Jb(e,n,t,r,o,i,s,a,c){let l=n.consts,u=Vs(n,e,4,s||null,ds(l,a));Xp(n,t,u,ds(l,c)),Wl(n,u);let d=u.tView=su(2,u,r,o,i,n.directiveRegistry,n.pipeRegistry,null,n.schemas,l,null);return n.queries!==null&&(n.queries.template(n,u),d.queries=n.queries.embeddedTView(u)),u}function pe(e,n,t,r,o,i,s,a){let c=Q(),l=We(),u=e+rt,d=l.firstCreatePass?Jb(u,l,c,n,t,r,o,i,s):l.data[u];bo(d,!1);let p=Xb(l,c,d,e);Gl()&&ou(l,c,p,d),un(p,c);let f=ng(p,c,p,d);return c[u]=f,$s(c,f),Bb(f,d,c),jl(d)&&Yp(l,c,d),s!=null&&Qp(c,d,a),pe}var Xb=e0;function e0(e,n,t,r){return ql(!0),n[he].createComment("")}function zs(e,n,t,r){let o=Q(),i=Co();if(mr(o,i,n)){let s=We(),a=zl();JD(a,o,e,n,t,r)}return zs}function gg(e,n,t,r){return mr(e,Co(),t)?n+Ss(t)+r:mn}function Ji(e,n){return e<<17|n<<2}function dn(e){return e>>17&32767}function t0(e){return(e&2)==2}function n0(e,n){return e&131071|n<<17}function vl(e){return e|2}function ur(e){return(e&131068)>>2}function Fc(e,n){return e&-131069|n<<2}function r0(e){return(e&1)===1}function yl(e){return e|1}function o0(e,n,t,r,o,i){let s=i?n.classBindings:n.styleBindings,a=dn(s),c=ur(s);e[r]=t;let l=!1,u;if(Array.isArray(t)){let d=t;u=d[1],(u===null||Do(d,u)>0)&&(l=!0)}else u=t;if(o)if(c!==0){let p=dn(e[a+1]);e[r+1]=Ji(p,a),p!==0&&(e[p+1]=Fc(e[p+1],r)),e[a+1]=n0(e[a+1],r)}else e[r+1]=Ji(a,0),a!==0&&(e[a+1]=Fc(e[a+1],r)),a=r;else e[r+1]=Ji(c,0),a===0?a=r:e[c+1]=Fc(e[c+1],r),c=r;l&&(e[r+1]=vl(e[r+1])),fh(e,u,r,!0),fh(e,u,r,!1),i0(n,u,e,r,i),s=Ji(a,c),i?n.classBindings=s:n.styleBindings=s}function i0(e,n,t,r,o){let i=o?e.residualClasses:e.residualStyles;i!=null&&typeof n=="string"&&Do(i,n)>=0&&(t[r+1]=yl(t[r+1]))}function fh(e,n,t,r){let o=e[t+1],i=n===null,s=r?dn(o):ur(o),a=!1;for(;s!==0&&(a===!1||i);){let c=e[s],l=e[s+1];s0(c,n)&&(a=!0,e[s+1]=r?yl(l):vl(l)),s=r?dn(l):ur(l)}a&&(e[t+1]=r?vl(o):yl(o))}function s0(e,n){return e===null||n==null||(Array.isArray(e)?e[1]:e)===n?!0:Array.isArray(e)&&typeof n=="string"?Do(e,n)>=0:!1}function Ce(e,n,t){let r=Q(),o=Co();if(mr(r,o,n)){let i=We(),s=zl();Jp(i,s,r,e,n,r[he],t,!1)}return Ce}function hh(e,n,t,r,o){let i=n.inputs,s=o?"class":"style";au(e,t,i[s],s,r)}function vr(e,n){return a0(e,n,null,!0),vr}function a0(e,n,t,r){let o=Q(),i=We(),s=D_(2);if(i.firstUpdatePass&&l0(i,e,s,r),n!==mn&&mr(o,s,n)){let a=i.data[pn()];p0(i,a,o,o[he],e,o[s+1]=g0(n,t),r,s)}}function c0(e,n){return n>=e.expandoStartIndex}function l0(e,n,t,r){let o=e.data;if(o[t+1]===null){let i=o[pn()],s=c0(e,t);m0(i,r)&&n===null&&!s&&(n=!1),n=u0(o,i,n,r),o0(o,i,n,t,s,r)}}function u0(e,n,t,r){let o=I_(e),i=r?n.residualClasses:n.residualStyles;if(o===null)(r?n.classBindings:n.styleBindings)===0&&(t=Lc(null,e,n,t,r),t=_o(t,n.attrs,r),i=null);else{let s=n.directiveStylingLast;if(s===-1||e[s]!==o)if(t=Lc(o,e,n,t,r),i===null){let c=d0(e,n,r);c!==void 0&&Array.isArray(c)&&(c=Lc(null,e,n,c[1],r),c=_o(c,n.attrs,r),f0(e,n,r,c))}else i=h0(e,n,r)}return i!==void 0&&(r?n.residualClasses=i:n.residualStyles=i),t}function d0(e,n,t){let r=t?n.classBindings:n.styleBindings;if(ur(r)!==0)return e[dn(r)]}function f0(e,n,t,r){let o=t?n.classBindings:n.styleBindings;e[dn(o)]=r}function h0(e,n,t){let r,o=n.directiveEnd;for(let i=1+n.directiveStylingLast;i0;){let c=e[o],l=Array.isArray(c),u=l?c[1]:c,d=u===null,p=t[o+1];p===mn&&(p=d?Ge:void 0);let f=d?Sc(p,r):u===r?p:void 0;if(l&&!Ds(f)&&(f=Sc(c,r)),Ds(f)&&(a=f,s))return a;let v=e[o+1];o=s?dn(v):ur(v)}if(n!==null){let c=i?n.residualClasses:n.residualStyles;c!=null&&(a=Sc(c,r))}return a}function Ds(e){return e!==void 0}function g0(e,n){return e==null||e===""||(typeof n=="string"?e=e+n:typeof e=="object"&&(e=Te(Io(e)))),e}function m0(e,n){return(e.flags&(n?8:16))!==0}var wl=class{destroy(n){}updateValue(n,t){}swap(n,t){let r=Math.min(n,t),o=Math.max(n,t),i=this.detach(o);if(o-r>1){let s=this.detach(r);this.attach(r,i),this.attach(o,s)}else this.attach(r,i)}move(n,t){this.attach(t,this.detach(n))}};function jc(e,n,t,r,o){return e===t&&Object.is(n,r)?1:Object.is(o(e,n),o(t,r))?-1:0}function v0(e,n,t){let r,o,i=0,s=e.length-1;if(Array.isArray(n)){let a=n.length-1;for(;i<=s&&i<=a;){let c=e.at(i),l=n[i],u=jc(i,c,i,l,t);if(u!==0){u<0&&e.updateValue(i,l),i++;continue}let d=e.at(s),p=n[a],f=jc(s,d,a,p,t);if(f!==0){f<0&&e.updateValue(s,p),s--,a--;continue}let v=t(i,c),m=t(s,d),y=t(i,l);if(Object.is(y,m)){let C=t(a,p);Object.is(C,v)?(e.swap(i,s),e.updateValue(s,p),a--,s--):e.move(s,i),e.updateValue(i,l),i++;continue}if(r??=new bs,o??=mh(e,i,s,t),_l(e,r,i,y))e.updateValue(i,l),i++,s++;else if(o.has(y))r.set(v,e.detach(i)),s--;else{let C=e.create(i,n[i]);e.attach(i,C),i++,s++}}for(;i<=a;)gh(e,r,t,i,n[i]),i++}else if(n!=null){let a=n[Symbol.iterator](),c=a.next();for(;!c.done&&i<=s;){let l=e.at(i),u=c.value,d=jc(i,l,i,u,t);if(d!==0)d<0&&e.updateValue(i,u),i++,c=a.next();else{r??=new bs,o??=mh(e,i,s,t);let p=t(i,u);if(_l(e,r,i,p))e.updateValue(i,u),i++,s++,c=a.next();else if(!o.has(p))e.attach(i,e.create(i,u)),i++,s++,c=a.next();else{let f=t(i,l);r.set(f,e.detach(i)),s--}}}for(;!c.done;)gh(e,r,t,e.length,c.value),c=a.next()}for(;i<=s;)e.destroy(e.detach(s--));r?.forEach(a=>{e.destroy(a)})}function _l(e,n,t,r){return n!==void 0&&n.has(r)?(e.attach(t,n.get(r)),n.delete(r),!0):!1}function gh(e,n,t,r,o){if(_l(e,n,r,t(r,o)))e.updateValue(r,o);else{let i=e.create(r,o);e.attach(r,i)}}function mh(e,n,t,r){let o=new Set;for(let i=n;i<=t;i++)o.add(r(i,e.at(i)));return o}var bs=class{constructor(){this.kvMap=new Map,this._vMap=void 0}has(n){return this.kvMap.has(n)}delete(n){if(!this.has(n))return!1;let t=this.kvMap.get(n);return this._vMap!==void 0&&this._vMap.has(t)?(this.kvMap.set(n,this._vMap.get(t)),this._vMap.delete(t)):this.kvMap.delete(n),!0}get(n){return this.kvMap.get(n)}set(n,t){if(this.kvMap.has(n)){let r=this.kvMap.get(n);this._vMap===void 0&&(this._vMap=new Map);let o=this._vMap;for(;o.has(r);)r=o.get(r);o.set(r,t)}else this.kvMap.set(n,t)}forEach(n){for(let[t,r]of this.kvMap)if(n(r,t),this._vMap!==void 0){let o=this._vMap;for(;o.has(r);)r=o.get(r),n(r,t)}}};function me(e,n,t){yn("NgControlFlow");let r=Q(),o=Co(),i=El(r,rt+e),s=0;if(mr(r,o,n)){let a=L(null);try{if(sg(i,s),n!==-1){let c=Il(r[P],rt+n),l=mo(i,c.tView.ssrId),u=lu(r,c,t,{dehydratedView:l});Us(i,u,s,go(c,l))}}finally{L(a)}}else{let a=ig(i,s);a!==void 0&&(a[De]=t)}}var Dl=class{constructor(n,t,r){this.lContainer=n,this.$implicit=t,this.$index=r}get $count(){return this.lContainer.length-Ie}};var bl=class{constructor(n,t,r){this.hasEmptyBlock=n,this.trackByFn=t,this.liveCollection=r}};function Gs(e,n,t,r,o,i,s,a,c,l,u,d,p){yn("NgControlFlow");let f=c!==void 0,v=Q(),m=a?s.bind(v[nt][De]):s,y=new bl(f,m);v[rt+e]=y,pe(e+1,n,t,r,o,i),f&&pe(e+2,c,l,u,d,p)}var Cl=class extends wl{constructor(n,t,r){super(),this.lContainer=n,this.hostLView=t,this.templateTNode=r,this.needsIndexUpdate=!1}get length(){return this.lContainer.length-Ie}at(n){return this.getLView(n)[De].$implicit}attach(n,t){let r=t[co];this.needsIndexUpdate||=n!==this.length,Us(this.lContainer,t,n,go(this.templateTNode,r))}detach(n){return this.needsIndexUpdate||=n!==this.length-1,y0(this.lContainer,n)}create(n,t){let r=mo(this.lContainer,this.templateTNode.tView.ssrId);return lu(this.hostLView,this.templateTNode,new Dl(this.lContainer,t,n),{dehydratedView:r})}destroy(n){Fs(n[P],n)}updateValue(n,t){this.getLView(n)[De].$implicit=t}reset(){this.needsIndexUpdate=!1}updateIndexes(){if(this.needsIndexUpdate)for(let n=0;n(ql(!0),Lp(r,o,x_()));function mg(){return Q()}var Cs="en-US";var b0=Cs;function C0(e){typeof e=="string"&&(b0=e.toLowerCase().replace(/_/g,"-"))}function ae(e,n,t,r){let o=Q(),i=We(),s=Ze();return I0(i,o,o[he],s,e,n,r),ae}function E0(e,n,t,r){let o=e.cleanup;if(o!=null)for(let i=0;ic?a[c]:null}typeof s=="string"&&(i+=2)}return null}function I0(e,n,t,r,o,i,s){let a=jl(r),l=e.firstCreatePass&&rb(e),u=n[De],d=nb(n),p=!0;if(r.type&3||s){let m=qe(r,n),y=s?s(m):m,C=d.length,ie=s?J=>s(ft(J[r.index])):r.index,R=null;if(!s&&a&&(R=E0(e,n,o,r.index)),R!==null){let J=R.__ngLastListenerFn__||R;J.__ngNextListenerFn__=i,R.__ngLastListenerFn__=i,p=!1}else{i=yh(r,n,u,i,!1);let J=t.listen(y,o,i);d.push(i,J),l&&l.push(o,ie,C,C+1)}}else i=yh(r,n,u,i,!1);let f=r.outputs,v;if(p&&f!==null&&(v=f[o])){let m=v.length;if(m)for(let y=0;y-1?Lt(e.index,n):n;uu(a);let c=vh(n,t,r,s),l=i.__ngNextListenerFn__;for(;l;)c=vh(n,t,l,s)&&c,l=l.__ngNextListenerFn__;return o&&c===!1&&s.preventDefault(),c}}function st(e=1){return S_(e)}function pu(e,n,t){return Mo(e,"",n,"",t),pu}function Mo(e,n,t,r,o){let i=Q(),s=gg(i,n,t,r);if(s!==mn){let a=We(),c=zl();Jp(a,c,i,e,s,i[he],o,!1)}return Mo}function D(e,n=""){let t=Q(),r=We(),o=e+rt,i=r.firstCreatePass?Vs(r,o,1,n,null):r.data[o],s=M0(r,t,i,n,e);t[o]=s,Gl()&&ou(r,t,s,i),bo(i,!1)}var M0=(e,n,t,r,o)=>(ql(!0),dD(n[he],r));function _n(e){return yr("",e,""),_n}function yr(e,n,t){let r=Q(),o=gg(r,e,n,t);return o!==mn&&ob(r,pn(),o),yr}function S0(e,n,t){let r=We();if(r.firstCreatePass){let o=Pt(e);Ml(t,r.data,r.blueprint,o,!0),Ml(n,r.data,r.blueprint,o,!1)}}function Ml(e,n,t,r,o){if(e=Ee(e),Array.isArray(e))for(let i=0;i>20;if(ir(e)||!e.multi){let f=new ln(l,o,K),v=$c(c,n,o?u:u+p,d);v===-1?(Jc(ps(a,s),i,c),Vc(i,e,n.length),n.push(c),a.directiveStart++,a.directiveEnd++,o&&(a.providerIndexes+=1048576),t.push(f),s.push(f)):(t[v]=f,s[v]=f)}else{let f=$c(c,n,u+p,d),v=$c(c,n,u,u+p),m=f>=0&&t[f],y=v>=0&&t[v];if(o&&!y||!o&&!m){Jc(ps(a,s),i,c);let C=A0(o?T0:x0,t.length,o,r,l);!o&&y&&(t[v].providerFactory=C),Vc(i,e,n.length,0),n.push(c),a.directiveStart++,a.directiveEnd++,o&&(a.providerIndexes+=1048576),t.push(C),s.push(C)}else{let C=vg(t[o?v:f],l,!o&&r);Vc(i,e,f>-1?f:v,C)}!o&&r&&y&&t[v].componentProviders++}}}function Vc(e,n,t,r){let o=ir(n),i=Gw(n);if(o||i){let c=(i?Ee(n.useClass):n).prototype.ngOnDestroy;if(c){let l=e.destroyHooks||(e.destroyHooks=[]);if(!o&&n.multi){let u=l.indexOf(t);u===-1?l.push(t,[r,c]):l[u+1].push(r,c)}else l.push(t,c)}}}function vg(e,n,t){return t&&e.componentProviders++,e.multi.push(n)-1}function $c(e,n,t,r){for(let o=t;o{t.providersResolver=(r,o)=>S0(r,o?o(e):e,n)}}var O0=(()=>{class e{constructor(t){this._injector=t,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(t){if(!t.standalone)return null;if(!this.cachedInjectors.has(t)){let r=Uh(!1,t.type),o=r.length>0?hu([r],this._injector,`Standalone[${t.type.name}]`):null;this.cachedInjectors.set(t,o)}return this.cachedInjectors.get(t)}ngOnDestroy(){try{for(let t of this.cachedInjectors.values())t!==null&&t.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=E({token:e,providedIn:"environment",factory:()=>new e(A(Ae))})}}return e})();function Z(e){yn("NgStandalone"),e.getStandaloneInjector=n=>n.get(O0).getOrCreateStandaloneInjector(e)}var Zs=(()=>{class e{log(t){console.log(t)}warn(t){console.warn(t)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"platform"})}}return e})();var yg=new M("");function Dn(e){return!!e&&typeof e.then=="function"}function wg(e){return!!e&&typeof e.subscribe=="function"}var _g=new M(""),Dg=(()=>{class e{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((t,r)=>{this.resolve=t,this.reject=r}),this.appInits=g(_g,{optional:!0})??[]}runInitializers(){if(this.initialized)return;let t=[];for(let o of this.appInits){let i=o();if(Dn(i))t.push(i);else if(wg(i)){let s=new Promise((a,c)=>{i.subscribe({complete:a,error:c})});t.push(s)}}let r=()=>{this.done=!0,this.resolve()};Promise.all(t).then(()=>{r()}).catch(o=>{this.reject(o)}),t.length===0&&r(),this.initialized=!0}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),Ys=new M("");function N0(){cf(()=>{throw new I(600,!1)})}function R0(e){return e.isBoundToModule}function P0(e,n,t){try{let r=t();return Dn(r)?r.catch(o=>{throw n.runOutsideAngular(()=>e.handleError(o)),o}):r}catch(r){throw n.runOutsideAngular(()=>e.handleError(r)),r}}var wr=(()=>{class e{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=g(Ip),this.afterRenderEffectManager=g(hg),this.externalTestViews=new Set,this.beforeRender=new we,this.afterTick=new we,this.componentTypes=[],this.components=[],this.isStable=g(wn).hasPendingTasks.pipe(O(t=>!t)),this._injector=g(Ae)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(t,r){let o=t instanceof ys;if(!this._injector.get(Dg).done){let p=!o&&Lh(t),f=!1;throw new I(405,f)}let s;o?s=t:s=this._injector.get(Bs).resolveComponentFactory(t),this.componentTypes.push(s.componentType);let a=R0(s)?void 0:this._injector.get(kt),c=r||s.selector,l=s.create(gn.NULL,[],c,a),u=l.location.nativeElement,d=l.injector.get(yg,null);return d?.registerApplication(u),l.onDestroy(()=>{this.detachView(l.hostView),Uc(this.components,l),d?.unregisterApplication(u)}),this._loadComponent(l),l}tick(){this._tick(!0)}_tick(t){if(this._runningTick)throw new I(101,!1);let r=L(null);try{this._runningTick=!0,this.detectChangesInAttachedViews(t)}catch(o){this.internalErrorHandler(o)}finally{this.afterTick.next(),this._runningTick=!1,L(r)}}detectChangesInAttachedViews(t){let r=0,o=this.afterRenderEffectManager;for(;;){if(r===cg)throw new I(103,!1);if(t){let i=r===0;this.beforeRender.next(i);for(let{_lView:s,notifyErrorHandler:a}of this._views)k0(s,i,a)}if(r++,o.executeInternalCallbacks(),![...this.externalTestViews.keys(),...this._views].some(({_lView:i})=>xl(i))&&(o.execute(),![...this.externalTestViews.keys(),...this._views].some(({_lView:i})=>xl(i))))break}}attachView(t){let r=t;this._views.push(r),r.attachToAppRef(this)}detachView(t){let r=t;Uc(this._views,r),r.detachFromAppRef()}_loadComponent(t){this.attachView(t.hostView),this.tick(),this.components.push(t);let r=this._injector.get(Ys,[]);[...this._bootstrapListeners,...r].forEach(o=>o(t))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(t=>t()),this._views.slice().forEach(t=>t.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(t){return this._destroyListeners.push(t),()=>Uc(this._destroyListeners,t)}destroy(){if(this._destroyed)throw new I(406,!1);let t=this._injector;t.destroy&&!t.destroyed&&t.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function Uc(e,n){let t=e.indexOf(n);t>-1&&e.splice(t,1)}function k0(e,n,t){!n&&!xl(e)||F0(e,t,n)}function xl(e){return Ul(e)}function F0(e,n,t){let r;t?(r=0,e[S]|=1024):e[S]&64?r=0:r=1,lg(e,n,r)}var Tl=class{constructor(n,t){this.ngModuleFactory=n,this.componentFactories=t}},gu=(()=>{class e{compileModuleSync(t){return new ml(t)}compileModuleAsync(t){return Promise.resolve(this.compileModuleSync(t))}compileModuleAndAllComponentsSync(t){let r=this.compileModuleSync(t),o=jh(t),i=Fp(o.declarations).reduce((s,a)=>{let c=on(a);return c&&s.push(new yo(c)),s},[]);return new Tl(r,i)}compileModuleAndAllComponentsAsync(t){return Promise.resolve(this.compileModuleAndAllComponentsSync(t))}clearCache(){}clearCacheFor(t){}getModuleId(t){}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var L0=(()=>{class e{constructor(){this.zone=g(oe),this.applicationRef=g(wr)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function j0(e){return[{provide:oe,useFactory:e},{provide:or,multi:!0,useFactory:()=>{let n=g(L0,{optional:!0});return()=>n.initialize()}},{provide:or,multi:!0,useFactory:()=>{let n=g(B0);return()=>{n.initialize()}}},{provide:Ip,useFactory:V0}]}function V0(){let e=g(oe),n=g(ot);return t=>e.runOutsideAngular(()=>n.handleError(t))}function $0(e){let n=j0(()=>new oe(U0(e)));return fr([[],n])}function U0(e){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:e?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:e?.runCoalescing??!1}}var B0=(()=>{class e{constructor(){this.subscription=new le,this.initialized=!1,this.zone=g(oe),this.pendingTasks=g(wn)}initialize(){if(this.initialized)return;this.initialized=!0;let t=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(t=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{oe.assertNotInAngularZone(),queueMicrotask(()=>{t!==null&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(t),t=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{oe.assertInAngularZone(),t??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function H0(){return typeof $localize<"u"&&$localize.locale||Cs}var mu=new M("",{providedIn:"root",factory:()=>g(mu,k.Optional|k.SkipSelf)||H0()});var bg=new M("");var os=null;function z0(e=[],n){return gn.create({name:n,providers:[{provide:Ts,useValue:"platform"},{provide:bg,useValue:new Set([()=>os=null])},...e]})}function G0(e=[]){if(os)return os;let n=z0(e);return os=n,N0(),q0(n),n}function q0(e){e.get(Jl,null)?.forEach(t=>t())}var bn=(()=>{class e{static{this.__NG_ELEMENT_ID__=W0}}return e})();function W0(e){return Z0(Ze(),Q(),(e&16)===16)}function Z0(e,n,t){if(Ns(e)&&!t){let r=Lt(e.index,n);return new lr(r,r)}else if(e.type&47){let r=n[nt];return new lr(r,n)}return null}function Cg(e){try{let{rootComponent:n,appProviders:t,platformProviders:r}=e,o=G0(r),i=[$0(),...t||[]],a=new _s({providers:i,parent:o,debugName:"",runEnvironmentInitializers:!1}).injector,c=a.get(oe);return c.run(()=>{a.resolveInjectorInitializers();let l=a.get(ot,null),u;c.runOutsideAngular(()=>{u=c.onError.subscribe({next:f=>{l.handleError(f)}})});let d=()=>a.destroy(),p=o.get(bg);return p.add(d),a.onDestroy(()=>{u.unsubscribe(),p.delete(d)}),P0(l,c,()=>{let f=a.get(Dg);return f.runInitializers(),f.donePromise.then(()=>{let v=a.get(mu,Cs);C0(v||Cs);let m=a.get(wr);return n!==void 0&&m.bootstrap(n),m})})})}catch(n){return Promise.reject(n)}}function _r(e){return typeof e=="boolean"?e:e!=null&&e!=="false"}var Y0=new M("",{providedIn:"root",factory:()=>g(Q0)}),Q0=(()=>{class e{static{this.\u0275prov=E({token:e,providedIn:"root",factory:()=>new Al})}}return e})(),Al=class{constructor(){this.queuedEffectCount=0,this.queues=new Map,this.pendingTasks=g(wn),this.taskId=null}scheduleEffect(n){if(this.enqueue(n),this.taskId===null){let t=this.taskId=this.pendingTasks.add();queueMicrotask(()=>{this.flush(),this.pendingTasks.remove(t),this.taskId=null})}}enqueue(n){let t=n.creationZone;this.queues.has(t)||this.queues.set(t,new Set);let r=this.queues.get(t);r.has(n)||(this.queuedEffectCount++,r.add(n))}flush(){for(;this.queuedEffectCount>0;)for(let[n,t]of this.queues)n===null?this.flushQueue(t):n.run(()=>this.flushQueue(t))}flushQueue(n){for(let t of n)n.delete(t),this.queuedEffectCount--,t.run()}},Ol=class{constructor(n,t,r,o,i,s){this.scheduler=n,this.effectFn=t,this.creationZone=r,this.injector=i,this.watcher=df(a=>this.runEffect(a),()=>this.schedule(),s),this.unregisterOnDestroy=o?.onDestroy(()=>this.destroy())}runEffect(n){try{this.effectFn(n)}catch(t){this.injector.get(ot,null,{optional:!0})?.handleError(t)}}run(){this.watcher.run()}schedule(){this.scheduler.scheduleEffect(this)}destroy(){this.watcher.destroy(),this.unregisterOnDestroy?.()}};function So(e,n){yn("NgSignals"),!n?.injector&&Jw(So);let t=n?.injector??g(gn),r=n?.manualCleanup!==!0?t.get(Rs):null,o=new Ol(t.get(Y0),e,typeof Zone>"u"?null:Zone.current,r,t,n?.allowSignalWrites??!1),i=t.get(bn,null,{optional:!0});return!i||!(i._lView[S]&8)?o.watcher.notify():(i._lView[es]??=[]).push(o.watcher.notify),o}var Mg=null;function Et(){return Mg}function Sg(e){Mg??=e}var Qs=class{};var Oe=new M(""),xg=(()=>{class e{historyGo(t){throw new Error("")}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:()=>g(K0),providedIn:"platform"})}}return e})();var K0=(()=>{class e extends xg{constructor(){super(),this._doc=g(Oe),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return Et().getBaseHref(this._doc)}onPopState(t){let r=Et().getGlobalEventTarget(this._doc,"window");return r.addEventListener("popstate",t,!1),()=>r.removeEventListener("popstate",t)}onHashChange(t){let r=Et().getGlobalEventTarget(this._doc,"window");return r.addEventListener("hashchange",t,!1),()=>r.removeEventListener("hashchange",t)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(t){this._location.pathname=t}pushState(t,r,o){this._history.pushState(t,r,o)}replaceState(t,r,o){this._history.replaceState(t,r,o)}forward(){this._history.forward()}back(){this._history.back()}historyGo(t=0){this._history.go(t)}getState(){return this._history.state}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:()=>new e,providedIn:"platform"})}}return e})();function Tg(e,n){if(e.length==0)return n;if(n.length==0)return e;let t=0;return e.endsWith("/")&&t++,n.startsWith("/")&&t++,t==2?e+n.substring(1):t==1?e+n:e+"/"+n}function Eg(e){let n=e.match(/#|\?|$/),t=n&&n.index||e.length,r=t-(e[t-1]==="/"?1:0);return e.slice(0,r)+e.slice(t)}function Cn(e){return e&&e[0]!=="?"?"?"+e:e}var br=(()=>{class e{historyGo(t){throw new Error("")}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:()=>g(Ag),providedIn:"root"})}}return e})(),J0=new M(""),Ag=(()=>{class e extends br{constructor(t,r){super(),this._platformLocation=t,this._removeListenerFns=[],this._baseHref=r??this._platformLocation.getBaseHrefFromDOM()??g(Oe).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(t){this._removeListenerFns.push(this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t))}getBaseHref(){return this._baseHref}prepareExternalUrl(t){return Tg(this._baseHref,t)}path(t=!1){let r=this._platformLocation.pathname+Cn(this._platformLocation.search),o=this._platformLocation.hash;return o&&t?`${r}${o}`:r}pushState(t,r,o,i){let s=this.prepareExternalUrl(o+Cn(i));this._platformLocation.pushState(t,r,s)}replaceState(t,r,o,i){let s=this.prepareExternalUrl(o+Cn(i));this._platformLocation.replaceState(t,r,s)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(t=0){this._platformLocation.historyGo?.(t)}static{this.\u0275fac=function(r){return new(r||e)(A(xg),A(J0,8))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var xo=(()=>{class e{constructor(t){this._subject=new _e,this._urlChangeListeners=[],this._urlChangeSubscription=null,this._locationStrategy=t;let r=this._locationStrategy.getBaseHref();this._basePath=tC(Eg(Ig(r))),this._locationStrategy.onPopState(o=>{this._subject.emit({url:this.path(!0),pop:!0,state:o.state,type:o.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(t=!1){return this.normalize(this._locationStrategy.path(t))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(t,r=""){return this.path()==this.normalize(t+Cn(r))}normalize(t){return e.stripTrailingSlash(eC(this._basePath,Ig(t)))}prepareExternalUrl(t){return t&&t[0]!=="/"&&(t="/"+t),this._locationStrategy.prepareExternalUrl(t)}go(t,r="",o=null){this._locationStrategy.pushState(o,"",t,r),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Cn(r)),o)}replaceState(t,r="",o=null){this._locationStrategy.replaceState(o,"",t,r),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Cn(r)),o)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(t=0){this._locationStrategy.historyGo?.(t)}onUrlChange(t){return this._urlChangeListeners.push(t),this._urlChangeSubscription??=this.subscribe(r=>{this._notifyUrlChangeListeners(r.url,r.state)}),()=>{let r=this._urlChangeListeners.indexOf(t);this._urlChangeListeners.splice(r,1),this._urlChangeListeners.length===0&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(t="",r){this._urlChangeListeners.forEach(o=>o(t,r))}subscribe(t,r,o){return this._subject.subscribe({next:t,error:r,complete:o})}static{this.normalizeQueryParams=Cn}static{this.joinWithSlash=Tg}static{this.stripTrailingSlash=Eg}static{this.\u0275fac=function(r){return new(r||e)(A(br))}}static{this.\u0275prov=E({token:e,factory:()=>X0(),providedIn:"root"})}}return e})();function X0(){return new xo(A(br))}function eC(e,n){if(!e||!n.startsWith(e))return n;let t=n.substring(e.length);return t===""||["/",";","?","#"].includes(t[0])?t:n}function Ig(e){return e.replace(/\/index.html$/,"")}function tC(e){if(new RegExp("^(https?:)?//").test(e)){let[,t]=e.split(/\/\/[^\/]+/);return t}return e}function Ks(e,n){n=encodeURIComponent(n);for(let t of e.split(";")){let r=t.indexOf("="),[o,i]=r==-1?[t,""]:[t.slice(0,r),t.slice(r+1)];if(o.trim()===n)return decodeURIComponent(i)}return null}var Og="browser",nC="server";function Js(e){return e===nC}var Dr=class{};var Ao=class{},ea=class{},En=class e{constructor(n){this.normalizedNames=new Map,this.lazyUpdate=null,n?typeof n=="string"?this.lazyInit=()=>{this.headers=new Map,n.split(` +`).forEach(t=>{let r=t.indexOf(":");if(r>0){let o=t.slice(0,r),i=o.toLowerCase(),s=t.slice(r+1).trim();this.maybeSetNormalizedName(o,i),this.headers.has(i)?this.headers.get(i).push(s):this.headers.set(i,[s])}})}:typeof Headers<"u"&&n instanceof Headers?(this.headers=new Map,n.forEach((t,r)=>{this.setHeaderEntries(r,t)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(n).forEach(([t,r])=>{this.setHeaderEntries(t,r)})}:this.headers=new Map}has(n){return this.init(),this.headers.has(n.toLowerCase())}get(n){this.init();let t=this.headers.get(n.toLowerCase());return t&&t.length>0?t[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(n){return this.init(),this.headers.get(n.toLowerCase())||null}append(n,t){return this.clone({name:n,value:t,op:"a"})}set(n,t){return this.clone({name:n,value:t,op:"s"})}delete(n,t){return this.clone({name:n,value:t,op:"d"})}maybeSetNormalizedName(n,t){this.normalizedNames.has(t)||this.normalizedNames.set(t,n)}init(){this.lazyInit&&(this.lazyInit instanceof e?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(n=>this.applyUpdate(n)),this.lazyUpdate=null))}copyFrom(n){n.init(),Array.from(n.headers.keys()).forEach(t=>{this.headers.set(t,n.headers.get(t)),this.normalizedNames.set(t,n.normalizedNames.get(t))})}clone(n){let t=new e;return t.lazyInit=this.lazyInit&&this.lazyInit instanceof e?this.lazyInit:this,t.lazyUpdate=(this.lazyUpdate||[]).concat([n]),t}applyUpdate(n){let t=n.name.toLowerCase();switch(n.op){case"a":case"s":let r=n.value;if(typeof r=="string"&&(r=[r]),r.length===0)return;this.maybeSetNormalizedName(n.name,t);let o=(n.op==="a"?this.headers.get(t):void 0)||[];o.push(...r),this.headers.set(t,o);break;case"d":let i=n.value;if(!i)this.headers.delete(t),this.normalizedNames.delete(t);else{let s=this.headers.get(t);if(!s)return;s=s.filter(a=>i.indexOf(a)===-1),s.length===0?(this.headers.delete(t),this.normalizedNames.delete(t)):this.headers.set(t,s)}break}}setHeaderEntries(n,t){let r=(Array.isArray(t)?t:[t]).map(i=>i.toString()),o=n.toLowerCase();this.headers.set(o,r),this.maybeSetNormalizedName(n,o)}forEach(n){this.init(),Array.from(this.normalizedNames.keys()).forEach(t=>n(this.normalizedNames.get(t),this.headers.get(t)))}};var wu=class{encodeKey(n){return Rg(n)}encodeValue(n){return Rg(n)}decodeKey(n){return decodeURIComponent(n)}decodeValue(n){return decodeURIComponent(n)}};function iC(e,n){let t=new Map;return e.length>0&&e.replace(/^\?/,"").split("&").forEach(o=>{let i=o.indexOf("="),[s,a]=i==-1?[n.decodeKey(o),""]:[n.decodeKey(o.slice(0,i)),n.decodeValue(o.slice(i+1))],c=t.get(s)||[];c.push(a),t.set(s,c)}),t}var sC=/%(\d[a-f0-9])/gi,aC={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Rg(e){return encodeURIComponent(e).replace(sC,(n,t)=>aC[t]??n)}function Xs(e){return`${e}`}var Ut=class e{constructor(n={}){if(this.updates=null,this.cloneFrom=null,this.encoder=n.encoder||new wu,n.fromString){if(n.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=iC(n.fromString,this.encoder)}else n.fromObject?(this.map=new Map,Object.keys(n.fromObject).forEach(t=>{let r=n.fromObject[t],o=Array.isArray(r)?r.map(Xs):[Xs(r)];this.map.set(t,o)})):this.map=null}has(n){return this.init(),this.map.has(n)}get(n){this.init();let t=this.map.get(n);return t?t[0]:null}getAll(n){return this.init(),this.map.get(n)||null}keys(){return this.init(),Array.from(this.map.keys())}append(n,t){return this.clone({param:n,value:t,op:"a"})}appendAll(n){let t=[];return Object.keys(n).forEach(r=>{let o=n[r];Array.isArray(o)?o.forEach(i=>{t.push({param:r,value:i,op:"a"})}):t.push({param:r,value:o,op:"a"})}),this.clone(t)}set(n,t){return this.clone({param:n,value:t,op:"s"})}delete(n,t){return this.clone({param:n,value:t,op:"d"})}toString(){return this.init(),this.keys().map(n=>{let t=this.encoder.encodeKey(n);return this.map.get(n).map(r=>t+"="+this.encoder.encodeValue(r)).join("&")}).filter(n=>n!=="").join("&")}clone(n){let t=new e({encoder:this.encoder});return t.cloneFrom=this.cloneFrom||this,t.updates=(this.updates||[]).concat(n),t}init(){this.map===null&&(this.map=new Map),this.cloneFrom!==null&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(n=>this.map.set(n,this.cloneFrom.map.get(n))),this.updates.forEach(n=>{switch(n.op){case"a":case"s":let t=(n.op==="a"?this.map.get(n.param):void 0)||[];t.push(Xs(n.value)),this.map.set(n.param,t);break;case"d":if(n.value!==void 0){let r=this.map.get(n.param)||[],o=r.indexOf(Xs(n.value));o!==-1&&r.splice(o,1),r.length>0?this.map.set(n.param,r):this.map.delete(n.param)}else{this.map.delete(n.param);break}}}),this.cloneFrom=this.updates=null)}};var _u=class{constructor(){this.map=new Map}set(n,t){return this.map.set(n,t),this}get(n){return this.map.has(n)||this.map.set(n,n.defaultValue()),this.map.get(n)}delete(n){return this.map.delete(n),this}has(n){return this.map.has(n)}keys(){return this.map.keys()}};function cC(e){switch(e){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}function Pg(e){return typeof ArrayBuffer<"u"&&e instanceof ArrayBuffer}function kg(e){return typeof Blob<"u"&&e instanceof Blob}function Fg(e){return typeof FormData<"u"&&e instanceof FormData}function lC(e){return typeof URLSearchParams<"u"&&e instanceof URLSearchParams}var To=class e{constructor(n,t,r,o){this.url=t,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=n.toUpperCase();let i;if(cC(this.method)||o?(this.body=r!==void 0?r:null,i=o):i=r,i&&(this.reportProgress=!!i.reportProgress,this.withCredentials=!!i.withCredentials,i.responseType&&(this.responseType=i.responseType),i.headers&&(this.headers=i.headers),i.context&&(this.context=i.context),i.params&&(this.params=i.params),this.transferCache=i.transferCache),this.headers??=new En,this.context??=new _u,!this.params)this.params=new Ut,this.urlWithParams=t;else{let s=this.params.toString();if(s.length===0)this.urlWithParams=t;else{let a=t.indexOf("?"),c=a===-1?"?":ap.set(f,n.setHeaders[f]),l)),n.setParams&&(u=Object.keys(n.setParams).reduce((p,f)=>p.set(f,n.setParams[f]),u)),new e(t,r,s,{params:u,headers:l,context:d,reportProgress:c,responseType:o,withCredentials:a,transferCache:i})}},Cr=function(e){return e[e.Sent=0]="Sent",e[e.UploadProgress=1]="UploadProgress",e[e.ResponseHeader=2]="ResponseHeader",e[e.DownloadProgress=3]="DownloadProgress",e[e.Response=4]="Response",e[e.User=5]="User",e}(Cr||{}),Oo=class{constructor(n,t=ra.Ok,r="OK"){this.headers=n.headers||new En,this.status=n.status!==void 0?n.status:t,this.statusText=n.statusText||r,this.url=n.url||null,this.ok=this.status>=200&&this.status<300}},Du=class e extends Oo{constructor(n={}){super(n),this.type=Cr.ResponseHeader}clone(n={}){return new e({headers:n.headers||this.headers,status:n.status!==void 0?n.status:this.status,statusText:n.statusText||this.statusText,url:n.url||this.url||void 0})}},ta=class e extends Oo{constructor(n={}){super(n),this.type=Cr.Response,this.body=n.body!==void 0?n.body:null}clone(n={}){return new e({body:n.body!==void 0?n.body:this.body,headers:n.headers||this.headers,status:n.status!==void 0?n.status:this.status,statusText:n.statusText||this.statusText,url:n.url||this.url||void 0})}},na=class extends Oo{constructor(n){super(n,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.status>=200&&this.status<300?this.message=`Http failure during parsing for ${n.url||"(unknown url)"}`:this.message=`Http failure response for ${n.url||"(unknown url)"}: ${n.status} ${n.statusText}`,this.error=n.error||null}},ra=function(e){return e[e.Continue=100]="Continue",e[e.SwitchingProtocols=101]="SwitchingProtocols",e[e.Processing=102]="Processing",e[e.EarlyHints=103]="EarlyHints",e[e.Ok=200]="Ok",e[e.Created=201]="Created",e[e.Accepted=202]="Accepted",e[e.NonAuthoritativeInformation=203]="NonAuthoritativeInformation",e[e.NoContent=204]="NoContent",e[e.ResetContent=205]="ResetContent",e[e.PartialContent=206]="PartialContent",e[e.MultiStatus=207]="MultiStatus",e[e.AlreadyReported=208]="AlreadyReported",e[e.ImUsed=226]="ImUsed",e[e.MultipleChoices=300]="MultipleChoices",e[e.MovedPermanently=301]="MovedPermanently",e[e.Found=302]="Found",e[e.SeeOther=303]="SeeOther",e[e.NotModified=304]="NotModified",e[e.UseProxy=305]="UseProxy",e[e.Unused=306]="Unused",e[e.TemporaryRedirect=307]="TemporaryRedirect",e[e.PermanentRedirect=308]="PermanentRedirect",e[e.BadRequest=400]="BadRequest",e[e.Unauthorized=401]="Unauthorized",e[e.PaymentRequired=402]="PaymentRequired",e[e.Forbidden=403]="Forbidden",e[e.NotFound=404]="NotFound",e[e.MethodNotAllowed=405]="MethodNotAllowed",e[e.NotAcceptable=406]="NotAcceptable",e[e.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",e[e.RequestTimeout=408]="RequestTimeout",e[e.Conflict=409]="Conflict",e[e.Gone=410]="Gone",e[e.LengthRequired=411]="LengthRequired",e[e.PreconditionFailed=412]="PreconditionFailed",e[e.PayloadTooLarge=413]="PayloadTooLarge",e[e.UriTooLong=414]="UriTooLong",e[e.UnsupportedMediaType=415]="UnsupportedMediaType",e[e.RangeNotSatisfiable=416]="RangeNotSatisfiable",e[e.ExpectationFailed=417]="ExpectationFailed",e[e.ImATeapot=418]="ImATeapot",e[e.MisdirectedRequest=421]="MisdirectedRequest",e[e.UnprocessableEntity=422]="UnprocessableEntity",e[e.Locked=423]="Locked",e[e.FailedDependency=424]="FailedDependency",e[e.TooEarly=425]="TooEarly",e[e.UpgradeRequired=426]="UpgradeRequired",e[e.PreconditionRequired=428]="PreconditionRequired",e[e.TooManyRequests=429]="TooManyRequests",e[e.RequestHeaderFieldsTooLarge=431]="RequestHeaderFieldsTooLarge",e[e.UnavailableForLegalReasons=451]="UnavailableForLegalReasons",e[e.InternalServerError=500]="InternalServerError",e[e.NotImplemented=501]="NotImplemented",e[e.BadGateway=502]="BadGateway",e[e.ServiceUnavailable=503]="ServiceUnavailable",e[e.GatewayTimeout=504]="GatewayTimeout",e[e.HttpVersionNotSupported=505]="HttpVersionNotSupported",e[e.VariantAlsoNegotiates=506]="VariantAlsoNegotiates",e[e.InsufficientStorage=507]="InsufficientStorage",e[e.LoopDetected=508]="LoopDetected",e[e.NotExtended=510]="NotExtended",e[e.NetworkAuthenticationRequired=511]="NetworkAuthenticationRequired",e}(ra||{});function yu(e,n){return{body:n,headers:e.headers,context:e.context,observe:e.observe,params:e.params,reportProgress:e.reportProgress,responseType:e.responseType,withCredentials:e.withCredentials,transferCache:e.transferCache}}var uC=(()=>{class e{constructor(t){this.handler=t}request(t,r,o={}){let i;if(t instanceof To)i=t;else{let c;o.headers instanceof En?c=o.headers:c=new En(o.headers);let l;o.params&&(o.params instanceof Ut?l=o.params:l=new Ut({fromObject:o.params})),i=new To(t,r,o.body!==void 0?o.body:null,{headers:c,context:o.context,params:l,reportProgress:o.reportProgress,responseType:o.responseType||"json",withCredentials:o.withCredentials,transferCache:o.transferCache})}let s=x(i).pipe(At(c=>this.handler.handle(c)));if(t instanceof To||o.observe==="events")return s;let a=s.pipe(Le(c=>c instanceof ta));switch(o.observe||"body"){case"body":switch(i.responseType){case"arraybuffer":return a.pipe(O(c=>{if(c.body!==null&&!(c.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return c.body}));case"blob":return a.pipe(O(c=>{if(c.body!==null&&!(c.body instanceof Blob))throw new Error("Response is not a Blob.");return c.body}));case"text":return a.pipe(O(c=>{if(c.body!==null&&typeof c.body!="string")throw new Error("Response is not a string.");return c.body}));case"json":default:return a.pipe(O(c=>c.body))}case"response":return a;default:throw new Error(`Unreachable: unhandled observe type ${o.observe}}`)}}delete(t,r={}){return this.request("DELETE",t,r)}get(t,r={}){return this.request("GET",t,r)}head(t,r={}){return this.request("HEAD",t,r)}jsonp(t,r){return this.request("JSONP",t,{params:new Ut().append(r,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(t,r={}){return this.request("OPTIONS",t,r)}patch(t,r,o={}){return this.request("PATCH",t,yu(o,r))}post(t,r,o={}){return this.request("POST",t,yu(o,r))}put(t,r,o={}){return this.request("PUT",t,yu(o,r))}static{this.\u0275fac=function(r){return new(r||e)(A(Ao))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})();function dC(e,n){return n(e)}function fC(e,n,t){return(r,o)=>Dt(t,()=>n(r,i=>e(i,o)))}var bu=new M(""),hC=new M(""),pC=new M("");var Lg=(()=>{class e extends Ao{constructor(t,r){super(),this.backend=t,this.injector=r,this.chain=null,this.pendingTasks=g(wn);let o=g(pC,{optional:!0});this.backend=o??t}handle(t){if(this.chain===null){let o=Array.from(new Set([...this.injector.get(bu),...this.injector.get(hC,[])]));this.chain=o.reduceRight((i,s)=>fC(i,s,this.injector),dC)}let r=this.pendingTasks.add();return this.chain(t,o=>this.backend.handle(o)).pipe(en(()=>this.pendingTasks.remove(r)))}static{this.\u0275fac=function(r){return new(r||e)(A(ea),A(Ae))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})();var gC=/^\)\]\}',?\n/;function mC(e){return"responseURL"in e&&e.responseURL?e.responseURL:/^X-Request-URL:/m.test(e.getAllResponseHeaders())?e.getResponseHeader("X-Request-URL"):null}var jg=(()=>{class e{constructor(t){this.xhrFactory=t}handle(t){if(t.method==="JSONP")throw new I(-2800,!1);let r=this.xhrFactory;return(r.\u0275loadImpl?te(r.\u0275loadImpl()):x(null)).pipe(je(()=>new B(i=>{let s=r.build();if(s.open(t.method,t.urlWithParams),t.withCredentials&&(s.withCredentials=!0),t.headers.forEach((m,y)=>s.setRequestHeader(m,y.join(","))),t.headers.has("Accept")||s.setRequestHeader("Accept","application/json, text/plain, */*"),!t.headers.has("Content-Type")){let m=t.detectContentTypeHeader();m!==null&&s.setRequestHeader("Content-Type",m)}if(t.responseType){let m=t.responseType.toLowerCase();s.responseType=m!=="json"?m:"text"}let a=t.serializeBody(),c=null,l=()=>{if(c!==null)return c;let m=s.statusText||"OK",y=new En(s.getAllResponseHeaders()),C=mC(s)||t.url;return c=new Du({headers:y,status:s.status,statusText:m,url:C}),c},u=()=>{let{headers:m,status:y,statusText:C,url:ie}=l(),R=null;y!==ra.NoContent&&(R=typeof s.response>"u"?s.responseText:s.response),y===0&&(y=R?ra.Ok:0);let J=y>=200&&y<300;if(t.responseType==="json"&&typeof R=="string"){let ee=R;R=R.replace(gC,"");try{R=R!==""?JSON.parse(R):null}catch(Pe){R=ee,J&&(J=!1,R={error:Pe,text:R})}}J?(i.next(new ta({body:R,headers:m,status:y,statusText:C,url:ie||void 0})),i.complete()):i.error(new na({error:R,headers:m,status:y,statusText:C,url:ie||void 0}))},d=m=>{let{url:y}=l(),C=new na({error:m,status:s.status||0,statusText:s.statusText||"Unknown Error",url:y||void 0});i.error(C)},p=!1,f=m=>{p||(i.next(l()),p=!0);let y={type:Cr.DownloadProgress,loaded:m.loaded};m.lengthComputable&&(y.total=m.total),t.responseType==="text"&&s.responseText&&(y.partialText=s.responseText),i.next(y)},v=m=>{let y={type:Cr.UploadProgress,loaded:m.loaded};m.lengthComputable&&(y.total=m.total),i.next(y)};return s.addEventListener("load",u),s.addEventListener("error",d),s.addEventListener("timeout",d),s.addEventListener("abort",d),t.reportProgress&&(s.addEventListener("progress",f),a!==null&&s.upload&&s.upload.addEventListener("progress",v)),s.send(a),i.next({type:Cr.Sent}),()=>{s.removeEventListener("error",d),s.removeEventListener("abort",d),s.removeEventListener("load",u),s.removeEventListener("timeout",d),t.reportProgress&&(s.removeEventListener("progress",f),a!==null&&s.upload&&s.upload.removeEventListener("progress",v)),s.readyState!==s.DONE&&s.abort()}})))}static{this.\u0275fac=function(r){return new(r||e)(A(Dr))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})(),Vg=new M(""),vC="XSRF-TOKEN",yC=new M("",{providedIn:"root",factory:()=>vC}),wC="X-XSRF-TOKEN",_C=new M("",{providedIn:"root",factory:()=>wC}),oa=class{},DC=(()=>{class e{constructor(t,r,o){this.doc=t,this.platform=r,this.cookieName=o,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if(this.platform==="server")return null;let t=this.doc.cookie||"";return t!==this.lastCookieString&&(this.parseCount++,this.lastToken=Ks(t,this.cookieName),this.lastCookieString=t),this.lastToken}static{this.\u0275fac=function(r){return new(r||e)(A(Oe),A(Vt),A(yC))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})();function bC(e,n){let t=e.url.toLowerCase();if(!g(Vg)||e.method==="GET"||e.method==="HEAD"||t.startsWith("http://")||t.startsWith("https://"))return n(e);let r=g(oa).getToken(),o=g(_C);return r!=null&&!e.headers.has(o)&&(e=e.clone({headers:e.headers.set(o,r)})),n(e)}var $g=function(e){return e[e.Interceptors=0]="Interceptors",e[e.LegacyInterceptors=1]="LegacyInterceptors",e[e.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",e[e.NoXsrfProtection=3]="NoXsrfProtection",e[e.JsonpSupport=4]="JsonpSupport",e[e.RequestsMadeViaParent=5]="RequestsMadeViaParent",e[e.Fetch=6]="Fetch",e}($g||{});function CC(e,n){return{\u0275kind:e,\u0275providers:n}}function Ug(...e){let n=[uC,jg,Lg,{provide:Ao,useExisting:Lg},{provide:ea,useExisting:jg},{provide:bu,useValue:bC,multi:!0},{provide:Vg,useValue:!0},{provide:oa,useClass:DC}];for(let t of e)n.push(...t.\u0275providers);return fr(n)}function Bg(e){return CC($g.Interceptors,e.map(n=>({provide:bu,useValue:n,multi:!0})))}var Iu=class extends Qs{constructor(){super(...arguments),this.supportsDOMEvents=!0}},Mu=class e extends Iu{static makeCurrent(){Sg(new e)}onAndCancel(n,t,r){return n.addEventListener(t,r),()=>{n.removeEventListener(t,r)}}dispatchEvent(n,t){n.dispatchEvent(t)}remove(n){n.parentNode&&n.parentNode.removeChild(n)}createElement(n,t){return t=t||this.getDefaultDocument(),t.createElement(n)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(n){return n.nodeType===Node.ELEMENT_NODE}isShadowRoot(n){return n instanceof DocumentFragment}getGlobalEventTarget(n,t){return t==="window"?window:t==="document"?n:t==="body"?n.body:null}getBaseHref(n){let t=IC();return t==null?null:MC(t)}resetBaseElement(){No=null}getUserAgent(){return window.navigator.userAgent}getCookie(n){return Ks(document.cookie,n)}},No=null;function IC(){return No=No||document.querySelector("base"),No?No.getAttribute("href"):null}function MC(e){return new URL(e,document.baseURI).pathname}var SC=(()=>{class e{build(){return new XMLHttpRequest}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})(),Su=new M(""),qg=(()=>{class e{constructor(t,r){this._zone=r,this._eventNameToPlugin=new Map,t.forEach(o=>{o.manager=this}),this._plugins=t.slice().reverse()}addEventListener(t,r,o){return this._findPluginFor(r).addEventListener(t,r,o)}getZone(){return this._zone}_findPluginFor(t){let r=this._eventNameToPlugin.get(t);if(r)return r;if(r=this._plugins.find(i=>i.supports(t)),!r)throw new I(5101,!1);return this._eventNameToPlugin.set(t,r),r}static{this.\u0275fac=function(r){return new(r||e)(A(Su),A(oe))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})(),ia=class{constructor(n){this._doc=n}},Cu="ng-app-id",Wg=(()=>{class e{constructor(t,r,o,i={}){this.doc=t,this.appId=r,this.nonce=o,this.platformId=i,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=Js(i),this.resetHostNodes()}addStyles(t){for(let r of t)this.changeUsageCount(r,1)===1&&this.onStyleAdded(r)}removeStyles(t){for(let r of t)this.changeUsageCount(r,-1)<=0&&this.onStyleRemoved(r)}ngOnDestroy(){let t=this.styleNodesInDOM;t&&(t.forEach(r=>r.remove()),t.clear());for(let r of this.getAllStyles())this.onStyleRemoved(r);this.resetHostNodes()}addHost(t){this.hostNodes.add(t);for(let r of this.getAllStyles())this.addStyleToHost(t,r)}removeHost(t){this.hostNodes.delete(t)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(t){for(let r of this.hostNodes)this.addStyleToHost(r,t)}onStyleRemoved(t){let r=this.styleRef;r.get(t)?.elements?.forEach(o=>o.remove()),r.delete(t)}collectServerRenderedStyles(){let t=this.doc.head?.querySelectorAll(`style[${Cu}="${this.appId}"]`);if(t?.length){let r=new Map;return t.forEach(o=>{o.textContent!=null&&r.set(o.textContent,o)}),r}return null}changeUsageCount(t,r){let o=this.styleRef;if(o.has(t)){let i=o.get(t);return i.usage+=r,i.usage}return o.set(t,{usage:r,elements:[]}),r}getStyleElement(t,r){let o=this.styleNodesInDOM,i=o?.get(r);if(i?.parentNode===t)return o.delete(r),i.removeAttribute(Cu),i;{let s=this.doc.createElement("style");return this.nonce&&s.setAttribute("nonce",this.nonce),s.textContent=r,this.platformIsServer&&s.setAttribute(Cu,this.appId),t.appendChild(s),s}}addStyleToHost(t,r){let o=this.getStyleElement(t,r),i=this.styleRef,s=i.get(r)?.elements;s?s.push(o):i.set(r,{elements:[o],usage:1})}resetHostNodes(){let t=this.hostNodes;t.clear(),t.add(this.doc.head)}static{this.\u0275fac=function(r){return new(r||e)(A(Oe),A(Kl),A(Xl,8),A(Vt))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})(),Eu={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/MathML/"},Tu=/%COMP%/g,Zg="%COMP%",xC=`_nghost-${Zg}`,TC=`_ngcontent-${Zg}`,AC=!0,OC=new M("",{providedIn:"root",factory:()=>AC});function NC(e){return TC.replace(Tu,e)}function RC(e){return xC.replace(Tu,e)}function Yg(e,n){return n.map(t=>t.replace(Tu,e))}var Hg=(()=>{class e{constructor(t,r,o,i,s,a,c,l=null){this.eventManager=t,this.sharedStylesHost=r,this.appId=o,this.removeStylesOnCompDestroy=i,this.doc=s,this.platformId=a,this.ngZone=c,this.nonce=l,this.rendererByCompId=new Map,this.platformIsServer=Js(a),this.defaultRenderer=new Ro(t,s,c,this.platformIsServer)}createRenderer(t,r){if(!t||!r)return this.defaultRenderer;this.platformIsServer&&r.encapsulation===dt.ShadowDom&&(r=G(_({},r),{encapsulation:dt.Emulated}));let o=this.getOrCreateRenderer(t,r);return o instanceof sa?o.applyToHost(t):o instanceof Po&&o.applyStyles(),o}getOrCreateRenderer(t,r){let o=this.rendererByCompId,i=o.get(r.id);if(!i){let s=this.doc,a=this.ngZone,c=this.eventManager,l=this.sharedStylesHost,u=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(r.encapsulation){case dt.Emulated:i=new sa(c,l,r,this.appId,u,s,a,d);break;case dt.ShadowDom:return new xu(c,l,t,r,s,a,this.nonce,d);default:i=new Po(c,l,r,u,s,a,d);break}o.set(r.id,i)}return i}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(r){return new(r||e)(A(qg),A(Wg),A(Kl),A(OC),A(Oe),A(Vt),A(oe),A(Xl))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})(),Ro=class{constructor(n,t,r,o){this.eventManager=n,this.doc=t,this.ngZone=r,this.platformIsServer=o,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(n,t){return t?this.doc.createElementNS(Eu[t]||t,n):this.doc.createElement(n)}createComment(n){return this.doc.createComment(n)}createText(n){return this.doc.createTextNode(n)}appendChild(n,t){(zg(n)?n.content:n).appendChild(t)}insertBefore(n,t,r){n&&(zg(n)?n.content:n).insertBefore(t,r)}removeChild(n,t){n&&n.removeChild(t)}selectRootElement(n,t){let r=typeof n=="string"?this.doc.querySelector(n):n;if(!r)throw new I(-5104,!1);return t||(r.textContent=""),r}parentNode(n){return n.parentNode}nextSibling(n){return n.nextSibling}setAttribute(n,t,r,o){if(o){t=o+":"+t;let i=Eu[o];i?n.setAttributeNS(i,t,r):n.setAttribute(t,r)}else n.setAttribute(t,r)}removeAttribute(n,t,r){if(r){let o=Eu[r];o?n.removeAttributeNS(o,t):n.removeAttribute(`${r}:${t}`)}else n.removeAttribute(t)}addClass(n,t){n.classList.add(t)}removeClass(n,t){n.classList.remove(t)}setStyle(n,t,r,o){o&(_t.DashCase|_t.Important)?n.style.setProperty(t,r,o&_t.Important?"important":""):n.style[t]=r}removeStyle(n,t,r){r&_t.DashCase?n.style.removeProperty(t):n.style[t]=""}setProperty(n,t,r){n!=null&&(n[t]=r)}setValue(n,t){n.nodeValue=t}listen(n,t,r){if(typeof n=="string"&&(n=Et().getGlobalEventTarget(this.doc,n),!n))throw new Error(`Unsupported event target ${n} for event ${t}`);return this.eventManager.addEventListener(n,t,this.decoratePreventDefault(r))}decoratePreventDefault(n){return t=>{if(t==="__ngUnwrap__")return n;(this.platformIsServer?this.ngZone.runGuarded(()=>n(t)):n(t))===!1&&t.preventDefault()}}};function zg(e){return e.tagName==="TEMPLATE"&&e.content!==void 0}var xu=class extends Ro{constructor(n,t,r,o,i,s,a,c){super(n,i,s,c),this.sharedStylesHost=t,this.hostEl=r,this.shadowRoot=r.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);let l=Yg(o.id,o.styles);for(let u of l){let d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=u,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(n){return n===this.hostEl?this.shadowRoot:n}appendChild(n,t){return super.appendChild(this.nodeOrShadowRoot(n),t)}insertBefore(n,t,r){return super.insertBefore(this.nodeOrShadowRoot(n),t,r)}removeChild(n,t){return super.removeChild(this.nodeOrShadowRoot(n),t)}parentNode(n){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(n)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}},Po=class extends Ro{constructor(n,t,r,o,i,s,a,c){super(n,i,s,a),this.sharedStylesHost=t,this.removeStylesOnCompDestroy=o,this.styles=c?Yg(c,r.styles):r.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}},sa=class extends Po{constructor(n,t,r,o,i,s,a,c){let l=o+"-"+r.id;super(n,t,r,i,s,a,c,l),this.contentAttr=NC(l),this.hostAttr=RC(l)}applyToHost(n){this.applyStyles(),this.setAttribute(n,this.hostAttr,"")}createElement(n,t){let r=super.createElement(n,t);return super.setAttribute(r,this.contentAttr,""),r}},PC=(()=>{class e extends ia{constructor(t){super(t)}supports(t){return!0}addEventListener(t,r,o){return t.addEventListener(r,o,!1),()=>this.removeEventListener(t,r,o)}removeEventListener(t,r,o){return t.removeEventListener(r,o)}static{this.\u0275fac=function(r){return new(r||e)(A(Oe))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})(),Gg=["alt","control","meta","shift"],kC={"\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"},FC={alt:e=>e.altKey,control:e=>e.ctrlKey,meta:e=>e.metaKey,shift:e=>e.shiftKey},LC=(()=>{class e extends ia{constructor(t){super(t)}supports(t){return e.parseEventName(t)!=null}addEventListener(t,r,o){let i=e.parseEventName(r),s=e.eventCallback(i.fullKey,o,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>Et().onAndCancel(t,i.domEventName,s))}static parseEventName(t){let r=t.toLowerCase().split("."),o=r.shift();if(r.length===0||!(o==="keydown"||o==="keyup"))return null;let i=e._normalizeKey(r.pop()),s="",a=r.indexOf("code");if(a>-1&&(r.splice(a,1),s="code."),Gg.forEach(l=>{let u=r.indexOf(l);u>-1&&(r.splice(u,1),s+=l+".")}),s+=i,r.length!=0||i.length===0)return null;let c={};return c.domEventName=o,c.fullKey=s,c}static matchEventFullKeyCode(t,r){let o=kC[t.key]||t.key,i="";return r.indexOf("code.")>-1&&(o=t.code,i="code."),o==null||!o?!1:(o=o.toLowerCase(),o===" "?o="space":o==="."&&(o="dot"),Gg.forEach(s=>{if(s!==o){let a=FC[s];a(t)&&(i+=s+".")}}),i+=o,i===r)}static eventCallback(t,r,o){return i=>{e.matchEventFullKeyCode(i,t)&&o.runGuarded(()=>r(i))}}static _normalizeKey(t){return t==="esc"?"escape":t}static{this.\u0275fac=function(r){return new(r||e)(A(Oe))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac})}}return e})();function Qg(e,n){return Cg(_({rootComponent:e},jC(n)))}function jC(e){return{appProviders:[...HC,...e?.providers??[]],platformProviders:BC}}function VC(){Mu.makeCurrent()}function $C(){return new ot}function UC(){return Op(document),document}var BC=[{provide:Vt,useValue:Og},{provide:Jl,useValue:VC,multi:!0},{provide:Oe,useFactory:UC,deps:[]}];var HC=[{provide:Ts,useValue:"root"},{provide:ot,useFactory:$C,deps:[]},{provide:Su,useClass:PC,multi:!0,deps:[Oe,oe,Vt]},{provide:Su,useClass:LC,multi:!0,deps:[Oe]},Hg,Wg,qg,{provide:vo,useExisting:Hg},{provide:Dr,useClass:SC,deps:[]},[]];var Kg=(()=>{class e{constructor(t){this._doc=t}getTitle(){return this._doc.title}setTitle(t){this._doc.title=t||""}static{this.\u0275fac=function(r){return new(r||e)(A(Oe))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var N="primary",Yo=Symbol("RouteTitle"),Pu=class{constructor(n){this.params=n||{}}has(n){return Object.prototype.hasOwnProperty.call(this.params,n)}get(n){if(this.has(n)){let t=this.params[n];return Array.isArray(t)?t[0]:t}return null}getAll(n){if(this.has(n)){let t=this.params[n];return Array.isArray(t)?t:[t]}return[]}get keys(){return Object.keys(this.params)}};function xr(e){return new Pu(e)}function GC(e,n,t){let r=t.path.split("/");if(r.length>e.length||t.pathMatch==="full"&&(n.hasChildren()||r.lengthr[i]===o)}else return e===n}function om(e){return e.length>0?e[e.length-1]:null}function Gt(e){return wc(e)?e:Dn(e)?te(Promise.resolve(e)):x(e)}var WC={exact:sm,subset:am},im={exact:ZC,subset:YC,ignored:()=>!0};function Jg(e,n,t){return WC[t.paths](e.root,n.root,t.matrixParams)&&im[t.queryParams](e.queryParams,n.queryParams)&&!(t.fragment==="exact"&&e.fragment!==n.fragment)}function ZC(e,n){return ht(e,n)}function sm(e,n,t){if(!Mn(e.segments,n.segments)||!la(e.segments,n.segments,t)||e.numberOfChildren!==n.numberOfChildren)return!1;for(let r in n.children)if(!e.children[r]||!sm(e.children[r],n.children[r],t))return!1;return!0}function YC(e,n){return Object.keys(n).length<=Object.keys(e).length&&Object.keys(n).every(t=>rm(e[t],n[t]))}function am(e,n,t){return cm(e,n,n.segments,t)}function cm(e,n,t,r){if(e.segments.length>t.length){let o=e.segments.slice(0,t.length);return!(!Mn(o,t)||n.hasChildren()||!la(o,t,r))}else if(e.segments.length===t.length){if(!Mn(e.segments,t)||!la(e.segments,t,r))return!1;for(let o in n.children)if(!e.children[o]||!am(e.children[o],n.children[o],r))return!1;return!0}else{let o=t.slice(0,e.segments.length),i=t.slice(e.segments.length);return!Mn(e.segments,o)||!la(e.segments,o,r)||!e.children[N]?!1:cm(e.children[N],n,i,r)}}function la(e,n,t){return n.every((r,o)=>im[t](e[o].parameters,r.parameters))}var Bt=class{constructor(n=new q([],{}),t={},r=null){this.root=n,this.queryParams=t,this.fragment=r}get queryParamMap(){return this._queryParamMap??=xr(this.queryParams),this._queryParamMap}toString(){return JC.serialize(this)}},q=class{constructor(n,t){this.segments=n,this.children=t,this.parent=null,Object.values(t).forEach(r=>r.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return ua(this)}},In=class{constructor(n,t){this.path=n,this.parameters=t}get parameterMap(){return this._parameterMap??=xr(this.parameters),this._parameterMap}toString(){return um(this)}};function QC(e,n){return Mn(e,n)&&e.every((t,r)=>ht(t.parameters,n[r].parameters))}function Mn(e,n){return e.length!==n.length?!1:e.every((t,r)=>t.path===n[r].path)}function KC(e,n){let t=[];return Object.entries(e.children).forEach(([r,o])=>{r===N&&(t=t.concat(n(o,r)))}),Object.entries(e.children).forEach(([r,o])=>{r!==N&&(t=t.concat(n(o,r)))}),t}var ad=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:()=>new fa,providedIn:"root"})}}return e})(),fa=class{parse(n){let t=new Lu(n);return new Bt(t.parseRootSegment(),t.parseQueryParams(),t.parseFragment())}serialize(n){let t=`/${ko(n.root,!0)}`,r=tE(n.queryParams),o=typeof n.fragment=="string"?`#${XC(n.fragment)}`:"";return`${t}${r}${o}`}},JC=new fa;function ua(e){return e.segments.map(n=>um(n)).join("/")}function ko(e,n){if(!e.hasChildren())return ua(e);if(n){let t=e.children[N]?ko(e.children[N],!1):"",r=[];return Object.entries(e.children).forEach(([o,i])=>{o!==N&&r.push(`${o}:${ko(i,!1)}`)}),r.length>0?`${t}(${r.join("//")})`:t}else{let t=KC(e,(r,o)=>o===N?[ko(e.children[N],!1)]:[`${o}:${ko(r,!1)}`]);return Object.keys(e.children).length===1&&e.children[N]!=null?`${ua(e)}/${t[0]}`:`${ua(e)}/(${t.join("//")})`}}function lm(e){return encodeURIComponent(e).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function aa(e){return lm(e).replace(/%3B/gi,";")}function XC(e){return encodeURI(e)}function Fu(e){return lm(e).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function da(e){return decodeURIComponent(e)}function Xg(e){return da(e.replace(/\+/g,"%20"))}function um(e){return`${Fu(e.path)}${eE(e.parameters)}`}function eE(e){return Object.entries(e).map(([n,t])=>`;${Fu(n)}=${Fu(t)}`).join("")}function tE(e){let n=Object.entries(e).map(([t,r])=>Array.isArray(r)?r.map(o=>`${aa(t)}=${aa(o)}`).join("&"):`${aa(t)}=${aa(r)}`).filter(t=>t);return n.length?`?${n.join("&")}`:""}var nE=/^[^\/()?;#]+/;function Au(e){let n=e.match(nE);return n?n[0]:""}var rE=/^[^\/()?;=#]+/;function oE(e){let n=e.match(rE);return n?n[0]:""}var iE=/^[^=?&#]+/;function sE(e){let n=e.match(iE);return n?n[0]:""}var aE=/^[^&#]+/;function cE(e){let n=e.match(aE);return n?n[0]:""}var Lu=class{constructor(n){this.url=n,this.remaining=n}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new q([],{}):new q([],this.parseChildren())}parseQueryParams(){let n={};if(this.consumeOptional("?"))do this.parseQueryParam(n);while(this.consumeOptional("&"));return n}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(this.remaining==="")return{};this.consumeOptional("/");let n=[];for(this.peekStartsWith("(")||n.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),n.push(this.parseSegment());let t={};this.peekStartsWith("/(")&&(this.capture("/"),t=this.parseParens(!0));let r={};return this.peekStartsWith("(")&&(r=this.parseParens(!1)),(n.length>0||Object.keys(t).length>0)&&(r[N]=new q(n,t)),r}parseSegment(){let n=Au(this.remaining);if(n===""&&this.peekStartsWith(";"))throw new I(4009,!1);return this.capture(n),new In(da(n),this.parseMatrixParams())}parseMatrixParams(){let n={};for(;this.consumeOptional(";");)this.parseParam(n);return n}parseParam(n){let t=oE(this.remaining);if(!t)return;this.capture(t);let r="";if(this.consumeOptional("=")){let o=Au(this.remaining);o&&(r=o,this.capture(r))}n[da(t)]=da(r)}parseQueryParam(n){let t=sE(this.remaining);if(!t)return;this.capture(t);let r="";if(this.consumeOptional("=")){let s=cE(this.remaining);s&&(r=s,this.capture(r))}let o=Xg(t),i=Xg(r);if(n.hasOwnProperty(o)){let s=n[o];Array.isArray(s)||(s=[s],n[o]=s),s.push(i)}else n[o]=i}parseParens(n){let t={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let r=Au(this.remaining),o=this.remaining[r.length];if(o!=="/"&&o!==")"&&o!==";")throw new I(4010,!1);let i;r.indexOf(":")>-1?(i=r.slice(0,r.indexOf(":")),this.capture(i),this.capture(":")):n&&(i=N);let s=this.parseChildren();t[i]=Object.keys(s).length===1?s[N]:new q([],s),this.consumeOptional("//")}return t}peekStartsWith(n){return this.remaining.startsWith(n)}consumeOptional(n){return this.peekStartsWith(n)?(this.remaining=this.remaining.substring(n.length),!0):!1}capture(n){if(!this.consumeOptional(n))throw new I(4011,!1)}};function dm(e){return e.segments.length>0?new q([],{[N]:e}):e}function fm(e){let n={};for(let[r,o]of Object.entries(e.children)){let i=fm(o);if(r===N&&i.segments.length===0&&i.hasChildren())for(let[s,a]of Object.entries(i.children))n[s]=a;else(i.segments.length>0||i.hasChildren())&&(n[r]=i)}let t=new q(e.segments,n);return lE(t)}function lE(e){if(e.numberOfChildren===1&&e.children[N]){let n=e.children[N];return new q(e.segments.concat(n.segments),n.children)}return e}function Tr(e){return e instanceof Bt}function uE(e,n,t=null,r=null){let o=hm(e);return pm(o,n,t,r)}function hm(e){let n;function t(i){let s={};for(let c of i.children){let l=t(c);s[c.outlet]=l}let a=new q(i.url,s);return i===e&&(n=a),a}let r=t(e.root),o=dm(r);return n??o}function pm(e,n,t,r){let o=e;for(;o.parent;)o=o.parent;if(n.length===0)return Ou(o,o,o,t,r);let i=dE(n);if(i.toRoot())return Ou(o,o,new q([],{}),t,r);let s=fE(i,o,e),a=s.processChildren?jo(s.segmentGroup,s.index,i.commands):mm(s.segmentGroup,s.index,i.commands);return Ou(o,s.segmentGroup,a,t,r)}function ha(e){return typeof e=="object"&&e!=null&&!e.outlets&&!e.segmentPath}function Uo(e){return typeof e=="object"&&e!=null&&e.outlets}function Ou(e,n,t,r,o){let i={};r&&Object.entries(r).forEach(([c,l])=>{i[c]=Array.isArray(l)?l.map(u=>`${u}`):`${l}`});let s;e===n?s=t:s=gm(e,n,t);let a=dm(fm(s));return new Bt(a,i,o)}function gm(e,n,t){let r={};return Object.entries(e.children).forEach(([o,i])=>{i===n?r[o]=t:r[o]=gm(i,n,t)}),new q(e.segments,r)}var pa=class{constructor(n,t,r){if(this.isAbsolute=n,this.numberOfDoubleDots=t,this.commands=r,n&&r.length>0&&ha(r[0]))throw new I(4003,!1);let o=r.find(Uo);if(o&&o!==om(r))throw new I(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function dE(e){if(typeof e[0]=="string"&&e.length===1&&e[0]==="/")return new pa(!0,0,e);let n=0,t=!1,r=e.reduce((o,i,s)=>{if(typeof i=="object"&&i!=null){if(i.outlets){let a={};return Object.entries(i.outlets).forEach(([c,l])=>{a[c]=typeof l=="string"?l.split("/"):l}),[...o,{outlets:a}]}if(i.segmentPath)return[...o,i.segmentPath]}return typeof i!="string"?[...o,i]:s===0?(i.split("/").forEach((a,c)=>{c==0&&a==="."||(c==0&&a===""?t=!0:a===".."?n++:a!=""&&o.push(a))}),o):[...o,i]},[]);return new pa(t,n,r)}var Mr=class{constructor(n,t,r){this.segmentGroup=n,this.processChildren=t,this.index=r}};function fE(e,n,t){if(e.isAbsolute)return new Mr(n,!0,0);if(!t)return new Mr(n,!1,NaN);if(t.parent===null)return new Mr(t,!0,0);let r=ha(e.commands[0])?0:1,o=t.segments.length-1+r;return hE(t,o,e.numberOfDoubleDots)}function hE(e,n,t){let r=e,o=n,i=t;for(;i>o;){if(i-=o,r=r.parent,!r)throw new I(4005,!1);o=r.segments.length}return new Mr(r,!1,o-i)}function pE(e){return Uo(e[0])?e[0].outlets:{[N]:e}}function mm(e,n,t){if(e??=new q([],{}),e.segments.length===0&&e.hasChildren())return jo(e,n,t);let r=gE(e,n,t),o=t.slice(r.commandIndex);if(r.match&&r.pathIndexi!==N)&&e.children[N]&&e.numberOfChildren===1&&e.children[N].segments.length===0){let i=jo(e.children[N],n,t);return new q(e.segments,i.children)}return Object.entries(r).forEach(([i,s])=>{typeof s=="string"&&(s=[s]),s!==null&&(o[i]=mm(e.children[i],n,s))}),Object.entries(e.children).forEach(([i,s])=>{r[i]===void 0&&(o[i]=s)}),new q(e.segments,o)}}function gE(e,n,t){let r=0,o=n,i={match:!1,pathIndex:0,commandIndex:0};for(;o=t.length)return i;let s=e.segments[o],a=t[r];if(Uo(a))break;let c=`${a}`,l=r0&&c===void 0)break;if(c&&l&&typeof l=="object"&&l.outlets===void 0){if(!tm(c,l,s))return i;r+=2}else{if(!tm(c,{},s))return i;r++}o++}return{match:!0,pathIndex:o,commandIndex:r}}function ju(e,n,t){let r=e.segments.slice(0,n),o=0;for(;o{typeof r=="string"&&(r=[r]),r!==null&&(n[t]=ju(new q([],{}),0,r))}),n}function em(e){let n={};return Object.entries(e).forEach(([t,r])=>n[t]=`${r}`),n}function tm(e,n,t){return e==t.path&&ht(n,t.parameters)}var Vo="imperative",ve=function(e){return e[e.NavigationStart=0]="NavigationStart",e[e.NavigationEnd=1]="NavigationEnd",e[e.NavigationCancel=2]="NavigationCancel",e[e.NavigationError=3]="NavigationError",e[e.RoutesRecognized=4]="RoutesRecognized",e[e.ResolveStart=5]="ResolveStart",e[e.ResolveEnd=6]="ResolveEnd",e[e.GuardsCheckStart=7]="GuardsCheckStart",e[e.GuardsCheckEnd=8]="GuardsCheckEnd",e[e.RouteConfigLoadStart=9]="RouteConfigLoadStart",e[e.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",e[e.ChildActivationStart=11]="ChildActivationStart",e[e.ChildActivationEnd=12]="ChildActivationEnd",e[e.ActivationStart=13]="ActivationStart",e[e.ActivationEnd=14]="ActivationEnd",e[e.Scroll=15]="Scroll",e[e.NavigationSkipped=16]="NavigationSkipped",e}(ve||{}),Ye=class{constructor(n,t){this.id=n,this.url=t}},Bo=class extends Ye{constructor(n,t,r="imperative",o=null){super(n,t),this.type=ve.NavigationStart,this.navigationTrigger=r,this.restoredState=o}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},Ht=class extends Ye{constructor(n,t,r){super(n,t),this.urlAfterRedirects=r,this.type=ve.NavigationEnd}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},Ue=function(e){return e[e.Redirect=0]="Redirect",e[e.SupersededByNewNavigation=1]="SupersededByNewNavigation",e[e.NoDataFromResolver=2]="NoDataFromResolver",e[e.GuardRejected=3]="GuardRejected",e}(Ue||{}),Vu=function(e){return e[e.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",e[e.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",e}(Vu||{}),zt=class extends Ye{constructor(n,t,r,o){super(n,t),this.reason=r,this.code=o,this.type=ve.NavigationCancel}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}},Sn=class extends Ye{constructor(n,t,r,o){super(n,t),this.reason=r,this.code=o,this.type=ve.NavigationSkipped}},Ho=class extends Ye{constructor(n,t,r,o){super(n,t),this.error=r,this.target=o,this.type=ve.NavigationError}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},ga=class extends Ye{constructor(n,t,r,o){super(n,t),this.urlAfterRedirects=r,this.state=o,this.type=ve.RoutesRecognized}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},$u=class extends Ye{constructor(n,t,r,o){super(n,t),this.urlAfterRedirects=r,this.state=o,this.type=ve.GuardsCheckStart}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Uu=class extends Ye{constructor(n,t,r,o,i){super(n,t),this.urlAfterRedirects=r,this.state=o,this.shouldActivate=i,this.type=ve.GuardsCheckEnd}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},Bu=class extends Ye{constructor(n,t,r,o){super(n,t),this.urlAfterRedirects=r,this.state=o,this.type=ve.ResolveStart}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Hu=class extends Ye{constructor(n,t,r,o){super(n,t),this.urlAfterRedirects=r,this.state=o,this.type=ve.ResolveEnd}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},zu=class{constructor(n){this.route=n,this.type=ve.RouteConfigLoadStart}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},Gu=class{constructor(n){this.route=n,this.type=ve.RouteConfigLoadEnd}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},qu=class{constructor(n){this.snapshot=n,this.type=ve.ChildActivationStart}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Wu=class{constructor(n){this.snapshot=n,this.type=ve.ChildActivationEnd}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Zu=class{constructor(n){this.snapshot=n,this.type=ve.ActivationStart}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Yu=class{constructor(n){this.snapshot=n,this.type=ve.ActivationEnd}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}};var zo=class{},Go=class{constructor(n){this.url=n}};var Qu=class{constructor(){this.outlet=null,this.route=null,this.injector=null,this.children=new Da,this.attachRef=null}},Da=(()=>{class e{constructor(){this.contexts=new Map}onChildOutletCreated(t,r){let o=this.getOrCreateContext(t);o.outlet=r,this.contexts.set(t,o)}onChildOutletDestroyed(t){let r=this.getContext(t);r&&(r.outlet=null,r.attachRef=null)}onOutletDeactivated(){let t=this.contexts;return this.contexts=new Map,t}onOutletReAttached(t){this.contexts=t}getOrCreateContext(t){let r=this.getContext(t);return r||(r=new Qu,this.contexts.set(t,r)),r}getContext(t){return this.contexts.get(t)||null}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),ma=class{constructor(n){this._root=n}get root(){return this._root.value}parent(n){let t=this.pathFromRoot(n);return t.length>1?t[t.length-2]:null}children(n){let t=Ku(n,this._root);return t?t.children.map(r=>r.value):[]}firstChild(n){let t=Ku(n,this._root);return t&&t.children.length>0?t.children[0].value:null}siblings(n){let t=Ju(n,this._root);return t.length<2?[]:t[t.length-2].children.map(o=>o.value).filter(o=>o!==n)}pathFromRoot(n){return Ju(n,this._root).map(t=>t.value)}};function Ku(e,n){if(e===n.value)return n;for(let t of n.children){let r=Ku(e,t);if(r)return r}return null}function Ju(e,n){if(e===n.value)return[n];for(let t of n.children){let r=Ju(e,t);if(r.length)return r.unshift(n),r}return[]}var $e=class{constructor(n,t){this.value=n,this.children=t}toString(){return`TreeNode(${this.value})`}};function Ir(e){let n={};return e&&e.children.forEach(t=>n[t.value.outlet]=t),n}var va=class extends ma{constructor(n,t){super(n),this.snapshot=t,ld(this,n)}toString(){return this.snapshot.toString()}};function vm(e){let n=vE(e),t=new ge([new In("",{})]),r=new ge({}),o=new ge({}),i=new ge({}),s=new ge(""),a=new Be(t,r,i,s,o,N,e,n.root);return a.snapshot=n.root,new va(new $e(a,[]),n)}function vE(e){let n={},t={},r={},o="",i=new qo([],n,r,o,t,N,e,null,{});return new ya("",new $e(i,[]))}var Be=class{constructor(n,t,r,o,i,s,a,c){this.urlSubject=n,this.paramsSubject=t,this.queryParamsSubject=r,this.fragmentSubject=o,this.dataSubject=i,this.outlet=s,this.component=a,this._futureSnapshot=c,this.title=this.dataSubject?.pipe(O(l=>l[Yo]))??x(void 0),this.url=n,this.params=t,this.queryParams=r,this.fragment=o,this.data=i}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(O(n=>xr(n))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(O(n=>xr(n))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function cd(e,n,t="emptyOnly"){let r,{routeConfig:o}=e;return n!==null&&(t==="always"||o?.path===""||!n.component&&!n.routeConfig?.loadComponent)?r={params:_(_({},n.params),e.params),data:_(_({},n.data),e.data),resolve:_(_(_(_({},e.data),n.data),o?.data),e._resolvedData)}:r={params:_({},e.params),data:_({},e.data),resolve:_(_({},e.data),e._resolvedData??{})},o&&wm(o)&&(r.resolve[Yo]=o.title),r}var qo=class{get title(){return this.data?.[Yo]}constructor(n,t,r,o,i,s,a,c,l){this.url=n,this.params=t,this.queryParams=r,this.fragment=o,this.data=i,this.outlet=s,this.component=a,this.routeConfig=c,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??=xr(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=xr(this.queryParams),this._queryParamMap}toString(){let n=this.url.map(r=>r.toString()).join("/"),t=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${n}', path:'${t}')`}},ya=class extends ma{constructor(n,t){super(t),this.url=n,ld(this,t)}toString(){return ym(this._root)}};function ld(e,n){n.value._routerState=e,n.children.forEach(t=>ld(e,t))}function ym(e){let n=e.children.length>0?` { ${e.children.map(ym).join(", ")} } `:"";return`${e.value}${n}`}function Nu(e){if(e.snapshot){let n=e.snapshot,t=e._futureSnapshot;e.snapshot=t,ht(n.queryParams,t.queryParams)||e.queryParamsSubject.next(t.queryParams),n.fragment!==t.fragment&&e.fragmentSubject.next(t.fragment),ht(n.params,t.params)||e.paramsSubject.next(t.params),qC(n.url,t.url)||e.urlSubject.next(t.url),ht(n.data,t.data)||e.dataSubject.next(t.data)}else e.snapshot=e._futureSnapshot,e.dataSubject.next(e._futureSnapshot.data)}function Xu(e,n){let t=ht(e.params,n.params)&&QC(e.url,n.url),r=!e.parent!=!n.parent;return t&&!r&&(!e.parent||Xu(e.parent,n.parent))}function wm(e){return typeof e.title=="string"||e.title===null}var Qo=(()=>{class e{constructor(){this.activated=null,this._activatedRoute=null,this.name=N,this.activateEvents=new _e,this.deactivateEvents=new _e,this.attachEvents=new _e,this.detachEvents=new _e,this.parentContexts=g(Da),this.location=g(Hs),this.changeDetector=g(bn),this.environmentInjector=g(Ae),this.inputBinder=g(ud,{optional:!0}),this.supportsBindingToComponentInputs=!0}get activatedComponentRef(){return this.activated}ngOnChanges(t){if(t.name){let{firstChange:r,previousValue:o}=t.name;if(r)return;this.isTrackedInParentContexts(o)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(o)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(t){return this.parentContexts.getContext(t)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let t=this.parentContexts.getContext(this.name);t?.route&&(t.attachRef?this.attach(t.attachRef,t.route):this.activateWith(t.route,t.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new I(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new I(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new I(4012,!1);this.location.detach();let t=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(t.instance),t}attach(t,r){this.activated=t,this._activatedRoute=r,this.location.insert(t.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(t.instance)}deactivate(){if(this.activated){let t=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(t)}}activateWith(t,r){if(this.isActivated)throw new I(4013,!1);this._activatedRoute=t;let o=this.location,s=t.snapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,c=new ed(t,a,o.injector);this.activated=o.createComponent(s,{index:o.length,injector:c,environmentInjector:r??this.environmentInjector}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275dir=Ve({type:e,selectors:[["router-outlet"]],inputs:{name:"name"},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],standalone:!0,features:[Ft]})}}return e})(),ed=class e{__ngOutletInjector(n){return new e(this.route,this.childContexts,n)}constructor(n,t,r){this.route=n,this.childContexts=t,this.parent=r}get(n,t){return n===Be?this.route:n===Da?this.childContexts:this.parent.get(n,t)}},ud=new M("");function yE(e,n,t){let r=Wo(e,n._root,t?t._root:void 0);return new va(r,n)}function Wo(e,n,t){if(t&&e.shouldReuseRoute(n.value,t.value.snapshot)){let r=t.value;r._futureSnapshot=n.value;let o=wE(e,n,t);return new $e(r,o)}else{if(e.shouldAttach(n.value)){let i=e.retrieve(n.value);if(i!==null){let s=i.route;return s.value._futureSnapshot=n.value,s.children=n.children.map(a=>Wo(e,a)),s}}let r=_E(n.value),o=n.children.map(i=>Wo(e,i));return new $e(r,o)}}function wE(e,n,t){return n.children.map(r=>{for(let o of t.children)if(e.shouldReuseRoute(r.value,o.value.snapshot))return Wo(e,r,o);return Wo(e,r)})}function _E(e){return new Be(new ge(e.url),new ge(e.params),new ge(e.queryParams),new ge(e.fragment),new ge(e.data),e.outlet,e.component,e)}var _m="ngNavigationCancelingError";function Dm(e,n){let{redirectTo:t,navigationBehaviorOptions:r}=Tr(n)?{redirectTo:n,navigationBehaviorOptions:void 0}:n,o=bm(!1,Ue.Redirect);return o.url=t,o.navigationBehaviorOptions=r,o}function bm(e,n){let t=new Error(`NavigationCancelingError: ${e||""}`);return t[_m]=!0,t.cancellationCode=n,t}function DE(e){return Cm(e)&&Tr(e.url)}function Cm(e){return!!e&&e[_m]}var bE=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["ng-component"]],standalone:!0,features:[Z],decls:1,vars:0,template:function(r,o){r&1&&H(0,"router-outlet")},dependencies:[Qo],encapsulation:2})}}return e})();function CE(e,n){return e.providers&&!e._injector&&(e._injector=hu(e.providers,n,`Route: ${e.path}`)),e._injector??n}function dd(e){let n=e.children&&e.children.map(dd),t=n?G(_({},e),{children:n}):_({},e);return!t.component&&!t.loadComponent&&(n||t.loadChildren)&&t.outlet&&t.outlet!==N&&(t.component=bE),t}function pt(e){return e.outlet||N}function EE(e,n){let t=e.filter(r=>pt(r)===n);return t.push(...e.filter(r=>pt(r)!==n)),t}function Ko(e){if(!e)return null;if(e.routeConfig?._injector)return e.routeConfig._injector;for(let n=e.parent;n;n=n.parent){let t=n.routeConfig;if(t?._loadedInjector)return t._loadedInjector;if(t?._injector)return t._injector}return null}var IE=(e,n,t,r)=>O(o=>(new td(n,o.targetRouterState,o.currentRouterState,t,r).activate(e),o)),td=class{constructor(n,t,r,o,i){this.routeReuseStrategy=n,this.futureState=t,this.currState=r,this.forwardEvent=o,this.inputBindingEnabled=i}activate(n){let t=this.futureState._root,r=this.currState?this.currState._root:null;this.deactivateChildRoutes(t,r,n),Nu(this.futureState.root),this.activateChildRoutes(t,r,n)}deactivateChildRoutes(n,t,r){let o=Ir(t);n.children.forEach(i=>{let s=i.value.outlet;this.deactivateRoutes(i,o[s],r),delete o[s]}),Object.values(o).forEach(i=>{this.deactivateRouteAndItsChildren(i,r)})}deactivateRoutes(n,t,r){let o=n.value,i=t?t.value:null;if(o===i)if(o.component){let s=r.getContext(o.outlet);s&&this.deactivateChildRoutes(n,t,s.children)}else this.deactivateChildRoutes(n,t,r);else i&&this.deactivateRouteAndItsChildren(t,r)}deactivateRouteAndItsChildren(n,t){n.value.component&&this.routeReuseStrategy.shouldDetach(n.value.snapshot)?this.detachAndStoreRouteSubtree(n,t):this.deactivateRouteAndOutlet(n,t)}detachAndStoreRouteSubtree(n,t){let r=t.getContext(n.value.outlet),o=r&&n.value.component?r.children:t,i=Ir(n);for(let s of Object.values(i))this.deactivateRouteAndItsChildren(s,o);if(r&&r.outlet){let s=r.outlet.detach(),a=r.children.onOutletDeactivated();this.routeReuseStrategy.store(n.value.snapshot,{componentRef:s,route:n,contexts:a})}}deactivateRouteAndOutlet(n,t){let r=t.getContext(n.value.outlet),o=r&&n.value.component?r.children:t,i=Ir(n);for(let s of Object.values(i))this.deactivateRouteAndItsChildren(s,o);r&&(r.outlet&&(r.outlet.deactivate(),r.children.onOutletDeactivated()),r.attachRef=null,r.route=null)}activateChildRoutes(n,t,r){let o=Ir(t);n.children.forEach(i=>{this.activateRoutes(i,o[i.value.outlet],r),this.forwardEvent(new Yu(i.value.snapshot))}),n.children.length&&this.forwardEvent(new Wu(n.value.snapshot))}activateRoutes(n,t,r){let o=n.value,i=t?t.value:null;if(Nu(o),o===i)if(o.component){let s=r.getOrCreateContext(o.outlet);this.activateChildRoutes(n,t,s.children)}else this.activateChildRoutes(n,t,r);else if(o.component){let s=r.getOrCreateContext(o.outlet);if(this.routeReuseStrategy.shouldAttach(o.snapshot)){let a=this.routeReuseStrategy.retrieve(o.snapshot);this.routeReuseStrategy.store(o.snapshot,null),s.children.onOutletReAttached(a.contexts),s.attachRef=a.componentRef,s.route=a.route.value,s.outlet&&s.outlet.attach(a.componentRef,a.route.value),Nu(a.route.value),this.activateChildRoutes(n,null,s.children)}else{let a=Ko(o.snapshot);s.attachRef=null,s.route=o,s.injector=a,s.outlet&&s.outlet.activateWith(o,s.injector),this.activateChildRoutes(n,null,s.children)}}else this.activateChildRoutes(n,null,r)}},wa=class{constructor(n){this.path=n,this.route=this.path[this.path.length-1]}},Sr=class{constructor(n,t){this.component=n,this.route=t}};function ME(e,n,t){let r=e._root,o=n?n._root:null;return Fo(r,o,t,[r.value])}function SE(e){let n=e.routeConfig?e.routeConfig.canActivateChild:null;return!n||n.length===0?null:{node:e,guards:n}}function Or(e,n){let t=Symbol(),r=n.get(e,t);return r===t?typeof e=="function"&&!Ch(e)?e:n.get(e):r}function Fo(e,n,t,r,o={canDeactivateChecks:[],canActivateChecks:[]}){let i=Ir(n);return e.children.forEach(s=>{xE(s,i[s.value.outlet],t,r.concat([s.value]),o),delete i[s.value.outlet]}),Object.entries(i).forEach(([s,a])=>$o(a,t.getContext(s),o)),o}function xE(e,n,t,r,o={canDeactivateChecks:[],canActivateChecks:[]}){let i=e.value,s=n?n.value:null,a=t?t.getContext(e.value.outlet):null;if(s&&i.routeConfig===s.routeConfig){let c=TE(s,i,i.routeConfig.runGuardsAndResolvers);c?o.canActivateChecks.push(new wa(r)):(i.data=s.data,i._resolvedData=s._resolvedData),i.component?Fo(e,n,a?a.children:null,r,o):Fo(e,n,t,r,o),c&&a&&a.outlet&&a.outlet.isActivated&&o.canDeactivateChecks.push(new Sr(a.outlet.component,s))}else s&&$o(n,a,o),o.canActivateChecks.push(new wa(r)),i.component?Fo(e,null,a?a.children:null,r,o):Fo(e,null,t,r,o);return o}function TE(e,n,t){if(typeof t=="function")return t(e,n);switch(t){case"pathParamsChange":return!Mn(e.url,n.url);case"pathParamsOrQueryParamsChange":return!Mn(e.url,n.url)||!ht(e.queryParams,n.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Xu(e,n)||!ht(e.queryParams,n.queryParams);case"paramsChange":default:return!Xu(e,n)}}function $o(e,n,t){let r=Ir(e),o=e.value;Object.entries(r).forEach(([i,s])=>{o.component?n?$o(s,n.children.getContext(i),t):$o(s,null,t):$o(s,n,t)}),o.component?n&&n.outlet&&n.outlet.isActivated?t.canDeactivateChecks.push(new Sr(n.outlet.component,o)):t.canDeactivateChecks.push(new Sr(null,o)):t.canDeactivateChecks.push(new Sr(null,o))}function Jo(e){return typeof e=="function"}function AE(e){return typeof e=="boolean"}function OE(e){return e&&Jo(e.canLoad)}function NE(e){return e&&Jo(e.canActivate)}function RE(e){return e&&Jo(e.canActivateChild)}function PE(e){return e&&Jo(e.canDeactivate)}function kE(e){return e&&Jo(e.canMatch)}function Em(e){return e instanceof yt||e?.name==="EmptyError"}var ca=Symbol("INITIAL_VALUE");function Ar(){return je(e=>Wi(e.map(n=>n.pipe(wt(1),Ic(ca)))).pipe(O(n=>{for(let t of n)if(t!==!0){if(t===ca)return ca;if(t===!1||t instanceof Bt)return t}return!0}),Le(n=>n!==ca),wt(1)))}function FE(e,n){return ue(t=>{let{targetSnapshot:r,currentSnapshot:o,guards:{canActivateChecks:i,canDeactivateChecks:s}}=t;return s.length===0&&i.length===0?x(G(_({},t),{guardsResult:!0})):LE(s,r,o,e).pipe(ue(a=>a&&AE(a)?jE(r,i,e,n):x(a)),O(a=>G(_({},t),{guardsResult:a})))})}function LE(e,n,t,r){return te(e).pipe(ue(o=>HE(o.component,o.route,t,n,r)),ct(o=>o!==!0,!0))}function jE(e,n,t,r){return te(n).pipe(At(o=>Yn($E(o.route.parent,r),VE(o.route,r),BE(e,o.path,t),UE(e,o.route,t))),ct(o=>o!==!0,!0))}function VE(e,n){return e!==null&&n&&n(new Zu(e)),x(!0)}function $E(e,n){return e!==null&&n&&n(new qu(e)),x(!0)}function UE(e,n,t){let r=n.routeConfig?n.routeConfig.canActivate:null;if(!r||r.length===0)return x(!0);let o=r.map(i=>Zi(()=>{let s=Ko(n)??t,a=Or(i,s),c=NE(a)?a.canActivate(n,e):Dt(s,()=>a(n,e));return Gt(c).pipe(ct())}));return x(o).pipe(Ar())}function BE(e,n,t){let r=n[n.length-1],i=n.slice(0,n.length-1).reverse().map(s=>SE(s)).filter(s=>s!==null).map(s=>Zi(()=>{let a=s.guards.map(c=>{let l=Ko(s.node)??t,u=Or(c,l),d=RE(u)?u.canActivateChild(r,e):Dt(l,()=>u(r,e));return Gt(d).pipe(ct())});return x(a).pipe(Ar())}));return x(i).pipe(Ar())}function HE(e,n,t,r,o){let i=n&&n.routeConfig?n.routeConfig.canDeactivate:null;if(!i||i.length===0)return x(!0);let s=i.map(a=>{let c=Ko(n)??o,l=Or(a,c),u=PE(l)?l.canDeactivate(e,n,t,r):Dt(c,()=>l(e,n,t,r));return Gt(u).pipe(ct())});return x(s).pipe(Ar())}function zE(e,n,t,r){let o=n.canLoad;if(o===void 0||o.length===0)return x(!0);let i=o.map(s=>{let a=Or(s,e),c=OE(a)?a.canLoad(n,t):Dt(e,()=>a(n,t));return Gt(c)});return x(i).pipe(Ar(),Im(r))}function Im(e){return gc(fe(n=>{if(Tr(n))throw Dm(e,n)}),O(n=>n===!0))}function GE(e,n,t,r){let o=n.canMatch;if(!o||o.length===0)return x(!0);let i=o.map(s=>{let a=Or(s,e),c=kE(a)?a.canMatch(n,t):Dt(e,()=>a(n,t));return Gt(c)});return x(i).pipe(Ar(),Im(r))}var Zo=class{constructor(n){this.segmentGroup=n||null}},_a=class extends Error{constructor(n){super(),this.urlTree=n}};function Er(e){return Zn(new Zo(e))}function qE(e){return Zn(new I(4e3,!1))}function WE(e){return Zn(bm(!1,Ue.GuardRejected))}var nd=class{constructor(n,t){this.urlSerializer=n,this.urlTree=t}lineralizeSegments(n,t){let r=[],o=t.root;for(;;){if(r=r.concat(o.segments),o.numberOfChildren===0)return x(r);if(o.numberOfChildren>1||!o.children[N])return qE(n.redirectTo);o=o.children[N]}}applyRedirectCommands(n,t,r){let o=this.applyRedirectCreateUrlTree(t,this.urlSerializer.parse(t),n,r);if(t.startsWith("/"))throw new _a(o);return o}applyRedirectCreateUrlTree(n,t,r,o){let i=this.createSegmentGroup(n,t.root,r,o);return new Bt(i,this.createQueryParams(t.queryParams,this.urlTree.queryParams),t.fragment)}createQueryParams(n,t){let r={};return Object.entries(n).forEach(([o,i])=>{if(typeof i=="string"&&i.startsWith(":")){let a=i.substring(1);r[o]=t[a]}else r[o]=i}),r}createSegmentGroup(n,t,r,o){let i=this.createSegments(n,t.segments,r,o),s={};return Object.entries(t.children).forEach(([a,c])=>{s[a]=this.createSegmentGroup(n,c,r,o)}),new q(i,s)}createSegments(n,t,r,o){return t.map(i=>i.path.startsWith(":")?this.findPosParam(n,i,o):this.findOrReturn(i,r))}findPosParam(n,t,r){let o=r[t.path.substring(1)];if(!o)throw new I(4001,!1);return o}findOrReturn(n,t){let r=0;for(let o of t){if(o.path===n.path)return t.splice(r),o;r++}return n}},rd={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function ZE(e,n,t,r,o){let i=fd(e,n,t);return i.matched?(r=CE(n,r),GE(r,n,t,o).pipe(O(s=>s===!0?i:_({},rd)))):x(i)}function fd(e,n,t){if(n.path==="**")return YE(t);if(n.path==="")return n.pathMatch==="full"&&(e.hasChildren()||t.length>0)?_({},rd):{matched:!0,consumedSegments:[],remainingSegments:t,parameters:{},positionalParamSegments:{}};let o=(n.matcher||GC)(t,e,n);if(!o)return _({},rd);let i={};Object.entries(o.posParams??{}).forEach(([a,c])=>{i[a]=c.path});let s=o.consumed.length>0?_(_({},i),o.consumed[o.consumed.length-1].parameters):i;return{matched:!0,consumedSegments:o.consumed,remainingSegments:t.slice(o.consumed.length),parameters:s,positionalParamSegments:o.posParams??{}}}function YE(e){return{matched:!0,parameters:e.length>0?om(e).parameters:{},consumedSegments:e,remainingSegments:[],positionalParamSegments:{}}}function nm(e,n,t,r){return t.length>0&&JE(e,t,r)?{segmentGroup:new q(n,KE(r,new q(t,e.children))),slicedSegments:[]}:t.length===0&&XE(e,t,r)?{segmentGroup:new q(e.segments,QE(e,t,r,e.children)),slicedSegments:t}:{segmentGroup:new q(e.segments,e.children),slicedSegments:t}}function QE(e,n,t,r){let o={};for(let i of t)if(ba(e,n,i)&&!r[pt(i)]){let s=new q([],{});o[pt(i)]=s}return _(_({},r),o)}function KE(e,n){let t={};t[N]=n;for(let r of e)if(r.path===""&&pt(r)!==N){let o=new q([],{});t[pt(r)]=o}return t}function JE(e,n,t){return t.some(r=>ba(e,n,r)&&pt(r)!==N)}function XE(e,n,t){return t.some(r=>ba(e,n,r))}function ba(e,n,t){return(e.hasChildren()||n.length>0)&&t.pathMatch==="full"?!1:t.path===""}function eI(e,n,t,r){return pt(e)!==r&&(r===N||!ba(n,t,e))?!1:fd(n,e,t).matched}function tI(e,n,t){return n.length===0&&!e.children[t]}var od=class{};function nI(e,n,t,r,o,i,s="emptyOnly"){return new id(e,n,t,r,o,s,i).recognize()}var rI=31,id=class{constructor(n,t,r,o,i,s,a){this.injector=n,this.configLoader=t,this.rootComponentType=r,this.config=o,this.urlTree=i,this.paramsInheritanceStrategy=s,this.urlSerializer=a,this.applyRedirects=new nd(this.urlSerializer,this.urlTree),this.absoluteRedirectCount=0,this.allowRedirects=!0}noMatchError(n){return new I(4002,`'${n.segmentGroup}'`)}recognize(){let n=nm(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(n).pipe(O(t=>{let r=new qo([],Object.freeze({}),Object.freeze(_({},this.urlTree.queryParams)),this.urlTree.fragment,{},N,this.rootComponentType,null,{}),o=new $e(r,t),i=new ya("",o),s=uE(r,[],this.urlTree.queryParams,this.urlTree.fragment);return s.queryParams=this.urlTree.queryParams,i.url=this.urlSerializer.serialize(s),this.inheritParamsAndData(i._root,null),{state:i,tree:s}}))}match(n){return this.processSegmentGroup(this.injector,this.config,n,N).pipe(Tt(r=>{if(r instanceof _a)return this.urlTree=r.urlTree,this.match(r.urlTree.root);throw r instanceof Zo?this.noMatchError(r):r}))}inheritParamsAndData(n,t){let r=n.value,o=cd(r,t,this.paramsInheritanceStrategy);r.params=Object.freeze(o.params),r.data=Object.freeze(o.data),n.children.forEach(i=>this.inheritParamsAndData(i,r))}processSegmentGroup(n,t,r,o){return r.segments.length===0&&r.hasChildren()?this.processChildren(n,t,r):this.processSegment(n,t,r,r.segments,o,!0).pipe(O(i=>i instanceof $e?[i]:[]))}processChildren(n,t,r){let o=[];for(let i of Object.keys(r.children))i==="primary"?o.unshift(i):o.push(i);return te(o).pipe(At(i=>{let s=r.children[i],a=EE(t,i);return this.processSegmentGroup(n,a,s,i)}),Ec((i,s)=>(i.push(...s),i)),Ot(null),Cc(),ue(i=>{if(i===null)return Er(r);let s=Mm(i);return oI(s),x(s)}))}processSegment(n,t,r,o,i,s){return te(t).pipe(At(a=>this.processSegmentAgainstRoute(a._injector??n,t,a,r,o,i,s).pipe(Tt(c=>{if(c instanceof Zo)return x(null);throw c}))),ct(a=>!!a),Tt(a=>{if(Em(a))return tI(r,o,i)?x(new od):Er(r);throw a}))}processSegmentAgainstRoute(n,t,r,o,i,s,a){return eI(r,o,i,s)?r.redirectTo===void 0?this.matchSegmentAgainstRoute(n,o,r,i,s):this.allowRedirects&&a?this.expandSegmentAgainstRouteUsingRedirect(n,o,t,r,i,s):Er(o):Er(o)}expandSegmentAgainstRouteUsingRedirect(n,t,r,o,i,s){let{matched:a,consumedSegments:c,positionalParamSegments:l,remainingSegments:u}=fd(t,o,i);if(!a)return Er(t);o.redirectTo.startsWith("/")&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>rI&&(this.allowRedirects=!1));let d=this.applyRedirects.applyRedirectCommands(c,o.redirectTo,l);return this.applyRedirects.lineralizeSegments(o,d).pipe(ue(p=>this.processSegment(n,r,t,p.concat(u),s,!1)))}matchSegmentAgainstRoute(n,t,r,o,i){let s=ZE(t,r,o,n,this.urlSerializer);return r.path==="**"&&(t.children={}),s.pipe(je(a=>a.matched?(n=r._injector??n,this.getChildConfig(n,r,o).pipe(je(({routes:c})=>{let l=r._loadedInjector??n,{consumedSegments:u,remainingSegments:d,parameters:p}=a,f=new qo(u,p,Object.freeze(_({},this.urlTree.queryParams)),this.urlTree.fragment,sI(r),pt(r),r.component??r._loadedComponent??null,r,aI(r)),{segmentGroup:v,slicedSegments:m}=nm(t,u,d,c);if(m.length===0&&v.hasChildren())return this.processChildren(l,c,v).pipe(O(C=>C===null?null:new $e(f,C)));if(c.length===0&&m.length===0)return x(new $e(f,[]));let y=pt(r)===i;return this.processSegment(l,c,v,m,y?N:i,!0).pipe(O(C=>new $e(f,C instanceof $e?[C]:[])))}))):Er(t)))}getChildConfig(n,t,r){return t.children?x({routes:t.children,injector:n}):t.loadChildren?t._loadedRoutes!==void 0?x({routes:t._loadedRoutes,injector:t._loadedInjector}):zE(n,t,r,this.urlSerializer).pipe(ue(o=>o?this.configLoader.loadChildren(n,t).pipe(fe(i=>{t._loadedRoutes=i.routes,t._loadedInjector=i.injector})):WE(t))):x({routes:[],injector:n})}};function oI(e){e.sort((n,t)=>n.value.outlet===N?-1:t.value.outlet===N?1:n.value.outlet.localeCompare(t.value.outlet))}function iI(e){let n=e.value.routeConfig;return n&&n.path===""}function Mm(e){let n=[],t=new Set;for(let r of e){if(!iI(r)){n.push(r);continue}let o=n.find(i=>r.value.routeConfig===i.value.routeConfig);o!==void 0?(o.children.push(...r.children),t.add(o)):n.push(r)}for(let r of t){let o=Mm(r.children);n.push(new $e(r.value,o))}return n.filter(r=>!t.has(r))}function sI(e){return e.data||{}}function aI(e){return e.resolve||{}}function cI(e,n,t,r,o,i){return ue(s=>nI(e,n,t,r,s.extractedUrl,o,i).pipe(O(({state:a,tree:c})=>G(_({},s),{targetSnapshot:a,urlAfterRedirects:c}))))}function lI(e,n){return ue(t=>{let{targetSnapshot:r,guards:{canActivateChecks:o}}=t;if(!o.length)return x(t);let i=new Set(o.map(c=>c.route)),s=new Set;for(let c of i)if(!s.has(c))for(let l of Sm(c))s.add(l);let a=0;return te(s).pipe(At(c=>i.has(c)?uI(c,r,e,n):(c.data=cd(c,c.parent,e).resolve,x(void 0))),fe(()=>a++),Qn(1),ue(c=>a===s.size?x(t):Fe))})}function Sm(e){let n=e.children.map(t=>Sm(t)).flat();return[e,...n]}function uI(e,n,t,r){let o=e.routeConfig,i=e._resolve;return o?.title!==void 0&&!wm(o)&&(i[Yo]=o.title),dI(i,e,n,r).pipe(O(s=>(e._resolvedData=s,e.data=cd(e,e.parent,t).resolve,null)))}function dI(e,n,t,r){let o=ku(e);if(o.length===0)return x({});let i={};return te(o).pipe(ue(s=>fI(e[s],n,t,r).pipe(ct(),fe(a=>{i[s]=a}))),Qn(1),bc(i),Tt(s=>Em(s)?Fe:Zn(s)))}function fI(e,n,t,r){let o=Ko(n)??r,i=Or(e,o),s=i.resolve?i.resolve(n,t):Dt(o,()=>i(n,t));return Gt(s)}function Ru(e){return je(n=>{let t=e(n);return t?te(t).pipe(O(()=>n)):x(n)})}var xm=(()=>{class e{buildTitle(t){let r,o=t.root;for(;o!==void 0;)r=this.getResolvedTitleForRoute(o)??r,o=o.children.find(i=>i.outlet===N);return r}getResolvedTitleForRoute(t){return t.data[Yo]}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:()=>g(hI),providedIn:"root"})}}return e})(),hI=(()=>{class e extends xm{constructor(t){super(),this.title=t}updateTitle(t){let r=this.buildTitle(t);r!==void 0&&this.title.setTitle(r)}static{this.\u0275fac=function(r){return new(r||e)(A(Kg))}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),hd=new M("",{providedIn:"root",factory:()=>({})}),pd=new M(""),pI=(()=>{class e{constructor(){this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap,this.compiler=g(gu)}loadComponent(t){if(this.componentLoaders.get(t))return this.componentLoaders.get(t);if(t._loadedComponent)return x(t._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(t);let r=Gt(t.loadComponent()).pipe(O(Tm),fe(i=>{this.onLoadEndListener&&this.onLoadEndListener(t),t._loadedComponent=i}),en(()=>{this.componentLoaders.delete(t)})),o=new Wn(r,()=>new we).pipe(qn());return this.componentLoaders.set(t,o),o}loadChildren(t,r){if(this.childrenLoaders.get(r))return this.childrenLoaders.get(r);if(r._loadedRoutes)return x({routes:r._loadedRoutes,injector:r._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(r);let i=gI(r,this.compiler,t,this.onLoadEndListener).pipe(en(()=>{this.childrenLoaders.delete(r)})),s=new Wn(i,()=>new we).pipe(qn());return this.childrenLoaders.set(r,s),s}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function gI(e,n,t,r){return Gt(e.loadChildren()).pipe(O(Tm),ue(o=>o instanceof wo||Array.isArray(o)?x(o):te(n.compileModuleAsync(o))),O(o=>{r&&r(e);let i,s,a=!1;return Array.isArray(o)?(s=o,a=!0):(i=o.create(t).injector,s=i.get(pd,[],{optional:!0,self:!0}).flat()),{routes:s.map(dd),injector:i}}))}function mI(e){return e&&typeof e=="object"&&"default"in e}function Tm(e){return mI(e)?e.default:e}var gd=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:()=>g(vI),providedIn:"root"})}}return e})(),vI=(()=>{class e{shouldProcessUrl(t){return!0}extract(t){return t}merge(t,r){return t}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),yI=new M("");var wI=(()=>{class e{get hasRequestedNavigation(){return this.navigationId!==0}constructor(){this.currentNavigation=null,this.currentTransition=null,this.lastSuccessfulNavigation=null,this.events=new we,this.transitionAbortSubject=new we,this.configLoader=g(pI),this.environmentInjector=g(Ae),this.urlSerializer=g(ad),this.rootContexts=g(Da),this.location=g(xo),this.inputBindingEnabled=g(ud,{optional:!0})!==null,this.titleStrategy=g(xm),this.options=g(hd,{optional:!0})||{},this.paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly",this.urlHandlingStrategy=g(gd),this.createViewTransition=g(yI,{optional:!0}),this.navigationId=0,this.afterPreactivation=()=>x(void 0),this.rootComponentType=null;let t=o=>this.events.next(new zu(o)),r=o=>this.events.next(new Gu(o));this.configLoader.onLoadEndListener=r,this.configLoader.onLoadStartListener=t}complete(){this.transitions?.complete()}handleNavigationRequest(t){let r=++this.navigationId;this.transitions?.next(G(_(_({},this.transitions.value),t),{id:r}))}setupNavigations(t,r,o){return this.transitions=new ge({id:0,currentUrlTree:r,currentRawUrl:r,extractedUrl:this.urlHandlingStrategy.extract(r),urlAfterRedirects:this.urlHandlingStrategy.extract(r),rawUrl:r,extras:{},resolve:null,reject:null,promise:Promise.resolve(!0),source:Vo,restoredState:null,currentSnapshot:o.snapshot,targetSnapshot:null,currentRouterState:o,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe(Le(i=>i.id!==0),O(i=>G(_({},i),{extractedUrl:this.urlHandlingStrategy.extract(i.rawUrl)})),je(i=>{let s=!1,a=!1;return x(i).pipe(je(c=>{if(this.navigationId>i.id)return this.cancelNavigationTransition(i,"",Ue.SupersededByNewNavigation),Fe;this.currentTransition=i,this.currentNavigation={id:c.id,initialUrl:c.rawUrl,extractedUrl:c.extractedUrl,trigger:c.source,extras:c.extras,previousNavigation:this.lastSuccessfulNavigation?G(_({},this.lastSuccessfulNavigation),{previousNavigation:null}):null};let l=!t.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),u=c.extras.onSameUrlNavigation??t.onSameUrlNavigation;if(!l&&u!=="reload"){let d="";return this.events.next(new Sn(c.id,this.urlSerializer.serialize(c.rawUrl),d,Vu.IgnoredSameUrlNavigation)),c.resolve(null),Fe}if(this.urlHandlingStrategy.shouldProcessUrl(c.rawUrl))return x(c).pipe(je(d=>{let p=this.transitions?.getValue();return this.events.next(new Bo(d.id,this.urlSerializer.serialize(d.extractedUrl),d.source,d.restoredState)),p!==this.transitions?.getValue()?Fe:Promise.resolve(d)}),cI(this.environmentInjector,this.configLoader,this.rootComponentType,t.config,this.urlSerializer,this.paramsInheritanceStrategy),fe(d=>{i.targetSnapshot=d.targetSnapshot,i.urlAfterRedirects=d.urlAfterRedirects,this.currentNavigation=G(_({},this.currentNavigation),{finalUrl:d.urlAfterRedirects});let p=new ga(d.id,this.urlSerializer.serialize(d.extractedUrl),this.urlSerializer.serialize(d.urlAfterRedirects),d.targetSnapshot);this.events.next(p)}));if(l&&this.urlHandlingStrategy.shouldProcessUrl(c.currentRawUrl)){let{id:d,extractedUrl:p,source:f,restoredState:v,extras:m}=c,y=new Bo(d,this.urlSerializer.serialize(p),f,v);this.events.next(y);let C=vm(this.rootComponentType).snapshot;return this.currentTransition=i=G(_({},c),{targetSnapshot:C,urlAfterRedirects:p,extras:G(_({},m),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.finalUrl=p,x(i)}else{let d="";return this.events.next(new Sn(c.id,this.urlSerializer.serialize(c.extractedUrl),d,Vu.IgnoredByUrlHandlingStrategy)),c.resolve(null),Fe}}),fe(c=>{let l=new $u(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot);this.events.next(l)}),O(c=>(this.currentTransition=i=G(_({},c),{guards:ME(c.targetSnapshot,c.currentSnapshot,this.rootContexts)}),i)),FE(this.environmentInjector,c=>this.events.next(c)),fe(c=>{if(i.guardsResult=c.guardsResult,Tr(c.guardsResult))throw Dm(this.urlSerializer,c.guardsResult);let l=new Uu(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot,!!c.guardsResult);this.events.next(l)}),Le(c=>c.guardsResult?!0:(this.cancelNavigationTransition(c,"",Ue.GuardRejected),!1)),Ru(c=>{if(c.guards.canActivateChecks.length)return x(c).pipe(fe(l=>{let u=new Bu(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(u)}),je(l=>{let u=!1;return x(l).pipe(lI(this.paramsInheritanceStrategy,this.environmentInjector),fe({next:()=>u=!0,complete:()=>{u||this.cancelNavigationTransition(l,"",Ue.NoDataFromResolver)}}))}),fe(l=>{let u=new Hu(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(u)}))}),Ru(c=>{let l=u=>{let d=[];u.routeConfig?.loadComponent&&!u.routeConfig._loadedComponent&&d.push(this.configLoader.loadComponent(u.routeConfig).pipe(fe(p=>{u.component=p}),O(()=>{})));for(let p of u.children)d.push(...l(p));return d};return Wi(l(c.targetSnapshot.root)).pipe(Ot(null),wt(1))}),Ru(()=>this.afterPreactivation()),je(()=>{let{currentSnapshot:c,targetSnapshot:l}=i,u=this.createViewTransition?.(this.environmentInjector,c.root,l.root);return u?te(u).pipe(O(()=>i)):x(i)}),O(c=>{let l=yE(t.routeReuseStrategy,c.targetSnapshot,c.currentRouterState);return this.currentTransition=i=G(_({},c),{targetRouterState:l}),this.currentNavigation.targetRouterState=l,i}),fe(()=>{this.events.next(new zo)}),IE(this.rootContexts,t.routeReuseStrategy,c=>this.events.next(c),this.inputBindingEnabled),wt(1),fe({next:c=>{s=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new Ht(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects))),this.titleStrategy?.updateTitle(c.targetRouterState.snapshot),c.resolve(!0)},complete:()=>{s=!0}}),Mc(this.transitionAbortSubject.pipe(fe(c=>{throw c}))),en(()=>{!s&&!a&&this.cancelNavigationTransition(i,"",Ue.SupersededByNewNavigation),this.currentTransition?.id===i.id&&(this.currentNavigation=null,this.currentTransition=null)}),Tt(c=>{if(a=!0,Cm(c))this.events.next(new zt(i.id,this.urlSerializer.serialize(i.extractedUrl),c.message,c.cancellationCode)),DE(c)?this.events.next(new Go(c.url)):i.resolve(!1);else{this.events.next(new Ho(i.id,this.urlSerializer.serialize(i.extractedUrl),c,i.targetSnapshot??void 0));try{i.resolve(t.errorHandler(c))}catch(l){this.options.resolveNavigationPromiseOnError?i.resolve(!1):i.reject(l)}}return Fe}))}))}cancelNavigationTransition(t,r,o){let i=new zt(t.id,this.urlSerializer.serialize(t.extractedUrl),r,o);this.events.next(i),t.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){return this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))).toString()!==this.currentTransition?.extractedUrl.toString()&&!this.currentTransition?.extras.skipLocationChange}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function _I(e){return e!==Vo}var DI=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:()=>g(bI),providedIn:"root"})}}return e})(),sd=class{shouldDetach(n){return!1}store(n,t){}shouldAttach(n){return!1}retrieve(n){return null}shouldReuseRoute(n,t){return n.routeConfig===t.routeConfig}},bI=(()=>{class e extends sd{static{this.\u0275fac=(()=>{let t;return function(o){return(t||(t=Eo(e)))(o||e)}})()}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),Am=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:()=>g(CI),providedIn:"root"})}}return e})(),CI=(()=>{class e extends Am{constructor(){super(...arguments),this.location=g(xo),this.urlSerializer=g(ad),this.options=g(hd,{optional:!0})||{},this.canceledNavigationResolution=this.options.canceledNavigationResolution||"replace",this.urlHandlingStrategy=g(gd),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.currentUrlTree=new Bt,this.rawUrlTree=this.currentUrlTree,this.currentPageId=0,this.lastSuccessfulId=-1,this.routerState=vm(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(t){return this.location.subscribe(r=>{r.type==="popstate"&&t(r.url,r.state)})}handleRouterEvent(t,r){if(t instanceof Bo)this.stateMemento=this.createStateMemento();else if(t instanceof Sn)this.rawUrlTree=r.initialUrl;else if(t instanceof ga){if(this.urlUpdateStrategy==="eager"&&!r.extras.skipLocationChange){let o=this.urlHandlingStrategy.merge(r.finalUrl,r.initialUrl);this.setBrowserUrl(o,r)}}else t instanceof zo?(this.currentUrlTree=r.finalUrl,this.rawUrlTree=this.urlHandlingStrategy.merge(r.finalUrl,r.initialUrl),this.routerState=r.targetRouterState,this.urlUpdateStrategy==="deferred"&&(r.extras.skipLocationChange||this.setBrowserUrl(this.rawUrlTree,r))):t instanceof zt&&(t.code===Ue.GuardRejected||t.code===Ue.NoDataFromResolver)?this.restoreHistory(r):t instanceof Ho?this.restoreHistory(r,!0):t instanceof Ht&&(this.lastSuccessfulId=t.id,this.currentPageId=this.browserPageId)}setBrowserUrl(t,r){let o=this.urlSerializer.serialize(t);if(this.location.isCurrentPathEqualTo(o)||r.extras.replaceUrl){let i=this.browserPageId,s=_(_({},r.extras.state),this.generateNgRouterState(r.id,i));this.location.replaceState(o,"",s)}else{let i=_(_({},r.extras.state),this.generateNgRouterState(r.id,this.browserPageId+1));this.location.go(o,"",i)}}restoreHistory(t,r=!1){if(this.canceledNavigationResolution==="computed"){let o=this.browserPageId,i=this.currentPageId-o;i!==0?this.location.historyGo(i):this.currentUrlTree===t.finalUrl&&i===0&&(this.resetState(t),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(r&&this.resetState(t),this.resetUrlToCurrentUrlTree())}resetState(t){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,t.finalUrl??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(t,r){return this.canceledNavigationResolution==="computed"?{navigationId:t,\u0275routerPageId:r}:{navigationId:t}}static{this.\u0275fac=(()=>{let t;return function(o){return(t||(t=Eo(e)))(o||e)}})()}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),Lo=function(e){return e[e.COMPLETE=0]="COMPLETE",e[e.FAILED=1]="FAILED",e[e.REDIRECTING=2]="REDIRECTING",e}(Lo||{});function EI(e,n){e.events.pipe(Le(t=>t instanceof Ht||t instanceof zt||t instanceof Ho||t instanceof Sn),O(t=>t instanceof Ht||t instanceof Sn?Lo.COMPLETE:(t instanceof zt?t.code===Ue.Redirect||t.code===Ue.SupersededByNewNavigation:!1)?Lo.REDIRECTING:Lo.FAILED),Le(t=>t!==Lo.REDIRECTING),wt(1)).subscribe(()=>{n()})}function II(e){throw e}var MI={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},SI={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"},Me=(()=>{class e{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.isNgZoneEnabled=!1,this.console=g(Zs),this.stateManager=g(Am),this.options=g(hd,{optional:!0})||{},this.pendingTasks=g(wn),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.navigationTransitions=g(wI),this.urlSerializer=g(ad),this.location=g(xo),this.urlHandlingStrategy=g(gd),this._events=new we,this.errorHandler=this.options.errorHandler||II,this.navigated=!1,this.routeReuseStrategy=g(DI),this.onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore",this.config=g(pd,{optional:!0})?.flat()??[],this.componentInputBindingEnabled=!!g(ud,{optional:!0}),this.eventsSubscription=new le,this.isNgZoneEnabled=g(oe)instanceof oe&&oe.isInAngularZone(),this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this,this.currentUrlTree,this.routerState).subscribe({error:t=>{this.console.warn(t)}}),this.subscribeToNavigationEvents()}subscribeToNavigationEvents(){let t=this.navigationTransitions.events.subscribe(r=>{try{let o=this.navigationTransitions.currentTransition,i=this.navigationTransitions.currentNavigation;if(o!==null&&i!==null){if(this.stateManager.handleRouterEvent(r,i),r instanceof zt&&r.code!==Ue.Redirect&&r.code!==Ue.SupersededByNewNavigation)this.navigated=!0;else if(r instanceof Ht)this.navigated=!0;else if(r instanceof Go){let s=this.urlHandlingStrategy.merge(r.url,o.currentRawUrl),a={info:o.extras.info,skipLocationChange:o.extras.skipLocationChange,replaceUrl:this.urlUpdateStrategy==="eager"||_I(o.source)};this.scheduleNavigation(s,Vo,null,a,{resolve:o.resolve,reject:o.reject,promise:o.promise})}}TI(r)&&this._events.next(r)}catch(o){this.navigationTransitions.transitionAbortSubject.next(o)}});this.eventsSubscription.add(t)}resetRootComponentType(t){this.routerState.root.component=t,this.navigationTransitions.rootComponentType=t}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),Vo,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((t,r)=>{setTimeout(()=>{this.navigateToSyncWithBrowser(t,"popstate",r)},0)})}navigateToSyncWithBrowser(t,r,o){let i={replaceUrl:!0},s=o?.navigationId?o:null;if(o){let c=_({},o);delete c.navigationId,delete c.\u0275routerPageId,Object.keys(c).length!==0&&(i.state=c)}let a=this.parseUrl(t);this.scheduleNavigation(a,r,s,i)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(t){this.config=t.map(dd),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(t,r={}){let{relativeTo:o,queryParams:i,fragment:s,queryParamsHandling:a,preserveFragment:c}=r,l=c?this.currentUrlTree.fragment:s,u=null;switch(a){case"merge":u=_(_({},this.currentUrlTree.queryParams),i);break;case"preserve":u=this.currentUrlTree.queryParams;break;default:u=i||null}u!==null&&(u=this.removeEmptyProps(u));let d;try{let p=o?o.snapshot:this.routerState.snapshot.root;d=hm(p)}catch{(typeof t[0]!="string"||!t[0].startsWith("/"))&&(t=[]),d=this.currentUrlTree.root}return pm(d,t,u,l??null)}navigateByUrl(t,r={skipLocationChange:!1}){let o=Tr(t)?t:this.parseUrl(t),i=this.urlHandlingStrategy.merge(o,this.rawUrlTree);return this.scheduleNavigation(i,Vo,null,r)}navigate(t,r={skipLocationChange:!1}){return xI(t),this.navigateByUrl(this.createUrlTree(t,r),r)}serializeUrl(t){return this.urlSerializer.serialize(t)}parseUrl(t){try{return this.urlSerializer.parse(t)}catch{return this.urlSerializer.parse("/")}}isActive(t,r){let o;if(r===!0?o=_({},MI):r===!1?o=_({},SI):o=r,Tr(t))return Jg(this.currentUrlTree,t,o);let i=this.parseUrl(t);return Jg(this.currentUrlTree,i,o)}removeEmptyProps(t){return Object.entries(t).reduce((r,[o,i])=>(i!=null&&(r[o]=i),r),{})}scheduleNavigation(t,r,o,i,s){if(this.disposed)return Promise.resolve(!1);let a,c,l;s?(a=s.resolve,c=s.reject,l=s.promise):l=new Promise((d,p)=>{a=d,c=p});let u=this.pendingTasks.add();return EI(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(u))}),this.navigationTransitions.handleNavigationRequest({source:r,restoredState:o,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:t,extras:i,resolve:a,reject:c,promise:l,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),l.catch(d=>Promise.reject(d))}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function xI(e){for(let n=0;n{class e{constructor(t,r,o,i,s,a){this.router=t,this.route=r,this.tabIndexAttribute=o,this.renderer=i,this.el=s,this.locationStrategy=a,this.href=null,this.commands=null,this.onChanges=new we,this.preserveFragment=!1,this.skipLocationChange=!1,this.replaceUrl=!1;let c=s.nativeElement.tagName?.toLowerCase();this.isAnchorElement=c==="a"||c==="area",this.isAnchorElement?this.subscription=t.events.subscribe(l=>{l instanceof Ht&&this.updateHref()}):this.setTabIndexIfNotOnNativeEl("0")}setTabIndexIfNotOnNativeEl(t){this.tabIndexAttribute!=null||this.isAnchorElement||this.applyAttributeValue("tabindex",t)}ngOnChanges(t){this.isAnchorElement&&this.updateHref(),this.onChanges.next(this)}set routerLink(t){t!=null?(this.commands=Array.isArray(t)?t:[t],this.setTabIndexIfNotOnNativeEl("0")):(this.commands=null,this.setTabIndexIfNotOnNativeEl(null))}onClick(t,r,o,i,s){let a=this.urlTree;if(a===null||this.isAnchorElement&&(t!==0||r||o||i||s||typeof this.target=="string"&&this.target!="_self"))return!0;let c={skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info};return this.router.navigateByUrl(a,c),!this.isAnchorElement}ngOnDestroy(){this.subscription?.unsubscribe()}updateHref(){let t=this.urlTree;this.href=t!==null&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(t)):null;let r=this.href===null?null:Pp(this.href,this.el.nativeElement.tagName.toLowerCase(),"href");this.applyAttributeValue("href",r)}applyAttributeValue(t,r){let o=this.renderer,i=this.el.nativeElement;r!==null?o.setAttribute(i,t,r):o.removeAttribute(i,t)}get urlTree(){return this.commands===null?null:this.router.createUrlTree(this.commands,{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(r){return new(r||e)(K(Me),K(Be),Yl("tabindex"),K(vn),K(jt),K(br))}}static{this.\u0275dir=Ve({type:e,selectors:[["","routerLink",""]],hostVars:1,hostBindings:function(r,o){r&1&&ae("click",function(s){return o.onClick(s.button,s.ctrlKey,s.shiftKey,s.altKey,s.metaKey)}),r&2&&zs("target",o.target)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[ne.HasDecoratorInputTransform,"preserveFragment","preserveFragment",_r],skipLocationChange:[ne.HasDecoratorInputTransform,"skipLocationChange","skipLocationChange",_r],replaceUrl:[ne.HasDecoratorInputTransform,"replaceUrl","replaceUrl",_r],routerLink:"routerLink"},standalone:!0,features:[fu,Ft]})}}return e})();var AI=new M("");function Om(e,...n){return fr([{provide:pd,multi:!0,useValue:e},[],{provide:Be,useFactory:OI,deps:[Me]},{provide:Ys,multi:!0,useFactory:NI},n.map(t=>t.\u0275providers)])}function OI(e){return e.routerState.root}function NI(){let e=g(gn);return n=>{let t=e.get(wr);if(n!==t.components[0])return;let r=e.get(Me),o=e.get(RI);e.get(PI)===1&&r.initialNavigation(),e.get(kI,null,k.Optional)?.setUpPreloading(),e.get(AI,null,k.Optional)?.init(),r.resetRootComponentType(t.componentTypes[0]),o.closed||(o.next(),o.complete(),o.unsubscribe())}}var RI=new M("",{factory:()=>new we}),PI=new M("",{providedIn:"root",factory:()=>1});var kI=new M("");var $m=(()=>{class e{constructor(t,r){this._renderer=t,this._elementRef=r,this.onChange=o=>{},this.onTouched=()=>{}}setProperty(t,r){this._renderer.setProperty(this._elementRef.nativeElement,t,r)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty("disabled",t)}static{this.\u0275fac=function(r){return new(r||e)(K(vn),K(jt))}}static{this.\u0275dir=Ve({type:e})}}return e})(),FI=(()=>{class e extends $m{static{this.\u0275fac=(()=>{let t;return function(o){return(t||(t=Eo(e)))(o||e)}})()}static{this.\u0275dir=Ve({type:e,features:[$t]})}}return e})(),Um=new M("");var LI={provide:Um,useExisting:dr(()=>Wt),multi:!0};function jI(){let e=Et()?Et().getUserAgent():"";return/android (\d+)/.test(e.toLowerCase())}var VI=new M(""),Wt=(()=>{class e extends $m{constructor(t,r,o){super(t,r),this._compositionMode=o,this._composing=!1,this._compositionMode==null&&(this._compositionMode=!jI())}writeValue(t){let r=t??"";this.setProperty("value",r)}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}static{this.\u0275fac=function(r){return new(r||e)(K(vn),K(jt),K(VI,8))}}static{this.\u0275dir=Ve({type:e,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(r,o){r&1&&ae("input",function(s){return o._handleInput(s.target.value)})("blur",function(){return o.onTouched()})("compositionstart",function(){return o._compositionStart()})("compositionend",function(s){return o._compositionEnd(s.target.value)})},features:[Ws([LI]),$t]})}}return e})();function qt(e){return e==null||(typeof e=="string"||Array.isArray(e))&&e.length===0}function Bm(e){return e!=null&&typeof e.length=="number"}var Hm=new M(""),zm=new M(""),$I=/^(?=.{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])?)*$/,Se=class{static min(n){return UI(n)}static max(n){return BI(n)}static required(n){return HI(n)}static requiredTrue(n){return zI(n)}static email(n){return GI(n)}static minLength(n){return qI(n)}static maxLength(n){return WI(n)}static pattern(n){return ZI(n)}static nullValidator(n){return Gm(n)}static compose(n){return Km(n)}static composeAsync(n){return Xm(n)}};function UI(e){return n=>{if(qt(n.value)||qt(e))return null;let t=parseFloat(n.value);return!isNaN(t)&&t{if(qt(n.value)||qt(e))return null;let t=parseFloat(n.value);return!isNaN(t)&&t>e?{max:{max:e,actual:n.value}}:null}}function HI(e){return qt(e.value)?{required:!0}:null}function zI(e){return e.value===!0?null:{required:!0}}function GI(e){return qt(e.value)||$I.test(e.value)?null:{email:!0}}function qI(e){return n=>qt(n.value)||!Bm(n.value)?null:n.value.lengthBm(n.value)&&n.value.length>e?{maxlength:{requiredLength:e,actualLength:n.value.length}}:null}function ZI(e){if(!e)return Gm;let n,t;return typeof e=="string"?(t="",e.charAt(0)!=="^"&&(t+="^"),t+=e,e.charAt(e.length-1)!=="$"&&(t+="$"),n=new RegExp(t)):(t=e.toString(),n=e),r=>{if(qt(r.value))return null;let o=r.value;return n.test(o)?null:{pattern:{requiredPattern:t,actualValue:o}}}}function Gm(e){return null}function qm(e){return e!=null}function Wm(e){return Dn(e)?te(e):e}function Zm(e){let n={};return e.forEach(t=>{n=t!=null?_(_({},n),t):n}),Object.keys(n).length===0?null:n}function Ym(e,n){return n.map(t=>t(e))}function YI(e){return!e.validate}function Qm(e){return e.map(n=>YI(n)?n:t=>n.validate(t))}function Km(e){if(!e)return null;let n=e.filter(qm);return n.length==0?null:function(t){return Zm(Ym(t,n))}}function Jm(e){return e!=null?Km(Qm(e)):null}function Xm(e){if(!e)return null;let n=e.filter(qm);return n.length==0?null:function(t){let r=Ym(t,n).map(Wm);return Dc(r).pipe(O(Zm))}}function ev(e){return e!=null?Xm(Qm(e)):null}function Nm(e,n){return e===null?[n]:Array.isArray(e)?[...e,n]:[e,n]}function tv(e){return e._rawValidators}function nv(e){return e._rawAsyncValidators}function md(e){return e?Array.isArray(e)?e:[e]:[]}function Ia(e,n){return Array.isArray(e)?e.includes(n):e===n}function Rm(e,n){let t=md(n);return md(e).forEach(o=>{Ia(t,o)||t.push(o)}),t}function Pm(e,n){return md(n).filter(t=>!Ia(e,t))}var Ma=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(n){this._rawValidators=n||[],this._composedValidatorFn=Jm(this._rawValidators)}_setAsyncValidators(n){this._rawAsyncValidators=n||[],this._composedAsyncValidatorFn=ev(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(n){this._onDestroyCallbacks.push(n)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(n=>n()),this._onDestroyCallbacks=[]}reset(n=void 0){this.control&&this.control.reset(n)}hasError(n,t){return this.control?this.control.hasError(n,t):!1}getError(n,t){return this.control?this.control.getError(n,t):null}},Rr=class extends Ma{get formDirective(){return null}get path(){return null}},ti=class extends Ma{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}},Sa=class{constructor(n){this._cd=n}get isTouched(){return!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return!!this._cd?.submitted}},QI={"[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"},mk=G(_({},QI),{"[class.ng-submitted]":"isSubmitted"}),kr=(()=>{class e extends Sa{constructor(t){super(t)}static{this.\u0275fac=function(r){return new(r||e)(K(ti,2))}}static{this.\u0275dir=Ve({type:e,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(r,o){r&2&&vr("ng-untouched",o.isUntouched)("ng-touched",o.isTouched)("ng-pristine",o.isPristine)("ng-dirty",o.isDirty)("ng-valid",o.isValid)("ng-invalid",o.isInvalid)("ng-pending",o.isPending)},features:[$t]})}}return e})(),Fr=(()=>{class e extends Sa{constructor(t){super(t)}static{this.\u0275fac=function(r){return new(r||e)(K(Rr,10))}}static{this.\u0275dir=Ve({type:e,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(r,o){r&2&&vr("ng-untouched",o.isUntouched)("ng-touched",o.isTouched)("ng-pristine",o.isPristine)("ng-dirty",o.isDirty)("ng-valid",o.isValid)("ng-invalid",o.isInvalid)("ng-pending",o.isPending)("ng-submitted",o.isSubmitted)},features:[$t]})}}return e})();var Xo="VALID",Ca="INVALID",Nr="PENDING",ei="DISABLED";function wd(e){return(Oa(e)?e.validators:e)||null}function KI(e){return Array.isArray(e)?Jm(e):e||null}function _d(e,n){return(Oa(n)?n.asyncValidators:e)||null}function JI(e){return Array.isArray(e)?ev(e):e||null}function Oa(e){return e!=null&&!Array.isArray(e)&&typeof e=="object"}function rv(e,n,t){let r=e.controls;if(!(n?Object.keys(r):r).length)throw new I(1e3,"");if(!r[t])throw new I(1001,"")}function ov(e,n,t){e._forEachChild((r,o)=>{if(t[o]===void 0)throw new I(1002,"")})}var Pr=class{constructor(n,t){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=!1,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this.pristine=!0,this.touched=!1,this._onDisabledChange=[],this._assignValidators(n),this._assignAsyncValidators(t)}get validator(){return this._composedValidatorFn}set validator(n){this._rawValidators=this._composedValidatorFn=n}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(n){this._rawAsyncValidators=this._composedAsyncValidatorFn=n}get parent(){return this._parent}get valid(){return this.status===Xo}get invalid(){return this.status===Ca}get pending(){return this.status==Nr}get disabled(){return this.status===ei}get enabled(){return this.status!==ei}get dirty(){return!this.pristine}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(n){this._assignValidators(n)}setAsyncValidators(n){this._assignAsyncValidators(n)}addValidators(n){this.setValidators(Rm(n,this._rawValidators))}addAsyncValidators(n){this.setAsyncValidators(Rm(n,this._rawAsyncValidators))}removeValidators(n){this.setValidators(Pm(n,this._rawValidators))}removeAsyncValidators(n){this.setAsyncValidators(Pm(n,this._rawAsyncValidators))}hasValidator(n){return Ia(this._rawValidators,n)}hasAsyncValidator(n){return Ia(this._rawAsyncValidators,n)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(n={}){this.touched=!0,this._parent&&!n.onlySelf&&this._parent.markAsTouched(n)}markAllAsTouched(){this.markAsTouched({onlySelf:!0}),this._forEachChild(n=>n.markAllAsTouched())}markAsUntouched(n={}){this.touched=!1,this._pendingTouched=!1,this._forEachChild(t=>{t.markAsUntouched({onlySelf:!0})}),this._parent&&!n.onlySelf&&this._parent._updateTouched(n)}markAsDirty(n={}){this.pristine=!1,this._parent&&!n.onlySelf&&this._parent.markAsDirty(n)}markAsPristine(n={}){this.pristine=!0,this._pendingDirty=!1,this._forEachChild(t=>{t.markAsPristine({onlySelf:!0})}),this._parent&&!n.onlySelf&&this._parent._updatePristine(n)}markAsPending(n={}){this.status=Nr,n.emitEvent!==!1&&this.statusChanges.emit(this.status),this._parent&&!n.onlySelf&&this._parent.markAsPending(n)}disable(n={}){let t=this._parentMarkedDirty(n.onlySelf);this.status=ei,this.errors=null,this._forEachChild(r=>{r.disable(G(_({},n),{onlySelf:!0}))}),this._updateValue(),n.emitEvent!==!1&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(G(_({},n),{skipPristineCheck:t})),this._onDisabledChange.forEach(r=>r(!0))}enable(n={}){let t=this._parentMarkedDirty(n.onlySelf);this.status=Xo,this._forEachChild(r=>{r.enable(G(_({},n),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:n.emitEvent}),this._updateAncestors(G(_({},n),{skipPristineCheck:t})),this._onDisabledChange.forEach(r=>r(!1))}_updateAncestors(n){this._parent&&!n.onlySelf&&(this._parent.updateValueAndValidity(n),n.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}setParent(n){this._parent=n}getRawValue(){return this.value}updateValueAndValidity(n={}){this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===Xo||this.status===Nr)&&this._runAsyncValidator(n.emitEvent)),n.emitEvent!==!1&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!n.onlySelf&&this._parent.updateValueAndValidity(n)}_updateTreeValidity(n={emitEvent:!0}){this._forEachChild(t=>t._updateTreeValidity(n)),this.updateValueAndValidity({onlySelf:!0,emitEvent:n.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?ei:Xo}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(n){if(this.asyncValidator){this.status=Nr,this._hasOwnPendingAsyncValidator=!0;let t=Wm(this.asyncValidator(this));this._asyncValidationSubscription=t.subscribe(r=>{this._hasOwnPendingAsyncValidator=!1,this.setErrors(r,{emitEvent:n})})}}_cancelExistingSubscription(){this._asyncValidationSubscription&&(this._asyncValidationSubscription.unsubscribe(),this._hasOwnPendingAsyncValidator=!1)}setErrors(n,t={}){this.errors=n,this._updateControlsErrors(t.emitEvent!==!1)}get(n){let t=n;return t==null||(Array.isArray(t)||(t=t.split(".")),t.length===0)?null:t.reduce((r,o)=>r&&r._find(o),this)}getError(n,t){let r=t?this.get(t):this;return r&&r.errors?r.errors[n]:null}hasError(n,t){return!!this.getError(n,t)}get root(){let n=this;for(;n._parent;)n=n._parent;return n}_updateControlsErrors(n){this.status=this._calculateStatus(),n&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(n)}_initObservables(){this.valueChanges=new _e,this.statusChanges=new _e}_calculateStatus(){return this._allControlsDisabled()?ei:this.errors?Ca:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(Nr)?Nr:this._anyControlsHaveStatus(Ca)?Ca:Xo}_anyControlsHaveStatus(n){return this._anyControls(t=>t.status===n)}_anyControlsDirty(){return this._anyControls(n=>n.dirty)}_anyControlsTouched(){return this._anyControls(n=>n.touched)}_updatePristine(n={}){this.pristine=!this._anyControlsDirty(),this._parent&&!n.onlySelf&&this._parent._updatePristine(n)}_updateTouched(n={}){this.touched=this._anyControlsTouched(),this._parent&&!n.onlySelf&&this._parent._updateTouched(n)}_registerOnCollectionChange(n){this._onCollectionChange=n}_setUpdateStrategy(n){Oa(n)&&n.updateOn!=null&&(this._updateOn=n.updateOn)}_parentMarkedDirty(n){let t=this._parent&&this._parent.dirty;return!n&&!!t&&!this._parent._anyControlsDirty()}_find(n){return null}_assignValidators(n){this._rawValidators=Array.isArray(n)?n.slice():n,this._composedValidatorFn=KI(this._rawValidators)}_assignAsyncValidators(n){this._rawAsyncValidators=Array.isArray(n)?n.slice():n,this._composedAsyncValidatorFn=JI(this._rawAsyncValidators)}},xa=class extends Pr{constructor(n,t,r){super(wd(t),_d(r,t)),this.controls=n,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(n,t){return this.controls[n]?this.controls[n]:(this.controls[n]=t,t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange),t)}addControl(n,t,r={}){this.registerControl(n,t),this.updateValueAndValidity({emitEvent:r.emitEvent}),this._onCollectionChange()}removeControl(n,t={}){this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),delete this.controls[n],this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}setControl(n,t,r={}){this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),delete this.controls[n],t&&this.registerControl(n,t),this.updateValueAndValidity({emitEvent:r.emitEvent}),this._onCollectionChange()}contains(n){return this.controls.hasOwnProperty(n)&&this.controls[n].enabled}setValue(n,t={}){ov(this,!0,n),Object.keys(n).forEach(r=>{rv(this,!0,r),this.controls[r].setValue(n[r],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(n,t={}){n!=null&&(Object.keys(n).forEach(r=>{let o=this.controls[r];o&&o.patchValue(n[r],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(n={},t={}){this._forEachChild((r,o)=>{r.reset(n?n[o]:null,{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t),this._updateTouched(t),this.updateValueAndValidity(t)}getRawValue(){return this._reduceChildren({},(n,t,r)=>(n[r]=t.getRawValue(),n))}_syncPendingControls(){let n=this._reduceChildren(!1,(t,r)=>r._syncPendingControls()?!0:t);return n&&this.updateValueAndValidity({onlySelf:!0}),n}_forEachChild(n){Object.keys(this.controls).forEach(t=>{let r=this.controls[t];r&&n(r,t)})}_setUpControls(){this._forEachChild(n=>{n.setParent(this),n._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(n){for(let[t,r]of Object.entries(this.controls))if(this.contains(t)&&n(r))return!0;return!1}_reduceValue(){let n={};return this._reduceChildren(n,(t,r,o)=>((r.enabled||this.disabled)&&(t[o]=r.value),t))}_reduceChildren(n,t){let r=n;return this._forEachChild((o,i)=>{r=t(r,o,i)}),r}_allControlsDisabled(){for(let n of Object.keys(this.controls))if(this.controls[n].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(n){return this.controls.hasOwnProperty(n)?this.controls[n]:null}};var vd=class extends xa{};var iv=new M("CallSetDisabledState",{providedIn:"root",factory:()=>Dd}),Dd="always";function XI(e,n){return[...n.path,e]}function km(e,n,t=Dd){bd(e,n),n.valueAccessor.writeValue(e.value),(e.disabled||t==="always")&&n.valueAccessor.setDisabledState?.(e.disabled),tM(e,n),rM(e,n),nM(e,n),eM(e,n)}function Fm(e,n,t=!0){let r=()=>{};n.valueAccessor&&(n.valueAccessor.registerOnChange(r),n.valueAccessor.registerOnTouched(r)),Aa(e,n),e&&(n._invokeOnDestroyCallbacks(),e._registerOnCollectionChange(()=>{}))}function Ta(e,n){e.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(n)})}function eM(e,n){if(n.valueAccessor.setDisabledState){let t=r=>{n.valueAccessor.setDisabledState(r)};e.registerOnDisabledChange(t),n._registerOnDestroy(()=>{e._unregisterOnDisabledChange(t)})}}function bd(e,n){let t=tv(e);n.validator!==null?e.setValidators(Nm(t,n.validator)):typeof t=="function"&&e.setValidators([t]);let r=nv(e);n.asyncValidator!==null?e.setAsyncValidators(Nm(r,n.asyncValidator)):typeof r=="function"&&e.setAsyncValidators([r]);let o=()=>e.updateValueAndValidity();Ta(n._rawValidators,o),Ta(n._rawAsyncValidators,o)}function Aa(e,n){let t=!1;if(e!==null){if(n.validator!==null){let o=tv(e);if(Array.isArray(o)&&o.length>0){let i=o.filter(s=>s!==n.validator);i.length!==o.length&&(t=!0,e.setValidators(i))}}if(n.asyncValidator!==null){let o=nv(e);if(Array.isArray(o)&&o.length>0){let i=o.filter(s=>s!==n.asyncValidator);i.length!==o.length&&(t=!0,e.setAsyncValidators(i))}}}let r=()=>{};return Ta(n._rawValidators,r),Ta(n._rawAsyncValidators,r),t}function tM(e,n){n.valueAccessor.registerOnChange(t=>{e._pendingValue=t,e._pendingChange=!0,e._pendingDirty=!0,e.updateOn==="change"&&sv(e,n)})}function nM(e,n){n.valueAccessor.registerOnTouched(()=>{e._pendingTouched=!0,e.updateOn==="blur"&&e._pendingChange&&sv(e,n),e.updateOn!=="submit"&&e.markAsTouched()})}function sv(e,n){e._pendingDirty&&e.markAsDirty(),e.setValue(e._pendingValue,{emitModelToViewChange:!1}),n.viewToModelUpdate(e._pendingValue),e._pendingChange=!1}function rM(e,n){let t=(r,o)=>{n.valueAccessor.writeValue(r),o&&n.viewToModelUpdate(r)};e.registerOnChange(t),n._registerOnDestroy(()=>{e._unregisterOnChange(t)})}function oM(e,n){e==null,bd(e,n)}function iM(e,n){return Aa(e,n)}function sM(e,n){if(!e.hasOwnProperty("model"))return!1;let t=e.model;return t.isFirstChange()?!0:!Object.is(n,t.currentValue)}function aM(e){return Object.getPrototypeOf(e.constructor)===FI}function cM(e,n){e._syncPendingControls(),n.forEach(t=>{let r=t.control;r.updateOn==="submit"&&r._pendingChange&&(t.viewToModelUpdate(r._pendingValue),r._pendingChange=!1)})}function lM(e,n){if(!n)return null;Array.isArray(n);let t,r,o;return n.forEach(i=>{i.constructor===Wt?t=i:aM(i)?r=i:o=i}),o||r||t||null}function uM(e,n){let t=e.indexOf(n);t>-1&&e.splice(t,1)}function Lm(e,n){let t=e.indexOf(n);t>-1&&e.splice(t,1)}function jm(e){return typeof e=="object"&&e!==null&&Object.keys(e).length===2&&"value"in e&&"disabled"in e}var Ea=class extends Pr{constructor(n=null,t,r){super(wd(t),_d(r,t)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(n),this._setUpdateStrategy(t),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),Oa(t)&&(t.nonNullable||t.initialValueIsDefault)&&(jm(n)?this.defaultValue=n.value:this.defaultValue=n)}setValue(n,t={}){this.value=this._pendingValue=n,this._onChange.length&&t.emitModelToViewChange!==!1&&this._onChange.forEach(r=>r(this.value,t.emitViewToModelChange!==!1)),this.updateValueAndValidity(t)}patchValue(n,t={}){this.setValue(n,t)}reset(n=this.defaultValue,t={}){this._applyFormState(n),this.markAsPristine(t),this.markAsUntouched(t),this.setValue(this.value,t),this._pendingChange=!1}_updateValue(){}_anyControls(n){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(n){this._onChange.push(n)}_unregisterOnChange(n){Lm(this._onChange,n)}registerOnDisabledChange(n){this._onDisabledChange.push(n)}_unregisterOnDisabledChange(n){Lm(this._onDisabledChange,n)}_forEachChild(n){}_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(n){jm(n)?(this.value=this._pendingValue=n.value,n.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=n}};var dM=e=>e instanceof Ea;var Lr=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275dir=Ve({type:e,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""]})}}return e})();var av=new M("");var fM={provide:Rr,useExisting:dr(()=>xn)},xn=(()=>{class e extends Rr{constructor(t,r,o){super(),this.callSetDisabledState=o,this.submitted=!1,this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new _e,this._setValidators(t),this._setAsyncValidators(r)}ngOnChanges(t){this._checkFormPresent(),t.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(Aa(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(t){let r=this.form.get(t.path);return km(r,t,this.callSetDisabledState),r.updateValueAndValidity({emitEvent:!1}),this.directives.push(t),r}getControl(t){return this.form.get(t.path)}removeControl(t){Fm(t.control||null,t,!1),uM(this.directives,t)}addFormGroup(t){this._setUpFormContainer(t)}removeFormGroup(t){this._cleanUpFormContainer(t)}getFormGroup(t){return this.form.get(t.path)}addFormArray(t){this._setUpFormContainer(t)}removeFormArray(t){this._cleanUpFormContainer(t)}getFormArray(t){return this.form.get(t.path)}updateModel(t,r){this.form.get(t.path).setValue(r)}onSubmit(t){return this.submitted=!0,cM(this.form,this.directives),this.ngSubmit.emit(t),t?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(t=void 0){this.form.reset(t),this.submitted=!1}_updateDomValue(){this.directives.forEach(t=>{let r=t.control,o=this.form.get(t.path);r!==o&&(Fm(r||null,t),dM(o)&&(km(o,t,this.callSetDisabledState),t.control=o))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(t){let r=this.form.get(t.path);oM(r,t),r.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(t){if(this.form){let r=this.form.get(t.path);r&&iM(r,t)&&r.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){bd(this.form,this),this._oldForm&&Aa(this._oldForm,this)}_checkFormPresent(){this.form}static{this.\u0275fac=function(r){return new(r||e)(K(Hm,10),K(zm,10),K(iv,8))}}static{this.\u0275dir=Ve({type:e,selectors:[["","formGroup",""]],hostBindings:function(r,o){r&1&&ae("submit",function(s){return o.onSubmit(s)})("reset",function(){return o.onReset()})},inputs:{form:[ne.None,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Ws([fM]),$t,Ft]})}}return e})();var hM={provide:ti,useExisting:dr(()=>Tn)},Tn=(()=>{class e extends ti{set isDisabled(t){}static{this._ngModelWarningSentOnce=!1}constructor(t,r,o,i,s){super(),this._ngModelWarningConfig=s,this._added=!1,this.name=null,this.update=new _e,this._ngModelWarningSent=!1,this._parent=t,this._setValidators(r),this._setAsyncValidators(o),this.valueAccessor=lM(this,i)}ngOnChanges(t){this._added||this._setUpControl(),sM(t,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}get path(){return XI(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(r){return new(r||e)(K(Rr,13),K(Hm,10),K(zm,10),K(Um,10),K(av,8))}}static{this.\u0275dir=Ve({type:e,selectors:[["","formControlName",""]],inputs:{name:[ne.None,"formControlName","name"],isDisabled:[ne.None,"disabled","isDisabled"],model:[ne.None,"ngModel","model"]},outputs:{update:"ngModelChange"},features:[Ws([hM]),$t,Ft]})}}return e})();var pM=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275mod=hn({type:e})}static{this.\u0275inj=fn({})}}return e})(),yd=class extends Pr{constructor(n,t,r){super(wd(t),_d(r,t)),this.controls=n,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}at(n){return this.controls[this._adjustIndex(n)]}push(n,t={}){this.controls.push(n),this._registerControl(n),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}insert(n,t,r={}){this.controls.splice(n,0,t),this._registerControl(t),this.updateValueAndValidity({emitEvent:r.emitEvent})}removeAt(n,t={}){let r=this._adjustIndex(n);r<0&&(r=0),this.controls[r]&&this.controls[r]._registerOnCollectionChange(()=>{}),this.controls.splice(r,1),this.updateValueAndValidity({emitEvent:t.emitEvent})}setControl(n,t,r={}){let o=this._adjustIndex(n);o<0&&(o=0),this.controls[o]&&this.controls[o]._registerOnCollectionChange(()=>{}),this.controls.splice(o,1),t&&(this.controls.splice(o,0,t),this._registerControl(t)),this.updateValueAndValidity({emitEvent:r.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(n,t={}){ov(this,!1,n),n.forEach((r,o)=>{rv(this,!1,o),this.at(o).setValue(r,{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(n,t={}){n!=null&&(n.forEach((r,o)=>{this.at(o)&&this.at(o).patchValue(r,{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(n=[],t={}){this._forEachChild((r,o)=>{r.reset(n[o],{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t),this._updateTouched(t),this.updateValueAndValidity(t)}getRawValue(){return this.controls.map(n=>n.getRawValue())}clear(n={}){this.controls.length<1||(this._forEachChild(t=>t._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:n.emitEvent}))}_adjustIndex(n){return n<0?n+this.length:n}_syncPendingControls(){let n=this.controls.reduce((t,r)=>r._syncPendingControls()?!0:t,!1);return n&&this.updateValueAndValidity({onlySelf:!0}),n}_forEachChild(n){this.controls.forEach((t,r)=>{n(t,r)})}_updateValue(){this.value=this.controls.filter(n=>n.enabled||this.disabled).map(n=>n.value)}_anyControls(n){return this.controls.some(t=>t.enabled&&n(t))}_setUpControls(){this._forEachChild(n=>this._registerControl(n))}_allControlsDisabled(){for(let n of this.controls)if(n.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(n){n.setParent(this),n._registerOnCollectionChange(this._onCollectionChange)}_find(n){return this.at(n)??null}};function Vm(e){return!!e&&(e.asyncValidators!==void 0||e.validators!==void 0||e.updateOn!==void 0)}var jr=(()=>{class e{constructor(){this.useNonNullable=!1}get nonNullable(){let t=new e;return t.useNonNullable=!0,t}group(t,r=null){let o=this._reduceControls(t),i={};return Vm(r)?i=r:r!==null&&(i.validators=r.validator,i.asyncValidators=r.asyncValidator),new xa(o,i)}record(t,r=null){let o=this._reduceControls(t);return new vd(o,r)}control(t,r,o){let i={};return this.useNonNullable?(Vm(r)?i=r:(i.validators=r,i.asyncValidators=o),new Ea(t,G(_({},i),{nonNullable:!0}))):new Ea(t,r,o)}array(t,r,o){let i=t.map(s=>this._createControl(s));return new yd(i,r,o)}_reduceControls(t){let r={};return Object.keys(t).forEach(o=>{r[o]=this._createControl(t[o])}),r}_createControl(t){if(t instanceof Ea)return t;if(t instanceof Pr)return t;if(Array.isArray(t)){let r=t[0],o=t.length>1?t[1]:null,i=t.length>2?t[2]:null;return this.control(r,o,i)}else return this.control(t)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var Vr=(()=>{class e{static withConfig(t){return{ngModule:e,providers:[{provide:av,useValue:t.warnOnNgModelWithFormControl??"always"},{provide:iv,useValue:t.callSetDisabledState??Dd}]}}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275mod=hn({type:e})}static{this.\u0275inj=fn({imports:[pM]})}}return e})();var cv=e=>{let n;return e?n=e:typeof fetch>"u"?n=(...t)=>import("./chunk-6ISG364Z.js").then(({default:r})=>r(...t)):n=fetch,(...t)=>n(...t)};var ni=class extends Error{constructor(n,t="FunctionsError",r){super(n),this.name=t,this.context=r}},Na=class extends ni{constructor(n){super("Failed to send a request to the Edge Function","FunctionsFetchError",n)}},Ra=class extends ni{constructor(n){super("Relay Error invoking the Edge Function","FunctionsRelayError",n)}},Pa=class extends ni{constructor(n){super("Edge Function returned a non-2xx status code","FunctionsHttpError",n)}},Ed=function(e){return e.Any="any",e.ApNortheast1="ap-northeast-1",e.ApNortheast2="ap-northeast-2",e.ApSouth1="ap-south-1",e.ApSoutheast1="ap-southeast-1",e.ApSoutheast2="ap-southeast-2",e.CaCentral1="ca-central-1",e.EuCentral1="eu-central-1",e.EuWest1="eu-west-1",e.EuWest2="eu-west-2",e.EuWest3="eu-west-3",e.SaEast1="sa-east-1",e.UsEast1="us-east-1",e.UsWest1="us-west-1",e.UsWest2="us-west-2",e}(Ed||{});var gM=function(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},ri=class{constructor(n,{headers:t={},customFetch:r,region:o=Ed.Any}={}){this.url=n,this.headers=t,this.region=o,this.fetch=cv(r)}setAuth(n){this.headers.Authorization=`Bearer ${n}`}invoke(n,t={}){var r;return gM(this,void 0,void 0,function*(){try{let{headers:o,method:i,body:s}=t,a={},{region:c}=t;c||(c=this.region),c&&c!=="any"&&(a["x-region"]=c);let l;s&&(o&&!Object.prototype.hasOwnProperty.call(o,"Content-Type")||!o)&&(typeof Blob<"u"&&s instanceof Blob||s instanceof ArrayBuffer?(a["Content-Type"]="application/octet-stream",l=s):typeof s=="string"?(a["Content-Type"]="text/plain",l=s):typeof FormData<"u"&&s instanceof FormData?l=s:(a["Content-Type"]="application/json",l=JSON.stringify(s)));let u=yield this.fetch(`${this.url}/${n}`,{method:i||"POST",headers:Object.assign(Object.assign(Object.assign({},a),this.headers),o),body:l}).catch(v=>{throw new Na(v)}),d=u.headers.get("x-relay-error");if(d&&d==="true")throw new Ra(u);if(!u.ok)throw new Pa(u);let p=((r=u.headers.get("Content-Type"))!==null&&r!==void 0?r:"text/plain").split(";")[0].trim(),f;return p==="application/json"?f=yield u.json():p==="application/octet-stream"?f=yield u.blob():p==="text/event-stream"?f=u:p==="multipart/form-data"?f=yield u.formData():f=yield u.text(),{data:f,error:null}}catch(o){return{data:null,error:o}}})}};var Dv=Ey(_v(),1),{PostgrestClient:bv,PostgrestQueryBuilder:Fk,PostgrestFilterBuilder:Lk,PostgrestTransformBuilder:jk,PostgrestBuilder:Vk}=Dv.default;var Cv="2.10.7";var Ev={"X-Client-Info":`realtime-js/${Cv}`},Iv="1.0.0",ja=1e4,Mv=1e3,Ur=function(e){return e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed",e}(Ur||{}),He=function(e){return e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving",e}(He||{}),Qe=function(e){return e.close="phx_close",e.error="phx_error",e.join="phx_join",e.reply="phx_reply",e.leave="phx_leave",e.access_token="access_token",e}(Qe||{}),Fd=function(e){return e.websocket="websocket",e}(Fd||{}),An=function(e){return e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed",e}(An||{});var Va=class{constructor(){this.HEADER_LENGTH=1}decode(n,t){return n.constructor===ArrayBuffer?t(this._binaryDecode(n)):t(typeof n=="string"?JSON.parse(n):{})}_binaryDecode(n){let t=new DataView(n),r=new TextDecoder;return this._decodeBroadcast(n,t,r)}_decodeBroadcast(n,t,r){let o=t.getUint8(1),i=t.getUint8(2),s=this.HEADER_LENGTH+2,a=r.decode(n.slice(s,s+o));s=s+o;let c=r.decode(n.slice(s,s+i));s=s+i;let l=JSON.parse(r.decode(n.slice(s,n.byteLength)));return{ref:null,topic:a,event:c,payload:l}}};var Br=class{constructor(n,t){this.callback=n,this.timerCalc=t,this.timer=void 0,this.tries=0,this.callback=n,this.timerCalc=t}reset(){this.tries=0,clearTimeout(this.timer)}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}};var X=function(e){return e.abstime="abstime",e.bool="bool",e.date="date",e.daterange="daterange",e.float4="float4",e.float8="float8",e.int2="int2",e.int4="int4",e.int4range="int4range",e.int8="int8",e.int8range="int8range",e.json="json",e.jsonb="jsonb",e.money="money",e.numeric="numeric",e.oid="oid",e.reltime="reltime",e.text="text",e.time="time",e.timestamp="timestamp",e.timestamptz="timestamptz",e.timetz="timetz",e.tsrange="tsrange",e.tstzrange="tstzrange",e}(X||{}),jd=(e,n,t={})=>{var r;let o=(r=t.skipTypes)!==null&&r!==void 0?r:[];return Object.keys(n).reduce((i,s)=>(i[s]=SM(s,e,n,o),i),{})},SM=(e,n,t,r)=>{let o=n.find(a=>a.name===e),i=o?.type,s=t[e];return i&&!r.includes(i)?Sv(i,s):Ld(s)},Sv=(e,n)=>{if(e.charAt(0)==="_"){let t=e.slice(1,e.length);return OM(n,t)}switch(e){case X.bool:return xM(n);case X.float4:case X.float8:case X.int2:case X.int4:case X.int8:case X.numeric:case X.oid:return TM(n);case X.json:case X.jsonb:return AM(n);case X.timestamp:return NM(n);case X.abstime:case X.date:case X.daterange:case X.int4range:case X.int8range:case X.money:case X.reltime:case X.text:case X.time:case X.timestamptz:case X.timetz:case X.tsrange:case X.tstzrange:return Ld(n);default:return Ld(n)}},Ld=e=>e,xM=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},TM=e=>{if(typeof e=="string"){let n=parseFloat(e);if(!Number.isNaN(n))return n}return e},AM=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch(n){return console.log(`JSON parse error: ${n}`),e}return e},OM=(e,n)=>{if(typeof e!="string")return e;let t=e.length-1,r=e[t];if(e[0]==="{"&&r==="}"){let i,s=e.slice(1,t);try{i=JSON.parse("["+s+"]")}catch{i=s?s.split(","):[]}return i.map(a=>Sv(n,a))}return e},NM=e=>typeof e=="string"?e.replace(" ","T"):e,$a=e=>{let n=e;return n=n.replace(/^ws/i,"http"),n=n.replace(/(\/socket\/websocket|\/socket|\/websocket)\/?$/i,""),n.replace(/\/+$/,"")};var Hr=class{constructor(n,t,r={},o=ja){this.channel=n,this.event=t,this.payload=r,this.timeout=o,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHooks=[],this.refEvent=null}resend(n){this.timeout=n,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,join_ref:this.channel._joinRef()}))}updatePayload(n){this.payload=Object.assign(Object.assign({},this.payload),n)}receive(n,t){var r;return this._hasReceived(n)&&t((r=this.receivedResp)===null||r===void 0?void 0:r.response),this.recHooks.push({status:n,callback:t}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);let n=t=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=t,this._matchReceive(t)};this.channel._on(this.refEvent,{},n),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(n,t){this.refEvent&&this.channel._trigger(this.refEvent,{status:n,response:t})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:n,response:t}){this.recHooks.filter(r=>r.status===n).forEach(r=>r.callback(t))}_hasReceived(n){return this.receivedResp&&this.receivedResp.status===n}};var ui=class e{constructor(n,t){this.channel=n,this.state={},this.pendingDiffs=[],this.joinRef=null,this.caller={onJoin:()=>{},onLeave:()=>{},onSync:()=>{}};let r=t?.events||{state:"presence_state",diff:"presence_diff"};this.channel._on(r.state,{},o=>{let{onJoin:i,onLeave:s,onSync:a}=this.caller;this.joinRef=this.channel._joinRef(),this.state=e.syncState(this.state,o,i,s),this.pendingDiffs.forEach(c=>{this.state=e.syncDiff(this.state,c,i,s)}),this.pendingDiffs=[],a()}),this.channel._on(r.diff,{},o=>{let{onJoin:i,onLeave:s,onSync:a}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(o):(this.state=e.syncDiff(this.state,o,i,s),a())}),this.onJoin((o,i,s)=>{this.channel._trigger("presence",{event:"join",key:o,currentPresences:i,newPresences:s})}),this.onLeave((o,i,s)=>{this.channel._trigger("presence",{event:"leave",key:o,currentPresences:i,leftPresences:s})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(n,t,r,o){let i=this.cloneDeep(n),s=this.transformState(t),a={},c={};return this.map(i,(l,u)=>{s[l]||(c[l]=u)}),this.map(s,(l,u)=>{let d=i[l];if(d){let p=u.map(y=>y.presence_ref),f=d.map(y=>y.presence_ref),v=u.filter(y=>f.indexOf(y.presence_ref)<0),m=d.filter(y=>p.indexOf(y.presence_ref)<0);v.length>0&&(a[l]=v),m.length>0&&(c[l]=m)}else a[l]=u}),this.syncDiff(i,{joins:a,leaves:c},r,o)}static syncDiff(n,t,r,o){let{joins:i,leaves:s}={joins:this.transformState(t.joins),leaves:this.transformState(t.leaves)};return r||(r=()=>{}),o||(o=()=>{}),this.map(i,(a,c)=>{var l;let u=(l=n[a])!==null&&l!==void 0?l:[];if(n[a]=this.cloneDeep(c),u.length>0){let d=n[a].map(f=>f.presence_ref),p=u.filter(f=>d.indexOf(f.presence_ref)<0);n[a].unshift(...p)}r(a,u,c)}),this.map(s,(a,c)=>{let l=n[a];if(!l)return;let u=c.map(d=>d.presence_ref);l=l.filter(d=>u.indexOf(d.presence_ref)<0),n[a]=l,o(a,l,c),l.length===0&&delete n[a]}),n}static map(n,t){return Object.getOwnPropertyNames(n).map(r=>t(r,n[r]))}static transformState(n){return n=this.cloneDeep(n),Object.getOwnPropertyNames(n).reduce((t,r)=>{let o=n[r];return"metas"in o?t[r]=o.metas.map(i=>(i.presence_ref=i.phx_ref,delete i.phx_ref,delete i.phx_ref_prev,i)):t[r]=o,t},{})}static cloneDeep(n){return JSON.parse(JSON.stringify(n))}onJoin(n){this.caller.onJoin=n}onLeave(n){this.caller.onLeave=n}onSync(n){this.caller.onSync=n}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}};var di=class e{constructor(n,t={config:{}},r){this.topic=n,this.params=t,this.socket=r,this.bindings={},this.state=He.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=n.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:""},private:!1},t.config),this.timeout=this.socket.timeout,this.joinPush=new Hr(this,Qe.join,this.params,this.timeout),this.rejoinTimer=new Br(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=He.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(o=>o.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=He.closed,this.socket._remove(this)}),this._onError(o=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,o),this.state=He.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=He.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Qe.reply,{},(o,i)=>{this._trigger(this._replyEventName(i),o)}),this.presence=new ui(this),this.broadcastEndpointURL=$a(this.socket.endPoint)+"/api/broadcast",this.private=this.params.config.private||!1}subscribe(n,t=this.timeout){var r,o;if(this.socket.isConnected()||this.socket.connect(),this.joinedOnce)throw"tried to subscribe multiple times. 'subscribe' can only be called a single time per channel instance";{let{config:{broadcast:i,presence:s,private:a}}=this.params;this._onError(u=>n&&n("CHANNEL_ERROR",u)),this._onClose(()=>n&&n("CLOSED"));let c={},l={broadcast:i,presence:s,postgres_changes:(o=(r=this.bindings.postgres_changes)===null||r===void 0?void 0:r.map(u=>u.filter))!==null&&o!==void 0?o:[],private:a};this.socket.accessToken&&(c.access_token=this.socket.accessToken),this.updateJoinPayload(Object.assign({config:l},c)),this.joinedOnce=!0,this._rejoin(t),this.joinPush.receive("ok",({postgres_changes:u})=>{var d;if(this.socket.accessToken&&this.socket.setAuth(this.socket.accessToken),u===void 0){n&&n("SUBSCRIBED");return}else{let p=this.bindings.postgres_changes,f=(d=p?.length)!==null&&d!==void 0?d:0,v=[];for(let m=0;m{n&&n("CHANNEL_ERROR",new Error(JSON.stringify(Object.values(u).join(", ")||"error")))}).receive("timeout",()=>{n&&n("TIMED_OUT")})}return this}presenceState(){return this.presence.state}track(r){return h(this,arguments,function*(n,t={}){return yield this.send({type:"presence",event:"track",payload:n},t.timeout||this.timeout)})}untrack(){return h(this,arguments,function*(n={}){return yield this.send({type:"presence",event:"untrack"},n)})}on(n,t,r){return this._on(n,t,r)}send(r){return h(this,arguments,function*(n,t={}){var o,i;if(!this._canPush()&&n.type==="broadcast"){let{event:s,payload:a}=n,c={method:"POST",headers:{Authorization:this.socket.accessToken?`Bearer ${this.socket.accessToken}`:"",apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"},body:JSON.stringify({messages:[{topic:this.subTopic,event:s,payload:a,private:this.private}]})};try{let l=yield this._fetchWithTimeout(this.broadcastEndpointURL,c,(o=t.timeout)!==null&&o!==void 0?o:this.timeout);return yield(i=l.body)===null||i===void 0?void 0:i.cancel(),l.ok?"ok":"error"}catch(l){return l.name==="AbortError"?"timed out":"error"}}else return new Promise(s=>{var a,c,l;let u=this._push(n.type,n,t.timeout||this.timeout);n.type==="broadcast"&&!(!((l=(c=(a=this.params)===null||a===void 0?void 0:a.config)===null||c===void 0?void 0:c.broadcast)===null||l===void 0)&&l.ack)&&s("ok"),u.receive("ok",()=>s("ok")),u.receive("error",()=>s("error")),u.receive("timeout",()=>s("timed out"))})})}updateJoinPayload(n){this.joinPush.updatePayload(n)}unsubscribe(n=this.timeout){this.state=He.leaving;let t=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Qe.close,"leave",this._joinRef())};return this.rejoinTimer.reset(),this.joinPush.destroy(),new Promise(r=>{let o=new Hr(this,Qe.leave,{},n);o.receive("ok",()=>{t(),r("ok")}).receive("timeout",()=>{t(),r("timed out")}).receive("error",()=>{r("error")}),o.send(),this._canPush()||o.trigger("ok",{})})}_fetchWithTimeout(n,t,r){return h(this,null,function*(){let o=new AbortController,i=setTimeout(()=>o.abort(),r),s=yield this.socket.fetch(n,Object.assign(Object.assign({},t),{signal:o.signal}));return clearTimeout(i),s})}_push(n,t,r=this.timeout){if(!this.joinedOnce)throw`tried to push '${n}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let o=new Hr(this,n,t,r);return this._canPush()?o.send():(o.startTimeout(),this.pushBuffer.push(o)),o}_onMessage(n,t,r){return t}_isMember(n){return this.topic===n}_joinRef(){return this.joinPush.ref}_trigger(n,t,r){var o,i;let s=n.toLocaleLowerCase(),{close:a,error:c,leave:l,join:u}=Qe;if(r&&[a,c,l,u].indexOf(s)>=0&&r!==this._joinRef())return;let p=this._onMessage(s,t,r);if(t&&!p)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(s)?(o=this.bindings.postgres_changes)===null||o===void 0||o.filter(f=>{var v,m,y;return((v=f.filter)===null||v===void 0?void 0:v.event)==="*"||((y=(m=f.filter)===null||m===void 0?void 0:m.event)===null||y===void 0?void 0:y.toLocaleLowerCase())===s}).map(f=>f.callback(p,r)):(i=this.bindings[s])===null||i===void 0||i.filter(f=>{var v,m,y,C,ie,R;if(["broadcast","presence","postgres_changes"].includes(s))if("id"in f){let J=f.id,ee=(v=f.filter)===null||v===void 0?void 0:v.event;return J&&((m=t.ids)===null||m===void 0?void 0:m.includes(J))&&(ee==="*"||ee?.toLocaleLowerCase()===((y=t.data)===null||y===void 0?void 0:y.type.toLocaleLowerCase()))}else{let J=(ie=(C=f?.filter)===null||C===void 0?void 0:C.event)===null||ie===void 0?void 0:ie.toLocaleLowerCase();return J==="*"||J===((R=t?.event)===null||R===void 0?void 0:R.toLocaleLowerCase())}else return f.type.toLocaleLowerCase()===s}).map(f=>{if(typeof p=="object"&&"ids"in p){let v=p.data,{schema:m,table:y,commit_timestamp:C,type:ie,errors:R}=v;p=Object.assign(Object.assign({},{schema:m,table:y,commit_timestamp:C,eventType:ie,new:{},old:{},errors:R}),this._getPayloadRecords(v))}f.callback(p,r)})}_isClosed(){return this.state===He.closed}_isJoined(){return this.state===He.joined}_isJoining(){return this.state===He.joining}_isLeaving(){return this.state===He.leaving}_replyEventName(n){return`chan_reply_${n}`}_on(n,t,r){let o=n.toLocaleLowerCase(),i={type:o,filter:t,callback:r};return this.bindings[o]?this.bindings[o].push(i):this.bindings[o]=[i],this}_off(n,t){let r=n.toLocaleLowerCase();return this.bindings[r]=this.bindings[r].filter(o=>{var i;return!(((i=o.type)===null||i===void 0?void 0:i.toLocaleLowerCase())===r&&e.isEqual(o.filter,t))}),this}static isEqual(n,t){if(Object.keys(n).length!==Object.keys(t).length)return!1;for(let r in n)if(n[r]!==t[r])return!1;return!0}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(n){this._on(Qe.close,{},n)}_onError(n){this._on(Qe.error,{},t=>n(t))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(n=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=He.joining,this.joinPush.resend(n))}_getPayloadRecords(n){let t={new:{},old:{}};return(n.type==="INSERT"||n.type==="UPDATE")&&(t.new=jd(n.columns,n.record)),(n.type==="UPDATE"||n.type==="DELETE")&&(t.old=jd(n.columns,n.old_record)),t}};var PM=()=>{},kM=typeof WebSocket<"u",FM=` + addEventListener("message", (e) => { + if (e.data.event === "start") { + setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval); + } + });`,fi=class{constructor(n,t){var r;this.accessToken=null,this.apiKey=null,this.channels=[],this.endPoint="",this.httpEndpoint="",this.headers=Ev,this.params={},this.timeout=ja,this.heartbeatIntervalMs=3e4,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.ref=0,this.logger=PM,this.conn=null,this.sendBuffer=[],this.serializer=new Va,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this._resolveFetch=i=>{let s;return i?s=i:typeof fetch>"u"?s=(...a)=>import("./chunk-6ISG364Z.js").then(({default:c})=>c(...a)):s=fetch,(...a)=>s(...a)},this.endPoint=`${n}/${Fd.websocket}`,this.httpEndpoint=$a(n),t?.transport?this.transport=t.transport:this.transport=null,t?.params&&(this.params=t.params),t?.headers&&(this.headers=Object.assign(Object.assign({},this.headers),t.headers)),t?.timeout&&(this.timeout=t.timeout),t?.logger&&(this.logger=t.logger),t?.heartbeatIntervalMs&&(this.heartbeatIntervalMs=t.heartbeatIntervalMs);let o=(r=t?.params)===null||r===void 0?void 0:r.apikey;if(o&&(this.accessToken=o,this.apiKey=o),this.reconnectAfterMs=t?.reconnectAfterMs?t.reconnectAfterMs:i=>[1e3,2e3,5e3,1e4][i-1]||1e4,this.encode=t?.encode?t.encode:(i,s)=>s(JSON.stringify(i)),this.decode=t?.decode?t.decode:this.serializer.decode.bind(this.serializer),this.reconnectTimer=new Br(()=>h(this,null,function*(){this.disconnect(),this.connect()}),this.reconnectAfterMs),this.fetch=this._resolveFetch(t?.fetch),t?.worker){if(typeof window<"u"&&!window.Worker)throw new Error("Web Worker is not supported");this.worker=t?.worker||!1,this.workerUrl=t?.workerUrl}}connect(){if(!this.conn){if(this.transport){this.conn=new this.transport(this._endPointURL(),void 0,{headers:this.headers});return}if(kM){this.conn=new WebSocket(this._endPointURL()),this.setupConnection();return}this.conn=new Vd(this._endPointURL(),void 0,{close:()=>{this.conn=null}}),import("./chunk-FJRMAC5Z.js").then(({default:n})=>{this.conn=new n(this._endPointURL(),void 0,{headers:this.headers}),this.setupConnection()})}}disconnect(n,t){this.conn&&(this.conn.onclose=function(){},n?this.conn.close(n,t??""):this.conn.close(),this.conn=null,this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.reconnectTimer.reset())}getChannels(){return this.channels}removeChannel(n){return h(this,null,function*(){let t=yield n.unsubscribe();return this.channels.length===0&&this.disconnect(),t})}removeAllChannels(){return h(this,null,function*(){let n=yield Promise.all(this.channels.map(t=>t.unsubscribe()));return this.disconnect(),n})}log(n,t,r){this.logger(n,t,r)}connectionState(){switch(this.conn&&this.conn.readyState){case Ur.connecting:return An.Connecting;case Ur.open:return An.Open;case Ur.closing:return An.Closing;default:return An.Closed}}isConnected(){return this.connectionState()===An.Open}channel(n,t={config:{}}){let r=new di(`realtime:${n}`,t,this);return this.channels.push(r),r}push(n){let{topic:t,event:r,payload:o,ref:i}=n,s=()=>{this.encode(n,a=>{var c;(c=this.conn)===null||c===void 0||c.send(a)})};this.log("push",`${t} ${r} (${i})`,o),this.isConnected()?s():this.sendBuffer.push(s)}setAuth(n){this.accessToken=n,this.channels.forEach(t=>{n&&t.updateJoinPayload({access_token:n}),t.joinedOnce&&t._isJoined()&&t._push(Qe.access_token,{access_token:n})})}_makeRef(){let n=this.ref+1;return n===this.ref?this.ref=0:this.ref=n,this.ref.toString()}_leaveOpenTopic(n){let t=this.channels.find(r=>r.topic===n&&(r._isJoined()||r._isJoining()));t&&(this.log("transport",`leaving duplicate topic "${n}"`),t.unsubscribe())}_remove(n){this.channels=this.channels.filter(t=>t._joinRef()!==n._joinRef())}setupConnection(){this.conn&&(this.conn.binaryType="arraybuffer",this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=n=>this._onConnError(n),this.conn.onmessage=n=>this._onConnMessage(n),this.conn.onclose=n=>this._onConnClose(n))}_endPointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:Iv}))}_onConnMessage(n){this.decode(n.data,t=>{let{topic:r,event:o,payload:i,ref:s}=t;(s&&s===this.pendingHeartbeatRef||o===i?.type)&&(this.pendingHeartbeatRef=null),this.log("receive",`${i.status||""} ${r} ${o} ${s&&"("+s+")"||""}`,i),this.channels.filter(a=>a._isMember(r)).forEach(a=>a._trigger(o,i,s)),this.stateChangeCallbacks.message.forEach(a=>a(t))})}_onConnOpen(){return h(this,null,function*(){if(this.log("transport",`connected to ${this._endPointURL()}`),this._flushSendBuffer(),this.reconnectTimer.reset(),!this.worker)this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this._sendHeartbeat(),this.heartbeatIntervalMs);else{this.workerUrl?this.log("worker",`starting worker for from ${this.workerUrl}`):this.log("worker","starting default worker");let n=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(n),this.workerRef.onerror=t=>{this.log("worker","worker error",t.message),this.workerRef.terminate()},this.workerRef.onmessage=t=>{t.data.event==="keepAlive"&&this._sendHeartbeat()},this.workerRef.postMessage({event:"start",interval:this.heartbeatIntervalMs})}this.stateChangeCallbacks.open.forEach(n=>n())})}_onConnClose(n){this.log("transport","close",n),this._triggerChanError(),this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.reconnectTimer.scheduleTimeout(),this.stateChangeCallbacks.close.forEach(t=>t(n))}_onConnError(n){this.log("transport",n.message),this._triggerChanError(),this.stateChangeCallbacks.error.forEach(t=>t(n))}_triggerChanError(){this.channels.forEach(n=>n._trigger(Qe.error))}_appendParams(n,t){if(Object.keys(t).length===0)return n;let r=n.match(/\?/)?"&":"?",o=new URLSearchParams(t);return`${n}${r}${o}`}_flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(n=>n()),this.sendBuffer=[])}_sendHeartbeat(){var n;if(this.isConnected()){if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection"),(n=this.conn)===null||n===void 0||n.close(Mv,"hearbeat timeout");return}this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef}),this.setAuth(this.accessToken)}}_workerObjectUrl(n){let t;if(n)t=n;else{let r=new Blob([FM],{type:"application/javascript"});t=URL.createObjectURL(r)}return t}};var Vd=class{constructor(n,t,r){this.binaryType="arraybuffer",this.onclose=()=>{},this.onerror=()=>{},this.onmessage=()=>{},this.onopen=()=>{},this.readyState=Ur.connecting,this.send=()=>{},this.url=null,this.url=n,this.close=r.close}};var zr=class extends Error{constructor(n){super(n),this.__isStorageError=!0,this.name="StorageError"}};function ce(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}var Ua=class extends zr{constructor(n,t){super(n),this.name="StorageApiError",this.status=t}toJSON(){return{name:this.name,message:this.message,status:this.status}}},On=class extends zr{constructor(n,t){super(n),this.name="StorageUnknownError",this.originalError=t}};var LM=function(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},Ha=e=>{let n;return e?n=e:typeof fetch>"u"?n=(...t)=>import("./chunk-6ISG364Z.js").then(({default:r})=>r(...t)):n=fetch,(...t)=>n(...t)},xv=()=>LM(void 0,void 0,void 0,function*(){return typeof Response>"u"?(yield import("./chunk-6ISG364Z.js")).Response:Response}),Ba=e=>{if(Array.isArray(e))return e.map(t=>Ba(t));if(typeof e=="function"||e!==Object(e))return e;let n={};return Object.entries(e).forEach(([t,r])=>{let o=t.replace(/([-_][a-z])/gi,i=>i.toUpperCase().replace(/[-_]/g,""));n[o]=Ba(r)}),n};var Nn=function(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},$d=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),jM=(e,n,t)=>Nn(void 0,void 0,void 0,function*(){let r=yield xv();e instanceof r&&!t?.noResolveJson?e.json().then(o=>{n(new Ua($d(o),e.status||500))}).catch(o=>{n(new On($d(o),o))}):n(new On($d(e),e))}),VM=(e,n,t,r)=>{let o={method:e,headers:n?.headers||{}};return e==="GET"?o:(o.headers=Object.assign({"Content-Type":"application/json"},n?.headers),r&&(o.body=JSON.stringify(r)),Object.assign(Object.assign({},o),t))};function hi(e,n,t,r,o,i){return Nn(this,void 0,void 0,function*(){return new Promise((s,a)=>{e(t,VM(n,r,o,i)).then(c=>{if(!c.ok)throw c;return r?.noResolveJson?c:c.json()}).then(c=>s(c)).catch(c=>jM(c,a,r))})})}function Gr(e,n,t,r){return Nn(this,void 0,void 0,function*(){return hi(e,"GET",n,t,r)})}function gt(e,n,t,r,o){return Nn(this,void 0,void 0,function*(){return hi(e,"POST",n,r,o,t)})}function Tv(e,n,t,r,o){return Nn(this,void 0,void 0,function*(){return hi(e,"PUT",n,r,o,t)})}function Av(e,n,t,r){return Nn(this,void 0,void 0,function*(){return hi(e,"HEAD",n,Object.assign(Object.assign({},t),{noResolveJson:!0}),r)})}function za(e,n,t,r,o){return Nn(this,void 0,void 0,function*(){return hi(e,"DELETE",n,r,o,t)})}var Re=function(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},$M={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},Ov={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1},Ga=class{constructor(n,t={},r,o){this.url=n,this.headers=t,this.bucketId=r,this.fetch=Ha(o)}uploadOrUpdate(n,t,r,o){return Re(this,void 0,void 0,function*(){try{let i,s=Object.assign(Object.assign({},Ov),o),a=Object.assign(Object.assign({},this.headers),n==="POST"&&{"x-upsert":String(s.upsert)}),c=s.metadata;typeof Blob<"u"&&r instanceof Blob?(i=new FormData,i.append("cacheControl",s.cacheControl),c&&i.append("metadata",this.encodeMetadata(c)),i.append("",r)):typeof FormData<"u"&&r instanceof FormData?(i=r,i.append("cacheControl",s.cacheControl),c&&i.append("metadata",this.encodeMetadata(c))):(i=r,a["cache-control"]=`max-age=${s.cacheControl}`,a["content-type"]=s.contentType,c&&(a["x-metadata"]=this.toBase64(this.encodeMetadata(c)))),o?.headers&&(a=Object.assign(Object.assign({},a),o.headers));let l=this._removeEmptyFolders(t),u=this._getFinalPath(l),d=yield this.fetch(`${this.url}/object/${u}`,Object.assign({method:n,body:i,headers:a},s?.duplex?{duplex:s.duplex}:{})),p=yield d.json();return d.ok?{data:{path:l,id:p.Id,fullPath:p.Key},error:null}:{data:null,error:p}}catch(i){if(ce(i))return{data:null,error:i};throw i}})}upload(n,t,r){return Re(this,void 0,void 0,function*(){return this.uploadOrUpdate("POST",n,t,r)})}uploadToSignedUrl(n,t,r,o){return Re(this,void 0,void 0,function*(){let i=this._removeEmptyFolders(n),s=this._getFinalPath(i),a=new URL(this.url+`/object/upload/sign/${s}`);a.searchParams.set("token",t);try{let c,l=Object.assign({upsert:Ov.upsert},o),u=Object.assign(Object.assign({},this.headers),{"x-upsert":String(l.upsert)});typeof Blob<"u"&&r instanceof Blob?(c=new FormData,c.append("cacheControl",l.cacheControl),c.append("",r)):typeof FormData<"u"&&r instanceof FormData?(c=r,c.append("cacheControl",l.cacheControl)):(c=r,u["cache-control"]=`max-age=${l.cacheControl}`,u["content-type"]=l.contentType);let d=yield this.fetch(a.toString(),{method:"PUT",body:c,headers:u}),p=yield d.json();return d.ok?{data:{path:i,fullPath:p.Key},error:null}:{data:null,error:p}}catch(c){if(ce(c))return{data:null,error:c};throw c}})}createSignedUploadUrl(n,t){return Re(this,void 0,void 0,function*(){try{let r=this._getFinalPath(n),o=Object.assign({},this.headers);t?.upsert&&(o["x-upsert"]="true");let i=yield gt(this.fetch,`${this.url}/object/upload/sign/${r}`,{},{headers:o}),s=new URL(this.url+i.url),a=s.searchParams.get("token");if(!a)throw new zr("No token returned by API");return{data:{signedUrl:s.toString(),path:n,token:a},error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}})}update(n,t,r){return Re(this,void 0,void 0,function*(){return this.uploadOrUpdate("PUT",n,t,r)})}move(n,t,r){return Re(this,void 0,void 0,function*(){try{return{data:yield gt(this.fetch,`${this.url}/object/move`,{bucketId:this.bucketId,sourceKey:n,destinationKey:t,destinationBucket:r?.destinationBucket},{headers:this.headers}),error:null}}catch(o){if(ce(o))return{data:null,error:o};throw o}})}copy(n,t,r){return Re(this,void 0,void 0,function*(){try{return{data:{path:(yield gt(this.fetch,`${this.url}/object/copy`,{bucketId:this.bucketId,sourceKey:n,destinationKey:t,destinationBucket:r?.destinationBucket},{headers:this.headers})).Key},error:null}}catch(o){if(ce(o))return{data:null,error:o};throw o}})}createSignedUrl(n,t,r){return Re(this,void 0,void 0,function*(){try{let o=this._getFinalPath(n),i=yield gt(this.fetch,`${this.url}/object/sign/${o}`,Object.assign({expiresIn:t},r?.transform?{transform:r.transform}:{}),{headers:this.headers}),s=r?.download?`&download=${r.download===!0?"":r.download}`:"";return i={signedUrl:encodeURI(`${this.url}${i.signedURL}${s}`)},{data:i,error:null}}catch(o){if(ce(o))return{data:null,error:o};throw o}})}createSignedUrls(n,t,r){return Re(this,void 0,void 0,function*(){try{let o=yield gt(this.fetch,`${this.url}/object/sign/${this.bucketId}`,{expiresIn:t,paths:n},{headers:this.headers}),i=r?.download?`&download=${r.download===!0?"":r.download}`:"";return{data:o.map(s=>Object.assign(Object.assign({},s),{signedUrl:s.signedURL?encodeURI(`${this.url}${s.signedURL}${i}`):null})),error:null}}catch(o){if(ce(o))return{data:null,error:o};throw o}})}download(n,t){return Re(this,void 0,void 0,function*(){let o=typeof t?.transform<"u"?"render/image/authenticated":"object",i=this.transformOptsToQueryString(t?.transform||{}),s=i?`?${i}`:"";try{let a=this._getFinalPath(n);return{data:yield(yield Gr(this.fetch,`${this.url}/${o}/${a}${s}`,{headers:this.headers,noResolveJson:!0})).blob(),error:null}}catch(a){if(ce(a))return{data:null,error:a};throw a}})}info(n){return Re(this,void 0,void 0,function*(){let t=this._getFinalPath(n);try{let r=yield Gr(this.fetch,`${this.url}/object/info/${t}`,{headers:this.headers});return{data:Ba(r),error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}})}exists(n){return Re(this,void 0,void 0,function*(){let t=this._getFinalPath(n);try{return yield Av(this.fetch,`${this.url}/object/${t}`,{headers:this.headers}),{data:!0,error:null}}catch(r){if(ce(r)&&r instanceof On){let o=r.originalError;if([400,404].includes(o?.status))return{data:!1,error:r}}throw r}})}getPublicUrl(n,t){let r=this._getFinalPath(n),o=[],i=t?.download?`download=${t.download===!0?"":t.download}`:"";i!==""&&o.push(i);let a=typeof t?.transform<"u"?"render/image":"object",c=this.transformOptsToQueryString(t?.transform||{});c!==""&&o.push(c);let l=o.join("&");return l!==""&&(l=`?${l}`),{data:{publicUrl:encodeURI(`${this.url}/${a}/public/${r}${l}`)}}}remove(n){return Re(this,void 0,void 0,function*(){try{return{data:yield za(this.fetch,`${this.url}/object/${this.bucketId}`,{prefixes:n},{headers:this.headers}),error:null}}catch(t){if(ce(t))return{data:null,error:t};throw t}})}list(n,t,r){return Re(this,void 0,void 0,function*(){try{let o=Object.assign(Object.assign(Object.assign({},$M),t),{prefix:n||""});return{data:yield gt(this.fetch,`${this.url}/object/list/${this.bucketId}`,o,{headers:this.headers},r),error:null}}catch(o){if(ce(o))return{data:null,error:o};throw o}})}encodeMetadata(n){return JSON.stringify(n)}toBase64(n){return typeof Buffer<"u"?Buffer.from(n).toString("base64"):btoa(n)}_getFinalPath(n){return`${this.bucketId}/${n}`}_removeEmptyFolders(n){return n.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(n){let t=[];return n.width&&t.push(`width=${n.width}`),n.height&&t.push(`height=${n.height}`),n.resize&&t.push(`resize=${n.resize}`),n.format&&t.push(`format=${n.format}`),n.quality&&t.push(`quality=${n.quality}`),t.join("&")}};var Nv="2.7.1";var Rv={"X-Client-Info":`storage-js/${Nv}`};var qr=function(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},qa=class{constructor(n,t={},r){this.url=n,this.headers=Object.assign(Object.assign({},Rv),t),this.fetch=Ha(r)}listBuckets(){return qr(this,void 0,void 0,function*(){try{return{data:yield Gr(this.fetch,`${this.url}/bucket`,{headers:this.headers}),error:null}}catch(n){if(ce(n))return{data:null,error:n};throw n}})}getBucket(n){return qr(this,void 0,void 0,function*(){try{return{data:yield Gr(this.fetch,`${this.url}/bucket/${n}`,{headers:this.headers}),error:null}}catch(t){if(ce(t))return{data:null,error:t};throw t}})}createBucket(n,t={public:!1}){return qr(this,void 0,void 0,function*(){try{return{data:yield gt(this.fetch,`${this.url}/bucket`,{id:n,name:n,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}})}updateBucket(n,t){return qr(this,void 0,void 0,function*(){try{return{data:yield Tv(this.fetch,`${this.url}/bucket/${n}`,{id:n,name:n,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}})}emptyBucket(n){return qr(this,void 0,void 0,function*(){try{return{data:yield gt(this.fetch,`${this.url}/bucket/${n}/empty`,{},{headers:this.headers}),error:null}}catch(t){if(ce(t))return{data:null,error:t};throw t}})}deleteBucket(n){return qr(this,void 0,void 0,function*(){try{return{data:yield za(this.fetch,`${this.url}/bucket/${n}`,{},{headers:this.headers}),error:null}}catch(t){if(ce(t))return{data:null,error:t};throw t}})}};var pi=class extends qa{constructor(n,t={},r){super(n,t,r)}from(n){return new Ga(this.url,this.headers,n,this.fetch)}};var Pv="2.46.1";var gi="";typeof Deno<"u"?gi="deno":typeof document<"u"?gi="web":typeof navigator<"u"&&navigator.product==="ReactNative"?gi="react-native":gi="node";var UM={"X-Client-Info":`supabase-js-${gi}/${Pv}`},kv={headers:UM},Fv={schema:"public"},Lv={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},jv={};Xd();var BM=function(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},HM=e=>{let n;return e?n=e:typeof fetch>"u"?n=Kd:n=fetch,(...t)=>n(...t)},zM=()=>typeof Headers>"u"?Jd:Headers,Vv=(e,n,t)=>{let r=HM(t),o=zM();return(i,s)=>BM(void 0,void 0,void 0,function*(){var a;let c=(a=yield n())!==null&&a!==void 0?a:e,l=new o(s?.headers);return l.has("apikey")||l.set("apikey",e),l.has("Authorization")||l.set("Authorization",`Bearer ${c}`),r(i,Object.assign(Object.assign({},s),{headers:l}))})};var GM=function(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})};function $v(e){return e.replace(/\/$/,"")}function Uv(e,n){let{db:t,auth:r,realtime:o,global:i}=e,{db:s,auth:a,realtime:c,global:l}=n,u={db:Object.assign(Object.assign({},s),t),auth:Object.assign(Object.assign({},a),r),realtime:Object.assign(Object.assign({},c),o),global:Object.assign(Object.assign({},l),i),accessToken:()=>GM(this,void 0,void 0,function*(){return""})};return e.accessToken?u.accessToken=e.accessToken:delete u.accessToken,u}function Bv(e){return Math.round(Date.now()/1e3)+e}function Hv(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){let n=Math.random()*16|0;return(e=="x"?n:n&3|8).toString(16)})}var at=()=>typeof document<"u",Rn={tested:!1,writable:!1},Zt=()=>{if(!at())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(Rn.tested)return Rn.writable;let e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),Rn.tested=!0,Rn.writable=!0}catch{Rn.tested=!0,Rn.writable=!1}return Rn.writable};function Wa(e){let n={},t=new URL(e);if(t.hash&&t.hash[0]==="#")try{new URLSearchParams(t.hash.substring(1)).forEach((o,i)=>{n[i]=o})}catch{}return t.searchParams.forEach((r,o)=>{n[o]=r}),n}var Za=e=>{let n;return e?n=e:typeof fetch>"u"?n=(...t)=>import("./chunk-6ISG364Z.js").then(({default:r})=>r(...t)):n=fetch,(...t)=>n(...t)},zv=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",Yt=(e,n,t)=>h(void 0,null,function*(){yield e.setItem(n,JSON.stringify(t))}),vi=(e,n)=>h(void 0,null,function*(){let t=yield e.getItem(n);if(!t)return null;try{return JSON.parse(t)}catch{return t}}),Ya=(e,n)=>h(void 0,null,function*(){yield e.removeItem(n)});function qM(e){let n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",t="",r,o,i,s,a,c,l,u=0;for(e=e.replace("-","+").replace("_","/");u>4,o=(a&15)<<4|c>>2,i=(c&3)<<6|l,t=t+String.fromCharCode(r),c!=64&&o!=0&&(t=t+String.fromCharCode(o)),l!=64&&i!=0&&(t=t+String.fromCharCode(i));return t}var mi=class e{constructor(){this.promise=new e.promiseConstructor((n,t)=>{this.resolve=n,this.reject=t})}};mi.promiseConstructor=Promise;function Ud(e){let n=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}=?$|[a-z0-9_-]{2}(==)?$)$/i,t=e.split(".");if(t.length!==3)throw new Error("JWT is not valid: not a JWT structure");if(!n.test(t[1]))throw new Error("JWT is not valid: payload is not in base64url format");let r=t[1];return JSON.parse(qM(r))}function Gv(e){return h(this,null,function*(){return yield new Promise(n=>{setTimeout(()=>n(null),e)})})}function qv(e,n){return new Promise((r,o)=>{h(this,null,function*(){for(let i=0;i<1/0;i++)try{let s=yield e(i);if(!n(i,null,s)){r(s);return}}catch(s){if(!n(i,s)){o(s);return}}})})}function WM(e){return("0"+e.toString(16)).substr(-2)}function Pn(){let n=new Uint32Array(56);if(typeof crypto>"u"){let t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",r=t.length,o="";for(let i=0;i<56;i++)o+=t.charAt(Math.floor(Math.random()*r));return o}return crypto.getRandomValues(n),Array.from(n,WM).join("")}function ZM(e){return h(this,null,function*(){let t=new TextEncoder().encode(e),r=yield crypto.subtle.digest("SHA-256",t),o=new Uint8Array(r);return Array.from(o).map(i=>String.fromCharCode(i)).join("")})}function YM(e){return btoa(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function kn(e){return h(this,null,function*(){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),e;let t=yield ZM(e);return YM(t)})}var yi=class extends Error{constructor(n,t){super(n),this.__isAuthError=!0,this.name="AuthError",this.status=t}};function F(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}var Qa=class extends yi{constructor(n,t){super(n,t),this.name="AuthApiError",this.status=t}toJSON(){return{name:this.name,message:this.message,status:this.status}}};function Wv(e){return F(e)&&e.name==="AuthApiError"}var Wr=class extends yi{constructor(n,t){super(n),this.name="AuthUnknownError",this.originalError=t}},It=class extends yi{constructor(n,t,r){super(n),this.name=t,this.status=r}toJSON(){return{name:this.name,message:this.message,status:this.status}}},Mt=class extends It{constructor(){super("Auth session missing!","AuthSessionMissingError",400)}},Zr=class extends It{constructor(){super("Auth session or user missing","AuthInvalidTokenResponseError",500)}},Fn=class extends It{constructor(n){super(n,"AuthInvalidCredentialsError",400)}},Ln=class extends It{constructor(n,t=null){super(n,"AuthImplicitGrantRedirectError",500),this.details=null,this.details=t}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}},wi=class extends It{constructor(n,t=null){super(n,"AuthPKCEGrantCodeExchangeError",500),this.details=null,this.details=t}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}},Yr=class extends It{constructor(n,t){super(n,"AuthRetryableFetchError",t)}};function Ja(e){return F(e)&&e.name==="AuthRetryableFetchError"}var Ka=class extends It{constructor(n,t,r){super(n,"AuthWeakPasswordError",t),this.reasons=r}};var QM=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);oe.msg||e.message||e.error_description||e.error||JSON.stringify(e),KM=[502,503,504];function Zv(e){return h(this,null,function*(){if(!zv(e))throw new Yr(Qr(e),0);if(KM.includes(e.status))throw new Yr(Qr(e),e.status);let n;try{n=yield e.json()}catch(t){throw new Wr(Qr(t),t)}throw typeof n=="object"&&n&&typeof n.weak_password=="object"&&n.weak_password&&Array.isArray(n.weak_password.reasons)&&n.weak_password.reasons.length&&n.weak_password.reasons.reduce((t,r)=>t&&typeof r=="string",!0)?new Ka(Qr(n),e.status,n.weak_password.reasons):new Qa(Qr(n),e.status||500)})}var JM=(e,n,t,r)=>{let o={method:e,headers:n?.headers||{}};return e==="GET"?o:(o.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},n?.headers),o.body=JSON.stringify(r),Object.assign(Object.assign({},o),t))};function $(e,n,t,r){return h(this,null,function*(){var o;let i=Object.assign({},r?.headers);r?.jwt&&(i.Authorization=`Bearer ${r.jwt}`);let s=(o=r?.query)!==null&&o!==void 0?o:{};r?.redirectTo&&(s.redirect_to=r.redirectTo);let a=Object.keys(s).length?"?"+new URLSearchParams(s).toString():"",c=yield XM(e,n,t+a,{headers:i,noResolveJson:r?.noResolveJson},{},r?.body);return r?.xform?r?.xform(c):{data:Object.assign({},c),error:null}})}function XM(e,n,t,r,o,i){return h(this,null,function*(){let s=JM(n,r,o,i),a;try{a=yield e(t,s)}catch(c){throw console.error(c),new Yr(Qr(c),0)}if(a.ok||(yield Zv(a)),r?.noResolveJson)return a;try{return yield a.json()}catch(c){yield Zv(c)}})}function Qt(e){var n;let t=null;eS(e)&&(t=Object.assign({},e),e.expires_at||(t.expires_at=Bv(e.expires_in)));let r=(n=e.user)!==null&&n!==void 0?n:e;return{data:{session:t,user:r},error:null}}function Bd(e){let n=Qt(e);return!n.error&&e.weak_password&&typeof e.weak_password=="object"&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message=="string"&&e.weak_password.reasons.reduce((t,r)=>t&&typeof r=="string",!0)&&(n.data.weak_password=e.weak_password),n}function mt(e){var n;return{data:{user:(n=e.user)!==null&&n!==void 0?n:e},error:null}}function Yv(e){return{data:e,error:null}}function Qv(e){let{action_link:n,email_otp:t,hashed_token:r,redirect_to:o,verification_type:i}=e,s=QM(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),a={action_link:n,email_otp:t,hashed_token:r,redirect_to:o,verification_type:i},c=Object.assign({},s);return{data:{properties:a,user:c},error:null}}function Kv(e){return e}function eS(e){return e.access_token&&e.refresh_token&&e.expires_in}var tS=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var o=0,r=Object.getOwnPropertySymbols(e);o0&&(f.forEach(v=>{let m=parseInt(v.split(";")[0].split("=")[1].substring(0,1)),y=JSON.parse(v.split(";")[1].split("=")[1]);l[`${y}Page`]=m}),l.total=parseInt(p)),{data:Object.assign(Object.assign({},d),l),error:null}}catch(l){if(F(l))return{data:{users:[]},error:l};throw l}})}getUserById(n){return h(this,null,function*(){try{return yield $(this.fetch,"GET",`${this.url}/admin/users/${n}`,{headers:this.headers,xform:mt})}catch(t){if(F(t))return{data:{user:null},error:t};throw t}})}updateUserById(n,t){return h(this,null,function*(){try{return yield $(this.fetch,"PUT",`${this.url}/admin/users/${n}`,{body:t,headers:this.headers,xform:mt})}catch(r){if(F(r))return{data:{user:null},error:r};throw r}})}deleteUser(n,t=!1){return h(this,null,function*(){try{return yield $(this.fetch,"DELETE",`${this.url}/admin/users/${n}`,{headers:this.headers,body:{should_soft_delete:t},xform:mt})}catch(r){if(F(r))return{data:{user:null},error:r};throw r}})}_listFactors(n){return h(this,null,function*(){try{let{data:t,error:r}=yield $(this.fetch,"GET",`${this.url}/admin/users/${n.userId}/factors`,{headers:this.headers,xform:o=>({data:{factors:o},error:null})});return{data:t,error:r}}catch(t){if(F(t))return{data:null,error:t};throw t}})}_deleteFactor(n){return h(this,null,function*(){try{return{data:yield $(this.fetch,"DELETE",`${this.url}/admin/users/${n.userId}/factors/${n.id}`,{headers:this.headers}),error:null}}catch(t){if(F(t))return{data:null,error:t};throw t}})}};var Xa="2.61.0";var Jv="http://localhost:9999",Xv="supabase.auth.token";var ey={"X-Client-Info":`gotrue-js/${Xa}`},Hd=10;var ty={getItem:e=>Zt()?globalThis.localStorage.getItem(e):null,setItem:(e,n)=>{Zt()&&globalThis.localStorage.setItem(e,n)},removeItem:e=>{Zt()&&globalThis.localStorage.removeItem(e)}};function zd(e={}){return{getItem:n=>e[n]||null,setItem:(n,t)=>{e[n]=t},removeItem:n=>{delete e[n]}}}function ny(){if(typeof globalThis!="object")try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<"u"&&(self.globalThis=self)}}var nS={debug:!!(globalThis&&Zt()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")},ec=class extends Error{constructor(n){super(n),this.isAcquireTimeout=!0}};ny();var rS={url:Jv,storageKey:Xv,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:ey,flowType:"implicit",debug:!1},_i=30*1e3,ry=3;function oS(e,n,t){return h(this,null,function*(){return yield t()})}var Gd=(()=>{class e{constructor(t){var r;this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log,this.instanceID=e.nextInstanceID,e.nextInstanceID+=1,this.instanceID>0&&at()&&console.warn("Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.");let o=Object.assign(Object.assign({},rS),t);if(this.logDebugMessages=!!o.debug,typeof o.debug=="function"&&(this.logger=o.debug),this.persistSession=o.persistSession,this.storageKey=o.storageKey,this.autoRefreshToken=o.autoRefreshToken,this.admin=new Kr({url:o.url,headers:o.headers,fetch:o.fetch}),this.url=o.url,this.headers=o.headers,this.fetch=Za(o.fetch),this.lock=o.lock||oS,this.detectSessionInUrl=o.detectSessionInUrl,this.flowType=o.flowType,this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this)},this.persistSession?o.storage?this.storage=o.storage:Zt()?this.storage=ty:(this.memoryStorage={},this.storage=zd(this.memoryStorage)):(this.memoryStorage={},this.storage=zd(this.memoryStorage)),at()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(i){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",i)}(r=this.broadcastChannel)===null||r===void 0||r.addEventListener("message",i=>h(this,null,function*(){this._debug("received broadcast notification from other tab or client",i),yield this._notifyAllSubscribers(i.data.event,i.data.session,!1)}))}this.initialize()}_debug(...t){return this.logDebugMessages&&this.logger(`GoTrueClient@${this.instanceID} (${Xa}) ${new Date().toISOString()}`,...t),this}initialize(){return h(this,null,function*(){return this.initializePromise?yield this.initializePromise:(this.initializePromise=h(this,null,function*(){return yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._initialize()}))}),yield this.initializePromise)})}_initialize(){return h(this,null,function*(){try{let t=at()?yield this._isPKCEFlow():!1;if(this._debug("#_initialize()","begin","is PKCE flow",t),t||this.detectSessionInUrl&&this._isImplicitGrantFlow()){let{data:r,error:o}=yield this._getSessionFromURL(t);if(o)return this._debug("#_initialize()","error detecting session from URL",o),o?.message==="Identity is already linked"||o?.message==="Identity is already linked to another user"?{error:o}:(yield this._removeSession(),{error:o});let{session:i,redirectType:s}=r;return this._debug("#_initialize()","detected session in URL",i,"redirect type",s),yield this._saveSession(i),setTimeout(()=>h(this,null,function*(){s==="recovery"?yield this._notifyAllSubscribers("PASSWORD_RECOVERY",i):yield this._notifyAllSubscribers("SIGNED_IN",i)}),0),{error:null}}return yield this._recoverAndRefresh(),{error:null}}catch(t){return F(t)?{error:t}:{error:new Wr("Unexpected error during initialization",t)}}finally{yield this._handleVisibilityChange(),this._debug("#_initialize()","end")}})}signUp(t){return h(this,null,function*(){var r,o,i;try{yield this._removeSession();let s;if("email"in t){let{email:d,password:p,options:f}=t,v=null,m=null;if(this.flowType==="pkce"){let y=Pn();yield Yt(this.storage,`${this.storageKey}-code-verifier`,y),v=yield kn(y),m=y===v?"plain":"s256"}s=yield $(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:f?.emailRedirectTo,body:{email:d,password:p,data:(r=f?.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:f?.captchaToken},code_challenge:v,code_challenge_method:m},xform:Qt})}else if("phone"in t){let{phone:d,password:p,options:f}=t;s=yield $(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:d,password:p,data:(o=f?.data)!==null&&o!==void 0?o:{},channel:(i=f?.channel)!==null&&i!==void 0?i:"sms",gotrue_meta_security:{captcha_token:f?.captchaToken}},xform:Qt})}else throw new Fn("You must provide either an email or phone number and a password");let{data:a,error:c}=s;if(c||!a)return{data:{user:null,session:null},error:c};let l=a.session,u=a.user;return a.session&&(yield this._saveSession(a.session),yield this._notifyAllSubscribers("SIGNED_IN",l)),{data:{user:u,session:l},error:null}}catch(s){if(F(s))return{data:{user:null,session:null},error:s};throw s}})}signInWithPassword(t){return h(this,null,function*(){try{yield this._removeSession();let r;if("email"in t){let{email:s,password:a,options:c}=t;r=yield $(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:s,password:a,gotrue_meta_security:{captcha_token:c?.captchaToken}},xform:Bd})}else if("phone"in t){let{phone:s,password:a,options:c}=t;r=yield $(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:s,password:a,gotrue_meta_security:{captcha_token:c?.captchaToken}},xform:Bd})}else throw new Fn("You must provide either an email or phone number and a password");let{data:o,error:i}=r;return i?{data:{user:null,session:null},error:i}:!o||!o.session||!o.user?{data:{user:null,session:null},error:new Zr}:(o.session&&(yield this._saveSession(o.session),yield this._notifyAllSubscribers("SIGNED_IN",o.session)),{data:Object.assign({user:o.user,session:o.session},o.weak_password?{weakPassword:o.weak_password}:null),error:i})}catch(r){if(F(r))return{data:{user:null,session:null},error:r};throw r}})}signInWithOAuth(t){return h(this,null,function*(){var r,o,i,s;return yield this._removeSession(),yield this._handleProviderSignIn(t.provider,{redirectTo:(r=t.options)===null||r===void 0?void 0:r.redirectTo,scopes:(o=t.options)===null||o===void 0?void 0:o.scopes,queryParams:(i=t.options)===null||i===void 0?void 0:i.queryParams,skipBrowserRedirect:(s=t.options)===null||s===void 0?void 0:s.skipBrowserRedirect})})}exchangeCodeForSession(t){return h(this,null,function*(){return yield this.initializePromise,this._acquireLock(-1,()=>h(this,null,function*(){return this._exchangeCodeForSession(t)}))})}_exchangeCodeForSession(t){return h(this,null,function*(){let r=yield vi(this.storage,`${this.storageKey}-code-verifier`),[o,i]=(r??"").split("/"),{data:s,error:a}=yield $(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:o},xform:Qt});return yield Ya(this.storage,`${this.storageKey}-code-verifier`),a?{data:{user:null,session:null,redirectType:null},error:a}:!s||!s.session||!s.user?{data:{user:null,session:null,redirectType:null},error:new Zr}:(s.session&&(yield this._saveSession(s.session),yield this._notifyAllSubscribers("SIGNED_IN",s.session)),{data:Object.assign(Object.assign({},s),{redirectType:i??null}),error:a})})}signInWithIdToken(t){return h(this,null,function*(){yield this._removeSession();try{let{options:r,provider:o,token:i,access_token:s,nonce:a}=t,c=yield $(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:o,id_token:i,access_token:s,nonce:a,gotrue_meta_security:{captcha_token:r?.captchaToken}},xform:Qt}),{data:l,error:u}=c;return u?{data:{user:null,session:null},error:u}:!l||!l.session||!l.user?{data:{user:null,session:null},error:new Zr}:(l.session&&(yield this._saveSession(l.session),yield this._notifyAllSubscribers("SIGNED_IN",l.session)),{data:l,error:u})}catch(r){if(F(r))return{data:{user:null,session:null},error:r};throw r}})}signInWithOtp(t){return h(this,null,function*(){var r,o,i,s,a;try{if(yield this._removeSession(),"email"in t){let{email:c,options:l}=t,u=null,d=null;if(this.flowType==="pkce"){let f=Pn();yield Yt(this.storage,`${this.storageKey}-code-verifier`,f),u=yield kn(f),d=f===u?"plain":"s256"}let{error:p}=yield $(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:c,data:(r=l?.data)!==null&&r!==void 0?r:{},create_user:(o=l?.shouldCreateUser)!==null&&o!==void 0?o:!0,gotrue_meta_security:{captcha_token:l?.captchaToken},code_challenge:u,code_challenge_method:d},redirectTo:l?.emailRedirectTo});return{data:{user:null,session:null},error:p}}if("phone"in t){let{phone:c,options:l}=t,{data:u,error:d}=yield $(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:c,data:(i=l?.data)!==null&&i!==void 0?i:{},create_user:(s=l?.shouldCreateUser)!==null&&s!==void 0?s:!0,gotrue_meta_security:{captcha_token:l?.captchaToken},channel:(a=l?.channel)!==null&&a!==void 0?a:"sms"}});return{data:{user:null,session:null,messageId:u?.message_id},error:d}}throw new Fn("You must provide either an email or phone number.")}catch(c){if(F(c))return{data:{user:null,session:null},error:c};throw c}})}verifyOtp(t){return h(this,null,function*(){var r,o;try{t.type!=="email_change"&&t.type!=="phone_change"&&(yield this._removeSession());let i,s;"options"in t&&(i=(r=t.options)===null||r===void 0?void 0:r.redirectTo,s=(o=t.options)===null||o===void 0?void 0:o.captchaToken);let{data:a,error:c}=yield $(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:s}}),redirectTo:i,xform:Qt});if(c)throw c;if(!a)throw new Error("An error occurred on token verification.");let l=a.session,u=a.user;return l?.access_token&&(yield this._saveSession(l),yield this._notifyAllSubscribers("SIGNED_IN",l)),{data:{user:u,session:l},error:null}}catch(i){if(F(i))return{data:{user:null,session:null},error:i};throw i}})}signInWithSSO(t){return h(this,null,function*(){var r,o,i;try{yield this._removeSession();let s=null,a=null;if(this.flowType==="pkce"){let c=Pn();yield Yt(this.storage,`${this.storageKey}-code-verifier`,c),s=yield kn(c),a=c===s?"plain":"s256"}return yield $(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in t?{provider_id:t.providerId}:null),"domain"in t?{domain:t.domain}:null),{redirect_to:(o=(r=t.options)===null||r===void 0?void 0:r.redirectTo)!==null&&o!==void 0?o:void 0}),!((i=t?.options)===null||i===void 0)&&i.captchaToken?{gotrue_meta_security:{captcha_token:t.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:s,code_challenge_method:a}),headers:this.headers,xform:Yv})}catch(s){if(F(s))return{data:null,error:s};throw s}})}reauthenticate(){return h(this,null,function*(){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._reauthenticate()}))})}_reauthenticate(){return h(this,null,function*(){try{return yield this._useSession(t=>h(this,null,function*(){let{data:{session:r},error:o}=t;if(o)throw o;if(!r)throw new Mt;let{error:i}=yield $(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:r.access_token});return{data:{user:null,session:null},error:i}}))}catch(t){if(F(t))return{data:{user:null,session:null},error:t};throw t}})}resend(t){return h(this,null,function*(){try{t.type!="email_change"&&t.type!="phone_change"&&(yield this._removeSession());let r=`${this.url}/resend`;if("email"in t){let{email:o,type:i,options:s}=t,{error:a}=yield $(this.fetch,"POST",r,{headers:this.headers,body:{email:o,type:i,gotrue_meta_security:{captcha_token:s?.captchaToken}},redirectTo:s?.emailRedirectTo});return{data:{user:null,session:null},error:a}}else if("phone"in t){let{phone:o,type:i,options:s}=t,{data:a,error:c}=yield $(this.fetch,"POST",r,{headers:this.headers,body:{phone:o,type:i,gotrue_meta_security:{captcha_token:s?.captchaToken}}});return{data:{user:null,session:null,messageId:a?.message_id},error:c}}throw new Fn("You must provide either an email or phone number and a type")}catch(r){if(F(r))return{data:{user:null,session:null},error:r};throw r}})}getSession(){return h(this,null,function*(){return yield this.initializePromise,this._acquireLock(-1,()=>h(this,null,function*(){return this._useSession(t=>h(this,null,function*(){return t}))}))})}_acquireLock(t,r){return h(this,null,function*(){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){let o=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),i=h(this,null,function*(){return yield o,yield r()});return this.pendingInLock.push(h(this,null,function*(){try{yield i}catch{}})),i}return yield this.lock(`lock:${this.storageKey}`,t,()=>h(this,null,function*(){this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;let o=r();for(this.pendingInLock.push(h(this,null,function*(){try{yield o}catch{}})),yield o;this.pendingInLock.length;){let i=[...this.pendingInLock];yield Promise.all(i),this.pendingInLock.splice(0,i.length)}return yield o}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}}))}finally{this._debug("#_acquireLock","end")}})}_useSession(t){return h(this,null,function*(){this._debug("#_useSession","begin");try{let r=yield this.__loadSession();return yield t(r)}finally{this._debug("#_useSession","end")}})}__loadSession(){return h(this,null,function*(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null,r=yield vi(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",r),r!==null&&(this._isValidSession(r)?t=r:(this._debug("#getSession()","session from storage is not valid"),yield this._removeSession())),!t)return{data:{session:null},error:null};let o=t.expires_at?t.expires_at<=Date.now()/1e3:!1;if(this._debug("#__loadSession()",`session has${o?"":" not"} expired`,"expires_at",t.expires_at),!o)return{data:{session:t},error:null};let{session:i,error:s}=yield this._callRefreshToken(t.refresh_token);return s?{data:{session:null},error:s}:{data:{session:i},error:null}}finally{this._debug("#__loadSession()","end")}})}getUser(t){return h(this,null,function*(){return t?yield this._getUser(t):(yield this.initializePromise,this._acquireLock(-1,()=>h(this,null,function*(){return yield this._getUser()})))})}_getUser(t){return h(this,null,function*(){try{return t?yield $(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:mt}):yield this._useSession(r=>h(this,null,function*(){var o,i;let{data:s,error:a}=r;if(a)throw a;return yield $(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(i=(o=s.session)===null||o===void 0?void 0:o.access_token)!==null&&i!==void 0?i:void 0,xform:mt})}))}catch(r){if(F(r))return{data:{user:null},error:r};throw r}})}updateUser(o){return h(this,arguments,function*(t,r={}){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._updateUser(t,r)}))})}_updateUser(o){return h(this,arguments,function*(t,r={}){try{return yield this._useSession(i=>h(this,null,function*(){let{data:s,error:a}=i;if(a)throw a;if(!s.session)throw new Mt;let c=s.session,l=null,u=null;if(this.flowType==="pkce"&&t.email!=null){let f=Pn();yield Yt(this.storage,`${this.storageKey}-code-verifier`,f),l=yield kn(f),u=f===l?"plain":"s256"}let{data:d,error:p}=yield $(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:r?.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:l,code_challenge_method:u}),jwt:c.access_token,xform:mt});if(p)throw p;return c.user=d.user,yield this._saveSession(c),yield this._notifyAllSubscribers("USER_UPDATED",c),{data:{user:c.user},error:null}}))}catch(i){if(F(i))return{data:{user:null},error:i};throw i}})}_decodeJWT(t){return Ud(t)}setSession(t){return h(this,null,function*(){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._setSession(t)}))})}_setSession(t){return h(this,null,function*(){try{if(!t.access_token||!t.refresh_token)throw new Mt;let r=Date.now()/1e3,o=r,i=!0,s=null,a=Ud(t.access_token);if(a.exp&&(o=a.exp,i=o<=r),i){let{session:c,error:l}=yield this._callRefreshToken(t.refresh_token);if(l)return{data:{user:null,session:null},error:l};if(!c)return{data:{user:null,session:null},error:null};s=c}else{let{data:c,error:l}=yield this._getUser(t.access_token);if(l)throw l;s={access_token:t.access_token,refresh_token:t.refresh_token,user:c.user,token_type:"bearer",expires_in:o-r,expires_at:o},yield this._saveSession(s),yield this._notifyAllSubscribers("SIGNED_IN",s)}return{data:{user:s.user,session:s},error:null}}catch(r){if(F(r))return{data:{session:null,user:null},error:r};throw r}})}refreshSession(t){return h(this,null,function*(){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._refreshSession(t)}))})}_refreshSession(t){return h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var o;if(!t){let{data:a,error:c}=r;if(c)throw c;t=(o=a.session)!==null&&o!==void 0?o:void 0}if(!t?.refresh_token)throw new Mt;let{session:i,error:s}=yield this._callRefreshToken(t.refresh_token);return s?{data:{user:null,session:null},error:s}:i?{data:{user:i.user,session:i},error:null}:{data:{user:null,session:null},error:null}}))}catch(r){if(F(r))return{data:{user:null,session:null},error:r};throw r}})}_getSessionFromURL(t){return h(this,null,function*(){try{if(!at())throw new Ln("No browser detected.");if(this.flowType==="implicit"&&!this._isImplicitGrantFlow())throw new Ln("Not a valid implicit grant flow url.");if(this.flowType=="pkce"&&!t)throw new wi("Not a valid PKCE flow url.");let r=Wa(window.location.href);if(t){if(!r.code)throw new wi("No code detected.");let{data:R,error:J}=yield this._exchangeCodeForSession(r.code);if(J)throw J;let ee=new URL(window.location.href);return ee.searchParams.delete("code"),window.history.replaceState(window.history.state,"",ee.toString()),{data:{session:R.session,redirectType:null},error:null}}if(r.error||r.error_description||r.error_code)throw new Ln(r.error_description||"Error in URL with unspecified error_description",{error:r.error||"unspecified_error",code:r.error_code||"unspecified_code"});let{provider_token:o,provider_refresh_token:i,access_token:s,refresh_token:a,expires_in:c,expires_at:l,token_type:u}=r;if(!s||!c||!a||!u)throw new Ln("No session defined in URL");let d=Math.round(Date.now()/1e3),p=parseInt(c),f=d+p;l&&(f=parseInt(l));let v=f-d;v*1e3<=_i&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${v}s, should have been closer to ${p}s`);let m=f-p;d-m>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",m,f,d):d-m<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clok for skew",m,f,d);let{data:y,error:C}=yield this._getUser(s);if(C)throw C;let ie={provider_token:o,provider_refresh_token:i,access_token:s,expires_in:p,expires_at:f,refresh_token:a,token_type:u,user:y.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),{data:{session:ie,redirectType:r.type},error:null}}catch(r){if(F(r))return{data:{session:null,redirectType:null},error:r};throw r}})}_isImplicitGrantFlow(){let t=Wa(window.location.href);return!!(at()&&(t.access_token||t.error_description))}_isPKCEFlow(){return h(this,null,function*(){let t=Wa(window.location.href),r=yield vi(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&r)})}signOut(){return h(this,arguments,function*(t={scope:"global"}){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._signOut(t)}))})}_signOut(){return h(this,arguments,function*({scope:t}={scope:"global"}){return yield this._useSession(r=>h(this,null,function*(){var o;let{data:i,error:s}=r;if(s)return{error:s};let a=(o=i.session)===null||o===void 0?void 0:o.access_token;if(a){let{error:c}=yield this.admin.signOut(a,t);if(c&&!(Wv(c)&&(c.status===404||c.status===401)))return{error:c}}return t!=="others"&&(yield this._removeSession(),yield Ya(this.storage,`${this.storageKey}-code-verifier`),yield this._notifyAllSubscribers("SIGNED_OUT",null)),{error:null}}))})}onAuthStateChange(t){let r=Hv(),o={id:r,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",r),this.stateChangeEmitters.delete(r)}};return this._debug("#onAuthStateChange()","registered callback with id",r),this.stateChangeEmitters.set(r,o),h(this,null,function*(){yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){this._emitInitialSession(r)}))}),{data:{subscription:o}}}_emitInitialSession(t){return h(this,null,function*(){return yield this._useSession(r=>h(this,null,function*(){var o,i;try{let{data:{session:s},error:a}=r;if(a)throw a;yield(o=this.stateChangeEmitters.get(t))===null||o===void 0?void 0:o.callback("INITIAL_SESSION",s),this._debug("INITIAL_SESSION","callback id",t,"session",s)}catch(s){yield(i=this.stateChangeEmitters.get(t))===null||i===void 0?void 0:i.callback("INITIAL_SESSION",null),this._debug("INITIAL_SESSION","callback id",t,"error",s),console.error(s)}}))})}resetPasswordForEmail(o){return h(this,arguments,function*(t,r={}){let i=null,s=null;if(this.flowType==="pkce"){let a=Pn();yield Yt(this.storage,`${this.storageKey}-code-verifier`,`${a}/PASSWORD_RECOVERY`),i=yield kn(a),s=a===i?"plain":"s256"}try{return yield $(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:i,code_challenge_method:s,gotrue_meta_security:{captcha_token:r.captchaToken}},headers:this.headers,redirectTo:r.redirectTo})}catch(a){if(F(a))return{data:null,error:a};throw a}})}getUserIdentities(){return h(this,null,function*(){var t;try{let{data:r,error:o}=yield this.getUser();if(o)throw o;return{data:{identities:(t=r.user.identities)!==null&&t!==void 0?t:[]},error:null}}catch(r){if(F(r))return{data:null,error:r};throw r}})}linkIdentity(t){return h(this,null,function*(){var r;try{let{data:o,error:i}=yield this._useSession(s=>h(this,null,function*(){var a,c,l,u,d;let{data:p,error:f}=s;if(f)throw f;let v=yield this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(a=t.options)===null||a===void 0?void 0:a.redirectTo,scopes:(c=t.options)===null||c===void 0?void 0:c.scopes,queryParams:(l=t.options)===null||l===void 0?void 0:l.queryParams,skipBrowserRedirect:!0});return yield $(this.fetch,"GET",v,{headers:this.headers,jwt:(d=(u=p.session)===null||u===void 0?void 0:u.access_token)!==null&&d!==void 0?d:void 0})}));if(i)throw i;return at()&&!(!((r=t.options)===null||r===void 0)&&r.skipBrowserRedirect)&&window.location.assign(o?.url),{data:{provider:t.provider,url:o?.url},error:null}}catch(o){if(F(o))return{data:{provider:t.provider,url:null},error:o};throw o}})}unlinkIdentity(t){return h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var o,i;let{data:s,error:a}=r;if(a)throw a;return yield $(this.fetch,"DELETE",`${this.url}/user/identities/${t.identity_id}`,{headers:this.headers,jwt:(i=(o=s.session)===null||o===void 0?void 0:o.access_token)!==null&&i!==void 0?i:void 0})}))}catch(r){if(F(r))return{data:null,error:r};throw r}})}_refreshAccessToken(t){return h(this,null,function*(){let r=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(r,"begin");try{let o=Date.now();return yield qv(i=>h(this,null,function*(){return yield Gv(i*200),this._debug(r,"refreshing attempt",i),yield $(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:Qt})}),(i,s,a)=>a&&a.error&&Ja(a.error)&&Date.now()+(i+1)*200-o<_i)}catch(o){if(this._debug(r,"error",o),F(o))return{data:{session:null,user:null},error:o};throw o}finally{this._debug(r,"end")}})}_isValidSession(t){return typeof t=="object"&&t!==null&&"access_token"in t&&"refresh_token"in t&&"expires_at"in t}_handleProviderSignIn(t,r){return h(this,null,function*(){let o=yield this._getUrlForProvider(`${this.url}/authorize`,t,{redirectTo:r.redirectTo,scopes:r.scopes,queryParams:r.queryParams});return this._debug("#_handleProviderSignIn()","provider",t,"options",r,"url",o),at()&&!r.skipBrowserRedirect&&window.location.assign(o),{data:{provider:t,url:o},error:null}})}_recoverAndRefresh(){return h(this,null,function*(){var t;let r="#_recoverAndRefresh()";this._debug(r,"begin");try{let o=yield vi(this.storage,this.storageKey);if(this._debug(r,"session from storage",o),!this._isValidSession(o)){this._debug(r,"session is not valid"),o!==null&&(yield this._removeSession());return}let i=Math.round(Date.now()/1e3),s=((t=o.expires_at)!==null&&t!==void 0?t:1/0)h(this,null,function*(){try{yield c.callback(t,r)}catch(l){s.push(l)}}));if(yield Promise.all(a),s.length>0){for(let c=0;cthis._autoRefreshTokenTick(),_i);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t),setTimeout(()=>h(this,null,function*(){yield this.initializePromise,yield this._autoRefreshTokenTick()}),0)})}_stopAutoRefresh(){return h(this,null,function*(){this._debug("#_stopAutoRefresh()");let t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t)})}startAutoRefresh(){return h(this,null,function*(){this._removeVisibilityChangedCallback(),yield this._startAutoRefresh()})}stopAutoRefresh(){return h(this,null,function*(){this._removeVisibilityChangedCallback(),yield this._stopAutoRefresh()})}_autoRefreshTokenTick(){return h(this,null,function*(){this._debug("#_autoRefreshTokenTick()","begin");try{yield this._acquireLock(0,()=>h(this,null,function*(){try{let t=Date.now();try{return yield this._useSession(r=>h(this,null,function*(){let{data:{session:o}}=r;if(!o||!o.refresh_token||!o.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}let i=Math.floor((o.expires_at*1e3-t)/_i);this._debug("#_autoRefreshTokenTick()",`access token expires in ${i} ticks, a tick lasts ${_i}ms, refresh threshold is ${ry} ticks`),i<=ry&&(yield this._callRefreshToken(o.refresh_token))}))}catch(r){console.error("Auto refresh tick failed with error. This is likely a transient error.",r)}}finally{this._debug("#_autoRefreshTokenTick()","end")}}))}catch(t){if(t.isAcquireTimeout||t instanceof ec)this._debug("auto refresh token tick lock not available");else throw t}})}_handleVisibilityChange(){return h(this,null,function*(){if(this._debug("#_handleVisibilityChange()"),!at()||!window?.addEventListener)return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=()=>h(this,null,function*(){return yield this._onVisibilityChanged(!1)}),window?.addEventListener("visibilitychange",this.visibilityChangedCallback),yield this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}})}_onVisibilityChanged(t){return h(this,null,function*(){let r=`#_onVisibilityChanged(${t})`;this._debug(r,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){if(document.visibilityState!=="visible"){this._debug(r,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}yield this._recoverAndRefresh()})))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()})}_getUrlForProvider(t,r,o){return h(this,null,function*(){let i=[`provider=${encodeURIComponent(r)}`];if(o?.redirectTo&&i.push(`redirect_to=${encodeURIComponent(o.redirectTo)}`),o?.scopes&&i.push(`scopes=${encodeURIComponent(o.scopes)}`),this.flowType==="pkce"){let s=Pn();yield Yt(this.storage,`${this.storageKey}-code-verifier`,s);let a=yield kn(s),c=s===a?"plain":"s256";this._debug("PKCE","code verifier",`${s.substring(0,5)}...`,"code challenge",a,"method",c);let l=new URLSearchParams({code_challenge:`${encodeURIComponent(a)}`,code_challenge_method:`${encodeURIComponent(c)}`});i.push(l.toString())}if(o?.queryParams){let s=new URLSearchParams(o.queryParams);i.push(s.toString())}return o?.skipBrowserRedirect&&i.push(`skip_http_redirect=${o.skipBrowserRedirect}`),`${t}?${i.join("&")}`})}_unenroll(t){return h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var o;let{data:i,error:s}=r;return s?{data:null,error:s}:yield $(this.fetch,"DELETE",`${this.url}/factors/${t.factorId}`,{headers:this.headers,jwt:(o=i?.session)===null||o===void 0?void 0:o.access_token})}))}catch(r){if(F(r))return{data:null,error:r};throw r}})}_enroll(t){return h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var o,i;let{data:s,error:a}=r;if(a)return{data:null,error:a};let{data:c,error:l}=yield $(this.fetch,"POST",`${this.url}/factors`,{body:{friendly_name:t.friendlyName,factor_type:t.factorType,issuer:t.issuer},headers:this.headers,jwt:(o=s?.session)===null||o===void 0?void 0:o.access_token});return l?{data:null,error:l}:(!((i=c?.totp)===null||i===void 0)&&i.qr_code&&(c.totp.qr_code=`data:image/svg+xml;utf-8,${c.totp.qr_code}`),{data:c,error:null})}))}catch(r){if(F(r))return{data:null,error:r};throw r}})}_verify(t){return h(this,null,function*(){return this._acquireLock(-1,()=>h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var o;let{data:i,error:s}=r;if(s)return{data:null,error:s};let{data:a,error:c}=yield $(this.fetch,"POST",`${this.url}/factors/${t.factorId}/verify`,{body:{code:t.code,challenge_id:t.challengeId},headers:this.headers,jwt:(o=i?.session)===null||o===void 0?void 0:o.access_token});return c?{data:null,error:c}:(yield this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+a.expires_in},a)),yield this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",a),{data:a,error:c})}))}catch(r){if(F(r))return{data:null,error:r};throw r}}))})}_challenge(t){return h(this,null,function*(){return this._acquireLock(-1,()=>h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var o;let{data:i,error:s}=r;return s?{data:null,error:s}:yield $(this.fetch,"POST",`${this.url}/factors/${t.factorId}/challenge`,{headers:this.headers,jwt:(o=i?.session)===null||o===void 0?void 0:o.access_token})}))}catch(r){if(F(r))return{data:null,error:r};throw r}}))})}_challengeAndVerify(t){return h(this,null,function*(){let{data:r,error:o}=yield this._challenge({factorId:t.factorId});return o?{data:null,error:o}:yield this._verify({factorId:t.factorId,challengeId:r.id,code:t.code})})}_listFactors(){return h(this,null,function*(){let{data:{user:t},error:r}=yield this.getUser();if(r)return{data:null,error:r};let o=t?.factors||[],i=o.filter(s=>s.factor_type==="totp"&&s.status==="verified");return{data:{all:o,totp:i},error:null}})}_getAuthenticatorAssuranceLevel(){return h(this,null,function*(){return this._acquireLock(-1,()=>h(this,null,function*(){return yield this._useSession(t=>h(this,null,function*(){var r,o;let{data:{session:i},error:s}=t;if(s)return{data:null,error:s};if(!i)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};let a=this._decodeJWT(i.access_token),c=null;a.aal&&(c=a.aal);let l=c;((o=(r=i.user.factors)===null||r===void 0?void 0:r.filter(p=>p.status==="verified"))!==null&&o!==void 0?o:[]).length>0&&(l="aal2");let d=a.amr||[];return{data:{currentLevel:c,nextLevel:l,currentAuthenticationMethods:d},error:null}}))}))})}}return e.nextInstanceID=0,e})();var iS=Gd,qd=iS;var tc=class extends qd{constructor(n){super(n)}};var sS=function(e,n,t,r){function o(i){return i instanceof t?i:new t(function(s){s(i)})}return new(t||(t=Promise))(function(i,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?i(u.value):o(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},nc=class{constructor(n,t,r){var o,i,s;if(this.supabaseUrl=n,this.supabaseKey=t,!n)throw new Error("supabaseUrl is required.");if(!t)throw new Error("supabaseKey is required.");let a=$v(n);this.realtimeUrl=`${a}/realtime/v1`.replace(/^http/i,"ws"),this.authUrl=`${a}/auth/v1`,this.storageUrl=`${a}/storage/v1`,this.functionsUrl=`${a}/functions/v1`;let c=`sb-${new URL(this.authUrl).hostname.split(".")[0]}-auth-token`,l={db:Fv,realtime:jv,auth:Object.assign(Object.assign({},Lv),{storageKey:c}),global:kv},u=Uv(r??{},l);this.storageKey=(o=u.auth.storageKey)!==null&&o!==void 0?o:"",this.headers=(i=u.global.headers)!==null&&i!==void 0?i:{},u.accessToken?(this.accessToken=u.accessToken,this.auth=new Proxy({},{get:(d,p)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(p)} is not possible`)}})):this.auth=this._initSupabaseAuthClient((s=u.auth)!==null&&s!==void 0?s:{},this.headers,u.global.fetch),this.fetch=Vv(t,this._getAccessToken.bind(this),u.global.fetch),this.realtime=this._initRealtimeClient(Object.assign({headers:this.headers},u.realtime)),this.rest=new bv(`${a}/rest/v1`,{headers:this.headers,schema:u.db.schema,fetch:this.fetch}),u.accessToken||this._listenForAuthEvents()}get functions(){return new ri(this.functionsUrl,{headers:this.headers,customFetch:this.fetch})}get storage(){return new pi(this.storageUrl,this.headers,this.fetch)}from(n){return this.rest.from(n)}schema(n){return this.rest.schema(n)}rpc(n,t={},r={}){return this.rest.rpc(n,t,r)}channel(n,t={config:{}}){return this.realtime.channel(n,t)}getChannels(){return this.realtime.getChannels()}removeChannel(n){return this.realtime.removeChannel(n)}removeAllChannels(){return this.realtime.removeAllChannels()}_getAccessToken(){var n,t;return sS(this,void 0,void 0,function*(){if(this.accessToken)return yield this.accessToken();let{data:r}=yield this.auth.getSession();return(t=(n=r.session)===null||n===void 0?void 0:n.access_token)!==null&&t!==void 0?t:null})}_initSupabaseAuthClient({autoRefreshToken:n,persistSession:t,detectSessionInUrl:r,storage:o,storageKey:i,flowType:s,lock:a,debug:c},l,u){var d;let p={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new tc({url:this.authUrl,headers:Object.assign(Object.assign({},p),l),storageKey:i,autoRefreshToken:n,persistSession:t,detectSessionInUrl:r,storage:o,flowType:s,lock:a,debug:c,fetch:u,hasCustomAuthorizationHeader:(d="Authorization"in this.headers)!==null&&d!==void 0?d:!1})}_initRealtimeClient(n){return new fi(this.realtimeUrl,Object.assign(Object.assign({},n),{params:Object.assign({apikey:this.supabaseKey},n?.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((t,r)=>{this._handleTokenChanged(t,"CLIENT",r?.access_token)})}_handleTokenChanged(n,t,r){(n==="TOKEN_REFRESHED"||n==="SIGNED_IN")&&this.changedAccessToken!==r?(this.realtime.setAuth(r??null),this.changedAccessToken=r):n==="SIGNED_OUT"&&(this.realtime.setAuth(this.supabaseKey),t=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}};var oy=(e,n,t)=>new nc(e,n,t);var Wd={production:!0,supabaseUrl:"https://qjahtmynumgefznenznr.supabase.co",supabaseKey:"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InFqYWh0bXludW1nZWZ6bmVuem5yIiwicm9sZSI6ImFub24iLCJpYXQiOjE3MzE4NTI3MDQsImV4cCI6MjA0NzQyODcwNH0.Vu-krFpene5evj8cjbSsarwv3364Tiqwwl69ZU7-H3A"};var Jr=(()=>{class e{constructor(){this.supabase=oy(Wd.supabaseUrl,Wd.supabaseKey)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var jn=class extends Error{};jn.prototype.name="InvalidTokenError";function aS(e){return decodeURIComponent(atob(e).replace(/(.)/g,(n,t)=>{let r=t.charCodeAt(0).toString(16).toUpperCase();return r.length<2&&(r="0"+r),"%"+r}))}function cS(e){let n=e.replace(/-/g,"+").replace(/_/g,"/");switch(n.length%4){case 0:break;case 2:n+="==";break;case 3:n+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return aS(n)}catch{return atob(n)}}function Zd(e,n){if(typeof e!="string")throw new jn("Invalid token specified: must be a string");n||(n={});let t=n.header===!0?0:1,r=e.split(".")[t];if(typeof r!="string")throw new jn(`Invalid token specified: missing part #${t+1}`);let o;try{o=cS(r)}catch(i){throw new jn(`Invalid token specified: invalid base64 for part #${t+1} (${i.message})`)}try{return JSON.parse(o)}catch(i){throw new jn(`Invalid token specified: invalid json for part #${t+1} (${i.message})`)}}var Ke=(()=>{class e{constructor(){this.supabase_client=g(Jr).supabase}session(){this.supabase_client.auth.getSession()}signUp(t,r){return h(this,null,function*(){let{data:o,error:i}=yield this.supabase_client.auth.signUp({email:t,password:r});return i?(console.error("Error al registrarse:",i.message),{error:i}):(console.log("Registro exitoso:",o),{data:o})})}logIn(t,r){return this.supabase_client.auth.signInWithPassword({email:t,password:r})}signOut(){return h(this,null,function*(){let{error:t}=yield this.supabase_client.auth.signOut();return t?{error:t}:{error:null}})}isLoggeIn(){return this.getToken()?!this.isTokenExpired():!1}isTokenExpired(){let t=this.getToken();if(!t)return!0;let r=Zd(t),o=Date.now()>=r.exp*1e3;return o&&this.logout(),o}getUserDetail(){let t=this.getToken();if(!t)return null;let r=Zd(t);return{id:r.sub,email:r.email,rol:r.role}}logout(){localStorage.removeItem("token")}getToken(){return localStorage.getItem("token")}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function lS(e,n){e&1&&(b(0,"small",15)(1,"span",7),D(2," error "),w(),D(3," Debes ingresar tu correo."),w())}function uS(e,n){e&1&&(b(0,"small",15)(1,"span",7),D(2," error "),w(),D(3," El correo no es valido."),w())}function dS(e,n){if(e&1&&pe(0,lS,4,0,"small",15)(1,uS,4,0,"small",15),e&2){let t=st();me(0,t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.required?0:-1),z(),me(1,t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.email&&(t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.pattern)?1:-1)}}function fS(e,n){e&1&&(b(0,"small",15)(1,"span",7),D(2," error "),w(),D(3," Debes ingresar tu contrase\xF1a."),w())}function hS(e,n){if(e&1&&pe(0,fS,4,0,"small",15),e&2){let t=st();me(0,t.formulario.controls.password.errors!=null&&t.formulario.controls.password.errors.required?0:-1)}}var iy=(()=>{class e{constructor(){this.form=g(jr),this.router=g(Me),this.authSupaBase=g(Ke)}ngOnInit(){this.formulario=this.form.group({email:this.form.control("",[Se.required,Se.email,Se.pattern(/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/)]),password:this.form.control("",[Se.required])})}autenticacion(){if(this.formulario.valid){let t=this.formulario.controls.email.value,r=this.formulario.controls.password.value;this.authSupaBase.logIn(t,r).then(o=>{localStorage.setItem("token",o.data.session.access_token),this.router.navigate(["/administrador/home"])}).catch(o=>{console.log(o)})}}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-auth-login"]],standalone:!0,features:[Z],decls:30,vars:3,consts:[[1,"card"],[1,"card-body"],[1,"text-center"],[1,"card-title"],["enctype","multipart/form-data","method","post",3,"submit","formGroup"],[1,"mb-3"],["for","email",1,"form-label"],[1,"material-symbols-outlined"],["type","email","name","email","id","email","formControlName","email","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"mb-2"],["for","password",1,"form-label"],["type","password","name","password","id","password","formControlName","password","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"accion"],["routerLink","/register"],["type","submit",1,"btn-event"],["id","message-error",1,"text-muted"]],template:function(r,o){r&1&&(b(0,"div",0)(1,"div",1)(2,"div",2)(3,"h5",3),D(4,"Inicio de Sesion"),w()(),H(5,"hr"),b(6,"form",4),ae("submit",function(){return o.autenticacion()}),b(7,"div",5)(8,"label",6)(9,"span",7),D(10," mail "),w(),D(11," Correo Electronico"),w(),H(12,"input",8),pe(13,dS,2,2),w(),b(14,"div",9)(15,"label",10)(16,"span",7),D(17," lock "),w(),D(18,"Contrase\xF1a"),w(),H(19,"input",11),pe(20,hS,1,1),w(),b(21,"div",12)(22,"p"),D(23,"Deseas crear una nueva cuenta. "),b(24,"a",13),D(25,"Aqui"),w()(),b(26,"button",14)(27,"span",7),D(28," login "),w(),D(29," Ingresar"),w()()()()()),r&2&&(z(6),Ce("formGroup",o.formulario),z(7),me(13,o.formulario.controls.email.touched&&o.formulario.controls.email.invalid||o.formulario.controls.email.dirty?13:-1),z(7),me(20,o.formulario.controls.password.touched&&o.formulario.controls.password.invalid||o.formulario.controls.password.dirty?20:-1))},dependencies:[Vr,Lr,Wt,kr,Fr,xn,Tn,Ne],styles:[".card[_ngcontent-%COMP%]{width:40vh;box-shadow:5px 10px 15px #9c9c9c25;border:none;border-radius:30px}.card[_ngcontent-%COMP%] .card-header[_ngcontent-%COMP%]{background-color:#fff;color:#000}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%]{margin:0;padding:0;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:1px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%]:focus{border:1px solid rgba(156,156,156,.144)}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%]{color:#ff00007c!important;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-align:end;font-size:.75rem;margin-bottom:10px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] p[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{text-decoration:none;color:#000}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] p[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:hover{color:#b28181}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{border:none;width:100%;padding:4px;border-radius:20px;background-color:#f8f4f4;display:flex;justify-content:center;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.1rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background-color:#f4ecec}"]})}}return e})();var sy=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-login"]],standalone:!0,features:[Z],decls:2,vars:0,consts:[[1,"content-login"]],template:function(r,o){r&1&&(b(0,"div",0),H(1,"app-auth-login"),w())},dependencies:[iy]})}}return e})();function pS(e,n){e&1&&(b(0,"small",15)(1,"span",4),D(2," error "),w(),D(3," Debes ingresar tu correo."),w())}function gS(e,n){e&1&&(b(0,"small",15)(1,"span",4),D(2," error "),w(),D(3," El correo no es valido."),w())}function mS(e,n){if(e&1&&pe(0,pS,4,0,"small",15)(1,gS,4,0,"small",15),e&2){let t=st();me(0,t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.required?0:-1),z(),me(1,t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.email&&(t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.pattern)?1:-1)}}function vS(e,n){e&1&&(b(0,"small",15)(1,"span",4),D(2," error "),w(),D(3," Debes ingresar tu contrase\xF1a."),w())}function yS(e,n){if(e&1&&pe(0,vS,4,0,"small",15),e&2){let t=st();me(0,t.formulario.controls.password.errors!=null&&t.formulario.controls.password.errors.required?0:-1)}}var ay=(()=>{class e{constructor(){this.form=g(jr),this.authSupaBase=g(Ke)}ngOnInit(){this.formulario=this.form.group({email:this.form.control("",[Se.required,Se.email,Se.pattern(/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/)]),password:this.form.control("",[Se.required])})}crearCuenta(){return h(this,null,function*(){if(this.formulario.valid){let t=this.formulario.controls.email.value,r=this.formulario.controls.password.value;console.log(t,r);let o=yield this.authSupaBase.signUp(t,r);o.error?alert(o.error.message):console.log(o.data)}})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-auth-register"]],standalone:!0,features:[Z],decls:29,vars:3,consts:[[1,"card"],[1,"card-body"],[1,"text-center"],["routerLink","/login",1,"arrow-login"],[1,"material-symbols-outlined"],[1,"card-title"],["enctype","multipart/form-data","method","post",3,"submit","formGroup"],[1,"mb-3"],["for","email",1,"form-label"],["type","email","name","email","id","email","formControlName","email","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"mb-2"],["for","password",1,"form-label"],["type","password","name","password","id","password","formControlName","password","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"accion"],["type","submit",1,"btn-event"],["id","message-error",1,"text-muted"]],template:function(r,o){r&1&&(b(0,"div",0)(1,"div",1)(2,"div",2)(3,"a",3)(4,"span",4),D(5," chevron_left "),w()(),b(6,"h5",5),D(7,"Crear Cuenta"),w()(),H(8,"hr"),b(9,"form",6),ae("submit",function(){return o.crearCuenta()}),b(10,"div",7)(11,"label",8)(12,"span",4),D(13," mail "),w(),D(14," Correo Electronico"),w(),H(15,"input",9),pe(16,mS,2,2),w(),b(17,"div",10)(18,"label",11)(19,"span",4),D(20," lock "),w(),D(21,"Contrase\xF1a"),w(),H(22,"input",12),pe(23,yS,1,1),w(),b(24,"div",13)(25,"button",14)(26,"span",4),D(27," save "),w(),D(28," Crear Cuenta"),w()()()()()),r&2&&(z(9),Ce("formGroup",o.formulario),z(7),me(16,o.formulario.controls.email.touched&&o.formulario.controls.email.invalid||o.formulario.controls.email.dirty?16:-1),z(7),me(23,o.formulario.controls.password.touched&&o.formulario.controls.password.invalid||o.formulario.controls.password.dirty?23:-1))},dependencies:[Vr,Lr,Wt,kr,Fr,xn,Tn,Ne],styles:[".card[_ngcontent-%COMP%]{width:40vh;box-shadow:5px 10px 15px #9c9c9c25;border:none;border-radius:30px}.card[_ngcontent-%COMP%] .card-header[_ngcontent-%COMP%]{background-color:#fff;color:#000}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow-login[_ngcontent-%COMP%]{position:absolute;top:2%;left:5%;text-decoration:none;color:#000;background-color:#f8f4f4;border-radius:100%;padding:2px;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow-login[_ngcontent-%COMP%]:hover{background-color:#f4ecec}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%]{margin:0;padding:0;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:1px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%]:focus{border:1px solid rgba(156,156,156,.144)}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%]{color:#ff00007c!important;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{border:none;width:100%;padding:4px;border-radius:20px;background-color:#f8f4f4;display:flex;justify-content:center;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.1rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background-color:#f4ecec}"]})}}return e})();var cy=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-register"]],standalone:!0,features:[Z],decls:2,vars:0,consts:[[1,"content-register"]],template:function(r,o){r&1&&(b(0,"div",0),H(1,"app-auth-register"),w())},dependencies:[ay]})}}return e})();var ly=(()=>{class e{constructor(){this.work=pr(),this.delete=Ps()}deleteEvent(){this.delete.emit(this.work())}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-home-work"]],inputs:{work:[ne.SignalBased,"work"]},outputs:{delete:"delete"},standalone:!0,features:[Z],decls:11,vars:6,consts:[[1,"card"],[1,"actions"],["title","Editar",1,"update",3,"routerLink"],["title","Eliminar",1,"delete",3,"click"],[1,"card-body"],[1,"card-title"],[1,"content"],[1,"card-footer",3,"routerLink"]],template:function(r,o){if(r&1&&(b(0,"div",0)(1,"div",1),H(2,"button",2),b(3,"button",3),ae("click",function(){return o.deleteEvent()}),w()(),b(4,"div",4)(5,"h5",5),D(6),w(),b(7,"div",6),D(8),w()(),b(9,"a",7),D(10," Ver "),w()()),r&2){let i,s,a,c;z(2),Mo("routerLink","/administrador/home/work/",(i=o.work())==null?null:i.id,"/edit"),z(4),_n((s=o.work())==null?null:s.titulo),z(2),yr(" ",(a=o.work())==null?null:a.descripcion," "),z(),Mo("routerLink","/administrador/home/",(c=o.work())==null?null:c.id,"/work/")}},dependencies:[Ne],styles:[".card[_ngcontent-%COMP%]{text-decoration:none;border:2px solid #f8f4f4}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{position:absolute;top:1%;right:0%}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{margin-right:5px;border-radius:100%;padding:0;border:1px solid rgb(129,129,129);width:13px;height:13px}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] .update[_ngcontent-%COMP%]{background-color:#ff0}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] .delete[_ngcontent-%COMP%]{background-color:red}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%]{padding:9px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .card-title[_ngcontent-%COMP%]{margin-bottom:4px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{line-height:.9rem;font-size:.74rem;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:5;overflow:hidden;text-overflow:ellipsis;text-align:justify}.card[_ngcontent-%COMP%] .card-footer[_ngcontent-%COMP%]{text-decoration:none;padding:4px 8px;border:none;text-align:center;background-color:#fff;font-size:.9rem}.card[_ngcontent-%COMP%]:hover{box-shadow:10px 10px 10px #ebdddd;cursor:pointer}@media screen and (width <= 1210){.card-footer[_ngcontent-%COMP%]{font-size:.4rem}}"]})}}return e})();var Xr=(()=>{class e{constructor(){this.supabase_client=g(Jr).supabase}sellstWork(){return h(this,null,function*(){let{data:t,error:r}=yield this.supabase_client.from("work").select("*").order("id",{ascending:!0});if(r)throw console.error("Error al leer los datos:",r.message),new Error(r.message);return t})}gettWork(t){return h(this,null,function*(){let{data:r,error:o}=yield this.supabase_client.from("work").select().eq("id",t).single();if(o)throw console.error("Error al leer los datos:",o.message),new Error(o.message);return r})}dltWork(t){return h(this,null,function*(){let{error:r}=yield this.supabase_client.from("work").delete().eq("id",t);if(r)throw console.error("Error al eliminar el registro:",r.message),new Error(r.message);return console.log("Registro eliminado correctamente"),""})}addWork(t){return h(this,null,function*(){let{data:r,error:o}=yield this.supabase_client.from("work").insert([t]).select();if(o)throw console.error("Error al insertar datos:",o.message),new Error(o.message);return console.log("Datos insertados correctamente:",r),r})}updWork(t,r){return h(this,null,function*(){let{data:o,error:i}=yield this.supabase_client.from("work").update(r).eq("id",t).select().single();if(i)throw console.error("Error al actualizar el registro:",i.message),new Error("No se pudo actualizar el registro");return o})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var wS=(e,n)=>n.id;function _S(e,n){if(e&1){let t=mg();b(0,"app-home-work",4),ae("delete",function(o){rp(t);let i=st();return op(i.dltWork(o))}),w()}if(e&2){let t=n.$implicit;Ce("work",t)}}var uy=(()=>{class e{constructor(){this.works=gr([]),this.areaServices=g(Xr)}ngOnInit(){this.sellWork()}ngOnDestroy(){this.works.set([])}sellWork(){return h(this,null,function*(){try{let t=yield this.areaServices.sellstWork();this.works.set(t)}catch(t){console.log(t)}})}dltWork(t){return h(this,null,function*(){if(confirm(`Deseas eliminar el area de trabajo '${t?.titulo}'`))try{let o=t?.id,i=yield this.areaServices.dltWork(o);console.log(i);let s=this.works().filter(a=>a.id!==t?.id);this.works.set(s)}catch(o){console.log(o)}})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-home"]],standalone:!0,features:[Z],decls:6,vars:0,consts:[[1,"content-work"],[3,"work"],["routerLink","/administrador/home/work/create",1,"add-work"],[1,"material-symbols-outlined"],[3,"delete","work"]],template:function(r,o){r&1&&(b(0,"div",0),Gs(1,_S,1,1,"app-home-work",1,wS),b(3,"a",2)(4,"span",3),D(5," add "),w()()()),r&2&&(z(),qs(o.works()))},dependencies:[ly,Ne],styles:[".content-work[_ngcontent-%COMP%]{margin:20px;display:grid;grid-template-columns:repeat(auto-fit,minmax(400px,1fr));gap:20px}.add-work[_ngcontent-%COMP%]{box-shadow:5px 10px 10px #f4ecec;background-color:#ebdddd;text-decoration:none;width:max-content;padding:4px;margin:0;display:flex;align-items:center;justify-content:center;border-radius:100%;position:fixed;bottom:2%;right:1%}.add-work[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:#000;font-size:1.8rem}@media screen and (width <= 700px){.add-work[_ngcontent-%COMP%]{bottom:2%;right:3%}}"]})}}return e})();var dy=(e,n)=>g(Ke).isLoggeIn()?!0:(g(Me).navigate(["/"]),!1);var Yd=(e,n)=>g(Ke).isLoggeIn()?(g(Me).navigate(["/administrador/home"]),!1):!0;function DS(e,n){e&1&&(b(0,"small",15)(1,"span",4),D(2," error "),w(),D(3," Debes ingresar el titulo."),w())}function bS(e,n){if(e&1&&pe(0,DS,4,0,"small",15),e&2){let t=st();me(0,t.formulario.controls.titulo.errors!=null&&t.formulario.controls.titulo.errors.required?0:-1)}}function CS(e,n){e&1&&(b(0,"small",15)(1,"span",4),D(2," error "),w(),D(3," Debes ingresar la descripci\xF3n."),w())}function ES(e,n){if(e&1&&pe(0,CS,4,0,"small",15),e&2){let t=st();me(0,t.formulario.controls.descripcion.errors!=null&&t.formulario.controls.descripcion.errors.required?0:-1)}}var fy=(()=>{class e{constructor(){this.formulario_work=Ps(),this.editWork=pr(),this.userDetails=g(Ke).getUserDetail(),this.routerActive=g(Be),this.form=g(jr),this.routerActive.params.subscribe(t=>{t.id>0?(this.titulo="Editar Area de Trabajo",this.idWork=t.id):(this.titulo="Crear Area de Trabajo",this.idWork=0)}),this.formulario=this.form.group({titulo:this.form.control("",[Se.required]),descripcion:this.form.control("",[Se.required])}),So(()=>{let t=this.editWork();t!=null&&this.detailWork(t)})}detailWork(t){this.formulario.controls.titulo.setValue(t.titulo),this.formulario.controls.descripcion.setValue(t.descripcion)}submitWork(){let t;this.formulario.valid&&(this.idWork>0?t={id:this.idWork,titulo:this.formulario.controls.titulo.value,descripcion:this.formulario.controls.descripcion.value,uidUser:this.userDetails?.id}:t={titulo:this.formulario.controls.titulo.value,descripcion:this.formulario.controls.descripcion.value,uidUser:this.userDetails?.id},this.formulario_work.emit(t))}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-post-update-work"]],inputs:{editWork:[ne.SignalBased,"editWork"]},outputs:{formulario_work:"formulario_work"},standalone:!0,features:[Z],decls:29,vars:5,consts:[[1,"card"],[1,"card-body"],[1,"text-center"],["routerLink","/administrador/home",1,"arrow"],[1,"material-symbols-outlined"],[1,"card-title"],["enctype","multipart/form-data","method","post",3,"submit","formGroup"],[1,"mb-3"],["for","titulo",1,"form-label"],["type","text","name","titulo","id","titulo","formControlName","titulo","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"mb-2"],["for","password",1,"form-label"],["name","descripcion","id","descripcion","formControlName","descripcion",1,"form-control","form-control-sm","shadow-none"],[1,"accion"],["type","submit",1,"btn-event"],["id","message-error",1,"text-muted"]],template:function(r,o){r&1&&(b(0,"div",0)(1,"div",1)(2,"div",2)(3,"a",3)(4,"span",4),D(5," chevron_left "),w()(),b(6,"h5",5),D(7),w()(),H(8,"hr"),b(9,"form",6),ae("submit",function(){return o.submitWork()}),b(10,"div",7)(11,"label",8)(12,"span",4),D(13," edit "),w(),D(14," Titulo"),w(),H(15,"input",9),pe(16,bS,1,1),w(),b(17,"div",10)(18,"label",11)(19,"span",4),D(20," edit "),w(),D(21," Descripci\xF3n"),w(),H(22,"textarea",12),pe(23,ES,1,1),w(),b(24,"div",13)(25,"button",14)(26,"span",4),D(27," save "),w(),D(28),w()()()()()),r&2&&(z(7),_n(o.titulo),z(2),Ce("formGroup",o.formulario),z(7),me(16,o.formulario.controls.titulo.touched&&o.formulario.controls.titulo.invalid||o.formulario.controls.titulo.dirty?16:-1),z(7),me(23,o.formulario.controls.descripcion.touched&&o.formulario.controls.descripcion.invalid||o.formulario.controls.descripcion.dirty?23:-1),z(5),yr(" ",o.idWork>0?"Editar Area":"Crear Area",""))},dependencies:[Ne,Vr,Lr,Wt,kr,Fr,xn,Tn],styles:[".card[_ngcontent-%COMP%]{width:40vh;box-shadow:5px 10px 15px #9c9c9c25;border:none;border-radius:30px}.card[_ngcontent-%COMP%] .card-header[_ngcontent-%COMP%]{background-color:#fff;color:#000}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]{position:absolute;top:2%;left:5%;text-decoration:none;color:#000;background-color:#f8f4f4;border-radius:100%;padding:2px;display:flex;align-items:center;cursor:pointer}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]:hover{background-color:#f4ecec}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%]{margin:0;padding:0;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:1px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%]:focus{border:1px solid rgba(156,156,156,.144)}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{resize:none;field-sizing:content}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%]{color:#ff00007c!important;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{border:none;width:100%;padding:4px;border-radius:20px;background-color:#f8f4f4;display:flex;justify-content:center;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.1rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background-color:#f4ecec}"]})}}return e})();var Qd=(()=>{class e{constructor(){this.areaServices=g(Xr),this.routerActive=g(Be),this.router=g(Me),this.routerActive.params.subscribe(t=>{t.id>0&&this.getWork(t.id)})}formPostArea(t){t.id>0?this.updateWork(t):this.postArea(t),setTimeout(()=>{this.router.navigate(["/administrador/home"])},1e3)}getWork(t){return h(this,null,function*(){try{let r=yield this.areaServices.gettWork(t);this.editWork=r}catch{this.router.navigate(["administrador/home"])}})}postArea(t){return h(this,null,function*(){try{let r=yield this.areaServices.addWork(t)}catch(r){console.log(r)}})}updateWork(t){return h(this,null,function*(){try{let r=t.id,o=yield this.areaServices.updWork(r,{titulo:t.titulo,descripcion:t.descripcion,uidUser:t.uidUser})}catch(r){console.log(r)}})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-create-update-work"]],standalone:!0,features:[Z],decls:2,vars:1,consts:[[1,"content-post-update"],[3,"formulario_work","editWork"]],template:function(r,o){r&1&&(b(0,"div",0)(1,"app-post-update-work",1),ae("formulario_work",function(s){return o.formPostArea(s)}),w()()),r&2&&(z(),Ce("editWork",o.editWork))},dependencies:[fy]})}}return e})();var hy=(()=>{class e{constructor(){this.authService=g(Ke),this.router=g(Me)}logout(){return h(this,null,function*(){(yield this.authService.signOut()).error||(this.authService.logout(),this.router.navigate([""]))})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-navbar"]],standalone:!0,features:[Z],decls:11,vars:0,consts:[[1,"navbar","navbar-expand","bg-body-tertiary"],[1,"container-fluid"],["routerLink","/administrador/home/",1,"navbar-brand"],["src","../../../../../assets/img/icon.png","alt","Logo","width","30","height","30"],["id","navbarSupportedContent",1,"collapse","navbar-collapse","justify-content-end"],["type","button",1,"logout",3,"click"],[1,"material-symbols-outlined"]],template:function(r,o){r&1&&(b(0,"nav",0)(1,"div",1)(2,"a",2),H(3,"img",3),D(4," Gesti\xF3n de Tareas"),w(),b(5,"div",4)(6,"button",5),ae("click",function(){return o.logout()}),b(7,"span",6),D(8," logout "),w(),D(9," Cerrar Sesi\xF3n "),w()()()(),H(10,"router-outlet"))},dependencies:[Qo,Ne],styles:[".navbar[_ngcontent-%COMP%]{position:sticky;top:0;z-index:1020}.navbar-brand[_ngcontent-%COMP%], .logout[_ngcontent-%COMP%]{display:flex;place-items:center;gap:2px}.logout[_ngcontent-%COMP%]{background-color:#fff;padding:5px 10px;border-radius:13px;border:2px solid #f8f4f4}.logout[_ngcontent-%COMP%]:hover{background-color:#ebdddd}"]})}}return e})();var py=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-work-area-post-task"]],standalone:!0,features:[Z],decls:12,vars:0,consts:[["enctype","multipart/form-data","method","post"],[1,"mt-4","mb-2"],["type","text","name","tarea","id","tarea","placeholder","Nueva Tarea ........",1,"form-control","form-control-sm","shadow-none"],["id","message-error",1,"text-muted"],[1,"material-symbols-outlined"],[1,"accion"],["type","submit",1,"btn-event"]],template:function(r,o){r&1&&(b(0,"form",0)(1,"div",1),H(2,"input",2),b(3,"small",3)(4,"span",4),D(5," error "),w(),D(6," Help text"),w()(),b(7,"div",5)(8,"button",6)(9,"span",4),D(10," add "),w(),D(11," Agregar Tarea "),w()()())},styles:[".form-control[_ngcontent-%COMP%]:focus{border:1px solid rgba(156,156,156,.1450980392)}#message-error[_ngcontent-%COMP%]{color:#ff00007c!important;display:flex;align-items:center}#message-error[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:2px}.accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{border:none;width:100%;padding:4px;border-radius:20px;background-color:#f8f4f4;display:flex;justify-content:center;align-items:center}.accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.1rem;margin-right:2px}.accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background-color:#f4ecec}"]})}}return e})();var gy=(()=>{class e{constructor(){this.task_complete=gr(!1),this.task=pr.required(),So(()=>{this.task().estado?this.task_complete.set(!0):this.task_complete.set(!1)},{allowSignalWrites:!0})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-work-area-list-task"]],inputs:{task:[ne.SignalBased,"task"]},standalone:!0,features:[Z],decls:10,vars:6,consts:[[1,"list-group","list-group-flush"],[1,"list-group-item"],[1,"task"],["type","checkbox",1,"form-check-input","shadow-none",3,"value","id"],[1,"form-check-label",3,"for"],[1,"accion"],[1,"delete_task"],[1,"material-symbols-outlined"]],template:function(r,o){r&1&&(b(0,"ul",0)(1,"li",1)(2,"div",2),H(3,"input",3),b(4,"label",4),D(5),w()(),b(6,"div",5)(7,"button",6)(8,"span",7),D(9," delete "),w()()()()()),r&2&&(z(),vr("task-hidden",o.task_complete()),z(2),pu("value",o.task().id),Ce("id",o.task().id),z(),Ce("for",o.task().id),z(),_n(o.task().tarea))},styles:[".list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%]{padding:8px 9px;display:flex;justify-content:space-between;align-items:center}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .task[_ngcontent-%COMP%] .form-check-input[_ngcontent-%COMP%]{margin-right:10px;border-radius:100%}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .task[_ngcontent-%COMP%] .form-check-input[_ngcontent-%COMP%]:checked{background-color:#f4ecec;color:#000;border-color:#f4ecec}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .task[_ngcontent-%COMP%] .form-check-input[_ngcontent-%COMP%] {box-shadow:none!important;border:1px solid rgba(156,156,156,.1450980392)}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] .delete_task[_ngcontent-%COMP%]{display:flex;place-items:center;border-radius:100%;padding:5px;border:none;background-color:#f8f4f4}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] .delete_task[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1rem}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] .delete_task[_ngcontent-%COMP%]:hover{background-color:#f4ecec}.list-group[_ngcontent-%COMP%] .task-hidden[_ngcontent-%COMP%] .form-check-input[_ngcontent-%COMP%]:checked{cursor:no-drop}.list-group[_ngcontent-%COMP%] .task-hidden[_ngcontent-%COMP%] .form-check-label[_ngcontent-%COMP%]{text-decoration:line-through}"],changeDetection:0})}}return e})();var my=(()=>{class e{constructor(){this.supabase_client=g(Jr).supabase}sellstTask(t){return h(this,null,function*(){let{data:r,error:o}=yield this.supabase_client.from("task").select("*").eq("task_id",t).order("id",{ascending:!1});if(o)throw console.error("Error fetching tasks:",o),new Error(o.message);return r})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=E({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var IS=(e,n)=>n.id;function MS(e,n){if(e&1&&H(0,"app-work-area-list-task",8),e&2){let t=n.$implicit;Ce("task",t)}}var vy=(()=>{class e{constructor(){this.tasks=gr([]),this.taskService=g(my),this.router=g(Be),this.route=g(Me),this.workServices=g(Xr)}ngOnInit(){this.router.params.subscribe(t=>{this.getWork(t.id)})}ngOnDestroy(){this.tasks.set([])}getWork(t){return h(this,null,function*(){try{let r=yield this.workServices.gettWork(t);this.sellstTask(t)}catch{this.route.navigate(["administrador/home"])}})}postTask(t){console.log(t)}sellstTask(t){return h(this,null,function*(){try{let r=yield this.taskService.sellstTask(t);this.tasks.set(r)}catch(r){console.error(r)}})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-work-area"]],standalone:!0,features:[Z],decls:14,vars:0,consts:[[1,"content-work-area"],[1,"card"],[1,"card-body"],[1,"text-center"],["routerLink","/administrador/home",1,"arrow"],[1,"material-symbols-outlined"],[1,"card-title","text-center"],[1,"content-task"],[3,"task"]],template:function(r,o){r&1&&(b(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"a",4)(5,"span",5),D(6," chevron_left "),w()()(),H(7,"app-work-area-post-task")(8,"hr"),b(9,"h6",6),D(10,"Lista de Tareas"),w(),b(11,"div",7),Gs(12,MS,1,1,"app-work-area-list-task",8,IS),w()()()()),r&2&&(z(12),qs(o.tasks()))},dependencies:[py,gy,Ne],styles:[".card[_ngcontent-%COMP%]{width:40vh;margin-bottom:20px;box-shadow:5px 10px 15px #9c9c9c25;border:none;border-radius:30px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]{position:absolute;top:2%;left:5%;text-decoration:none;color:#000;background-color:#f8f4f4;border-radius:100%;padding:2px;display:flex;align-items:center;cursor:pointer}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]:hover{background-color:#f4ecec}.card[_ngcontent-%COMP%] .content-task[_ngcontent-%COMP%]{height:100%;max-height:20rem;overflow:auto}.card[_ngcontent-%COMP%] .content-task[_ngcontent-%COMP%]::-webkit-scrollbar{display:none}"]})}}return e})();var yy=[{path:"",pathMatch:"full",redirectTo:"login"},{path:"login",component:sy,canActivate:[Yd]},{path:"register",component:cy,canActivate:[Yd]},{path:"administrador/home",component:hy,children:[{path:"",component:uy},{path:"work/create",component:Qd},{path:"work/:id/edit",component:Qd},{path:":id/work",component:vy}],canActivate:[dy]}];var wy=(e,n)=>{let t=localStorage.getItem("token"),r=e.clone({setHeaders:{Authorization:`Bearer ${t}`}});return n(r)};var _y={providers:[Om(yy),Ug(Bg([wy]))]};var Dy=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-root"]],standalone:!0,features:[Z],decls:1,vars:0,template:function(r,o){r&1&&H(0,"router-outlet")},dependencies:[Qo]})}}return e})();Qg(Dy,_y).catch(e=>console.error(e)); diff --git a/main-WIBJQLKF.js b/main-WIBJQLKF.js deleted file mode 100644 index e8e9445..0000000 --- a/main-WIBJQLKF.js +++ /dev/null @@ -1,13 +0,0 @@ -import{b as Wd,c as Zd,f as Ey,g as Yd}from"./chunk-5PDZ6P5C.js";import{a as b,b as G,d as yt,f as by,g as Cy,h}from"./chunk-RS6LHQUM.js";var Cd=yt(bd=>{"use strict";Object.defineProperty(bd,"__esModule",{value:!0});var Dd=class extends Error{constructor(n){super(n.message),this.name="PostgrestError",this.details=n.details,this.hint=n.hint,this.code=n.code}};bd.default=Dd});var Id=yt(Ki=>{"use strict";var cv=Ki&&Ki.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ki,"__esModule",{value:!0});var pM=cv((Yd(),Cy(Ey))),gM=cv(Cd()),Ed=class{constructor(n){this.shouldThrowOnError=!1,this.method=n.method,this.url=n.url,this.headers=n.headers,this.schema=n.schema,this.body=n.body,this.shouldThrowOnError=n.shouldThrowOnError,this.signal=n.signal,this.isMaybeSingle=n.isMaybeSingle,n.fetch?this.fetch=n.fetch:typeof fetch>"u"?this.fetch=pM.default:this.fetch=fetch}throwOnError(){return this.shouldThrowOnError=!0,this}setHeader(n,t){return this.headers=Object.assign({},this.headers),this.headers[n]=t,this}then(n,t){this.schema===void 0||(["GET","HEAD"].includes(this.method)?this.headers["Accept-Profile"]=this.schema:this.headers["Content-Profile"]=this.schema),this.method!=="GET"&&this.method!=="HEAD"&&(this.headers["Content-Type"]="application/json");let r=this.fetch,i=r(this.url.toString(),{method:this.method,headers:this.headers,body:JSON.stringify(this.body),signal:this.signal}).then(o=>h(this,null,function*(){var s,a,c;let l=null,u=null,d=null,p=o.status,f=o.statusText;if(o.ok){if(this.method!=="HEAD"){let C=yield o.text();C===""||(this.headers.Accept==="text/csv"||this.headers.Accept&&this.headers.Accept.includes("application/vnd.pgrst.plan+text")?u=C:u=JSON.parse(C))}let v=(s=this.headers.Prefer)===null||s===void 0?void 0:s.match(/count=(exact|planned|estimated)/),D=(a=o.headers.get("content-range"))===null||a===void 0?void 0:a.split("/");v&&D&&D.length>1&&(d=parseInt(D[1])),this.isMaybeSingle&&this.method==="GET"&&Array.isArray(u)&&(u.length>1?(l={code:"PGRST116",details:`Results contain ${u.length} rows, application/vnd.pgrst.object+json requires 1 row`,hint:null,message:"JSON object requested, multiple (or no) rows returned"},u=null,d=null,p=406,f="Not Acceptable"):u.length===1?u=u[0]:u=null)}else{let v=yield o.text();try{l=JSON.parse(v),Array.isArray(l)&&o.status===404&&(u=[],l=null,p=200,f="OK")}catch{o.status===404&&v===""?(p=204,f="No Content"):l={message:v}}if(l&&this.isMaybeSingle&&(!((c=l?.details)===null||c===void 0)&&c.includes("0 rows"))&&(l=null,p=200,f="OK"),l&&this.shouldThrowOnError)throw new gM.default(l)}return{error:l,data:u,count:d,status:p,statusText:f}}));return this.shouldThrowOnError||(i=i.catch(o=>{var s,a,c;return{error:{message:`${(s=o?.name)!==null&&s!==void 0?s:"FetchError"}: ${o?.message}`,details:`${(a=o?.stack)!==null&&a!==void 0?a:""}`,hint:"",code:`${(c=o?.code)!==null&&c!==void 0?c:""}`},data:null,count:null,status:0,statusText:""}})),i.then(n,t)}};Ki.default=Ed});var Sd=yt(Ji=>{"use strict";var mM=Ji&&Ji.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ji,"__esModule",{value:!0});var vM=mM(Id()),Md=class extends vM.default{select(n){let t=!1,r=(n??"*").split("").map(i=>/\s/.test(i)&&!t?"":(i==='"'&&(t=!t),i)).join("");return this.url.searchParams.set("select",r),this.headers.Prefer&&(this.headers.Prefer+=","),this.headers.Prefer+="return=representation",this}order(n,{ascending:t=!0,nullsFirst:r,foreignTable:i,referencedTable:o=i}={}){let s=o?`${o}.order`:"order",a=this.url.searchParams.get(s);return this.url.searchParams.set(s,`${a?`${a},`:""}${n}.${t?"asc":"desc"}${r===void 0?"":r?".nullsfirst":".nullslast"}`),this}limit(n,{foreignTable:t,referencedTable:r=t}={}){let i=typeof r>"u"?"limit":`${r}.limit`;return this.url.searchParams.set(i,`${n}`),this}range(n,t,{foreignTable:r,referencedTable:i=r}={}){let o=typeof i>"u"?"offset":`${i}.offset`,s=typeof i>"u"?"limit":`${i}.limit`;return this.url.searchParams.set(o,`${n}`),this.url.searchParams.set(s,`${t-n+1}`),this}abortSignal(n){return this.signal=n,this}single(){return this.headers.Accept="application/vnd.pgrst.object+json",this}maybeSingle(){return this.method==="GET"?this.headers.Accept="application/json":this.headers.Accept="application/vnd.pgrst.object+json",this.isMaybeSingle=!0,this}csv(){return this.headers.Accept="text/csv",this}geojson(){return this.headers.Accept="application/geo+json",this}explain({analyze:n=!1,verbose:t=!1,settings:r=!1,buffers:i=!1,wal:o=!1,format:s="text"}={}){var a;let c=[n?"analyze":null,t?"verbose":null,r?"settings":null,i?"buffers":null,o?"wal":null].filter(Boolean).join("|"),l=(a=this.headers.Accept)!==null&&a!==void 0?a:"application/json";return this.headers.Accept=`application/vnd.pgrst.plan+${s}; for="${l}"; options=${c};`,s==="json"?this:this}rollback(){var n;return((n=this.headers.Prefer)!==null&&n!==void 0?n:"").trim().length>0?this.headers.Prefer+=",tx=rollback":this.headers.Prefer="tx=rollback",this}returns(){return this}};Ji.default=Md});var Ta=yt(Xi=>{"use strict";var yM=Xi&&Xi.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Xi,"__esModule",{value:!0});var wM=yM(Sd()),xd=class extends wM.default{eq(n,t){return this.url.searchParams.append(n,`eq.${t}`),this}neq(n,t){return this.url.searchParams.append(n,`neq.${t}`),this}gt(n,t){return this.url.searchParams.append(n,`gt.${t}`),this}gte(n,t){return this.url.searchParams.append(n,`gte.${t}`),this}lt(n,t){return this.url.searchParams.append(n,`lt.${t}`),this}lte(n,t){return this.url.searchParams.append(n,`lte.${t}`),this}like(n,t){return this.url.searchParams.append(n,`like.${t}`),this}likeAllOf(n,t){return this.url.searchParams.append(n,`like(all).{${t.join(",")}}`),this}likeAnyOf(n,t){return this.url.searchParams.append(n,`like(any).{${t.join(",")}}`),this}ilike(n,t){return this.url.searchParams.append(n,`ilike.${t}`),this}ilikeAllOf(n,t){return this.url.searchParams.append(n,`ilike(all).{${t.join(",")}}`),this}ilikeAnyOf(n,t){return this.url.searchParams.append(n,`ilike(any).{${t.join(",")}}`),this}is(n,t){return this.url.searchParams.append(n,`is.${t}`),this}in(n,t){let r=Array.from(new Set(t)).map(i=>typeof i=="string"&&new RegExp("[,()]").test(i)?`"${i}"`:`${i}`).join(",");return this.url.searchParams.append(n,`in.(${r})`),this}contains(n,t){return typeof t=="string"?this.url.searchParams.append(n,`cs.${t}`):Array.isArray(t)?this.url.searchParams.append(n,`cs.{${t.join(",")}}`):this.url.searchParams.append(n,`cs.${JSON.stringify(t)}`),this}containedBy(n,t){return typeof t=="string"?this.url.searchParams.append(n,`cd.${t}`):Array.isArray(t)?this.url.searchParams.append(n,`cd.{${t.join(",")}}`):this.url.searchParams.append(n,`cd.${JSON.stringify(t)}`),this}rangeGt(n,t){return this.url.searchParams.append(n,`sr.${t}`),this}rangeGte(n,t){return this.url.searchParams.append(n,`nxl.${t}`),this}rangeLt(n,t){return this.url.searchParams.append(n,`sl.${t}`),this}rangeLte(n,t){return this.url.searchParams.append(n,`nxr.${t}`),this}rangeAdjacent(n,t){return this.url.searchParams.append(n,`adj.${t}`),this}overlaps(n,t){return typeof t=="string"?this.url.searchParams.append(n,`ov.${t}`):this.url.searchParams.append(n,`ov.{${t.join(",")}}`),this}textSearch(n,t,{config:r,type:i}={}){let o="";i==="plain"?o="pl":i==="phrase"?o="ph":i==="websearch"&&(o="w");let s=r===void 0?"":`(${r})`;return this.url.searchParams.append(n,`${o}fts${s}.${t}`),this}match(n){return Object.entries(n).forEach(([t,r])=>{this.url.searchParams.append(t,`eq.${r}`)}),this}not(n,t,r){return this.url.searchParams.append(n,`not.${t}.${r}`),this}or(n,{foreignTable:t,referencedTable:r=t}={}){let i=r?`${r}.or`:"or";return this.url.searchParams.append(i,`(${n})`),this}filter(n,t,r){return this.url.searchParams.append(n,`${t}.${r}`),this}};Xi.default=xd});var Ad=yt(to=>{"use strict";var _M=to&&to.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(to,"__esModule",{value:!0});var eo=_M(Ta()),Td=class{constructor(n,{headers:t={},schema:r,fetch:i}){this.url=n,this.headers=t,this.schema=r,this.fetch=i}select(n,{head:t=!1,count:r}={}){let i=t?"HEAD":"GET",o=!1,s=(n??"*").split("").map(a=>/\s/.test(a)&&!o?"":(a==='"'&&(o=!o),a)).join("");return this.url.searchParams.set("select",s),r&&(this.headers.Prefer=`count=${r}`),new eo.default({method:i,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch,allowEmpty:!1})}insert(n,{count:t,defaultToNull:r=!0}={}){let i="POST",o=[];if(this.headers.Prefer&&o.push(this.headers.Prefer),t&&o.push(`count=${t}`),r||o.push("missing=default"),this.headers.Prefer=o.join(","),Array.isArray(n)){let s=n.reduce((a,c)=>a.concat(Object.keys(c)),[]);if(s.length>0){let a=[...new Set(s)].map(c=>`"${c}"`);this.url.searchParams.set("columns",a.join(","))}}return new eo.default({method:i,url:this.url,headers:this.headers,schema:this.schema,body:n,fetch:this.fetch,allowEmpty:!1})}upsert(n,{onConflict:t,ignoreDuplicates:r=!1,count:i,defaultToNull:o=!0}={}){let s="POST",a=[`resolution=${r?"ignore":"merge"}-duplicates`];if(t!==void 0&&this.url.searchParams.set("on_conflict",t),this.headers.Prefer&&a.push(this.headers.Prefer),i&&a.push(`count=${i}`),o||a.push("missing=default"),this.headers.Prefer=a.join(","),Array.isArray(n)){let c=n.reduce((l,u)=>l.concat(Object.keys(u)),[]);if(c.length>0){let l=[...new Set(c)].map(u=>`"${u}"`);this.url.searchParams.set("columns",l.join(","))}}return new eo.default({method:s,url:this.url,headers:this.headers,schema:this.schema,body:n,fetch:this.fetch,allowEmpty:!1})}update(n,{count:t}={}){let r="PATCH",i=[];return this.headers.Prefer&&i.push(this.headers.Prefer),t&&i.push(`count=${t}`),this.headers.Prefer=i.join(","),new eo.default({method:r,url:this.url,headers:this.headers,schema:this.schema,body:n,fetch:this.fetch,allowEmpty:!1})}delete({count:n}={}){let t="DELETE",r=[];return n&&r.push(`count=${n}`),this.headers.Prefer&&r.unshift(this.headers.Prefer),this.headers.Prefer=r.join(","),new eo.default({method:t,url:this.url,headers:this.headers,schema:this.schema,fetch:this.fetch,allowEmpty:!1})}};to.default=Td});var lv=yt(Aa=>{"use strict";Object.defineProperty(Aa,"__esModule",{value:!0});Aa.version=void 0;Aa.version="0.0.0-automated"});var uv=yt(Oa=>{"use strict";Object.defineProperty(Oa,"__esModule",{value:!0});Oa.DEFAULT_HEADERS=void 0;var DM=lv();Oa.DEFAULT_HEADERS={"X-Client-Info":`postgrest-js/${DM.version}`}});var fv=yt(no=>{"use strict";var dv=no&&no.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(no,"__esModule",{value:!0});var bM=dv(Ad()),CM=dv(Ta()),EM=uv(),Od=class e{constructor(n,{headers:t={},schema:r,fetch:i}={}){this.url=n,this.headers=Object.assign(Object.assign({},EM.DEFAULT_HEADERS),t),this.schemaName=r,this.fetch=i}from(n){let t=new URL(`${this.url}/${n}`);return new bM.default(t,{headers:Object.assign({},this.headers),schema:this.schemaName,fetch:this.fetch})}schema(n){return new e(this.url,{headers:this.headers,schema:n,fetch:this.fetch})}rpc(n,t={},{head:r=!1,get:i=!1,count:o}={}){let s,a=new URL(`${this.url}/rpc/${n}`),c;r||i?(s=r?"HEAD":"GET",Object.entries(t).filter(([u,d])=>d!==void 0).map(([u,d])=>[u,Array.isArray(d)?`{${d.join(",")}}`:`${d}`]).forEach(([u,d])=>{a.searchParams.append(u,d)})):(s="POST",c=t);let l=Object.assign({},this.headers);return o&&(l.Prefer=`count=${o}`),new CM.default({method:s,url:a,headers:l,schema:this.schemaName,body:c,fetch:this.fetch,allowEmpty:!1})}};no.default=Od});var wv=yt(we=>{"use strict";var Lr=we&&we.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(we,"__esModule",{value:!0});we.PostgrestError=we.PostgrestBuilder=we.PostgrestTransformBuilder=we.PostgrestFilterBuilder=we.PostgrestQueryBuilder=we.PostgrestClient=void 0;var hv=Lr(fv());we.PostgrestClient=hv.default;var pv=Lr(Ad());we.PostgrestQueryBuilder=pv.default;var gv=Lr(Ta());we.PostgrestFilterBuilder=gv.default;var mv=Lr(Sd());we.PostgrestTransformBuilder=mv.default;var vv=Lr(Id());we.PostgrestBuilder=vv.default;var yv=Lr(Cd());we.PostgrestError=yv.default;we.default={PostgrestClient:hv.default,PostgrestQueryBuilder:pv.default,PostgrestFilterBuilder:gv.default,PostgrestTransformBuilder:mv.default,PostgrestBuilder:vv.default,PostgrestError:yv.default}});function Iy(e,n){return Object.is(e,n)}var fe=null,Yr=!1,go=1,xt=Symbol("SIGNAL");function V(e){let n=fe;return fe=e,n}function My(){return Yr}var mo={version:0,lastCleanEpoch:0,dirty:!1,producerNode:void 0,producerLastReadVersion:void 0,producerIndexOfThis:void 0,nextProducerIndex:0,liveConsumerNode:void 0,liveConsumerIndexOfThis:void 0,consumerAllowSignalWrites:!1,consumerIsAlwaysLive:!1,producerMustRecompute:()=>!1,producerRecomputeValue:()=>{},consumerMarkedDirty:()=>{},consumerOnSignalRead:()=>{}};function tc(e){if(Yr)throw new Error("");if(fe===null)return;fe.consumerOnSignalRead(e);let n=fe.nextProducerIndex++;if($n(fe),ne.nextProducerIndex;)e.producerNode.pop(),e.producerLastReadVersion.pop(),e.producerIndexOfThis.pop()}}function vo(e){$n(e);for(let n=0;n0}function $n(e){e.producerNode??=[],e.producerIndexOfThis??=[],e.producerLastReadVersion??=[]}function ef(e){e.liveConsumerNode??=[],e.liveConsumerIndexOfThis??=[]}function Ty(){throw new Error}var tf=Ty;function nf(){tf()}function rf(e){tf=e}var Ay=null;function of(e){let n=Object.create(oc);n.value=e;let t=()=>(tc(n),n.value);return t[xt]=n,t}function wo(e,n){Kd()||nf(),e.equal(e.value,n)||(e.value=n,Oy(e))}function sf(e,n){Kd()||nf(),wo(e,n(e.value))}var oc=G(b({},mo),{equal:Iy,value:void 0});function Oy(e){e.version++,Sy(),Qd(e),Ay?.()}function af(e,n,t){let r=Object.create(Ny);t&&(r.consumerAllowSignalWrites=!0),r.fn=e,r.schedule=n;let i=c=>{r.cleanupFn=c};function o(c){return c.fn===null&&c.schedule===null}function s(c){o(c)||(ic(c),c.cleanupFn(),c.fn=null,c.schedule=null,c.cleanupFn=ec)}let a=()=>{if(r.fn===null)return;if(My())throw new Error("Schedulers cannot synchronously execute watches while scheduling.");if(r.dirty=!1,r.hasRun&&!vo(r))return;r.hasRun=!0;let c=nc(r);try{r.cleanupFn(),r.cleanupFn=ec,r.fn(i)}finally{rc(r,c)}};return r.ref={notify:()=>Jd(r),run:a,cleanup:()=>r.cleanupFn(),destroy:()=>s(r),[xt]:r},r.ref}var ec=()=>{},Ny=G(b({},mo),{consumerIsAlwaysLive:!0,consumerAllowSignalWrites:!1,consumerMarkedDirty:e=>{e.schedule!==null&&e.schedule(e.ref)},hasRun:!1,cleanupFn:ec});function A(e){return typeof e=="function"}function Un(e){let t=e(r=>{Error.call(r),r.stack=new Error().stack});return t.prototype=Object.create(Error.prototype),t.prototype.constructor=t,t}var _o=Un(e=>function(t){e(this),this.message=t?`${t.length} errors occurred during unsubscription: -${t.map((r,i)=>`${i+1}) ${r.toString()}`).join(` - `)}`:"",this.name="UnsubscriptionError",this.errors=t});function Kr(e,n){if(e){let t=e.indexOf(n);0<=t&&e.splice(t,1)}}var le=class e{constructor(n){this.initialTeardown=n,this.closed=!1,this._parentage=null,this._finalizers=null}unsubscribe(){let n;if(!this.closed){this.closed=!0;let{_parentage:t}=this;if(t)if(this._parentage=null,Array.isArray(t))for(let o of t)o.remove(this);else t.remove(this);let{initialTeardown:r}=this;if(A(r))try{r()}catch(o){n=o instanceof _o?o.errors:[o]}let{_finalizers:i}=this;if(i){this._finalizers=null;for(let o of i)try{cf(o)}catch(s){n=n??[],s instanceof _o?n=[...n,...s.errors]:n.push(s)}}if(n)throw new _o(n)}}add(n){var t;if(n&&n!==this)if(this.closed)cf(n);else{if(n instanceof e){if(n.closed||n._hasParent(this))return;n._addParent(this)}(this._finalizers=(t=this._finalizers)!==null&&t!==void 0?t:[]).push(n)}}_hasParent(n){let{_parentage:t}=this;return t===n||Array.isArray(t)&&t.includes(n)}_addParent(n){let{_parentage:t}=this;this._parentage=Array.isArray(t)?(t.push(n),t):t?[t,n]:n}_removeParent(n){let{_parentage:t}=this;t===n?this._parentage=null:Array.isArray(t)&&Kr(t,n)}remove(n){let{_finalizers:t}=this;t&&Kr(t,n),n instanceof e&&n._removeParent(this)}};le.EMPTY=(()=>{let e=new le;return e.closed=!0,e})();var sc=le.EMPTY;function Do(e){return e instanceof le||e&&"closed"in e&&A(e.remove)&&A(e.add)&&A(e.unsubscribe)}function cf(e){A(e)?e():e.unsubscribe()}var Ke={onUnhandledError:null,onStoppedNotification:null,Promise:void 0,useDeprecatedSynchronousErrorHandling:!1,useDeprecatedNextContext:!1};var Bn={setTimeout(e,n,...t){let{delegate:r}=Bn;return r?.setTimeout?r.setTimeout(e,n,...t):setTimeout(e,n,...t)},clearTimeout(e){let{delegate:n}=Bn;return(n?.clearTimeout||clearTimeout)(e)},delegate:void 0};function bo(e){Bn.setTimeout(()=>{let{onUnhandledError:n}=Ke;if(n)n(e);else throw e})}function Jr(){}var lf=ac("C",void 0,void 0);function uf(e){return ac("E",void 0,e)}function df(e){return ac("N",e,void 0)}function ac(e,n,t){return{kind:e,value:n,error:t}}var Jt=null;function Hn(e){if(Ke.useDeprecatedSynchronousErrorHandling){let n=!Jt;if(n&&(Jt={errorThrown:!1,error:null}),e(),n){let{errorThrown:t,error:r}=Jt;if(Jt=null,t)throw r}}else e()}function ff(e){Ke.useDeprecatedSynchronousErrorHandling&&Jt&&(Jt.errorThrown=!0,Jt.error=e)}var Xt=class extends le{constructor(n){super(),this.isStopped=!1,n?(this.destination=n,Do(n)&&n.add(this)):this.destination=ky}static create(n,t,r){return new zn(n,t,r)}next(n){this.isStopped?lc(df(n),this):this._next(n)}error(n){this.isStopped?lc(uf(n),this):(this.isStopped=!0,this._error(n))}complete(){this.isStopped?lc(lf,this):(this.isStopped=!0,this._complete())}unsubscribe(){this.closed||(this.isStopped=!0,super.unsubscribe(),this.destination=null)}_next(n){this.destination.next(n)}_error(n){try{this.destination.error(n)}finally{this.unsubscribe()}}_complete(){try{this.destination.complete()}finally{this.unsubscribe()}}},Ry=Function.prototype.bind;function cc(e,n){return Ry.call(e,n)}var uc=class{constructor(n){this.partialObserver=n}next(n){let{partialObserver:t}=this;if(t.next)try{t.next(n)}catch(r){Co(r)}}error(n){let{partialObserver:t}=this;if(t.error)try{t.error(n)}catch(r){Co(r)}else Co(n)}complete(){let{partialObserver:n}=this;if(n.complete)try{n.complete()}catch(t){Co(t)}}},zn=class extends Xt{constructor(n,t,r){super();let i;if(A(n)||!n)i={next:n??void 0,error:t??void 0,complete:r??void 0};else{let o;this&&Ke.useDeprecatedNextContext?(o=Object.create(n),o.unsubscribe=()=>this.unsubscribe(),i={next:n.next&&cc(n.next,o),error:n.error&&cc(n.error,o),complete:n.complete&&cc(n.complete,o)}):i=n}this.destination=new uc(i)}};function Co(e){Ke.useDeprecatedSynchronousErrorHandling?ff(e):bo(e)}function Py(e){throw e}function lc(e,n){let{onStoppedNotification:t}=Ke;t&&Bn.setTimeout(()=>t(e,n))}var ky={closed:!0,next:Jr,error:Py,complete:Jr};var Gn=typeof Symbol=="function"&&Symbol.observable||"@@observable";function Pe(e){return e}function dc(...e){return fc(e)}function fc(e){return e.length===0?Pe:e.length===1?e[0]:function(t){return e.reduce((r,i)=>i(r),t)}}var z=(()=>{class e{constructor(t){t&&(this._subscribe=t)}lift(t){let r=new e;return r.source=this,r.operator=t,r}subscribe(t,r,i){let o=Ly(t)?t:new zn(t,r,i);return Hn(()=>{let{operator:s,source:a}=this;o.add(s?s.call(o,a):a?this._subscribe(o):this._trySubscribe(o))}),o}_trySubscribe(t){try{return this._subscribe(t)}catch(r){t.error(r)}}forEach(t,r){return r=hf(r),new r((i,o)=>{let s=new zn({next:a=>{try{t(a)}catch(c){o(c),s.unsubscribe()}},error:o,complete:i});this.subscribe(s)})}_subscribe(t){var r;return(r=this.source)===null||r===void 0?void 0:r.subscribe(t)}[Gn](){return this}pipe(...t){return fc(t)(this)}toPromise(t){return t=hf(t),new t((r,i)=>{let o;this.subscribe(s=>o=s,s=>i(s),()=>r(o))})}}return e.create=n=>new e(n),e})();function hf(e){var n;return(n=e??Ke.Promise)!==null&&n!==void 0?n:Promise}function Fy(e){return e&&A(e.next)&&A(e.error)&&A(e.complete)}function Ly(e){return e&&e instanceof Xt||Fy(e)&&Do(e)}function hc(e){return A(e?.lift)}function H(e){return n=>{if(hc(n))return n.lift(function(t){try{return e(t,this)}catch(r){this.error(r)}});throw new TypeError("Unable to lift unknown Observable type")}}function $(e,n,t,r,i){return new pc(e,n,t,r,i)}var pc=class extends Xt{constructor(n,t,r,i,o,s){super(n),this.onFinalize=o,this.shouldUnsubscribe=s,this._next=t?function(a){try{t(a)}catch(c){n.error(c)}}:super._next,this._error=i?function(a){try{i(a)}catch(c){n.error(c)}finally{this.unsubscribe()}}:super._error,this._complete=r?function(){try{r()}catch(a){n.error(a)}finally{this.unsubscribe()}}:super._complete}unsubscribe(){var n;if(!this.shouldUnsubscribe||this.shouldUnsubscribe()){let{closed:t}=this;super.unsubscribe(),!t&&((n=this.onFinalize)===null||n===void 0||n.call(this))}}};function qn(){return H((e,n)=>{let t=null;e._refCount++;let r=$(n,void 0,void 0,void 0,()=>{if(!e||e._refCount<=0||0<--e._refCount){t=null;return}let i=e._connection,o=t;t=null,i&&(!o||i===o)&&i.unsubscribe(),n.unsubscribe()});e.subscribe(r),r.closed||(t=e.connect())})}var Wn=class extends z{constructor(n,t){super(),this.source=n,this.subjectFactory=t,this._subject=null,this._refCount=0,this._connection=null,hc(n)&&(this.lift=n.lift)}_subscribe(n){return this.getSubject().subscribe(n)}getSubject(){let n=this._subject;return(!n||n.isStopped)&&(this._subject=this.subjectFactory()),this._subject}_teardown(){this._refCount=0;let{_connection:n}=this;this._subject=this._connection=null,n?.unsubscribe()}connect(){let n=this._connection;if(!n){n=this._connection=new le;let t=this.getSubject();n.add(this.source.subscribe($(t,void 0,()=>{this._teardown(),t.complete()},r=>{this._teardown(),t.error(r)},()=>this._teardown()))),n.closed&&(this._connection=null,n=le.EMPTY)}return n}refCount(){return qn()(this)}};var pf=Un(e=>function(){e(this),this.name="ObjectUnsubscribedError",this.message="object unsubscribed"});var _e=(()=>{class e extends z{constructor(){super(),this.closed=!1,this.currentObservers=null,this.observers=[],this.isStopped=!1,this.hasError=!1,this.thrownError=null}lift(t){let r=new Eo(this,this);return r.operator=t,r}_throwIfClosed(){if(this.closed)throw new pf}next(t){Hn(()=>{if(this._throwIfClosed(),!this.isStopped){this.currentObservers||(this.currentObservers=Array.from(this.observers));for(let r of this.currentObservers)r.next(t)}})}error(t){Hn(()=>{if(this._throwIfClosed(),!this.isStopped){this.hasError=this.isStopped=!0,this.thrownError=t;let{observers:r}=this;for(;r.length;)r.shift().error(t)}})}complete(){Hn(()=>{if(this._throwIfClosed(),!this.isStopped){this.isStopped=!0;let{observers:t}=this;for(;t.length;)t.shift().complete()}})}unsubscribe(){this.isStopped=this.closed=!0,this.observers=this.currentObservers=null}get observed(){var t;return((t=this.observers)===null||t===void 0?void 0:t.length)>0}_trySubscribe(t){return this._throwIfClosed(),super._trySubscribe(t)}_subscribe(t){return this._throwIfClosed(),this._checkFinalizedStatuses(t),this._innerSubscribe(t)}_innerSubscribe(t){let{hasError:r,isStopped:i,observers:o}=this;return r||i?sc:(this.currentObservers=null,o.push(t),new le(()=>{this.currentObservers=null,Kr(o,t)}))}_checkFinalizedStatuses(t){let{hasError:r,thrownError:i,isStopped:o}=this;r?t.error(i):o&&t.complete()}asObservable(){let t=new z;return t.source=this,t}}return e.create=(n,t)=>new Eo(n,t),e})(),Eo=class extends _e{constructor(n,t){super(),this.destination=n,this.source=t}next(n){var t,r;(r=(t=this.destination)===null||t===void 0?void 0:t.next)===null||r===void 0||r.call(t,n)}error(n){var t,r;(r=(t=this.destination)===null||t===void 0?void 0:t.error)===null||r===void 0||r.call(t,n)}complete(){var n,t;(t=(n=this.destination)===null||n===void 0?void 0:n.complete)===null||t===void 0||t.call(n)}_subscribe(n){var t,r;return(r=(t=this.source)===null||t===void 0?void 0:t.subscribe(n))!==null&&r!==void 0?r:sc}};var ue=class extends _e{constructor(n){super(),this._value=n}get value(){return this.getValue()}_subscribe(n){let t=super._subscribe(n);return!t.closed&&n.next(this._value),t}getValue(){let{hasError:n,thrownError:t,_value:r}=this;if(n)throw t;return this._throwIfClosed(),r}next(n){super.next(this._value=n)}};var ke=new z(e=>e.complete());function gf(e){return e&&A(e.schedule)}function mf(e){return e[e.length-1]}function Io(e){return A(mf(e))?e.pop():void 0}function Tt(e){return gf(mf(e))?e.pop():void 0}function yf(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})}function vf(e){var n=typeof Symbol=="function"&&Symbol.iterator,t=n&&e[n],r=0;if(t)return t.call(e);if(e&&typeof e.length=="number")return{next:function(){return e&&r>=e.length&&(e=void 0),{value:e&&e[r++],done:!e}}};throw new TypeError(n?"Object is not iterable.":"Symbol.iterator is not defined.")}function en(e){return this instanceof en?(this.v=e,this):new en(e)}function wf(e,n,t){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=t.apply(e,n||[]),i,o=[];return i=Object.create((typeof AsyncIterator=="function"?AsyncIterator:Object).prototype),a("next"),a("throw"),a("return",s),i[Symbol.asyncIterator]=function(){return this},i;function s(f){return function(w){return Promise.resolve(w).then(f,d)}}function a(f,w){r[f]&&(i[f]=function(v){return new Promise(function(D,C){o.push([f,v,D,C])>1||c(f,v)})},w&&(i[f]=w(i[f])))}function c(f,w){try{l(r[f](w))}catch(v){p(o[0][3],v)}}function l(f){f.value instanceof en?Promise.resolve(f.value.v).then(u,d):p(o[0][2],f)}function u(f){c("next",f)}function d(f){c("throw",f)}function p(f,w){f(w),o.shift(),o.length&&c(o[0][0],o[0][1])}}function _f(e){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var n=e[Symbol.asyncIterator],t;return n?n.call(e):(e=typeof vf=="function"?vf(e):e[Symbol.iterator](),t={},r("next"),r("throw"),r("return"),t[Symbol.asyncIterator]=function(){return this},t);function r(o){t[o]=e[o]&&function(s){return new Promise(function(a,c){s=e[o](s),i(a,c,s.done,s.value)})}}function i(o,s,a,c){Promise.resolve(c).then(function(l){o({value:l,done:a})},s)}}var Mo=e=>e&&typeof e.length=="number"&&typeof e!="function";function So(e){return A(e?.then)}function xo(e){return A(e[Gn])}function To(e){return Symbol.asyncIterator&&A(e?.[Symbol.asyncIterator])}function Ao(e){return new TypeError(`You provided ${e!==null&&typeof e=="object"?"an invalid object":`'${e}'`} where a stream was expected. You can provide an Observable, Promise, ReadableStream, Array, AsyncIterable, or Iterable.`)}function jy(){return typeof Symbol!="function"||!Symbol.iterator?"@@iterator":Symbol.iterator}var Oo=jy();function No(e){return A(e?.[Oo])}function Ro(e){return wf(this,arguments,function*(){let t=e.getReader();try{for(;;){let{value:r,done:i}=yield en(t.read());if(i)return yield en(void 0);yield yield en(r)}}finally{t.releaseLock()}})}function Po(e){return A(e?.getReader)}function oe(e){if(e instanceof z)return e;if(e!=null){if(xo(e))return Vy(e);if(Mo(e))return $y(e);if(So(e))return Uy(e);if(To(e))return Df(e);if(No(e))return By(e);if(Po(e))return Hy(e)}throw Ao(e)}function Vy(e){return new z(n=>{let t=e[Gn]();if(A(t.subscribe))return t.subscribe(n);throw new TypeError("Provided object does not correctly implement Symbol.observable")})}function $y(e){return new z(n=>{for(let t=0;t{e.then(t=>{n.closed||(n.next(t),n.complete())},t=>n.error(t)).then(null,bo)})}function By(e){return new z(n=>{for(let t of e)if(n.next(t),n.closed)return;n.complete()})}function Df(e){return new z(n=>{zy(e,n).catch(t=>n.error(t))})}function Hy(e){return Df(Ro(e))}function zy(e,n){var t,r,i,o;return yf(this,void 0,void 0,function*(){try{for(t=_f(e);r=yield t.next(),!r.done;){let s=r.value;if(n.next(s),n.closed)return}}catch(s){i={error:s}}finally{try{r&&!r.done&&(o=t.return)&&(yield o.call(t))}finally{if(i)throw i.error}}n.complete()})}function Se(e,n,t,r=0,i=!1){let o=n.schedule(function(){t(),i?e.add(this.schedule(null,r)):this.unsubscribe()},r);if(e.add(o),!i)return o}function ko(e,n=0){return H((t,r)=>{t.subscribe($(r,i=>Se(r,e,()=>r.next(i),n),()=>Se(r,e,()=>r.complete(),n),i=>Se(r,e,()=>r.error(i),n)))})}function Fo(e,n=0){return H((t,r)=>{r.add(e.schedule(()=>t.subscribe(r),n))})}function bf(e,n){return oe(e).pipe(Fo(n),ko(n))}function Cf(e,n){return oe(e).pipe(Fo(n),ko(n))}function Ef(e,n){return new z(t=>{let r=0;return n.schedule(function(){r===e.length?t.complete():(t.next(e[r++]),t.closed||this.schedule())})})}function If(e,n){return new z(t=>{let r;return Se(t,n,()=>{r=e[Oo](),Se(t,n,()=>{let i,o;try{({value:i,done:o}=r.next())}catch(s){t.error(s);return}o?t.complete():t.next(i)},0,!0)}),()=>A(r?.return)&&r.return()})}function Lo(e,n){if(!e)throw new Error("Iterable cannot be null");return new z(t=>{Se(t,n,()=>{let r=e[Symbol.asyncIterator]();Se(t,n,()=>{r.next().then(i=>{i.done?t.complete():t.next(i.value)})},0,!0)})})}function Mf(e,n){return Lo(Ro(e),n)}function Sf(e,n){if(e!=null){if(xo(e))return bf(e,n);if(Mo(e))return Ef(e,n);if(So(e))return Cf(e,n);if(To(e))return Lo(e,n);if(No(e))return If(e,n);if(Po(e))return Mf(e,n)}throw Ao(e)}function te(e,n){return n?Sf(e,n):oe(e)}function x(...e){let n=Tt(e);return te(e,n)}function Zn(e,n){let t=A(e)?e:()=>e,r=i=>i.error(t());return new z(n?i=>n.schedule(r,0,i):r)}function gc(e){return!!e&&(e instanceof z||A(e.lift)&&A(e.subscribe))}var wt=Un(e=>function(){e(this),this.name="EmptyError",this.message="no elements in sequence"});function N(e,n){return H((t,r)=>{let i=0;t.subscribe($(r,o=>{r.next(e.call(n,o,i++))}))})}var{isArray:Gy}=Array;function qy(e,n){return Gy(n)?e(...n):e(n)}function jo(e){return N(n=>qy(e,n))}var{isArray:Wy}=Array,{getPrototypeOf:Zy,prototype:Yy,keys:Qy}=Object;function Vo(e){if(e.length===1){let n=e[0];if(Wy(n))return{args:n,keys:null};if(Ky(n)){let t=Qy(n);return{args:t.map(r=>n[r]),keys:t}}}return{args:e,keys:null}}function Ky(e){return e&&typeof e=="object"&&Zy(e)===Yy}function $o(e,n){return e.reduce((t,r,i)=>(t[r]=n[i],t),{})}function Uo(...e){let n=Tt(e),t=Io(e),{args:r,keys:i}=Vo(e);if(r.length===0)return te([],n);let o=new z(Jy(r,n,i?s=>$o(i,s):Pe));return t?o.pipe(jo(t)):o}function Jy(e,n,t=Pe){return r=>{xf(n,()=>{let{length:i}=e,o=new Array(i),s=i,a=i;for(let c=0;c{let l=te(e[c],n),u=!1;l.subscribe($(r,d=>{o[c]=d,u||(u=!0,a--),a||r.next(t(o.slice()))},()=>{--s||r.complete()}))},r)},r)}}function xf(e,n,t){e?Se(t,e,n):n()}function Tf(e,n,t,r,i,o,s,a){let c=[],l=0,u=0,d=!1,p=()=>{d&&!c.length&&!l&&n.complete()},f=v=>l{o&&n.next(v),l++;let D=!1;oe(t(v,u++)).subscribe($(n,C=>{i?.(C),o?f(C):n.next(C)},()=>{D=!0},void 0,()=>{if(D)try{for(l--;c.length&&lw(C)):w(C)}p()}catch(C){n.error(C)}}))};return e.subscribe($(n,f,()=>{d=!0,p()})),()=>{a?.()}}function de(e,n,t=1/0){return A(n)?de((r,i)=>N((o,s)=>n(r,o,i,s))(oe(e(r,i))),t):(typeof n=="number"&&(t=n),H((r,i)=>Tf(r,i,e,t)))}function mc(e=1/0){return de(Pe,e)}function Af(){return mc(1)}function Yn(...e){return Af()(te(e,Tt(e)))}function Bo(e){return new z(n=>{oe(e()).subscribe(n)})}function vc(...e){let n=Io(e),{args:t,keys:r}=Vo(e),i=new z(o=>{let{length:s}=t;if(!s){o.complete();return}let a=new Array(s),c=s,l=s;for(let u=0;u{d||(d=!0,l--),a[u]=p},()=>c--,void 0,()=>{(!c||!d)&&(l||o.next(r?$o(r,a):a),o.complete())}))}});return n?i.pipe(jo(n)):i}function Fe(e,n){return H((t,r)=>{let i=0;t.subscribe($(r,o=>e.call(n,o,i++)&&r.next(o)))})}function At(e){return H((n,t)=>{let r=null,i=!1,o;r=n.subscribe($(t,void 0,void 0,s=>{o=oe(e(s,At(e)(n))),r?(r.unsubscribe(),r=null,o.subscribe(t)):i=!0})),i&&(r.unsubscribe(),r=null,o.subscribe(t))})}function Of(e,n,t,r,i){return(o,s)=>{let a=t,c=n,l=0;o.subscribe($(s,u=>{let d=l++;c=a?e(c,u,d):(a=!0,u),r&&s.next(c)},i&&(()=>{a&&s.next(c),s.complete()})))}}function Ot(e,n){return A(n)?de(e,n,1):de(e,1)}function Nt(e){return H((n,t)=>{let r=!1;n.subscribe($(t,i=>{r=!0,t.next(i)},()=>{r||t.next(e),t.complete()}))})}function _t(e){return e<=0?()=>ke:H((n,t)=>{let r=0;n.subscribe($(t,i=>{++r<=e&&(t.next(i),e<=r&&t.complete())}))})}function yc(e){return N(()=>e)}function Ho(e=Xy){return H((n,t)=>{let r=!1;n.subscribe($(t,i=>{r=!0,t.next(i)},()=>r?t.complete():t.error(e())))})}function Xy(){return new wt}function tn(e){return H((n,t)=>{try{n.subscribe(t)}finally{t.add(e)}})}function lt(e,n){let t=arguments.length>=2;return r=>r.pipe(e?Fe((i,o)=>e(i,o,r)):Pe,_t(1),t?Nt(n):Ho(()=>new wt))}function Qn(e){return e<=0?()=>ke:H((n,t)=>{let r=[];n.subscribe($(t,i=>{r.push(i),e{for(let i of r)t.next(i);t.complete()},void 0,()=>{r=null}))})}function wc(e,n){let t=arguments.length>=2;return r=>r.pipe(e?Fe((i,o)=>e(i,o,r)):Pe,Qn(1),t?Nt(n):Ho(()=>new wt))}function _c(e,n){return H(Of(e,n,arguments.length>=2,!0))}function Dc(...e){let n=Tt(e);return H((t,r)=>{(n?Yn(e,t,n):Yn(e,t)).subscribe(r)})}function Le(e,n){return H((t,r)=>{let i=null,o=0,s=!1,a=()=>s&&!i&&r.complete();t.subscribe($(r,c=>{i?.unsubscribe();let l=0,u=o++;oe(e(c,u)).subscribe(i=$(r,d=>r.next(n?n(c,d,u,l++):d),()=>{i=null,a()}))},()=>{s=!0,a()}))})}function bc(e){return H((n,t)=>{oe(e).subscribe($(t,()=>t.complete(),Jr)),!t.closed&&n.subscribe(t)})}function he(e,n,t){let r=A(e)||n||t?{next:e,error:n,complete:t}:e;return r?H((i,o)=>{var s;(s=r.subscribe)===null||s===void 0||s.call(r);let a=!0;i.subscribe($(o,c=>{var l;(l=r.next)===null||l===void 0||l.call(r,c),o.next(c)},()=>{var c;a=!1,(c=r.complete)===null||c===void 0||c.call(r),o.complete()},c=>{var l;a=!1,(l=r.error)===null||l===void 0||l.call(r,c),o.error(c)},()=>{var c,l;a&&((c=r.unsubscribe)===null||c===void 0||c.call(r)),(l=r.finalize)===null||l===void 0||l.call(r)}))}):Pe}var gh="https://g.co/ng/security#xss",E=class extends Error{constructor(n,t){super(ys(n,t)),this.code=n}};function ys(e,n){return`${`NG0${Math.abs(e)}`}${n?": "+n:""}`}var mh=Symbol("InputSignalNode#UNSET"),ew=G(b({},oc),{transformFn:void 0,applyValueToInputSignal(e,n){wo(e,n)}});function vh(e,n){let t=Object.create(ew);t.value=e,t.transformFn=n?.transform;function r(){if(tc(t),t.value===mh)throw new E(-950,!1);return t.value}return r[xt]=t,r}function ws(e){return{toString:e}.toString()}var nn=globalThis;function Y(e){for(let n in e)if(e[n]===Y)return n;throw Error("Could not find renamed property on target object.")}function tw(e,n){for(let t in n)n.hasOwnProperty(t)&&!e.hasOwnProperty(t)&&(e[t]=n[t])}function xe(e){if(typeof e=="string")return e;if(Array.isArray(e))return"["+e.map(xe).join(", ")+"]";if(e==null)return""+e;if(e.overriddenName)return`${e.overriddenName}`;if(e.name)return`${e.name}`;let n=e.toString();if(n==null)return""+n;let t=n.indexOf(` -`);return t===-1?n:n.substring(0,t)}function Nf(e,n){return e==null||e===""?n===null?"":n:n==null||n===""?e:e+" "+n}var nw=Y({__forward_ref__:Y});function dr(e){return e.__forward_ref__=dr,e.toString=function(){return xe(this())},e}function Ee(e){return yh(e)?e():e}function yh(e){return typeof e=="function"&&e.hasOwnProperty(nw)&&e.__forward_ref__===dr}function I(e){return{token:e.token,providedIn:e.providedIn||null,factory:e.factory,value:void 0}}function hn(e){return{providers:e.providers||[],imports:e.imports||[]}}function _s(e){return Rf(e,_h)||Rf(e,Dh)}function wh(e){return _s(e)!==null}function Rf(e,n){return e.hasOwnProperty(n)?e[n]:null}function rw(e){let n=e&&(e[_h]||e[Dh]);return n||null}function Pf(e){return e&&(e.hasOwnProperty(kf)||e.hasOwnProperty(iw))?e[kf]:null}var _h=Y({\u0275prov:Y}),kf=Y({\u0275inj:Y}),Dh=Y({ngInjectableDef:Y}),iw=Y({ngInjectorDef:Y}),M=class{constructor(n,t){this._desc=n,this.ngMetadataName="InjectionToken",this.\u0275prov=void 0,typeof t=="number"?this.__NG_ELEMENT_ID__=t:t!==void 0&&(this.\u0275prov=I({token:this,providedIn:t.providedIn||"root",factory:t.factory}))}get multi(){return this}toString(){return`InjectionToken ${this._desc}`}};function bh(e){return e&&!!e.\u0275providers}var ow=Y({\u0275cmp:Y}),sw=Y({\u0275dir:Y}),aw=Y({\u0275pipe:Y}),cw=Y({\u0275mod:Y}),Xo=Y({\u0275fac:Y}),Xr=Y({__NG_ELEMENT_ID__:Y}),Ff=Y({__NG_ENV_ID__:Y});function Ds(e){return typeof e=="string"?e:e==null?"":String(e)}function lw(e){return typeof e=="function"?e.name||e.toString():typeof e=="object"&&e!=null&&typeof e.type=="function"?e.type.name||e.type.toString():Ds(e)}function uw(e,n){let t=n?`. Dependency path: ${n.join(" > ")} > ${e}`:"";throw new E(-200,e)}function xl(e,n){throw new E(-201,!1)}var L=function(e){return e[e.Default=0]="Default",e[e.Host=1]="Host",e[e.Self=2]="Self",e[e.SkipSelf=4]="SkipSelf",e[e.Optional=8]="Optional",e}(L||{}),jc;function Ch(){return jc}function He(e){let n=jc;return jc=e,n}function Eh(e,n,t){let r=_s(e);if(r&&r.providedIn=="root")return r.value===void 0?r.value=r.factory():r.value;if(t&L.Optional)return null;if(n!==void 0)return n;xl(e,"Injector")}var dw={},ei=dw,fw="__NG_DI_FLAG__",es="ngTempTokenPath",hw="ngTokenPath",pw=/\n/gm,gw="\u0275",Lf="__source",er;function mw(){return er}function Rt(e){let n=er;return er=e,n}function vw(e,n=L.Default){if(er===void 0)throw new E(-203,!1);return er===null?Eh(e,void 0,n):er.get(e,n&L.Optional?null:void 0,n)}function O(e,n=L.Default){return(Ch()||vw)(Ee(e),n)}function m(e,n=L.Default){return O(e,bs(n))}function bs(e){return typeof e>"u"||typeof e=="number"?e:0|(e.optional&&8)|(e.host&&1)|(e.self&&2)|(e.skipSelf&&4)}function Vc(e){let n=[];for(let t=0;t ");else if(typeof n=="object"){let o=[];for(let s in n)if(n.hasOwnProperty(s)){let a=n[s];o.push(s+":"+(typeof a=="string"?JSON.stringify(a):xe(a)))}i=`{${o.join(", ")}}`}return`${t}${r?"("+r+")":""}[${i}]: ${e.replace(pw,` - `)}`}function nr(e,n){let t=e.hasOwnProperty(Xo);return t?e[Xo]:null}function Tl(e,n){e.forEach(t=>Array.isArray(t)?Tl(t,n):n(t))}function Ih(e,n,t){n>=e.length?e.push(t):e.splice(n,0,t)}function ts(e,n){return n>=e.length-1?e.pop():e.splice(n,1)[0]}function Dw(e,n,t,r){let i=e.length;if(i==n)e.push(t,r);else if(i===1)e.push(r,e[0]),e[0]=t;else{for(i--,e.push(e[i-1],e[i]);i>n;){let o=i-2;e[i]=e[o],i--}e[n]=t,e[n+1]=r}}function bw(e,n,t){let r=gi(e,n);return r>=0?e[r|1]=t:(r=~r,Dw(e,r,n,t)),r}function Cc(e,n){let t=gi(e,n);if(t>=0)return e[t|1]}function gi(e,n){return Cw(e,n,1)}function Cw(e,n,t){let r=0,i=e.length>>t;for(;i!==r;){let o=r+(i-r>>1),s=e[o<n?i=o:r=o+1}return~(i<n){s=o-1;break}}}for(;o-1){let o;for(;++io?d="":d=i[u+1].toLowerCase(),r&2&&l!==d){if(Je(r))return!1;s=!0}}}}return Je(r)||s}function Je(e){return(e&1)===0}function Tw(e,n,t,r){if(n===null)return-1;let i=0;if(r||!t){let o=!1;for(;i-1)for(t++;t0?'="'+a+'"':"")+"]"}else r&8?i+="."+s:r&4&&(i+=" "+s);else i!==""&&!Je(s)&&(n+=Vf(o,i),i=""),r=s,o=o||!Je(r);t++}return i!==""&&(n+=Vf(o,i)),n}function Pw(e){return e.map(Rw).join(",")}function kw(e){let n=[],t=[],r=1,i=2;for(;r{let n=kh(e),t=G(b({},n),{decls:e.decls,vars:e.vars,template:e.template,consts:e.consts||null,ngContentSelectors:e.ngContentSelectors,onPush:e.changeDetection===xh.OnPush,directiveDefs:null,pipeDefs:null,dependencies:n.standalone&&e.dependencies||null,getStandaloneInjector:null,signals:e.signals??!1,data:e.data||{},encapsulation:e.encapsulation||ft.Emulated,styles:e.styles||ze,_:null,schemas:e.schemas||null,tView:null,id:""});Fh(t);let r=e.dependencies;return t.directiveDefs=Uf(r,!1),t.pipeDefs=Uf(r,!0),t.id=jw(t),t})}function Fw(e){return sn(e)||Oh(e)}function Lw(e){return e!==null}function pn(e){return ws(()=>({type:e.type,bootstrap:e.bootstrap||ze,declarations:e.declarations||ze,imports:e.imports||ze,exports:e.exports||ze,transitiveCompileScopes:null,schemas:e.schemas||null,id:e.id||null}))}function $f(e,n){if(e==null)return rr;let t={};for(let r in e)if(e.hasOwnProperty(r)){let i=e[r],o,s,a=se.None;Array.isArray(i)?(a=i[0],o=i[1],s=i[2]??o):(o=i,s=i),n?(t[o]=a!==se.None?[r,a]:r,n[o]=s):t[o]=r}return t}function je(e){return ws(()=>{let n=kh(e);return Fh(n),n})}function sn(e){return e[ow]||null}function Oh(e){return e[sw]||null}function Nh(e){return e[aw]||null}function Rh(e){let n=sn(e)||Oh(e)||Nh(e);return n!==null?n.standalone:!1}function Ph(e,n){let t=e[cw]||null;if(!t&&n===!0)throw new Error(`Type ${xe(e)} does not have '\u0275mod' property.`);return t}function kh(e){let n={};return{type:e.type,providersResolver:null,factory:null,hostBindings:e.hostBindings||null,hostVars:e.hostVars||0,hostAttrs:e.hostAttrs||null,contentQueries:e.contentQueries||null,declaredInputs:n,inputTransforms:null,inputConfig:e.inputs||rr,exportAs:e.exportAs||null,standalone:e.standalone===!0,signals:e.signals===!0,selectors:e.selectors||ze,viewQuery:e.viewQuery||null,features:e.features||null,setInput:null,findHostDirectiveDefs:null,hostDirectives:null,inputs:$f(e.inputs,n),outputs:$f(e.outputs),debugInfo:null}}function Fh(e){e.features?.forEach(n=>n(e))}function Uf(e,n){if(!e)return null;let t=n?Nh:Fw;return()=>(typeof e=="function"?e():e).map(r=>t(r)).filter(Lw)}function jw(e){let n=0,t=[e.selectors,e.ngContentSelectors,e.hostVars,e.hostAttrs,e.consts,e.vars,e.decls,e.encapsulation,e.standalone,e.signals,e.exportAs,JSON.stringify(e.inputs),JSON.stringify(e.outputs),Object.getOwnPropertyNames(e.type.prototype),!!e.contentQueries,!!e.viewQuery].join("|");for(let i of t)n=Math.imul(31,n)+i.charCodeAt(0)<<0;return n+=2147483648,"c"+n}function fr(e){return{\u0275providers:e}}function Vw(...e){return{\u0275providers:Lh(!0,e),\u0275fromNgModule:!0}}function Lh(e,...n){let t=[],r=new Set,i,o=s=>{t.push(s)};return Tl(n,s=>{let a=s;Uc(a,o,[],r)&&(i||=[],i.push(a))}),i!==void 0&&jh(i,o),t}function jh(e,n){for(let t=0;t{n(o,r)})}}function Uc(e,n,t,r){if(e=Ee(e),!e)return!1;let i=null,o=Pf(e),s=!o&&sn(e);if(!o&&!s){let c=e.ngModule;if(o=Pf(c),o)i=c;else return!1}else{if(s&&!s.standalone)return!1;i=e}let a=r.has(i);if(s){if(a)return!1;if(r.add(i),s.dependencies){let c=typeof s.dependencies=="function"?s.dependencies():s.dependencies;for(let l of c)Uc(l,n,t,r)}}else if(o){if(o.imports!=null&&!a){r.add(i);let l;try{Tl(o.imports,u=>{Uc(u,n,t,r)&&(l||=[],l.push(u))})}finally{}l!==void 0&&jh(l,n)}if(!a){let l=nr(i)||(()=>new i);n({provide:i,useFactory:l,deps:ze},i),n({provide:Sh,useValue:i,multi:!0},i),n({provide:ir,useValue:()=>O(i),multi:!0},i)}let c=o.providers;if(c!=null&&!a){let l=e;Ol(c,u=>{n(u,l)})}}else return!1;return i!==e&&e.providers!==void 0}function Ol(e,n){for(let t of e)bh(t)&&(t=t.\u0275providers),Array.isArray(t)?Ol(t,n):n(t)}var $w=Y({provide:String,useValue:Y});function Vh(e){return e!==null&&typeof e=="object"&&$w in e}function Uw(e){return!!(e&&e.useExisting)}function Bw(e){return!!(e&&e.useFactory)}function or(e){return typeof e=="function"}function Hw(e){return!!e.useClass}var Cs=new M(""),Wo={},zw={},Ec;function Nl(){return Ec===void 0&&(Ec=new ns),Ec}var Te=class{},ni=class extends Te{get destroyed(){return this._destroyed}constructor(n,t,r,i){super(),this.parent=t,this.source=r,this.scopes=i,this.records=new Map,this._ngOnDestroyHooks=new Set,this._onDestroyHooks=[],this._destroyed=!1,Hc(n,s=>this.processProvider(s)),this.records.set(Mh,Kn(void 0,this)),i.has("environment")&&this.records.set(Te,Kn(void 0,this));let o=this.records.get(Cs);o!=null&&typeof o.value=="string"&&this.scopes.add(o.value),this.injectorDefTypes=new Set(this.get(Sh,ze,L.Self))}destroy(){this.assertNotDestroyed(),this._destroyed=!0;let n=V(null);try{for(let r of this._ngOnDestroyHooks)r.ngOnDestroy();let t=this._onDestroyHooks;this._onDestroyHooks=[];for(let r of t)r()}finally{this.records.clear(),this._ngOnDestroyHooks.clear(),this.injectorDefTypes.clear(),V(n)}}onDestroy(n){return this.assertNotDestroyed(),this._onDestroyHooks.push(n),()=>this.removeOnDestroy(n)}runInContext(n){this.assertNotDestroyed();let t=Rt(this),r=He(void 0),i;try{return n()}finally{Rt(t),He(r)}}get(n,t=ei,r=L.Default){if(this.assertNotDestroyed(),n.hasOwnProperty(Ff))return n[Ff](this);r=bs(r);let i,o=Rt(this),s=He(void 0);try{if(!(r&L.SkipSelf)){let c=this.records.get(n);if(c===void 0){let l=Yw(n)&&_s(n);l&&this.injectableDefInScope(l)?c=Kn(Bc(n),Wo):c=null,this.records.set(n,c)}if(c!=null)return this.hydrate(n,c)}let a=r&L.Self?Nl():this.parent;return t=r&L.Optional&&t===ei?null:t,a.get(n,t)}catch(a){if(a.name==="NullInjectorError"){if((a[es]=a[es]||[]).unshift(xe(n)),o)throw a;return ww(a,n,"R3InjectorError",this.source)}else throw a}finally{He(s),Rt(o)}}resolveInjectorInitializers(){let n=V(null),t=Rt(this),r=He(void 0),i;try{let o=this.get(ir,ze,L.Self);for(let s of o)s()}finally{Rt(t),He(r),V(n)}}toString(){let n=[],t=this.records;for(let r of t.keys())n.push(xe(r));return`R3Injector[${n.join(", ")}]`}assertNotDestroyed(){if(this._destroyed)throw new E(205,!1)}processProvider(n){n=Ee(n);let t=or(n)?n:Ee(n&&n.provide),r=qw(n);if(!or(n)&&n.multi===!0){let i=this.records.get(t);i||(i=Kn(void 0,Wo,!0),i.factory=()=>Vc(i.multi),this.records.set(t,i)),t=n,i.multi.push(n)}this.records.set(t,r)}hydrate(n,t){let r=V(null);try{return t.value===Wo&&(t.value=zw,t.value=t.factory()),typeof t.value=="object"&&t.value&&Zw(t.value)&&this._ngOnDestroyHooks.add(t.value),t.value}finally{V(r)}}injectableDefInScope(n){if(!n.providedIn)return!1;let t=Ee(n.providedIn);return typeof t=="string"?t==="any"||this.scopes.has(t):this.injectorDefTypes.has(t)}removeOnDestroy(n){let t=this._onDestroyHooks.indexOf(n);t!==-1&&this._onDestroyHooks.splice(t,1)}};function Bc(e){let n=_s(e),t=n!==null?n.factory:nr(e);if(t!==null)return t;if(e instanceof M)throw new E(204,!1);if(e instanceof Function)return Gw(e);throw new E(204,!1)}function Gw(e){if(e.length>0)throw new E(204,!1);let t=rw(e);return t!==null?()=>t.factory(e):()=>new e}function qw(e){if(Vh(e))return Kn(void 0,e.useValue);{let n=$h(e);return Kn(n,Wo)}}function $h(e,n,t){let r;if(or(e)){let i=Ee(e);return nr(i)||Bc(i)}else if(Vh(e))r=()=>Ee(e.useValue);else if(Bw(e))r=()=>e.useFactory(...Vc(e.deps||[]));else if(Uw(e))r=()=>O(Ee(e.useExisting));else{let i=Ee(e&&(e.useClass||e.provide));if(Ww(e))r=()=>new i(...Vc(e.deps));else return nr(i)||Bc(i)}return r}function Kn(e,n,t=!1){return{factory:e,value:n,multi:t?[]:void 0}}function Ww(e){return!!e.deps}function Zw(e){return e!==null&&typeof e=="object"&&typeof e.ngOnDestroy=="function"}function Yw(e){return typeof e=="function"||typeof e=="object"&&e instanceof M}function Hc(e,n){for(let t of e)Array.isArray(t)?Hc(t,n):t&&bh(t)?Hc(t.\u0275providers,n):n(t)}function bt(e,n){e instanceof ni&&e.assertNotDestroyed();let t,r=Rt(e),i=He(void 0);try{return n()}finally{Rt(r),He(i)}}function Uh(){return Ch()!==void 0||mw()!=null}function Qw(e){if(!Uh())throw new E(-203,!1)}function Kw(e){return typeof e=="function"}var Ct=0,k=1,S=2,Ce=3,Xe=4,it=5,ri=6,ii=7,be=8,sr=9,et=10,pe=11,oi=12,Bf=13,hr=14,tt=15,Es=16,Jn=17,ar=18,Is=19,Bh=20,Pt=21,Zo=22,an=23,nt=25,Hh=1;var cn=7,rs=8,is=9,Ie=10,Rl=function(e){return e[e.None=0]="None",e[e.HasTransplantedViews=2]="HasTransplantedViews",e}(Rl||{});function rn(e){return Array.isArray(e)&&typeof e[Hh]=="object"}function Et(e){return Array.isArray(e)&&e[Hh]===!0}function zh(e){return(e.flags&4)!==0}function Ms(e){return e.componentOffset>-1}function Pl(e){return(e.flags&1)===1}function kt(e){return!!e.template}function Jw(e){return(e[S]&512)!==0}var zc=class{constructor(n,t,r){this.previousValue=n,this.currentValue=t,this.firstChange=r}isFirstChange(){return this.firstChange}};function Gh(e,n,t,r){n!==null?n.applyValueToInputSignal(n,r):e[t]=r}function Lt(){return qh}function qh(e){return e.type.prototype.ngOnChanges&&(e.setInput=e_),Xw}Lt.ngInherit=!0;function Xw(){let e=Zh(this),n=e?.current;if(n){let t=e.previous;if(t===rr)e.previous=n;else for(let r in n)t[r]=n[r];e.current=null,this.ngOnChanges(n)}}function e_(e,n,t,r,i){let o=this.declaredInputs[r],s=Zh(e)||t_(e,{previous:rr,current:null}),a=s.current||(s.current={}),c=s.previous,l=c[o];a[o]=new zc(l&&l.currentValue,t,c===rr),Gh(e,n,i,t)}var Wh="__ngSimpleChanges__";function Zh(e){return e[Wh]||null}function t_(e,n){return e[Wh]=n}var Hf=null;var ut=function(e,n,t){Hf?.(e,n,t)},n_="svg",r_="math",i_=!1;function o_(){return i_}function ht(e){for(;Array.isArray(e);)e=e[Ct];return e}function Yh(e,n){return ht(n[e])}function Ge(e,n){return ht(n[e.index])}function kl(e,n){return e.data[n]}function jt(e,n){let t=n[e];return rn(t)?t:t[Ct]}function Fl(e){return(e[S]&128)===128}function s_(e){return Et(e[Ce])}function os(e,n){return n==null?null:e[n]}function Qh(e){e[Jn]=0}function a_(e){e[S]&1024||(e[S]|=1024,Fl(e)&&si(e))}function c_(e,n){for(;e>0;)n=n[hr],e--;return n}function Ll(e){return!!(e[S]&9216||e[an]?.dirty)}function Gc(e){e[et].changeDetectionScheduler?.notify(1),Ll(e)?si(e):e[S]&64&&(o_()?(e[S]|=1024,si(e)):e[et].changeDetectionScheduler?.notify())}function si(e){e[et].changeDetectionScheduler?.notify();let n=ai(e);for(;n!==null&&!(n[S]&8192||(n[S]|=8192,!Fl(n)));)n=ai(n)}function Kh(e,n){if((e[S]&256)===256)throw new E(911,!1);e[Pt]===null&&(e[Pt]=[]),e[Pt].push(n)}function l_(e,n){if(e[Pt]===null)return;let t=e[Pt].indexOf(n);t!==-1&&e[Pt].splice(t,1)}function ai(e){let n=e[Ce];return Et(n)?n[Ce]:n}var U={lFrame:sp(null),bindingsEnabled:!0,skipHydrationRootTNode:null};function u_(){return U.lFrame.elementDepthCount}function d_(){U.lFrame.elementDepthCount++}function f_(){U.lFrame.elementDepthCount--}function Jh(){return U.bindingsEnabled}function h_(){return U.skipHydrationRootTNode!==null}function p_(e){return U.skipHydrationRootTNode===e}function g_(){U.skipHydrationRootTNode=null}function Q(){return U.lFrame.lView}function qe(){return U.lFrame.tView}function Xh(e){return U.lFrame.contextLView=e,e[be]}function ep(e){return U.lFrame.contextLView=null,e}function We(){let e=tp();for(;e!==null&&e.type===64;)e=e.parent;return e}function tp(){return U.lFrame.currentTNode}function m_(){let e=U.lFrame,n=e.currentTNode;return e.isParent?n:n.parent}function mi(e,n){let t=U.lFrame;t.currentTNode=e,t.isParent=n}function np(){return U.lFrame.isParent}function v_(){U.lFrame.isParent=!1}function y_(e){return U.lFrame.bindingIndex=e}function vi(){return U.lFrame.bindingIndex++}function w_(e){let n=U.lFrame,t=n.bindingIndex;return n.bindingIndex=n.bindingIndex+e,t}function __(){return U.lFrame.inI18n}function D_(e,n){let t=U.lFrame;t.bindingIndex=t.bindingRootIndex=e,qc(n)}function b_(){return U.lFrame.currentDirectiveIndex}function qc(e){U.lFrame.currentDirectiveIndex=e}function C_(e){let n=U.lFrame.currentDirectiveIndex;return n===-1?null:e[n]}function rp(e){U.lFrame.currentQueryIndex=e}function E_(e){let n=e[k];return n.type===2?n.declTNode:n.type===1?e[it]:null}function ip(e,n,t){if(t&L.SkipSelf){let i=n,o=e;for(;i=i.parent,i===null&&!(t&L.Host);)if(i=E_(o),i===null||(o=o[hr],i.type&10))break;if(i===null)return!1;n=i,e=o}let r=U.lFrame=op();return r.currentTNode=n,r.lView=e,!0}function jl(e){let n=op(),t=e[k];U.lFrame=n,n.currentTNode=t.firstChild,n.lView=e,n.tView=t,n.contextLView=e,n.bindingIndex=t.bindingStartIndex,n.inI18n=!1}function op(){let e=U.lFrame,n=e===null?null:e.child;return n===null?sp(e):n}function sp(e){let n={currentTNode:null,isParent:!0,lView:null,tView:null,selectedIndex:-1,contextLView:null,elementDepthCount:0,currentNamespace:null,currentDirectiveIndex:-1,bindingRootIndex:-1,bindingIndex:-1,currentQueryIndex:0,parent:e,child:null,inI18n:!1};return e!==null&&(e.child=n),n}function ap(){let e=U.lFrame;return U.lFrame=e.parent,e.currentTNode=null,e.lView=null,e}var cp=ap;function Vl(){let e=ap();e.isParent=!0,e.tView=null,e.selectedIndex=-1,e.contextLView=null,e.elementDepthCount=0,e.currentDirectiveIndex=-1,e.currentNamespace=null,e.bindingRootIndex=-1,e.bindingIndex=-1,e.currentQueryIndex=0}function I_(e){return(U.lFrame.contextLView=c_(e,U.lFrame.contextLView))[be]}function gn(){return U.lFrame.selectedIndex}function ln(e){U.lFrame.selectedIndex=e}function $l(){let e=U.lFrame;return kl(e.tView,e.selectedIndex)}function M_(){return U.lFrame.currentNamespace}var lp=!0;function Ul(){return lp}function Bl(e){lp=e}function S_(e,n,t){let{ngOnChanges:r,ngOnInit:i,ngDoCheck:o}=n.type.prototype;if(r){let s=qh(n);(t.preOrderHooks??=[]).push(e,s),(t.preOrderCheckHooks??=[]).push(e,s)}i&&(t.preOrderHooks??=[]).push(0-e,i),o&&((t.preOrderHooks??=[]).push(e,o),(t.preOrderCheckHooks??=[]).push(e,o))}function Hl(e,n){for(let t=n.directiveStart,r=n.directiveEnd;t=r)break}else n[c]<0&&(e[Jn]+=65536),(a>14>16&&(e[S]&3)===n&&(e[S]+=16384,zf(a,o)):zf(a,o)}var tr=-1,un=class{constructor(n,t,r){this.factory=n,this.resolving=!1,this.canSeeViewProviders=t,this.injectImpl=r}};function T_(e){return e instanceof un}function A_(e){return(e.flags&8)!==0}function O_(e){return(e.flags&16)!==0}function dp(e){return e!==tr}function ss(e){return e&32767}function N_(e){return e>>16}function as(e,n){let t=N_(e),r=n;for(;t>0;)r=r[hr],t--;return r}var Wc=!0;function Gf(e){let n=Wc;return Wc=e,n}var R_=256,fp=R_-1,hp=5,P_=0,dt={};function k_(e,n,t){let r;typeof t=="string"?r=t.charCodeAt(0)||0:t.hasOwnProperty(Xr)&&(r=t[Xr]),r==null&&(r=t[Xr]=P_++);let i=r&fp,o=1<>hp)]|=o}function cs(e,n){let t=pp(e,n);if(t!==-1)return t;let r=n[k];r.firstCreatePass&&(e.injectorIndex=n.length,Mc(r.data,e),Mc(n,null),Mc(r.blueprint,null));let i=zl(e,n),o=e.injectorIndex;if(dp(i)){let s=ss(i),a=as(i,n),c=a[k].data;for(let l=0;l<8;l++)n[o+l]=a[s+l]|c[s+l]}return n[o+8]=i,o}function Mc(e,n){e.push(0,0,0,0,0,0,0,0,n)}function pp(e,n){return e.injectorIndex===-1||e.parent&&e.parent.injectorIndex===e.injectorIndex||n[e.injectorIndex+8]===null?-1:e.injectorIndex}function zl(e,n){if(e.parent&&e.parent.injectorIndex!==-1)return e.parent.injectorIndex;let t=0,r=null,i=n;for(;i!==null;){if(r=wp(i),r===null)return tr;if(t++,i=i[hr],r.injectorIndex!==-1)return r.injectorIndex|t<<16}return tr}function Zc(e,n,t){k_(e,n,t)}function F_(e,n){if(n==="class")return e.classes;if(n==="style")return e.styles;let t=e.attrs;if(t){let r=t.length,i=0;for(;i>20,d=r?a:a+u,p=i?a+u:l;for(let f=d;f=c&&w.type===t)return f}if(i){let f=s[c];if(f&&kt(f)&&f.type===t)return c}return null}function cr(e,n,t,r){let i=e[t],o=n.data;if(T_(i)){let s=i;s.resolving&&uw(lw(o[t]));let a=Gf(s.canSeeViewProviders);s.resolving=!0;let c,l=s.injectImpl?He(s.injectImpl):null,u=ip(e,r,L.Default);try{i=e[t]=s.factory(void 0,o,e,r),n.firstCreatePass&&t>=r.directiveStart&&S_(t,o[t],n)}finally{l!==null&&He(l),Gf(a),s.resolving=!1,cp()}}return i}function V_(e){if(typeof e=="string")return e.charCodeAt(0)||0;let n=e.hasOwnProperty(Xr)?e[Xr]:void 0;return typeof n=="number"?n>=0?n&fp:$_:n}function qf(e,n,t){let r=1<>hp)]&r)}function Wf(e,n){return!(e&L.Self)&&!(e&L.Host&&n)}var on=class{constructor(n,t){this._tNode=n,this._lView=t}get(n,t,r){return vp(this._tNode,this._lView,n,bs(r),t)}};function $_(){return new on(We(),Q())}function yi(e){return ws(()=>{let n=e.prototype.constructor,t=n[Xo]||Yc(n),r=Object.prototype,i=Object.getPrototypeOf(e.prototype).constructor;for(;i&&i!==r;){let o=i[Xo]||Yc(i);if(o&&o!==t)return o;i=Object.getPrototypeOf(i)}return o=>new o})}function Yc(e){return yh(e)?()=>{let n=Yc(Ee(e));return n&&n()}:nr(e)}function U_(e,n,t,r,i){let o=e,s=n;for(;o!==null&&s!==null&&s[S]&2048&&!(s[S]&512);){let a=yp(o,s,t,r|L.Self,dt);if(a!==dt)return a;let c=o.parent;if(!c){let l=s[Bh];if(l){let u=l.get(t,dt,r);if(u!==dt)return u}c=wp(s),s=s[hr]}o=c}return i}function wp(e){let n=e[k],t=n.type;return t===2?n.declTNode:t===1?e[it]:null}function Gl(e){return F_(We(),e)}function Zf(e,n=null,t=null,r){let i=_p(e,n,t,r);return i.resolveInjectorInitializers(),i}function _p(e,n=null,t=null,r,i=new Set){let o=[t||ze,Vw(e)];return r=r||(typeof e=="object"?void 0:xe(e)),new ni(o,n||Nl(),r||null,i)}var mn=(()=>{class e{static{this.THROW_IF_NOT_FOUND=ei}static{this.NULL=new ns}static create(t,r){if(Array.isArray(t))return Zf({name:""},r,t,"");{let i=t.name??"";return Zf({name:i},t.parent,t.providers,i)}}static{this.\u0275prov=I({token:e,providedIn:"any",factory:()=>O(Mh)})}static{this.__NG_ELEMENT_ID__=-1}}return e})();var B_="ngOriginalError";function Sc(e){return e[B_]}var rt=class{constructor(){this._console=console}handleError(n){let t=this._findOriginalError(n);this._console.error("ERROR",n),t&&this._console.error("ORIGINAL ERROR",t)}_findOriginalError(n){let t=n&&Sc(n);for(;t&&Sc(t);)t=Sc(t);return t||null}},Dp=new M("",{providedIn:"root",factory:()=>m(rt).handleError.bind(void 0)}),Ss=(()=>{class e{static{this.__NG_ELEMENT_ID__=H_}static{this.__NG_ENV_ID__=t=>t}}return e})(),Qc=class extends Ss{constructor(n){super(),this._lView=n}onDestroy(n){return Kh(this._lView,n),()=>l_(this._lView,n)}};function H_(){return new Qc(Q())}var Kc=class{constructor(){this.destroyed=!1,this.listeners=null,this.errorHandler=m(rt,{optional:!0}),this.destroyRef=m(Ss),this.destroyRef.onDestroy(()=>{this.destroyed=!0,this.listeners=null})}subscribe(n){if(this.destroyed)throw new E(953,!1);return(this.listeners??=[]).push(n),{unsubscribe:()=>{let t=this.listeners?.indexOf(n);t!==void 0&&t!==-1&&this.listeners?.splice(t,1)}}}emit(n){if(this.destroyed)throw new E(953,!1);if(this.listeners===null)return;let t=V(null);try{for(let r of this.listeners)try{r(n)}catch(i){this.errorHandler?.handleError(i)}}finally{V(t)}}};function xs(e){return new Kc}function Yf(e,n){return vh(e,n)}function z_(e){return vh(mh,e)}var Ts=(Yf.required=z_,Yf);function G_(){return ql(We(),Q())}function ql(e,n){return new Vt(Ge(e,n))}var Vt=(()=>{class e{constructor(t){this.nativeElement=t}static{this.__NG_ELEMENT_ID__=G_}}return e})();var Jc=class extends _e{constructor(n=!1){super(),this.destroyRef=void 0,this.__isAsync=n,Uh()&&(this.destroyRef=m(Ss,{optional:!0})??void 0)}emit(n){let t=V(null);try{super.next(n)}finally{V(t)}}subscribe(n,t,r){let i=n,o=t||(()=>null),s=r;if(n&&typeof n=="object"){let c=n;i=c.next?.bind(c),o=c.error?.bind(c),s=c.complete?.bind(c)}this.__isAsync&&(o=xc(o),i&&(i=xc(i)),s&&(s=xc(s)));let a=super.subscribe({next:i,error:o,complete:s});return n instanceof le&&n.add(a),a}};function xc(e){return n=>{setTimeout(e,void 0,n)}}var De=Jc;function bp(e){return(e.flags&128)===128}var Cp=new Map,q_=0;function W_(){return q_++}function Z_(e){Cp.set(e[Is],e)}function Y_(e){Cp.delete(e[Is])}var Qf="__ngContext__";function dn(e,n){rn(n)?(e[Qf]=n[Is],Z_(n)):e[Qf]=n}function Ep(e){return Mp(e[oi])}function Ip(e){return Mp(e[Xe])}function Mp(e){for(;e!==null&&!Et(e);)e=e[Xe];return e}var Xc;function Sp(e){Xc=e}function Q_(){if(Xc!==void 0)return Xc;if(typeof document<"u")return document;throw new E(210,!1)}var Wl=new M("",{providedIn:"root",factory:()=>K_}),K_="ng",Zl=new M(""),$t=new M("",{providedIn:"platform",factory:()=>"unknown"});var Yl=new M("",{providedIn:"root",factory:()=>Q_().body?.querySelector("[ngCspNonce]")?.getAttribute("ngCspNonce")||null});var J_="h",X_="b";var e0=()=>null;function Ql(e,n,t=!1){return e0(e,n,t)}var xp=!1,t0=new M("",{providedIn:"root",factory:()=>xp});var zo;function n0(){if(zo===void 0&&(zo=null,nn.trustedTypes))try{zo=nn.trustedTypes.createPolicy("angular#unsafe-bypass",{createHTML:e=>e,createScript:e=>e,createScriptURL:e=>e})}catch{}return zo}function Kf(e){return n0()?.createScriptURL(e)||e}var ls=class{constructor(n){this.changingThisBreaksApplicationSecurity=n}toString(){return`SafeValue must use [property]=binding: ${this.changingThisBreaksApplicationSecurity} (see ${gh})`}};function wi(e){return e instanceof ls?e.changingThisBreaksApplicationSecurity:e}function Kl(e,n){let t=r0(e);if(t!=null&&t!==n){if(t==="ResourceURL"&&n==="URL")return!0;throw new Error(`Required a safe ${n}, got a ${t} (see ${gh})`)}return t===n}function r0(e){return e instanceof ls&&e.getTypeName()||null}var i0=/^(?!javascript:)(?:[a-z0-9+.-]+:|[^&:\/?#]*(?:[\/?#]|$))/i;function Tp(e){return e=String(e),e.match(i0)?e:"unsafe:"+e}var As=function(e){return e[e.NONE=0]="NONE",e[e.HTML=1]="HTML",e[e.STYLE=2]="STYLE",e[e.SCRIPT=3]="SCRIPT",e[e.URL=4]="URL",e[e.RESOURCE_URL=5]="RESOURCE_URL",e}(As||{});function o0(e){let n=Op();return n?n.sanitize(As.URL,e)||"":Kl(e,"URL")?wi(e):Tp(Ds(e))}function s0(e){let n=Op();if(n)return Kf(n.sanitize(As.RESOURCE_URL,e)||"");if(Kl(e,"ResourceURL"))return Kf(wi(e));throw new E(904,!1)}function a0(e,n){return n==="src"&&(e==="embed"||e==="frame"||e==="iframe"||e==="media"||e==="script")||n==="href"&&(e==="base"||e==="link")?s0:o0}function Ap(e,n,t){return a0(n,t)(e)}function Op(){let e=Q();return e&&e[et].sanitizer}function Np(e){return e instanceof Function?e():e}var Dt=function(e){return e[e.Important=1]="Important",e[e.DashCase=2]="DashCase",e}(Dt||{}),c0;function Jl(e,n){return c0(e,n)}function Xn(e,n,t,r,i){if(r!=null){let o,s=!1;Et(r)?o=r:rn(r)&&(s=!0,r=r[Ct]);let a=ht(r);e===0&&t!==null?i==null?Fp(n,t,a):us(n,t,a,i||null,!0):e===1&&t!==null?us(n,t,a,i||null,!0):e===2?I0(n,a,s):e===3&&n.destroyNode(a),o!=null&&S0(n,e,o,t,i)}}function l0(e,n){return e.createText(n)}function u0(e,n,t){e.setValue(n,t)}function Rp(e,n,t){return e.createElement(n,t)}function d0(e,n){Pp(e,n),n[Ct]=null,n[it]=null}function f0(e,n,t,r,i,o){r[Ct]=i,r[it]=n,Ns(e,r,t,1,i,o)}function Pp(e,n){n[et].changeDetectionScheduler?.notify(1),Ns(e,n,n[pe],2,null,null)}function h0(e){let n=e[oi];if(!n)return Tc(e[k],e);for(;n;){let t=null;if(rn(n))t=n[oi];else{let r=n[Ie];r&&(t=r)}if(!t){for(;n&&!n[Xe]&&n!==e;)rn(n)&&Tc(n[k],n),n=n[Ce];n===null&&(n=e),rn(n)&&Tc(n[k],n),t=n&&n[Xe]}n=t}}function p0(e,n,t,r){let i=Ie+r,o=t.length;r>0&&(t[i-1][Xe]=n),r0&&(e[t-1][Xe]=r[Xe]);let o=ts(e,Ie+n);d0(r[k],r);let s=o[ar];s!==null&&s.detachView(o[k]),r[Ce]=null,r[Xe]=null,r[S]&=-129}return r}function Os(e,n){if(!(n[S]&256)){let t=n[pe];t.destroyNode&&Ns(e,n,t,3,null,null),h0(n)}}function Tc(e,n){if(n[S]&256)return;let t=V(null);try{n[S]&=-129,n[S]|=256,n[an]&&ic(n[an]),v0(e,n),m0(e,n),n[k].type===1&&n[pe].destroy();let r=n[Es];if(r!==null&&Et(n[Ce])){r!==n[Ce]&&kp(r,n);let i=n[ar];i!==null&&i.detachView(e)}Y_(n)}finally{V(t)}}function m0(e,n){let t=e.cleanup,r=n[ii];if(t!==null)for(let o=0;o=0?r[s]():r[-s].unsubscribe(),o+=2}else{let s=r[t[o+1]];t[o].call(s)}r!==null&&(n[ii]=null);let i=n[Pt];if(i!==null){n[Pt]=null;for(let o=0;o-1){let{encapsulation:o}=e.data[r.directiveStart+i];if(o===ft.None||o===ft.Emulated)return null}return Ge(r,t)}}function us(e,n,t,r,i){e.insertBefore(n,t,r,i)}function Fp(e,n,t){e.appendChild(n,t)}function Jf(e,n,t,r,i){r!==null?us(e,n,t,r,i):Fp(e,n,t)}function _0(e,n,t,r){e.removeChild(n,t,r)}function Xl(e,n){return e.parentNode(n)}function D0(e,n){return e.nextSibling(n)}function b0(e,n,t){return E0(e,n,t)}function C0(e,n,t){return e.type&40?Ge(e,t):null}var E0=C0,Xf;function eu(e,n,t,r){let i=y0(e,r,n),o=n[pe],s=r.parent||n[it],a=b0(s,r,n);if(i!=null)if(Array.isArray(t))for(let c=0;cnt&&$p(e,n,nt,!1),ut(s?2:0,i),t(r,i)}finally{ln(o),ut(s?3:1,i)}}function zp(e,n,t){if(zh(n)){let r=V(null);try{let i=n.directiveStart,o=n.directiveEnd;for(let s=i;snull;function F0(e,n,t,r,i,o){let s=n?n.injectorIndex:-1,a=0;return h_()&&(a|=128),{type:t,index:r,insertBeforeIndex:null,injectorIndex:s,directiveStart:-1,directiveEnd:-1,directiveStylingLast:-1,componentOffset:-1,propertyBindings:null,flags:a,providerIndexes:0,value:i,attrs:o,mergedAttrs:null,localNames:null,initialInputs:void 0,inputs:null,outputs:null,tView:null,next:null,prev:null,projectionNext:null,child:null,parent:n,projection:null,styles:null,stylesWithoutHost:null,residualStyles:void 0,classes:null,classesWithoutHost:null,residualClasses:void 0,classBindings:0,styleBindings:0}}function eh(e,n,t,r,i){for(let o in n){if(!n.hasOwnProperty(o))continue;let s=n[o];if(s===void 0)continue;r??={};let a,c=se.None;Array.isArray(s)?(a=s[0],c=s[1]):a=s;let l=o;if(i!==null){if(!i.hasOwnProperty(o))continue;l=i[o]}e===0?th(r,t,l,a,c):th(r,t,l,a)}return r}function th(e,n,t,r,i){let o;e.hasOwnProperty(t)?(o=e[t]).push(n,r):o=e[t]=[n,r],i!==void 0&&o.push(i)}function L0(e,n,t){let r=n.directiveStart,i=n.directiveEnd,o=e.data,s=n.attrs,a=[],c=null,l=null;for(let u=r;u0;){let t=e[--n];if(typeof t=="number"&&t<0)return t}return 0}function B0(e,n,t,r){let i=t.directiveStart,o=t.directiveEnd;Ms(t)&&Y0(n,t,e.data[i+t.componentOffset]),e.firstCreatePass||cs(t,n),dn(r,n);let s=t.initialInputs;for(let a=i;a{si(e.lView)},consumerOnSignalRead(){this.lView[an]=this}}),ig=100;function og(e,n=!0,t=0){let r=e[et],i=r.rendererFactory,o=!1;o||i.begin?.();try{dD(e,t)}catch(s){throw n&&eg(e,s),s}finally{o||(i.end?.(),r.inlineEffectRunner?.flush())}}function dD(e,n){rl(e,n);let t=0;for(;Ll(e);){if(t===ig)throw new E(103,!1);t++,rl(e,1)}}function fD(e,n,t,r){let i=n[S];if((i&256)===256)return;let o=!1;!o&&n[et].inlineEffectRunner?.flush(),jl(n);let s=null,a=null;!o&&hD(e)&&(a=aD(n),s=nc(a));try{Qh(n),y_(e.bindingStartIndex),t!==null&&Hp(e,n,t,2,r);let c=(i&3)===3;if(!o)if(c){let d=e.preOrderCheckHooks;d!==null&&Yo(n,d,null)}else{let d=e.preOrderHooks;d!==null&&Qo(n,d,0,null),Ic(n,0)}if(pD(n),sg(n,0),e.contentQueries!==null&&Xp(e,n),!o)if(c){let d=e.contentCheckHooks;d!==null&&Yo(n,d)}else{let d=e.contentHooks;d!==null&&Qo(n,d,1),Ic(n,1)}A0(e,n);let l=e.components;l!==null&&cg(n,l,0);let u=e.viewQuery;if(u!==null&&nl(2,u,r),!o)if(c){let d=e.viewCheckHooks;d!==null&&Yo(n,d)}else{let d=e.viewHooks;d!==null&&Qo(n,d,2),Ic(n,2)}if(e.firstUpdatePass===!0&&(e.firstUpdatePass=!1),n[Zo]){for(let d of n[Zo])d();n[Zo]=null}o||(n[S]&=-73)}catch(c){throw si(n),c}finally{a!==null&&(rc(a,s),lD(a)),Vl()}}function hD(e){return e.type!==2}function sg(e,n){for(let t=Ep(e);t!==null;t=Ip(t))for(let r=Ie;r-1&&(ci(n,r),ts(t,r))}this._attachedToViewContainer=!1}Os(this._lView[k],this._lView)}onDestroy(n){Kh(this._lView,n)}markForCheck(){su(this._cdRefInjectingView||this._lView)}detach(){this._lView[S]&=-129}reattach(){Gc(this._lView),this._lView[S]|=128}detectChanges(){this._lView[S]|=1024,og(this._lView,this.notifyErrorHandler)}checkNoChanges(){}attachToViewContainerRef(){if(this._appRef)throw new E(902,!1);this._attachedToViewContainer=!0}detachFromAppRef(){this._appRef=null,Pp(this._lView[k],this._lView)}attachToAppRef(n){if(this._attachedToViewContainer)throw new E(902,!1);this._appRef=n,Gc(this._lView)}};var dR=new RegExp(`^(\\d+)*(${X_}|${J_})*(.*)`);var mD=()=>null;function ui(e,n){return mD(e,n)}var il=class{},ol=class{},fs=class{};function vD(e){let n=Error(`No component factory found for ${xe(e)}.`);return n[yD]=e,n}var yD="ngComponent";var sl=class{resolveComponentFactory(n){throw vD(n)}},Ls=(()=>{class e{static{this.NULL=new sl}}return e})(),di=class{},yn=(()=>{class e{constructor(){this.destroyNode=null}static{this.__NG_ELEMENT_ID__=()=>wD()}}return e})();function wD(){let e=Q(),n=We(),t=jt(n.index,e);return(rn(t)?t:e)[pe]}var _D=(()=>{class e{static{this.\u0275prov=I({token:e,providedIn:"root",factory:()=>null})}}return e})(),Ac={};var nh=new Set;function wn(e){nh.has(e)||(nh.add(e),performance?.mark?.("mark_feature_usage",{detail:{feature:e}}))}function rh(...e){}function DD(){let e=typeof nn.requestAnimationFrame=="function",n=nn[e?"requestAnimationFrame":"setTimeout"],t=nn[e?"cancelAnimationFrame":"clearTimeout"];if(typeof Zone<"u"&&n&&t){let r=n[Zone.__symbol__("OriginalDelegate")];r&&(n=r);let i=t[Zone.__symbol__("OriginalDelegate")];i&&(t=i)}return{nativeRequestAnimationFrame:n,nativeCancelAnimationFrame:t}}var ne=class e{constructor({enableLongStackTrace:n=!1,shouldCoalesceEventChangeDetection:t=!1,shouldCoalesceRunChangeDetection:r=!1}){if(this.hasPendingMacrotasks=!1,this.hasPendingMicrotasks=!1,this.isStable=!0,this.onUnstable=new De(!1),this.onMicrotaskEmpty=new De(!1),this.onStable=new De(!1),this.onError=new De(!1),typeof Zone>"u")throw new E(908,!1);Zone.assertZonePatched();let i=this;i._nesting=0,i._outer=i._inner=Zone.current,Zone.TaskTrackingZoneSpec&&(i._inner=i._inner.fork(new Zone.TaskTrackingZoneSpec)),n&&Zone.longStackTraceZoneSpec&&(i._inner=i._inner.fork(Zone.longStackTraceZoneSpec)),i.shouldCoalesceEventChangeDetection=!r&&t,i.shouldCoalesceRunChangeDetection=r,i.lastRequestAnimationFrameId=-1,i.nativeRequestAnimationFrame=DD().nativeRequestAnimationFrame,ED(i)}static isInAngularZone(){return typeof Zone<"u"&&Zone.current.get("isAngularZone")===!0}static assertInAngularZone(){if(!e.isInAngularZone())throw new E(909,!1)}static assertNotInAngularZone(){if(e.isInAngularZone())throw new E(909,!1)}run(n,t,r){return this._inner.run(n,t,r)}runTask(n,t,r,i){let o=this._inner,s=o.scheduleEventTask("NgZoneEvent: "+i,n,bD,rh,rh);try{return o.runTask(s,t,r)}finally{o.cancelTask(s)}}runGuarded(n,t,r){return this._inner.runGuarded(n,t,r)}runOutsideAngular(n){return this._outer.run(n)}},bD={};function au(e){if(e._nesting==0&&!e.hasPendingMicrotasks&&!e.isStable)try{e._nesting++,e.onMicrotaskEmpty.emit(null)}finally{if(e._nesting--,!e.hasPendingMicrotasks)try{e.runOutsideAngular(()=>e.onStable.emit(null))}finally{e.isStable=!0}}}function CD(e){e.isCheckStableRunning||e.lastRequestAnimationFrameId!==-1||(e.lastRequestAnimationFrameId=e.nativeRequestAnimationFrame.call(nn,()=>{e.fakeTopEventTask||(e.fakeTopEventTask=Zone.root.scheduleEventTask("fakeTopEventTask",()=>{e.lastRequestAnimationFrameId=-1,al(e),e.isCheckStableRunning=!0,au(e),e.isCheckStableRunning=!1},void 0,()=>{},()=>{})),e.fakeTopEventTask.invoke()}),al(e))}function ED(e){let n=()=>{CD(e)};e._inner=e._inner.fork({name:"angular",properties:{isAngularZone:!0},onInvokeTask:(t,r,i,o,s,a)=>{if(ID(a))return t.invokeTask(i,o,s,a);try{return ih(e),t.invokeTask(i,o,s,a)}finally{(e.shouldCoalesceEventChangeDetection&&o.type==="eventTask"||e.shouldCoalesceRunChangeDetection)&&n(),oh(e)}},onInvoke:(t,r,i,o,s,a,c)=>{try{return ih(e),t.invoke(i,o,s,a,c)}finally{e.shouldCoalesceRunChangeDetection&&n(),oh(e)}},onHasTask:(t,r,i,o)=>{t.hasTask(i,o),r===i&&(o.change=="microTask"?(e._hasPendingMicrotasks=o.microTask,al(e),au(e)):o.change=="macroTask"&&(e.hasPendingMacrotasks=o.macroTask))},onHandleError:(t,r,i,o)=>(t.handleError(i,o),e.runOutsideAngular(()=>e.onError.emit(o)),!1)})}function al(e){e._hasPendingMicrotasks||(e.shouldCoalesceEventChangeDetection||e.shouldCoalesceRunChangeDetection)&&e.lastRequestAnimationFrameId!==-1?e.hasPendingMicrotasks=!0:e.hasPendingMicrotasks=!1}function ih(e){e._nesting++,e.isStable&&(e.isStable=!1,e.onUnstable.emit(null))}function oh(e){e._nesting--,au(e)}function ID(e){return!Array.isArray(e)||e.length!==1?!1:e[0].data?.__ignore_ng_zone__===!0}var lg=(()=>{class e{constructor(){this.handler=null,this.internalCallbacks=[]}execute(){this.executeInternalCallbacks(),this.handler?.execute()}executeInternalCallbacks(){let t=[...this.internalCallbacks];this.internalCallbacks.length=0;for(let r of t)r()}ngOnDestroy(){this.handler?.destroy(),this.handler=null,this.internalCallbacks.length=0}static{this.\u0275prov=I({token:e,providedIn:"root",factory:()=>new e})}}return e})();function cl(e,n,t){let r=t?e.styles:null,i=t?e.classes:null,o=0;if(n!==null)for(let s=0;s0&&jp(e,t,o.join(" "))}}function ND(e,n,t){let r=e.projection=[];for(let i=0;i{class e{static{this.__NG_ELEMENT_ID__=PD}}return e})();function PD(){let e=We();return FD(e,Q())}var kD=js,ug=class extends kD{constructor(n,t,r){super(),this._lContainer=n,this._hostTNode=t,this._hostLView=r}get element(){return ql(this._hostTNode,this._hostLView)}get injector(){return new on(this._hostTNode,this._hostLView)}get parentInjector(){let n=zl(this._hostTNode,this._hostLView);if(dp(n)){let t=as(n,this._hostLView),r=ss(n),i=t[k].data[r+8];return new on(i,t)}else return new on(null,this._hostLView)}clear(){for(;this.length>0;)this.remove(this.length-1)}get(n){let t=ah(this._lContainer);return t!==null&&t[n]||null}get length(){return this._lContainer.length-Ie}createEmbeddedView(n,t,r){let i,o;typeof r=="number"?i=r:r!=null&&(i=r.index,o=r.injector);let s=ui(this._lContainer,n.ssrId),a=n.createEmbeddedViewImpl(t||{},o,s);return this.insertImpl(a,i,li(this._hostTNode,s)),a}createComponent(n,t,r,i,o){let s=n&&!Kw(n),a;if(s)a=t;else{let w=t||{};a=w.index,r=w.injector,i=w.projectableNodes,o=w.environmentInjector||w.ngModuleRef}let c=s?n:new fi(sn(n)),l=r||this.parentInjector;if(!o&&c.ngModule==null){let v=(s?l:this.parentInjector).get(Te,null);v&&(o=v)}let u=sn(c.componentType??{}),d=ui(this._lContainer,u?.id??null),p=d?.firstChild??null,f=c.create(l,i,p,o);return this.insertImpl(f.hostView,a,li(this._hostTNode,d)),f}insert(n,t){return this.insertImpl(n,t,!0)}insertImpl(n,t,r){let i=n._lView;if(s_(i)){let a=this.indexOf(n);if(a!==-1)this.detach(a);else{let c=i[Ce],l=new ug(c,c[it],c[Ce]);l.detach(l.indexOf(n))}}let o=this._adjustIndex(t),s=this._lContainer;return Fs(s,i,o,r),n.attachToViewContainerRef(),Ih(Oc(s),o,n),n}move(n,t){return this.insert(n,t)}indexOf(n){let t=ah(this._lContainer);return t!==null?t.indexOf(n):-1}remove(n){let t=this._adjustIndex(n,-1),r=ci(this._lContainer,t);r&&(ts(Oc(this._lContainer),t),Os(r[k],r))}detach(n){let t=this._adjustIndex(n,-1),r=ci(this._lContainer,t);return r&&ts(Oc(this._lContainer),t)!=null?new lr(r):null}_adjustIndex(n,t=0){return n??this.length+t}};function ah(e){return e[rs]}function Oc(e){return e[rs]||(e[rs]=[])}function FD(e,n){let t,r=n[e.index];return Et(r)?t=r:(t=Jp(r,n,null,e),n[e.index]=t,ks(n,t)),jD(t,n,e,r),new ug(t,e,n)}function LD(e,n){let t=e[pe],r=t.createComment(""),i=Ge(n,e),o=Xl(t,i);return us(t,o,r,D0(t,i),!1),r}var jD=UD,VD=()=>!1;function $D(e,n,t){return VD(e,n,t)}function UD(e,n,t,r){if(e[cn])return;let i;t.type&8?i=ht(r):i=LD(n,t),e[cn]=i}function dg(e,n){wn("NgSignals");let t=of(e),r=t[xt];return n?.equal&&(r.equal=n.equal),t.set=i=>wo(r,i),t.update=i=>sf(r,i),t.asReadonly=BD.bind(t),t}function BD(){let e=this[xt];if(e.readonlyFn===void 0){let n=()=>this();n[xt]=e,e.readonlyFn=n}return e.readonlyFn}function HD(e){return Object.getPrototypeOf(e.prototype).constructor}function Ut(e){let n=HD(e.type),t=!0,r=[e];for(;n;){let i;if(kt(e))i=n.\u0275cmp||n.\u0275dir;else{if(n.\u0275cmp)throw new E(903,!1);i=n.\u0275dir}if(i){if(t){r.push(i);let s=e;s.inputs=Go(e.inputs),s.inputTransforms=Go(e.inputTransforms),s.declaredInputs=Go(e.declaredInputs),s.outputs=Go(e.outputs);let a=i.hostBindings;a&&ZD(e,a);let c=i.viewQuery,l=i.contentQueries;if(c&&qD(e,c),l&&WD(e,l),zD(e,i),tw(e.outputs,i.outputs),kt(i)&&i.data.animation){let u=e.data;u.animation=(u.animation||[]).concat(i.data.animation)}}let o=i.features;if(o)for(let s=0;s=0;r--){let i=e[r];i.hostVars=n+=i.hostVars,i.hostAttrs=ti(i.hostAttrs,t=ti(t,i.hostAttrs))}}function Go(e){return e===rr?{}:e===ze?[]:e}function qD(e,n){let t=e.viewQuery;t?e.viewQuery=(r,i)=>{n(r,i),t(r,i)}:e.viewQuery=n}function WD(e,n){let t=e.contentQueries;t?e.contentQueries=(r,i,o)=>{n(r,i,o),t(r,i,o)}:e.contentQueries=n}function ZD(e,n){let t=e.hostBindings;t?e.hostBindings=(r,i)=>{n(r,i),t(r,i)}:e.hostBindings=n}function cu(e){let n=e.inputConfig,t={};for(let r in n)if(n.hasOwnProperty(r)){let i=n[r];Array.isArray(i)&&i[3]&&(t[r]=i[3])}e.inputTransforms=t}var Ft=class{},hi=class{};var dl=class extends Ft{constructor(n,t,r){super(),this._parent=t,this._bootstrapComponents=[],this.destroyCbs=[],this.componentFactoryResolver=new hs(this);let i=Ph(n);this._bootstrapComponents=Np(i.bootstrap),this._r3Injector=_p(n,t,[{provide:Ft,useValue:this},{provide:Ls,useValue:this.componentFactoryResolver},...r],xe(n),new Set(["environment"])),this._r3Injector.resolveInjectorInitializers(),this.instance=this._r3Injector.get(n)}get injector(){return this._r3Injector}destroy(){let n=this._r3Injector;!n.destroyed&&n.destroy(),this.destroyCbs.forEach(t=>t()),this.destroyCbs=null}onDestroy(n){this.destroyCbs.push(n)}},fl=class extends hi{constructor(n){super(),this.moduleType=n}create(n){return new dl(this.moduleType,n,[])}};var ps=class extends Ft{constructor(n){super(),this.componentFactoryResolver=new hs(this),this.instance=null;let t=new ni([...n.providers,{provide:Ft,useValue:this},{provide:Ls,useValue:this.componentFactoryResolver}],n.parent||Nl(),n.debugName,new Set(["environment"]));this.injector=t,n.runEnvironmentInitializers&&t.resolveInjectorInitializers()}destroy(){this.injector.destroy()}onDestroy(n){this.injector.onDestroy(n)}};function lu(e,n,t=null){return new ps({providers:e,parent:n,debugName:t,runEnvironmentInitializers:!0}).injector}var _n=(()=>{class e{constructor(){this.taskId=0,this.pendingTasks=new Set,this.hasPendingTasks=new ue(!1)}get _hasPendingTasks(){return this.hasPendingTasks.value}add(){this._hasPendingTasks||this.hasPendingTasks.next(!0);let t=this.taskId++;return this.pendingTasks.add(t),t}remove(t){this.pendingTasks.delete(t),this.pendingTasks.size===0&&this._hasPendingTasks&&this.hasPendingTasks.next(!1)}ngOnDestroy(){this.pendingTasks.clear(),this._hasPendingTasks&&this.hasPendingTasks.next(!1)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function pr(e,n,t){let r=e[n];return Object.is(r,t)?!1:(e[n]=t,!0)}function YD(e){return(e.flags&32)===32}function QD(e,n,t,r,i,o,s,a,c){let l=n.consts,u=Ps(n,e,4,s||null,os(l,a));Yp(n,t,u,os(l,c)),Hl(n,u);let d=u.tView=nu(2,u,r,i,o,n.directiveRegistry,n.pipeRegistry,null,n.schemas,l,null);return n.queries!==null&&(n.queries.template(n,u),d.queries=n.queries.embeddedTView(u)),u}function ge(e,n,t,r,i,o,s,a){let c=Q(),l=qe(),u=e+nt,d=l.firstCreatePass?QD(u,l,c,n,t,r,i,o,s):l.data[u];mi(d,!1);let p=KD(l,c,d,e);Ul()&&eu(l,c,p,d),dn(p,c);let f=Jp(p,c,p,d);return c[u]=f,ks(c,f),$D(f,d,c),Pl(d)&&Gp(l,c,d),s!=null&&qp(c,d,a),ge}var KD=JD;function JD(e,n,t,r){return Bl(!0),n[pe].createComment("")}function Vs(e,n,t,r){let i=Q(),o=vi();if(pr(i,o,n)){let s=qe(),a=$l();Q0(a,i,e,n,t,r)}return Vs}function fg(e,n,t,r){return pr(e,vi(),t)?n+Ds(t)+r:vn}function qo(e,n){return e<<17|n<<2}function fn(e){return e>>17&32767}function XD(e){return(e&2)==2}function eb(e,n){return e&131071|n<<17}function hl(e){return e|2}function ur(e){return(e&131068)>>2}function Nc(e,n){return e&-131069|n<<2}function tb(e){return(e&1)===1}function pl(e){return e|1}function nb(e,n,t,r,i,o){let s=o?n.classBindings:n.styleBindings,a=fn(s),c=ur(s);e[r]=t;let l=!1,u;if(Array.isArray(t)){let d=t;u=d[1],(u===null||gi(d,u)>0)&&(l=!0)}else u=t;if(i)if(c!==0){let p=fn(e[a+1]);e[r+1]=qo(p,a),p!==0&&(e[p+1]=Nc(e[p+1],r)),e[a+1]=eb(e[a+1],r)}else e[r+1]=qo(a,0),a!==0&&(e[a+1]=Nc(e[a+1],r)),a=r;else e[r+1]=qo(c,0),a===0?a=r:e[c+1]=Nc(e[c+1],r),c=r;l&&(e[r+1]=hl(e[r+1])),ch(e,u,r,!0),ch(e,u,r,!1),rb(n,u,e,r,o),s=qo(a,c),o?n.classBindings=s:n.styleBindings=s}function rb(e,n,t,r,i){let o=i?e.residualClasses:e.residualStyles;o!=null&&typeof n=="string"&&gi(o,n)>=0&&(t[r+1]=pl(t[r+1]))}function ch(e,n,t,r){let i=e[t+1],o=n===null,s=r?fn(i):ur(i),a=!1;for(;s!==0&&(a===!1||o);){let c=e[s],l=e[s+1];ib(c,n)&&(a=!0,e[s+1]=r?pl(l):hl(l)),s=r?fn(l):ur(l)}a&&(e[t+1]=r?hl(i):pl(i))}function ib(e,n){return e===null||n==null||(Array.isArray(e)?e[1]:e)===n?!0:Array.isArray(e)&&typeof n=="string"?gi(e,n)>=0:!1}function ot(e,n,t){let r=Q(),i=vi();if(pr(r,i,n)){let o=qe(),s=$l();Zp(o,s,r,e,n,r[pe],t,!1)}return ot}function lh(e,n,t,r,i){let o=n.inputs,s=i?"class":"style";ru(e,t,o[s],s,r)}function me(e,n){return ob(e,n,null,!0),me}function ob(e,n,t,r){let i=Q(),o=qe(),s=w_(2);if(o.firstUpdatePass&&ab(o,e,s,r),n!==vn&&pr(i,s,n)){let a=o.data[gn()];fb(o,a,i,i[pe],e,i[s+1]=hb(n,t),r,s)}}function sb(e,n){return n>=e.expandoStartIndex}function ab(e,n,t,r){let i=e.data;if(i[t+1]===null){let o=i[gn()],s=sb(e,t);pb(o,r)&&n===null&&!s&&(n=!1),n=cb(i,o,n,r),nb(i,o,n,t,s,r)}}function cb(e,n,t,r){let i=C_(e),o=r?n.residualClasses:n.residualStyles;if(i===null)(r?n.classBindings:n.styleBindings)===0&&(t=Rc(null,e,n,t,r),t=pi(t,n.attrs,r),o=null);else{let s=n.directiveStylingLast;if(s===-1||e[s]!==i)if(t=Rc(i,e,n,t,r),o===null){let c=lb(e,n,r);c!==void 0&&Array.isArray(c)&&(c=Rc(null,e,n,c[1],r),c=pi(c,n.attrs,r),ub(e,n,r,c))}else o=db(e,n,r)}return o!==void 0&&(r?n.residualClasses=o:n.residualStyles=o),t}function lb(e,n,t){let r=t?n.classBindings:n.styleBindings;if(ur(r)!==0)return e[fn(r)]}function ub(e,n,t,r){let i=t?n.classBindings:n.styleBindings;e[fn(i)]=r}function db(e,n,t){let r,i=n.directiveEnd;for(let o=1+n.directiveStylingLast;o0;){let c=e[i],l=Array.isArray(c),u=l?c[1]:c,d=u===null,p=t[i+1];p===vn&&(p=d?ze:void 0);let f=d?Cc(p,r):u===r?p:void 0;if(l&&!gs(f)&&(f=Cc(c,r)),gs(f)&&(a=f,s))return a;let w=e[i+1];i=s?fn(w):ur(w)}if(n!==null){let c=o?n.residualClasses:n.residualStyles;c!=null&&(a=Cc(c,r))}return a}function gs(e){return e!==void 0}function hb(e,n){return e==null||e===""||(typeof n=="string"?e=e+n:typeof e=="object"&&(e=xe(wi(e)))),e}function pb(e,n){return(e.flags&(n?8:16))!==0}var gl=class{destroy(n){}updateValue(n,t){}swap(n,t){let r=Math.min(n,t),i=Math.max(n,t),o=this.detach(i);if(i-r>1){let s=this.detach(r);this.attach(r,o),this.attach(i,s)}else this.attach(r,o)}move(n,t){this.attach(t,this.detach(n))}};function Pc(e,n,t,r,i){return e===t&&Object.is(n,r)?1:Object.is(i(e,n),i(t,r))?-1:0}function gb(e,n,t){let r,i,o=0,s=e.length-1;if(Array.isArray(n)){let a=n.length-1;for(;o<=s&&o<=a;){let c=e.at(o),l=n[o],u=Pc(o,c,o,l,t);if(u!==0){u<0&&e.updateValue(o,l),o++;continue}let d=e.at(s),p=n[a],f=Pc(s,d,a,p,t);if(f!==0){f<0&&e.updateValue(s,p),s--,a--;continue}let w=t(o,c),v=t(s,d),D=t(o,l);if(Object.is(D,v)){let C=t(a,p);Object.is(C,w)?(e.swap(o,s),e.updateValue(s,p),a--,s--):e.move(s,o),e.updateValue(o,l),o++;continue}if(r??=new ms,i??=fh(e,o,s,t),ml(e,r,o,D))e.updateValue(o,l),o++,s++;else if(i.has(D))r.set(w,e.detach(o)),s--;else{let C=e.create(o,n[o]);e.attach(o,C),o++,s++}}for(;o<=a;)dh(e,r,t,o,n[o]),o++}else if(n!=null){let a=n[Symbol.iterator](),c=a.next();for(;!c.done&&o<=s;){let l=e.at(o),u=c.value,d=Pc(o,l,o,u,t);if(d!==0)d<0&&e.updateValue(o,u),o++,c=a.next();else{r??=new ms,i??=fh(e,o,s,t);let p=t(o,u);if(ml(e,r,o,p))e.updateValue(o,u),o++,s++,c=a.next();else if(!i.has(p))e.attach(o,e.create(o,u)),o++,s++,c=a.next();else{let f=t(o,l);r.set(f,e.detach(o)),s--}}}for(;!c.done;)dh(e,r,t,e.length,c.value),c=a.next()}for(;o<=s;)e.destroy(e.detach(s--));r?.forEach(a=>{e.destroy(a)})}function ml(e,n,t,r){return n!==void 0&&n.has(r)?(e.attach(t,n.get(r)),n.delete(r),!0):!1}function dh(e,n,t,r,i){if(ml(e,n,r,t(r,i)))e.updateValue(r,i);else{let o=e.create(r,i);e.attach(r,o)}}function fh(e,n,t,r){let i=new Set;for(let o=n;o<=t;o++)i.add(r(o,e.at(o)));return i}var ms=class{constructor(){this.kvMap=new Map,this._vMap=void 0}has(n){return this.kvMap.has(n)}delete(n){if(!this.has(n))return!1;let t=this.kvMap.get(n);return this._vMap!==void 0&&this._vMap.has(t)?(this.kvMap.set(n,this._vMap.get(t)),this._vMap.delete(t)):this.kvMap.delete(n),!0}get(n){return this.kvMap.get(n)}set(n,t){if(this.kvMap.has(n)){let r=this.kvMap.get(n);this._vMap===void 0&&(this._vMap=new Map);let i=this._vMap;for(;i.has(r);)r=i.get(r);i.set(r,t)}else this.kvMap.set(n,t)}forEach(n){for(let[t,r]of this.kvMap)if(n(r,t),this._vMap!==void 0){let i=this._vMap;for(;i.has(r);)r=i.get(r),n(r,t)}}};function ve(e,n,t){wn("NgControlFlow");let r=Q(),i=vi(),o=_l(r,nt+e),s=0;if(pr(r,i,n)){let a=V(null);try{if(ng(o,s),n!==-1){let c=Dl(r[k],nt+n),l=ui(o,c.tView.ssrId),u=ou(r,c,t,{dehydratedView:l});Fs(o,u,s,li(c,l))}}finally{V(a)}}else{let a=tg(o,s);a!==void 0&&(a[be]=t)}}var vl=class{constructor(n,t,r){this.lContainer=n,this.$implicit=t,this.$index=r}get $count(){return this.lContainer.length-Ie}};var yl=class{constructor(n,t,r){this.hasEmptyBlock=n,this.trackByFn=t,this.liveCollection=r}};function hg(e,n,t,r,i,o,s,a,c,l,u,d,p){wn("NgControlFlow");let f=c!==void 0,w=Q(),v=a?s.bind(w[tt][be]):s,D=new yl(f,v);w[nt+e]=D,ge(e+1,n,t,r,i,o),f&&ge(e+2,c,l,u,d,p)}var wl=class extends gl{constructor(n,t,r){super(),this.lContainer=n,this.hostLView=t,this.templateTNode=r,this.needsIndexUpdate=!1}get length(){return this.lContainer.length-Ie}at(n){return this.getLView(n)[be].$implicit}attach(n,t){let r=t[ri];this.needsIndexUpdate||=n!==this.length,Fs(this.lContainer,t,n,li(this.templateTNode,r))}detach(n){return this.needsIndexUpdate||=n!==this.length-1,mb(this.lContainer,n)}create(n,t){let r=ui(this.lContainer,this.templateTNode.tView.ssrId);return ou(this.hostLView,this.templateTNode,new vl(this.lContainer,t,n),{dehydratedView:r})}destroy(n){Os(n[k],n)}updateValue(n,t){this.getLView(n)[be].$implicit=t}reset(){this.needsIndexUpdate=!1}updateIndexes(){if(this.needsIndexUpdate)for(let n=0;n(Bl(!0),Rp(r,i,M_()));function gg(){return Q()}var vs="en-US";var _b=vs;function Db(e){typeof e=="string"&&(_b=e.toLowerCase().replace(/_/g,"-"))}function ae(e,n,t,r){let i=Q(),o=qe(),s=We();return Cb(o,i,i[pe],s,e,n,r),ae}function bb(e,n,t,r){let i=e.cleanup;if(i!=null)for(let o=0;oc?a[c]:null}typeof s=="string"&&(o+=2)}return null}function Cb(e,n,t,r,i,o,s){let a=Pl(r),l=e.firstCreatePass&&tD(e),u=n[be],d=eD(n),p=!0;if(r.type&3||s){let v=Ge(r,n),D=s?s(v):v,C=d.length,ie=s?J=>s(ht(J[r.index])):r.index,P=null;if(!s&&a&&(P=bb(e,n,i,r.index)),P!==null){let J=P.__ngLastListenerFn__||P;J.__ngNextListenerFn__=o,P.__ngLastListenerFn__=o,p=!1}else{o=ph(r,n,u,o,!1);let J=t.listen(D,i,o);d.push(o,J),l&&l.push(i,ie,C,C+1)}}else o=ph(r,n,u,o,!1);let f=r.outputs,w;if(p&&f!==null&&(w=f[i])){let v=w.length;if(v)for(let D=0;D-1?jt(e.index,n):n;su(a);let c=hh(n,t,r,s),l=o.__ngNextListenerFn__;for(;l;)c=hh(n,t,l,s)&&c,l=l.__ngNextListenerFn__;return i&&c===!1&&s.preventDefault(),c}}function st(e=1){return I_(e)}function $s(e,n,t,r,i){let o=Q(),s=fg(o,n,t,r);if(s!==vn){let a=qe(),c=$l();Zp(a,c,o,e,s,o[pe],i,!1)}return $s}function _(e,n=""){let t=Q(),r=qe(),i=e+nt,o=r.firstCreatePass?Ps(r,i,1,n,null):r.data[i],s=Eb(r,t,o,n,e);t[i]=s,Ul()&&eu(r,t,s,o),mi(o,!1)}var Eb=(e,n,t,r,i)=>(Bl(!0),l0(n[pe],r));function _i(e){return gr("",e,""),_i}function gr(e,n,t){let r=Q(),i=fg(r,e,n,t);return i!==vn&&nD(r,gn(),i),gr}function Ib(e,n,t){let r=qe();if(r.firstCreatePass){let i=kt(e);bl(t,r.data,r.blueprint,i,!0),bl(n,r.data,r.blueprint,i,!1)}}function bl(e,n,t,r,i){if(e=Ee(e),Array.isArray(e))for(let o=0;o>20;if(or(e)||!e.multi){let f=new un(l,i,K),w=Fc(c,n,i?u:u+p,d);w===-1?(Zc(cs(a,s),o,c),kc(o,e,n.length),n.push(c),a.directiveStart++,a.directiveEnd++,i&&(a.providerIndexes+=1048576),t.push(f),s.push(f)):(t[w]=f,s[w]=f)}else{let f=Fc(c,n,u+p,d),w=Fc(c,n,u,u+p),v=f>=0&&t[f],D=w>=0&&t[w];if(i&&!D||!i&&!v){Zc(cs(a,s),o,c);let C=xb(i?Sb:Mb,t.length,i,r,l);!i&&D&&(t[w].providerFactory=C),kc(o,e,n.length,0),n.push(c),a.directiveStart++,a.directiveEnd++,i&&(a.providerIndexes+=1048576),t.push(C),s.push(C)}else{let C=mg(t[i?w:f],l,!i&&r);kc(o,e,f>-1?f:w,C)}!i&&r&&D&&t[w].componentProviders++}}}function kc(e,n,t,r){let i=or(n),o=Hw(n);if(i||o){let c=(o?Ee(n.useClass):n).prototype.ngOnDestroy;if(c){let l=e.destroyHooks||(e.destroyHooks=[]);if(!i&&n.multi){let u=l.indexOf(t);u===-1?l.push(t,[r,c]):l[u+1].push(r,c)}else l.push(t,c)}}}function mg(e,n,t){return t&&e.componentProviders++,e.multi.push(n)-1}function Fc(e,n,t,r){for(let i=t;i{t.providersResolver=(r,i)=>Ib(r,i?i(e):e,n)}}var Tb=(()=>{class e{constructor(t){this._injector=t,this.cachedInjectors=new Map}getOrCreateStandaloneInjector(t){if(!t.standalone)return null;if(!this.cachedInjectors.has(t)){let r=Lh(!1,t.type),i=r.length>0?lu([r],this._injector,`Standalone[${t.type.name}]`):null;this.cachedInjectors.set(t,i)}return this.cachedInjectors.get(t)}ngOnDestroy(){try{for(let t of this.cachedInjectors.values())t!==null&&t.destroy()}finally{this.cachedInjectors.clear()}}static{this.\u0275prov=I({token:e,providedIn:"environment",factory:()=>new e(O(Te))})}}return e})();function Z(e){wn("NgStandalone"),e.getStandaloneInjector=n=>n.get(Tb).getOrCreateStandaloneInjector(e)}var Bs=(()=>{class e{log(t){console.log(t)}warn(t){console.warn(t)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"platform"})}}return e})();var vg=new M("");function Dn(e){return!!e&&typeof e.then=="function"}function yg(e){return!!e&&typeof e.subscribe=="function"}var wg=new M(""),_g=(()=>{class e{constructor(){this.initialized=!1,this.done=!1,this.donePromise=new Promise((t,r)=>{this.resolve=t,this.reject=r}),this.appInits=m(wg,{optional:!0})??[]}runInitializers(){if(this.initialized)return;let t=[];for(let i of this.appInits){let o=i();if(Dn(o))t.push(o);else if(yg(o)){let s=new Promise((a,c)=>{o.subscribe({complete:a,error:c})});t.push(s)}}let r=()=>{this.done=!0,this.resolve()};Promise.all(t).then(()=>{r()}).catch(i=>{this.reject(i)}),t.length===0&&r(),this.initialized=!0}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),Hs=new M("");function Ab(){rf(()=>{throw new E(600,!1)})}function Ob(e){return e.isBoundToModule}function Nb(e,n,t){try{let r=t();return Dn(r)?r.catch(i=>{throw n.runOutsideAngular(()=>e.handleError(i)),i}):r}catch(r){throw n.runOutsideAngular(()=>e.handleError(r)),r}}var mr=(()=>{class e{constructor(){this._bootstrapListeners=[],this._runningTick=!1,this._destroyed=!1,this._destroyListeners=[],this._views=[],this.internalErrorHandler=m(Dp),this.afterRenderEffectManager=m(lg),this.externalTestViews=new Set,this.beforeRender=new _e,this.afterTick=new _e,this.componentTypes=[],this.components=[],this.isStable=m(_n).hasPendingTasks.pipe(N(t=>!t)),this._injector=m(Te)}get destroyed(){return this._destroyed}get injector(){return this._injector}bootstrap(t,r){let i=t instanceof fs;if(!this._injector.get(_g).done){let p=!i&&Rh(t),f=!1;throw new E(405,f)}let s;i?s=t:s=this._injector.get(Ls).resolveComponentFactory(t),this.componentTypes.push(s.componentType);let a=Ob(s)?void 0:this._injector.get(Ft),c=r||s.selector,l=s.create(mn.NULL,[],c,a),u=l.location.nativeElement,d=l.injector.get(vg,null);return d?.registerApplication(u),l.onDestroy(()=>{this.detachView(l.hostView),Lc(this.components,l),d?.unregisterApplication(u)}),this._loadComponent(l),l}tick(){this._tick(!0)}_tick(t){if(this._runningTick)throw new E(101,!1);let r=V(null);try{this._runningTick=!0,this.detectChangesInAttachedViews(t)}catch(i){this.internalErrorHandler(i)}finally{this.afterTick.next(),this._runningTick=!1,V(r)}}detectChangesInAttachedViews(t){let r=0,i=this.afterRenderEffectManager;for(;;){if(r===ig)throw new E(103,!1);if(t){let o=r===0;this.beforeRender.next(o);for(let{_lView:s,notifyErrorHandler:a}of this._views)Rb(s,o,a)}if(r++,i.executeInternalCallbacks(),![...this.externalTestViews.keys(),...this._views].some(({_lView:o})=>El(o))&&(i.execute(),![...this.externalTestViews.keys(),...this._views].some(({_lView:o})=>El(o))))break}}attachView(t){let r=t;this._views.push(r),r.attachToAppRef(this)}detachView(t){let r=t;Lc(this._views,r),r.detachFromAppRef()}_loadComponent(t){this.attachView(t.hostView),this.tick(),this.components.push(t);let r=this._injector.get(Hs,[]);[...this._bootstrapListeners,...r].forEach(i=>i(t))}ngOnDestroy(){if(!this._destroyed)try{this._destroyListeners.forEach(t=>t()),this._views.slice().forEach(t=>t.destroy())}finally{this._destroyed=!0,this._views=[],this._bootstrapListeners=[],this._destroyListeners=[]}}onDestroy(t){return this._destroyListeners.push(t),()=>Lc(this._destroyListeners,t)}destroy(){if(this._destroyed)throw new E(406,!1);let t=this._injector;t.destroy&&!t.destroyed&&t.destroy()}get viewCount(){return this._views.length}warnIfDestroyed(){}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function Lc(e,n){let t=e.indexOf(n);t>-1&&e.splice(t,1)}function Rb(e,n,t){!n&&!El(e)||Pb(e,t,n)}function El(e){return Ll(e)}function Pb(e,n,t){let r;t?(r=0,e[S]|=1024):e[S]&64?r=0:r=1,og(e,n,r)}var Il=class{constructor(n,t){this.ngModuleFactory=n,this.componentFactories=t}},uu=(()=>{class e{compileModuleSync(t){return new fl(t)}compileModuleAsync(t){return Promise.resolve(this.compileModuleSync(t))}compileModuleAndAllComponentsSync(t){let r=this.compileModuleSync(t),i=Ph(t),o=Np(i.declarations).reduce((s,a)=>{let c=sn(a);return c&&s.push(new fi(c)),s},[]);return new Il(r,o)}compileModuleAndAllComponentsAsync(t){return Promise.resolve(this.compileModuleAndAllComponentsSync(t))}clearCache(){}clearCacheFor(t){}getModuleId(t){}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var kb=(()=>{class e{constructor(){this.zone=m(ne),this.applicationRef=m(mr)}initialize(){this._onMicrotaskEmptySubscription||(this._onMicrotaskEmptySubscription=this.zone.onMicrotaskEmpty.subscribe({next:()=>{this.zone.run(()=>{this.applicationRef.tick()})}}))}ngOnDestroy(){this._onMicrotaskEmptySubscription?.unsubscribe()}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function Fb(e){return[{provide:ne,useFactory:e},{provide:ir,multi:!0,useFactory:()=>{let n=m(kb,{optional:!0});return()=>n.initialize()}},{provide:ir,multi:!0,useFactory:()=>{let n=m($b);return()=>{n.initialize()}}},{provide:Dp,useFactory:Lb}]}function Lb(){let e=m(ne),n=m(rt);return t=>e.runOutsideAngular(()=>n.handleError(t))}function jb(e){let n=Fb(()=>new ne(Vb(e)));return fr([[],n])}function Vb(e){return{enableLongStackTrace:!1,shouldCoalesceEventChangeDetection:e?.eventCoalescing??!1,shouldCoalesceRunChangeDetection:e?.runCoalescing??!1}}var $b=(()=>{class e{constructor(){this.subscription=new le,this.initialized=!1,this.zone=m(ne),this.pendingTasks=m(_n)}initialize(){if(this.initialized)return;this.initialized=!0;let t=null;!this.zone.isStable&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(t=this.pendingTasks.add()),this.zone.runOutsideAngular(()=>{this.subscription.add(this.zone.onStable.subscribe(()=>{ne.assertNotInAngularZone(),queueMicrotask(()=>{t!==null&&!this.zone.hasPendingMacrotasks&&!this.zone.hasPendingMicrotasks&&(this.pendingTasks.remove(t),t=null)})}))}),this.subscription.add(this.zone.onUnstable.subscribe(()=>{ne.assertInAngularZone(),t??=this.pendingTasks.add()}))}ngOnDestroy(){this.subscription.unsubscribe()}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function Ub(){return typeof $localize<"u"&&$localize.locale||vs}var du=new M("",{providedIn:"root",factory:()=>m(du,L.Optional|L.SkipSelf)||Ub()});var Dg=new M("");var Jo=null;function Bb(e=[],n){return mn.create({name:n,providers:[{provide:Cs,useValue:"platform"},{provide:Dg,useValue:new Set([()=>Jo=null])},...e]})}function Hb(e=[]){if(Jo)return Jo;let n=Bb(e);return Jo=n,Ab(),zb(n),n}function zb(e){e.get(Zl,null)?.forEach(t=>t())}var bn=(()=>{class e{static{this.__NG_ELEMENT_ID__=Gb}}return e})();function Gb(e){return qb(We(),Q(),(e&16)===16)}function qb(e,n,t){if(Ms(e)&&!t){let r=jt(e.index,n);return new lr(r,r)}else if(e.type&47){let r=n[tt];return new lr(r,n)}return null}function bg(e){try{let{rootComponent:n,appProviders:t,platformProviders:r}=e,i=Hb(r),o=[jb(),...t||[]],a=new ps({providers:o,parent:i,debugName:"",runEnvironmentInitializers:!1}).injector,c=a.get(ne);return c.run(()=>{a.resolveInjectorInitializers();let l=a.get(rt,null),u;c.runOutsideAngular(()=>{u=c.onError.subscribe({next:f=>{l.handleError(f)}})});let d=()=>a.destroy(),p=i.get(Dg);return p.add(d),a.onDestroy(()=>{u.unsubscribe(),p.delete(d)}),Nb(l,c,()=>{let f=a.get(_g);return f.runInitializers(),f.donePromise.then(()=>{let w=a.get(du,vs);Db(w||vs);let v=a.get(mr);return n!==void 0&&v.bootstrap(n),v})})})}catch(n){return Promise.reject(n)}}function vr(e){return typeof e=="boolean"?e:e!=null&&e!=="false"}var Wb=new M("",{providedIn:"root",factory:()=>m(Zb)}),Zb=(()=>{class e{static{this.\u0275prov=I({token:e,providedIn:"root",factory:()=>new Ml})}}return e})(),Ml=class{constructor(){this.queuedEffectCount=0,this.queues=new Map,this.pendingTasks=m(_n),this.taskId=null}scheduleEffect(n){if(this.enqueue(n),this.taskId===null){let t=this.taskId=this.pendingTasks.add();queueMicrotask(()=>{this.flush(),this.pendingTasks.remove(t),this.taskId=null})}}enqueue(n){let t=n.creationZone;this.queues.has(t)||this.queues.set(t,new Set);let r=this.queues.get(t);r.has(n)||(this.queuedEffectCount++,r.add(n))}flush(){for(;this.queuedEffectCount>0;)for(let[n,t]of this.queues)n===null?this.flushQueue(t):n.run(()=>this.flushQueue(t))}flushQueue(n){for(let t of n)n.delete(t),this.queuedEffectCount--,t.run()}},Sl=class{constructor(n,t,r,i,o,s){this.scheduler=n,this.effectFn=t,this.creationZone=r,this.injector=o,this.watcher=af(a=>this.runEffect(a),()=>this.schedule(),s),this.unregisterOnDestroy=i?.onDestroy(()=>this.destroy())}runEffect(n){try{this.effectFn(n)}catch(t){this.injector.get(rt,null,{optional:!0})?.handleError(t)}}run(){this.watcher.run()}schedule(){this.scheduler.scheduleEffect(this)}destroy(){this.watcher.destroy(),this.unregisterOnDestroy?.()}};function fu(e,n){wn("NgSignals"),!n?.injector&&Qw(fu);let t=n?.injector??m(mn),r=n?.manualCleanup!==!0?t.get(Ss):null,i=new Sl(t.get(Wb),e,typeof Zone>"u"?null:Zone.current,r,t,n?.allowSignalWrites??!1),o=t.get(bn,null,{optional:!0});return!o||!(o._lView[S]&8)?i.watcher.notify():(o._lView[Zo]??=[]).push(i.watcher.notify),i}var Ig=null;function It(){return Ig}function Mg(e){Ig??=e}var zs=class{};var Ae=new M(""),Sg=(()=>{class e{historyGo(t){throw new Error("")}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:()=>m(Yb),providedIn:"platform"})}}return e})();var Yb=(()=>{class e extends Sg{constructor(){super(),this._doc=m(Ae),this._location=window.location,this._history=window.history}getBaseHrefFromDOM(){return It().getBaseHref(this._doc)}onPopState(t){let r=It().getGlobalEventTarget(this._doc,"window");return r.addEventListener("popstate",t,!1),()=>r.removeEventListener("popstate",t)}onHashChange(t){let r=It().getGlobalEventTarget(this._doc,"window");return r.addEventListener("hashchange",t,!1),()=>r.removeEventListener("hashchange",t)}get href(){return this._location.href}get protocol(){return this._location.protocol}get hostname(){return this._location.hostname}get port(){return this._location.port}get pathname(){return this._location.pathname}get search(){return this._location.search}get hash(){return this._location.hash}set pathname(t){this._location.pathname=t}pushState(t,r,i){this._history.pushState(t,r,i)}replaceState(t,r,i){this._history.replaceState(t,r,i)}forward(){this._history.forward()}back(){this._history.back()}historyGo(t=0){this._history.go(t)}getState(){return this._history.state}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:()=>new e,providedIn:"platform"})}}return e})();function xg(e,n){if(e.length==0)return n;if(n.length==0)return e;let t=0;return e.endsWith("/")&&t++,n.startsWith("/")&&t++,t==2?e+n.substring(1):t==1?e+n:e+"/"+n}function Cg(e){let n=e.match(/#|\?|$/),t=n&&n.index||e.length,r=t-(e[t-1]==="/"?1:0);return e.slice(0,r)+e.slice(t)}function Cn(e){return e&&e[0]!=="?"?"?"+e:e}var wr=(()=>{class e{historyGo(t){throw new Error("")}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:()=>m(Tg),providedIn:"root"})}}return e})(),Qb=new M(""),Tg=(()=>{class e extends wr{constructor(t,r){super(),this._platformLocation=t,this._removeListenerFns=[],this._baseHref=r??this._platformLocation.getBaseHrefFromDOM()??m(Ae).location?.origin??""}ngOnDestroy(){for(;this._removeListenerFns.length;)this._removeListenerFns.pop()()}onPopState(t){this._removeListenerFns.push(this._platformLocation.onPopState(t),this._platformLocation.onHashChange(t))}getBaseHref(){return this._baseHref}prepareExternalUrl(t){return xg(this._baseHref,t)}path(t=!1){let r=this._platformLocation.pathname+Cn(this._platformLocation.search),i=this._platformLocation.hash;return i&&t?`${r}${i}`:r}pushState(t,r,i,o){let s=this.prepareExternalUrl(i+Cn(o));this._platformLocation.pushState(t,r,s)}replaceState(t,r,i,o){let s=this.prepareExternalUrl(i+Cn(o));this._platformLocation.replaceState(t,r,s)}forward(){this._platformLocation.forward()}back(){this._platformLocation.back()}getState(){return this._platformLocation.getState()}historyGo(t=0){this._platformLocation.historyGo?.(t)}static{this.\u0275fac=function(r){return new(r||e)(O(Sg),O(Qb,8))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var Di=(()=>{class e{constructor(t){this._subject=new De,this._urlChangeListeners=[],this._urlChangeSubscription=null,this._locationStrategy=t;let r=this._locationStrategy.getBaseHref();this._basePath=Xb(Cg(Eg(r))),this._locationStrategy.onPopState(i=>{this._subject.emit({url:this.path(!0),pop:!0,state:i.state,type:i.type})})}ngOnDestroy(){this._urlChangeSubscription?.unsubscribe(),this._urlChangeListeners=[]}path(t=!1){return this.normalize(this._locationStrategy.path(t))}getState(){return this._locationStrategy.getState()}isCurrentPathEqualTo(t,r=""){return this.path()==this.normalize(t+Cn(r))}normalize(t){return e.stripTrailingSlash(Jb(this._basePath,Eg(t)))}prepareExternalUrl(t){return t&&t[0]!=="/"&&(t="/"+t),this._locationStrategy.prepareExternalUrl(t)}go(t,r="",i=null){this._locationStrategy.pushState(i,"",t,r),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Cn(r)),i)}replaceState(t,r="",i=null){this._locationStrategy.replaceState(i,"",t,r),this._notifyUrlChangeListeners(this.prepareExternalUrl(t+Cn(r)),i)}forward(){this._locationStrategy.forward()}back(){this._locationStrategy.back()}historyGo(t=0){this._locationStrategy.historyGo?.(t)}onUrlChange(t){return this._urlChangeListeners.push(t),this._urlChangeSubscription??=this.subscribe(r=>{this._notifyUrlChangeListeners(r.url,r.state)}),()=>{let r=this._urlChangeListeners.indexOf(t);this._urlChangeListeners.splice(r,1),this._urlChangeListeners.length===0&&(this._urlChangeSubscription?.unsubscribe(),this._urlChangeSubscription=null)}}_notifyUrlChangeListeners(t="",r){this._urlChangeListeners.forEach(i=>i(t,r))}subscribe(t,r,i){return this._subject.subscribe({next:t,error:r,complete:i})}static{this.normalizeQueryParams=Cn}static{this.joinWithSlash=xg}static{this.stripTrailingSlash=Cg}static{this.\u0275fac=function(r){return new(r||e)(O(wr))}}static{this.\u0275prov=I({token:e,factory:()=>Kb(),providedIn:"root"})}}return e})();function Kb(){return new Di(O(wr))}function Jb(e,n){if(!e||!n.startsWith(e))return n;let t=n.substring(e.length);return t===""||["/",";","?","#"].includes(t[0])?t:n}function Eg(e){return e.replace(/\/index.html$/,"")}function Xb(e){if(new RegExp("^(https?:)?//").test(e)){let[,t]=e.split(/\/\/[^\/]+/);return t}return e}function Gs(e,n){n=encodeURIComponent(n);for(let t of e.split(";")){let r=t.indexOf("="),[i,o]=r==-1?[t,""]:[t.slice(0,r),t.slice(r+1)];if(i.trim()===n)return decodeURIComponent(o)}return null}var Ag="browser",eC="server";function qs(e){return e===eC}var yr=class{};var Ci=class{},Zs=class{},En=class e{constructor(n){this.normalizedNames=new Map,this.lazyUpdate=null,n?typeof n=="string"?this.lazyInit=()=>{this.headers=new Map,n.split(` -`).forEach(t=>{let r=t.indexOf(":");if(r>0){let i=t.slice(0,r),o=i.toLowerCase(),s=t.slice(r+1).trim();this.maybeSetNormalizedName(i,o),this.headers.has(o)?this.headers.get(o).push(s):this.headers.set(o,[s])}})}:typeof Headers<"u"&&n instanceof Headers?(this.headers=new Map,n.forEach((t,r)=>{this.setHeaderEntries(r,t)})):this.lazyInit=()=>{this.headers=new Map,Object.entries(n).forEach(([t,r])=>{this.setHeaderEntries(t,r)})}:this.headers=new Map}has(n){return this.init(),this.headers.has(n.toLowerCase())}get(n){this.init();let t=this.headers.get(n.toLowerCase());return t&&t.length>0?t[0]:null}keys(){return this.init(),Array.from(this.normalizedNames.values())}getAll(n){return this.init(),this.headers.get(n.toLowerCase())||null}append(n,t){return this.clone({name:n,value:t,op:"a"})}set(n,t){return this.clone({name:n,value:t,op:"s"})}delete(n,t){return this.clone({name:n,value:t,op:"d"})}maybeSetNormalizedName(n,t){this.normalizedNames.has(t)||this.normalizedNames.set(t,n)}init(){this.lazyInit&&(this.lazyInit instanceof e?this.copyFrom(this.lazyInit):this.lazyInit(),this.lazyInit=null,this.lazyUpdate&&(this.lazyUpdate.forEach(n=>this.applyUpdate(n)),this.lazyUpdate=null))}copyFrom(n){n.init(),Array.from(n.headers.keys()).forEach(t=>{this.headers.set(t,n.headers.get(t)),this.normalizedNames.set(t,n.normalizedNames.get(t))})}clone(n){let t=new e;return t.lazyInit=this.lazyInit&&this.lazyInit instanceof e?this.lazyInit:this,t.lazyUpdate=(this.lazyUpdate||[]).concat([n]),t}applyUpdate(n){let t=n.name.toLowerCase();switch(n.op){case"a":case"s":let r=n.value;if(typeof r=="string"&&(r=[r]),r.length===0)return;this.maybeSetNormalizedName(n.name,t);let i=(n.op==="a"?this.headers.get(t):void 0)||[];i.push(...r),this.headers.set(t,i);break;case"d":let o=n.value;if(!o)this.headers.delete(t),this.normalizedNames.delete(t);else{let s=this.headers.get(t);if(!s)return;s=s.filter(a=>o.indexOf(a)===-1),s.length===0?(this.headers.delete(t),this.normalizedNames.delete(t)):this.headers.set(t,s)}break}}setHeaderEntries(n,t){let r=(Array.isArray(t)?t:[t]).map(o=>o.toString()),i=n.toLowerCase();this.headers.set(i,r),this.maybeSetNormalizedName(n,i)}forEach(n){this.init(),Array.from(this.normalizedNames.keys()).forEach(t=>n(this.normalizedNames.get(t),this.headers.get(t)))}};var gu=class{encodeKey(n){return Ng(n)}encodeValue(n){return Ng(n)}decodeKey(n){return decodeURIComponent(n)}decodeValue(n){return decodeURIComponent(n)}};function rC(e,n){let t=new Map;return e.length>0&&e.replace(/^\?/,"").split("&").forEach(i=>{let o=i.indexOf("="),[s,a]=o==-1?[n.decodeKey(i),""]:[n.decodeKey(i.slice(0,o)),n.decodeValue(i.slice(o+1))],c=t.get(s)||[];c.push(a),t.set(s,c)}),t}var iC=/%(\d[a-f0-9])/gi,oC={40:"@","3A":":",24:"$","2C":",","3B":";","3D":"=","3F":"?","2F":"/"};function Ng(e){return encodeURIComponent(e).replace(iC,(n,t)=>oC[t]??n)}function Ws(e){return`${e}`}var Bt=class e{constructor(n={}){if(this.updates=null,this.cloneFrom=null,this.encoder=n.encoder||new gu,n.fromString){if(n.fromObject)throw new Error("Cannot specify both fromString and fromObject.");this.map=rC(n.fromString,this.encoder)}else n.fromObject?(this.map=new Map,Object.keys(n.fromObject).forEach(t=>{let r=n.fromObject[t],i=Array.isArray(r)?r.map(Ws):[Ws(r)];this.map.set(t,i)})):this.map=null}has(n){return this.init(),this.map.has(n)}get(n){this.init();let t=this.map.get(n);return t?t[0]:null}getAll(n){return this.init(),this.map.get(n)||null}keys(){return this.init(),Array.from(this.map.keys())}append(n,t){return this.clone({param:n,value:t,op:"a"})}appendAll(n){let t=[];return Object.keys(n).forEach(r=>{let i=n[r];Array.isArray(i)?i.forEach(o=>{t.push({param:r,value:o,op:"a"})}):t.push({param:r,value:i,op:"a"})}),this.clone(t)}set(n,t){return this.clone({param:n,value:t,op:"s"})}delete(n,t){return this.clone({param:n,value:t,op:"d"})}toString(){return this.init(),this.keys().map(n=>{let t=this.encoder.encodeKey(n);return this.map.get(n).map(r=>t+"="+this.encoder.encodeValue(r)).join("&")}).filter(n=>n!=="").join("&")}clone(n){let t=new e({encoder:this.encoder});return t.cloneFrom=this.cloneFrom||this,t.updates=(this.updates||[]).concat(n),t}init(){this.map===null&&(this.map=new Map),this.cloneFrom!==null&&(this.cloneFrom.init(),this.cloneFrom.keys().forEach(n=>this.map.set(n,this.cloneFrom.map.get(n))),this.updates.forEach(n=>{switch(n.op){case"a":case"s":let t=(n.op==="a"?this.map.get(n.param):void 0)||[];t.push(Ws(n.value)),this.map.set(n.param,t);break;case"d":if(n.value!==void 0){let r=this.map.get(n.param)||[],i=r.indexOf(Ws(n.value));i!==-1&&r.splice(i,1),r.length>0?this.map.set(n.param,r):this.map.delete(n.param)}else{this.map.delete(n.param);break}}}),this.cloneFrom=this.updates=null)}};var mu=class{constructor(){this.map=new Map}set(n,t){return this.map.set(n,t),this}get(n){return this.map.has(n)||this.map.set(n,n.defaultValue()),this.map.get(n)}delete(n){return this.map.delete(n),this}has(n){return this.map.has(n)}keys(){return this.map.keys()}};function sC(e){switch(e){case"DELETE":case"GET":case"HEAD":case"OPTIONS":case"JSONP":return!1;default:return!0}}function Rg(e){return typeof ArrayBuffer<"u"&&e instanceof ArrayBuffer}function Pg(e){return typeof Blob<"u"&&e instanceof Blob}function kg(e){return typeof FormData<"u"&&e instanceof FormData}function aC(e){return typeof URLSearchParams<"u"&&e instanceof URLSearchParams}var bi=class e{constructor(n,t,r,i){this.url=t,this.body=null,this.reportProgress=!1,this.withCredentials=!1,this.responseType="json",this.method=n.toUpperCase();let o;if(sC(this.method)||i?(this.body=r!==void 0?r:null,o=i):o=r,o&&(this.reportProgress=!!o.reportProgress,this.withCredentials=!!o.withCredentials,o.responseType&&(this.responseType=o.responseType),o.headers&&(this.headers=o.headers),o.context&&(this.context=o.context),o.params&&(this.params=o.params),this.transferCache=o.transferCache),this.headers??=new En,this.context??=new mu,!this.params)this.params=new Bt,this.urlWithParams=t;else{let s=this.params.toString();if(s.length===0)this.urlWithParams=t;else{let a=t.indexOf("?"),c=a===-1?"?":ap.set(f,n.setHeaders[f]),l)),n.setParams&&(u=Object.keys(n.setParams).reduce((p,f)=>p.set(f,n.setParams[f]),u)),new e(t,r,s,{params:u,headers:l,context:d,reportProgress:c,responseType:i,withCredentials:a,transferCache:o})}},_r=function(e){return e[e.Sent=0]="Sent",e[e.UploadProgress=1]="UploadProgress",e[e.ResponseHeader=2]="ResponseHeader",e[e.DownloadProgress=3]="DownloadProgress",e[e.Response=4]="Response",e[e.User=5]="User",e}(_r||{}),Ei=class{constructor(n,t=Ks.Ok,r="OK"){this.headers=n.headers||new En,this.status=n.status!==void 0?n.status:t,this.statusText=n.statusText||r,this.url=n.url||null,this.ok=this.status>=200&&this.status<300}},vu=class e extends Ei{constructor(n={}){super(n),this.type=_r.ResponseHeader}clone(n={}){return new e({headers:n.headers||this.headers,status:n.status!==void 0?n.status:this.status,statusText:n.statusText||this.statusText,url:n.url||this.url||void 0})}},Ys=class e extends Ei{constructor(n={}){super(n),this.type=_r.Response,this.body=n.body!==void 0?n.body:null}clone(n={}){return new e({body:n.body!==void 0?n.body:this.body,headers:n.headers||this.headers,status:n.status!==void 0?n.status:this.status,statusText:n.statusText||this.statusText,url:n.url||this.url||void 0})}},Qs=class extends Ei{constructor(n){super(n,0,"Unknown Error"),this.name="HttpErrorResponse",this.ok=!1,this.status>=200&&this.status<300?this.message=`Http failure during parsing for ${n.url||"(unknown url)"}`:this.message=`Http failure response for ${n.url||"(unknown url)"}: ${n.status} ${n.statusText}`,this.error=n.error||null}},Ks=function(e){return e[e.Continue=100]="Continue",e[e.SwitchingProtocols=101]="SwitchingProtocols",e[e.Processing=102]="Processing",e[e.EarlyHints=103]="EarlyHints",e[e.Ok=200]="Ok",e[e.Created=201]="Created",e[e.Accepted=202]="Accepted",e[e.NonAuthoritativeInformation=203]="NonAuthoritativeInformation",e[e.NoContent=204]="NoContent",e[e.ResetContent=205]="ResetContent",e[e.PartialContent=206]="PartialContent",e[e.MultiStatus=207]="MultiStatus",e[e.AlreadyReported=208]="AlreadyReported",e[e.ImUsed=226]="ImUsed",e[e.MultipleChoices=300]="MultipleChoices",e[e.MovedPermanently=301]="MovedPermanently",e[e.Found=302]="Found",e[e.SeeOther=303]="SeeOther",e[e.NotModified=304]="NotModified",e[e.UseProxy=305]="UseProxy",e[e.Unused=306]="Unused",e[e.TemporaryRedirect=307]="TemporaryRedirect",e[e.PermanentRedirect=308]="PermanentRedirect",e[e.BadRequest=400]="BadRequest",e[e.Unauthorized=401]="Unauthorized",e[e.PaymentRequired=402]="PaymentRequired",e[e.Forbidden=403]="Forbidden",e[e.NotFound=404]="NotFound",e[e.MethodNotAllowed=405]="MethodNotAllowed",e[e.NotAcceptable=406]="NotAcceptable",e[e.ProxyAuthenticationRequired=407]="ProxyAuthenticationRequired",e[e.RequestTimeout=408]="RequestTimeout",e[e.Conflict=409]="Conflict",e[e.Gone=410]="Gone",e[e.LengthRequired=411]="LengthRequired",e[e.PreconditionFailed=412]="PreconditionFailed",e[e.PayloadTooLarge=413]="PayloadTooLarge",e[e.UriTooLong=414]="UriTooLong",e[e.UnsupportedMediaType=415]="UnsupportedMediaType",e[e.RangeNotSatisfiable=416]="RangeNotSatisfiable",e[e.ExpectationFailed=417]="ExpectationFailed",e[e.ImATeapot=418]="ImATeapot",e[e.MisdirectedRequest=421]="MisdirectedRequest",e[e.UnprocessableEntity=422]="UnprocessableEntity",e[e.Locked=423]="Locked",e[e.FailedDependency=424]="FailedDependency",e[e.TooEarly=425]="TooEarly",e[e.UpgradeRequired=426]="UpgradeRequired",e[e.PreconditionRequired=428]="PreconditionRequired",e[e.TooManyRequests=429]="TooManyRequests",e[e.RequestHeaderFieldsTooLarge=431]="RequestHeaderFieldsTooLarge",e[e.UnavailableForLegalReasons=451]="UnavailableForLegalReasons",e[e.InternalServerError=500]="InternalServerError",e[e.NotImplemented=501]="NotImplemented",e[e.BadGateway=502]="BadGateway",e[e.ServiceUnavailable=503]="ServiceUnavailable",e[e.GatewayTimeout=504]="GatewayTimeout",e[e.HttpVersionNotSupported=505]="HttpVersionNotSupported",e[e.VariantAlsoNegotiates=506]="VariantAlsoNegotiates",e[e.InsufficientStorage=507]="InsufficientStorage",e[e.LoopDetected=508]="LoopDetected",e[e.NotExtended=510]="NotExtended",e[e.NetworkAuthenticationRequired=511]="NetworkAuthenticationRequired",e}(Ks||{});function pu(e,n){return{body:n,headers:e.headers,context:e.context,observe:e.observe,params:e.params,reportProgress:e.reportProgress,responseType:e.responseType,withCredentials:e.withCredentials,transferCache:e.transferCache}}var cC=(()=>{class e{constructor(t){this.handler=t}request(t,r,i={}){let o;if(t instanceof bi)o=t;else{let c;i.headers instanceof En?c=i.headers:c=new En(i.headers);let l;i.params&&(i.params instanceof Bt?l=i.params:l=new Bt({fromObject:i.params})),o=new bi(t,r,i.body!==void 0?i.body:null,{headers:c,context:i.context,params:l,reportProgress:i.reportProgress,responseType:i.responseType||"json",withCredentials:i.withCredentials,transferCache:i.transferCache})}let s=x(o).pipe(Ot(c=>this.handler.handle(c)));if(t instanceof bi||i.observe==="events")return s;let a=s.pipe(Fe(c=>c instanceof Ys));switch(i.observe||"body"){case"body":switch(o.responseType){case"arraybuffer":return a.pipe(N(c=>{if(c.body!==null&&!(c.body instanceof ArrayBuffer))throw new Error("Response is not an ArrayBuffer.");return c.body}));case"blob":return a.pipe(N(c=>{if(c.body!==null&&!(c.body instanceof Blob))throw new Error("Response is not a Blob.");return c.body}));case"text":return a.pipe(N(c=>{if(c.body!==null&&typeof c.body!="string")throw new Error("Response is not a string.");return c.body}));case"json":default:return a.pipe(N(c=>c.body))}case"response":return a;default:throw new Error(`Unreachable: unhandled observe type ${i.observe}}`)}}delete(t,r={}){return this.request("DELETE",t,r)}get(t,r={}){return this.request("GET",t,r)}head(t,r={}){return this.request("HEAD",t,r)}jsonp(t,r){return this.request("JSONP",t,{params:new Bt().append(r,"JSONP_CALLBACK"),observe:"body",responseType:"json"})}options(t,r={}){return this.request("OPTIONS",t,r)}patch(t,r,i={}){return this.request("PATCH",t,pu(i,r))}post(t,r,i={}){return this.request("POST",t,pu(i,r))}put(t,r,i={}){return this.request("PUT",t,pu(i,r))}static{this.\u0275fac=function(r){return new(r||e)(O(Ci))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})();function lC(e,n){return n(e)}function uC(e,n,t){return(r,i)=>bt(t,()=>n(r,o=>e(o,i)))}var yu=new M(""),dC=new M(""),fC=new M("");var Fg=(()=>{class e extends Ci{constructor(t,r){super(),this.backend=t,this.injector=r,this.chain=null,this.pendingTasks=m(_n);let i=m(fC,{optional:!0});this.backend=i??t}handle(t){if(this.chain===null){let i=Array.from(new Set([...this.injector.get(yu),...this.injector.get(dC,[])]));this.chain=i.reduceRight((o,s)=>uC(o,s,this.injector),lC)}let r=this.pendingTasks.add();return this.chain(t,i=>this.backend.handle(i)).pipe(tn(()=>this.pendingTasks.remove(r)))}static{this.\u0275fac=function(r){return new(r||e)(O(Zs),O(Te))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})();var hC=/^\)\]\}',?\n/;function pC(e){return"responseURL"in e&&e.responseURL?e.responseURL:/^X-Request-URL:/m.test(e.getAllResponseHeaders())?e.getResponseHeader("X-Request-URL"):null}var Lg=(()=>{class e{constructor(t){this.xhrFactory=t}handle(t){if(t.method==="JSONP")throw new E(-2800,!1);let r=this.xhrFactory;return(r.\u0275loadImpl?te(r.\u0275loadImpl()):x(null)).pipe(Le(()=>new z(o=>{let s=r.build();if(s.open(t.method,t.urlWithParams),t.withCredentials&&(s.withCredentials=!0),t.headers.forEach((v,D)=>s.setRequestHeader(v,D.join(","))),t.headers.has("Accept")||s.setRequestHeader("Accept","application/json, text/plain, */*"),!t.headers.has("Content-Type")){let v=t.detectContentTypeHeader();v!==null&&s.setRequestHeader("Content-Type",v)}if(t.responseType){let v=t.responseType.toLowerCase();s.responseType=v!=="json"?v:"text"}let a=t.serializeBody(),c=null,l=()=>{if(c!==null)return c;let v=s.statusText||"OK",D=new En(s.getAllResponseHeaders()),C=pC(s)||t.url;return c=new vu({headers:D,status:s.status,statusText:v,url:C}),c},u=()=>{let{headers:v,status:D,statusText:C,url:ie}=l(),P=null;D!==Ks.NoContent&&(P=typeof s.response>"u"?s.responseText:s.response),D===0&&(D=P?Ks.Ok:0);let J=D>=200&&D<300;if(t.responseType==="json"&&typeof P=="string"){let ee=P;P=P.replace(hC,"");try{P=P!==""?JSON.parse(P):null}catch(Re){P=ee,J&&(J=!1,P={error:Re,text:P})}}J?(o.next(new Ys({body:P,headers:v,status:D,statusText:C,url:ie||void 0})),o.complete()):o.error(new Qs({error:P,headers:v,status:D,statusText:C,url:ie||void 0}))},d=v=>{let{url:D}=l(),C=new Qs({error:v,status:s.status||0,statusText:s.statusText||"Unknown Error",url:D||void 0});o.error(C)},p=!1,f=v=>{p||(o.next(l()),p=!0);let D={type:_r.DownloadProgress,loaded:v.loaded};v.lengthComputable&&(D.total=v.total),t.responseType==="text"&&s.responseText&&(D.partialText=s.responseText),o.next(D)},w=v=>{let D={type:_r.UploadProgress,loaded:v.loaded};v.lengthComputable&&(D.total=v.total),o.next(D)};return s.addEventListener("load",u),s.addEventListener("error",d),s.addEventListener("timeout",d),s.addEventListener("abort",d),t.reportProgress&&(s.addEventListener("progress",f),a!==null&&s.upload&&s.upload.addEventListener("progress",w)),s.send(a),o.next({type:_r.Sent}),()=>{s.removeEventListener("error",d),s.removeEventListener("abort",d),s.removeEventListener("load",u),s.removeEventListener("timeout",d),t.reportProgress&&(s.removeEventListener("progress",f),a!==null&&s.upload&&s.upload.removeEventListener("progress",w)),s.readyState!==s.DONE&&s.abort()}})))}static{this.\u0275fac=function(r){return new(r||e)(O(yr))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),jg=new M(""),gC="XSRF-TOKEN",mC=new M("",{providedIn:"root",factory:()=>gC}),vC="X-XSRF-TOKEN",yC=new M("",{providedIn:"root",factory:()=>vC}),Js=class{},wC=(()=>{class e{constructor(t,r,i){this.doc=t,this.platform=r,this.cookieName=i,this.lastCookieString="",this.lastToken=null,this.parseCount=0}getToken(){if(this.platform==="server")return null;let t=this.doc.cookie||"";return t!==this.lastCookieString&&(this.parseCount++,this.lastToken=Gs(t,this.cookieName),this.lastCookieString=t),this.lastToken}static{this.\u0275fac=function(r){return new(r||e)(O(Ae),O($t),O(mC))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})();function _C(e,n){let t=e.url.toLowerCase();if(!m(jg)||e.method==="GET"||e.method==="HEAD"||t.startsWith("http://")||t.startsWith("https://"))return n(e);let r=m(Js).getToken(),i=m(yC);return r!=null&&!e.headers.has(i)&&(e=e.clone({headers:e.headers.set(i,r)})),n(e)}var Vg=function(e){return e[e.Interceptors=0]="Interceptors",e[e.LegacyInterceptors=1]="LegacyInterceptors",e[e.CustomXsrfConfiguration=2]="CustomXsrfConfiguration",e[e.NoXsrfProtection=3]="NoXsrfProtection",e[e.JsonpSupport=4]="JsonpSupport",e[e.RequestsMadeViaParent=5]="RequestsMadeViaParent",e[e.Fetch=6]="Fetch",e}(Vg||{});function DC(e,n){return{\u0275kind:e,\u0275providers:n}}function $g(...e){let n=[cC,Lg,Fg,{provide:Ci,useExisting:Fg},{provide:Zs,useExisting:Lg},{provide:yu,useValue:_C,multi:!0},{provide:jg,useValue:!0},{provide:Js,useClass:wC}];for(let t of e)n.push(...t.\u0275providers);return fr(n)}function Ug(e){return DC(Vg.Interceptors,e.map(n=>({provide:yu,useValue:n,multi:!0})))}var Du=class extends zs{constructor(){super(...arguments),this.supportsDOMEvents=!0}},bu=class e extends Du{static makeCurrent(){Mg(new e)}onAndCancel(n,t,r){return n.addEventListener(t,r),()=>{n.removeEventListener(t,r)}}dispatchEvent(n,t){n.dispatchEvent(t)}remove(n){n.parentNode&&n.parentNode.removeChild(n)}createElement(n,t){return t=t||this.getDefaultDocument(),t.createElement(n)}createHtmlDocument(){return document.implementation.createHTMLDocument("fakeTitle")}getDefaultDocument(){return document}isElementNode(n){return n.nodeType===Node.ELEMENT_NODE}isShadowRoot(n){return n instanceof DocumentFragment}getGlobalEventTarget(n,t){return t==="window"?window:t==="document"?n:t==="body"?n.body:null}getBaseHref(n){let t=CC();return t==null?null:EC(t)}resetBaseElement(){Ii=null}getUserAgent(){return window.navigator.userAgent}getCookie(n){return Gs(document.cookie,n)}},Ii=null;function CC(){return Ii=Ii||document.querySelector("base"),Ii?Ii.getAttribute("href"):null}function EC(e){return new URL(e,document.baseURI).pathname}var IC=(()=>{class e{build(){return new XMLHttpRequest}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),Cu=new M(""),Gg=(()=>{class e{constructor(t,r){this._zone=r,this._eventNameToPlugin=new Map,t.forEach(i=>{i.manager=this}),this._plugins=t.slice().reverse()}addEventListener(t,r,i){return this._findPluginFor(r).addEventListener(t,r,i)}getZone(){return this._zone}_findPluginFor(t){let r=this._eventNameToPlugin.get(t);if(r)return r;if(r=this._plugins.find(o=>o.supports(t)),!r)throw new E(5101,!1);return this._eventNameToPlugin.set(t,r),r}static{this.\u0275fac=function(r){return new(r||e)(O(Cu),O(ne))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),Xs=class{constructor(n){this._doc=n}},wu="ng-app-id",qg=(()=>{class e{constructor(t,r,i,o={}){this.doc=t,this.appId=r,this.nonce=i,this.platformId=o,this.styleRef=new Map,this.hostNodes=new Set,this.styleNodesInDOM=this.collectServerRenderedStyles(),this.platformIsServer=qs(o),this.resetHostNodes()}addStyles(t){for(let r of t)this.changeUsageCount(r,1)===1&&this.onStyleAdded(r)}removeStyles(t){for(let r of t)this.changeUsageCount(r,-1)<=0&&this.onStyleRemoved(r)}ngOnDestroy(){let t=this.styleNodesInDOM;t&&(t.forEach(r=>r.remove()),t.clear());for(let r of this.getAllStyles())this.onStyleRemoved(r);this.resetHostNodes()}addHost(t){this.hostNodes.add(t);for(let r of this.getAllStyles())this.addStyleToHost(t,r)}removeHost(t){this.hostNodes.delete(t)}getAllStyles(){return this.styleRef.keys()}onStyleAdded(t){for(let r of this.hostNodes)this.addStyleToHost(r,t)}onStyleRemoved(t){let r=this.styleRef;r.get(t)?.elements?.forEach(i=>i.remove()),r.delete(t)}collectServerRenderedStyles(){let t=this.doc.head?.querySelectorAll(`style[${wu}="${this.appId}"]`);if(t?.length){let r=new Map;return t.forEach(i=>{i.textContent!=null&&r.set(i.textContent,i)}),r}return null}changeUsageCount(t,r){let i=this.styleRef;if(i.has(t)){let o=i.get(t);return o.usage+=r,o.usage}return i.set(t,{usage:r,elements:[]}),r}getStyleElement(t,r){let i=this.styleNodesInDOM,o=i?.get(r);if(o?.parentNode===t)return i.delete(r),o.removeAttribute(wu),o;{let s=this.doc.createElement("style");return this.nonce&&s.setAttribute("nonce",this.nonce),s.textContent=r,this.platformIsServer&&s.setAttribute(wu,this.appId),t.appendChild(s),s}}addStyleToHost(t,r){let i=this.getStyleElement(t,r),o=this.styleRef,s=o.get(r)?.elements;s?s.push(i):o.set(r,{elements:[i],usage:1})}resetHostNodes(){let t=this.hostNodes;t.clear(),t.add(this.doc.head)}static{this.\u0275fac=function(r){return new(r||e)(O(Ae),O(Wl),O(Yl,8),O($t))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),_u={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/MathML/"},Iu=/%COMP%/g,Wg="%COMP%",MC=`_nghost-${Wg}`,SC=`_ngcontent-${Wg}`,xC=!0,TC=new M("",{providedIn:"root",factory:()=>xC});function AC(e){return SC.replace(Iu,e)}function OC(e){return MC.replace(Iu,e)}function Zg(e,n){return n.map(t=>t.replace(Iu,e))}var Bg=(()=>{class e{constructor(t,r,i,o,s,a,c,l=null){this.eventManager=t,this.sharedStylesHost=r,this.appId=i,this.removeStylesOnCompDestroy=o,this.doc=s,this.platformId=a,this.ngZone=c,this.nonce=l,this.rendererByCompId=new Map,this.platformIsServer=qs(a),this.defaultRenderer=new Mi(t,s,c,this.platformIsServer)}createRenderer(t,r){if(!t||!r)return this.defaultRenderer;this.platformIsServer&&r.encapsulation===ft.ShadowDom&&(r=G(b({},r),{encapsulation:ft.Emulated}));let i=this.getOrCreateRenderer(t,r);return i instanceof ea?i.applyToHost(t):i instanceof Si&&i.applyStyles(),i}getOrCreateRenderer(t,r){let i=this.rendererByCompId,o=i.get(r.id);if(!o){let s=this.doc,a=this.ngZone,c=this.eventManager,l=this.sharedStylesHost,u=this.removeStylesOnCompDestroy,d=this.platformIsServer;switch(r.encapsulation){case ft.Emulated:o=new ea(c,l,r,this.appId,u,s,a,d);break;case ft.ShadowDom:return new Eu(c,l,t,r,s,a,this.nonce,d);default:o=new Si(c,l,r,u,s,a,d);break}i.set(r.id,o)}return o}ngOnDestroy(){this.rendererByCompId.clear()}static{this.\u0275fac=function(r){return new(r||e)(O(Gg),O(qg),O(Wl),O(TC),O(Ae),O($t),O(ne),O(Yl))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),Mi=class{constructor(n,t,r,i){this.eventManager=n,this.doc=t,this.ngZone=r,this.platformIsServer=i,this.data=Object.create(null),this.throwOnSyntheticProps=!0,this.destroyNode=null}destroy(){}createElement(n,t){return t?this.doc.createElementNS(_u[t]||t,n):this.doc.createElement(n)}createComment(n){return this.doc.createComment(n)}createText(n){return this.doc.createTextNode(n)}appendChild(n,t){(Hg(n)?n.content:n).appendChild(t)}insertBefore(n,t,r){n&&(Hg(n)?n.content:n).insertBefore(t,r)}removeChild(n,t){n&&n.removeChild(t)}selectRootElement(n,t){let r=typeof n=="string"?this.doc.querySelector(n):n;if(!r)throw new E(-5104,!1);return t||(r.textContent=""),r}parentNode(n){return n.parentNode}nextSibling(n){return n.nextSibling}setAttribute(n,t,r,i){if(i){t=i+":"+t;let o=_u[i];o?n.setAttributeNS(o,t,r):n.setAttribute(t,r)}else n.setAttribute(t,r)}removeAttribute(n,t,r){if(r){let i=_u[r];i?n.removeAttributeNS(i,t):n.removeAttribute(`${r}:${t}`)}else n.removeAttribute(t)}addClass(n,t){n.classList.add(t)}removeClass(n,t){n.classList.remove(t)}setStyle(n,t,r,i){i&(Dt.DashCase|Dt.Important)?n.style.setProperty(t,r,i&Dt.Important?"important":""):n.style[t]=r}removeStyle(n,t,r){r&Dt.DashCase?n.style.removeProperty(t):n.style[t]=""}setProperty(n,t,r){n!=null&&(n[t]=r)}setValue(n,t){n.nodeValue=t}listen(n,t,r){if(typeof n=="string"&&(n=It().getGlobalEventTarget(this.doc,n),!n))throw new Error(`Unsupported event target ${n} for event ${t}`);return this.eventManager.addEventListener(n,t,this.decoratePreventDefault(r))}decoratePreventDefault(n){return t=>{if(t==="__ngUnwrap__")return n;(this.platformIsServer?this.ngZone.runGuarded(()=>n(t)):n(t))===!1&&t.preventDefault()}}};function Hg(e){return e.tagName==="TEMPLATE"&&e.content!==void 0}var Eu=class extends Mi{constructor(n,t,r,i,o,s,a,c){super(n,o,s,c),this.sharedStylesHost=t,this.hostEl=r,this.shadowRoot=r.attachShadow({mode:"open"}),this.sharedStylesHost.addHost(this.shadowRoot);let l=Zg(i.id,i.styles);for(let u of l){let d=document.createElement("style");a&&d.setAttribute("nonce",a),d.textContent=u,this.shadowRoot.appendChild(d)}}nodeOrShadowRoot(n){return n===this.hostEl?this.shadowRoot:n}appendChild(n,t){return super.appendChild(this.nodeOrShadowRoot(n),t)}insertBefore(n,t,r){return super.insertBefore(this.nodeOrShadowRoot(n),t,r)}removeChild(n,t){return super.removeChild(this.nodeOrShadowRoot(n),t)}parentNode(n){return this.nodeOrShadowRoot(super.parentNode(this.nodeOrShadowRoot(n)))}destroy(){this.sharedStylesHost.removeHost(this.shadowRoot)}},Si=class extends Mi{constructor(n,t,r,i,o,s,a,c){super(n,o,s,a),this.sharedStylesHost=t,this.removeStylesOnCompDestroy=i,this.styles=c?Zg(c,r.styles):r.styles}applyStyles(){this.sharedStylesHost.addStyles(this.styles)}destroy(){this.removeStylesOnCompDestroy&&this.sharedStylesHost.removeStyles(this.styles)}},ea=class extends Si{constructor(n,t,r,i,o,s,a,c){let l=i+"-"+r.id;super(n,t,r,o,s,a,c,l),this.contentAttr=AC(l),this.hostAttr=OC(l)}applyToHost(n){this.applyStyles(),this.setAttribute(n,this.hostAttr,"")}createElement(n,t){let r=super.createElement(n,t);return super.setAttribute(r,this.contentAttr,""),r}},NC=(()=>{class e extends Xs{constructor(t){super(t)}supports(t){return!0}addEventListener(t,r,i){return t.addEventListener(r,i,!1),()=>this.removeEventListener(t,r,i)}removeEventListener(t,r,i){return t.removeEventListener(r,i)}static{this.\u0275fac=function(r){return new(r||e)(O(Ae))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})(),zg=["alt","control","meta","shift"],RC={"\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"},PC={alt:e=>e.altKey,control:e=>e.ctrlKey,meta:e=>e.metaKey,shift:e=>e.shiftKey},kC=(()=>{class e extends Xs{constructor(t){super(t)}supports(t){return e.parseEventName(t)!=null}addEventListener(t,r,i){let o=e.parseEventName(r),s=e.eventCallback(o.fullKey,i,this.manager.getZone());return this.manager.getZone().runOutsideAngular(()=>It().onAndCancel(t,o.domEventName,s))}static parseEventName(t){let r=t.toLowerCase().split("."),i=r.shift();if(r.length===0||!(i==="keydown"||i==="keyup"))return null;let o=e._normalizeKey(r.pop()),s="",a=r.indexOf("code");if(a>-1&&(r.splice(a,1),s="code."),zg.forEach(l=>{let u=r.indexOf(l);u>-1&&(r.splice(u,1),s+=l+".")}),s+=o,r.length!=0||o.length===0)return null;let c={};return c.domEventName=i,c.fullKey=s,c}static matchEventFullKeyCode(t,r){let i=RC[t.key]||t.key,o="";return r.indexOf("code.")>-1&&(i=t.code,o="code."),i==null||!i?!1:(i=i.toLowerCase(),i===" "?i="space":i==="."&&(i="dot"),zg.forEach(s=>{if(s!==i){let a=PC[s];a(t)&&(o+=s+".")}}),o+=i,o===r)}static eventCallback(t,r,i){return o=>{e.matchEventFullKeyCode(o,t)&&i.runGuarded(()=>r(o))}}static _normalizeKey(t){return t==="esc"?"escape":t}static{this.\u0275fac=function(r){return new(r||e)(O(Ae))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac})}}return e})();function Yg(e,n){return bg(b({rootComponent:e},FC(n)))}function FC(e){return{appProviders:[...UC,...e?.providers??[]],platformProviders:$C}}function LC(){bu.makeCurrent()}function jC(){return new rt}function VC(){return Sp(document),document}var $C=[{provide:$t,useValue:Ag},{provide:Zl,useValue:LC,multi:!0},{provide:Ae,useFactory:VC,deps:[]}];var UC=[{provide:Cs,useValue:"root"},{provide:rt,useFactory:jC,deps:[]},{provide:Cu,useClass:NC,multi:!0,deps:[Ae,ne,$t]},{provide:Cu,useClass:kC,multi:!0,deps:[Ae]},Bg,qg,Gg,{provide:di,useExisting:Bg},{provide:yr,useClass:IC,deps:[]},[]];var Qg=(()=>{class e{constructor(t){this._doc=t}getTitle(){return this._doc.title}setTitle(t){this._doc.title=t||""}static{this.\u0275fac=function(r){return new(r||e)(O(Ae))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var R="primary",Bi=Symbol("RouteTitle"),Au=class{constructor(n){this.params=n||{}}has(n){return Object.prototype.hasOwnProperty.call(this.params,n)}get(n){if(this.has(n)){let t=this.params[n];return Array.isArray(t)?t[0]:t}return null}getAll(n){if(this.has(n)){let t=this.params[n];return Array.isArray(t)?t:[t]}return[]}get keys(){return Object.keys(this.params)}};function Ir(e){return new Au(e)}function HC(e,n,t){let r=t.path.split("/");if(r.length>e.length||t.pathMatch==="full"&&(n.hasChildren()||r.lengthr[o]===i)}else return e===n}function rm(e){return e.length>0?e[e.length-1]:null}function qt(e){return gc(e)?e:Dn(e)?te(Promise.resolve(e)):x(e)}var GC={exact:om,subset:sm},im={exact:qC,subset:WC,ignored:()=>!0};function Kg(e,n,t){return GC[t.paths](e.root,n.root,t.matrixParams)&&im[t.queryParams](e.queryParams,n.queryParams)&&!(t.fragment==="exact"&&e.fragment!==n.fragment)}function qC(e,n){return pt(e,n)}function om(e,n,t){if(!Mn(e.segments,n.segments)||!ra(e.segments,n.segments,t)||e.numberOfChildren!==n.numberOfChildren)return!1;for(let r in n.children)if(!e.children[r]||!om(e.children[r],n.children[r],t))return!1;return!0}function WC(e,n){return Object.keys(n).length<=Object.keys(e).length&&Object.keys(n).every(t=>nm(e[t],n[t]))}function sm(e,n,t){return am(e,n,n.segments,t)}function am(e,n,t,r){if(e.segments.length>t.length){let i=e.segments.slice(0,t.length);return!(!Mn(i,t)||n.hasChildren()||!ra(i,t,r))}else if(e.segments.length===t.length){if(!Mn(e.segments,t)||!ra(e.segments,t,r))return!1;for(let i in n.children)if(!e.children[i]||!sm(e.children[i],n.children[i],r))return!1;return!0}else{let i=t.slice(0,e.segments.length),o=t.slice(e.segments.length);return!Mn(e.segments,i)||!ra(e.segments,i,r)||!e.children[R]?!1:am(e.children[R],n,o,r)}}function ra(e,n,t){return n.every((r,i)=>im[t](e[i].parameters,r.parameters))}var Ht=class{constructor(n=new q([],{}),t={},r=null){this.root=n,this.queryParams=t,this.fragment=r}get queryParamMap(){return this._queryParamMap??=Ir(this.queryParams),this._queryParamMap}toString(){return QC.serialize(this)}},q=class{constructor(n,t){this.segments=n,this.children=t,this.parent=null,Object.values(t).forEach(r=>r.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return ia(this)}},In=class{constructor(n,t){this.path=n,this.parameters=t}get parameterMap(){return this._parameterMap??=Ir(this.parameters),this._parameterMap}toString(){return lm(this)}};function ZC(e,n){return Mn(e,n)&&e.every((t,r)=>pt(t.parameters,n[r].parameters))}function Mn(e,n){return e.length!==n.length?!1:e.every((t,r)=>t.path===n[r].path)}function YC(e,n){let t=[];return Object.entries(e.children).forEach(([r,i])=>{r===R&&(t=t.concat(n(i,r)))}),Object.entries(e.children).forEach(([r,i])=>{r!==R&&(t=t.concat(n(i,r)))}),t}var rd=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:()=>new sa,providedIn:"root"})}}return e})(),sa=class{parse(n){let t=new Ru(n);return new Ht(t.parseRootSegment(),t.parseQueryParams(),t.parseFragment())}serialize(n){let t=`/${xi(n.root,!0)}`,r=XC(n.queryParams),i=typeof n.fragment=="string"?`#${KC(n.fragment)}`:"";return`${t}${r}${i}`}},QC=new sa;function ia(e){return e.segments.map(n=>lm(n)).join("/")}function xi(e,n){if(!e.hasChildren())return ia(e);if(n){let t=e.children[R]?xi(e.children[R],!1):"",r=[];return Object.entries(e.children).forEach(([i,o])=>{i!==R&&r.push(`${i}:${xi(o,!1)}`)}),r.length>0?`${t}(${r.join("//")})`:t}else{let t=YC(e,(r,i)=>i===R?[xi(e.children[R],!1)]:[`${i}:${xi(r,!1)}`]);return Object.keys(e.children).length===1&&e.children[R]!=null?`${ia(e)}/${t[0]}`:`${ia(e)}/(${t.join("//")})`}}function cm(e){return encodeURIComponent(e).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function ta(e){return cm(e).replace(/%3B/gi,";")}function KC(e){return encodeURI(e)}function Nu(e){return cm(e).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function oa(e){return decodeURIComponent(e)}function Jg(e){return oa(e.replace(/\+/g,"%20"))}function lm(e){return`${Nu(e.path)}${JC(e.parameters)}`}function JC(e){return Object.entries(e).map(([n,t])=>`;${Nu(n)}=${Nu(t)}`).join("")}function XC(e){let n=Object.entries(e).map(([t,r])=>Array.isArray(r)?r.map(i=>`${ta(t)}=${ta(i)}`).join("&"):`${ta(t)}=${ta(r)}`).filter(t=>t);return n.length?`?${n.join("&")}`:""}var eE=/^[^\/()?;#]+/;function Mu(e){let n=e.match(eE);return n?n[0]:""}var tE=/^[^\/()?;=#]+/;function nE(e){let n=e.match(tE);return n?n[0]:""}var rE=/^[^=?&#]+/;function iE(e){let n=e.match(rE);return n?n[0]:""}var oE=/^[^&#]+/;function sE(e){let n=e.match(oE);return n?n[0]:""}var Ru=class{constructor(n){this.url=n,this.remaining=n}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new q([],{}):new q([],this.parseChildren())}parseQueryParams(){let n={};if(this.consumeOptional("?"))do this.parseQueryParam(n);while(this.consumeOptional("&"));return n}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(this.remaining==="")return{};this.consumeOptional("/");let n=[];for(this.peekStartsWith("(")||n.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),n.push(this.parseSegment());let t={};this.peekStartsWith("/(")&&(this.capture("/"),t=this.parseParens(!0));let r={};return this.peekStartsWith("(")&&(r=this.parseParens(!1)),(n.length>0||Object.keys(t).length>0)&&(r[R]=new q(n,t)),r}parseSegment(){let n=Mu(this.remaining);if(n===""&&this.peekStartsWith(";"))throw new E(4009,!1);return this.capture(n),new In(oa(n),this.parseMatrixParams())}parseMatrixParams(){let n={};for(;this.consumeOptional(";");)this.parseParam(n);return n}parseParam(n){let t=nE(this.remaining);if(!t)return;this.capture(t);let r="";if(this.consumeOptional("=")){let i=Mu(this.remaining);i&&(r=i,this.capture(r))}n[oa(t)]=oa(r)}parseQueryParam(n){let t=iE(this.remaining);if(!t)return;this.capture(t);let r="";if(this.consumeOptional("=")){let s=sE(this.remaining);s&&(r=s,this.capture(r))}let i=Jg(t),o=Jg(r);if(n.hasOwnProperty(i)){let s=n[i];Array.isArray(s)||(s=[s],n[i]=s),s.push(o)}else n[i]=o}parseParens(n){let t={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let r=Mu(this.remaining),i=this.remaining[r.length];if(i!=="/"&&i!==")"&&i!==";")throw new E(4010,!1);let o;r.indexOf(":")>-1?(o=r.slice(0,r.indexOf(":")),this.capture(o),this.capture(":")):n&&(o=R);let s=this.parseChildren();t[o]=Object.keys(s).length===1?s[R]:new q([],s),this.consumeOptional("//")}return t}peekStartsWith(n){return this.remaining.startsWith(n)}consumeOptional(n){return this.peekStartsWith(n)?(this.remaining=this.remaining.substring(n.length),!0):!1}capture(n){if(!this.consumeOptional(n))throw new E(4011,!1)}};function um(e){return e.segments.length>0?new q([],{[R]:e}):e}function dm(e){let n={};for(let[r,i]of Object.entries(e.children)){let o=dm(i);if(r===R&&o.segments.length===0&&o.hasChildren())for(let[s,a]of Object.entries(o.children))n[s]=a;else(o.segments.length>0||o.hasChildren())&&(n[r]=o)}let t=new q(e.segments,n);return aE(t)}function aE(e){if(e.numberOfChildren===1&&e.children[R]){let n=e.children[R];return new q(e.segments.concat(n.segments),n.children)}return e}function Mr(e){return e instanceof Ht}function cE(e,n,t=null,r=null){let i=fm(e);return hm(i,n,t,r)}function fm(e){let n;function t(o){let s={};for(let c of o.children){let l=t(c);s[c.outlet]=l}let a=new q(o.url,s);return o===e&&(n=a),a}let r=t(e.root),i=um(r);return n??i}function hm(e,n,t,r){let i=e;for(;i.parent;)i=i.parent;if(n.length===0)return Su(i,i,i,t,r);let o=lE(n);if(o.toRoot())return Su(i,i,new q([],{}),t,r);let s=uE(o,i,e),a=s.processChildren?Oi(s.segmentGroup,s.index,o.commands):gm(s.segmentGroup,s.index,o.commands);return Su(i,s.segmentGroup,a,t,r)}function aa(e){return typeof e=="object"&&e!=null&&!e.outlets&&!e.segmentPath}function Pi(e){return typeof e=="object"&&e!=null&&e.outlets}function Su(e,n,t,r,i){let o={};r&&Object.entries(r).forEach(([c,l])=>{o[c]=Array.isArray(l)?l.map(u=>`${u}`):`${l}`});let s;e===n?s=t:s=pm(e,n,t);let a=um(dm(s));return new Ht(a,o,i)}function pm(e,n,t){let r={};return Object.entries(e.children).forEach(([i,o])=>{o===n?r[i]=t:r[i]=pm(o,n,t)}),new q(e.segments,r)}var ca=class{constructor(n,t,r){if(this.isAbsolute=n,this.numberOfDoubleDots=t,this.commands=r,n&&r.length>0&&aa(r[0]))throw new E(4003,!1);let i=r.find(Pi);if(i&&i!==rm(r))throw new E(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function lE(e){if(typeof e[0]=="string"&&e.length===1&&e[0]==="/")return new ca(!0,0,e);let n=0,t=!1,r=e.reduce((i,o,s)=>{if(typeof o=="object"&&o!=null){if(o.outlets){let a={};return Object.entries(o.outlets).forEach(([c,l])=>{a[c]=typeof l=="string"?l.split("/"):l}),[...i,{outlets:a}]}if(o.segmentPath)return[...i,o.segmentPath]}return typeof o!="string"?[...i,o]:s===0?(o.split("/").forEach((a,c)=>{c==0&&a==="."||(c==0&&a===""?t=!0:a===".."?n++:a!=""&&i.push(a))}),i):[...i,o]},[]);return new ca(t,n,r)}var Cr=class{constructor(n,t,r){this.segmentGroup=n,this.processChildren=t,this.index=r}};function uE(e,n,t){if(e.isAbsolute)return new Cr(n,!0,0);if(!t)return new Cr(n,!1,NaN);if(t.parent===null)return new Cr(t,!0,0);let r=aa(e.commands[0])?0:1,i=t.segments.length-1+r;return dE(t,i,e.numberOfDoubleDots)}function dE(e,n,t){let r=e,i=n,o=t;for(;o>i;){if(o-=i,r=r.parent,!r)throw new E(4005,!1);i=r.segments.length}return new Cr(r,!1,i-o)}function fE(e){return Pi(e[0])?e[0].outlets:{[R]:e}}function gm(e,n,t){if(e??=new q([],{}),e.segments.length===0&&e.hasChildren())return Oi(e,n,t);let r=hE(e,n,t),i=t.slice(r.commandIndex);if(r.match&&r.pathIndexo!==R)&&e.children[R]&&e.numberOfChildren===1&&e.children[R].segments.length===0){let o=Oi(e.children[R],n,t);return new q(e.segments,o.children)}return Object.entries(r).forEach(([o,s])=>{typeof s=="string"&&(s=[s]),s!==null&&(i[o]=gm(e.children[o],n,s))}),Object.entries(e.children).forEach(([o,s])=>{r[o]===void 0&&(i[o]=s)}),new q(e.segments,i)}}function hE(e,n,t){let r=0,i=n,o={match:!1,pathIndex:0,commandIndex:0};for(;i=t.length)return o;let s=e.segments[i],a=t[r];if(Pi(a))break;let c=`${a}`,l=r0&&c===void 0)break;if(c&&l&&typeof l=="object"&&l.outlets===void 0){if(!em(c,l,s))return o;r+=2}else{if(!em(c,{},s))return o;r++}i++}return{match:!0,pathIndex:i,commandIndex:r}}function Pu(e,n,t){let r=e.segments.slice(0,n),i=0;for(;i{typeof r=="string"&&(r=[r]),r!==null&&(n[t]=Pu(new q([],{}),0,r))}),n}function Xg(e){let n={};return Object.entries(e).forEach(([t,r])=>n[t]=`${r}`),n}function em(e,n,t){return e==t.path&&pt(n,t.parameters)}var Ni="imperative",ye=function(e){return e[e.NavigationStart=0]="NavigationStart",e[e.NavigationEnd=1]="NavigationEnd",e[e.NavigationCancel=2]="NavigationCancel",e[e.NavigationError=3]="NavigationError",e[e.RoutesRecognized=4]="RoutesRecognized",e[e.ResolveStart=5]="ResolveStart",e[e.ResolveEnd=6]="ResolveEnd",e[e.GuardsCheckStart=7]="GuardsCheckStart",e[e.GuardsCheckEnd=8]="GuardsCheckEnd",e[e.RouteConfigLoadStart=9]="RouteConfigLoadStart",e[e.RouteConfigLoadEnd=10]="RouteConfigLoadEnd",e[e.ChildActivationStart=11]="ChildActivationStart",e[e.ChildActivationEnd=12]="ChildActivationEnd",e[e.ActivationStart=13]="ActivationStart",e[e.ActivationEnd=14]="ActivationEnd",e[e.Scroll=15]="Scroll",e[e.NavigationSkipped=16]="NavigationSkipped",e}(ye||{}),Ze=class{constructor(n,t){this.id=n,this.url=t}},ki=class extends Ze{constructor(n,t,r="imperative",i=null){super(n,t),this.type=ye.NavigationStart,this.navigationTrigger=r,this.restoredState=i}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},zt=class extends Ze{constructor(n,t,r){super(n,t),this.urlAfterRedirects=r,this.type=ye.NavigationEnd}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},$e=function(e){return e[e.Redirect=0]="Redirect",e[e.SupersededByNewNavigation=1]="SupersededByNewNavigation",e[e.NoDataFromResolver=2]="NoDataFromResolver",e[e.GuardRejected=3]="GuardRejected",e}($e||{}),ku=function(e){return e[e.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",e[e.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",e}(ku||{}),Gt=class extends Ze{constructor(n,t,r,i){super(n,t),this.reason=r,this.code=i,this.type=ye.NavigationCancel}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}},Sn=class extends Ze{constructor(n,t,r,i){super(n,t),this.reason=r,this.code=i,this.type=ye.NavigationSkipped}},Fi=class extends Ze{constructor(n,t,r,i){super(n,t),this.error=r,this.target=i,this.type=ye.NavigationError}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},la=class extends Ze{constructor(n,t,r,i){super(n,t),this.urlAfterRedirects=r,this.state=i,this.type=ye.RoutesRecognized}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Fu=class extends Ze{constructor(n,t,r,i){super(n,t),this.urlAfterRedirects=r,this.state=i,this.type=ye.GuardsCheckStart}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Lu=class extends Ze{constructor(n,t,r,i,o){super(n,t),this.urlAfterRedirects=r,this.state=i,this.shouldActivate=o,this.type=ye.GuardsCheckEnd}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},ju=class extends Ze{constructor(n,t,r,i){super(n,t),this.urlAfterRedirects=r,this.state=i,this.type=ye.ResolveStart}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Vu=class extends Ze{constructor(n,t,r,i){super(n,t),this.urlAfterRedirects=r,this.state=i,this.type=ye.ResolveEnd}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},$u=class{constructor(n){this.route=n,this.type=ye.RouteConfigLoadStart}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},Uu=class{constructor(n){this.route=n,this.type=ye.RouteConfigLoadEnd}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},Bu=class{constructor(n){this.snapshot=n,this.type=ye.ChildActivationStart}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Hu=class{constructor(n){this.snapshot=n,this.type=ye.ChildActivationEnd}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},zu=class{constructor(n){this.snapshot=n,this.type=ye.ActivationStart}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Gu=class{constructor(n){this.snapshot=n,this.type=ye.ActivationEnd}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}};var Li=class{},ji=class{constructor(n){this.url=n}};var qu=class{constructor(){this.outlet=null,this.route=null,this.injector=null,this.children=new ga,this.attachRef=null}},ga=(()=>{class e{constructor(){this.contexts=new Map}onChildOutletCreated(t,r){let i=this.getOrCreateContext(t);i.outlet=r,this.contexts.set(t,i)}onChildOutletDestroyed(t){let r=this.getContext(t);r&&(r.outlet=null,r.attachRef=null)}onOutletDeactivated(){let t=this.contexts;return this.contexts=new Map,t}onOutletReAttached(t){this.contexts=t}getOrCreateContext(t){let r=this.getContext(t);return r||(r=new qu,this.contexts.set(t,r)),r}getContext(t){return this.contexts.get(t)||null}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),ua=class{constructor(n){this._root=n}get root(){return this._root.value}parent(n){let t=this.pathFromRoot(n);return t.length>1?t[t.length-2]:null}children(n){let t=Wu(n,this._root);return t?t.children.map(r=>r.value):[]}firstChild(n){let t=Wu(n,this._root);return t&&t.children.length>0?t.children[0].value:null}siblings(n){let t=Zu(n,this._root);return t.length<2?[]:t[t.length-2].children.map(i=>i.value).filter(i=>i!==n)}pathFromRoot(n){return Zu(n,this._root).map(t=>t.value)}};function Wu(e,n){if(e===n.value)return n;for(let t of n.children){let r=Wu(e,t);if(r)return r}return null}function Zu(e,n){if(e===n.value)return[n];for(let t of n.children){let r=Zu(e,t);if(r.length)return r.unshift(n),r}return[]}var Ve=class{constructor(n,t){this.value=n,this.children=t}toString(){return`TreeNode(${this.value})`}};function br(e){let n={};return e&&e.children.forEach(t=>n[t.value.outlet]=t),n}var da=class extends ua{constructor(n,t){super(n),this.snapshot=t,od(this,n)}toString(){return this.snapshot.toString()}};function mm(e){let n=gE(e),t=new ue([new In("",{})]),r=new ue({}),i=new ue({}),o=new ue({}),s=new ue(""),a=new at(t,r,o,s,i,R,e,n.root);return a.snapshot=n.root,new da(new Ve(a,[]),n)}function gE(e){let n={},t={},r={},i="",o=new Vi([],n,r,i,t,R,e,null,{});return new fa("",new Ve(o,[]))}var at=class{constructor(n,t,r,i,o,s,a,c){this.urlSubject=n,this.paramsSubject=t,this.queryParamsSubject=r,this.fragmentSubject=i,this.dataSubject=o,this.outlet=s,this.component=a,this._futureSnapshot=c,this.title=this.dataSubject?.pipe(N(l=>l[Bi]))??x(void 0),this.url=n,this.params=t,this.queryParams=r,this.fragment=i,this.data=o}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(N(n=>Ir(n))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(N(n=>Ir(n))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function id(e,n,t="emptyOnly"){let r,{routeConfig:i}=e;return n!==null&&(t==="always"||i?.path===""||!n.component&&!n.routeConfig?.loadComponent)?r={params:b(b({},n.params),e.params),data:b(b({},n.data),e.data),resolve:b(b(b(b({},e.data),n.data),i?.data),e._resolvedData)}:r={params:b({},e.params),data:b({},e.data),resolve:b(b({},e.data),e._resolvedData??{})},i&&ym(i)&&(r.resolve[Bi]=i.title),r}var Vi=class{get title(){return this.data?.[Bi]}constructor(n,t,r,i,o,s,a,c,l){this.url=n,this.params=t,this.queryParams=r,this.fragment=i,this.data=o,this.outlet=s,this.component=a,this.routeConfig=c,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??=Ir(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=Ir(this.queryParams),this._queryParamMap}toString(){let n=this.url.map(r=>r.toString()).join("/"),t=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${n}', path:'${t}')`}},fa=class extends ua{constructor(n,t){super(t),this.url=n,od(this,t)}toString(){return vm(this._root)}};function od(e,n){n.value._routerState=e,n.children.forEach(t=>od(e,t))}function vm(e){let n=e.children.length>0?` { ${e.children.map(vm).join(", ")} } `:"";return`${e.value}${n}`}function xu(e){if(e.snapshot){let n=e.snapshot,t=e._futureSnapshot;e.snapshot=t,pt(n.queryParams,t.queryParams)||e.queryParamsSubject.next(t.queryParams),n.fragment!==t.fragment&&e.fragmentSubject.next(t.fragment),pt(n.params,t.params)||e.paramsSubject.next(t.params),zC(n.url,t.url)||e.urlSubject.next(t.url),pt(n.data,t.data)||e.dataSubject.next(t.data)}else e.snapshot=e._futureSnapshot,e.dataSubject.next(e._futureSnapshot.data)}function Yu(e,n){let t=pt(e.params,n.params)&&ZC(e.url,n.url),r=!e.parent!=!n.parent;return t&&!r&&(!e.parent||Yu(e.parent,n.parent))}function ym(e){return typeof e.title=="string"||e.title===null}var Hi=(()=>{class e{constructor(){this.activated=null,this._activatedRoute=null,this.name=R,this.activateEvents=new De,this.deactivateEvents=new De,this.attachEvents=new De,this.detachEvents=new De,this.parentContexts=m(ga),this.location=m(js),this.changeDetector=m(bn),this.environmentInjector=m(Te),this.inputBinder=m(sd,{optional:!0}),this.supportsBindingToComponentInputs=!0}get activatedComponentRef(){return this.activated}ngOnChanges(t){if(t.name){let{firstChange:r,previousValue:i}=t.name;if(r)return;this.isTrackedInParentContexts(i)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(i)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(t){return this.parentContexts.getContext(t)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let t=this.parentContexts.getContext(this.name);t?.route&&(t.attachRef?this.attach(t.attachRef,t.route):this.activateWith(t.route,t.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new E(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new E(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new E(4012,!1);this.location.detach();let t=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(t.instance),t}attach(t,r){this.activated=t,this._activatedRoute=r,this.location.insert(t.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(t.instance)}deactivate(){if(this.activated){let t=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(t)}}activateWith(t,r){if(this.isActivated)throw new E(4013,!1);this._activatedRoute=t;let i=this.location,s=t.snapshot.component,a=this.parentContexts.getOrCreateContext(this.name).children,c=new Qu(t,a,i.injector);this.activated=i.createComponent(s,{index:i.length,injector:c,environmentInjector:r??this.environmentInjector}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275dir=je({type:e,selectors:[["router-outlet"]],inputs:{name:"name"},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],standalone:!0,features:[Lt]})}}return e})(),Qu=class e{__ngOutletInjector(n){return new e(this.route,this.childContexts,n)}constructor(n,t,r){this.route=n,this.childContexts=t,this.parent=r}get(n,t){return n===at?this.route:n===ga?this.childContexts:this.parent.get(n,t)}},sd=new M("");function mE(e,n,t){let r=$i(e,n._root,t?t._root:void 0);return new da(r,n)}function $i(e,n,t){if(t&&e.shouldReuseRoute(n.value,t.value.snapshot)){let r=t.value;r._futureSnapshot=n.value;let i=vE(e,n,t);return new Ve(r,i)}else{if(e.shouldAttach(n.value)){let o=e.retrieve(n.value);if(o!==null){let s=o.route;return s.value._futureSnapshot=n.value,s.children=n.children.map(a=>$i(e,a)),s}}let r=yE(n.value),i=n.children.map(o=>$i(e,o));return new Ve(r,i)}}function vE(e,n,t){return n.children.map(r=>{for(let i of t.children)if(e.shouldReuseRoute(r.value,i.value.snapshot))return $i(e,r,i);return $i(e,r)})}function yE(e){return new at(new ue(e.url),new ue(e.params),new ue(e.queryParams),new ue(e.fragment),new ue(e.data),e.outlet,e.component,e)}var wm="ngNavigationCancelingError";function _m(e,n){let{redirectTo:t,navigationBehaviorOptions:r}=Mr(n)?{redirectTo:n,navigationBehaviorOptions:void 0}:n,i=Dm(!1,$e.Redirect);return i.url=t,i.navigationBehaviorOptions=r,i}function Dm(e,n){let t=new Error(`NavigationCancelingError: ${e||""}`);return t[wm]=!0,t.cancellationCode=n,t}function wE(e){return bm(e)&&Mr(e.url)}function bm(e){return!!e&&e[wm]}var _E=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["ng-component"]],standalone:!0,features:[Z],decls:1,vars:0,template:function(r,i){r&1&&T(0,"router-outlet")},dependencies:[Hi],encapsulation:2})}}return e})();function DE(e,n){return e.providers&&!e._injector&&(e._injector=lu(e.providers,n,`Route: ${e.path}`)),e._injector??n}function ad(e){let n=e.children&&e.children.map(ad),t=n?G(b({},e),{children:n}):b({},e);return!t.component&&!t.loadComponent&&(n||t.loadChildren)&&t.outlet&&t.outlet!==R&&(t.component=_E),t}function gt(e){return e.outlet||R}function bE(e,n){let t=e.filter(r=>gt(r)===n);return t.push(...e.filter(r=>gt(r)!==n)),t}function zi(e){if(!e)return null;if(e.routeConfig?._injector)return e.routeConfig._injector;for(let n=e.parent;n;n=n.parent){let t=n.routeConfig;if(t?._loadedInjector)return t._loadedInjector;if(t?._injector)return t._injector}return null}var CE=(e,n,t,r)=>N(i=>(new Ku(n,i.targetRouterState,i.currentRouterState,t,r).activate(e),i)),Ku=class{constructor(n,t,r,i,o){this.routeReuseStrategy=n,this.futureState=t,this.currState=r,this.forwardEvent=i,this.inputBindingEnabled=o}activate(n){let t=this.futureState._root,r=this.currState?this.currState._root:null;this.deactivateChildRoutes(t,r,n),xu(this.futureState.root),this.activateChildRoutes(t,r,n)}deactivateChildRoutes(n,t,r){let i=br(t);n.children.forEach(o=>{let s=o.value.outlet;this.deactivateRoutes(o,i[s],r),delete i[s]}),Object.values(i).forEach(o=>{this.deactivateRouteAndItsChildren(o,r)})}deactivateRoutes(n,t,r){let i=n.value,o=t?t.value:null;if(i===o)if(i.component){let s=r.getContext(i.outlet);s&&this.deactivateChildRoutes(n,t,s.children)}else this.deactivateChildRoutes(n,t,r);else o&&this.deactivateRouteAndItsChildren(t,r)}deactivateRouteAndItsChildren(n,t){n.value.component&&this.routeReuseStrategy.shouldDetach(n.value.snapshot)?this.detachAndStoreRouteSubtree(n,t):this.deactivateRouteAndOutlet(n,t)}detachAndStoreRouteSubtree(n,t){let r=t.getContext(n.value.outlet),i=r&&n.value.component?r.children:t,o=br(n);for(let s of Object.values(o))this.deactivateRouteAndItsChildren(s,i);if(r&&r.outlet){let s=r.outlet.detach(),a=r.children.onOutletDeactivated();this.routeReuseStrategy.store(n.value.snapshot,{componentRef:s,route:n,contexts:a})}}deactivateRouteAndOutlet(n,t){let r=t.getContext(n.value.outlet),i=r&&n.value.component?r.children:t,o=br(n);for(let s of Object.values(o))this.deactivateRouteAndItsChildren(s,i);r&&(r.outlet&&(r.outlet.deactivate(),r.children.onOutletDeactivated()),r.attachRef=null,r.route=null)}activateChildRoutes(n,t,r){let i=br(t);n.children.forEach(o=>{this.activateRoutes(o,i[o.value.outlet],r),this.forwardEvent(new Gu(o.value.snapshot))}),n.children.length&&this.forwardEvent(new Hu(n.value.snapshot))}activateRoutes(n,t,r){let i=n.value,o=t?t.value:null;if(xu(i),i===o)if(i.component){let s=r.getOrCreateContext(i.outlet);this.activateChildRoutes(n,t,s.children)}else this.activateChildRoutes(n,t,r);else if(i.component){let s=r.getOrCreateContext(i.outlet);if(this.routeReuseStrategy.shouldAttach(i.snapshot)){let a=this.routeReuseStrategy.retrieve(i.snapshot);this.routeReuseStrategy.store(i.snapshot,null),s.children.onOutletReAttached(a.contexts),s.attachRef=a.componentRef,s.route=a.route.value,s.outlet&&s.outlet.attach(a.componentRef,a.route.value),xu(a.route.value),this.activateChildRoutes(n,null,s.children)}else{let a=zi(i.snapshot);s.attachRef=null,s.route=i,s.injector=a,s.outlet&&s.outlet.activateWith(i,s.injector),this.activateChildRoutes(n,null,s.children)}}else this.activateChildRoutes(n,null,r)}},ha=class{constructor(n){this.path=n,this.route=this.path[this.path.length-1]}},Er=class{constructor(n,t){this.component=n,this.route=t}};function EE(e,n,t){let r=e._root,i=n?n._root:null;return Ti(r,i,t,[r.value])}function IE(e){let n=e.routeConfig?e.routeConfig.canActivateChild:null;return!n||n.length===0?null:{node:e,guards:n}}function xr(e,n){let t=Symbol(),r=n.get(e,t);return r===t?typeof e=="function"&&!wh(e)?e:n.get(e):r}function Ti(e,n,t,r,i={canDeactivateChecks:[],canActivateChecks:[]}){let o=br(n);return e.children.forEach(s=>{ME(s,o[s.value.outlet],t,r.concat([s.value]),i),delete o[s.value.outlet]}),Object.entries(o).forEach(([s,a])=>Ri(a,t.getContext(s),i)),i}function ME(e,n,t,r,i={canDeactivateChecks:[],canActivateChecks:[]}){let o=e.value,s=n?n.value:null,a=t?t.getContext(e.value.outlet):null;if(s&&o.routeConfig===s.routeConfig){let c=SE(s,o,o.routeConfig.runGuardsAndResolvers);c?i.canActivateChecks.push(new ha(r)):(o.data=s.data,o._resolvedData=s._resolvedData),o.component?Ti(e,n,a?a.children:null,r,i):Ti(e,n,t,r,i),c&&a&&a.outlet&&a.outlet.isActivated&&i.canDeactivateChecks.push(new Er(a.outlet.component,s))}else s&&Ri(n,a,i),i.canActivateChecks.push(new ha(r)),o.component?Ti(e,null,a?a.children:null,r,i):Ti(e,null,t,r,i);return i}function SE(e,n,t){if(typeof t=="function")return t(e,n);switch(t){case"pathParamsChange":return!Mn(e.url,n.url);case"pathParamsOrQueryParamsChange":return!Mn(e.url,n.url)||!pt(e.queryParams,n.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Yu(e,n)||!pt(e.queryParams,n.queryParams);case"paramsChange":default:return!Yu(e,n)}}function Ri(e,n,t){let r=br(e),i=e.value;Object.entries(r).forEach(([o,s])=>{i.component?n?Ri(s,n.children.getContext(o),t):Ri(s,null,t):Ri(s,n,t)}),i.component?n&&n.outlet&&n.outlet.isActivated?t.canDeactivateChecks.push(new Er(n.outlet.component,i)):t.canDeactivateChecks.push(new Er(null,i)):t.canDeactivateChecks.push(new Er(null,i))}function Gi(e){return typeof e=="function"}function xE(e){return typeof e=="boolean"}function TE(e){return e&&Gi(e.canLoad)}function AE(e){return e&&Gi(e.canActivate)}function OE(e){return e&&Gi(e.canActivateChild)}function NE(e){return e&&Gi(e.canDeactivate)}function RE(e){return e&&Gi(e.canMatch)}function Cm(e){return e instanceof wt||e?.name==="EmptyError"}var na=Symbol("INITIAL_VALUE");function Sr(){return Le(e=>Uo(e.map(n=>n.pipe(_t(1),Dc(na)))).pipe(N(n=>{for(let t of n)if(t!==!0){if(t===na)return na;if(t===!1||t instanceof Ht)return t}return!0}),Fe(n=>n!==na),_t(1)))}function PE(e,n){return de(t=>{let{targetSnapshot:r,currentSnapshot:i,guards:{canActivateChecks:o,canDeactivateChecks:s}}=t;return s.length===0&&o.length===0?x(G(b({},t),{guardsResult:!0})):kE(s,r,i,e).pipe(de(a=>a&&xE(a)?FE(r,o,e,n):x(a)),N(a=>G(b({},t),{guardsResult:a})))})}function kE(e,n,t,r){return te(e).pipe(de(i=>UE(i.component,i.route,t,n,r)),lt(i=>i!==!0,!0))}function FE(e,n,t,r){return te(n).pipe(Ot(i=>Yn(jE(i.route.parent,r),LE(i.route,r),$E(e,i.path,t),VE(e,i.route,t))),lt(i=>i!==!0,!0))}function LE(e,n){return e!==null&&n&&n(new zu(e)),x(!0)}function jE(e,n){return e!==null&&n&&n(new Bu(e)),x(!0)}function VE(e,n,t){let r=n.routeConfig?n.routeConfig.canActivate:null;if(!r||r.length===0)return x(!0);let i=r.map(o=>Bo(()=>{let s=zi(n)??t,a=xr(o,s),c=AE(a)?a.canActivate(n,e):bt(s,()=>a(n,e));return qt(c).pipe(lt())}));return x(i).pipe(Sr())}function $E(e,n,t){let r=n[n.length-1],o=n.slice(0,n.length-1).reverse().map(s=>IE(s)).filter(s=>s!==null).map(s=>Bo(()=>{let a=s.guards.map(c=>{let l=zi(s.node)??t,u=xr(c,l),d=OE(u)?u.canActivateChild(r,e):bt(l,()=>u(r,e));return qt(d).pipe(lt())});return x(a).pipe(Sr())}));return x(o).pipe(Sr())}function UE(e,n,t,r,i){let o=n&&n.routeConfig?n.routeConfig.canDeactivate:null;if(!o||o.length===0)return x(!0);let s=o.map(a=>{let c=zi(n)??i,l=xr(a,c),u=NE(l)?l.canDeactivate(e,n,t,r):bt(c,()=>l(e,n,t,r));return qt(u).pipe(lt())});return x(s).pipe(Sr())}function BE(e,n,t,r){let i=n.canLoad;if(i===void 0||i.length===0)return x(!0);let o=i.map(s=>{let a=xr(s,e),c=TE(a)?a.canLoad(n,t):bt(e,()=>a(n,t));return qt(c)});return x(o).pipe(Sr(),Em(r))}function Em(e){return dc(he(n=>{if(Mr(n))throw _m(e,n)}),N(n=>n===!0))}function HE(e,n,t,r){let i=n.canMatch;if(!i||i.length===0)return x(!0);let o=i.map(s=>{let a=xr(s,e),c=RE(a)?a.canMatch(n,t):bt(e,()=>a(n,t));return qt(c)});return x(o).pipe(Sr(),Em(r))}var Ui=class{constructor(n){this.segmentGroup=n||null}},pa=class extends Error{constructor(n){super(),this.urlTree=n}};function Dr(e){return Zn(new Ui(e))}function zE(e){return Zn(new E(4e3,!1))}function GE(e){return Zn(Dm(!1,$e.GuardRejected))}var Ju=class{constructor(n,t){this.urlSerializer=n,this.urlTree=t}lineralizeSegments(n,t){let r=[],i=t.root;for(;;){if(r=r.concat(i.segments),i.numberOfChildren===0)return x(r);if(i.numberOfChildren>1||!i.children[R])return zE(n.redirectTo);i=i.children[R]}}applyRedirectCommands(n,t,r){let i=this.applyRedirectCreateUrlTree(t,this.urlSerializer.parse(t),n,r);if(t.startsWith("/"))throw new pa(i);return i}applyRedirectCreateUrlTree(n,t,r,i){let o=this.createSegmentGroup(n,t.root,r,i);return new Ht(o,this.createQueryParams(t.queryParams,this.urlTree.queryParams),t.fragment)}createQueryParams(n,t){let r={};return Object.entries(n).forEach(([i,o])=>{if(typeof o=="string"&&o.startsWith(":")){let a=o.substring(1);r[i]=t[a]}else r[i]=o}),r}createSegmentGroup(n,t,r,i){let o=this.createSegments(n,t.segments,r,i),s={};return Object.entries(t.children).forEach(([a,c])=>{s[a]=this.createSegmentGroup(n,c,r,i)}),new q(o,s)}createSegments(n,t,r,i){return t.map(o=>o.path.startsWith(":")?this.findPosParam(n,o,i):this.findOrReturn(o,r))}findPosParam(n,t,r){let i=r[t.path.substring(1)];if(!i)throw new E(4001,!1);return i}findOrReturn(n,t){let r=0;for(let i of t){if(i.path===n.path)return t.splice(r),i;r++}return n}},Xu={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function qE(e,n,t,r,i){let o=cd(e,n,t);return o.matched?(r=DE(n,r),HE(r,n,t,i).pipe(N(s=>s===!0?o:b({},Xu)))):x(o)}function cd(e,n,t){if(n.path==="**")return WE(t);if(n.path==="")return n.pathMatch==="full"&&(e.hasChildren()||t.length>0)?b({},Xu):{matched:!0,consumedSegments:[],remainingSegments:t,parameters:{},positionalParamSegments:{}};let i=(n.matcher||HC)(t,e,n);if(!i)return b({},Xu);let o={};Object.entries(i.posParams??{}).forEach(([a,c])=>{o[a]=c.path});let s=i.consumed.length>0?b(b({},o),i.consumed[i.consumed.length-1].parameters):o;return{matched:!0,consumedSegments:i.consumed,remainingSegments:t.slice(i.consumed.length),parameters:s,positionalParamSegments:i.posParams??{}}}function WE(e){return{matched:!0,parameters:e.length>0?rm(e).parameters:{},consumedSegments:e,remainingSegments:[],positionalParamSegments:{}}}function tm(e,n,t,r){return t.length>0&&QE(e,t,r)?{segmentGroup:new q(n,YE(r,new q(t,e.children))),slicedSegments:[]}:t.length===0&&KE(e,t,r)?{segmentGroup:new q(e.segments,ZE(e,t,r,e.children)),slicedSegments:t}:{segmentGroup:new q(e.segments,e.children),slicedSegments:t}}function ZE(e,n,t,r){let i={};for(let o of t)if(ma(e,n,o)&&!r[gt(o)]){let s=new q([],{});i[gt(o)]=s}return b(b({},r),i)}function YE(e,n){let t={};t[R]=n;for(let r of e)if(r.path===""&>(r)!==R){let i=new q([],{});t[gt(r)]=i}return t}function QE(e,n,t){return t.some(r=>ma(e,n,r)&>(r)!==R)}function KE(e,n,t){return t.some(r=>ma(e,n,r))}function ma(e,n,t){return(e.hasChildren()||n.length>0)&&t.pathMatch==="full"?!1:t.path===""}function JE(e,n,t,r){return gt(e)!==r&&(r===R||!ma(n,t,e))?!1:cd(n,e,t).matched}function XE(e,n,t){return n.length===0&&!e.children[t]}var ed=class{};function eI(e,n,t,r,i,o,s="emptyOnly"){return new td(e,n,t,r,i,s,o).recognize()}var tI=31,td=class{constructor(n,t,r,i,o,s,a){this.injector=n,this.configLoader=t,this.rootComponentType=r,this.config=i,this.urlTree=o,this.paramsInheritanceStrategy=s,this.urlSerializer=a,this.applyRedirects=new Ju(this.urlSerializer,this.urlTree),this.absoluteRedirectCount=0,this.allowRedirects=!0}noMatchError(n){return new E(4002,`'${n.segmentGroup}'`)}recognize(){let n=tm(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(n).pipe(N(t=>{let r=new Vi([],Object.freeze({}),Object.freeze(b({},this.urlTree.queryParams)),this.urlTree.fragment,{},R,this.rootComponentType,null,{}),i=new Ve(r,t),o=new fa("",i),s=cE(r,[],this.urlTree.queryParams,this.urlTree.fragment);return s.queryParams=this.urlTree.queryParams,o.url=this.urlSerializer.serialize(s),this.inheritParamsAndData(o._root,null),{state:o,tree:s}}))}match(n){return this.processSegmentGroup(this.injector,this.config,n,R).pipe(At(r=>{if(r instanceof pa)return this.urlTree=r.urlTree,this.match(r.urlTree.root);throw r instanceof Ui?this.noMatchError(r):r}))}inheritParamsAndData(n,t){let r=n.value,i=id(r,t,this.paramsInheritanceStrategy);r.params=Object.freeze(i.params),r.data=Object.freeze(i.data),n.children.forEach(o=>this.inheritParamsAndData(o,r))}processSegmentGroup(n,t,r,i){return r.segments.length===0&&r.hasChildren()?this.processChildren(n,t,r):this.processSegment(n,t,r,r.segments,i,!0).pipe(N(o=>o instanceof Ve?[o]:[]))}processChildren(n,t,r){let i=[];for(let o of Object.keys(r.children))o==="primary"?i.unshift(o):i.push(o);return te(i).pipe(Ot(o=>{let s=r.children[o],a=bE(t,o);return this.processSegmentGroup(n,a,s,o)}),_c((o,s)=>(o.push(...s),o)),Nt(null),wc(),de(o=>{if(o===null)return Dr(r);let s=Im(o);return nI(s),x(s)}))}processSegment(n,t,r,i,o,s){return te(t).pipe(Ot(a=>this.processSegmentAgainstRoute(a._injector??n,t,a,r,i,o,s).pipe(At(c=>{if(c instanceof Ui)return x(null);throw c}))),lt(a=>!!a),At(a=>{if(Cm(a))return XE(r,i,o)?x(new ed):Dr(r);throw a}))}processSegmentAgainstRoute(n,t,r,i,o,s,a){return JE(r,i,o,s)?r.redirectTo===void 0?this.matchSegmentAgainstRoute(n,i,r,o,s):this.allowRedirects&&a?this.expandSegmentAgainstRouteUsingRedirect(n,i,t,r,o,s):Dr(i):Dr(i)}expandSegmentAgainstRouteUsingRedirect(n,t,r,i,o,s){let{matched:a,consumedSegments:c,positionalParamSegments:l,remainingSegments:u}=cd(t,i,o);if(!a)return Dr(t);i.redirectTo.startsWith("/")&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>tI&&(this.allowRedirects=!1));let d=this.applyRedirects.applyRedirectCommands(c,i.redirectTo,l);return this.applyRedirects.lineralizeSegments(i,d).pipe(de(p=>this.processSegment(n,r,t,p.concat(u),s,!1)))}matchSegmentAgainstRoute(n,t,r,i,o){let s=qE(t,r,i,n,this.urlSerializer);return r.path==="**"&&(t.children={}),s.pipe(Le(a=>a.matched?(n=r._injector??n,this.getChildConfig(n,r,i).pipe(Le(({routes:c})=>{let l=r._loadedInjector??n,{consumedSegments:u,remainingSegments:d,parameters:p}=a,f=new Vi(u,p,Object.freeze(b({},this.urlTree.queryParams)),this.urlTree.fragment,iI(r),gt(r),r.component??r._loadedComponent??null,r,oI(r)),{segmentGroup:w,slicedSegments:v}=tm(t,u,d,c);if(v.length===0&&w.hasChildren())return this.processChildren(l,c,w).pipe(N(C=>C===null?null:new Ve(f,C)));if(c.length===0&&v.length===0)return x(new Ve(f,[]));let D=gt(r)===o;return this.processSegment(l,c,w,v,D?R:o,!0).pipe(N(C=>new Ve(f,C instanceof Ve?[C]:[])))}))):Dr(t)))}getChildConfig(n,t,r){return t.children?x({routes:t.children,injector:n}):t.loadChildren?t._loadedRoutes!==void 0?x({routes:t._loadedRoutes,injector:t._loadedInjector}):BE(n,t,r,this.urlSerializer).pipe(de(i=>i?this.configLoader.loadChildren(n,t).pipe(he(o=>{t._loadedRoutes=o.routes,t._loadedInjector=o.injector})):GE(t))):x({routes:[],injector:n})}};function nI(e){e.sort((n,t)=>n.value.outlet===R?-1:t.value.outlet===R?1:n.value.outlet.localeCompare(t.value.outlet))}function rI(e){let n=e.value.routeConfig;return n&&n.path===""}function Im(e){let n=[],t=new Set;for(let r of e){if(!rI(r)){n.push(r);continue}let i=n.find(o=>r.value.routeConfig===o.value.routeConfig);i!==void 0?(i.children.push(...r.children),t.add(i)):n.push(r)}for(let r of t){let i=Im(r.children);n.push(new Ve(r.value,i))}return n.filter(r=>!t.has(r))}function iI(e){return e.data||{}}function oI(e){return e.resolve||{}}function sI(e,n,t,r,i,o){return de(s=>eI(e,n,t,r,s.extractedUrl,i,o).pipe(N(({state:a,tree:c})=>G(b({},s),{targetSnapshot:a,urlAfterRedirects:c}))))}function aI(e,n){return de(t=>{let{targetSnapshot:r,guards:{canActivateChecks:i}}=t;if(!i.length)return x(t);let o=new Set(i.map(c=>c.route)),s=new Set;for(let c of o)if(!s.has(c))for(let l of Mm(c))s.add(l);let a=0;return te(s).pipe(Ot(c=>o.has(c)?cI(c,r,e,n):(c.data=id(c,c.parent,e).resolve,x(void 0))),he(()=>a++),Qn(1),de(c=>a===s.size?x(t):ke))})}function Mm(e){let n=e.children.map(t=>Mm(t)).flat();return[e,...n]}function cI(e,n,t,r){let i=e.routeConfig,o=e._resolve;return i?.title!==void 0&&!ym(i)&&(o[Bi]=i.title),lI(o,e,n,r).pipe(N(s=>(e._resolvedData=s,e.data=id(e,e.parent,t).resolve,null)))}function lI(e,n,t,r){let i=Ou(e);if(i.length===0)return x({});let o={};return te(i).pipe(de(s=>uI(e[s],n,t,r).pipe(lt(),he(a=>{o[s]=a}))),Qn(1),yc(o),At(s=>Cm(s)?ke:Zn(s)))}function uI(e,n,t,r){let i=zi(n)??r,o=xr(e,i),s=o.resolve?o.resolve(n,t):bt(i,()=>o(n,t));return qt(s)}function Tu(e){return Le(n=>{let t=e(n);return t?te(t).pipe(N(()=>n)):x(n)})}var Sm=(()=>{class e{buildTitle(t){let r,i=t.root;for(;i!==void 0;)r=this.getResolvedTitleForRoute(i)??r,i=i.children.find(o=>o.outlet===R);return r}getResolvedTitleForRoute(t){return t.data[Bi]}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:()=>m(dI),providedIn:"root"})}}return e})(),dI=(()=>{class e extends Sm{constructor(t){super(),this.title=t}updateTitle(t){let r=this.buildTitle(t);r!==void 0&&this.title.setTitle(r)}static{this.\u0275fac=function(r){return new(r||e)(O(Qg))}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),ld=new M("",{providedIn:"root",factory:()=>({})}),ud=new M(""),fI=(()=>{class e{constructor(){this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap,this.compiler=m(uu)}loadComponent(t){if(this.componentLoaders.get(t))return this.componentLoaders.get(t);if(t._loadedComponent)return x(t._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(t);let r=qt(t.loadComponent()).pipe(N(xm),he(o=>{this.onLoadEndListener&&this.onLoadEndListener(t),t._loadedComponent=o}),tn(()=>{this.componentLoaders.delete(t)})),i=new Wn(r,()=>new _e).pipe(qn());return this.componentLoaders.set(t,i),i}loadChildren(t,r){if(this.childrenLoaders.get(r))return this.childrenLoaders.get(r);if(r._loadedRoutes)return x({routes:r._loadedRoutes,injector:r._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(r);let o=hI(r,this.compiler,t,this.onLoadEndListener).pipe(tn(()=>{this.childrenLoaders.delete(r)})),s=new Wn(o,()=>new _e).pipe(qn());return this.childrenLoaders.set(r,s),s}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function hI(e,n,t,r){return qt(e.loadChildren()).pipe(N(xm),de(i=>i instanceof hi||Array.isArray(i)?x(i):te(n.compileModuleAsync(i))),N(i=>{r&&r(e);let o,s,a=!1;return Array.isArray(i)?(s=i,a=!0):(o=i.create(t).injector,s=o.get(ud,[],{optional:!0,self:!0}).flat()),{routes:s.map(ad),injector:o}}))}function pI(e){return e&&typeof e=="object"&&"default"in e}function xm(e){return pI(e)?e.default:e}var dd=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:()=>m(gI),providedIn:"root"})}}return e})(),gI=(()=>{class e{shouldProcessUrl(t){return!0}extract(t){return t}merge(t,r){return t}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),mI=new M("");var vI=(()=>{class e{get hasRequestedNavigation(){return this.navigationId!==0}constructor(){this.currentNavigation=null,this.currentTransition=null,this.lastSuccessfulNavigation=null,this.events=new _e,this.transitionAbortSubject=new _e,this.configLoader=m(fI),this.environmentInjector=m(Te),this.urlSerializer=m(rd),this.rootContexts=m(ga),this.location=m(Di),this.inputBindingEnabled=m(sd,{optional:!0})!==null,this.titleStrategy=m(Sm),this.options=m(ld,{optional:!0})||{},this.paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly",this.urlHandlingStrategy=m(dd),this.createViewTransition=m(mI,{optional:!0}),this.navigationId=0,this.afterPreactivation=()=>x(void 0),this.rootComponentType=null;let t=i=>this.events.next(new $u(i)),r=i=>this.events.next(new Uu(i));this.configLoader.onLoadEndListener=r,this.configLoader.onLoadStartListener=t}complete(){this.transitions?.complete()}handleNavigationRequest(t){let r=++this.navigationId;this.transitions?.next(G(b(b({},this.transitions.value),t),{id:r}))}setupNavigations(t,r,i){return this.transitions=new ue({id:0,currentUrlTree:r,currentRawUrl:r,extractedUrl:this.urlHandlingStrategy.extract(r),urlAfterRedirects:this.urlHandlingStrategy.extract(r),rawUrl:r,extras:{},resolve:null,reject:null,promise:Promise.resolve(!0),source:Ni,restoredState:null,currentSnapshot:i.snapshot,targetSnapshot:null,currentRouterState:i,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe(Fe(o=>o.id!==0),N(o=>G(b({},o),{extractedUrl:this.urlHandlingStrategy.extract(o.rawUrl)})),Le(o=>{let s=!1,a=!1;return x(o).pipe(Le(c=>{if(this.navigationId>o.id)return this.cancelNavigationTransition(o,"",$e.SupersededByNewNavigation),ke;this.currentTransition=o,this.currentNavigation={id:c.id,initialUrl:c.rawUrl,extractedUrl:c.extractedUrl,trigger:c.source,extras:c.extras,previousNavigation:this.lastSuccessfulNavigation?G(b({},this.lastSuccessfulNavigation),{previousNavigation:null}):null};let l=!t.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),u=c.extras.onSameUrlNavigation??t.onSameUrlNavigation;if(!l&&u!=="reload"){let d="";return this.events.next(new Sn(c.id,this.urlSerializer.serialize(c.rawUrl),d,ku.IgnoredSameUrlNavigation)),c.resolve(null),ke}if(this.urlHandlingStrategy.shouldProcessUrl(c.rawUrl))return x(c).pipe(Le(d=>{let p=this.transitions?.getValue();return this.events.next(new ki(d.id,this.urlSerializer.serialize(d.extractedUrl),d.source,d.restoredState)),p!==this.transitions?.getValue()?ke:Promise.resolve(d)}),sI(this.environmentInjector,this.configLoader,this.rootComponentType,t.config,this.urlSerializer,this.paramsInheritanceStrategy),he(d=>{o.targetSnapshot=d.targetSnapshot,o.urlAfterRedirects=d.urlAfterRedirects,this.currentNavigation=G(b({},this.currentNavigation),{finalUrl:d.urlAfterRedirects});let p=new la(d.id,this.urlSerializer.serialize(d.extractedUrl),this.urlSerializer.serialize(d.urlAfterRedirects),d.targetSnapshot);this.events.next(p)}));if(l&&this.urlHandlingStrategy.shouldProcessUrl(c.currentRawUrl)){let{id:d,extractedUrl:p,source:f,restoredState:w,extras:v}=c,D=new ki(d,this.urlSerializer.serialize(p),f,w);this.events.next(D);let C=mm(this.rootComponentType).snapshot;return this.currentTransition=o=G(b({},c),{targetSnapshot:C,urlAfterRedirects:p,extras:G(b({},v),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.finalUrl=p,x(o)}else{let d="";return this.events.next(new Sn(c.id,this.urlSerializer.serialize(c.extractedUrl),d,ku.IgnoredByUrlHandlingStrategy)),c.resolve(null),ke}}),he(c=>{let l=new Fu(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot);this.events.next(l)}),N(c=>(this.currentTransition=o=G(b({},c),{guards:EE(c.targetSnapshot,c.currentSnapshot,this.rootContexts)}),o)),PE(this.environmentInjector,c=>this.events.next(c)),he(c=>{if(o.guardsResult=c.guardsResult,Mr(c.guardsResult))throw _m(this.urlSerializer,c.guardsResult);let l=new Lu(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects),c.targetSnapshot,!!c.guardsResult);this.events.next(l)}),Fe(c=>c.guardsResult?!0:(this.cancelNavigationTransition(c,"",$e.GuardRejected),!1)),Tu(c=>{if(c.guards.canActivateChecks.length)return x(c).pipe(he(l=>{let u=new ju(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(u)}),Le(l=>{let u=!1;return x(l).pipe(aI(this.paramsInheritanceStrategy,this.environmentInjector),he({next:()=>u=!0,complete:()=>{u||this.cancelNavigationTransition(l,"",$e.NoDataFromResolver)}}))}),he(l=>{let u=new Vu(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(u)}))}),Tu(c=>{let l=u=>{let d=[];u.routeConfig?.loadComponent&&!u.routeConfig._loadedComponent&&d.push(this.configLoader.loadComponent(u.routeConfig).pipe(he(p=>{u.component=p}),N(()=>{})));for(let p of u.children)d.push(...l(p));return d};return Uo(l(c.targetSnapshot.root)).pipe(Nt(null),_t(1))}),Tu(()=>this.afterPreactivation()),Le(()=>{let{currentSnapshot:c,targetSnapshot:l}=o,u=this.createViewTransition?.(this.environmentInjector,c.root,l.root);return u?te(u).pipe(N(()=>o)):x(o)}),N(c=>{let l=mE(t.routeReuseStrategy,c.targetSnapshot,c.currentRouterState);return this.currentTransition=o=G(b({},c),{targetRouterState:l}),this.currentNavigation.targetRouterState=l,o}),he(()=>{this.events.next(new Li)}),CE(this.rootContexts,t.routeReuseStrategy,c=>this.events.next(c),this.inputBindingEnabled),_t(1),he({next:c=>{s=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new zt(c.id,this.urlSerializer.serialize(c.extractedUrl),this.urlSerializer.serialize(c.urlAfterRedirects))),this.titleStrategy?.updateTitle(c.targetRouterState.snapshot),c.resolve(!0)},complete:()=>{s=!0}}),bc(this.transitionAbortSubject.pipe(he(c=>{throw c}))),tn(()=>{!s&&!a&&this.cancelNavigationTransition(o,"",$e.SupersededByNewNavigation),this.currentTransition?.id===o.id&&(this.currentNavigation=null,this.currentTransition=null)}),At(c=>{if(a=!0,bm(c))this.events.next(new Gt(o.id,this.urlSerializer.serialize(o.extractedUrl),c.message,c.cancellationCode)),wE(c)?this.events.next(new ji(c.url)):o.resolve(!1);else{this.events.next(new Fi(o.id,this.urlSerializer.serialize(o.extractedUrl),c,o.targetSnapshot??void 0));try{o.resolve(t.errorHandler(c))}catch(l){this.options.resolveNavigationPromiseOnError?o.resolve(!1):o.reject(l)}}return ke}))}))}cancelNavigationTransition(t,r,i){let o=new Gt(t.id,this.urlSerializer.serialize(t.extractedUrl),r,i);this.events.next(o),t.resolve(!1)}isUpdatingInternalState(){return this.currentTransition?.extractedUrl.toString()!==this.currentTransition?.currentUrlTree.toString()}isUpdatedBrowserUrl(){return this.urlHandlingStrategy.extract(this.urlSerializer.parse(this.location.path(!0))).toString()!==this.currentTransition?.extractedUrl.toString()&&!this.currentTransition?.extras.skipLocationChange}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function yI(e){return e!==Ni}var wI=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:()=>m(_I),providedIn:"root"})}}return e})(),nd=class{shouldDetach(n){return!1}store(n,t){}shouldAttach(n){return!1}retrieve(n){return null}shouldReuseRoute(n,t){return n.routeConfig===t.routeConfig}},_I=(()=>{class e extends nd{static{this.\u0275fac=(()=>{let t;return function(i){return(t||(t=yi(e)))(i||e)}})()}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),Tm=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:()=>m(DI),providedIn:"root"})}}return e})(),DI=(()=>{class e extends Tm{constructor(){super(...arguments),this.location=m(Di),this.urlSerializer=m(rd),this.options=m(ld,{optional:!0})||{},this.canceledNavigationResolution=this.options.canceledNavigationResolution||"replace",this.urlHandlingStrategy=m(dd),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.currentUrlTree=new Ht,this.rawUrlTree=this.currentUrlTree,this.currentPageId=0,this.lastSuccessfulId=-1,this.routerState=mm(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(t){return this.location.subscribe(r=>{r.type==="popstate"&&t(r.url,r.state)})}handleRouterEvent(t,r){if(t instanceof ki)this.stateMemento=this.createStateMemento();else if(t instanceof Sn)this.rawUrlTree=r.initialUrl;else if(t instanceof la){if(this.urlUpdateStrategy==="eager"&&!r.extras.skipLocationChange){let i=this.urlHandlingStrategy.merge(r.finalUrl,r.initialUrl);this.setBrowserUrl(i,r)}}else t instanceof Li?(this.currentUrlTree=r.finalUrl,this.rawUrlTree=this.urlHandlingStrategy.merge(r.finalUrl,r.initialUrl),this.routerState=r.targetRouterState,this.urlUpdateStrategy==="deferred"&&(r.extras.skipLocationChange||this.setBrowserUrl(this.rawUrlTree,r))):t instanceof Gt&&(t.code===$e.GuardRejected||t.code===$e.NoDataFromResolver)?this.restoreHistory(r):t instanceof Fi?this.restoreHistory(r,!0):t instanceof zt&&(this.lastSuccessfulId=t.id,this.currentPageId=this.browserPageId)}setBrowserUrl(t,r){let i=this.urlSerializer.serialize(t);if(this.location.isCurrentPathEqualTo(i)||r.extras.replaceUrl){let o=this.browserPageId,s=b(b({},r.extras.state),this.generateNgRouterState(r.id,o));this.location.replaceState(i,"",s)}else{let o=b(b({},r.extras.state),this.generateNgRouterState(r.id,this.browserPageId+1));this.location.go(i,"",o)}}restoreHistory(t,r=!1){if(this.canceledNavigationResolution==="computed"){let i=this.browserPageId,o=this.currentPageId-i;o!==0?this.location.historyGo(o):this.currentUrlTree===t.finalUrl&&o===0&&(this.resetState(t),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(r&&this.resetState(t),this.resetUrlToCurrentUrlTree())}resetState(t){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,t.finalUrl??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(t,r){return this.canceledNavigationResolution==="computed"?{navigationId:t,\u0275routerPageId:r}:{navigationId:t}}static{this.\u0275fac=(()=>{let t;return function(i){return(t||(t=yi(e)))(i||e)}})()}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})(),Ai=function(e){return e[e.COMPLETE=0]="COMPLETE",e[e.FAILED=1]="FAILED",e[e.REDIRECTING=2]="REDIRECTING",e}(Ai||{});function bI(e,n){e.events.pipe(Fe(t=>t instanceof zt||t instanceof Gt||t instanceof Fi||t instanceof Sn),N(t=>t instanceof zt||t instanceof Sn?Ai.COMPLETE:(t instanceof Gt?t.code===$e.Redirect||t.code===$e.SupersededByNewNavigation:!1)?Ai.REDIRECTING:Ai.FAILED),Fe(t=>t!==Ai.REDIRECTING),_t(1)).subscribe(()=>{n()})}function CI(e){throw e}var EI={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},II={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"},Ue=(()=>{class e{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.isNgZoneEnabled=!1,this.console=m(Bs),this.stateManager=m(Tm),this.options=m(ld,{optional:!0})||{},this.pendingTasks=m(_n),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.navigationTransitions=m(vI),this.urlSerializer=m(rd),this.location=m(Di),this.urlHandlingStrategy=m(dd),this._events=new _e,this.errorHandler=this.options.errorHandler||CI,this.navigated=!1,this.routeReuseStrategy=m(wI),this.onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore",this.config=m(ud,{optional:!0})?.flat()??[],this.componentInputBindingEnabled=!!m(sd,{optional:!0}),this.eventsSubscription=new le,this.isNgZoneEnabled=m(ne)instanceof ne&&ne.isInAngularZone(),this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this,this.currentUrlTree,this.routerState).subscribe({error:t=>{this.console.warn(t)}}),this.subscribeToNavigationEvents()}subscribeToNavigationEvents(){let t=this.navigationTransitions.events.subscribe(r=>{try{let i=this.navigationTransitions.currentTransition,o=this.navigationTransitions.currentNavigation;if(i!==null&&o!==null){if(this.stateManager.handleRouterEvent(r,o),r instanceof Gt&&r.code!==$e.Redirect&&r.code!==$e.SupersededByNewNavigation)this.navigated=!0;else if(r instanceof zt)this.navigated=!0;else if(r instanceof ji){let s=this.urlHandlingStrategy.merge(r.url,i.currentRawUrl),a={info:i.extras.info,skipLocationChange:i.extras.skipLocationChange,replaceUrl:this.urlUpdateStrategy==="eager"||yI(i.source)};this.scheduleNavigation(s,Ni,null,a,{resolve:i.resolve,reject:i.reject,promise:i.promise})}}SI(r)&&this._events.next(r)}catch(i){this.navigationTransitions.transitionAbortSubject.next(i)}});this.eventsSubscription.add(t)}resetRootComponentType(t){this.routerState.root.component=t,this.navigationTransitions.rootComponentType=t}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),Ni,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((t,r)=>{setTimeout(()=>{this.navigateToSyncWithBrowser(t,"popstate",r)},0)})}navigateToSyncWithBrowser(t,r,i){let o={replaceUrl:!0},s=i?.navigationId?i:null;if(i){let c=b({},i);delete c.navigationId,delete c.\u0275routerPageId,Object.keys(c).length!==0&&(o.state=c)}let a=this.parseUrl(t);this.scheduleNavigation(a,r,s,o)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(t){this.config=t.map(ad),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(t,r={}){let{relativeTo:i,queryParams:o,fragment:s,queryParamsHandling:a,preserveFragment:c}=r,l=c?this.currentUrlTree.fragment:s,u=null;switch(a){case"merge":u=b(b({},this.currentUrlTree.queryParams),o);break;case"preserve":u=this.currentUrlTree.queryParams;break;default:u=o||null}u!==null&&(u=this.removeEmptyProps(u));let d;try{let p=i?i.snapshot:this.routerState.snapshot.root;d=fm(p)}catch{(typeof t[0]!="string"||!t[0].startsWith("/"))&&(t=[]),d=this.currentUrlTree.root}return hm(d,t,u,l??null)}navigateByUrl(t,r={skipLocationChange:!1}){let i=Mr(t)?t:this.parseUrl(t),o=this.urlHandlingStrategy.merge(i,this.rawUrlTree);return this.scheduleNavigation(o,Ni,null,r)}navigate(t,r={skipLocationChange:!1}){return MI(t),this.navigateByUrl(this.createUrlTree(t,r),r)}serializeUrl(t){return this.urlSerializer.serialize(t)}parseUrl(t){try{return this.urlSerializer.parse(t)}catch{return this.urlSerializer.parse("/")}}isActive(t,r){let i;if(r===!0?i=b({},EI):r===!1?i=b({},II):i=r,Mr(t))return Kg(this.currentUrlTree,t,i);let o=this.parseUrl(t);return Kg(this.currentUrlTree,o,i)}removeEmptyProps(t){return Object.entries(t).reduce((r,[i,o])=>(o!=null&&(r[i]=o),r),{})}scheduleNavigation(t,r,i,o,s){if(this.disposed)return Promise.resolve(!1);let a,c,l;s?(a=s.resolve,c=s.reject,l=s.promise):l=new Promise((d,p)=>{a=d,c=p});let u=this.pendingTasks.add();return bI(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(u))}),this.navigationTransitions.handleNavigationRequest({source:r,restoredState:i,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:t,extras:o,resolve:a,reject:c,promise:l,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),l.catch(d=>Promise.reject(d))}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function MI(e){for(let n=0;n{class e{constructor(t,r,i,o,s,a){this.router=t,this.route=r,this.tabIndexAttribute=i,this.renderer=o,this.el=s,this.locationStrategy=a,this.href=null,this.commands=null,this.onChanges=new _e,this.preserveFragment=!1,this.skipLocationChange=!1,this.replaceUrl=!1;let c=s.nativeElement.tagName?.toLowerCase();this.isAnchorElement=c==="a"||c==="area",this.isAnchorElement?this.subscription=t.events.subscribe(l=>{l instanceof zt&&this.updateHref()}):this.setTabIndexIfNotOnNativeEl("0")}setTabIndexIfNotOnNativeEl(t){this.tabIndexAttribute!=null||this.isAnchorElement||this.applyAttributeValue("tabindex",t)}ngOnChanges(t){this.isAnchorElement&&this.updateHref(),this.onChanges.next(this)}set routerLink(t){t!=null?(this.commands=Array.isArray(t)?t:[t],this.setTabIndexIfNotOnNativeEl("0")):(this.commands=null,this.setTabIndexIfNotOnNativeEl(null))}onClick(t,r,i,o,s){let a=this.urlTree;if(a===null||this.isAnchorElement&&(t!==0||r||i||o||s||typeof this.target=="string"&&this.target!="_self"))return!0;let c={skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info};return this.router.navigateByUrl(a,c),!this.isAnchorElement}ngOnDestroy(){this.subscription?.unsubscribe()}updateHref(){let t=this.urlTree;this.href=t!==null&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(t)):null;let r=this.href===null?null:Ap(this.href,this.el.nativeElement.tagName.toLowerCase(),"href");this.applyAttributeValue("href",r)}applyAttributeValue(t,r){let i=this.renderer,o=this.el.nativeElement;r!==null?i.setAttribute(o,t,r):i.removeAttribute(o,t)}get urlTree(){return this.commands===null?null:this.router.createUrlTree(this.commands,{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(r){return new(r||e)(K(Ue),K(at),Gl("tabindex"),K(yn),K(Vt),K(wr))}}static{this.\u0275dir=je({type:e,selectors:[["","routerLink",""]],hostVars:1,hostBindings:function(r,i){r&1&&ae("click",function(s){return i.onClick(s.button,s.ctrlKey,s.shiftKey,s.altKey,s.metaKey)}),r&2&&Vs("target",i.target)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[se.HasDecoratorInputTransform,"preserveFragment","preserveFragment",vr],skipLocationChange:[se.HasDecoratorInputTransform,"skipLocationChange","skipLocationChange",vr],replaceUrl:[se.HasDecoratorInputTransform,"replaceUrl","replaceUrl",vr],routerLink:"routerLink"},standalone:!0,features:[cu,Lt]})}}return e})();var xI=new M("");function Am(e,...n){return fr([{provide:ud,multi:!0,useValue:e},[],{provide:at,useFactory:TI,deps:[Ue]},{provide:Hs,multi:!0,useFactory:AI},n.map(t=>t.\u0275providers)])}function TI(e){return e.routerState.root}function AI(){let e=m(mn);return n=>{let t=e.get(mr);if(n!==t.components[0])return;let r=e.get(Ue),i=e.get(OI);e.get(NI)===1&&r.initialNavigation(),e.get(RI,null,L.Optional)?.setUpPreloading(),e.get(xI,null,L.Optional)?.init(),r.resetRootComponentType(t.componentTypes[0]),i.closed||(i.next(),i.complete(),i.unsubscribe())}}var OI=new M("",{factory:()=>new _e}),NI=new M("",{providedIn:"root",factory:()=>1});var RI=new M("");var Vm=(()=>{class e{constructor(t,r){this._renderer=t,this._elementRef=r,this.onChange=i=>{},this.onTouched=()=>{}}setProperty(t,r){this._renderer.setProperty(this._elementRef.nativeElement,t,r)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty("disabled",t)}static{this.\u0275fac=function(r){return new(r||e)(K(yn),K(Vt))}}static{this.\u0275dir=je({type:e})}}return e})(),PI=(()=>{class e extends Vm{static{this.\u0275fac=(()=>{let t;return function(i){return(t||(t=yi(e)))(i||e)}})()}static{this.\u0275dir=je({type:e,features:[Ut]})}}return e})(),$m=new M("");var kI={provide:$m,useExisting:dr(()=>Zt),multi:!0};function FI(){let e=It()?It().getUserAgent():"";return/android (\d+)/.test(e.toLowerCase())}var LI=new M(""),Zt=(()=>{class e extends Vm{constructor(t,r,i){super(t,r),this._compositionMode=i,this._composing=!1,this._compositionMode==null&&(this._compositionMode=!FI())}writeValue(t){let r=t??"";this.setProperty("value",r)}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}static{this.\u0275fac=function(r){return new(r||e)(K(yn),K(Vt),K(LI,8))}}static{this.\u0275dir=je({type:e,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(r,i){r&1&&ae("input",function(s){return i._handleInput(s.target.value)})("blur",function(){return i.onTouched()})("compositionstart",function(){return i._compositionStart()})("compositionend",function(s){return i._compositionEnd(s.target.value)})},features:[Us([kI]),Ut]})}}return e})();function Wt(e){return e==null||(typeof e=="string"||Array.isArray(e))&&e.length===0}function Um(e){return e!=null&&typeof e.length=="number"}var Bm=new M(""),Hm=new M(""),jI=/^(?=.{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])?)*$/,Me=class{static min(n){return VI(n)}static max(n){return $I(n)}static required(n){return UI(n)}static requiredTrue(n){return BI(n)}static email(n){return HI(n)}static minLength(n){return zI(n)}static maxLength(n){return GI(n)}static pattern(n){return qI(n)}static nullValidator(n){return zm(n)}static compose(n){return Qm(n)}static composeAsync(n){return Jm(n)}};function VI(e){return n=>{if(Wt(n.value)||Wt(e))return null;let t=parseFloat(n.value);return!isNaN(t)&&t{if(Wt(n.value)||Wt(e))return null;let t=parseFloat(n.value);return!isNaN(t)&&t>e?{max:{max:e,actual:n.value}}:null}}function UI(e){return Wt(e.value)?{required:!0}:null}function BI(e){return e.value===!0?null:{required:!0}}function HI(e){return Wt(e.value)||jI.test(e.value)?null:{email:!0}}function zI(e){return n=>Wt(n.value)||!Um(n.value)?null:n.value.lengthUm(n.value)&&n.value.length>e?{maxlength:{requiredLength:e,actualLength:n.value.length}}:null}function qI(e){if(!e)return zm;let n,t;return typeof e=="string"?(t="",e.charAt(0)!=="^"&&(t+="^"),t+=e,e.charAt(e.length-1)!=="$"&&(t+="$"),n=new RegExp(t)):(t=e.toString(),n=e),r=>{if(Wt(r.value))return null;let i=r.value;return n.test(i)?null:{pattern:{requiredPattern:t,actualValue:i}}}}function zm(e){return null}function Gm(e){return e!=null}function qm(e){return Dn(e)?te(e):e}function Wm(e){let n={};return e.forEach(t=>{n=t!=null?b(b({},n),t):n}),Object.keys(n).length===0?null:n}function Zm(e,n){return n.map(t=>t(e))}function WI(e){return!e.validate}function Ym(e){return e.map(n=>WI(n)?n:t=>n.validate(t))}function Qm(e){if(!e)return null;let n=e.filter(Gm);return n.length==0?null:function(t){return Wm(Zm(t,n))}}function Km(e){return e!=null?Qm(Ym(e)):null}function Jm(e){if(!e)return null;let n=e.filter(Gm);return n.length==0?null:function(t){let r=Zm(t,n).map(qm);return vc(r).pipe(N(Wm))}}function Xm(e){return e!=null?Jm(Ym(e)):null}function Om(e,n){return e===null?[n]:Array.isArray(e)?[...e,n]:[e,n]}function ev(e){return e._rawValidators}function tv(e){return e._rawAsyncValidators}function fd(e){return e?Array.isArray(e)?e:[e]:[]}function wa(e,n){return Array.isArray(e)?e.includes(n):e===n}function Nm(e,n){let t=fd(n);return fd(e).forEach(i=>{wa(t,i)||t.push(i)}),t}function Rm(e,n){return fd(n).filter(t=>!wa(e,t))}var _a=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(n){this._rawValidators=n||[],this._composedValidatorFn=Km(this._rawValidators)}_setAsyncValidators(n){this._rawAsyncValidators=n||[],this._composedAsyncValidatorFn=Xm(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(n){this._onDestroyCallbacks.push(n)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(n=>n()),this._onDestroyCallbacks=[]}reset(n=void 0){this.control&&this.control.reset(n)}hasError(n,t){return this.control?this.control.hasError(n,t):!1}getError(n,t){return this.control?this.control.getError(n,t):null}},Ar=class extends _a{get formDirective(){return null}get path(){return null}},Zi=class extends _a{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}},Da=class{constructor(n){this._cd=n}get isTouched(){return!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return!!this._cd?.submitted}},ZI={"[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"},fk=G(b({},ZI),{"[class.ng-submitted]":"isSubmitted"}),Nr=(()=>{class e extends Da{constructor(t){super(t)}static{this.\u0275fac=function(r){return new(r||e)(K(Zi,2))}}static{this.\u0275dir=je({type:e,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(r,i){r&2&&me("ng-untouched",i.isUntouched)("ng-touched",i.isTouched)("ng-pristine",i.isPristine)("ng-dirty",i.isDirty)("ng-valid",i.isValid)("ng-invalid",i.isInvalid)("ng-pending",i.isPending)},features:[Ut]})}}return e})(),Rr=(()=>{class e extends Da{constructor(t){super(t)}static{this.\u0275fac=function(r){return new(r||e)(K(Ar,10))}}static{this.\u0275dir=je({type:e,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(r,i){r&2&&me("ng-untouched",i.isUntouched)("ng-touched",i.isTouched)("ng-pristine",i.isPristine)("ng-dirty",i.isDirty)("ng-valid",i.isValid)("ng-invalid",i.isInvalid)("ng-pending",i.isPending)("ng-submitted",i.isSubmitted)},features:[Ut]})}}return e})();var qi="VALID",va="INVALID",Tr="PENDING",Wi="DISABLED";function gd(e){return(Ia(e)?e.validators:e)||null}function YI(e){return Array.isArray(e)?Km(e):e||null}function md(e,n){return(Ia(n)?n.asyncValidators:e)||null}function QI(e){return Array.isArray(e)?Xm(e):e||null}function Ia(e){return e!=null&&!Array.isArray(e)&&typeof e=="object"}function nv(e,n,t){let r=e.controls;if(!(n?Object.keys(r):r).length)throw new E(1e3,"");if(!r[t])throw new E(1001,"")}function rv(e,n,t){e._forEachChild((r,i)=>{if(t[i]===void 0)throw new E(1002,"")})}var Or=class{constructor(n,t){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=!1,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this.pristine=!0,this.touched=!1,this._onDisabledChange=[],this._assignValidators(n),this._assignAsyncValidators(t)}get validator(){return this._composedValidatorFn}set validator(n){this._rawValidators=this._composedValidatorFn=n}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(n){this._rawAsyncValidators=this._composedAsyncValidatorFn=n}get parent(){return this._parent}get valid(){return this.status===qi}get invalid(){return this.status===va}get pending(){return this.status==Tr}get disabled(){return this.status===Wi}get enabled(){return this.status!==Wi}get dirty(){return!this.pristine}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(n){this._assignValidators(n)}setAsyncValidators(n){this._assignAsyncValidators(n)}addValidators(n){this.setValidators(Nm(n,this._rawValidators))}addAsyncValidators(n){this.setAsyncValidators(Nm(n,this._rawAsyncValidators))}removeValidators(n){this.setValidators(Rm(n,this._rawValidators))}removeAsyncValidators(n){this.setAsyncValidators(Rm(n,this._rawAsyncValidators))}hasValidator(n){return wa(this._rawValidators,n)}hasAsyncValidator(n){return wa(this._rawAsyncValidators,n)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(n={}){this.touched=!0,this._parent&&!n.onlySelf&&this._parent.markAsTouched(n)}markAllAsTouched(){this.markAsTouched({onlySelf:!0}),this._forEachChild(n=>n.markAllAsTouched())}markAsUntouched(n={}){this.touched=!1,this._pendingTouched=!1,this._forEachChild(t=>{t.markAsUntouched({onlySelf:!0})}),this._parent&&!n.onlySelf&&this._parent._updateTouched(n)}markAsDirty(n={}){this.pristine=!1,this._parent&&!n.onlySelf&&this._parent.markAsDirty(n)}markAsPristine(n={}){this.pristine=!0,this._pendingDirty=!1,this._forEachChild(t=>{t.markAsPristine({onlySelf:!0})}),this._parent&&!n.onlySelf&&this._parent._updatePristine(n)}markAsPending(n={}){this.status=Tr,n.emitEvent!==!1&&this.statusChanges.emit(this.status),this._parent&&!n.onlySelf&&this._parent.markAsPending(n)}disable(n={}){let t=this._parentMarkedDirty(n.onlySelf);this.status=Wi,this.errors=null,this._forEachChild(r=>{r.disable(G(b({},n),{onlySelf:!0}))}),this._updateValue(),n.emitEvent!==!1&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors(G(b({},n),{skipPristineCheck:t})),this._onDisabledChange.forEach(r=>r(!0))}enable(n={}){let t=this._parentMarkedDirty(n.onlySelf);this.status=qi,this._forEachChild(r=>{r.enable(G(b({},n),{onlySelf:!0}))}),this.updateValueAndValidity({onlySelf:!0,emitEvent:n.emitEvent}),this._updateAncestors(G(b({},n),{skipPristineCheck:t})),this._onDisabledChange.forEach(r=>r(!1))}_updateAncestors(n){this._parent&&!n.onlySelf&&(this._parent.updateValueAndValidity(n),n.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}setParent(n){this._parent=n}getRawValue(){return this.value}updateValueAndValidity(n={}){this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===qi||this.status===Tr)&&this._runAsyncValidator(n.emitEvent)),n.emitEvent!==!1&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!n.onlySelf&&this._parent.updateValueAndValidity(n)}_updateTreeValidity(n={emitEvent:!0}){this._forEachChild(t=>t._updateTreeValidity(n)),this.updateValueAndValidity({onlySelf:!0,emitEvent:n.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?Wi:qi}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(n){if(this.asyncValidator){this.status=Tr,this._hasOwnPendingAsyncValidator=!0;let t=qm(this.asyncValidator(this));this._asyncValidationSubscription=t.subscribe(r=>{this._hasOwnPendingAsyncValidator=!1,this.setErrors(r,{emitEvent:n})})}}_cancelExistingSubscription(){this._asyncValidationSubscription&&(this._asyncValidationSubscription.unsubscribe(),this._hasOwnPendingAsyncValidator=!1)}setErrors(n,t={}){this.errors=n,this._updateControlsErrors(t.emitEvent!==!1)}get(n){let t=n;return t==null||(Array.isArray(t)||(t=t.split(".")),t.length===0)?null:t.reduce((r,i)=>r&&r._find(i),this)}getError(n,t){let r=t?this.get(t):this;return r&&r.errors?r.errors[n]:null}hasError(n,t){return!!this.getError(n,t)}get root(){let n=this;for(;n._parent;)n=n._parent;return n}_updateControlsErrors(n){this.status=this._calculateStatus(),n&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(n)}_initObservables(){this.valueChanges=new De,this.statusChanges=new De}_calculateStatus(){return this._allControlsDisabled()?Wi:this.errors?va:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(Tr)?Tr:this._anyControlsHaveStatus(va)?va:qi}_anyControlsHaveStatus(n){return this._anyControls(t=>t.status===n)}_anyControlsDirty(){return this._anyControls(n=>n.dirty)}_anyControlsTouched(){return this._anyControls(n=>n.touched)}_updatePristine(n={}){this.pristine=!this._anyControlsDirty(),this._parent&&!n.onlySelf&&this._parent._updatePristine(n)}_updateTouched(n={}){this.touched=this._anyControlsTouched(),this._parent&&!n.onlySelf&&this._parent._updateTouched(n)}_registerOnCollectionChange(n){this._onCollectionChange=n}_setUpdateStrategy(n){Ia(n)&&n.updateOn!=null&&(this._updateOn=n.updateOn)}_parentMarkedDirty(n){let t=this._parent&&this._parent.dirty;return!n&&!!t&&!this._parent._anyControlsDirty()}_find(n){return null}_assignValidators(n){this._rawValidators=Array.isArray(n)?n.slice():n,this._composedValidatorFn=YI(this._rawValidators)}_assignAsyncValidators(n){this._rawAsyncValidators=Array.isArray(n)?n.slice():n,this._composedAsyncValidatorFn=QI(this._rawAsyncValidators)}},ba=class extends Or{constructor(n,t,r){super(gd(t),md(r,t)),this.controls=n,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(n,t){return this.controls[n]?this.controls[n]:(this.controls[n]=t,t.setParent(this),t._registerOnCollectionChange(this._onCollectionChange),t)}addControl(n,t,r={}){this.registerControl(n,t),this.updateValueAndValidity({emitEvent:r.emitEvent}),this._onCollectionChange()}removeControl(n,t={}){this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),delete this.controls[n],this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}setControl(n,t,r={}){this.controls[n]&&this.controls[n]._registerOnCollectionChange(()=>{}),delete this.controls[n],t&&this.registerControl(n,t),this.updateValueAndValidity({emitEvent:r.emitEvent}),this._onCollectionChange()}contains(n){return this.controls.hasOwnProperty(n)&&this.controls[n].enabled}setValue(n,t={}){rv(this,!0,n),Object.keys(n).forEach(r=>{nv(this,!0,r),this.controls[r].setValue(n[r],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(n,t={}){n!=null&&(Object.keys(n).forEach(r=>{let i=this.controls[r];i&&i.patchValue(n[r],{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(n={},t={}){this._forEachChild((r,i)=>{r.reset(n?n[i]:null,{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t),this._updateTouched(t),this.updateValueAndValidity(t)}getRawValue(){return this._reduceChildren({},(n,t,r)=>(n[r]=t.getRawValue(),n))}_syncPendingControls(){let n=this._reduceChildren(!1,(t,r)=>r._syncPendingControls()?!0:t);return n&&this.updateValueAndValidity({onlySelf:!0}),n}_forEachChild(n){Object.keys(this.controls).forEach(t=>{let r=this.controls[t];r&&n(r,t)})}_setUpControls(){this._forEachChild(n=>{n.setParent(this),n._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(n){for(let[t,r]of Object.entries(this.controls))if(this.contains(t)&&n(r))return!0;return!1}_reduceValue(){let n={};return this._reduceChildren(n,(t,r,i)=>((r.enabled||this.disabled)&&(t[i]=r.value),t))}_reduceChildren(n,t){let r=n;return this._forEachChild((i,o)=>{r=t(r,i,o)}),r}_allControlsDisabled(){for(let n of Object.keys(this.controls))if(this.controls[n].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(n){return this.controls.hasOwnProperty(n)?this.controls[n]:null}};var hd=class extends ba{};var iv=new M("CallSetDisabledState",{providedIn:"root",factory:()=>vd}),vd="always";function KI(e,n){return[...n.path,e]}function Pm(e,n,t=vd){yd(e,n),n.valueAccessor.writeValue(e.value),(e.disabled||t==="always")&&n.valueAccessor.setDisabledState?.(e.disabled),XI(e,n),tM(e,n),eM(e,n),JI(e,n)}function km(e,n,t=!0){let r=()=>{};n.valueAccessor&&(n.valueAccessor.registerOnChange(r),n.valueAccessor.registerOnTouched(r)),Ea(e,n),e&&(n._invokeOnDestroyCallbacks(),e._registerOnCollectionChange(()=>{}))}function Ca(e,n){e.forEach(t=>{t.registerOnValidatorChange&&t.registerOnValidatorChange(n)})}function JI(e,n){if(n.valueAccessor.setDisabledState){let t=r=>{n.valueAccessor.setDisabledState(r)};e.registerOnDisabledChange(t),n._registerOnDestroy(()=>{e._unregisterOnDisabledChange(t)})}}function yd(e,n){let t=ev(e);n.validator!==null?e.setValidators(Om(t,n.validator)):typeof t=="function"&&e.setValidators([t]);let r=tv(e);n.asyncValidator!==null?e.setAsyncValidators(Om(r,n.asyncValidator)):typeof r=="function"&&e.setAsyncValidators([r]);let i=()=>e.updateValueAndValidity();Ca(n._rawValidators,i),Ca(n._rawAsyncValidators,i)}function Ea(e,n){let t=!1;if(e!==null){if(n.validator!==null){let i=ev(e);if(Array.isArray(i)&&i.length>0){let o=i.filter(s=>s!==n.validator);o.length!==i.length&&(t=!0,e.setValidators(o))}}if(n.asyncValidator!==null){let i=tv(e);if(Array.isArray(i)&&i.length>0){let o=i.filter(s=>s!==n.asyncValidator);o.length!==i.length&&(t=!0,e.setAsyncValidators(o))}}}let r=()=>{};return Ca(n._rawValidators,r),Ca(n._rawAsyncValidators,r),t}function XI(e,n){n.valueAccessor.registerOnChange(t=>{e._pendingValue=t,e._pendingChange=!0,e._pendingDirty=!0,e.updateOn==="change"&&ov(e,n)})}function eM(e,n){n.valueAccessor.registerOnTouched(()=>{e._pendingTouched=!0,e.updateOn==="blur"&&e._pendingChange&&ov(e,n),e.updateOn!=="submit"&&e.markAsTouched()})}function ov(e,n){e._pendingDirty&&e.markAsDirty(),e.setValue(e._pendingValue,{emitModelToViewChange:!1}),n.viewToModelUpdate(e._pendingValue),e._pendingChange=!1}function tM(e,n){let t=(r,i)=>{n.valueAccessor.writeValue(r),i&&n.viewToModelUpdate(r)};e.registerOnChange(t),n._registerOnDestroy(()=>{e._unregisterOnChange(t)})}function nM(e,n){e==null,yd(e,n)}function rM(e,n){return Ea(e,n)}function iM(e,n){if(!e.hasOwnProperty("model"))return!1;let t=e.model;return t.isFirstChange()?!0:!Object.is(n,t.currentValue)}function oM(e){return Object.getPrototypeOf(e.constructor)===PI}function sM(e,n){e._syncPendingControls(),n.forEach(t=>{let r=t.control;r.updateOn==="submit"&&r._pendingChange&&(t.viewToModelUpdate(r._pendingValue),r._pendingChange=!1)})}function aM(e,n){if(!n)return null;Array.isArray(n);let t,r,i;return n.forEach(o=>{o.constructor===Zt?t=o:oM(o)?r=o:i=o}),i||r||t||null}function cM(e,n){let t=e.indexOf(n);t>-1&&e.splice(t,1)}function Fm(e,n){let t=e.indexOf(n);t>-1&&e.splice(t,1)}function Lm(e){return typeof e=="object"&&e!==null&&Object.keys(e).length===2&&"value"in e&&"disabled"in e}var ya=class extends Or{constructor(n=null,t,r){super(gd(t),md(r,t)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(n),this._setUpdateStrategy(t),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),Ia(t)&&(t.nonNullable||t.initialValueIsDefault)&&(Lm(n)?this.defaultValue=n.value:this.defaultValue=n)}setValue(n,t={}){this.value=this._pendingValue=n,this._onChange.length&&t.emitModelToViewChange!==!1&&this._onChange.forEach(r=>r(this.value,t.emitViewToModelChange!==!1)),this.updateValueAndValidity(t)}patchValue(n,t={}){this.setValue(n,t)}reset(n=this.defaultValue,t={}){this._applyFormState(n),this.markAsPristine(t),this.markAsUntouched(t),this.setValue(this.value,t),this._pendingChange=!1}_updateValue(){}_anyControls(n){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(n){this._onChange.push(n)}_unregisterOnChange(n){Fm(this._onChange,n)}registerOnDisabledChange(n){this._onDisabledChange.push(n)}_unregisterOnDisabledChange(n){Fm(this._onDisabledChange,n)}_forEachChild(n){}_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(n){Lm(n)?(this.value=this._pendingValue=n.value,n.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=n}};var lM=e=>e instanceof ya;var Pr=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275dir=je({type:e,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""]})}}return e})();var sv=new M("");var uM={provide:Ar,useExisting:dr(()=>xn)},xn=(()=>{class e extends Ar{constructor(t,r,i){super(),this.callSetDisabledState=i,this.submitted=!1,this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new De,this._setValidators(t),this._setAsyncValidators(r)}ngOnChanges(t){this._checkFormPresent(),t.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(Ea(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(t){let r=this.form.get(t.path);return Pm(r,t,this.callSetDisabledState),r.updateValueAndValidity({emitEvent:!1}),this.directives.push(t),r}getControl(t){return this.form.get(t.path)}removeControl(t){km(t.control||null,t,!1),cM(this.directives,t)}addFormGroup(t){this._setUpFormContainer(t)}removeFormGroup(t){this._cleanUpFormContainer(t)}getFormGroup(t){return this.form.get(t.path)}addFormArray(t){this._setUpFormContainer(t)}removeFormArray(t){this._cleanUpFormContainer(t)}getFormArray(t){return this.form.get(t.path)}updateModel(t,r){this.form.get(t.path).setValue(r)}onSubmit(t){return this.submitted=!0,sM(this.form,this.directives),this.ngSubmit.emit(t),t?.target?.method==="dialog"}onReset(){this.resetForm()}resetForm(t=void 0){this.form.reset(t),this.submitted=!1}_updateDomValue(){this.directives.forEach(t=>{let r=t.control,i=this.form.get(t.path);r!==i&&(km(r||null,t),lM(i)&&(Pm(i,t,this.callSetDisabledState),t.control=i))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(t){let r=this.form.get(t.path);nM(r,t),r.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(t){if(this.form){let r=this.form.get(t.path);r&&rM(r,t)&&r.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){yd(this.form,this),this._oldForm&&Ea(this._oldForm,this)}_checkFormPresent(){this.form}static{this.\u0275fac=function(r){return new(r||e)(K(Bm,10),K(Hm,10),K(iv,8))}}static{this.\u0275dir=je({type:e,selectors:[["","formGroup",""]],hostBindings:function(r,i){r&1&&ae("submit",function(s){return i.onSubmit(s)})("reset",function(){return i.onReset()})},inputs:{form:[se.None,"formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[Us([uM]),Ut,Lt]})}}return e})();var dM={provide:Zi,useExisting:dr(()=>Tn)},Tn=(()=>{class e extends Zi{set isDisabled(t){}static{this._ngModelWarningSentOnce=!1}constructor(t,r,i,o,s){super(),this._ngModelWarningConfig=s,this._added=!1,this.name=null,this.update=new De,this._ngModelWarningSent=!1,this._parent=t,this._setValidators(r),this._setAsyncValidators(i),this.valueAccessor=aM(this,o)}ngOnChanges(t){this._added||this._setUpControl(),iM(t,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}get path(){return KI(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(r){return new(r||e)(K(Ar,13),K(Bm,10),K(Hm,10),K($m,10),K(sv,8))}}static{this.\u0275dir=je({type:e,selectors:[["","formControlName",""]],inputs:{name:[se.None,"formControlName","name"],isDisabled:[se.None,"disabled","isDisabled"],model:[se.None,"ngModel","model"]},outputs:{update:"ngModelChange"},features:[Us([dM]),Ut,Lt]})}}return e})();var fM=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275mod=pn({type:e})}static{this.\u0275inj=hn({})}}return e})(),pd=class extends Or{constructor(n,t,r){super(gd(t),md(r,t)),this.controls=n,this._initObservables(),this._setUpdateStrategy(t),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}at(n){return this.controls[this._adjustIndex(n)]}push(n,t={}){this.controls.push(n),this._registerControl(n),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}insert(n,t,r={}){this.controls.splice(n,0,t),this._registerControl(t),this.updateValueAndValidity({emitEvent:r.emitEvent})}removeAt(n,t={}){let r=this._adjustIndex(n);r<0&&(r=0),this.controls[r]&&this.controls[r]._registerOnCollectionChange(()=>{}),this.controls.splice(r,1),this.updateValueAndValidity({emitEvent:t.emitEvent})}setControl(n,t,r={}){let i=this._adjustIndex(n);i<0&&(i=0),this.controls[i]&&this.controls[i]._registerOnCollectionChange(()=>{}),this.controls.splice(i,1),t&&(this.controls.splice(i,0,t),this._registerControl(t)),this.updateValueAndValidity({emitEvent:r.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(n,t={}){rv(this,!1,n),n.forEach((r,i)=>{nv(this,!1,i),this.at(i).setValue(r,{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t)}patchValue(n,t={}){n!=null&&(n.forEach((r,i)=>{this.at(i)&&this.at(i).patchValue(r,{onlySelf:!0,emitEvent:t.emitEvent})}),this.updateValueAndValidity(t))}reset(n=[],t={}){this._forEachChild((r,i)=>{r.reset(n[i],{onlySelf:!0,emitEvent:t.emitEvent})}),this._updatePristine(t),this._updateTouched(t),this.updateValueAndValidity(t)}getRawValue(){return this.controls.map(n=>n.getRawValue())}clear(n={}){this.controls.length<1||(this._forEachChild(t=>t._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:n.emitEvent}))}_adjustIndex(n){return n<0?n+this.length:n}_syncPendingControls(){let n=this.controls.reduce((t,r)=>r._syncPendingControls()?!0:t,!1);return n&&this.updateValueAndValidity({onlySelf:!0}),n}_forEachChild(n){this.controls.forEach((t,r)=>{n(t,r)})}_updateValue(){this.value=this.controls.filter(n=>n.enabled||this.disabled).map(n=>n.value)}_anyControls(n){return this.controls.some(t=>t.enabled&&n(t))}_setUpControls(){this._forEachChild(n=>this._registerControl(n))}_allControlsDisabled(){for(let n of this.controls)if(n.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(n){n.setParent(this),n._registerOnCollectionChange(this._onCollectionChange)}_find(n){return this.at(n)??null}};function jm(e){return!!e&&(e.asyncValidators!==void 0||e.validators!==void 0||e.updateOn!==void 0)}var kr=(()=>{class e{constructor(){this.useNonNullable=!1}get nonNullable(){let t=new e;return t.useNonNullable=!0,t}group(t,r=null){let i=this._reduceControls(t),o={};return jm(r)?o=r:r!==null&&(o.validators=r.validator,o.asyncValidators=r.asyncValidator),new ba(i,o)}record(t,r=null){let i=this._reduceControls(t);return new hd(i,r)}control(t,r,i){let o={};return this.useNonNullable?(jm(r)?o=r:(o.validators=r,o.asyncValidators=i),new ya(t,G(b({},o),{nonNullable:!0}))):new ya(t,r,i)}array(t,r,i){let o=t.map(s=>this._createControl(s));return new pd(o,r,i)}_reduceControls(t){let r={};return Object.keys(t).forEach(i=>{r[i]=this._createControl(t[i])}),r}_createControl(t){if(t instanceof ya)return t;if(t instanceof Or)return t;if(Array.isArray(t)){let r=t[0],i=t.length>1?t[1]:null,o=t.length>2?t[2]:null;return this.control(r,i,o)}else return this.control(t)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var Fr=(()=>{class e{static withConfig(t){return{ngModule:e,providers:[{provide:sv,useValue:t.warnOnNgModelWithFormControl??"always"},{provide:iv,useValue:t.callSetDisabledState??vd}]}}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275mod=pn({type:e})}static{this.\u0275inj=hn({imports:[fM]})}}return e})();var av=e=>{let n;return e?n=e:typeof fetch>"u"?n=(...t)=>import("./chunk-6ISG364Z.js").then(({default:r})=>r(...t)):n=fetch,(...t)=>n(...t)};var Yi=class extends Error{constructor(n,t="FunctionsError",r){super(n),this.name=t,this.context=r}},Ma=class extends Yi{constructor(n){super("Failed to send a request to the Edge Function","FunctionsFetchError",n)}},Sa=class extends Yi{constructor(n){super("Relay Error invoking the Edge Function","FunctionsRelayError",n)}},xa=class extends Yi{constructor(n){super("Edge Function returned a non-2xx status code","FunctionsHttpError",n)}},_d=function(e){return e.Any="any",e.ApNortheast1="ap-northeast-1",e.ApNortheast2="ap-northeast-2",e.ApSouth1="ap-south-1",e.ApSoutheast1="ap-southeast-1",e.ApSoutheast2="ap-southeast-2",e.CaCentral1="ca-central-1",e.EuCentral1="eu-central-1",e.EuWest1="eu-west-1",e.EuWest2="eu-west-2",e.EuWest3="eu-west-3",e.SaEast1="sa-east-1",e.UsEast1="us-east-1",e.UsWest1="us-west-1",e.UsWest2="us-west-2",e}(_d||{});var hM=function(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},Qi=class{constructor(n,{headers:t={},customFetch:r,region:i=_d.Any}={}){this.url=n,this.headers=t,this.region=i,this.fetch=av(r)}setAuth(n){this.headers.Authorization=`Bearer ${n}`}invoke(n,t={}){var r;return hM(this,void 0,void 0,function*(){try{let{headers:i,method:o,body:s}=t,a={},{region:c}=t;c||(c=this.region),c&&c!=="any"&&(a["x-region"]=c);let l;s&&(i&&!Object.prototype.hasOwnProperty.call(i,"Content-Type")||!i)&&(typeof Blob<"u"&&s instanceof Blob||s instanceof ArrayBuffer?(a["Content-Type"]="application/octet-stream",l=s):typeof s=="string"?(a["Content-Type"]="text/plain",l=s):typeof FormData<"u"&&s instanceof FormData?l=s:(a["Content-Type"]="application/json",l=JSON.stringify(s)));let u=yield this.fetch(`${this.url}/${n}`,{method:o||"POST",headers:Object.assign(Object.assign(Object.assign({},a),this.headers),i),body:l}).catch(w=>{throw new Ma(w)}),d=u.headers.get("x-relay-error");if(d&&d==="true")throw new Sa(u);if(!u.ok)throw new xa(u);let p=((r=u.headers.get("Content-Type"))!==null&&r!==void 0?r:"text/plain").split(";")[0].trim(),f;return p==="application/json"?f=yield u.json():p==="application/octet-stream"?f=yield u.blob():p==="text/event-stream"?f=u:p==="multipart/form-data"?f=yield u.formData():f=yield u.text(),{data:f,error:null}}catch(i){return{data:null,error:i}}})}};var _v=by(wv(),1),{PostgrestClient:Dv,PostgrestQueryBuilder:Nk,PostgrestFilterBuilder:Rk,PostgrestTransformBuilder:Pk,PostgrestBuilder:kk}=_v.default;var bv="2.10.7";var Cv={"X-Client-Info":`realtime-js/${bv}`},Ev="1.0.0",Na=1e4,Iv=1e3,jr=function(e){return e[e.connecting=0]="connecting",e[e.open=1]="open",e[e.closing=2]="closing",e[e.closed=3]="closed",e}(jr||{}),Be=function(e){return e.closed="closed",e.errored="errored",e.joined="joined",e.joining="joining",e.leaving="leaving",e}(Be||{}),Ye=function(e){return e.close="phx_close",e.error="phx_error",e.join="phx_join",e.reply="phx_reply",e.leave="phx_leave",e.access_token="access_token",e}(Ye||{}),Nd=function(e){return e.websocket="websocket",e}(Nd||{}),An=function(e){return e.Connecting="connecting",e.Open="open",e.Closing="closing",e.Closed="closed",e}(An||{});var Ra=class{constructor(){this.HEADER_LENGTH=1}decode(n,t){return n.constructor===ArrayBuffer?t(this._binaryDecode(n)):t(typeof n=="string"?JSON.parse(n):{})}_binaryDecode(n){let t=new DataView(n),r=new TextDecoder;return this._decodeBroadcast(n,t,r)}_decodeBroadcast(n,t,r){let i=t.getUint8(1),o=t.getUint8(2),s=this.HEADER_LENGTH+2,a=r.decode(n.slice(s,s+i));s=s+i;let c=r.decode(n.slice(s,s+o));s=s+o;let l=JSON.parse(r.decode(n.slice(s,n.byteLength)));return{ref:null,topic:a,event:c,payload:l}}};var Vr=class{constructor(n,t){this.callback=n,this.timerCalc=t,this.timer=void 0,this.tries=0,this.callback=n,this.timerCalc=t}reset(){this.tries=0,clearTimeout(this.timer)}scheduleTimeout(){clearTimeout(this.timer),this.timer=setTimeout(()=>{this.tries=this.tries+1,this.callback()},this.timerCalc(this.tries+1))}};var X=function(e){return e.abstime="abstime",e.bool="bool",e.date="date",e.daterange="daterange",e.float4="float4",e.float8="float8",e.int2="int2",e.int4="int4",e.int4range="int4range",e.int8="int8",e.int8range="int8range",e.json="json",e.jsonb="jsonb",e.money="money",e.numeric="numeric",e.oid="oid",e.reltime="reltime",e.text="text",e.time="time",e.timestamp="timestamp",e.timestamptz="timestamptz",e.timetz="timetz",e.tsrange="tsrange",e.tstzrange="tstzrange",e}(X||{}),Pd=(e,n,t={})=>{var r;let i=(r=t.skipTypes)!==null&&r!==void 0?r:[];return Object.keys(n).reduce((o,s)=>(o[s]=IM(s,e,n,i),o),{})},IM=(e,n,t,r)=>{let i=n.find(a=>a.name===e),o=i?.type,s=t[e];return o&&!r.includes(o)?Mv(o,s):Rd(s)},Mv=(e,n)=>{if(e.charAt(0)==="_"){let t=e.slice(1,e.length);return TM(n,t)}switch(e){case X.bool:return MM(n);case X.float4:case X.float8:case X.int2:case X.int4:case X.int8:case X.numeric:case X.oid:return SM(n);case X.json:case X.jsonb:return xM(n);case X.timestamp:return AM(n);case X.abstime:case X.date:case X.daterange:case X.int4range:case X.int8range:case X.money:case X.reltime:case X.text:case X.time:case X.timestamptz:case X.timetz:case X.tsrange:case X.tstzrange:return Rd(n);default:return Rd(n)}},Rd=e=>e,MM=e=>{switch(e){case"t":return!0;case"f":return!1;default:return e}},SM=e=>{if(typeof e=="string"){let n=parseFloat(e);if(!Number.isNaN(n))return n}return e},xM=e=>{if(typeof e=="string")try{return JSON.parse(e)}catch(n){return console.log(`JSON parse error: ${n}`),e}return e},TM=(e,n)=>{if(typeof e!="string")return e;let t=e.length-1,r=e[t];if(e[0]==="{"&&r==="}"){let o,s=e.slice(1,t);try{o=JSON.parse("["+s+"]")}catch{o=s?s.split(","):[]}return o.map(a=>Mv(n,a))}return e},AM=e=>typeof e=="string"?e.replace(" ","T"):e,Pa=e=>{let n=e;return n=n.replace(/^ws/i,"http"),n=n.replace(/(\/socket\/websocket|\/socket|\/websocket)\/?$/i,""),n.replace(/\/+$/,"")};var $r=class{constructor(n,t,r={},i=Na){this.channel=n,this.event=t,this.payload=r,this.timeout=i,this.sent=!1,this.timeoutTimer=void 0,this.ref="",this.receivedResp=null,this.recHooks=[],this.refEvent=null}resend(n){this.timeout=n,this._cancelRefEvent(),this.ref="",this.refEvent=null,this.receivedResp=null,this.sent=!1,this.send()}send(){this._hasReceived("timeout")||(this.startTimeout(),this.sent=!0,this.channel.socket.push({topic:this.channel.topic,event:this.event,payload:this.payload,ref:this.ref,join_ref:this.channel._joinRef()}))}updatePayload(n){this.payload=Object.assign(Object.assign({},this.payload),n)}receive(n,t){var r;return this._hasReceived(n)&&t((r=this.receivedResp)===null||r===void 0?void 0:r.response),this.recHooks.push({status:n,callback:t}),this}startTimeout(){if(this.timeoutTimer)return;this.ref=this.channel.socket._makeRef(),this.refEvent=this.channel._replyEventName(this.ref);let n=t=>{this._cancelRefEvent(),this._cancelTimeout(),this.receivedResp=t,this._matchReceive(t)};this.channel._on(this.refEvent,{},n),this.timeoutTimer=setTimeout(()=>{this.trigger("timeout",{})},this.timeout)}trigger(n,t){this.refEvent&&this.channel._trigger(this.refEvent,{status:n,response:t})}destroy(){this._cancelRefEvent(),this._cancelTimeout()}_cancelRefEvent(){this.refEvent&&this.channel._off(this.refEvent,{})}_cancelTimeout(){clearTimeout(this.timeoutTimer),this.timeoutTimer=void 0}_matchReceive({status:n,response:t}){this.recHooks.filter(r=>r.status===n).forEach(r=>r.callback(t))}_hasReceived(n){return this.receivedResp&&this.receivedResp.status===n}};var ro=class e{constructor(n,t){this.channel=n,this.state={},this.pendingDiffs=[],this.joinRef=null,this.caller={onJoin:()=>{},onLeave:()=>{},onSync:()=>{}};let r=t?.events||{state:"presence_state",diff:"presence_diff"};this.channel._on(r.state,{},i=>{let{onJoin:o,onLeave:s,onSync:a}=this.caller;this.joinRef=this.channel._joinRef(),this.state=e.syncState(this.state,i,o,s),this.pendingDiffs.forEach(c=>{this.state=e.syncDiff(this.state,c,o,s)}),this.pendingDiffs=[],a()}),this.channel._on(r.diff,{},i=>{let{onJoin:o,onLeave:s,onSync:a}=this.caller;this.inPendingSyncState()?this.pendingDiffs.push(i):(this.state=e.syncDiff(this.state,i,o,s),a())}),this.onJoin((i,o,s)=>{this.channel._trigger("presence",{event:"join",key:i,currentPresences:o,newPresences:s})}),this.onLeave((i,o,s)=>{this.channel._trigger("presence",{event:"leave",key:i,currentPresences:o,leftPresences:s})}),this.onSync(()=>{this.channel._trigger("presence",{event:"sync"})})}static syncState(n,t,r,i){let o=this.cloneDeep(n),s=this.transformState(t),a={},c={};return this.map(o,(l,u)=>{s[l]||(c[l]=u)}),this.map(s,(l,u)=>{let d=o[l];if(d){let p=u.map(D=>D.presence_ref),f=d.map(D=>D.presence_ref),w=u.filter(D=>f.indexOf(D.presence_ref)<0),v=d.filter(D=>p.indexOf(D.presence_ref)<0);w.length>0&&(a[l]=w),v.length>0&&(c[l]=v)}else a[l]=u}),this.syncDiff(o,{joins:a,leaves:c},r,i)}static syncDiff(n,t,r,i){let{joins:o,leaves:s}={joins:this.transformState(t.joins),leaves:this.transformState(t.leaves)};return r||(r=()=>{}),i||(i=()=>{}),this.map(o,(a,c)=>{var l;let u=(l=n[a])!==null&&l!==void 0?l:[];if(n[a]=this.cloneDeep(c),u.length>0){let d=n[a].map(f=>f.presence_ref),p=u.filter(f=>d.indexOf(f.presence_ref)<0);n[a].unshift(...p)}r(a,u,c)}),this.map(s,(a,c)=>{let l=n[a];if(!l)return;let u=c.map(d=>d.presence_ref);l=l.filter(d=>u.indexOf(d.presence_ref)<0),n[a]=l,i(a,l,c),l.length===0&&delete n[a]}),n}static map(n,t){return Object.getOwnPropertyNames(n).map(r=>t(r,n[r]))}static transformState(n){return n=this.cloneDeep(n),Object.getOwnPropertyNames(n).reduce((t,r)=>{let i=n[r];return"metas"in i?t[r]=i.metas.map(o=>(o.presence_ref=o.phx_ref,delete o.phx_ref,delete o.phx_ref_prev,o)):t[r]=i,t},{})}static cloneDeep(n){return JSON.parse(JSON.stringify(n))}onJoin(n){this.caller.onJoin=n}onLeave(n){this.caller.onLeave=n}onSync(n){this.caller.onSync=n}inPendingSyncState(){return!this.joinRef||this.joinRef!==this.channel._joinRef()}};var io=class e{constructor(n,t={config:{}},r){this.topic=n,this.params=t,this.socket=r,this.bindings={},this.state=Be.closed,this.joinedOnce=!1,this.pushBuffer=[],this.subTopic=n.replace(/^realtime:/i,""),this.params.config=Object.assign({broadcast:{ack:!1,self:!1},presence:{key:""},private:!1},t.config),this.timeout=this.socket.timeout,this.joinPush=new $r(this,Ye.join,this.params,this.timeout),this.rejoinTimer=new Vr(()=>this._rejoinUntilConnected(),this.socket.reconnectAfterMs),this.joinPush.receive("ok",()=>{this.state=Be.joined,this.rejoinTimer.reset(),this.pushBuffer.forEach(i=>i.send()),this.pushBuffer=[]}),this._onClose(()=>{this.rejoinTimer.reset(),this.socket.log("channel",`close ${this.topic} ${this._joinRef()}`),this.state=Be.closed,this.socket._remove(this)}),this._onError(i=>{this._isLeaving()||this._isClosed()||(this.socket.log("channel",`error ${this.topic}`,i),this.state=Be.errored,this.rejoinTimer.scheduleTimeout())}),this.joinPush.receive("timeout",()=>{this._isJoining()&&(this.socket.log("channel",`timeout ${this.topic}`,this.joinPush.timeout),this.state=Be.errored,this.rejoinTimer.scheduleTimeout())}),this._on(Ye.reply,{},(i,o)=>{this._trigger(this._replyEventName(o),i)}),this.presence=new ro(this),this.broadcastEndpointURL=Pa(this.socket.endPoint)+"/api/broadcast",this.private=this.params.config.private||!1}subscribe(n,t=this.timeout){var r,i;if(this.socket.isConnected()||this.socket.connect(),this.joinedOnce)throw"tried to subscribe multiple times. 'subscribe' can only be called a single time per channel instance";{let{config:{broadcast:o,presence:s,private:a}}=this.params;this._onError(u=>n&&n("CHANNEL_ERROR",u)),this._onClose(()=>n&&n("CLOSED"));let c={},l={broadcast:o,presence:s,postgres_changes:(i=(r=this.bindings.postgres_changes)===null||r===void 0?void 0:r.map(u=>u.filter))!==null&&i!==void 0?i:[],private:a};this.socket.accessToken&&(c.access_token=this.socket.accessToken),this.updateJoinPayload(Object.assign({config:l},c)),this.joinedOnce=!0,this._rejoin(t),this.joinPush.receive("ok",({postgres_changes:u})=>{var d;if(this.socket.accessToken&&this.socket.setAuth(this.socket.accessToken),u===void 0){n&&n("SUBSCRIBED");return}else{let p=this.bindings.postgres_changes,f=(d=p?.length)!==null&&d!==void 0?d:0,w=[];for(let v=0;v{n&&n("CHANNEL_ERROR",new Error(JSON.stringify(Object.values(u).join(", ")||"error")))}).receive("timeout",()=>{n&&n("TIMED_OUT")})}return this}presenceState(){return this.presence.state}track(r){return h(this,arguments,function*(n,t={}){return yield this.send({type:"presence",event:"track",payload:n},t.timeout||this.timeout)})}untrack(){return h(this,arguments,function*(n={}){return yield this.send({type:"presence",event:"untrack"},n)})}on(n,t,r){return this._on(n,t,r)}send(r){return h(this,arguments,function*(n,t={}){var i,o;if(!this._canPush()&&n.type==="broadcast"){let{event:s,payload:a}=n,c={method:"POST",headers:{Authorization:this.socket.accessToken?`Bearer ${this.socket.accessToken}`:"",apikey:this.socket.apiKey?this.socket.apiKey:"","Content-Type":"application/json"},body:JSON.stringify({messages:[{topic:this.subTopic,event:s,payload:a,private:this.private}]})};try{let l=yield this._fetchWithTimeout(this.broadcastEndpointURL,c,(i=t.timeout)!==null&&i!==void 0?i:this.timeout);return yield(o=l.body)===null||o===void 0?void 0:o.cancel(),l.ok?"ok":"error"}catch(l){return l.name==="AbortError"?"timed out":"error"}}else return new Promise(s=>{var a,c,l;let u=this._push(n.type,n,t.timeout||this.timeout);n.type==="broadcast"&&!(!((l=(c=(a=this.params)===null||a===void 0?void 0:a.config)===null||c===void 0?void 0:c.broadcast)===null||l===void 0)&&l.ack)&&s("ok"),u.receive("ok",()=>s("ok")),u.receive("error",()=>s("error")),u.receive("timeout",()=>s("timed out"))})})}updateJoinPayload(n){this.joinPush.updatePayload(n)}unsubscribe(n=this.timeout){this.state=Be.leaving;let t=()=>{this.socket.log("channel",`leave ${this.topic}`),this._trigger(Ye.close,"leave",this._joinRef())};return this.rejoinTimer.reset(),this.joinPush.destroy(),new Promise(r=>{let i=new $r(this,Ye.leave,{},n);i.receive("ok",()=>{t(),r("ok")}).receive("timeout",()=>{t(),r("timed out")}).receive("error",()=>{r("error")}),i.send(),this._canPush()||i.trigger("ok",{})})}_fetchWithTimeout(n,t,r){return h(this,null,function*(){let i=new AbortController,o=setTimeout(()=>i.abort(),r),s=yield this.socket.fetch(n,Object.assign(Object.assign({},t),{signal:i.signal}));return clearTimeout(o),s})}_push(n,t,r=this.timeout){if(!this.joinedOnce)throw`tried to push '${n}' to '${this.topic}' before joining. Use channel.subscribe() before pushing events`;let i=new $r(this,n,t,r);return this._canPush()?i.send():(i.startTimeout(),this.pushBuffer.push(i)),i}_onMessage(n,t,r){return t}_isMember(n){return this.topic===n}_joinRef(){return this.joinPush.ref}_trigger(n,t,r){var i,o;let s=n.toLocaleLowerCase(),{close:a,error:c,leave:l,join:u}=Ye;if(r&&[a,c,l,u].indexOf(s)>=0&&r!==this._joinRef())return;let p=this._onMessage(s,t,r);if(t&&!p)throw"channel onMessage callbacks must return the payload, modified or unmodified";["insert","update","delete"].includes(s)?(i=this.bindings.postgres_changes)===null||i===void 0||i.filter(f=>{var w,v,D;return((w=f.filter)===null||w===void 0?void 0:w.event)==="*"||((D=(v=f.filter)===null||v===void 0?void 0:v.event)===null||D===void 0?void 0:D.toLocaleLowerCase())===s}).map(f=>f.callback(p,r)):(o=this.bindings[s])===null||o===void 0||o.filter(f=>{var w,v,D,C,ie,P;if(["broadcast","presence","postgres_changes"].includes(s))if("id"in f){let J=f.id,ee=(w=f.filter)===null||w===void 0?void 0:w.event;return J&&((v=t.ids)===null||v===void 0?void 0:v.includes(J))&&(ee==="*"||ee?.toLocaleLowerCase()===((D=t.data)===null||D===void 0?void 0:D.type.toLocaleLowerCase()))}else{let J=(ie=(C=f?.filter)===null||C===void 0?void 0:C.event)===null||ie===void 0?void 0:ie.toLocaleLowerCase();return J==="*"||J===((P=t?.event)===null||P===void 0?void 0:P.toLocaleLowerCase())}else return f.type.toLocaleLowerCase()===s}).map(f=>{if(typeof p=="object"&&"ids"in p){let w=p.data,{schema:v,table:D,commit_timestamp:C,type:ie,errors:P}=w;p=Object.assign(Object.assign({},{schema:v,table:D,commit_timestamp:C,eventType:ie,new:{},old:{},errors:P}),this._getPayloadRecords(w))}f.callback(p,r)})}_isClosed(){return this.state===Be.closed}_isJoined(){return this.state===Be.joined}_isJoining(){return this.state===Be.joining}_isLeaving(){return this.state===Be.leaving}_replyEventName(n){return`chan_reply_${n}`}_on(n,t,r){let i=n.toLocaleLowerCase(),o={type:i,filter:t,callback:r};return this.bindings[i]?this.bindings[i].push(o):this.bindings[i]=[o],this}_off(n,t){let r=n.toLocaleLowerCase();return this.bindings[r]=this.bindings[r].filter(i=>{var o;return!(((o=i.type)===null||o===void 0?void 0:o.toLocaleLowerCase())===r&&e.isEqual(i.filter,t))}),this}static isEqual(n,t){if(Object.keys(n).length!==Object.keys(t).length)return!1;for(let r in n)if(n[r]!==t[r])return!1;return!0}_rejoinUntilConnected(){this.rejoinTimer.scheduleTimeout(),this.socket.isConnected()&&this._rejoin()}_onClose(n){this._on(Ye.close,{},n)}_onError(n){this._on(Ye.error,{},t=>n(t))}_canPush(){return this.socket.isConnected()&&this._isJoined()}_rejoin(n=this.timeout){this._isLeaving()||(this.socket._leaveOpenTopic(this.topic),this.state=Be.joining,this.joinPush.resend(n))}_getPayloadRecords(n){let t={new:{},old:{}};return(n.type==="INSERT"||n.type==="UPDATE")&&(t.new=Pd(n.columns,n.record)),(n.type==="UPDATE"||n.type==="DELETE")&&(t.old=Pd(n.columns,n.old_record)),t}};var NM=()=>{},RM=typeof WebSocket<"u",PM=` - addEventListener("message", (e) => { - if (e.data.event === "start") { - setInterval(() => postMessage({ event: "keepAlive" }), e.data.interval); - } - });`,oo=class{constructor(n,t){var r;this.accessToken=null,this.apiKey=null,this.channels=[],this.endPoint="",this.httpEndpoint="",this.headers=Cv,this.params={},this.timeout=Na,this.heartbeatIntervalMs=3e4,this.heartbeatTimer=void 0,this.pendingHeartbeatRef=null,this.ref=0,this.logger=NM,this.conn=null,this.sendBuffer=[],this.serializer=new Ra,this.stateChangeCallbacks={open:[],close:[],error:[],message:[]},this._resolveFetch=o=>{let s;return o?s=o:typeof fetch>"u"?s=(...a)=>import("./chunk-6ISG364Z.js").then(({default:c})=>c(...a)):s=fetch,(...a)=>s(...a)},this.endPoint=`${n}/${Nd.websocket}`,this.httpEndpoint=Pa(n),t?.transport?this.transport=t.transport:this.transport=null,t?.params&&(this.params=t.params),t?.headers&&(this.headers=Object.assign(Object.assign({},this.headers),t.headers)),t?.timeout&&(this.timeout=t.timeout),t?.logger&&(this.logger=t.logger),t?.heartbeatIntervalMs&&(this.heartbeatIntervalMs=t.heartbeatIntervalMs);let i=(r=t?.params)===null||r===void 0?void 0:r.apikey;if(i&&(this.accessToken=i,this.apiKey=i),this.reconnectAfterMs=t?.reconnectAfterMs?t.reconnectAfterMs:o=>[1e3,2e3,5e3,1e4][o-1]||1e4,this.encode=t?.encode?t.encode:(o,s)=>s(JSON.stringify(o)),this.decode=t?.decode?t.decode:this.serializer.decode.bind(this.serializer),this.reconnectTimer=new Vr(()=>h(this,null,function*(){this.disconnect(),this.connect()}),this.reconnectAfterMs),this.fetch=this._resolveFetch(t?.fetch),t?.worker){if(typeof window<"u"&&!window.Worker)throw new Error("Web Worker is not supported");this.worker=t?.worker||!1,this.workerUrl=t?.workerUrl}}connect(){if(!this.conn){if(this.transport){this.conn=new this.transport(this._endPointURL(),void 0,{headers:this.headers});return}if(RM){this.conn=new WebSocket(this._endPointURL()),this.setupConnection();return}this.conn=new kd(this._endPointURL(),void 0,{close:()=>{this.conn=null}}),import("./chunk-FJRMAC5Z.js").then(({default:n})=>{this.conn=new n(this._endPointURL(),void 0,{headers:this.headers}),this.setupConnection()})}}disconnect(n,t){this.conn&&(this.conn.onclose=function(){},n?this.conn.close(n,t??""):this.conn.close(),this.conn=null,this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.reconnectTimer.reset())}getChannels(){return this.channels}removeChannel(n){return h(this,null,function*(){let t=yield n.unsubscribe();return this.channels.length===0&&this.disconnect(),t})}removeAllChannels(){return h(this,null,function*(){let n=yield Promise.all(this.channels.map(t=>t.unsubscribe()));return this.disconnect(),n})}log(n,t,r){this.logger(n,t,r)}connectionState(){switch(this.conn&&this.conn.readyState){case jr.connecting:return An.Connecting;case jr.open:return An.Open;case jr.closing:return An.Closing;default:return An.Closed}}isConnected(){return this.connectionState()===An.Open}channel(n,t={config:{}}){let r=new io(`realtime:${n}`,t,this);return this.channels.push(r),r}push(n){let{topic:t,event:r,payload:i,ref:o}=n,s=()=>{this.encode(n,a=>{var c;(c=this.conn)===null||c===void 0||c.send(a)})};this.log("push",`${t} ${r} (${o})`,i),this.isConnected()?s():this.sendBuffer.push(s)}setAuth(n){this.accessToken=n,this.channels.forEach(t=>{n&&t.updateJoinPayload({access_token:n}),t.joinedOnce&&t._isJoined()&&t._push(Ye.access_token,{access_token:n})})}_makeRef(){let n=this.ref+1;return n===this.ref?this.ref=0:this.ref=n,this.ref.toString()}_leaveOpenTopic(n){let t=this.channels.find(r=>r.topic===n&&(r._isJoined()||r._isJoining()));t&&(this.log("transport",`leaving duplicate topic "${n}"`),t.unsubscribe())}_remove(n){this.channels=this.channels.filter(t=>t._joinRef()!==n._joinRef())}setupConnection(){this.conn&&(this.conn.binaryType="arraybuffer",this.conn.onopen=()=>this._onConnOpen(),this.conn.onerror=n=>this._onConnError(n),this.conn.onmessage=n=>this._onConnMessage(n),this.conn.onclose=n=>this._onConnClose(n))}_endPointURL(){return this._appendParams(this.endPoint,Object.assign({},this.params,{vsn:Ev}))}_onConnMessage(n){this.decode(n.data,t=>{let{topic:r,event:i,payload:o,ref:s}=t;(s&&s===this.pendingHeartbeatRef||i===o?.type)&&(this.pendingHeartbeatRef=null),this.log("receive",`${o.status||""} ${r} ${i} ${s&&"("+s+")"||""}`,o),this.channels.filter(a=>a._isMember(r)).forEach(a=>a._trigger(i,o,s)),this.stateChangeCallbacks.message.forEach(a=>a(t))})}_onConnOpen(){return h(this,null,function*(){if(this.log("transport",`connected to ${this._endPointURL()}`),this._flushSendBuffer(),this.reconnectTimer.reset(),!this.worker)this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.heartbeatTimer=setInterval(()=>this._sendHeartbeat(),this.heartbeatIntervalMs);else{this.workerUrl?this.log("worker",`starting worker for from ${this.workerUrl}`):this.log("worker","starting default worker");let n=this._workerObjectUrl(this.workerUrl);this.workerRef=new Worker(n),this.workerRef.onerror=t=>{this.log("worker","worker error",t.message),this.workerRef.terminate()},this.workerRef.onmessage=t=>{t.data.event==="keepAlive"&&this._sendHeartbeat()},this.workerRef.postMessage({event:"start",interval:this.heartbeatIntervalMs})}this.stateChangeCallbacks.open.forEach(n=>n())})}_onConnClose(n){this.log("transport","close",n),this._triggerChanError(),this.heartbeatTimer&&clearInterval(this.heartbeatTimer),this.reconnectTimer.scheduleTimeout(),this.stateChangeCallbacks.close.forEach(t=>t(n))}_onConnError(n){this.log("transport",n.message),this._triggerChanError(),this.stateChangeCallbacks.error.forEach(t=>t(n))}_triggerChanError(){this.channels.forEach(n=>n._trigger(Ye.error))}_appendParams(n,t){if(Object.keys(t).length===0)return n;let r=n.match(/\?/)?"&":"?",i=new URLSearchParams(t);return`${n}${r}${i}`}_flushSendBuffer(){this.isConnected()&&this.sendBuffer.length>0&&(this.sendBuffer.forEach(n=>n()),this.sendBuffer=[])}_sendHeartbeat(){var n;if(this.isConnected()){if(this.pendingHeartbeatRef){this.pendingHeartbeatRef=null,this.log("transport","heartbeat timeout. Attempting to re-establish connection"),(n=this.conn)===null||n===void 0||n.close(Iv,"hearbeat timeout");return}this.pendingHeartbeatRef=this._makeRef(),this.push({topic:"phoenix",event:"heartbeat",payload:{},ref:this.pendingHeartbeatRef}),this.setAuth(this.accessToken)}}_workerObjectUrl(n){let t;if(n)t=n;else{let r=new Blob([PM],{type:"application/javascript"});t=URL.createObjectURL(r)}return t}};var kd=class{constructor(n,t,r){this.binaryType="arraybuffer",this.onclose=()=>{},this.onerror=()=>{},this.onmessage=()=>{},this.onopen=()=>{},this.readyState=jr.connecting,this.send=()=>{},this.url=null,this.url=n,this.close=r.close}};var Ur=class extends Error{constructor(n){super(n),this.__isStorageError=!0,this.name="StorageError"}};function ce(e){return typeof e=="object"&&e!==null&&"__isStorageError"in e}var ka=class extends Ur{constructor(n,t){super(n),this.name="StorageApiError",this.status=t}toJSON(){return{name:this.name,message:this.message,status:this.status}}},On=class extends Ur{constructor(n,t){super(n),this.name="StorageUnknownError",this.originalError=t}};var kM=function(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},La=e=>{let n;return e?n=e:typeof fetch>"u"?n=(...t)=>import("./chunk-6ISG364Z.js").then(({default:r})=>r(...t)):n=fetch,(...t)=>n(...t)},Sv=()=>kM(void 0,void 0,void 0,function*(){return typeof Response>"u"?(yield import("./chunk-6ISG364Z.js")).Response:Response}),Fa=e=>{if(Array.isArray(e))return e.map(t=>Fa(t));if(typeof e=="function"||e!==Object(e))return e;let n={};return Object.entries(e).forEach(([t,r])=>{let i=t.replace(/([-_][a-z])/gi,o=>o.toUpperCase().replace(/[-_]/g,""));n[i]=Fa(r)}),n};var Nn=function(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},Fd=e=>e.msg||e.message||e.error_description||e.error||JSON.stringify(e),FM=(e,n,t)=>Nn(void 0,void 0,void 0,function*(){let r=yield Sv();e instanceof r&&!t?.noResolveJson?e.json().then(i=>{n(new ka(Fd(i),e.status||500))}).catch(i=>{n(new On(Fd(i),i))}):n(new On(Fd(e),e))}),LM=(e,n,t,r)=>{let i={method:e,headers:n?.headers||{}};return e==="GET"?i:(i.headers=Object.assign({"Content-Type":"application/json"},n?.headers),r&&(i.body=JSON.stringify(r)),Object.assign(Object.assign({},i),t))};function so(e,n,t,r,i,o){return Nn(this,void 0,void 0,function*(){return new Promise((s,a)=>{e(t,LM(n,r,i,o)).then(c=>{if(!c.ok)throw c;return r?.noResolveJson?c:c.json()}).then(c=>s(c)).catch(c=>FM(c,a,r))})})}function Br(e,n,t,r){return Nn(this,void 0,void 0,function*(){return so(e,"GET",n,t,r)})}function mt(e,n,t,r,i){return Nn(this,void 0,void 0,function*(){return so(e,"POST",n,r,i,t)})}function xv(e,n,t,r,i){return Nn(this,void 0,void 0,function*(){return so(e,"PUT",n,r,i,t)})}function Tv(e,n,t,r){return Nn(this,void 0,void 0,function*(){return so(e,"HEAD",n,Object.assign(Object.assign({},t),{noResolveJson:!0}),r)})}function ja(e,n,t,r,i){return Nn(this,void 0,void 0,function*(){return so(e,"DELETE",n,r,i,t)})}var Ne=function(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},jM={limit:100,offset:0,sortBy:{column:"name",order:"asc"}},Av={cacheControl:"3600",contentType:"text/plain;charset=UTF-8",upsert:!1},Va=class{constructor(n,t={},r,i){this.url=n,this.headers=t,this.bucketId=r,this.fetch=La(i)}uploadOrUpdate(n,t,r,i){return Ne(this,void 0,void 0,function*(){try{let o,s=Object.assign(Object.assign({},Av),i),a=Object.assign(Object.assign({},this.headers),n==="POST"&&{"x-upsert":String(s.upsert)}),c=s.metadata;typeof Blob<"u"&&r instanceof Blob?(o=new FormData,o.append("cacheControl",s.cacheControl),c&&o.append("metadata",this.encodeMetadata(c)),o.append("",r)):typeof FormData<"u"&&r instanceof FormData?(o=r,o.append("cacheControl",s.cacheControl),c&&o.append("metadata",this.encodeMetadata(c))):(o=r,a["cache-control"]=`max-age=${s.cacheControl}`,a["content-type"]=s.contentType,c&&(a["x-metadata"]=this.toBase64(this.encodeMetadata(c)))),i?.headers&&(a=Object.assign(Object.assign({},a),i.headers));let l=this._removeEmptyFolders(t),u=this._getFinalPath(l),d=yield this.fetch(`${this.url}/object/${u}`,Object.assign({method:n,body:o,headers:a},s?.duplex?{duplex:s.duplex}:{})),p=yield d.json();return d.ok?{data:{path:l,id:p.Id,fullPath:p.Key},error:null}:{data:null,error:p}}catch(o){if(ce(o))return{data:null,error:o};throw o}})}upload(n,t,r){return Ne(this,void 0,void 0,function*(){return this.uploadOrUpdate("POST",n,t,r)})}uploadToSignedUrl(n,t,r,i){return Ne(this,void 0,void 0,function*(){let o=this._removeEmptyFolders(n),s=this._getFinalPath(o),a=new URL(this.url+`/object/upload/sign/${s}`);a.searchParams.set("token",t);try{let c,l=Object.assign({upsert:Av.upsert},i),u=Object.assign(Object.assign({},this.headers),{"x-upsert":String(l.upsert)});typeof Blob<"u"&&r instanceof Blob?(c=new FormData,c.append("cacheControl",l.cacheControl),c.append("",r)):typeof FormData<"u"&&r instanceof FormData?(c=r,c.append("cacheControl",l.cacheControl)):(c=r,u["cache-control"]=`max-age=${l.cacheControl}`,u["content-type"]=l.contentType);let d=yield this.fetch(a.toString(),{method:"PUT",body:c,headers:u}),p=yield d.json();return d.ok?{data:{path:o,fullPath:p.Key},error:null}:{data:null,error:p}}catch(c){if(ce(c))return{data:null,error:c};throw c}})}createSignedUploadUrl(n,t){return Ne(this,void 0,void 0,function*(){try{let r=this._getFinalPath(n),i=Object.assign({},this.headers);t?.upsert&&(i["x-upsert"]="true");let o=yield mt(this.fetch,`${this.url}/object/upload/sign/${r}`,{},{headers:i}),s=new URL(this.url+o.url),a=s.searchParams.get("token");if(!a)throw new Ur("No token returned by API");return{data:{signedUrl:s.toString(),path:n,token:a},error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}})}update(n,t,r){return Ne(this,void 0,void 0,function*(){return this.uploadOrUpdate("PUT",n,t,r)})}move(n,t,r){return Ne(this,void 0,void 0,function*(){try{return{data:yield mt(this.fetch,`${this.url}/object/move`,{bucketId:this.bucketId,sourceKey:n,destinationKey:t,destinationBucket:r?.destinationBucket},{headers:this.headers}),error:null}}catch(i){if(ce(i))return{data:null,error:i};throw i}})}copy(n,t,r){return Ne(this,void 0,void 0,function*(){try{return{data:{path:(yield mt(this.fetch,`${this.url}/object/copy`,{bucketId:this.bucketId,sourceKey:n,destinationKey:t,destinationBucket:r?.destinationBucket},{headers:this.headers})).Key},error:null}}catch(i){if(ce(i))return{data:null,error:i};throw i}})}createSignedUrl(n,t,r){return Ne(this,void 0,void 0,function*(){try{let i=this._getFinalPath(n),o=yield mt(this.fetch,`${this.url}/object/sign/${i}`,Object.assign({expiresIn:t},r?.transform?{transform:r.transform}:{}),{headers:this.headers}),s=r?.download?`&download=${r.download===!0?"":r.download}`:"";return o={signedUrl:encodeURI(`${this.url}${o.signedURL}${s}`)},{data:o,error:null}}catch(i){if(ce(i))return{data:null,error:i};throw i}})}createSignedUrls(n,t,r){return Ne(this,void 0,void 0,function*(){try{let i=yield mt(this.fetch,`${this.url}/object/sign/${this.bucketId}`,{expiresIn:t,paths:n},{headers:this.headers}),o=r?.download?`&download=${r.download===!0?"":r.download}`:"";return{data:i.map(s=>Object.assign(Object.assign({},s),{signedUrl:s.signedURL?encodeURI(`${this.url}${s.signedURL}${o}`):null})),error:null}}catch(i){if(ce(i))return{data:null,error:i};throw i}})}download(n,t){return Ne(this,void 0,void 0,function*(){let i=typeof t?.transform<"u"?"render/image/authenticated":"object",o=this.transformOptsToQueryString(t?.transform||{}),s=o?`?${o}`:"";try{let a=this._getFinalPath(n);return{data:yield(yield Br(this.fetch,`${this.url}/${i}/${a}${s}`,{headers:this.headers,noResolveJson:!0})).blob(),error:null}}catch(a){if(ce(a))return{data:null,error:a};throw a}})}info(n){return Ne(this,void 0,void 0,function*(){let t=this._getFinalPath(n);try{let r=yield Br(this.fetch,`${this.url}/object/info/${t}`,{headers:this.headers});return{data:Fa(r),error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}})}exists(n){return Ne(this,void 0,void 0,function*(){let t=this._getFinalPath(n);try{return yield Tv(this.fetch,`${this.url}/object/${t}`,{headers:this.headers}),{data:!0,error:null}}catch(r){if(ce(r)&&r instanceof On){let i=r.originalError;if([400,404].includes(i?.status))return{data:!1,error:r}}throw r}})}getPublicUrl(n,t){let r=this._getFinalPath(n),i=[],o=t?.download?`download=${t.download===!0?"":t.download}`:"";o!==""&&i.push(o);let a=typeof t?.transform<"u"?"render/image":"object",c=this.transformOptsToQueryString(t?.transform||{});c!==""&&i.push(c);let l=i.join("&");return l!==""&&(l=`?${l}`),{data:{publicUrl:encodeURI(`${this.url}/${a}/public/${r}${l}`)}}}remove(n){return Ne(this,void 0,void 0,function*(){try{return{data:yield ja(this.fetch,`${this.url}/object/${this.bucketId}`,{prefixes:n},{headers:this.headers}),error:null}}catch(t){if(ce(t))return{data:null,error:t};throw t}})}list(n,t,r){return Ne(this,void 0,void 0,function*(){try{let i=Object.assign(Object.assign(Object.assign({},jM),t),{prefix:n||""});return{data:yield mt(this.fetch,`${this.url}/object/list/${this.bucketId}`,i,{headers:this.headers},r),error:null}}catch(i){if(ce(i))return{data:null,error:i};throw i}})}encodeMetadata(n){return JSON.stringify(n)}toBase64(n){return typeof Buffer<"u"?Buffer.from(n).toString("base64"):btoa(n)}_getFinalPath(n){return`${this.bucketId}/${n}`}_removeEmptyFolders(n){return n.replace(/^\/|\/$/g,"").replace(/\/+/g,"/")}transformOptsToQueryString(n){let t=[];return n.width&&t.push(`width=${n.width}`),n.height&&t.push(`height=${n.height}`),n.resize&&t.push(`resize=${n.resize}`),n.format&&t.push(`format=${n.format}`),n.quality&&t.push(`quality=${n.quality}`),t.join("&")}};var Ov="2.7.1";var Nv={"X-Client-Info":`storage-js/${Ov}`};var Hr=function(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},$a=class{constructor(n,t={},r){this.url=n,this.headers=Object.assign(Object.assign({},Nv),t),this.fetch=La(r)}listBuckets(){return Hr(this,void 0,void 0,function*(){try{return{data:yield Br(this.fetch,`${this.url}/bucket`,{headers:this.headers}),error:null}}catch(n){if(ce(n))return{data:null,error:n};throw n}})}getBucket(n){return Hr(this,void 0,void 0,function*(){try{return{data:yield Br(this.fetch,`${this.url}/bucket/${n}`,{headers:this.headers}),error:null}}catch(t){if(ce(t))return{data:null,error:t};throw t}})}createBucket(n,t={public:!1}){return Hr(this,void 0,void 0,function*(){try{return{data:yield mt(this.fetch,`${this.url}/bucket`,{id:n,name:n,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}})}updateBucket(n,t){return Hr(this,void 0,void 0,function*(){try{return{data:yield xv(this.fetch,`${this.url}/bucket/${n}`,{id:n,name:n,public:t.public,file_size_limit:t.fileSizeLimit,allowed_mime_types:t.allowedMimeTypes},{headers:this.headers}),error:null}}catch(r){if(ce(r))return{data:null,error:r};throw r}})}emptyBucket(n){return Hr(this,void 0,void 0,function*(){try{return{data:yield mt(this.fetch,`${this.url}/bucket/${n}/empty`,{},{headers:this.headers}),error:null}}catch(t){if(ce(t))return{data:null,error:t};throw t}})}deleteBucket(n){return Hr(this,void 0,void 0,function*(){try{return{data:yield ja(this.fetch,`${this.url}/bucket/${n}`,{},{headers:this.headers}),error:null}}catch(t){if(ce(t))return{data:null,error:t};throw t}})}};var ao=class extends $a{constructor(n,t={},r){super(n,t,r)}from(n){return new Va(this.url,this.headers,n,this.fetch)}};var Rv="2.46.1";var co="";typeof Deno<"u"?co="deno":typeof document<"u"?co="web":typeof navigator<"u"&&navigator.product==="ReactNative"?co="react-native":co="node";var VM={"X-Client-Info":`supabase-js-${co}/${Rv}`},Pv={headers:VM},kv={schema:"public"},Fv={autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,flowType:"implicit"},Lv={};Yd();var $M=function(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},UM=e=>{let n;return e?n=e:typeof fetch>"u"?n=Wd:n=fetch,(...t)=>n(...t)},BM=()=>typeof Headers>"u"?Zd:Headers,jv=(e,n,t)=>{let r=UM(t),i=BM();return(o,s)=>$M(void 0,void 0,void 0,function*(){var a;let c=(a=yield n())!==null&&a!==void 0?a:e,l=new i(s?.headers);return l.has("apikey")||l.set("apikey",e),l.has("Authorization")||l.set("Authorization",`Bearer ${c}`),r(o,Object.assign(Object.assign({},s),{headers:l}))})};var HM=function(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})};function Vv(e){return e.replace(/\/$/,"")}function $v(e,n){let{db:t,auth:r,realtime:i,global:o}=e,{db:s,auth:a,realtime:c,global:l}=n,u={db:Object.assign(Object.assign({},s),t),auth:Object.assign(Object.assign({},a),r),realtime:Object.assign(Object.assign({},c),i),global:Object.assign(Object.assign({},l),o),accessToken:()=>HM(this,void 0,void 0,function*(){return""})};return e.accessToken?u.accessToken=e.accessToken:delete u.accessToken,u}function Uv(e){return Math.round(Date.now()/1e3)+e}function Bv(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(e){let n=Math.random()*16|0;return(e=="x"?n:n&3|8).toString(16)})}var ct=()=>typeof document<"u",Rn={tested:!1,writable:!1},Yt=()=>{if(!ct())return!1;try{if(typeof globalThis.localStorage!="object")return!1}catch{return!1}if(Rn.tested)return Rn.writable;let e=`lswt-${Math.random()}${Math.random()}`;try{globalThis.localStorage.setItem(e,e),globalThis.localStorage.removeItem(e),Rn.tested=!0,Rn.writable=!0}catch{Rn.tested=!0,Rn.writable=!1}return Rn.writable};function Ua(e){let n={},t=new URL(e);if(t.hash&&t.hash[0]==="#")try{new URLSearchParams(t.hash.substring(1)).forEach((i,o)=>{n[o]=i})}catch{}return t.searchParams.forEach((r,i)=>{n[i]=r}),n}var Ba=e=>{let n;return e?n=e:typeof fetch>"u"?n=(...t)=>import("./chunk-6ISG364Z.js").then(({default:r})=>r(...t)):n=fetch,(...t)=>n(...t)},Hv=e=>typeof e=="object"&&e!==null&&"status"in e&&"ok"in e&&"json"in e&&typeof e.json=="function",Qt=(e,n,t)=>h(void 0,null,function*(){yield e.setItem(n,JSON.stringify(t))}),uo=(e,n)=>h(void 0,null,function*(){let t=yield e.getItem(n);if(!t)return null;try{return JSON.parse(t)}catch{return t}}),Ha=(e,n)=>h(void 0,null,function*(){yield e.removeItem(n)});function zM(e){let n="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",t="",r,i,o,s,a,c,l,u=0;for(e=e.replace("-","+").replace("_","/");u>4,i=(a&15)<<4|c>>2,o=(c&3)<<6|l,t=t+String.fromCharCode(r),c!=64&&i!=0&&(t=t+String.fromCharCode(i)),l!=64&&o!=0&&(t=t+String.fromCharCode(o));return t}var lo=class e{constructor(){this.promise=new e.promiseConstructor((n,t)=>{this.resolve=n,this.reject=t})}};lo.promiseConstructor=Promise;function Ld(e){let n=/^([a-z0-9_-]{4})*($|[a-z0-9_-]{3}=?$|[a-z0-9_-]{2}(==)?$)$/i,t=e.split(".");if(t.length!==3)throw new Error("JWT is not valid: not a JWT structure");if(!n.test(t[1]))throw new Error("JWT is not valid: payload is not in base64url format");let r=t[1];return JSON.parse(zM(r))}function zv(e){return h(this,null,function*(){return yield new Promise(n=>{setTimeout(()=>n(null),e)})})}function Gv(e,n){return new Promise((r,i)=>{h(this,null,function*(){for(let o=0;o<1/0;o++)try{let s=yield e(o);if(!n(o,null,s)){r(s);return}}catch(s){if(!n(o,s)){i(s);return}}})})}function GM(e){return("0"+e.toString(16)).substr(-2)}function Pn(){let n=new Uint32Array(56);if(typeof crypto>"u"){let t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~",r=t.length,i="";for(let o=0;o<56;o++)i+=t.charAt(Math.floor(Math.random()*r));return i}return crypto.getRandomValues(n),Array.from(n,GM).join("")}function qM(e){return h(this,null,function*(){let t=new TextEncoder().encode(e),r=yield crypto.subtle.digest("SHA-256",t),i=new Uint8Array(r);return Array.from(i).map(o=>String.fromCharCode(o)).join("")})}function WM(e){return btoa(e).replace(/\+/g,"-").replace(/\//g,"_").replace(/=+$/,"")}function kn(e){return h(this,null,function*(){if(!(typeof crypto<"u"&&typeof crypto.subtle<"u"&&typeof TextEncoder<"u"))return console.warn("WebCrypto API is not supported. Code challenge method will default to use plain instead of sha256."),e;let t=yield qM(e);return WM(t)})}var fo=class extends Error{constructor(n,t){super(n),this.__isAuthError=!0,this.name="AuthError",this.status=t}};function j(e){return typeof e=="object"&&e!==null&&"__isAuthError"in e}var za=class extends fo{constructor(n,t){super(n,t),this.name="AuthApiError",this.status=t}toJSON(){return{name:this.name,message:this.message,status:this.status}}};function qv(e){return j(e)&&e.name==="AuthApiError"}var zr=class extends fo{constructor(n,t){super(n),this.name="AuthUnknownError",this.originalError=t}},Mt=class extends fo{constructor(n,t,r){super(n),this.name=t,this.status=r}toJSON(){return{name:this.name,message:this.message,status:this.status}}},St=class extends Mt{constructor(){super("Auth session missing!","AuthSessionMissingError",400)}},Gr=class extends Mt{constructor(){super("Auth session or user missing","AuthInvalidTokenResponseError",500)}},Fn=class extends Mt{constructor(n){super(n,"AuthInvalidCredentialsError",400)}},Ln=class extends Mt{constructor(n,t=null){super(n,"AuthImplicitGrantRedirectError",500),this.details=null,this.details=t}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}},ho=class extends Mt{constructor(n,t=null){super(n,"AuthPKCEGrantCodeExchangeError",500),this.details=null,this.details=t}toJSON(){return{name:this.name,message:this.message,status:this.status,details:this.details}}},qr=class extends Mt{constructor(n,t){super(n,"AuthRetryableFetchError",t)}};function qa(e){return j(e)&&e.name==="AuthRetryableFetchError"}var Ga=class extends Mt{constructor(n,t,r){super(n,"AuthWeakPasswordError",t),this.reasons=r}};var ZM=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);ie.msg||e.message||e.error_description||e.error||JSON.stringify(e),YM=[502,503,504];function Wv(e){return h(this,null,function*(){if(!Hv(e))throw new qr(Wr(e),0);if(YM.includes(e.status))throw new qr(Wr(e),e.status);let n;try{n=yield e.json()}catch(t){throw new zr(Wr(t),t)}throw typeof n=="object"&&n&&typeof n.weak_password=="object"&&n.weak_password&&Array.isArray(n.weak_password.reasons)&&n.weak_password.reasons.length&&n.weak_password.reasons.reduce((t,r)=>t&&typeof r=="string",!0)?new Ga(Wr(n),e.status,n.weak_password.reasons):new za(Wr(n),e.status||500)})}var QM=(e,n,t,r)=>{let i={method:e,headers:n?.headers||{}};return e==="GET"?i:(i.headers=Object.assign({"Content-Type":"application/json;charset=UTF-8"},n?.headers),i.body=JSON.stringify(r),Object.assign(Object.assign({},i),t))};function B(e,n,t,r){return h(this,null,function*(){var i;let o=Object.assign({},r?.headers);r?.jwt&&(o.Authorization=`Bearer ${r.jwt}`);let s=(i=r?.query)!==null&&i!==void 0?i:{};r?.redirectTo&&(s.redirect_to=r.redirectTo);let a=Object.keys(s).length?"?"+new URLSearchParams(s).toString():"",c=yield KM(e,n,t+a,{headers:o,noResolveJson:r?.noResolveJson},{},r?.body);return r?.xform?r?.xform(c):{data:Object.assign({},c),error:null}})}function KM(e,n,t,r,i,o){return h(this,null,function*(){let s=QM(n,r,i,o),a;try{a=yield e(t,s)}catch(c){throw console.error(c),new qr(Wr(c),0)}if(a.ok||(yield Wv(a)),r?.noResolveJson)return a;try{return yield a.json()}catch(c){yield Wv(c)}})}function Kt(e){var n;let t=null;JM(e)&&(t=Object.assign({},e),e.expires_at||(t.expires_at=Uv(e.expires_in)));let r=(n=e.user)!==null&&n!==void 0?n:e;return{data:{session:t,user:r},error:null}}function jd(e){let n=Kt(e);return!n.error&&e.weak_password&&typeof e.weak_password=="object"&&Array.isArray(e.weak_password.reasons)&&e.weak_password.reasons.length&&e.weak_password.message&&typeof e.weak_password.message=="string"&&e.weak_password.reasons.reduce((t,r)=>t&&typeof r=="string",!0)&&(n.data.weak_password=e.weak_password),n}function vt(e){var n;return{data:{user:(n=e.user)!==null&&n!==void 0?n:e},error:null}}function Zv(e){return{data:e,error:null}}function Yv(e){let{action_link:n,email_otp:t,hashed_token:r,redirect_to:i,verification_type:o}=e,s=ZM(e,["action_link","email_otp","hashed_token","redirect_to","verification_type"]),a={action_link:n,email_otp:t,hashed_token:r,redirect_to:i,verification_type:o},c=Object.assign({},s);return{data:{properties:a,user:c},error:null}}function Qv(e){return e}function JM(e){return e.access_token&&e.refresh_token&&e.expires_in}var XM=function(e,n){var t={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&n.indexOf(r)<0&&(t[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i0&&(f.forEach(w=>{let v=parseInt(w.split(";")[0].split("=")[1].substring(0,1)),D=JSON.parse(w.split(";")[1].split("=")[1]);l[`${D}Page`]=v}),l.total=parseInt(p)),{data:Object.assign(Object.assign({},d),l),error:null}}catch(l){if(j(l))return{data:{users:[]},error:l};throw l}})}getUserById(n){return h(this,null,function*(){try{return yield B(this.fetch,"GET",`${this.url}/admin/users/${n}`,{headers:this.headers,xform:vt})}catch(t){if(j(t))return{data:{user:null},error:t};throw t}})}updateUserById(n,t){return h(this,null,function*(){try{return yield B(this.fetch,"PUT",`${this.url}/admin/users/${n}`,{body:t,headers:this.headers,xform:vt})}catch(r){if(j(r))return{data:{user:null},error:r};throw r}})}deleteUser(n,t=!1){return h(this,null,function*(){try{return yield B(this.fetch,"DELETE",`${this.url}/admin/users/${n}`,{headers:this.headers,body:{should_soft_delete:t},xform:vt})}catch(r){if(j(r))return{data:{user:null},error:r};throw r}})}_listFactors(n){return h(this,null,function*(){try{let{data:t,error:r}=yield B(this.fetch,"GET",`${this.url}/admin/users/${n.userId}/factors`,{headers:this.headers,xform:i=>({data:{factors:i},error:null})});return{data:t,error:r}}catch(t){if(j(t))return{data:null,error:t};throw t}})}_deleteFactor(n){return h(this,null,function*(){try{return{data:yield B(this.fetch,"DELETE",`${this.url}/admin/users/${n.userId}/factors/${n.id}`,{headers:this.headers}),error:null}}catch(t){if(j(t))return{data:null,error:t};throw t}})}};var Wa="2.61.0";var Kv="http://localhost:9999",Jv="supabase.auth.token";var Xv={"X-Client-Info":`gotrue-js/${Wa}`},Vd=10;var ey={getItem:e=>Yt()?globalThis.localStorage.getItem(e):null,setItem:(e,n)=>{Yt()&&globalThis.localStorage.setItem(e,n)},removeItem:e=>{Yt()&&globalThis.localStorage.removeItem(e)}};function $d(e={}){return{getItem:n=>e[n]||null,setItem:(n,t)=>{e[n]=t},removeItem:n=>{delete e[n]}}}function ty(){if(typeof globalThis!="object")try{Object.defineProperty(Object.prototype,"__magic__",{get:function(){return this},configurable:!0}),__magic__.globalThis=__magic__,delete Object.prototype.__magic__}catch{typeof self<"u"&&(self.globalThis=self)}}var eS={debug:!!(globalThis&&Yt()&&globalThis.localStorage&&globalThis.localStorage.getItem("supabase.gotrue-js.locks.debug")==="true")},Za=class extends Error{constructor(n){super(n),this.isAcquireTimeout=!0}};ty();var tS={url:Kv,storageKey:Jv,autoRefreshToken:!0,persistSession:!0,detectSessionInUrl:!0,headers:Xv,flowType:"implicit",debug:!1},po=30*1e3,ny=3;function nS(e,n,t){return h(this,null,function*(){return yield t()})}var Ud=(()=>{class e{constructor(t){var r;this.memoryStorage=null,this.stateChangeEmitters=new Map,this.autoRefreshTicker=null,this.visibilityChangedCallback=null,this.refreshingDeferred=null,this.initializePromise=null,this.detectSessionInUrl=!0,this.lockAcquired=!1,this.pendingInLock=[],this.broadcastChannel=null,this.logger=console.log,this.instanceID=e.nextInstanceID,e.nextInstanceID+=1,this.instanceID>0&&ct()&&console.warn("Multiple GoTrueClient instances detected in the same browser context. It is not an error, but this should be avoided as it may produce undefined behavior when used concurrently under the same storage key.");let i=Object.assign(Object.assign({},tS),t);if(this.logDebugMessages=!!i.debug,typeof i.debug=="function"&&(this.logger=i.debug),this.persistSession=i.persistSession,this.storageKey=i.storageKey,this.autoRefreshToken=i.autoRefreshToken,this.admin=new Zr({url:i.url,headers:i.headers,fetch:i.fetch}),this.url=i.url,this.headers=i.headers,this.fetch=Ba(i.fetch),this.lock=i.lock||nS,this.detectSessionInUrl=i.detectSessionInUrl,this.flowType=i.flowType,this.mfa={verify:this._verify.bind(this),enroll:this._enroll.bind(this),unenroll:this._unenroll.bind(this),challenge:this._challenge.bind(this),listFactors:this._listFactors.bind(this),challengeAndVerify:this._challengeAndVerify.bind(this),getAuthenticatorAssuranceLevel:this._getAuthenticatorAssuranceLevel.bind(this)},this.persistSession?i.storage?this.storage=i.storage:Yt()?this.storage=ey:(this.memoryStorage={},this.storage=$d(this.memoryStorage)):(this.memoryStorage={},this.storage=$d(this.memoryStorage)),ct()&&globalThis.BroadcastChannel&&this.persistSession&&this.storageKey){try{this.broadcastChannel=new globalThis.BroadcastChannel(this.storageKey)}catch(o){console.error("Failed to create a new BroadcastChannel, multi-tab state changes will not be available",o)}(r=this.broadcastChannel)===null||r===void 0||r.addEventListener("message",o=>h(this,null,function*(){this._debug("received broadcast notification from other tab or client",o),yield this._notifyAllSubscribers(o.data.event,o.data.session,!1)}))}this.initialize()}_debug(...t){return this.logDebugMessages&&this.logger(`GoTrueClient@${this.instanceID} (${Wa}) ${new Date().toISOString()}`,...t),this}initialize(){return h(this,null,function*(){return this.initializePromise?yield this.initializePromise:(this.initializePromise=h(this,null,function*(){return yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._initialize()}))}),yield this.initializePromise)})}_initialize(){return h(this,null,function*(){try{let t=ct()?yield this._isPKCEFlow():!1;if(this._debug("#_initialize()","begin","is PKCE flow",t),t||this.detectSessionInUrl&&this._isImplicitGrantFlow()){let{data:r,error:i}=yield this._getSessionFromURL(t);if(i)return this._debug("#_initialize()","error detecting session from URL",i),i?.message==="Identity is already linked"||i?.message==="Identity is already linked to another user"?{error:i}:(yield this._removeSession(),{error:i});let{session:o,redirectType:s}=r;return this._debug("#_initialize()","detected session in URL",o,"redirect type",s),yield this._saveSession(o),setTimeout(()=>h(this,null,function*(){s==="recovery"?yield this._notifyAllSubscribers("PASSWORD_RECOVERY",o):yield this._notifyAllSubscribers("SIGNED_IN",o)}),0),{error:null}}return yield this._recoverAndRefresh(),{error:null}}catch(t){return j(t)?{error:t}:{error:new zr("Unexpected error during initialization",t)}}finally{yield this._handleVisibilityChange(),this._debug("#_initialize()","end")}})}signUp(t){return h(this,null,function*(){var r,i,o;try{yield this._removeSession();let s;if("email"in t){let{email:d,password:p,options:f}=t,w=null,v=null;if(this.flowType==="pkce"){let D=Pn();yield Qt(this.storage,`${this.storageKey}-code-verifier`,D),w=yield kn(D),v=D===w?"plain":"s256"}s=yield B(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,redirectTo:f?.emailRedirectTo,body:{email:d,password:p,data:(r=f?.data)!==null&&r!==void 0?r:{},gotrue_meta_security:{captcha_token:f?.captchaToken},code_challenge:w,code_challenge_method:v},xform:Kt})}else if("phone"in t){let{phone:d,password:p,options:f}=t;s=yield B(this.fetch,"POST",`${this.url}/signup`,{headers:this.headers,body:{phone:d,password:p,data:(i=f?.data)!==null&&i!==void 0?i:{},channel:(o=f?.channel)!==null&&o!==void 0?o:"sms",gotrue_meta_security:{captcha_token:f?.captchaToken}},xform:Kt})}else throw new Fn("You must provide either an email or phone number and a password");let{data:a,error:c}=s;if(c||!a)return{data:{user:null,session:null},error:c};let l=a.session,u=a.user;return a.session&&(yield this._saveSession(a.session),yield this._notifyAllSubscribers("SIGNED_IN",l)),{data:{user:u,session:l},error:null}}catch(s){if(j(s))return{data:{user:null,session:null},error:s};throw s}})}signInWithPassword(t){return h(this,null,function*(){try{yield this._removeSession();let r;if("email"in t){let{email:s,password:a,options:c}=t;r=yield B(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{email:s,password:a,gotrue_meta_security:{captcha_token:c?.captchaToken}},xform:jd})}else if("phone"in t){let{phone:s,password:a,options:c}=t;r=yield B(this.fetch,"POST",`${this.url}/token?grant_type=password`,{headers:this.headers,body:{phone:s,password:a,gotrue_meta_security:{captcha_token:c?.captchaToken}},xform:jd})}else throw new Fn("You must provide either an email or phone number and a password");let{data:i,error:o}=r;return o?{data:{user:null,session:null},error:o}:!i||!i.session||!i.user?{data:{user:null,session:null},error:new Gr}:(i.session&&(yield this._saveSession(i.session),yield this._notifyAllSubscribers("SIGNED_IN",i.session)),{data:Object.assign({user:i.user,session:i.session},i.weak_password?{weakPassword:i.weak_password}:null),error:o})}catch(r){if(j(r))return{data:{user:null,session:null},error:r};throw r}})}signInWithOAuth(t){return h(this,null,function*(){var r,i,o,s;return yield this._removeSession(),yield this._handleProviderSignIn(t.provider,{redirectTo:(r=t.options)===null||r===void 0?void 0:r.redirectTo,scopes:(i=t.options)===null||i===void 0?void 0:i.scopes,queryParams:(o=t.options)===null||o===void 0?void 0:o.queryParams,skipBrowserRedirect:(s=t.options)===null||s===void 0?void 0:s.skipBrowserRedirect})})}exchangeCodeForSession(t){return h(this,null,function*(){return yield this.initializePromise,this._acquireLock(-1,()=>h(this,null,function*(){return this._exchangeCodeForSession(t)}))})}_exchangeCodeForSession(t){return h(this,null,function*(){let r=yield uo(this.storage,`${this.storageKey}-code-verifier`),[i,o]=(r??"").split("/"),{data:s,error:a}=yield B(this.fetch,"POST",`${this.url}/token?grant_type=pkce`,{headers:this.headers,body:{auth_code:t,code_verifier:i},xform:Kt});return yield Ha(this.storage,`${this.storageKey}-code-verifier`),a?{data:{user:null,session:null,redirectType:null},error:a}:!s||!s.session||!s.user?{data:{user:null,session:null,redirectType:null},error:new Gr}:(s.session&&(yield this._saveSession(s.session),yield this._notifyAllSubscribers("SIGNED_IN",s.session)),{data:Object.assign(Object.assign({},s),{redirectType:o??null}),error:a})})}signInWithIdToken(t){return h(this,null,function*(){yield this._removeSession();try{let{options:r,provider:i,token:o,access_token:s,nonce:a}=t,c=yield B(this.fetch,"POST",`${this.url}/token?grant_type=id_token`,{headers:this.headers,body:{provider:i,id_token:o,access_token:s,nonce:a,gotrue_meta_security:{captcha_token:r?.captchaToken}},xform:Kt}),{data:l,error:u}=c;return u?{data:{user:null,session:null},error:u}:!l||!l.session||!l.user?{data:{user:null,session:null},error:new Gr}:(l.session&&(yield this._saveSession(l.session),yield this._notifyAllSubscribers("SIGNED_IN",l.session)),{data:l,error:u})}catch(r){if(j(r))return{data:{user:null,session:null},error:r};throw r}})}signInWithOtp(t){return h(this,null,function*(){var r,i,o,s,a;try{if(yield this._removeSession(),"email"in t){let{email:c,options:l}=t,u=null,d=null;if(this.flowType==="pkce"){let f=Pn();yield Qt(this.storage,`${this.storageKey}-code-verifier`,f),u=yield kn(f),d=f===u?"plain":"s256"}let{error:p}=yield B(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{email:c,data:(r=l?.data)!==null&&r!==void 0?r:{},create_user:(i=l?.shouldCreateUser)!==null&&i!==void 0?i:!0,gotrue_meta_security:{captcha_token:l?.captchaToken},code_challenge:u,code_challenge_method:d},redirectTo:l?.emailRedirectTo});return{data:{user:null,session:null},error:p}}if("phone"in t){let{phone:c,options:l}=t,{data:u,error:d}=yield B(this.fetch,"POST",`${this.url}/otp`,{headers:this.headers,body:{phone:c,data:(o=l?.data)!==null&&o!==void 0?o:{},create_user:(s=l?.shouldCreateUser)!==null&&s!==void 0?s:!0,gotrue_meta_security:{captcha_token:l?.captchaToken},channel:(a=l?.channel)!==null&&a!==void 0?a:"sms"}});return{data:{user:null,session:null,messageId:u?.message_id},error:d}}throw new Fn("You must provide either an email or phone number.")}catch(c){if(j(c))return{data:{user:null,session:null},error:c};throw c}})}verifyOtp(t){return h(this,null,function*(){var r,i;try{t.type!=="email_change"&&t.type!=="phone_change"&&(yield this._removeSession());let o,s;"options"in t&&(o=(r=t.options)===null||r===void 0?void 0:r.redirectTo,s=(i=t.options)===null||i===void 0?void 0:i.captchaToken);let{data:a,error:c}=yield B(this.fetch,"POST",`${this.url}/verify`,{headers:this.headers,body:Object.assign(Object.assign({},t),{gotrue_meta_security:{captcha_token:s}}),redirectTo:o,xform:Kt});if(c)throw c;if(!a)throw new Error("An error occurred on token verification.");let l=a.session,u=a.user;return l?.access_token&&(yield this._saveSession(l),yield this._notifyAllSubscribers("SIGNED_IN",l)),{data:{user:u,session:l},error:null}}catch(o){if(j(o))return{data:{user:null,session:null},error:o};throw o}})}signInWithSSO(t){return h(this,null,function*(){var r,i,o;try{yield this._removeSession();let s=null,a=null;if(this.flowType==="pkce"){let c=Pn();yield Qt(this.storage,`${this.storageKey}-code-verifier`,c),s=yield kn(c),a=c===s?"plain":"s256"}return yield B(this.fetch,"POST",`${this.url}/sso`,{body:Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({},"providerId"in t?{provider_id:t.providerId}:null),"domain"in t?{domain:t.domain}:null),{redirect_to:(i=(r=t.options)===null||r===void 0?void 0:r.redirectTo)!==null&&i!==void 0?i:void 0}),!((o=t?.options)===null||o===void 0)&&o.captchaToken?{gotrue_meta_security:{captcha_token:t.options.captchaToken}}:null),{skip_http_redirect:!0,code_challenge:s,code_challenge_method:a}),headers:this.headers,xform:Zv})}catch(s){if(j(s))return{data:null,error:s};throw s}})}reauthenticate(){return h(this,null,function*(){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._reauthenticate()}))})}_reauthenticate(){return h(this,null,function*(){try{return yield this._useSession(t=>h(this,null,function*(){let{data:{session:r},error:i}=t;if(i)throw i;if(!r)throw new St;let{error:o}=yield B(this.fetch,"GET",`${this.url}/reauthenticate`,{headers:this.headers,jwt:r.access_token});return{data:{user:null,session:null},error:o}}))}catch(t){if(j(t))return{data:{user:null,session:null},error:t};throw t}})}resend(t){return h(this,null,function*(){try{t.type!="email_change"&&t.type!="phone_change"&&(yield this._removeSession());let r=`${this.url}/resend`;if("email"in t){let{email:i,type:o,options:s}=t,{error:a}=yield B(this.fetch,"POST",r,{headers:this.headers,body:{email:i,type:o,gotrue_meta_security:{captcha_token:s?.captchaToken}},redirectTo:s?.emailRedirectTo});return{data:{user:null,session:null},error:a}}else if("phone"in t){let{phone:i,type:o,options:s}=t,{data:a,error:c}=yield B(this.fetch,"POST",r,{headers:this.headers,body:{phone:i,type:o,gotrue_meta_security:{captcha_token:s?.captchaToken}}});return{data:{user:null,session:null,messageId:a?.message_id},error:c}}throw new Fn("You must provide either an email or phone number and a type")}catch(r){if(j(r))return{data:{user:null,session:null},error:r};throw r}})}getSession(){return h(this,null,function*(){return yield this.initializePromise,this._acquireLock(-1,()=>h(this,null,function*(){return this._useSession(t=>h(this,null,function*(){return t}))}))})}_acquireLock(t,r){return h(this,null,function*(){this._debug("#_acquireLock","begin",t);try{if(this.lockAcquired){let i=this.pendingInLock.length?this.pendingInLock[this.pendingInLock.length-1]:Promise.resolve(),o=h(this,null,function*(){return yield i,yield r()});return this.pendingInLock.push(h(this,null,function*(){try{yield o}catch{}})),o}return yield this.lock(`lock:${this.storageKey}`,t,()=>h(this,null,function*(){this._debug("#_acquireLock","lock acquired for storage key",this.storageKey);try{this.lockAcquired=!0;let i=r();for(this.pendingInLock.push(h(this,null,function*(){try{yield i}catch{}})),yield i;this.pendingInLock.length;){let o=[...this.pendingInLock];yield Promise.all(o),this.pendingInLock.splice(0,o.length)}return yield i}finally{this._debug("#_acquireLock","lock released for storage key",this.storageKey),this.lockAcquired=!1}}))}finally{this._debug("#_acquireLock","end")}})}_useSession(t){return h(this,null,function*(){this._debug("#_useSession","begin");try{let r=yield this.__loadSession();return yield t(r)}finally{this._debug("#_useSession","end")}})}__loadSession(){return h(this,null,function*(){this._debug("#__loadSession()","begin"),this.lockAcquired||this._debug("#__loadSession()","used outside of an acquired lock!",new Error().stack);try{let t=null,r=yield uo(this.storage,this.storageKey);if(this._debug("#getSession()","session from storage",r),r!==null&&(this._isValidSession(r)?t=r:(this._debug("#getSession()","session from storage is not valid"),yield this._removeSession())),!t)return{data:{session:null},error:null};let i=t.expires_at?t.expires_at<=Date.now()/1e3:!1;if(this._debug("#__loadSession()",`session has${i?"":" not"} expired`,"expires_at",t.expires_at),!i)return{data:{session:t},error:null};let{session:o,error:s}=yield this._callRefreshToken(t.refresh_token);return s?{data:{session:null},error:s}:{data:{session:o},error:null}}finally{this._debug("#__loadSession()","end")}})}getUser(t){return h(this,null,function*(){return t?yield this._getUser(t):(yield this.initializePromise,this._acquireLock(-1,()=>h(this,null,function*(){return yield this._getUser()})))})}_getUser(t){return h(this,null,function*(){try{return t?yield B(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:t,xform:vt}):yield this._useSession(r=>h(this,null,function*(){var i,o;let{data:s,error:a}=r;if(a)throw a;return yield B(this.fetch,"GET",`${this.url}/user`,{headers:this.headers,jwt:(o=(i=s.session)===null||i===void 0?void 0:i.access_token)!==null&&o!==void 0?o:void 0,xform:vt})}))}catch(r){if(j(r))return{data:{user:null},error:r};throw r}})}updateUser(i){return h(this,arguments,function*(t,r={}){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._updateUser(t,r)}))})}_updateUser(i){return h(this,arguments,function*(t,r={}){try{return yield this._useSession(o=>h(this,null,function*(){let{data:s,error:a}=o;if(a)throw a;if(!s.session)throw new St;let c=s.session,l=null,u=null;if(this.flowType==="pkce"&&t.email!=null){let f=Pn();yield Qt(this.storage,`${this.storageKey}-code-verifier`,f),l=yield kn(f),u=f===l?"plain":"s256"}let{data:d,error:p}=yield B(this.fetch,"PUT",`${this.url}/user`,{headers:this.headers,redirectTo:r?.emailRedirectTo,body:Object.assign(Object.assign({},t),{code_challenge:l,code_challenge_method:u}),jwt:c.access_token,xform:vt});if(p)throw p;return c.user=d.user,yield this._saveSession(c),yield this._notifyAllSubscribers("USER_UPDATED",c),{data:{user:c.user},error:null}}))}catch(o){if(j(o))return{data:{user:null},error:o};throw o}})}_decodeJWT(t){return Ld(t)}setSession(t){return h(this,null,function*(){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._setSession(t)}))})}_setSession(t){return h(this,null,function*(){try{if(!t.access_token||!t.refresh_token)throw new St;let r=Date.now()/1e3,i=r,o=!0,s=null,a=Ld(t.access_token);if(a.exp&&(i=a.exp,o=i<=r),o){let{session:c,error:l}=yield this._callRefreshToken(t.refresh_token);if(l)return{data:{user:null,session:null},error:l};if(!c)return{data:{user:null,session:null},error:null};s=c}else{let{data:c,error:l}=yield this._getUser(t.access_token);if(l)throw l;s={access_token:t.access_token,refresh_token:t.refresh_token,user:c.user,token_type:"bearer",expires_in:i-r,expires_at:i},yield this._saveSession(s),yield this._notifyAllSubscribers("SIGNED_IN",s)}return{data:{user:s.user,session:s},error:null}}catch(r){if(j(r))return{data:{session:null,user:null},error:r};throw r}})}refreshSession(t){return h(this,null,function*(){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._refreshSession(t)}))})}_refreshSession(t){return h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var i;if(!t){let{data:a,error:c}=r;if(c)throw c;t=(i=a.session)!==null&&i!==void 0?i:void 0}if(!t?.refresh_token)throw new St;let{session:o,error:s}=yield this._callRefreshToken(t.refresh_token);return s?{data:{user:null,session:null},error:s}:o?{data:{user:o.user,session:o},error:null}:{data:{user:null,session:null},error:null}}))}catch(r){if(j(r))return{data:{user:null,session:null},error:r};throw r}})}_getSessionFromURL(t){return h(this,null,function*(){try{if(!ct())throw new Ln("No browser detected.");if(this.flowType==="implicit"&&!this._isImplicitGrantFlow())throw new Ln("Not a valid implicit grant flow url.");if(this.flowType=="pkce"&&!t)throw new ho("Not a valid PKCE flow url.");let r=Ua(window.location.href);if(t){if(!r.code)throw new ho("No code detected.");let{data:P,error:J}=yield this._exchangeCodeForSession(r.code);if(J)throw J;let ee=new URL(window.location.href);return ee.searchParams.delete("code"),window.history.replaceState(window.history.state,"",ee.toString()),{data:{session:P.session,redirectType:null},error:null}}if(r.error||r.error_description||r.error_code)throw new Ln(r.error_description||"Error in URL with unspecified error_description",{error:r.error||"unspecified_error",code:r.error_code||"unspecified_code"});let{provider_token:i,provider_refresh_token:o,access_token:s,refresh_token:a,expires_in:c,expires_at:l,token_type:u}=r;if(!s||!c||!a||!u)throw new Ln("No session defined in URL");let d=Math.round(Date.now()/1e3),p=parseInt(c),f=d+p;l&&(f=parseInt(l));let w=f-d;w*1e3<=po&&console.warn(`@supabase/gotrue-js: Session as retrieved from URL expires in ${w}s, should have been closer to ${p}s`);let v=f-p;d-v>=120?console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued over 120s ago, URL could be stale",v,f,d):d-v<0&&console.warn("@supabase/gotrue-js: Session as retrieved from URL was issued in the future? Check the device clok for skew",v,f,d);let{data:D,error:C}=yield this._getUser(s);if(C)throw C;let ie={provider_token:i,provider_refresh_token:o,access_token:s,expires_in:p,expires_at:f,refresh_token:a,token_type:u,user:D.user};return window.location.hash="",this._debug("#_getSessionFromURL()","clearing window.location.hash"),{data:{session:ie,redirectType:r.type},error:null}}catch(r){if(j(r))return{data:{session:null,redirectType:null},error:r};throw r}})}_isImplicitGrantFlow(){let t=Ua(window.location.href);return!!(ct()&&(t.access_token||t.error_description))}_isPKCEFlow(){return h(this,null,function*(){let t=Ua(window.location.href),r=yield uo(this.storage,`${this.storageKey}-code-verifier`);return!!(t.code&&r)})}signOut(){return h(this,arguments,function*(t={scope:"global"}){return yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){return yield this._signOut(t)}))})}_signOut(){return h(this,arguments,function*({scope:t}={scope:"global"}){return yield this._useSession(r=>h(this,null,function*(){var i;let{data:o,error:s}=r;if(s)return{error:s};let a=(i=o.session)===null||i===void 0?void 0:i.access_token;if(a){let{error:c}=yield this.admin.signOut(a,t);if(c&&!(qv(c)&&(c.status===404||c.status===401)))return{error:c}}return t!=="others"&&(yield this._removeSession(),yield Ha(this.storage,`${this.storageKey}-code-verifier`),yield this._notifyAllSubscribers("SIGNED_OUT",null)),{error:null}}))})}onAuthStateChange(t){let r=Bv(),i={id:r,callback:t,unsubscribe:()=>{this._debug("#unsubscribe()","state change callback with id removed",r),this.stateChangeEmitters.delete(r)}};return this._debug("#onAuthStateChange()","registered callback with id",r),this.stateChangeEmitters.set(r,i),h(this,null,function*(){yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){this._emitInitialSession(r)}))}),{data:{subscription:i}}}_emitInitialSession(t){return h(this,null,function*(){return yield this._useSession(r=>h(this,null,function*(){var i,o;try{let{data:{session:s},error:a}=r;if(a)throw a;yield(i=this.stateChangeEmitters.get(t))===null||i===void 0?void 0:i.callback("INITIAL_SESSION",s),this._debug("INITIAL_SESSION","callback id",t,"session",s)}catch(s){yield(o=this.stateChangeEmitters.get(t))===null||o===void 0?void 0:o.callback("INITIAL_SESSION",null),this._debug("INITIAL_SESSION","callback id",t,"error",s),console.error(s)}}))})}resetPasswordForEmail(i){return h(this,arguments,function*(t,r={}){let o=null,s=null;if(this.flowType==="pkce"){let a=Pn();yield Qt(this.storage,`${this.storageKey}-code-verifier`,`${a}/PASSWORD_RECOVERY`),o=yield kn(a),s=a===o?"plain":"s256"}try{return yield B(this.fetch,"POST",`${this.url}/recover`,{body:{email:t,code_challenge:o,code_challenge_method:s,gotrue_meta_security:{captcha_token:r.captchaToken}},headers:this.headers,redirectTo:r.redirectTo})}catch(a){if(j(a))return{data:null,error:a};throw a}})}getUserIdentities(){return h(this,null,function*(){var t;try{let{data:r,error:i}=yield this.getUser();if(i)throw i;return{data:{identities:(t=r.user.identities)!==null&&t!==void 0?t:[]},error:null}}catch(r){if(j(r))return{data:null,error:r};throw r}})}linkIdentity(t){return h(this,null,function*(){var r;try{let{data:i,error:o}=yield this._useSession(s=>h(this,null,function*(){var a,c,l,u,d;let{data:p,error:f}=s;if(f)throw f;let w=yield this._getUrlForProvider(`${this.url}/user/identities/authorize`,t.provider,{redirectTo:(a=t.options)===null||a===void 0?void 0:a.redirectTo,scopes:(c=t.options)===null||c===void 0?void 0:c.scopes,queryParams:(l=t.options)===null||l===void 0?void 0:l.queryParams,skipBrowserRedirect:!0});return yield B(this.fetch,"GET",w,{headers:this.headers,jwt:(d=(u=p.session)===null||u===void 0?void 0:u.access_token)!==null&&d!==void 0?d:void 0})}));if(o)throw o;return ct()&&!(!((r=t.options)===null||r===void 0)&&r.skipBrowserRedirect)&&window.location.assign(i?.url),{data:{provider:t.provider,url:i?.url},error:null}}catch(i){if(j(i))return{data:{provider:t.provider,url:null},error:i};throw i}})}unlinkIdentity(t){return h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var i,o;let{data:s,error:a}=r;if(a)throw a;return yield B(this.fetch,"DELETE",`${this.url}/user/identities/${t.identity_id}`,{headers:this.headers,jwt:(o=(i=s.session)===null||i===void 0?void 0:i.access_token)!==null&&o!==void 0?o:void 0})}))}catch(r){if(j(r))return{data:null,error:r};throw r}})}_refreshAccessToken(t){return h(this,null,function*(){let r=`#_refreshAccessToken(${t.substring(0,5)}...)`;this._debug(r,"begin");try{let i=Date.now();return yield Gv(o=>h(this,null,function*(){return yield zv(o*200),this._debug(r,"refreshing attempt",o),yield B(this.fetch,"POST",`${this.url}/token?grant_type=refresh_token`,{body:{refresh_token:t},headers:this.headers,xform:Kt})}),(o,s,a)=>a&&a.error&&qa(a.error)&&Date.now()+(o+1)*200-ih(this,null,function*(){try{yield c.callback(t,r)}catch(l){s.push(l)}}));if(yield Promise.all(a),s.length>0){for(let c=0;cthis._autoRefreshTokenTick(),po);this.autoRefreshTicker=t,t&&typeof t=="object"&&typeof t.unref=="function"?t.unref():typeof Deno<"u"&&typeof Deno.unrefTimer=="function"&&Deno.unrefTimer(t),setTimeout(()=>h(this,null,function*(){yield this.initializePromise,yield this._autoRefreshTokenTick()}),0)})}_stopAutoRefresh(){return h(this,null,function*(){this._debug("#_stopAutoRefresh()");let t=this.autoRefreshTicker;this.autoRefreshTicker=null,t&&clearInterval(t)})}startAutoRefresh(){return h(this,null,function*(){this._removeVisibilityChangedCallback(),yield this._startAutoRefresh()})}stopAutoRefresh(){return h(this,null,function*(){this._removeVisibilityChangedCallback(),yield this._stopAutoRefresh()})}_autoRefreshTokenTick(){return h(this,null,function*(){this._debug("#_autoRefreshTokenTick()","begin");try{yield this._acquireLock(0,()=>h(this,null,function*(){try{let t=Date.now();try{return yield this._useSession(r=>h(this,null,function*(){let{data:{session:i}}=r;if(!i||!i.refresh_token||!i.expires_at){this._debug("#_autoRefreshTokenTick()","no session");return}let o=Math.floor((i.expires_at*1e3-t)/po);this._debug("#_autoRefreshTokenTick()",`access token expires in ${o} ticks, a tick lasts ${po}ms, refresh threshold is ${ny} ticks`),o<=ny&&(yield this._callRefreshToken(i.refresh_token))}))}catch(r){console.error("Auto refresh tick failed with error. This is likely a transient error.",r)}}finally{this._debug("#_autoRefreshTokenTick()","end")}}))}catch(t){if(t.isAcquireTimeout||t instanceof Za)this._debug("auto refresh token tick lock not available");else throw t}})}_handleVisibilityChange(){return h(this,null,function*(){if(this._debug("#_handleVisibilityChange()"),!ct()||!window?.addEventListener)return this.autoRefreshToken&&this.startAutoRefresh(),!1;try{this.visibilityChangedCallback=()=>h(this,null,function*(){return yield this._onVisibilityChanged(!1)}),window?.addEventListener("visibilitychange",this.visibilityChangedCallback),yield this._onVisibilityChanged(!0)}catch(t){console.error("_handleVisibilityChange",t)}})}_onVisibilityChanged(t){return h(this,null,function*(){let r=`#_onVisibilityChanged(${t})`;this._debug(r,"visibilityState",document.visibilityState),document.visibilityState==="visible"?(this.autoRefreshToken&&this._startAutoRefresh(),t||(yield this.initializePromise,yield this._acquireLock(-1,()=>h(this,null,function*(){if(document.visibilityState!=="visible"){this._debug(r,"acquired the lock to recover the session, but the browser visibilityState is no longer visible, aborting");return}yield this._recoverAndRefresh()})))):document.visibilityState==="hidden"&&this.autoRefreshToken&&this._stopAutoRefresh()})}_getUrlForProvider(t,r,i){return h(this,null,function*(){let o=[`provider=${encodeURIComponent(r)}`];if(i?.redirectTo&&o.push(`redirect_to=${encodeURIComponent(i.redirectTo)}`),i?.scopes&&o.push(`scopes=${encodeURIComponent(i.scopes)}`),this.flowType==="pkce"){let s=Pn();yield Qt(this.storage,`${this.storageKey}-code-verifier`,s);let a=yield kn(s),c=s===a?"plain":"s256";this._debug("PKCE","code verifier",`${s.substring(0,5)}...`,"code challenge",a,"method",c);let l=new URLSearchParams({code_challenge:`${encodeURIComponent(a)}`,code_challenge_method:`${encodeURIComponent(c)}`});o.push(l.toString())}if(i?.queryParams){let s=new URLSearchParams(i.queryParams);o.push(s.toString())}return i?.skipBrowserRedirect&&o.push(`skip_http_redirect=${i.skipBrowserRedirect}`),`${t}?${o.join("&")}`})}_unenroll(t){return h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var i;let{data:o,error:s}=r;return s?{data:null,error:s}:yield B(this.fetch,"DELETE",`${this.url}/factors/${t.factorId}`,{headers:this.headers,jwt:(i=o?.session)===null||i===void 0?void 0:i.access_token})}))}catch(r){if(j(r))return{data:null,error:r};throw r}})}_enroll(t){return h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var i,o;let{data:s,error:a}=r;if(a)return{data:null,error:a};let{data:c,error:l}=yield B(this.fetch,"POST",`${this.url}/factors`,{body:{friendly_name:t.friendlyName,factor_type:t.factorType,issuer:t.issuer},headers:this.headers,jwt:(i=s?.session)===null||i===void 0?void 0:i.access_token});return l?{data:null,error:l}:(!((o=c?.totp)===null||o===void 0)&&o.qr_code&&(c.totp.qr_code=`data:image/svg+xml;utf-8,${c.totp.qr_code}`),{data:c,error:null})}))}catch(r){if(j(r))return{data:null,error:r};throw r}})}_verify(t){return h(this,null,function*(){return this._acquireLock(-1,()=>h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var i;let{data:o,error:s}=r;if(s)return{data:null,error:s};let{data:a,error:c}=yield B(this.fetch,"POST",`${this.url}/factors/${t.factorId}/verify`,{body:{code:t.code,challenge_id:t.challengeId},headers:this.headers,jwt:(i=o?.session)===null||i===void 0?void 0:i.access_token});return c?{data:null,error:c}:(yield this._saveSession(Object.assign({expires_at:Math.round(Date.now()/1e3)+a.expires_in},a)),yield this._notifyAllSubscribers("MFA_CHALLENGE_VERIFIED",a),{data:a,error:c})}))}catch(r){if(j(r))return{data:null,error:r};throw r}}))})}_challenge(t){return h(this,null,function*(){return this._acquireLock(-1,()=>h(this,null,function*(){try{return yield this._useSession(r=>h(this,null,function*(){var i;let{data:o,error:s}=r;return s?{data:null,error:s}:yield B(this.fetch,"POST",`${this.url}/factors/${t.factorId}/challenge`,{headers:this.headers,jwt:(i=o?.session)===null||i===void 0?void 0:i.access_token})}))}catch(r){if(j(r))return{data:null,error:r};throw r}}))})}_challengeAndVerify(t){return h(this,null,function*(){let{data:r,error:i}=yield this._challenge({factorId:t.factorId});return i?{data:null,error:i}:yield this._verify({factorId:t.factorId,challengeId:r.id,code:t.code})})}_listFactors(){return h(this,null,function*(){let{data:{user:t},error:r}=yield this.getUser();if(r)return{data:null,error:r};let i=t?.factors||[],o=i.filter(s=>s.factor_type==="totp"&&s.status==="verified");return{data:{all:i,totp:o},error:null}})}_getAuthenticatorAssuranceLevel(){return h(this,null,function*(){return this._acquireLock(-1,()=>h(this,null,function*(){return yield this._useSession(t=>h(this,null,function*(){var r,i;let{data:{session:o},error:s}=t;if(s)return{data:null,error:s};if(!o)return{data:{currentLevel:null,nextLevel:null,currentAuthenticationMethods:[]},error:null};let a=this._decodeJWT(o.access_token),c=null;a.aal&&(c=a.aal);let l=c;((i=(r=o.user.factors)===null||r===void 0?void 0:r.filter(p=>p.status==="verified"))!==null&&i!==void 0?i:[]).length>0&&(l="aal2");let d=a.amr||[];return{data:{currentLevel:c,nextLevel:l,currentAuthenticationMethods:d},error:null}}))}))})}}return e.nextInstanceID=0,e})();var rS=Ud,Bd=rS;var Ya=class extends Bd{constructor(n){super(n)}};var iS=function(e,n,t,r){function i(o){return o instanceof t?o:new t(function(s){s(o)})}return new(t||(t=Promise))(function(o,s){function a(u){try{l(r.next(u))}catch(d){s(d)}}function c(u){try{l(r.throw(u))}catch(d){s(d)}}function l(u){u.done?o(u.value):i(u.value).then(a,c)}l((r=r.apply(e,n||[])).next())})},Qa=class{constructor(n,t,r){var i,o,s;if(this.supabaseUrl=n,this.supabaseKey=t,!n)throw new Error("supabaseUrl is required.");if(!t)throw new Error("supabaseKey is required.");let a=Vv(n);this.realtimeUrl=`${a}/realtime/v1`.replace(/^http/i,"ws"),this.authUrl=`${a}/auth/v1`,this.storageUrl=`${a}/storage/v1`,this.functionsUrl=`${a}/functions/v1`;let c=`sb-${new URL(this.authUrl).hostname.split(".")[0]}-auth-token`,l={db:kv,realtime:Lv,auth:Object.assign(Object.assign({},Fv),{storageKey:c}),global:Pv},u=$v(r??{},l);this.storageKey=(i=u.auth.storageKey)!==null&&i!==void 0?i:"",this.headers=(o=u.global.headers)!==null&&o!==void 0?o:{},u.accessToken?(this.accessToken=u.accessToken,this.auth=new Proxy({},{get:(d,p)=>{throw new Error(`@supabase/supabase-js: Supabase Client is configured with the accessToken option, accessing supabase.auth.${String(p)} is not possible`)}})):this.auth=this._initSupabaseAuthClient((s=u.auth)!==null&&s!==void 0?s:{},this.headers,u.global.fetch),this.fetch=jv(t,this._getAccessToken.bind(this),u.global.fetch),this.realtime=this._initRealtimeClient(Object.assign({headers:this.headers},u.realtime)),this.rest=new Dv(`${a}/rest/v1`,{headers:this.headers,schema:u.db.schema,fetch:this.fetch}),u.accessToken||this._listenForAuthEvents()}get functions(){return new Qi(this.functionsUrl,{headers:this.headers,customFetch:this.fetch})}get storage(){return new ao(this.storageUrl,this.headers,this.fetch)}from(n){return this.rest.from(n)}schema(n){return this.rest.schema(n)}rpc(n,t={},r={}){return this.rest.rpc(n,t,r)}channel(n,t={config:{}}){return this.realtime.channel(n,t)}getChannels(){return this.realtime.getChannels()}removeChannel(n){return this.realtime.removeChannel(n)}removeAllChannels(){return this.realtime.removeAllChannels()}_getAccessToken(){var n,t;return iS(this,void 0,void 0,function*(){if(this.accessToken)return yield this.accessToken();let{data:r}=yield this.auth.getSession();return(t=(n=r.session)===null||n===void 0?void 0:n.access_token)!==null&&t!==void 0?t:null})}_initSupabaseAuthClient({autoRefreshToken:n,persistSession:t,detectSessionInUrl:r,storage:i,storageKey:o,flowType:s,lock:a,debug:c},l,u){var d;let p={Authorization:`Bearer ${this.supabaseKey}`,apikey:`${this.supabaseKey}`};return new Ya({url:this.authUrl,headers:Object.assign(Object.assign({},p),l),storageKey:o,autoRefreshToken:n,persistSession:t,detectSessionInUrl:r,storage:i,flowType:s,lock:a,debug:c,fetch:u,hasCustomAuthorizationHeader:(d="Authorization"in this.headers)!==null&&d!==void 0?d:!1})}_initRealtimeClient(n){return new oo(this.realtimeUrl,Object.assign(Object.assign({},n),{params:Object.assign({apikey:this.supabaseKey},n?.params)}))}_listenForAuthEvents(){return this.auth.onAuthStateChange((t,r)=>{this._handleTokenChanged(t,"CLIENT",r?.access_token)})}_handleTokenChanged(n,t,r){(n==="TOKEN_REFRESHED"||n==="SIGNED_IN")&&this.changedAccessToken!==r?(this.realtime.setAuth(r??null),this.changedAccessToken=r):n==="SIGNED_OUT"&&(this.realtime.setAuth(this.supabaseKey),t=="STORAGE"&&this.auth.signOut(),this.changedAccessToken=void 0)}};var ry=(e,n,t)=>new Qa(e,n,t);var Hd={production:!0,supabaseUrl:"https://qjahtmynumgefznenznr.supabase.co",supabaseKey:"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJzdXBhYmFzZSIsInJlZiI6InFqYWh0bXludW1nZWZ6bmVuem5yIiwicm9sZSI6ImFub24iLCJpYXQiOjE3MzE4NTI3MDQsImV4cCI6MjA0NzQyODcwNH0.Vu-krFpene5evj8cjbSsarwv3364Tiqwwl69ZU7-H3A"};var Ka=(()=>{class e{constructor(){this.supabase=ry(Hd.supabaseUrl,Hd.supabaseKey)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var jn=class extends Error{};jn.prototype.name="InvalidTokenError";function oS(e){return decodeURIComponent(atob(e).replace(/(.)/g,(n,t)=>{let r=t.charCodeAt(0).toString(16).toUpperCase();return r.length<2&&(r="0"+r),"%"+r}))}function sS(e){let n=e.replace(/-/g,"+").replace(/_/g,"/");switch(n.length%4){case 0:break;case 2:n+="==";break;case 3:n+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return oS(n)}catch{return atob(n)}}function zd(e,n){if(typeof e!="string")throw new jn("Invalid token specified: must be a string");n||(n={});let t=n.header===!0?0:1,r=e.split(".")[t];if(typeof r!="string")throw new jn(`Invalid token specified: missing part #${t+1}`);let i;try{i=sS(r)}catch(o){throw new jn(`Invalid token specified: invalid base64 for part #${t+1} (${o.message})`)}try{return JSON.parse(i)}catch(o){throw new jn(`Invalid token specified: invalid json for part #${t+1} (${o.message})`)}}var Qe=(()=>{class e{constructor(){this.supabase_client=m(Ka).supabase}session(){this.supabase_client.auth.getSession()}signUp(t,r){return h(this,null,function*(){let{data:i,error:o}=yield this.supabase_client.auth.signUp({email:t,password:r});return o?(console.error("Error al registrarse:",o.message),{error:o}):(console.log("Registro exitoso:",i),{data:i})})}logIn(t,r){return this.supabase_client.auth.signInWithPassword({email:t,password:r})}signOut(){return h(this,null,function*(){let{error:t}=yield this.supabase_client.auth.signOut();return t?{error:t}:{error:null}})}isLoggeIn(){return this.getToken()?!this.isTokenExpired():!1}isTokenExpired(){let t=this.getToken();if(!t)return!0;let r=zd(t),i=Date.now()>=r.exp*1e3;return i&&this.logout(),i}getUserDetail(){let t=this.getToken();if(!t)return null;let r=zd(t);return{id:r.sub,email:r.email,rol:r.role}}logout(){localStorage.removeItem("token")}getToken(){return localStorage.getItem("token")}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();function aS(e,n){e&1&&(y(0,"small",15)(1,"span",7),_(2," error "),g(),_(3," Debes ingresar tu correo."),g())}function cS(e,n){e&1&&(y(0,"small",15)(1,"span",7),_(2," error "),g(),_(3," El correo no es valido."),g())}function lS(e,n){if(e&1&&ge(0,aS,4,0,"small",15)(1,cS,4,0,"small",15),e&2){let t=st();ve(0,t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.required?0:-1),F(),ve(1,t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.email&&(t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.pattern)?1:-1)}}function uS(e,n){e&1&&(y(0,"small",15)(1,"span",7),_(2," error "),g(),_(3," Debes ingresar tu contrase\xF1a."),g())}function dS(e,n){if(e&1&&ge(0,uS,4,0,"small",15),e&2){let t=st();ve(0,t.formulario.controls.password.errors!=null&&t.formulario.controls.password.errors.required?0:-1)}}var iy=(()=>{class e{constructor(){this.form=m(kr),this.router=m(Ue),this.authSupaBase=m(Qe)}ngOnInit(){this.formulario=this.form.group({email:this.form.control("",[Me.required,Me.email,Me.pattern(/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/)]),password:this.form.control("",[Me.required])})}autenticacion(){if(this.formulario.valid){let t=this.formulario.controls.email.value,r=this.formulario.controls.password.value;this.authSupaBase.logIn(t,r).then(i=>{localStorage.setItem("token",i.data.session.access_token),this.router.navigate(["/administrador/home"])}).catch(i=>{console.log(i)})}}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-auth-login"]],standalone:!0,features:[Z],decls:30,vars:3,consts:[[1,"card"],[1,"card-body"],[1,"text-center"],[1,"card-title"],["enctype","multipart/form-data","method","post",3,"submit","formGroup"],[1,"mb-3"],["for","email",1,"form-label"],[1,"material-symbols-outlined"],["type","email","name","email","id","email","formControlName","email","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"mb-2"],["for","password",1,"form-label"],["type","password","name","password","id","password","formControlName","password","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"accion"],["routerLink","/register"],["type","submit",1,"btn-event"],["id","message-error",1,"text-muted"]],template:function(r,i){r&1&&(y(0,"div",0)(1,"div",1)(2,"div",2)(3,"h5",3),_(4,"Inicio de Sesion"),g()(),T(5,"hr"),y(6,"form",4),ae("submit",function(){return i.autenticacion()}),y(7,"div",5)(8,"label",6)(9,"span",7),_(10," mail "),g(),_(11," Correo Electronico"),g(),T(12,"input",8),ge(13,lS,2,2),g(),y(14,"div",9)(15,"label",10)(16,"span",7),_(17," lock "),g(),_(18,"Contrase\xF1a"),g(),T(19,"input",11),ge(20,dS,1,1),g(),y(21,"div",12)(22,"p"),_(23,"Deseas crear una nueva cuenta. "),y(24,"a",13),_(25,"Aqui"),g()(),y(26,"button",14)(27,"span",7),_(28," login "),g(),_(29," Ingresar"),g()()()()()),r&2&&(F(6),ot("formGroup",i.formulario),F(7),ve(13,i.formulario.controls.email.touched&&i.formulario.controls.email.invalid||i.formulario.controls.email.dirty?13:-1),F(7),ve(20,i.formulario.controls.password.touched&&i.formulario.controls.password.invalid||i.formulario.controls.password.dirty?20:-1))},dependencies:[Fr,Pr,Zt,Nr,Rr,xn,Tn,Oe],styles:[".card[_ngcontent-%COMP%]{width:40vh;box-shadow:5px 10px 15px #9c9c9c25;border:none;border-radius:30px}.card[_ngcontent-%COMP%] .card-header[_ngcontent-%COMP%]{background-color:#fff;color:#000}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%]{margin:0;padding:0;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:1px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%]:focus{border:1px solid rgba(156,156,156,.144)}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%]{color:#ff00007c!important;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{text-align:end;font-size:.75rem;margin-bottom:10px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] p[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{text-decoration:none;color:#000}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] p[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:hover{color:#b28181}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{border:none;width:100%;padding:4px;border-radius:20px;background-color:#f8f4f4;display:flex;justify-content:center;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.1rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background-color:#f4ecec}"]})}}return e})();var oy=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-login"]],standalone:!0,features:[Z],decls:2,vars:0,consts:[[1,"content-login"]],template:function(r,i){r&1&&(y(0,"div",0),T(1,"app-auth-login"),g())},dependencies:[iy]})}}return e})();function fS(e,n){e&1&&(y(0,"small",15)(1,"span",4),_(2," error "),g(),_(3," Debes ingresar tu correo."),g())}function hS(e,n){e&1&&(y(0,"small",15)(1,"span",4),_(2," error "),g(),_(3," El correo no es valido."),g())}function pS(e,n){if(e&1&&ge(0,fS,4,0,"small",15)(1,hS,4,0,"small",15),e&2){let t=st();ve(0,t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.required?0:-1),F(),ve(1,t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.email&&(t.formulario.controls.email.errors!=null&&t.formulario.controls.email.errors.pattern)?1:-1)}}function gS(e,n){e&1&&(y(0,"small",15)(1,"span",4),_(2," error "),g(),_(3," Debes ingresar tu contrase\xF1a."),g())}function mS(e,n){if(e&1&&ge(0,gS,4,0,"small",15),e&2){let t=st();ve(0,t.formulario.controls.password.errors!=null&&t.formulario.controls.password.errors.required?0:-1)}}var sy=(()=>{class e{constructor(){this.form=m(kr),this.authSupaBase=m(Qe)}ngOnInit(){this.formulario=this.form.group({email:this.form.control("",[Me.required,Me.email,Me.pattern(/^[a-zA-Z0-9._%+-]+@[a-zA-Z0-9.-]+\.[a-zA-Z]{2,}$/)]),password:this.form.control("",[Me.required])})}crearCuenta(){return h(this,null,function*(){if(this.formulario.valid){let t=this.formulario.controls.email.value,r=this.formulario.controls.password.value;console.log(t,r);let i=yield this.authSupaBase.signUp(t,r);i.error?alert(i.error.message):console.log(i.data)}})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-auth-register"]],standalone:!0,features:[Z],decls:29,vars:3,consts:[[1,"card"],[1,"card-body"],[1,"text-center"],["routerLink","/login",1,"arrow-login"],[1,"material-symbols-outlined"],[1,"card-title"],["enctype","multipart/form-data","method","post",3,"submit","formGroup"],[1,"mb-3"],["for","email",1,"form-label"],["type","email","name","email","id","email","formControlName","email","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"mb-2"],["for","password",1,"form-label"],["type","password","name","password","id","password","formControlName","password","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"accion"],["type","submit",1,"btn-event"],["id","message-error",1,"text-muted"]],template:function(r,i){r&1&&(y(0,"div",0)(1,"div",1)(2,"div",2)(3,"a",3)(4,"span",4),_(5," chevron_left "),g()(),y(6,"h5",5),_(7,"Crear Cuenta"),g()(),T(8,"hr"),y(9,"form",6),ae("submit",function(){return i.crearCuenta()}),y(10,"div",7)(11,"label",8)(12,"span",4),_(13," mail "),g(),_(14," Correo Electronico"),g(),T(15,"input",9),ge(16,pS,2,2),g(),y(17,"div",10)(18,"label",11)(19,"span",4),_(20," lock "),g(),_(21,"Contrase\xF1a"),g(),T(22,"input",12),ge(23,mS,1,1),g(),y(24,"div",13)(25,"button",14)(26,"span",4),_(27," save "),g(),_(28," Crear Cuenta"),g()()()()()),r&2&&(F(9),ot("formGroup",i.formulario),F(7),ve(16,i.formulario.controls.email.touched&&i.formulario.controls.email.invalid||i.formulario.controls.email.dirty?16:-1),F(7),ve(23,i.formulario.controls.password.touched&&i.formulario.controls.password.invalid||i.formulario.controls.password.dirty?23:-1))},dependencies:[Fr,Pr,Zt,Nr,Rr,xn,Tn,Oe],styles:[".card[_ngcontent-%COMP%]{width:40vh;box-shadow:5px 10px 15px #9c9c9c25;border:none;border-radius:30px}.card[_ngcontent-%COMP%] .card-header[_ngcontent-%COMP%]{background-color:#fff;color:#000}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow-login[_ngcontent-%COMP%]{position:absolute;top:2%;left:5%;text-decoration:none;color:#000;background-color:#f8f4f4;border-radius:100%;padding:2px;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow-login[_ngcontent-%COMP%]:hover{background-color:#f4ecec}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%]{margin:0;padding:0;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:1px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%]:focus{border:1px solid rgba(156,156,156,.144)}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%]{color:#ff00007c!important;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{border:none;width:100%;padding:4px;border-radius:20px;background-color:#f8f4f4;display:flex;justify-content:center;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.1rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background-color:#f4ecec}"]})}}return e})();var ay=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-register"]],standalone:!0,features:[Z],decls:2,vars:0,consts:[[1,"content-register"]],template:function(r,i){r&1&&(y(0,"div",0),T(1,"app-auth-register"),g())},dependencies:[sy]})}}return e})();var cy=(()=>{class e{constructor(){this.work=Ts(),this.delete=xs()}deleteEvent(){this.delete.emit(this.work())}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-home-work"]],inputs:{work:[se.SignalBased,"work"]},outputs:{delete:"delete"},standalone:!0,features:[Z],decls:11,vars:6,consts:[[1,"card"],[1,"actions"],["title","Editar",1,"update",3,"routerLink"],["title","Eliminar",1,"delete",3,"click"],[1,"card-body"],[1,"card-title"],[1,"content"],[1,"card-footer",3,"routerLink"]],template:function(r,i){if(r&1&&(y(0,"div",0)(1,"div",1),T(2,"button",2),y(3,"button",3),ae("click",function(){return i.deleteEvent()}),g()(),y(4,"div",4)(5,"h5",5),_(6),g(),y(7,"div",6),_(8),g()(),y(9,"a",7),_(10," Ver "),g()()),r&2){let o,s,a,c;F(2),$s("routerLink","/administrador/home/work/",(o=i.work())==null?null:o.id,"/edit"),F(4),_i((s=i.work())==null?null:s.titulo),F(2),gr(" ",(a=i.work())==null?null:a.descripcion," "),F(),$s("routerLink","/administrador/home/",(c=i.work())==null?null:c.id,"/work/")}},dependencies:[Oe],styles:[".card[_ngcontent-%COMP%]{text-decoration:none;border:2px solid #f8f4f4}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%]{position:absolute;top:1%;right:0%}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{margin-right:5px;border-radius:100%;padding:0;border:1px solid rgb(129,129,129);width:13px;height:13px}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{display:flex;justify-content:center;align-items:center}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] .update[_ngcontent-%COMP%]{background-color:#ff0}.card[_ngcontent-%COMP%] .actions[_ngcontent-%COMP%] .delete[_ngcontent-%COMP%]{background-color:red}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%]{padding:9px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .card-title[_ngcontent-%COMP%]{margin-bottom:4px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .content[_ngcontent-%COMP%]{line-height:.9rem;font-size:.74rem;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:5;overflow:hidden;text-overflow:ellipsis;text-align:justify}.card[_ngcontent-%COMP%] .card-footer[_ngcontent-%COMP%]{text-decoration:none;padding:4px 8px;border:none;text-align:center;background-color:#fff;font-size:.9rem}.card[_ngcontent-%COMP%]:hover{box-shadow:10px 10px 10px #ebdddd;cursor:pointer}@media screen and (width <= 1210){.card-footer[_ngcontent-%COMP%]{font-size:.4rem}}"]})}}return e})();var Ja=(()=>{class e{constructor(){this.works=new ue([]),this.work_dinamic=[],this.supabase_client=m(Ka).supabase}cleanWork(){this.work_dinamic=[],this.works.next(this.work_dinamic)}setWork(t){this.work_dinamic.push(t),this.works.next(this.work_dinamic)}getWork(){return this.works.asObservable()}removeWork(t){let r=this.work_dinamic.findIndex(i=>i.id===t);r!=-1&&(this.work_dinamic.splice(r,1),this.works.next(this.work_dinamic))}updateWork(t){let r=this.work_dinamic.findIndex(i=>i.id===t.id);r!=-1&&(this.work_dinamic[r].titulo=t.titulo,this.work_dinamic[r].descripcion=t.descripcion,this.works.next(this.work_dinamic))}sellstWork(){return h(this,null,function*(){let{data:t,error:r}=yield this.supabase_client.from("work").select("*");return r?(console.error("Error al leer los datos:",r.message),{work:null,error:r}):{work:t,error:null}})}gettWork(t){return h(this,null,function*(){let{data:r,error:i}=yield this.supabase_client.from("work").select().eq("id",t).single();return i?(console.error("Error al leer los datos:",i.message),{work:null,error:i}):{work:r,error:null}})}dltWork(t){return h(this,null,function*(){let{error:r}=yield this.supabase_client.from("work").delete().eq("id",t);return r?(console.error("Error al eliminar el registro:",r.message),{error:r}):(console.log("Registro eliminado correctamente"),{error:null})})}addWork(t){return h(this,null,function*(){let{data:r,error:i}=yield this.supabase_client.from("work").insert([t]).select();return i?(console.error("Error al insertar datos:",i.message),{data:null,error:i}):(console.log("Datos insertados correctamente:",r),{data:r,error:null})})}updWork(t,r){return h(this,null,function*(){try{let{data:i,error:o}=yield this.supabase_client.from("work").update(r).eq("id",t).select().single();if(o)throw console.error("Error al actualizar el registro:",o.message),new Error("No se pudo actualizar el registro");return i}catch(i){throw console.error("Error en el proceso de actualizaci\xF3n:",i),i}})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275prov=I({token:e,factory:e.\u0275fac,providedIn:"root"})}}return e})();var vS=(e,n)=>n.id;function yS(e,n){if(e&1){let t=gg();y(0,"app-home-work",4),ae("delete",function(i){Xh(t);let o=st();return ep(o.dltWork(i))}),g()}if(e&2){let t=n.$implicit;ot("work",t)}}var ly=(()=>{class e{constructor(){this.work=[],this.areaServices=m(Ja)}ngOnInit(){this.sellWork()}ngOnDestroy(){this.areaServices.cleanWork()}ngAfterViewInit(){this.areaServices.getWork().subscribe({next:t=>{this.work=t},error:t=>{}})}sellWork(){return h(this,null,function*(){let t=yield this.areaServices.sellstWork();t.error||t.work&&t.work.forEach(r=>{this.areaServices.setWork(r)})})}dltWork(t){return h(this,null,function*(){confirm(`Deseas eliminar el area de trabajo '${t?.titulo}'`)&&((yield this.areaServices.dltWork(t?.id)).error||this.areaServices.removeWork(t?.id))})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-home"]],standalone:!0,features:[Z],decls:6,vars:0,consts:[[1,"content-work"],[3,"work"],["routerLink","/administrador/home/work/create",1,"add-work"],[1,"material-symbols-outlined"],[3,"delete","work"]],template:function(r,i){r&1&&(y(0,"div",0),hg(1,yS,1,1,"app-home-work",1,vS),y(3,"a",2)(4,"span",3),_(5," add "),g()()()),r&2&&(F(),pg(i.work))},dependencies:[cy,Oe],styles:[".content-work[_ngcontent-%COMP%]{margin:20px;display:grid;grid-template-columns:repeat(auto-fit,minmax(400px,1fr));gap:20px}.add-work[_ngcontent-%COMP%]{box-shadow:5px 10px 10px #f4ecec;background-color:#ebdddd;text-decoration:none;width:max-content;padding:4px;margin:0;display:flex;align-items:center;justify-content:center;border-radius:100%;position:fixed;bottom:2%;right:1%}.add-work[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{color:#000;font-size:1.8rem}@media screen and (width <= 700px){.add-work[_ngcontent-%COMP%]{bottom:2%;right:3%}}"]})}}return e})();var uy=(e,n)=>m(Qe).isLoggeIn()?!0:(m(Ue).navigate(["/"]),!1);var Gd=(e,n)=>m(Qe).isLoggeIn()?(m(Ue).navigate(["/administrador/home"]),!1):!0;function wS(e,n){e&1&&(y(0,"small",15)(1,"span",4),_(2," error "),g(),_(3," Debes ingresar el titulo."),g())}function _S(e,n){if(e&1&&ge(0,wS,4,0,"small",15),e&2){let t=st();ve(0,t.formulario.controls.titulo.errors!=null&&t.formulario.controls.titulo.errors.required?0:-1)}}function DS(e,n){e&1&&(y(0,"small",15)(1,"span",4),_(2," error "),g(),_(3," Debes ingresar la descripci\xF3n."),g())}function bS(e,n){if(e&1&&ge(0,DS,4,0,"small",15),e&2){let t=st();ve(0,t.formulario.controls.descripcion.errors!=null&&t.formulario.controls.descripcion.errors.required?0:-1)}}var dy=(()=>{class e{constructor(){this.formulario_work=xs(),this.editWork=Ts(),this.userDetails=m(Qe).getUserDetail(),this.routerActive=m(at),this.form=m(kr),this.routerActive.params.subscribe(t=>{t.id>0?(this.titulo="Editar Area de Trabajo",this.idWork=t.id):(this.titulo="Crear Area de Trabajo",this.idWork=0)}),this.formulario=this.form.group({titulo:this.form.control("",[Me.required]),descripcion:this.form.control("",[Me.required])}),fu(()=>{let t=this.editWork();t!=null&&this.detailWork(t)})}detailWork(t){this.formulario.controls.titulo.setValue(t.titulo),this.formulario.controls.descripcion.setValue(t.descripcion)}submitWork(){let t;this.formulario.valid&&(this.idWork>0?t={id:this.idWork,titulo:this.formulario.controls.titulo.value,descripcion:this.formulario.controls.descripcion.value,uidUser:this.userDetails?.id}:t={titulo:this.formulario.controls.titulo.value,descripcion:this.formulario.controls.descripcion.value,uidUser:this.userDetails?.id},this.formulario_work.emit(t))}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-post-update-work"]],inputs:{editWork:[se.SignalBased,"editWork"]},outputs:{formulario_work:"formulario_work"},standalone:!0,features:[Z],decls:29,vars:5,consts:[[1,"card"],[1,"card-body"],[1,"text-center"],["routerLink","/administrador/home",1,"arrow"],[1,"material-symbols-outlined"],[1,"card-title"],["enctype","multipart/form-data","method","post",3,"submit","formGroup"],[1,"mb-3"],["for","titulo",1,"form-label"],["type","text","name","titulo","id","titulo","formControlName","titulo","placeholder","",1,"form-control","form-control-sm","shadow-none"],[1,"mb-2"],["for","password",1,"form-label"],["name","descripcion","id","descripcion","formControlName","descripcion",1,"form-control","form-control-sm","shadow-none"],[1,"accion"],["type","submit",1,"btn-event"],["id","message-error",1,"text-muted"]],template:function(r,i){r&1&&(y(0,"div",0)(1,"div",1)(2,"div",2)(3,"a",3)(4,"span",4),_(5," chevron_left "),g()(),y(6,"h5",5),_(7),g()(),T(8,"hr"),y(9,"form",6),ae("submit",function(){return i.submitWork()}),y(10,"div",7)(11,"label",8)(12,"span",4),_(13," edit "),g(),_(14," Titulo"),g(),T(15,"input",9),ge(16,_S,1,1),g(),y(17,"div",10)(18,"label",11)(19,"span",4),_(20," edit "),g(),_(21," Descripci\xF3n"),g(),T(22,"textarea",12),ge(23,bS,1,1),g(),y(24,"div",13)(25,"button",14)(26,"span",4),_(27," save "),g(),_(28),g()()()()()),r&2&&(F(7),_i(i.titulo),F(2),ot("formGroup",i.formulario),F(7),ve(16,i.formulario.controls.titulo.touched&&i.formulario.controls.titulo.invalid||i.formulario.controls.titulo.dirty?16:-1),F(7),ve(23,i.formulario.controls.descripcion.touched&&i.formulario.controls.descripcion.invalid||i.formulario.controls.descripcion.dirty?23:-1),F(5),gr(" ",i.idWork>0?"Editar Area":"Crear Area",""))},dependencies:[Oe,Fr,Pr,Zt,Nr,Rr,xn,Tn],styles:[".card[_ngcontent-%COMP%]{width:40vh;box-shadow:5px 10px 15px #9c9c9c25;border:none;border-radius:30px}.card[_ngcontent-%COMP%] .card-header[_ngcontent-%COMP%]{background-color:#fff;color:#000}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]{position:absolute;top:2%;left:5%;text-decoration:none;color:#000;background-color:#f8f4f4;border-radius:100%;padding:2px;display:flex;align-items:center;cursor:pointer}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]:hover{background-color:#f4ecec}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%]{margin:0;padding:0;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-label[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:1px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .form-control[_ngcontent-%COMP%]:focus{border:1px solid rgba(156,156,156,.144)}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] textarea[_ngcontent-%COMP%]{resize:none;field-sizing:content}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%]{color:#ff00007c!important;display:flex;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] #message-error[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{border:none;width:100%;padding:4px;border-radius:20px;background-color:#f8f4f4;display:flex;justify-content:center;align-items:center}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.1rem;margin-right:2px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background-color:#f4ecec}"]})}}return e})();var qd=(()=>{class e{constructor(){this.areaServices=m(Ja),this.routerActive=m(at),this.router=m(Ue),this.routerActive.params.subscribe(t=>{t.id>0&&this.getWork(t.id)})}formPostArea(t){t.id>0?this.updateWork(t):this.postArea(t),setTimeout(()=>{this.router.navigate(["/administrador/home"])},1e3)}getWork(t){return h(this,null,function*(){let r=yield this.areaServices.gettWork(t);r.error?this.router.navigate(["administrador/home"]):r.work&&(this.editWork=r.work)})}postArea(t){return h(this,null,function*(){(yield this.areaServices.addWork(t)).error})}updateWork(t){return h(this,null,function*(){let r=yield this.areaServices.updWork(t.id,{titulo:t.titulo,descripcion:t.descripcion,uidUser:t.uidUser})})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-create-update-work"]],standalone:!0,features:[Z],decls:2,vars:1,consts:[[1,"content-post-update"],[3,"formulario_work","editWork"]],template:function(r,i){r&1&&(y(0,"div",0)(1,"app-post-update-work",1),ae("formulario_work",function(s){return i.formPostArea(s)}),g()()),r&2&&(F(),ot("editWork",i.editWork))},dependencies:[dy]})}}return e})();var fy=(()=>{class e{constructor(){this.authService=m(Qe),this.router=m(Ue)}logout(){return h(this,null,function*(){(yield this.authService.signOut()).error||(this.authService.logout(),this.router.navigate([""]))})}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-navbar"]],standalone:!0,features:[Z],decls:11,vars:0,consts:[[1,"navbar","navbar-expand","bg-body-tertiary"],[1,"container-fluid"],["routerLink","/administrador/home/",1,"navbar-brand"],["src","../../../../../assets/img/icon.png","alt","Logo","width","30","height","30"],["id","navbarSupportedContent",1,"collapse","navbar-collapse","justify-content-end"],["type","button",1,"logout",3,"click"],[1,"material-symbols-outlined"]],template:function(r,i){r&1&&(y(0,"nav",0)(1,"div",1)(2,"a",2),T(3,"img",3),_(4," Gesti\xF3n de Tareas"),g(),y(5,"div",4)(6,"button",5),ae("click",function(){return i.logout()}),y(7,"span",6),_(8," logout "),g(),_(9," Cerrar Sesi\xF3n "),g()()()(),T(10,"router-outlet"))},dependencies:[Hi,Oe],styles:[".navbar[_ngcontent-%COMP%]{position:sticky;top:0;z-index:1020}.navbar-brand[_ngcontent-%COMP%], .logout[_ngcontent-%COMP%]{display:flex;place-items:center;gap:2px}.logout[_ngcontent-%COMP%]{background-color:#fff;padding:5px 10px;border-radius:13px;border:2px solid #f8f4f4}.logout[_ngcontent-%COMP%]:hover{background-color:#ebdddd}"]})}}return e})();var hy=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-work-area-post-task"]],standalone:!0,features:[Z],decls:12,vars:0,consts:[["enctype","multipart/form-data","method","post"],[1,"mt-4","mb-2"],["type","text","name","tarea","id","tarea","placeholder","Nueva Tarea ........",1,"form-control","form-control-sm","shadow-none"],["id","message-error",1,"text-muted"],[1,"material-symbols-outlined"],[1,"accion"],["type","submit",1,"btn-event"]],template:function(r,i){r&1&&(y(0,"form",0)(1,"div",1),T(2,"input",2),y(3,"small",3)(4,"span",4),_(5," error "),g(),_(6," Help text"),g()(),y(7,"div",5)(8,"button",6)(9,"span",4),_(10," add "),g(),_(11," Agregar Tarea "),g()()())},styles:[".form-control[_ngcontent-%COMP%]:focus{border:1px solid rgba(156,156,156,.1450980392)}#message-error[_ngcontent-%COMP%]{color:#ff00007c!important;display:flex;align-items:center}#message-error[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.02rem;margin-right:2px}.accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]{border:none;width:100%;padding:4px;border-radius:20px;background-color:#f8f4f4;display:flex;justify-content:center;align-items:center}.accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1.1rem;margin-right:2px}.accion[_ngcontent-%COMP%] button[_ngcontent-%COMP%]:hover{background-color:#f4ecec}"]})}}return e})();var py=(()=>{class e{constructor(){this.task_complete=dg(!0)}static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-work-area-list-task"]],standalone:!0,features:[Z],decls:118,vars:26,consts:[[1,"list-group","list-group-flush"],[1,"list-group-item"],[1,"task"],["type","checkbox","value","","id","firstCheckbox",1,"form-check-input","shadow-none"],["for","firstCheckbox",1,"form-check-label"],[1,"accion"],[1,"delete_task"],[1,"material-symbols-outlined"]],template:function(r,i){r&1&&(y(0,"ul",0)(1,"li",1)(2,"div",2),T(3,"input",3),y(4,"label",4),_(5,"First checkbox"),g()(),y(6,"div",5)(7,"button",6)(8,"span",7),_(9," delete "),g()()()(),y(10,"li",1)(11,"div",2),T(12,"input",3),y(13,"label",4),_(14,"First checkbox"),g()(),y(15,"div",5)(16,"button",6)(17,"span",7),_(18," delete "),g()()()(),y(19,"li",1)(20,"div",2),T(21,"input",3),y(22,"label",4),_(23,"First checkbox"),g()(),y(24,"div",5)(25,"button",6)(26,"span",7),_(27," delete "),g()()()(),y(28,"li",1)(29,"div",2),T(30,"input",3),y(31,"label",4),_(32,"First checkbox"),g()(),y(33,"div",5)(34,"button",6)(35,"span",7),_(36," delete "),g()()()(),y(37,"li",1)(38,"div",2),T(39,"input",3),y(40,"label",4),_(41,"First checkbox"),g()(),y(42,"div",5)(43,"button",6)(44,"span",7),_(45," delete "),g()()()(),y(46,"li",1)(47,"div",2),T(48,"input",3),y(49,"label",4),_(50,"First checkbox"),g()(),y(51,"div",5)(52,"button",6)(53,"span",7),_(54," delete "),g()()()(),y(55,"li",1)(56,"div",2),T(57,"input",3),y(58,"label",4),_(59,"First checkbox"),g()(),y(60,"div",5)(61,"button",6)(62,"span",7),_(63," delete "),g()()()(),y(64,"li",1)(65,"div",2),T(66,"input",3),y(67,"label",4),_(68,"First checkbox"),g()(),y(69,"div",5)(70,"button",6)(71,"span",7),_(72," delete "),g()()()(),y(73,"li",1)(74,"div",2),T(75,"input",3),y(76,"label",4),_(77,"First checkbox"),g()(),y(78,"div",5)(79,"button",6)(80,"span",7),_(81," delete "),g()()()(),y(82,"li",1)(83,"div",2),T(84,"input",3),y(85,"label",4),_(86,"First checkbox"),g()(),y(87,"div",5)(88,"button",6)(89,"span",7),_(90," delete "),g()()()(),y(91,"li",1)(92,"div",2),T(93,"input",3),y(94,"label",4),_(95,"First checkbox"),g()(),y(96,"div",5)(97,"button",6)(98,"span",7),_(99," delete "),g()()()(),y(100,"li",1)(101,"div",2),T(102,"input",3),y(103,"label",4),_(104,"First checkbox"),g()(),y(105,"div",5)(106,"button",6)(107,"span",7),_(108," delete "),g()()()(),y(109,"li",1)(110,"div",2),T(111,"input",3),y(112,"label",4),_(113,"First checkbox"),g()(),y(114,"div",5)(115,"button",6)(116,"span",7),_(117," delete "),g()()()()()),r&2&&(F(),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()),F(9),me("task-hidden",i.task_complete()))},styles:[".list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%]{padding:8px 9px;display:flex;justify-content:space-between;align-items:center}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .task[_ngcontent-%COMP%] .form-check-input[_ngcontent-%COMP%]{margin-right:10px;border-radius:100%}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .task[_ngcontent-%COMP%] .form-check-input[_ngcontent-%COMP%]:checked{background-color:#f4ecec;color:#000;border-color:#f4ecec}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .task[_ngcontent-%COMP%] .form-check-input[_ngcontent-%COMP%] {box-shadow:none!important;border:1px solid rgba(156,156,156,.1450980392)}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] .delete_task[_ngcontent-%COMP%]{display:flex;place-items:center;border-radius:100%;padding:5px;border:none;background-color:#f8f4f4}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] .delete_task[_ngcontent-%COMP%] span[_ngcontent-%COMP%]{font-size:1rem}.list-group[_ngcontent-%COMP%] .list-group-item[_ngcontent-%COMP%] .accion[_ngcontent-%COMP%] .delete_task[_ngcontent-%COMP%]:hover{background-color:#f4ecec}.list-group[_ngcontent-%COMP%] .task-hidden[_ngcontent-%COMP%] .form-check-input[_ngcontent-%COMP%]:checked{cursor:no-drop}.list-group[_ngcontent-%COMP%] .task-hidden[_ngcontent-%COMP%] .form-check-label[_ngcontent-%COMP%]{text-decoration:line-through}"]})}}return e})();var gy=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-work-area"]],standalone:!0,features:[Z],decls:13,vars:0,consts:[[1,"content-work-area"],[1,"card"],[1,"card-body"],[1,"text-center"],["routerLink","/administrador/home",1,"arrow"],[1,"material-symbols-outlined"],[1,"card-title","text-center"],[1,"content-task"]],template:function(r,i){r&1&&(y(0,"div",0)(1,"div",1)(2,"div",2)(3,"div",3)(4,"a",4)(5,"span",5),_(6," chevron_left "),g()()(),T(7,"app-work-area-post-task")(8,"hr"),y(9,"h6",6),_(10,"Lista de Tareas"),g(),y(11,"div",7),T(12,"app-work-area-list-task"),g()()()())},dependencies:[hy,py,Oe],styles:[".card[_ngcontent-%COMP%]{width:40vh;margin-bottom:20px;box-shadow:5px 10px 15px #9c9c9c25;border:none;border-radius:30px}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]{position:absolute;top:2%;left:5%;text-decoration:none;color:#000;background-color:#f8f4f4;border-radius:100%;padding:2px;display:flex;align-items:center;cursor:pointer}.card[_ngcontent-%COMP%] .card-body[_ngcontent-%COMP%] .arrow[_ngcontent-%COMP%]:hover{background-color:#f4ecec}.card[_ngcontent-%COMP%] .content-task[_ngcontent-%COMP%]{height:100%;max-height:20rem;overflow:auto}.card[_ngcontent-%COMP%] .content-task[_ngcontent-%COMP%]::-webkit-scrollbar{display:none}"]})}}return e})();var my=[{path:"",pathMatch:"full",redirectTo:"login"},{path:"login",component:oy,canActivate:[Gd]},{path:"register",component:ay,canActivate:[Gd]},{path:"administrador/home",component:fy,children:[{path:"",component:ly},{path:"work/create",component:qd},{path:"work/:id/edit",component:qd},{path:":id/work",component:gy}],canActivate:[uy]}];var vy=(e,n)=>{let t=localStorage.getItem("token"),r=e.clone({setHeaders:{Authorization:`Bearer ${t}`}});return n(r)};var yy={providers:[Am(my),$g(Ug([vy]))]};var wy=(()=>{class e{static{this.\u0275fac=function(r){return new(r||e)}}static{this.\u0275cmp=W({type:e,selectors:[["app-root"]],standalone:!0,features:[Z],decls:1,vars:0,template:function(r,i){r&1&&T(0,"router-outlet")},dependencies:[Hi]})}}return e})();Yg(wy,yy).catch(e=>console.error(e));