import{e as Yn}from"./chunk-PTRKLJBW.js";import{I as Kn,d as Wn,f as Gn,g as vt,h as Qn,i as Zn,j as mt}from"./chunk-A2TWSRQ3.js";import{Aa as Rn,Ba as x,Ca as Sn,Ea as w,Ed as Vn,Gd as be,Ha as b,Hc as zn,Hd as Ie,I as A,Id as Bn,J as d,Jd as Vt,K as pt,L as pn,La as S,M as gn,Ma as wn,Md as Ae,Na as bn,O as C,Oa as O,P as Ft,Pa as ve,Pb as Un,Q as D,Qa as F,R as de,Ra as f,Rc as Fn,Rd as Bt,S as vn,T as fe,Ta as In,Ua as An,Ub as et,Vb as xn,Wd as Hn,Xa as qt,Ya as Dn,Z as Q,Za as Mn,_a as me,_b as Pn,a as h,ab as Tn,ac as nt,b as I,ba as Y,bc as Se,ca as X,cc as $n,db as tt,ea as pe,eb as _,fa as J,gb as Ce,ha as mn,hc as Nn,jc as jn,l as hn,lb as ye,lc as we,m as dn,mb as En,mc as Ln,md as _n,na as _t,nb as Re,o as fn,oa as z,q as le,qa as ge,qc as kn,r as he,ra as Cn,rb as On,s as L,sb as gt,t as E,va as yn,y as k,zd as qn}from"./chunk-WNE7PXNE.js";var p="primary",Pt=Symbol("RouteTitle"),Oe=class{constructor(t){this.params=t||{}}has(t){return Object.prototype.hasOwnProperty.call(this.params,t)}get(t){if(this.has(t)){let i=this.params[t];return Array.isArray(i)?i[0]:i}return null}getAll(t){if(this.has(t)){let i=this.params[t];return Array.isArray(i)?i:[i]}return[]}get keys(){return Object.keys(this.params)}};function at(e){return new Oe(e)}function Vr(e,t,i){let n=i.path.split("/");if(n.length>e.length||i.pathMatch==="full"&&(t.hasChildren()||n.length<e.length))return null;let r={};for(let s=0;s<n.length;s++){let o=n[s],a=e[s];if(o.startsWith(":"))r[o.substring(1)]=a;else if(o!==a.path)return null}return{consumed:e.slice(0,n.length),posParams:r}}function Br(e,t){if(e.length!==t.length)return!1;for(let i=0;i<e.length;++i)if(!P(e[i],t[i]))return!1;return!0}function P(e,t){let i=e?Ue(e):void 0,n=t?Ue(t):void 0;if(!i||!n||i.length!=n.length)return!1;let r;for(let s=0;s<i.length;s++)if(r=i[s],!or(e[r],t[r]))return!1;return!0}function Ue(e){return[...Object.keys(e),...Object.getOwnPropertySymbols(e)]}function or(e,t){if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return!1;let i=[...e].sort(),n=[...t].sort();return i.every((r,s)=>n[s]===r)}else return e===t}function ar(e){return e.length>0?e[e.length-1]:null}function W(e){return pn(e)?e:Vn(e)?A(Promise.resolve(e)):d(e)}var Hr={exact:cr,subset:lr},ur={exact:Wr,subset:Gr,ignored:()=>!0};function Xn(e,t,i){return Hr[i.paths](e.root,t.root,i.matrixParams)&&ur[i.queryParams](e.queryParams,t.queryParams)&&!(i.fragment==="exact"&&e.fragment!==t.fragment)}function Wr(e,t){return P(e,t)}function cr(e,t,i){if(!K(e.segments,t.segments)||!Gt(e.segments,t.segments,i)||e.numberOfChildren!==t.numberOfChildren)return!1;for(let n in t.children)if(!e.children[n]||!cr(e.children[n],t.children[n],i))return!1;return!0}function Gr(e,t){return Object.keys(t).length<=Object.keys(e).length&&Object.keys(t).every(i=>or(e[i],t[i]))}function lr(e,t,i){return hr(e,t,t.segments,i)}function hr(e,t,i,n){if(e.segments.length>i.length){let r=e.segments.slice(0,i.length);return!(!K(r,i)||t.hasChildren()||!Gt(r,i,n))}else if(e.segments.length===i.length){if(!K(e.segments,i)||!Gt(e.segments,i,n))return!1;for(let r in t.children)if(!e.children[r]||!lr(e.children[r],t.children[r],n))return!1;return!0}else{let r=i.slice(0,e.segments.length),s=i.slice(e.segments.length);return!K(e.segments,r)||!Gt(e.segments,r,n)||!e.children[p]?!1:hr(e.children[p],t,s,n)}}function Gt(e,t,i){return t.every((n,r)=>ur[i](e[r].parameters,n.parameters))}var q=class{constructor(t=new m([],{}),i={},n=null){this.root=t,this.queryParams=i,this.fragment=n}get queryParamMap(){return this._queryParamMap??=at(this.queryParams),this._queryParamMap}toString(){return Kr.serialize(this)}},m=class{constructor(t,i){this.segments=t,this.children=i,this.parent=null,Object.values(i).forEach(n=>n.parent=this)}hasChildren(){return this.numberOfChildren>0}get numberOfChildren(){return Object.keys(this.children).length}toString(){return Qt(this)}},Z=class{constructor(t,i){this.path=t,this.parameters=i}get parameterMap(){return this._parameterMap??=at(this.parameters),this._parameterMap}toString(){return fr(this)}};function Qr(e,t){return K(e,t)&&e.every((i,n)=>P(i.parameters,t[n].parameters))}function K(e,t){return e.length!==t.length?!1:e.every((i,n)=>i.path===t[n].path)}function Zr(e,t){let i=[];return Object.entries(e.children).forEach(([n,r])=>{n===p&&(i=i.concat(t(r,n)))}),Object.entries(e.children).forEach(([n,r])=>{n!==p&&(i=i.concat(t(r,n)))}),i}var $t=(()=>{let t=class t{};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:()=>new It,providedIn:"root"});let e=t;return e})(),It=class{parse(t){let i=new Pe(t);return new q(i.parseRootSegment(),i.parseQueryParams(),i.parseFragment())}serialize(t){let i=`/${Ct(t.root,!0)}`,n=Jr(t.queryParams),r=typeof t.fragment=="string"?`#${Yr(t.fragment)}`:"";return`${i}${n}${r}`}},Kr=new It;function Qt(e){return e.segments.map(t=>fr(t)).join("/")}function Ct(e,t){if(!e.hasChildren())return Qt(e);if(t){let i=e.children[p]?Ct(e.children[p],!1):"",n=[];return Object.entries(e.children).forEach(([r,s])=>{r!==p&&n.push(`${r}:${Ct(s,!1)}`)}),n.length>0?`${i}(${n.join("//")})`:i}else{let i=Zr(e,(n,r)=>r===p?[Ct(e.children[p],!1)]:[`${r}:${Ct(n,!1)}`]);return Object.keys(e.children).length===1&&e.children[p]!=null?`${Qt(e)}/${i[0]}`:`${Qt(e)}/(${i.join("//")})`}}function dr(e){return encodeURIComponent(e).replace(/%40/g,"@").replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",")}function Ht(e){return dr(e).replace(/%3B/gi,";")}function Yr(e){return encodeURI(e)}function xe(e){return dr(e).replace(/\(/g,"%28").replace(/\)/g,"%29").replace(/%26/gi,"&")}function Zt(e){return decodeURIComponent(e)}function Jn(e){return Zt(e.replace(/\+/g,"%20"))}function fr(e){return`${xe(e.path)}${Xr(e.parameters)}`}function Xr(e){return Object.entries(e).map(([t,i])=>`;${xe(t)}=${xe(i)}`).join("")}function Jr(e){let t=Object.entries(e).map(([i,n])=>Array.isArray(n)?n.map(r=>`${Ht(i)}=${Ht(r)}`).join("&"):`${Ht(i)}=${Ht(n)}`).filter(i=>i);return t.length?`?${t.join("&")}`:""}var ti=/^[^\/()?;#]+/;function De(e){let t=e.match(ti);return t?t[0]:""}var ei=/^[^\/()?;=#]+/;function ni(e){let t=e.match(ei);return t?t[0]:""}var ri=/^[^=?&#]+/;function ii(e){let t=e.match(ri);return t?t[0]:""}var si=/^[^&#]+/;function oi(e){let t=e.match(si);return t?t[0]:""}var Pe=class{constructor(t){this.url=t,this.remaining=t}parseRootSegment(){return this.consumeOptional("/"),this.remaining===""||this.peekStartsWith("?")||this.peekStartsWith("#")?new m([],{}):new m([],this.parseChildren())}parseQueryParams(){let t={};if(this.consumeOptional("?"))do this.parseQueryParam(t);while(this.consumeOptional("&"));return t}parseFragment(){return this.consumeOptional("#")?decodeURIComponent(this.remaining):null}parseChildren(){if(this.remaining==="")return{};this.consumeOptional("/");let t=[];for(this.peekStartsWith("(")||t.push(this.parseSegment());this.peekStartsWith("/")&&!this.peekStartsWith("//")&&!this.peekStartsWith("/(");)this.capture("/"),t.push(this.parseSegment());let i={};this.peekStartsWith("/(")&&(this.capture("/"),i=this.parseParens(!0));let n={};return this.peekStartsWith("(")&&(n=this.parseParens(!1)),(t.length>0||Object.keys(i).length>0)&&(n[p]=new m(t,i)),n}parseSegment(){let t=De(this.remaining);if(t===""&&this.peekStartsWith(";"))throw new b(4009,!1);return this.capture(t),new Z(Zt(t),this.parseMatrixParams())}parseMatrixParams(){let t={};for(;this.consumeOptional(";");)this.parseParam(t);return t}parseParam(t){let i=ni(this.remaining);if(!i)return;this.capture(i);let n="";if(this.consumeOptional("=")){let r=De(this.remaining);r&&(n=r,this.capture(n))}t[Zt(i)]=Zt(n)}parseQueryParam(t){let i=ii(this.remaining);if(!i)return;this.capture(i);let n="";if(this.consumeOptional("=")){let o=oi(this.remaining);o&&(n=o,this.capture(n))}let r=Jn(i),s=Jn(n);if(t.hasOwnProperty(r)){let o=t[r];Array.isArray(o)||(o=[o],t[r]=o),o.push(s)}else t[r]=s}parseParens(t){let i={};for(this.capture("(");!this.consumeOptional(")")&&this.remaining.length>0;){let n=De(this.remaining),r=this.remaining[n.length];if(r!=="/"&&r!==")"&&r!==";")throw new b(4010,!1);let s;n.indexOf(":")>-1?(s=n.slice(0,n.indexOf(":")),this.capture(s),this.capture(":")):t&&(s=p);let o=this.parseChildren();i[s]=Object.keys(o).length===1?o[p]:new m([],o),this.consumeOptional("//")}return i}peekStartsWith(t){return this.remaining.startsWith(t)}consumeOptional(t){return this.peekStartsWith(t)?(this.remaining=this.remaining.substring(t.length),!0):!1}capture(t){if(!this.consumeOptional(t))throw new b(4011,!1)}};function pr(e){return e.segments.length>0?new m([],{[p]:e}):e}function gr(e){let t={};for(let[n,r]of Object.entries(e.children)){let s=gr(r);if(n===p&&s.segments.length===0&&s.hasChildren())for(let[o,a]of Object.entries(s.children))t[o]=a;else(s.segments.length>0||s.hasChildren())&&(t[n]=s)}let i=new m(e.segments,t);return ai(i)}function ai(e){if(e.numberOfChildren===1&&e.children[p]){let t=e.children[p];return new m(e.segments.concat(t.segments),t.children)}return e}function ut(e){return e instanceof q}function ui(e,t,i=null,n=null){let r=vr(e);return mr(r,t,i,n)}function vr(e){let t;function i(s){let o={};for(let c of s.children){let u=i(c);o[c.outlet]=u}let a=new m(s.url,o);return s===e&&(t=a),a}let n=i(e.root),r=pr(n);return t??r}function mr(e,t,i,n){let r=e;for(;r.parent;)r=r.parent;if(t.length===0)return Me(r,r,r,i,n);let s=ci(t);if(s.toRoot())return Me(r,r,new m([],{}),i,n);let o=li(s,r,e),a=o.processChildren?St(o.segmentGroup,o.index,s.commands):yr(o.segmentGroup,o.index,s.commands);return Me(r,o.segmentGroup,a,i,n)}function Kt(e){return typeof e=="object"&&e!=null&&!e.outlets&&!e.segmentPath}function At(e){return typeof e=="object"&&e!=null&&e.outlets}function Me(e,t,i,n,r){let s={};n&&Object.entries(n).forEach(([c,u])=>{s[c]=Array.isArray(u)?u.map(l=>`${l}`):`${u}`});let o;e===t?o=i:o=Cr(e,t,i);let a=pr(gr(o));return new q(a,s,r)}function Cr(e,t,i){let n={};return Object.entries(e.children).forEach(([r,s])=>{s===t?n[r]=i:n[r]=Cr(s,t,i)}),new m(e.segments,n)}var Yt=class{constructor(t,i,n){if(this.isAbsolute=t,this.numberOfDoubleDots=i,this.commands=n,t&&n.length>0&&Kt(n[0]))throw new b(4003,!1);let r=n.find(At);if(r&&r!==ar(n))throw new b(4004,!1)}toRoot(){return this.isAbsolute&&this.commands.length===1&&this.commands[0]=="/"}};function ci(e){if(typeof e[0]=="string"&&e.length===1&&e[0]==="/")return new Yt(!0,0,e);let t=0,i=!1,n=e.reduce((r,s,o)=>{if(typeof s=="object"&&s!=null){if(s.outlets){let a={};return Object.entries(s.outlets).forEach(([c,u])=>{a[c]=typeof u=="string"?u.split("/"):u}),[...r,{outlets:a}]}if(s.segmentPath)return[...r,s.segmentPath]}return typeof s!="string"?[...r,s]:o===0?(s.split("/").forEach((a,c)=>{c==0&&a==="."||(c==0&&a===""?i=!0:a===".."?t++:a!=""&&r.push(a))}),r):[...r,s]},[]);return new Yt(i,t,n)}var st=class{constructor(t,i,n){this.segmentGroup=t,this.processChildren=i,this.index=n}};function li(e,t,i){if(e.isAbsolute)return new st(t,!0,0);if(!i)return new st(t,!1,NaN);if(i.parent===null)return new st(i,!0,0);let n=Kt(e.commands[0])?0:1,r=i.segments.length-1+n;return hi(i,r,e.numberOfDoubleDots)}function hi(e,t,i){let n=e,r=t,s=i;for(;s>r;){if(s-=r,n=n.parent,!n)throw new b(4005,!1);r=n.segments.length}return new st(n,!1,r-s)}function di(e){return At(e[0])?e[0].outlets:{[p]:e}}function yr(e,t,i){if(e??=new m([],{}),e.segments.length===0&&e.hasChildren())return St(e,t,i);let n=fi(e,t,i),r=i.slice(n.commandIndex);if(n.match&&n.pathIndex<e.segments.length){let s=new m(e.segments.slice(0,n.pathIndex),{});return s.children[p]=new m(e.segments.slice(n.pathIndex),e.children),St(s,0,r)}else return n.match&&r.length===0?new m(e.segments,{}):n.match&&!e.hasChildren()?$e(e,t,i):n.match?St(e,0,r):$e(e,t,i)}function St(e,t,i){if(i.length===0)return new m(e.segments,{});{let n=di(i),r={};if(Object.keys(n).some(s=>s!==p)&&e.children[p]&&e.numberOfChildren===1&&e.children[p].segments.length===0){let s=St(e.children[p],t,i);return new m(e.segments,s.children)}return Object.entries(n).forEach(([s,o])=>{typeof o=="string"&&(o=[o]),o!==null&&(r[s]=yr(e.children[s],t,o))}),Object.entries(e.children).forEach(([s,o])=>{n[s]===void 0&&(r[s]=o)}),new m(e.segments,r)}}function fi(e,t,i){let n=0,r=t,s={match:!1,pathIndex:0,commandIndex:0};for(;r<e.segments.length;){if(n>=i.length)return s;let o=e.segments[r],a=i[n];if(At(a))break;let c=`${a}`,u=n<i.length-1?i[n+1]:null;if(r>0&&c===void 0)break;if(c&&u&&typeof u=="object"&&u.outlets===void 0){if(!er(c,u,o))return s;n+=2}else{if(!er(c,{},o))return s;n++}r++}return{match:!0,pathIndex:r,commandIndex:n}}function $e(e,t,i){let n=e.segments.slice(0,t),r=0;for(;r<i.length;){let s=i[r];if(At(s)){let c=pi(s.outlets);return new m(n,c)}if(r===0&&Kt(i[0])){let c=e.segments[t];n.push(new Z(c.path,tr(i[0]))),r++;continue}let o=At(s)?s.outlets[p]:`${s}`,a=r<i.length-1?i[r+1]:null;o&&a&&Kt(a)?(n.push(new Z(o,tr(a))),r+=2):(n.push(new Z(o,{})),r++)}return new m(n,{})}function pi(e){let t={};return Object.entries(e).forEach(([i,n])=>{typeof n=="string"&&(n=[n]),n!==null&&(t[i]=$e(new m([],{}),0,n))}),t}function tr(e){let t={};return Object.entries(e).forEach(([i,n])=>t[i]=`${n}`),t}function er(e,t,i){return e==i.path&&P(t,i.parameters)}var wt="imperative",R=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}(R||{}),U=class{constructor(t,i){this.id=t,this.url=i}},ct=class extends U{constructor(t,i,n="imperative",r=null){super(t,i),this.type=R.NavigationStart,this.navigationTrigger=n,this.restoredState=r}toString(){return`NavigationStart(id: ${this.id}, url: '${this.url}')`}},$=class extends U{constructor(t,i,n){super(t,i),this.urlAfterRedirects=n,this.type=R.NavigationEnd}toString(){return`NavigationEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}')`}},T=function(e){return e[e.Redirect=0]="Redirect",e[e.SupersededByNewNavigation=1]="SupersededByNewNavigation",e[e.NoDataFromResolver=2]="NoDataFromResolver",e[e.GuardRejected=3]="GuardRejected",e}(T||{}),Xt=function(e){return e[e.IgnoredSameUrlNavigation=0]="IgnoredSameUrlNavigation",e[e.IgnoredByUrlHandlingStrategy=1]="IgnoredByUrlHandlingStrategy",e}(Xt||{}),V=class extends U{constructor(t,i,n,r){super(t,i),this.reason=n,this.code=r,this.type=R.NavigationCancel}toString(){return`NavigationCancel(id: ${this.id}, url: '${this.url}')`}},B=class extends U{constructor(t,i,n,r){super(t,i),this.reason=n,this.code=r,this.type=R.NavigationSkipped}},Dt=class extends U{constructor(t,i,n,r){super(t,i),this.error=n,this.target=r,this.type=R.NavigationError}toString(){return`NavigationError(id: ${this.id}, url: '${this.url}', error: ${this.error})`}},Jt=class extends U{constructor(t,i,n,r){super(t,i),this.urlAfterRedirects=n,this.state=r,this.type=R.RoutesRecognized}toString(){return`RoutesRecognized(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},Ne=class extends U{constructor(t,i,n,r){super(t,i),this.urlAfterRedirects=n,this.state=r,this.type=R.GuardsCheckStart}toString(){return`GuardsCheckStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},je=class extends U{constructor(t,i,n,r,s){super(t,i),this.urlAfterRedirects=n,this.state=r,this.shouldActivate=s,this.type=R.GuardsCheckEnd}toString(){return`GuardsCheckEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state}, shouldActivate: ${this.shouldActivate})`}},Le=class extends U{constructor(t,i,n,r){super(t,i),this.urlAfterRedirects=n,this.state=r,this.type=R.ResolveStart}toString(){return`ResolveStart(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},ke=class extends U{constructor(t,i,n,r){super(t,i),this.urlAfterRedirects=n,this.state=r,this.type=R.ResolveEnd}toString(){return`ResolveEnd(id: ${this.id}, url: '${this.url}', urlAfterRedirects: '${this.urlAfterRedirects}', state: ${this.state})`}},ze=class{constructor(t){this.route=t,this.type=R.RouteConfigLoadStart}toString(){return`RouteConfigLoadStart(path: ${this.route.path})`}},Fe=class{constructor(t){this.route=t,this.type=R.RouteConfigLoadEnd}toString(){return`RouteConfigLoadEnd(path: ${this.route.path})`}},_e=class{constructor(t){this.snapshot=t,this.type=R.ChildActivationStart}toString(){return`ChildActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},qe=class{constructor(t){this.snapshot=t,this.type=R.ChildActivationEnd}toString(){return`ChildActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Ve=class{constructor(t){this.snapshot=t,this.type=R.ActivationStart}toString(){return`ActivationStart(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},Be=class{constructor(t){this.snapshot=t,this.type=R.ActivationEnd}toString(){return`ActivationEnd(path: '${this.snapshot.routeConfig&&this.snapshot.routeConfig.path||""}')`}},te=class{constructor(t,i,n){this.routerEvent=t,this.position=i,this.anchor=n,this.type=R.Scroll}toString(){let t=this.position?`${this.position[0]}, ${this.position[1]}`:null;return`Scroll(anchor: '${this.anchor}', position: '${t}')`}},Mt=class{},Tt=class{constructor(t){this.url=t}};var He=class{constructor(){this.outlet=null,this.route=null,this.injector=null,this.children=new Nt,this.attachRef=null}},Nt=(()=>{let t=class t{constructor(){this.contexts=new Map}onChildOutletCreated(n,r){let s=this.getOrCreateContext(n);s.outlet=r,this.contexts.set(n,s)}onChildOutletDestroyed(n){let r=this.getContext(n);r&&(r.outlet=null,r.attachRef=null)}onOutletDeactivated(){let n=this.contexts;return this.contexts=new Map,n}onOutletReAttached(n){this.contexts=n}getOrCreateContext(n){let r=this.getContext(n);return r||(r=new He,this.contexts.set(n,r)),r}getContext(n){return this.contexts.get(n)||null}};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})(),ee=class{constructor(t){this._root=t}get root(){return this._root.value}parent(t){let i=this.pathFromRoot(t);return i.length>1?i[i.length-2]:null}children(t){let i=We(t,this._root);return i?i.children.map(n=>n.value):[]}firstChild(t){let i=We(t,this._root);return i&&i.children.length>0?i.children[0].value:null}siblings(t){let i=Ge(t,this._root);return i.length<2?[]:i[i.length-2].children.map(r=>r.value).filter(r=>r!==t)}pathFromRoot(t){return Ge(t,this._root).map(i=>i.value)}};function We(e,t){if(e===t.value)return t;for(let i of t.children){let n=We(e,i);if(n)return n}return null}function Ge(e,t){if(e===t.value)return[t];for(let i of t.children){let n=Ge(e,i);if(n.length)return n.unshift(t),n}return[]}var M=class{constructor(t,i){this.value=t,this.children=i}toString(){return`TreeNode(${this.value})`}};function it(e){let t={};return e&&e.children.forEach(i=>t[i.value.outlet]=i),t}var ne=class extends ee{constructor(t,i){super(t),this.snapshot=i,rn(this,t)}toString(){return this.snapshot.toString()}};function Rr(e){let t=gi(e),i=new E([new Z("",{})]),n=new E({}),r=new E({}),s=new E({}),o=new E(""),a=new H(i,n,s,o,r,p,e,t.root);return a.snapshot=t.root,new ne(new M(a,[]),t)}function gi(e){let t={},i={},n={},r="",s=new Et([],t,n,r,i,p,e,null,{});return new re("",new M(s,[]))}var H=class{constructor(t,i,n,r,s,o,a,c){this.urlSubject=t,this.paramsSubject=i,this.queryParamsSubject=n,this.fragmentSubject=r,this.dataSubject=s,this.outlet=o,this.component=a,this._futureSnapshot=c,this.title=this.dataSubject?.pipe(C(u=>u[Pt]))??d(void 0),this.url=t,this.params=i,this.queryParams=n,this.fragment=r,this.data=s}get routeConfig(){return this._futureSnapshot.routeConfig}get root(){return this._routerState.root}get parent(){return this._routerState.parent(this)}get firstChild(){return this._routerState.firstChild(this)}get children(){return this._routerState.children(this)}get pathFromRoot(){return this._routerState.pathFromRoot(this)}get paramMap(){return this._paramMap??=this.params.pipe(C(t=>at(t))),this._paramMap}get queryParamMap(){return this._queryParamMap??=this.queryParams.pipe(C(t=>at(t))),this._queryParamMap}toString(){return this.snapshot?this.snapshot.toString():`Future(${this._futureSnapshot})`}};function nn(e,t,i="emptyOnly"){let n,{routeConfig:r}=e;return t!==null&&(i==="always"||r?.path===""||!t.component&&!t.routeConfig?.loadComponent)?n={params:h(h({},t.params),e.params),data:h(h({},t.data),e.data),resolve:h(h(h(h({},e.data),t.data),r?.data),e._resolvedData)}:n={params:h({},e.params),data:h({},e.data),resolve:h(h({},e.data),e._resolvedData??{})},r&&wr(r)&&(n.resolve[Pt]=r.title),n}var Et=class{get title(){return this.data?.[Pt]}constructor(t,i,n,r,s,o,a,c,u){this.url=t,this.params=i,this.queryParams=n,this.fragment=r,this.data=s,this.outlet=o,this.component=a,this.routeConfig=c,this._resolve=u}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??=at(this.params),this._paramMap}get queryParamMap(){return this._queryParamMap??=at(this.queryParams),this._queryParamMap}toString(){let t=this.url.map(n=>n.toString()).join("/"),i=this.routeConfig?this.routeConfig.path:"";return`Route(url:'${t}', path:'${i}')`}},re=class extends ee{constructor(t,i){super(i),this.url=t,rn(this,i)}toString(){return Sr(this._root)}};function rn(e,t){t.value._routerState=e,t.children.forEach(i=>rn(e,i))}function Sr(e){let t=e.children.length>0?` { ${e.children.map(Sr).join(", ")} } `:"";return`${e.value}${t}`}function Te(e){if(e.snapshot){let t=e.snapshot,i=e._futureSnapshot;e.snapshot=i,P(t.queryParams,i.queryParams)||e.queryParamsSubject.next(i.queryParams),t.fragment!==i.fragment&&e.fragmentSubject.next(i.fragment),P(t.params,i.params)||e.paramsSubject.next(i.params),Br(t.url,i.url)||e.urlSubject.next(i.url),P(t.data,i.data)||e.dataSubject.next(i.data)}else e.snapshot=e._futureSnapshot,e.dataSubject.next(e._futureSnapshot.data)}function Qe(e,t){let i=P(e.params,t.params)&&Qr(e.url,t.url),n=!e.parent!=!t.parent;return i&&!n&&(!e.parent||Qe(e.parent,t.parent))}function wr(e){return typeof e.title=="string"||e.title===null}var vi=(()=>{let t=class t{constructor(){this.activated=null,this._activatedRoute=null,this.name=p,this.activateEvents=new gt,this.deactivateEvents=new gt,this.attachEvents=new gt,this.detachEvents=new gt,this.parentContexts=f(Nt),this.location=f($n),this.changeDetector=f(Ae),this.environmentInjector=f(tt),this.inputBinder=f(ae,{optional:!0}),this.supportsBindingToComponentInputs=!0}get activatedComponentRef(){return this.activated}ngOnChanges(n){if(n.name){let{firstChange:r,previousValue:s}=n.name;if(r)return;this.isTrackedInParentContexts(s)&&(this.deactivate(),this.parentContexts.onChildOutletDestroyed(s)),this.initializeOutletWithName()}}ngOnDestroy(){this.isTrackedInParentContexts(this.name)&&this.parentContexts.onChildOutletDestroyed(this.name),this.inputBinder?.unsubscribeFromRouteData(this)}isTrackedInParentContexts(n){return this.parentContexts.getContext(n)?.outlet===this}ngOnInit(){this.initializeOutletWithName()}initializeOutletWithName(){if(this.parentContexts.onChildOutletCreated(this.name,this),this.activated)return;let n=this.parentContexts.getContext(this.name);n?.route&&(n.attachRef?this.attach(n.attachRef,n.route):this.activateWith(n.route,n.injector))}get isActivated(){return!!this.activated}get component(){if(!this.activated)throw new b(4012,!1);return this.activated.instance}get activatedRoute(){if(!this.activated)throw new b(4012,!1);return this._activatedRoute}get activatedRouteData(){return this._activatedRoute?this._activatedRoute.snapshot.data:{}}detach(){if(!this.activated)throw new b(4012,!1);this.location.detach();let n=this.activated;return this.activated=null,this._activatedRoute=null,this.detachEvents.emit(n.instance),n}attach(n,r){this.activated=n,this._activatedRoute=r,this.location.insert(n.hostView),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.attachEvents.emit(n.instance)}deactivate(){if(this.activated){let n=this.component;this.activated.destroy(),this.activated=null,this._activatedRoute=null,this.deactivateEvents.emit(n)}}activateWith(n,r){if(this.isActivated)throw new b(4013,!1);this._activatedRoute=n;let s=this.location,a=n.snapshot.component,c=this.parentContexts.getOrCreateContext(this.name).children,u=new Ze(n,c,s.injector);this.activated=s.createComponent(a,{index:s.length,injector:u,environmentInjector:r??this.environmentInjector}),this.changeDetector.markForCheck(),this.inputBinder?.bindActivatedRouteToOutletComponent(this),this.activateEvents.emit(this.activated.instance)}};t.\u0275fac=function(r){return new(r||t)},t.\u0275dir=me({type:t,selectors:[["router-outlet"]],inputs:{name:"name"},outputs:{activateEvents:"activate",deactivateEvents:"deactivate",attachEvents:"attach",detachEvents:"detach"},exportAs:["outlet"],standalone:!0,features:[Ce]});let e=t;return e})(),Ze=class e{__ngOutletInjector(t){return new e(this.route,this.childContexts,t)}constructor(t,i,n){this.route=t,this.childContexts=i,this.parent=n}get(t,i){return t===H?this.route:t===Nt?this.childContexts:this.parent.get(t,i)}},ae=new O(""),nr=(()=>{let t=class t{constructor(){this.outletDataSubscriptions=new Map}bindActivatedRouteToOutletComponent(n){this.unsubscribeFromRouteData(n),this.subscribeToRouteData(n)}unsubscribeFromRouteData(n){this.outletDataSubscriptions.get(n)?.unsubscribe(),this.outletDataSubscriptions.delete(n)}subscribeToRouteData(n){let{activatedRoute:r}=n,s=Ft([r.queryParams,r.params,r.data]).pipe(x(([o,a,c],u)=>(c=h(h(h({},o),a),c),u===0?d(c):Promise.resolve(c)))).subscribe(o=>{if(!n.isActivated||!n.activatedComponentRef||n.activatedRoute!==r||r.component===null){this.unsubscribeFromRouteData(n);return}let a=Hn(r.component);if(!a){this.unsubscribeFromRouteData(n);return}for(let{templateName:c}of a.inputs)n.activatedComponentRef.setInput(c,o[c])});this.outletDataSubscriptions.set(n,s)}};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:t.\u0275fac});let e=t;return e})();function mi(e,t,i){let n=Ot(e,t._root,i?i._root:void 0);return new ne(n,t)}function Ot(e,t,i){if(i&&e.shouldReuseRoute(t.value,i.value.snapshot)){let n=i.value;n._futureSnapshot=t.value;let r=Ci(e,t,i);return new M(n,r)}else{if(e.shouldAttach(t.value)){let s=e.retrieve(t.value);if(s!==null){let o=s.route;return o.value._futureSnapshot=t.value,o.children=t.children.map(a=>Ot(e,a)),o}}let n=yi(t.value),r=t.children.map(s=>Ot(e,s));return new M(n,r)}}function Ci(e,t,i){return t.children.map(n=>{for(let r of i.children)if(e.shouldReuseRoute(n.value,r.value.snapshot))return Ot(e,n,r);return Ot(e,n)})}function yi(e){return new H(new E(e.url),new E(e.params),new E(e.queryParams),new E(e.fragment),new E(e.data),e.outlet,e.component,e)}var br="ngNavigationCancelingError";function Ir(e,t){let{redirectTo:i,navigationBehaviorOptions:n}=ut(t)?{redirectTo:t,navigationBehaviorOptions:void 0}:t,r=Ar(!1,T.Redirect);return r.url=i,r.navigationBehaviorOptions=n,r}function Ar(e,t){let i=new Error(`NavigationCancelingError: ${e||""}`);return i[br]=!0,i.cancellationCode=t,i}function Ri(e){return Dr(e)&&ut(e.url)}function Dr(e){return!!e&&e[br]}var Si=(()=>{let t=class t{};t.\u0275fac=function(r){return new(r||t)},t.\u0275cmp=Dn({type:t,selectors:[["ng-component"]],standalone:!0,features:[_n],decls:1,vars:0,template:function(r,s){r&1&&zn(0,"router-outlet")},dependencies:[vi],encapsulation:2});let e=t;return e})();function wi(e,t){return e.providers&&!e._injector&&(e._injector=we(e.providers,t,`Route: ${e.path}`)),e._injector??t}function sn(e){let t=e.children&&e.children.map(sn),i=t?I(h({},e),{children:t}):h({},e);return!i.component&&!i.loadComponent&&(t||i.loadChildren)&&i.outlet&&i.outlet!==p&&(i.component=Si),i}function N(e){return e.outlet||p}function bi(e,t){let i=e.filter(n=>N(n)===t);return i.push(...e.filter(n=>N(n)!==t)),i}function jt(e){if(!e)return null;if(e.routeConfig?._injector)return e.routeConfig._injector;for(let t=e.parent;t;t=t.parent){let i=t.routeConfig;if(i?._loadedInjector)return i._loadedInjector;if(i?._injector)return i._injector}return null}var Ii=(e,t,i,n)=>C(r=>(new Ke(t,r.targetRouterState,r.currentRouterState,i,n).activate(e),r)),Ke=class{constructor(t,i,n,r,s){this.routeReuseStrategy=t,this.futureState=i,this.currState=n,this.forwardEvent=r,this.inputBindingEnabled=s}activate(t){let i=this.futureState._root,n=this.currState?this.currState._root:null;this.deactivateChildRoutes(i,n,t),Te(this.futureState.root),this.activateChildRoutes(i,n,t)}deactivateChildRoutes(t,i,n){let r=it(i);t.children.forEach(s=>{let o=s.value.outlet;this.deactivateRoutes(s,r[o],n),delete r[o]}),Object.values(r).forEach(s=>{this.deactivateRouteAndItsChildren(s,n)})}deactivateRoutes(t,i,n){let r=t.value,s=i?i.value:null;if(r===s)if(r.component){let o=n.getContext(r.outlet);o&&this.deactivateChildRoutes(t,i,o.children)}else this.deactivateChildRoutes(t,i,n);else s&&this.deactivateRouteAndItsChildren(i,n)}deactivateRouteAndItsChildren(t,i){t.value.component&&this.routeReuseStrategy.shouldDetach(t.value.snapshot)?this.detachAndStoreRouteSubtree(t,i):this.deactivateRouteAndOutlet(t,i)}detachAndStoreRouteSubtree(t,i){let n=i.getContext(t.value.outlet),r=n&&t.value.component?n.children:i,s=it(t);for(let o of Object.values(s))this.deactivateRouteAndItsChildren(o,r);if(n&&n.outlet){let o=n.outlet.detach(),a=n.children.onOutletDeactivated();this.routeReuseStrategy.store(t.value.snapshot,{componentRef:o,route:t,contexts:a})}}deactivateRouteAndOutlet(t,i){let n=i.getContext(t.value.outlet),r=n&&t.value.component?n.children:i,s=it(t);for(let o of Object.values(s))this.deactivateRouteAndItsChildren(o,r);n&&(n.outlet&&(n.outlet.deactivate(),n.children.onOutletDeactivated()),n.attachRef=null,n.route=null)}activateChildRoutes(t,i,n){let r=it(i);t.children.forEach(s=>{this.activateRoutes(s,r[s.value.outlet],n),this.forwardEvent(new Be(s.value.snapshot))}),t.children.length&&this.forwardEvent(new qe(t.value.snapshot))}activateRoutes(t,i,n){let r=t.value,s=i?i.value:null;if(Te(r),r===s)if(r.component){let o=n.getOrCreateContext(r.outlet);this.activateChildRoutes(t,i,o.children)}else this.activateChildRoutes(t,i,n);else if(r.component){let o=n.getOrCreateContext(r.outlet);if(this.routeReuseStrategy.shouldAttach(r.snapshot)){let a=this.routeReuseStrategy.retrieve(r.snapshot);this.routeReuseStrategy.store(r.snapshot,null),o.children.onOutletReAttached(a.contexts),o.attachRef=a.componentRef,o.route=a.route.value,o.outlet&&o.outlet.attach(a.componentRef,a.route.value),Te(a.route.value),this.activateChildRoutes(t,null,o.children)}else{let a=jt(r.snapshot);o.attachRef=null,o.route=r,o.injector=a,o.outlet&&o.outlet.activateWith(r,o.injector),this.activateChildRoutes(t,null,o.children)}}else this.activateChildRoutes(t,null,n)}},ie=class{constructor(t){this.path=t,this.route=this.path[this.path.length-1]}},ot=class{constructor(t,i){this.component=t,this.route=i}};function Ai(e,t,i){let n=e._root,r=t?t._root:null;return yt(n,r,i,[n.value])}function Di(e){let t=e.routeConfig?e.routeConfig.canActivateChild:null;return!t||t.length===0?null:{node:e,guards:t}}function ht(e,t){let i=Symbol(),n=t.get(e,i);return n===i?typeof e=="function"&&!bn(e)?e:t.get(e):n}function yt(e,t,i,n,r={canDeactivateChecks:[],canActivateChecks:[]}){let s=it(t);return e.children.forEach(o=>{Mi(o,s[o.value.outlet],i,n.concat([o.value]),r),delete s[o.value.outlet]}),Object.entries(s).forEach(([o,a])=>bt(a,i.getContext(o),r)),r}function Mi(e,t,i,n,r={canDeactivateChecks:[],canActivateChecks:[]}){let s=e.value,o=t?t.value:null,a=i?i.getContext(e.value.outlet):null;if(o&&s.routeConfig===o.routeConfig){let c=Ti(o,s,s.routeConfig.runGuardsAndResolvers);c?r.canActivateChecks.push(new ie(n)):(s.data=o.data,s._resolvedData=o._resolvedData),s.component?yt(e,t,a?a.children:null,n,r):yt(e,t,i,n,r),c&&a&&a.outlet&&a.outlet.isActivated&&r.canDeactivateChecks.push(new ot(a.outlet.component,o))}else o&&bt(t,a,r),r.canActivateChecks.push(new ie(n)),s.component?yt(e,null,a?a.children:null,n,r):yt(e,null,i,n,r);return r}function Ti(e,t,i){if(typeof i=="function")return i(e,t);switch(i){case"pathParamsChange":return!K(e.url,t.url);case"pathParamsOrQueryParamsChange":return!K(e.url,t.url)||!P(e.queryParams,t.queryParams);case"always":return!0;case"paramsOrQueryParamsChange":return!Qe(e,t)||!P(e.queryParams,t.queryParams);case"paramsChange":default:return!Qe(e,t)}}function bt(e,t,i){let n=it(e),r=e.value;Object.entries(n).forEach(([s,o])=>{r.component?t?bt(o,t.children.getContext(s),i):bt(o,null,i):bt(o,t,i)}),r.component?t&&t.outlet&&t.outlet.isActivated?i.canDeactivateChecks.push(new ot(t.outlet.component,r)):i.canDeactivateChecks.push(new ot(null,r)):i.canDeactivateChecks.push(new ot(null,r))}function Lt(e){return typeof e=="function"}function Ei(e){return typeof e=="boolean"}function Oi(e){return e&&Lt(e.canLoad)}function Ui(e){return e&&Lt(e.canActivate)}function xi(e){return e&&Lt(e.canActivateChild)}function Pi(e){return e&&Lt(e.canDeactivate)}function $i(e){return e&&Lt(e.canMatch)}function Mr(e){return e instanceof gn||e?.name==="EmptyError"}var Wt=Symbol("INITIAL_VALUE");function lt(){return x(e=>Ft(e.map(t=>t.pipe(J(1),Rn(Wt)))).pipe(C(t=>{for(let i of t)if(i!==!0){if(i===Wt)return Wt;if(i===!1||i instanceof q)return i}return!0}),Q(t=>t!==Wt),J(1)))}function Ni(e,t){return D(i=>{let{targetSnapshot:n,currentSnapshot:r,guards:{canActivateChecks:s,canDeactivateChecks:o}}=i;return o.length===0&&s.length===0?d(I(h({},i),{guardsResult:!0})):ji(o,n,r,e).pipe(D(a=>a&&Ei(a)?Li(n,s,e,t):d(a)),C(a=>I(h({},i),{guardsResult:a})))})}function ji(e,t,i,n){return A(e).pipe(D(r=>qi(r.component,r.route,i,t,n)),z(r=>r!==!0,!0))}function Li(e,t,i,n){return A(t).pipe(X(r=>vn(zi(r.route.parent,n),ki(r.route,n),_i(e,r.path,i),Fi(e,r.route,i))),z(r=>r!==!0,!0))}function ki(e,t){return e!==null&&t&&t(new Ve(e)),d(!0)}function zi(e,t){return e!==null&&t&&t(new _e(e)),d(!0)}function Fi(e,t,i){let n=t.routeConfig?t.routeConfig.canActivate:null;if(!n||n.length===0)return d(!0);let r=n.map(s=>fe(()=>{let o=jt(t)??i,a=ht(s,o),c=Ui(a)?a.canActivate(t,e):_(o,()=>a(t,e));return W(c).pipe(z())}));return d(r).pipe(lt())}function _i(e,t,i){let n=t[t.length-1],s=t.slice(0,t.length-1).reverse().map(o=>Di(o)).filter(o=>o!==null).map(o=>fe(()=>{let a=o.guards.map(c=>{let u=jt(o.node)??i,l=ht(c,u),v=xi(l)?l.canActivateChild(n,e):_(u,()=>l(n,e));return W(v).pipe(z())});return d(a).pipe(lt())}));return d(s).pipe(lt())}function qi(e,t,i,n,r){let s=t&&t.routeConfig?t.routeConfig.canDeactivate:null;if(!s||s.length===0)return d(!0);let o=s.map(a=>{let c=jt(t)??r,u=ht(a,c),l=Pi(u)?u.canDeactivate(e,t,i,n):_(c,()=>u(e,t,i,n));return W(l).pipe(z())});return d(o).pipe(lt())}function Vi(e,t,i,n){let r=t.canLoad;if(r===void 0||r.length===0)return d(!0);let s=r.map(o=>{let a=ht(o,e),c=Oi(a)?a.canLoad(t,i):_(e,()=>a(t,i));return W(c)});return d(s).pipe(lt(),Tr(n))}function Tr(e){return fn(w(t=>{if(ut(t))throw Ir(e,t)}),C(t=>t===!0))}function Bi(e,t,i,n){let r=t.canMatch;if(!r||r.length===0)return d(!0);let s=r.map(o=>{let a=ht(o,e),c=$i(a)?a.canMatch(t,i):_(e,()=>a(t,i));return W(c)});return d(s).pipe(lt(),Tr(n))}var Ut=class{constructor(t){this.segmentGroup=t||null}},se=class extends Error{constructor(t){super(),this.urlTree=t}};function rt(e){return pt(new Ut(e))}function Hi(e){return pt(new b(4e3,!1))}function Wi(e){return pt(Ar(!1,T.GuardRejected))}var Ye=class{constructor(t,i){this.urlSerializer=t,this.urlTree=i}lineralizeSegments(t,i){let n=[],r=i.root;for(;;){if(n=n.concat(r.segments),r.numberOfChildren===0)return d(n);if(r.numberOfChildren>1||!r.children[p])return Hi(t.redirectTo);r=r.children[p]}}applyRedirectCommands(t,i,n){let r=this.applyRedirectCreateUrlTree(i,this.urlSerializer.parse(i),t,n);if(i.startsWith("/"))throw new se(r);return r}applyRedirectCreateUrlTree(t,i,n,r){let s=this.createSegmentGroup(t,i.root,n,r);return new q(s,this.createQueryParams(i.queryParams,this.urlTree.queryParams),i.fragment)}createQueryParams(t,i){let n={};return Object.entries(t).forEach(([r,s])=>{if(typeof s=="string"&&s.startsWith(":")){let a=s.substring(1);n[r]=i[a]}else n[r]=s}),n}createSegmentGroup(t,i,n,r){let s=this.createSegments(t,i.segments,n,r),o={};return Object.entries(i.children).forEach(([a,c])=>{o[a]=this.createSegmentGroup(t,c,n,r)}),new m(s,o)}createSegments(t,i,n,r){return i.map(s=>s.path.startsWith(":")?this.findPosParam(t,s,r):this.findOrReturn(s,n))}findPosParam(t,i,n){let r=n[i.path.substring(1)];if(!r)throw new b(4001,!1);return r}findOrReturn(t,i){let n=0;for(let r of i){if(r.path===t.path)return i.splice(n),r;n++}return t}},Xe={matched:!1,consumedSegments:[],remainingSegments:[],parameters:{},positionalParamSegments:{}};function Gi(e,t,i,n,r){let s=on(e,t,i);return s.matched?(n=wi(t,n),Bi(n,t,i,r).pipe(C(o=>o===!0?s:h({},Xe)))):d(s)}function on(e,t,i){if(t.path==="**")return Qi(i);if(t.path==="")return t.pathMatch==="full"&&(e.hasChildren()||i.length>0)?h({},Xe):{matched:!0,consumedSegments:[],remainingSegments:i,parameters:{},positionalParamSegments:{}};let r=(t.matcher||Vr)(i,e,t);if(!r)return h({},Xe);let s={};Object.entries(r.posParams??{}).forEach(([a,c])=>{s[a]=c.path});let o=r.consumed.length>0?h(h({},s),r.consumed[r.consumed.length-1].parameters):s;return{matched:!0,consumedSegments:r.consumed,remainingSegments:i.slice(r.consumed.length),parameters:o,positionalParamSegments:r.posParams??{}}}function Qi(e){return{matched:!0,parameters:e.length>0?ar(e).parameters:{},consumedSegments:e,remainingSegments:[],positionalParamSegments:{}}}function rr(e,t,i,n){return i.length>0&&Yi(e,i,n)?{segmentGroup:new m(t,Ki(n,new m(i,e.children))),slicedSegments:[]}:i.length===0&&Xi(e,i,n)?{segmentGroup:new m(e.segments,Zi(e,i,n,e.children)),slicedSegments:i}:{segmentGroup:new m(e.segments,e.children),slicedSegments:i}}function Zi(e,t,i,n){let r={};for(let s of i)if(ue(e,t,s)&&!n[N(s)]){let o=new m([],{});r[N(s)]=o}return h(h({},n),r)}function Ki(e,t){let i={};i[p]=t;for(let n of e)if(n.path===""&&N(n)!==p){let r=new m([],{});i[N(n)]=r}return i}function Yi(e,t,i){return i.some(n=>ue(e,t,n)&&N(n)!==p)}function Xi(e,t,i){return i.some(n=>ue(e,t,n))}function ue(e,t,i){return(e.hasChildren()||t.length>0)&&i.pathMatch==="full"?!1:i.path===""}function Ji(e,t,i,n){return N(e)!==n&&(n===p||!ue(t,i,e))?!1:on(t,e,i).matched}function ts(e,t,i){return t.length===0&&!e.children[i]}var Je=class{};function es(e,t,i,n,r,s,o="emptyOnly"){return new tn(e,t,i,n,r,o,s).recognize()}var ns=31,tn=class{constructor(t,i,n,r,s,o,a){this.injector=t,this.configLoader=i,this.rootComponentType=n,this.config=r,this.urlTree=s,this.paramsInheritanceStrategy=o,this.urlSerializer=a,this.applyRedirects=new Ye(this.urlSerializer,this.urlTree),this.absoluteRedirectCount=0,this.allowRedirects=!0}noMatchError(t){return new b(4002,`'${t.segmentGroup}'`)}recognize(){let t=rr(this.urlTree.root,[],[],this.config).segmentGroup;return this.match(t).pipe(C(i=>{let n=new Et([],Object.freeze({}),Object.freeze(h({},this.urlTree.queryParams)),this.urlTree.fragment,{},p,this.rootComponentType,null,{}),r=new M(n,i),s=new re("",r),o=ui(n,[],this.urlTree.queryParams,this.urlTree.fragment);return o.queryParams=this.urlTree.queryParams,s.url=this.urlSerializer.serialize(o),this.inheritParamsAndData(s._root,null),{state:s,tree:o}}))}match(t){return this.processSegmentGroup(this.injector,this.config,t,p).pipe(Y(n=>{if(n instanceof se)return this.urlTree=n.urlTree,this.match(n.urlTree.root);throw n instanceof Ut?this.noMatchError(n):n}))}inheritParamsAndData(t,i){let n=t.value,r=nn(n,i,this.paramsInheritanceStrategy);n.params=Object.freeze(r.params),n.data=Object.freeze(r.data),t.children.forEach(s=>this.inheritParamsAndData(s,n))}processSegmentGroup(t,i,n,r){return n.segments.length===0&&n.hasChildren()?this.processChildren(t,i,n):this.processSegment(t,i,n,n.segments,r,!0).pipe(C(s=>s instanceof M?[s]:[]))}processChildren(t,i,n){let r=[];for(let s of Object.keys(n.children))s==="primary"?r.unshift(s):r.push(s);return A(r).pipe(X(s=>{let o=n.children[s],a=bi(i,s);return this.processSegmentGroup(t,a,o,s)}),yn((s,o)=>(s.push(...o),s)),pe(null),Cn(),D(s=>{if(s===null)return rt(n);let o=Er(s);return rs(o),d(o)}))}processSegment(t,i,n,r,s,o){return A(i).pipe(X(a=>this.processSegmentAgainstRoute(a._injector??t,i,a,n,r,s,o).pipe(Y(c=>{if(c instanceof Ut)return d(null);throw c}))),z(a=>!!a),Y(a=>{if(Mr(a))return ts(n,r,s)?d(new Je):rt(n);throw a}))}processSegmentAgainstRoute(t,i,n,r,s,o,a){return Ji(n,r,s,o)?n.redirectTo===void 0?this.matchSegmentAgainstRoute(t,r,n,s,o):this.allowRedirects&&a?this.expandSegmentAgainstRouteUsingRedirect(t,r,i,n,s,o):rt(r):rt(r)}expandSegmentAgainstRouteUsingRedirect(t,i,n,r,s,o){let{matched:a,consumedSegments:c,positionalParamSegments:u,remainingSegments:l}=on(i,r,s);if(!a)return rt(i);r.redirectTo.startsWith("/")&&(this.absoluteRedirectCount++,this.absoluteRedirectCount>ns&&(this.allowRedirects=!1));let v=this.applyRedirects.applyRedirectCommands(c,r.redirectTo,u);return this.applyRedirects.lineralizeSegments(r,v).pipe(D(g=>this.processSegment(t,n,i,g.concat(l),o,!1)))}matchSegmentAgainstRoute(t,i,n,r,s){let o=Gi(i,n,r,t,this.urlSerializer);return n.path==="**"&&(i.children={}),o.pipe(x(a=>a.matched?(t=n._injector??t,this.getChildConfig(t,n,r).pipe(x(({routes:c})=>{let u=n._loadedInjector??t,{consumedSegments:l,remainingSegments:v,parameters:g}=a,y=new Et(l,g,Object.freeze(h({},this.urlTree.queryParams)),this.urlTree.fragment,ss(n),N(n),n.component??n._loadedComponent??null,n,os(n)),{segmentGroup:dt,slicedSegments:ft}=rr(i,l,v,c);if(ft.length===0&&dt.hasChildren())return this.processChildren(u,c,dt).pipe(C(G=>G===null?null:new M(y,G)));if(c.length===0&&ft.length===0)return d(new M(y,[]));let ce=N(n)===s;return this.processSegment(u,c,dt,ft,ce?p:s,!0).pipe(C(G=>new M(y,G instanceof M?[G]:[])))}))):rt(i)))}getChildConfig(t,i,n){return i.children?d({routes:i.children,injector:t}):i.loadChildren?i._loadedRoutes!==void 0?d({routes:i._loadedRoutes,injector:i._loadedInjector}):Vi(t,i,n,this.urlSerializer).pipe(D(r=>r?this.configLoader.loadChildren(t,i).pipe(w(s=>{i._loadedRoutes=s.routes,i._loadedInjector=s.injector})):Wi(i))):d({routes:[],injector:t})}};function rs(e){e.sort((t,i)=>t.value.outlet===p?-1:i.value.outlet===p?1:t.value.outlet.localeCompare(i.value.outlet))}function is(e){let t=e.value.routeConfig;return t&&t.path===""}function Er(e){let t=[],i=new Set;for(let n of e){if(!is(n)){t.push(n);continue}let r=t.find(s=>n.value.routeConfig===s.value.routeConfig);r!==void 0?(r.children.push(...n.children),i.add(r)):t.push(n)}for(let n of i){let r=Er(n.children);t.push(new M(n.value,r))}return t.filter(n=>!i.has(n))}function ss(e){return e.data||{}}function os(e){return e.resolve||{}}function as(e,t,i,n,r,s){return D(o=>es(e,t,i,n,o.extractedUrl,r,s).pipe(C(({state:a,tree:c})=>I(h({},o),{targetSnapshot:a,urlAfterRedirects:c}))))}function us(e,t){return D(i=>{let{targetSnapshot:n,guards:{canActivateChecks:r}}=i;if(!r.length)return d(i);let s=new Set(r.map(c=>c.route)),o=new Set;for(let c of s)if(!o.has(c))for(let u of Or(c))o.add(u);let a=0;return A(o).pipe(X(c=>s.has(c)?cs(c,n,e,t):(c.data=nn(c,c.parent,e).resolve,d(void 0))),w(()=>a++),ge(1),D(c=>a===o.size?d(i):k))})}function Or(e){let t=e.children.map(i=>Or(i)).flat();return[e,...t]}function cs(e,t,i,n){let r=e.routeConfig,s=e._resolve;return r?.title!==void 0&&!wr(r)&&(s[Pt]=r.title),ls(s,e,t,n).pipe(C(o=>(e._resolvedData=o,e.data=nn(e,e.parent,i).resolve,null)))}function ls(e,t,i,n){let r=Ue(e);if(r.length===0)return d({});let s={};return A(r).pipe(D(o=>hs(e[o],t,i,n).pipe(z(),w(a=>{s[o]=a}))),ge(1),mn(s),Y(o=>Mr(o)?k:pt(o)))}function hs(e,t,i,n){let r=jt(t)??n,s=ht(e,r),o=s.resolve?s.resolve(t,i):_(r,()=>s(t,i));return W(o)}function Ee(e){return x(t=>{let i=e(t);return i?A(i).pipe(C(()=>t)):d(t)})}var Ur=(()=>{let t=class t{buildTitle(n){let r,s=n.root;for(;s!==void 0;)r=this.getResolvedTitleForRoute(s)??r,s=s.children.find(o=>o.outlet===p);return r}getResolvedTitleForRoute(n){return n.data[Pt]}};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:()=>f(ds),providedIn:"root"});let e=t;return e})(),ds=(()=>{let t=class t extends Ur{constructor(n){super(),this.title=n}updateTitle(n){let r=this.buildTitle(n);r!==void 0&&this.title.setTitle(r)}};t.\u0275fac=function(r){return new(r||t)(F(Yn))},t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})(),kt=new O("",{providedIn:"root",factory:()=>({})}),xt=new O(""),an=(()=>{let t=class t{constructor(){this.componentLoaders=new WeakMap,this.childrenLoaders=new WeakMap,this.compiler=f(Vt)}loadComponent(n){if(this.componentLoaders.get(n))return this.componentLoaders.get(n);if(n._loadedComponent)return d(n._loadedComponent);this.onLoadStartListener&&this.onLoadStartListener(n);let r=W(n.loadComponent()).pipe(C(xr),w(o=>{this.onLoadEndListener&&this.onLoadEndListener(n),n._loadedComponent=o}),_t(()=>{this.componentLoaders.delete(n)})),s=new he(r,()=>new L).pipe(le());return this.componentLoaders.set(n,s),s}loadChildren(n,r){if(this.childrenLoaders.get(r))return this.childrenLoaders.get(r);if(r._loadedRoutes)return d({routes:r._loadedRoutes,injector:r._loadedInjector});this.onLoadStartListener&&this.onLoadStartListener(r);let o=fs(r,this.compiler,n,this.onLoadEndListener).pipe(_t(()=>{this.childrenLoaders.delete(r)})),a=new he(o,()=>new L).pipe(le());return this.childrenLoaders.set(r,a),a}};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})();function fs(e,t,i,n){return W(e.loadChildren()).pipe(C(xr),D(r=>r instanceof jn||Array.isArray(r)?d(r):A(t.compileModuleAsync(r))),C(r=>{n&&n(e);let s,o,a=!1;return Array.isArray(r)?(o=r,a=!0):(s=r.create(i).injector,o=s.get(xt,[],{optional:!0,self:!0}).flat()),{routes:o.map(sn),injector:s}}))}function ps(e){return e&&typeof e=="object"&&"default"in e}function xr(e){return ps(e)?e.default:e}var un=(()=>{let t=class t{};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:()=>f(gs),providedIn:"root"});let e=t;return e})(),gs=(()=>{let t=class t{shouldProcessUrl(n){return!0}extract(n){return n}merge(n,r){return n}};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})(),Pr=new O(""),$r=new O("");function vs(e,t,i){let n=e.get($r),r=e.get(Wn);return e.get(nt).runOutsideAngular(()=>{if(!r.startViewTransition||n.skipNextTransition)return n.skipNextTransition=!1,new Promise(u=>setTimeout(u));let s,o=new Promise(u=>{s=u}),a=r.startViewTransition(()=>(s(),ms(e))),{onViewTransitionCreated:c}=n;return c&&_(e,()=>c({transition:a,from:t,to:i})),o})}function ms(e){return new Promise(t=>{Se(t,{injector:e})})}var cn=(()=>{let t=class t{get hasRequestedNavigation(){return this.navigationId!==0}constructor(){this.currentNavigation=null,this.currentTransition=null,this.lastSuccessfulNavigation=null,this.events=new L,this.transitionAbortSubject=new L,this.configLoader=f(an),this.environmentInjector=f(tt),this.urlSerializer=f($t),this.rootContexts=f(Nt),this.location=f(mt),this.inputBindingEnabled=f(ae,{optional:!0})!==null,this.titleStrategy=f(Ur),this.options=f(kt,{optional:!0})||{},this.paramsInheritanceStrategy=this.options.paramsInheritanceStrategy||"emptyOnly",this.urlHandlingStrategy=f(un),this.createViewTransition=f(Pr,{optional:!0}),this.navigationId=0,this.afterPreactivation=()=>d(void 0),this.rootComponentType=null;let n=s=>this.events.next(new ze(s)),r=s=>this.events.next(new Fe(s));this.configLoader.onLoadEndListener=r,this.configLoader.onLoadStartListener=n}complete(){this.transitions?.complete()}handleNavigationRequest(n){let r=++this.navigationId;this.transitions?.next(I(h(h({},this.transitions.value),n),{id:r}))}setupNavigations(n,r,s){return this.transitions=new E({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:wt,restoredState:null,currentSnapshot:s.snapshot,targetSnapshot:null,currentRouterState:s,targetRouterState:null,guards:{canActivateChecks:[],canDeactivateChecks:[]},guardsResult:null}),this.transitions.pipe(Q(o=>o.id!==0),C(o=>I(h({},o),{extractedUrl:this.urlHandlingStrategy.extract(o.rawUrl)})),x(o=>{let a=!1,c=!1;return d(o).pipe(x(u=>{if(this.navigationId>o.id)return this.cancelNavigationTransition(o,"",T.SupersededByNewNavigation),k;this.currentTransition=o,this.currentNavigation={id:u.id,initialUrl:u.rawUrl,extractedUrl:u.extractedUrl,trigger:u.source,extras:u.extras,previousNavigation:this.lastSuccessfulNavigation?I(h({},this.lastSuccessfulNavigation),{previousNavigation:null}):null};let l=!n.navigated||this.isUpdatingInternalState()||this.isUpdatedBrowserUrl(),v=u.extras.onSameUrlNavigation??n.onSameUrlNavigation;if(!l&&v!=="reload"){let g="";return this.events.next(new B(u.id,this.urlSerializer.serialize(u.rawUrl),g,Xt.IgnoredSameUrlNavigation)),u.resolve(null),k}if(this.urlHandlingStrategy.shouldProcessUrl(u.rawUrl))return d(u).pipe(x(g=>{let y=this.transitions?.getValue();return this.events.next(new ct(g.id,this.urlSerializer.serialize(g.extractedUrl),g.source,g.restoredState)),y!==this.transitions?.getValue()?k:Promise.resolve(g)}),as(this.environmentInjector,this.configLoader,this.rootComponentType,n.config,this.urlSerializer,this.paramsInheritanceStrategy),w(g=>{o.targetSnapshot=g.targetSnapshot,o.urlAfterRedirects=g.urlAfterRedirects,this.currentNavigation=I(h({},this.currentNavigation),{finalUrl:g.urlAfterRedirects});let y=new Jt(g.id,this.urlSerializer.serialize(g.extractedUrl),this.urlSerializer.serialize(g.urlAfterRedirects),g.targetSnapshot);this.events.next(y)}));if(l&&this.urlHandlingStrategy.shouldProcessUrl(u.currentRawUrl)){let{id:g,extractedUrl:y,source:dt,restoredState:ft,extras:ce}=u,G=new ct(g,this.urlSerializer.serialize(y),dt,ft);this.events.next(G);let qr=Rr(this.rootComponentType).snapshot;return this.currentTransition=o=I(h({},u),{targetSnapshot:qr,urlAfterRedirects:y,extras:I(h({},ce),{skipLocationChange:!1,replaceUrl:!1})}),this.currentNavigation.finalUrl=y,d(o)}else{let g="";return this.events.next(new B(u.id,this.urlSerializer.serialize(u.extractedUrl),g,Xt.IgnoredByUrlHandlingStrategy)),u.resolve(null),k}}),w(u=>{let l=new Ne(u.id,this.urlSerializer.serialize(u.extractedUrl),this.urlSerializer.serialize(u.urlAfterRedirects),u.targetSnapshot);this.events.next(l)}),C(u=>(this.currentTransition=o=I(h({},u),{guards:Ai(u.targetSnapshot,u.currentSnapshot,this.rootContexts)}),o)),Ni(this.environmentInjector,u=>this.events.next(u)),w(u=>{if(o.guardsResult=u.guardsResult,ut(u.guardsResult))throw Ir(this.urlSerializer,u.guardsResult);let l=new je(u.id,this.urlSerializer.serialize(u.extractedUrl),this.urlSerializer.serialize(u.urlAfterRedirects),u.targetSnapshot,!!u.guardsResult);this.events.next(l)}),Q(u=>u.guardsResult?!0:(this.cancelNavigationTransition(u,"",T.GuardRejected),!1)),Ee(u=>{if(u.guards.canActivateChecks.length)return d(u).pipe(w(l=>{let v=new Le(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(v)}),x(l=>{let v=!1;return d(l).pipe(us(this.paramsInheritanceStrategy,this.environmentInjector),w({next:()=>v=!0,complete:()=>{v||this.cancelNavigationTransition(l,"",T.NoDataFromResolver)}}))}),w(l=>{let v=new ke(l.id,this.urlSerializer.serialize(l.extractedUrl),this.urlSerializer.serialize(l.urlAfterRedirects),l.targetSnapshot);this.events.next(v)}))}),Ee(u=>{let l=v=>{let g=[];v.routeConfig?.loadComponent&&!v.routeConfig._loadedComponent&&g.push(this.configLoader.loadComponent(v.routeConfig).pipe(w(y=>{v.component=y}),C(()=>{})));for(let y of v.children)g.push(...l(y));return g};return Ft(l(u.targetSnapshot.root)).pipe(pe(null),J(1))}),Ee(()=>this.afterPreactivation()),x(()=>{let{currentSnapshot:u,targetSnapshot:l}=o,v=this.createViewTransition?.(this.environmentInjector,u.root,l.root);return v?A(v).pipe(C(()=>o)):d(o)}),C(u=>{let l=mi(n.routeReuseStrategy,u.targetSnapshot,u.currentRouterState);return this.currentTransition=o=I(h({},u),{targetRouterState:l}),this.currentNavigation.targetRouterState=l,o}),w(()=>{this.events.next(new Mt)}),Ii(this.rootContexts,n.routeReuseStrategy,u=>this.events.next(u),this.inputBindingEnabled),J(1),w({next:u=>{a=!0,this.lastSuccessfulNavigation=this.currentNavigation,this.events.next(new $(u.id,this.urlSerializer.serialize(u.extractedUrl),this.urlSerializer.serialize(u.urlAfterRedirects))),this.titleStrategy?.updateTitle(u.targetRouterState.snapshot),u.resolve(!0)},complete:()=>{a=!0}}),Sn(this.transitionAbortSubject.pipe(w(u=>{throw u}))),_t(()=>{!a&&!c&&this.cancelNavigationTransition(o,"",T.SupersededByNewNavigation),this.currentTransition?.id===o.id&&(this.currentNavigation=null,this.currentTransition=null)}),Y(u=>{if(c=!0,Dr(u))this.events.next(new V(o.id,this.urlSerializer.serialize(o.extractedUrl),u.message,u.cancellationCode)),Ri(u)?this.events.next(new Tt(u.url)):o.resolve(!1);else{this.events.next(new Dt(o.id,this.urlSerializer.serialize(o.extractedUrl),u,o.targetSnapshot??void 0));try{o.resolve(n.errorHandler(u))}catch(l){this.options.resolveNavigationPromiseOnError?o.resolve(!1):o.reject(l)}}return k}))}))}cancelNavigationTransition(n,r,s){let o=new V(n.id,this.urlSerializer.serialize(n.extractedUrl),r,s);this.events.next(o),n.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}};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})();function Cs(e){return e!==wt}var ys=(()=>{let t=class t{};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:()=>f(Rs),providedIn:"root"});let e=t;return e})(),en=class{shouldDetach(t){return!1}store(t,i){}shouldAttach(t){return!1}retrieve(t){return null}shouldReuseRoute(t,i){return t.routeConfig===i.routeConfig}},Rs=(()=>{let t=class t extends en{};t.\u0275fac=(()=>{let n;return function(s){return(n||(n=ye(t)))(s||t)}})(),t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})(),Nr=(()=>{let t=class t{};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:()=>f(Ss),providedIn:"root"});let e=t;return e})(),Ss=(()=>{let t=class t extends Nr{constructor(){super(...arguments),this.location=f(mt),this.urlSerializer=f($t),this.options=f(kt,{optional:!0})||{},this.canceledNavigationResolution=this.options.canceledNavigationResolution||"replace",this.urlHandlingStrategy=f(un),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.currentUrlTree=new q,this.rawUrlTree=this.currentUrlTree,this.currentPageId=0,this.lastSuccessfulId=-1,this.routerState=Rr(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(n){return this.location.subscribe(r=>{r.type==="popstate"&&n(r.url,r.state)})}handleRouterEvent(n,r){if(n instanceof ct)this.stateMemento=this.createStateMemento();else if(n instanceof B)this.rawUrlTree=r.initialUrl;else if(n instanceof Jt){if(this.urlUpdateStrategy==="eager"&&!r.extras.skipLocationChange){let s=this.urlHandlingStrategy.merge(r.finalUrl,r.initialUrl);this.setBrowserUrl(s,r)}}else n instanceof Mt?(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))):n instanceof V&&(n.code===T.GuardRejected||n.code===T.NoDataFromResolver)?this.restoreHistory(r):n instanceof Dt?this.restoreHistory(r,!0):n instanceof $&&(this.lastSuccessfulId=n.id,this.currentPageId=this.browserPageId)}setBrowserUrl(n,r){let s=this.urlSerializer.serialize(n);if(this.location.isCurrentPathEqualTo(s)||r.extras.replaceUrl){let o=this.browserPageId,a=h(h({},r.extras.state),this.generateNgRouterState(r.id,o));this.location.replaceState(s,"",a)}else{let o=h(h({},r.extras.state),this.generateNgRouterState(r.id,this.browserPageId+1));this.location.go(s,"",o)}}restoreHistory(n,r=!1){if(this.canceledNavigationResolution==="computed"){let s=this.browserPageId,o=this.currentPageId-s;o!==0?this.location.historyGo(o):this.currentUrlTree===n.finalUrl&&o===0&&(this.resetState(n),this.resetUrlToCurrentUrlTree())}else this.canceledNavigationResolution==="replace"&&(r&&this.resetState(n),this.resetUrlToCurrentUrlTree())}resetState(n){this.routerState=this.stateMemento.routerState,this.currentUrlTree=this.stateMemento.currentUrlTree,this.rawUrlTree=this.urlHandlingStrategy.merge(this.currentUrlTree,n.finalUrl??this.rawUrlTree)}resetUrlToCurrentUrlTree(){this.location.replaceState(this.urlSerializer.serialize(this.rawUrlTree),"",this.generateNgRouterState(this.lastSuccessfulId,this.currentPageId))}generateNgRouterState(n,r){return this.canceledNavigationResolution==="computed"?{navigationId:n,\u0275routerPageId:r}:{navigationId:n}}};t.\u0275fac=(()=>{let n;return function(s){return(n||(n=ye(t)))(s||t)}})(),t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})(),Rt=function(e){return e[e.COMPLETE=0]="COMPLETE",e[e.FAILED=1]="FAILED",e[e.REDIRECTING=2]="REDIRECTING",e}(Rt||{});function jr(e,t){e.events.pipe(Q(i=>i instanceof $||i instanceof V||i instanceof Dt||i instanceof B),C(i=>i instanceof $||i instanceof B?Rt.COMPLETE:(i instanceof V?i.code===T.Redirect||i.code===T.SupersededByNewNavigation:!1)?Rt.REDIRECTING:Rt.FAILED),Q(i=>i!==Rt.REDIRECTING),J(1)).subscribe(()=>{t()})}function ws(e){throw e}var bs={paths:"exact",fragment:"ignored",matrixParams:"ignored",queryParams:"exact"},Is={paths:"subset",fragment:"ignored",matrixParams:"ignored",queryParams:"subset"},j=(()=>{let t=class t{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=f(qn),this.stateManager=f(Nr),this.options=f(kt,{optional:!0})||{},this.pendingTasks=f(Ln),this.urlUpdateStrategy=this.options.urlUpdateStrategy||"deferred",this.navigationTransitions=f(cn),this.urlSerializer=f($t),this.location=f(mt),this.urlHandlingStrategy=f(un),this._events=new L,this.errorHandler=this.options.errorHandler||ws,this.navigated=!1,this.routeReuseStrategy=f(ys),this.onSameUrlNavigation=this.options.onSameUrlNavigation||"ignore",this.config=f(xt,{optional:!0})?.flat()??[],this.componentInputBindingEnabled=!!f(ae,{optional:!0}),this.eventsSubscription=new dn,this.isNgZoneEnabled=f(nt)instanceof nt&&nt.isInAngularZone(),this.resetConfig(this.config),this.navigationTransitions.setupNavigations(this,this.currentUrlTree,this.routerState).subscribe({error:n=>{this.console.warn(n)}}),this.subscribeToNavigationEvents()}subscribeToNavigationEvents(){let n=this.navigationTransitions.events.subscribe(r=>{try{let s=this.navigationTransitions.currentTransition,o=this.navigationTransitions.currentNavigation;if(s!==null&&o!==null){if(this.stateManager.handleRouterEvent(r,o),r instanceof V&&r.code!==T.Redirect&&r.code!==T.SupersededByNewNavigation)this.navigated=!0;else if(r instanceof $)this.navigated=!0;else if(r instanceof Tt){let a=this.urlHandlingStrategy.merge(r.url,s.currentRawUrl),c={info:s.extras.info,skipLocationChange:s.extras.skipLocationChange,replaceUrl:this.urlUpdateStrategy==="eager"||Cs(s.source)};this.scheduleNavigation(a,wt,null,c,{resolve:s.resolve,reject:s.reject,promise:s.promise})}}Ds(r)&&this._events.next(r)}catch(s){this.navigationTransitions.transitionAbortSubject.next(s)}});this.eventsSubscription.add(n)}resetRootComponentType(n){this.routerState.root.component=n,this.navigationTransitions.rootComponentType=n}initialNavigation(){this.setUpLocationChangeListener(),this.navigationTransitions.hasRequestedNavigation||this.navigateToSyncWithBrowser(this.location.path(!0),wt,this.stateManager.restoredState())}setUpLocationChangeListener(){this.nonRouterCurrentEntryChangeSubscription??=this.stateManager.registerNonRouterCurrentEntryChangeListener((n,r)=>{setTimeout(()=>{this.navigateToSyncWithBrowser(n,"popstate",r)},0)})}navigateToSyncWithBrowser(n,r,s){let o={replaceUrl:!0},a=s?.navigationId?s:null;if(s){let u=h({},s);delete u.navigationId,delete u.\u0275routerPageId,Object.keys(u).length!==0&&(o.state=u)}let c=this.parseUrl(n);this.scheduleNavigation(c,r,a,o)}get url(){return this.serializeUrl(this.currentUrlTree)}getCurrentNavigation(){return this.navigationTransitions.currentNavigation}get lastSuccessfulNavigation(){return this.navigationTransitions.lastSuccessfulNavigation}resetConfig(n){this.config=n.map(sn),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(n,r={}){let{relativeTo:s,queryParams:o,fragment:a,queryParamsHandling:c,preserveFragment:u}=r,l=u?this.currentUrlTree.fragment:a,v=null;switch(c){case"merge":v=h(h({},this.currentUrlTree.queryParams),o);break;case"preserve":v=this.currentUrlTree.queryParams;break;default:v=o||null}v!==null&&(v=this.removeEmptyProps(v));let g;try{let y=s?s.snapshot:this.routerState.snapshot.root;g=vr(y)}catch{(typeof n[0]!="string"||!n[0].startsWith("/"))&&(n=[]),g=this.currentUrlTree.root}return mr(g,n,v,l??null)}navigateByUrl(n,r={skipLocationChange:!1}){let s=ut(n)?n:this.parseUrl(n),o=this.urlHandlingStrategy.merge(s,this.rawUrlTree);return this.scheduleNavigation(o,wt,null,r)}navigate(n,r={skipLocationChange:!1}){return As(n),this.navigateByUrl(this.createUrlTree(n,r),r)}serializeUrl(n){return this.urlSerializer.serialize(n)}parseUrl(n){try{return this.urlSerializer.parse(n)}catch{return this.urlSerializer.parse("/")}}isActive(n,r){let s;if(r===!0?s=h({},bs):r===!1?s=h({},Is):s=r,ut(n))return Xn(this.currentUrlTree,n,s);let o=this.parseUrl(n);return Xn(this.currentUrlTree,o,s)}removeEmptyProps(n){return Object.entries(n).reduce((r,[s,o])=>(o!=null&&(r[s]=o),r),{})}scheduleNavigation(n,r,s,o,a){if(this.disposed)return Promise.resolve(!1);let c,u,l;a?(c=a.resolve,u=a.reject,l=a.promise):l=new Promise((g,y)=>{c=g,u=y});let v=this.pendingTasks.add();return jr(this,()=>{queueMicrotask(()=>this.pendingTasks.remove(v))}),this.navigationTransitions.handleNavigationRequest({source:r,restoredState:s,currentUrlTree:this.currentUrlTree,currentRawUrl:this.currentUrlTree,rawUrl:n,extras:o,resolve:c,reject:u,promise:l,currentSnapshot:this.routerState.snapshot,currentRouterState:this.routerState}),l.catch(g=>Promise.reject(g))}};t.\u0275fac=function(r){return new(r||t)},t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})();function As(e){for(let t=0;t<e.length;t++)if(e[t]==null)throw new b(4008,!1)}function Ds(e){return!(e instanceof Mt)&&!(e instanceof Tt)}var fo=(()=>{let t=class t{constructor(n,r,s,o,a,c){this.router=n,this.route=r,this.tabIndexAttribute=s,this.renderer=o,this.el=a,this.locationStrategy=c,this.href=null,this.commands=null,this.onChanges=new L,this.preserveFragment=!1,this.skipLocationChange=!1,this.replaceUrl=!1;let u=a.nativeElement.tagName?.toLowerCase();this.isAnchorElement=u==="a"||u==="area",this.isAnchorElement?this.subscription=n.events.subscribe(l=>{l instanceof $&&this.updateHref()}):this.setTabIndexIfNotOnNativeEl("0")}setTabIndexIfNotOnNativeEl(n){this.tabIndexAttribute!=null||this.isAnchorElement||this.applyAttributeValue("tabindex",n)}ngOnChanges(n){this.isAnchorElement&&this.updateHref(),this.onChanges.next(this)}set routerLink(n){n!=null?(this.commands=Array.isArray(n)?n:[n],this.setTabIndexIfNotOnNativeEl("0")):(this.commands=null,this.setTabIndexIfNotOnNativeEl(null))}onClick(n,r,s,o,a){let c=this.urlTree;if(c===null||this.isAnchorElement&&(n!==0||r||s||o||a||typeof this.target=="string"&&this.target!="_self"))return!0;let u={skipLocationChange:this.skipLocationChange,replaceUrl:this.replaceUrl,state:this.state,info:this.info};return this.router.navigateByUrl(c,u),!this.isAnchorElement}ngOnDestroy(){this.subscription?.unsubscribe()}updateHref(){let n=this.urlTree;this.href=n!==null&&this.locationStrategy?this.locationStrategy?.prepareExternalUrl(this.router.serializeUrl(n)):null;let r=this.href===null?null:Un(this.href,this.el.nativeElement.tagName.toLowerCase(),"href");this.applyAttributeValue("href",r)}applyAttributeValue(n,r){let s=this.renderer,o=this.el.nativeElement;r!==null?s.setAttribute(o,n,r):s.removeAttribute(o,n)}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})}};t.\u0275fac=function(r){return new(r||t)(et(j),et(H),En("tabindex"),et(Pn),et(On),et(vt))},t.\u0275dir=me({type:t,selectors:[["","routerLink",""]],hostVars:1,hostBindings:function(r,s){r&1&&Fn("click",function(a){return s.onClick(a.button,a.ctrlKey,a.shiftKey,a.altKey,a.metaKey)}),r&2&&kn("target",s.target)},inputs:{target:"target",queryParams:"queryParams",fragment:"fragment",queryParamsHandling:"queryParamsHandling",state:"state",info:"info",relativeTo:"relativeTo",preserveFragment:[qt.HasDecoratorInputTransform,"preserveFragment","preserveFragment",Bt],skipLocationChange:[qt.HasDecoratorInputTransform,"skipLocationChange","skipLocationChange",Bt],replaceUrl:[qt.HasDecoratorInputTransform,"replaceUrl","replaceUrl",Bt],routerLink:"routerLink"},standalone:!0,features:[Nn,Ce]});let e=t;return e})();var oe=class{};var Ms=(()=>{let t=class t{constructor(n,r,s,o,a){this.router=n,this.injector=s,this.preloadingStrategy=o,this.loader=a}setUpPreloading(){this.subscription=this.router.events.pipe(Q(n=>n instanceof $),X(()=>this.preload())).subscribe(()=>{})}preload(){return this.processRoutes(this.injector,this.router.config)}ngOnDestroy(){this.subscription&&this.subscription.unsubscribe()}processRoutes(n,r){let s=[];for(let o of r){o.providers&&!o._injector&&(o._injector=we(o.providers,n,`Route: ${o.path}`));let a=o._injector??n,c=o._loadedInjector??a;(o.loadChildren&&!o._loadedRoutes&&o.canLoad===void 0||o.loadComponent&&!o._loadedComponent)&&s.push(this.preloadConfig(a,o)),(o.children||o._loadedRoutes)&&s.push(this.processRoutes(c,o.children??o._loadedRoutes))}return A(s).pipe(de())}preloadConfig(n,r){return this.preloadingStrategy.preload(r,()=>{let s;r.loadChildren&&r.canLoad===void 0?s=this.loader.loadChildren(n,r):s=d(null);let o=s.pipe(D(a=>a===null?d(void 0):(r._loadedRoutes=a.routes,r._loadedInjector=a.injector,this.processRoutes(a.injector??n,a.routes))));if(r.loadComponent&&!r._loadedComponent){let a=this.loader.loadComponent(r);return A([o,a]).pipe(de())}else return o})}};t.\u0275fac=function(r){return new(r||t)(F(j),F(Vt),F(tt),F(oe),F(an))},t.\u0275prov=S({token:t,factory:t.\u0275fac,providedIn:"root"});let e=t;return e})(),Lr=new O(""),Ts=(()=>{let t=class t{constructor(n,r,s,o,a={}){this.urlSerializer=n,this.transitions=r,this.viewportScroller=s,this.zone=o,this.options=a,this.lastId=0,this.lastSource="imperative",this.restoredId=0,this.store={},this.environmentInjector=f(tt),a.scrollPositionRestoration||="disabled",a.anchorScrolling||="disabled"}init(){this.options.scrollPositionRestoration!=="disabled"&&this.viewportScroller.setHistoryScrollRestoration("manual"),this.routerEventsSubscription=this.createScrollEvents(),this.scrollEventsSubscription=this.consumeScrollEvents()}createScrollEvents(){return this.transitions.events.subscribe(n=>{n instanceof ct?(this.store[this.lastId]=this.viewportScroller.getScrollPosition(),this.lastSource=n.navigationTrigger,this.restoredId=n.restoredState?n.restoredState.navigationId:0):n instanceof $?(this.lastId=n.id,this.scheduleScrollEvent(n,this.urlSerializer.parse(n.urlAfterRedirects).fragment)):n instanceof B&&n.code===Xt.IgnoredSameUrlNavigation&&(this.lastSource=void 0,this.restoredId=0,this.scheduleScrollEvent(n,this.urlSerializer.parse(n.url).fragment))})}consumeScrollEvents(){return this.transitions.events.subscribe(n=>{n instanceof te&&(n.position?this.options.scrollPositionRestoration==="top"?this.viewportScroller.scrollToPosition([0,0]):this.options.scrollPositionRestoration==="enabled"&&this.viewportScroller.scrollToPosition(n.position):n.anchor&&this.options.anchorScrolling==="enabled"?this.viewportScroller.scrollToAnchor(n.anchor):this.options.scrollPositionRestoration!=="disabled"&&this.viewportScroller.scrollToPosition([0,0]))})}scheduleScrollEvent(n,r){this.zone.runOutsideAngular(()=>hn(this,null,function*(){yield new Promise(s=>{setTimeout(()=>{s()}),Se(()=>{s()},{injector:this.environmentInjector})}),this.zone.run(()=>{this.transitions.events.next(new te(n,this.lastSource==="popstate"?this.store[this.restoredId]:null,r))})}))}ngOnDestroy(){this.routerEventsSubscription?.unsubscribe(),this.scrollEventsSubscription?.unsubscribe()}};t.\u0275fac=function(r){xn()},t.\u0275prov=S({token:t,factory:t.\u0275fac});let e=t;return e})();function po(e,...t){return Tn([{provide:xt,multi:!0,useValue:e},[],{provide:H,useFactory:kr,deps:[j]},{provide:Ie,multi:!0,useFactory:zr},t.map(i=>i.\u0275providers)])}function kr(e){return e.routerState.root}function zt(e,t){return{\u0275kind:e,\u0275providers:t}}function zr(){let e=f(Re);return t=>{let i=e.get(Bn);if(t!==i.components[0])return;let n=e.get(j),r=e.get(Fr);e.get(ln)===1&&n.initialNavigation(),e.get(_r,null,ve.Optional)?.setUpPreloading(),e.get(Lr,null,ve.Optional)?.init(),n.resetRootComponentType(i.componentTypes[0]),r.closed||(r.next(),r.complete(),r.unsubscribe())}}var Fr=new O("",{factory:()=>new L}),ln=new O("",{providedIn:"root",factory:()=>1});function Es(){return zt(2,[{provide:ln,useValue:0},{provide:be,multi:!0,deps:[Re],useFactory:t=>{let i=t.get(Gn,Promise.resolve());return()=>i.then(()=>new Promise(n=>{let r=t.get(j),s=t.get(Fr);jr(r,()=>{n(!0)}),t.get(cn).afterPreactivation=()=>(n(!0),s.closed?d(void 0):s),r.initialNavigation()}))}}])}function Os(){return zt(3,[{provide:be,multi:!0,useFactory:()=>{let t=f(j);return()=>{t.setUpLocationChangeListener()}}},{provide:ln,useValue:2}])}var _r=new O("");function Us(e){return zt(0,[{provide:_r,useExisting:Ms},{provide:oe,useExisting:e}])}function xs(){return zt(8,[nr,{provide:ae,useExisting:nr}])}function Ps(e){let t=[{provide:Pr,useValue:vs},{provide:$r,useValue:h({skipNextTransition:!!e?.skipInitialTransition},e)}];return zt(9,t)}var ir=new O("ROUTER_FORROOT_GUARD"),$s=[mt,{provide:$t,useClass:It},j,Nt,{provide:H,useFactory:kr,deps:[j]},an,[]],go=(()=>{let t=class t{constructor(n){}static forRoot(n,r){return{ngModule:t,providers:[$s,[],{provide:xt,multi:!0,useValue:n},{provide:ir,useFactory:ks,deps:[[j,new In,new An]]},{provide:kt,useValue:r||{}},r?.useHash?js():Ls(),Ns(),r?.preloadingStrategy?Us(r.preloadingStrategy).\u0275providers:[],r?.initialNavigation?zs(r):[],r?.bindToComponentInputs?xs().\u0275providers:[],r?.enableViewTransitions?Ps().\u0275providers:[],Fs()]}}static forChild(n){return{ngModule:t,providers:[{provide:xt,multi:!0,useValue:n}]}}};t.\u0275fac=function(r){return new(r||t)(F(ir,8))},t.\u0275mod=Mn({type:t}),t.\u0275inj=wn({});let e=t;return e})();function Ns(){return{provide:Lr,useFactory:()=>{let e=f(Kn),t=f(nt),i=f(kt),n=f(cn),r=f($t);return i.scrollOffset&&e.setOffset(i.scrollOffset),new Ts(r,n,e,t,i)}}}function js(){return{provide:vt,useClass:Zn}}function Ls(){return{provide:vt,useClass:Qn}}function ks(e){return"guarded"}function zs(e){return[e.initialNavigation==="disabled"?Os().\u0275providers:[],e.initialNavigation==="enabledBlocking"?Es().\u0275providers:[]]}var sr=new O("");function Fs(){return[{provide:sr,useFactory:zr},{provide:Ie,multi:!0,useExisting:sr}]}export{p as a,Z as b,ct as c,$ as d,V as e,B as f,Dt as g,Jt as h,H as i,vi as j,j as k,fo as l,po as m,Es as n,go as o};